| 83 |
83 |
| 84 # help text |
84 # help text |
| 85 printhelp() |
85 printhelp() |
| 86 { |
86 { |
| 87 echo "Usage: $0 [OPTIONS]..." |
87 echo "Usage: $0 [OPTIONS]..." |
| 88 echo 'Configuration:' |
88 if [ $has_overridable_config_vars__ -eq 1 ] ; then |
| |
89 echo |
| |
90 echo "Configuration:" |
| |
91 fi |
| 89 if true \ |
92 if true \ |
| 90 ; then |
93 ; then |
| 91 : |
94 : |
| 92 if test -z "$prefix__described__"; then |
95 if [ -z "$prefix__described__" ] ; then |
| 93 prefix__described__=1 |
96 prefix__described__=1 |
| 94 cat << '__EOF__' |
97 cat << '__EOF__' |
| 95 --prefix path prefix for architecture-independent files [/usr] |
98 --prefix path prefix for architecture-independent files [/usr] |
| 96 __EOF__ |
99 __EOF__ |
| 97 fi |
100 fi |
| 98 if test -z "$exec_prefix__described__"; then |
101 if [ -z "$exec_prefix__described__" ] ; then |
| 99 exec_prefix__described__=1 |
102 exec_prefix__described__=1 |
| 100 cat << '__EOF__' |
103 cat << '__EOF__' |
| 101 --exec-prefix path prefix for architecture-dependent files [PREFIX] |
104 --exec-prefix path prefix for architecture-dependent files [PREFIX] |
| 102 __EOF__ |
105 __EOF__ |
| 103 fi |
106 fi |
| 104 if test -z "$libdir__described__"; then |
107 if [ -z "$libdir__described__" ] ; then |
| 105 libdir__described__=1 |
108 libdir__described__=1 |
| 106 cat << '__EOF__' |
109 cat << '__EOF__' |
| 107 --libdir object code libraries [EPREFIX/lib] |
110 --libdir object code libraries [EPREFIX/lib] |
| 108 __EOF__ |
111 __EOF__ |
| 109 fi |
112 fi |
| 110 if test -z "$includedir__described__"; then |
113 if [ -z "$includedir__described__" ] ; then |
| 111 includedir__described__=1 |
114 includedir__described__=1 |
| 112 cat << '__EOF__' |
115 cat << '__EOF__' |
| 113 --includedir C header files [PREFIX/include] |
116 --includedir C header files [PREFIX/include] |
| 114 __EOF__ |
117 __EOF__ |
| 115 fi |
118 fi |
| 116 fi |
119 fi |
| 117 if true \ |
120 if true \ |
| 118 && isplatform "freebsd" \ |
121 && isplatform "freebsd" \ |
| 119 ; then |
122 ; then |
| 120 : |
123 : |
| 121 if test -z "$pkgconfigdir__described__"; then |
124 if [ -z "$pkgconfigdir__described__" ] ; then |
| 122 pkgconfigdir__described__=1 |
125 pkgconfigdir__described__=1 |
| 123 cat << '__EOF__' |
126 cat << '__EOF__' |
| 124 --pkgconfigdir location of the *.pc files |
127 --pkgconfigdir location of the *.pc files |
| 125 __EOF__ |
128 __EOF__ |
| 126 fi |
129 fi |
| 127 fi |
130 fi |
| 128 if true \ |
131 if true \ |
| 129 && notisplatform "freebsd" \ |
132 && notisplatform "freebsd" \ |
| 130 ; then |
133 ; then |
| 131 : |
134 : |
| 132 if test -z "$pkgconfigdir__described__"; then |
135 if [ -z "$pkgconfigdir__described__" ] ; then |
| 133 pkgconfigdir__described__=1 |
136 pkgconfigdir__described__=1 |
| 134 cat << '__EOF__' |
137 cat << '__EOF__' |
| 135 --pkgconfigdir location of the *.pc files |
138 --pkgconfigdir location of the *.pc files |
| 136 __EOF__ |
139 __EOF__ |
| 137 fi |
140 fi |
| 138 fi |
141 fi |
| 139 if true \ |
142 if true \ |
| 140 ; then |
143 ; then |
| 141 : |
144 : |
| 142 if test -z "$DOXYGEN__described__"; then |
145 if [ -z "$DOXYGEN__described__" ] ; then |
| 143 DOXYGEN__described__=1 |
146 DOXYGEN__described__=1 |
| 144 cat << '__EOF__' |
147 cat << '__EOF__' |
| 145 --doxygen path of the Doxygen executable |
148 --doxygen path of the Doxygen executable |
| 146 __EOF__ |
149 __EOF__ |
| 147 fi |
150 fi |
| 179 fi |
182 fi |
| 180 touch "$TEMP_DIR/options" |
183 touch "$TEMP_DIR/options" |
| 181 touch "$TEMP_DIR/features" |
184 touch "$TEMP_DIR/features" |
| 182 |
185 |
| 183 # config variables |
186 # config variables |
| |
187 has_overridable_config_vars__=0 |
| 184 if true \ |
188 if true \ |
| 185 ; then |
189 ; then |
| 186 : |
190 : |
| 187 if test -z "$prefix__initialized__"; then |
191 if [ -z "$prefix__initialized__" ] ; then |
| |
192 has_overridable_config_vars__=1 |
| 188 prefix__initialized__=1 |
193 prefix__initialized__=1 |
| 189 prefix='/usr' |
194 prefix='/usr' |
| 190 fi |
195 fi |
| 191 if test -z "$exec_prefix__initialized__"; then |
196 if [ -z "$exec_prefix__initialized__" ] ; then |
| |
197 has_overridable_config_vars__=1 |
| 192 exec_prefix__initialized__=1 |
198 exec_prefix__initialized__=1 |
| 193 exec_prefix='' |
199 exec_prefix='' |
| 194 fi |
200 fi |
| 195 if test -z "$libdir__initialized__"; then |
201 if [ -z "$libdir__initialized__" ] ; then |
| |
202 has_overridable_config_vars__=1 |
| 196 libdir__initialized__=1 |
203 libdir__initialized__=1 |
| 197 libdir='' |
204 libdir='' |
| 198 fi |
205 fi |
| 199 if test -z "$includedir__initialized__"; then |
206 if [ -z "$includedir__initialized__" ] ; then |
| |
207 has_overridable_config_vars__=1 |
| 200 includedir__initialized__=1 |
208 includedir__initialized__=1 |
| 201 includedir='' |
209 includedir='' |
| 202 fi |
210 fi |
| 203 if test -z "$VERSION__initialized__"; then |
211 if [ -z "$VERSION__initialized__" ] ; then |
| 204 VERSION__initialized__=1 |
212 VERSION__initialized__=1 |
| 205 VERSION='4.0.0' |
213 VERSION='4.0.0' |
| 206 fi |
214 fi |
| 207 if test -z "$LIBVERSION__initialized__"; then |
215 if [ -z "$LIBVERSION__initialized__" ] ; then |
| 208 LIBVERSION__initialized__=1 |
216 LIBVERSION__initialized__=1 |
| 209 LIBVERSION='7.0.0' |
217 LIBVERSION='7.0.0' |
| 210 fi |
218 fi |
| 211 if test -z "$LIBVERSION_MAJOR__initialized__"; then |
219 if [ -z "$LIBVERSION_MAJOR__initialized__" ] ; then |
| 212 LIBVERSION_MAJOR__initialized__=1 |
220 LIBVERSION_MAJOR__initialized__=1 |
| 213 LIBVERSION_MAJOR='7' |
221 LIBVERSION_MAJOR='7' |
| 214 fi |
222 fi |
| 215 if test -z "$root_dir__initialized__"; then |
223 if [ -z "$root_dir__initialized__" ] ; then |
| 216 root_dir__initialized__=1 |
224 root_dir__initialized__=1 |
| 217 root_dir=`pwd` |
225 root_dir=`pwd` |
| 218 fi |
226 fi |
| 219 if test -z "$build_dir__initialized__"; then |
227 if [ -z "$build_dir__initialized__" ] ; then |
| 220 build_dir__initialized__=1 |
228 build_dir__initialized__=1 |
| 221 build_dir='${root_dir}/build' |
229 build_dir='${root_dir}/build' |
| 222 fi |
230 fi |
| 223 if test -z "$docs_dir__initialized__"; then |
231 if [ -z "$docs_dir__initialized__" ] ; then |
| 224 docs_dir__initialized__=1 |
232 docs_dir__initialized__=1 |
| 225 docs_dir='${root_dir}/build/docs' |
233 docs_dir='${root_dir}/build/docs' |
| 226 fi |
234 fi |
| 227 if test -z "$dist_dir__initialized__"; then |
235 if [ -z "$dist_dir__initialized__" ] ; then |
| 228 dist_dir__initialized__=1 |
236 dist_dir__initialized__=1 |
| 229 dist_dir='${root_dir}/dist' |
237 dist_dir='${root_dir}/dist' |
| 230 fi |
238 fi |
| 231 if test -z "$MKDIR__initialized__"; then |
239 if [ -z "$MKDIR__initialized__" ] ; then |
| 232 MKDIR__initialized__=1 |
240 MKDIR__initialized__=1 |
| 233 MKDIR='/bin/mkdir -p' |
241 MKDIR='/bin/mkdir -p' |
| 234 fi |
242 fi |
| 235 if test -z "$RMFILE__initialized__"; then |
243 if [ -z "$RMFILE__initialized__" ] ; then |
| 236 RMFILE__initialized__=1 |
244 RMFILE__initialized__=1 |
| 237 RMFILE='/bin/rm -f' |
245 RMFILE='/bin/rm -f' |
| 238 fi |
246 fi |
| 239 if test -z "$RMDIR__initialized__"; then |
247 if [ -z "$RMDIR__initialized__" ] ; then |
| 240 RMDIR__initialized__=1 |
248 RMDIR__initialized__=1 |
| 241 RMDIR='/bin/rm -f -R' |
249 RMDIR='/bin/rm -f -R' |
| 242 fi |
250 fi |
| 243 if test -z "$COPYFILE__initialized__"; then |
251 if [ -z "$COPYFILE__initialized__" ] ; then |
| 244 COPYFILE__initialized__=1 |
252 COPYFILE__initialized__=1 |
| 245 COPYFILE='/bin/cp -f' |
253 COPYFILE='/bin/cp -f' |
| 246 fi |
254 fi |
| 247 if test -z "$COPYALL__initialized__"; then |
255 if [ -z "$COPYALL__initialized__" ] ; then |
| 248 COPYALL__initialized__=1 |
256 COPYALL__initialized__=1 |
| 249 COPYALL='/bin/cp -f -R' |
257 COPYALL='/bin/cp -f -R' |
| 250 fi |
258 fi |
| 251 if test -z "$SYMLINK__initialized__"; then |
259 if [ -z "$SYMLINK__initialized__" ] ; then |
| 252 SYMLINK__initialized__=1 |
260 SYMLINK__initialized__=1 |
| 253 SYMLINK='/bin/ln -s' |
261 SYMLINK='/bin/ln -s' |
| 254 fi |
262 fi |
| 255 fi |
263 fi |
| 256 if true \ |
264 if true \ |
| 257 && isplatform "freebsd" \ |
265 && isplatform "freebsd" \ |
| 258 ; then |
266 ; then |
| 259 : |
267 : |
| 260 if test -z "$pkgconfigdir__initialized__"; then |
268 if [ -z "$pkgconfigdir__initialized__" ] ; then |
| |
269 has_overridable_config_vars__=1 |
| 261 pkgconfigdir__initialized__=1 |
270 pkgconfigdir__initialized__=1 |
| 262 pkgconfigdir='${exec_prefix}/libdata/pkgconfig' |
271 pkgconfigdir='${exec_prefix}/libdata/pkgconfig' |
| 263 fi |
272 fi |
| 264 fi |
273 fi |
| 265 if true \ |
274 if true \ |
| 266 && notisplatform "freebsd" \ |
275 && notisplatform "freebsd" \ |
| 267 ; then |
276 ; then |
| 268 : |
277 : |
| 269 if test -z "$pkgconfigdir__initialized__"; then |
278 if [ -z "$pkgconfigdir__initialized__" ] ; then |
| |
279 has_overridable_config_vars__=1 |
| 270 pkgconfigdir__initialized__=1 |
280 pkgconfigdir__initialized__=1 |
| 271 pkgconfigdir='${libdir}/pkgconfig' |
281 pkgconfigdir='${libdir}/pkgconfig' |
| 272 fi |
282 fi |
| 273 fi |
283 fi |
| 274 if true \ |
284 if true \ |
| 275 ; then |
285 ; then |
| 276 : |
286 : |
| 277 if test -z "$DOXYGEN__initialized__"; then |
287 if [ -z "$DOXYGEN__initialized__" ] ; then |
| |
288 has_overridable_config_vars__=1 |
| 278 DOXYGEN__initialized__=1 |
289 DOXYGEN__initialized__=1 |
| 279 DOXYGEN=`command -v doxygen || echo '/bin/false'` |
290 DOXYGEN=`command -v doxygen || echo '/bin/false'` |
| 280 fi |
291 fi |
| 281 fi |
292 fi |
| 282 |
293 |
| 422 fi |
433 fi |
| 423 fi |
434 fi |
| 424 |
435 |
| 425 |
436 |
| 426 # generate vars.mk |
437 # generate vars.mk |
| 427 cat > "$TEMP_DIR/vars.mk" << __EOF__ |
438 echo '# configuration' > "$TEMP_DIR/vars.mk" |
| 428 prefix=$prefix |
439 echo "prefix=$prefix" >> "$TEMP_DIR/vars.mk" |
| 429 exec_prefix=$exec_prefix |
440 echo "exec_prefix=$exec_prefix" >> "$TEMP_DIR/vars.mk" |
| 430 libdir=$libdir |
441 echo "libdir=$libdir" >> "$TEMP_DIR/vars.mk" |
| 431 includedir=$includedir |
442 echo "includedir=$includedir" >> "$TEMP_DIR/vars.mk" |
| 432 VERSION=$VERSION |
443 echo "VERSION=$VERSION" >> "$TEMP_DIR/vars.mk" |
| 433 LIBVERSION=$LIBVERSION |
444 echo "LIBVERSION=$LIBVERSION" >> "$TEMP_DIR/vars.mk" |
| 434 LIBVERSION_MAJOR=$LIBVERSION_MAJOR |
445 echo "LIBVERSION_MAJOR=$LIBVERSION_MAJOR" >> "$TEMP_DIR/vars.mk" |
| 435 root_dir=$root_dir |
446 echo "root_dir=$root_dir" >> "$TEMP_DIR/vars.mk" |
| 436 build_dir=$build_dir |
447 echo "build_dir=$build_dir" >> "$TEMP_DIR/vars.mk" |
| 437 docs_dir=$docs_dir |
448 echo "docs_dir=$docs_dir" >> "$TEMP_DIR/vars.mk" |
| 438 dist_dir=$dist_dir |
449 echo "dist_dir=$dist_dir" >> "$TEMP_DIR/vars.mk" |
| 439 MKDIR=$MKDIR |
450 echo "MKDIR=$MKDIR" >> "$TEMP_DIR/vars.mk" |
| 440 RMFILE=$RMFILE |
451 echo "RMFILE=$RMFILE" >> "$TEMP_DIR/vars.mk" |
| 441 RMDIR=$RMDIR |
452 echo "RMDIR=$RMDIR" >> "$TEMP_DIR/vars.mk" |
| 442 COPYFILE=$COPYFILE |
453 echo "COPYFILE=$COPYFILE" >> "$TEMP_DIR/vars.mk" |
| 443 COPYALL=$COPYALL |
454 echo "COPYALL=$COPYALL" >> "$TEMP_DIR/vars.mk" |
| 444 SYMLINK=$SYMLINK |
455 echo "SYMLINK=$SYMLINK" >> "$TEMP_DIR/vars.mk" |
| 445 pkgconfigdir=$pkgconfigdir |
456 echo "pkgconfigdir=$pkgconfigdir" >> "$TEMP_DIR/vars.mk" |
| 446 DOXYGEN=$DOXYGEN |
457 echo "DOXYGEN=$DOXYGEN" >> "$TEMP_DIR/vars.mk" |
| 447 __EOF__ |
458 echo >> "$TEMP_DIR/vars.mk" |
| 448 |
|
| 449 |
459 |
| 450 # |
460 # |
| 451 # DEPENDENCIES |
461 # DEPENDENCIES |
| 452 # |
462 # |
| 453 |
|
| 454 |
|
| 455 |
463 |
| 456 # create buffer for make variables required by dependencies |
464 # create buffer for make variables required by dependencies |
| 457 echo > "$TEMP_DIR/make.mk" |
465 echo > "$TEMP_DIR/make.mk" |
| 458 |
466 |
| 459 test_pkg_config() |
467 test_pkg_config() |
| 1035 echo " word size: $TOOLCHAIN_WSIZE bit" |
1043 echo " word size: $TOOLCHAIN_WSIZE bit" |
| 1036 fi |
1044 fi |
| 1037 if [ -n "$TOOLCHAIN_CSTD" ]; then |
1045 if [ -n "$TOOLCHAIN_CSTD" ]; then |
| 1038 echo " default C std: $TOOLCHAIN_CSTD" |
1046 echo " default C std: $TOOLCHAIN_CSTD" |
| 1039 fi |
1047 fi |
| 1040 echo |
1048 if [ $has_overridable_config_vars__ -eq 1 ]; then |
| 1041 echo "Config:" |
1049 echo |
| 1042 printf ' %-16s' 'prefix:' |
1050 echo "Config:" |
| 1043 echo "$prefix" |
1051 if [ -n "$prefix__initialized__" ]; then |
| 1044 printf ' %-16s' 'exec-prefix:' |
1052 printf ' %-16s' 'prefix:' |
| 1045 echo "$exec_prefix" |
1053 echo "$prefix" |
| 1046 printf ' %-16s' 'libdir:' |
1054 fi |
| 1047 echo "$libdir" |
1055 if [ -n "$exec_prefix__initialized__" ]; then |
| 1048 printf ' %-16s' 'includedir:' |
1056 printf ' %-16s' 'exec-prefix:' |
| 1049 echo "$includedir" |
1057 echo "$exec_prefix" |
| 1050 printf ' %-16s' 'pkgconfigdir:' |
1058 fi |
| 1051 echo "$pkgconfigdir" |
1059 if [ -n "$libdir__initialized__" ]; then |
| 1052 printf ' %-16s' 'doxygen:' |
1060 printf ' %-16s' 'libdir:' |
| 1053 echo "$DOXYGEN" |
1061 echo "$libdir" |
| |
1062 fi |
| |
1063 if [ -n "$includedir__initialized__" ]; then |
| |
1064 printf ' %-16s' 'includedir:' |
| |
1065 echo "$includedir" |
| |
1066 fi |
| |
1067 if [ -n "$pkgconfigdir__initialized__" ]; then |
| |
1068 printf ' %-16s' 'pkgconfigdir:' |
| |
1069 echo "$pkgconfigdir" |
| |
1070 fi |
| |
1071 if [ -n "$DOXYGEN__initialized__" ]; then |
| |
1072 printf ' %-16s' 'doxygen:' |
| |
1073 echo "$DOXYGEN" |
| |
1074 fi |
| |
1075 fi |
| 1054 echo |
1076 echo |
| 1055 echo "Features:" |
1077 echo "Features:" |
| 1056 printf ' %-16s' 'api-docs:' |
1078 printf ' %-16s' 'api-docs:' |
| 1057 if [ -n "$FEATURE_API_DOCS" ]; then |
1079 if [ -n "$FEATURE_API_DOCS" ]; then |
| 1058 echo 'on' |
1080 echo 'on' |