annotate src/of-netcdf-1-fixes.patch @ 4421:e76a7e02174d

of-netcdf: allow build in dev octave * src/of-netcdf-1-fixes.patch: new file * dist-files.mk: add of-netcdf-1-fixes.patch * src/of-netcdf.mk: run autogen.sh on src dir
author John D
date Fri, 14 Jul 2017 11:53:49 -0400
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4421
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
1 diff --git a/src/configure.base b/src/configure.base
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
2 index 176e152..ae67f7a 100644
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
3 --- a/src/configure.base
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
4 +++ b/src/configure.base
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
5 @@ -53,106 +53,6 @@ test -z "$MKOCTFILE" && AC_MSG_WARN([no mkoctfile found on path])
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
6 AC_CHECK_PROG(OCTAVE_CONFIG,octave-config,octave-config)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
7 test -z "$OCTAVE_CONFIG" && AC_MSG_WARN([no octave-config found on path])
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
8
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
9 -AC_SUBST(ver)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
10 -AC_SUBST(subver)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
11 -AC_SUBST(mpath)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
12 -AC_SUBST(opath)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
13 -AC_SUBST(xpath)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
14 -AC_SUBST(altpath)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
15 -AC_SUBST(altmpath)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
16 -AC_SUBST(altopath)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
17 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
18 -AC_ARG_WITH(path,
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
19 - [ --with-path install path prefix],
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
20 - [ path=$withval ])
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
21 -AC_ARG_WITH(mpath,
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
22 - [ --with-mpath override path for m-files],
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
23 - [mpath=$withval])
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
24 -AC_ARG_WITH(opath,
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
25 - [ --with-opath override path for oct-files],
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
26 - [opath=$withval])
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
27 -AC_ARG_WITH(xpath,
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
28 - [ --with-xpath override path for executables],
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
29 - [xpath=$withval])
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
30 -AC_ARG_WITH(altpath,
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
31 - [ --with-altpath alternative functions install path prefix],
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
32 - [ altpath=$withval ])
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
33 -AC_ARG_WITH(altmpath,
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
34 - [ --with-altmpath override path for alternative m-files],
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
35 - [altmpath=$withval])
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
36 -AC_ARG_WITH(altopath,
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
37 - [ --with-altopath override path for alternative oct-files],
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
38 - [altopath=$withval])
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
39 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
40 -if test -n "$path" ; then
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
41 - test -z "$mpath" && mpath=$path
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
42 - test -z "$opath" && opath=$path/oct
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
43 - test -z "$xpath" && xpath=$path/bin
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
44 - test -z "$altpath" && altpath=$path-alternatives
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
45 -fi
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
46 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
47 -if test -n "$altpath" ; then
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
48 - test -z "$altmpath" && altmpath=$altpath
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
49 - test -z "$altopath" && altopath=$altpath/oct
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
50 -fi
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
51 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
52 -dnl Don't query if path/ver are given in the configure environment
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
53 -#if test -z "$mpath" || test -z "$opath" || test -z "$xpath" || test -z "$altmpath" || test -z "$altopath" || test -z "$ver" ; then
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
54 -if test -z "$mpath" || test -z "$opath" || test -z "$xpath" || test -z "$ver" ; then
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
55 - dnl Construct program to get mkoctfile version and local install paths
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
56 - cat > conftest.cc <<EOF
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
57 -#include <octave/config.h>
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
58 -#include <octave/version.h>
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
59 -#include <octave/defaults.h>
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
60 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
61 -#define INFOV "\nINFOV=" OCTAVE_VERSION "\n"
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
62 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
63 -#define INFOH "\nINFOH=" OCTAVE_CANONICAL_HOST_TYPE "\n"
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
64 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
65 -#ifdef OCTAVE_LOCALVERFCNFILEDIR
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
66 -# define INFOM "\nINFOM=" OCTAVE_LOCALVERFCNFILEDIR "\n"
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
67 -#else
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
68 -# define INFOM "\nINFOM=" OCTAVE_LOCALFCNFILEPATH "\n"
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
69 -#endif
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
70 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
71 -#ifdef OCTAVE_LOCALVEROCTFILEDIR
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
72 -# define INFOO "\nINFOO=" OCTAVE_LOCALVEROCTFILEDIR "\n"
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
73 -#else
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
74 -# define INFOO "\nINFOO=" OCTAVE_LOCALOCTFILEPATH "\n"
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
75 -#endif
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
76 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
77 -#ifdef OCTAVE_LOCALVERARCHLIBDIR
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
78 -# define INFOX "\nINFOX=" OCTAVE_LOCALVERARCHLIBDIR "\n"
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
79 -#else
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
80 -# define INFOX "\nINFOX=" OCTAVE_LOCALARCHLIBDIR "\n"
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
81 -#endif
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
82 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
83 -const char *infom = INFOM;
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
84 -const char *infoo = INFOO;
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
85 -const char *infox = INFOX;
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
86 -const char *infoh = INFOH;
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
87 -const char *infov = INFOV;
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
88 -EOF
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
89 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
90 - dnl Compile program perhaps with a special version of mkoctfile
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
91 - $MKOCTFILE conftest.cc || AC_MSG_ERROR(Could not run $MKOCTFILE)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
92 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
93 - dnl Strip the config info from the compiled file
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
94 - eval `strings conftest.o | grep "^INFO.=" | sed -e "s,//.*$,,"`
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
95 - rm -rf conftest*
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
96 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
97 - dnl set the appropriate variables if they are not already set
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
98 - ver=`echo $INFOV | sed -e "s/\.//" -e "s/\..*$//"`
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
99 - subver=`echo $INFOV | sed -e "[s/^[^.]*[.][^.]*[.]//]"`
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
100 - alt_mbase=`echo $INFOM | sed -e "[s,\/[^\/]*$,,]"`
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
101 - alt_obase=`echo $INFOO | sed -e "[s,/site.*$,/site,]"`
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
102 - test -z "$mpath" && mpath=$INFOM/octave-forge
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
103 - test -z "$opath" && opath=$INFOO/octave-forge
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
104 - test -z "$xpath" && xpath=$INFOX
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
105 - test -z "$altmpath" && altmpath=$alt_mbase/octave-forge-alternatives/m
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
106 - test -z "$altopath" && altopath=$alt_obase/octave-forge-alternatives/oct/$INFOH
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
107 -fi
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
108 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
109 dnl *******************************************************************
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
110
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
111 dnl Get LDFLAGS and CPPFLAGS set by user
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
112 @@ -348,23 +248,10 @@ dnl AC_CHECK_LIB([netcdf], [nc_set_chunk_cache], , [AC_MSG_ERROR(nc_set_chunk_ca
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
113
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
114 CONFIGURE_OUTPUTS="Makeconf"
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
115 STATUS_MSG="
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
116 -octave commands will install into the following directories:
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
117 - m-files: $mpath
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
118 - oct-files: $opath
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
119 - binaries: $xpath
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
120 -alternatives:
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
121 - m-files: $altmpath
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
122 - oct-files: $altopath
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
123 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
124 -shell commands will install into the following directories:
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
125 - binaries: $bindir
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
126 - man pages: $mandir
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
127 - libraries: $libdir
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
128 - headers: $includedir
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
129 -
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
130 octave-forge is configured with
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
131 octave: $OCTAVE (version $OCTAVE_VERSION)
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
132 mkoctfile: $MKOCTFILE for Octave $subver
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
133 octave-config: $OCTAVE_CONFIG for Octave $subver
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
134 + nc-config: $NC_CONFIG
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
135 netCDF compiler flags: $NETCDF_CFLAGS
e76a7e02174d of-netcdf: allow build in dev octave
John D
parents:
diff changeset
136 netCDF libraries: $NETCDF_LIBS"