Codebase list hdf5 / 6edb479
Imported Upstream version 1.10.0~alpha1+docs Gilles Filippini 8 years ago
157 changed file(s) with 13595 addition(s) and 8010 deletion(s). Raw diff Collapse all Expand all
373373 if (HDF5_ENABLE_USING_MEMCHECKER)
374374 set (H5_USING_MEMCHECKER 1)
375375 endif (HDF5_ENABLE_USING_MEMCHECKER)
376
377 #-----------------------------------------------------------------------------
378 # Option to indicate internal memory allocation sanity checks are enabled
379 #-----------------------------------------------------------------------------
380 option (HDF5_MEMORY_ALLOC_SANITY_CHECK "Indicate that internal memory allocation sanity checks are enabled" OFF)
381 if (HDF5_MEMORY_ALLOC_SANITY_CHECK)
382 set (H5_MEMORY_ALLOC_SANITY_CHECK 1)
383 endif (HDF5_MEMORY_ALLOC_SANITY_CHECK)
376384
377385 #-----------------------------------------------------------------------------
378386 # Option to use deprecated public API symbols
6565 ./bin/runtest _DO_NOT_DISTRIBUTE_
6666 ./bin/snapshot
6767 ./bin/snapshot_version _DO_NOT_DISTRIBUTE_
68 ./bin/switch_maint_mode _DO_NOT_DISTRIBUTE_
6869 ./bin/timekeeper _DO_NOT_DISTRIBUTE_
6970 ./bin/trace
7071 ./bin/yodconfigure
14441445 ./tools/testfiles/filter_fail.h5
14451446 ./tools/testfiles/filter_fail.ddl
14461447 ./tools/testfiles/h5dump-help.txt
1448 ./tools/testfiles/non_existing.ddl
14471449 ./tools/testfiles/packedbits.ddl
14481450 ./tools/testfiles/taindices.h5
14491451 ./tools/testfiles/tall-1.ddl
17031705
17041706 # h5dump test error files
17051707 ./tools/h5dump/errfiles/filter_fail.err
1708 ./tools/h5dump/errfiles/non_existing.err
17061709 ./tools/h5dump/errfiles/tall-1.err
17071710 ./tools/h5dump/errfiles/tall-2A.err
17081711 ./tools/h5dump/errfiles/tall-2A0.err
197197 $(top_srcdir)/bin/install-sh $(top_srcdir)/bin/ltmain.sh \
198198 $(top_srcdir)/bin/missing $(top_srcdir)/config/commence.am \
199199 COPYING bin/COPYING bin/README bin/compile bin/config.guess \
200 bin/config.sub bin/depcomp bin/install-sh bin/ltmain.sh \
201 bin/missing
200 bin/config.sub bin/install-sh bin/ltmain.sh bin/missing
202201 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
203202 distdir = $(PACKAGE)-$(VERSION)
204203 top_distdir = $(distdir)
353352 LN_S = @LN_S@
354353 LTLIBOBJS = @LTLIBOBJS@
355354 LT_STATIC_EXEC = @LT_STATIC_EXEC@
355 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
356356 MAINT = @MAINT@
357357 MAKEINFO = @MAKEINFO@
358358 MANIFEST_TOOL = @MANIFEST_TOOL@
0 HDF5 version 1.10.0-alpha0 released on 2015-12-29
0 HDF5 version 1.10.0-alpha1 released on 2016-01-18
11 Please refer to the release_docs/INSTALL file for installation instructions.
22 ------------------------------------------------------------------------------
33
123123
124124 echo "$banner" with output saved in $logfile
125125 (TIMESTAMP; nerror=0 ;
126 echo "eval $command"
127 eval $command || nerror=1 ;
128 TIMESTAMP; exit $nerror) < /dev/null > "$logfile" 2>&1
126 echo "eval $command"
127 eval $command || nerror=1 ;
128 TIMESTAMP; exit $nerror) < /dev/null > "$logfile" 2>&1
129129 if [ $? -ne 0 ]; then
130 echo "error in '$banner'. $progname aborted."
131 exit 1
130 echo "error in '$banner'. $progname aborted."
131 exit 1
132132 fi
133133 }
134134
142142 {
143143 myos="`uname -s`"
144144 case "$myos" in
145 Linux)
146 install_file=./HDF5-${version}-Linux.sh
147 $install_file --skip-license $*
148 ;;
149 Darwin) # Mac OSX DMG file
150 install_file=HDF5-${version}-Darwin.dmg
151 test -d hdf5 || mkdir hdf5
152 basename=`basename $install_file .dmg`
153 # mount the DMG file as /Volumes/$basename
154 # echo 'Y' as yes for license.
155 echo Y | hdiutil mount $install_file
156 # copy the contents to the install location
157 cp -R "/Volumes/$basename/HDF_Group" hdf5
158 # unmount the DMG file
159 hdiutil unmount /Volumes/$basename
160 ;;
161 *) # unknown/unsupported OS.
162 echo "INSTALL_HDF5: Error--unknown/unsupported OS($myos)"
163 return 1
164 ;;
145 Linux)
146 install_file=./HDF5-${version}-Linux.sh
147 $install_file --skip-license $*
148 ;;
149 Darwin) # Mac OSX DMG file
150 # These steps were a kludge. Need proper support from Cmake engineering.
151 echo Darwin install step needs proper implementation. Quit.
152 return 1
153 #
154 install_file=HDF5-${version}-Darwin.dmg
155 test -d hdf5 || mkdir hdf5
156 basename=`basename $install_file .dmg`
157 # mount the DMG file as /Volumes/$basename
158 # echo 'Y' as yes for license.
159 echo Y | hdiutil mount $install_file
160 # copy the contents to the install location
161 cp -R "/Volumes/$basename/HDF_Group" hdf5
162 # unmount the DMG file
163 hdiutil unmount /Volumes/$basename
164 ;;
165 *) # unknown/unsupported OS.
166 echo "INSTALL_HDF5: Error--unknown/unsupported OS($myos)"
167 return 1
168 ;;
165169 esac
166170 }
167171
171175 DUMP_LOGFILE()
172176 {
173177 for x in $*; do
174 if [ -f $x ]; then
175 echo "=================================="
176 echo "Dumping $x"
177 echo "=================================="
178 cat $x
179 echo "==== END $x ====="
180 echo
181 fi
178 if [ -f $x ]; then
179 echo "=================================="
180 echo "Dumping $x"
181 echo "=================================="
182 cat $x
183 echo "==== END $x ====="
184 echo
185 fi
182186 done
183187 }
184188
206210 # tools Build tools
207211 while [ $# -gt 0 ]; do
208212 case "$1" in
209 --enable-fortran)
210 build_fortran=-DHDF5_BUILD_FORTRAN:BOOL=ON
211 ;;
212 --disable-fortran)
213 build_fortran=-DHDF5_BUILD_FORTRAN:BOOL=OFF
214 ;;
215 --enable-cxx)
216 build_cpp_lib=-DHDF5_BUILD_CPP_LIB:BOOL=ON
217 ;;
218 --disable-cxx)
219 build_cpp_lib=-DHDF5_BUILD_CPP_LIB:BOOL=OFF
220 ;;
221 --enable-hl)
222 build_hl_lib=-DHDF5_BUILD_HL_LIB:BOOL=ON
223 ;;
224 --disable-hl)
225 build_hl_lib=-DHDF5_BUILD_HL_LIB:BOOL=OFF
226 ;;
227 --enable-shared)
228 shared_lib=-DBUILD_SHARED_LIBS:BOOL=ON
229 ;;
230 --disable-shared)
231 shared_lib=-DBUILD_SHARED_LIBS:BOOL=OFF
232 ;;
233 --enable-tools)
234 build_tools=-DHDF5_BUILD_TOOLS:BOOL=ON
235 ;;
236 --disable-tools)
237 build_tools=-DHDF5_BUILD_TOOLS:BOOL=OFF
238 ;;
239 --enable-testing)
240 build_testing=-DBUILD_TESTING:BOOL=ON
241 ;;
242 --disable-testing)
243 build_testing=-DBUILD_TESTING:BOOL=OFF
244 ;;
245 --with-zlib)
246 with_zlib=-DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=ON
247 ;;
248 --with-zlib=*)
249 xarg=`echo $1 | cut -d= -f2-`
250 with_zlib="-DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=ON -DZLIB_ROOT=$xarg"
251 ;;
252 --without-zlib)
253 with_zlib=-DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=OFF
254 ;;
255 --with-szlib)
256 with_szlib=-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=ON
257 szlib_path="" # szlib is in default paths
258 ;;
259 --with-szlib=*)
260 xarg=`echo $1 | cut -d= -f2-`
261 with_szlib="-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=ON"
262 szlib_path="SZIP_INSTALL=$xarg"
263 ;;
264 --without-szlib)
265 with_szlib=-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF
266 szlib_path="" # reset the path
267 ;;
268 --njobs=*)
269 njobs=`echo $1 | cut -d= -f2-`
270 ;;
271 --enable-verbose)
272 vflag=1
273 ;;
274 --disable-verbose)
275 vflag=0
276 ;;
277 --help)
278 # print the detail help page and exit
279 HELP
280 exit 0
281 ;;
282 *)
283 echo "Unknown options: $1"
284 HELP
285 exit 1
286 ;;
213 --enable-fortran)
214 build_fortran=-DHDF5_BUILD_FORTRAN:BOOL=ON
215 ;;
216 --disable-fortran)
217 build_fortran=-DHDF5_BUILD_FORTRAN:BOOL=OFF
218 ;;
219 --enable-cxx)
220 build_cpp_lib=-DHDF5_BUILD_CPP_LIB:BOOL=ON
221 ;;
222 --disable-cxx)
223 build_cpp_lib=-DHDF5_BUILD_CPP_LIB:BOOL=OFF
224 ;;
225 --enable-hl)
226 build_hl_lib=-DHDF5_BUILD_HL_LIB:BOOL=ON
227 ;;
228 --disable-hl)
229 build_hl_lib=-DHDF5_BUILD_HL_LIB:BOOL=OFF
230 ;;
231 --enable-shared)
232 shared_lib=-DBUILD_SHARED_LIBS:BOOL=ON
233 ;;
234 --disable-shared)
235 shared_lib=-DBUILD_SHARED_LIBS:BOOL=OFF
236 ;;
237 --enable-tools)
238 build_tools=-DHDF5_BUILD_TOOLS:BOOL=ON
239 ;;
240 --disable-tools)
241 build_tools=-DHDF5_BUILD_TOOLS:BOOL=OFF
242 ;;
243 --enable-testing)
244 build_testing=-DBUILD_TESTING:BOOL=ON
245 ;;
246 --disable-testing)
247 build_testing=-DBUILD_TESTING:BOOL=OFF
248 ;;
249 --with-zlib)
250 with_zlib=-DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=ON
251 ;;
252 --with-zlib=*)
253 xarg=`echo $1 | cut -d= -f2-`
254 with_zlib="-DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=ON -DZLIB_ROOT=$xarg"
255 ;;
256 --without-zlib)
257 with_zlib=-DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=OFF
258 ;;
259 --with-szlib)
260 with_szlib=-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=ON
261 szlib_path="" # szlib is in default paths
262 ;;
263 --with-szlib=*)
264 xarg=`echo $1 | cut -d= -f2-`
265 with_szlib="-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=ON"
266 szlib_path="SZIP_INSTALL=$xarg"
267 ;;
268 --without-szlib)
269 with_szlib=-DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF
270 szlib_path="" # reset the path
271 ;;
272 --njobs=*)
273 njobs=`echo $1 | cut -d= -f2-`
274 ;;
275 --enable-verbose)
276 vflag=1
277 ;;
278 --disable-verbose)
279 vflag=0
280 ;;
281 --help)
282 # print the detail help page and exit
283 HELP
284 exit 0
285 ;;
286 *)
287 echo "Unknown options: $1"
288 HELP
289 exit 1
290 ;;
287291 esac
288292 shift
289293 done
312316
313317 # setup output of all the log files if verbose is on upon exit
314318 trap \
315 "if [ $vflag -ne 0 ]; then DUMP_LOGFILE \$configlog \$makelog \$testlog \$packlog \$installlog; fi" \
316 0
319 "if [ $vflag -ne 0 ]; then DUMP_LOGFILE \$configlog \$makelog \$testlog \$packlog \$installlog; fi" \
320 0
317321
318322 echo Running Cmake for HDF5-${version} ...
319323 # 4. Configure the C library, tools and tests with this command:
342346 # 7. Create an install image with this command:
343347 STEP "Create an install image..." "cpack -C Release CPackConfig.cmake" $packlog
344348
349 # The implementation of installation is imcomplete (only works for linux).
350 # Screen it out for now till it is completed.
351 if false; then
345352 # 8. Install with this command:
346353 STEP "Install..." "INSTALL_HDF5" $installlog
354 fi
355
347356 # save the last exit code
348357 exit_code=$?
349358
11 # Attempt to guess a canonical system name.
22 # Copyright 1992-2014 Free Software Foundation, Inc.
33
4 timestamp='2014-03-23'
4 timestamp='2014-11-04'
55
66 # This file is free software; you can redistribute it and/or modify it
77 # under the terms of the GNU General Public License as published by
2323 # program. This Exception is an additional permission under section 7
2424 # of the GNU General Public License, version 3 ("GPLv3").
2525 #
26 # Originally written by Per Bothner.
26 # Originally written by Per Bothner; maintained since 2000 by Ben Elliston.
2727 #
2828 # You can get the latest version of this script from:
2929 # http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
3030 #
31 # Please send patches with a ChangeLog entry to config-patches@gnu.org.
31 # Please send patches to <config-patches@gnu.org>.
3232
3333
3434 me=`echo "$0" | sed -e 's,.*/,,'`
578578 else
579579 IBM_ARCH=powerpc
580580 fi
581 if [ -x /usr/bin/oslevel ] ; then
582 IBM_REV=`/usr/bin/oslevel`
581 if [ -x /usr/bin/lslpp ] ; then
582 IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc |
583 awk -F: '{ print $3 }' | sed s/[0-9]*$/0/`
583584 else
584585 IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
585586 fi
11 # Configuration validation subroutine script.
22 # Copyright 1992-2014 Free Software Foundation, Inc.
33
4 timestamp='2014-09-11'
4 timestamp='2014-12-03'
55
66 # This file is free software; you can redistribute it and/or modify it
77 # under the terms of the GNU General Public License as published by
2424 # of the GNU General Public License, version 3 ("GPLv3").
2525
2626
27 # Please send patches with a ChangeLog entry to config-patches@gnu.org.
27 # Please send patches to <config-patches@gnu.org>.
2828 #
2929 # Configuration subroutine to validate and canonicalize a configuration type.
3030 # Supply the specified configuration type as an argument.
312312 | tahoe | tic4x | tic54x | tic55x | tic6x | tic80 | tron \
313313 | ubicom32 \
314314 | v850 | v850e | v850e1 | v850e2 | v850es | v850e2v3 \
315 | visium \
315316 | we32k \
316317 | x86 | xc16x | xstormy16 | xtensa \
317318 | z8k | z80)
325326 ;;
326327 c6x)
327328 basic_machine=tic6x-unknown
329 ;;
330 leon|leon[3-9])
331 basic_machine=sparc-$basic_machine
328332 ;;
329333 m6811 | m68hc11 | m6812 | m68hc12 | m68hcs12x | nvptx | picochip)
330334 basic_machine=$basic_machine-unknown
436440 | ubicom32-* \
437441 | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \
438442 | vax-* \
443 | visium-* \
439444 | we32k-* \
440445 | x86-* | x86_64-* | xc16x-* | xps100-* \
441446 | xstormy16-* | xtensa*-* \
772777 isi68 | isi)
773778 basic_machine=m68k-isi
774779 os=-sysv
780 ;;
781 leon-*|leon[3-9]-*)
782 basic_machine=sparc-`echo $basic_machine | sed 's/-.*//'`
775783 ;;
776784 m68knommu)
777785 basic_machine=m68k-unknown
0
1 # libtool (GNU libtool) 2.4.2
0 #! /bin/sh
1 ## DO NOT EDIT - This file generated from ./build-aux/ltmain.in
2 ## by inline-source v2014-01-03.01
3
4 # libtool (GNU libtool) 2.4.6
5 # Provide generalized library-building support services.
26 # Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
37
4 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006,
5 # 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
8 # Copyright (C) 1996-2015 Free Software Foundation, Inc.
69 # This is free software; see the source for copying conditions. There is NO
710 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
811
2225 # General Public License for more details.
2326 #
2427 # You should have received a copy of the GNU General Public License
25 # along with GNU Libtool; see the file COPYING. If not, a copy
26 # can be downloaded from http://www.gnu.org/licenses/gpl.html,
27 # or obtained by writing to the Free Software Foundation, Inc.,
28 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
29
30 # Usage: $progname [OPTION]... [MODE-ARG]...
31 #
32 # Provide generalized library-building support services.
33 #
34 # --config show all configuration variables
35 # --debug enable verbose shell tracing
36 # -n, --dry-run display commands without modifying any files
37 # --features display basic configuration information and exit
38 # --mode=MODE use operation mode MODE
39 # --preserve-dup-deps don't remove duplicate dependency libraries
40 # --quiet, --silent don't print informational messages
41 # --no-quiet, --no-silent
42 # print informational messages (default)
43 # --no-warn don't display warning messages
44 # --tag=TAG use configuration variables from tag TAG
45 # -v, --verbose print more informational messages than default
46 # --no-verbose don't print the extra informational messages
47 # --version print version information
48 # -h, --help, --help-all print short, long, or detailed help message
49 #
50 # MODE must be one of the following:
51 #
52 # clean remove files from the build directory
53 # compile compile a source file into a libtool object
54 # execute automatically set library path, then run a program
55 # finish complete the installation of libtool libraries
56 # install install libraries or executables
57 # link create a library or an executable
58 # uninstall remove libraries from an installed directory
59 #
60 # MODE-ARGS vary depending on the MODE. When passed as first option,
61 # `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that.
62 # Try `$progname --help --mode=MODE' for a more detailed description of MODE.
63 #
64 # When reporting a bug, please describe a test case to reproduce it and
65 # include the following information:
66 #
67 # host-triplet: $host
68 # shell: $SHELL
69 # compiler: $LTCC
70 # compiler flags: $LTCFLAGS
71 # linker: $LD (gnu? $with_gnu_ld)
72 # $progname: (GNU libtool) 2.4.2 Debian-2.4.2-1.11
73 # automake: $automake_version
74 # autoconf: $autoconf_version
75 #
76 # Report bugs to <bug-libtool@gnu.org>.
77 # GNU libtool home page: <http://www.gnu.org/software/libtool/>.
78 # General help using GNU software: <http://www.gnu.org/gethelp/>.
28 # along with this program. If not, see <http://www.gnu.org/licenses/>.
29
7930
8031 PROGRAM=libtool
8132 PACKAGE=libtool
82 VERSION="2.4.2 Debian-2.4.2-1.11"
83 TIMESTAMP=""
84 package_revision=1.3337
85
86 # Be Bourne compatible
87 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
33 VERSION=2.4.6
34 package_revision=2.4.6
35
36
37 ## ------ ##
38 ## Usage. ##
39 ## ------ ##
40
41 # Run './libtool --help' for help with using this script from the
42 # command line.
43
44
45 ## ------------------------------- ##
46 ## User overridable command paths. ##
47 ## ------------------------------- ##
48
49 # After configure completes, it has a better idea of some of the
50 # shell tools we need than the defaults used by the functions shared
51 # with bootstrap, so set those here where they can still be over-
52 # ridden by the user, but otherwise take precedence.
53
54 : ${AUTOCONF="autoconf"}
55 : ${AUTOMAKE="automake"}
56
57
58 ## -------------------------- ##
59 ## Source external libraries. ##
60 ## -------------------------- ##
61
62 # Much of our low-level functionality needs to be sourced from external
63 # libraries, which are installed to $pkgauxdir.
64
65 # Set a version string for this script.
66 scriptversion=2015-01-20.17; # UTC
67
68 # General shell script boiler plate, and helper functions.
69 # Written by Gary V. Vaughan, 2004
70
71 # Copyright (C) 2004-2015 Free Software Foundation, Inc.
72 # This is free software; see the source for copying conditions. There is NO
73 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
74
75 # This program is free software; you can redistribute it and/or modify
76 # it under the terms of the GNU General Public License as published by
77 # the Free Software Foundation; either version 3 of the License, or
78 # (at your option) any later version.
79
80 # As a special exception to the GNU General Public License, if you distribute
81 # this file as part of a program or library that is built using GNU Libtool,
82 # you may include this file under the same distribution terms that you use
83 # for the rest of that program.
84
85 # This program is distributed in the hope that it will be useful,
86 # but WITHOUT ANY WARRANTY; without even the implied warranty of
87 # MERCHANTABILITY or FITNES FOR A PARTICULAR PURPOSE. See the GNU
88 # General Public License for more details.
89
90 # You should have received a copy of the GNU General Public License
91 # along with this program. If not, see <http://www.gnu.org/licenses/>.
92
93 # Please report bugs or propose patches to gary@gnu.org.
94
95
96 ## ------ ##
97 ## Usage. ##
98 ## ------ ##
99
100 # Evaluate this file near the top of your script to gain access to
101 # the functions and variables defined here:
102 #
103 # . `echo "$0" | ${SED-sed} 's|[^/]*$||'`/build-aux/funclib.sh
104 #
105 # If you need to override any of the default environment variable
106 # settings, do that before evaluating this file.
107
108
109 ## -------------------- ##
110 ## Shell normalisation. ##
111 ## -------------------- ##
112
113 # Some shells need a little help to be as Bourne compatible as possible.
114 # Before doing anything else, make sure all that help has been provided!
115
116 DUALCASE=1; export DUALCASE # for MKS sh
117 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
88118 emulate sh
89119 NULLCMD=:
90 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
120 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
91121 # is contrary to our usage. Disable this feature.
92122 alias -g '${1+"$@"}'='"$@"'
93123 setopt NO_GLOB_SUBST
94124 else
95 case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac
125 case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac
96126 fi
97 BIN_SH=xpg4; export BIN_SH # for Tru64
98 DUALCASE=1; export DUALCASE # for MKS sh
99
100 # A function that is used when there is no print builtin or printf.
101 func_fallback_echo ()
102 {
103 eval 'cat <<_LTECHO_EOF
104 $1
105 _LTECHO_EOF'
106 }
107
108 # NLS nuisances: We save the old values to restore during execute mode.
109 lt_user_locale=
110 lt_safe_locale=
111 for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
127
128 # NLS nuisances: We save the old values in case they are required later.
129 _G_user_locale=
130 _G_safe_locale=
131 for _G_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
112132 do
113 eval "if test \"\${$lt_var+set}\" = set; then
114 save_$lt_var=\$$lt_var
115 $lt_var=C
116 export $lt_var
117 lt_user_locale=\"$lt_var=\\\$save_\$lt_var; \$lt_user_locale\"
118 lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\"
133 eval "if test set = \"\${$_G_var+set}\"; then
134 save_$_G_var=\$$_G_var
135 $_G_var=C
136 export $_G_var
137 _G_user_locale=\"$_G_var=\\\$save_\$_G_var; \$_G_user_locale\"
138 _G_safe_locale=\"$_G_var=C; \$_G_safe_locale\"
119139 fi"
120140 done
121 LC_ALL=C
122 LANGUAGE=C
123 export LANGUAGE LC_ALL
124
125 $lt_unset CDPATH
126
141
142 # CDPATH.
143 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
144
145 # Make sure IFS has a sensible default
146 sp=' '
147 nl='
148 '
149 IFS="$sp $nl"
150
151 # There are apparently some retarded systems that use ';' as a PATH separator!
152 if test "${PATH_SEPARATOR+set}" != set; then
153 PATH_SEPARATOR=:
154 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
155 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
156 PATH_SEPARATOR=';'
157 }
158 fi
159
160
161
162 ## ------------------------- ##
163 ## Locate command utilities. ##
164 ## ------------------------- ##
165
166
167 # func_executable_p FILE
168 # ----------------------
169 # Check that FILE is an executable regular file.
170 func_executable_p ()
171 {
172 test -f "$1" && test -x "$1"
173 }
174
175
176 # func_path_progs PROGS_LIST CHECK_FUNC [PATH]
177 # --------------------------------------------
178 # Search for either a program that responds to --version with output
179 # containing "GNU", or else returned by CHECK_FUNC otherwise, by
180 # trying all the directories in PATH with each of the elements of
181 # PROGS_LIST.
182 #
183 # CHECK_FUNC should accept the path to a candidate program, and
184 # set $func_check_prog_result if it truncates its output less than
185 # $_G_path_prog_max characters.
186 func_path_progs ()
187 {
188 _G_progs_list=$1
189 _G_check_func=$2
190 _G_PATH=${3-"$PATH"}
191
192 _G_path_prog_max=0
193 _G_path_prog_found=false
194 _G_save_IFS=$IFS; IFS=${PATH_SEPARATOR-:}
195 for _G_dir in $_G_PATH; do
196 IFS=$_G_save_IFS
197 test -z "$_G_dir" && _G_dir=.
198 for _G_prog_name in $_G_progs_list; do
199 for _exeext in '' .EXE; do
200 _G_path_prog=$_G_dir/$_G_prog_name$_exeext
201 func_executable_p "$_G_path_prog" || continue
202 case `"$_G_path_prog" --version 2>&1` in
203 *GNU*) func_path_progs_result=$_G_path_prog _G_path_prog_found=: ;;
204 *) $_G_check_func $_G_path_prog
205 func_path_progs_result=$func_check_prog_result
206 ;;
207 esac
208 $_G_path_prog_found && break 3
209 done
210 done
211 done
212 IFS=$_G_save_IFS
213 test -z "$func_path_progs_result" && {
214 echo "no acceptable sed could be found in \$PATH" >&2
215 exit 1
216 }
217 }
218
219
220 # We want to be able to use the functions in this file before configure
221 # has figured out where the best binaries are kept, which means we have
222 # to search for them ourselves - except when the results are already set
223 # where we skip the searches.
224
225 # Unless the user overrides by setting SED, search the path for either GNU
226 # sed, or the sed that truncates its output the least.
227 test -z "$SED" && {
228 _G_sed_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
229 for _G_i in 1 2 3 4 5 6 7; do
230 _G_sed_script=$_G_sed_script$nl$_G_sed_script
231 done
232 echo "$_G_sed_script" 2>/dev/null | sed 99q >conftest.sed
233 _G_sed_script=
234
235 func_check_prog_sed ()
236 {
237 _G_path_prog=$1
238
239 _G_count=0
240 printf 0123456789 >conftest.in
241 while :
242 do
243 cat conftest.in conftest.in >conftest.tmp
244 mv conftest.tmp conftest.in
245 cp conftest.in conftest.nl
246 echo '' >> conftest.nl
247 "$_G_path_prog" -f conftest.sed <conftest.nl >conftest.out 2>/dev/null || break
248 diff conftest.out conftest.nl >/dev/null 2>&1 || break
249 _G_count=`expr $_G_count + 1`
250 if test "$_G_count" -gt "$_G_path_prog_max"; then
251 # Best one so far, save it but keep looking for a better one
252 func_check_prog_result=$_G_path_prog
253 _G_path_prog_max=$_G_count
254 fi
255 # 10*(2^10) chars as input seems more than enough
256 test 10 -lt "$_G_count" && break
257 done
258 rm -f conftest.in conftest.tmp conftest.nl conftest.out
259 }
260
261 func_path_progs "sed gsed" func_check_prog_sed $PATH:/usr/xpg4/bin
262 rm -f conftest.sed
263 SED=$func_path_progs_result
264 }
265
266
267 # Unless the user overrides by setting GREP, search the path for either GNU
268 # grep, or the grep that truncates its output the least.
269 test -z "$GREP" && {
270 func_check_prog_grep ()
271 {
272 _G_path_prog=$1
273
274 _G_count=0
275 _G_path_prog_max=0
276 printf 0123456789 >conftest.in
277 while :
278 do
279 cat conftest.in conftest.in >conftest.tmp
280 mv conftest.tmp conftest.in
281 cp conftest.in conftest.nl
282 echo 'GREP' >> conftest.nl
283 "$_G_path_prog" -e 'GREP$' -e '-(cannot match)-' <conftest.nl >conftest.out 2>/dev/null || break
284 diff conftest.out conftest.nl >/dev/null 2>&1 || break
285 _G_count=`expr $_G_count + 1`
286 if test "$_G_count" -gt "$_G_path_prog_max"; then
287 # Best one so far, save it but keep looking for a better one
288 func_check_prog_result=$_G_path_prog
289 _G_path_prog_max=$_G_count
290 fi
291 # 10*(2^10) chars as input seems more than enough
292 test 10 -lt "$_G_count" && break
293 done
294 rm -f conftest.in conftest.tmp conftest.nl conftest.out
295 }
296
297 func_path_progs "grep ggrep" func_check_prog_grep $PATH:/usr/xpg4/bin
298 GREP=$func_path_progs_result
299 }
300
301
302 ## ------------------------------- ##
303 ## User overridable command paths. ##
304 ## ------------------------------- ##
305
306 # All uppercase variable names are used for environment variables. These
307 # variables can be overridden by the user before calling a script that
308 # uses them if a suitable command of that name is not already available
309 # in the command search PATH.
310
311 : ${CP="cp -f"}
312 : ${ECHO="printf %s\n"}
313 : ${EGREP="$GREP -E"}
314 : ${FGREP="$GREP -F"}
315 : ${LN_S="ln -s"}
316 : ${MAKE="make"}
317 : ${MKDIR="mkdir"}
318 : ${MV="mv -f"}
319 : ${RM="rm -f"}
320 : ${SHELL="${CONFIG_SHELL-/bin/sh}"}
321
322
323 ## -------------------- ##
324 ## Useful sed snippets. ##
325 ## -------------------- ##
326
327 sed_dirname='s|/[^/]*$||'
328 sed_basename='s|^.*/||'
329
330 # Sed substitution that helps us do robust quoting. It backslashifies
331 # metacharacters that are still active within double-quoted strings.
332 sed_quote_subst='s|\([`"$\\]\)|\\\1|g'
333
334 # Same as above, but do not quote variable references.
335 sed_double_quote_subst='s/\(["`\\]\)/\\\1/g'
336
337 # Sed substitution that turns a string into a regex matching for the
338 # string literally.
339 sed_make_literal_regex='s|[].[^$\\*\/]|\\&|g'
340
341 # Sed substitution that converts a w32 file name or path
342 # that contains forward slashes, into one that contains
343 # (escaped) backslashes. A very naive implementation.
344 sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
345
346 # Re-'\' parameter expansions in output of sed_double_quote_subst that
347 # were '\'-ed in input to the same. If an odd number of '\' preceded a
348 # '$' in input to sed_double_quote_subst, that '$' was protected from
349 # expansion. Since each input '\' is now two '\'s, look for any number
350 # of runs of four '\'s followed by two '\'s and then a '$'. '\' that '$'.
351 _G_bs='\\'
352 _G_bs2='\\\\'
353 _G_bs4='\\\\\\\\'
354 _G_dollar='\$'
355 sed_double_backslash="\
356 s/$_G_bs4/&\\
357 /g
358 s/^$_G_bs2$_G_dollar/$_G_bs&/
359 s/\\([^$_G_bs]\\)$_G_bs2$_G_dollar/\\1$_G_bs2$_G_bs$_G_dollar/g
360 s/\n//g"
361
362
363 ## ----------------- ##
364 ## Global variables. ##
365 ## ----------------- ##
366
367 # Except for the global variables explicitly listed below, the following
368 # functions in the '^func_' namespace, and the '^require_' namespace
369 # variables initialised in the 'Resource management' section, sourcing
370 # this file will not pollute your global namespace with anything
371 # else. There's no portable way to scope variables in Bourne shell
372 # though, so actually running these functions will sometimes place
373 # results into a variable named after the function, and often use
374 # temporary variables in the '^_G_' namespace. If you are careful to
375 # avoid using those namespaces casually in your sourcing script, things
376 # should continue to work as you expect. And, of course, you can freely
377 # overwrite any of the functions or variables defined here before
378 # calling anything to customize them.
379
380 EXIT_SUCCESS=0
381 EXIT_FAILURE=1
382 EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing.
383 EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake.
384
385 # Allow overriding, eg assuming that you follow the convention of
386 # putting '$debug_cmd' at the start of all your functions, you can get
387 # bash to show function call trace with:
388 #
389 # debug_cmd='eval echo "${FUNCNAME[0]} $*" >&2' bash your-script-name
390 debug_cmd=${debug_cmd-":"}
391 exit_cmd=:
392
393 # By convention, finish your script with:
394 #
395 # exit $exit_status
396 #
397 # so that you can set exit_status to non-zero if you want to indicate
398 # something went wrong during execution without actually bailing out at
399 # the point of failure.
400 exit_status=$EXIT_SUCCESS
127401
128402 # Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh
129403 # is ksh but when the shell is invoked as "sh" and the current value of
130404 # the _XPG environment variable is not equal to 1 (one), the special
131405 # positional parameter $0, within a function call, is the name of the
132406 # function.
133 progpath="$0"
134
135
136
137 : ${CP="cp -f"}
138 test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'}
139 : ${MAKE="make"}
140 : ${MKDIR="mkdir"}
141 : ${MV="mv -f"}
142 : ${RM="rm -f"}
143 : ${SHELL="${CONFIG_SHELL-/bin/sh}"}
144 : ${Xsed="$SED -e 1s/^X//"}
145
146 # Global variables:
147 EXIT_SUCCESS=0
148 EXIT_FAILURE=1
149 EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing.
150 EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake.
151
152 exit_status=$EXIT_SUCCESS
153
154 # Make sure IFS has a sensible default
155 lt_nl='
156 '
157 IFS=" $lt_nl"
158
159 dirname="s,/[^/]*$,,"
160 basename="s,^.*/,,"
161
162 # func_dirname file append nondir_replacement
407 progpath=$0
408
409 # The name of this program.
410 progname=`$ECHO "$progpath" |$SED "$sed_basename"`
411
412 # Make sure we have an absolute progpath for reexecution:
413 case $progpath in
414 [\\/]*|[A-Za-z]:\\*) ;;
415 *[\\/]*)
416 progdir=`$ECHO "$progpath" |$SED "$sed_dirname"`
417 progdir=`cd "$progdir" && pwd`
418 progpath=$progdir/$progname
419 ;;
420 *)
421 _G_IFS=$IFS
422 IFS=${PATH_SEPARATOR-:}
423 for progdir in $PATH; do
424 IFS=$_G_IFS
425 test -x "$progdir/$progname" && break
426 done
427 IFS=$_G_IFS
428 test -n "$progdir" || progdir=`pwd`
429 progpath=$progdir/$progname
430 ;;
431 esac
432
433
434 ## ----------------- ##
435 ## Standard options. ##
436 ## ----------------- ##
437
438 # The following options affect the operation of the functions defined
439 # below, and should be set appropriately depending on run-time para-
440 # meters passed on the command line.
441
442 opt_dry_run=false
443 opt_quiet=false
444 opt_verbose=false
445
446 # Categories 'all' and 'none' are always available. Append any others
447 # you will pass as the first argument to func_warning from your own
448 # code.
449 warning_categories=
450
451 # By default, display warnings according to 'opt_warning_types'. Set
452 # 'warning_func' to ':' to elide all warnings, or func_fatal_error to
453 # treat the next displayed warning as a fatal error.
454 warning_func=func_warn_and_continue
455
456 # Set to 'all' to display all warnings, 'none' to suppress all
457 # warnings, or a space delimited list of some subset of
458 # 'warning_categories' to display only the listed warnings.
459 opt_warning_types=all
460
461
462 ## -------------------- ##
463 ## Resource management. ##
464 ## -------------------- ##
465
466 # This section contains definitions for functions that each ensure a
467 # particular resource (a file, or a non-empty configuration variable for
468 # example) is available, and if appropriate to extract default values
469 # from pertinent package files. Call them using their associated
470 # 'require_*' variable to ensure that they are executed, at most, once.
471 #
472 # It's entirely deliberate that calling these functions can set
473 # variables that don't obey the namespace limitations obeyed by the rest
474 # of this file, in order that that they be as useful as possible to
475 # callers.
476
477
478 # require_term_colors
479 # -------------------
480 # Allow display of bold text on terminals that support it.
481 require_term_colors=func_require_term_colors
482 func_require_term_colors ()
483 {
484 $debug_cmd
485
486 test -t 1 && {
487 # COLORTERM and USE_ANSI_COLORS environment variables take
488 # precedence, because most terminfo databases neglect to describe
489 # whether color sequences are supported.
490 test -n "${COLORTERM+set}" && : ${USE_ANSI_COLORS="1"}
491
492 if test 1 = "$USE_ANSI_COLORS"; then
493 # Standard ANSI escape sequences
494 tc_reset=''
495 tc_bold=''; tc_standout=''
496 tc_red=''; tc_green=''
497 tc_blue=''; tc_cyan=''
498 else
499 # Otherwise trust the terminfo database after all.
500 test -n "`tput sgr0 2>/dev/null`" && {
501 tc_reset=`tput sgr0`
502 test -n "`tput bold 2>/dev/null`" && tc_bold=`tput bold`
503 tc_standout=$tc_bold
504 test -n "`tput smso 2>/dev/null`" && tc_standout=`tput smso`
505 test -n "`tput setaf 1 2>/dev/null`" && tc_red=`tput setaf 1`
506 test -n "`tput setaf 2 2>/dev/null`" && tc_green=`tput setaf 2`
507 test -n "`tput setaf 4 2>/dev/null`" && tc_blue=`tput setaf 4`
508 test -n "`tput setaf 5 2>/dev/null`" && tc_cyan=`tput setaf 5`
509 }
510 fi
511 }
512
513 require_term_colors=:
514 }
515
516
517 ## ----------------- ##
518 ## Function library. ##
519 ## ----------------- ##
520
521 # This section contains a variety of useful functions to call in your
522 # scripts. Take note of the portable wrappers for features provided by
523 # some modern shells, which will fall back to slower equivalents on
524 # less featureful shells.
525
526
527 # func_append VAR VALUE
528 # ---------------------
529 # Append VALUE onto the existing contents of VAR.
530
531 # We should try to minimise forks, especially on Windows where they are
532 # unreasonably slow, so skip the feature probes when bash or zsh are
533 # being used:
534 if test set = "${BASH_VERSION+set}${ZSH_VERSION+set}"; then
535 : ${_G_HAVE_ARITH_OP="yes"}
536 : ${_G_HAVE_XSI_OPS="yes"}
537 # The += operator was introduced in bash 3.1
538 case $BASH_VERSION in
539 [12].* | 3.0 | 3.0*) ;;
540 *)
541 : ${_G_HAVE_PLUSEQ_OP="yes"}
542 ;;
543 esac
544 fi
545
546 # _G_HAVE_PLUSEQ_OP
547 # Can be empty, in which case the shell is probed, "yes" if += is
548 # useable or anything else if it does not work.
549 test -z "$_G_HAVE_PLUSEQ_OP" \
550 && (eval 'x=a; x+=" b"; test "a b" = "$x"') 2>/dev/null \
551 && _G_HAVE_PLUSEQ_OP=yes
552
553 if test yes = "$_G_HAVE_PLUSEQ_OP"
554 then
555 # This is an XSI compatible shell, allowing a faster implementation...
556 eval 'func_append ()
557 {
558 $debug_cmd
559
560 eval "$1+=\$2"
561 }'
562 else
563 # ...otherwise fall back to using expr, which is often a shell builtin.
564 func_append ()
565 {
566 $debug_cmd
567
568 eval "$1=\$$1\$2"
569 }
570 fi
571
572
573 # func_append_quoted VAR VALUE
574 # ----------------------------
575 # Quote VALUE and append to the end of shell variable VAR, separated
576 # by a space.
577 if test yes = "$_G_HAVE_PLUSEQ_OP"; then
578 eval 'func_append_quoted ()
579 {
580 $debug_cmd
581
582 func_quote_for_eval "$2"
583 eval "$1+=\\ \$func_quote_for_eval_result"
584 }'
585 else
586 func_append_quoted ()
587 {
588 $debug_cmd
589
590 func_quote_for_eval "$2"
591 eval "$1=\$$1\\ \$func_quote_for_eval_result"
592 }
593 fi
594
595
596 # func_append_uniq VAR VALUE
597 # --------------------------
598 # Append unique VALUE onto the existing contents of VAR, assuming
599 # entries are delimited by the first character of VALUE. For example:
600 #
601 # func_append_uniq options " --another-option option-argument"
602 #
603 # will only append to $options if " --another-option option-argument "
604 # is not already present somewhere in $options already (note spaces at
605 # each end implied by leading space in second argument).
606 func_append_uniq ()
607 {
608 $debug_cmd
609
610 eval _G_current_value='`$ECHO $'$1'`'
611 _G_delim=`expr "$2" : '\(.\)'`
612
613 case $_G_delim$_G_current_value$_G_delim in
614 *"$2$_G_delim"*) ;;
615 *) func_append "$@" ;;
616 esac
617 }
618
619
620 # func_arith TERM...
621 # ------------------
622 # Set func_arith_result to the result of evaluating TERMs.
623 test -z "$_G_HAVE_ARITH_OP" \
624 && (eval 'test 2 = $(( 1 + 1 ))') 2>/dev/null \
625 && _G_HAVE_ARITH_OP=yes
626
627 if test yes = "$_G_HAVE_ARITH_OP"; then
628 eval 'func_arith ()
629 {
630 $debug_cmd
631
632 func_arith_result=$(( $* ))
633 }'
634 else
635 func_arith ()
636 {
637 $debug_cmd
638
639 func_arith_result=`expr "$@"`
640 }
641 fi
642
643
644 # func_basename FILE
645 # ------------------
646 # Set func_basename_result to FILE with everything up to and including
647 # the last / stripped.
648 if test yes = "$_G_HAVE_XSI_OPS"; then
649 # If this shell supports suffix pattern removal, then use it to avoid
650 # forking. Hide the definitions single quotes in case the shell chokes
651 # on unsupported syntax...
652 _b='func_basename_result=${1##*/}'
653 _d='case $1 in
654 */*) func_dirname_result=${1%/*}$2 ;;
655 * ) func_dirname_result=$3 ;;
656 esac'
657
658 else
659 # ...otherwise fall back to using sed.
660 _b='func_basename_result=`$ECHO "$1" |$SED "$sed_basename"`'
661 _d='func_dirname_result=`$ECHO "$1" |$SED "$sed_dirname"`
662 if test "X$func_dirname_result" = "X$1"; then
663 func_dirname_result=$3
664 else
665 func_append func_dirname_result "$2"
666 fi'
667 fi
668
669 eval 'func_basename ()
670 {
671 $debug_cmd
672
673 '"$_b"'
674 }'
675
676
677 # func_dirname FILE APPEND NONDIR_REPLACEMENT
678 # -------------------------------------------
163679 # Compute the dirname of FILE. If nonempty, add APPEND to the result,
164680 # otherwise set result to NONDIR_REPLACEMENT.
165 func_dirname ()
166 {
167 func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
168 if test "X$func_dirname_result" = "X${1}"; then
169 func_dirname_result="${3}"
170 else
171 func_dirname_result="$func_dirname_result${2}"
172 fi
173 } # func_dirname may be replaced by extended shell implementation
174
175
176 # func_basename file
177 func_basename ()
178 {
179 func_basename_result=`$ECHO "${1}" | $SED "$basename"`
180 } # func_basename may be replaced by extended shell implementation
181
182
183 # func_dirname_and_basename file append nondir_replacement
184 # perform func_basename and func_dirname in a single function
681 eval 'func_dirname ()
682 {
683 $debug_cmd
684
685 '"$_d"'
686 }'
687
688
689 # func_dirname_and_basename FILE APPEND NONDIR_REPLACEMENT
690 # --------------------------------------------------------
691 # Perform func_basename and func_dirname in a single function
185692 # call:
186693 # dirname: Compute the dirname of FILE. If nonempty,
187694 # add APPEND to the result, otherwise set result
189696 # value returned in "$func_dirname_result"
190697 # basename: Compute filename of FILE.
191698 # value retuned in "$func_basename_result"
192 # Implementation must be kept synchronized with func_dirname
193 # and func_basename. For efficiency, we do not delegate to
194 # those functions but instead duplicate the functionality here.
195 func_dirname_and_basename ()
196 {
197 # Extract subdirectory from the argument.
198 func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"`
199 if test "X$func_dirname_result" = "X${1}"; then
200 func_dirname_result="${3}"
699 # For efficiency, we do not delegate to the functions above but instead
700 # duplicate the functionality here.
701 eval 'func_dirname_and_basename ()
702 {
703 $debug_cmd
704
705 '"$_b"'
706 '"$_d"'
707 }'
708
709
710 # func_echo ARG...
711 # ----------------
712 # Echo program name prefixed message.
713 func_echo ()
714 {
715 $debug_cmd
716
717 _G_message=$*
718
719 func_echo_IFS=$IFS
720 IFS=$nl
721 for _G_line in $_G_message; do
722 IFS=$func_echo_IFS
723 $ECHO "$progname: $_G_line"
724 done
725 IFS=$func_echo_IFS
726 }
727
728
729 # func_echo_all ARG...
730 # --------------------
731 # Invoke $ECHO with all args, space-separated.
732 func_echo_all ()
733 {
734 $ECHO "$*"
735 }
736
737
738 # func_echo_infix_1 INFIX ARG...
739 # ------------------------------
740 # Echo program name, followed by INFIX on the first line, with any
741 # additional lines not showing INFIX.
742 func_echo_infix_1 ()
743 {
744 $debug_cmd
745
746 $require_term_colors
747
748 _G_infix=$1; shift
749 _G_indent=$_G_infix
750 _G_prefix="$progname: $_G_infix: "
751 _G_message=$*
752
753 # Strip color escape sequences before counting printable length
754 for _G_tc in "$tc_reset" "$tc_bold" "$tc_standout" "$tc_red" "$tc_green" "$tc_blue" "$tc_cyan"
755 do
756 test -n "$_G_tc" && {
757 _G_esc_tc=`$ECHO "$_G_tc" | $SED "$sed_make_literal_regex"`
758 _G_indent=`$ECHO "$_G_indent" | $SED "s|$_G_esc_tc||g"`
759 }
760 done
761 _G_indent="$progname: "`echo "$_G_indent" | $SED 's|.| |g'`" " ## exclude from sc_prohibit_nested_quotes
762
763 func_echo_infix_1_IFS=$IFS
764 IFS=$nl
765 for _G_line in $_G_message; do
766 IFS=$func_echo_infix_1_IFS
767 $ECHO "$_G_prefix$tc_bold$_G_line$tc_reset" >&2
768 _G_prefix=$_G_indent
769 done
770 IFS=$func_echo_infix_1_IFS
771 }
772
773
774 # func_error ARG...
775 # -----------------
776 # Echo program name prefixed message to standard error.
777 func_error ()
778 {
779 $debug_cmd
780
781 $require_term_colors
782
783 func_echo_infix_1 " $tc_standout${tc_red}error$tc_reset" "$*" >&2
784 }
785
786
787 # func_fatal_error ARG...
788 # -----------------------
789 # Echo program name prefixed message to standard error, and exit.
790 func_fatal_error ()
791 {
792 $debug_cmd
793
794 func_error "$*"
795 exit $EXIT_FAILURE
796 }
797
798
799 # func_grep EXPRESSION FILENAME
800 # -----------------------------
801 # Check whether EXPRESSION matches any line of FILENAME, without output.
802 func_grep ()
803 {
804 $debug_cmd
805
806 $GREP "$1" "$2" >/dev/null 2>&1
807 }
808
809
810 # func_len STRING
811 # ---------------
812 # Set func_len_result to the length of STRING. STRING may not
813 # start with a hyphen.
814 test -z "$_G_HAVE_XSI_OPS" \
815 && (eval 'x=a/b/c;
816 test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \
817 && _G_HAVE_XSI_OPS=yes
818
819 if test yes = "$_G_HAVE_XSI_OPS"; then
820 eval 'func_len ()
821 {
822 $debug_cmd
823
824 func_len_result=${#1}
825 }'
826 else
827 func_len ()
828 {
829 $debug_cmd
830
831 func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
832 }
833 fi
834
835
836 # func_mkdir_p DIRECTORY-PATH
837 # ---------------------------
838 # Make sure the entire path to DIRECTORY-PATH is available.
839 func_mkdir_p ()
840 {
841 $debug_cmd
842
843 _G_directory_path=$1
844 _G_dir_list=
845
846 if test -n "$_G_directory_path" && test : != "$opt_dry_run"; then
847
848 # Protect directory names starting with '-'
849 case $_G_directory_path in
850 -*) _G_directory_path=./$_G_directory_path ;;
851 esac
852
853 # While some portion of DIR does not yet exist...
854 while test ! -d "$_G_directory_path"; do
855 # ...make a list in topmost first order. Use a colon delimited
856 # list incase some portion of path contains whitespace.
857 _G_dir_list=$_G_directory_path:$_G_dir_list
858
859 # If the last portion added has no slash in it, the list is done
860 case $_G_directory_path in */*) ;; *) break ;; esac
861
862 # ...otherwise throw away the child directory and loop
863 _G_directory_path=`$ECHO "$_G_directory_path" | $SED -e "$sed_dirname"`
864 done
865 _G_dir_list=`$ECHO "$_G_dir_list" | $SED 's|:*$||'`
866
867 func_mkdir_p_IFS=$IFS; IFS=:
868 for _G_dir in $_G_dir_list; do
869 IFS=$func_mkdir_p_IFS
870 # mkdir can fail with a 'File exist' error if two processes
871 # try to create one of the directories concurrently. Don't
872 # stop in that case!
873 $MKDIR "$_G_dir" 2>/dev/null || :
874 done
875 IFS=$func_mkdir_p_IFS
876
877 # Bail out if we (or some other process) failed to create a directory.
878 test -d "$_G_directory_path" || \
879 func_fatal_error "Failed to create '$1'"
880 fi
881 }
882
883
884 # func_mktempdir [BASENAME]
885 # -------------------------
886 # Make a temporary directory that won't clash with other running
887 # libtool processes, and avoids race conditions if possible. If
888 # given, BASENAME is the basename for that directory.
889 func_mktempdir ()
890 {
891 $debug_cmd
892
893 _G_template=${TMPDIR-/tmp}/${1-$progname}
894
895 if test : = "$opt_dry_run"; then
896 # Return a directory name, but don't create it in dry-run mode
897 _G_tmpdir=$_G_template-$$
201898 else
202 func_dirname_result="$func_dirname_result${2}"
899
900 # If mktemp works, use that first and foremost
901 _G_tmpdir=`mktemp -d "$_G_template-XXXXXXXX" 2>/dev/null`
902
903 if test ! -d "$_G_tmpdir"; then
904 # Failing that, at least try and use $RANDOM to avoid a race
905 _G_tmpdir=$_G_template-${RANDOM-0}$$
906
907 func_mktempdir_umask=`umask`
908 umask 0077
909 $MKDIR "$_G_tmpdir"
910 umask $func_mktempdir_umask
911 fi
912
913 # If we're not in dry-run mode, bomb out on failure
914 test -d "$_G_tmpdir" || \
915 func_fatal_error "cannot create temporary directory '$_G_tmpdir'"
203916 fi
204 func_basename_result=`$ECHO "${1}" | $SED -e "$basename"`
205 } # func_dirname_and_basename may be replaced by extended shell implementation
206
207
208 # func_stripname prefix suffix name
209 # strip PREFIX and SUFFIX off of NAME.
210 # PREFIX and SUFFIX must not contain globbing or regex special
211 # characters, hashes, percent signs, but SUFFIX may contain a leading
212 # dot (in which case that matches only a dot).
213 # func_strip_suffix prefix name
214 func_stripname ()
215 {
216 case ${2} in
217 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
218 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
219 esac
220 } # func_stripname may be replaced by extended shell implementation
221
222
223 # These SED scripts presuppose an absolute path with a trailing slash.
224 pathcar='s,^/\([^/]*\).*$,\1,'
225 pathcdr='s,^/[^/]*,,'
226 removedotparts=':dotsl
227 s@/\./@/@g
228 t dotsl
229 s,/\.$,/,'
230 collapseslashes='s@/\{1,\}@/@g'
231 finalslash='s,/*$,/,'
917
918 $ECHO "$_G_tmpdir"
919 }
920
232921
233922 # func_normal_abspath PATH
923 # ------------------------
234924 # Remove doubled-up and trailing slashes, "." path components,
235925 # and cancel out any ".." path components in PATH after making
236926 # it an absolute path.
237 # value returned in "$func_normal_abspath_result"
238927 func_normal_abspath ()
239928 {
240 # Start from root dir and reassemble the path.
241 func_normal_abspath_result=
242 func_normal_abspath_tpath=$1
243 func_normal_abspath_altnamespace=
244 case $func_normal_abspath_tpath in
245 "")
246 # Empty path, that just means $cwd.
247 func_stripname '' '/' "`pwd`"
248 func_normal_abspath_result=$func_stripname_result
249 return
250 ;;
251 # The next three entries are used to spot a run of precisely
252 # two leading slashes without using negated character classes;
253 # we take advantage of case's first-match behaviour.
254 ///*)
255 # Unusual form of absolute path, do nothing.
256 ;;
257 //*)
258 # Not necessarily an ordinary path; POSIX reserves leading '//'
259 # and for example Cygwin uses it to access remote file shares
260 # over CIFS/SMB, so we conserve a leading double slash if found.
261 func_normal_abspath_altnamespace=/
262 ;;
263 /*)
264 # Absolute path, do nothing.
265 ;;
266 *)
267 # Relative path, prepend $cwd.
268 func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath
269 ;;
270 esac
271 # Cancel out all the simple stuff to save iterations. We also want
272 # the path to end with a slash for ease of parsing, so make sure
273 # there is one (and only one) here.
274 func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
275 -e "$removedotparts" -e "$collapseslashes" -e "$finalslash"`
276 while :; do
277 # Processed it all yet?
278 if test "$func_normal_abspath_tpath" = / ; then
279 # If we ascended to the root using ".." the result may be empty now.
280 if test -z "$func_normal_abspath_result" ; then
281 func_normal_abspath_result=/
282 fi
283 break
284 fi
285 func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \
286 -e "$pathcar"`
929 $debug_cmd
930
931 # These SED scripts presuppose an absolute path with a trailing slash.
932 _G_pathcar='s|^/\([^/]*\).*$|\1|'
933 _G_pathcdr='s|^/[^/]*||'
934 _G_removedotparts=':dotsl
935 s|/\./|/|g
936 t dotsl
937 s|/\.$|/|'
938 _G_collapseslashes='s|/\{1,\}|/|g'
939 _G_finalslash='s|/*$|/|'
940
941 # Start from root dir and reassemble the path.
942 func_normal_abspath_result=
943 func_normal_abspath_tpath=$1
944 func_normal_abspath_altnamespace=
945 case $func_normal_abspath_tpath in
946 "")
947 # Empty path, that just means $cwd.
948 func_stripname '' '/' "`pwd`"
949 func_normal_abspath_result=$func_stripname_result
950 return
951 ;;
952 # The next three entries are used to spot a run of precisely
953 # two leading slashes without using negated character classes;
954 # we take advantage of case's first-match behaviour.
955 ///*)
956 # Unusual form of absolute path, do nothing.
957 ;;
958 //*)
959 # Not necessarily an ordinary path; POSIX reserves leading '//'
960 # and for example Cygwin uses it to access remote file shares
961 # over CIFS/SMB, so we conserve a leading double slash if found.
962 func_normal_abspath_altnamespace=/
963 ;;
964 /*)
965 # Absolute path, do nothing.
966 ;;
967 *)
968 # Relative path, prepend $cwd.
969 func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath
970 ;;
971 esac
972
973 # Cancel out all the simple stuff to save iterations. We also want
974 # the path to end with a slash for ease of parsing, so make sure
975 # there is one (and only one) here.
287976 func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
288 -e "$pathcdr"`
289 # Figure out what to do with it
290 case $func_normal_abspath_tcomponent in
291 "")
292 # Trailing empty path component, ignore it.
293 ;;
294 ..)
295 # Parent dir; strip last assembled component from result.
296 func_dirname "$func_normal_abspath_result"
297 func_normal_abspath_result=$func_dirname_result
298 ;;
299 *)
300 # Actual path component, append it.
301 func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent
302 ;;
303 esac
304 done
305 # Restore leading double-slash if one was found on entry.
306 func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result
307 }
308
309 # func_relative_path SRCDIR DSTDIR
310 # generates a relative path from SRCDIR to DSTDIR, with a trailing
311 # slash if non-empty, suitable for immediately appending a filename
312 # without needing to append a separator.
313 # value returned in "$func_relative_path_result"
314 func_relative_path ()
315 {
316 func_relative_path_result=
317 func_normal_abspath "$1"
318 func_relative_path_tlibdir=$func_normal_abspath_result
319 func_normal_abspath "$2"
320 func_relative_path_tbindir=$func_normal_abspath_result
321
322 # Ascend the tree starting from libdir
323 while :; do
324 # check if we have found a prefix of bindir
325 case $func_relative_path_tbindir in
326 $func_relative_path_tlibdir)
327 # found an exact match
328 func_relative_path_tcancelled=
329 break
330 ;;
331 $func_relative_path_tlibdir*)
332 # found a matching prefix
333 func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir"
334 func_relative_path_tcancelled=$func_stripname_result
335 if test -z "$func_relative_path_result"; then
336 func_relative_path_result=.
977 -e "$_G_removedotparts" -e "$_G_collapseslashes" -e "$_G_finalslash"`
978 while :; do
979 # Processed it all yet?
980 if test / = "$func_normal_abspath_tpath"; then
981 # If we ascended to the root using ".." the result may be empty now.
982 if test -z "$func_normal_abspath_result"; then
983 func_normal_abspath_result=/
337984 fi
338985 break
339 ;;
340 *)
341 func_dirname $func_relative_path_tlibdir
342 func_relative_path_tlibdir=${func_dirname_result}
343 if test "x$func_relative_path_tlibdir" = x ; then
344 # Have to descend all the way to the root!
345 func_relative_path_result=../$func_relative_path_result
346 func_relative_path_tcancelled=$func_relative_path_tbindir
347 break
348 fi
349 func_relative_path_result=../$func_relative_path_result
350 ;;
351 esac
352 done
353
354 # Now calculate path; take care to avoid doubling-up slashes.
355 func_stripname '' '/' "$func_relative_path_result"
356 func_relative_path_result=$func_stripname_result
357 func_stripname '/' '/' "$func_relative_path_tcancelled"
358 if test "x$func_stripname_result" != x ; then
359 func_relative_path_result=${func_relative_path_result}/${func_stripname_result}
360 fi
361
362 # Normalisation. If bindir is libdir, return empty string,
363 # else relative path ending with a slash; either way, target
364 # file name can be directly appended.
365 if test ! -z "$func_relative_path_result"; then
366 func_stripname './' '' "$func_relative_path_result/"
367 func_relative_path_result=$func_stripname_result
368 fi
369 }
370
371 # The name of this program:
372 func_dirname_and_basename "$progpath"
373 progname=$func_basename_result
374
375 # Make sure we have an absolute path for reexecution:
376 case $progpath in
377 [\\/]*|[A-Za-z]:\\*) ;;
378 *[\\/]*)
379 progdir=$func_dirname_result
380 progdir=`cd "$progdir" && pwd`
381 progpath="$progdir/$progname"
382 ;;
383 *)
384 save_IFS="$IFS"
385 IFS=${PATH_SEPARATOR-:}
386 for progdir in $PATH; do
387 IFS="$save_IFS"
388 test -x "$progdir/$progname" && break
389 done
390 IFS="$save_IFS"
391 test -n "$progdir" || progdir=`pwd`
392 progpath="$progdir/$progname"
393 ;;
394 esac
395
396 # Sed substitution that helps us do robust quoting. It backslashifies
397 # metacharacters that are still active within double-quoted strings.
398 Xsed="${SED}"' -e 1s/^X//'
399 sed_quote_subst='s/\([`"$\\]\)/\\\1/g'
400
401 # Same as above, but do not quote variable references.
402 double_quote_subst='s/\(["`\\]\)/\\\1/g'
403
404 # Sed substitution that turns a string into a regex matching for the
405 # string literally.
406 sed_make_literal_regex='s,[].[^$\\*\/],\\&,g'
407
408 # Sed substitution that converts a w32 file name or path
409 # which contains forward slashes, into one that contains
410 # (escaped) backslashes. A very naive implementation.
411 lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
412
413 # Re-`\' parameter expansions in output of double_quote_subst that were
414 # `\'-ed in input to the same. If an odd number of `\' preceded a '$'
415 # in input to double_quote_subst, that '$' was protected from expansion.
416 # Since each input `\' is now two `\'s, look for any number of runs of
417 # four `\'s followed by two `\'s and then a '$'. `\' that '$'.
418 bs='\\'
419 bs2='\\\\'
420 bs4='\\\\\\\\'
421 dollar='\$'
422 sed_double_backslash="\
423 s/$bs4/&\\
424 /g
425 s/^$bs2$dollar/$bs&/
426 s/\\([^$bs]\\)$bs2$dollar/\\1$bs2$bs$dollar/g
427 s/\n//g"
428
429 # Standard options:
430 opt_dry_run=false
431 opt_help=false
432 opt_quiet=false
433 opt_verbose=false
434 opt_warning=:
435
436 # func_echo arg...
437 # Echo program name prefixed message, along with the current mode
438 # name if it has been set yet.
439 func_echo ()
440 {
441 $ECHO "$progname: ${opt_mode+$opt_mode: }$*"
442 }
443
444 # func_verbose arg...
445 # Echo program name prefixed message in verbose mode only.
446 func_verbose ()
447 {
448 $opt_verbose && func_echo ${1+"$@"}
986 fi
987 func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \
988 -e "$_G_pathcar"`
989 func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
990 -e "$_G_pathcdr"`
991 # Figure out what to do with it
992 case $func_normal_abspath_tcomponent in
993 "")
994 # Trailing empty path component, ignore it.
995 ;;
996 ..)
997 # Parent dir; strip last assembled component from result.
998 func_dirname "$func_normal_abspath_result"
999 func_normal_abspath_result=$func_dirname_result
1000 ;;
1001 *)
1002 # Actual path component, append it.
1003 func_append func_normal_abspath_result "/$func_normal_abspath_tcomponent"
1004 ;;
1005 esac
1006 done
1007 # Restore leading double-slash if one was found on entry.
1008 func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result
1009 }
1010
1011
1012 # func_notquiet ARG...
1013 # --------------------
1014 # Echo program name prefixed message only when not in quiet mode.
1015 func_notquiet ()
1016 {
1017 $debug_cmd
1018
1019 $opt_quiet || func_echo ${1+"$@"}
4491020
4501021 # A bug in bash halts the script if the last line of a function
4511022 # fails when set -e is in force, so we need another command to
4531024 :
4541025 }
4551026
456 # func_echo_all arg...
457 # Invoke $ECHO with all args, space-separated.
458 func_echo_all ()
459 {
460 $ECHO "$*"
461 }
462
463 # func_error arg...
464 # Echo program name prefixed message to standard error.
465 func_error ()
466 {
467 $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2
468 }
469
470 # func_warning arg...
471 # Echo program name prefixed warning message to standard error.
472 func_warning ()
473 {
474 $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2
475
476 # bash bug again:
1027
1028 # func_relative_path SRCDIR DSTDIR
1029 # --------------------------------
1030 # Set func_relative_path_result to the relative path from SRCDIR to DSTDIR.
1031 func_relative_path ()
1032 {
1033 $debug_cmd
1034
1035 func_relative_path_result=
1036 func_normal_abspath "$1"
1037 func_relative_path_tlibdir=$func_normal_abspath_result
1038 func_normal_abspath "$2"
1039 func_relative_path_tbindir=$func_normal_abspath_result
1040
1041 # Ascend the tree starting from libdir
1042 while :; do
1043 # check if we have found a prefix of bindir
1044 case $func_relative_path_tbindir in
1045 $func_relative_path_tlibdir)
1046 # found an exact match
1047 func_relative_path_tcancelled=
1048 break
1049 ;;
1050 $func_relative_path_tlibdir*)
1051 # found a matching prefix
1052 func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir"
1053 func_relative_path_tcancelled=$func_stripname_result
1054 if test -z "$func_relative_path_result"; then
1055 func_relative_path_result=.
1056 fi
1057 break
1058 ;;
1059 *)
1060 func_dirname $func_relative_path_tlibdir
1061 func_relative_path_tlibdir=$func_dirname_result
1062 if test -z "$func_relative_path_tlibdir"; then
1063 # Have to descend all the way to the root!
1064 func_relative_path_result=../$func_relative_path_result
1065 func_relative_path_tcancelled=$func_relative_path_tbindir
1066 break
1067 fi
1068 func_relative_path_result=../$func_relative_path_result
1069 ;;
1070 esac
1071 done
1072
1073 # Now calculate path; take care to avoid doubling-up slashes.
1074 func_stripname '' '/' "$func_relative_path_result"
1075 func_relative_path_result=$func_stripname_result
1076 func_stripname '/' '/' "$func_relative_path_tcancelled"
1077 if test -n "$func_stripname_result"; then
1078 func_append func_relative_path_result "/$func_stripname_result"
1079 fi
1080
1081 # Normalisation. If bindir is libdir, return '.' else relative path.
1082 if test -n "$func_relative_path_result"; then
1083 func_stripname './' '' "$func_relative_path_result"
1084 func_relative_path_result=$func_stripname_result
1085 fi
1086
1087 test -n "$func_relative_path_result" || func_relative_path_result=.
1088
4771089 :
4781090 }
4791091
480 # func_fatal_error arg...
481 # Echo program name prefixed message to standard error, and exit.
482 func_fatal_error ()
483 {
484 func_error ${1+"$@"}
485 exit $EXIT_FAILURE
486 }
487
488 # func_fatal_help arg...
489 # Echo program name prefixed message to standard error, followed by
490 # a help hint, and exit.
491 func_fatal_help ()
492 {
493 func_error ${1+"$@"}
494 func_fatal_error "$help"
495 }
496 help="Try \`$progname --help' for more information." ## default
497
498
499 # func_grep expression filename
500 # Check whether EXPRESSION matches any line of FILENAME, without output.
501 func_grep ()
502 {
503 $GREP "$1" "$2" >/dev/null 2>&1
504 }
505
506
507 # func_mkdir_p directory-path
508 # Make sure the entire path to DIRECTORY-PATH is available.
509 func_mkdir_p ()
510 {
511 my_directory_path="$1"
512 my_dir_list=
513
514 if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then
515
516 # Protect directory names starting with `-'
517 case $my_directory_path in
518 -*) my_directory_path="./$my_directory_path" ;;
1092
1093 # func_quote_for_eval ARG...
1094 # --------------------------
1095 # Aesthetically quote ARGs to be evaled later.
1096 # This function returns two values:
1097 # i) func_quote_for_eval_result
1098 # double-quoted, suitable for a subsequent eval
1099 # ii) func_quote_for_eval_unquoted_result
1100 # has all characters that are still active within double
1101 # quotes backslashified.
1102 func_quote_for_eval ()
1103 {
1104 $debug_cmd
1105
1106 func_quote_for_eval_unquoted_result=
1107 func_quote_for_eval_result=
1108 while test 0 -lt $#; do
1109 case $1 in
1110 *[\\\`\"\$]*)
1111 _G_unquoted_arg=`printf '%s\n' "$1" |$SED "$sed_quote_subst"` ;;
1112 *)
1113 _G_unquoted_arg=$1 ;;
5191114 esac
520
521 # While some portion of DIR does not yet exist...
522 while test ! -d "$my_directory_path"; do
523 # ...make a list in topmost first order. Use a colon delimited
524 # list incase some portion of path contains whitespace.
525 my_dir_list="$my_directory_path:$my_dir_list"
526
527 # If the last portion added has no slash in it, the list is done
528 case $my_directory_path in */*) ;; *) break ;; esac
529
530 # ...otherwise throw away the child directory and loop
531 my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"`
532 done
533 my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'`
534
535 save_mkdir_p_IFS="$IFS"; IFS=':'
536 for my_dir in $my_dir_list; do
537 IFS="$save_mkdir_p_IFS"
538 # mkdir can fail with a `File exist' error if two processes
539 # try to create one of the directories concurrently. Don't
540 # stop in that case!
541 $MKDIR "$my_dir" 2>/dev/null || :
542 done
543 IFS="$save_mkdir_p_IFS"
544
545 # Bail out if we (or some other process) failed to create a directory.
546 test -d "$my_directory_path" || \
547 func_fatal_error "Failed to create \`$1'"
548 fi
549 }
550
551
552 # func_mktempdir [string]
553 # Make a temporary directory that won't clash with other running
554 # libtool processes, and avoids race conditions if possible. If
555 # given, STRING is the basename for that directory.
556 func_mktempdir ()
557 {
558 my_template="${TMPDIR-/tmp}/${1-$progname}"
559
560 if test "$opt_dry_run" = ":"; then
561 # Return a directory name, but don't create it in dry-run mode
562 my_tmpdir="${my_template}-$$"
563 else
564
565 # If mktemp works, use that first and foremost
566 my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null`
567
568 if test ! -d "$my_tmpdir"; then
569 # Failing that, at least try and use $RANDOM to avoid a race
570 my_tmpdir="${my_template}-${RANDOM-0}$$"
571
572 save_mktempdir_umask=`umask`
573 umask 0077
574 $MKDIR "$my_tmpdir"
575 umask $save_mktempdir_umask
1115 if test -n "$func_quote_for_eval_unquoted_result"; then
1116 func_append func_quote_for_eval_unquoted_result " $_G_unquoted_arg"
1117 else
1118 func_append func_quote_for_eval_unquoted_result "$_G_unquoted_arg"
5761119 fi
5771120
578 # If we're not in dry-run mode, bomb out on failure
579 test -d "$my_tmpdir" || \
580 func_fatal_error "cannot create temporary directory \`$my_tmpdir'"
581 fi
582
583 $ECHO "$my_tmpdir"
584 }
585
586
587 # func_quote_for_eval arg
588 # Aesthetically quote ARG to be evaled later.
589 # This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT
590 # is double-quoted, suitable for a subsequent eval, whereas
591 # FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters
592 # which are still active within double quotes backslashified.
593 func_quote_for_eval ()
594 {
595 case $1 in
596 *[\\\`\"\$]*)
597 func_quote_for_eval_unquoted_result=`$ECHO "$1" | $SED "$sed_quote_subst"` ;;
598 *)
599 func_quote_for_eval_unquoted_result="$1" ;;
600 esac
601
602 case $func_quote_for_eval_unquoted_result in
603 # Double-quote args containing shell metacharacters to delay
604 # word splitting, command substitution and and variable
605 # expansion for a subsequent eval.
606 # Many Bourne shells cannot handle close brackets correctly
607 # in scan sets, so we specify it separately.
608 *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"")
609 func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\""
610 ;;
611 *)
612 func_quote_for_eval_result="$func_quote_for_eval_unquoted_result"
613 esac
614 }
615
616
617 # func_quote_for_expand arg
1121 case $_G_unquoted_arg in
1122 # Double-quote args containing shell metacharacters to delay
1123 # word splitting, command substitution and variable expansion
1124 # for a subsequent eval.
1125 # Many Bourne shells cannot handle close brackets correctly
1126 # in scan sets, so we specify it separately.
1127 *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"")
1128 _G_quoted_arg=\"$_G_unquoted_arg\"
1129 ;;
1130 *)
1131 _G_quoted_arg=$_G_unquoted_arg
1132 ;;
1133 esac
1134
1135 if test -n "$func_quote_for_eval_result"; then
1136 func_append func_quote_for_eval_result " $_G_quoted_arg"
1137 else
1138 func_append func_quote_for_eval_result "$_G_quoted_arg"
1139 fi
1140 shift
1141 done
1142 }
1143
1144
1145 # func_quote_for_expand ARG
1146 # -------------------------
6181147 # Aesthetically quote ARG to be evaled later; same as above,
6191148 # but do not quote variable references.
6201149 func_quote_for_expand ()
6211150 {
1151 $debug_cmd
1152
6221153 case $1 in
6231154 *[\\\`\"]*)
624 my_arg=`$ECHO "$1" | $SED \
625 -e "$double_quote_subst" -e "$sed_double_backslash"` ;;
1155 _G_arg=`$ECHO "$1" | $SED \
1156 -e "$sed_double_quote_subst" -e "$sed_double_backslash"` ;;
6261157 *)
627 my_arg="$1" ;;
1158 _G_arg=$1 ;;
6281159 esac
6291160
630 case $my_arg in
1161 case $_G_arg in
6311162 # Double-quote args containing shell metacharacters to delay
6321163 # word splitting and command substitution for a subsequent eval.
6331164 # Many Bourne shells cannot handle close brackets correctly
6341165 # in scan sets, so we specify it separately.
6351166 *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"")
636 my_arg="\"$my_arg\""
1167 _G_arg=\"$_G_arg\"
6371168 ;;
6381169 esac
6391170
640 func_quote_for_expand_result="$my_arg"
641 }
642
643
644 # func_show_eval cmd [fail_exp]
645 # Unless opt_silent is true, then output CMD. Then, if opt_dryrun is
1171 func_quote_for_expand_result=$_G_arg
1172 }
1173
1174
1175 # func_stripname PREFIX SUFFIX NAME
1176 # ---------------------------------
1177 # strip PREFIX and SUFFIX from NAME, and store in func_stripname_result.
1178 # PREFIX and SUFFIX must not contain globbing or regex special
1179 # characters, hashes, percent signs, but SUFFIX may contain a leading
1180 # dot (in which case that matches only a dot).
1181 if test yes = "$_G_HAVE_XSI_OPS"; then
1182 eval 'func_stripname ()
1183 {
1184 $debug_cmd
1185
1186 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
1187 # positional parameters, so assign one to ordinary variable first.
1188 func_stripname_result=$3
1189 func_stripname_result=${func_stripname_result#"$1"}
1190 func_stripname_result=${func_stripname_result%"$2"}
1191 }'
1192 else
1193 func_stripname ()
1194 {
1195 $debug_cmd
1196
1197 case $2 in
1198 .*) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%\\\\$2\$%%"`;;
1199 *) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%$2\$%%"`;;
1200 esac
1201 }
1202 fi
1203
1204
1205 # func_show_eval CMD [FAIL_EXP]
1206 # -----------------------------
1207 # Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is
6461208 # not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP
6471209 # is given, then evaluate it.
6481210 func_show_eval ()
6491211 {
650 my_cmd="$1"
651 my_fail_exp="${2-:}"
652
653 ${opt_silent-false} || {
654 func_quote_for_expand "$my_cmd"
655 eval "func_echo $func_quote_for_expand_result"
1212 $debug_cmd
1213
1214 _G_cmd=$1
1215 _G_fail_exp=${2-':'}
1216
1217 func_quote_for_expand "$_G_cmd"
1218 eval "func_notquiet $func_quote_for_expand_result"
1219
1220 $opt_dry_run || {
1221 eval "$_G_cmd"
1222 _G_status=$?
1223 if test 0 -ne "$_G_status"; then
1224 eval "(exit $_G_status); $_G_fail_exp"
1225 fi
6561226 }
657
658 if ${opt_dry_run-false}; then :; else
659 eval "$my_cmd"
660 my_status=$?
661 if test "$my_status" -eq 0; then :; else
662 eval "(exit $my_status); $my_fail_exp"
663 fi
664 fi
665 }
666
667
668 # func_show_eval_locale cmd [fail_exp]
669 # Unless opt_silent is true, then output CMD. Then, if opt_dryrun is
1227 }
1228
1229
1230 # func_show_eval_locale CMD [FAIL_EXP]
1231 # ------------------------------------
1232 # Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is
6701233 # not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP
6711234 # is given, then evaluate it. Use the saved locale for evaluation.
6721235 func_show_eval_locale ()
6731236 {
674 my_cmd="$1"
675 my_fail_exp="${2-:}"
676
677 ${opt_silent-false} || {
678 func_quote_for_expand "$my_cmd"
1237 $debug_cmd
1238
1239 _G_cmd=$1
1240 _G_fail_exp=${2-':'}
1241
1242 $opt_quiet || {
1243 func_quote_for_expand "$_G_cmd"
6791244 eval "func_echo $func_quote_for_expand_result"
6801245 }
6811246
682 if ${opt_dry_run-false}; then :; else
683 eval "$lt_user_locale
684 $my_cmd"
685 my_status=$?
686 eval "$lt_safe_locale"
687 if test "$my_status" -eq 0; then :; else
688 eval "(exit $my_status); $my_fail_exp"
1247 $opt_dry_run || {
1248 eval "$_G_user_locale
1249 $_G_cmd"
1250 _G_status=$?
1251 eval "$_G_safe_locale"
1252 if test 0 -ne "$_G_status"; then
1253 eval "(exit $_G_status); $_G_fail_exp"
6891254 fi
690 fi
691 }
1255 }
1256 }
1257
6921258
6931259 # func_tr_sh
1260 # ----------
6941261 # Turn $1 into a string suitable for a shell variable name.
6951262 # Result is stored in $func_tr_sh_result. All characters
6961263 # not in the set a-zA-Z0-9_ are replaced with '_'. Further,
6971264 # if $1 begins with a digit, a '_' is prepended as well.
6981265 func_tr_sh ()
6991266 {
700 case $1 in
701 [0-9]* | *[!a-zA-Z0-9_]*)
702 func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'`
703 ;;
704 * )
705 func_tr_sh_result=$1
706 ;;
707 esac
708 }
709
710
711 # func_version
712 # Echo version message to standard output and exit.
713 func_version ()
714 {
715 $opt_debug
716
717 $SED -n '/(C)/!b go
718 :more
719 /\./!{
720 N
721 s/\n# / /
722 b more
723 }
724 :go
725 /^# '$PROGRAM' (GNU /,/# warranty; / {
726 s/^# //
727 s/^# *$//
728 s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/
729 p
730 }' < "$progpath"
731 exit $?
732 }
733
734 # func_usage
735 # Echo short help message to standard output and exit.
736 func_usage ()
737 {
738 $opt_debug
739
740 $SED -n '/^# Usage:/,/^# *.*--help/ {
741 s/^# //
742 s/^# *$//
743 s/\$progname/'$progname'/
744 p
745 }' < "$progpath"
746 echo
747 $ECHO "run \`$progname --help | more' for full usage"
748 exit $?
749 }
750
751 # func_help [NOEXIT]
752 # Echo long help message to standard output and exit,
753 # unless 'noexit' is passed as argument.
1267 $debug_cmd
1268
1269 case $1 in
1270 [0-9]* | *[!a-zA-Z0-9_]*)
1271 func_tr_sh_result=`$ECHO "$1" | $SED -e 's/^\([0-9]\)/_\1/' -e 's/[^a-zA-Z0-9_]/_/g'`
1272 ;;
1273 * )
1274 func_tr_sh_result=$1
1275 ;;
1276 esac
1277 }
1278
1279
1280 # func_verbose ARG...
1281 # -------------------
1282 # Echo program name prefixed message in verbose mode only.
1283 func_verbose ()
1284 {
1285 $debug_cmd
1286
1287 $opt_verbose && func_echo "$*"
1288
1289 :
1290 }
1291
1292
1293 # func_warn_and_continue ARG...
1294 # -----------------------------
1295 # Echo program name prefixed warning message to standard error.
1296 func_warn_and_continue ()
1297 {
1298 $debug_cmd
1299
1300 $require_term_colors
1301
1302 func_echo_infix_1 "${tc_red}warning$tc_reset" "$*" >&2
1303 }
1304
1305
1306 # func_warning CATEGORY ARG...
1307 # ----------------------------
1308 # Echo program name prefixed warning message to standard error. Warning
1309 # messages can be filtered according to CATEGORY, where this function
1310 # elides messages where CATEGORY is not listed in the global variable
1311 # 'opt_warning_types'.
1312 func_warning ()
1313 {
1314 $debug_cmd
1315
1316 # CATEGORY must be in the warning_categories list!
1317 case " $warning_categories " in
1318 *" $1 "*) ;;
1319 *) func_internal_error "invalid warning category '$1'" ;;
1320 esac
1321
1322 _G_category=$1
1323 shift
1324
1325 case " $opt_warning_types " in
1326 *" $_G_category "*) $warning_func ${1+"$@"} ;;
1327 esac
1328 }
1329
1330
1331 # func_sort_ver VER1 VER2
1332 # -----------------------
1333 # 'sort -V' is not generally available.
1334 # Note this deviates from the version comparison in automake
1335 # in that it treats 1.5 < 1.5.0, and treats 1.4.4a < 1.4-p3a
1336 # but this should suffice as we won't be specifying old
1337 # version formats or redundant trailing .0 in bootstrap.conf.
1338 # If we did want full compatibility then we should probably
1339 # use m4_version_compare from autoconf.
1340 func_sort_ver ()
1341 {
1342 $debug_cmd
1343
1344 printf '%s\n%s\n' "$1" "$2" \
1345 | sort -t. -k 1,1n -k 2,2n -k 3,3n -k 4,4n -k 5,5n -k 6,6n -k 7,7n -k 8,8n -k 9,9n
1346 }
1347
1348 # func_lt_ver PREV CURR
1349 # ---------------------
1350 # Return true if PREV and CURR are in the correct order according to
1351 # func_sort_ver, otherwise false. Use it like this:
1352 #
1353 # func_lt_ver "$prev_ver" "$proposed_ver" || func_fatal_error "..."
1354 func_lt_ver ()
1355 {
1356 $debug_cmd
1357
1358 test "x$1" = x`func_sort_ver "$1" "$2" | $SED 1q`
1359 }
1360
1361
1362 # Local variables:
1363 # mode: shell-script
1364 # sh-indentation: 2
1365 # eval: (add-hook 'before-save-hook 'time-stamp)
1366 # time-stamp-pattern: "10/scriptversion=%:y-%02m-%02d.%02H; # UTC"
1367 # time-stamp-time-zone: "UTC"
1368 # End:
1369 #! /bin/sh
1370
1371 # Set a version string for this script.
1372 scriptversion=2014-01-07.03; # UTC
1373
1374 # A portable, pluggable option parser for Bourne shell.
1375 # Written by Gary V. Vaughan, 2010
1376
1377 # Copyright (C) 2010-2015 Free Software Foundation, Inc.
1378 # This is free software; see the source for copying conditions. There is NO
1379 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
1380
1381 # This program is free software: you can redistribute it and/or modify
1382 # it under the terms of the GNU General Public License as published by
1383 # the Free Software Foundation, either version 3 of the License, or
1384 # (at your option) any later version.
1385
1386 # This program is distributed in the hope that it will be useful,
1387 # but WITHOUT ANY WARRANTY; without even the implied warranty of
1388 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1389 # GNU General Public License for more details.
1390
1391 # You should have received a copy of the GNU General Public License
1392 # along with this program. If not, see <http://www.gnu.org/licenses/>.
1393
1394 # Please report bugs or propose patches to gary@gnu.org.
1395
1396
1397 ## ------ ##
1398 ## Usage. ##
1399 ## ------ ##
1400
1401 # This file is a library for parsing options in your shell scripts along
1402 # with assorted other useful supporting features that you can make use
1403 # of too.
1404 #
1405 # For the simplest scripts you might need only:
1406 #
1407 # #!/bin/sh
1408 # . relative/path/to/funclib.sh
1409 # . relative/path/to/options-parser
1410 # scriptversion=1.0
1411 # func_options ${1+"$@"}
1412 # eval set dummy "$func_options_result"; shift
1413 # ...rest of your script...
1414 #
1415 # In order for the '--version' option to work, you will need to have a
1416 # suitably formatted comment like the one at the top of this file
1417 # starting with '# Written by ' and ending with '# warranty; '.
1418 #
1419 # For '-h' and '--help' to work, you will also need a one line
1420 # description of your script's purpose in a comment directly above the
1421 # '# Written by ' line, like the one at the top of this file.
1422 #
1423 # The default options also support '--debug', which will turn on shell
1424 # execution tracing (see the comment above debug_cmd below for another
1425 # use), and '--verbose' and the func_verbose function to allow your script
1426 # to display verbose messages only when your user has specified
1427 # '--verbose'.
1428 #
1429 # After sourcing this file, you can plug processing for additional
1430 # options by amending the variables from the 'Configuration' section
1431 # below, and following the instructions in the 'Option parsing'
1432 # section further down.
1433
1434 ## -------------- ##
1435 ## Configuration. ##
1436 ## -------------- ##
1437
1438 # You should override these variables in your script after sourcing this
1439 # file so that they reflect the customisations you have added to the
1440 # option parser.
1441
1442 # The usage line for option parsing errors and the start of '-h' and
1443 # '--help' output messages. You can embed shell variables for delayed
1444 # expansion at the time the message is displayed, but you will need to
1445 # quote other shell meta-characters carefully to prevent them being
1446 # expanded when the contents are evaled.
1447 usage='$progpath [OPTION]...'
1448
1449 # Short help message in response to '-h' and '--help'. Add to this or
1450 # override it after sourcing this library to reflect the full set of
1451 # options your script accepts.
1452 usage_message="\
1453 --debug enable verbose shell tracing
1454 -W, --warnings=CATEGORY
1455 report the warnings falling in CATEGORY [all]
1456 -v, --verbose verbosely report processing
1457 --version print version information and exit
1458 -h, --help print short or long help message and exit
1459 "
1460
1461 # Additional text appended to 'usage_message' in response to '--help'.
1462 long_help_message="
1463 Warning categories include:
1464 'all' show all warnings
1465 'none' turn off all the warnings
1466 'error' warnings are treated as fatal errors"
1467
1468 # Help message printed before fatal option parsing errors.
1469 fatal_help="Try '\$progname --help' for more information."
1470
1471
1472
1473 ## ------------------------- ##
1474 ## Hook function management. ##
1475 ## ------------------------- ##
1476
1477 # This section contains functions for adding, removing, and running hooks
1478 # to the main code. A hook is just a named list of of function, that can
1479 # be run in order later on.
1480
1481 # func_hookable FUNC_NAME
1482 # -----------------------
1483 # Declare that FUNC_NAME will run hooks added with
1484 # 'func_add_hook FUNC_NAME ...'.
1485 func_hookable ()
1486 {
1487 $debug_cmd
1488
1489 func_append hookable_fns " $1"
1490 }
1491
1492
1493 # func_add_hook FUNC_NAME HOOK_FUNC
1494 # ---------------------------------
1495 # Request that FUNC_NAME call HOOK_FUNC before it returns. FUNC_NAME must
1496 # first have been declared "hookable" by a call to 'func_hookable'.
1497 func_add_hook ()
1498 {
1499 $debug_cmd
1500
1501 case " $hookable_fns " in
1502 *" $1 "*) ;;
1503 *) func_fatal_error "'$1' does not accept hook functions." ;;
1504 esac
1505
1506 eval func_append ${1}_hooks '" $2"'
1507 }
1508
1509
1510 # func_remove_hook FUNC_NAME HOOK_FUNC
1511 # ------------------------------------
1512 # Remove HOOK_FUNC from the list of functions called by FUNC_NAME.
1513 func_remove_hook ()
1514 {
1515 $debug_cmd
1516
1517 eval ${1}_hooks='`$ECHO "\$'$1'_hooks" |$SED "s| '$2'||"`'
1518 }
1519
1520
1521 # func_run_hooks FUNC_NAME [ARG]...
1522 # ---------------------------------
1523 # Run all hook functions registered to FUNC_NAME.
1524 # It is assumed that the list of hook functions contains nothing more
1525 # than a whitespace-delimited list of legal shell function names, and
1526 # no effort is wasted trying to catch shell meta-characters or preserve
1527 # whitespace.
1528 func_run_hooks ()
1529 {
1530 $debug_cmd
1531
1532 case " $hookable_fns " in
1533 *" $1 "*) ;;
1534 *) func_fatal_error "'$1' does not support hook funcions.n" ;;
1535 esac
1536
1537 eval _G_hook_fns=\$$1_hooks; shift
1538
1539 for _G_hook in $_G_hook_fns; do
1540 eval $_G_hook '"$@"'
1541
1542 # store returned options list back into positional
1543 # parameters for next 'cmd' execution.
1544 eval _G_hook_result=\$${_G_hook}_result
1545 eval set dummy "$_G_hook_result"; shift
1546 done
1547
1548 func_quote_for_eval ${1+"$@"}
1549 func_run_hooks_result=$func_quote_for_eval_result
1550 }
1551
1552
1553
1554 ## --------------- ##
1555 ## Option parsing. ##
1556 ## --------------- ##
1557
1558 # In order to add your own option parsing hooks, you must accept the
1559 # full positional parameter list in your hook function, remove any
1560 # options that you action, and then pass back the remaining unprocessed
1561 # options in '<hooked_function_name>_result', escaped suitably for
1562 # 'eval'. Like this:
1563 #
1564 # my_options_prep ()
1565 # {
1566 # $debug_cmd
1567 #
1568 # # Extend the existing usage message.
1569 # usage_message=$usage_message'
1570 # -s, --silent don'\''t print informational messages
1571 # '
1572 #
1573 # func_quote_for_eval ${1+"$@"}
1574 # my_options_prep_result=$func_quote_for_eval_result
1575 # }
1576 # func_add_hook func_options_prep my_options_prep
1577 #
1578 #
1579 # my_silent_option ()
1580 # {
1581 # $debug_cmd
1582 #
1583 # # Note that for efficiency, we parse as many options as we can
1584 # # recognise in a loop before passing the remainder back to the
1585 # # caller on the first unrecognised argument we encounter.
1586 # while test $# -gt 0; do
1587 # opt=$1; shift
1588 # case $opt in
1589 # --silent|-s) opt_silent=: ;;
1590 # # Separate non-argument short options:
1591 # -s*) func_split_short_opt "$_G_opt"
1592 # set dummy "$func_split_short_opt_name" \
1593 # "-$func_split_short_opt_arg" ${1+"$@"}
1594 # shift
1595 # ;;
1596 # *) set dummy "$_G_opt" "$*"; shift; break ;;
1597 # esac
1598 # done
1599 #
1600 # func_quote_for_eval ${1+"$@"}
1601 # my_silent_option_result=$func_quote_for_eval_result
1602 # }
1603 # func_add_hook func_parse_options my_silent_option
1604 #
1605 #
1606 # my_option_validation ()
1607 # {
1608 # $debug_cmd
1609 #
1610 # $opt_silent && $opt_verbose && func_fatal_help "\
1611 # '--silent' and '--verbose' options are mutually exclusive."
1612 #
1613 # func_quote_for_eval ${1+"$@"}
1614 # my_option_validation_result=$func_quote_for_eval_result
1615 # }
1616 # func_add_hook func_validate_options my_option_validation
1617 #
1618 # You'll alse need to manually amend $usage_message to reflect the extra
1619 # options you parse. It's preferable to append if you can, so that
1620 # multiple option parsing hooks can be added safely.
1621
1622
1623 # func_options [ARG]...
1624 # ---------------------
1625 # All the functions called inside func_options are hookable. See the
1626 # individual implementations for details.
1627 func_hookable func_options
1628 func_options ()
1629 {
1630 $debug_cmd
1631
1632 func_options_prep ${1+"$@"}
1633 eval func_parse_options \
1634 ${func_options_prep_result+"$func_options_prep_result"}
1635 eval func_validate_options \
1636 ${func_parse_options_result+"$func_parse_options_result"}
1637
1638 eval func_run_hooks func_options \
1639 ${func_validate_options_result+"$func_validate_options_result"}
1640
1641 # save modified positional parameters for caller
1642 func_options_result=$func_run_hooks_result
1643 }
1644
1645
1646 # func_options_prep [ARG]...
1647 # --------------------------
1648 # All initialisations required before starting the option parse loop.
1649 # Note that when calling hook functions, we pass through the list of
1650 # positional parameters. If a hook function modifies that list, and
1651 # needs to propogate that back to rest of this script, then the complete
1652 # modified list must be put in 'func_run_hooks_result' before
1653 # returning.
1654 func_hookable func_options_prep
1655 func_options_prep ()
1656 {
1657 $debug_cmd
1658
1659 # Option defaults:
1660 opt_verbose=false
1661 opt_warning_types=
1662
1663 func_run_hooks func_options_prep ${1+"$@"}
1664
1665 # save modified positional parameters for caller
1666 func_options_prep_result=$func_run_hooks_result
1667 }
1668
1669
1670 # func_parse_options [ARG]...
1671 # ---------------------------
1672 # The main option parsing loop.
1673 func_hookable func_parse_options
1674 func_parse_options ()
1675 {
1676 $debug_cmd
1677
1678 func_parse_options_result=
1679
1680 # this just eases exit handling
1681 while test $# -gt 0; do
1682 # Defer to hook functions for initial option parsing, so they
1683 # get priority in the event of reusing an option name.
1684 func_run_hooks func_parse_options ${1+"$@"}
1685
1686 # Adjust func_parse_options positional parameters to match
1687 eval set dummy "$func_run_hooks_result"; shift
1688
1689 # Break out of the loop if we already parsed every option.
1690 test $# -gt 0 || break
1691
1692 _G_opt=$1
1693 shift
1694 case $_G_opt in
1695 --debug|-x) debug_cmd='set -x'
1696 func_echo "enabling shell trace mode"
1697 $debug_cmd
1698 ;;
1699
1700 --no-warnings|--no-warning|--no-warn)
1701 set dummy --warnings none ${1+"$@"}
1702 shift
1703 ;;
1704
1705 --warnings|--warning|-W)
1706 test $# = 0 && func_missing_arg $_G_opt && break
1707 case " $warning_categories $1" in
1708 *" $1 "*)
1709 # trailing space prevents matching last $1 above
1710 func_append_uniq opt_warning_types " $1"
1711 ;;
1712 *all)
1713 opt_warning_types=$warning_categories
1714 ;;
1715 *none)
1716 opt_warning_types=none
1717 warning_func=:
1718 ;;
1719 *error)
1720 opt_warning_types=$warning_categories
1721 warning_func=func_fatal_error
1722 ;;
1723 *)
1724 func_fatal_error \
1725 "unsupported warning category: '$1'"
1726 ;;
1727 esac
1728 shift
1729 ;;
1730
1731 --verbose|-v) opt_verbose=: ;;
1732 --version) func_version ;;
1733 -\?|-h) func_usage ;;
1734 --help) func_help ;;
1735
1736 # Separate optargs to long options (plugins may need this):
1737 --*=*) func_split_equals "$_G_opt"
1738 set dummy "$func_split_equals_lhs" \
1739 "$func_split_equals_rhs" ${1+"$@"}
1740 shift
1741 ;;
1742
1743 # Separate optargs to short options:
1744 -W*)
1745 func_split_short_opt "$_G_opt"
1746 set dummy "$func_split_short_opt_name" \
1747 "$func_split_short_opt_arg" ${1+"$@"}
1748 shift
1749 ;;
1750
1751 # Separate non-argument short options:
1752 -\?*|-h*|-v*|-x*)
1753 func_split_short_opt "$_G_opt"
1754 set dummy "$func_split_short_opt_name" \
1755 "-$func_split_short_opt_arg" ${1+"$@"}
1756 shift
1757 ;;
1758
1759 --) break ;;
1760 -*) func_fatal_help "unrecognised option: '$_G_opt'" ;;
1761 *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;;
1762 esac
1763 done
1764
1765 # save modified positional parameters for caller
1766 func_quote_for_eval ${1+"$@"}
1767 func_parse_options_result=$func_quote_for_eval_result
1768 }
1769
1770
1771 # func_validate_options [ARG]...
1772 # ------------------------------
1773 # Perform any sanity checks on option settings and/or unconsumed
1774 # arguments.
1775 func_hookable func_validate_options
1776 func_validate_options ()
1777 {
1778 $debug_cmd
1779
1780 # Display all warnings if -W was not given.
1781 test -n "$opt_warning_types" || opt_warning_types=" $warning_categories"
1782
1783 func_run_hooks func_validate_options ${1+"$@"}
1784
1785 # Bail if the options were screwed!
1786 $exit_cmd $EXIT_FAILURE
1787
1788 # save modified positional parameters for caller
1789 func_validate_options_result=$func_run_hooks_result
1790 }
1791
1792
1793
1794 ## ----------------- ##
1795 ## Helper functions. ##
1796 ## ----------------- ##
1797
1798 # This section contains the helper functions used by the rest of the
1799 # hookable option parser framework in ascii-betical order.
1800
1801
1802 # func_fatal_help ARG...
1803 # ----------------------
1804 # Echo program name prefixed message to standard error, followed by
1805 # a help hint, and exit.
1806 func_fatal_help ()
1807 {
1808 $debug_cmd
1809
1810 eval \$ECHO \""Usage: $usage"\"
1811 eval \$ECHO \""$fatal_help"\"
1812 func_error ${1+"$@"}
1813 exit $EXIT_FAILURE
1814 }
1815
1816
1817 # func_help
1818 # ---------
1819 # Echo long help message to standard output and exit.
7541820 func_help ()
7551821 {
756 $opt_debug
757
758 $SED -n '/^# Usage:/,/# Report bugs to/ {
759 :print
760 s/^# //
761 s/^# *$//
762 s*\$progname*'$progname'*
763 s*\$host*'"$host"'*
764 s*\$SHELL*'"$SHELL"'*
765 s*\$LTCC*'"$LTCC"'*
766 s*\$LTCFLAGS*'"$LTCFLAGS"'*
767 s*\$LD*'"$LD"'*
768 s/\$with_gnu_ld/'"$with_gnu_ld"'/
769 s/\$automake_version/'"`(${AUTOMAKE-automake} --version) 2>/dev/null |$SED 1q`"'/
770 s/\$autoconf_version/'"`(${AUTOCONF-autoconf} --version) 2>/dev/null |$SED 1q`"'/
771 p
772 d
773 }
774 /^# .* home page:/b print
775 /^# General help using/b print
776 ' < "$progpath"
777 ret=$?
778 if test -z "$1"; then
779 exit $ret
780 fi
781 }
782
783 # func_missing_arg argname
1822 $debug_cmd
1823
1824 func_usage_message
1825 $ECHO "$long_help_message"
1826 exit 0
1827 }
1828
1829
1830 # func_missing_arg ARGNAME
1831 # ------------------------
7841832 # Echo program name prefixed message to standard error and set global
7851833 # exit_cmd.
7861834 func_missing_arg ()
7871835 {
788 $opt_debug
789
790 func_error "missing argument for $1."
1836 $debug_cmd
1837
1838 func_error "Missing argument for '$1'."
7911839 exit_cmd=exit
7921840 }
7931841
7941842
795 # func_split_short_opt shortopt
1843 # func_split_equals STRING
1844 # ------------------------
1845 # Set func_split_equals_lhs and func_split_equals_rhs shell variables after
1846 # splitting STRING at the '=' sign.
1847 test -z "$_G_HAVE_XSI_OPS" \
1848 && (eval 'x=a/b/c;
1849 test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \
1850 && _G_HAVE_XSI_OPS=yes
1851
1852 if test yes = "$_G_HAVE_XSI_OPS"
1853 then
1854 # This is an XSI compatible shell, allowing a faster implementation...
1855 eval 'func_split_equals ()
1856 {
1857 $debug_cmd
1858
1859 func_split_equals_lhs=${1%%=*}
1860 func_split_equals_rhs=${1#*=}
1861 test "x$func_split_equals_lhs" = "x$1" \
1862 && func_split_equals_rhs=
1863 }'
1864 else
1865 # ...otherwise fall back to using expr, which is often a shell builtin.
1866 func_split_equals ()
1867 {
1868 $debug_cmd
1869
1870 func_split_equals_lhs=`expr "x$1" : 'x\([^=]*\)'`
1871 func_split_equals_rhs=
1872 test "x$func_split_equals_lhs" = "x$1" \
1873 || func_split_equals_rhs=`expr "x$1" : 'x[^=]*=\(.*\)$'`
1874 }
1875 fi #func_split_equals
1876
1877
1878 # func_split_short_opt SHORTOPT
1879 # -----------------------------
7961880 # Set func_split_short_opt_name and func_split_short_opt_arg shell
7971881 # variables after splitting SHORTOPT after the 2nd character.
798 func_split_short_opt ()
799 {
800 my_sed_short_opt='1s/^\(..\).*$/\1/;q'
801 my_sed_short_rest='1s/^..\(.*\)$/\1/;q'
802
803 func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"`
804 func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"`
805 } # func_split_short_opt may be replaced by extended shell implementation
806
807
808 # func_split_long_opt longopt
809 # Set func_split_long_opt_name and func_split_long_opt_arg shell
810 # variables after splitting LONGOPT at the `=' sign.
811 func_split_long_opt ()
812 {
813 my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q'
814 my_sed_long_arg='1s/^--[^=]*=//'
815
816 func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"`
817 func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"`
818 } # func_split_long_opt may be replaced by extended shell implementation
819
820 exit_cmd=:
821
822
823
824
825
826 magic="%%%MAGIC variable%%%"
827 magic_exe="%%%MAGIC EXE variable%%%"
828
829 # Global variables.
830 nonopt=
831 preserve_args=
832 lo2o="s/\\.lo\$/.${objext}/"
833 o2lo="s/\\.${objext}\$/.lo/"
834 extracted_archives=
835 extracted_serial=0
836
837 # If this variable is set in any of the actions, the command in it
838 # will be execed at the end. This prevents here-documents from being
839 # left over by shells.
840 exec_cmd=
841
842 # func_append var value
843 # Append VALUE to the end of shell variable VAR.
844 func_append ()
845 {
846 eval "${1}=\$${1}\${2}"
847 } # func_append may be replaced by extended shell implementation
848
849 # func_append_quoted var value
850 # Quote VALUE and append to the end of shell variable VAR, separated
851 # by a space.
852 func_append_quoted ()
853 {
854 func_quote_for_eval "${2}"
855 eval "${1}=\$${1}\\ \$func_quote_for_eval_result"
856 } # func_append_quoted may be replaced by extended shell implementation
857
858
859 # func_arith arithmetic-term...
860 func_arith ()
861 {
862 func_arith_result=`expr "${@}"`
863 } # func_arith may be replaced by extended shell implementation
864
865
866 # func_len string
867 # STRING may not start with a hyphen.
868 func_len ()
869 {
870 func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len`
871 } # func_len may be replaced by extended shell implementation
872
873
874 # func_lo2o object
875 func_lo2o ()
876 {
877 func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
878 } # func_lo2o may be replaced by extended shell implementation
879
880
881 # func_xform libobj-or-source
882 func_xform ()
883 {
884 func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
885 } # func_xform may be replaced by extended shell implementation
886
887
888 # func_fatal_configuration arg...
1882 if test yes = "$_G_HAVE_XSI_OPS"
1883 then
1884 # This is an XSI compatible shell, allowing a faster implementation...
1885 eval 'func_split_short_opt ()
1886 {
1887 $debug_cmd
1888
1889 func_split_short_opt_arg=${1#??}
1890 func_split_short_opt_name=${1%"$func_split_short_opt_arg"}
1891 }'
1892 else
1893 # ...otherwise fall back to using expr, which is often a shell builtin.
1894 func_split_short_opt ()
1895 {
1896 $debug_cmd
1897
1898 func_split_short_opt_name=`expr "x$1" : 'x-\(.\)'`
1899 func_split_short_opt_arg=`expr "x$1" : 'x-.\(.*\)$'`
1900 }
1901 fi #func_split_short_opt
1902
1903
1904 # func_usage
1905 # ----------
1906 # Echo short help message to standard output and exit.
1907 func_usage ()
1908 {
1909 $debug_cmd
1910
1911 func_usage_message
1912 $ECHO "Run '$progname --help |${PAGER-more}' for full usage"
1913 exit 0
1914 }
1915
1916
1917 # func_usage_message
1918 # ------------------
1919 # Echo short help message to standard output.
1920 func_usage_message ()
1921 {
1922 $debug_cmd
1923
1924 eval \$ECHO \""Usage: $usage"\"
1925 echo
1926 $SED -n 's|^# ||
1927 /^Written by/{
1928 x;p;x
1929 }
1930 h
1931 /^Written by/q' < "$progpath"
1932 echo
1933 eval \$ECHO \""$usage_message"\"
1934 }
1935
1936
1937 # func_version
1938 # ------------
1939 # Echo version message to standard output and exit.
1940 func_version ()
1941 {
1942 $debug_cmd
1943
1944 printf '%s\n' "$progname $scriptversion"
1945 $SED -n '
1946 /(C)/!b go
1947 :more
1948 /\./!{
1949 N
1950 s|\n# | |
1951 b more
1952 }
1953 :go
1954 /^# Written by /,/# warranty; / {
1955 s|^# ||
1956 s|^# *$||
1957 s|\((C)\)[ 0-9,-]*[ ,-]\([1-9][0-9]* \)|\1 \2|
1958 p
1959 }
1960 /^# Written by / {
1961 s|^# ||
1962 p
1963 }
1964 /^warranty; /q' < "$progpath"
1965
1966 exit $?
1967 }
1968
1969
1970 # Local variables:
1971 # mode: shell-script
1972 # sh-indentation: 2
1973 # eval: (add-hook 'before-save-hook 'time-stamp)
1974 # time-stamp-pattern: "10/scriptversion=%:y-%02m-%02d.%02H; # UTC"
1975 # time-stamp-time-zone: "UTC"
1976 # End:
1977
1978 # Set a version string.
1979 scriptversion='(GNU libtool) 2.4.6'
1980
1981
1982 # func_echo ARG...
1983 # ----------------
1984 # Libtool also displays the current mode in messages, so override
1985 # funclib.sh func_echo with this custom definition.
1986 func_echo ()
1987 {
1988 $debug_cmd
1989
1990 _G_message=$*
1991
1992 func_echo_IFS=$IFS
1993 IFS=$nl
1994 for _G_line in $_G_message; do
1995 IFS=$func_echo_IFS
1996 $ECHO "$progname${opt_mode+: $opt_mode}: $_G_line"
1997 done
1998 IFS=$func_echo_IFS
1999 }
2000
2001
2002 # func_warning ARG...
2003 # -------------------
2004 # Libtool warnings are not categorized, so override funclib.sh
2005 # func_warning with this simpler definition.
2006 func_warning ()
2007 {
2008 $debug_cmd
2009
2010 $warning_func ${1+"$@"}
2011 }
2012
2013
2014 ## ---------------- ##
2015 ## Options parsing. ##
2016 ## ---------------- ##
2017
2018 # Hook in the functions to make sure our own options are parsed during
2019 # the option parsing loop.
2020
2021 usage='$progpath [OPTION]... [MODE-ARG]...'
2022
2023 # Short help message in response to '-h'.
2024 usage_message="Options:
2025 --config show all configuration variables
2026 --debug enable verbose shell tracing
2027 -n, --dry-run display commands without modifying any files
2028 --features display basic configuration information and exit
2029 --mode=MODE use operation mode MODE
2030 --no-warnings equivalent to '-Wnone'
2031 --preserve-dup-deps don't remove duplicate dependency libraries
2032 --quiet, --silent don't print informational messages
2033 --tag=TAG use configuration variables from tag TAG
2034 -v, --verbose print more informational messages than default
2035 --version print version information
2036 -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all]
2037 -h, --help, --help-all print short, long, or detailed help message
2038 "
2039
2040 # Additional text appended to 'usage_message' in response to '--help'.
2041 func_help ()
2042 {
2043 $debug_cmd
2044
2045 func_usage_message
2046 $ECHO "$long_help_message
2047
2048 MODE must be one of the following:
2049
2050 clean remove files from the build directory
2051 compile compile a source file into a libtool object
2052 execute automatically set library path, then run a program
2053 finish complete the installation of libtool libraries
2054 install install libraries or executables
2055 link create a library or an executable
2056 uninstall remove libraries from an installed directory
2057
2058 MODE-ARGS vary depending on the MODE. When passed as first option,
2059 '--mode=MODE' may be abbreviated as 'MODE' or a unique abbreviation of that.
2060 Try '$progname --help --mode=MODE' for a more detailed description of MODE.
2061
2062 When reporting a bug, please describe a test case to reproduce it and
2063 include the following information:
2064
2065 host-triplet: $host
2066 shell: $SHELL
2067 compiler: $LTCC
2068 compiler flags: $LTCFLAGS
2069 linker: $LD (gnu? $with_gnu_ld)
2070 version: $progname (GNU libtool) 2.4.6
2071 automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q`
2072 autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q`
2073
2074 Report bugs to <bug-libtool@gnu.org>.
2075 GNU libtool home page: <http://www.gnu.org/software/libtool/>.
2076 General help using GNU software: <http://www.gnu.org/gethelp/>."
2077 exit 0
2078 }
2079
2080
2081 # func_lo2o OBJECT-NAME
2082 # ---------------------
2083 # Transform OBJECT-NAME from a '.lo' suffix to the platform specific
2084 # object suffix.
2085
2086 lo2o=s/\\.lo\$/.$objext/
2087 o2lo=s/\\.$objext\$/.lo/
2088
2089 if test yes = "$_G_HAVE_XSI_OPS"; then
2090 eval 'func_lo2o ()
2091 {
2092 case $1 in
2093 *.lo) func_lo2o_result=${1%.lo}.$objext ;;
2094 * ) func_lo2o_result=$1 ;;
2095 esac
2096 }'
2097
2098 # func_xform LIBOBJ-OR-SOURCE
2099 # ---------------------------
2100 # Transform LIBOBJ-OR-SOURCE from a '.o' or '.c' (or otherwise)
2101 # suffix to a '.lo' libtool-object suffix.
2102 eval 'func_xform ()
2103 {
2104 func_xform_result=${1%.*}.lo
2105 }'
2106 else
2107 # ...otherwise fall back to using sed.
2108 func_lo2o ()
2109 {
2110 func_lo2o_result=`$ECHO "$1" | $SED "$lo2o"`
2111 }
2112
2113 func_xform ()
2114 {
2115 func_xform_result=`$ECHO "$1" | $SED 's|\.[^.]*$|.lo|'`
2116 }
2117 fi
2118
2119
2120 # func_fatal_configuration ARG...
2121 # -------------------------------
8892122 # Echo program name prefixed message to standard error, followed by
8902123 # a configuration failure hint, and exit.
8912124 func_fatal_configuration ()
8922125 {
893 func_error ${1+"$@"}
894 func_error "See the $PACKAGE documentation for more information."
895 func_fatal_error "Fatal configuration error."
2126 func__fatal_error ${1+"$@"} \
2127 "See the $PACKAGE documentation for more information." \
2128 "Fatal configuration error."
8962129 }
8972130
8982131
8992132 # func_config
2133 # -----------
9002134 # Display the configuration for all the tags in this script.
9012135 func_config ()
9022136 {
9142148 exit $?
9152149 }
9162150
2151
9172152 # func_features
2153 # -------------
9182154 # Display the features supported by this script.
9192155 func_features ()
9202156 {
9212157 echo "host: $host"
922 if test "$build_libtool_libs" = yes; then
2158 if test yes = "$build_libtool_libs"; then
9232159 echo "enable shared libraries"
9242160 else
9252161 echo "disable shared libraries"
9262162 fi
927 if test "$build_old_libs" = yes; then
2163 if test yes = "$build_old_libs"; then
9282164 echo "enable static libraries"
9292165 else
9302166 echo "disable static libraries"
9332169 exit $?
9342170 }
9352171
936 # func_enable_tag tagname
2172
2173 # func_enable_tag TAGNAME
2174 # -----------------------
9372175 # Verify that TAGNAME is valid, and either flag an error and exit, or
9382176 # enable the TAGNAME tag. We also add TAGNAME to the global $taglist
9392177 # variable here.
9402178 func_enable_tag ()
9412179 {
942 # Global variable:
943 tagname="$1"
944
945 re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$"
946 re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$"
947 sed_extractcf="/$re_begincf/,/$re_endcf/p"
948
949 # Validate tagname.
950 case $tagname in
951 *[!-_A-Za-z0-9,/]*)
952 func_fatal_error "invalid tag name: $tagname"
953 ;;
954 esac
955
956 # Don't test for the "default" C tag, as we know it's
957 # there but not specially marked.
958 case $tagname in
959 CC) ;;
2180 # Global variable:
2181 tagname=$1
2182
2183 re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$"
2184 re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$"
2185 sed_extractcf=/$re_begincf/,/$re_endcf/p
2186
2187 # Validate tagname.
2188 case $tagname in
2189 *[!-_A-Za-z0-9,/]*)
2190 func_fatal_error "invalid tag name: $tagname"
2191 ;;
2192 esac
2193
2194 # Don't test for the "default" C tag, as we know it's
2195 # there but not specially marked.
2196 case $tagname in
2197 CC) ;;
9602198 *)
961 if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then
962 taglist="$taglist $tagname"
963
964 # Evaluate the configuration. Be careful to quote the path
965 # and the sed script, to avoid splitting on whitespace, but
966 # also don't use non-portable quotes within backquotes within
967 # quotes we have to do it in 2 steps:
968 extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"`
969 eval "$extractedcf"
970 else
971 func_error "ignoring unknown tag $tagname"
972 fi
973 ;;
974 esac
975 }
2199 if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then
2200 taglist="$taglist $tagname"
2201
2202 # Evaluate the configuration. Be careful to quote the path
2203 # and the sed script, to avoid splitting on whitespace, but
2204 # also don't use non-portable quotes within backquotes within
2205 # quotes we have to do it in 2 steps:
2206 extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"`
2207 eval "$extractedcf"
2208 else
2209 func_error "ignoring unknown tag $tagname"
2210 fi
2211 ;;
2212 esac
2213 }
2214
9762215
9772216 # func_check_version_match
2217 # ------------------------
9782218 # Ensure that we are using m4 macros, and libtool script from the same
9792219 # release of libtool.
9802220 func_check_version_match ()
9812221 {
982 if test "$package_revision" != "$macro_revision"; then
983 if test "$VERSION" != "$macro_version"; then
984 if test -z "$macro_version"; then
985 cat >&2 <<_LT_EOF
2222 if test "$package_revision" != "$macro_revision"; then
2223 if test "$VERSION" != "$macro_version"; then
2224 if test -z "$macro_version"; then
2225 cat >&2 <<_LT_EOF
9862226 $progname: Version mismatch error. This is $PACKAGE $VERSION, but the
9872227 $progname: definition of this LT_INIT comes from an older release.
9882228 $progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
9892229 $progname: and run autoconf again.
9902230 _LT_EOF
991 else
992 cat >&2 <<_LT_EOF
2231 else
2232 cat >&2 <<_LT_EOF
9932233 $progname: Version mismatch error. This is $PACKAGE $VERSION, but the
9942234 $progname: definition of this LT_INIT comes from $PACKAGE $macro_version.
9952235 $progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
9962236 $progname: and run autoconf again.
9972237 _LT_EOF
998 fi
999 else
1000 cat >&2 <<_LT_EOF
2238 fi
2239 else
2240 cat >&2 <<_LT_EOF
10012241 $progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision,
10022242 $progname: but the definition of this LT_INIT comes from revision $macro_revision.
10032243 $progname: You should recreate aclocal.m4 with macros from revision $package_revision
10042244 $progname: of $PACKAGE $VERSION and run autoconf again.
10052245 _LT_EOF
2246 fi
2247
2248 exit $EXIT_MISMATCH
10062249 fi
1007
1008 exit $EXIT_MISMATCH
1009 fi
1010 }
1011
1012
1013 # Shorthand for --mode=foo, only valid as the first argument
1014 case $1 in
1015 clean|clea|cle|cl)
1016 shift; set dummy --mode clean ${1+"$@"}; shift
1017 ;;
1018 compile|compil|compi|comp|com|co|c)
1019 shift; set dummy --mode compile ${1+"$@"}; shift
1020 ;;
1021 execute|execut|execu|exec|exe|ex|e)
1022 shift; set dummy --mode execute ${1+"$@"}; shift
1023 ;;
1024 finish|finis|fini|fin|fi|f)
1025 shift; set dummy --mode finish ${1+"$@"}; shift
1026 ;;
1027 install|instal|insta|inst|ins|in|i)
1028 shift; set dummy --mode install ${1+"$@"}; shift
1029 ;;
1030 link|lin|li|l)
1031 shift; set dummy --mode link ${1+"$@"}; shift
1032 ;;
1033 uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
1034 shift; set dummy --mode uninstall ${1+"$@"}; shift
1035 ;;
1036 esac
1037
1038
1039
1040 # Option defaults:
1041 opt_debug=:
1042 opt_dry_run=false
1043 opt_config=false
1044 opt_preserve_dup_deps=false
1045 opt_features=false
1046 opt_finish=false
1047 opt_help=false
1048 opt_help_all=false
1049 opt_silent=:
1050 opt_warning=:
1051 opt_verbose=:
1052 opt_silent=false
1053 opt_verbose=false
1054
1055
1056 # Parse options once, thoroughly. This comes as soon as possible in the
1057 # script to make things like `--version' happen as quickly as we can.
1058 {
1059 # this just eases exit handling
1060 while test $# -gt 0; do
1061 opt="$1"
1062 shift
1063 case $opt in
1064 --debug|-x) opt_debug='set -x'
1065 func_echo "enabling shell trace mode"
1066 $opt_debug
1067 ;;
1068 --dry-run|--dryrun|-n)
1069 opt_dry_run=:
1070 ;;
1071 --config)
1072 opt_config=:
1073 func_config
1074 ;;
1075 --dlopen|-dlopen)
1076 optarg="$1"
1077 opt_dlopen="${opt_dlopen+$opt_dlopen
1078 }$optarg"
1079 shift
1080 ;;
1081 --preserve-dup-deps)
1082 opt_preserve_dup_deps=:
1083 ;;
1084 --features)
1085 opt_features=:
1086 func_features
1087 ;;
1088 --finish)
1089 opt_finish=:
1090 set dummy --mode finish ${1+"$@"}; shift
1091 ;;
1092 --help)
1093 opt_help=:
1094 ;;
1095 --help-all)
1096 opt_help_all=:
1097 opt_help=': help-all'
1098 ;;
1099 --mode)
1100 test $# = 0 && func_missing_arg $opt && break
1101 optarg="$1"
1102 opt_mode="$optarg"
1103 case $optarg in
1104 # Valid mode arguments:
1105 clean|compile|execute|finish|install|link|relink|uninstall) ;;
1106
1107 # Catch anything else as an error
1108 *) func_error "invalid argument for $opt"
1109 exit_cmd=exit
1110 break
1111 ;;
1112 esac
1113 shift
1114 ;;
1115 --no-silent|--no-quiet)
1116 opt_silent=false
1117 func_append preserve_args " $opt"
1118 ;;
1119 --no-warning|--no-warn)
1120 opt_warning=false
1121 func_append preserve_args " $opt"
1122 ;;
1123 --no-verbose)
1124 opt_verbose=false
1125 func_append preserve_args " $opt"
1126 ;;
1127 --silent|--quiet)
1128 opt_silent=:
1129 func_append preserve_args " $opt"
1130 opt_verbose=false
1131 ;;
1132 --verbose|-v)
1133 opt_verbose=:
1134 func_append preserve_args " $opt"
1135 opt_silent=false
1136 ;;
1137 --tag)
1138 test $# = 0 && func_missing_arg $opt && break
1139 optarg="$1"
1140 opt_tag="$optarg"
1141 func_append preserve_args " $opt $optarg"
1142 func_enable_tag "$optarg"
1143 shift
1144 ;;
1145
1146 -\?|-h) func_usage ;;
1147 --help) func_help ;;
1148 --version) func_version ;;
1149
1150 # Separate optargs to long options:
1151 --*=*)
1152 func_split_long_opt "$opt"
1153 set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"}
1154 shift
1155 ;;
1156
1157 # Separate non-argument short options:
1158 -\?*|-h*|-n*|-v*)
1159 func_split_short_opt "$opt"
1160 set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"}
1161 shift
1162 ;;
1163
1164 --) break ;;
1165 -*) func_fatal_help "unrecognized option \`$opt'" ;;
1166 *) set dummy "$opt" ${1+"$@"}; shift; break ;;
2250 }
2251
2252
2253 # libtool_options_prep [ARG]...
2254 # -----------------------------
2255 # Preparation for options parsed by libtool.
2256 libtool_options_prep ()
2257 {
2258 $debug_mode
2259
2260 # Option defaults:
2261 opt_config=false
2262 opt_dlopen=
2263 opt_dry_run=false
2264 opt_help=false
2265 opt_mode=
2266 opt_preserve_dup_deps=false
2267 opt_quiet=false
2268
2269 nonopt=
2270 preserve_args=
2271
2272 # Shorthand for --mode=foo, only valid as the first argument
2273 case $1 in
2274 clean|clea|cle|cl)
2275 shift; set dummy --mode clean ${1+"$@"}; shift
2276 ;;
2277 compile|compil|compi|comp|com|co|c)
2278 shift; set dummy --mode compile ${1+"$@"}; shift
2279 ;;
2280 execute|execut|execu|exec|exe|ex|e)
2281 shift; set dummy --mode execute ${1+"$@"}; shift
2282 ;;
2283 finish|finis|fini|fin|fi|f)
2284 shift; set dummy --mode finish ${1+"$@"}; shift
2285 ;;
2286 install|instal|insta|inst|ins|in|i)
2287 shift; set dummy --mode install ${1+"$@"}; shift
2288 ;;
2289 link|lin|li|l)
2290 shift; set dummy --mode link ${1+"$@"}; shift
2291 ;;
2292 uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
2293 shift; set dummy --mode uninstall ${1+"$@"}; shift
2294 ;;
11672295 esac
1168 done
1169
1170 # Validate options:
1171
1172 # save first non-option argument
1173 if test "$#" -gt 0; then
1174 nonopt="$opt"
1175 shift
1176 fi
1177
1178 # preserve --debug
1179 test "$opt_debug" = : || func_append preserve_args " --debug"
1180
1181 case $host in
1182 *cygwin* | *mingw* | *pw32* | *cegcc*)
1183 # don't eliminate duplications in $postdeps and $predeps
1184 opt_duplicate_compiler_generated_deps=:
1185 ;;
1186 *)
1187 opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps
1188 ;;
1189 esac
1190
1191 $opt_help || {
1192 # Sanity checks first:
1193 func_check_version_match
1194
1195 if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then
1196 func_fatal_configuration "not configured to build any kind of library"
2296
2297 # Pass back the list of options.
2298 func_quote_for_eval ${1+"$@"}
2299 libtool_options_prep_result=$func_quote_for_eval_result
2300 }
2301 func_add_hook func_options_prep libtool_options_prep
2302
2303
2304 # libtool_parse_options [ARG]...
2305 # ---------------------------------
2306 # Provide handling for libtool specific options.
2307 libtool_parse_options ()
2308 {
2309 $debug_cmd
2310
2311 # Perform our own loop to consume as many options as possible in
2312 # each iteration.
2313 while test $# -gt 0; do
2314 _G_opt=$1
2315 shift
2316 case $_G_opt in
2317 --dry-run|--dryrun|-n)
2318 opt_dry_run=:
2319 ;;
2320
2321 --config) func_config ;;
2322
2323 --dlopen|-dlopen)
2324 opt_dlopen="${opt_dlopen+$opt_dlopen
2325 }$1"
2326 shift
2327 ;;
2328
2329 --preserve-dup-deps)
2330 opt_preserve_dup_deps=: ;;
2331
2332 --features) func_features ;;
2333
2334 --finish) set dummy --mode finish ${1+"$@"}; shift ;;
2335
2336 --help) opt_help=: ;;
2337
2338 --help-all) opt_help=': help-all' ;;
2339
2340 --mode) test $# = 0 && func_missing_arg $_G_opt && break
2341 opt_mode=$1
2342 case $1 in
2343 # Valid mode arguments:
2344 clean|compile|execute|finish|install|link|relink|uninstall) ;;
2345
2346 # Catch anything else as an error
2347 *) func_error "invalid argument for $_G_opt"
2348 exit_cmd=exit
2349 break
2350 ;;
2351 esac
2352 shift
2353 ;;
2354
2355 --no-silent|--no-quiet)
2356 opt_quiet=false
2357 func_append preserve_args " $_G_opt"
2358 ;;
2359
2360 --no-warnings|--no-warning|--no-warn)
2361 opt_warning=false
2362 func_append preserve_args " $_G_opt"
2363 ;;
2364
2365 --no-verbose)
2366 opt_verbose=false
2367 func_append preserve_args " $_G_opt"
2368 ;;
2369
2370 --silent|--quiet)
2371 opt_quiet=:
2372 opt_verbose=false
2373 func_append preserve_args " $_G_opt"
2374 ;;
2375
2376 --tag) test $# = 0 && func_missing_arg $_G_opt && break
2377 opt_tag=$1
2378 func_append preserve_args " $_G_opt $1"
2379 func_enable_tag "$1"
2380 shift
2381 ;;
2382
2383 --verbose|-v) opt_quiet=false
2384 opt_verbose=:
2385 func_append preserve_args " $_G_opt"
2386 ;;
2387
2388 # An option not handled by this hook function:
2389 *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;;
2390 esac
2391 done
2392
2393
2394 # save modified positional parameters for caller
2395 func_quote_for_eval ${1+"$@"}
2396 libtool_parse_options_result=$func_quote_for_eval_result
2397 }
2398 func_add_hook func_parse_options libtool_parse_options
2399
2400
2401
2402 # libtool_validate_options [ARG]...
2403 # ---------------------------------
2404 # Perform any sanity checks on option settings and/or unconsumed
2405 # arguments.
2406 libtool_validate_options ()
2407 {
2408 # save first non-option argument
2409 if test 0 -lt $#; then
2410 nonopt=$1
2411 shift
11972412 fi
11982413
1199 # Darwin sucks
1200 eval std_shrext=\"$shrext_cmds\"
1201
1202 # Only execute mode is allowed to have -dlopen flags.
1203 if test -n "$opt_dlopen" && test "$opt_mode" != execute; then
1204 func_error "unrecognized option \`-dlopen'"
1205 $ECHO "$help" 1>&2
1206 exit $EXIT_FAILURE
1207 fi
1208
1209 # Change the help message to a mode-specific one.
1210 generic_help="$help"
1211 help="Try \`$progname --help --mode=$opt_mode' for more information."
1212 }
1213
1214
1215 # Bail if the options were screwed
1216 $exit_cmd $EXIT_FAILURE
1217 }
1218
2414 # preserve --debug
2415 test : = "$debug_cmd" || func_append preserve_args " --debug"
2416
2417 case $host in
2418 # Solaris2 added to fix http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16452
2419 # see also: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59788
2420 *cygwin* | *mingw* | *pw32* | *cegcc* | *solaris2* | *os2*)
2421 # don't eliminate duplications in $postdeps and $predeps
2422 opt_duplicate_compiler_generated_deps=:
2423 ;;
2424 *)
2425 opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps
2426 ;;
2427 esac
2428
2429 $opt_help || {
2430 # Sanity checks first:
2431 func_check_version_match
2432
2433 test yes != "$build_libtool_libs" \
2434 && test yes != "$build_old_libs" \
2435 && func_fatal_configuration "not configured to build any kind of library"
2436
2437 # Darwin sucks
2438 eval std_shrext=\"$shrext_cmds\"
2439
2440 # Only execute mode is allowed to have -dlopen flags.
2441 if test -n "$opt_dlopen" && test execute != "$opt_mode"; then
2442 func_error "unrecognized option '-dlopen'"
2443 $ECHO "$help" 1>&2
2444 exit $EXIT_FAILURE
2445 fi
2446
2447 # Change the help message to a mode-specific one.
2448 generic_help=$help
2449 help="Try '$progname --help --mode=$opt_mode' for more information."
2450 }
2451
2452 # Pass back the unparsed argument list
2453 func_quote_for_eval ${1+"$@"}
2454 libtool_validate_options_result=$func_quote_for_eval_result
2455 }
2456 func_add_hook func_validate_options libtool_validate_options
2457
2458
2459 # Process options as early as possible so that --help and --version
2460 # can return quickly.
2461 func_options ${1+"$@"}
2462 eval set dummy "$func_options_result"; shift
12192463
12202464
12212465
12232467 ## Main. ##
12242468 ## ----------- ##
12252469
2470 magic='%%%MAGIC variable%%%'
2471 magic_exe='%%%MAGIC EXE variable%%%'
2472
2473 # Global variables.
2474 extracted_archives=
2475 extracted_serial=0
2476
2477 # If this variable is set in any of the actions, the command in it
2478 # will be execed at the end. This prevents here-documents from being
2479 # left over by shells.
2480 exec_cmd=
2481
2482
2483 # A function that is used when there is no print builtin or printf.
2484 func_fallback_echo ()
2485 {
2486 eval 'cat <<_LTECHO_EOF
2487 $1
2488 _LTECHO_EOF'
2489 }
2490
2491 # func_generated_by_libtool
2492 # True iff stdin has been generated by Libtool. This function is only
2493 # a basic sanity check; it will hardly flush out determined imposters.
2494 func_generated_by_libtool_p ()
2495 {
2496 $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1
2497 }
2498
12262499 # func_lalib_p file
1227 # True iff FILE is a libtool `.la' library or `.lo' object file.
2500 # True iff FILE is a libtool '.la' library or '.lo' object file.
12282501 # This function is only a basic sanity check; it will hardly flush out
12292502 # determined imposters.
12302503 func_lalib_p ()
12312504 {
12322505 test -f "$1" &&
1233 $SED -e 4q "$1" 2>/dev/null \
1234 | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1
2506 $SED -e 4q "$1" 2>/dev/null | func_generated_by_libtool_p
12352507 }
12362508
12372509 # func_lalib_unsafe_p file
1238 # True iff FILE is a libtool `.la' library or `.lo' object file.
2510 # True iff FILE is a libtool '.la' library or '.lo' object file.
12392511 # This function implements the same check as func_lalib_p without
12402512 # resorting to external programs. To this end, it redirects stdin and
12412513 # closes it afterwards, without saving the original file descriptor.
12422514 # As a safety measure, use it only where a negative result would be
1243 # fatal anyway. Works if `file' does not exist.
2515 # fatal anyway. Works if 'file' does not exist.
12442516 func_lalib_unsafe_p ()
12452517 {
12462518 lalib_p=no
12482520 for lalib_p_l in 1 2 3 4
12492521 do
12502522 read lalib_p_line
1251 case "$lalib_p_line" in
2523 case $lalib_p_line in
12522524 \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;;
12532525 esac
12542526 done
12552527 exec 0<&5 5<&-
12562528 fi
1257 test "$lalib_p" = yes
2529 test yes = "$lalib_p"
12582530 }
12592531
12602532 # func_ltwrapper_script_p file
12632535 # determined imposters.
12642536 func_ltwrapper_script_p ()
12652537 {
1266 func_lalib_p "$1"
2538 test -f "$1" &&
2539 $lt_truncate_bin < "$1" 2>/dev/null | func_generated_by_libtool_p
12672540 }
12682541
12692542 # func_ltwrapper_executable_p file
12882561 {
12892562 func_dirname_and_basename "$1" "" "."
12902563 func_stripname '' '.exe' "$func_basename_result"
1291 func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper"
2564 func_ltwrapper_scriptname_result=$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper
12922565 }
12932566
12942567 # func_ltwrapper_p file
13072580 # FAIL_CMD may read-access the current command in variable CMD!
13082581 func_execute_cmds ()
13092582 {
1310 $opt_debug
2583 $debug_cmd
2584
13112585 save_ifs=$IFS; IFS='~'
13122586 for cmd in $1; do
2587 IFS=$sp$nl
2588 eval cmd=\"$cmd\"
13132589 IFS=$save_ifs
1314 eval cmd=\"$cmd\"
13152590 func_show_eval "$cmd" "${2-:}"
13162591 done
13172592 IFS=$save_ifs
13232598 # Note that it is not necessary on cygwin/mingw to append a dot to
13242599 # FILE even if both FILE and FILE.exe exist: automatic-append-.exe
13252600 # behavior happens only for exec(3), not for open(2)! Also, sourcing
1326 # `FILE.' does not work on cygwin managed mounts.
2601 # 'FILE.' does not work on cygwin managed mounts.
13272602 func_source ()
13282603 {
1329 $opt_debug
2604 $debug_cmd
2605
13302606 case $1 in
13312607 */* | *\\*) . "$1" ;;
13322608 *) . "./$1" ;;
13532629 # store the result into func_replace_sysroot_result.
13542630 func_replace_sysroot ()
13552631 {
1356 case "$lt_sysroot:$1" in
2632 case $lt_sysroot:$1 in
13572633 ?*:"$lt_sysroot"*)
13582634 func_stripname "$lt_sysroot" '' "$1"
1359 func_replace_sysroot_result="=$func_stripname_result"
2635 func_replace_sysroot_result='='$func_stripname_result
13602636 ;;
13612637 *)
13622638 # Including no sysroot.
13732649 # arg is usually of the form 'gcc ...'
13742650 func_infer_tag ()
13752651 {
1376 $opt_debug
2652 $debug_cmd
2653
13772654 if test -n "$available_tags" && test -z "$tagname"; then
13782655 CC_quoted=
13792656 for arg in $CC; do
13922669 for z in $available_tags; do
13932670 if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then
13942671 # Evaluate the configuration.
1395 eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`"
2672 eval "`$SED -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`"
13962673 CC_quoted=
13972674 for arg in $CC; do
13982675 # Double-quote args containing other shell metacharacters.
14172694 # line option must be used.
14182695 if test -z "$tagname"; then
14192696 func_echo "unable to infer tagged configuration"
1420 func_fatal_error "specify a tag with \`--tag'"
2697 func_fatal_error "specify a tag with '--tag'"
14212698 # else
14222699 # func_verbose "using $tagname tagged configuration"
14232700 fi
14332710 # but don't create it if we're doing a dry run.
14342711 func_write_libtool_object ()
14352712 {
1436 write_libobj=${1}
1437 if test "$build_libtool_libs" = yes; then
1438 write_lobj=\'${2}\'
2713 write_libobj=$1
2714 if test yes = "$build_libtool_libs"; then
2715 write_lobj=\'$2\'
14392716 else
14402717 write_lobj=none
14412718 fi
14422719
1443 if test "$build_old_libs" = yes; then
1444 write_oldobj=\'${3}\'
2720 if test yes = "$build_old_libs"; then
2721 write_oldobj=\'$3\'
14452722 else
14462723 write_oldobj=none
14472724 fi
14492726 $opt_dry_run || {
14502727 cat >${write_libobj}T <<EOF
14512728 # $write_libobj - a libtool object file
1452 # Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
2729 # Generated by $PROGRAM (GNU $PACKAGE) $VERSION
14532730 #
14542731 # Please DO NOT delete this file!
14552732 # It is necessary for linking the library.
14612738 non_pic_object=$write_oldobj
14622739
14632740 EOF
1464 $MV "${write_libobj}T" "${write_libobj}"
2741 $MV "${write_libobj}T" "$write_libobj"
14652742 }
14662743 }
14672744
14812758 # be empty on error (or when ARG is empty)
14822759 func_convert_core_file_wine_to_w32 ()
14832760 {
1484 $opt_debug
1485 func_convert_core_file_wine_to_w32_result="$1"
2761 $debug_cmd
2762
2763 func_convert_core_file_wine_to_w32_result=$1
14862764 if test -n "$1"; then
14872765 # Unfortunately, winepath does not exit with a non-zero error code, so we
14882766 # are forced to check the contents of stdout. On the other hand, if the
14902768 # *an error message* to stdout. So we must check for both error code of
14912769 # zero AND non-empty stdout, which explains the odd construction:
14922770 func_convert_core_file_wine_to_w32_tmp=`winepath -w "$1" 2>/dev/null`
1493 if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then
2771 if test "$?" -eq 0 && test -n "$func_convert_core_file_wine_to_w32_tmp"; then
14942772 func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" |
1495 $SED -e "$lt_sed_naive_backslashify"`
2773 $SED -e "$sed_naive_backslashify"`
14962774 else
14972775 func_convert_core_file_wine_to_w32_result=
14982776 fi
15132791 # are convertible, then the result may be empty.
15142792 func_convert_core_path_wine_to_w32 ()
15152793 {
1516 $opt_debug
2794 $debug_cmd
2795
15172796 # unfortunately, winepath doesn't convert paths, only file names
1518 func_convert_core_path_wine_to_w32_result=""
2797 func_convert_core_path_wine_to_w32_result=
15192798 if test -n "$1"; then
15202799 oldIFS=$IFS
15212800 IFS=:
15222801 for func_convert_core_path_wine_to_w32_f in $1; do
15232802 IFS=$oldIFS
15242803 func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f"
1525 if test -n "$func_convert_core_file_wine_to_w32_result" ; then
2804 if test -n "$func_convert_core_file_wine_to_w32_result"; then
15262805 if test -z "$func_convert_core_path_wine_to_w32_result"; then
1527 func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result"
2806 func_convert_core_path_wine_to_w32_result=$func_convert_core_file_wine_to_w32_result
15282807 else
15292808 func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result"
15302809 fi
15532832 # environment variable; do not put it in $PATH.
15542833 func_cygpath ()
15552834 {
1556 $opt_debug
2835 $debug_cmd
2836
15572837 if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then
15582838 func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null`
15592839 if test "$?" -ne 0; then
15622842 fi
15632843 else
15642844 func_cygpath_result=
1565 func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'"
2845 func_error "LT_CYGPATH is empty or specifies non-existent file: '$LT_CYGPATH'"
15662846 fi
15672847 }
15682848 #end: func_cygpath
15732853 # result in func_convert_core_msys_to_w32_result.
15742854 func_convert_core_msys_to_w32 ()
15752855 {
1576 $opt_debug
2856 $debug_cmd
2857
15772858 # awkward: cmd appends spaces to result
15782859 func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null |
1579 $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"`
2860 $SED -e 's/[ ]*$//' -e "$sed_naive_backslashify"`
15802861 }
15812862 #end: func_convert_core_msys_to_w32
15822863
15872868 # func_to_host_file_result to ARG1).
15882869 func_convert_file_check ()
15892870 {
1590 $opt_debug
1591 if test -z "$2" && test -n "$1" ; then
2871 $debug_cmd
2872
2873 if test -z "$2" && test -n "$1"; then
15922874 func_error "Could not determine host file name corresponding to"
1593 func_error " \`$1'"
2875 func_error " '$1'"
15942876 func_error "Continuing, but uninstalled executables may not work."
15952877 # Fallback:
1596 func_to_host_file_result="$1"
2878 func_to_host_file_result=$1
15972879 fi
15982880 }
15992881 # end func_convert_file_check
16052887 # func_to_host_file_result to a simplistic fallback value (see below).
16062888 func_convert_path_check ()
16072889 {
1608 $opt_debug
2890 $debug_cmd
2891
16092892 if test -z "$4" && test -n "$3"; then
16102893 func_error "Could not determine the host path corresponding to"
1611 func_error " \`$3'"
2894 func_error " '$3'"
16122895 func_error "Continuing, but uninstalled executables may not work."
16132896 # Fallback. This is a deliberately simplistic "conversion" and
16142897 # should not be "improved". See libtool.info.
16172900 func_to_host_path_result=`echo "$3" |
16182901 $SED -e "$lt_replace_pathsep_chars"`
16192902 else
1620 func_to_host_path_result="$3"
2903 func_to_host_path_result=$3
16212904 fi
16222905 fi
16232906 }
16292912 # and appending REPL if ORIG matches BACKPAT.
16302913 func_convert_path_front_back_pathsep ()
16312914 {
1632 $opt_debug
2915 $debug_cmd
2916
16332917 case $4 in
1634 $1 ) func_to_host_path_result="$3$func_to_host_path_result"
2918 $1 ) func_to_host_path_result=$3$func_to_host_path_result
16352919 ;;
16362920 esac
16372921 case $4 in
16452929 ##################################################
16462930 # $build to $host FILE NAME CONVERSION FUNCTIONS #
16472931 ##################################################
1648 # invoked via `$to_host_file_cmd ARG'
2932 # invoked via '$to_host_file_cmd ARG'
16492933 #
16502934 # In each case, ARG is the path to be converted from $build to $host format.
16512935 # Result will be available in $func_to_host_file_result.
16562940 # in func_to_host_file_result.
16572941 func_to_host_file ()
16582942 {
1659 $opt_debug
2943 $debug_cmd
2944
16602945 $to_host_file_cmd "$1"
16612946 }
16622947 # end func_to_host_file
16682953 # in (the comma separated) LAZY, no conversion takes place.
16692954 func_to_tool_file ()
16702955 {
1671 $opt_debug
2956 $debug_cmd
2957
16722958 case ,$2, in
16732959 *,"$to_tool_file_cmd",*)
16742960 func_to_tool_file_result=$1
16862972 # Copy ARG to func_to_host_file_result.
16872973 func_convert_file_noop ()
16882974 {
1689 func_to_host_file_result="$1"
2975 func_to_host_file_result=$1
16902976 }
16912977 # end func_convert_file_noop
16922978
16972983 # func_to_host_file_result.
16982984 func_convert_file_msys_to_w32 ()
16992985 {
1700 $opt_debug
1701 func_to_host_file_result="$1"
2986 $debug_cmd
2987
2988 func_to_host_file_result=$1
17022989 if test -n "$1"; then
17032990 func_convert_core_msys_to_w32 "$1"
1704 func_to_host_file_result="$func_convert_core_msys_to_w32_result"
2991 func_to_host_file_result=$func_convert_core_msys_to_w32_result
17052992 fi
17062993 func_convert_file_check "$1" "$func_to_host_file_result"
17072994 }
17133000 # func_to_host_file_result.
17143001 func_convert_file_cygwin_to_w32 ()
17153002 {
1716 $opt_debug
1717 func_to_host_file_result="$1"
3003 $debug_cmd
3004
3005 func_to_host_file_result=$1
17183006 if test -n "$1"; then
17193007 # because $build is cygwin, we call "the" cygpath in $PATH; no need to use
17203008 # LT_CYGPATH in this case.
17303018 # and a working winepath. Returns result in func_to_host_file_result.
17313019 func_convert_file_nix_to_w32 ()
17323020 {
1733 $opt_debug
1734 func_to_host_file_result="$1"
3021 $debug_cmd
3022
3023 func_to_host_file_result=$1
17353024 if test -n "$1"; then
17363025 func_convert_core_file_wine_to_w32 "$1"
1737 func_to_host_file_result="$func_convert_core_file_wine_to_w32_result"
3026 func_to_host_file_result=$func_convert_core_file_wine_to_w32_result
17383027 fi
17393028 func_convert_file_check "$1" "$func_to_host_file_result"
17403029 }
17463035 # Returns result in func_to_host_file_result.
17473036 func_convert_file_msys_to_cygwin ()
17483037 {
1749 $opt_debug
1750 func_to_host_file_result="$1"
3038 $debug_cmd
3039
3040 func_to_host_file_result=$1
17513041 if test -n "$1"; then
17523042 func_convert_core_msys_to_w32 "$1"
17533043 func_cygpath -u "$func_convert_core_msys_to_w32_result"
1754 func_to_host_file_result="$func_cygpath_result"
3044 func_to_host_file_result=$func_cygpath_result
17553045 fi
17563046 func_convert_file_check "$1" "$func_to_host_file_result"
17573047 }
17643054 # in func_to_host_file_result.
17653055 func_convert_file_nix_to_cygwin ()
17663056 {
1767 $opt_debug
1768 func_to_host_file_result="$1"
3057 $debug_cmd
3058
3059 func_to_host_file_result=$1
17693060 if test -n "$1"; then
17703061 # convert from *nix to w32, then use cygpath to convert from w32 to cygwin.
17713062 func_convert_core_file_wine_to_w32 "$1"
17723063 func_cygpath -u "$func_convert_core_file_wine_to_w32_result"
1773 func_to_host_file_result="$func_cygpath_result"
3064 func_to_host_file_result=$func_cygpath_result
17743065 fi
17753066 func_convert_file_check "$1" "$func_to_host_file_result"
17763067 }
17803071 #############################################
17813072 # $build to $host PATH CONVERSION FUNCTIONS #
17823073 #############################################
1783 # invoked via `$to_host_path_cmd ARG'
3074 # invoked via '$to_host_path_cmd ARG'
17843075 #
17853076 # In each case, ARG is the path to be converted from $build to $host format.
17863077 # The result will be available in $func_to_host_path_result.
18043095 to_host_path_cmd=
18053096 func_init_to_host_path_cmd ()
18063097 {
1807 $opt_debug
3098 $debug_cmd
3099
18083100 if test -z "$to_host_path_cmd"; then
18093101 func_stripname 'func_convert_file_' '' "$to_host_file_cmd"
1810 to_host_path_cmd="func_convert_path_${func_stripname_result}"
3102 to_host_path_cmd=func_convert_path_$func_stripname_result
18113103 fi
18123104 }
18133105
18173109 # in func_to_host_path_result.
18183110 func_to_host_path ()
18193111 {
1820 $opt_debug
3112 $debug_cmd
3113
18213114 func_init_to_host_path_cmd
18223115 $to_host_path_cmd "$1"
18233116 }
18283121 # Copy ARG to func_to_host_path_result.
18293122 func_convert_path_noop ()
18303123 {
1831 func_to_host_path_result="$1"
3124 func_to_host_path_result=$1
18323125 }
18333126 # end func_convert_path_noop
18343127
18393132 # func_to_host_path_result.
18403133 func_convert_path_msys_to_w32 ()
18413134 {
1842 $opt_debug
1843 func_to_host_path_result="$1"
3135 $debug_cmd
3136
3137 func_to_host_path_result=$1
18443138 if test -n "$1"; then
18453139 # Remove leading and trailing path separator characters from ARG. MSYS
18463140 # behavior is inconsistent here; cygpath turns them into '.;' and ';.';
18483142 func_stripname : : "$1"
18493143 func_to_host_path_tmp1=$func_stripname_result
18503144 func_convert_core_msys_to_w32 "$func_to_host_path_tmp1"
1851 func_to_host_path_result="$func_convert_core_msys_to_w32_result"
3145 func_to_host_path_result=$func_convert_core_msys_to_w32_result
18523146 func_convert_path_check : ";" \
18533147 "$func_to_host_path_tmp1" "$func_to_host_path_result"
18543148 func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
18623156 # func_to_host_file_result.
18633157 func_convert_path_cygwin_to_w32 ()
18643158 {
1865 $opt_debug
1866 func_to_host_path_result="$1"
3159 $debug_cmd
3160
3161 func_to_host_path_result=$1
18673162 if test -n "$1"; then
18683163 # See func_convert_path_msys_to_w32:
18693164 func_stripname : : "$1"
18823177 # a working winepath. Returns result in func_to_host_file_result.
18833178 func_convert_path_nix_to_w32 ()
18843179 {
1885 $opt_debug
1886 func_to_host_path_result="$1"
3180 $debug_cmd
3181
3182 func_to_host_path_result=$1
18873183 if test -n "$1"; then
18883184 # See func_convert_path_msys_to_w32:
18893185 func_stripname : : "$1"
18903186 func_to_host_path_tmp1=$func_stripname_result
18913187 func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1"
1892 func_to_host_path_result="$func_convert_core_path_wine_to_w32_result"
3188 func_to_host_path_result=$func_convert_core_path_wine_to_w32_result
18933189 func_convert_path_check : ";" \
18943190 "$func_to_host_path_tmp1" "$func_to_host_path_result"
18953191 func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
19033199 # Returns result in func_to_host_file_result.
19043200 func_convert_path_msys_to_cygwin ()
19053201 {
1906 $opt_debug
1907 func_to_host_path_result="$1"
3202 $debug_cmd
3203
3204 func_to_host_path_result=$1
19083205 if test -n "$1"; then
19093206 # See func_convert_path_msys_to_w32:
19103207 func_stripname : : "$1"
19113208 func_to_host_path_tmp1=$func_stripname_result
19123209 func_convert_core_msys_to_w32 "$func_to_host_path_tmp1"
19133210 func_cygpath -u -p "$func_convert_core_msys_to_w32_result"
1914 func_to_host_path_result="$func_cygpath_result"
3211 func_to_host_path_result=$func_cygpath_result
19153212 func_convert_path_check : : \
19163213 "$func_to_host_path_tmp1" "$func_to_host_path_result"
19173214 func_convert_path_front_back_pathsep ":*" "*:" : "$1"
19263223 # func_to_host_file_result.
19273224 func_convert_path_nix_to_cygwin ()
19283225 {
1929 $opt_debug
1930 func_to_host_path_result="$1"
3226 $debug_cmd
3227
3228 func_to_host_path_result=$1
19313229 if test -n "$1"; then
19323230 # Remove leading and trailing path separator characters from
19333231 # ARG. msys behavior is inconsistent here, cygpath turns them
19363234 func_to_host_path_tmp1=$func_stripname_result
19373235 func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1"
19383236 func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result"
1939 func_to_host_path_result="$func_cygpath_result"
3237 func_to_host_path_result=$func_cygpath_result
19403238 func_convert_path_check : : \
19413239 "$func_to_host_path_tmp1" "$func_to_host_path_result"
19423240 func_convert_path_front_back_pathsep ":*" "*:" : "$1"
19453243 # end func_convert_path_nix_to_cygwin
19463244
19473245
3246 # func_dll_def_p FILE
3247 # True iff FILE is a Windows DLL '.def' file.
3248 # Keep in sync with _LT_DLL_DEF_P in libtool.m4
3249 func_dll_def_p ()
3250 {
3251 $debug_cmd
3252
3253 func_dll_def_p_tmp=`$SED -n \
3254 -e 's/^[ ]*//' \
3255 -e '/^\(;.*\)*$/d' \
3256 -e 's/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p' \
3257 -e q \
3258 "$1"`
3259 test DEF = "$func_dll_def_p_tmp"
3260 }
3261
3262
19483263 # func_mode_compile arg...
19493264 func_mode_compile ()
19503265 {
1951 $opt_debug
3266 $debug_cmd
3267
19523268 # Get the compilation command and the source file.
19533269 base_compile=
1954 srcfile="$nonopt" # always keep a non-empty value in "srcfile"
3270 srcfile=$nonopt # always keep a non-empty value in "srcfile"
19553271 suppress_opt=yes
19563272 suppress_output=
19573273 arg_mode=normal
19643280 case $arg_mode in
19653281 arg )
19663282 # do not "continue". Instead, add this to base_compile
1967 lastarg="$arg"
3283 lastarg=$arg
19683284 arg_mode=normal
19693285 ;;
19703286
19713287 target )
1972 libobj="$arg"
3288 libobj=$arg
19733289 arg_mode=normal
19743290 continue
19753291 ;;
19793295 case $arg in
19803296 -o)
19813297 test -n "$libobj" && \
1982 func_fatal_error "you cannot specify \`-o' more than once"
3298 func_fatal_error "you cannot specify '-o' more than once"
19833299 arg_mode=target
19843300 continue
19853301 ;;
20083324 func_stripname '-Wc,' '' "$arg"
20093325 args=$func_stripname_result
20103326 lastarg=
2011 save_ifs="$IFS"; IFS=','
3327 save_ifs=$IFS; IFS=,
20123328 for arg in $args; do
2013 IFS="$save_ifs"
3329 IFS=$save_ifs
20143330 func_append_quoted lastarg "$arg"
20153331 done
2016 IFS="$save_ifs"
3332 IFS=$save_ifs
20173333 func_stripname ' ' '' "$lastarg"
20183334 lastarg=$func_stripname_result
20193335
20263342 # Accept the current argument as the source file.
20273343 # The previous "srcfile" becomes the current argument.
20283344 #
2029 lastarg="$srcfile"
2030 srcfile="$arg"
3345 lastarg=$srcfile
3346 srcfile=$arg
20313347 ;;
20323348 esac # case $arg
20333349 ;;
20423358 func_fatal_error "you must specify an argument for -Xcompile"
20433359 ;;
20443360 target)
2045 func_fatal_error "you must specify a target with \`-o'"
3361 func_fatal_error "you must specify a target with '-o'"
20463362 ;;
20473363 *)
20483364 # Get the name of the library object.
20493365 test -z "$libobj" && {
20503366 func_basename "$srcfile"
2051 libobj="$func_basename_result"
3367 libobj=$func_basename_result
20523368 }
20533369 ;;
20543370 esac
20683384 case $libobj in
20693385 *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;;
20703386 *)
2071 func_fatal_error "cannot determine name of library object from \`$libobj'"
3387 func_fatal_error "cannot determine name of library object from '$libobj'"
20723388 ;;
20733389 esac
20743390
20773393 for arg in $later; do
20783394 case $arg in
20793395 -shared)
2080 test "$build_libtool_libs" != yes && \
2081 func_fatal_configuration "can not build a shared library"
3396 test yes = "$build_libtool_libs" \
3397 || func_fatal_configuration "cannot build a shared library"
20823398 build_old_libs=no
20833399 continue
20843400 ;;
21043420 func_quote_for_eval "$libobj"
21053421 test "X$libobj" != "X$func_quote_for_eval_result" \
21063422 && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \
2107 && func_warning "libobj name \`$libobj' may not contain shell special characters."
3423 && func_warning "libobj name '$libobj' may not contain shell special characters."
21083424 func_dirname_and_basename "$obj" "/" ""
2109 objname="$func_basename_result"
2110 xdir="$func_dirname_result"
2111 lobj=${xdir}$objdir/$objname
3425 objname=$func_basename_result
3426 xdir=$func_dirname_result
3427 lobj=$xdir$objdir/$objname
21123428
21133429 test -z "$base_compile" && \
21143430 func_fatal_help "you must specify a compilation command"
21153431
21163432 # Delete any leftover library objects.
2117 if test "$build_old_libs" = yes; then
3433 if test yes = "$build_old_libs"; then
21183434 removelist="$obj $lobj $libobj ${libobj}T"
21193435 else
21203436 removelist="$lobj $libobj ${libobj}T"
21263442 pic_mode=default
21273443 ;;
21283444 esac
2129 if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then
3445 if test no = "$pic_mode" && test pass_all != "$deplibs_check_method"; then
21303446 # non-PIC code in shared libraries is not supported
21313447 pic_mode=default
21323448 fi
21333449
21343450 # Calculate the filename of the output object if compiler does
21353451 # not support -o with -c
2136 if test "$compiler_c_o" = no; then
2137 output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.${objext}
2138 lockfile="$output_obj.lock"
3452 if test no = "$compiler_c_o"; then
3453 output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.$objext
3454 lockfile=$output_obj.lock
21393455 else
21403456 output_obj=
21413457 need_locks=no
21443460
21453461 # Lock this critical section if it is needed
21463462 # We use this script file to make the link, it avoids creating a new file
2147 if test "$need_locks" = yes; then
3463 if test yes = "$need_locks"; then
21483464 until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do
21493465 func_echo "Waiting for $lockfile to be removed"
21503466 sleep 2
21513467 done
2152 elif test "$need_locks" = warn; then
3468 elif test warn = "$need_locks"; then
21533469 if test -f "$lockfile"; then
21543470 $ECHO "\
21553471 *** ERROR, $lockfile exists and contains:
21573473
21583474 This indicates that another process is trying to use the same
21593475 temporary object file, and libtool could not work around it because
2160 your compiler does not support \`-c' and \`-o' together. If you
3476 your compiler does not support '-c' and '-o' together. If you
21613477 repeat this compilation, it may succeed, by chance, but you had better
21623478 avoid parallel builds (make -j) in this platform, or get a better
21633479 compiler."
21793495 qsrcfile=$func_quote_for_eval_result
21803496
21813497 # Only build a PIC object if we are building libtool libraries.
2182 if test "$build_libtool_libs" = yes; then
3498 if test yes = "$build_libtool_libs"; then
21833499 # Without this assignment, base_compile gets emptied.
21843500 fbsd_hideous_sh_bug=$base_compile
21853501
2186 if test "$pic_mode" != no; then
3502 if test no != "$pic_mode"; then
21873503 command="$base_compile $qsrcfile $pic_flag"
21883504 else
21893505 # Don't build PIC code
22003516 func_show_eval_locale "$command" \
22013517 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE'
22023518
2203 if test "$need_locks" = warn &&
3519 if test warn = "$need_locks" &&
22043520 test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then
22053521 $ECHO "\
22063522 *** ERROR, $lockfile contains:
22113527
22123528 This indicates that another process is trying to use the same
22133529 temporary object file, and libtool could not work around it because
2214 your compiler does not support \`-c' and \`-o' together. If you
3530 your compiler does not support '-c' and '-o' together. If you
22153531 repeat this compilation, it may succeed, by chance, but you had better
22163532 avoid parallel builds (make -j) in this platform, or get a better
22173533 compiler."
22273543 fi
22283544
22293545 # Allow error messages only from the first compilation.
2230 if test "$suppress_opt" = yes; then
3546 if test yes = "$suppress_opt"; then
22313547 suppress_output=' >/dev/null 2>&1'
22323548 fi
22333549 fi
22343550
22353551 # Only build a position-dependent object if we build old libraries.
2236 if test "$build_old_libs" = yes; then
2237 if test "$pic_mode" != yes; then
3552 if test yes = "$build_old_libs"; then
3553 if test yes != "$pic_mode"; then
22383554 # Don't build PIC code
22393555 command="$base_compile $qsrcfile$pie_flag"
22403556 else
22413557 command="$base_compile $qsrcfile $pic_flag"
22423558 fi
2243 if test "$compiler_c_o" = yes; then
3559 if test yes = "$compiler_c_o"; then
22443560 func_append command " -o $obj"
22453561 fi
22463562
22493565 func_show_eval_locale "$command" \
22503566 '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE'
22513567
2252 if test "$need_locks" = warn &&
3568 if test warn = "$need_locks" &&
22533569 test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then
22543570 $ECHO "\
22553571 *** ERROR, $lockfile contains:
22603576
22613577 This indicates that another process is trying to use the same
22623578 temporary object file, and libtool could not work around it because
2263 your compiler does not support \`-c' and \`-o' together. If you
3579 your compiler does not support '-c' and '-o' together. If you
22643580 repeat this compilation, it may succeed, by chance, but you had better
22653581 avoid parallel builds (make -j) in this platform, or get a better
22663582 compiler."
22803596 func_write_libtool_object "$libobj" "$objdir/$objname" "$objname"
22813597
22823598 # Unlock the critical section if it was locked
2283 if test "$need_locks" != no; then
3599 if test no != "$need_locks"; then
22843600 removelist=$lockfile
22853601 $RM "$lockfile"
22863602 fi
22903606 }
22913607
22923608 $opt_help || {
2293 test "$opt_mode" = compile && func_mode_compile ${1+"$@"}
3609 test compile = "$opt_mode" && func_mode_compile ${1+"$@"}
22943610 }
22953611
22963612 func_mode_help ()
23103626 Remove files from the build directory.
23113627
23123628 RM is the name of the program to use to delete files associated with each FILE
2313 (typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed
3629 (typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed
23143630 to RM.
23153631
23163632 If FILE is a libtool library, object or program, all the files associated
23293645 -no-suppress do not suppress compiler output for multiple passes
23303646 -prefer-pic try to build PIC objects only
23313647 -prefer-non-pic try to build non-PIC objects only
2332 -shared do not build a \`.o' file suitable for static linking
2333 -static only build a \`.o' file suitable for static linking
3648 -shared do not build a '.o' file suitable for static linking
3649 -static only build a '.o' file suitable for static linking
23343650 -Wc,FLAG pass FLAG directly to the compiler
23353651
2336 COMPILE-COMMAND is a command to be used in creating a \`standard' object file
3652 COMPILE-COMMAND is a command to be used in creating a 'standard' object file
23373653 from the given SOURCEFILE.
23383654
23393655 The output file name is determined by removing the directory component from
2340 SOURCEFILE, then substituting the C source code suffix \`.c' with the
2341 library object suffix, \`.lo'."
3656 SOURCEFILE, then substituting the C source code suffix '.c' with the
3657 library object suffix, '.lo'."
23423658 ;;
23433659
23443660 execute)
23513667
23523668 -dlopen FILE add the directory containing FILE to the library path
23533669
2354 This mode sets the library path environment variable according to \`-dlopen'
3670 This mode sets the library path environment variable according to '-dlopen'
23553671 flags.
23563672
23573673 If any of the ARGS are libtool executable wrappers, then they are translated
23703686 Each LIBDIR is a directory that contains libtool libraries.
23713687
23723688 The commands that this mode executes may require superuser privileges. Use
2373 the \`--dry-run' option if you just want to see what would be executed."
3689 the '--dry-run' option if you just want to see what would be executed."
23743690 ;;
23753691
23763692 install)
23803696 Install executables or libraries.
23813697
23823698 INSTALL-COMMAND is the installation command. The first component should be
2383 either the \`install' or \`cp' program.
3699 either the 'install' or 'cp' program.
23843700
23853701 The following components of INSTALL-COMMAND are treated specially:
23863702
24063722 -avoid-version do not add a version suffix if possible
24073723 -bindir BINDIR specify path to binaries directory (for systems where
24083724 libraries must be found in the PATH setting at runtime)
2409 -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime
3725 -dlopen FILE '-dlpreopen' FILE if it cannot be dlopened at runtime
24103726 -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols
24113727 -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3)
24123728 -export-symbols SYMFILE
24203736 -no-install link a not-installable executable
24213737 -no-undefined declare that a library does not refer to external symbols
24223738 -o OUTPUT-FILE create OUTPUT-FILE from the specified objects
2423 -objectlist FILE Use a list of object files found in FILE to specify objects
3739 -objectlist FILE use a list of object files found in FILE to specify objects
3740 -os2dllname NAME force a short DLL name on OS/2 (no effect on other OSes)
24243741 -precious-files-regex REGEX
24253742 don't remove output files matching REGEX
24263743 -release RELEASE specify package release information
24403757 -Xlinker FLAG pass linker-specific FLAG directly to the linker
24413758 -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC)
24423759
2443 All other options (arguments beginning with \`-') are ignored.
2444
2445 Every other argument is treated as a filename. Files ending in \`.la' are
3760 All other options (arguments beginning with '-') are ignored.
3761
3762 Every other argument is treated as a filename. Files ending in '.la' are
24463763 treated as uninstalled libtool libraries, other files are standard or library
24473764 object files.
24483765
2449 If the OUTPUT-FILE ends in \`.la', then a libtool library is created,
2450 only library objects (\`.lo' files) may be specified, and \`-rpath' is
3766 If the OUTPUT-FILE ends in '.la', then a libtool library is created,
3767 only library objects ('.lo' files) may be specified, and '-rpath' is
24513768 required, except when creating a convenience library.
24523769
2453 If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created
2454 using \`ar' and \`ranlib', or on Windows using \`lib'.
2455
2456 If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file
3770 If OUTPUT-FILE ends in '.a' or '.lib', then a standard library is created
3771 using 'ar' and 'ranlib', or on Windows using 'lib'.
3772
3773 If OUTPUT-FILE ends in '.lo' or '.$objext', then a reloadable object file
24573774 is created, otherwise an executable program is created."
24583775 ;;
24593776
24643781 Remove libraries from an installation directory.
24653782
24663783 RM is the name of the program to use to delete files associated with each FILE
2467 (typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed
3784 (typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed
24683785 to RM.
24693786
24703787 If FILE is a libtool library, all the files associated with it are deleted.
24723789 ;;
24733790
24743791 *)
2475 func_fatal_help "invalid operation mode \`$opt_mode'"
3792 func_fatal_help "invalid operation mode '$opt_mode'"
24763793 ;;
24773794 esac
24783795
24793796 echo
2480 $ECHO "Try \`$progname --help' for more information about other modes."
3797 $ECHO "Try '$progname --help' for more information about other modes."
24813798 }
24823799
24833800 # Now that we've collected a possible --mode arg, show help if necessary
24843801 if $opt_help; then
2485 if test "$opt_help" = :; then
3802 if test : = "$opt_help"; then
24863803 func_mode_help
24873804 else
24883805 {
24903807 for opt_mode in compile link execute install finish uninstall clean; do
24913808 func_mode_help
24923809 done
2493 } | sed -n '1p; 2,$s/^Usage:/ or: /p'
3810 } | $SED -n '1p; 2,$s/^Usage:/ or: /p'
24943811 {
24953812 func_help noexit
24963813 for opt_mode in compile link execute install finish uninstall clean; do
24983815 func_mode_help
24993816 done
25003817 } |
2501 sed '1d
3818 $SED '1d
25023819 /^When reporting/,/^Report/{
25033820 H
25043821 d
25153832 # func_mode_execute arg...
25163833 func_mode_execute ()
25173834 {
2518 $opt_debug
3835 $debug_cmd
3836
25193837 # The first argument is the command name.
2520 cmd="$nonopt"
3838 cmd=$nonopt
25213839 test -z "$cmd" && \
25223840 func_fatal_help "you must specify a COMMAND"
25233841
25243842 # Handle -dlopen flags immediately.
25253843 for file in $opt_dlopen; do
25263844 test -f "$file" \
2527 || func_fatal_help "\`$file' is not a file"
3845 || func_fatal_help "'$file' is not a file"
25283846
25293847 dir=
25303848 case $file in
25343852
25353853 # Check to see that this really is a libtool archive.
25363854 func_lalib_unsafe_p "$file" \
2537 || func_fatal_help "\`$lib' is not a valid libtool archive"
3855 || func_fatal_help "'$lib' is not a valid libtool archive"
25383856
25393857 # Read the libtool library.
25403858 dlname=
25453863 if test -z "$dlname"; then
25463864 # Warn if it was a shared library.
25473865 test -n "$library_names" && \
2548 func_warning "\`$file' was not linked with \`-export-dynamic'"
3866 func_warning "'$file' was not linked with '-export-dynamic'"
25493867 continue
25503868 fi
25513869
25523870 func_dirname "$file" "" "."
2553 dir="$func_dirname_result"
3871 dir=$func_dirname_result
25543872
25553873 if test -f "$dir/$objdir/$dlname"; then
25563874 func_append dir "/$objdir"
25573875 else
25583876 if test ! -f "$dir/$dlname"; then
2559 func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'"
3877 func_fatal_error "cannot find '$dlname' in '$dir' or '$dir/$objdir'"
25603878 fi
25613879 fi
25623880 ;;
25643882 *.lo)
25653883 # Just add the directory containing the .lo file.
25663884 func_dirname "$file" "" "."
2567 dir="$func_dirname_result"
3885 dir=$func_dirname_result
25683886 ;;
25693887
25703888 *)
2571 func_warning "\`-dlopen' is ignored for non-libtool libraries and objects"
3889 func_warning "'-dlopen' is ignored for non-libtool libraries and objects"
25723890 continue
25733891 ;;
25743892 esac
25753893
25763894 # Get the absolute pathname.
25773895 absdir=`cd "$dir" && pwd`
2578 test -n "$absdir" && dir="$absdir"
3896 test -n "$absdir" && dir=$absdir
25793897
25803898 # Now add the directory to shlibpath_var.
25813899 if eval "test -z \"\$$shlibpath_var\""; then
25873905
25883906 # This variable tells wrapper scripts just to set shlibpath_var
25893907 # rather than running their programs.
2590 libtool_execute_magic="$magic"
3908 libtool_execute_magic=$magic
25913909
25923910 # Check if any of the arguments is a wrapper script.
25933911 args=
26003918 if func_ltwrapper_script_p "$file"; then
26013919 func_source "$file"
26023920 # Transform arg to wrapped name.
2603 file="$progdir/$program"
3921 file=$progdir/$program
26043922 elif func_ltwrapper_executable_p "$file"; then
26053923 func_ltwrapper_scriptname "$file"
26063924 func_source "$func_ltwrapper_scriptname_result"
26073925 # Transform arg to wrapped name.
2608 file="$progdir/$program"
3926 file=$progdir/$program
26093927 fi
26103928 ;;
26113929 esac
26133931 func_append_quoted args "$file"
26143932 done
26153933
2616 if test "X$opt_dry_run" = Xfalse; then
3934 if $opt_dry_run; then
3935 # Display what would be done.
3936 if test -n "$shlibpath_var"; then
3937 eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\""
3938 echo "export $shlibpath_var"
3939 fi
3940 $ECHO "$cmd$args"
3941 exit $EXIT_SUCCESS
3942 else
26173943 if test -n "$shlibpath_var"; then
26183944 # Export the shlibpath_var.
26193945 eval "export $shlibpath_var"
26303956 done
26313957
26323958 # Now prepare to actually exec the command.
2633 exec_cmd="\$cmd$args"
2634 else
2635 # Display what would be done.
2636 if test -n "$shlibpath_var"; then
2637 eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\""
2638 echo "export $shlibpath_var"
2639 fi
2640 $ECHO "$cmd$args"
2641 exit $EXIT_SUCCESS
3959 exec_cmd=\$cmd$args
26423960 fi
26433961 }
26443962
2645 test "$opt_mode" = execute && func_mode_execute ${1+"$@"}
3963 test execute = "$opt_mode" && func_mode_execute ${1+"$@"}
26463964
26473965
26483966 # func_mode_finish arg...
26493967 func_mode_finish ()
26503968 {
2651 $opt_debug
3969 $debug_cmd
3970
26523971 libs=
26533972 libdirs=
26543973 admincmds=
26623981 if func_lalib_unsafe_p "$opt"; then
26633982 func_append libs " $opt"
26643983 else
2665 func_warning "\`$opt' is not a valid libtool archive"
3984 func_warning "'$opt' is not a valid libtool archive"
26663985 fi
26673986
26683987 else
2669 func_fatal_error "invalid argument \`$opt'"
3988 func_fatal_error "invalid argument '$opt'"
26703989 fi
26713990 done
26723991
26814000 # Remove sysroot references
26824001 if $opt_dry_run; then
26834002 for lib in $libs; do
2684 echo "removing references to $lt_sysroot and \`=' prefixes from $lib"
4003 echo "removing references to $lt_sysroot and '=' prefixes from $lib"
26854004 done
26864005 else
26874006 tmpdir=`func_mktempdir`
26884007 for lib in $libs; do
2689 sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \
4008 $SED -e "$sysroot_cmd s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \
26904009 > $tmpdir/tmp-la
26914010 mv -f $tmpdir/tmp-la $lib
26924011 done
27114030 fi
27124031
27134032 # Exit here if they wanted silent mode.
2714 $opt_silent && exit $EXIT_SUCCESS
4033 $opt_quiet && exit $EXIT_SUCCESS
27154034
27164035 if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
27174036 echo "----------------------------------------------------------------------"
27224041 echo
27234042 echo "If you ever happen to want to link against installed libraries"
27244043 echo "in a given directory, LIBDIR, you must either use libtool, and"
2725 echo "specify the full pathname of the library, or use the \`-LLIBDIR'"
4044 echo "specify the full pathname of the library, or use the '-LLIBDIR'"
27264045 echo "flag during linking and do at least one of the following:"
27274046 if test -n "$shlibpath_var"; then
2728 echo " - add LIBDIR to the \`$shlibpath_var' environment variable"
4047 echo " - add LIBDIR to the '$shlibpath_var' environment variable"
27294048 echo " during execution"
27304049 fi
27314050 if test -n "$runpath_var"; then
2732 echo " - add LIBDIR to the \`$runpath_var' environment variable"
4051 echo " - add LIBDIR to the '$runpath_var' environment variable"
27334052 echo " during linking"
27344053 fi
27354054 if test -n "$hardcode_libdir_flag_spec"; then
27364055 libdir=LIBDIR
27374056 eval flag=\"$hardcode_libdir_flag_spec\"
27384057
2739 $ECHO " - use the \`$flag' linker flag"
4058 $ECHO " - use the '$flag' linker flag"
27404059 fi
27414060 if test -n "$admincmds"; then
27424061 $ECHO " - have your system administrator run these commands:$admincmds"
27434062 fi
27444063 if test -f /etc/ld.so.conf; then
2745 echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
4064 echo " - have your system administrator add LIBDIR to '/etc/ld.so.conf'"
27464065 fi
27474066 echo
27484067
27614080 exit $EXIT_SUCCESS
27624081 }
27634082
2764 test "$opt_mode" = finish && func_mode_finish ${1+"$@"}
4083 test finish = "$opt_mode" && func_mode_finish ${1+"$@"}
27654084
27664085
27674086 # func_mode_install arg...
27684087 func_mode_install ()
27694088 {
2770 $opt_debug
4089 $debug_cmd
4090
27714091 # There may be an optional sh(1) argument at the beginning of
27724092 # install_prog (especially on Windows NT).
2773 if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh ||
4093 if test "$SHELL" = "$nonopt" || test /bin/sh = "$nonopt" ||
27744094 # Allow the use of GNU shtool's install command.
2775 case $nonopt in *shtool*) :;; *) false;; esac; then
4095 case $nonopt in *shtool*) :;; *) false;; esac
4096 then
27764097 # Aesthetically quote it.
27774098 func_quote_for_eval "$nonopt"
27784099 install_prog="$func_quote_for_eval_result "
27994120 opts=
28004121 prev=
28014122 install_type=
2802 isdir=no
4123 isdir=false
28034124 stripme=
28044125 no_mode=:
28054126 for arg
28124133 fi
28134134
28144135 case $arg in
2815 -d) isdir=yes ;;
4136 -d) isdir=: ;;
28164137 -f)
28174138 if $install_cp; then :; else
28184139 prev=$arg
28304151 *)
28314152 # If the previous option needed an argument, then skip it.
28324153 if test -n "$prev"; then
2833 if test "x$prev" = x-m && test -n "$install_override_mode"; then
4154 if test X-m = "X$prev" && test -n "$install_override_mode"; then
28344155 arg2=$install_override_mode
28354156 no_mode=false
28364157 fi
28554176 func_fatal_help "you must specify an install program"
28564177
28574178 test -n "$prev" && \
2858 func_fatal_help "the \`$prev' option requires an argument"
4179 func_fatal_help "the '$prev' option requires an argument"
28594180
28604181 if test -n "$install_override_mode" && $no_mode; then
28614182 if $install_cp; then :; else
28774198 dest=$func_stripname_result
28784199
28794200 # Check to see that the destination is a directory.
2880 test -d "$dest" && isdir=yes
2881 if test "$isdir" = yes; then
2882 destdir="$dest"
4201 test -d "$dest" && isdir=:
4202 if $isdir; then
4203 destdir=$dest
28834204 destname=
28844205 else
28854206 func_dirname_and_basename "$dest" "" "."
2886 destdir="$func_dirname_result"
2887 destname="$func_basename_result"
4207 destdir=$func_dirname_result
4208 destname=$func_basename_result
28884209
28894210 # Not a directory, so check to see that there is only one file specified.
28904211 set dummy $files; shift
28914212 test "$#" -gt 1 && \
2892 func_fatal_help "\`$dest' is not a directory"
4213 func_fatal_help "'$dest' is not a directory"
28934214 fi
28944215 case $destdir in
28954216 [\\/]* | [A-Za-z]:[\\/]*) ;;
28984219 case $file in
28994220 *.lo) ;;
29004221 *)
2901 func_fatal_help "\`$destdir' must be an absolute directory name"
4222 func_fatal_help "'$destdir' must be an absolute directory name"
29024223 ;;
29034224 esac
29044225 done
29074228
29084229 # This variable tells wrapper scripts just to set variables rather
29094230 # than running their programs.
2910 libtool_install_magic="$magic"
4231 libtool_install_magic=$magic
29114232
29124233 staticlibs=
29134234 future_libdirs=
29274248
29284249 # Check to see that this really is a libtool archive.
29294250 func_lalib_unsafe_p "$file" \
2930 || func_fatal_help "\`$file' is not a valid libtool archive"
4251 || func_fatal_help "'$file' is not a valid libtool archive"
29314252
29324253 library_names=
29334254 old_library=
29494270 fi
29504271
29514272 func_dirname "$file" "/" ""
2952 dir="$func_dirname_result"
4273 dir=$func_dirname_result
29534274 func_append dir "$objdir"
29544275
29554276 if test -n "$relink_command"; then
29634284 # are installed into $libdir/../bin (currently, that works fine)
29644285 # but it's something to keep an eye on.
29654286 test "$inst_prefix_dir" = "$destdir" && \
2966 func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir"
4287 func_fatal_error "error: cannot install '$file' to a directory not ending in $libdir"
29674288
29684289 if test -n "$inst_prefix_dir"; then
29694290 # Stick the inst_prefix_dir data into the link command.
29724293 relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"`
29734294 fi
29744295
2975 func_warning "relinking \`$file'"
4296 func_warning "relinking '$file'"
29764297 func_show_eval "$relink_command" \
2977 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"'
4298 'func_fatal_error "error: relink '\''$file'\'' with the above command before installing it"'
29784299 fi
29794300
29804301 # See the names of the shared library.
29814302 set dummy $library_names; shift
29824303 if test -n "$1"; then
2983 realname="$1"
4304 realname=$1
29844305 shift
29854306
2986 srcname="$realname"
2987 test -n "$relink_command" && srcname="$realname"T
4307 srcname=$realname
4308 test -n "$relink_command" && srcname=${realname}T
29884309
29894310 # Install the shared library and build the symlinks.
29904311 func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \
29914312 'exit $?'
2992 tstripme="$stripme"
4313 tstripme=$stripme
29934314 case $host_os in
29944315 cygwin* | mingw* | pw32* | cegcc*)
29954316 case $realname in
29964317 *.dll.a)
2997 tstripme=""
4318 tstripme=
4319 ;;
4320 esac
4321 ;;
4322 os2*)
4323 case $realname in
4324 *_dll.a)
4325 tstripme=
29984326 ;;
29994327 esac
30004328 ;;
30054333
30064334 if test "$#" -gt 0; then
30074335 # Delete the old symlinks, and create new ones.
3008 # Try `ln -sf' first, because the `ln' binary might depend on
4336 # Try 'ln -sf' first, because the 'ln' binary might depend on
30094337 # the symlink we replace! Solaris /bin/ln does not understand -f,
30104338 # so we also need to try rm && ln -s.
30114339 for linkname
30164344 fi
30174345
30184346 # Do each command in the postinstall commands.
3019 lib="$destdir/$realname"
4347 lib=$destdir/$realname
30204348 func_execute_cmds "$postinstall_cmds" 'exit $?'
30214349 fi
30224350
30234351 # Install the pseudo-library for information purposes.
30244352 func_basename "$file"
3025 name="$func_basename_result"
3026 instname="$dir/$name"i
4353 name=$func_basename_result
4354 instname=$dir/${name}i
30274355 func_show_eval "$install_prog $instname $destdir/$name" 'exit $?'
30284356
30294357 # Maybe install the static library, too.
30354363
30364364 # Figure out destination file name, if it wasn't already specified.
30374365 if test -n "$destname"; then
3038 destfile="$destdir/$destname"
4366 destfile=$destdir/$destname
30394367 else
30404368 func_basename "$file"
3041 destfile="$func_basename_result"
3042 destfile="$destdir/$destfile"
4369 destfile=$func_basename_result
4370 destfile=$destdir/$destfile
30434371 fi
30444372
30454373 # Deduce the name of the destination old-style object file.
30494377 staticdest=$func_lo2o_result
30504378 ;;
30514379 *.$objext)
3052 staticdest="$destfile"
4380 staticdest=$destfile
30534381 destfile=
30544382 ;;
30554383 *)
3056 func_fatal_help "cannot copy a libtool object to \`$destfile'"
4384 func_fatal_help "cannot copy a libtool object to '$destfile'"
30574385 ;;
30584386 esac
30594387
30624390 func_show_eval "$install_prog $file $destfile" 'exit $?'
30634391
30644392 # Install the old object if enabled.
3065 if test "$build_old_libs" = yes; then
4393 if test yes = "$build_old_libs"; then
30664394 # Deduce the name of the old-style object file.
30674395 func_lo2o "$file"
30684396 staticobj=$func_lo2o_result
30744402 *)
30754403 # Figure out destination file name, if it wasn't already specified.
30764404 if test -n "$destname"; then
3077 destfile="$destdir/$destname"
4405 destfile=$destdir/$destname
30784406 else
30794407 func_basename "$file"
3080 destfile="$func_basename_result"
3081 destfile="$destdir/$destfile"
4408 destfile=$func_basename_result
4409 destfile=$destdir/$destfile
30824410 fi
30834411
30844412 # If the file is missing, and there is a .exe on the end, strip it
30854413 # because it is most likely a libtool script we actually want to
30864414 # install
3087 stripped_ext=""
4415 stripped_ext=
30884416 case $file in
30894417 *.exe)
30904418 if test ! -f "$file"; then
30914419 func_stripname '' '.exe' "$file"
30924420 file=$func_stripname_result
3093 stripped_ext=".exe"
4421 stripped_ext=.exe
30944422 fi
30954423 ;;
30964424 esac
31184446
31194447 # Check the variables that should have been set.
31204448 test -z "$generated_by_libtool_version" && \
3121 func_fatal_error "invalid libtool wrapper script \`$wrapper'"
3122
3123 finalize=yes
4449 func_fatal_error "invalid libtool wrapper script '$wrapper'"
4450
4451 finalize=:
31244452 for lib in $notinst_deplibs; do
31254453 # Check to see that each library is installed.
31264454 libdir=
31274455 if test -f "$lib"; then
31284456 func_source "$lib"
31294457 fi
3130 libfile="$libdir/"`$ECHO "$lib" | $SED 's%^.*/%%g'` ### testsuite: skip nested quoting test
4458 libfile=$libdir/`$ECHO "$lib" | $SED 's%^.*/%%g'`
31314459 if test -n "$libdir" && test ! -f "$libfile"; then
3132 func_warning "\`$lib' has not been installed in \`$libdir'"
3133 finalize=no
4460 func_warning "'$lib' has not been installed in '$libdir'"
4461 finalize=false
31344462 fi
31354463 done
31364464
31384466 func_source "$wrapper"
31394467
31404468 outputname=
3141 if test "$fast_install" = no && test -n "$relink_command"; then
4469 if test no = "$fast_install" && test -n "$relink_command"; then
31424470 $opt_dry_run || {
3143 if test "$finalize" = yes; then
4471 if $finalize; then
31444472 tmpdir=`func_mktempdir`
31454473 func_basename "$file$stripped_ext"
3146 file="$func_basename_result"
3147 outputname="$tmpdir/$file"
4474 file=$func_basename_result
4475 outputname=$tmpdir/$file
31484476 # Replace the output file specification.
31494477 relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'`
31504478
3151 $opt_silent || {
4479 $opt_quiet || {
31524480 func_quote_for_expand "$relink_command"
31534481 eval "func_echo $func_quote_for_expand_result"
31544482 }
31554483 if eval "$relink_command"; then :
31564484 else
3157 func_error "error: relink \`$file' with the above command before installing it"
4485 func_error "error: relink '$file' with the above command before installing it"
31584486 $opt_dry_run || ${RM}r "$tmpdir"
31594487 continue
31604488 fi
3161 file="$outputname"
4489 file=$outputname
31624490 else
3163 func_warning "cannot relink \`$file'"
4491 func_warning "cannot relink '$file'"
31644492 fi
31654493 }
31664494 else
31974525
31984526 for file in $staticlibs; do
31994527 func_basename "$file"
3200 name="$func_basename_result"
4528 name=$func_basename_result
32014529
32024530 # Set up the ranlib parameters.
3203 oldlib="$destdir/$name"
4531 oldlib=$destdir/$name
32044532 func_to_tool_file "$oldlib" func_convert_file_msys_to_w32
32054533 tool_oldlib=$func_to_tool_file_result
32064534
32154543 done
32164544
32174545 test -n "$future_libdirs" && \
3218 func_warning "remember to run \`$progname --finish$future_libdirs'"
4546 func_warning "remember to run '$progname --finish$future_libdirs'"
32194547
32204548 if test -n "$current_libdirs"; then
32214549 # Maybe just do a dry run.
32224550 $opt_dry_run && current_libdirs=" -n$current_libdirs"
3223 exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs'
4551 exec_cmd='$SHELL "$progpath" $preserve_args --finish$current_libdirs'
32244552 else
32254553 exit $EXIT_SUCCESS
32264554 fi
32274555 }
32284556
3229 test "$opt_mode" = install && func_mode_install ${1+"$@"}
4557 test install = "$opt_mode" && func_mode_install ${1+"$@"}
32304558
32314559
32324560 # func_generate_dlsyms outputname originator pic_p
32344562 # a dlpreopen symbol table.
32354563 func_generate_dlsyms ()
32364564 {
3237 $opt_debug
3238 my_outputname="$1"
3239 my_originator="$2"
3240 my_pic_p="${3-no}"
3241 my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'`
4565 $debug_cmd
4566
4567 my_outputname=$1
4568 my_originator=$2
4569 my_pic_p=${3-false}
4570 my_prefix=`$ECHO "$my_originator" | $SED 's%[^a-zA-Z0-9]%_%g'`
32424571 my_dlsyms=
32434572
3244 if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
4573 if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then
32454574 if test -n "$NM" && test -n "$global_symbol_pipe"; then
3246 my_dlsyms="${my_outputname}S.c"
4575 my_dlsyms=${my_outputname}S.c
32474576 else
32484577 func_error "not configured to extract global symbols from dlpreopened files"
32494578 fi
32544583 "") ;;
32554584 *.c)
32564585 # Discover the nlist of each of the dlfiles.
3257 nlist="$output_objdir/${my_outputname}.nm"
4586 nlist=$output_objdir/$my_outputname.nm
32584587
32594588 func_show_eval "$RM $nlist ${nlist}S ${nlist}T"
32604589
32624591 func_verbose "creating $output_objdir/$my_dlsyms"
32634592
32644593 $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\
3265 /* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */
3266 /* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */
4594 /* $my_dlsyms - symbol resolution table for '$my_outputname' dlsym emulation. */
4595 /* Generated by $PROGRAM (GNU $PACKAGE) $VERSION */
32674596
32684597 #ifdef __cplusplus
32694598 extern \"C\" {
32704599 #endif
32714600
3272 #if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4))
4601 #if defined __GNUC__ && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4))
32734602 #pragma GCC diagnostic ignored \"-Wstrict-prototypes\"
32744603 #endif
32754604
32764605 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
3277 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
3278 /* DATA imports from DLLs on WIN32 con't be const, because runtime
4606 #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
4607 /* DATA imports from DLLs on WIN32 can't be const, because runtime
32794608 relocations are performed -- see ld's documentation on pseudo-relocs. */
32804609 # define LT_DLSYM_CONST
3281 #elif defined(__osf__)
4610 #elif defined __osf__
32824611 /* This system does not cope well with relocations in const data. */
32834612 # define LT_DLSYM_CONST
32844613 #else
32854614 # define LT_DLSYM_CONST const
32864615 #endif
32874616
4617 #define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0)
4618
32884619 /* External symbol declarations for the compiler. */\
32894620 "
32904621
3291 if test "$dlself" = yes; then
3292 func_verbose "generating symbol list for \`$output'"
4622 if test yes = "$dlself"; then
4623 func_verbose "generating symbol list for '$output'"
32934624
32944625 $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist"
32954626
32974628 progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP`
32984629 for progfile in $progfiles; do
32994630 func_to_tool_file "$progfile" func_convert_file_msys_to_w32
3300 func_verbose "extracting global C symbols from \`$func_to_tool_file_result'"
4631 func_verbose "extracting global C symbols from '$func_to_tool_file_result'"
33014632 $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'"
33024633 done
33034634
33174648
33184649 # Prepare the list of exported symbols
33194650 if test -z "$export_symbols"; then
3320 export_symbols="$output_objdir/$outputname.exp"
4651 export_symbols=$output_objdir/$outputname.exp
33214652 $opt_dry_run || {
33224653 $RM $export_symbols
3323 eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"'
4654 eval "$SED -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"'
33244655 case $host in
33254656 *cygwin* | *mingw* | *cegcc* )
33264657 eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
33304661 }
33314662 else
33324663 $opt_dry_run || {
3333 eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"'
4664 eval "$SED -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"'
33344665 eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T'
33354666 eval '$MV "$nlist"T "$nlist"'
33364667 case $host in
33444675 fi
33454676
33464677 for dlprefile in $dlprefiles; do
3347 func_verbose "extracting global C symbols from \`$dlprefile'"
4678 func_verbose "extracting global C symbols from '$dlprefile'"
33484679 func_basename "$dlprefile"
3349 name="$func_basename_result"
4680 name=$func_basename_result
33504681 case $host in
33514682 *cygwin* | *mingw* | *cegcc* )
33524683 # if an import library, we need to obtain dlname
33534684 if func_win32_import_lib_p "$dlprefile"; then
33544685 func_tr_sh "$dlprefile"
33554686 eval "curr_lafile=\$libfile_$func_tr_sh_result"
3356 dlprefile_dlbasename=""
4687 dlprefile_dlbasename=
33574688 if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then
33584689 # Use subshell, to avoid clobbering current variable values
33594690 dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"`
3360 if test -n "$dlprefile_dlname" ; then
4691 if test -n "$dlprefile_dlname"; then
33614692 func_basename "$dlprefile_dlname"
3362 dlprefile_dlbasename="$func_basename_result"
4693 dlprefile_dlbasename=$func_basename_result
33634694 else
33644695 # no lafile. user explicitly requested -dlpreopen <import library>.
33654696 $sharedlib_from_linklib_cmd "$dlprefile"
33674698 fi
33684699 fi
33694700 $opt_dry_run || {
3370 if test -n "$dlprefile_dlbasename" ; then
4701 if test -n "$dlprefile_dlbasename"; then
33714702 eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"'
33724703 else
33734704 func_warning "Could not compute DLL name from $name"
34234754 echo '/* NONE */' >> "$output_objdir/$my_dlsyms"
34244755 fi
34254756
4757 func_show_eval '$RM "${nlist}I"'
4758 if test -n "$global_symbol_to_import"; then
4759 eval "$global_symbol_to_import"' < "$nlist"S > "$nlist"I'
4760 fi
4761
34264762 echo >> "$output_objdir/$my_dlsyms" "\
34274763
34284764 /* The mapping between symbol names and symbols. */
34314767 void *address;
34324768 } lt_dlsymlist;
34334769 extern LT_DLSYM_CONST lt_dlsymlist
3434 lt_${my_prefix}_LTX_preloaded_symbols[];
4770 lt_${my_prefix}_LTX_preloaded_symbols[];\
4771 "
4772
4773 if test -s "$nlist"I; then
4774 echo >> "$output_objdir/$my_dlsyms" "\
4775 static void lt_syminit(void)
4776 {
4777 LT_DLSYM_CONST lt_dlsymlist *symbol = lt_${my_prefix}_LTX_preloaded_symbols;
4778 for (; symbol->name; ++symbol)
4779 {"
4780 $SED 's/.*/ if (STREQ (symbol->name, \"&\")) symbol->address = (void *) \&&;/' < "$nlist"I >> "$output_objdir/$my_dlsyms"
4781 echo >> "$output_objdir/$my_dlsyms" "\
4782 }
4783 }"
4784 fi
4785 echo >> "$output_objdir/$my_dlsyms" "\
34354786 LT_DLSYM_CONST lt_dlsymlist
34364787 lt_${my_prefix}_LTX_preloaded_symbols[] =
3437 {\
3438 { \"$my_originator\", (void *) 0 },"
4788 { {\"$my_originator\", (void *) 0},"
4789
4790 if test -s "$nlist"I; then
4791 echo >> "$output_objdir/$my_dlsyms" "\
4792 {\"@INIT@\", (void *) &lt_syminit},"
4793 fi
34394794
34404795 case $need_lib_prefix in
34414796 no)
34774832 *-*-hpux*)
34784833 pic_flag_for_symtable=" $pic_flag" ;;
34794834 *)
3480 if test "X$my_pic_p" != Xno; then
3481 pic_flag_for_symtable=" $pic_flag"
3482 fi
4835 $my_pic_p && pic_flag_for_symtable=" $pic_flag"
34834836 ;;
34844837 esac
34854838 ;;
34964849 func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?'
34974850
34984851 # Clean up the generated files.
3499 func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"'
4852 func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T" "${nlist}I"'
35004853
35014854 # Transform the symbol file into the correct name.
3502 symfileobj="$output_objdir/${my_outputname}S.$objext"
4855 symfileobj=$output_objdir/${my_outputname}S.$objext
35034856 case $host in
35044857 *cygwin* | *mingw* | *cegcc* )
35054858 if test -f "$output_objdir/$my_outputname.def"; then
35174870 esac
35184871 ;;
35194872 *)
3520 func_fatal_error "unknown suffix for \`$my_dlsyms'"
4873 func_fatal_error "unknown suffix for '$my_dlsyms'"
35214874 ;;
35224875 esac
35234876 else
35294882 compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"`
35304883 finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"`
35314884 fi
4885 }
4886
4887 # func_cygming_gnu_implib_p ARG
4888 # This predicate returns with zero status (TRUE) if
4889 # ARG is a GNU/binutils-style import library. Returns
4890 # with nonzero status (FALSE) otherwise.
4891 func_cygming_gnu_implib_p ()
4892 {
4893 $debug_cmd
4894
4895 func_to_tool_file "$1" func_convert_file_msys_to_w32
4896 func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'`
4897 test -n "$func_cygming_gnu_implib_tmp"
4898 }
4899
4900 # func_cygming_ms_implib_p ARG
4901 # This predicate returns with zero status (TRUE) if
4902 # ARG is an MS-style import library. Returns
4903 # with nonzero status (FALSE) otherwise.
4904 func_cygming_ms_implib_p ()
4905 {
4906 $debug_cmd
4907
4908 func_to_tool_file "$1" func_convert_file_msys_to_w32
4909 func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'`
4910 test -n "$func_cygming_ms_implib_tmp"
35324911 }
35334912
35344913 # func_win32_libid arg
35404919 # Despite the name, also deal with 64 bit binaries.
35414920 func_win32_libid ()
35424921 {
3543 $opt_debug
3544 win32_libid_type="unknown"
4922 $debug_cmd
4923
4924 win32_libid_type=unknown
35454925 win32_fileres=`file -L $1 2>/dev/null`
35464926 case $win32_fileres in
35474927 *ar\ archive\ import\ library*) # definitely import
35514931 # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD.
35524932 if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null |
35534933 $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then
3554 func_to_tool_file "$1" func_convert_file_msys_to_w32
3555 win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" |
3556 $SED -n -e '
4934 case $nm_interface in
4935 "MS dumpbin")
4936 if func_cygming_ms_implib_p "$1" ||
4937 func_cygming_gnu_implib_p "$1"
4938 then
4939 win32_nmres=import
4940 else
4941 win32_nmres=
4942 fi
4943 ;;
4944 *)
4945 func_to_tool_file "$1" func_convert_file_msys_to_w32
4946 win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" |
4947 $SED -n -e '
35574948 1,100{
35584949 / I /{
3559 s,.*,import,
4950 s|.*|import|
35604951 p
35614952 q
35624953 }
35634954 }'`
4955 ;;
4956 esac
35644957 case $win32_nmres in
35654958 import*) win32_libid_type="x86 archive import";;
35664959 *) win32_libid_type="x86 archive static";;
35924985 # $sharedlib_from_linklib_result
35934986 func_cygming_dll_for_implib ()
35944987 {
3595 $opt_debug
4988 $debug_cmd
4989
35964990 sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"`
35974991 }
35984992
36095003 # specified import library.
36105004 func_cygming_dll_for_implib_fallback_core ()
36115005 {
3612 $opt_debug
5006 $debug_cmd
5007
36135008 match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"`
36145009 $OBJDUMP -s --section "$1" "$2" 2>/dev/null |
36155010 $SED '/^Contents of section '"$match_literal"':/{
36455040 /./p' |
36465041 # we now have a list, one entry per line, of the stringified
36475042 # contents of the appropriate section of all members of the
3648 # archive which possess that section. Heuristic: eliminate
3649 # all those which have a first or second character that is
5043 # archive that possess that section. Heuristic: eliminate
5044 # all those that have a first or second character that is
36505045 # a '.' (that is, objdump's representation of an unprintable
36515046 # character.) This should work for all archives with less than
36525047 # 0x302f exports -- but will fail for DLLs whose name actually
36555050 #
36565051 # Of those that remain, print the first one.
36575052 $SED -e '/^\./d;/^.\./d;q'
3658 }
3659
3660 # func_cygming_gnu_implib_p ARG
3661 # This predicate returns with zero status (TRUE) if
3662 # ARG is a GNU/binutils-style import library. Returns
3663 # with nonzero status (FALSE) otherwise.
3664 func_cygming_gnu_implib_p ()
3665 {
3666 $opt_debug
3667 func_to_tool_file "$1" func_convert_file_msys_to_w32
3668 func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'`
3669 test -n "$func_cygming_gnu_implib_tmp"
3670 }
3671
3672 # func_cygming_ms_implib_p ARG
3673 # This predicate returns with zero status (TRUE) if
3674 # ARG is an MS-style import library. Returns
3675 # with nonzero status (FALSE) otherwise.
3676 func_cygming_ms_implib_p ()
3677 {
3678 $opt_debug
3679 func_to_tool_file "$1" func_convert_file_msys_to_w32
3680 func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'`
3681 test -n "$func_cygming_ms_implib_tmp"
36825053 }
36835054
36845055 # func_cygming_dll_for_implib_fallback ARG
36945065 # $sharedlib_from_linklib_result
36955066 func_cygming_dll_for_implib_fallback ()
36965067 {
3697 $opt_debug
3698 if func_cygming_gnu_implib_p "$1" ; then
5068 $debug_cmd
5069
5070 if func_cygming_gnu_implib_p "$1"; then
36995071 # binutils import library
37005072 sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"`
3701 elif func_cygming_ms_implib_p "$1" ; then
5073 elif func_cygming_ms_implib_p "$1"; then
37025074 # ms-generated import library
37035075 sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"`
37045076 else
37055077 # unknown
3706 sharedlib_from_linklib_result=""
5078 sharedlib_from_linklib_result=
37075079 fi
37085080 }
37095081
37115083 # func_extract_an_archive dir oldlib
37125084 func_extract_an_archive ()
37135085 {
3714 $opt_debug
3715 f_ex_an_ar_dir="$1"; shift
3716 f_ex_an_ar_oldlib="$1"
3717 if test "$lock_old_archive_extraction" = yes; then
5086 $debug_cmd
5087
5088 f_ex_an_ar_dir=$1; shift
5089 f_ex_an_ar_oldlib=$1
5090 if test yes = "$lock_old_archive_extraction"; then
37185091 lockfile=$f_ex_an_ar_oldlib.lock
37195092 until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do
37205093 func_echo "Waiting for $lockfile to be removed"
37235096 fi
37245097 func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \
37255098 'stat=$?; rm -f "$lockfile"; exit $stat'
3726 if test "$lock_old_archive_extraction" = yes; then
5099 if test yes = "$lock_old_archive_extraction"; then
37275100 $opt_dry_run || rm -f "$lockfile"
37285101 fi
37295102 if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then
37375110 # func_extract_archives gentop oldlib ...
37385111 func_extract_archives ()
37395112 {
3740 $opt_debug
3741 my_gentop="$1"; shift
5113 $debug_cmd
5114
5115 my_gentop=$1; shift
37425116 my_oldlibs=${1+"$@"}
3743 my_oldobjs=""
3744 my_xlib=""
3745 my_xabs=""
3746 my_xdir=""
5117 my_oldobjs=
5118 my_xlib=
5119 my_xabs=
5120 my_xdir=
37475121
37485122 for my_xlib in $my_oldlibs; do
37495123 # Extract the objects.
37505124 case $my_xlib in
3751 [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;;
5125 [\\/]* | [A-Za-z]:[\\/]*) my_xabs=$my_xlib ;;
37525126 *) my_xabs=`pwd`"/$my_xlib" ;;
37535127 esac
37545128 func_basename "$my_xlib"
3755 my_xlib="$func_basename_result"
5129 my_xlib=$func_basename_result
37565130 my_xlib_u=$my_xlib
37575131 while :; do
37585132 case " $extracted_archives " in
37645138 esac
37655139 done
37665140 extracted_archives="$extracted_archives $my_xlib_u"
3767 my_xdir="$my_gentop/$my_xlib_u"
5141 my_xdir=$my_gentop/$my_xlib_u
37685142
37695143 func_mkdir_p "$my_xdir"
37705144
37775151 cd $my_xdir || exit $?
37785152 darwin_archive=$my_xabs
37795153 darwin_curdir=`pwd`
3780 darwin_base_archive=`basename "$darwin_archive"`
5154 func_basename "$darwin_archive"
5155 darwin_base_archive=$func_basename_result
37815156 darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true`
37825157 if test -n "$darwin_arches"; then
37835158 darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'`
37845159 darwin_arch=
37855160 func_verbose "$darwin_base_archive has multiple architectures $darwin_arches"
3786 for darwin_arch in $darwin_arches ; do
3787 func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}"
3788 $LIPO -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}"
3789 cd "unfat-$$/${darwin_base_archive}-${darwin_arch}"
3790 func_extract_an_archive "`pwd`" "${darwin_base_archive}"
5161 for darwin_arch in $darwin_arches; do
5162 func_mkdir_p "unfat-$$/$darwin_base_archive-$darwin_arch"
5163 $LIPO -thin $darwin_arch -output "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" "$darwin_archive"
5164 cd "unfat-$$/$darwin_base_archive-$darwin_arch"
5165 func_extract_an_archive "`pwd`" "$darwin_base_archive"
37915166 cd "$darwin_curdir"
3792 $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}"
5167 $RM "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive"
37935168 done # $darwin_arches
37945169 ## Okay now we've a bunch of thin objects, gotta fatten them up :)
3795 darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$basename" | sort -u`
5170 darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$sed_basename" | sort -u`
37965171 darwin_file=
37975172 darwin_files=
37985173 for darwin_file in $darwin_filelist; do
38145189 my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP`
38155190 done
38165191
3817 func_extract_archives_result="$my_oldobjs"
5192 func_extract_archives_result=$my_oldobjs
38185193 }
38195194
38205195
38295204 #
38305205 # ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR
38315206 # variable will take. If 'yes', then the emitted script
3832 # will assume that the directory in which it is stored is
5207 # will assume that the directory where it is stored is
38335208 # the $objdir directory. This is a cygwin/mingw-specific
38345209 # behavior.
38355210 func_emit_wrapper ()
38405215 #! $SHELL
38415216
38425217 # $output - temporary wrapper script for $objdir/$outputname
3843 # Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
5218 # Generated by $PROGRAM (GNU $PACKAGE) $VERSION
38445219 #
38455220 # The $output program cannot be directly executed until all the libtool
38465221 # libraries that it depends on are installed.
38975272
38985273 # Very basic option parsing. These options are (a) specific to
38995274 # the libtool wrapper, (b) are identical between the wrapper
3900 # /script/ and the wrapper /executable/ which is used only on
5275 # /script/ and the wrapper /executable/ that is used only on
39015276 # windows platforms, and (c) all begin with the string "--lt-"
3902 # (application programs are unlikely to have options which match
5277 # (application programs are unlikely to have options that match
39035278 # this pattern).
39045279 #
39055280 # There are only two supported options: --lt-debug and
39325307
39335308 # Print the debug banner immediately:
39345309 if test -n \"\$lt_option_debug\"; then
3935 echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2
5310 echo \"$outputname:$output:\$LINENO: libtool wrapper (GNU $PACKAGE) $VERSION\" 1>&2
39365311 fi
39375312 }
39385313
39435318 lt_dump_args_N=1;
39445319 for lt_arg
39455320 do
3946 \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\"
5321 \$ECHO \"$outputname:$output:\$LINENO: newargv[\$lt_dump_args_N]: \$lt_arg\"
39475322 lt_dump_args_N=\`expr \$lt_dump_args_N + 1\`
39485323 done
39495324 }
39575332 *-*-mingw | *-*-os2* | *-cegcc*)
39585333 $ECHO "\
39595334 if test -n \"\$lt_option_debug\"; then
3960 \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2
5335 \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir\\\\\$program\" 1>&2
39615336 func_lt_dump_args \${1+\"\$@\"} 1>&2
39625337 fi
39635338 exec \"\$progdir\\\\\$program\" \${1+\"\$@\"}
39675342 *)
39685343 $ECHO "\
39695344 if test -n \"\$lt_option_debug\"; then
3970 \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2
5345 \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir/\$program\" 1>&2
39715346 func_lt_dump_args \${1+\"\$@\"} 1>&2
39725347 fi
39735348 exec \"\$progdir/\$program\" \${1+\"\$@\"}
40425417 test -n \"\$absdir\" && thisdir=\"\$absdir\"
40435418 "
40445419
4045 if test "$fast_install" = yes; then
5420 if test yes = "$fast_install"; then
40465421 $ECHO "\
40475422 program=lt-'$outputname'$exeext
40485423 progdir=\"\$thisdir/$objdir\"
40495424
40505425 if test ! -f \"\$progdir/\$program\" ||
4051 { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\
5426 { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | $SED 1q\`; \\
40525427 test \"X\$file\" != \"X\$progdir/\$program\"; }; then
40535428
40545429 file=\"\$\$-\$program\"
40655440 if test -n \"\$relink_command\"; then
40665441 if relink_command_output=\`eval \$relink_command 2>&1\`; then :
40675442 else
4068 $ECHO \"\$relink_command_output\" >&2
5443 \$ECHO \"\$relink_command_output\" >&2
40695444 $RM \"\$progdir/\$file\"
40705445 exit 1
40715446 fi
41005475 fi
41015476
41025477 # Export our shlibpath_var if we have one.
4103 if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
5478 if test yes = "$shlibpath_overrides_runpath" && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
41045479 $ECHO "\
41055480 # Add our own library path to $shlibpath_var
41065481 $shlibpath_var=\"$temp_rpath\$$shlibpath_var\"
41205495 fi
41215496 else
41225497 # The program doesn't exist.
4123 \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2
5498 \$ECHO \"\$0: error: '\$progdir/\$program' does not exist\" 1>&2
41245499 \$ECHO \"This script is just a wrapper for \$program.\" 1>&2
41255500 \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2
41265501 exit 1
41395514 cat <<EOF
41405515
41415516 /* $cwrappersource - temporary wrapper executable for $objdir/$outputname
4142 Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
5517 Generated by $PROGRAM (GNU $PACKAGE) $VERSION
41435518
41445519 The $output program cannot be directly executed until all the libtool
41455520 libraries that it depends on are installed.
41745549 #include <fcntl.h>
41755550 #include <sys/stat.h>
41765551
5552 #define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0)
5553
41775554 /* declarations of non-ANSI functions */
4178 #if defined(__MINGW32__)
5555 #if defined __MINGW32__
41795556 # ifdef __STRICT_ANSI__
41805557 int _putenv (const char *);
41815558 # endif
4182 #elif defined(__CYGWIN__)
5559 #elif defined __CYGWIN__
41835560 # ifdef __STRICT_ANSI__
41845561 char *realpath (const char *, char *);
41855562 int putenv (char *);
41865563 int setenv (const char *, const char *, int);
41875564 # endif
4188 /* #elif defined (other platforms) ... */
5565 /* #elif defined other_platform || defined ... */
41895566 #endif
41905567
41915568 /* portability defines, excluding path handling macros */
4192 #if defined(_MSC_VER)
5569 #if defined _MSC_VER
41935570 # define setmode _setmode
41945571 # define stat _stat
41955572 # define chmod _chmod
41965573 # define getcwd _getcwd
41975574 # define putenv _putenv
41985575 # define S_IXUSR _S_IEXEC
4199 # ifndef _INTPTR_T_DEFINED
4200 # define _INTPTR_T_DEFINED
4201 # define intptr_t int
4202 # endif
4203 #elif defined(__MINGW32__)
5576 #elif defined __MINGW32__
42045577 # define setmode _setmode
42055578 # define stat _stat
42065579 # define chmod _chmod
42075580 # define getcwd _getcwd
42085581 # define putenv _putenv
4209 #elif defined(__CYGWIN__)
5582 #elif defined __CYGWIN__
42105583 # define HAVE_SETENV
42115584 # define FOPEN_WB "wb"
4212 /* #elif defined (other platforms) ... */
5585 /* #elif defined other platforms ... */
42135586 #endif
42145587
4215 #if defined(PATH_MAX)
5588 #if defined PATH_MAX
42165589 # define LT_PATHMAX PATH_MAX
4217 #elif defined(MAXPATHLEN)
5590 #elif defined MAXPATHLEN
42185591 # define LT_PATHMAX MAXPATHLEN
42195592 #else
42205593 # define LT_PATHMAX 1024
42335606 # define PATH_SEPARATOR ':'
42345607 #endif
42355608
4236 #if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \
4237 defined (__OS2__)
5609 #if defined _WIN32 || defined __MSDOS__ || defined __DJGPP__ || \
5610 defined __OS2__
42385611 # define HAVE_DOS_BASED_FILE_SYSTEM
42395612 # define FOPEN_WB "wb"
42405613 # ifndef DIR_SEPARATOR_2
42675640
42685641 #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type)))
42695642 #define XFREE(stale) do { \
4270 if (stale) { free ((void *) stale); stale = 0; } \
5643 if (stale) { free (stale); stale = 0; } \
42715644 } while (0)
42725645
4273 #if defined(LT_DEBUGWRAPPER)
5646 #if defined LT_DEBUGWRAPPER
42745647 static int lt_debug = 1;
42755648 #else
42765649 static int lt_debug = 0;
42995672 EOF
43005673
43015674 cat <<EOF
4302 volatile const char * MAGIC_EXE = "$magic_exe";
5675 #if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 5)
5676 # define externally_visible volatile
5677 #else
5678 # define externally_visible __attribute__((externally_visible)) volatile
5679 #endif
5680 externally_visible const char * MAGIC_EXE = "$magic_exe";
43035681 const char * LIB_PATH_VARNAME = "$shlibpath_var";
43045682 EOF
43055683
4306 if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
5684 if test yes = "$shlibpath_overrides_runpath" && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
43075685 func_to_host_path "$temp_rpath"
43085686 cat <<EOF
43095687 const char * LIB_PATH_VALUE = "$func_to_host_path_result";
43275705 EOF
43285706 fi
43295707
4330 if test "$fast_install" = yes; then
5708 if test yes = "$fast_install"; then
43315709 cat <<EOF
43325710 const char * TARGET_PROGRAM_NAME = "lt-$outputname"; /* hopefully, no .exe */
43335711 EOF
43565734 char *actual_cwrapper_name;
43575735 char *target_name;
43585736 char *lt_argv_zero;
4359 intptr_t rval = 127;
5737 int rval = 127;
43605738
43615739 int i;
43625740
43635741 program_name = (char *) xstrdup (base_name (argv[0]));
4364 newargz = XMALLOC (char *, argc + 1);
5742 newargz = XMALLOC (char *, (size_t) argc + 1);
43655743
43665744 /* very simple arg parsing; don't want to rely on getopt
43675745 * also, copy all non cwrapper options to newargz, except
43705748 newargc=0;
43715749 for (i = 1; i < argc; i++)
43725750 {
4373 if (strcmp (argv[i], dumpscript_opt) == 0)
5751 if (STREQ (argv[i], dumpscript_opt))
43745752 {
43755753 EOF
4376 case "$host" in
5754 case $host in
43775755 *mingw* | *cygwin* )
43785756 # make stdout use "unix" line endings
43795757 echo " setmode(1,_O_BINARY);"
43845762 lt_dump_script (stdout);
43855763 return 0;
43865764 }
4387 if (strcmp (argv[i], debug_opt) == 0)
5765 if (STREQ (argv[i], debug_opt))
43885766 {
43895767 lt_debug = 1;
43905768 continue;
43915769 }
4392 if (strcmp (argv[i], ltwrapper_option_prefix) == 0)
5770 if (STREQ (argv[i], ltwrapper_option_prefix))
43935771 {
43945772 /* however, if there is an option in the LTWRAPPER_OPTION_PREFIX
43955773 namespace, but it is not one of the ones we know about and
44125790 EOF
44135791 cat <<EOF
44145792 /* The GNU banner must be the first non-error debug message */
4415 lt_debugprintf (__FILE__, __LINE__, "libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\n");
5793 lt_debugprintf (__FILE__, __LINE__, "libtool wrapper (GNU $PACKAGE) $VERSION\n");
44165794 EOF
44175795 cat <<"EOF"
44185796 lt_debugprintf (__FILE__, __LINE__, "(main) argv[0]: %s\n", argv[0]);
45235901 cat <<"EOF"
45245902 /* execv doesn't actually work on mingw as expected on unix */
45255903 newargz = prepare_spawn (newargz);
4526 rval = _spawnv (_P_WAIT, lt_argv_zero, (const char * const *) newargz);
5904 rval = (int) _spawnv (_P_WAIT, lt_argv_zero, (const char * const *) newargz);
45275905 if (rval == -1)
45285906 {
45295907 /* failed to start process */
45685946 {
45695947 const char *base;
45705948
4571 #if defined (HAVE_DOS_BASED_FILE_SYSTEM)
5949 #if defined HAVE_DOS_BASED_FILE_SYSTEM
45725950 /* Skip over the disk name in MSDOS pathnames. */
45735951 if (isalpha ((unsigned char) name[0]) && name[1] == ':')
45745952 name += 2;
46276005 const char *p_next;
46286006 /* static buffer for getcwd */
46296007 char tmp[LT_PATHMAX + 1];
4630 int tmp_len;
6008 size_t tmp_len;
46316009 char *concat_name;
46326010
46336011 lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n",
46376015 return NULL;
46386016
46396017 /* Absolute path? */
4640 #if defined (HAVE_DOS_BASED_FILE_SYSTEM)
6018 #if defined HAVE_DOS_BASED_FILE_SYSTEM
46416019 if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':')
46426020 {
46436021 concat_name = xstrdup (wrapper);
46556033 return concat_name;
46566034 XFREE (concat_name);
46576035 }
4658 #if defined (HAVE_DOS_BASED_FILE_SYSTEM)
6036 #if defined HAVE_DOS_BASED_FILE_SYSTEM
46596037 }
46606038 #endif
46616039
46786056 for (q = p; *q; q++)
46796057 if (IS_PATH_SEPARATOR (*q))
46806058 break;
4681 p_len = q - p;
6059 p_len = (size_t) (q - p);
46826060 p_next = (*q == '\0' ? q : q + 1);
46836061 if (p_len == 0)
46846062 {
47976175 if (patlen <= len)
47986176 {
47996177 str += len - patlen;
4800 if (strcmp (str, pat) == 0)
6178 if (STREQ (str, pat))
48016179 *str = '\0';
48026180 }
48036181 return str;
48626240 char *str = xstrdup (value);
48636241 setenv (name, str, 1);
48646242 #else
4865 int len = strlen (name) + 1 + strlen (value) + 1;
6243 size_t len = strlen (name) + 1 + strlen (value) + 1;
48666244 char *str = XMALLOC (char, len);
48676245 sprintf (str, "%s=%s", name, value);
48686246 if (putenv (str) != EXIT_SUCCESS)
48796257 char *new_value;
48806258 if (orig_value && *orig_value)
48816259 {
4882 int orig_value_len = strlen (orig_value);
4883 int add_len = strlen (add);
6260 size_t orig_value_len = strlen (orig_value);
6261 size_t add_len = strlen (add);
48846262 new_value = XMALLOC (char, add_len + orig_value_len + 1);
48856263 if (to_end)
48866264 {
49116289 {
49126290 char *new_value = lt_extend_str (getenv (name), value, 0);
49136291 /* some systems can't cope with a ':'-terminated path #' */
4914 int len = strlen (new_value);
4915 while (((len = strlen (new_value)) > 0) && IS_PATH_SEPARATOR (new_value[len-1]))
6292 size_t len = strlen (new_value);
6293 while ((len > 0) && IS_PATH_SEPARATOR (new_value[len-1]))
49166294 {
4917 new_value[len-1] = '\0';
6295 new_value[--len] = '\0';
49186296 }
49196297 lt_setenv (name, new_value);
49206298 XFREE (new_value);
50816459 # True if ARG is an import lib, as indicated by $file_magic_cmd
50826460 func_win32_import_lib_p ()
50836461 {
5084 $opt_debug
6462 $debug_cmd
6463
50856464 case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in
50866465 *import*) : ;;
50876466 *) false ;;
50886467 esac
50896468 }
50906469
6470 # func_suncc_cstd_abi
6471 # !!ONLY CALL THIS FOR SUN CC AFTER $compile_command IS FULLY EXPANDED!!
6472 # Several compiler flags select an ABI that is incompatible with the
6473 # Cstd library. Avoid specifying it if any are in CXXFLAGS.
6474 func_suncc_cstd_abi ()
6475 {
6476 $debug_cmd
6477
6478 case " $compile_command " in
6479 *" -compat=g "*|*\ -std=c++[0-9][0-9]\ *|*" -library=stdcxx4 "*|*" -library=stlport4 "*)
6480 suncc_use_cstd_abi=no
6481 ;;
6482 *)
6483 suncc_use_cstd_abi=yes
6484 ;;
6485 esac
6486 }
6487
50916488 # func_mode_link arg...
50926489 func_mode_link ()
50936490 {
5094 $opt_debug
6491 $debug_cmd
6492
50956493 case $host in
50966494 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
50976495 # It is impossible to link a dll without this setting, and
50986496 # we shouldn't force the makefile maintainer to figure out
5099 # which system we are compiling for in order to pass an extra
6497 # what system we are compiling for in order to pass an extra
51006498 # flag for every libtool invocation.
51016499 # allow_undefined=no
51026500
51036501 # FIXME: Unfortunately, there are problems with the above when trying
5104 # to make a dll which has undefined symbols, in which case not
6502 # to make a dll that has undefined symbols, in which case not
51056503 # even a static library is built. For now, we need to specify
51066504 # -no-undefined on the libtool link line when we can be certain
51076505 # that all symbols are satisfied, otherwise we get a static library.
51456543 module=no
51466544 no_install=no
51476545 objs=
6546 os2dllname=
51486547 non_pic_objects=
51496548 precious_files_regex=
51506549 prefer_static_libs=no
5151 preload=no
6550 preload=false
51526551 prev=
51536552 prevarg=
51546553 release=
51606559 vinfo=
51616560 vinfo_number=no
51626561 weak_libs=
5163 single_module="${wl}-single_module"
6562 single_module=$wl-single_module
51646563 func_infer_tag $base_compile
51656564
51666565 # We need to know -static, to get the right output filenames.
51686567 do
51696568 case $arg in
51706569 -shared)
5171 test "$build_libtool_libs" != yes && \
5172 func_fatal_configuration "can not build a shared library"
6570 test yes != "$build_libtool_libs" \
6571 && func_fatal_configuration "cannot build a shared library"
51736572 build_old_libs=no
51746573 break
51756574 ;;
51766575 -all-static | -static | -static-libtool-libs)
51776576 case $arg in
51786577 -all-static)
5179 if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then
6578 if test yes = "$build_libtool_libs" && test -z "$link_static_flag"; then
51806579 func_warning "complete static linking is impossible in this configuration"
51816580 fi
51826581 if test -n "$link_static_flag"; then
52096608
52106609 # Go through the arguments, transforming them on the way.
52116610 while test "$#" -gt 0; do
5212 arg="$1"
6611 arg=$1
52136612 shift
52146613 func_quote_for_eval "$arg"
52156614 qarg=$func_quote_for_eval_unquoted_result
52266625
52276626 case $prev in
52286627 bindir)
5229 bindir="$arg"
6628 bindir=$arg
52306629 prev=
52316630 continue
52326631 ;;
52336632 dlfiles|dlprefiles)
5234 if test "$preload" = no; then
6633 $preload || {
52356634 # Add the symbol object into the linking commands.
52366635 func_append compile_command " @SYMFILE@"
52376636 func_append finalize_command " @SYMFILE@"
5238 preload=yes
5239 fi
6637 preload=:
6638 }
52406639 case $arg in
52416640 *.la | *.lo) ;; # We handle these cases below.
52426641 force)
5243 if test "$dlself" = no; then
6642 if test no = "$dlself"; then
52446643 dlself=needless
52456644 export_dynamic=yes
52466645 fi
52486647 continue
52496648 ;;
52506649 self)
5251 if test "$prev" = dlprefiles; then
6650 if test dlprefiles = "$prev"; then
52526651 dlself=yes
5253 elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then
6652 elif test dlfiles = "$prev" && test yes != "$dlopen_self"; then
52546653 dlself=yes
52556654 else
52566655 dlself=needless
52606659 continue
52616660 ;;
52626661 *)
5263 if test "$prev" = dlfiles; then
6662 if test dlfiles = "$prev"; then
52646663 func_append dlfiles " $arg"
52656664 else
52666665 func_append dlprefiles " $arg"
52716670 esac
52726671 ;;
52736672 expsyms)
5274 export_symbols="$arg"
6673 export_symbols=$arg
52756674 test -f "$arg" \
5276 || func_fatal_error "symbol file \`$arg' does not exist"
6675 || func_fatal_error "symbol file '$arg' does not exist"
52776676 prev=
52786677 continue
52796678 ;;
52806679 expsyms_regex)
5281 export_symbols_regex="$arg"
6680 export_symbols_regex=$arg
52826681 prev=
52836682 continue
52846683 ;;
52966695 continue
52976696 ;;
52986697 inst_prefix)
5299 inst_prefix_dir="$arg"
6698 inst_prefix_dir=$arg
6699 prev=
6700 continue
6701 ;;
6702 mllvm)
6703 # Clang does not use LLVM to link, so we can simply discard any
6704 # '-mllvm $arg' options when doing the link step.
53006705 prev=
53016706 continue
53026707 ;;
53206725
53216726 if test -z "$pic_object" ||
53226727 test -z "$non_pic_object" ||
5323 test "$pic_object" = none &&
5324 test "$non_pic_object" = none; then
5325 func_fatal_error "cannot find name of object for \`$arg'"
6728 test none = "$pic_object" &&
6729 test none = "$non_pic_object"; then
6730 func_fatal_error "cannot find name of object for '$arg'"
53266731 fi
53276732
53286733 # Extract subdirectory from the argument.
53296734 func_dirname "$arg" "/" ""
5330 xdir="$func_dirname_result"
5331
5332 if test "$pic_object" != none; then
6735 xdir=$func_dirname_result
6736
6737 if test none != "$pic_object"; then
53336738 # Prepend the subdirectory the object is found in.
5334 pic_object="$xdir$pic_object"
5335
5336 if test "$prev" = dlfiles; then
5337 if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
6739 pic_object=$xdir$pic_object
6740
6741 if test dlfiles = "$prev"; then
6742 if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then
53386743 func_append dlfiles " $pic_object"
53396744 prev=
53406745 continue
53456750 fi
53466751
53476752 # CHECK ME: I think I busted this. -Ossama
5348 if test "$prev" = dlprefiles; then
6753 if test dlprefiles = "$prev"; then
53496754 # Preload the old-style object.
53506755 func_append dlprefiles " $pic_object"
53516756 prev=
53536758
53546759 # A PIC object.
53556760 func_append libobjs " $pic_object"
5356 arg="$pic_object"
6761 arg=$pic_object
53576762 fi
53586763
53596764 # Non-PIC object.
5360 if test "$non_pic_object" != none; then
6765 if test none != "$non_pic_object"; then
53616766 # Prepend the subdirectory the object is found in.
5362 non_pic_object="$xdir$non_pic_object"
6767 non_pic_object=$xdir$non_pic_object
53636768
53646769 # A standard non-PIC object
53656770 func_append non_pic_objects " $non_pic_object"
5366 if test -z "$pic_object" || test "$pic_object" = none ; then
5367 arg="$non_pic_object"
6771 if test -z "$pic_object" || test none = "$pic_object"; then
6772 arg=$non_pic_object
53686773 fi
53696774 else
53706775 # If the PIC object exists, use it instead.
53716776 # $xdir was prepended to $pic_object above.
5372 non_pic_object="$pic_object"
6777 non_pic_object=$pic_object
53736778 func_append non_pic_objects " $non_pic_object"
53746779 fi
53756780 else
53776782 if $opt_dry_run; then
53786783 # Extract subdirectory from the argument.
53796784 func_dirname "$arg" "/" ""
5380 xdir="$func_dirname_result"
6785 xdir=$func_dirname_result
53816786
53826787 func_lo2o "$arg"
53836788 pic_object=$xdir$objdir/$func_lo2o_result
53856790 func_append libobjs " $pic_object"
53866791 func_append non_pic_objects " $non_pic_object"
53876792 else
5388 func_fatal_error "\`$arg' is not a valid libtool object"
6793 func_fatal_error "'$arg' is not a valid libtool object"
53896794 fi
53906795 fi
53916796 done
53926797 else
5393 func_fatal_error "link input file \`$arg' does not exist"
6798 func_fatal_error "link input file '$arg' does not exist"
53946799 fi
53956800 arg=$save_arg
53966801 prev=
53976802 continue
53986803 ;;
6804 os2dllname)
6805 os2dllname=$arg
6806 prev=
6807 continue
6808 ;;
53996809 precious_regex)
5400 precious_files_regex="$arg"
6810 precious_files_regex=$arg
54016811 prev=
54026812 continue
54036813 ;;
54046814 release)
5405 release="-$arg"
6815 release=-$arg
54066816 prev=
54076817 continue
54086818 ;;
54146824 func_fatal_error "only absolute run-paths are allowed"
54156825 ;;
54166826 esac
5417 if test "$prev" = rpath; then
6827 if test rpath = "$prev"; then
54186828 case "$rpath " in
54196829 *" $arg "*) ;;
54206830 *) func_append rpath " $arg" ;;
54296839 continue
54306840 ;;
54316841 shrext)
5432 shrext_cmds="$arg"
6842 shrext_cmds=$arg
54336843 prev=
54346844 continue
54356845 ;;
54696879 esac
54706880 fi # test -n "$prev"
54716881
5472 prevarg="$arg"
6882 prevarg=$arg
54736883
54746884 case $arg in
54756885 -all-static)
54836893
54846894 -allow-undefined)
54856895 # FIXME: remove this flag sometime in the future.
5486 func_fatal_error "\`-allow-undefined' must not be used because it is the default"
6896 func_fatal_error "'-allow-undefined' must not be used because it is the default"
54876897 ;;
54886898
54896899 -avoid-version)
55156925 if test -n "$export_symbols" || test -n "$export_symbols_regex"; then
55166926 func_fatal_error "more than one -exported-symbols argument is not allowed"
55176927 fi
5518 if test "X$arg" = "X-export-symbols"; then
6928 if test X-export-symbols = "X$arg"; then
55196929 prev=expsyms
55206930 else
55216931 prev=expsyms_regex
55496959 func_stripname "-L" '' "$arg"
55506960 if test -z "$func_stripname_result"; then
55516961 if test "$#" -gt 0; then
5552 func_fatal_error "require no space between \`-L' and \`$1'"
6962 func_fatal_error "require no space between '-L' and '$1'"
55536963 else
5554 func_fatal_error "need path for \`-L' option"
6964 func_fatal_error "need path for '-L' option"
55556965 fi
55566966 fi
55576967 func_resolve_sysroot "$func_stripname_result"
55626972 *)
55636973 absdir=`cd "$dir" && pwd`
55646974 test -z "$absdir" && \
5565 func_fatal_error "cannot determine absolute directory name of \`$dir'"
5566 dir="$absdir"
6975 func_fatal_error "cannot determine absolute directory name of '$dir'"
6976 dir=$absdir
55676977 ;;
55686978 esac
55696979 case "$deplibs " in
55987008 ;;
55997009
56007010 -l*)
5601 if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then
7011 if test X-lc = "X$arg" || test X-lm = "X$arg"; then
56027012 case $host in
56037013 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*)
56047014 # These systems don't actually have a C or math library (as such)
56067016 ;;
56077017 *-*-os2*)
56087018 # These systems don't actually have a C library (as such)
5609 test "X$arg" = "X-lc" && continue
7019 test X-lc = "X$arg" && continue
56107020 ;;
5611 *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
7021 *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig*)
56127022 # Do not include libc due to us having libc/libc_r.
5613 test "X$arg" = "X-lc" && continue
7023 test X-lc = "X$arg" && continue
56147024 ;;
56157025 *-*-rhapsody* | *-*-darwin1.[012])
56167026 # Rhapsody C and math libraries are in the System framework
56197029 ;;
56207030 *-*-sco3.2v5* | *-*-sco5v6*)
56217031 # Causes problems with __ctype
5622 test "X$arg" = "X-lc" && continue
7032 test X-lc = "X$arg" && continue
56237033 ;;
56247034 *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*)
56257035 # Compiler inserts libc in the correct place for threads to work
5626 test "X$arg" = "X-lc" && continue
7036 test X-lc = "X$arg" && continue
56277037 ;;
56287038 esac
5629 elif test "X$arg" = "X-lc_r"; then
7039 elif test X-lc_r = "X$arg"; then
56307040 case $host in
5631 *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
7041 *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig*)
56327042 # Do not include libc_r directly, use -pthread flag.
56337043 continue
56347044 ;;
56357045 esac
56367046 fi
56377047 func_append deplibs " $arg"
7048 continue
7049 ;;
7050
7051 -mllvm)
7052 prev=mllvm
56387053 continue
56397054 ;;
56407055
56677082 ;;
56687083
56697084 -multi_module)
5670 single_module="${wl}-multi_module"
7085 single_module=$wl-multi_module
56717086 continue
56727087 ;;
56737088
56817096 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*)
56827097 # The PATH hackery in wrapper scripts is required on Windows
56837098 # and Darwin in order for the loader to find any dlls it needs.
5684 func_warning "\`-no-install' is ignored for $host"
5685 func_warning "assuming \`-no-fast-install' instead"
7099 func_warning "'-no-install' is ignored for $host"
7100 func_warning "assuming '-no-fast-install' instead"
56867101 fast_install=no
56877102 ;;
56887103 *) no_install=yes ;;
56977112
56987113 -objectlist)
56997114 prev=objectlist
7115 continue
7116 ;;
7117
7118 -os2dllname)
7119 prev=os2dllname
57007120 continue
57017121 ;;
57027122
57877207 func_stripname '-Wc,' '' "$arg"
57887208 args=$func_stripname_result
57897209 arg=
5790 save_ifs="$IFS"; IFS=','
7210 save_ifs=$IFS; IFS=,
57917211 for flag in $args; do
5792 IFS="$save_ifs"
7212 IFS=$save_ifs
57937213 func_quote_for_eval "$flag"
57947214 func_append arg " $func_quote_for_eval_result"
57957215 func_append compiler_flags " $func_quote_for_eval_result"
57967216 done
5797 IFS="$save_ifs"
7217 IFS=$save_ifs
57987218 func_stripname ' ' '' "$arg"
57997219 arg=$func_stripname_result
58007220 ;;
58037223 func_stripname '-Wl,' '' "$arg"
58047224 args=$func_stripname_result
58057225 arg=
5806 save_ifs="$IFS"; IFS=','
7226 save_ifs=$IFS; IFS=,
58077227 for flag in $args; do
5808 IFS="$save_ifs"
7228 IFS=$save_ifs
58097229 func_quote_for_eval "$flag"
58107230 func_append arg " $wl$func_quote_for_eval_result"
58117231 func_append compiler_flags " $wl$func_quote_for_eval_result"
58127232 func_append linker_flags " $func_quote_for_eval_result"
58137233 done
5814 IFS="$save_ifs"
7234 IFS=$save_ifs
58157235 func_stripname ' ' '' "$arg"
58167236 arg=$func_stripname_result
58177237 ;;
58347254 # -msg_* for osf cc
58357255 -msg_*)
58367256 func_quote_for_eval "$arg"
5837 arg="$func_quote_for_eval_result"
7257 arg=$func_quote_for_eval_result
58387258 ;;
58397259
58407260 # Flags to be passed through unchanged, with rationale:
58467266 # -m*, -t[45]*, -txscale* architecture-specific flags for GCC
58477267 # -F/path path to uninstalled frameworks, gcc on darwin
58487268 # -p, -pg, --coverage, -fprofile-* profiling flags for GCC
7269 # -fstack-protector* stack protector flags for GCC
58497270 # @file GCC response files
58507271 # -tp=* Portland pgcc target processor selection
58517272 # --sysroot=* for sysroot support
5852 # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization
7273 # -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization
7274 # -stdlib=* select c++ std lib with clang
58537275 -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
58547276 -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
5855 -O*|-flto*|-fwhopr*|-fuse-linker-plugin)
7277 -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*)
58567278 func_quote_for_eval "$arg"
5857 arg="$func_quote_for_eval_result"
7279 arg=$func_quote_for_eval_result
58587280 func_append compile_command " $arg"
58597281 func_append finalize_command " $arg"
58607282 func_append compiler_flags " $arg"
58617283 continue
58627284 ;;
58637285
7286 -Z*)
7287 if test os2 = "`expr $host : '.*\(os2\)'`"; then
7288 # OS/2 uses -Zxxx to specify OS/2-specific options
7289 compiler_flags="$compiler_flags $arg"
7290 func_append compile_command " $arg"
7291 func_append finalize_command " $arg"
7292 case $arg in
7293 -Zlinker | -Zstack)
7294 prev=xcompiler
7295 ;;
7296 esac
7297 continue
7298 else
7299 # Otherwise treat like 'Some other compiler flag' below
7300 func_quote_for_eval "$arg"
7301 arg=$func_quote_for_eval_result
7302 fi
7303 ;;
7304
58647305 # Some other compiler flag.
58657306 -* | +*)
58667307 func_quote_for_eval "$arg"
5867 arg="$func_quote_for_eval_result"
7308 arg=$func_quote_for_eval_result
58687309 ;;
58697310
58707311 *.$objext)
58857326
58867327 if test -z "$pic_object" ||
58877328 test -z "$non_pic_object" ||
5888 test "$pic_object" = none &&
5889 test "$non_pic_object" = none; then
5890 func_fatal_error "cannot find name of object for \`$arg'"
7329 test none = "$pic_object" &&
7330 test none = "$non_pic_object"; then
7331 func_fatal_error "cannot find name of object for '$arg'"
58917332 fi
58927333
58937334 # Extract subdirectory from the argument.
58947335 func_dirname "$arg" "/" ""
5895 xdir="$func_dirname_result"
5896
5897 if test "$pic_object" != none; then
7336 xdir=$func_dirname_result
7337
7338 test none = "$pic_object" || {
58987339 # Prepend the subdirectory the object is found in.
5899 pic_object="$xdir$pic_object"
5900
5901 if test "$prev" = dlfiles; then
5902 if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
7340 pic_object=$xdir$pic_object
7341
7342 if test dlfiles = "$prev"; then
7343 if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then
59037344 func_append dlfiles " $pic_object"
59047345 prev=
59057346 continue
59107351 fi
59117352
59127353 # CHECK ME: I think I busted this. -Ossama
5913 if test "$prev" = dlprefiles; then
7354 if test dlprefiles = "$prev"; then
59147355 # Preload the old-style object.
59157356 func_append dlprefiles " $pic_object"
59167357 prev=
59187359
59197360 # A PIC object.
59207361 func_append libobjs " $pic_object"
5921 arg="$pic_object"
5922 fi
7362 arg=$pic_object
7363 }
59237364
59247365 # Non-PIC object.
5925 if test "$non_pic_object" != none; then
7366 if test none != "$non_pic_object"; then
59267367 # Prepend the subdirectory the object is found in.
5927 non_pic_object="$xdir$non_pic_object"
7368 non_pic_object=$xdir$non_pic_object
59287369
59297370 # A standard non-PIC object
59307371 func_append non_pic_objects " $non_pic_object"
5931 if test -z "$pic_object" || test "$pic_object" = none ; then
5932 arg="$non_pic_object"
7372 if test -z "$pic_object" || test none = "$pic_object"; then
7373 arg=$non_pic_object
59337374 fi
59347375 else
59357376 # If the PIC object exists, use it instead.
59367377 # $xdir was prepended to $pic_object above.
5937 non_pic_object="$pic_object"
7378 non_pic_object=$pic_object
59387379 func_append non_pic_objects " $non_pic_object"
59397380 fi
59407381 else
59427383 if $opt_dry_run; then
59437384 # Extract subdirectory from the argument.
59447385 func_dirname "$arg" "/" ""
5945 xdir="$func_dirname_result"
7386 xdir=$func_dirname_result
59467387
59477388 func_lo2o "$arg"
59487389 pic_object=$xdir$objdir/$func_lo2o_result
59507391 func_append libobjs " $pic_object"
59517392 func_append non_pic_objects " $non_pic_object"
59527393 else
5953 func_fatal_error "\`$arg' is not a valid libtool object"
7394 func_fatal_error "'$arg' is not a valid libtool object"
59547395 fi
59557396 fi
59567397 ;;
59667407 # A libtool-controlled library.
59677408
59687409 func_resolve_sysroot "$arg"
5969 if test "$prev" = dlfiles; then
7410 if test dlfiles = "$prev"; then
59707411 # This library was specified with -dlopen.
59717412 func_append dlfiles " $func_resolve_sysroot_result"
59727413 prev=
5973 elif test "$prev" = dlprefiles; then
7414 elif test dlprefiles = "$prev"; then
59747415 # The library was specified with -dlpreopen.
59757416 func_append dlprefiles " $func_resolve_sysroot_result"
59767417 prev=
59857426 # Unknown arguments in both finalize_command and compile_command need
59867427 # to be aesthetically quoted because they are evaled later.
59877428 func_quote_for_eval "$arg"
5988 arg="$func_quote_for_eval_result"
7429 arg=$func_quote_for_eval_result
59897430 ;;
59907431 esac # arg
59917432
59977438 done # argument parsing loop
59987439
59997440 test -n "$prev" && \
6000 func_fatal_help "the \`$prevarg' option requires an argument"
6001
6002 if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then
7441 func_fatal_help "the '$prevarg' option requires an argument"
7442
7443 if test yes = "$export_dynamic" && test -n "$export_dynamic_flag_spec"; then
60037444 eval arg=\"$export_dynamic_flag_spec\"
60047445 func_append compile_command " $arg"
60057446 func_append finalize_command " $arg"
60087449 oldlibs=
60097450 # calculate the name of the file, without its directory
60107451 func_basename "$output"
6011 outputname="$func_basename_result"
6012 libobjs_save="$libobjs"
7452 outputname=$func_basename_result
7453 libobjs_save=$libobjs
60137454
60147455 if test -n "$shlibpath_var"; then
60157456 # get the directories listed in $shlibpath_var
6016 eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\`
7457 eval shlib_search_path=\`\$ECHO \"\$$shlibpath_var\" \| \$SED \'s/:/ /g\'\`
60177458 else
60187459 shlib_search_path=
60197460 fi
60207461 eval sys_lib_search_path=\"$sys_lib_search_path_spec\"
60217462 eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\"
60227463
7464 # Definition is injected by LT_CONFIG during libtool generation.
7465 func_munge_path_list sys_lib_dlsearch_path "$LT_SYS_LIBRARY_PATH"
7466
60237467 func_dirname "$output" "/" ""
6024 output_objdir="$func_dirname_result$objdir"
7468 output_objdir=$func_dirname_result$objdir
60257469 func_to_tool_file "$output_objdir/"
60267470 tool_output_objdir=$func_to_tool_file_result
60277471 # Create the object directory.
60447488 # Find all interdependent deplibs by searching for libraries
60457489 # that are linked more than once (e.g. -la -lb -la)
60467490 for deplib in $deplibs; do
6047 if $opt_preserve_dup_deps ; then
7491 if $opt_preserve_dup_deps; then
60487492 case "$libs " in
60497493 *" $deplib "*) func_append specialdeplibs " $deplib" ;;
60507494 esac
60527496 func_append libs " $deplib"
60537497 done
60547498
6055 if test "$linkmode" = lib; then
7499 if test lib = "$linkmode"; then
60567500 libs="$predeps $libs $compiler_lib_search_path $postdeps"
60577501
60587502 # Compute libraries that are listed more than once in $predeps
60847528 case $file in
60857529 *.la) ;;
60867530 *)
6087 func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file"
7531 func_fatal_help "libraries can '-dlopen' only libtool libraries: $file"
60887532 ;;
60897533 esac
60907534 done
60927536 prog)
60937537 compile_deplibs=
60947538 finalize_deplibs=
6095 alldeplibs=no
7539 alldeplibs=false
60967540 newdlfiles=
60977541 newdlprefiles=
60987542 passes="conv scan dlopen dlpreopen link"
61047548 for pass in $passes; do
61057549 # The preopen pass in lib mode reverses $deplibs; put it back here
61067550 # so that -L comes before libs that need it for instance...
6107 if test "$linkmode,$pass" = "lib,link"; then
7551 if test lib,link = "$linkmode,$pass"; then
61087552 ## FIXME: Find the place where the list is rebuilt in the wrong
61097553 ## order, and fix it there properly
61107554 tmp_deplibs=
61117555 for deplib in $deplibs; do
61127556 tmp_deplibs="$deplib $tmp_deplibs"
61137557 done
6114 deplibs="$tmp_deplibs"
7558 deplibs=$tmp_deplibs
61157559 fi
61167560
6117 if test "$linkmode,$pass" = "lib,link" ||
6118 test "$linkmode,$pass" = "prog,scan"; then
6119 libs="$deplibs"
7561 if test lib,link = "$linkmode,$pass" ||
7562 test prog,scan = "$linkmode,$pass"; then
7563 libs=$deplibs
61207564 deplibs=
61217565 fi
6122 if test "$linkmode" = prog; then
7566 if test prog = "$linkmode"; then
61237567 case $pass in
6124 dlopen) libs="$dlfiles" ;;
6125 dlpreopen) libs="$dlprefiles" ;;
6126 link)
6127 libs="$deplibs %DEPLIBS%"
6128 test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs"
6129 ;;
7568 dlopen) libs=$dlfiles ;;
7569 dlpreopen) libs=$dlprefiles ;;
7570 link) libs="$deplibs %DEPLIBS% $dependency_libs" ;;
61307571 esac
61317572 fi
6132 if test "$linkmode,$pass" = "lib,dlpreopen"; then
7573 if test lib,dlpreopen = "$linkmode,$pass"; then
61337574 # Collect and forward deplibs of preopened libtool libs
61347575 for lib in $dlprefiles; do
61357576 # Ignore non-libtool-libs
61507591 esac
61517592 done
61527593 done
6153 libs="$dlprefiles"
7594 libs=$dlprefiles
61547595 fi
6155 if test "$pass" = dlopen; then
7596 if test dlopen = "$pass"; then
61567597 # Collect dlpreopened libraries
6157 save_deplibs="$deplibs"
7598 save_deplibs=$deplibs
61587599 deplibs=
61597600 fi
61607601
61617602 for deplib in $libs; do
61627603 lib=
6163 found=no
7604 found=false
61647605 case $deplib in
61657606 -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \
61667607 |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*)
6167 if test "$linkmode,$pass" = "prog,link"; then
7608 if test prog,link = "$linkmode,$pass"; then
61687609 compile_deplibs="$deplib $compile_deplibs"
61697610 finalize_deplibs="$deplib $finalize_deplibs"
61707611 else
61717612 func_append compiler_flags " $deplib"
6172 if test "$linkmode" = lib ; then
7613 if test lib = "$linkmode"; then
61737614 case "$new_inherited_linker_flags " in
61747615 *" $deplib "*) ;;
61757616 * ) func_append new_inherited_linker_flags " $deplib" ;;
61797620 continue
61807621 ;;
61817622 -l*)
6182 if test "$linkmode" != lib && test "$linkmode" != prog; then
6183 func_warning "\`-l' is ignored for archives/objects"
7623 if test lib != "$linkmode" && test prog != "$linkmode"; then
7624 func_warning "'-l' is ignored for archives/objects"
61847625 continue
61857626 fi
61867627 func_stripname '-l' '' "$deplib"
61877628 name=$func_stripname_result
6188 if test "$linkmode" = lib; then
7629 if test lib = "$linkmode"; then
61897630 searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path"
61907631 else
61917632 searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path"
61937634 for searchdir in $searchdirs; do
61947635 for search_ext in .la $std_shrext .so .a; do
61957636 # Search the libtool library
6196 lib="$searchdir/lib${name}${search_ext}"
7637 lib=$searchdir/lib$name$search_ext
61977638 if test -f "$lib"; then
6198 if test "$search_ext" = ".la"; then
6199 found=yes
7639 if test .la = "$search_ext"; then
7640 found=:
62007641 else
6201 found=no
7642 found=false
62027643 fi
62037644 break 2
62047645 fi
62057646 done
62067647 done
6207 if test "$found" != yes; then
6208 # deplib doesn't seem to be a libtool library
6209 if test "$linkmode,$pass" = "prog,link"; then
6210 compile_deplibs="$deplib $compile_deplibs"
6211 finalize_deplibs="$deplib $finalize_deplibs"
6212 else
6213 deplibs="$deplib $deplibs"
6214 test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
6215 fi
6216 continue
6217 else # deplib is a libtool library
7648 if $found; then
7649 # deplib is a libtool library
62187650 # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib,
62197651 # We need to do some special things here, and not later.
6220 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7652 if test yes = "$allow_libtool_libs_with_static_runtimes"; then
62217653 case " $predeps $postdeps " in
62227654 *" $deplib "*)
62237655 if func_lalib_p "$lib"; then
62257657 old_library=
62267658 func_source "$lib"
62277659 for l in $old_library $library_names; do
6228 ll="$l"
7660 ll=$l
62297661 done
6230 if test "X$ll" = "X$old_library" ; then # only static version available
6231 found=no
7662 if test "X$ll" = "X$old_library"; then # only static version available
7663 found=false
62327664 func_dirname "$lib" "" "."
6233 ladir="$func_dirname_result"
7665 ladir=$func_dirname_result
62347666 lib=$ladir/$old_library
6235 if test "$linkmode,$pass" = "prog,link"; then
7667 if test prog,link = "$linkmode,$pass"; then
62367668 compile_deplibs="$deplib $compile_deplibs"
62377669 finalize_deplibs="$deplib $finalize_deplibs"
62387670 else
62397671 deplibs="$deplib $deplibs"
6240 test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
7672 test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs"
62417673 fi
62427674 continue
62437675 fi
62467678 *) ;;
62477679 esac
62487680 fi
7681 else
7682 # deplib doesn't seem to be a libtool library
7683 if test prog,link = "$linkmode,$pass"; then
7684 compile_deplibs="$deplib $compile_deplibs"
7685 finalize_deplibs="$deplib $finalize_deplibs"
7686 else
7687 deplibs="$deplib $deplibs"
7688 test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs"
7689 fi
7690 continue
62497691 fi
62507692 ;; # -l
62517693 *.ltframework)
6252 if test "$linkmode,$pass" = "prog,link"; then
7694 if test prog,link = "$linkmode,$pass"; then
62537695 compile_deplibs="$deplib $compile_deplibs"
62547696 finalize_deplibs="$deplib $finalize_deplibs"
62557697 else
62567698 deplibs="$deplib $deplibs"
6257 if test "$linkmode" = lib ; then
7699 if test lib = "$linkmode"; then
62587700 case "$new_inherited_linker_flags " in
62597701 *" $deplib "*) ;;
62607702 * ) func_append new_inherited_linker_flags " $deplib" ;;
62677709 case $linkmode in
62687710 lib)
62697711 deplibs="$deplib $deplibs"
6270 test "$pass" = conv && continue
7712 test conv = "$pass" && continue
62717713 newdependency_libs="$deplib $newdependency_libs"
62727714 func_stripname '-L' '' "$deplib"
62737715 func_resolve_sysroot "$func_stripname_result"
62747716 func_append newlib_search_path " $func_resolve_sysroot_result"
62757717 ;;
62767718 prog)
6277 if test "$pass" = conv; then
7719 if test conv = "$pass"; then
62787720 deplibs="$deplib $deplibs"
62797721 continue
62807722 fi
6281 if test "$pass" = scan; then
7723 if test scan = "$pass"; then
62827724 deplibs="$deplib $deplibs"
62837725 else
62847726 compile_deplibs="$deplib $compile_deplibs"
62897731 func_append newlib_search_path " $func_resolve_sysroot_result"
62907732 ;;
62917733 *)
6292 func_warning "\`-L' is ignored for archives/objects"
7734 func_warning "'-L' is ignored for archives/objects"
62937735 ;;
62947736 esac # linkmode
62957737 continue
62967738 ;; # -L
62977739 -R*)
6298 if test "$pass" = link; then
7740 if test link = "$pass"; then
62997741 func_stripname '-R' '' "$deplib"
63007742 func_resolve_sysroot "$func_stripname_result"
63017743 dir=$func_resolve_sysroot_result
63137755 lib=$func_resolve_sysroot_result
63147756 ;;
63157757 *.$libext)
6316 if test "$pass" = conv; then
7758 if test conv = "$pass"; then
63177759 deplibs="$deplib $deplibs"
63187760 continue
63197761 fi
63247766 case " $dlpreconveniencelibs " in
63257767 *" $deplib "*) ;;
63267768 *)
6327 valid_a_lib=no
7769 valid_a_lib=false
63287770 case $deplibs_check_method in
63297771 match_pattern*)
63307772 set dummy $deplibs_check_method; shift
63317773 match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
63327774 if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \
63337775 | $EGREP "$match_pattern_regex" > /dev/null; then
6334 valid_a_lib=yes
7776 valid_a_lib=:
63357777 fi
63367778 ;;
63377779 pass_all)
6338 valid_a_lib=yes
7780 valid_a_lib=:
63397781 ;;
63407782 esac
6341 if test "$valid_a_lib" != yes; then
7783 if $valid_a_lib; then
7784 echo
7785 $ECHO "*** Warning: Linking the shared library $output against the"
7786 $ECHO "*** static library $deplib is not portable!"
7787 deplibs="$deplib $deplibs"
7788 else
63427789 echo
63437790 $ECHO "*** Warning: Trying to link with static lib archive $deplib."
63447791 echo "*** I have the capability to make that library automatically link in when"
63467793 echo "*** shared version of the library, which you do not appear to have"
63477794 echo "*** because the file extensions .$libext of this argument makes me believe"
63487795 echo "*** that it is just a static archive that I should not use here."
6349 else
6350 echo
6351 $ECHO "*** Warning: Linking the shared library $output against the"
6352 $ECHO "*** static library $deplib is not portable!"
6353 deplibs="$deplib $deplibs"
63547796 fi
63557797 ;;
63567798 esac
63577799 continue
63587800 ;;
63597801 prog)
6360 if test "$pass" != link; then
7802 if test link != "$pass"; then
63617803 deplibs="$deplib $deplibs"
63627804 else
63637805 compile_deplibs="$deplib $compile_deplibs"
63687810 esac # linkmode
63697811 ;; # *.$libext
63707812 *.lo | *.$objext)
6371 if test "$pass" = conv; then
7813 if test conv = "$pass"; then
63727814 deplibs="$deplib $deplibs"
6373 elif test "$linkmode" = prog; then
6374 if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then
7815 elif test prog = "$linkmode"; then
7816 if test dlpreopen = "$pass" || test yes != "$dlopen_support" || test no = "$build_libtool_libs"; then
63757817 # If there is no dlopen support or we're linking statically,
63767818 # we need to preload.
63777819 func_append newdlprefiles " $deplib"
63847826 continue
63857827 ;;
63867828 %DEPLIBS%)
6387 alldeplibs=yes
7829 alldeplibs=:
63887830 continue
63897831 ;;
63907832 esac # case $deplib
63917833
6392 if test "$found" = yes || test -f "$lib"; then :
6393 else
6394 func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'"
6395 fi
7834 $found || test -f "$lib" \
7835 || func_fatal_error "cannot find the library '$lib' or unhandled argument '$deplib'"
63967836
63977837 # Check to see that this really is a libtool archive.
63987838 func_lalib_unsafe_p "$lib" \
6399 || func_fatal_error "\`$lib' is not a valid libtool archive"
7839 || func_fatal_error "'$lib' is not a valid libtool archive"
64007840
64017841 func_dirname "$lib" "" "."
6402 ladir="$func_dirname_result"
7842 ladir=$func_dirname_result
64037843
64047844 dlname=
64057845 dlopen=
64297869 done
64307870 fi
64317871 dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
6432 if test "$linkmode,$pass" = "lib,link" ||
6433 test "$linkmode,$pass" = "prog,scan" ||
6434 { test "$linkmode" != prog && test "$linkmode" != lib; }; then
7872 if test lib,link = "$linkmode,$pass" ||
7873 test prog,scan = "$linkmode,$pass" ||
7874 { test prog != "$linkmode" && test lib != "$linkmode"; }; then
64357875 test -n "$dlopen" && func_append dlfiles " $dlopen"
64367876 test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen"
64377877 fi
64387878
6439 if test "$pass" = conv; then
7879 if test conv = "$pass"; then
64407880 # Only check for convenience libraries
64417881 deplibs="$lib $deplibs"
64427882 if test -z "$libdir"; then
64437883 if test -z "$old_library"; then
6444 func_fatal_error "cannot find name of link library for \`$lib'"
7884 func_fatal_error "cannot find name of link library for '$lib'"
64457885 fi
64467886 # It is a libtool convenience library, so add in its objects.
64477887 func_append convenience " $ladir/$objdir/$old_library"
64487888 func_append old_convenience " $ladir/$objdir/$old_library"
6449 tmp_libs=
6450 for deplib in $dependency_libs; do
6451 deplibs="$deplib $deplibs"
6452 if $opt_preserve_dup_deps ; then
6453 case "$tmp_libs " in
6454 *" $deplib "*) func_append specialdeplibs " $deplib" ;;
6455 esac
6456 fi
6457 func_append tmp_libs " $deplib"
6458 done
6459 elif test "$linkmode" != prog && test "$linkmode" != lib; then
6460 func_fatal_error "\`$lib' is not a convenience library"
7889 elif test prog != "$linkmode" && test lib != "$linkmode"; then
7890 func_fatal_error "'$lib' is not a convenience library"
64617891 fi
7892 tmp_libs=
7893 for deplib in $dependency_libs; do
7894 deplibs="$deplib $deplibs"
7895 if $opt_preserve_dup_deps; then
7896 case "$tmp_libs " in
7897 *" $deplib "*) func_append specialdeplibs " $deplib" ;;
7898 esac
7899 fi
7900 func_append tmp_libs " $deplib"
7901 done
64627902 continue
64637903 fi # $pass = conv
64647904
64667906 # Get the name of the library we link against.
64677907 linklib=
64687908 if test -n "$old_library" &&
6469 { test "$prefer_static_libs" = yes ||
6470 test "$prefer_static_libs,$installed" = "built,no"; }; then
7909 { test yes = "$prefer_static_libs" ||
7910 test built,no = "$prefer_static_libs,$installed"; }; then
64717911 linklib=$old_library
64727912 else
64737913 for l in $old_library $library_names; do
6474 linklib="$l"
7914 linklib=$l
64757915 done
64767916 fi
64777917 if test -z "$linklib"; then
6478 func_fatal_error "cannot find name of link library for \`$lib'"
7918 func_fatal_error "cannot find name of link library for '$lib'"
64797919 fi
64807920
64817921 # This library was specified with -dlopen.
6482 if test "$pass" = dlopen; then
6483 if test -z "$libdir"; then
6484 func_fatal_error "cannot -dlopen a convenience library: \`$lib'"
6485 fi
7922 if test dlopen = "$pass"; then
7923 test -z "$libdir" \
7924 && func_fatal_error "cannot -dlopen a convenience library: '$lib'"
64867925 if test -z "$dlname" ||
6487 test "$dlopen_support" != yes ||
6488 test "$build_libtool_libs" = no; then
7926 test yes != "$dlopen_support" ||
7927 test no = "$build_libtool_libs"
7928 then
64897929 # If there is no dlname, no dlopen support or we're linking
64907930 # statically, we need to preload. We also need to preload any
64917931 # dependent libraries so libltdl's deplib preloader doesn't
64997939
65007940 # We need an absolute path.
65017941 case $ladir in
6502 [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;;
7942 [\\/]* | [A-Za-z]:[\\/]*) abs_ladir=$ladir ;;
65037943 *)
65047944 abs_ladir=`cd "$ladir" && pwd`
65057945 if test -z "$abs_ladir"; then
6506 func_warning "cannot determine absolute directory name of \`$ladir'"
7946 func_warning "cannot determine absolute directory name of '$ladir'"
65077947 func_warning "passing it literally to the linker, although it might fail"
6508 abs_ladir="$ladir"
7948 abs_ladir=$ladir
65097949 fi
65107950 ;;
65117951 esac
65127952 func_basename "$lib"
6513 laname="$func_basename_result"
7953 laname=$func_basename_result
65147954
65157955 # Find the relevant object directory and library name.
6516 if test "X$installed" = Xyes; then
7956 if test yes = "$installed"; then
65177957 if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
6518 func_warning "library \`$lib' was moved."
6519 dir="$ladir"
6520 absdir="$abs_ladir"
6521 libdir="$abs_ladir"
7958 func_warning "library '$lib' was moved."
7959 dir=$ladir
7960 absdir=$abs_ladir
7961 libdir=$abs_ladir
65227962 else
6523 dir="$lt_sysroot$libdir"
6524 absdir="$lt_sysroot$libdir"
7963 dir=$lt_sysroot$libdir
7964 absdir=$lt_sysroot$libdir
65257965 fi
6526 test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes
7966 test yes = "$hardcode_automatic" && avoidtemprpath=yes
65277967 else
65287968 if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then
6529 dir="$ladir"
6530 absdir="$abs_ladir"
7969 dir=$ladir
7970 absdir=$abs_ladir
65317971 # Remove this search path later
65327972 func_append notinst_path " $abs_ladir"
65337973 else
6534 dir="$ladir/$objdir"
6535 absdir="$abs_ladir/$objdir"
7974 dir=$ladir/$objdir
7975 absdir=$abs_ladir/$objdir
65367976 # Remove this search path later
65377977 func_append notinst_path " $abs_ladir"
65387978 fi
65417981 name=$func_stripname_result
65427982
65437983 # This library was specified with -dlpreopen.
6544 if test "$pass" = dlpreopen; then
6545 if test -z "$libdir" && test "$linkmode" = prog; then
6546 func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'"
7984 if test dlpreopen = "$pass"; then
7985 if test -z "$libdir" && test prog = "$linkmode"; then
7986 func_fatal_error "only libraries may -dlpreopen a convenience library: '$lib'"
65477987 fi
6548 case "$host" in
7988 case $host in
65497989 # special handling for platforms with PE-DLLs.
65507990 *cygwin* | *mingw* | *cegcc* )
65517991 # Linker will automatically link against shared library if both
65898029
65908030 if test -z "$libdir"; then
65918031 # Link the convenience library
6592 if test "$linkmode" = lib; then
8032 if test lib = "$linkmode"; then
65938033 deplibs="$dir/$old_library $deplibs"
6594 elif test "$linkmode,$pass" = "prog,link"; then
8034 elif test prog,link = "$linkmode,$pass"; then
65958035 compile_deplibs="$dir/$old_library $compile_deplibs"
65968036 finalize_deplibs="$dir/$old_library $finalize_deplibs"
65978037 else
66018041 fi
66028042
66038043
6604 if test "$linkmode" = prog && test "$pass" != link; then
8044 if test prog = "$linkmode" && test link != "$pass"; then
66058045 func_append newlib_search_path " $ladir"
66068046 deplibs="$lib $deplibs"
66078047
6608 linkalldeplibs=no
6609 if test "$link_all_deplibs" != no || test -z "$library_names" ||
6610 test "$build_libtool_libs" = no; then
6611 linkalldeplibs=yes
8048 linkalldeplibs=false
8049 if test no != "$link_all_deplibs" || test -z "$library_names" ||
8050 test no = "$build_libtool_libs"; then
8051 linkalldeplibs=:
66128052 fi
66138053
66148054 tmp_libs=
66208060 ;;
66218061 esac
66228062 # Need to link against all dependency_libs?
6623 if test "$linkalldeplibs" = yes; then
8063 if $linkalldeplibs; then
66248064 deplibs="$deplib $deplibs"
66258065 else
66268066 # Need to hardcode shared library paths
66278067 # or/and link against static libraries
66288068 newdependency_libs="$deplib $newdependency_libs"
66298069 fi
6630 if $opt_preserve_dup_deps ; then
8070 if $opt_preserve_dup_deps; then
66318071 case "$tmp_libs " in
66328072 *" $deplib "*) func_append specialdeplibs " $deplib" ;;
66338073 esac
66378077 continue
66388078 fi # $linkmode = prog...
66398079
6640 if test "$linkmode,$pass" = "prog,link"; then
8080 if test prog,link = "$linkmode,$pass"; then
66418081 if test -n "$library_names" &&
6642 { { test "$prefer_static_libs" = no ||
6643 test "$prefer_static_libs,$installed" = "built,yes"; } ||
8082 { { test no = "$prefer_static_libs" ||
8083 test built,yes = "$prefer_static_libs,$installed"; } ||
66448084 test -z "$old_library"; }; then
66458085 # We need to hardcode the library path
6646 if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then
8086 if test -n "$shlibpath_var" && test -z "$avoidtemprpath"; then
66478087 # Make sure the rpath contains only unique directories.
6648 case "$temp_rpath:" in
8088 case $temp_rpath: in
66498089 *"$absdir:"*) ;;
66508090 *) func_append temp_rpath "$absdir:" ;;
66518091 esac
66748114 esac
66758115 fi # $linkmode,$pass = prog,link...
66768116
6677 if test "$alldeplibs" = yes &&
6678 { test "$deplibs_check_method" = pass_all ||
6679 { test "$build_libtool_libs" = yes &&
8117 if $alldeplibs &&
8118 { test pass_all = "$deplibs_check_method" ||
8119 { test yes = "$build_libtool_libs" &&
66808120 test -n "$library_names"; }; }; then
66818121 # We only need to search for static libraries
66828122 continue
66858125
66868126 link_static=no # Whether the deplib will be linked statically
66878127 use_static_libs=$prefer_static_libs
6688 if test "$use_static_libs" = built && test "$installed" = yes; then
8128 if test built = "$use_static_libs" && test yes = "$installed"; then
66898129 use_static_libs=no
66908130 fi
66918131 if test -n "$library_names" &&
6692 { test "$use_static_libs" = no || test -z "$old_library"; }; then
8132 { test no = "$use_static_libs" || test -z "$old_library"; }; then
66938133 case $host in
6694 *cygwin* | *mingw* | *cegcc*)
8134 *cygwin* | *mingw* | *cegcc* | *os2*)
66958135 # No point in relinking DLLs because paths are not encoded
66968136 func_append notinst_deplibs " $lib"
66978137 need_relink=no
66988138 ;;
66998139 *)
6700 if test "$installed" = no; then
8140 if test no = "$installed"; then
67018141 func_append notinst_deplibs " $lib"
67028142 need_relink=yes
67038143 fi
67078147
67088148 # Warn about portability, can't link against -module's on some
67098149 # systems (darwin). Don't bleat about dlopened modules though!
6710 dlopenmodule=""
8150 dlopenmodule=
67118151 for dlpremoduletest in $dlprefiles; do
67128152 if test "X$dlpremoduletest" = "X$lib"; then
6713 dlopenmodule="$dlpremoduletest"
8153 dlopenmodule=$dlpremoduletest
67148154 break
67158155 fi
67168156 done
6717 if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then
8157 if test -z "$dlopenmodule" && test yes = "$shouldnotlink" && test link = "$pass"; then
67188158 echo
6719 if test "$linkmode" = prog; then
8159 if test prog = "$linkmode"; then
67208160 $ECHO "*** Warning: Linking the executable $output against the loadable module"
67218161 else
67228162 $ECHO "*** Warning: Linking the shared library $output against the loadable module"
67238163 fi
67248164 $ECHO "*** $linklib is not portable!"
67258165 fi
6726 if test "$linkmode" = lib &&
6727 test "$hardcode_into_libs" = yes; then
8166 if test lib = "$linkmode" &&
8167 test yes = "$hardcode_into_libs"; then
67288168 # Hardcode the library path.
67298169 # Skip directories that are in the system default run-time
67308170 # search path.
67528192 # figure out the soname
67538193 set dummy $library_names
67548194 shift
6755 realname="$1"
8195 realname=$1
67568196 shift
67578197 libname=`eval "\\$ECHO \"$libname_spec\""`
67588198 # use dlname if we got it. it's perfectly good, no?
67598199 if test -n "$dlname"; then
6760 soname="$dlname"
8200 soname=$dlname
67618201 elif test -n "$soname_spec"; then
67628202 # bleh windows
67638203 case $host in
6764 *cygwin* | mingw* | *cegcc*)
8204 *cygwin* | mingw* | *cegcc* | *os2*)
67658205 func_arith $current - $age
67668206 major=$func_arith_result
6767 versuffix="-$major"
8207 versuffix=-$major
67688208 ;;
67698209 esac
67708210 eval soname=\"$soname_spec\"
67718211 else
6772 soname="$realname"
8212 soname=$realname
67738213 fi
67748214
67758215 # Make a new name for the extract_expsyms_cmds to use
6776 soroot="$soname"
8216 soroot=$soname
67778217 func_basename "$soroot"
6778 soname="$func_basename_result"
8218 soname=$func_basename_result
67798219 func_stripname 'lib' '.dll' "$soname"
67808220 newlib=libimp-$func_stripname_result.a
67818221
67828222 # If the library has no export list, then create one now
67838223 if test -f "$output_objdir/$soname-def"; then :
67848224 else
6785 func_verbose "extracting exported symbol list from \`$soname'"
8225 func_verbose "extracting exported symbol list from '$soname'"
67868226 func_execute_cmds "$extract_expsyms_cmds" 'exit $?'
67878227 fi
67888228
67898229 # Create $newlib
67908230 if test -f "$output_objdir/$newlib"; then :; else
6791 func_verbose "generating import library for \`$soname'"
8231 func_verbose "generating import library for '$soname'"
67928232 func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?'
67938233 fi
67948234 # make sure the library variables are pointing to the new library
67968236 linklib=$newlib
67978237 fi # test -n "$old_archive_from_expsyms_cmds"
67988238
6799 if test "$linkmode" = prog || test "$opt_mode" != relink; then
8239 if test prog = "$linkmode" || test relink != "$opt_mode"; then
68008240 add_shlibpath=
68018241 add_dir=
68028242 add=
68038243 lib_linked=yes
68048244 case $hardcode_action in
68058245 immediate | unsupported)
6806 if test "$hardcode_direct" = no; then
6807 add="$dir/$linklib"
8246 if test no = "$hardcode_direct"; then
8247 add=$dir/$linklib
68088248 case $host in
6809 *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;;
6810 *-*-sysv4*uw2*) add_dir="-L$dir" ;;
8249 *-*-sco3.2v5.0.[024]*) add_dir=-L$dir ;;
8250 *-*-sysv4*uw2*) add_dir=-L$dir ;;
68118251 *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \
6812 *-*-unixware7*) add_dir="-L$dir" ;;
8252 *-*-unixware7*) add_dir=-L$dir ;;
68138253 *-*-darwin* )
6814 # if the lib is a (non-dlopened) module then we can not
8254 # if the lib is a (non-dlopened) module then we cannot
68158255 # link against it, someone is ignoring the earlier warnings
68168256 if /usr/bin/file -L $add 2> /dev/null |
6817 $GREP ": [^:]* bundle" >/dev/null ; then
8257 $GREP ": [^:]* bundle" >/dev/null; then
68188258 if test "X$dlopenmodule" != "X$lib"; then
68198259 $ECHO "*** Warning: lib $linklib is a module, not a shared library"
6820 if test -z "$old_library" ; then
8260 if test -z "$old_library"; then
68218261 echo
68228262 echo "*** And there doesn't seem to be a static archive available"
68238263 echo "*** The link will probably fail, sorry"
68248264 else
6825 add="$dir/$old_library"
8265 add=$dir/$old_library
68268266 fi
68278267 elif test -n "$old_library"; then
6828 add="$dir/$old_library"
8268 add=$dir/$old_library
68298269 fi
68308270 fi
68318271 esac
6832 elif test "$hardcode_minus_L" = no; then
8272 elif test no = "$hardcode_minus_L"; then
68338273 case $host in
6834 *-*-sunos*) add_shlibpath="$dir" ;;
8274 *-*-sunos*) add_shlibpath=$dir ;;
68358275 esac
6836 add_dir="-L$dir"
6837 add="-l$name"
6838 elif test "$hardcode_shlibpath_var" = no; then
6839 add_shlibpath="$dir"
6840 add="-l$name"
8276 add_dir=-L$dir
8277 add=-l$name
8278 elif test no = "$hardcode_shlibpath_var"; then
8279 add_shlibpath=$dir
8280 add=-l$name
68418281 else
68428282 lib_linked=no
68438283 fi
68448284 ;;
68458285 relink)
6846 if test "$hardcode_direct" = yes &&
6847 test "$hardcode_direct_absolute" = no; then
6848 add="$dir/$linklib"
6849 elif test "$hardcode_minus_L" = yes; then
6850 add_dir="-L$absdir"
8286 if test yes = "$hardcode_direct" &&
8287 test no = "$hardcode_direct_absolute"; then
8288 add=$dir/$linklib
8289 elif test yes = "$hardcode_minus_L"; then
8290 add_dir=-L$absdir
68518291 # Try looking first in the location we're being installed to.
68528292 if test -n "$inst_prefix_dir"; then
68538293 case $libdir in
68568296 ;;
68578297 esac
68588298 fi
6859 add="-l$name"
6860 elif test "$hardcode_shlibpath_var" = yes; then
6861 add_shlibpath="$dir"
6862 add="-l$name"
8299 add=-l$name
8300 elif test yes = "$hardcode_shlibpath_var"; then
8301 add_shlibpath=$dir
8302 add=-l$name
68638303 else
68648304 lib_linked=no
68658305 fi
68678307 *) lib_linked=no ;;
68688308 esac
68698309
6870 if test "$lib_linked" != yes; then
8310 if test yes != "$lib_linked"; then
68718311 func_fatal_configuration "unsupported hardcode properties"
68728312 fi
68738313
68778317 *) func_append compile_shlibpath "$add_shlibpath:" ;;
68788318 esac
68798319 fi
6880 if test "$linkmode" = prog; then
8320 if test prog = "$linkmode"; then
68818321 test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs"
68828322 test -n "$add" && compile_deplibs="$add $compile_deplibs"
68838323 else
68848324 test -n "$add_dir" && deplibs="$add_dir $deplibs"
68858325 test -n "$add" && deplibs="$add $deplibs"
6886 if test "$hardcode_direct" != yes &&
6887 test "$hardcode_minus_L" != yes &&
6888 test "$hardcode_shlibpath_var" = yes; then
8326 if test yes != "$hardcode_direct" &&
8327 test yes != "$hardcode_minus_L" &&
8328 test yes = "$hardcode_shlibpath_var"; then
68898329 case :$finalize_shlibpath: in
68908330 *":$libdir:"*) ;;
68918331 *) func_append finalize_shlibpath "$libdir:" ;;
68948334 fi
68958335 fi
68968336
6897 if test "$linkmode" = prog || test "$opt_mode" = relink; then
8337 if test prog = "$linkmode" || test relink = "$opt_mode"; then
68988338 add_shlibpath=
68998339 add_dir=
69008340 add=
69018341 # Finalize command for both is simple: just hardcode it.
6902 if test "$hardcode_direct" = yes &&
6903 test "$hardcode_direct_absolute" = no; then
6904 add="$libdir/$linklib"
6905 elif test "$hardcode_minus_L" = yes; then
6906 add_dir="-L$libdir"
6907 add="-l$name"
6908 elif test "$hardcode_shlibpath_var" = yes; then
8342 if test yes = "$hardcode_direct" &&
8343 test no = "$hardcode_direct_absolute"; then
8344 add=$libdir/$linklib
8345 elif test yes = "$hardcode_minus_L"; then
8346 add_dir=-L$libdir
8347 add=-l$name
8348 elif test yes = "$hardcode_shlibpath_var"; then
69098349 case :$finalize_shlibpath: in
69108350 *":$libdir:"*) ;;
69118351 *) func_append finalize_shlibpath "$libdir:" ;;
69128352 esac
6913 add="-l$name"
6914 elif test "$hardcode_automatic" = yes; then
8353 add=-l$name
8354 elif test yes = "$hardcode_automatic"; then
69158355 if test -n "$inst_prefix_dir" &&
6916 test -f "$inst_prefix_dir$libdir/$linklib" ; then
6917 add="$inst_prefix_dir$libdir/$linklib"
8356 test -f "$inst_prefix_dir$libdir/$linklib"; then
8357 add=$inst_prefix_dir$libdir/$linklib
69188358 else
6919 add="$libdir/$linklib"
8359 add=$libdir/$linklib
69208360 fi
69218361 else
69228362 # We cannot seem to hardcode it, guess we'll fake it.
6923 add_dir="-L$libdir"
8363 add_dir=-L$libdir
69248364 # Try looking first in the location we're being installed to.
69258365 if test -n "$inst_prefix_dir"; then
69268366 case $libdir in
69298369 ;;
69308370 esac
69318371 fi
6932 add="-l$name"
8372 add=-l$name
69338373 fi
69348374
6935 if test "$linkmode" = prog; then
8375 if test prog = "$linkmode"; then
69368376 test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs"
69378377 test -n "$add" && finalize_deplibs="$add $finalize_deplibs"
69388378 else
69408380 test -n "$add" && deplibs="$add $deplibs"
69418381 fi
69428382 fi
6943 elif test "$linkmode" = prog; then
8383 elif test prog = "$linkmode"; then
69448384 # Here we assume that one of hardcode_direct or hardcode_minus_L
69458385 # is not unsupported. This is valid on all known static and
69468386 # shared platforms.
6947 if test "$hardcode_direct" != unsupported; then
6948 test -n "$old_library" && linklib="$old_library"
8387 if test unsupported != "$hardcode_direct"; then
8388 test -n "$old_library" && linklib=$old_library
69498389 compile_deplibs="$dir/$linklib $compile_deplibs"
69508390 finalize_deplibs="$dir/$linklib $finalize_deplibs"
69518391 else
69528392 compile_deplibs="-l$name -L$dir $compile_deplibs"
69538393 finalize_deplibs="-l$name -L$dir $finalize_deplibs"
69548394 fi
6955 elif test "$build_libtool_libs" = yes; then
8395 elif test yes = "$build_libtool_libs"; then
69568396 # Not a shared library
6957 if test "$deplibs_check_method" != pass_all; then
8397 if test pass_all != "$deplibs_check_method"; then
69588398 # We're trying link a shared library against a static one
69598399 # but the system doesn't support it.
69608400
69618401 # Just print a warning and add the library to dependency_libs so
69628402 # that the program can be linked against the static library.
69638403 echo
6964 $ECHO "*** Warning: This system can not link to static lib archive $lib."
8404 $ECHO "*** Warning: This system cannot link to static lib archive $lib."
69658405 echo "*** I have the capability to make that library automatically link in when"
69668406 echo "*** you link to this library. But I can only do this if you have a"
69678407 echo "*** shared version of the library, which you do not appear to have."
6968 if test "$module" = yes; then
8408 if test yes = "$module"; then
69698409 echo "*** But as you try to build a module library, libtool will still create "
69708410 echo "*** a static module, that should work as long as the dlopening application"
69718411 echo "*** is linked with the -dlopen flag to resolve symbols at runtime."
69728412 if test -z "$global_symbol_pipe"; then
69738413 echo
69748414 echo "*** However, this would only work if libtool was able to extract symbol"
6975 echo "*** lists from a program, using \`nm' or equivalent, but libtool could"
8415 echo "*** lists from a program, using 'nm' or equivalent, but libtool could"
69768416 echo "*** not find such a program. So, this module is probably useless."
6977 echo "*** \`nm' from GNU binutils and a full rebuild may help."
8417 echo "*** 'nm' from GNU binutils and a full rebuild may help."
69788418 fi
6979 if test "$build_old_libs" = no; then
8419 if test no = "$build_old_libs"; then
69808420 build_libtool_libs=module
69818421 build_old_libs=yes
69828422 else
69898429 fi
69908430 fi # link shared/static library?
69918431
6992 if test "$linkmode" = lib; then
8432 if test lib = "$linkmode"; then
69938433 if test -n "$dependency_libs" &&
6994 { test "$hardcode_into_libs" != yes ||
6995 test "$build_old_libs" = yes ||
6996 test "$link_static" = yes; }; then
8434 { test yes != "$hardcode_into_libs" ||
8435 test yes = "$build_old_libs" ||
8436 test yes = "$link_static"; }; then
69978437 # Extract -R from dependency_libs
69988438 temp_deplibs=
69998439 for libdir in $dependency_libs; do
70078447 *) func_append temp_deplibs " $libdir";;
70088448 esac
70098449 done
7010 dependency_libs="$temp_deplibs"
8450 dependency_libs=$temp_deplibs
70118451 fi
70128452
70138453 func_append newlib_search_path " $absdir"
70148454 # Link against this library
7015 test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs"
8455 test no = "$link_static" && newdependency_libs="$abs_ladir/$laname $newdependency_libs"
70168456 # ... and its dependency_libs
70178457 tmp_libs=
70188458 for deplib in $dependency_libs; do
70228462 func_resolve_sysroot "$func_stripname_result";;
70238463 *) func_resolve_sysroot "$deplib" ;;
70248464 esac
7025 if $opt_preserve_dup_deps ; then
8465 if $opt_preserve_dup_deps; then
70268466 case "$tmp_libs " in
70278467 *" $func_resolve_sysroot_result "*)
70288468 func_append specialdeplibs " $func_resolve_sysroot_result" ;;
70318471 func_append tmp_libs " $func_resolve_sysroot_result"
70328472 done
70338473
7034 if test "$link_all_deplibs" != no; then
8474 if test no != "$link_all_deplibs"; then
70358475 # Add the search paths of all dependency libraries
70368476 for deplib in $dependency_libs; do
70378477 path=
70388478 case $deplib in
7039 -L*) path="$deplib" ;;
8479 -L*) path=$deplib ;;
70408480 *.la)
70418481 func_resolve_sysroot "$deplib"
70428482 deplib=$func_resolve_sysroot_result
70448484 dir=$func_dirname_result
70458485 # We need an absolute path.
70468486 case $dir in
7047 [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;;
8487 [\\/]* | [A-Za-z]:[\\/]*) absdir=$dir ;;
70488488 *)
70498489 absdir=`cd "$dir" && pwd`
70508490 if test -z "$absdir"; then
7051 func_warning "cannot determine absolute directory name of \`$dir'"
7052 absdir="$dir"
8491 func_warning "cannot determine absolute directory name of '$dir'"
8492 absdir=$dir
70538493 fi
70548494 ;;
70558495 esac
70578497 case $host in
70588498 *-*-darwin*)
70598499 depdepl=
7060 eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib`
7061 if test -n "$deplibrary_names" ; then
7062 for tmp in $deplibrary_names ; do
8500 eval deplibrary_names=`$SED -n -e 's/^library_names=\(.*\)$/\1/p' $deplib`
8501 if test -n "$deplibrary_names"; then
8502 for tmp in $deplibrary_names; do
70638503 depdepl=$tmp
70648504 done
7065 if test -f "$absdir/$objdir/$depdepl" ; then
7066 depdepl="$absdir/$objdir/$depdepl"
7067 darwin_install_name=`${OTOOL} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'`
8505 if test -f "$absdir/$objdir/$depdepl"; then
8506 depdepl=$absdir/$objdir/$depdepl
8507 darwin_install_name=`$OTOOL -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'`
70688508 if test -z "$darwin_install_name"; then
7069 darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'`
8509 darwin_install_name=`$OTOOL64 -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'`
70708510 fi
7071 func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}"
7072 func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}"
8511 func_append compiler_flags " $wl-dylib_file $wl$darwin_install_name:$depdepl"
8512 func_append linker_flags " -dylib_file $darwin_install_name:$depdepl"
70738513 path=
70748514 fi
70758515 fi
70768516 ;;
70778517 *)
7078 path="-L$absdir/$objdir"
8518 path=-L$absdir/$objdir
70798519 ;;
70808520 esac
70818521 else
7082 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
8522 eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
70838523 test -z "$libdir" && \
7084 func_fatal_error "\`$deplib' is not a valid libtool archive"
8524 func_fatal_error "'$deplib' is not a valid libtool archive"
70858525 test "$absdir" != "$libdir" && \
7086 func_warning "\`$deplib' seems to be moved"
7087
7088 path="-L$absdir"
8526 func_warning "'$deplib' seems to be moved"
8527
8528 path=-L$absdir
70898529 fi
70908530 ;;
70918531 esac
70978537 fi # link_all_deplibs != no
70988538 fi # linkmode = lib
70998539 done # for deplib in $libs
7100 if test "$pass" = link; then
7101 if test "$linkmode" = "prog"; then
8540 if test link = "$pass"; then
8541 if test prog = "$linkmode"; then
71028542 compile_deplibs="$new_inherited_linker_flags $compile_deplibs"
71038543 finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs"
71048544 else
71058545 compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
71068546 fi
71078547 fi
7108 dependency_libs="$newdependency_libs"
7109 if test "$pass" = dlpreopen; then
8548 dependency_libs=$newdependency_libs
8549 if test dlpreopen = "$pass"; then
71108550 # Link the dlpreopened libraries before other libraries
71118551 for deplib in $save_deplibs; do
71128552 deplibs="$deplib $deplibs"
71138553 done
71148554 fi
7115 if test "$pass" != dlopen; then
7116 if test "$pass" != conv; then
8555 if test dlopen != "$pass"; then
8556 test conv = "$pass" || {
71178557 # Make sure lib_search_path contains only unique directories.
71188558 lib_search_path=
71198559 for dir in $newlib_search_path; do
71238563 esac
71248564 done
71258565 newlib_search_path=
7126 fi
7127
7128 if test "$linkmode,$pass" != "prog,link"; then
7129 vars="deplibs"
8566 }
8567
8568 if test prog,link = "$linkmode,$pass"; then
8569 vars="compile_deplibs finalize_deplibs"
71308570 else
7131 vars="compile_deplibs finalize_deplibs"
8571 vars=deplibs
71328572 fi
71338573 for var in $vars dependency_libs; do
71348574 # Add libraries to $var in reverse order
71868626 eval $var=\"$tmp_libs\"
71878627 done # for var
71888628 fi
8629
8630 # Add Sun CC postdeps if required:
8631 test CXX = "$tagname" && {
8632 case $host_os in
8633 linux*)
8634 case `$CC -V 2>&1 | sed 5q` in
8635 *Sun\ C*) # Sun C++ 5.9
8636 func_suncc_cstd_abi
8637
8638 if test no != "$suncc_use_cstd_abi"; then
8639 func_append postdeps ' -library=Cstd -library=Crun'
8640 fi
8641 ;;
8642 esac
8643 ;;
8644
8645 solaris*)
8646 func_cc_basename "$CC"
8647 case $func_cc_basename_result in
8648 CC* | sunCC*)
8649 func_suncc_cstd_abi
8650
8651 if test no != "$suncc_use_cstd_abi"; then
8652 func_append postdeps ' -library=Cstd -library=Crun'
8653 fi
8654 ;;
8655 esac
8656 ;;
8657 esac
8658 }
8659
71898660 # Last step: remove runtime libs from dependency_libs
71908661 # (they stay in deplibs)
71918662 tmp_libs=
7192 for i in $dependency_libs ; do
8663 for i in $dependency_libs; do
71938664 case " $predeps $postdeps $compiler_lib_search_path " in
71948665 *" $i "*)
7195 i=""
8666 i=
71968667 ;;
71978668 esac
7198 if test -n "$i" ; then
8669 if test -n "$i"; then
71998670 func_append tmp_libs " $i"
72008671 fi
72018672 done
72028673 dependency_libs=$tmp_libs
72038674 done # for pass
7204 if test "$linkmode" = prog; then
7205 dlfiles="$newdlfiles"
8675 if test prog = "$linkmode"; then
8676 dlfiles=$newdlfiles
72068677 fi
7207 if test "$linkmode" = prog || test "$linkmode" = lib; then
7208 dlprefiles="$newdlprefiles"
8678 if test prog = "$linkmode" || test lib = "$linkmode"; then
8679 dlprefiles=$newdlprefiles
72098680 fi
72108681
72118682 case $linkmode in
72128683 oldlib)
7213 if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
7214 func_warning "\`-dlopen' is ignored for archives"
8684 if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then
8685 func_warning "'-dlopen' is ignored for archives"
72158686 fi
72168687
72178688 case " $deplibs" in
72188689 *\ -l* | *\ -L*)
7219 func_warning "\`-l' and \`-L' are ignored for archives" ;;
8690 func_warning "'-l' and '-L' are ignored for archives" ;;
72208691 esac
72218692
72228693 test -n "$rpath" && \
7223 func_warning "\`-rpath' is ignored for archives"
8694 func_warning "'-rpath' is ignored for archives"
72248695
72258696 test -n "$xrpath" && \
7226 func_warning "\`-R' is ignored for archives"
8697 func_warning "'-R' is ignored for archives"
72278698
72288699 test -n "$vinfo" && \
7229 func_warning "\`-version-info/-version-number' is ignored for archives"
8700 func_warning "'-version-info/-version-number' is ignored for archives"
72308701
72318702 test -n "$release" && \
7232 func_warning "\`-release' is ignored for archives"
8703 func_warning "'-release' is ignored for archives"
72338704
72348705 test -n "$export_symbols$export_symbols_regex" && \
7235 func_warning "\`-export-symbols' is ignored for archives"
8706 func_warning "'-export-symbols' is ignored for archives"
72368707
72378708 # Now set the variables for building old libraries.
72388709 build_libtool_libs=no
7239 oldlibs="$output"
8710 oldlibs=$output
72408711 func_append objs "$old_deplibs"
72418712 ;;
72428713
72438714 lib)
7244 # Make sure we only generate libraries of the form `libNAME.la'.
8715 # Make sure we only generate libraries of the form 'libNAME.la'.
72458716 case $outputname in
72468717 lib*)
72478718 func_stripname 'lib' '.la' "$outputname"
72508721 eval libname=\"$libname_spec\"
72518722 ;;
72528723 *)
7253 test "$module" = no && \
7254 func_fatal_help "libtool library \`$output' must begin with \`lib'"
7255
7256 if test "$need_lib_prefix" != no; then
8724 test no = "$module" \
8725 && func_fatal_help "libtool library '$output' must begin with 'lib'"
8726
8727 if test no != "$need_lib_prefix"; then
72578728 # Add the "lib" prefix for modules if required
72588729 func_stripname '' '.la' "$outputname"
72598730 name=$func_stripname_result
72678738 esac
72688739
72698740 if test -n "$objs"; then
7270 if test "$deplibs_check_method" != pass_all; then
7271 func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs"
8741 if test pass_all != "$deplibs_check_method"; then
8742 func_fatal_error "cannot build libtool library '$output' from non-libtool objects on this host:$objs"
72728743 else
72738744 echo
72748745 $ECHO "*** Warning: Linking the shared library $output against the non-libtool"
72778748 fi
72788749 fi
72798750
7280 test "$dlself" != no && \
7281 func_warning "\`-dlopen self' is ignored for libtool libraries"
8751 test no = "$dlself" \
8752 || func_warning "'-dlopen self' is ignored for libtool libraries"
72828753
72838754 set dummy $rpath
72848755 shift
7285 test "$#" -gt 1 && \
7286 func_warning "ignoring multiple \`-rpath's for a libtool library"
7287
7288 install_libdir="$1"
8756 test 1 -lt "$#" \
8757 && func_warning "ignoring multiple '-rpath's for a libtool library"
8758
8759 install_libdir=$1
72898760
72908761 oldlibs=
72918762 if test -z "$rpath"; then
7292 if test "$build_libtool_libs" = yes; then
8763 if test yes = "$build_libtool_libs"; then
72938764 # Building a libtool convenience library.
7294 # Some compilers have problems with a `.al' extension so
8765 # Some compilers have problems with a '.al' extension so
72958766 # convenience libraries should have the same extension an
72968767 # archive normally would.
72978768 oldlibs="$output_objdir/$libname.$libext $oldlibs"
73008771 fi
73018772
73028773 test -n "$vinfo" && \
7303 func_warning "\`-version-info/-version-number' is ignored for convenience libraries"
8774 func_warning "'-version-info/-version-number' is ignored for convenience libraries"
73048775
73058776 test -n "$release" && \
7306 func_warning "\`-release' is ignored for convenience libraries"
8777 func_warning "'-release' is ignored for convenience libraries"
73078778 else
73088779
73098780 # Parse the version information argument.
7310 save_ifs="$IFS"; IFS=':'
8781 save_ifs=$IFS; IFS=:
73118782 set dummy $vinfo 0 0 0
73128783 shift
7313 IFS="$save_ifs"
8784 IFS=$save_ifs
73148785
73158786 test -n "$7" && \
7316 func_fatal_help "too many parameters to \`-version-info'"
8787 func_fatal_help "too many parameters to '-version-info'"
73178788
73188789 # convert absolute version numbers to libtool ages
73198790 # this retains compatibility with .la files and attempts
73218792
73228793 case $vinfo_number in
73238794 yes)
7324 number_major="$1"
7325 number_minor="$2"
7326 number_revision="$3"
8795 number_major=$1
8796 number_minor=$2
8797 number_revision=$3
73278798 #
73288799 # There are really only two kinds -- those that
73298800 # use the current revision as the major version
73308801 # and those that subtract age and use age as
73318802 # a minor version. But, then there is irix
7332 # which has an extra 1 added just for fun
8803 # that has an extra 1 added just for fun
73338804 #
73348805 case $version_type in
73358806 # correct linux to gnu/linux during the next big refactor
7336 darwin|linux|osf|windows|none)
8807 darwin|freebsd-elf|linux|osf|windows|none)
73378808 func_arith $number_major + $number_minor
73388809 current=$func_arith_result
7339 age="$number_minor"
7340 revision="$number_revision"
8810 age=$number_minor
8811 revision=$number_revision
73418812 ;;
7342 freebsd-aout|freebsd-elf|qnx|sunos)
7343 current="$number_major"
7344 revision="$number_minor"
7345 age="0"
8813 freebsd-aout|qnx|sunos)
8814 current=$number_major
8815 revision=$number_minor
8816 age=0
73468817 ;;
73478818 irix|nonstopux)
73488819 func_arith $number_major + $number_minor
73498820 current=$func_arith_result
7350 age="$number_minor"
7351 revision="$number_minor"
8821 age=$number_minor
8822 revision=$number_minor
73528823 lt_irix_increment=no
7353 ;;
7354 *)
7355 func_fatal_configuration "$modename: unknown library version type \`$version_type'"
73568824 ;;
73578825 esac
73588826 ;;
73598827 no)
7360 current="$1"
7361 revision="$2"
7362 age="$3"
8828 current=$1
8829 revision=$2
8830 age=$3
73638831 ;;
73648832 esac
73658833
73678835 case $current in
73688836 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;;
73698837 *)
7370 func_error "CURRENT \`$current' must be a nonnegative integer"
7371 func_fatal_error "\`$vinfo' is not valid version information"
8838 func_error "CURRENT '$current' must be a nonnegative integer"
8839 func_fatal_error "'$vinfo' is not valid version information"
73728840 ;;
73738841 esac
73748842
73758843 case $revision in
73768844 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;;
73778845 *)
7378 func_error "REVISION \`$revision' must be a nonnegative integer"
7379 func_fatal_error "\`$vinfo' is not valid version information"
8846 func_error "REVISION '$revision' must be a nonnegative integer"
8847 func_fatal_error "'$vinfo' is not valid version information"
73808848 ;;
73818849 esac
73828850
73838851 case $age in
73848852 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;;
73858853 *)
7386 func_error "AGE \`$age' must be a nonnegative integer"
7387 func_fatal_error "\`$vinfo' is not valid version information"
8854 func_error "AGE '$age' must be a nonnegative integer"
8855 func_fatal_error "'$vinfo' is not valid version information"
73888856 ;;
73898857 esac
73908858
73918859 if test "$age" -gt "$current"; then
7392 func_error "AGE \`$age' is greater than the current interface number \`$current'"
7393 func_fatal_error "\`$vinfo' is not valid version information"
8860 func_error "AGE '$age' is greater than the current interface number '$current'"
8861 func_fatal_error "'$vinfo' is not valid version information"
73948862 fi
73958863
73968864 # Calculate the version variables.
74058873 # verstring for coding it into the library header
74068874 func_arith $current - $age
74078875 major=.$func_arith_result
7408 versuffix="$major.$age.$revision"
8876 versuffix=$major.$age.$revision
74098877 # Darwin ld doesn't like 0 for these options...
74108878 func_arith $current + 1
74118879 minor_current=$func_arith_result
7412 xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision"
8880 xlcverstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision"
74138881 verstring="-compatibility_version $minor_current -current_version $minor_current.$revision"
8882 # On Darwin other compilers
8883 case $CC in
8884 nagfor*)
8885 verstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision"
8886 ;;
8887 *)
8888 verstring="-compatibility_version $minor_current -current_version $minor_current.$revision"
8889 ;;
8890 esac
74148891 ;;
74158892
74168893 freebsd-aout)
7417 major=".$current"
7418 versuffix=".$current.$revision";
8894 major=.$current
8895 versuffix=.$current.$revision
74198896 ;;
74208897
74218898 freebsd-elf)
7422 major=".$current"
7423 versuffix=".$current"
8899 func_arith $current - $age
8900 major=.$func_arith_result
8901 versuffix=$major.$age.$revision
74248902 ;;
74258903
74268904 irix | nonstopux)
7427 if test "X$lt_irix_increment" = "Xno"; then
8905 if test no = "$lt_irix_increment"; then
74288906 func_arith $current - $age
74298907 else
74308908 func_arith $current - $age + 1
74358913 nonstopux) verstring_prefix=nonstopux ;;
74368914 *) verstring_prefix=sgi ;;
74378915 esac
7438 verstring="$verstring_prefix$major.$revision"
8916 verstring=$verstring_prefix$major.$revision
74398917
74408918 # Add in all the interfaces that we are compatible with.
74418919 loop=$revision
7442 while test "$loop" -ne 0; do
8920 while test 0 -ne "$loop"; do
74438921 func_arith $revision - $loop
74448922 iface=$func_arith_result
74458923 func_arith $loop - 1
74468924 loop=$func_arith_result
7447 verstring="$verstring_prefix$major.$iface:$verstring"
8925 verstring=$verstring_prefix$major.$iface:$verstring
74488926 done
74498927
7450 # Before this point, $major must not contain `.'.
8928 # Before this point, $major must not contain '.'.
74518929 major=.$major
7452 versuffix="$major.$revision"
8930 versuffix=$major.$revision
74538931 ;;
74548932
74558933 linux) # correct to gnu/linux during the next big refactor
74568934 func_arith $current - $age
74578935 major=.$func_arith_result
7458 versuffix="$major.$age.$revision"
8936 versuffix=$major.$age.$revision
74598937 ;;
74608938
74618939 osf)
74628940 func_arith $current - $age
74638941 major=.$func_arith_result
7464 versuffix=".$current.$age.$revision"
7465 verstring="$current.$age.$revision"
8942 versuffix=.$current.$age.$revision
8943 verstring=$current.$age.$revision
74668944
74678945 # Add in all the interfaces that we are compatible with.
74688946 loop=$age
7469 while test "$loop" -ne 0; do
8947 while test 0 -ne "$loop"; do
74708948 func_arith $current - $loop
74718949 iface=$func_arith_result
74728950 func_arith $loop - 1
74738951 loop=$func_arith_result
7474 verstring="$verstring:${iface}.0"
8952 verstring=$verstring:$iface.0
74758953 done
74768954
74778955 # Make executables depend on our current version.
7478 func_append verstring ":${current}.0"
8956 func_append verstring ":$current.0"
74798957 ;;
74808958
74818959 qnx)
7482 major=".$current"
7483 versuffix=".$current"
8960 major=.$current
8961 versuffix=.$current
74848962 ;;
74858963
8964 sco)
8965 major=.$current
8966 versuffix=.$current
8967 ;;
8968
74868969 sunos)
7487 major=".$current"
7488 versuffix=".$current.$revision"
8970 major=.$current
8971 versuffix=.$current.$revision
74898972 ;;
74908973
74918974 windows)
74928975 # Use '-' rather than '.', since we only want one
7493 # extension on DOS 8.3 filesystems.
8976 # extension on DOS 8.3 file systems.
74948977 func_arith $current - $age
74958978 major=$func_arith_result
7496 versuffix="-$major"
8979 versuffix=-$major
74978980 ;;
74988981
74998982 *)
7500 func_fatal_configuration "unknown library version type \`$version_type'"
8983 func_fatal_configuration "unknown library version type '$version_type'"
75018984 ;;
75028985 esac
75038986
75118994 verstring=
75128995 ;;
75138996 *)
7514 verstring="0.0"
8997 verstring=0.0
75158998 ;;
75168999 esac
7517 if test "$need_version" = no; then
9000 if test no = "$need_version"; then
75189001 versuffix=
75199002 else
7520 versuffix=".0.0"
9003 versuffix=.0.0
75219004 fi
75229005 fi
75239006
75249007 # Remove version info from name if versioning should be avoided
7525 if test "$avoid_version" = yes && test "$need_version" = no; then
9008 if test yes,no = "$avoid_version,$need_version"; then
75269009 major=
75279010 versuffix=
7528 verstring=""
9011 verstring=
75299012 fi
75309013
75319014 # Check to see if the archive will have undefined symbols.
7532 if test "$allow_undefined" = yes; then
7533 if test "$allow_undefined_flag" = unsupported; then
7534 func_warning "undefined symbols not allowed in $host shared libraries"
7535 build_libtool_libs=no
7536 build_old_libs=yes
9015 if test yes = "$allow_undefined"; then
9016 if test unsupported = "$allow_undefined_flag"; then
9017 if test yes = "$build_old_libs"; then
9018 func_warning "undefined symbols not allowed in $host shared libraries; building static only"
9019 build_libtool_libs=no
9020 else
9021 func_fatal_error "can't build $host shared library unless -no-undefined is specified"
9022 fi
75379023 fi
75389024 else
75399025 # Don't allow undefined symbols.
7540 allow_undefined_flag="$no_undefined_flag"
9026 allow_undefined_flag=$no_undefined_flag
75419027 fi
75429028
75439029 fi
75449030
7545 func_generate_dlsyms "$libname" "$libname" "yes"
9031 func_generate_dlsyms "$libname" "$libname" :
75469032 func_append libobjs " $symfileobj"
7547 test "X$libobjs" = "X " && libobjs=
7548
7549 if test "$opt_mode" != relink; then
9033 test " " = "$libobjs" && libobjs=
9034
9035 if test relink != "$opt_mode"; then
75509036 # Remove our outputs, but don't remove object files since they
75519037 # may have been created when compiling PIC objects.
75529038 removelist=
75559041 case $p in
75569042 *.$objext | *.gcno)
75579043 ;;
7558 $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*)
7559 if test "X$precious_files_regex" != "X"; then
9044 $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/$libname$release.*)
9045 if test -n "$precious_files_regex"; then
75609046 if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1
75619047 then
75629048 continue
75729058 fi
75739059
75749060 # Now set the variables for building old libraries.
7575 if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then
9061 if test yes = "$build_old_libs" && test convenience != "$build_libtool_libs"; then
75769062 func_append oldlibs " $output_objdir/$libname.$libext"
75779063
75789064 # Transform .lo files to .o files.
7579 oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP`
9065 oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; $lo2o" | $NL2SP`
75809066 fi
75819067
75829068 # Eliminate all temporary directories.
75979083 *) func_append finalize_rpath " $libdir" ;;
75989084 esac
75999085 done
7600 if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then
9086 if test yes != "$hardcode_into_libs" || test yes = "$build_old_libs"; then
76019087 dependency_libs="$temp_xrpath $dependency_libs"
76029088 fi
76039089 fi
76049090
76059091 # Make sure dlfiles contains only unique files that won't be dlpreopened
7606 old_dlfiles="$dlfiles"
9092 old_dlfiles=$dlfiles
76079093 dlfiles=
76089094 for lib in $old_dlfiles; do
76099095 case " $dlprefiles $dlfiles " in
76139099 done
76149100
76159101 # Make sure dlprefiles contains only unique files
7616 old_dlprefiles="$dlprefiles"
9102 old_dlprefiles=$dlprefiles
76179103 dlprefiles=
76189104 for lib in $old_dlprefiles; do
76199105 case "$dlprefiles " in
76229108 esac
76239109 done
76249110
7625 if test "$build_libtool_libs" = yes; then
9111 if test yes = "$build_libtool_libs"; then
76269112 if test -n "$rpath"; then
76279113 case $host in
76289114 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*)
76469132 ;;
76479133 *)
76489134 # Add libc to deplibs on all other systems if necessary.
7649 if test "$build_libtool_need_lc" = "yes"; then
9135 if test yes = "$build_libtool_need_lc"; then
76509136 func_append deplibs " -lc"
76519137 fi
76529138 ;;
76629148 # I'm not sure if I'm treating the release correctly. I think
76639149 # release should show up in the -l (ie -lgmp5) so we don't want to
76649150 # add it in twice. Is that correct?
7665 release=""
7666 versuffix=""
7667 major=""
9151 release=
9152 versuffix=
9153 major=
76689154 newdeplibs=
76699155 droppeddeps=no
76709156 case $deplibs_check_method in
76939179 -l*)
76949180 func_stripname -l '' "$i"
76959181 name=$func_stripname_result
7696 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
9182 if test yes = "$allow_libtool_libs_with_static_runtimes"; then
76979183 case " $predeps $postdeps " in
76989184 *" $i "*)
76999185 func_append newdeplibs " $i"
7700 i=""
9186 i=
77019187 ;;
77029188 esac
77039189 fi
7704 if test -n "$i" ; then
9190 if test -n "$i"; then
77059191 libname=`eval "\\$ECHO \"$libname_spec\""`
77069192 deplib_matches=`eval "\\$ECHO \"$library_names_spec\""`
77079193 set dummy $deplib_matches; shift
77089194 deplib_match=$1
7709 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
9195 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0; then
77109196 func_append newdeplibs " $i"
77119197 else
77129198 droppeddeps=yes
77369222 $opt_dry_run || $RM conftest
77379223 if $LTCC $LTCFLAGS -o conftest conftest.c $i; then
77389224 ldd_output=`ldd conftest`
7739 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
9225 if test yes = "$allow_libtool_libs_with_static_runtimes"; then
77409226 case " $predeps $postdeps " in
77419227 *" $i "*)
77429228 func_append newdeplibs " $i"
7743 i=""
9229 i=
77449230 ;;
77459231 esac
77469232 fi
7747 if test -n "$i" ; then
9233 if test -n "$i"; then
77489234 libname=`eval "\\$ECHO \"$libname_spec\""`
77499235 deplib_matches=`eval "\\$ECHO \"$library_names_spec\""`
77509236 set dummy $deplib_matches; shift
77519237 deplib_match=$1
7752 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
9238 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0; then
77539239 func_append newdeplibs " $i"
77549240 else
77559241 droppeddeps=yes
77869272 -l*)
77879273 func_stripname -l '' "$a_deplib"
77889274 name=$func_stripname_result
7789 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
9275 if test yes = "$allow_libtool_libs_with_static_runtimes"; then
77909276 case " $predeps $postdeps " in
77919277 *" $a_deplib "*)
77929278 func_append newdeplibs " $a_deplib"
7793 a_deplib=""
9279 a_deplib=
77949280 ;;
77959281 esac
77969282 fi
7797 if test -n "$a_deplib" ; then
9283 if test -n "$a_deplib"; then
77989284 libname=`eval "\\$ECHO \"$libname_spec\""`
77999285 if test -n "$file_magic_glob"; then
78009286 libnameglob=`func_echo_all "$libname" | $SED -e $file_magic_glob`
78019287 else
78029288 libnameglob=$libname
78039289 fi
7804 test "$want_nocaseglob" = yes && nocaseglob=`shopt -p nocaseglob`
9290 test yes = "$want_nocaseglob" && nocaseglob=`shopt -p nocaseglob`
78059291 for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
7806 if test "$want_nocaseglob" = yes; then
9292 if test yes = "$want_nocaseglob"; then
78079293 shopt -s nocaseglob
78089294 potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null`
78099295 $nocaseglob
78219307 # We might still enter an endless loop, since a link
78229308 # loop can be closed while we follow links,
78239309 # but so what?
7824 potlib="$potent_lib"
9310 potlib=$potent_lib
78259311 while test -h "$potlib" 2>/dev/null; do
7826 potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'`
9312 potliblink=`ls -ld $potlib | $SED 's/.* -> //'`
78279313 case $potliblink in
7828 [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";;
7829 *) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";;
9314 [\\/]* | [A-Za-z]:[\\/]*) potlib=$potliblink;;
9315 *) potlib=`$ECHO "$potlib" | $SED 's|[^/]*$||'`"$potliblink";;
78309316 esac
78319317 done
78329318 if eval $file_magic_cmd \"\$potlib\" 2>/dev/null |
78339319 $SED -e 10q |
78349320 $EGREP "$file_magic_regex" > /dev/null; then
78359321 func_append newdeplibs " $a_deplib"
7836 a_deplib=""
9322 a_deplib=
78379323 break 2
78389324 fi
78399325 done
78409326 done
78419327 fi
7842 if test -n "$a_deplib" ; then
9328 if test -n "$a_deplib"; then
78439329 droppeddeps=yes
78449330 echo
78459331 $ECHO "*** Warning: linker path does not have real file for library $a_deplib."
78479333 echo "*** you link to this library. But I can only do this if you have a"
78489334 echo "*** shared version of the library, which you do not appear to have"
78499335 echo "*** because I did check the linker path looking for a file starting"
7850 if test -z "$potlib" ; then
9336 if test -z "$potlib"; then
78519337 $ECHO "*** with $libname but no candidates were found. (...for file magic test)"
78529338 else
78539339 $ECHO "*** with $libname and none of the candidates passed a file format test"
78709356 -l*)
78719357 func_stripname -l '' "$a_deplib"
78729358 name=$func_stripname_result
7873 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
9359 if test yes = "$allow_libtool_libs_with_static_runtimes"; then
78749360 case " $predeps $postdeps " in
78759361 *" $a_deplib "*)
78769362 func_append newdeplibs " $a_deplib"
7877 a_deplib=""
9363 a_deplib=
78789364 ;;
78799365 esac
78809366 fi
7881 if test -n "$a_deplib" ; then
9367 if test -n "$a_deplib"; then
78829368 libname=`eval "\\$ECHO \"$libname_spec\""`
78839369 for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
78849370 potential_libs=`ls $i/$libname[.-]* 2>/dev/null`
78859371 for potent_lib in $potential_libs; do
7886 potlib="$potent_lib" # see symlink-check above in file_magic test
9372 potlib=$potent_lib # see symlink-check above in file_magic test
78879373 if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \
78889374 $EGREP "$match_pattern_regex" > /dev/null; then
78899375 func_append newdeplibs " $a_deplib"
7890 a_deplib=""
9376 a_deplib=
78919377 break 2
78929378 fi
78939379 done
78949380 done
78959381 fi
7896 if test -n "$a_deplib" ; then
9382 if test -n "$a_deplib"; then
78979383 droppeddeps=yes
78989384 echo
78999385 $ECHO "*** Warning: linker path does not have real file for library $a_deplib."
79019387 echo "*** you link to this library. But I can only do this if you have a"
79029388 echo "*** shared version of the library, which you do not appear to have"
79039389 echo "*** because I did check the linker path looking for a file starting"
7904 if test -z "$potlib" ; then
9390 if test -z "$potlib"; then
79059391 $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)"
79069392 else
79079393 $ECHO "*** with $libname and none of the candidates passed a file format test"
79179403 done # Gone through all deplibs.
79189404 ;;
79199405 none | unknown | *)
7920 newdeplibs=""
9406 newdeplibs=
79219407 tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'`
7922 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7923 for i in $predeps $postdeps ; do
9408 if test yes = "$allow_libtool_libs_with_static_runtimes"; then
9409 for i in $predeps $postdeps; do
79249410 # can't use Xsed below, because $i might contain '/'
7925 tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"`
9411 tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s|$i||"`
79269412 done
79279413 fi
79289414 case $tmp_deplibs in
79299415 *[!\ \ ]*)
79309416 echo
7931 if test "X$deplibs_check_method" = "Xnone"; then
9417 if test none = "$deplibs_check_method"; then
79329418 echo "*** Warning: inter-library dependencies are not supported in this platform."
79339419 else
79349420 echo "*** Warning: inter-library dependencies are not known to be supported."
79529438 ;;
79539439 esac
79549440
7955 if test "$droppeddeps" = yes; then
7956 if test "$module" = yes; then
9441 if test yes = "$droppeddeps"; then
9442 if test yes = "$module"; then
79579443 echo
79589444 echo "*** Warning: libtool could not satisfy all declared inter-library"
79599445 $ECHO "*** dependencies of module $libname. Therefore, libtool will create"
79629448 if test -z "$global_symbol_pipe"; then
79639449 echo
79649450 echo "*** However, this would only work if libtool was able to extract symbol"
7965 echo "*** lists from a program, using \`nm' or equivalent, but libtool could"
9451 echo "*** lists from a program, using 'nm' or equivalent, but libtool could"
79669452 echo "*** not find such a program. So, this module is probably useless."
7967 echo "*** \`nm' from GNU binutils and a full rebuild may help."
9453 echo "*** 'nm' from GNU binutils and a full rebuild may help."
79689454 fi
7969 if test "$build_old_libs" = no; then
7970 oldlibs="$output_objdir/$libname.$libext"
9455 if test no = "$build_old_libs"; then
9456 oldlibs=$output_objdir/$libname.$libext
79719457 build_libtool_libs=module
79729458 build_old_libs=yes
79739459 else
79789464 echo "*** automatically added whenever a program is linked with this library"
79799465 echo "*** or is declared to -dlopen it."
79809466
7981 if test "$allow_undefined" = no; then
9467 if test no = "$allow_undefined"; then
79829468 echo
79839469 echo "*** Since this library must not contain undefined symbols,"
79849470 echo "*** because either the platform does not support them or"
79859471 echo "*** it was explicitly requested with -no-undefined,"
79869472 echo "*** libtool will only create a static version of it."
7987 if test "$build_old_libs" = no; then
7988 oldlibs="$output_objdir/$libname.$libext"
9473 if test no = "$build_old_libs"; then
9474 oldlibs=$output_objdir/$libname.$libext
79899475 build_libtool_libs=module
79909476 build_old_libs=yes
79919477 else
80319517 *) func_append new_libs " $deplib" ;;
80329518 esac
80339519 done
8034 deplibs="$new_libs"
9520 deplibs=$new_libs
80359521
80369522 # All the library-specific variables (install_libdir is set above).
80379523 library_names=
80399525 dlname=
80409526
80419527 # Test again, we may have decided not to build it any more
8042 if test "$build_libtool_libs" = yes; then
8043 # Remove ${wl} instances when linking with ld.
9528 if test yes = "$build_libtool_libs"; then
9529 # Remove $wl instances when linking with ld.
80449530 # FIXME: should test the right _cmds variable.
80459531 case $archive_cmds in
80469532 *\$LD\ *) wl= ;;
80479533 esac
8048 if test "$hardcode_into_libs" = yes; then
9534 if test yes = "$hardcode_into_libs"; then
80499535 # Hardcode the library paths
80509536 hardcode_libdirs=
80519537 dep_rpath=
8052 rpath="$finalize_rpath"
8053 test "$opt_mode" != relink && rpath="$compile_rpath$rpath"
9538 rpath=$finalize_rpath
9539 test relink = "$opt_mode" || rpath=$compile_rpath$rpath
80549540 for libdir in $rpath; do
80559541 if test -n "$hardcode_libdir_flag_spec"; then
80569542 if test -n "$hardcode_libdir_separator"; then
80579543 func_replace_sysroot "$libdir"
80589544 libdir=$func_replace_sysroot_result
80599545 if test -z "$hardcode_libdirs"; then
8060 hardcode_libdirs="$libdir"
9546 hardcode_libdirs=$libdir
80619547 else
80629548 # Just accumulate the unique libdirs.
80639549 case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
80829568 # Substitute the hardcoded libdirs into the rpath.
80839569 if test -n "$hardcode_libdir_separator" &&
80849570 test -n "$hardcode_libdirs"; then
8085 libdir="$hardcode_libdirs"
9571 libdir=$hardcode_libdirs
80869572 eval "dep_rpath=\"$hardcode_libdir_flag_spec\""
80879573 fi
80889574 if test -n "$runpath_var" && test -n "$perm_rpath"; then
80969582 test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs"
80979583 fi
80989584
8099 shlibpath="$finalize_shlibpath"
8100 test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath"
9585 shlibpath=$finalize_shlibpath
9586 test relink = "$opt_mode" || shlibpath=$compile_shlibpath$shlibpath
81019587 if test -n "$shlibpath"; then
81029588 eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var"
81039589 fi
81079593 eval library_names=\"$library_names_spec\"
81089594 set dummy $library_names
81099595 shift
8110 realname="$1"
9596 realname=$1
81119597 shift
81129598
81139599 if test -n "$soname_spec"; then
81149600 eval soname=\"$soname_spec\"
81159601 else
8116 soname="$realname"
9602 soname=$realname
81179603 fi
81189604 if test -z "$dlname"; then
81199605 dlname=$soname
81209606 fi
81219607
8122 lib="$output_objdir/$realname"
9608 lib=$output_objdir/$realname
81239609 linknames=
81249610 for link
81259611 do
81339619 delfiles=
81349620 if test -n "$export_symbols" && test -n "$include_expsyms"; then
81359621 $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp"
8136 export_symbols="$output_objdir/$libname.uexp"
9622 export_symbols=$output_objdir/$libname.uexp
81379623 func_append delfiles " $export_symbols"
81389624 fi
81399625
81429628 cygwin* | mingw* | cegcc*)
81439629 if test -n "$export_symbols" && test -z "$export_symbols_regex"; then
81449630 # exporting using user supplied symfile
8145 if test "x`$SED 1q $export_symbols`" != xEXPORTS; then
9631 func_dll_def_p "$export_symbols" || {
81469632 # and it's NOT already a .def file. Must figure out
81479633 # which of the given symbols are data symbols and tag
81489634 # them as such. So, trigger use of export_symbols_cmds.
81499635 # export_symbols gets reassigned inside the "prepare
81509636 # the list of exported symbols" if statement, so the
81519637 # include_expsyms logic still works.
8152 orig_export_symbols="$export_symbols"
9638 orig_export_symbols=$export_symbols
81539639 export_symbols=
81549640 always_export_symbols=yes
8155 fi
9641 }
81569642 fi
81579643 ;;
81589644 esac
81599645
81609646 # Prepare the list of exported symbols
81619647 if test -z "$export_symbols"; then
8162 if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then
8163 func_verbose "generating symbol list for \`$libname.la'"
8164 export_symbols="$output_objdir/$libname.exp"
9648 if test yes = "$always_export_symbols" || test -n "$export_symbols_regex"; then
9649 func_verbose "generating symbol list for '$libname.la'"
9650 export_symbols=$output_objdir/$libname.exp
81659651 $opt_dry_run || $RM $export_symbols
81669652 cmds=$export_symbols_cmds
8167 save_ifs="$IFS"; IFS='~'
9653 save_ifs=$IFS; IFS='~'
81689654 for cmd1 in $cmds; do
8169 IFS="$save_ifs"
9655 IFS=$save_ifs
81709656 # Take the normal branch if the nm_file_list_spec branch
81719657 # doesn't work or if tool conversion is not needed.
81729658 case $nm_file_list_spec~$to_tool_file_cmd in
81809666 try_normal_branch=no
81819667 ;;
81829668 esac
8183 if test "$try_normal_branch" = yes \
9669 if test yes = "$try_normal_branch" \
81849670 && { test "$len" -lt "$max_cmd_len" \
81859671 || test "$max_cmd_len" -le -1; }
81869672 then
81919677 output_la=$func_basename_result
81929678 save_libobjs=$libobjs
81939679 save_output=$output
8194 output=${output_objdir}/${output_la}.nm
9680 output=$output_objdir/$output_la.nm
81959681 func_to_tool_file "$output"
81969682 libobjs=$nm_file_list_spec$func_to_tool_file_result
81979683 func_append delfiles " $output"
82149700 break
82159701 fi
82169702 done
8217 IFS="$save_ifs"
8218 if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then
9703 IFS=$save_ifs
9704 if test -n "$export_symbols_regex" && test : != "$skipped_export"; then
82199705 func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"'
82209706 func_show_eval '$MV "${export_symbols}T" "$export_symbols"'
82219707 fi
82239709 fi
82249710
82259711 if test -n "$export_symbols" && test -n "$include_expsyms"; then
8226 tmp_export_symbols="$export_symbols"
8227 test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
9712 tmp_export_symbols=$export_symbols
9713 test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols
82289714 $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
82299715 fi
82309716
8231 if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then
9717 if test : != "$skipped_export" && test -n "$orig_export_symbols"; then
82329718 # The given exports_symbols file has to be filtered, so filter it.
8233 func_verbose "filter symbol list for \`$libname.la' to tag DATA exports"
9719 func_verbose "filter symbol list for '$libname.la' to tag DATA exports"
82349720 # FIXME: $output_objdir/$libname.filter potentially contains lots of
8235 # 's' commands which not all seds can handle. GNU sed should be fine
9721 # 's' commands, which not all seds can handle. GNU sed should be fine
82369722 # though. Also, the filter scales superlinearly with the number of
82379723 # global variables. join(1) would be nice here, but unfortunately
82389724 # isn't a blessed tool.
82519737 ;;
82529738 esac
82539739 done
8254 deplibs="$tmp_deplibs"
9740 deplibs=$tmp_deplibs
82559741
82569742 if test -n "$convenience"; then
82579743 if test -n "$whole_archive_flag_spec" &&
8258 test "$compiler_needs_object" = yes &&
9744 test yes = "$compiler_needs_object" &&
82599745 test -z "$libobjs"; then
82609746 # extract the archives, so we have objects to list.
82619747 # TODO: could optimize this to just extract one archive.
82669752 eval libobjs=\"\$libobjs $whole_archive_flag_spec\"
82679753 test "X$libobjs" = "X " && libobjs=
82689754 else
8269 gentop="$output_objdir/${outputname}x"
9755 gentop=$output_objdir/${outputname}x
82709756 func_append generated " $gentop"
82719757
82729758 func_extract_archives $gentop $convenience
82759761 fi
82769762 fi
82779763
8278 if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then
9764 if test yes = "$thread_safe" && test -n "$thread_safe_flag_spec"; then
82799765 eval flag=\"$thread_safe_flag_spec\"
82809766 func_append linker_flags " $flag"
82819767 fi
82829768
82839769 # Make a backup of the uninstalled library when relinking
8284 if test "$opt_mode" = relink; then
9770 if test relink = "$opt_mode"; then
82859771 $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $?
82869772 fi
82879773
82889774 # Do each of the archive commands.
8289 if test "$module" = yes && test -n "$module_cmds" ; then
9775 if test yes = "$module" && test -n "$module_cmds"; then
82909776 if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then
82919777 eval test_cmds=\"$module_expsym_cmds\"
82929778 cmds=$module_expsym_cmds
83049790 fi
83059791 fi
83069792
8307 if test "X$skipped_export" != "X:" &&
9793 if test : != "$skipped_export" &&
83089794 func_len " $test_cmds" &&
83099795 len=$func_len_result &&
83109796 test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then
83379823 last_robj=
83389824 k=1
83399825
8340 if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then
8341 output=${output_objdir}/${output_la}.lnkscript
9826 if test -n "$save_libobjs" && test : != "$skipped_export" && test yes = "$with_gnu_ld"; then
9827 output=$output_objdir/$output_la.lnkscript
83429828 func_verbose "creating GNU ld script: $output"
83439829 echo 'INPUT (' > $output
83449830 for obj in $save_libobjs
83509836 func_append delfiles " $output"
83519837 func_to_tool_file "$output"
83529838 output=$func_to_tool_file_result
8353 elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then
8354 output=${output_objdir}/${output_la}.lnk
9839 elif test -n "$save_libobjs" && test : != "$skipped_export" && test -n "$file_list_spec"; then
9840 output=$output_objdir/$output_la.lnk
83559841 func_verbose "creating linker input file list: $output"
83569842 : > $output
83579843 set x $save_libobjs
83589844 shift
83599845 firstobj=
8360 if test "$compiler_needs_object" = yes; then
9846 if test yes = "$compiler_needs_object"; then
83619847 firstobj="$1 "
83629848 shift
83639849 fi
83729858 else
83739859 if test -n "$save_libobjs"; then
83749860 func_verbose "creating reloadable object files..."
8375 output=$output_objdir/$output_la-${k}.$objext
9861 output=$output_objdir/$output_la-$k.$objext
83769862 eval test_cmds=\"$reload_cmds\"
83779863 func_len " $test_cmds"
83789864 len0=$func_len_result
83849870 func_len " $obj"
83859871 func_arith $len + $func_len_result
83869872 len=$func_arith_result
8387 if test "X$objlist" = X ||
9873 if test -z "$objlist" ||
83889874 test "$len" -lt "$max_cmd_len"; then
83899875 func_append objlist " $obj"
83909876 else
83919877 # The command $test_cmds is almost too long, add a
83929878 # command to the queue.
8393 if test "$k" -eq 1 ; then
9879 if test 1 -eq "$k"; then
83949880 # The first file doesn't have a previous command to add.
83959881 reload_objs=$objlist
83969882 eval concat_cmds=\"$reload_cmds\"
84009886 reload_objs="$objlist $last_robj"
84019887 eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\"
84029888 fi
8403 last_robj=$output_objdir/$output_la-${k}.$objext
9889 last_robj=$output_objdir/$output_la-$k.$objext
84049890 func_arith $k + 1
84059891 k=$func_arith_result
8406 output=$output_objdir/$output_la-${k}.$objext
9892 output=$output_objdir/$output_la-$k.$objext
84079893 objlist=" $obj"
84089894 func_len " $last_robj"
84099895 func_arith $len0 + $func_len_result
84159901 # files will link in the last one created.
84169902 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
84179903 reload_objs="$objlist $last_robj"
8418 eval concat_cmds=\"\${concat_cmds}$reload_cmds\"
9904 eval concat_cmds=\"\$concat_cmds$reload_cmds\"
84199905 if test -n "$last_robj"; then
8420 eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\"
9906 eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\"
84219907 fi
84229908 func_append delfiles " $output"
84239909
84259911 output=
84269912 fi
84279913
8428 if ${skipped_export-false}; then
8429 func_verbose "generating symbol list for \`$libname.la'"
8430 export_symbols="$output_objdir/$libname.exp"
9914 ${skipped_export-false} && {
9915 func_verbose "generating symbol list for '$libname.la'"
9916 export_symbols=$output_objdir/$libname.exp
84319917 $opt_dry_run || $RM $export_symbols
84329918 libobjs=$output
84339919 # Append the command to create the export file.
84369922 if test -n "$last_robj"; then
84379923 eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\"
84389924 fi
8439 fi
9925 }
84409926
84419927 test -n "$save_libobjs" &&
84429928 func_verbose "creating a temporary reloadable object file: $output"
84439929
84449930 # Loop through the commands generated above and execute them.
8445 save_ifs="$IFS"; IFS='~'
9931 save_ifs=$IFS; IFS='~'
84469932 for cmd in $concat_cmds; do
8447 IFS="$save_ifs"
8448 $opt_silent || {
9933 IFS=$save_ifs
9934 $opt_quiet || {
84499935 func_quote_for_expand "$cmd"
84509936 eval "func_echo $func_quote_for_expand_result"
84519937 }
84539939 lt_exit=$?
84549940
84559941 # Restore the uninstalled library and exit
8456 if test "$opt_mode" = relink; then
9942 if test relink = "$opt_mode"; then
84579943 ( cd "$output_objdir" && \
84589944 $RM "${realname}T" && \
84599945 $MV "${realname}U" "$realname" )
84629948 exit $lt_exit
84639949 }
84649950 done
8465 IFS="$save_ifs"
9951 IFS=$save_ifs
84669952
84679953 if test -n "$export_symbols_regex" && ${skipped_export-false}; then
84689954 func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"'
84709956 fi
84719957 fi
84729958
8473 if ${skipped_export-false}; then
9959 ${skipped_export-false} && {
84749960 if test -n "$export_symbols" && test -n "$include_expsyms"; then
8475 tmp_export_symbols="$export_symbols"
8476 test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
9961 tmp_export_symbols=$export_symbols
9962 test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols
84779963 $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
84789964 fi
84799965
84809966 if test -n "$orig_export_symbols"; then
84819967 # The given exports_symbols file has to be filtered, so filter it.
8482 func_verbose "filter symbol list for \`$libname.la' to tag DATA exports"
9968 func_verbose "filter symbol list for '$libname.la' to tag DATA exports"
84839969 # FIXME: $output_objdir/$libname.filter potentially contains lots of
8484 # 's' commands which not all seds can handle. GNU sed should be fine
9970 # 's' commands, which not all seds can handle. GNU sed should be fine
84859971 # though. Also, the filter scales superlinearly with the number of
84869972 # global variables. join(1) would be nice here, but unfortunately
84879973 # isn't a blessed tool.
84909976 export_symbols=$output_objdir/$libname.def
84919977 $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
84929978 fi
8493 fi
9979 }
84949980
84959981 libobjs=$output
84969982 # Restore the value of output.
85049990 # value of $libobjs for piecewise linking.
85059991
85069992 # Do each of the archive commands.
8507 if test "$module" = yes && test -n "$module_cmds" ; then
9993 if test yes = "$module" && test -n "$module_cmds"; then
85089994 if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then
85099995 cmds=$module_expsym_cmds
85109996 else
852610012
852710013 # Add any objects from preloaded convenience libraries
852810014 if test -n "$dlprefiles"; then
8529 gentop="$output_objdir/${outputname}x"
10015 gentop=$output_objdir/${outputname}x
853010016 func_append generated " $gentop"
853110017
853210018 func_extract_archives $gentop $dlprefiles
853410020 test "X$libobjs" = "X " && libobjs=
853510021 fi
853610022
8537 save_ifs="$IFS"; IFS='~'
10023 save_ifs=$IFS; IFS='~'
853810024 for cmd in $cmds; do
8539 IFS="$save_ifs"
10025 IFS=$sp$nl
854010026 eval cmd=\"$cmd\"
8541 $opt_silent || {
10027 IFS=$save_ifs
10028 $opt_quiet || {
854210029 func_quote_for_expand "$cmd"
854310030 eval "func_echo $func_quote_for_expand_result"
854410031 }
854610033 lt_exit=$?
854710034
854810035 # Restore the uninstalled library and exit
8549 if test "$opt_mode" = relink; then
10036 if test relink = "$opt_mode"; then
855010037 ( cd "$output_objdir" && \
855110038 $RM "${realname}T" && \
855210039 $MV "${realname}U" "$realname" )
855510042 exit $lt_exit
855610043 }
855710044 done
8558 IFS="$save_ifs"
10045 IFS=$save_ifs
855910046
856010047 # Restore the uninstalled library and exit
8561 if test "$opt_mode" = relink; then
10048 if test relink = "$opt_mode"; then
856210049 $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $?
856310050
856410051 if test -n "$convenience"; then
857810065 done
857910066
858010067 # If -module or -export-dynamic was specified, set the dlname.
8581 if test "$module" = yes || test "$export_dynamic" = yes; then
10068 if test yes = "$module" || test yes = "$export_dynamic"; then
858210069 # On all known operating systems, these are identical.
8583 dlname="$soname"
10070 dlname=$soname
858410071 fi
858510072 fi
858610073 ;;
858710074
858810075 obj)
8589 if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
8590 func_warning "\`-dlopen' is ignored for objects"
10076 if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then
10077 func_warning "'-dlopen' is ignored for objects"
859110078 fi
859210079
859310080 case " $deplibs" in
859410081 *\ -l* | *\ -L*)
8595 func_warning "\`-l' and \`-L' are ignored for objects" ;;
10082 func_warning "'-l' and '-L' are ignored for objects" ;;
859610083 esac
859710084
859810085 test -n "$rpath" && \
8599 func_warning "\`-rpath' is ignored for objects"
10086 func_warning "'-rpath' is ignored for objects"
860010087
860110088 test -n "$xrpath" && \
8602 func_warning "\`-R' is ignored for objects"
10089 func_warning "'-R' is ignored for objects"
860310090
860410091 test -n "$vinfo" && \
8605 func_warning "\`-version-info' is ignored for objects"
10092 func_warning "'-version-info' is ignored for objects"
860610093
860710094 test -n "$release" && \
8608 func_warning "\`-release' is ignored for objects"
10095 func_warning "'-release' is ignored for objects"
860910096
861010097 case $output in
861110098 *.lo)
861210099 test -n "$objs$old_deplibs" && \
8613 func_fatal_error "cannot build library object \`$output' from non-libtool objects"
10100 func_fatal_error "cannot build library object '$output' from non-libtool objects"
861410101
861510102 libobj=$output
861610103 func_lo2o "$libobj"
861810105 ;;
861910106 *)
862010107 libobj=
8621 obj="$output"
10108 obj=$output
862210109 ;;
862310110 esac
862410111
863110118 # the extraction.
863210119 reload_conv_objs=
863310120 gentop=
8634 # reload_cmds runs $LD directly, so let us get rid of
8635 # -Wl from whole_archive_flag_spec and hope we can get by with
8636 # turning comma into space..
8637 wl=
8638
10121 # if reload_cmds runs $LD directly, get rid of -Wl from
10122 # whole_archive_flag_spec and hope we can get by with turning comma
10123 # into space.
10124 case $reload_cmds in
10125 *\$LD[\ \$]*) wl= ;;
10126 esac
863910127 if test -n "$convenience"; then
864010128 if test -n "$whole_archive_flag_spec"; then
864110129 eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\"
8642 reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'`
10130 test -n "$wl" || tmp_whole_archive_flags=`$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'`
10131 reload_conv_objs=$reload_objs\ $tmp_whole_archive_flags
864310132 else
8644 gentop="$output_objdir/${obj}x"
10133 gentop=$output_objdir/${obj}x
864510134 func_append generated " $gentop"
864610135
864710136 func_extract_archives $gentop $convenience
865010139 fi
865110140
865210141 # If we're not building shared, we need to use non_pic_objs
8653 test "$build_libtool_libs" != yes && libobjs="$non_pic_objects"
10142 test yes = "$build_libtool_libs" || libobjs=$non_pic_objects
865410143
865510144 # Create the old-style object.
8656 reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test
8657
8658 output="$obj"
10145 reload_objs=$objs$old_deplibs' '`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; /\.lib$/d; $lo2o" | $NL2SP`' '$reload_conv_objs
10146
10147 output=$obj
865910148 func_execute_cmds "$reload_cmds" 'exit $?'
866010149
866110150 # Exit if we aren't doing a library object file.
866710156 exit $EXIT_SUCCESS
866810157 fi
866910158
8670 if test "$build_libtool_libs" != yes; then
10159 test yes = "$build_libtool_libs" || {
867110160 if test -n "$gentop"; then
867210161 func_show_eval '${RM}r "$gentop"'
867310162 fi
867710166 # $show "echo timestamp > $libobj"
867810167 # $opt_dry_run || eval "echo timestamp > $libobj" || exit $?
867910168 exit $EXIT_SUCCESS
8680 fi
8681
8682 if test -n "$pic_flag" || test "$pic_mode" != default; then
10169 }
10170
10171 if test -n "$pic_flag" || test default != "$pic_mode"; then
868310172 # Only do commands if we really have different PIC objects.
868410173 reload_objs="$libobjs $reload_conv_objs"
8685 output="$libobj"
10174 output=$libobj
868610175 func_execute_cmds "$reload_cmds" 'exit $?'
868710176 fi
868810177
869910188 output=$func_stripname_result.exe;;
870010189 esac
870110190 test -n "$vinfo" && \
8702 func_warning "\`-version-info' is ignored for programs"
10191 func_warning "'-version-info' is ignored for programs"
870310192
870410193 test -n "$release" && \
8705 func_warning "\`-release' is ignored for programs"
8706
8707 test "$preload" = yes \
8708 && test "$dlopen_support" = unknown \
8709 && test "$dlopen_self" = unknown \
8710 && test "$dlopen_self_static" = unknown && \
8711 func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support."
10194 func_warning "'-release' is ignored for programs"
10195
10196 $preload \
10197 && test unknown,unknown,unknown = "$dlopen_support,$dlopen_self,$dlopen_self_static" \
10198 && func_warning "'LT_INIT([dlopen])' not used. Assuming no dlopen support."
871210199
871310200 case $host in
871410201 *-*-rhapsody* | *-*-darwin1.[012])
872210209 *-*-darwin*)
872310210 # Don't allow lazy linking, it breaks C++ global constructors
872410211 # But is supposedly fixed on 10.4 or later (yay!).
8725 if test "$tagname" = CXX ; then
10212 if test CXX = "$tagname"; then
872610213 case ${MACOSX_DEPLOYMENT_TARGET-10.0} in
872710214 10.[0123])
8728 func_append compile_command " ${wl}-bind_at_load"
8729 func_append finalize_command " ${wl}-bind_at_load"
10215 func_append compile_command " $wl-bind_at_load"
10216 func_append finalize_command " $wl-bind_at_load"
873010217 ;;
873110218 esac
873210219 fi
876210249 *) func_append new_libs " $deplib" ;;
876310250 esac
876410251 done
8765 compile_deplibs="$new_libs"
10252 compile_deplibs=$new_libs
876610253
876710254
876810255 func_append compile_command " $compile_deplibs"
878610273 if test -n "$hardcode_libdir_flag_spec"; then
878710274 if test -n "$hardcode_libdir_separator"; then
878810275 if test -z "$hardcode_libdirs"; then
8789 hardcode_libdirs="$libdir"
10276 hardcode_libdirs=$libdir
879010277 else
879110278 # Just accumulate the unique libdirs.
879210279 case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
880910296 fi
881010297 case $host in
881110298 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
8812 testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'`
10299 testbindir=`$ECHO "$libdir" | $SED -e 's*/lib$*/bin*'`
881310300 case :$dllsearchpath: in
881410301 *":$libdir:"*) ;;
881510302 ::) dllsearchpath=$libdir;;
882610313 # Substitute the hardcoded libdirs into the rpath.
882710314 if test -n "$hardcode_libdir_separator" &&
882810315 test -n "$hardcode_libdirs"; then
8829 libdir="$hardcode_libdirs"
10316 libdir=$hardcode_libdirs
883010317 eval rpath=\" $hardcode_libdir_flag_spec\"
883110318 fi
8832 compile_rpath="$rpath"
10319 compile_rpath=$rpath
883310320
883410321 rpath=
883510322 hardcode_libdirs=
883710324 if test -n "$hardcode_libdir_flag_spec"; then
883810325 if test -n "$hardcode_libdir_separator"; then
883910326 if test -z "$hardcode_libdirs"; then
8840 hardcode_libdirs="$libdir"
10327 hardcode_libdirs=$libdir
884110328 else
884210329 # Just accumulate the unique libdirs.
884310330 case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
886210349 # Substitute the hardcoded libdirs into the rpath.
886310350 if test -n "$hardcode_libdir_separator" &&
886410351 test -n "$hardcode_libdirs"; then
8865 libdir="$hardcode_libdirs"
10352 libdir=$hardcode_libdirs
886610353 eval rpath=\" $hardcode_libdir_flag_spec\"
886710354 fi
8868 finalize_rpath="$rpath"
8869
8870 if test -n "$libobjs" && test "$build_old_libs" = yes; then
10355 finalize_rpath=$rpath
10356
10357 if test -n "$libobjs" && test yes = "$build_old_libs"; then
887110358 # Transform all the library objects into standard objects.
887210359 compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP`
887310360 finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP`
887410361 fi
887510362
8876 func_generate_dlsyms "$outputname" "@PROGRAM@" "no"
10363 func_generate_dlsyms "$outputname" "@PROGRAM@" false
887710364
887810365 # template prelinking step
887910366 if test -n "$prelink_cmds"; then
888010367 func_execute_cmds "$prelink_cmds" 'exit $?'
888110368 fi
888210369
8883 wrappers_required=yes
10370 wrappers_required=:
888410371 case $host in
888510372 *cegcc* | *mingw32ce*)
888610373 # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway.
8887 wrappers_required=no
10374 wrappers_required=false
888810375 ;;
888910376 *cygwin* | *mingw* )
8890 if test "$build_libtool_libs" != yes; then
8891 wrappers_required=no
8892 fi
10377 test yes = "$build_libtool_libs" || wrappers_required=false
889310378 ;;
889410379 *)
8895 if test "$need_relink" = no || test "$build_libtool_libs" != yes; then
8896 wrappers_required=no
10380 if test no = "$need_relink" || test yes != "$build_libtool_libs"; then
10381 wrappers_required=false
889710382 fi
889810383 ;;
889910384 esac
8900 if test "$wrappers_required" = no; then
10385 $wrappers_required || {
890110386 # Replace the output file specification.
890210387 compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'`
8903 link_command="$compile_command$compile_rpath"
10388 link_command=$compile_command$compile_rpath
890410389
890510390 # We have no uninstalled library dependencies, so finalize right now.
890610391 exit_status=0
891310398 fi
891410399
891510400 # Delete the generated files.
8916 if test -f "$output_objdir/${outputname}S.${objext}"; then
8917 func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"'
10401 if test -f "$output_objdir/${outputname}S.$objext"; then
10402 func_show_eval '$RM "$output_objdir/${outputname}S.$objext"'
891810403 fi
891910404
892010405 exit $exit_status
8921 fi
10406 }
892210407
892310408 if test -n "$compile_shlibpath$finalize_shlibpath"; then
892410409 compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command"
894810433 fi
894910434 fi
895010435
8951 if test "$no_install" = yes; then
10436 if test yes = "$no_install"; then
895210437 # We don't need to create a wrapper script.
8953 link_command="$compile_var$compile_command$compile_rpath"
10438 link_command=$compile_var$compile_command$compile_rpath
895410439 # Replace the output file specification.
895510440 link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'`
895610441 # Delete the old output file.
896710452 exit $EXIT_SUCCESS
896810453 fi
896910454
8970 if test "$hardcode_action" = relink; then
8971 # Fast installation is not supported
8972 link_command="$compile_var$compile_command$compile_rpath"
8973 relink_command="$finalize_var$finalize_command$finalize_rpath"
8974
8975 func_warning "this platform does not like uninstalled shared libraries"
8976 func_warning "\`$output' will be relinked during installation"
8977 else
8978 if test "$fast_install" != no; then
8979 link_command="$finalize_var$compile_command$finalize_rpath"
8980 if test "$fast_install" = yes; then
8981 relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'`
8982 else
8983 # fast_install is set to needless
8984 relink_command=
8985 fi
8986 else
8987 link_command="$compile_var$compile_command$compile_rpath"
8988 relink_command="$finalize_var$finalize_command$finalize_rpath"
8989 fi
8990 fi
10455 case $hardcode_action,$fast_install in
10456 relink,*)
10457 # Fast installation is not supported
10458 link_command=$compile_var$compile_command$compile_rpath
10459 relink_command=$finalize_var$finalize_command$finalize_rpath
10460
10461 func_warning "this platform does not like uninstalled shared libraries"
10462 func_warning "'$output' will be relinked during installation"
10463 ;;
10464 *,yes)
10465 link_command=$finalize_var$compile_command$finalize_rpath
10466 relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'`
10467 ;;
10468 *,no)
10469 link_command=$compile_var$compile_command$compile_rpath
10470 relink_command=$finalize_var$finalize_command$finalize_rpath
10471 ;;
10472 *,needless)
10473 link_command=$finalize_var$compile_command$finalize_rpath
10474 relink_command=
10475 ;;
10476 esac
899110477
899210478 # Replace the output file specification.
899310479 link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'`
904410530 func_dirname_and_basename "$output" "" "."
904510531 output_name=$func_basename_result
904610532 output_path=$func_dirname_result
9047 cwrappersource="$output_path/$objdir/lt-$output_name.c"
9048 cwrapper="$output_path/$output_name.exe"
10533 cwrappersource=$output_path/$objdir/lt-$output_name.c
10534 cwrapper=$output_path/$output_name.exe
904910535 $RM $cwrappersource $cwrapper
905010536 trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15
905110537
906610552 trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15
906710553 $opt_dry_run || {
906810554 # note: this script will not be executed, so do not chmod.
9069 if test "x$build" = "x$host" ; then
10555 if test "x$build" = "x$host"; then
907010556 $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result
907110557 else
907210558 func_emit_wrapper no > $func_ltwrapper_scriptname_result
908910575 # See if we need to build an old-fashioned archive.
909010576 for oldlib in $oldlibs; do
909110577
9092 if test "$build_libtool_libs" = convenience; then
9093 oldobjs="$libobjs_save $symfileobj"
9094 addlibs="$convenience"
9095 build_libtool_libs=no
9096 else
9097 if test "$build_libtool_libs" = module; then
9098 oldobjs="$libobjs_save"
10578 case $build_libtool_libs in
10579 convenience)
10580 oldobjs="$libobjs_save $symfileobj"
10581 addlibs=$convenience
909910582 build_libtool_libs=no
9100 else
10583 ;;
10584 module)
10585 oldobjs=$libobjs_save
10586 addlibs=$old_convenience
10587 build_libtool_libs=no
10588 ;;
10589 *)
910110590 oldobjs="$old_deplibs $non_pic_objects"
9102 if test "$preload" = yes && test -f "$symfileobj"; then
9103 func_append oldobjs " $symfileobj"
9104 fi
9105 fi
9106 addlibs="$old_convenience"
9107 fi
10591 $preload && test -f "$symfileobj" \
10592 && func_append oldobjs " $symfileobj"
10593 addlibs=$old_convenience
10594 ;;
10595 esac
910810596
910910597 if test -n "$addlibs"; then
9110 gentop="$output_objdir/${outputname}x"
10598 gentop=$output_objdir/${outputname}x
911110599 func_append generated " $gentop"
911210600
911310601 func_extract_archives $gentop $addlibs
911510603 fi
911610604
911710605 # Do each command in the archive commands.
9118 if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then
10606 if test -n "$old_archive_from_new_cmds" && test yes = "$build_libtool_libs"; then
911910607 cmds=$old_archive_from_new_cmds
912010608 else
912110609
912210610 # Add any objects from preloaded convenience libraries
912310611 if test -n "$dlprefiles"; then
9124 gentop="$output_objdir/${outputname}x"
10612 gentop=$output_objdir/${outputname}x
912510613 func_append generated " $gentop"
912610614
912710615 func_extract_archives $gentop $dlprefiles
914210630 :
914310631 else
914410632 echo "copying selected object files to avoid basename conflicts..."
9145 gentop="$output_objdir/${outputname}x"
10633 gentop=$output_objdir/${outputname}x
914610634 func_append generated " $gentop"
914710635 func_mkdir_p "$gentop"
914810636 save_oldobjs=$oldobjs
915110639 for obj in $save_oldobjs
915210640 do
915310641 func_basename "$obj"
9154 objbase="$func_basename_result"
10642 objbase=$func_basename_result
915510643 case " $oldobjs " in
915610644 " ") oldobjs=$obj ;;
915710645 *[\ /]"$objbase "*)
922010708 else
922110709 # the above command should be used before it gets too long
922210710 oldobjs=$objlist
9223 if test "$obj" = "$last_oldobj" ; then
10711 if test "$obj" = "$last_oldobj"; then
922410712 RANLIB=$save_RANLIB
922510713 fi
922610714 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
9227 eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\"
10715 eval concat_cmds=\"\$concat_cmds$old_archive_cmds\"
922810716 objlist=
922910717 len=$len0
923010718 fi
923110719 done
923210720 RANLIB=$save_RANLIB
923310721 oldobjs=$objlist
9234 if test "X$oldobjs" = "X" ; then
10722 if test -z "$oldobjs"; then
923510723 eval cmds=\"\$concat_cmds\"
923610724 else
923710725 eval cmds=\"\$concat_cmds~\$old_archive_cmds\"
924810736 case $output in
924910737 *.la)
925010738 old_library=
9251 test "$build_old_libs" = yes && old_library="$libname.$libext"
10739 test yes = "$build_old_libs" && old_library=$libname.$libext
925210740 func_verbose "creating $output"
925310741
925410742 # Preserve any variables that may affect compiler behavior
926310751 fi
926410752 done
926510753 # Quote the link command for shipping.
9266 relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)"
10754 relink_command="(cd `pwd`; $SHELL \"$progpath\" $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)"
926710755 relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"`
9268 if test "$hardcode_automatic" = yes ; then
10756 if test yes = "$hardcode_automatic"; then
926910757 relink_command=
927010758 fi
927110759
927210760 # Only create the output if not a dry run.
927310761 $opt_dry_run || {
927410762 for installed in no yes; do
9275 if test "$installed" = yes; then
10763 if test yes = "$installed"; then
927610764 if test -z "$install_libdir"; then
927710765 break
927810766 fi
9279 output="$output_objdir/$outputname"i
10767 output=$output_objdir/${outputname}i
928010768 # Replace all uninstalled libtool libraries with the installed ones
928110769 newdependency_libs=
928210770 for deplib in $dependency_libs; do
928310771 case $deplib in
928410772 *.la)
928510773 func_basename "$deplib"
9286 name="$func_basename_result"
10774 name=$func_basename_result
928710775 func_resolve_sysroot "$deplib"
9288 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result`
10776 eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result`
928910777 test -z "$libdir" && \
9290 func_fatal_error "\`$deplib' is not a valid libtool archive"
10778 func_fatal_error "'$deplib' is not a valid libtool archive"
929110779 func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name"
929210780 ;;
929310781 -L*)
930310791 *) func_append newdependency_libs " $deplib" ;;
930410792 esac
930510793 done
9306 dependency_libs="$newdependency_libs"
10794 dependency_libs=$newdependency_libs
930710795 newdlfiles=
930810796
930910797 for lib in $dlfiles; do
931010798 case $lib in
931110799 *.la)
931210800 func_basename "$lib"
9313 name="$func_basename_result"
9314 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
10801 name=$func_basename_result
10802 eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
931510803 test -z "$libdir" && \
9316 func_fatal_error "\`$lib' is not a valid libtool archive"
10804 func_fatal_error "'$lib' is not a valid libtool archive"
931710805 func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name"
931810806 ;;
931910807 *) func_append newdlfiles " $lib" ;;
932010808 esac
932110809 done
9322 dlfiles="$newdlfiles"
10810 dlfiles=$newdlfiles
932310811 newdlprefiles=
932410812 for lib in $dlprefiles; do
932510813 case $lib in
932910817 # didn't already link the preopened objects directly into
933010818 # the library:
933110819 func_basename "$lib"
9332 name="$func_basename_result"
9333 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
10820 name=$func_basename_result
10821 eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
933410822 test -z "$libdir" && \
9335 func_fatal_error "\`$lib' is not a valid libtool archive"
10823 func_fatal_error "'$lib' is not a valid libtool archive"
933610824 func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name"
933710825 ;;
933810826 esac
933910827 done
9340 dlprefiles="$newdlprefiles"
10828 dlprefiles=$newdlprefiles
934110829 else
934210830 newdlfiles=
934310831 for lib in $dlfiles; do
934410832 case $lib in
9345 [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
10833 [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;;
934610834 *) abs=`pwd`"/$lib" ;;
934710835 esac
934810836 func_append newdlfiles " $abs"
934910837 done
9350 dlfiles="$newdlfiles"
10838 dlfiles=$newdlfiles
935110839 newdlprefiles=
935210840 for lib in $dlprefiles; do
935310841 case $lib in
9354 [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
10842 [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;;
935510843 *) abs=`pwd`"/$lib" ;;
935610844 esac
935710845 func_append newdlprefiles " $abs"
935810846 done
9359 dlprefiles="$newdlprefiles"
10847 dlprefiles=$newdlprefiles
936010848 fi
936110849 $RM $output
936210850 # place dlname in correct position for cygwin
937210860 case $host,$output,$installed,$module,$dlname in
937310861 *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll)
937410862 # If a -bindir argument was supplied, place the dll there.
9375 if test "x$bindir" != x ;
9376 then
10863 if test -n "$bindir"; then
937710864 func_relative_path "$install_libdir" "$bindir"
9378 tdlname=$func_relative_path_result$dlname
10865 tdlname=$func_relative_path_result/$dlname
937910866 else
938010867 # Otherwise fall back on heuristic.
938110868 tdlname=../bin/$dlname
938410871 esac
938510872 $ECHO > $output "\
938610873 # $outputname - a libtool library file
9387 # Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
10874 # Generated by $PROGRAM (GNU $PACKAGE) $VERSION
938810875 #
938910876 # Please DO NOT delete this file!
939010877 # It is necessary for linking the library.
939810885 # The name of the static archive.
939910886 old_library='$old_library'
940010887
9401 # Linker flags that can not go in dependency_libs.
10888 # Linker flags that cannot go in dependency_libs.
940210889 inherited_linker_flags='$new_inherited_linker_flags'
940310890
940410891 # Libraries that this one depends upon.
942410911
942510912 # Directory that this library needs to be installed in:
942610913 libdir='$install_libdir'"
9427 if test "$installed" = no && test "$need_relink" = yes; then
10914 if test no,yes = "$installed,$need_relink"; then
942810915 $ECHO >> $output "\
942910916 relink_command=\"$relink_command\""
943010917 fi
943910926 exit $EXIT_SUCCESS
944010927 }
944110928
9442 { test "$opt_mode" = link || test "$opt_mode" = relink; } &&
9443 func_mode_link ${1+"$@"}
10929 if test link = "$opt_mode" || test relink = "$opt_mode"; then
10930 func_mode_link ${1+"$@"}
10931 fi
944410932
944510933
944610934 # func_mode_uninstall arg...
944710935 func_mode_uninstall ()
944810936 {
9449 $opt_debug
9450 RM="$nonopt"
10937 $debug_cmd
10938
10939 RM=$nonopt
945110940 files=
9452 rmforce=
10941 rmforce=false
945310942 exit_status=0
945410943
945510944 # This variable tells wrapper scripts just to set variables rather
945610945 # than running their programs.
9457 libtool_install_magic="$magic"
10946 libtool_install_magic=$magic
945810947
945910948 for arg
946010949 do
946110950 case $arg in
9462 -f) func_append RM " $arg"; rmforce=yes ;;
10951 -f) func_append RM " $arg"; rmforce=: ;;
946310952 -*) func_append RM " $arg" ;;
946410953 *) func_append files " $arg" ;;
946510954 esac
947210961
947310962 for file in $files; do
947410963 func_dirname "$file" "" "."
9475 dir="$func_dirname_result"
9476 if test "X$dir" = X.; then
9477 odir="$objdir"
10964 dir=$func_dirname_result
10965 if test . = "$dir"; then
10966 odir=$objdir
947810967 else
9479 odir="$dir/$objdir"
10968 odir=$dir/$objdir
948010969 fi
948110970 func_basename "$file"
9482 name="$func_basename_result"
9483 test "$opt_mode" = uninstall && odir="$dir"
10971 name=$func_basename_result
10972 test uninstall = "$opt_mode" && odir=$dir
948410973
948510974 # Remember odir for removal later, being careful to avoid duplicates
9486 if test "$opt_mode" = clean; then
10975 if test clean = "$opt_mode"; then
948710976 case " $rmdirs " in
948810977 *" $odir "*) ;;
948910978 *) func_append rmdirs " $odir" ;;
949810987 elif test -d "$file"; then
949910988 exit_status=1
950010989 continue
9501 elif test "$rmforce" = yes; then
10990 elif $rmforce; then
950210991 continue
950310992 fi
950410993
9505 rmfiles="$file"
10994 rmfiles=$file
950610995
950710996 case $name in
950810997 *.la)
951611005 done
951711006 test -n "$old_library" && func_append rmfiles " $odir/$old_library"
951811007
9519 case "$opt_mode" in
11008 case $opt_mode in
952011009 clean)
952111010 case " $library_names " in
952211011 *" $dlname "*) ;;
952711016 uninstall)
952811017 if test -n "$library_names"; then
952911018 # Do each command in the postuninstall commands.
9530 func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1'
11019 func_execute_cmds "$postuninstall_cmds" '$rmforce || exit_status=1'
953111020 fi
953211021
953311022 if test -n "$old_library"; then
953411023 # Do each command in the old_postuninstall commands.
9535 func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1'
11024 func_execute_cmds "$old_postuninstall_cmds" '$rmforce || exit_status=1'
953611025 fi
953711026 # FIXME: should reinstall the best remaining shared library.
953811027 ;;
954811037 func_source $dir/$name
954911038
955011039 # Add PIC object to the list of files to remove.
9551 if test -n "$pic_object" &&
9552 test "$pic_object" != none; then
11040 if test -n "$pic_object" && test none != "$pic_object"; then
955311041 func_append rmfiles " $dir/$pic_object"
955411042 fi
955511043
955611044 # Add non-PIC object to the list of files to remove.
9557 if test -n "$non_pic_object" &&
9558 test "$non_pic_object" != none; then
11045 if test -n "$non_pic_object" && test none != "$non_pic_object"; then
955911046 func_append rmfiles " $dir/$non_pic_object"
956011047 fi
956111048 fi
956211049 ;;
956311050
956411051 *)
9565 if test "$opt_mode" = clean ; then
11052 if test clean = "$opt_mode"; then
956611053 noexename=$name
956711054 case $file in
956811055 *.exe)
958911076
959011077 # note $name still contains .exe if it was in $file originally
959111078 # as does the version of $file that was added into $rmfiles
9592 func_append rmfiles " $odir/$name $odir/${name}S.${objext}"
9593 if test "$fast_install" = yes && test -n "$relink_command"; then
11079 func_append rmfiles " $odir/$name $odir/${name}S.$objext"
11080 if test yes = "$fast_install" && test -n "$relink_command"; then
959411081 func_append rmfiles " $odir/lt-$name"
959511082 fi
9596 if test "X$noexename" != "X$name" ; then
9597 func_append rmfiles " $odir/lt-${noexename}.c"
11083 if test "X$noexename" != "X$name"; then
11084 func_append rmfiles " $odir/lt-$noexename.c"
959811085 fi
959911086 fi
960011087 fi
960311090 func_show_eval "$RM $rmfiles" 'exit_status=1'
960411091 done
960511092
9606 # Try to remove the ${objdir}s in the directories where we deleted files
11093 # Try to remove the $objdir's in the directories where we deleted files
960711094 for dir in $rmdirs; do
960811095 if test -d "$dir"; then
960911096 func_show_eval "rmdir $dir >/dev/null 2>&1"
961311100 exit $exit_status
961411101 }
961511102
9616 { test "$opt_mode" = uninstall || test "$opt_mode" = clean; } &&
9617 func_mode_uninstall ${1+"$@"}
11103 if test uninstall = "$opt_mode" || test clean = "$opt_mode"; then
11104 func_mode_uninstall ${1+"$@"}
11105 fi
961811106
961911107 test -z "$opt_mode" && {
9620 help="$generic_help"
11108 help=$generic_help
962111109 func_fatal_help "you must specify a MODE"
962211110 }
962311111
962411112 test -z "$exec_cmd" && \
9625 func_fatal_help "invalid operation mode \`$opt_mode'"
11113 func_fatal_help "invalid operation mode '$opt_mode'"
962611114
962711115 if test -n "$exec_cmd"; then
962811116 eval exec "$exec_cmd"
963311121
963411122
963511123 # The TAGs below are defined such that we never get into a situation
9636 # in which we disable both kinds of libraries. Given conflicting
11124 # where we disable both kinds of libraries. Given conflicting
963711125 # choices, we go for a static library, that is the most portable,
963811126 # since we can't tell whether shared libraries were disabled because
963911127 # the user asked for that or because the platform doesn't support
965611144 # mode:shell-script
965711145 # sh-indentation:2
965811146 # End:
9659 # vi:sw=2
9660
174174 print_warning(*HEADER);
175175 print_startprotect(*HEADER, $file);
176176
177 # Begin extern C block
178 print HEADER "\n";
179 print HEADER "#ifdef __cplusplus\n";
180 print HEADER "extern \"C\" {\n";
181 print HEADER "#endif\n";
182
177183 # Iterate over all the major errors
178184 print HEADER "\n/*********************/\n";
179185 print HEADER "/* Major error codes */\n";
200206 printf HEADER "H5_DLLVAR hid_t %-20s /* %s */\n","${name}_g;",$minor{$name};
201207 }
202208 }
209
210 # End extern C block
211 print HEADER "\n";
212 print HEADER "#ifdef __cplusplus\n";
213 print HEADER "}\n";
214 print HEADER "#endif\n";
203215
204216 print_endprotect(*HEADER, $file);
205217
513513 LN_S = @LN_S@
514514 LTLIBOBJS = @LTLIBOBJS@
515515 LT_STATIC_EXEC = @LT_STATIC_EXEC@
516 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
516517 MAINT = @MAINT@
517518 MAKEINFO = @MAKEINFO@
518519 MANIFEST_TOOL = @MANIFEST_TOOL@
461461 LN_S = @LN_S@
462462 LTLIBOBJS = @LTLIBOBJS@
463463 LT_STATIC_EXEC = @LT_STATIC_EXEC@
464 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
464465 MAINT = @MAINT@
465466 MAKEINFO = @MAKEINFO@
466467 MANIFEST_TOOL = @MANIFEST_TOOL@
526526 LN_S = @LN_S@
527527 LTLIBOBJS = @LTLIBOBJS@
528528 LT_STATIC_EXEC = @LT_STATIC_EXEC@
529 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
529530 MAINT = @MAINT@
530531 MAKEINFO = @MAKEINFO@
531532 MANIFEST_TOOL = @MANIFEST_TOOL@
702703 # After making changes, run bin/reconfigure to update other configure related
703704 # files like Makefile.in.
704705 LT_VERS_INTERFACE = 100
705 LT_VERS_REVISION = 900
706 LT_VERS_REVISION = 0
706707 LT_VERS_AGE = 0
707708
708709 # This is our main target
3737 # could be handy for archiving the generated documentation or if some version
3838 # control system is used.
3939
40 PROJECT_NUMBER = "1.10.0-alpha0 currently under development"
40 PROJECT_NUMBER = "1.10.0-alpha1 currently under development"
4141
4242 # Using the PROJECT_BRIEF tag one can provide an optional one line description
4343 # for a project that appears at the top of each page and should give viewer a
515515 LN_S = @LN_S@
516516 LTLIBOBJS = @LTLIBOBJS@
517517 LT_STATIC_EXEC = @LT_STATIC_EXEC@
518 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
518519 MAINT = @MAINT@
519520 MAKEINFO = @MAKEINFO@
520521 MANIFEST_TOOL = @MANIFEST_TOOL@
3535
3636 set (HDF5_ENABLE_USING_MEMCHECKER OFF CACHE BOOL "Indicate that a memory checker is used" FORCE)
3737
38 set (HDF5_MEMORY_ALLOC_SANITY_CHECK OFF CACHE BOOL "Indicate that internal memory allocation sanity checks are enabled" FORCE)
39
3840 set (HDF5_DISABLE_COMPILER_WARNINGS OFF CACHE BOOL "Disable compiler warnings" FORCE)
3941
4042 set (HDF5_USE_FOLDERS ON CACHE BOOL "Enable folder grouping of projects in IDEs." FORCE)
6464 dmalloc: @H5_HAVE_LIBDMALLOC@
6565 Clear file buffers before write: @HDF5_Enable_Clear_File_Buffers@
6666 Using memory checker: @HDF5_ENABLE_USING_MEMCHECKER@
67 Memory allocation sanity checks: @HDF5_MEMORY_ALLOC_SANITY_CHECK@
6768 Function Stack Tracing: @HDF5_ENABLE_CODESTACK@
6869 Strict File Format Checks: @HDF5_STRICT_FORMAT_CHECKS@
6970 Optimization Instrumentation: @HDF5_Enable_Instrument@
4747
4848 set (HDF5_ENABLE_USING_MEMCHECKER ON CACHE BOOL "Indicate that a memory checker is used" FORCE)
4949
50 set (HDF5_MEMORY_ALLOC_SANITY_CHECK OFF CACHE BOOL "Indicate that internal memory allocation sanity checks are enabled" FORCE)
51
5052 set (HDF5_DISABLE_COMPILER_WARNINGS OFF CACHE BOOL "Disable compiler warnings" FORCE)
5153
5254 set (HDF5_USE_FOLDERS ON CACHE BOOL "Enable folder grouping of projects in IDEs." FORCE)
1818 # After making changes, run bin/reconfigure to update other configure related
1919 # files like Makefile.in.
2020 LT_VERS_INTERFACE = 100
21 LT_VERS_REVISION = 900
21 LT_VERS_REVISION = 0
2222 LT_VERS_AGE = 0
2323
2424 ## If the API changes *at all*, increment LT_VERS_INTERFACE and
+2686
-2005
configure less more
00 #! /bin/sh
11 # From configure.ac Id: configure.ac 22697 2012-08-19 14:35:47Z hdftest .
22 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69 for HDF5 1.10.0-alpha0.
3 # Generated by GNU Autoconf 2.69 for HDF5 1.10.0-alpha1.
44 #
55 # Report bugs to <help@hdfgroup.org>.
66 #
590590 # Identity of this package.
591591 PACKAGE_NAME='HDF5'
592592 PACKAGE_TARNAME='hdf5'
593 PACKAGE_VERSION='1.10.0-alpha0'
594 PACKAGE_STRING='HDF5 1.10.0-alpha0'
593 PACKAGE_VERSION='1.10.0-alpha1'
594 PACKAGE_STRING='HDF5 1.10.0-alpha1'
595595 PACKAGE_BUGREPORT='help@hdfgroup.org'
596596 PACKAGE_URL=''
597597
680680 LT_STATIC_EXEC
681681 USE_PLUGINS_CONDITIONAL_FALSE
682682 USE_PLUGINS_CONDITIONAL_TRUE
683 LT_SYS_LIBRARY_PATH
683684 OTOOL64
684685 OTOOL
685686 LIPO
892893 enable_static
893894 with_pic
894895 enable_fast_install
896 with_aix_soname
895897 with_gnu_ld
896898 with_sysroot
897899 enable_libtool_lock
937939 CXX
938940 CXXFLAGS
939941 CCC
940 CXXCPP'
942 CXXCPP
943 LT_SYS_LIBRARY_PATH'
941944
942945
943946 # Initialize some variables set by options.
14781481 # Omit some internal or obsolete options to make the list less imposing.
14791482 # This message is too long to be a string in the A/UX 3.1 sh.
14801483 cat <<_ACEOF
1481 \`configure' configures HDF5 1.10.0-alpha0 to adapt to many kinds of systems.
1484 \`configure' configures HDF5 1.10.0-alpha1 to adapt to many kinds of systems.
14821485
14831486 Usage: $0 [OPTION]... [VAR=VALUE]...
14841487
15481551
15491552 if test -n "$ac_init_help"; then
15501553 case $ac_init_help in
1551 short | recursive ) echo "Configuration of HDF5 1.10.0-alpha0:";;
1554 short | recursive ) echo "Configuration of HDF5 1.10.0-alpha1:";;
15521555 esac
15531556 cat <<\_ACEOF
15541557
16031606 bounds checking tool will be used on the HDF5
16041607 library. Enabling this causes the library to be more
16051608 picky about it's memory operations and also disables
1606 the library's free space manager code. Default=no.
1609 the library's free space manager code. This option
1610 is orthogonal to the
1611 --enable-memory-alloc-sanity-check option.
1612 Default=no.
16071613 --enable-parallel Search for MPI-IO and MPI support files
16081614 --enable-direct-vfd Build the direct I/O virtual file driver (VFD). This
16091615 is based on the POSIX (sec2) VFD and requires the
16281634 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
16291635 --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use
16301636 both]
1637 --with-aix-soname=aix|svr4|both
1638 shared library versioning (aka "SONAME") variant to
1639 provide on AIX, [default=aix].
16311640 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1632 --with-sysroot=DIR Search for dependent libraries within DIR
1633 (or the compiler's sysroot if not specified).
1641 --with-sysroot[=DIR] Search for dependent libraries within DIR (or the
1642 compiler's sysroot if not specified).
16341643
16351644 For the following --with-xxx options, you can specify where the header
16361645 files and libraries are in two different ways:
16691678 CXX C++ compiler command
16701679 CXXFLAGS C++ compiler flags
16711680 CXXCPP C++ preprocessor
1681 LT_SYS_LIBRARY_PATH
1682 User-defined run-time library search path.
16721683
16731684 Use these variables to override the choices made by `configure' or to help
16741685 it to find libraries and programs with nonstandard names/locations.
17361747 test -n "$ac_init_help" && exit $ac_status
17371748 if $ac_init_version; then
17381749 cat <<\_ACEOF
1739 HDF5 configure 1.10.0-alpha0
1750 HDF5 configure 1.10.0-alpha1
17401751 generated by GNU Autoconf 2.69
17411752
17421753 Copyright (C) 2012 Free Software Foundation, Inc.
26512662 This file contains any messages produced by compilers while
26522663 running configure, to aid debugging if configure makes a mistake.
26532664
2654 It was created by HDF5 $as_me 1.10.0-alpha0, which was
2665 It was created by HDF5 $as_me 1.10.0-alpha1, which was
26552666 generated by GNU Autoconf 2.69. Invocation command line was
26562667
26572668 $ $0 $@
35233534
35243535 # Define the identity of the package.
35253536 PACKAGE='hdf5'
3526 VERSION='1.10.0-alpha0'
3537 VERSION='1.10.0-alpha1'
35273538
35283539
35293540 cat >>confdefs.h <<_ACEOF
94959506
94969507
94979508
9498 macro_version='2.4.2'
9499 macro_revision='1.3337'
9500
9501
9502
9503
9504
9505
9506
9507
9508
9509
9510
9511
9512
9513 ltmain="$ac_aux_dir/ltmain.sh"
9509 macro_version='2.4.6'
9510 macro_revision='2.4.6'
9511
9512
9513
9514
9515
9516
9517
9518
9519
9520
9521
9522
9523
9524 ltmain=$ac_aux_dir/ltmain.sh
95149525
95159526 # Backslashify metacharacters that are still active within
95169527 # double-quoted strings.
95599570 $ECHO ""
95609571 }
95619572
9562 case "$ECHO" in
9573 case $ECHO in
95639574 printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
95649575 $as_echo "printf" >&6; } ;;
95659576 print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
97529763
97539764 # Check whether --with-gnu-ld was given.
97549765 if test "${with_gnu_ld+set}" = set; then :
9755 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
9766 withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
97569767 else
97579768 with_gnu_ld=no
97589769 fi
97599770
97609771 ac_prog=ld
9761 if test "$GCC" = yes; then
9772 if test yes = "$GCC"; then
97629773 # Check if gcc -print-prog-name=ld gives a path.
97639774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
97649775 $as_echo_n "checking for ld used by $CC... " >&6; }
97659776 case $host in
97669777 *-*-mingw*)
9767 # gcc leaves a trailing carriage return which upsets mingw
9778 # gcc leaves a trailing carriage return, which upsets mingw
97689779 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
97699780 *)
97709781 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
97789789 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
97799790 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
97809791 done
9781 test -z "$LD" && LD="$ac_prog"
9792 test -z "$LD" && LD=$ac_prog
97829793 ;;
97839794 "")
97849795 # If it fails, then pretend we aren't using GCC.
97899800 with_gnu_ld=unknown
97909801 ;;
97919802 esac
9792 elif test "$with_gnu_ld" = yes; then
9803 elif test yes = "$with_gnu_ld"; then
97939804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
97949805 $as_echo_n "checking for GNU ld... " >&6; }
97959806 else
98009811 $as_echo_n "(cached) " >&6
98019812 else
98029813 if test -z "$LD"; then
9803 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
9814 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
98049815 for ac_dir in $PATH; do
9805 IFS="$lt_save_ifs"
9816 IFS=$lt_save_ifs
98069817 test -z "$ac_dir" && ac_dir=.
98079818 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
9808 lt_cv_path_LD="$ac_dir/$ac_prog"
9819 lt_cv_path_LD=$ac_dir/$ac_prog
98099820 # Check to see if the program is GNU ld. I'd rather use --version,
98109821 # but apparently some variants of GNU ld only accept -v.
98119822 # Break only if it was the GNU/non-GNU ld that we prefer.
98129823 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
98139824 *GNU* | *'with BFD'*)
9814 test "$with_gnu_ld" != no && break
9825 test no != "$with_gnu_ld" && break
98159826 ;;
98169827 *)
9817 test "$with_gnu_ld" != yes && break
9828 test yes != "$with_gnu_ld" && break
98189829 ;;
98199830 esac
98209831 fi
98219832 done
9822 IFS="$lt_save_ifs"
9823 else
9824 lt_cv_path_LD="$LD" # Let the user override the test with a path.
9825 fi
9826 fi
9827
9828 LD="$lt_cv_path_LD"
9833 IFS=$lt_save_ifs
9834 else
9835 lt_cv_path_LD=$LD # Let the user override the test with a path.
9836 fi
9837 fi
9838
9839 LD=$lt_cv_path_LD
98299840 if test -n "$LD"; then
98309841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
98319842 $as_echo "$LD" >&6; }
98689879 else
98699880 if test -n "$NM"; then
98709881 # Let the user override the test.
9871 lt_cv_path_NM="$NM"
9872 else
9873 lt_nm_to_check="${ac_tool_prefix}nm"
9882 lt_cv_path_NM=$NM
9883 else
9884 lt_nm_to_check=${ac_tool_prefix}nm
98749885 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
98759886 lt_nm_to_check="$lt_nm_to_check nm"
98769887 fi
98779888 for lt_tmp_nm in $lt_nm_to_check; do
9878 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
9889 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
98799890 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
9880 IFS="$lt_save_ifs"
9891 IFS=$lt_save_ifs
98819892 test -z "$ac_dir" && ac_dir=.
9882 tmp_nm="$ac_dir/$lt_tmp_nm"
9883 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
9893 tmp_nm=$ac_dir/$lt_tmp_nm
9894 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
98849895 # Check to see if the nm accepts a BSD-compat flag.
9885 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
9896 # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
98869897 # nm: unknown option "B" ignored
98879898 # Tru64's nm complains that /dev/null is an invalid object file
9888 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
9889 */dev/null* | *'Invalid file or object type'*)
9899 # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
9900 case $build_os in
9901 mingw*) lt_bad_file=conftest.nm/nofile ;;
9902 *) lt_bad_file=/dev/null ;;
9903 esac
9904 case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
9905 *$lt_bad_file* | *'Invalid file or object type'*)
98909906 lt_cv_path_NM="$tmp_nm -B"
9891 break
9907 break 2
98929908 ;;
98939909 *)
98949910 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
98959911 */dev/null*)
98969912 lt_cv_path_NM="$tmp_nm -p"
9897 break
9913 break 2
98989914 ;;
98999915 *)
99009916 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
99059921 esac
99069922 fi
99079923 done
9908 IFS="$lt_save_ifs"
9924 IFS=$lt_save_ifs
99099925 done
99109926 : ${lt_cv_path_NM=no}
99119927 fi
99129928 fi
99139929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
99149930 $as_echo "$lt_cv_path_NM" >&6; }
9915 if test "$lt_cv_path_NM" != "no"; then
9916 NM="$lt_cv_path_NM"
9931 if test no != "$lt_cv_path_NM"; then
9932 NM=$lt_cv_path_NM
99179933 else
99189934 # Didn't find any BSD compatible name lister, look for dumpbin.
99199935 if test -n "$DUMPBIN"; then :
1001910035 fi
1002010036 fi
1002110037
10022 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
10038 case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
1002310039 *COFF*)
10024 DUMPBIN="$DUMPBIN -symbols"
10040 DUMPBIN="$DUMPBIN -symbols -headers"
1002510041 ;;
1002610042 *)
1002710043 DUMPBIN=:
1002910045 esac
1003010046 fi
1003110047
10032 if test "$DUMPBIN" != ":"; then
10033 NM="$DUMPBIN"
10048 if test : != "$DUMPBIN"; then
10049 NM=$DUMPBIN
1003410050 fi
1003510051 fi
1003610052 test -z "$NM" && NM=nm
1008110097 $as_echo_n "(cached) " >&6
1008210098 else
1008310099 i=0
10084 teststring="ABCD"
10100 teststring=ABCD
1008510101
1008610102 case $build_os in
1008710103 msdosdjgpp*)
1012110137 lt_cv_sys_max_cmd_len=8192;
1012210138 ;;
1012310139
10124 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
10140 bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
1012510141 # This has been around since 386BSD, at least. Likely further.
1012610142 if test -x /sbin/sysctl; then
1012710143 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
1017210188 *)
1017310189 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
1017410190 if test -n "$lt_cv_sys_max_cmd_len" && \
10175 test undefined != "$lt_cv_sys_max_cmd_len"; then
10191 test undefined != "$lt_cv_sys_max_cmd_len"; then
1017610192 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
1017710193 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
1017810194 else
1017910195 # Make teststring a little bigger before we do anything with it.
1018010196 # a 1K string should be a reasonable start.
10181 for i in 1 2 3 4 5 6 7 8 ; do
10197 for i in 1 2 3 4 5 6 7 8; do
1018210198 teststring=$teststring$teststring
1018310199 done
1018410200 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
1018510201 # If test is not a shell built-in, we'll probably end up computing a
1018610202 # maximum length that is only half of the actual maximum length, but
1018710203 # we can't tell.
10188 while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
10204 while { test X`env echo "$teststring$teststring" 2>/dev/null` \
1018910205 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
10190 test $i != 17 # 1/2 MB should be enough
10206 test 17 != "$i" # 1/2 MB should be enough
1019110207 do
1019210208 i=`expr $i + 1`
1019310209 teststring=$teststring$teststring
1020510221
1020610222 fi
1020710223
10208 if test -n $lt_cv_sys_max_cmd_len ; then
10224 if test -n "$lt_cv_sys_max_cmd_len"; then
1020910225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
1021010226 $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
1021110227 else
1022210238 : ${CP="cp -f"}
1022310239 : ${MV="mv -f"}
1022410240 : ${RM="rm -f"}
10225
10226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
10227 $as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
10228 # Try some XSI features
10229 xsi_shell=no
10230 ( _lt_dummy="a/b/c"
10231 test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
10232 = c,a/b,b/c, \
10233 && eval 'test $(( 1 + 1 )) -eq 2 \
10234 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
10235 && xsi_shell=yes
10236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
10237 $as_echo "$xsi_shell" >&6; }
10238
10239
10240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
10241 $as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
10242 lt_shell_append=no
10243 ( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
10244 >/dev/null 2>&1 \
10245 && lt_shell_append=yes
10246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
10247 $as_echo "$lt_shell_append" >&6; }
10248
1024910241
1025010242 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
1025110243 lt_unset=unset
1036910361 reload_cmds='$LD$reload_flag -o $output$reload_objs'
1037010362 case $host_os in
1037110363 cygwin* | mingw* | pw32* | cegcc*)
10372 if test "$GCC" != yes; then
10364 if test yes != "$GCC"; then
1037310365 reload_cmds=false
1037410366 fi
1037510367 ;;
1037610368 darwin*)
10377 if test "$GCC" = yes; then
10378 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
10369 if test yes = "$GCC"; then
10370 reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
1037910371 else
1038010372 reload_cmds='$LD$reload_flag -o $output$reload_objs'
1038110373 fi
1050310495 # Need to set the preceding variable on all platforms that support
1050410496 # interlibrary dependencies.
1050510497 # 'none' -- dependencies not supported.
10506 # `unknown' -- same as none, but documents that we really don't know.
10498 # 'unknown' -- same as none, but documents that we really don't know.
1050710499 # 'pass_all' -- all dependencies passed with no checks.
1050810500 # 'test_compile' -- check by making test program.
1050910501 # 'file_magic [[regex]]' -- check by looking for files in library path
10510 # which responds to the $file_magic_cmd with a given extended regex.
10511 # If you have `file' or equivalent on your system and you're not sure
10512 # whether `pass_all' will *always* work, you probably want this one.
10502 # that responds to the $file_magic_cmd with a given extended regex.
10503 # If you have 'file' or equivalent on your system and you're not sure
10504 # whether 'pass_all' will *always* work, you probably want this one.
1051310505
1051410506 case $host_os in
1051510507 aix[4-9]*)
1053610528 # Base MSYS/MinGW do not provide the 'file' command needed by
1053710529 # func_win32_libid shell function, so use a weaker test based on 'objdump',
1053810530 # unless we find 'file', for example because we are cross-compiling.
10539 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
10540 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
10531 if ( file / ) >/dev/null 2>&1; then
1054110532 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
1054210533 lt_cv_file_magic_cmd='func_win32_libid'
1054310534 else
1061510606 lt_cv_deplibs_check_method=pass_all
1061610607 ;;
1061710608
10618 netbsd* | netbsdelf*-gnu)
10609 netbsd*)
1061910610 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
1062010611 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
1062110612 else
1063310624 lt_cv_deplibs_check_method=pass_all
1063410625 ;;
1063510626
10636 openbsd*)
10637 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
10627 openbsd* | bitrig*)
10628 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
1063810629 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
1063910630 else
1064010631 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
1068710678 tpf*)
1068810679 lt_cv_deplibs_check_method=pass_all
1068910680 ;;
10681 os2*)
10682 lt_cv_deplibs_check_method=pass_all
10683 ;;
1069010684 esac
1069110685
1069210686 fi
1084410838
1084510839 case $host_os in
1084610840 cygwin* | mingw* | pw32* | cegcc*)
10847 # two different shell functions defined in ltmain.sh
10848 # decide which to use based on capabilities of $DLLTOOL
10841 # two different shell functions defined in ltmain.sh;
10842 # decide which one to use based on capabilities of $DLLTOOL
1084910843 case `$DLLTOOL --help 2>&1` in
1085010844 *--identify-strict*)
1085110845 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
1085710851 ;;
1085810852 *)
1085910853 # fallback: assume linklib IS sharedlib
10860 lt_cv_sharedlib_from_linklib_cmd="$ECHO"
10854 lt_cv_sharedlib_from_linklib_cmd=$ECHO
1086110855 ;;
1086210856 esac
1086310857
1101911013 ac_status=$?
1102011014 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1102111015 test $ac_status = 0; }
11022 if test "$ac_status" -eq 0; then
11016 if test 0 -eq "$ac_status"; then
1102311017 # Ensure the archiver fails upon bogus file names.
1102411018 rm -f conftest.$ac_objext libconftest.a
1102511019 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
1102711021 ac_status=$?
1102811022 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1102911023 test $ac_status = 0; }
11030 if test "$ac_status" -ne 0; then
11024 if test 0 -ne "$ac_status"; then
1103111025 lt_cv_ar_at_file=@
1103211026 fi
1103311027 fi
1104011034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
1104111035 $as_echo "$lt_cv_ar_at_file" >&6; }
1104211036
11043 if test "x$lt_cv_ar_at_file" = xno; then
11037 if test no = "$lt_cv_ar_at_file"; then
1104411038 archiver_list_spec=
1104511039 else
1104611040 archiver_list_spec=$lt_cv_ar_at_file
1125711251
1125811252 if test -n "$RANLIB"; then
1125911253 case $host_os in
11260 openbsd*)
11254 bitrig* | openbsd*)
1126111255 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
1126211256 ;;
1126311257 *)
1134711341 symcode='[ABCDGISTW]'
1134811342 ;;
1134911343 hpux*)
11350 if test "$host_cpu" = ia64; then
11344 if test ia64 = "$host_cpu"; then
1135111345 symcode='[ABCDEGRST]'
1135211346 fi
1135311347 ;;
1138011374 symcode='[ABCDGIRSTW]' ;;
1138111375 esac
1138211376
11377 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
11378 # Gets list of data symbols to import.
11379 lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
11380 # Adjust the below global symbol transforms to fixup imported variables.
11381 lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
11382 lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'"
11383 lt_c_name_lib_hook="\
11384 -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\
11385 -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'"
11386 else
11387 # Disable hooks by default.
11388 lt_cv_sys_global_symbol_to_import=
11389 lt_cdecl_hook=
11390 lt_c_name_hook=
11391 lt_c_name_lib_hook=
11392 fi
11393
1138311394 # Transform an extracted symbol line into a proper C declaration.
1138411395 # Some systems (esp. on ia64) link data and code symbols differently,
1138511396 # so use this general approach.
11386 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
11397 lt_cv_sys_global_symbol_to_cdecl="sed -n"\
11398 $lt_cdecl_hook\
11399 " -e 's/^T .* \(.*\)$/extern int \1();/p'"\
11400 " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
1138711401
1138811402 # Transform an extracted symbol line into symbol name and symbol address
11389 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
11390 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
11403 lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
11404 $lt_c_name_hook\
11405 " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
11406 " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'"
11407
11408 # Transform an extracted symbol line into symbol name with lib prefix and
11409 # symbol address.
11410 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
11411 $lt_c_name_lib_hook\
11412 " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
11413 " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\
11414 " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'"
1139111415
1139211416 # Handle CRLF in mingw tool chain
1139311417 opt_cr=
1140511429
1140611430 # Write the raw and C identifiers.
1140711431 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
11408 # Fake it for dumpbin and say T for any non-static function
11409 # and D for any global variable.
11432 # Fake it for dumpbin and say T for any non-static function,
11433 # D for any global variable and I for any imported variable.
1141011434 # Also find C++ and __fastcall symbols from MSVC++,
1141111435 # which start with @ or ?.
1141211436 lt_cv_sys_global_symbol_pipe="$AWK '"\
1141311437 " {last_section=section; section=\$ 3};"\
1141411438 " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
1141511439 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
11440 " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
11441 " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
11442 " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
1141611443 " \$ 0!~/External *\|/{next};"\
1141711444 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
1141811445 " {if(hide[section]) next};"\
11419 " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
11420 " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
11421 " s[1]~/^[@?]/{print s[1], s[1]; next};"\
11422 " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
11446 " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
11447 " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
11448 " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
11449 " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
1142311450 " ' prfx=^$ac_symprfx"
1142411451 else
1142511452 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
1146711494 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
1146811495 cat <<_LT_EOF > conftest.$ac_ext
1146911496 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
11470 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
11471 /* DATA imports from DLLs on WIN32 con't be const, because runtime
11497 #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
11498 /* DATA imports from DLLs on WIN32 can't be const, because runtime
1147211499 relocations are performed -- see ld's documentation on pseudo-relocs. */
1147311500 # define LT_DLSYM_CONST
11474 #elif defined(__osf__)
11501 #elif defined __osf__
1147511502 /* This system does not cope well with relocations in const data. */
1147611503 # define LT_DLSYM_CONST
1147711504 #else
1149711524 {
1149811525 { "@PROGRAM@", (void *) 0 },
1149911526 _LT_EOF
11500 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
11527 $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
1150111528 cat <<\_LT_EOF >> conftest.$ac_ext
1150211529 {0, (void *) 0}
1150311530 };
1151711544 mv conftest.$ac_objext conftstm.$ac_objext
1151811545 lt_globsym_save_LIBS=$LIBS
1151911546 lt_globsym_save_CFLAGS=$CFLAGS
11520 LIBS="conftstm.$ac_objext"
11547 LIBS=conftstm.$ac_objext
1152111548 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
1152211549 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
1152311550 (eval $ac_link) 2>&5
1152411551 ac_status=$?
1152511552 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11526 test $ac_status = 0; } && test -s conftest${ac_exeext}; then
11553 test $ac_status = 0; } && test -s conftest$ac_exeext; then
1152711554 pipe_works=yes
1152811555 fi
1152911556 LIBS=$lt_globsym_save_LIBS
1154411571 rm -rf conftest* conftst*
1154511572
1154611573 # Do not use the global_symbol_pipe unless it works.
11547 if test "$pipe_works" = yes; then
11574 if test yes = "$pipe_works"; then
1154811575 break
1154911576 else
1155011577 lt_cv_sys_global_symbol_pipe=
1159711624
1159811625
1159911626
11627
11628
11629
11630
11631
11632
11633
11634
11635
11636
1160011637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
1160111638 $as_echo_n "checking for sysroot... " >&6; }
1160211639
1160911646
1161011647
1161111648 lt_sysroot=
11612 case ${with_sysroot} in #(
11649 case $with_sysroot in #(
1161311650 yes)
11614 if test "$GCC" = yes; then
11651 if test yes = "$GCC"; then
1161511652 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
1161611653 fi
1161711654 ;; #(
1162111658 no|'')
1162211659 ;; #(
1162311660 *)
11624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5
11625 $as_echo "${with_sysroot}" >&6; }
11661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
11662 $as_echo "$with_sysroot" >&6; }
1162611663 as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
1162711664 ;;
1162811665 esac
1163411671
1163511672
1163611673
11674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
11675 $as_echo_n "checking for a working dd... " >&6; }
11676 if ${ac_cv_path_lt_DD+:} false; then :
11677 $as_echo_n "(cached) " >&6
11678 else
11679 printf 0123456789abcdef0123456789abcdef >conftest.i
11680 cat conftest.i conftest.i >conftest2.i
11681 : ${lt_DD:=$DD}
11682 if test -z "$lt_DD"; then
11683 ac_path_lt_DD_found=false
11684 # Loop through the user's path and test for each of PROGNAME-LIST
11685 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11686 for as_dir in $PATH
11687 do
11688 IFS=$as_save_IFS
11689 test -z "$as_dir" && as_dir=.
11690 for ac_prog in dd; do
11691 for ac_exec_ext in '' $ac_executable_extensions; do
11692 ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext"
11693 as_fn_executable_p "$ac_path_lt_DD" || continue
11694 if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
11695 cmp -s conftest.i conftest.out \
11696 && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
11697 fi
11698 $ac_path_lt_DD_found && break 3
11699 done
11700 done
11701 done
11702 IFS=$as_save_IFS
11703 if test -z "$ac_cv_path_lt_DD"; then
11704 :
11705 fi
11706 else
11707 ac_cv_path_lt_DD=$lt_DD
11708 fi
11709
11710 rm -f conftest.i conftest2.i conftest.out
11711 fi
11712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
11713 $as_echo "$ac_cv_path_lt_DD" >&6; }
11714
11715
11716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
11717 $as_echo_n "checking how to truncate binary pipes... " >&6; }
11718 if ${lt_cv_truncate_bin+:} false; then :
11719 $as_echo_n "(cached) " >&6
11720 else
11721 printf 0123456789abcdef0123456789abcdef >conftest.i
11722 cat conftest.i conftest.i >conftest2.i
11723 lt_cv_truncate_bin=
11724 if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
11725 cmp -s conftest.i conftest.out \
11726 && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
11727 fi
11728 rm -f conftest.i conftest2.i conftest.out
11729 test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"
11730 fi
11731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
11732 $as_echo "$lt_cv_truncate_bin" >&6; }
11733
11734
11735
11736
11737
11738
11739
11740 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
11741 func_cc_basename ()
11742 {
11743 for cc_temp in $*""; do
11744 case $cc_temp in
11745 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
11746 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
11747 \-*) ;;
11748 *) break;;
11749 esac
11750 done
11751 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
11752 }
11753
1163711754 # Check whether --enable-libtool-lock was given.
1163811755 if test "${enable_libtool_lock+set}" = set; then :
1163911756 enableval=$enable_libtool_lock;
1164011757 fi
1164111758
11642 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
11759 test no = "$enable_libtool_lock" || enable_libtool_lock=yes
1164311760
1164411761 # Some flags need to be propagated to the compiler or linker for good
1164511762 # libtool support.
1164611763 case $host in
1164711764 ia64-*-hpux*)
11648 # Find out which ABI we are using.
11765 # Find out what ABI is being produced by ac_compile, and set mode
11766 # options accordingly.
1164911767 echo 'int i;' > conftest.$ac_ext
1165011768 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
1165111769 (eval $ac_compile) 2>&5
1165411772 test $ac_status = 0; }; then
1165511773 case `/usr/bin/file conftest.$ac_objext` in
1165611774 *ELF-32*)
11657 HPUX_IA64_MODE="32"
11775 HPUX_IA64_MODE=32
1165811776 ;;
1165911777 *ELF-64*)
11660 HPUX_IA64_MODE="64"
11778 HPUX_IA64_MODE=64
1166111779 ;;
1166211780 esac
1166311781 fi
1166411782 rm -rf conftest*
1166511783 ;;
1166611784 *-*-irix6*)
11667 # Find out which ABI we are using.
11785 # Find out what ABI is being produced by ac_compile, and set linker
11786 # options accordingly.
1166811787 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
1166911788 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
1167011789 (eval $ac_compile) 2>&5
1167111790 ac_status=$?
1167211791 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1167311792 test $ac_status = 0; }; then
11674 if test "$lt_cv_prog_gnu_ld" = yes; then
11793 if test yes = "$lt_cv_prog_gnu_ld"; then
1167511794 case `/usr/bin/file conftest.$ac_objext` in
1167611795 *32-bit*)
1167711796 LD="${LD-ld} -melf32bsmip"
1170011819 rm -rf conftest*
1170111820 ;;
1170211821
11822 mips64*-*linux*)
11823 # Find out what ABI is being produced by ac_compile, and set linker
11824 # options accordingly.
11825 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
11826 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
11827 (eval $ac_compile) 2>&5
11828 ac_status=$?
11829 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11830 test $ac_status = 0; }; then
11831 emul=elf
11832 case `/usr/bin/file conftest.$ac_objext` in
11833 *32-bit*)
11834 emul="${emul}32"
11835 ;;
11836 *64-bit*)
11837 emul="${emul}64"
11838 ;;
11839 esac
11840 case `/usr/bin/file conftest.$ac_objext` in
11841 *MSB*)
11842 emul="${emul}btsmip"
11843 ;;
11844 *LSB*)
11845 emul="${emul}ltsmip"
11846 ;;
11847 esac
11848 case `/usr/bin/file conftest.$ac_objext` in
11849 *N32*)
11850 emul="${emul}n32"
11851 ;;
11852 esac
11853 LD="${LD-ld} -m $emul"
11854 fi
11855 rm -rf conftest*
11856 ;;
11857
1170311858 x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
1170411859 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
11705 # Find out which ABI we are using.
11860 # Find out what ABI is being produced by ac_compile, and set linker
11861 # options accordingly. Note that the listed cases only cover the
11862 # situations where additional linker options are needed (such as when
11863 # doing 32-bit compilation for a host where ld defaults to 64-bit, or
11864 # vice versa); the common cases where no linker options are needed do
11865 # not appear in the list.
1170611866 echo 'int i;' > conftest.$ac_ext
1170711867 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
1170811868 (eval $ac_compile) 2>&5
1172511885 ;;
1172611886 esac
1172711887 ;;
11728 powerpc64le-*)
11888 powerpc64le-*linux*)
1172911889 LD="${LD-ld} -m elf32lppclinux"
1173011890 ;;
11731 powerpc64-*)
11891 powerpc64-*linux*)
1173211892 LD="${LD-ld} -m elf32ppclinux"
1173311893 ;;
1173411894 s390x-*linux*)
1174711907 x86_64-*linux*)
1174811908 LD="${LD-ld} -m elf_x86_64"
1174911909 ;;
11750 powerpcle-*)
11910 powerpcle-*linux*)
1175111911 LD="${LD-ld} -m elf64lppc"
1175211912 ;;
11753 powerpc-*)
11913 powerpc-*linux*)
1175411914 LD="${LD-ld} -m elf64ppc"
1175511915 ;;
1175611916 s390*-*linux*|s390*-*tpf*)
1176811928
1176911929 *-*-sco3.2v5*)
1177011930 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
11771 SAVE_CFLAGS="$CFLAGS"
11931 SAVE_CFLAGS=$CFLAGS
1177211932 CFLAGS="$CFLAGS -belf"
1177311933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
1177411934 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
1181611976 fi
1181711977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
1181811978 $as_echo "$lt_cv_cc_needs_belf" >&6; }
11819 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
11979 if test yes != "$lt_cv_cc_needs_belf"; then
1182011980 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
11821 CFLAGS="$SAVE_CFLAGS"
11981 CFLAGS=$SAVE_CFLAGS
1182211982 fi
1182311983 ;;
1182411984 *-*solaris*)
11825 # Find out which ABI we are using.
11985 # Find out what ABI is being produced by ac_compile, and set linker
11986 # options accordingly.
1182611987 echo 'int i;' > conftest.$ac_ext
1182711988 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
1182811989 (eval $ac_compile) 2>&5
1183411995 case $lt_cv_prog_gnu_ld in
1183511996 yes*)
1183611997 case $host in
11837 i?86-*-solaris*)
11998 i?86-*-solaris*|x86_64-*-solaris*)
1183811999 LD="${LD-ld} -m elf_x86_64"
1183912000 ;;
1184012001 sparc*-*-solaris*)
1184312004 esac
1184412005 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
1184512006 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
11846 LD="${LD-ld}_sol2"
12007 LD=${LD-ld}_sol2
1184712008 fi
1184812009 ;;
1184912010 *)
1185912020 ;;
1186012021 esac
1186112022
11862 need_locks="$enable_libtool_lock"
12023 need_locks=$enable_libtool_lock
1186312024
1186412025 if test -n "$ac_tool_prefix"; then
1186512026 # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
1197012131 fi
1197112132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
1197212133 $as_echo "$lt_cv_path_mainfest_tool" >&6; }
11973 if test "x$lt_cv_path_mainfest_tool" != xyes; then
12134 if test yes != "$lt_cv_path_mainfest_tool"; then
1197412135 MANIFEST_TOOL=:
1197512136 fi
1197612137
1247312634 $as_echo_n "(cached) " >&6
1247412635 else
1247512636 lt_cv_apple_cc_single_mod=no
12476 if test -z "${LT_MULTI_MODULE}"; then
12637 if test -z "$LT_MULTI_MODULE"; then
1247712638 # By default we will add the -single_module flag. You can override
1247812639 # by either setting the environment variable LT_MULTI_MODULE
1247912640 # non-empty at configure time, or by adding -multi_module to the
1249112652 cat conftest.err >&5
1249212653 # Otherwise, if the output was created with a 0 exit code from
1249312654 # the compiler, it worked.
12494 elif test -f libconftest.dylib && test $_lt_result -eq 0; then
12655 elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
1249512656 lt_cv_apple_cc_single_mod=yes
1249612657 else
1249712658 cat conftest.err >&5
1253812699 fi
1253912700 rm -f core conftest.err conftest.$ac_objext \
1254012701 conftest$ac_exeext conftest.$ac_ext
12541 LDFLAGS="$save_LDFLAGS"
12702 LDFLAGS=$save_LDFLAGS
1254212703
1254312704 fi
1254412705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
1256712728 _lt_result=$?
1256812729 if test -s conftest.err && $GREP force_load conftest.err; then
1256912730 cat conftest.err >&5
12570 elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
12731 elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
1257112732 lt_cv_ld_force_load=yes
1257212733 else
1257312734 cat conftest.err >&5
1258012741 $as_echo "$lt_cv_ld_force_load" >&6; }
1258112742 case $host_os in
1258212743 rhapsody* | darwin1.[012])
12583 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
12744 _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
1258412745 darwin1.*)
12585 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
12746 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
1258612747 darwin*) # darwin 5.x on
1258712748 # if running on 10.5 or later, the deployment target defaults
1258812749 # to the OS version, if on x86, and 10.4, the deployment
1258912750 # target defaults to 10.4. Don't you love it?
1259012751 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
1259112752 10.0,*86*-darwin8*|10.0,*-darwin[91]*)
12592 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
12593 10.[012]*)
12594 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
12753 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
12754 10.[012][,.]*)
12755 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
1259512756 10.*)
12596 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
12757 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
1259712758 esac
1259812759 ;;
1259912760 esac
12600 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
12761 if test yes = "$lt_cv_apple_cc_single_mod"; then
1260112762 _lt_dar_single_mod='$single_module'
1260212763 fi
12603 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
12604 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
12764 if test yes = "$lt_cv_ld_exported_symbols_list"; then
12765 _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
1260512766 else
12606 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
12767 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
1260712768 fi
12608 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
12769 if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
1260912770 _lt_dsymutil='~$DSYMUTIL $lib || :'
1261012771 else
1261112772 _lt_dsymutil=
1261212773 fi
1261312774 ;;
1261412775 esac
12776
12777 # func_munge_path_list VARIABLE PATH
12778 # -----------------------------------
12779 # VARIABLE is name of variable containing _space_ separated list of
12780 # directories to be munged by the contents of PATH, which is string
12781 # having a format:
12782 # "DIR[:DIR]:"
12783 # string "DIR[ DIR]" will be prepended to VARIABLE
12784 # ":DIR[:DIR]"
12785 # string "DIR[ DIR]" will be appended to VARIABLE
12786 # "DIRP[:DIRP]::[DIRA:]DIRA"
12787 # string "DIRP[ DIRP]" will be prepended to VARIABLE and string
12788 # "DIRA[ DIRA]" will be appended to VARIABLE
12789 # "DIR[:DIR]"
12790 # VARIABLE will be replaced by "DIR[ DIR]"
12791 func_munge_path_list ()
12792 {
12793 case x$2 in
12794 x)
12795 ;;
12796 *:)
12797 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
12798 ;;
12799 x:*)
12800 eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
12801 ;;
12802 *::*)
12803 eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
12804 eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
12805 ;;
12806 *)
12807 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
12808 ;;
12809 esac
12810 }
1261512811
1261612812 for ac_header in dlfcn.h
1261712813 do :
1263012826
1263112827 func_stripname_cnf ()
1263212828 {
12633 case ${2} in
12634 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
12635 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
12829 case $2 in
12830 .*) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%\\\\$2\$%%"`;;
12831 *) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%$2\$%%"`;;
1263612832 esac
1263712833 } # func_stripname_cnf
1263812834
1265812854 *)
1265912855 enable_shared=no
1266012856 # Look at the argument we got. We use all the common list separators.
12661 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
12857 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
1266212858 for pkg in $enableval; do
12663 IFS="$lt_save_ifs"
12859 IFS=$lt_save_ifs
1266412860 if test "X$pkg" = "X$p"; then
1266512861 enable_shared=yes
1266612862 fi
1266712863 done
12668 IFS="$lt_save_ifs"
12864 IFS=$lt_save_ifs
1266912865 ;;
1267012866 esac
1267112867 else
1268912885 *)
1269012886 enable_static=no
1269112887 # Look at the argument we got. We use all the common list separators.
12692 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
12888 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
1269312889 for pkg in $enableval; do
12694 IFS="$lt_save_ifs"
12890 IFS=$lt_save_ifs
1269512891 if test "X$pkg" = "X$p"; then
1269612892 enable_static=yes
1269712893 fi
1269812894 done
12699 IFS="$lt_save_ifs"
12895 IFS=$lt_save_ifs
1270012896 ;;
1270112897 esac
1270212898 else
1272012916 *)
1272112917 pic_mode=default
1272212918 # Look at the argument we got. We use all the common list separators.
12723 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
12919 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
1272412920 for lt_pkg in $withval; do
12725 IFS="$lt_save_ifs"
12921 IFS=$lt_save_ifs
1272612922 if test "X$lt_pkg" = "X$lt_p"; then
1272712923 pic_mode=yes
1272812924 fi
1272912925 done
12730 IFS="$lt_save_ifs"
12926 IFS=$lt_save_ifs
1273112927 ;;
1273212928 esac
1273312929 else
1273412930 pic_mode=default
1273512931 fi
1273612932
12737
12738 test -z "$pic_mode" && pic_mode=default
1273912933
1274012934
1274112935
1275212946 *)
1275312947 enable_fast_install=no
1275412948 # Look at the argument we got. We use all the common list separators.
12755 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
12949 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
1275612950 for pkg in $enableval; do
12757 IFS="$lt_save_ifs"
12951 IFS=$lt_save_ifs
1275812952 if test "X$pkg" = "X$p"; then
1275912953 enable_fast_install=yes
1276012954 fi
1276112955 done
12762 IFS="$lt_save_ifs"
12956 IFS=$lt_save_ifs
1276312957 ;;
1276412958 esac
1276512959 else
1277312967
1277412968
1277512969
12970 shared_archive_member_spec=
12971 case $host,$enable_shared in
12972 power*-*-aix[5-9]*,yes)
12973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
12974 $as_echo_n "checking which variant of shared library versioning to provide... " >&6; }
12975
12976 # Check whether --with-aix-soname was given.
12977 if test "${with_aix_soname+set}" = set; then :
12978 withval=$with_aix_soname; case $withval in
12979 aix|svr4|both)
12980 ;;
12981 *)
12982 as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5
12983 ;;
12984 esac
12985 lt_cv_with_aix_soname=$with_aix_soname
12986 else
12987 if ${lt_cv_with_aix_soname+:} false; then :
12988 $as_echo_n "(cached) " >&6
12989 else
12990 lt_cv_with_aix_soname=aix
12991 fi
12992
12993 with_aix_soname=$lt_cv_with_aix_soname
12994 fi
12995
12996 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
12997 $as_echo "$with_aix_soname" >&6; }
12998 if test aix != "$with_aix_soname"; then
12999 # For the AIX way of multilib, we name the shared archive member
13000 # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
13001 # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
13002 # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
13003 # the AIX toolchain works better with OBJECT_MODE set (default 32).
13004 if test 64 = "${OBJECT_MODE-32}"; then
13005 shared_archive_member_spec=shr_64
13006 else
13007 shared_archive_member_spec=shr
13008 fi
13009 fi
13010 ;;
13011 *)
13012 with_aix_soname=aix
13013 ;;
13014 esac
13015
13016
13017
13018
13019
13020
13021
1277613022
1277713023
1277813024
1277913025 # This can be used to rebuild libtool when needed
12780 LIBTOOL_DEPS="$ltmain"
13026 LIBTOOL_DEPS=$ltmain
1278113027
1278213028 # Always use our own libtool.
1278313029 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
1282613072
1282713073
1282813074
12829 if test -n "${ZSH_VERSION+set}" ; then
13075 if test -n "${ZSH_VERSION+set}"; then
1283013076 setopt NO_GLOB_SUBST
1283113077 fi
1283213078
1286513111 # AIX sometimes has problems with the GCC collect2 program. For some
1286613112 # reason, if we set the COLLECT_NAMES environment variable, the problems
1286713113 # vanish in a puff of smoke.
12868 if test "X${COLLECT_NAMES+set}" != Xset; then
13114 if test set != "${COLLECT_NAMES+set}"; then
1286913115 COLLECT_NAMES=
1287013116 export COLLECT_NAMES
1287113117 fi
1287613122 ofile=libtool
1287713123 can_build_shared=yes
1287813124
12879 # All known linkers require a `.a' archive for static linking (except MSVC,
13125 # All known linkers require a '.a' archive for static linking (except MSVC,
1288013126 # which needs '.lib').
1288113127 libext=a
1288213128
12883 with_gnu_ld="$lt_cv_prog_gnu_ld"
12884
12885 old_CC="$CC"
12886 old_CFLAGS="$CFLAGS"
13129 with_gnu_ld=$lt_cv_prog_gnu_ld
13130
13131 old_CC=$CC
13132 old_CFLAGS=$CFLAGS
1288713133
1288813134 # Set sane defaults for various variables
1288913135 test -z "$CC" && CC=cc
1289213138 test -z "$LD" && LD=ld
1289313139 test -z "$ac_objext" && ac_objext=o
1289413140
12895 for cc_temp in $compiler""; do
12896 case $cc_temp in
12897 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
12898 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
12899 \-*) ;;
12900 *) break;;
12901 esac
12902 done
12903 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
13141 func_cc_basename $compiler
13142 cc_basename=$func_cc_basename_result
1290413143
1290513144
1290613145 # Only perform the check for file, if the check method requires it
1291513154 else
1291613155 case $MAGIC_CMD in
1291713156 [\\/*] | ?:[\\/]*)
12918 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
13157 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
1291913158 ;;
1292013159 *)
12921 lt_save_MAGIC_CMD="$MAGIC_CMD"
12922 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
13160 lt_save_MAGIC_CMD=$MAGIC_CMD
13161 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
1292313162 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
1292413163 for ac_dir in $ac_dummy; do
12925 IFS="$lt_save_ifs"
13164 IFS=$lt_save_ifs
1292613165 test -z "$ac_dir" && ac_dir=.
12927 if test -f $ac_dir/${ac_tool_prefix}file; then
12928 lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
13166 if test -f "$ac_dir/${ac_tool_prefix}file"; then
13167 lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file"
1292913168 if test -n "$file_magic_test_file"; then
1293013169 case $deplibs_check_method in
1293113170 "file_magic "*)
1293213171 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
12933 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
13172 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
1293413173 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
1293513174 $EGREP "$file_magic_regex" > /dev/null; then
1293613175 :
1295313192 break
1295413193 fi
1295513194 done
12956 IFS="$lt_save_ifs"
12957 MAGIC_CMD="$lt_save_MAGIC_CMD"
13195 IFS=$lt_save_ifs
13196 MAGIC_CMD=$lt_save_MAGIC_CMD
1295813197 ;;
1295913198 esac
1296013199 fi
1296113200
12962 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
13201 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
1296313202 if test -n "$MAGIC_CMD"; then
1296413203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
1296513204 $as_echo "$MAGIC_CMD" >&6; }
1298113220 else
1298213221 case $MAGIC_CMD in
1298313222 [\\/*] | ?:[\\/]*)
12984 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
13223 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
1298513224 ;;
1298613225 *)
12987 lt_save_MAGIC_CMD="$MAGIC_CMD"
12988 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
13226 lt_save_MAGIC_CMD=$MAGIC_CMD
13227 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
1298913228 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
1299013229 for ac_dir in $ac_dummy; do
12991 IFS="$lt_save_ifs"
13230 IFS=$lt_save_ifs
1299213231 test -z "$ac_dir" && ac_dir=.
12993 if test -f $ac_dir/file; then
12994 lt_cv_path_MAGIC_CMD="$ac_dir/file"
13232 if test -f "$ac_dir/file"; then
13233 lt_cv_path_MAGIC_CMD=$ac_dir/"file"
1299513234 if test -n "$file_magic_test_file"; then
1299613235 case $deplibs_check_method in
1299713236 "file_magic "*)
1299813237 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
12999 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
13238 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
1300013239 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
1300113240 $EGREP "$file_magic_regex" > /dev/null; then
1300213241 :
1301913258 break
1302013259 fi
1302113260 done
13022 IFS="$lt_save_ifs"
13023 MAGIC_CMD="$lt_save_MAGIC_CMD"
13261 IFS=$lt_save_ifs
13262 MAGIC_CMD=$lt_save_MAGIC_CMD
1302413263 ;;
1302513264 esac
1302613265 fi
1302713266
13028 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
13267 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
1302913268 if test -n "$MAGIC_CMD"; then
1303013269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
1303113270 $as_echo "$MAGIC_CMD" >&6; }
1304613285
1304713286 # Use C for the default configuration in the libtool script
1304813287
13049 lt_save_CC="$CC"
13288 lt_save_CC=$CC
1305013289 ac_ext=c
1305113290 ac_cpp='$CPP $CPPFLAGS'
1305213291 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1310813347
1310913348 lt_prog_compiler_no_builtin_flag=
1311013349
13111 if test "$GCC" = yes; then
13350 if test yes = "$GCC"; then
1311213351 case $cc_basename in
1311313352 nvcc*)
1311413353 lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
1312413363 lt_cv_prog_compiler_rtti_exceptions=no
1312513364 ac_outfile=conftest.$ac_objext
1312613365 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
13127 lt_compiler_flag="-fno-rtti -fno-exceptions"
13366 lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment
1312813367 # Insert the option either (1) after the last *FLAGS variable, or
1312913368 # (2) before a word containing "conftest.", or (3) at the end.
1313013369 # Note that $ac_compile itself does not contain backslashes and begins
1315413393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
1315513394 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
1315613395
13157 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
13396 if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then
1315813397 lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
1315913398 else
1316013399 :
1317213411 lt_prog_compiler_static=
1317313412
1317413413
13175 if test "$GCC" = yes; then
13414 if test yes = "$GCC"; then
1317613415 lt_prog_compiler_wl='-Wl,'
1317713416 lt_prog_compiler_static='-static'
1317813417
1317913418 case $host_os in
1318013419 aix*)
1318113420 # All AIX code is PIC.
13182 if test "$host_cpu" = ia64; then
13421 if test ia64 = "$host_cpu"; then
1318313422 # AIX 5 now supports IA64 processor
1318413423 lt_prog_compiler_static='-Bstatic'
1318513424 fi
13425 lt_prog_compiler_pic='-fPIC'
1318613426 ;;
1318713427
1318813428 amigaos*)
1319313433 ;;
1319413434 m68k)
1319513435 # FIXME: we need at least 68020 code to build shared libraries, but
13196 # adding the `-m68020' flag to GCC prevents building anything better,
13197 # like `-m68040'.
13436 # adding the '-m68020' flag to GCC prevents building anything better,
13437 # like '-m68040'.
1319813438 lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
1319913439 ;;
1320013440 esac
1321013450 # Although the cygwin gcc ignores -fPIC, still need this for old-style
1321113451 # (--disable-auto-import) libraries
1321213452 lt_prog_compiler_pic='-DDLL_EXPORT'
13453 case $host_os in
13454 os2*)
13455 lt_prog_compiler_static='$wl-static'
13456 ;;
13457 esac
1321313458 ;;
1321413459
1321513460 darwin* | rhapsody*)
1328013525 case $host_os in
1328113526 aix*)
1328213527 lt_prog_compiler_wl='-Wl,'
13283 if test "$host_cpu" = ia64; then
13528 if test ia64 = "$host_cpu"; then
1328413529 # AIX 5 now supports IA64 processor
1328513530 lt_prog_compiler_static='-Bstatic'
1328613531 else
1328813533 fi
1328913534 ;;
1329013535
13536 darwin* | rhapsody*)
13537 # PIC is the default on this platform
13538 # Common symbols not allowed in MH_DYLIB files
13539 lt_prog_compiler_pic='-fno-common'
13540 case $cc_basename in
13541 nagfor*)
13542 # NAG Fortran compiler
13543 lt_prog_compiler_wl='-Wl,-Wl,,'
13544 lt_prog_compiler_pic='-PIC'
13545 lt_prog_compiler_static='-Bstatic'
13546 ;;
13547 esac
13548 ;;
13549
1329113550 mingw* | cygwin* | pw32* | os2* | cegcc*)
1329213551 # This hack is so that the source file can tell whether it is being
1329313552 # built for inclusion in a dll (and should export symbols for example).
1329413553 lt_prog_compiler_pic='-DDLL_EXPORT'
13554 case $host_os in
13555 os2*)
13556 lt_prog_compiler_static='$wl-static'
13557 ;;
13558 esac
1329513559 ;;
1329613560
1329713561 hpux9* | hpux10* | hpux11*)
1330713571 ;;
1330813572 esac
1330913573 # Is there a better lt_prog_compiler_static that works with the bundled CC?
13310 lt_prog_compiler_static='${wl}-a ${wl}archive'
13574 lt_prog_compiler_static='$wl-a ${wl}archive'
1331113575 ;;
1331213576
1331313577 irix5* | irix6* | nonstopux*)
1331813582
1331913583 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
1332013584 case $cc_basename in
13321 # old Intel for x86_64 which still supported -KPIC.
13585 # old Intel for x86_64, which still supported -KPIC.
1332213586 ecc*)
1332313587 lt_prog_compiler_wl='-Wl,'
1332413588 lt_prog_compiler_pic='-KPIC'
1334213606 lt_prog_compiler_wl='-Wl,-Wl,,'
1334313607 lt_prog_compiler_pic='-PIC'
1334413608 lt_prog_compiler_static='-Bstatic'
13609 ;;
13610 tcc*)
13611 # Fabrice Bellard et al's Tiny C Compiler
13612 lt_prog_compiler_wl='-Wl,'
13613 lt_prog_compiler_pic='-fPIC'
13614 lt_prog_compiler_static='-static'
1334513615 ;;
1334613616 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
1334713617 # Portland Group compilers (*not* the Pentium gcc compiler,
1344013710 ;;
1344113711
1344213712 sysv4*MP*)
13443 if test -d /usr/nec ;then
13713 if test -d /usr/nec; then
1344413714 lt_prog_compiler_pic='-Kconform_pic'
1344513715 lt_prog_compiler_static='-Bstatic'
1344613716 fi
1346913739 fi
1347013740
1347113741 case $host_os in
13472 # For platforms which do not support PIC, -DPIC is meaningless:
13742 # For platforms that do not support PIC, -DPIC is meaningless:
1347313743 *djgpp*)
1347413744 lt_prog_compiler_pic=
1347513745 ;;
1350113771 lt_cv_prog_compiler_pic_works=no
1350213772 ac_outfile=conftest.$ac_objext
1350313773 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
13504 lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
13774 lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment
1350513775 # Insert the option either (1) after the last *FLAGS variable, or
1350613776 # (2) before a word containing "conftest.", or (3) at the end.
1350713777 # Note that $ac_compile itself does not contain backslashes and begins
1353113801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
1353213802 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
1353313803
13534 if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
13804 if test yes = "$lt_cv_prog_compiler_pic_works"; then
1353513805 case $lt_prog_compiler_pic in
1353613806 "" | " "*) ;;
1353713807 *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
1356313833 $as_echo_n "(cached) " >&6
1356413834 else
1356513835 lt_cv_prog_compiler_static_works=no
13566 save_LDFLAGS="$LDFLAGS"
13836 save_LDFLAGS=$LDFLAGS
1356713837 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
1356813838 echo "$lt_simple_link_test_code" > conftest.$ac_ext
1356913839 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1358213852 fi
1358313853 fi
1358413854 $RM -r conftest*
13585 LDFLAGS="$save_LDFLAGS"
13855 LDFLAGS=$save_LDFLAGS
1358613856
1358713857 fi
1358813858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
1358913859 $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
1359013860
13591 if test x"$lt_cv_prog_compiler_static_works" = xyes; then
13861 if test yes = "$lt_cv_prog_compiler_static_works"; then
1359213862 :
1359313863 else
1359413864 lt_prog_compiler_static=
1370813978
1370913979
1371013980
13711 hard_links="nottested"
13712 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
13981 hard_links=nottested
13982 if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then
1371313983 # do not overwrite the value of need_locks provided by the user
1371413984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
1371513985 $as_echo_n "checking if we can lock with hard links... " >&6; }
1372113991 ln conftest.a conftest.b 2>/dev/null && hard_links=no
1372213992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
1372313993 $as_echo "$hard_links" >&6; }
13724 if test "$hard_links" = no; then
13725 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
13726 $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
13994 if test no = "$hard_links"; then
13995 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
13996 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
1372713997 need_locks=warn
1372813998 fi
1372913999 else
1376614036 # included in the symbol list
1376714037 include_expsyms=
1376814038 # exclude_expsyms can be an extended regexp of symbols to exclude
13769 # it will be wrapped by ` (' and `)$', so one must not match beginning or
13770 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
13771 # as well as any symbol that contains `d'.
14039 # it will be wrapped by ' (' and ')$', so one must not match beginning or
14040 # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
14041 # as well as any symbol that contains 'd'.
1377214042 exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
1377314043 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
1377414044 # platforms (ab)use it in PIC code, but their linkers get confused if
1378314053 # FIXME: the MSVC++ port hasn't been tested in a loooong time
1378414054 # When not using gcc, we currently assume that we are using
1378514055 # Microsoft Visual C++.
13786 if test "$GCC" != yes; then
14056 if test yes != "$GCC"; then
1378714057 with_gnu_ld=no
1378814058 fi
1378914059 ;;
1379114061 # we just hope/assume this is gcc and not c89 (= MSVC++)
1379214062 with_gnu_ld=yes
1379314063 ;;
13794 openbsd*)
14064 openbsd* | bitrig*)
1379514065 with_gnu_ld=no
13796 ;;
13797 linux* | k*bsd*-gnu | gnu*)
13798 link_all_deplibs=no
1379914066 ;;
1380014067 esac
1380114068
1380414071 # On some targets, GNU ld is compatible enough with the native linker
1380514072 # that we're better off using the native interface for both.
1380614073 lt_use_gnu_ld_interface=no
13807 if test "$with_gnu_ld" = yes; then
14074 if test yes = "$with_gnu_ld"; then
1380814075 case $host_os in
1380914076 aix*)
1381014077 # The AIX port of GNU ld has always aspired to compatibility
1382614093 esac
1382714094 fi
1382814095
13829 if test "$lt_use_gnu_ld_interface" = yes; then
14096 if test yes = "$lt_use_gnu_ld_interface"; then
1383014097 # If archive_cmds runs LD, not CC, wlarc should be empty
13831 wlarc='${wl}'
14098 wlarc='$wl'
1383214099
1383314100 # Set some defaults for GNU ld with shared library support. These
1383414101 # are reset later if shared libraries are not supported. Putting them
1383514102 # here allows them to be overridden if necessary.
1383614103 runpath_var=LD_RUN_PATH
13837 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
13838 export_dynamic_flag_spec='${wl}--export-dynamic'
14104 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
14105 export_dynamic_flag_spec='$wl--export-dynamic'
1383914106 # ancient GNU ld didn't support --whole-archive et. al.
1384014107 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
13841 whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
14108 whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
1384214109 else
1384314110 whole_archive_flag_spec=
1384414111 fi
1384514112 supports_anon_versioning=no
13846 case `$LD -v 2>&1` in
14113 case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in
1384714114 *GNU\ gold*) supports_anon_versioning=yes ;;
1384814115 *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
1384914116 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
1385614123 case $host_os in
1385714124 aix[3-9]*)
1385814125 # On AIX/PPC, the GNU linker is very broken
13859 if test "$host_cpu" != ia64; then
14126 if test ia64 != "$host_cpu"; then
1386014127 ld_shlibs=no
1386114128 cat <<_LT_EOF 1>&2
1386214129
1387514142 case $host_cpu in
1387614143 powerpc)
1387714144 # see comment about AmigaOS4 .so support
13878 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14145 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
1387914146 archive_expsym_cmds=''
1388014147 ;;
1388114148 m68k)
1389114158 allow_undefined_flag=unsupported
1389214159 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
1389314160 # support --undefined. This deserves some investigation. FIXME
13894 archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14161 archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
1389514162 else
1389614163 ld_shlibs=no
1389714164 fi
1390114168 # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
1390214169 # as there is no search path for DLLs.
1390314170 hardcode_libdir_flag_spec='-L$libdir'
13904 export_dynamic_flag_spec='${wl}--export-all-symbols'
14171 export_dynamic_flag_spec='$wl--export-all-symbols'
1390514172 allow_undefined_flag=unsupported
1390614173 always_export_symbols=no
1390714174 enable_shared_with_static_runtimes=yes
1390914176 exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
1391014177
1391114178 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
13912 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
13913 # If the export-symbols file already is a .def file (1st line
13914 # is EXPORTS), use it as is; otherwise, prepend...
13915 archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
13916 cp $export_symbols $output_objdir/$soname.def;
13917 else
13918 echo EXPORTS > $output_objdir/$soname.def;
13919 cat $export_symbols >> $output_objdir/$soname.def;
13920 fi~
13921 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
14179 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
14180 # If the export-symbols file already is a .def file, use it as
14181 # is; otherwise, prepend EXPORTS...
14182 archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
14183 cp $export_symbols $output_objdir/$soname.def;
14184 else
14185 echo EXPORTS > $output_objdir/$soname.def;
14186 cat $export_symbols >> $output_objdir/$soname.def;
14187 fi~
14188 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
1392214189 else
1392314190 ld_shlibs=no
1392414191 fi
1392514192 ;;
1392614193
1392714194 haiku*)
13928 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14195 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
1392914196 link_all_deplibs=yes
14197 ;;
14198
14199 os2*)
14200 hardcode_libdir_flag_spec='-L$libdir'
14201 hardcode_minus_L=yes
14202 allow_undefined_flag=unsupported
14203 shrext_cmds=.dll
14204 archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
14205 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
14206 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
14207 $ECHO EXPORTS >> $output_objdir/$libname.def~
14208 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
14209 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
14210 emximp -o $lib $output_objdir/$libname.def'
14211 archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
14212 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
14213 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
14214 $ECHO EXPORTS >> $output_objdir/$libname.def~
14215 prefix_cmds="$SED"~
14216 if test EXPORTS = "`$SED 1q $export_symbols`"; then
14217 prefix_cmds="$prefix_cmds -e 1d";
14218 fi~
14219 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
14220 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
14221 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
14222 emximp -o $lib $output_objdir/$libname.def'
14223 old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
14224 enable_shared_with_static_runtimes=yes
1393014225 ;;
1393114226
1393214227 interix[3-9]*)
1393314228 hardcode_direct=no
1393414229 hardcode_shlibpath_var=no
13935 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
13936 export_dynamic_flag_spec='${wl}-E'
14230 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
14231 export_dynamic_flag_spec='$wl-E'
1393714232 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
1393814233 # Instead, shared libraries are loaded at an image base (0x10000000 by
1393914234 # default) and relocated if they conflict, which is a slow very memory
1394014235 # consuming and fragmenting process. To avoid this, we pick a random,
1394114236 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
1394214237 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
13943 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
13944 archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
14238 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
14239 archive_expsym_cmds='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
1394514240 ;;
1394614241
1394714242 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
1394814243 tmp_diet=no
13949 if test "$host_os" = linux-dietlibc; then
14244 if test linux-dietlibc = "$host_os"; then
1395014245 case $cc_basename in
1395114246 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
1395214247 esac
1395314248 fi
1395414249 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
13955 && test "$tmp_diet" = no
14250 && test no = "$tmp_diet"
1395614251 then
1395714252 tmp_addflag=' $pic_flag'
1395814253 tmp_sharedflag='-shared'
1395914254 case $cc_basename,$host_cpu in
1396014255 pgcc*) # Portland Group C compiler
13961 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
14256 whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
1396214257 tmp_addflag=' $pic_flag'
1396314258 ;;
1396414259 pgf77* | pgf90* | pgf95* | pgfortran*)
1396514260 # Portland Group f77 and f90 compilers
13966 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
14261 whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
1396714262 tmp_addflag=' $pic_flag -Mnomain' ;;
1396814263 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
1396914264 tmp_addflag=' -i_dynamic' ;;
1397414269 lf95*) # Lahey Fortran 8.1
1397514270 whole_archive_flag_spec=
1397614271 tmp_sharedflag='--shared' ;;
14272 nagfor*) # NAGFOR 5.3
14273 tmp_sharedflag='-Wl,-shared' ;;
1397714274 xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
1397814275 tmp_sharedflag='-qmkshrobj'
1397914276 tmp_addflag= ;;
1398014277 nvcc*) # Cuda Compiler Driver 2.2
13981 whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
14278 whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
1398214279 compiler_needs_object=yes
1398314280 ;;
1398414281 esac
1398514282 case `$CC -V 2>&1 | sed 5q` in
1398614283 *Sun\ C*) # Sun C 5.9
13987 whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
14284 whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
1398814285 compiler_needs_object=yes
1398914286 tmp_sharedflag='-G' ;;
1399014287 *Sun\ F*) # Sun Fortran 8.3
1399114288 tmp_sharedflag='-G' ;;
1399214289 esac
13993 archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13994
13995 if test "x$supports_anon_versioning" = xyes; then
14290 archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
14291
14292 if test yes = "$supports_anon_versioning"; then
1399614293 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
13997 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
13998 echo "local: *; };" >> $output_objdir/$libname.ver~
13999 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
14294 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
14295 echo "local: *; };" >> $output_objdir/$libname.ver~
14296 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
1400014297 fi
1400114298
1400214299 case $cc_basename in
14300 tcc*)
14301 export_dynamic_flag_spec='-rdynamic'
14302 ;;
1400314303 xlf* | bgf* | bgxlf* | mpixlf*)
1400414304 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
1400514305 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
14006 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
14306 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
1400714307 archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
14008 if test "x$supports_anon_versioning" = xyes; then
14308 if test yes = "$supports_anon_versioning"; then
1400914309 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
14010 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
14011 echo "local: *; };" >> $output_objdir/$libname.ver~
14012 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
14310 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
14311 echo "local: *; };" >> $output_objdir/$libname.ver~
14312 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
1401314313 fi
1401414314 ;;
1401514315 esac
1401814318 fi
1401914319 ;;
1402014320
14021 netbsd* | netbsdelf*-gnu)
14321 netbsd*)
1402214322 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
1402314323 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
1402414324 wlarc=
1402514325 else
14026 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14027 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
14326 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
14327 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
1402814328 fi
1402914329 ;;
1403014330
1404214342
1404314343 _LT_EOF
1404414344 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
14045 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14046 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
14345 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
14346 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
1404714347 else
1404814348 ld_shlibs=no
1404914349 fi
1405514355 ld_shlibs=no
1405614356 cat <<_LT_EOF 1>&2
1405714357
14058 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
14358 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
1405914359 *** reliably create shared libraries on SCO systems. Therefore, libtool
1406014360 *** is disabling shared libraries support. We urge you to upgrade GNU
1406114361 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
1407014370 # DT_RUNPATH tag from executables and libraries. But doing so
1407114371 # requires that you compile everything twice, which is a pain.
1407214372 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
14073 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
14074 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14075 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
14373 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
14374 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
14375 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
1407614376 else
1407714377 ld_shlibs=no
1407814378 fi
1408914389
1409014390 *)
1409114391 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
14092 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14093 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
14392 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
14393 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
1409414394 else
1409514395 ld_shlibs=no
1409614396 fi
1409714397 ;;
1409814398 esac
1409914399
14100 if test "$ld_shlibs" = no; then
14400 if test no = "$ld_shlibs"; then
1410114401 runpath_var=
1410214402 hardcode_libdir_flag_spec=
1410314403 export_dynamic_flag_spec=
1411314413 # Note: this linker hardcodes the directories in LIBPATH if there
1411414414 # are no directories specified by -L.
1411514415 hardcode_minus_L=yes
14116 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
14416 if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
1411714417 # Neither direct hardcoding nor static linking is supported with a
1411814418 # broken collect2.
1411914419 hardcode_direct=unsupported
1412114421 ;;
1412214422
1412314423 aix[4-9]*)
14124 if test "$host_cpu" = ia64; then
14424 if test ia64 = "$host_cpu"; then
1412514425 # On IA64, the linker does run time linking by default, so we don't
1412614426 # have to do anything special.
1412714427 aix_use_runtimelinking=no
1412814428 exp_sym_flag='-Bexport'
14129 no_entry_flag=""
14429 no_entry_flag=
1413014430 else
1413114431 # If we're using GNU nm, then we don't want the "-C" option.
14132 # -C means demangle to AIX nm, but means don't demangle with GNU nm
14133 # Also, AIX nm treats weak defined symbols like other global
14134 # defined symbols, whereas GNU nm marks them as "W".
14432 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
14433 # Without the "-l" option, or with the "-B" option, AIX nm treats
14434 # weak defined symbols like other global defined symbols, whereas
14435 # GNU nm marks them as "W".
14436 # While the 'weak' keyword is ignored in the Export File, we need
14437 # it in the Import File for the 'aix-soname' feature, so we have
14438 # to replace the "-B" option with "-P" for AIX nm.
1413514439 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
14136 export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
14440 export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
1413714441 else
14138 export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
14442 export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
1413914443 fi
1414014444 aix_use_runtimelinking=no
1414114445
1414214446 # Test if we are trying to use run time linking or normal
1414314447 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
14144 # need to do runtime linking.
14448 # have runtime linking enabled, and use it for executables.
14449 # For shared libraries, we enable/disable runtime linking
14450 # depending on the kind of the shared library created -
14451 # when "with_aix_soname,aix_use_runtimelinking" is:
14452 # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
14453 # "aix,yes" lib.so shared, rtl:yes, for executables
14454 # lib.a static archive
14455 # "both,no" lib.so.V(shr.o) shared, rtl:yes
14456 # lib.a(lib.so.V) shared, rtl:no, for executables
14457 # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
14458 # lib.a(lib.so.V) shared, rtl:no
14459 # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
14460 # lib.a static archive
1414514461 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
1414614462 for ld_flag in $LDFLAGS; do
14147 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
14463 if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
1414814464 aix_use_runtimelinking=yes
1414914465 break
1415014466 fi
1415114467 done
14468 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
14469 # With aix-soname=svr4, we create the lib.so.V shared archives only,
14470 # so we don't have lib.a shared libs to link our executables.
14471 # We have to force runtime linking in this case.
14472 aix_use_runtimelinking=yes
14473 LDFLAGS="$LDFLAGS -Wl,-brtl"
14474 fi
1415214475 ;;
1415314476 esac
1415414477
1416714490 hardcode_direct_absolute=yes
1416814491 hardcode_libdir_separator=':'
1416914492 link_all_deplibs=yes
14170 file_list_spec='${wl}-f,'
14171
14172 if test "$GCC" = yes; then
14493 file_list_spec='$wl-f,'
14494 case $with_aix_soname,$aix_use_runtimelinking in
14495 aix,*) ;; # traditional, no import file
14496 svr4,* | *,yes) # use import file
14497 # The Import File defines what to hardcode.
14498 hardcode_direct=no
14499 hardcode_direct_absolute=no
14500 ;;
14501 esac
14502
14503 if test yes = "$GCC"; then
1417314504 case $host_os in aix4.[012]|aix4.[012].*)
1417414505 # We only want to do this on AIX 4.2 and lower, the check
1417514506 # below for broken collect2 doesn't work under 4.3+
14176 collect2name=`${CC} -print-prog-name=collect2`
14507 collect2name=`$CC -print-prog-name=collect2`
1417714508 if test -f "$collect2name" &&
1417814509 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
1417914510 then
1419214523 ;;
1419314524 esac
1419414525 shared_flag='-shared'
14195 if test "$aix_use_runtimelinking" = yes; then
14196 shared_flag="$shared_flag "'${wl}-G'
14526 if test yes = "$aix_use_runtimelinking"; then
14527 shared_flag="$shared_flag "'$wl-G'
1419714528 fi
14198 link_all_deplibs=no
14529 # Need to ensure runtime linking is disabled for the traditional
14530 # shared library, or the linker may eventually find shared libraries
14531 # /with/ Import File - we do not want to mix them.
14532 shared_flag_aix='-shared'
14533 shared_flag_svr4='-shared $wl-G'
1419914534 else
1420014535 # not using gcc
14201 if test "$host_cpu" = ia64; then
14536 if test ia64 = "$host_cpu"; then
1420214537 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
1420314538 # chokes on -Wl,-G. The following line is correct:
1420414539 shared_flag='-G'
1420514540 else
14206 if test "$aix_use_runtimelinking" = yes; then
14207 shared_flag='${wl}-G'
14541 if test yes = "$aix_use_runtimelinking"; then
14542 shared_flag='$wl-G'
1420814543 else
14209 shared_flag='${wl}-bM:SRE'
14544 shared_flag='$wl-bM:SRE'
1421014545 fi
14546 shared_flag_aix='$wl-bM:SRE'
14547 shared_flag_svr4='$wl-G'
1421114548 fi
1421214549 fi
1421314550
14214 export_dynamic_flag_spec='${wl}-bexpall'
14551 export_dynamic_flag_spec='$wl-bexpall'
1421514552 # It seems that -bexpall does not export symbols beginning with
1421614553 # underscore (_), so it is better to generate a list of symbols to export.
1421714554 always_export_symbols=yes
14218 if test "$aix_use_runtimelinking" = yes; then
14555 if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
1421914556 # Warning - without using the other runtime loading flags (-brtl),
1422014557 # -berok will link without error, but may produce a broken library.
1422114558 allow_undefined_flag='-berok'
1422214559 # Determine the default libpath from the value encoded in an
1422314560 # empty executable.
14224 if test "${lt_cv_aix_libpath+set}" = set; then
14561 if test set = "${lt_cv_aix_libpath+set}"; then
1422514562 aix_libpath=$lt_cv_aix_libpath
1422614563 else
1422714564 if ${lt_cv_aix_libpath_+:} false; then :
1426414601 rm -f core conftest.err conftest.$ac_objext \
1426514602 conftest$ac_exeext conftest.$ac_ext
1426614603 if test -z "$lt_cv_aix_libpath_"; then
14267 lt_cv_aix_libpath_="/usr/lib:/lib"
14604 lt_cv_aix_libpath_=/usr/lib:/lib
1426814605 fi
1426914606
1427014607 fi
1427214609 aix_libpath=$lt_cv_aix_libpath_
1427314610 fi
1427414611
14275 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
14276 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
14612 hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
14613 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
1427714614 else
14278 if test "$host_cpu" = ia64; then
14279 hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
14615 if test ia64 = "$host_cpu"; then
14616 hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib'
1428014617 allow_undefined_flag="-z nodefs"
14281 archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
14618 archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols"
1428214619 else
1428314620 # Determine the default libpath from the value encoded in an
1428414621 # empty executable.
14285 if test "${lt_cv_aix_libpath+set}" = set; then
14622 if test set = "${lt_cv_aix_libpath+set}"; then
1428614623 aix_libpath=$lt_cv_aix_libpath
1428714624 else
1428814625 if ${lt_cv_aix_libpath_+:} false; then :
1432514662 rm -f core conftest.err conftest.$ac_objext \
1432614663 conftest$ac_exeext conftest.$ac_ext
1432714664 if test -z "$lt_cv_aix_libpath_"; then
14328 lt_cv_aix_libpath_="/usr/lib:/lib"
14665 lt_cv_aix_libpath_=/usr/lib:/lib
1432914666 fi
1433014667
1433114668 fi
1433314670 aix_libpath=$lt_cv_aix_libpath_
1433414671 fi
1433514672
14336 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
14673 hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
1433714674 # Warning - without using the other run time loading flags,
1433814675 # -berok will link without error, but may produce a broken library.
14339 no_undefined_flag=' ${wl}-bernotok'
14340 allow_undefined_flag=' ${wl}-berok'
14341 if test "$with_gnu_ld" = yes; then
14676 no_undefined_flag=' $wl-bernotok'
14677 allow_undefined_flag=' $wl-berok'
14678 if test yes = "$with_gnu_ld"; then
1434214679 # We only use this code for GNU lds that support --whole-archive.
14343 whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
14680 whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive'
1434414681 else
1434514682 # Exported symbols can be pulled into shared objects from archives
1434614683 whole_archive_flag_spec='$convenience'
1434714684 fi
1434814685 archive_cmds_need_lc=yes
14349 # This is similar to how AIX traditionally builds its shared libraries.
14350 archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
14686 archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
14687 # -brtl affects multiple linker settings, -berok does not and is overridden later
14688 compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
14689 if test svr4 != "$with_aix_soname"; then
14690 # This is similar to how AIX traditionally builds its shared libraries.
14691 archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
14692 fi
14693 if test aix != "$with_aix_soname"; then
14694 archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
14695 else
14696 # used by -dlpreopen to get the symbols
14697 archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
14698 fi
14699 archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d'
1435114700 fi
1435214701 fi
1435314702 ;;
1435614705 case $host_cpu in
1435714706 powerpc)
1435814707 # see comment about AmigaOS4 .so support
14359 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14708 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
1436014709 archive_expsym_cmds=''
1436114710 ;;
1436214711 m68k)
1438614735 # Tell ltmain to make .lib files, not .a files.
1438714736 libext=lib
1438814737 # Tell ltmain to make .dll files, not .so files.
14389 shrext_cmds=".dll"
14738 shrext_cmds=.dll
1439014739 # FIXME: Setting linknames here is a bad hack.
14391 archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
14392 archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
14393 sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
14394 else
14395 sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
14396 fi~
14397 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
14398 linknames='
14740 archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
14741 archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
14742 cp "$export_symbols" "$output_objdir/$soname.def";
14743 echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
14744 else
14745 $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
14746 fi~
14747 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
14748 linknames='
1439914749 # The linker will not automatically build a static lib if we build a DLL.
1440014750 # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
1440114751 enable_shared_with_static_runtimes=yes
1440414754 # Don't use ranlib
1440514755 old_postinstall_cmds='chmod 644 $oldlib'
1440614756 postlink_cmds='lt_outputfile="@OUTPUT@"~
14407 lt_tool_outputfile="@TOOL_OUTPUT@"~
14408 case $lt_outputfile in
14409 *.exe|*.EXE) ;;
14410 *)
14411 lt_outputfile="$lt_outputfile.exe"
14412 lt_tool_outputfile="$lt_tool_outputfile.exe"
14413 ;;
14414 esac~
14415 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
14416 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
14417 $RM "$lt_outputfile.manifest";
14418 fi'
14757 lt_tool_outputfile="@TOOL_OUTPUT@"~
14758 case $lt_outputfile in
14759 *.exe|*.EXE) ;;
14760 *)
14761 lt_outputfile=$lt_outputfile.exe
14762 lt_tool_outputfile=$lt_tool_outputfile.exe
14763 ;;
14764 esac~
14765 if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
14766 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
14767 $RM "$lt_outputfile.manifest";
14768 fi'
1441914769 ;;
1442014770 *)
1442114771 # Assume MSVC wrapper
1442414774 # Tell ltmain to make .lib files, not .a files.
1442514775 libext=lib
1442614776 # Tell ltmain to make .dll files, not .so files.
14427 shrext_cmds=".dll"
14777 shrext_cmds=.dll
1442814778 # FIXME: Setting linknames here is a bad hack.
1442914779 archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
1443014780 # The linker will automatically build a .lib file if we build a DLL.
1444314793 hardcode_direct=no
1444414794 hardcode_automatic=yes
1444514795 hardcode_shlibpath_var=unsupported
14446 if test "$lt_cv_ld_force_load" = "yes"; then
14447 whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
14796 if test yes = "$lt_cv_ld_force_load"; then
14797 whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
1444814798
1444914799 else
1445014800 whole_archive_flag_spec=''
1445114801 fi
1445214802 link_all_deplibs=yes
14453 allow_undefined_flag="$_lt_dar_allow_undefined"
14803 allow_undefined_flag=$_lt_dar_allow_undefined
1445414804 case $cc_basename in
14455 ifort*) _lt_dar_can_shared=yes ;;
14805 ifort*|nagfor*) _lt_dar_can_shared=yes ;;
1445614806 *) _lt_dar_can_shared=$GCC ;;
1445714807 esac
14458 if test "$_lt_dar_can_shared" = "yes"; then
14808 if test yes = "$_lt_dar_can_shared"; then
1445914809 output_verbose_link_cmd=func_echo_all
14460 archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
14461 module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
14462 archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
14463 module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
14810 archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
14811 module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
14812 archive_expsym_cmds="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil"
14813 module_expsym_cmds="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil"
1446414814
1446514815 else
1446614816 ld_shlibs=no
1450214852 ;;
1450314853
1450414854 hpux9*)
14505 if test "$GCC" = yes; then
14506 archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
14855 if test yes = "$GCC"; then
14856 archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
1450714857 else
14508 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
14858 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
1450914859 fi
14510 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
14860 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
1451114861 hardcode_libdir_separator=:
1451214862 hardcode_direct=yes
1451314863
1451414864 # hardcode_minus_L: Not really in the search PATH,
1451514865 # but as the default location of the library.
1451614866 hardcode_minus_L=yes
14517 export_dynamic_flag_spec='${wl}-E'
14867 export_dynamic_flag_spec='$wl-E'
1451814868 ;;
1451914869
1452014870 hpux10*)
14521 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
14522 archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
14871 if test yes,no = "$GCC,$with_gnu_ld"; then
14872 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
1452314873 else
1452414874 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
1452514875 fi
14526 if test "$with_gnu_ld" = no; then
14527 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
14876 if test no = "$with_gnu_ld"; then
14877 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
1452814878 hardcode_libdir_separator=:
1452914879 hardcode_direct=yes
1453014880 hardcode_direct_absolute=yes
14531 export_dynamic_flag_spec='${wl}-E'
14881 export_dynamic_flag_spec='$wl-E'
1453214882 # hardcode_minus_L: Not really in the search PATH,
1453314883 # but as the default location of the library.
1453414884 hardcode_minus_L=yes
1453614886 ;;
1453714887
1453814888 hpux11*)
14539 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
14889 if test yes,no = "$GCC,$with_gnu_ld"; then
1454014890 case $host_cpu in
1454114891 hppa*64*)
14542 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
14892 archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
1454314893 ;;
1454414894 ia64*)
14545 archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
14895 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
1454614896 ;;
1454714897 *)
14548 archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
14898 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
1454914899 ;;
1455014900 esac
1455114901 else
1455214902 case $host_cpu in
1455314903 hppa*64*)
14554 archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
14904 archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
1455514905 ;;
1455614906 ia64*)
14557 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
14907 archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
1455814908 ;;
1455914909 *)
1456014910
1456614916 $as_echo_n "(cached) " >&6
1456714917 else
1456814918 lt_cv_prog_compiler__b=no
14569 save_LDFLAGS="$LDFLAGS"
14919 save_LDFLAGS=$LDFLAGS
1457014920 LDFLAGS="$LDFLAGS -b"
1457114921 echo "$lt_simple_link_test_code" > conftest.$ac_ext
1457214922 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1458514935 fi
1458614936 fi
1458714937 $RM -r conftest*
14588 LDFLAGS="$save_LDFLAGS"
14938 LDFLAGS=$save_LDFLAGS
1458914939
1459014940 fi
1459114941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
1459214942 $as_echo "$lt_cv_prog_compiler__b" >&6; }
1459314943
14594 if test x"$lt_cv_prog_compiler__b" = xyes; then
14595 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
14944 if test yes = "$lt_cv_prog_compiler__b"; then
14945 archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
1459614946 else
1459714947 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
1459814948 fi
1460014950 ;;
1460114951 esac
1460214952 fi
14603 if test "$with_gnu_ld" = no; then
14604 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
14953 if test no = "$with_gnu_ld"; then
14954 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
1460514955 hardcode_libdir_separator=:
1460614956
1460714957 case $host_cpu in
1461214962 *)
1461314963 hardcode_direct=yes
1461414964 hardcode_direct_absolute=yes
14615 export_dynamic_flag_spec='${wl}-E'
14965 export_dynamic_flag_spec='$wl-E'
1461614966
1461714967 # hardcode_minus_L: Not really in the search PATH,
1461814968 # but as the default location of the library.
1462314973 ;;
1462414974
1462514975 irix5* | irix6* | nonstopux*)
14626 if test "$GCC" = yes; then
14627 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
14976 if test yes = "$GCC"; then
14977 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
1462814978 # Try to use the -exported_symbol ld option, if it does not
1462914979 # work, assume that -exports_file does not work either and
1463014980 # implicitly export all symbols.
1463414984 if ${lt_cv_irix_exported_symbol+:} false; then :
1463514985 $as_echo_n "(cached) " >&6
1463614986 else
14637 save_LDFLAGS="$LDFLAGS"
14638 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
14987 save_LDFLAGS=$LDFLAGS
14988 LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
1463914989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1464014990 /* end confdefs.h. */
1464114991 int foo (void) { return 0; }
1464714997 fi
1464814998 rm -f core conftest.err conftest.$ac_objext \
1464914999 conftest$ac_exeext conftest.$ac_ext
14650 LDFLAGS="$save_LDFLAGS"
15000 LDFLAGS=$save_LDFLAGS
1465115001 fi
1465215002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
1465315003 $as_echo "$lt_cv_irix_exported_symbol" >&6; }
14654 if test "$lt_cv_irix_exported_symbol" = yes; then
14655 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
15004 if test yes = "$lt_cv_irix_exported_symbol"; then
15005 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
1465615006 fi
1465715007 else
14658 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
14659 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
15008 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
15009 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib'
1466015010 fi
1466115011 archive_cmds_need_lc='no'
14662 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
15012 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
1466315013 hardcode_libdir_separator=:
1466415014 inherit_rpath=yes
1466515015 link_all_deplibs=yes
1466615016 ;;
1466715017
14668 netbsd* | netbsdelf*-gnu)
15018 linux*)
15019 case $cc_basename in
15020 tcc*)
15021 # Fabrice Bellard et al's Tiny C Compiler
15022 ld_shlibs=yes
15023 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
15024 ;;
15025 esac
15026 ;;
15027
15028 netbsd*)
1466915029 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
1467015030 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
1467115031 else
1467915039 newsos6)
1468015040 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
1468115041 hardcode_direct=yes
14682 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
15042 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
1468315043 hardcode_libdir_separator=:
1468415044 hardcode_shlibpath_var=no
1468515045 ;;
1468715047 *nto* | *qnx*)
1468815048 ;;
1468915049
14690 openbsd*)
15050 openbsd* | bitrig*)
1469115051 if test -f /usr/libexec/ld.so; then
1469215052 hardcode_direct=yes
1469315053 hardcode_shlibpath_var=no
1469415054 hardcode_direct_absolute=yes
14695 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
15055 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
1469615056 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
14697 archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
14698 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
14699 export_dynamic_flag_spec='${wl}-E'
15057 archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
15058 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
15059 export_dynamic_flag_spec='$wl-E'
1470015060 else
14701 case $host_os in
14702 openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
14703 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
14704 hardcode_libdir_flag_spec='-R$libdir'
14705 ;;
14706 *)
14707 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
14708 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
14709 ;;
14710 esac
15061 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
15062 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
1471115063 fi
1471215064 else
1471315065 ld_shlibs=no
1471815070 hardcode_libdir_flag_spec='-L$libdir'
1471915071 hardcode_minus_L=yes
1472015072 allow_undefined_flag=unsupported
14721 archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
14722 old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
15073 shrext_cmds=.dll
15074 archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
15075 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
15076 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
15077 $ECHO EXPORTS >> $output_objdir/$libname.def~
15078 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
15079 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
15080 emximp -o $lib $output_objdir/$libname.def'
15081 archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
15082 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
15083 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
15084 $ECHO EXPORTS >> $output_objdir/$libname.def~
15085 prefix_cmds="$SED"~
15086 if test EXPORTS = "`$SED 1q $export_symbols`"; then
15087 prefix_cmds="$prefix_cmds -e 1d";
15088 fi~
15089 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
15090 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
15091 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
15092 emximp -o $lib $output_objdir/$libname.def'
15093 old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
15094 enable_shared_with_static_runtimes=yes
1472315095 ;;
1472415096
1472515097 osf3*)
14726 if test "$GCC" = yes; then
14727 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
14728 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
15098 if test yes = "$GCC"; then
15099 allow_undefined_flag=' $wl-expect_unresolved $wl\*'
15100 archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
1472915101 else
1473015102 allow_undefined_flag=' -expect_unresolved \*'
14731 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
15103 archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
1473215104 fi
1473315105 archive_cmds_need_lc='no'
14734 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
15106 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
1473515107 hardcode_libdir_separator=:
1473615108 ;;
1473715109
1473815110 osf4* | osf5*) # as osf3* with the addition of -msym flag
14739 if test "$GCC" = yes; then
14740 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
14741 archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
14742 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
15111 if test yes = "$GCC"; then
15112 allow_undefined_flag=' $wl-expect_unresolved $wl\*'
15113 archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
15114 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
1474315115 else
1474415116 allow_undefined_flag=' -expect_unresolved \*'
14745 archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
15117 archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
1474615118 archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
14747 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
15119 $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp'
1474815120
1474915121 # Both c and cxx compiler support -rpath directly
1475015122 hardcode_libdir_flag_spec='-rpath $libdir'
1475515127
1475615128 solaris*)
1475715129 no_undefined_flag=' -z defs'
14758 if test "$GCC" = yes; then
14759 wlarc='${wl}'
14760 archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
15130 if test yes = "$GCC"; then
15131 wlarc='$wl'
15132 archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
1476115133 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
14762 $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
15134 $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
1476315135 else
1476415136 case `$CC -V 2>&1` in
1476515137 *"Compilers 5.0"*)
1476615138 wlarc=''
14767 archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
15139 archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
1476815140 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
14769 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
15141 $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
1477015142 ;;
1477115143 *)
14772 wlarc='${wl}'
14773 archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
15144 wlarc='$wl'
15145 archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
1477415146 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
14775 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
15147 $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
1477615148 ;;
1477715149 esac
1477815150 fi
1478215154 solaris2.[0-5] | solaris2.[0-5].*) ;;
1478315155 *)
1478415156 # The compiler driver will combine and reorder linker options,
14785 # but understands `-z linker_flag'. GCC discards it without `$wl',
15157 # but understands '-z linker_flag'. GCC discards it without '$wl',
1478615158 # but is careful enough not to reorder.
1478715159 # Supported since Solaris 2.6 (maybe 2.5.1?)
14788 if test "$GCC" = yes; then
14789 whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
15160 if test yes = "$GCC"; then
15161 whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
1479015162 else
1479115163 whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
1479215164 fi
1479615168 ;;
1479715169
1479815170 sunos4*)
14799 if test "x$host_vendor" = xsequent; then
15171 if test sequent = "$host_vendor"; then
1480015172 # Use $CC to link under sequent, because it throws in some extra .o
1480115173 # files that make .init and .fini sections work.
14802 archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
15174 archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
1480315175 else
1480415176 archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
1480515177 fi
1484815220 ;;
1484915221
1485015222 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
14851 no_undefined_flag='${wl}-z,text'
15223 no_undefined_flag='$wl-z,text'
1485215224 archive_cmds_need_lc=no
1485315225 hardcode_shlibpath_var=no
1485415226 runpath_var='LD_RUN_PATH'
1485515227
14856 if test "$GCC" = yes; then
14857 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
14858 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15228 if test yes = "$GCC"; then
15229 archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15230 archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1485915231 else
14860 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
14861 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15232 archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15233 archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1486215234 fi
1486315235 ;;
1486415236
1486515237 sysv5* | sco3.2v5* | sco5v6*)
14866 # Note: We can NOT use -z defs as we might desire, because we do not
15238 # Note: We CANNOT use -z defs as we might desire, because we do not
1486715239 # link with -lc, and that would cause any symbols used from libc to
1486815240 # always be unresolved, which means just about no library would
1486915241 # ever link correctly. If we're not using GNU ld we use -z text
1487015242 # though, which does catch some bad symbols but isn't as heavy-handed
1487115243 # as -z defs.
14872 no_undefined_flag='${wl}-z,text'
14873 allow_undefined_flag='${wl}-z,nodefs'
15244 no_undefined_flag='$wl-z,text'
15245 allow_undefined_flag='$wl-z,nodefs'
1487415246 archive_cmds_need_lc=no
1487515247 hardcode_shlibpath_var=no
14876 hardcode_libdir_flag_spec='${wl}-R,$libdir'
15248 hardcode_libdir_flag_spec='$wl-R,$libdir'
1487715249 hardcode_libdir_separator=':'
1487815250 link_all_deplibs=yes
14879 export_dynamic_flag_spec='${wl}-Bexport'
15251 export_dynamic_flag_spec='$wl-Bexport'
1488015252 runpath_var='LD_RUN_PATH'
1488115253
14882 if test "$GCC" = yes; then
14883 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
14884 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15254 if test yes = "$GCC"; then
15255 archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15256 archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1488515257 else
14886 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
14887 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15258 archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
15259 archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1488815260 fi
1488915261 ;;
1489015262
1489915271 ;;
1490015272 esac
1490115273
14902 if test x$host_vendor = xsni; then
15274 if test sni = "$host_vendor"; then
1490315275 case $host in
1490415276 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
14905 export_dynamic_flag_spec='${wl}-Blargedynsym'
15277 export_dynamic_flag_spec='$wl-Blargedynsym'
1490615278 ;;
1490715279 esac
1490815280 fi
1491015282
1491115283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
1491215284 $as_echo "$ld_shlibs" >&6; }
14913 test "$ld_shlibs" = no && can_build_shared=no
15285 test no = "$ld_shlibs" && can_build_shared=no
1491415286
1491515287 with_gnu_ld=$with_gnu_ld
1491615288
1493615308 # Assume -lc should be added
1493715309 archive_cmds_need_lc=yes
1493815310
14939 if test "$enable_shared" = yes && test "$GCC" = yes; then
15311 if test yes,yes = "$GCC,$enable_shared"; then
1494015312 case $archive_cmds in
1494115313 *'~'*)
1494215314 # FIXME: we may have to deal with multi-command sequences.
1515115523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
1515215524 $as_echo_n "checking dynamic linker characteristics... " >&6; }
1515315525
15154 if test "$GCC" = yes; then
15526 if test yes = "$GCC"; then
1515515527 case $host_os in
15156 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
15157 *) lt_awk_arg="/^libraries:/" ;;
15528 darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
15529 *) lt_awk_arg='/^libraries:/' ;;
1515815530 esac
1515915531 case $host_os in
15160 mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
15161 *) lt_sed_strip_eq="s,=/,/,g" ;;
15532 mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;;
15533 *) lt_sed_strip_eq='s|=/|/|g' ;;
1516215534 esac
1516315535 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
1516415536 case $lt_search_path_spec in
1517415546 ;;
1517515547 esac
1517615548 # Ok, now we have the path, separated by spaces, we can step through it
15177 # and add multilib dir if necessary.
15549 # and add multilib dir if necessary...
1517815550 lt_tmp_lt_search_path_spec=
15179 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
15551 lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
15552 # ...but if some path component already ends with the multilib dir we assume
15553 # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
15554 case "$lt_multi_os_dir; $lt_search_path_spec " in
15555 "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
15556 lt_multi_os_dir=
15557 ;;
15558 esac
1518015559 for lt_sys_path in $lt_search_path_spec; do
15181 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
15182 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
15183 else
15560 if test -d "$lt_sys_path$lt_multi_os_dir"; then
15561 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
15562 elif test -n "$lt_multi_os_dir"; then
1518415563 test -d "$lt_sys_path" && \
1518515564 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
1518615565 fi
1518715566 done
1518815567 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
15189 BEGIN {RS=" "; FS="/|\n";} {
15190 lt_foo="";
15191 lt_count=0;
15568 BEGIN {RS = " "; FS = "/|\n";} {
15569 lt_foo = "";
15570 lt_count = 0;
1519215571 for (lt_i = NF; lt_i > 0; lt_i--) {
1519315572 if ($lt_i != "" && $lt_i != ".") {
1519415573 if ($lt_i == "..") {
1519515574 lt_count++;
1519615575 } else {
1519715576 if (lt_count == 0) {
15198 lt_foo="/" $lt_i lt_foo;
15577 lt_foo = "/" $lt_i lt_foo;
1519915578 } else {
1520015579 lt_count--;
1520115580 }
1520915588 # for these hosts.
1521015589 case $host_os in
1521115590 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
15212 $SED 's,/\([A-Za-z]:\),\1,g'` ;;
15591 $SED 's|/\([A-Za-z]:\)|\1|g'` ;;
1521315592 esac
1521415593 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
1521515594 else
1521815597 library_names_spec=
1521915598 libname_spec='lib$name'
1522015599 soname_spec=
15221 shrext_cmds=".so"
15600 shrext_cmds=.so
1522215601 postinstall_cmds=
1522315602 postuninstall_cmds=
1522415603 finish_cmds=
1523515614 # flags to be left without arguments
1523615615 need_version=unknown
1523715616
15617
15618
1523815619 case $host_os in
1523915620 aix3*)
1524015621 version_type=linux # correct to gnu/linux during the next big refactor
15241 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
15622 library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
1524215623 shlibpath_var=LIBPATH
1524315624
1524415625 # AIX 3 has no versioning support, so we append a major version to the name.
15245 soname_spec='${libname}${release}${shared_ext}$major'
15626 soname_spec='$libname$release$shared_ext$major'
1524615627 ;;
1524715628
1524815629 aix[4-9]*)
1525015631 need_lib_prefix=no
1525115632 need_version=no
1525215633 hardcode_into_libs=yes
15253 if test "$host_cpu" = ia64; then
15634 if test ia64 = "$host_cpu"; then
1525415635 # AIX 5 supports IA64
15255 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
15636 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
1525615637 shlibpath_var=LD_LIBRARY_PATH
1525715638 else
1525815639 # With GCC up to 2.95.x, collect2 would create an import file
1525915640 # for dependence libraries. The import file would start with
15260 # the line `#! .'. This would cause the generated library to
15261 # depend on `.', always an invalid library. This was fixed in
15641 # the line '#! .'. This would cause the generated library to
15642 # depend on '.', always an invalid library. This was fixed in
1526215643 # development snapshots of GCC prior to 3.0.
1526315644 case $host_os in
1526415645 aix4 | aix4.[01] | aix4.[01].*)
1526515646 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
1526615647 echo ' yes '
15267 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
15648 echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
1526815649 :
1526915650 else
1527015651 can_build_shared=no
1527115652 fi
1527215653 ;;
1527315654 esac
15274 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
15655 # Using Import Files as archive members, it is possible to support
15656 # filename-based versioning of shared library archives on AIX. While
15657 # this would work for both with and without runtime linking, it will
15658 # prevent static linking of such archives. So we do filename-based
15659 # shared library versioning with .so extension only, which is used
15660 # when both runtime linking and shared linking is enabled.
15661 # Unfortunately, runtime linking may impact performance, so we do
15662 # not want this to be the default eventually. Also, we use the
15663 # versioned .so libs for executables only if there is the -brtl
15664 # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
15665 # To allow for filename-based versioning support, we need to create
15666 # libNAME.so.V as an archive file, containing:
15667 # *) an Import File, referring to the versioned filename of the
15668 # archive as well as the shared archive member, telling the
15669 # bitwidth (32 or 64) of that shared object, and providing the
15670 # list of exported symbols of that shared object, eventually
15671 # decorated with the 'weak' keyword
15672 # *) the shared object with the F_LOADONLY flag set, to really avoid
15673 # it being seen by the linker.
15674 # At run time we better use the real file rather than another symlink,
15675 # but for link time we create the symlink libNAME.so -> libNAME.so.V
15676
15677 case $with_aix_soname,$aix_use_runtimelinking in
15678 # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
1527515679 # soname into executable. Probably we can add versioning support to
1527615680 # collect2, so additional links can be useful in future.
15277 if test "$aix_use_runtimelinking" = yes; then
15681 aix,yes) # traditional libtool
15682 dynamic_linker='AIX unversionable lib.so'
1527815683 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
1527915684 # instead of lib<name>.a to let people know that these are not
1528015685 # typical AIX shared libraries.
15281 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15282 else
15686 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
15687 ;;
15688 aix,no) # traditional AIX only
15689 dynamic_linker='AIX lib.a(lib.so.V)'
1528315690 # We preserve .a as extension for shared libraries through AIX4.2
1528415691 # and later when we are not doing run time linking.
15285 library_names_spec='${libname}${release}.a $libname.a'
15286 soname_spec='${libname}${release}${shared_ext}$major'
15287 fi
15692 library_names_spec='$libname$release.a $libname.a'
15693 soname_spec='$libname$release$shared_ext$major'
15694 ;;
15695 svr4,*) # full svr4 only
15696 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
15697 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
15698 # We do not specify a path in Import Files, so LIBPATH fires.
15699 shlibpath_overrides_runpath=yes
15700 ;;
15701 *,yes) # both, prefer svr4
15702 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
15703 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
15704 # unpreferred sharedlib libNAME.a needs extra handling
15705 postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"'
15706 postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"'
15707 # We do not specify a path in Import Files, so LIBPATH fires.
15708 shlibpath_overrides_runpath=yes
15709 ;;
15710 *,no) # both, prefer aix
15711 dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
15712 library_names_spec='$libname$release.a $libname.a'
15713 soname_spec='$libname$release$shared_ext$major'
15714 # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
15715 postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)'
15716 postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"'
15717 ;;
15718 esac
1528815719 shlibpath_var=LIBPATH
1528915720 fi
1529015721 ;;
1529415725 powerpc)
1529515726 # Since July 2007 AmigaOS4 officially supports .so libraries.
1529615727 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
15297 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15728 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
1529815729 ;;
1529915730 m68k)
1530015731 library_names_spec='$libname.ixlibrary $libname.a'
1530115732 # Create ${libname}_ixlibrary.a entries in /sys/libs.
15302 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
15733 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
1530315734 ;;
1530415735 esac
1530515736 ;;
1530615737
1530715738 beos*)
15308 library_names_spec='${libname}${shared_ext}'
15739 library_names_spec='$libname$shared_ext'
1530915740 dynamic_linker="$host_os ld.so"
1531015741 shlibpath_var=LIBRARY_PATH
1531115742 ;;
1531315744 bsdi[45]*)
1531415745 version_type=linux # correct to gnu/linux during the next big refactor
1531515746 need_version=no
15316 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15317 soname_spec='${libname}${release}${shared_ext}$major'
15747 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
15748 soname_spec='$libname$release$shared_ext$major'
1531815749 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
1531915750 shlibpath_var=LD_LIBRARY_PATH
1532015751 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
1532615757
1532715758 cygwin* | mingw* | pw32* | cegcc*)
1532815759 version_type=windows
15329 shrext_cmds=".dll"
15760 shrext_cmds=.dll
1533015761 need_version=no
1533115762 need_lib_prefix=no
1533215763
1533515766 # gcc
1533615767 library_names_spec='$libname.dll.a'
1533715768 # DLL is installed to $(libdir)/../bin by postinstall_cmds
15338 postinstall_cmds='base_file=`basename \${file}`~
15339 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
15769 postinstall_cmds='base_file=`basename \$file`~
15770 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
1534015771 dldir=$destdir/`dirname \$dlpath`~
1534115772 test -d \$dldir || mkdir -p \$dldir~
1534215773 $install_prog $dir/$dlname \$dldir/$dlname~
1535215783 case $host_os in
1535315784 cygwin*)
1535415785 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
15355 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
15786 soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
1535615787
1535715788 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
1535815789 ;;
1535915790 mingw* | cegcc*)
1536015791 # MinGW DLLs use traditional 'lib' prefix
15361 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
15792 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
1536215793 ;;
1536315794 pw32*)
1536415795 # pw32 DLLs use 'pw' prefix rather than 'lib'
15365 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
15796 library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
1536615797 ;;
1536715798 esac
1536815799 dynamic_linker='Win32 ld.exe'
1537115802 *,cl*)
1537215803 # Native MSVC
1537315804 libname_spec='$name'
15374 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
15375 library_names_spec='${libname}.dll.lib'
15805 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
15806 library_names_spec='$libname.dll.lib'
1537615807
1537715808 case $build_os in
1537815809 mingw*)
1539915830 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
1540015831 ;;
1540115832 *)
15402 sys_lib_search_path_spec="$LIB"
15833 sys_lib_search_path_spec=$LIB
1540315834 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
1540415835 # It is most probably a Windows format PATH.
1540515836 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
1541215843 esac
1541315844
1541415845 # DLL is installed to $(libdir)/../bin by postinstall_cmds
15415 postinstall_cmds='base_file=`basename \${file}`~
15416 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
15846 postinstall_cmds='base_file=`basename \$file`~
15847 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
1541715848 dldir=$destdir/`dirname \$dlpath`~
1541815849 test -d \$dldir || mkdir -p \$dldir~
1541915850 $install_prog $dir/$dlname \$dldir/$dlname'
1542615857
1542715858 *)
1542815859 # Assume MSVC wrapper
15429 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
15860 library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
1543015861 dynamic_linker='Win32 ld.exe'
1543115862 ;;
1543215863 esac
1543915870 version_type=darwin
1544015871 need_lib_prefix=no
1544115872 need_version=no
15442 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
15443 soname_spec='${libname}${release}${major}$shared_ext'
15873 library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
15874 soname_spec='$libname$release$major$shared_ext'
1544415875 shlibpath_overrides_runpath=yes
1544515876 shlibpath_var=DYLD_LIBRARY_PATH
1544615877 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
1545315884 version_type=linux # correct to gnu/linux during the next big refactor
1545415885 need_lib_prefix=no
1545515886 need_version=no
15456 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
15457 soname_spec='${libname}${release}${shared_ext}$major'
15887 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
15888 soname_spec='$libname$release$shared_ext$major'
1545815889 shlibpath_var=LD_LIBRARY_PATH
1545915890 ;;
1546015891
1547215903 version_type=freebsd-$objformat
1547315904 case $version_type in
1547415905 freebsd-elf*)
15475 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
15906 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
15907 soname_spec='$libname$release$shared_ext$major'
1547615908 need_version=no
1547715909 need_lib_prefix=no
1547815910 ;;
1547915911 freebsd-*)
15480 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
15912 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
1548115913 need_version=yes
1548215914 ;;
1548315915 esac
1550715939 need_lib_prefix=no
1550815940 need_version=no
1550915941 dynamic_linker="$host_os runtime_loader"
15510 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
15511 soname_spec='${libname}${release}${shared_ext}$major'
15942 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
15943 soname_spec='$libname$release$shared_ext$major'
1551215944 shlibpath_var=LIBRARY_PATH
15513 shlibpath_overrides_runpath=yes
15945 shlibpath_overrides_runpath=no
1551415946 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
1551515947 hardcode_into_libs=yes
1551615948 ;;
1552815960 dynamic_linker="$host_os dld.so"
1552915961 shlibpath_var=LD_LIBRARY_PATH
1553015962 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
15531 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15532 soname_spec='${libname}${release}${shared_ext}$major'
15533 if test "X$HPUX_IA64_MODE" = X32; then
15963 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
15964 soname_spec='$libname$release$shared_ext$major'
15965 if test 32 = "$HPUX_IA64_MODE"; then
1553415966 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
15967 sys_lib_dlsearch_path_spec=/usr/lib/hpux32
1553515968 else
1553615969 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
15970 sys_lib_dlsearch_path_spec=/usr/lib/hpux64
1553715971 fi
15538 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1553915972 ;;
1554015973 hppa*64*)
1554115974 shrext_cmds='.sl'
1554315976 dynamic_linker="$host_os dld.sl"
1554415977 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
1554515978 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
15546 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15547 soname_spec='${libname}${release}${shared_ext}$major'
15979 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
15980 soname_spec='$libname$release$shared_ext$major'
1554815981 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
1554915982 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1555015983 ;;
1555315986 dynamic_linker="$host_os dld.sl"
1555415987 shlibpath_var=SHLIB_PATH
1555515988 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
15556 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15557 soname_spec='${libname}${release}${shared_ext}$major'
15989 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
15990 soname_spec='$libname$release$shared_ext$major'
1555815991 ;;
1555915992 esac
1556015993 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
1556716000 version_type=linux # correct to gnu/linux during the next big refactor
1556816001 need_lib_prefix=no
1556916002 need_version=no
15570 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
15571 soname_spec='${libname}${release}${shared_ext}$major'
16003 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
16004 soname_spec='$libname$release$shared_ext$major'
1557216005 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
1557316006 shlibpath_var=LD_LIBRARY_PATH
1557416007 shlibpath_overrides_runpath=no
1557916012 case $host_os in
1558016013 nonstopux*) version_type=nonstopux ;;
1558116014 *)
15582 if test "$lt_cv_prog_gnu_ld" = yes; then
16015 if test yes = "$lt_cv_prog_gnu_ld"; then
1558316016 version_type=linux # correct to gnu/linux during the next big refactor
1558416017 else
1558516018 version_type=irix
1558716020 esac
1558816021 need_lib_prefix=no
1558916022 need_version=no
15590 soname_spec='${libname}${release}${shared_ext}$major'
15591 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
16023 soname_spec='$libname$release$shared_ext$major'
16024 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
1559216025 case $host_os in
1559316026 irix5* | nonstopux*)
1559416027 libsuff= shlibsuff=
1560716040 esac
1560816041 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
1560916042 shlibpath_overrides_runpath=no
15610 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
15611 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
16043 sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
16044 sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
1561216045 hardcode_into_libs=yes
1561316046 ;;
1561416047
1561516048 # No shared lib support for Linux oldld, aout, or coff.
1561616049 linux*oldld* | linux*aout* | linux*coff*)
1561716050 dynamic_linker=no
16051 ;;
16052
16053 linux*android*)
16054 version_type=none # Android doesn't support versioned libraries.
16055 need_lib_prefix=no
16056 need_version=no
16057 library_names_spec='$libname$release$shared_ext'
16058 soname_spec='$libname$release$shared_ext'
16059 finish_cmds=
16060 shlibpath_var=LD_LIBRARY_PATH
16061 shlibpath_overrides_runpath=yes
16062
16063 # This implies no fast_install, which is unacceptable.
16064 # Some rework will be needed to allow for fast_install
16065 # before this can be enabled.
16066 hardcode_into_libs=yes
16067
16068 dynamic_linker='Android linker'
16069 # Don't embed -rpath directories since the linker doesn't support them.
16070 hardcode_libdir_flag_spec='-L$libdir'
1561816071 ;;
1561916072
1562016073 # This must be glibc/ELF.
1562216075 version_type=linux # correct to gnu/linux during the next big refactor
1562316076 need_lib_prefix=no
1562416077 need_version=no
15625 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15626 soname_spec='${libname}${release}${shared_ext}$major'
16078 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
16079 soname_spec='$libname$release$shared_ext$major'
1562716080 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
1562816081 shlibpath_var=LD_LIBRARY_PATH
1562916082 shlibpath_overrides_runpath=no
1567516128 # before this can be enabled.
1567616129 hardcode_into_libs=yes
1567716130
15678 # Append ld.so.conf contents to the search path
16131 # Ideally, we could use ldconfig to report *all* directores which are
16132 # searched for libraries, however this is still not possible. Aside from not
16133 # being certain /sbin/ldconfig is available, command
16134 # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
16135 # even though it is searched at run-time. Try to do the best guess by
16136 # appending ld.so.conf contents (and includes) to the search path.
1567916137 if test -f /etc/ld.so.conf; then
1568016138 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
1568116139 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
1569016148 dynamic_linker='GNU/Linux ld.so'
1569116149 ;;
1569216150
15693 netbsdelf*-gnu)
15694 version_type=linux
15695 need_lib_prefix=no
15696 need_version=no
15697 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
15698 soname_spec='${libname}${release}${shared_ext}$major'
15699 shlibpath_var=LD_LIBRARY_PATH
15700 shlibpath_overrides_runpath=no
15701 hardcode_into_libs=yes
15702 dynamic_linker='NetBSD ld.elf_so'
15703 ;;
15704
1570516151 netbsd*)
1570616152 version_type=sunos
1570716153 need_lib_prefix=no
1570816154 need_version=no
1570916155 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
15710 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
16156 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
1571116157 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
1571216158 dynamic_linker='NetBSD (a.out) ld.so'
1571316159 else
15714 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
15715 soname_spec='${libname}${release}${shared_ext}$major'
16160 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
16161 soname_spec='$libname$release$shared_ext$major'
1571616162 dynamic_linker='NetBSD ld.elf_so'
1571716163 fi
1571816164 shlibpath_var=LD_LIBRARY_PATH
1572216168
1572316169 newsos6)
1572416170 version_type=linux # correct to gnu/linux during the next big refactor
15725 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16171 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
1572616172 shlibpath_var=LD_LIBRARY_PATH
1572716173 shlibpath_overrides_runpath=yes
1572816174 ;;
1573116177 version_type=qnx
1573216178 need_lib_prefix=no
1573316179 need_version=no
15734 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15735 soname_spec='${libname}${release}${shared_ext}$major'
16180 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
16181 soname_spec='$libname$release$shared_ext$major'
1573616182 shlibpath_var=LD_LIBRARY_PATH
1573716183 shlibpath_overrides_runpath=no
1573816184 hardcode_into_libs=yes
1573916185 dynamic_linker='ldqnx.so'
1574016186 ;;
1574116187
15742 openbsd*)
16188 openbsd* | bitrig*)
1574316189 version_type=sunos
15744 sys_lib_dlsearch_path_spec="/usr/lib"
16190 sys_lib_dlsearch_path_spec=/usr/lib
1574516191 need_lib_prefix=no
15746 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
15747 case $host_os in
15748 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
15749 *) need_version=no ;;
15750 esac
15751 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
16192 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
16193 need_version=no
16194 else
16195 need_version=yes
16196 fi
16197 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
1575216198 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
1575316199 shlibpath_var=LD_LIBRARY_PATH
15754 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
15755 case $host_os in
15756 openbsd2.[89] | openbsd2.[89].*)
15757 shlibpath_overrides_runpath=no
15758 ;;
15759 *)
15760 shlibpath_overrides_runpath=yes
15761 ;;
15762 esac
15763 else
15764 shlibpath_overrides_runpath=yes
15765 fi
16200 shlibpath_overrides_runpath=yes
1576616201 ;;
1576716202
1576816203 os2*)
1576916204 libname_spec='$name'
15770 shrext_cmds=".dll"
16205 version_type=windows
16206 shrext_cmds=.dll
16207 need_version=no
1577116208 need_lib_prefix=no
15772 library_names_spec='$libname${shared_ext} $libname.a'
16209 # OS/2 can only load a DLL with a base name of 8 characters or less.
16210 soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
16211 v=$($ECHO $release$versuffix | tr -d .-);
16212 n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
16213 $ECHO $n$v`$shared_ext'
16214 library_names_spec='${libname}_dll.$libext'
1577316215 dynamic_linker='OS/2 ld.exe'
15774 shlibpath_var=LIBPATH
16216 shlibpath_var=BEGINLIBPATH
16217 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
16218 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
16219 postinstall_cmds='base_file=`basename \$file`~
16220 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
16221 dldir=$destdir/`dirname \$dlpath`~
16222 test -d \$dldir || mkdir -p \$dldir~
16223 $install_prog $dir/$dlname \$dldir/$dlname~
16224 chmod a+x \$dldir/$dlname~
16225 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
16226 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
16227 fi'
16228 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
16229 dlpath=$dir/\$dldll~
16230 $RM \$dlpath'
1577516231 ;;
1577616232
1577716233 osf3* | osf4* | osf5*)
1577816234 version_type=osf
1577916235 need_lib_prefix=no
1578016236 need_version=no
15781 soname_spec='${libname}${release}${shared_ext}$major'
15782 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16237 soname_spec='$libname$release$shared_ext$major'
16238 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
1578316239 shlibpath_var=LD_LIBRARY_PATH
1578416240 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
15785 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
16241 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1578616242 ;;
1578716243
1578816244 rdos*)
1579316249 version_type=linux # correct to gnu/linux during the next big refactor
1579416250 need_lib_prefix=no
1579516251 need_version=no
15796 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15797 soname_spec='${libname}${release}${shared_ext}$major'
16252 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
16253 soname_spec='$libname$release$shared_ext$major'
1579816254 shlibpath_var=LD_LIBRARY_PATH
1579916255 shlibpath_overrides_runpath=yes
1580016256 hardcode_into_libs=yes
1580416260
1580516261 sunos4*)
1580616262 version_type=sunos
15807 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
16263 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
1580816264 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
1580916265 shlibpath_var=LD_LIBRARY_PATH
1581016266 shlibpath_overrides_runpath=yes
15811 if test "$with_gnu_ld" = yes; then
16267 if test yes = "$with_gnu_ld"; then
1581216268 need_lib_prefix=no
1581316269 fi
1581416270 need_version=yes
1581616272
1581716273 sysv4 | sysv4.3*)
1581816274 version_type=linux # correct to gnu/linux during the next big refactor
15819 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15820 soname_spec='${libname}${release}${shared_ext}$major'
16275 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
16276 soname_spec='$libname$release$shared_ext$major'
1582116277 shlibpath_var=LD_LIBRARY_PATH
1582216278 case $host_vendor in
1582316279 sni)
1583816294 ;;
1583916295
1584016296 sysv4*MP*)
15841 if test -d /usr/nec ;then
16297 if test -d /usr/nec; then
1584216298 version_type=linux # correct to gnu/linux during the next big refactor
15843 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
15844 soname_spec='$libname${shared_ext}.$major'
16299 library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
16300 soname_spec='$libname$shared_ext.$major'
1584516301 shlibpath_var=LD_LIBRARY_PATH
1584616302 fi
1584716303 ;;
1584816304
1584916305 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
15850 version_type=freebsd-elf
16306 version_type=sco
1585116307 need_lib_prefix=no
1585216308 need_version=no
15853 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
15854 soname_spec='${libname}${release}${shared_ext}$major'
16309 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
16310 soname_spec='$libname$release$shared_ext$major'
1585516311 shlibpath_var=LD_LIBRARY_PATH
1585616312 shlibpath_overrides_runpath=yes
1585716313 hardcode_into_libs=yes
15858 if test "$with_gnu_ld" = yes; then
16314 if test yes = "$with_gnu_ld"; then
1585916315 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
1586016316 else
1586116317 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
1587316329 version_type=linux # correct to gnu/linux during the next big refactor
1587416330 need_lib_prefix=no
1587516331 need_version=no
15876 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
16332 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
1587716333 shlibpath_var=LD_LIBRARY_PATH
1587816334 shlibpath_overrides_runpath=no
1587916335 hardcode_into_libs=yes
1588116337
1588216338 uts4*)
1588316339 version_type=linux # correct to gnu/linux during the next big refactor
15884 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15885 soname_spec='${libname}${release}${shared_ext}$major'
16340 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
16341 soname_spec='$libname$release$shared_ext$major'
1588616342 shlibpath_var=LD_LIBRARY_PATH
1588716343 ;;
1588816344
1589216348 esac
1589316349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
1589416350 $as_echo "$dynamic_linker" >&6; }
15895 test "$dynamic_linker" = no && can_build_shared=no
16351 test no = "$dynamic_linker" && can_build_shared=no
1589616352
1589716353 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
15898 if test "$GCC" = yes; then
16354 if test yes = "$GCC"; then
1589916355 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
1590016356 fi
1590116357
15902 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
15903 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
15904 fi
15905 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
15906 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
15907 fi
16358 if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
16359 sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
16360 fi
16361
16362 if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
16363 sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
16364 fi
16365
16366 # remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
16367 configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
16368
16369 # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
16370 func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
16371
16372 # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
16373 configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
16374
16375
16376
16377
16378
1590816379
1590916380
1591016381
1600216473 hardcode_action=
1600316474 if test -n "$hardcode_libdir_flag_spec" ||
1600416475 test -n "$runpath_var" ||
16005 test "X$hardcode_automatic" = "Xyes" ; then
16476 test yes = "$hardcode_automatic"; then
1600616477
1600716478 # We can hardcode non-existent directories.
16008 if test "$hardcode_direct" != no &&
16479 if test no != "$hardcode_direct" &&
1600916480 # If the only mechanism to avoid hardcoding is shlibpath_var, we
1601016481 # have to relink, otherwise we might link with an installed library
1601116482 # when we should be linking with a yet-to-be-installed one
16012 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
16013 test "$hardcode_minus_L" != no; then
16483 ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" &&
16484 test no != "$hardcode_minus_L"; then
1601416485 # Linking always hardcodes the temporary library directory.
1601516486 hardcode_action=relink
1601616487 else
1602516496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
1602616497 $as_echo "$hardcode_action" >&6; }
1602716498
16028 if test "$hardcode_action" = relink ||
16029 test "$inherit_rpath" = yes; then
16499 if test relink = "$hardcode_action" ||
16500 test yes = "$inherit_rpath"; then
1603016501 # Fast installation is not supported
1603116502 enable_fast_install=no
16032 elif test "$shlibpath_overrides_runpath" = yes ||
16033 test "$enable_shared" = no; then
16503 elif test yes = "$shlibpath_overrides_runpath" ||
16504 test no = "$enable_shared"; then
1603416505 # Fast installation is not necessary
1603516506 enable_fast_install=needless
1603616507 fi
1604016511
1604116512
1604216513
16043 if test "x$enable_dlopen" != xyes; then
16514 if test yes != "$enable_dlopen"; then
1604416515 enable_dlopen=unknown
1604516516 enable_dlopen_self=unknown
1604616517 enable_dlopen_self_static=unknown
1605016521
1605116522 case $host_os in
1605216523 beos*)
16053 lt_cv_dlopen="load_add_on"
16524 lt_cv_dlopen=load_add_on
1605416525 lt_cv_dlopen_libs=
1605516526 lt_cv_dlopen_self=yes
1605616527 ;;
1605716528
1605816529 mingw* | pw32* | cegcc*)
16059 lt_cv_dlopen="LoadLibrary"
16530 lt_cv_dlopen=LoadLibrary
1606016531 lt_cv_dlopen_libs=
1606116532 ;;
1606216533
1606316534 cygwin*)
16064 lt_cv_dlopen="dlopen"
16535 lt_cv_dlopen=dlopen
1606516536 lt_cv_dlopen_libs=
1606616537 ;;
1606716538
1606816539 darwin*)
16069 # if libdl is installed we need to link against it
16540 # if libdl is installed we need to link against it
1607016541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
1607116542 $as_echo_n "checking for dlopen in -ldl... " >&6; }
1607216543 if ${ac_cv_lib_dl_dlopen+:} false; then :
1611216583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
1611316584 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
1611416585 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
16115 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
16116 else
16117
16118 lt_cv_dlopen="dyld"
16586 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
16587 else
16588
16589 lt_cv_dlopen=dyld
1611916590 lt_cv_dlopen_libs=
1612016591 lt_cv_dlopen_self=yes
1612116592
1612216593 fi
1612316594
16595 ;;
16596
16597 tpf*)
16598 # Don't try to run any link tests for TPF. We know it's impossible
16599 # because TPF is a cross-compiler, and we know how we open DSOs.
16600 lt_cv_dlopen=dlopen
16601 lt_cv_dlopen_libs=
16602 lt_cv_dlopen_self=no
1612416603 ;;
1612516604
1612616605 *)
1612716606 ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
1612816607 if test "x$ac_cv_func_shl_load" = xyes; then :
16129 lt_cv_dlopen="shl_load"
16608 lt_cv_dlopen=shl_load
1613016609 else
1613116610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
1613216611 $as_echo_n "checking for shl_load in -ldld... " >&6; }
1617316652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
1617416653 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
1617516654 if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
16176 lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
16655 lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld
1617716656 else
1617816657 ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
1617916658 if test "x$ac_cv_func_dlopen" = xyes; then :
16180 lt_cv_dlopen="dlopen"
16659 lt_cv_dlopen=dlopen
1618116660 else
1618216661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
1618316662 $as_echo_n "checking for dlopen in -ldl... " >&6; }
1622416703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
1622516704 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
1622616705 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
16227 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
16706 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
1622816707 else
1622916708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
1623016709 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
1627116750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
1627216751 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
1627316752 if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
16274 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
16753 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld
1627516754 else
1627616755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
1627716756 $as_echo_n "checking for dld_link in -ldld... " >&6; }
1631816797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
1631916798 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
1632016799 if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
16321 lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
16800 lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld
1632216801 fi
1632316802
1632416803
1633916818 ;;
1634016819 esac
1634116820
16342 if test "x$lt_cv_dlopen" != xno; then
16821 if test no = "$lt_cv_dlopen"; then
16822 enable_dlopen=no
16823 else
1634316824 enable_dlopen=yes
16344 else
16345 enable_dlopen=no
1634616825 fi
1634716826
1634816827 case $lt_cv_dlopen in
1634916828 dlopen)
16350 save_CPPFLAGS="$CPPFLAGS"
16351 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
16352
16353 save_LDFLAGS="$LDFLAGS"
16829 save_CPPFLAGS=$CPPFLAGS
16830 test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
16831
16832 save_LDFLAGS=$LDFLAGS
1635416833 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
1635516834
16356 save_LIBS="$LIBS"
16835 save_LIBS=$LIBS
1635716836 LIBS="$lt_cv_dlopen_libs $LIBS"
1635816837
1635916838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
1636116840 if ${lt_cv_dlopen_self+:} false; then :
1636216841 $as_echo_n "(cached) " >&6
1636316842 else
16364 if test "$cross_compiling" = yes; then :
16843 if test yes = "$cross_compiling"; then :
1636516844 lt_cv_dlopen_self=cross
1636616845 else
1636716846 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1640816887 # endif
1640916888 #endif
1641016889
16411 /* When -fvisbility=hidden is used, assume the code has been annotated
16890 /* When -fvisibility=hidden is used, assume the code has been annotated
1641216891 correspondingly for the symbols needed. */
16413 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
16892 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
1641416893 int fnord () __attribute__((visibility("default")));
1641516894 #endif
1641616895
1644016919 (eval $ac_link) 2>&5
1644116920 ac_status=$?
1644216921 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16443 test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
16922 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
1644416923 (./conftest; exit; ) >&5 2>/dev/null
1644516924 lt_status=$?
1644616925 case x$lt_status in
1646016939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
1646116940 $as_echo "$lt_cv_dlopen_self" >&6; }
1646216941
16463 if test "x$lt_cv_dlopen_self" = xyes; then
16942 if test yes = "$lt_cv_dlopen_self"; then
1646416943 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
1646516944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
1646616945 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
1646716946 if ${lt_cv_dlopen_self_static+:} false; then :
1646816947 $as_echo_n "(cached) " >&6
1646916948 else
16470 if test "$cross_compiling" = yes; then :
16949 if test yes = "$cross_compiling"; then :
1647116950 lt_cv_dlopen_self_static=cross
1647216951 else
1647316952 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
1651416993 # endif
1651516994 #endif
1651616995
16517 /* When -fvisbility=hidden is used, assume the code has been annotated
16996 /* When -fvisibility=hidden is used, assume the code has been annotated
1651816997 correspondingly for the symbols needed. */
16519 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
16998 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
1652016999 int fnord () __attribute__((visibility("default")));
1652117000 #endif
1652217001
1654617025 (eval $ac_link) 2>&5
1654717026 ac_status=$?
1654817027 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16549 test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
17028 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
1655017029 (./conftest; exit; ) >&5 2>/dev/null
1655117030 lt_status=$?
1655217031 case x$lt_status in
1656717046 $as_echo "$lt_cv_dlopen_self_static" >&6; }
1656817047 fi
1656917048
16570 CPPFLAGS="$save_CPPFLAGS"
16571 LDFLAGS="$save_LDFLAGS"
16572 LIBS="$save_LIBS"
17049 CPPFLAGS=$save_CPPFLAGS
17050 LDFLAGS=$save_LDFLAGS
17051 LIBS=$save_LIBS
1657317052 ;;
1657417053 esac
1657517054
1661317092 # FIXME - insert some real tests, host_os isn't really good enough
1661417093 case $host_os in
1661517094 darwin*)
16616 if test -n "$STRIP" ; then
17095 if test -n "$STRIP"; then
1661717096 striplib="$STRIP -x"
1661817097 old_striplib="$STRIP -S"
1661917098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
1664117120
1664217121
1664317122
16644 # Report which library types will actually be built
17123 # Report what library types will actually be built
1664517124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
1664617125 $as_echo_n "checking if libtool supports shared libraries... " >&6; }
1664717126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
1664917128
1665017129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
1665117130 $as_echo_n "checking whether to build shared libraries... " >&6; }
16652 test "$can_build_shared" = "no" && enable_shared=no
17131 test no = "$can_build_shared" && enable_shared=no
1665317132
1665417133 # On AIX, shared libraries and static libraries use the same namespace, and
1665517134 # are all built from PIC.
1665617135 case $host_os in
1665717136 aix3*)
16658 test "$enable_shared" = yes && enable_static=no
17137 test yes = "$enable_shared" && enable_static=no
1665917138 if test -n "$RANLIB"; then
1666017139 archive_cmds="$archive_cmds~\$RANLIB \$lib"
1666117140 postinstall_cmds='$RANLIB $lib'
1666317142 ;;
1666417143
1666517144 aix[4-9]*)
16666 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
16667 test "$enable_shared" = yes && enable_static=no
17145 if test ia64 != "$host_cpu"; then
17146 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
17147 yes,aix,yes) ;; # shared object as lib.so file only
17148 yes,svr4,*) ;; # shared object as lib.so archive member only
17149 yes,*) enable_static=no ;; # shared object in lib.a archive as well
17150 esac
1666817151 fi
1666917152 ;;
1667017153 esac
1667417157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
1667517158 $as_echo_n "checking whether to build static libraries... " >&6; }
1667617159 # Make sure either enable_shared or enable_static is yes.
16677 test "$enable_shared" = yes || enable_static=yes
17160 test yes = "$enable_shared" || enable_static=yes
1667817161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
1667917162 $as_echo "$enable_static" >&6; }
1668017163
1668817171 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1668917172 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1669017173
16691 CC="$lt_save_CC"
16692
16693 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
16694 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
16695 (test "X$CXX" != "Xg++"))) ; then
17174 CC=$lt_save_CC
17175
17176 if test -n "$CXX" && ( test no != "$CXX" &&
17177 ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) ||
17178 (test g++ != "$CXX"))); then
1669617179 ac_ext=cpp
1669717180 ac_cpp='$CXXCPP $CPPFLAGS'
1669817181 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1687117354 # the CXX compiler isn't working. Some variables (like enable_shared)
1687217355 # are currently assumed to apply to all compilers on this platform,
1687317356 # and will be corrupted by setting them based on a non-working compiler.
16874 if test "$_lt_caught_CXX_error" != yes; then
17357 if test yes != "$_lt_caught_CXX_error"; then
1687517358 # Code to be used in simple compile tests
1687617359 lt_simple_compile_test_code="int some_variable = 0;"
1687717360
1693217415 CFLAGS=$CXXFLAGS
1693317416 compiler=$CC
1693417417 compiler_CXX=$CC
16935 for cc_temp in $compiler""; do
16936 case $cc_temp in
16937 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
16938 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
16939 \-*) ;;
16940 *) break;;
16941 esac
16942 done
16943 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
17418 func_cc_basename $compiler
17419 cc_basename=$func_cc_basename_result
1694417420
1694517421
1694617422 if test -n "$compiler"; then
1694717423 # We don't want -fno-exception when compiling C++ code, so set the
1694817424 # no_builtin_flag separately
16949 if test "$GXX" = yes; then
17425 if test yes = "$GXX"; then
1695017426 lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin'
1695117427 else
1695217428 lt_prog_compiler_no_builtin_flag_CXX=
1695317429 fi
1695417430
16955 if test "$GXX" = yes; then
17431 if test yes = "$GXX"; then
1695617432 # Set up default GNU C++ configuration
1695717433
1695817434
1695917435
1696017436 # Check whether --with-gnu-ld was given.
1696117437 if test "${with_gnu_ld+set}" = set; then :
16962 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
17438 withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
1696317439 else
1696417440 with_gnu_ld=no
1696517441 fi
1696617442
1696717443 ac_prog=ld
16968 if test "$GCC" = yes; then
17444 if test yes = "$GCC"; then
1696917445 # Check if gcc -print-prog-name=ld gives a path.
1697017446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
1697117447 $as_echo_n "checking for ld used by $CC... " >&6; }
1697217448 case $host in
1697317449 *-*-mingw*)
16974 # gcc leaves a trailing carriage return which upsets mingw
17450 # gcc leaves a trailing carriage return, which upsets mingw
1697517451 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
1697617452 *)
1697717453 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
1698517461 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
1698617462 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
1698717463 done
16988 test -z "$LD" && LD="$ac_prog"
17464 test -z "$LD" && LD=$ac_prog
1698917465 ;;
1699017466 "")
1699117467 # If it fails, then pretend we aren't using GCC.
1699617472 with_gnu_ld=unknown
1699717473 ;;
1699817474 esac
16999 elif test "$with_gnu_ld" = yes; then
17475 elif test yes = "$with_gnu_ld"; then
1700017476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
1700117477 $as_echo_n "checking for GNU ld... " >&6; }
1700217478 else
1700717483 $as_echo_n "(cached) " >&6
1700817484 else
1700917485 if test -z "$LD"; then
17010 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
17486 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
1701117487 for ac_dir in $PATH; do
17012 IFS="$lt_save_ifs"
17488 IFS=$lt_save_ifs
1701317489 test -z "$ac_dir" && ac_dir=.
1701417490 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
17015 lt_cv_path_LD="$ac_dir/$ac_prog"
17491 lt_cv_path_LD=$ac_dir/$ac_prog
1701617492 # Check to see if the program is GNU ld. I'd rather use --version,
1701717493 # but apparently some variants of GNU ld only accept -v.
1701817494 # Break only if it was the GNU/non-GNU ld that we prefer.
1701917495 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
1702017496 *GNU* | *'with BFD'*)
17021 test "$with_gnu_ld" != no && break
17497 test no != "$with_gnu_ld" && break
1702217498 ;;
1702317499 *)
17024 test "$with_gnu_ld" != yes && break
17500 test yes != "$with_gnu_ld" && break
1702517501 ;;
1702617502 esac
1702717503 fi
1702817504 done
17029 IFS="$lt_save_ifs"
17030 else
17031 lt_cv_path_LD="$LD" # Let the user override the test with a path.
17032 fi
17033 fi
17034
17035 LD="$lt_cv_path_LD"
17505 IFS=$lt_save_ifs
17506 else
17507 lt_cv_path_LD=$LD # Let the user override the test with a path.
17508 fi
17509 fi
17510
17511 LD=$lt_cv_path_LD
1703617512 if test -n "$LD"; then
1703717513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
1703817514 $as_echo "$LD" >&6; }
1706817544
1706917545 # Check if GNU C++ uses GNU ld as the underlying linker, since the
1707017546 # archiving commands below assume that GNU ld is being used.
17071 if test "$with_gnu_ld" = yes; then
17072 archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
17073 archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17074
17075 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
17076 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
17547 if test yes = "$with_gnu_ld"; then
17548 archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
17549 archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
17550
17551 hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir'
17552 export_dynamic_flag_spec_CXX='$wl--export-dynamic'
1707717553
1707817554 # If archive_cmds runs LD, not CC, wlarc should be empty
1707917555 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
1708017556 # investigate it a little bit more. (MM)
17081 wlarc='${wl}'
17557 wlarc='$wl'
1708217558
1708317559 # ancient GNU ld didn't support --whole-archive et. al.
1708417560 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
1708517561 $GREP 'no-whole-archive' > /dev/null; then
17086 whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
17562 whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
1708717563 else
1708817564 whole_archive_flag_spec_CXX=
1708917565 fi
1712017596 ld_shlibs_CXX=no
1712117597 ;;
1712217598 aix[4-9]*)
17123 if test "$host_cpu" = ia64; then
17599 if test ia64 = "$host_cpu"; then
1712417600 # On IA64, the linker does run time linking by default, so we don't
1712517601 # have to do anything special.
1712617602 aix_use_runtimelinking=no
1712717603 exp_sym_flag='-Bexport'
17128 no_entry_flag=""
17604 no_entry_flag=
1712917605 else
1713017606 aix_use_runtimelinking=no
1713117607
1713217608 # Test if we are trying to use run time linking or normal
1713317609 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
17134 # need to do runtime linking.
17610 # have runtime linking enabled, and use it for executables.
17611 # For shared libraries, we enable/disable runtime linking
17612 # depending on the kind of the shared library created -
17613 # when "with_aix_soname,aix_use_runtimelinking" is:
17614 # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
17615 # "aix,yes" lib.so shared, rtl:yes, for executables
17616 # lib.a static archive
17617 # "both,no" lib.so.V(shr.o) shared, rtl:yes
17618 # lib.a(lib.so.V) shared, rtl:no, for executables
17619 # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
17620 # lib.a(lib.so.V) shared, rtl:no
17621 # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
17622 # lib.a static archive
1713517623 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
1713617624 for ld_flag in $LDFLAGS; do
1713717625 case $ld_flag in
1714117629 ;;
1714217630 esac
1714317631 done
17632 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
17633 # With aix-soname=svr4, we create the lib.so.V shared archives only,
17634 # so we don't have lib.a shared libs to link our executables.
17635 # We have to force runtime linking in this case.
17636 aix_use_runtimelinking=yes
17637 LDFLAGS="$LDFLAGS -Wl,-brtl"
17638 fi
1714417639 ;;
1714517640 esac
1714617641
1715917654 hardcode_direct_absolute_CXX=yes
1716017655 hardcode_libdir_separator_CXX=':'
1716117656 link_all_deplibs_CXX=yes
17162 file_list_spec_CXX='${wl}-f,'
17163
17164 if test "$GXX" = yes; then
17657 file_list_spec_CXX='$wl-f,'
17658 case $with_aix_soname,$aix_use_runtimelinking in
17659 aix,*) ;; # no import file
17660 svr4,* | *,yes) # use import file
17661 # The Import File defines what to hardcode.
17662 hardcode_direct_CXX=no
17663 hardcode_direct_absolute_CXX=no
17664 ;;
17665 esac
17666
17667 if test yes = "$GXX"; then
1716517668 case $host_os in aix4.[012]|aix4.[012].*)
1716617669 # We only want to do this on AIX 4.2 and lower, the check
1716717670 # below for broken collect2 doesn't work under 4.3+
17168 collect2name=`${CC} -print-prog-name=collect2`
17671 collect2name=`$CC -print-prog-name=collect2`
1716917672 if test -f "$collect2name" &&
1717017673 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
1717117674 then
1718317686 fi
1718417687 esac
1718517688 shared_flag='-shared'
17186 if test "$aix_use_runtimelinking" = yes; then
17187 shared_flag="$shared_flag "'${wl}-G'
17689 if test yes = "$aix_use_runtimelinking"; then
17690 shared_flag=$shared_flag' $wl-G'
1718817691 fi
17692 # Need to ensure runtime linking is disabled for the traditional
17693 # shared library, or the linker may eventually find shared libraries
17694 # /with/ Import File - we do not want to mix them.
17695 shared_flag_aix='-shared'
17696 shared_flag_svr4='-shared $wl-G'
1718917697 else
1719017698 # not using gcc
17191 if test "$host_cpu" = ia64; then
17699 if test ia64 = "$host_cpu"; then
1719217700 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
1719317701 # chokes on -Wl,-G. The following line is correct:
1719417702 shared_flag='-G'
1719517703 else
17196 if test "$aix_use_runtimelinking" = yes; then
17197 shared_flag='${wl}-G'
17704 if test yes = "$aix_use_runtimelinking"; then
17705 shared_flag='$wl-G'
1719817706 else
17199 shared_flag='${wl}-bM:SRE'
17707 shared_flag='$wl-bM:SRE'
1720017708 fi
17709 shared_flag_aix='$wl-bM:SRE'
17710 shared_flag_svr4='$wl-G'
1720117711 fi
1720217712 fi
1720317713
17204 export_dynamic_flag_spec_CXX='${wl}-bexpall'
17714 export_dynamic_flag_spec_CXX='$wl-bexpall'
1720517715 # It seems that -bexpall does not export symbols beginning with
1720617716 # underscore (_), so it is better to generate a list of symbols to
1720717717 # export.
1720817718 always_export_symbols_CXX=yes
17209 if test "$aix_use_runtimelinking" = yes; then
17719 if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
1721017720 # Warning - without using the other runtime loading flags (-brtl),
1721117721 # -berok will link without error, but may produce a broken library.
17212 allow_undefined_flag_CXX='-berok'
17722 # The "-G" linker flag allows undefined symbols.
17723 no_undefined_flag_CXX='-bernotok'
1721317724 # Determine the default libpath from the value encoded in an empty
1721417725 # executable.
17215 if test "${lt_cv_aix_libpath+set}" = set; then
17726 if test set = "${lt_cv_aix_libpath+set}"; then
1721617727 aix_libpath=$lt_cv_aix_libpath
1721717728 else
1721817729 if ${lt_cv_aix_libpath__CXX+:} false; then :
1725517766 rm -f core conftest.err conftest.$ac_objext \
1725617767 conftest$ac_exeext conftest.$ac_ext
1725717768 if test -z "$lt_cv_aix_libpath__CXX"; then
17258 lt_cv_aix_libpath__CXX="/usr/lib:/lib"
17769 lt_cv_aix_libpath__CXX=/usr/lib:/lib
1725917770 fi
1726017771
1726117772 fi
1726317774 aix_libpath=$lt_cv_aix_libpath__CXX
1726417775 fi
1726517776
17266 hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
17267
17268 archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
17777 hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath"
17778
17779 archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
1726917780 else
17270 if test "$host_cpu" = ia64; then
17271 hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib'
17781 if test ia64 = "$host_cpu"; then
17782 hardcode_libdir_flag_spec_CXX='$wl-R $libdir:/usr/lib:/lib'
1727217783 allow_undefined_flag_CXX="-z nodefs"
17273 archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
17784 archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols"
1727417785 else
1727517786 # Determine the default libpath from the value encoded in an
1727617787 # empty executable.
17277 if test "${lt_cv_aix_libpath+set}" = set; then
17788 if test set = "${lt_cv_aix_libpath+set}"; then
1727817789 aix_libpath=$lt_cv_aix_libpath
1727917790 else
1728017791 if ${lt_cv_aix_libpath__CXX+:} false; then :
1731717828 rm -f core conftest.err conftest.$ac_objext \
1731817829 conftest$ac_exeext conftest.$ac_ext
1731917830 if test -z "$lt_cv_aix_libpath__CXX"; then
17320 lt_cv_aix_libpath__CXX="/usr/lib:/lib"
17831 lt_cv_aix_libpath__CXX=/usr/lib:/lib
1732117832 fi
1732217833
1732317834 fi
1732517836 aix_libpath=$lt_cv_aix_libpath__CXX
1732617837 fi
1732717838
17328 hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
17839 hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath"
1732917840 # Warning - without using the other run time loading flags,
1733017841 # -berok will link without error, but may produce a broken library.
17331 no_undefined_flag_CXX=' ${wl}-bernotok'
17332 allow_undefined_flag_CXX=' ${wl}-berok'
17333 if test "$with_gnu_ld" = yes; then
17842 no_undefined_flag_CXX=' $wl-bernotok'
17843 allow_undefined_flag_CXX=' $wl-berok'
17844 if test yes = "$with_gnu_ld"; then
1733417845 # We only use this code for GNU lds that support --whole-archive.
17335 whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
17846 whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive'
1733617847 else
1733717848 # Exported symbols can be pulled into shared objects from archives
1733817849 whole_archive_flag_spec_CXX='$convenience'
1733917850 fi
1734017851 archive_cmds_need_lc_CXX=yes
17341 # This is similar to how AIX traditionally builds its shared
17342 # libraries.
17343 archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
17852 archive_expsym_cmds_CXX='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
17853 # -brtl affects multiple linker settings, -berok does not and is overridden later
17854 compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
17855 if test svr4 != "$with_aix_soname"; then
17856 # This is similar to how AIX traditionally builds its shared
17857 # libraries. Need -bnortl late, we may have -brtl in LDFLAGS.
17858 archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
17859 fi
17860 if test aix != "$with_aix_soname"; then
17861 archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
17862 else
17863 # used by -dlpreopen to get the symbols
17864 archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
17865 fi
17866 archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$RM -r $output_objdir/$realname.d'
1734417867 fi
1734517868 fi
1734617869 ;;
1735017873 allow_undefined_flag_CXX=unsupported
1735117874 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
1735217875 # support --undefined. This deserves some investigation. FIXME
17353 archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17876 archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
1735417877 else
1735517878 ld_shlibs_CXX=no
1735617879 fi
1737817901 # Tell ltmain to make .lib files, not .a files.
1737917902 libext=lib
1738017903 # Tell ltmain to make .dll files, not .so files.
17381 shrext_cmds=".dll"
17904 shrext_cmds=.dll
1738217905 # FIXME: Setting linknames here is a bad hack.
17383 archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
17384 archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
17385 $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
17386 else
17387 $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
17388 fi~
17389 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
17390 linknames='
17906 archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
17907 archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
17908 cp "$export_symbols" "$output_objdir/$soname.def";
17909 echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
17910 else
17911 $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
17912 fi~
17913 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
17914 linknames='
1739117915 # The linker will not automatically build a static lib if we build a DLL.
1739217916 # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true'
1739317917 enable_shared_with_static_runtimes_CXX=yes
1739417918 # Don't use ranlib
1739517919 old_postinstall_cmds_CXX='chmod 644 $oldlib'
1739617920 postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~
17397 lt_tool_outputfile="@TOOL_OUTPUT@"~
17398 case $lt_outputfile in
17399 *.exe|*.EXE) ;;
17400 *)
17401 lt_outputfile="$lt_outputfile.exe"
17402 lt_tool_outputfile="$lt_tool_outputfile.exe"
17403 ;;
17404 esac~
17405 func_to_tool_file "$lt_outputfile"~
17406 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
17407 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
17408 $RM "$lt_outputfile.manifest";
17409 fi'
17921 lt_tool_outputfile="@TOOL_OUTPUT@"~
17922 case $lt_outputfile in
17923 *.exe|*.EXE) ;;
17924 *)
17925 lt_outputfile=$lt_outputfile.exe
17926 lt_tool_outputfile=$lt_tool_outputfile.exe
17927 ;;
17928 esac~
17929 func_to_tool_file "$lt_outputfile"~
17930 if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
17931 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
17932 $RM "$lt_outputfile.manifest";
17933 fi'
1741017934 ;;
1741117935 *)
1741217936 # g++
1741317937 # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless,
1741417938 # as there is no search path for DLLs.
1741517939 hardcode_libdir_flag_spec_CXX='-L$libdir'
17416 export_dynamic_flag_spec_CXX='${wl}--export-all-symbols'
17940 export_dynamic_flag_spec_CXX='$wl--export-all-symbols'
1741717941 allow_undefined_flag_CXX=unsupported
1741817942 always_export_symbols_CXX=no
1741917943 enable_shared_with_static_runtimes_CXX=yes
1742017944
1742117945 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
17422 archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
17423 # If the export-symbols file already is a .def file (1st line
17424 # is EXPORTS), use it as is; otherwise, prepend...
17425 archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
17426 cp $export_symbols $output_objdir/$soname.def;
17427 else
17428 echo EXPORTS > $output_objdir/$soname.def;
17429 cat $export_symbols >> $output_objdir/$soname.def;
17430 fi~
17431 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
17946 archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
17947 # If the export-symbols file already is a .def file, use it as
17948 # is; otherwise, prepend EXPORTS...
17949 archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
17950 cp $export_symbols $output_objdir/$soname.def;
17951 else
17952 echo EXPORTS > $output_objdir/$soname.def;
17953 cat $export_symbols >> $output_objdir/$soname.def;
17954 fi~
17955 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
1743217956 else
1743317957 ld_shlibs_CXX=no
1743417958 fi
1744217966 hardcode_direct_CXX=no
1744317967 hardcode_automatic_CXX=yes
1744417968 hardcode_shlibpath_var_CXX=unsupported
17445 if test "$lt_cv_ld_force_load" = "yes"; then
17446 whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
17969 if test yes = "$lt_cv_ld_force_load"; then
17970 whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
1744717971
1744817972 else
1744917973 whole_archive_flag_spec_CXX=''
1745017974 fi
1745117975 link_all_deplibs_CXX=yes
17452 allow_undefined_flag_CXX="$_lt_dar_allow_undefined"
17976 allow_undefined_flag_CXX=$_lt_dar_allow_undefined
1745317977 case $cc_basename in
17454 ifort*) _lt_dar_can_shared=yes ;;
17978 ifort*|nagfor*) _lt_dar_can_shared=yes ;;
1745517979 *) _lt_dar_can_shared=$GCC ;;
1745617980 esac
17457 if test "$_lt_dar_can_shared" = "yes"; then
17981 if test yes = "$_lt_dar_can_shared"; then
1745817982 output_verbose_link_cmd=func_echo_all
17459 archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
17460 module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
17461 archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
17462 module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
17463 if test "$lt_cv_apple_cc_single_mod" != "yes"; then
17464 archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
17465 archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
17983 archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
17984 module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
17985 archive_expsym_cmds_CXX="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil"
17986 module_expsym_cmds_CXX="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil"
17987 if test yes != "$lt_cv_apple_cc_single_mod"; then
17988 archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil"
17989 archive_expsym_cmds_CXX="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil"
1746617990 fi
1746717991
1746817992 else
1746917993 ld_shlibs_CXX=no
1747017994 fi
1747117995
17996 ;;
17997
17998 os2*)
17999 hardcode_libdir_flag_spec_CXX='-L$libdir'
18000 hardcode_minus_L_CXX=yes
18001 allow_undefined_flag_CXX=unsupported
18002 shrext_cmds=.dll
18003 archive_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
18004 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
18005 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
18006 $ECHO EXPORTS >> $output_objdir/$libname.def~
18007 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
18008 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
18009 emximp -o $lib $output_objdir/$libname.def'
18010 archive_expsym_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
18011 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
18012 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
18013 $ECHO EXPORTS >> $output_objdir/$libname.def~
18014 prefix_cmds="$SED"~
18015 if test EXPORTS = "`$SED 1q $export_symbols`"; then
18016 prefix_cmds="$prefix_cmds -e 1d";
18017 fi~
18018 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
18019 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
18020 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
18021 emximp -o $lib $output_objdir/$libname.def'
18022 old_archive_From_new_cmds_CXX='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
18023 enable_shared_with_static_runtimes_CXX=yes
1747218024 ;;
1747318025
1747418026 dgux*)
1750618058 ;;
1750718059
1750818060 haiku*)
17509 archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
18061 archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
1751018062 link_all_deplibs_CXX=yes
1751118063 ;;
1751218064
1751318065 hpux9*)
17514 hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
18066 hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir'
1751518067 hardcode_libdir_separator_CXX=:
17516 export_dynamic_flag_spec_CXX='${wl}-E'
18068 export_dynamic_flag_spec_CXX='$wl-E'
1751718069 hardcode_direct_CXX=yes
1751818070 hardcode_minus_L_CXX=yes # Not in the search PATH,
1751918071 # but as the default
1752518077 ld_shlibs_CXX=no
1752618078 ;;
1752718079 aCC*)
17528 archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
18080 archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
1752918081 # Commands to make compiler produce verbose output that lists
1753018082 # what "hidden" libraries, object files and flags are used when
1753118083 # linking a shared library.
1753418086 # explicitly linking system object files so we need to strip them
1753518087 # from the output so that they don't get included in the library
1753618088 # dependencies.
17537 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
18089 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
1753818090 ;;
1753918091 *)
17540 if test "$GXX" = yes; then
17541 archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
18092 if test yes = "$GXX"; then
18093 archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
1754218094 else
1754318095 # FIXME: insert proper C++ library support
1754418096 ld_shlibs_CXX=no
1754818100 ;;
1754918101
1755018102 hpux10*|hpux11*)
17551 if test $with_gnu_ld = no; then
17552 hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
18103 if test no = "$with_gnu_ld"; then
18104 hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir'
1755318105 hardcode_libdir_separator_CXX=:
1755418106
1755518107 case $host_cpu in
1755618108 hppa*64*|ia64*)
1755718109 ;;
1755818110 *)
17559 export_dynamic_flag_spec_CXX='${wl}-E'
18111 export_dynamic_flag_spec_CXX='$wl-E'
1756018112 ;;
1756118113 esac
1756218114 fi
1758218134 aCC*)
1758318135 case $host_cpu in
1758418136 hppa*64*)
17585 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
18137 archive_cmds_CXX='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1758618138 ;;
1758718139 ia64*)
17588 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
18140 archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1758918141 ;;
1759018142 *)
17591 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
18143 archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1759218144 ;;
1759318145 esac
1759418146 # Commands to make compiler produce verbose output that lists
1759918151 # explicitly linking system object files so we need to strip them
1760018152 # from the output so that they don't get included in the library
1760118153 # dependencies.
17602 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
18154 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
1760318155 ;;
1760418156 *)
17605 if test "$GXX" = yes; then
17606 if test $with_gnu_ld = no; then
18157 if test yes = "$GXX"; then
18158 if test no = "$with_gnu_ld"; then
1760718159 case $host_cpu in
1760818160 hppa*64*)
17609 archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
18161 archive_cmds_CXX='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1761018162 ;;
1761118163 ia64*)
17612 archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
18164 archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1761318165 ;;
1761418166 *)
17615 archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
18167 archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1761618168 ;;
1761718169 esac
1761818170 fi
1762718179 interix[3-9]*)
1762818180 hardcode_direct_CXX=no
1762918181 hardcode_shlibpath_var_CXX=no
17630 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
17631 export_dynamic_flag_spec_CXX='${wl}-E'
18182 hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir'
18183 export_dynamic_flag_spec_CXX='$wl-E'
1763218184 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
1763318185 # Instead, shared libraries are loaded at an image base (0x10000000 by
1763418186 # default) and relocated if they conflict, which is a slow very memory
1763518187 # consuming and fragmenting process. To avoid this, we pick a random,
1763618188 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
1763718189 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
17638 archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
17639 archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
18190 archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
18191 archive_expsym_cmds_CXX='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
1764018192 ;;
1764118193 irix5* | irix6*)
1764218194 case $cc_basename in
1764318195 CC*)
1764418196 # SGI C++
17645 archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
18197 archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
1764618198
1764718199 # Archives containing C++ object files must be created using
1764818200 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
1765118203 old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs'
1765218204 ;;
1765318205 *)
17654 if test "$GXX" = yes; then
17655 if test "$with_gnu_ld" = no; then
17656 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
18206 if test yes = "$GXX"; then
18207 if test no = "$with_gnu_ld"; then
18208 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
1765718209 else
17658 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
18210 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib'
1765918211 fi
1766018212 fi
1766118213 link_all_deplibs_CXX=yes
1766218214 ;;
1766318215 esac
17664 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
18216 hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir'
1766518217 hardcode_libdir_separator_CXX=:
1766618218 inherit_rpath_CXX=yes
1766718219 ;;
1767418226 # KCC will only create a shared library if the output file
1767518227 # ends with ".so" (or ".sl" for HP-UX), so rename the library
1767618228 # to its proper name (with version) after linking.
17677 archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
17678 archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
18229 archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
18230 archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib'
1767918231 # Commands to make compiler produce verbose output that lists
1768018232 # what "hidden" libraries, object files and flags are used when
1768118233 # linking a shared library.
1768418236 # explicitly linking system object files so we need to strip them
1768518237 # from the output so that they don't get included in the library
1768618238 # dependencies.
17687 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
17688
17689 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
17690 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
18239 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
18240
18241 hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir'
18242 export_dynamic_flag_spec_CXX='$wl--export-dynamic'
1769118243
1769218244 # Archives containing C++ object files must be created using
1769318245 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
1770118253 # earlier do not add the objects themselves.
1770218254 case `$CC -V 2>&1` in
1770318255 *"Version 7."*)
17704 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
17705 archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
18256 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
18257 archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
1770618258 ;;
1770718259 *) # Version 8.0 or newer
1770818260 tmp_idyn=
1770918261 case $host_cpu in
1771018262 ia64*) tmp_idyn=' -i_dynamic';;
1771118263 esac
17712 archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17713 archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
18264 archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
18265 archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
1771418266 ;;
1771518267 esac
1771618268 archive_cmds_need_lc_CXX=no
17717 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
17718 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
17719 whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
18269 hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir'
18270 export_dynamic_flag_spec_CXX='$wl--export-dynamic'
18271 whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive'
1772018272 ;;
1772118273 pgCC* | pgcpp*)
1772218274 # Portland Group C++ compiler
1772318275 case `$CC -V` in
1772418276 *pgCC\ [1-5].* | *pgcpp\ [1-5].*)
1772518277 prelink_cmds_CXX='tpldir=Template.dir~
17726 rm -rf $tpldir~
17727 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
17728 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
18278 rm -rf $tpldir~
18279 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
18280 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
1772918281 old_archive_cmds_CXX='tpldir=Template.dir~
17730 rm -rf $tpldir~
17731 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
17732 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
17733 $RANLIB $oldlib'
18282 rm -rf $tpldir~
18283 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
18284 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
18285 $RANLIB $oldlib'
1773418286 archive_cmds_CXX='tpldir=Template.dir~
17735 rm -rf $tpldir~
17736 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
17737 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
18287 rm -rf $tpldir~
18288 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
18289 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
1773818290 archive_expsym_cmds_CXX='tpldir=Template.dir~
17739 rm -rf $tpldir~
17740 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
17741 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
18291 rm -rf $tpldir~
18292 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
18293 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
1774218294 ;;
1774318295 *) # Version 6 and above use weak symbols
17744 archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
17745 archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
18296 archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
18297 archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
1774618298 ;;
1774718299 esac
1774818300
17749 hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir'
17750 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
17751 whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
18301 hardcode_libdir_flag_spec_CXX='$wl--rpath $wl$libdir'
18302 export_dynamic_flag_spec_CXX='$wl--export-dynamic'
18303 whole_archive_flag_spec_CXX='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
1775218304 ;;
1775318305 cxx*)
1775418306 # Compaq C++
17755 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
17756 archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
18307 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
18308 archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols'
1775718309
1775818310 runpath_var=LD_RUN_PATH
1775918311 hardcode_libdir_flag_spec_CXX='-rpath $libdir'
1776718319 # explicitly linking system object files so we need to strip them
1776818320 # from the output so that they don't get included in the library
1776918321 # dependencies.
17770 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
18322 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
1777118323 ;;
1777218324 xl* | mpixl* | bgxl*)
1777318325 # IBM XL 8.0 on PPC, with GNU ld
17774 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
17775 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
17776 archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17777 if test "x$supports_anon_versioning" = xyes; then
18326 hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir'
18327 export_dynamic_flag_spec_CXX='$wl--export-dynamic'
18328 archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
18329 if test yes = "$supports_anon_versioning"; then
1777818330 archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~
17779 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
17780 echo "local: *; };" >> $output_objdir/$libname.ver~
17781 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
18331 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
18332 echo "local: *; };" >> $output_objdir/$libname.ver~
18333 $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
1778218334 fi
1778318335 ;;
1778418336 *)
1778618338 *Sun\ C*)
1778718339 # Sun C++ 5.9
1778818340 no_undefined_flag_CXX=' -zdefs'
17789 archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
17790 archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
18341 archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
18342 archive_expsym_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols'
1779118343 hardcode_libdir_flag_spec_CXX='-R$libdir'
17792 whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
18344 whole_archive_flag_spec_CXX='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
1779318345 compiler_needs_object_CXX=yes
1779418346
1779518347 # Not sure whether something based on
1784718399 ld_shlibs_CXX=yes
1784818400 ;;
1784918401
17850 openbsd2*)
17851 # C++ shared libraries are fairly broken
17852 ld_shlibs_CXX=no
17853 ;;
17854
17855 openbsd*)
18402 openbsd* | bitrig*)
1785618403 if test -f /usr/libexec/ld.so; then
1785718404 hardcode_direct_CXX=yes
1785818405 hardcode_shlibpath_var_CXX=no
1785918406 hardcode_direct_absolute_CXX=yes
1786018407 archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
17861 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
17862 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
17863 archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
17864 export_dynamic_flag_spec_CXX='${wl}-E'
17865 whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
18408 hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir'
18409 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then
18410 archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib'
18411 export_dynamic_flag_spec_CXX='$wl-E'
18412 whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
1786618413 fi
1786718414 output_verbose_link_cmd=func_echo_all
1786818415 else
1787818425 # KCC will only create a shared library if the output file
1787918426 # ends with ".so" (or ".sl" for HP-UX), so rename the library
1788018427 # to its proper name (with version) after linking.
17881 archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
17882
17883 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
18428 archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
18429
18430 hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir'
1788418431 hardcode_libdir_separator_CXX=:
1788518432
1788618433 # Archives containing C++ object files must be created using
1789818445 cxx*)
1789918446 case $host in
1790018447 osf3*)
17901 allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
17902 archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
17903 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
18448 allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*'
18449 archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
18450 hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir'
1790418451 ;;
1790518452 *)
1790618453 allow_undefined_flag_CXX=' -expect_unresolved \*'
17907 archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
18454 archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
1790818455 archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
17909 echo "-hidden">> $lib.exp~
17910 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
17911 $RM $lib.exp'
18456 echo "-hidden">> $lib.exp~
18457 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~
18458 $RM $lib.exp'
1791218459 hardcode_libdir_flag_spec_CXX='-rpath $libdir'
1791318460 ;;
1791418461 esac
1792318470 # explicitly linking system object files so we need to strip them
1792418471 # from the output so that they don't get included in the library
1792518472 # dependencies.
17926 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
18473 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
1792718474 ;;
1792818475 *)
17929 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
17930 allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
18476 if test yes,no = "$GXX,$with_gnu_ld"; then
18477 allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*'
1793118478 case $host in
1793218479 osf3*)
17933 archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
18480 archive_cmds_CXX='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
1793418481 ;;
1793518482 *)
17936 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
18483 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
1793718484 ;;
1793818485 esac
1793918486
17940 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
18487 hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir'
1794118488 hardcode_libdir_separator_CXX=:
1794218489
1794318490 # Commands to make compiler produce verbose output that lists
1798318530 # Sun C++ 4.2, 5.x and Centerline C++
1798418531 archive_cmds_need_lc_CXX=yes
1798518532 no_undefined_flag_CXX=' -zdefs'
17986 archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
18533 archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
1798718534 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
17988 $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
18535 $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
1798918536
1799018537 hardcode_libdir_flag_spec_CXX='-R$libdir'
1799118538 hardcode_shlibpath_var_CXX=no
1799318540 solaris2.[0-5] | solaris2.[0-5].*) ;;
1799418541 *)
1799518542 # The compiler driver will combine and reorder linker options,
17996 # but understands `-z linker_flag'.
18543 # but understands '-z linker_flag'.
1799718544 # Supported since Solaris 2.6 (maybe 2.5.1?)
1799818545 whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract'
1799918546 ;;
1801018557 ;;
1801118558 gcx*)
1801218559 # Green Hills C++ Compiler
18013 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
18560 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
1801418561
1801518562 # The C++ compiler must be used to create the archive.
1801618563 old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
1801718564 ;;
1801818565 *)
1801918566 # GNU C++ compiler with Solaris linker
18020 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
18021 no_undefined_flag_CXX=' ${wl}-z ${wl}defs'
18567 if test yes,no = "$GXX,$with_gnu_ld"; then
18568 no_undefined_flag_CXX=' $wl-z ${wl}defs'
1802218569 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
18023 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
18570 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
1802418571 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
18025 $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
18572 $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
1802618573
1802718574 # Commands to make compiler produce verbose output that lists
1802818575 # what "hidden" libraries, object files and flags are used when
1802918576 # linking a shared library.
1803018577 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
1803118578 else
18032 # g++ 2.7 appears to require `-G' NOT `-shared' on this
18579 # g++ 2.7 appears to require '-G' NOT '-shared' on this
1803318580 # platform.
18034 archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
18581 archive_cmds_CXX='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
1803518582 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
18036 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
18583 $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
1803718584
1803818585 # Commands to make compiler produce verbose output that lists
1803918586 # what "hidden" libraries, object files and flags are used when
1804118588 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
1804218589 fi
1804318590
18044 hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir'
18591 hardcode_libdir_flag_spec_CXX='$wl-R $wl$libdir'
1804518592 case $host_os in
1804618593 solaris2.[0-5] | solaris2.[0-5].*) ;;
1804718594 *)
18048 whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
18595 whole_archive_flag_spec_CXX='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
1804918596 ;;
1805018597 esac
1805118598 fi
1805418601 ;;
1805518602
1805618603 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
18057 no_undefined_flag_CXX='${wl}-z,text'
18604 no_undefined_flag_CXX='$wl-z,text'
1805818605 archive_cmds_need_lc_CXX=no
1805918606 hardcode_shlibpath_var_CXX=no
1806018607 runpath_var='LD_RUN_PATH'
1806118608
1806218609 case $cc_basename in
1806318610 CC*)
18064 archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18065 archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18611 archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18612 archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1806618613 ;;
1806718614 *)
18068 archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18069 archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18615 archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18616 archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1807018617 ;;
1807118618 esac
1807218619 ;;
1807318620
1807418621 sysv5* | sco3.2v5* | sco5v6*)
18075 # Note: We can NOT use -z defs as we might desire, because we do not
18622 # Note: We CANNOT use -z defs as we might desire, because we do not
1807618623 # link with -lc, and that would cause any symbols used from libc to
1807718624 # always be unresolved, which means just about no library would
1807818625 # ever link correctly. If we're not using GNU ld we use -z text
1807918626 # though, which does catch some bad symbols but isn't as heavy-handed
1808018627 # as -z defs.
18081 no_undefined_flag_CXX='${wl}-z,text'
18082 allow_undefined_flag_CXX='${wl}-z,nodefs'
18628 no_undefined_flag_CXX='$wl-z,text'
18629 allow_undefined_flag_CXX='$wl-z,nodefs'
1808318630 archive_cmds_need_lc_CXX=no
1808418631 hardcode_shlibpath_var_CXX=no
18085 hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir'
18632 hardcode_libdir_flag_spec_CXX='$wl-R,$libdir'
1808618633 hardcode_libdir_separator_CXX=':'
1808718634 link_all_deplibs_CXX=yes
18088 export_dynamic_flag_spec_CXX='${wl}-Bexport'
18635 export_dynamic_flag_spec_CXX='$wl-Bexport'
1808918636 runpath_var='LD_RUN_PATH'
1809018637
1809118638 case $cc_basename in
1809218639 CC*)
18093 archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18094 archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18640 archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18641 archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1809518642 old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~
18096 '"$old_archive_cmds_CXX"
18643 '"$old_archive_cmds_CXX"
1809718644 reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~
18098 '"$reload_cmds_CXX"
18645 '"$reload_cmds_CXX"
1809918646 ;;
1810018647 *)
18101 archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18102 archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18648 archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
18649 archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
1810318650 ;;
1810418651 esac
1810518652 ;;
1813118678
1813218679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
1813318680 $as_echo "$ld_shlibs_CXX" >&6; }
18134 test "$ld_shlibs_CXX" = no && can_build_shared=no
18135
18136 GCC_CXX="$GXX"
18137 LD_CXX="$LD"
18681 test no = "$ld_shlibs_CXX" && can_build_shared=no
18682
18683 GCC_CXX=$GXX
18684 LD_CXX=$LD
1813818685
1813918686 ## CAVEAT EMPTOR:
1814018687 ## There is no encapsulation within the following macros, do not change
1817818725 pre_test_object_deps_done=no
1817918726
1818018727 for p in `eval "$output_verbose_link_cmd"`; do
18181 case ${prev}${p} in
18728 case $prev$p in
1818218729
1818318730 -L* | -R* | -l*)
1818418731 # Some compilers place space between "-{L,R}" and the path.
1818518732 # Remove the space.
18186 if test $p = "-L" ||
18187 test $p = "-R"; then
18733 if test x-L = "$p" ||
18734 test x-R = "$p"; then
1818818735 prev=$p
1818918736 continue
1819018737 fi
1820018747 case $p in
1820118748 =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
1820218749 esac
18203 if test "$pre_test_object_deps_done" = no; then
18204 case ${prev} in
18750 if test no = "$pre_test_object_deps_done"; then
18751 case $prev in
1820518752 -L | -R)
1820618753 # Internal compiler library paths should come after those
1820718754 # provided the user. The postdeps already come after the
1820818755 # user supplied libs so there is no need to process them.
1820918756 if test -z "$compiler_lib_search_path_CXX"; then
18210 compiler_lib_search_path_CXX="${prev}${p}"
18757 compiler_lib_search_path_CXX=$prev$p
1821118758 else
18212 compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}"
18759 compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} $prev$p"
1821318760 fi
1821418761 ;;
1821518762 # The "-l" case would never come before the object being
1821718764 esac
1821818765 else
1821918766 if test -z "$postdeps_CXX"; then
18220 postdeps_CXX="${prev}${p}"
18767 postdeps_CXX=$prev$p
1822118768 else
18222 postdeps_CXX="${postdeps_CXX} ${prev}${p}"
18769 postdeps_CXX="${postdeps_CXX} $prev$p"
1822318770 fi
1822418771 fi
1822518772 prev=
1823418781 continue
1823518782 fi
1823618783
18237 if test "$pre_test_object_deps_done" = no; then
18784 if test no = "$pre_test_object_deps_done"; then
1823818785 if test -z "$predep_objects_CXX"; then
18239 predep_objects_CXX="$p"
18786 predep_objects_CXX=$p
1824018787 else
1824118788 predep_objects_CXX="$predep_objects_CXX $p"
1824218789 fi
1824318790 else
1824418791 if test -z "$postdep_objects_CXX"; then
18245 postdep_objects_CXX="$p"
18792 postdep_objects_CXX=$p
1824618793 else
1824718794 postdep_objects_CXX="$postdep_objects_CXX $p"
1824818795 fi
1827218819 postdep_objects_CXX=
1827318820 postdeps_CXX=
1827418821 ;;
18275
18276 linux*)
18277 case `$CC -V 2>&1 | sed 5q` in
18278 *Sun\ C*)
18279 # Sun C++ 5.9
18280
18281 # The more standards-conforming stlport4 library is
18282 # incompatible with the Cstd library. Avoid specifying
18283 # it if it's in CXXFLAGS. Ignore libCrun as
18284 # -library=stlport4 depends on it.
18285 case " $CXX $CXXFLAGS " in
18286 *" -library=stlport4 "*)
18287 solaris_use_stlport4=yes
18288 ;;
18289 esac
18290
18291 if test "$solaris_use_stlport4" != yes; then
18292 postdeps_CXX='-library=Cstd -library=Crun'
18293 fi
18294 ;;
18295 esac
18296 ;;
18297
18298 solaris*)
18299 case $cc_basename in
18300 CC* | sunCC*)
18301 # The more standards-conforming stlport4 library is
18302 # incompatible with the Cstd library. Avoid specifying
18303 # it if it's in CXXFLAGS. Ignore libCrun as
18304 # -library=stlport4 depends on it.
18305 case " $CXX $CXXFLAGS " in
18306 *" -library=stlport4 "*)
18307 solaris_use_stlport4=yes
18308 ;;
18309 esac
18310
18311 # Adding this requires a known-good setup of shared libraries for
18312 # Sun compiler versions before 5.6, else PIC objects from an old
18313 # archive will be linked into the output, leading to subtle bugs.
18314 if test "$solaris_use_stlport4" != yes; then
18315 postdeps_CXX='-library=Cstd -library=Crun'
18316 fi
18317 ;;
18318 esac
18319 ;;
1832018822 esac
1832118823
1832218824
1832518827 esac
1832618828 compiler_lib_search_dirs_CXX=
1832718829 if test -n "${compiler_lib_search_path_CXX}"; then
18328 compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
18830 compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | $SED -e 's! -L! !g' -e 's!^ !!'`
1832918831 fi
1833018832
1833118833
1836418866
1836518867
1836618868 # C++ specific cases for pic, static, wl, etc.
18367 if test "$GXX" = yes; then
18869 if test yes = "$GXX"; then
1836818870 lt_prog_compiler_wl_CXX='-Wl,'
1836918871 lt_prog_compiler_static_CXX='-static'
1837018872
1837118873 case $host_os in
1837218874 aix*)
1837318875 # All AIX code is PIC.
18374 if test "$host_cpu" = ia64; then
18876 if test ia64 = "$host_cpu"; then
1837518877 # AIX 5 now supports IA64 processor
1837618878 lt_prog_compiler_static_CXX='-Bstatic'
1837718879 fi
18880 lt_prog_compiler_pic_CXX='-fPIC'
1837818881 ;;
1837918882
1838018883 amigaos*)
1838518888 ;;
1838618889 m68k)
1838718890 # FIXME: we need at least 68020 code to build shared libraries, but
18388 # adding the `-m68020' flag to GCC prevents building anything better,
18389 # like `-m68040'.
18891 # adding the '-m68020' flag to GCC prevents building anything better,
18892 # like '-m68040'.
1839018893 lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4'
1839118894 ;;
1839218895 esac
1840118904 # Although the cygwin gcc ignores -fPIC, still need this for old-style
1840218905 # (--disable-auto-import) libraries
1840318906 lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
18907 case $host_os in
18908 os2*)
18909 lt_prog_compiler_static_CXX='$wl-static'
18910 ;;
18911 esac
1840418912 ;;
1840518913 darwin* | rhapsody*)
1840618914 # PIC is the default on this platform
1845018958 case $host_os in
1845118959 aix[4-9]*)
1845218960 # All AIX code is PIC.
18453 if test "$host_cpu" = ia64; then
18961 if test ia64 = "$host_cpu"; then
1845418962 # AIX 5 now supports IA64 processor
1845518963 lt_prog_compiler_static_CXX='-Bstatic'
1845618964 else
1849018998 case $cc_basename in
1849118999 CC*)
1849219000 lt_prog_compiler_wl_CXX='-Wl,'
18493 lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
18494 if test "$host_cpu" != ia64; then
19001 lt_prog_compiler_static_CXX='$wl-a ${wl}archive'
19002 if test ia64 != "$host_cpu"; then
1849519003 lt_prog_compiler_pic_CXX='+Z'
1849619004 fi
1849719005 ;;
1849819006 aCC*)
1849919007 lt_prog_compiler_wl_CXX='-Wl,'
18500 lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
19008 lt_prog_compiler_static_CXX='$wl-a ${wl}archive'
1850119009 case $host_cpu in
1850219010 hppa*64*|ia64*)
1850319011 # +Z the default
1853419042 lt_prog_compiler_pic_CXX='-fPIC'
1853519043 ;;
1853619044 ecpc* )
18537 # old Intel C++ for x86_64 which still supported -KPIC.
19045 # old Intel C++ for x86_64, which still supported -KPIC.
1853819046 lt_prog_compiler_wl_CXX='-Wl,'
1853919047 lt_prog_compiler_pic_CXX='-KPIC'
1854019048 lt_prog_compiler_static_CXX='-static'
1859019098 ;;
1859119099 esac
1859219100 ;;
18593 netbsd* | netbsdelf*-gnu)
19101 netbsd*)
1859419102 ;;
1859519103 *qnx* | *nto*)
1859619104 # QNX uses GNU C++, but need to define -shared option too, otherwise
1867919187 fi
1868019188
1868119189 case $host_os in
18682 # For platforms which do not support PIC, -DPIC is meaningless:
19190 # For platforms that do not support PIC, -DPIC is meaningless:
1868319191 *djgpp*)
1868419192 lt_prog_compiler_pic_CXX=
1868519193 ;;
1871119219 lt_cv_prog_compiler_pic_works_CXX=no
1871219220 ac_outfile=conftest.$ac_objext
1871319221 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
18714 lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC"
19222 lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" ## exclude from sc_useless_quotes_in_assignment
1871519223 # Insert the option either (1) after the last *FLAGS variable, or
1871619224 # (2) before a word containing "conftest.", or (3) at the end.
1871719225 # Note that $ac_compile itself does not contain backslashes and begins
1874119249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5
1874219250 $as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; }
1874319251
18744 if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then
19252 if test yes = "$lt_cv_prog_compiler_pic_works_CXX"; then
1874519253 case $lt_prog_compiler_pic_CXX in
1874619254 "" | " "*) ;;
1874719255 *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;;
1876719275 $as_echo_n "(cached) " >&6
1876819276 else
1876919277 lt_cv_prog_compiler_static_works_CXX=no
18770 save_LDFLAGS="$LDFLAGS"
19278 save_LDFLAGS=$LDFLAGS
1877119279 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
1877219280 echo "$lt_simple_link_test_code" > conftest.$ac_ext
1877319281 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
1878619294 fi
1878719295 fi
1878819296 $RM -r conftest*
18789 LDFLAGS="$save_LDFLAGS"
19297 LDFLAGS=$save_LDFLAGS
1879019298
1879119299 fi
1879219300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5
1879319301 $as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; }
1879419302
18795 if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then
19303 if test yes = "$lt_cv_prog_compiler_static_works_CXX"; then
1879619304 :
1879719305 else
1879819306 lt_prog_compiler_static_CXX=
1890619414
1890719415
1890819416
18909 hard_links="nottested"
18910 if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then
19417 hard_links=nottested
19418 if test no = "$lt_cv_prog_compiler_c_o_CXX" && test no != "$need_locks"; then
1891119419 # do not overwrite the value of need_locks provided by the user
1891219420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
1891319421 $as_echo_n "checking if we can lock with hard links... " >&6; }
1891919427 ln conftest.a conftest.b 2>/dev/null && hard_links=no
1892019428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
1892119429 $as_echo "$hard_links" >&6; }
18922 if test "$hard_links" = no; then
18923 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
18924 $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
19430 if test no = "$hard_links"; then
19431 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
19432 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
1892519433 need_locks=warn
1892619434 fi
1892719435 else
1893819446 case $host_os in
1893919447 aix[4-9]*)
1894019448 # If we're using GNU nm, then we don't want the "-C" option.
18941 # -C means demangle to AIX nm, but means don't demangle with GNU nm
18942 # Also, AIX nm treats weak defined symbols like other global defined
18943 # symbols, whereas GNU nm marks them as "W".
19449 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
19450 # Without the "-l" option, or with the "-B" option, AIX nm treats
19451 # weak defined symbols like other global defined symbols, whereas
19452 # GNU nm marks them as "W".
19453 # While the 'weak' keyword is ignored in the Export File, we need
19454 # it in the Import File for the 'aix-soname' feature, so we have
19455 # to replace the "-B" option with "-P" for AIX nm.
1894419456 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
18945 export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
19457 export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
1894619458 else
18947 export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
19459 export_symbols_cmds_CXX='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
1894819460 fi
1894919461 ;;
1895019462 pw32*)
18951 export_symbols_cmds_CXX="$ltdll_cmds"
19463 export_symbols_cmds_CXX=$ltdll_cmds
1895219464 ;;
1895319465 cygwin* | mingw* | cegcc*)
1895419466 case $cc_basename in
1896119473 ;;
1896219474 esac
1896319475 ;;
18964 linux* | k*bsd*-gnu | gnu*)
18965 link_all_deplibs_CXX=no
18966 ;;
1896719476 *)
1896819477 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
1896919478 ;;
1897119480
1897219481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
1897319482 $as_echo "$ld_shlibs_CXX" >&6; }
18974 test "$ld_shlibs_CXX" = no && can_build_shared=no
19483 test no = "$ld_shlibs_CXX" && can_build_shared=no
1897519484
1897619485 with_gnu_ld_CXX=$with_gnu_ld
1897719486
1898819497 # Assume -lc should be added
1898919498 archive_cmds_need_lc_CXX=yes
1899019499
18991 if test "$enable_shared" = yes && test "$GCC" = yes; then
19500 if test yes,yes = "$GCC,$enable_shared"; then
1899219501 case $archive_cmds_CXX in
1899319502 *'~'*)
1899419503 # FIXME: we may have to deal with multi-command sequences.
1911619625 library_names_spec=
1911719626 libname_spec='lib$name'
1911819627 soname_spec=
19119 shrext_cmds=".so"
19628 shrext_cmds=.so
1912019629 postinstall_cmds=
1912119630 postuninstall_cmds=
1912219631 finish_cmds=
1913319642 # flags to be left without arguments
1913419643 need_version=unknown
1913519644
19645
19646
1913619647 case $host_os in
1913719648 aix3*)
1913819649 version_type=linux # correct to gnu/linux during the next big refactor
19139 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
19650 library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
1914019651 shlibpath_var=LIBPATH
1914119652
1914219653 # AIX 3 has no versioning support, so we append a major version to the name.
19143 soname_spec='${libname}${release}${shared_ext}$major'
19654 soname_spec='$libname$release$shared_ext$major'
1914419655 ;;
1914519656
1914619657 aix[4-9]*)
1914819659 need_lib_prefix=no
1914919660 need_version=no
1915019661 hardcode_into_libs=yes
19151 if test "$host_cpu" = ia64; then
19662 if test ia64 = "$host_cpu"; then
1915219663 # AIX 5 supports IA64
19153 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
19664 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
1915419665 shlibpath_var=LD_LIBRARY_PATH
1915519666 else
1915619667 # With GCC up to 2.95.x, collect2 would create an import file
1915719668 # for dependence libraries. The import file would start with
19158 # the line `#! .'. This would cause the generated library to
19159 # depend on `.', always an invalid library. This was fixed in
19669 # the line '#! .'. This would cause the generated library to
19670 # depend on '.', always an invalid library. This was fixed in
1916019671 # development snapshots of GCC prior to 3.0.
1916119672 case $host_os in
1916219673 aix4 | aix4.[01] | aix4.[01].*)
1916319674 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
1916419675 echo ' yes '
19165 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
19676 echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
1916619677 :
1916719678 else
1916819679 can_build_shared=no
1916919680 fi
1917019681 ;;
1917119682 esac
19172 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
19683 # Using Import Files as archive members, it is possible to support
19684 # filename-based versioning of shared library archives on AIX. While
19685 # this would work for both with and without runtime linking, it will
19686 # prevent static linking of such archives. So we do filename-based
19687 # shared library versioning with .so extension only, which is used
19688 # when both runtime linking and shared linking is enabled.
19689 # Unfortunately, runtime linking may impact performance, so we do
19690 # not want this to be the default eventually. Also, we use the
19691 # versioned .so libs for executables only if there is the -brtl
19692 # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
19693 # To allow for filename-based versioning support, we need to create
19694 # libNAME.so.V as an archive file, containing:
19695 # *) an Import File, referring to the versioned filename of the
19696 # archive as well as the shared archive member, telling the
19697 # bitwidth (32 or 64) of that shared object, and providing the
19698 # list of exported symbols of that shared object, eventually
19699 # decorated with the 'weak' keyword
19700 # *) the shared object with the F_LOADONLY flag set, to really avoid
19701 # it being seen by the linker.
19702 # At run time we better use the real file rather than another symlink,
19703 # but for link time we create the symlink libNAME.so -> libNAME.so.V
19704
19705 case $with_aix_soname,$aix_use_runtimelinking in
19706 # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
1917319707 # soname into executable. Probably we can add versioning support to
1917419708 # collect2, so additional links can be useful in future.
19175 if test "$aix_use_runtimelinking" = yes; then
19709 aix,yes) # traditional libtool
19710 dynamic_linker='AIX unversionable lib.so'
1917619711 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
1917719712 # instead of lib<name>.a to let people know that these are not
1917819713 # typical AIX shared libraries.
19179 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19180 else
19714 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
19715 ;;
19716 aix,no) # traditional AIX only
19717 dynamic_linker='AIX lib.a(lib.so.V)'
1918119718 # We preserve .a as extension for shared libraries through AIX4.2
1918219719 # and later when we are not doing run time linking.
19183 library_names_spec='${libname}${release}.a $libname.a'
19184 soname_spec='${libname}${release}${shared_ext}$major'
19185 fi
19720 library_names_spec='$libname$release.a $libname.a'
19721 soname_spec='$libname$release$shared_ext$major'
19722 ;;
19723 svr4,*) # full svr4 only
19724 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
19725 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
19726 # We do not specify a path in Import Files, so LIBPATH fires.
19727 shlibpath_overrides_runpath=yes
19728 ;;
19729 *,yes) # both, prefer svr4
19730 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
19731 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
19732 # unpreferred sharedlib libNAME.a needs extra handling
19733 postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"'
19734 postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"'
19735 # We do not specify a path in Import Files, so LIBPATH fires.
19736 shlibpath_overrides_runpath=yes
19737 ;;
19738 *,no) # both, prefer aix
19739 dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
19740 library_names_spec='$libname$release.a $libname.a'
19741 soname_spec='$libname$release$shared_ext$major'
19742 # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
19743 postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)'
19744 postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"'
19745 ;;
19746 esac
1918619747 shlibpath_var=LIBPATH
1918719748 fi
1918819749 ;;
1919219753 powerpc)
1919319754 # Since July 2007 AmigaOS4 officially supports .so libraries.
1919419755 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
19195 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19756 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
1919619757 ;;
1919719758 m68k)
1919819759 library_names_spec='$libname.ixlibrary $libname.a'
1919919760 # Create ${libname}_ixlibrary.a entries in /sys/libs.
19200 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
19761 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
1920119762 ;;
1920219763 esac
1920319764 ;;
1920419765
1920519766 beos*)
19206 library_names_spec='${libname}${shared_ext}'
19767 library_names_spec='$libname$shared_ext'
1920719768 dynamic_linker="$host_os ld.so"
1920819769 shlibpath_var=LIBRARY_PATH
1920919770 ;;
1921119772 bsdi[45]*)
1921219773 version_type=linux # correct to gnu/linux during the next big refactor
1921319774 need_version=no
19214 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19215 soname_spec='${libname}${release}${shared_ext}$major'
19775 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
19776 soname_spec='$libname$release$shared_ext$major'
1921619777 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
1921719778 shlibpath_var=LD_LIBRARY_PATH
1921819779 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
1922419785
1922519786 cygwin* | mingw* | pw32* | cegcc*)
1922619787 version_type=windows
19227 shrext_cmds=".dll"
19788 shrext_cmds=.dll
1922819789 need_version=no
1922919790 need_lib_prefix=no
1923019791
1923319794 # gcc
1923419795 library_names_spec='$libname.dll.a'
1923519796 # DLL is installed to $(libdir)/../bin by postinstall_cmds
19236 postinstall_cmds='base_file=`basename \${file}`~
19237 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
19797 postinstall_cmds='base_file=`basename \$file`~
19798 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
1923819799 dldir=$destdir/`dirname \$dlpath`~
1923919800 test -d \$dldir || mkdir -p \$dldir~
1924019801 $install_prog $dir/$dlname \$dldir/$dlname~
1925019811 case $host_os in
1925119812 cygwin*)
1925219813 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
19253 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
19814 soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
1925419815
1925519816 ;;
1925619817 mingw* | cegcc*)
1925719818 # MinGW DLLs use traditional 'lib' prefix
19258 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
19819 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
1925919820 ;;
1926019821 pw32*)
1926119822 # pw32 DLLs use 'pw' prefix rather than 'lib'
19262 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
19823 library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
1926319824 ;;
1926419825 esac
1926519826 dynamic_linker='Win32 ld.exe'
1926819829 *,cl*)
1926919830 # Native MSVC
1927019831 libname_spec='$name'
19271 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
19272 library_names_spec='${libname}.dll.lib'
19832 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
19833 library_names_spec='$libname.dll.lib'
1927319834
1927419835 case $build_os in
1927519836 mingw*)
1929619857 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
1929719858 ;;
1929819859 *)
19299 sys_lib_search_path_spec="$LIB"
19860 sys_lib_search_path_spec=$LIB
1930019861 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
1930119862 # It is most probably a Windows format PATH.
1930219863 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
1930919870 esac
1931019871
1931119872 # DLL is installed to $(libdir)/../bin by postinstall_cmds
19312 postinstall_cmds='base_file=`basename \${file}`~
19313 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
19873 postinstall_cmds='base_file=`basename \$file`~
19874 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
1931419875 dldir=$destdir/`dirname \$dlpath`~
1931519876 test -d \$dldir || mkdir -p \$dldir~
1931619877 $install_prog $dir/$dlname \$dldir/$dlname'
1932319884
1932419885 *)
1932519886 # Assume MSVC wrapper
19326 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
19887 library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
1932719888 dynamic_linker='Win32 ld.exe'
1932819889 ;;
1932919890 esac
1933619897 version_type=darwin
1933719898 need_lib_prefix=no
1933819899 need_version=no
19339 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
19340 soname_spec='${libname}${release}${major}$shared_ext'
19900 library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
19901 soname_spec='$libname$release$major$shared_ext'
1934119902 shlibpath_overrides_runpath=yes
1934219903 shlibpath_var=DYLD_LIBRARY_PATH
1934319904 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
1934919910 version_type=linux # correct to gnu/linux during the next big refactor
1935019911 need_lib_prefix=no
1935119912 need_version=no
19352 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
19353 soname_spec='${libname}${release}${shared_ext}$major'
19913 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
19914 soname_spec='$libname$release$shared_ext$major'
1935419915 shlibpath_var=LD_LIBRARY_PATH
1935519916 ;;
1935619917
1936819929 version_type=freebsd-$objformat
1936919930 case $version_type in
1937019931 freebsd-elf*)
19371 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
19932 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
19933 soname_spec='$libname$release$shared_ext$major'
1937219934 need_version=no
1937319935 need_lib_prefix=no
1937419936 ;;
1937519937 freebsd-*)
19376 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
19938 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
1937719939 need_version=yes
1937819940 ;;
1937919941 esac
1940319965 need_lib_prefix=no
1940419966 need_version=no
1940519967 dynamic_linker="$host_os runtime_loader"
19406 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
19407 soname_spec='${libname}${release}${shared_ext}$major'
19968 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
19969 soname_spec='$libname$release$shared_ext$major'
1940819970 shlibpath_var=LIBRARY_PATH
19409 shlibpath_overrides_runpath=yes
19971 shlibpath_overrides_runpath=no
1941019972 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
1941119973 hardcode_into_libs=yes
1941219974 ;;
1942419986 dynamic_linker="$host_os dld.so"
1942519987 shlibpath_var=LD_LIBRARY_PATH
1942619988 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
19427 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19428 soname_spec='${libname}${release}${shared_ext}$major'
19429 if test "X$HPUX_IA64_MODE" = X32; then
19989 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
19990 soname_spec='$libname$release$shared_ext$major'
19991 if test 32 = "$HPUX_IA64_MODE"; then
1943019992 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
19993 sys_lib_dlsearch_path_spec=/usr/lib/hpux32
1943119994 else
1943219995 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
19996 sys_lib_dlsearch_path_spec=/usr/lib/hpux64
1943319997 fi
19434 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1943519998 ;;
1943619999 hppa*64*)
1943720000 shrext_cmds='.sl'
1943920002 dynamic_linker="$host_os dld.sl"
1944020003 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
1944120004 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
19442 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19443 soname_spec='${libname}${release}${shared_ext}$major'
20005 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
20006 soname_spec='$libname$release$shared_ext$major'
1944420007 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
1944520008 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1944620009 ;;
1944920012 dynamic_linker="$host_os dld.sl"
1945020013 shlibpath_var=SHLIB_PATH
1945120014 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
19452 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19453 soname_spec='${libname}${release}${shared_ext}$major'
20015 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
20016 soname_spec='$libname$release$shared_ext$major'
1945420017 ;;
1945520018 esac
1945620019 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
1946320026 version_type=linux # correct to gnu/linux during the next big refactor
1946420027 need_lib_prefix=no
1946520028 need_version=no
19466 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
19467 soname_spec='${libname}${release}${shared_ext}$major'
20029 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
20030 soname_spec='$libname$release$shared_ext$major'
1946820031 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
1946920032 shlibpath_var=LD_LIBRARY_PATH
1947020033 shlibpath_overrides_runpath=no
1947520038 case $host_os in
1947620039 nonstopux*) version_type=nonstopux ;;
1947720040 *)
19478 if test "$lt_cv_prog_gnu_ld" = yes; then
20041 if test yes = "$lt_cv_prog_gnu_ld"; then
1947920042 version_type=linux # correct to gnu/linux during the next big refactor
1948020043 else
1948120044 version_type=irix
1948320046 esac
1948420047 need_lib_prefix=no
1948520048 need_version=no
19486 soname_spec='${libname}${release}${shared_ext}$major'
19487 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
20049 soname_spec='$libname$release$shared_ext$major'
20050 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
1948820051 case $host_os in
1948920052 irix5* | nonstopux*)
1949020053 libsuff= shlibsuff=
1950320066 esac
1950420067 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
1950520068 shlibpath_overrides_runpath=no
19506 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
19507 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
20069 sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
20070 sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
1950820071 hardcode_into_libs=yes
1950920072 ;;
1951020073
1951120074 # No shared lib support for Linux oldld, aout, or coff.
1951220075 linux*oldld* | linux*aout* | linux*coff*)
1951320076 dynamic_linker=no
20077 ;;
20078
20079 linux*android*)
20080 version_type=none # Android doesn't support versioned libraries.
20081 need_lib_prefix=no
20082 need_version=no
20083 library_names_spec='$libname$release$shared_ext'
20084 soname_spec='$libname$release$shared_ext'
20085 finish_cmds=
20086 shlibpath_var=LD_LIBRARY_PATH
20087 shlibpath_overrides_runpath=yes
20088
20089 # This implies no fast_install, which is unacceptable.
20090 # Some rework will be needed to allow for fast_install
20091 # before this can be enabled.
20092 hardcode_into_libs=yes
20093
20094 dynamic_linker='Android linker'
20095 # Don't embed -rpath directories since the linker doesn't support them.
20096 hardcode_libdir_flag_spec_CXX='-L$libdir'
1951420097 ;;
1951520098
1951620099 # This must be glibc/ELF.
1951820101 version_type=linux # correct to gnu/linux during the next big refactor
1951920102 need_lib_prefix=no
1952020103 need_version=no
19521 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19522 soname_spec='${libname}${release}${shared_ext}$major'
20104 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
20105 soname_spec='$libname$release$shared_ext$major'
1952320106 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
1952420107 shlibpath_var=LD_LIBRARY_PATH
1952520108 shlibpath_overrides_runpath=no
1957120154 # before this can be enabled.
1957220155 hardcode_into_libs=yes
1957320156
19574 # Append ld.so.conf contents to the search path
20157 # Ideally, we could use ldconfig to report *all* directores which are
20158 # searched for libraries, however this is still not possible. Aside from not
20159 # being certain /sbin/ldconfig is available, command
20160 # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
20161 # even though it is searched at run-time. Try to do the best guess by
20162 # appending ld.so.conf contents (and includes) to the search path.
1957520163 if test -f /etc/ld.so.conf; then
1957620164 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
1957720165 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
1958620174 dynamic_linker='GNU/Linux ld.so'
1958720175 ;;
1958820176
19589 netbsdelf*-gnu)
19590 version_type=linux
19591 need_lib_prefix=no
19592 need_version=no
19593 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
19594 soname_spec='${libname}${release}${shared_ext}$major'
19595 shlibpath_var=LD_LIBRARY_PATH
19596 shlibpath_overrides_runpath=no
19597 hardcode_into_libs=yes
19598 dynamic_linker='NetBSD ld.elf_so'
19599 ;;
19600
1960120177 netbsd*)
1960220178 version_type=sunos
1960320179 need_lib_prefix=no
1960420180 need_version=no
1960520181 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
19606 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
20182 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
1960720183 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
1960820184 dynamic_linker='NetBSD (a.out) ld.so'
1960920185 else
19610 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
19611 soname_spec='${libname}${release}${shared_ext}$major'
20186 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
20187 soname_spec='$libname$release$shared_ext$major'
1961220188 dynamic_linker='NetBSD ld.elf_so'
1961320189 fi
1961420190 shlibpath_var=LD_LIBRARY_PATH
1961820194
1961920195 newsos6)
1962020196 version_type=linux # correct to gnu/linux during the next big refactor
19621 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
20197 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
1962220198 shlibpath_var=LD_LIBRARY_PATH
1962320199 shlibpath_overrides_runpath=yes
1962420200 ;;
1962720203 version_type=qnx
1962820204 need_lib_prefix=no
1962920205 need_version=no
19630 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19631 soname_spec='${libname}${release}${shared_ext}$major'
20206 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
20207 soname_spec='$libname$release$shared_ext$major'
1963220208 shlibpath_var=LD_LIBRARY_PATH
1963320209 shlibpath_overrides_runpath=no
1963420210 hardcode_into_libs=yes
1963520211 dynamic_linker='ldqnx.so'
1963620212 ;;
1963720213
19638 openbsd*)
20214 openbsd* | bitrig*)
1963920215 version_type=sunos
19640 sys_lib_dlsearch_path_spec="/usr/lib"
20216 sys_lib_dlsearch_path_spec=/usr/lib
1964120217 need_lib_prefix=no
19642 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
19643 case $host_os in
19644 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
19645 *) need_version=no ;;
19646 esac
19647 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
20218 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
20219 need_version=no
20220 else
20221 need_version=yes
20222 fi
20223 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
1964820224 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
1964920225 shlibpath_var=LD_LIBRARY_PATH
19650 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
19651 case $host_os in
19652 openbsd2.[89] | openbsd2.[89].*)
19653 shlibpath_overrides_runpath=no
19654 ;;
19655 *)
19656 shlibpath_overrides_runpath=yes
19657 ;;
19658 esac
19659 else
19660 shlibpath_overrides_runpath=yes
19661 fi
20226 shlibpath_overrides_runpath=yes
1966220227 ;;
1966320228
1966420229 os2*)
1966520230 libname_spec='$name'
19666 shrext_cmds=".dll"
20231 version_type=windows
20232 shrext_cmds=.dll
20233 need_version=no
1966720234 need_lib_prefix=no
19668 library_names_spec='$libname${shared_ext} $libname.a'
20235 # OS/2 can only load a DLL with a base name of 8 characters or less.
20236 soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
20237 v=$($ECHO $release$versuffix | tr -d .-);
20238 n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
20239 $ECHO $n$v`$shared_ext'
20240 library_names_spec='${libname}_dll.$libext'
1966920241 dynamic_linker='OS/2 ld.exe'
19670 shlibpath_var=LIBPATH
20242 shlibpath_var=BEGINLIBPATH
20243 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
20244 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
20245 postinstall_cmds='base_file=`basename \$file`~
20246 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
20247 dldir=$destdir/`dirname \$dlpath`~
20248 test -d \$dldir || mkdir -p \$dldir~
20249 $install_prog $dir/$dlname \$dldir/$dlname~
20250 chmod a+x \$dldir/$dlname~
20251 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
20252 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
20253 fi'
20254 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
20255 dlpath=$dir/\$dldll~
20256 $RM \$dlpath'
1967120257 ;;
1967220258
1967320259 osf3* | osf4* | osf5*)
1967420260 version_type=osf
1967520261 need_lib_prefix=no
1967620262 need_version=no
19677 soname_spec='${libname}${release}${shared_ext}$major'
19678 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
20263 soname_spec='$libname$release$shared_ext$major'
20264 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
1967920265 shlibpath_var=LD_LIBRARY_PATH
1968020266 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
19681 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
20267 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
1968220268 ;;
1968320269
1968420270 rdos*)
1968920275 version_type=linux # correct to gnu/linux during the next big refactor
1969020276 need_lib_prefix=no
1969120277 need_version=no
19692 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19693 soname_spec='${libname}${release}${shared_ext}$major'
20278 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
20279 soname_spec='$libname$release$shared_ext$major'
1969420280 shlibpath_var=LD_LIBRARY_PATH
1969520281 shlibpath_overrides_runpath=yes
1969620282 hardcode_into_libs=yes
1970020286
1970120287 sunos4*)
1970220288 version_type=sunos
19703 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
20289 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
1970420290 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
1970520291 shlibpath_var=LD_LIBRARY_PATH
1970620292 shlibpath_overrides_runpath=yes
19707 if test "$with_gnu_ld" = yes; then
20293 if test yes = "$with_gnu_ld"; then
1970820294 need_lib_prefix=no
1970920295 fi
1971020296 need_version=yes
1971220298
1971320299 sysv4 | sysv4.3*)
1971420300 version_type=linux # correct to gnu/linux during the next big refactor
19715 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19716 soname_spec='${libname}${release}${shared_ext}$major'
20301 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
20302 soname_spec='$libname$release$shared_ext$major'
1971720303 shlibpath_var=LD_LIBRARY_PATH
1971820304 case $host_vendor in
1971920305 sni)
1973420320 ;;
1973520321
1973620322 sysv4*MP*)
19737 if test -d /usr/nec ;then
20323 if test -d /usr/nec; then
1973820324 version_type=linux # correct to gnu/linux during the next big refactor
19739 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
19740 soname_spec='$libname${shared_ext}.$major'
20325 library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
20326 soname_spec='$libname$shared_ext.$major'
1974120327 shlibpath_var=LD_LIBRARY_PATH
1974220328 fi
1974320329 ;;
1974420330
1974520331 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
19746 version_type=freebsd-elf
20332 version_type=sco
1974720333 need_lib_prefix=no
1974820334 need_version=no
19749 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
19750 soname_spec='${libname}${release}${shared_ext}$major'
20335 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
20336 soname_spec='$libname$release$shared_ext$major'
1975120337 shlibpath_var=LD_LIBRARY_PATH
1975220338 shlibpath_overrides_runpath=yes
1975320339 hardcode_into_libs=yes
19754 if test "$with_gnu_ld" = yes; then
20340 if test yes = "$with_gnu_ld"; then
1975520341 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
1975620342 else
1975720343 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
1976920355 version_type=linux # correct to gnu/linux during the next big refactor
1977020356 need_lib_prefix=no
1977120357 need_version=no
19772 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
20358 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
1977320359 shlibpath_var=LD_LIBRARY_PATH
1977420360 shlibpath_overrides_runpath=no
1977520361 hardcode_into_libs=yes
1977720363
1977820364 uts4*)
1977920365 version_type=linux # correct to gnu/linux during the next big refactor
19780 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19781 soname_spec='${libname}${release}${shared_ext}$major'
20366 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
20367 soname_spec='$libname$release$shared_ext$major'
1978220368 shlibpath_var=LD_LIBRARY_PATH
1978320369 ;;
1978420370
1978820374 esac
1978920375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
1979020376 $as_echo "$dynamic_linker" >&6; }
19791 test "$dynamic_linker" = no && can_build_shared=no
20377 test no = "$dynamic_linker" && can_build_shared=no
1979220378
1979320379 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
19794 if test "$GCC" = yes; then
20380 if test yes = "$GCC"; then
1979520381 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
1979620382 fi
1979720383
19798 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
19799 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
19800 fi
19801 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
19802 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
19803 fi
20384 if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
20385 sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
20386 fi
20387
20388 if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
20389 sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
20390 fi
20391
20392 # remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
20393 configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
20394
20395 # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
20396 func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
20397
20398 # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
20399 configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
20400
20401
1980420402
1980520403
1980620404
1984420442 hardcode_action_CXX=
1984520443 if test -n "$hardcode_libdir_flag_spec_CXX" ||
1984620444 test -n "$runpath_var_CXX" ||
19847 test "X$hardcode_automatic_CXX" = "Xyes" ; then
20445 test yes = "$hardcode_automatic_CXX"; then
1984820446
1984920447 # We can hardcode non-existent directories.
19850 if test "$hardcode_direct_CXX" != no &&
20448 if test no != "$hardcode_direct_CXX" &&
1985120449 # If the only mechanism to avoid hardcoding is shlibpath_var, we
1985220450 # have to relink, otherwise we might link with an installed library
1985320451 # when we should be linking with a yet-to-be-installed one
19854 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no &&
19855 test "$hardcode_minus_L_CXX" != no; then
20452 ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" &&
20453 test no != "$hardcode_minus_L_CXX"; then
1985620454 # Linking always hardcodes the temporary library directory.
1985720455 hardcode_action_CXX=relink
1985820456 else
1986720465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5
1986820466 $as_echo "$hardcode_action_CXX" >&6; }
1986920467
19870 if test "$hardcode_action_CXX" = relink ||
19871 test "$inherit_rpath_CXX" = yes; then
20468 if test relink = "$hardcode_action_CXX" ||
20469 test yes = "$inherit_rpath_CXX"; then
1987220470 # Fast installation is not supported
1987320471 enable_fast_install=no
19874 elif test "$shlibpath_overrides_runpath" = yes ||
19875 test "$enable_shared" = no; then
20472 elif test yes = "$shlibpath_overrides_runpath" ||
20473 test no = "$enable_shared"; then
1987620474 # Fast installation is not necessary
1987720475 enable_fast_install=needless
1987820476 fi
1989520493 lt_cv_path_LD=$lt_save_path_LD
1989620494 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
1989720495 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
19898 fi # test "$_lt_caught_CXX_error" != yes
20496 fi # test yes != "$_lt_caught_CXX_error"
1989920497
1990020498 ac_ext=c
1990120499 ac_cpp='$CPP $CPPFLAGS'
1991320511 ac_compiler_gnu=$ac_cv_fc_compiler_gnu
1991420512
1991520513
19916 if test -z "$FC" || test "X$FC" = "Xno"; then
20514 if test -z "$FC" || test no = "$FC"; then
1991720515 _lt_disable_FC=yes
1991820516 fi
1991920517
1995020548 # the FC compiler isn't working. Some variables (like enable_shared)
1995120549 # are currently assumed to apply to all compilers on this platform,
1995220550 # and will be corrupted by setting them based on a non-working compiler.
19953 if test "$_lt_disable_FC" != yes; then
20551 if test yes != "$_lt_disable_FC"; then
1995420552 # Code to be used in simple compile tests
1995520553 lt_simple_compile_test_code="\
1995620554 subroutine t
1999620594
1999720595
1999820596 # Allow CC to be a program name with arguments.
19999 lt_save_CC="$CC"
20597 lt_save_CC=$CC
2000020598 lt_save_GCC=$GCC
2000120599 lt_save_CFLAGS=$CFLAGS
2000220600 CC=${FC-"f95"}
2000520603 GCC=$ac_cv_fc_compiler_gnu
2000620604
2000720605 compiler_FC=$CC
20008 for cc_temp in $compiler""; do
20009 case $cc_temp in
20010 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
20011 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
20012 \-*) ;;
20013 *) break;;
20014 esac
20015 done
20016 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
20606 func_cc_basename $compiler
20607 cc_basename=$func_cc_basename_result
2001720608
2001820609
2001920610 if test -n "$compiler"; then
2002420615
2002520616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
2002620617 $as_echo_n "checking whether to build shared libraries... " >&6; }
20027 test "$can_build_shared" = "no" && enable_shared=no
20618 test no = "$can_build_shared" && enable_shared=no
2002820619
2002920620 # On AIX, shared libraries and static libraries use the same namespace, and
2003020621 # are all built from PIC.
2003120622 case $host_os in
2003220623 aix3*)
20033 test "$enable_shared" = yes && enable_static=no
20624 test yes = "$enable_shared" && enable_static=no
2003420625 if test -n "$RANLIB"; then
2003520626 archive_cmds="$archive_cmds~\$RANLIB \$lib"
2003620627 postinstall_cmds='$RANLIB $lib'
2003720628 fi
2003820629 ;;
2003920630 aix[4-9]*)
20040 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
20041 test "$enable_shared" = yes && enable_static=no
20631 if test ia64 != "$host_cpu"; then
20632 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
20633 yes,aix,yes) ;; # shared object as lib.so file only
20634 yes,svr4,*) ;; # shared object as lib.so archive member only
20635 yes,*) enable_static=no ;; # shared object in lib.a archive as well
20636 esac
2004220637 fi
2004320638 ;;
2004420639 esac
2004820643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
2004920644 $as_echo_n "checking whether to build static libraries... " >&6; }
2005020645 # Make sure either enable_shared or enable_static is yes.
20051 test "$enable_shared" = yes || enable_static=yes
20646 test yes = "$enable_shared" || enable_static=yes
2005220647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
2005320648 $as_echo "$enable_static" >&6; }
2005420649
20055 GCC_FC="$ac_cv_fc_compiler_gnu"
20056 LD_FC="$LD"
20650 GCC_FC=$ac_cv_fc_compiler_gnu
20651 LD_FC=$LD
2005720652
2005820653 ## CAVEAT EMPTOR:
2005920654 ## There is no encapsulation within the following macros, do not change
2009620691 pre_test_object_deps_done=no
2009720692
2009820693 for p in `eval "$output_verbose_link_cmd"`; do
20099 case ${prev}${p} in
20694 case $prev$p in
2010020695
2010120696 -L* | -R* | -l*)
2010220697 # Some compilers place space between "-{L,R}" and the path.
2010320698 # Remove the space.
20104 if test $p = "-L" ||
20105 test $p = "-R"; then
20699 if test x-L = "$p" ||
20700 test x-R = "$p"; then
2010620701 prev=$p
2010720702 continue
2010820703 fi
2011820713 case $p in
2011920714 =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
2012020715 esac
20121 if test "$pre_test_object_deps_done" = no; then
20122 case ${prev} in
20716 if test no = "$pre_test_object_deps_done"; then
20717 case $prev in
2012320718 -L | -R)
2012420719 # Internal compiler library paths should come after those
2012520720 # provided the user. The postdeps already come after the
2012620721 # user supplied libs so there is no need to process them.
2012720722 if test -z "$compiler_lib_search_path_FC"; then
20128 compiler_lib_search_path_FC="${prev}${p}"
20723 compiler_lib_search_path_FC=$prev$p
2012920724 else
20130 compiler_lib_search_path_FC="${compiler_lib_search_path_FC} ${prev}${p}"
20725 compiler_lib_search_path_FC="${compiler_lib_search_path_FC} $prev$p"
2013120726 fi
2013220727 ;;
2013320728 # The "-l" case would never come before the object being
2013520730 esac
2013620731 else
2013720732 if test -z "$postdeps_FC"; then
20138 postdeps_FC="${prev}${p}"
20733 postdeps_FC=$prev$p
2013920734 else
20140 postdeps_FC="${postdeps_FC} ${prev}${p}"
20735 postdeps_FC="${postdeps_FC} $prev$p"
2014120736 fi
2014220737 fi
2014320738 prev=
2015220747 continue
2015320748 fi
2015420749
20155 if test "$pre_test_object_deps_done" = no; then
20750 if test no = "$pre_test_object_deps_done"; then
2015620751 if test -z "$predep_objects_FC"; then
20157 predep_objects_FC="$p"
20752 predep_objects_FC=$p
2015820753 else
2015920754 predep_objects_FC="$predep_objects_FC $p"
2016020755 fi
2016120756 else
2016220757 if test -z "$postdep_objects_FC"; then
20163 postdep_objects_FC="$p"
20758 postdep_objects_FC=$p
2016420759 else
2016520760 postdep_objects_FC="$postdep_objects_FC $p"
2016620761 fi
2018920784 esac
2019020785 compiler_lib_search_dirs_FC=
2019120786 if test -n "${compiler_lib_search_path_FC}"; then
20192 compiler_lib_search_dirs_FC=`echo " ${compiler_lib_search_path_FC}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
20787 compiler_lib_search_dirs_FC=`echo " ${compiler_lib_search_path_FC}" | $SED -e 's! -L! !g' -e 's!^ !!'`
2019320788 fi
2019420789
2019520790
2020920804 lt_prog_compiler_static_FC=
2021020805
2021120806
20212 if test "$GCC" = yes; then
20807 if test yes = "$GCC"; then
2021320808 lt_prog_compiler_wl_FC='-Wl,'
2021420809 lt_prog_compiler_static_FC='-static'
2021520810
2021620811 case $host_os in
2021720812 aix*)
2021820813 # All AIX code is PIC.
20219 if test "$host_cpu" = ia64; then
20814 if test ia64 = "$host_cpu"; then
2022020815 # AIX 5 now supports IA64 processor
2022120816 lt_prog_compiler_static_FC='-Bstatic'
2022220817 fi
20818 lt_prog_compiler_pic_FC='-fPIC'
2022320819 ;;
2022420820
2022520821 amigaos*)
2023020826 ;;
2023120827 m68k)
2023220828 # FIXME: we need at least 68020 code to build shared libraries, but
20233 # adding the `-m68020' flag to GCC prevents building anything better,
20234 # like `-m68040'.
20829 # adding the '-m68020' flag to GCC prevents building anything better,
20830 # like '-m68040'.
2023520831 lt_prog_compiler_pic_FC='-m68020 -resident32 -malways-restore-a4'
2023620832 ;;
2023720833 esac
2024720843 # Although the cygwin gcc ignores -fPIC, still need this for old-style
2024820844 # (--disable-auto-import) libraries
2024920845 lt_prog_compiler_pic_FC='-DDLL_EXPORT'
20846 case $host_os in
20847 os2*)
20848 lt_prog_compiler_static_FC='$wl-static'
20849 ;;
20850 esac
2025020851 ;;
2025120852
2025220853 darwin* | rhapsody*)
2031720918 case $host_os in
2031820919 aix*)
2031920920 lt_prog_compiler_wl_FC='-Wl,'
20320 if test "$host_cpu" = ia64; then
20921 if test ia64 = "$host_cpu"; then
2032120922 # AIX 5 now supports IA64 processor
2032220923 lt_prog_compiler_static_FC='-Bstatic'
2032320924 else
2032520926 fi
2032620927 ;;
2032720928
20929 darwin* | rhapsody*)
20930 # PIC is the default on this platform
20931 # Common symbols not allowed in MH_DYLIB files
20932 lt_prog_compiler_pic_FC='-fno-common'
20933 case $cc_basename in
20934 nagfor*)
20935 # NAG Fortran compiler
20936 lt_prog_compiler_wl_FC='-Wl,-Wl,,'
20937 lt_prog_compiler_pic_FC='-PIC'
20938 lt_prog_compiler_static_FC='-Bstatic'
20939 ;;
20940 esac
20941 ;;
20942
2032820943 mingw* | cygwin* | pw32* | os2* | cegcc*)
2032920944 # This hack is so that the source file can tell whether it is being
2033020945 # built for inclusion in a dll (and should export symbols for example).
2033120946 lt_prog_compiler_pic_FC='-DDLL_EXPORT'
20947 case $host_os in
20948 os2*)
20949 lt_prog_compiler_static_FC='$wl-static'
20950 ;;
20951 esac
2033220952 ;;
2033320953
2033420954 hpux9* | hpux10* | hpux11*)
2034420964 ;;
2034520965 esac
2034620966 # Is there a better lt_prog_compiler_static that works with the bundled CC?
20347 lt_prog_compiler_static_FC='${wl}-a ${wl}archive'
20967 lt_prog_compiler_static_FC='$wl-a ${wl}archive'
2034820968 ;;
2034920969
2035020970 irix5* | irix6* | nonstopux*)
2035520975
2035620976 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
2035720977 case $cc_basename in
20358 # old Intel for x86_64 which still supported -KPIC.
20978 # old Intel for x86_64, which still supported -KPIC.
2035920979 ecc*)
2036020980 lt_prog_compiler_wl_FC='-Wl,'
2036120981 lt_prog_compiler_pic_FC='-KPIC'
2037920999 lt_prog_compiler_wl_FC='-Wl,-Wl,,'
2038021000 lt_prog_compiler_pic_FC='-PIC'
2038121001 lt_prog_compiler_static_FC='-Bstatic'
21002 ;;
21003 tcc*)
21004 # Fabrice Bellard et al's Tiny C Compiler
21005 lt_prog_compiler_wl_FC='-Wl,'
21006 lt_prog_compiler_pic_FC='-fPIC'
21007 lt_prog_compiler_static_FC='-static'
2038221008 ;;
2038321009 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
2038421010 # Portland Group compilers (*not* the Pentium gcc compiler,
2047721103 ;;
2047821104
2047921105 sysv4*MP*)
20480 if test -d /usr/nec ;then
21106 if test -d /usr/nec; then
2048121107 lt_prog_compiler_pic_FC='-Kconform_pic'
2048221108 lt_prog_compiler_static_FC='-Bstatic'
2048321109 fi
2050621132 fi
2050721133
2050821134 case $host_os in
20509 # For platforms which do not support PIC, -DPIC is meaningless:
21135 # For platforms that do not support PIC, -DPIC is meaningless:
2051021136 *djgpp*)
2051121137 lt_prog_compiler_pic_FC=
2051221138 ;;
2053821164 lt_cv_prog_compiler_pic_works_FC=no
2053921165 ac_outfile=conftest.$ac_objext
2054021166 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
20541 lt_compiler_flag="$lt_prog_compiler_pic_FC"
21167 lt_compiler_flag="$lt_prog_compiler_pic_FC" ## exclude from sc_useless_quotes_in_assignment
2054221168 # Insert the option either (1) after the last *FLAGS variable, or
2054321169 # (2) before a word containing "conftest.", or (3) at the end.
2054421170 # Note that $ac_compile itself does not contain backslashes and begins
2056821194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_FC" >&5
2056921195 $as_echo "$lt_cv_prog_compiler_pic_works_FC" >&6; }
2057021196
20571 if test x"$lt_cv_prog_compiler_pic_works_FC" = xyes; then
21197 if test yes = "$lt_cv_prog_compiler_pic_works_FC"; then
2057221198 case $lt_prog_compiler_pic_FC in
2057321199 "" | " "*) ;;
2057421200 *) lt_prog_compiler_pic_FC=" $lt_prog_compiler_pic_FC" ;;
2059421220 $as_echo_n "(cached) " >&6
2059521221 else
2059621222 lt_cv_prog_compiler_static_works_FC=no
20597 save_LDFLAGS="$LDFLAGS"
21223 save_LDFLAGS=$LDFLAGS
2059821224 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
2059921225 echo "$lt_simple_link_test_code" > conftest.$ac_ext
2060021226 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
2061321239 fi
2061421240 fi
2061521241 $RM -r conftest*
20616 LDFLAGS="$save_LDFLAGS"
21242 LDFLAGS=$save_LDFLAGS
2061721243
2061821244 fi
2061921245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_FC" >&5
2062021246 $as_echo "$lt_cv_prog_compiler_static_works_FC" >&6; }
2062121247
20622 if test x"$lt_cv_prog_compiler_static_works_FC" = xyes; then
21248 if test yes = "$lt_cv_prog_compiler_static_works_FC"; then
2062321249 :
2062421250 else
2062521251 lt_prog_compiler_static_FC=
2073321359
2073421360
2073521361
20736 hard_links="nottested"
20737 if test "$lt_cv_prog_compiler_c_o_FC" = no && test "$need_locks" != no; then
21362 hard_links=nottested
21363 if test no = "$lt_cv_prog_compiler_c_o_FC" && test no != "$need_locks"; then
2073821364 # do not overwrite the value of need_locks provided by the user
2073921365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
2074021366 $as_echo_n "checking if we can lock with hard links... " >&6; }
2074621372 ln conftest.a conftest.b 2>/dev/null && hard_links=no
2074721373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
2074821374 $as_echo "$hard_links" >&6; }
20749 if test "$hard_links" = no; then
20750 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
20751 $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
21375 if test no = "$hard_links"; then
21376 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
21377 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
2075221378 need_locks=warn
2075321379 fi
2075421380 else
2078821414 # included in the symbol list
2078921415 include_expsyms_FC=
2079021416 # exclude_expsyms can be an extended regexp of symbols to exclude
20791 # it will be wrapped by ` (' and `)$', so one must not match beginning or
20792 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
20793 # as well as any symbol that contains `d'.
21417 # it will be wrapped by ' (' and ')$', so one must not match beginning or
21418 # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
21419 # as well as any symbol that contains 'd'.
2079421420 exclude_expsyms_FC='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
2079521421 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
2079621422 # platforms (ab)use it in PIC code, but their linkers get confused if
2080521431 # FIXME: the MSVC++ port hasn't been tested in a loooong time
2080621432 # When not using gcc, we currently assume that we are using
2080721433 # Microsoft Visual C++.
20808 if test "$GCC" != yes; then
21434 if test yes != "$GCC"; then
2080921435 with_gnu_ld=no
2081021436 fi
2081121437 ;;
2081321439 # we just hope/assume this is gcc and not c89 (= MSVC++)
2081421440 with_gnu_ld=yes
2081521441 ;;
20816 openbsd*)
21442 openbsd* | bitrig*)
2081721443 with_gnu_ld=no
20818 ;;
20819 linux* | k*bsd*-gnu | gnu*)
20820 link_all_deplibs_FC=no
2082121444 ;;
2082221445 esac
2082321446
2082621449 # On some targets, GNU ld is compatible enough with the native linker
2082721450 # that we're better off using the native interface for both.
2082821451 lt_use_gnu_ld_interface=no
20829 if test "$with_gnu_ld" = yes; then
21452 if test yes = "$with_gnu_ld"; then
2083021453 case $host_os in
2083121454 aix*)
2083221455 # The AIX port of GNU ld has always aspired to compatibility
2084821471 esac
2084921472 fi
2085021473
20851 if test "$lt_use_gnu_ld_interface" = yes; then
21474 if test yes = "$lt_use_gnu_ld_interface"; then
2085221475 # If archive_cmds runs LD, not CC, wlarc should be empty
20853 wlarc='${wl}'
21476 wlarc='$wl'
2085421477
2085521478 # Set some defaults for GNU ld with shared library support. These
2085621479 # are reset later if shared libraries are not supported. Putting them
2085721480 # here allows them to be overridden if necessary.
2085821481 runpath_var=LD_RUN_PATH
20859 hardcode_libdir_flag_spec_FC='${wl}-rpath ${wl}$libdir'
20860 export_dynamic_flag_spec_FC='${wl}--export-dynamic'
21482 hardcode_libdir_flag_spec_FC='$wl-rpath $wl$libdir'
21483 export_dynamic_flag_spec_FC='$wl--export-dynamic'
2086121484 # ancient GNU ld didn't support --whole-archive et. al.
2086221485 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
20863 whole_archive_flag_spec_FC="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
21486 whole_archive_flag_spec_FC=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
2086421487 else
2086521488 whole_archive_flag_spec_FC=
2086621489 fi
2086721490 supports_anon_versioning=no
20868 case `$LD -v 2>&1` in
21491 case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in
2086921492 *GNU\ gold*) supports_anon_versioning=yes ;;
2087021493 *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
2087121494 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
2087821501 case $host_os in
2087921502 aix[3-9]*)
2088021503 # On AIX/PPC, the GNU linker is very broken
20881 if test "$host_cpu" != ia64; then
21504 if test ia64 != "$host_cpu"; then
2088221505 ld_shlibs_FC=no
2088321506 cat <<_LT_EOF 1>&2
2088421507
2089721520 case $host_cpu in
2089821521 powerpc)
2089921522 # see comment about AmigaOS4 .so support
20900 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
21523 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
2090121524 archive_expsym_cmds_FC=''
2090221525 ;;
2090321526 m68k)
2091321536 allow_undefined_flag_FC=unsupported
2091421537 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
2091521538 # support --undefined. This deserves some investigation. FIXME
20916 archive_cmds_FC='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
21539 archive_cmds_FC='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
2091721540 else
2091821541 ld_shlibs_FC=no
2091921542 fi
2092321546 # _LT_TAGVAR(hardcode_libdir_flag_spec, FC) is actually meaningless,
2092421547 # as there is no search path for DLLs.
2092521548 hardcode_libdir_flag_spec_FC='-L$libdir'
20926 export_dynamic_flag_spec_FC='${wl}--export-all-symbols'
21549 export_dynamic_flag_spec_FC='$wl--export-all-symbols'
2092721550 allow_undefined_flag_FC=unsupported
2092821551 always_export_symbols_FC=no
2092921552 enable_shared_with_static_runtimes_FC=yes
2093121554 exclude_expsyms_FC='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
2093221555
2093321556 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
20934 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
20935 # If the export-symbols file already is a .def file (1st line
20936 # is EXPORTS), use it as is; otherwise, prepend...
20937 archive_expsym_cmds_FC='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
20938 cp $export_symbols $output_objdir/$soname.def;
20939 else
20940 echo EXPORTS > $output_objdir/$soname.def;
20941 cat $export_symbols >> $output_objdir/$soname.def;
20942 fi~
20943 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
21557 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
21558 # If the export-symbols file already is a .def file, use it as
21559 # is; otherwise, prepend EXPORTS...
21560 archive_expsym_cmds_FC='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
21561 cp $export_symbols $output_objdir/$soname.def;
21562 else
21563 echo EXPORTS > $output_objdir/$soname.def;
21564 cat $export_symbols >> $output_objdir/$soname.def;
21565 fi~
21566 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
2094421567 else
2094521568 ld_shlibs_FC=no
2094621569 fi
2094721570 ;;
2094821571
2094921572 haiku*)
20950 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
21573 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
2095121574 link_all_deplibs_FC=yes
21575 ;;
21576
21577 os2*)
21578 hardcode_libdir_flag_spec_FC='-L$libdir'
21579 hardcode_minus_L_FC=yes
21580 allow_undefined_flag_FC=unsupported
21581 shrext_cmds=.dll
21582 archive_cmds_FC='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
21583 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
21584 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
21585 $ECHO EXPORTS >> $output_objdir/$libname.def~
21586 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
21587 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
21588 emximp -o $lib $output_objdir/$libname.def'
21589 archive_expsym_cmds_FC='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
21590 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
21591 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
21592 $ECHO EXPORTS >> $output_objdir/$libname.def~
21593 prefix_cmds="$SED"~
21594 if test EXPORTS = "`$SED 1q $export_symbols`"; then
21595 prefix_cmds="$prefix_cmds -e 1d";
21596 fi~
21597 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
21598 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
21599 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
21600 emximp -o $lib $output_objdir/$libname.def'
21601 old_archive_From_new_cmds_FC='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
21602 enable_shared_with_static_runtimes_FC=yes
2095221603 ;;
2095321604
2095421605 interix[3-9]*)
2095521606 hardcode_direct_FC=no
2095621607 hardcode_shlibpath_var_FC=no
20957 hardcode_libdir_flag_spec_FC='${wl}-rpath,$libdir'
20958 export_dynamic_flag_spec_FC='${wl}-E'
21608 hardcode_libdir_flag_spec_FC='$wl-rpath,$libdir'
21609 export_dynamic_flag_spec_FC='$wl-E'
2095921610 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
2096021611 # Instead, shared libraries are loaded at an image base (0x10000000 by
2096121612 # default) and relocated if they conflict, which is a slow very memory
2096221613 # consuming and fragmenting process. To avoid this, we pick a random,
2096321614 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
2096421615 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
20965 archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
20966 archive_expsym_cmds_FC='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
21616 archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
21617 archive_expsym_cmds_FC='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
2096721618 ;;
2096821619
2096921620 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
2097021621 tmp_diet=no
20971 if test "$host_os" = linux-dietlibc; then
21622 if test linux-dietlibc = "$host_os"; then
2097221623 case $cc_basename in
2097321624 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
2097421625 esac
2097521626 fi
2097621627 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
20977 && test "$tmp_diet" = no
21628 && test no = "$tmp_diet"
2097821629 then
2097921630 tmp_addflag=' $pic_flag'
2098021631 tmp_sharedflag='-shared'
2098121632 case $cc_basename,$host_cpu in
2098221633 pgcc*) # Portland Group C compiler
20983 whole_archive_flag_spec_FC='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
21634 whole_archive_flag_spec_FC='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
2098421635 tmp_addflag=' $pic_flag'
2098521636 ;;
2098621637 pgf77* | pgf90* | pgf95* | pgfortran*)
2098721638 # Portland Group f77 and f90 compilers
20988 whole_archive_flag_spec_FC='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
21639 whole_archive_flag_spec_FC='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
2098921640 tmp_addflag=' $pic_flag -Mnomain' ;;
2099021641 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
2099121642 tmp_addflag=' -i_dynamic' ;;
2099621647 lf95*) # Lahey Fortran 8.1
2099721648 whole_archive_flag_spec_FC=
2099821649 tmp_sharedflag='--shared' ;;
21650 nagfor*) # NAGFOR 5.3
21651 tmp_sharedflag='-Wl,-shared' ;;
2099921652 xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
2100021653 tmp_sharedflag='-qmkshrobj'
2100121654 tmp_addflag= ;;
2100221655 nvcc*) # Cuda Compiler Driver 2.2
21003 whole_archive_flag_spec_FC='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
21656 whole_archive_flag_spec_FC='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
2100421657 compiler_needs_object_FC=yes
2100521658 ;;
2100621659 esac
2100721660 case `$CC -V 2>&1 | sed 5q` in
2100821661 *Sun\ C*) # Sun C 5.9
21009 whole_archive_flag_spec_FC='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
21662 whole_archive_flag_spec_FC='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
2101021663 compiler_needs_object_FC=yes
2101121664 tmp_sharedflag='-G' ;;
2101221665 *Sun\ F*) # Sun Fortran 8.3
2101321666 tmp_sharedflag='-G' ;;
2101421667 esac
21015 archive_cmds_FC='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
21016
21017 if test "x$supports_anon_versioning" = xyes; then
21668 archive_cmds_FC='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
21669
21670 if test yes = "$supports_anon_versioning"; then
2101821671 archive_expsym_cmds_FC='echo "{ global:" > $output_objdir/$libname.ver~
21019 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
21020 echo "local: *; };" >> $output_objdir/$libname.ver~
21021 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
21672 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
21673 echo "local: *; };" >> $output_objdir/$libname.ver~
21674 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
2102221675 fi
2102321676
2102421677 case $cc_basename in
21678 tcc*)
21679 export_dynamic_flag_spec_FC='-rdynamic'
21680 ;;
2102521681 xlf* | bgf* | bgxlf* | mpixlf*)
2102621682 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
2102721683 whole_archive_flag_spec_FC='--whole-archive$convenience --no-whole-archive'
21028 hardcode_libdir_flag_spec_FC='${wl}-rpath ${wl}$libdir'
21684 hardcode_libdir_flag_spec_FC='$wl-rpath $wl$libdir'
2102921685 archive_cmds_FC='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
21030 if test "x$supports_anon_versioning" = xyes; then
21686 if test yes = "$supports_anon_versioning"; then
2103121687 archive_expsym_cmds_FC='echo "{ global:" > $output_objdir/$libname.ver~
21032 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
21033 echo "local: *; };" >> $output_objdir/$libname.ver~
21034 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
21688 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
21689 echo "local: *; };" >> $output_objdir/$libname.ver~
21690 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
2103521691 fi
2103621692 ;;
2103721693 esac
2104021696 fi
2104121697 ;;
2104221698
21043 netbsd* | netbsdelf*-gnu)
21699 netbsd*)
2104421700 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
2104521701 archive_cmds_FC='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
2104621702 wlarc=
2104721703 else
21048 archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
21049 archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
21704 archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
21705 archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
2105021706 fi
2105121707 ;;
2105221708
2106421720
2106521721 _LT_EOF
2106621722 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
21067 archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
21068 archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
21723 archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
21724 archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
2106921725 else
2107021726 ld_shlibs_FC=no
2107121727 fi
2107721733 ld_shlibs_FC=no
2107821734 cat <<_LT_EOF 1>&2
2107921735
21080 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
21736 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
2108121737 *** reliably create shared libraries on SCO systems. Therefore, libtool
2108221738 *** is disabling shared libraries support. We urge you to upgrade GNU
2108321739 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
2109221748 # DT_RUNPATH tag from executables and libraries. But doing so
2109321749 # requires that you compile everything twice, which is a pain.
2109421750 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
21095 hardcode_libdir_flag_spec_FC='${wl}-rpath ${wl}$libdir'
21096 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
21097 archive_expsym_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
21751 hardcode_libdir_flag_spec_FC='$wl-rpath $wl$libdir'
21752 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
21753 archive_expsym_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
2109821754 else
2109921755 ld_shlibs_FC=no
2110021756 fi
2111121767
2111221768 *)
2111321769 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
21114 archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
21115 archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
21770 archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
21771 archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
2111621772 else
2111721773 ld_shlibs_FC=no
2111821774 fi
2111921775 ;;
2112021776 esac
2112121777
21122 if test "$ld_shlibs_FC" = no; then
21778 if test no = "$ld_shlibs_FC"; then
2112321779 runpath_var=
2112421780 hardcode_libdir_flag_spec_FC=
2112521781 export_dynamic_flag_spec_FC=
2113521791 # Note: this linker hardcodes the directories in LIBPATH if there
2113621792 # are no directories specified by -L.
2113721793 hardcode_minus_L_FC=yes
21138 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
21794 if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
2113921795 # Neither direct hardcoding nor static linking is supported with a
2114021796 # broken collect2.
2114121797 hardcode_direct_FC=unsupported
2114321799 ;;
2114421800
2114521801 aix[4-9]*)
21146 if test "$host_cpu" = ia64; then
21802 if test ia64 = "$host_cpu"; then
2114721803 # On IA64, the linker does run time linking by default, so we don't
2114821804 # have to do anything special.
2114921805 aix_use_runtimelinking=no
2115021806 exp_sym_flag='-Bexport'
21151 no_entry_flag=""
21807 no_entry_flag=
2115221808 else
2115321809 # If we're using GNU nm, then we don't want the "-C" option.
21154 # -C means demangle to AIX nm, but means don't demangle with GNU nm
21155 # Also, AIX nm treats weak defined symbols like other global
21156 # defined symbols, whereas GNU nm marks them as "W".
21810 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
21811 # Without the "-l" option, or with the "-B" option, AIX nm treats
21812 # weak defined symbols like other global defined symbols, whereas
21813 # GNU nm marks them as "W".
21814 # While the 'weak' keyword is ignored in the Export File, we need
21815 # it in the Import File for the 'aix-soname' feature, so we have
21816 # to replace the "-B" option with "-P" for AIX nm.
2115721817 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
21158 export_symbols_cmds_FC='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
21818 export_symbols_cmds_FC='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
2115921819 else
21160 export_symbols_cmds_FC='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
21820 export_symbols_cmds_FC='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
2116121821 fi
2116221822 aix_use_runtimelinking=no
2116321823
2116421824 # Test if we are trying to use run time linking or normal
2116521825 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
21166 # need to do runtime linking.
21826 # have runtime linking enabled, and use it for executables.
21827 # For shared libraries, we enable/disable runtime linking
21828 # depending on the kind of the shared library created -
21829 # when "with_aix_soname,aix_use_runtimelinking" is:
21830 # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
21831 # "aix,yes" lib.so shared, rtl:yes, for executables
21832 # lib.a static archive
21833 # "both,no" lib.so.V(shr.o) shared, rtl:yes
21834 # lib.a(lib.so.V) shared, rtl:no, for executables
21835 # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
21836 # lib.a(lib.so.V) shared, rtl:no
21837 # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
21838 # lib.a static archive
2116721839 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
2116821840 for ld_flag in $LDFLAGS; do
21169 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
21841 if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
2117021842 aix_use_runtimelinking=yes
2117121843 break
2117221844 fi
2117321845 done
21846 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
21847 # With aix-soname=svr4, we create the lib.so.V shared archives only,
21848 # so we don't have lib.a shared libs to link our executables.
21849 # We have to force runtime linking in this case.
21850 aix_use_runtimelinking=yes
21851 LDFLAGS="$LDFLAGS -Wl,-brtl"
21852 fi
2117421853 ;;
2117521854 esac
2117621855
2118921868 hardcode_direct_absolute_FC=yes
2119021869 hardcode_libdir_separator_FC=':'
2119121870 link_all_deplibs_FC=yes
21192 file_list_spec_FC='${wl}-f,'
21193
21194 if test "$GCC" = yes; then
21871 file_list_spec_FC='$wl-f,'
21872 case $with_aix_soname,$aix_use_runtimelinking in
21873 aix,*) ;; # traditional, no import file
21874 svr4,* | *,yes) # use import file
21875 # The Import File defines what to hardcode.
21876 hardcode_direct_FC=no
21877 hardcode_direct_absolute_FC=no
21878 ;;
21879 esac
21880
21881 if test yes = "$GCC"; then
2119521882 case $host_os in aix4.[012]|aix4.[012].*)
2119621883 # We only want to do this on AIX 4.2 and lower, the check
2119721884 # below for broken collect2 doesn't work under 4.3+
21198 collect2name=`${CC} -print-prog-name=collect2`
21885 collect2name=`$CC -print-prog-name=collect2`
2119921886 if test -f "$collect2name" &&
2120021887 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
2120121888 then
2121421901 ;;
2121521902 esac
2121621903 shared_flag='-shared'
21217 if test "$aix_use_runtimelinking" = yes; then
21218 shared_flag="$shared_flag "'${wl}-G'
21904 if test yes = "$aix_use_runtimelinking"; then
21905 shared_flag="$shared_flag "'$wl-G'
2121921906 fi
21220 link_all_deplibs_FC=no
21907 # Need to ensure runtime linking is disabled for the traditional
21908 # shared library, or the linker may eventually find shared libraries
21909 # /with/ Import File - we do not want to mix them.
21910 shared_flag_aix='-shared'
21911 shared_flag_svr4='-shared $wl-G'
2122121912 else
2122221913 # not using gcc
21223 if test "$host_cpu" = ia64; then
21914 if test ia64 = "$host_cpu"; then
2122421915 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
2122521916 # chokes on -Wl,-G. The following line is correct:
2122621917 shared_flag='-G'
2122721918 else
21228 if test "$aix_use_runtimelinking" = yes; then
21229 shared_flag='${wl}-G'
21919 if test yes = "$aix_use_runtimelinking"; then
21920 shared_flag='$wl-G'
2123021921 else
21231 shared_flag='${wl}-bM:SRE'
21922 shared_flag='$wl-bM:SRE'
2123221923 fi
21924 shared_flag_aix='$wl-bM:SRE'
21925 shared_flag_svr4='$wl-G'
2123321926 fi
2123421927 fi
2123521928
21236 export_dynamic_flag_spec_FC='${wl}-bexpall'
21929 export_dynamic_flag_spec_FC='$wl-bexpall'
2123721930 # It seems that -bexpall does not export symbols beginning with
2123821931 # underscore (_), so it is better to generate a list of symbols to export.
2123921932 always_export_symbols_FC=yes
21240 if test "$aix_use_runtimelinking" = yes; then
21933 if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
2124121934 # Warning - without using the other runtime loading flags (-brtl),
2124221935 # -berok will link without error, but may produce a broken library.
2124321936 allow_undefined_flag_FC='-berok'
2124421937 # Determine the default libpath from the value encoded in an
2124521938 # empty executable.
21246 if test "${lt_cv_aix_libpath+set}" = set; then
21939 if test set = "${lt_cv_aix_libpath+set}"; then
2124721940 aix_libpath=$lt_cv_aix_libpath
2124821941 else
2124921942 if ${lt_cv_aix_libpath__FC+:} false; then :
2127221965 rm -f core conftest.err conftest.$ac_objext \
2127321966 conftest$ac_exeext conftest.$ac_ext
2127421967 if test -z "$lt_cv_aix_libpath__FC"; then
21275 lt_cv_aix_libpath__FC="/usr/lib:/lib"
21968 lt_cv_aix_libpath__FC=/usr/lib:/lib
2127621969 fi
2127721970
2127821971 fi
2128021973 aix_libpath=$lt_cv_aix_libpath__FC
2128121974 fi
2128221975
21283 hardcode_libdir_flag_spec_FC='${wl}-blibpath:$libdir:'"$aix_libpath"
21284 archive_expsym_cmds_FC='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
21976 hardcode_libdir_flag_spec_FC='$wl-blibpath:$libdir:'"$aix_libpath"
21977 archive_expsym_cmds_FC='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
2128521978 else
21286 if test "$host_cpu" = ia64; then
21287 hardcode_libdir_flag_spec_FC='${wl}-R $libdir:/usr/lib:/lib'
21979 if test ia64 = "$host_cpu"; then
21980 hardcode_libdir_flag_spec_FC='$wl-R $libdir:/usr/lib:/lib'
2128821981 allow_undefined_flag_FC="-z nodefs"
21289 archive_expsym_cmds_FC="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
21982 archive_expsym_cmds_FC="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols"
2129021983 else
2129121984 # Determine the default libpath from the value encoded in an
2129221985 # empty executable.
21293 if test "${lt_cv_aix_libpath+set}" = set; then
21986 if test set = "${lt_cv_aix_libpath+set}"; then
2129421987 aix_libpath=$lt_cv_aix_libpath
2129521988 else
2129621989 if ${lt_cv_aix_libpath__FC+:} false; then :
2131922012 rm -f core conftest.err conftest.$ac_objext \
2132022013 conftest$ac_exeext conftest.$ac_ext
2132122014 if test -z "$lt_cv_aix_libpath__FC"; then
21322 lt_cv_aix_libpath__FC="/usr/lib:/lib"
22015 lt_cv_aix_libpath__FC=/usr/lib:/lib
2132322016 fi
2132422017
2132522018 fi
2132722020 aix_libpath=$lt_cv_aix_libpath__FC
2132822021 fi
2132922022
21330 hardcode_libdir_flag_spec_FC='${wl}-blibpath:$libdir:'"$aix_libpath"
22023 hardcode_libdir_flag_spec_FC='$wl-blibpath:$libdir:'"$aix_libpath"
2133122024 # Warning - without using the other run time loading flags,
2133222025 # -berok will link without error, but may produce a broken library.
21333 no_undefined_flag_FC=' ${wl}-bernotok'
21334 allow_undefined_flag_FC=' ${wl}-berok'
21335 if test "$with_gnu_ld" = yes; then
22026 no_undefined_flag_FC=' $wl-bernotok'
22027 allow_undefined_flag_FC=' $wl-berok'
22028 if test yes = "$with_gnu_ld"; then
2133622029 # We only use this code for GNU lds that support --whole-archive.
21337 whole_archive_flag_spec_FC='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
22030 whole_archive_flag_spec_FC='$wl--whole-archive$convenience $wl--no-whole-archive'
2133822031 else
2133922032 # Exported symbols can be pulled into shared objects from archives
2134022033 whole_archive_flag_spec_FC='$convenience'
2134122034 fi
2134222035 archive_cmds_need_lc_FC=yes
21343 # This is similar to how AIX traditionally builds its shared libraries.
21344 archive_expsym_cmds_FC="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
22036 archive_expsym_cmds_FC='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
22037 # -brtl affects multiple linker settings, -berok does not and is overridden later
22038 compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
22039 if test svr4 != "$with_aix_soname"; then
22040 # This is similar to how AIX traditionally builds its shared libraries.
22041 archive_expsym_cmds_FC="$archive_expsym_cmds_FC"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
22042 fi
22043 if test aix != "$with_aix_soname"; then
22044 archive_expsym_cmds_FC="$archive_expsym_cmds_FC"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
22045 else
22046 # used by -dlpreopen to get the symbols
22047 archive_expsym_cmds_FC="$archive_expsym_cmds_FC"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
22048 fi
22049 archive_expsym_cmds_FC="$archive_expsym_cmds_FC"'~$RM -r $output_objdir/$realname.d'
2134522050 fi
2134622051 fi
2134722052 ;;
2135022055 case $host_cpu in
2135122056 powerpc)
2135222057 # see comment about AmigaOS4 .so support
21353 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
22058 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
2135422059 archive_expsym_cmds_FC=''
2135522060 ;;
2135622061 m68k)
2138022085 # Tell ltmain to make .lib files, not .a files.
2138122086 libext=lib
2138222087 # Tell ltmain to make .dll files, not .so files.
21383 shrext_cmds=".dll"
22088 shrext_cmds=.dll
2138422089 # FIXME: Setting linknames here is a bad hack.
21385 archive_cmds_FC='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
21386 archive_expsym_cmds_FC='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
21387 sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
21388 else
21389 sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
21390 fi~
21391 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
21392 linknames='
22090 archive_cmds_FC='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
22091 archive_expsym_cmds_FC='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
22092 cp "$export_symbols" "$output_objdir/$soname.def";
22093 echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
22094 else
22095 $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
22096 fi~
22097 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
22098 linknames='
2139322099 # The linker will not automatically build a static lib if we build a DLL.
2139422100 # _LT_TAGVAR(old_archive_from_new_cmds, FC)='true'
2139522101 enable_shared_with_static_runtimes_FC=yes
2139822104 # Don't use ranlib
2139922105 old_postinstall_cmds_FC='chmod 644 $oldlib'
2140022106 postlink_cmds_FC='lt_outputfile="@OUTPUT@"~
21401 lt_tool_outputfile="@TOOL_OUTPUT@"~
21402 case $lt_outputfile in
21403 *.exe|*.EXE) ;;
21404 *)
21405 lt_outputfile="$lt_outputfile.exe"
21406 lt_tool_outputfile="$lt_tool_outputfile.exe"
21407 ;;
21408 esac~
21409 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
21410 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
21411 $RM "$lt_outputfile.manifest";
21412 fi'
22107 lt_tool_outputfile="@TOOL_OUTPUT@"~
22108 case $lt_outputfile in
22109 *.exe|*.EXE) ;;
22110 *)
22111 lt_outputfile=$lt_outputfile.exe
22112 lt_tool_outputfile=$lt_tool_outputfile.exe
22113 ;;
22114 esac~
22115 if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
22116 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
22117 $RM "$lt_outputfile.manifest";
22118 fi'
2141322119 ;;
2141422120 *)
2141522121 # Assume MSVC wrapper
2141822124 # Tell ltmain to make .lib files, not .a files.
2141922125 libext=lib
2142022126 # Tell ltmain to make .dll files, not .so files.
21421 shrext_cmds=".dll"
22127 shrext_cmds=.dll
2142222128 # FIXME: Setting linknames here is a bad hack.
2142322129 archive_cmds_FC='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
2142422130 # The linker will automatically build a .lib file if we build a DLL.
2143722143 hardcode_direct_FC=no
2143822144 hardcode_automatic_FC=yes
2143922145 hardcode_shlibpath_var_FC=unsupported
21440 if test "$lt_cv_ld_force_load" = "yes"; then
21441 whole_archive_flag_spec_FC='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
22146 if test yes = "$lt_cv_ld_force_load"; then
22147 whole_archive_flag_spec_FC='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
2144222148 compiler_needs_object_FC=yes
2144322149 else
2144422150 whole_archive_flag_spec_FC=''
2144522151 fi
2144622152 link_all_deplibs_FC=yes
21447 allow_undefined_flag_FC="$_lt_dar_allow_undefined"
22153 allow_undefined_flag_FC=$_lt_dar_allow_undefined
2144822154 case $cc_basename in
21449 ifort*) _lt_dar_can_shared=yes ;;
22155 ifort*|nagfor*) _lt_dar_can_shared=yes ;;
2145022156 *) _lt_dar_can_shared=$GCC ;;
2145122157 esac
21452 if test "$_lt_dar_can_shared" = "yes"; then
22158 if test yes = "$_lt_dar_can_shared"; then
2145322159 output_verbose_link_cmd=func_echo_all
21454 archive_cmds_FC="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
21455 module_cmds_FC="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
21456 archive_expsym_cmds_FC="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
21457 module_expsym_cmds_FC="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
22160 archive_cmds_FC="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
22161 module_cmds_FC="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
22162 archive_expsym_cmds_FC="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil"
22163 module_expsym_cmds_FC="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil"
2145822164
2145922165 else
2146022166 ld_shlibs_FC=no
2149622202 ;;
2149722203
2149822204 hpux9*)
21499 if test "$GCC" = yes; then
21500 archive_cmds_FC='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
22205 if test yes = "$GCC"; then
22206 archive_cmds_FC='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
2150122207 else
21502 archive_cmds_FC='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
22208 archive_cmds_FC='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
2150322209 fi
21504 hardcode_libdir_flag_spec_FC='${wl}+b ${wl}$libdir'
22210 hardcode_libdir_flag_spec_FC='$wl+b $wl$libdir'
2150522211 hardcode_libdir_separator_FC=:
2150622212 hardcode_direct_FC=yes
2150722213
2150822214 # hardcode_minus_L: Not really in the search PATH,
2150922215 # but as the default location of the library.
2151022216 hardcode_minus_L_FC=yes
21511 export_dynamic_flag_spec_FC='${wl}-E'
22217 export_dynamic_flag_spec_FC='$wl-E'
2151222218 ;;
2151322219
2151422220 hpux10*)
21515 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
21516 archive_cmds_FC='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
22221 if test yes,no = "$GCC,$with_gnu_ld"; then
22222 archive_cmds_FC='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
2151722223 else
2151822224 archive_cmds_FC='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
2151922225 fi
21520 if test "$with_gnu_ld" = no; then
21521 hardcode_libdir_flag_spec_FC='${wl}+b ${wl}$libdir'
22226 if test no = "$with_gnu_ld"; then
22227 hardcode_libdir_flag_spec_FC='$wl+b $wl$libdir'
2152222228 hardcode_libdir_separator_FC=:
2152322229 hardcode_direct_FC=yes
2152422230 hardcode_direct_absolute_FC=yes
21525 export_dynamic_flag_spec_FC='${wl}-E'
22231 export_dynamic_flag_spec_FC='$wl-E'
2152622232 # hardcode_minus_L: Not really in the search PATH,
2152722233 # but as the default location of the library.
2152822234 hardcode_minus_L_FC=yes
2153022236 ;;
2153122237
2153222238 hpux11*)
21533 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
22239 if test yes,no = "$GCC,$with_gnu_ld"; then
2153422240 case $host_cpu in
2153522241 hppa*64*)
21536 archive_cmds_FC='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
22242 archive_cmds_FC='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
2153722243 ;;
2153822244 ia64*)
21539 archive_cmds_FC='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
22245 archive_cmds_FC='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
2154022246 ;;
2154122247 *)
21542 archive_cmds_FC='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
22248 archive_cmds_FC='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
2154322249 ;;
2154422250 esac
2154522251 else
2154622252 case $host_cpu in
2154722253 hppa*64*)
21548 archive_cmds_FC='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
22254 archive_cmds_FC='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
2154922255 ;;
2155022256 ia64*)
21551 archive_cmds_FC='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
22257 archive_cmds_FC='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
2155222258 ;;
2155322259 *)
21554 archive_cmds_FC='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
22260 archive_cmds_FC='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
2155522261 ;;
2155622262 esac
2155722263 fi
21558 if test "$with_gnu_ld" = no; then
21559 hardcode_libdir_flag_spec_FC='${wl}+b ${wl}$libdir'
22264 if test no = "$with_gnu_ld"; then
22265 hardcode_libdir_flag_spec_FC='$wl+b $wl$libdir'
2156022266 hardcode_libdir_separator_FC=:
2156122267
2156222268 case $host_cpu in
2156722273 *)
2156822274 hardcode_direct_FC=yes
2156922275 hardcode_direct_absolute_FC=yes
21570 export_dynamic_flag_spec_FC='${wl}-E'
22276 export_dynamic_flag_spec_FC='$wl-E'
2157122277
2157222278 # hardcode_minus_L: Not really in the search PATH,
2157322279 # but as the default location of the library.
2157822284 ;;
2157922285
2158022286 irix5* | irix6* | nonstopux*)
21581 if test "$GCC" = yes; then
21582 archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
22287 if test yes = "$GCC"; then
22288 archive_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
2158322289 # Try to use the -exported_symbol ld option, if it does not
2158422290 # work, assume that -exports_file does not work either and
2158522291 # implicitly export all symbols.
2158922295 if ${lt_cv_irix_exported_symbol+:} false; then :
2159022296 $as_echo_n "(cached) " >&6
2159122297 else
21592 save_LDFLAGS="$LDFLAGS"
21593 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
22298 save_LDFLAGS=$LDFLAGS
22299 LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
2159422300 cat > conftest.$ac_ext <<_ACEOF
2159522301
2159622302 subroutine foo
2160322309 fi
2160422310 rm -f core conftest.err conftest.$ac_objext \
2160522311 conftest$ac_exeext conftest.$ac_ext
21606 LDFLAGS="$save_LDFLAGS"
22312 LDFLAGS=$save_LDFLAGS
2160722313 fi
2160822314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
2160922315 $as_echo "$lt_cv_irix_exported_symbol" >&6; }
21610 if test "$lt_cv_irix_exported_symbol" = yes; then
21611 archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
22316 if test yes = "$lt_cv_irix_exported_symbol"; then
22317 archive_expsym_cmds_FC='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
2161222318 fi
2161322319 else
21614 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
21615 archive_expsym_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
22320 archive_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
22321 archive_expsym_cmds_FC='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib'
2161622322 fi
2161722323 archive_cmds_need_lc_FC='no'
21618 hardcode_libdir_flag_spec_FC='${wl}-rpath ${wl}$libdir'
22324 hardcode_libdir_flag_spec_FC='$wl-rpath $wl$libdir'
2161922325 hardcode_libdir_separator_FC=:
2162022326 inherit_rpath_FC=yes
2162122327 link_all_deplibs_FC=yes
2162222328 ;;
2162322329
21624 netbsd* | netbsdelf*-gnu)
22330 linux*)
22331 case $cc_basename in
22332 tcc*)
22333 # Fabrice Bellard et al's Tiny C Compiler
22334 ld_shlibs_FC=yes
22335 archive_cmds_FC='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
22336 ;;
22337 esac
22338 ;;
22339
22340 netbsd*)
2162522341 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
2162622342 archive_cmds_FC='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
2162722343 else
2163522351 newsos6)
2163622352 archive_cmds_FC='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
2163722353 hardcode_direct_FC=yes
21638 hardcode_libdir_flag_spec_FC='${wl}-rpath ${wl}$libdir'
22354 hardcode_libdir_flag_spec_FC='$wl-rpath $wl$libdir'
2163922355 hardcode_libdir_separator_FC=:
2164022356 hardcode_shlibpath_var_FC=no
2164122357 ;;
2164322359 *nto* | *qnx*)
2164422360 ;;
2164522361
21646 openbsd*)
22362 openbsd* | bitrig*)
2164722363 if test -f /usr/libexec/ld.so; then
2164822364 hardcode_direct_FC=yes
2164922365 hardcode_shlibpath_var_FC=no
2165022366 hardcode_direct_absolute_FC=yes
21651 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
22367 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
2165222368 archive_cmds_FC='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
21653 archive_expsym_cmds_FC='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
21654 hardcode_libdir_flag_spec_FC='${wl}-rpath,$libdir'
21655 export_dynamic_flag_spec_FC='${wl}-E'
22369 archive_expsym_cmds_FC='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
22370 hardcode_libdir_flag_spec_FC='$wl-rpath,$libdir'
22371 export_dynamic_flag_spec_FC='$wl-E'
2165622372 else
21657 case $host_os in
21658 openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
21659 archive_cmds_FC='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
21660 hardcode_libdir_flag_spec_FC='-R$libdir'
21661 ;;
21662 *)
21663 archive_cmds_FC='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
21664 hardcode_libdir_flag_spec_FC='${wl}-rpath,$libdir'
21665 ;;
21666 esac
22373 archive_cmds_FC='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
22374 hardcode_libdir_flag_spec_FC='$wl-rpath,$libdir'
2166722375 fi
2166822376 else
2166922377 ld_shlibs_FC=no
2167422382 hardcode_libdir_flag_spec_FC='-L$libdir'
2167522383 hardcode_minus_L_FC=yes
2167622384 allow_undefined_flag_FC=unsupported
21677 archive_cmds_FC='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
21678 old_archive_from_new_cmds_FC='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
22385 shrext_cmds=.dll
22386 archive_cmds_FC='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
22387 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
22388 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
22389 $ECHO EXPORTS >> $output_objdir/$libname.def~
22390 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
22391 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
22392 emximp -o $lib $output_objdir/$libname.def'
22393 archive_expsym_cmds_FC='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
22394 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
22395 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
22396 $ECHO EXPORTS >> $output_objdir/$libname.def~
22397 prefix_cmds="$SED"~
22398 if test EXPORTS = "`$SED 1q $export_symbols`"; then
22399 prefix_cmds="$prefix_cmds -e 1d";
22400 fi~
22401 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
22402 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
22403 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
22404 emximp -o $lib $output_objdir/$libname.def'
22405 old_archive_From_new_cmds_FC='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
22406 enable_shared_with_static_runtimes_FC=yes
2167922407 ;;
2168022408
2168122409 osf3*)
21682 if test "$GCC" = yes; then
21683 allow_undefined_flag_FC=' ${wl}-expect_unresolved ${wl}\*'
21684 archive_cmds_FC='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
22410 if test yes = "$GCC"; then
22411 allow_undefined_flag_FC=' $wl-expect_unresolved $wl\*'
22412 archive_cmds_FC='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
2168522413 else
2168622414 allow_undefined_flag_FC=' -expect_unresolved \*'
21687 archive_cmds_FC='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
22415 archive_cmds_FC='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
2168822416 fi
2168922417 archive_cmds_need_lc_FC='no'
21690 hardcode_libdir_flag_spec_FC='${wl}-rpath ${wl}$libdir'
22418 hardcode_libdir_flag_spec_FC='$wl-rpath $wl$libdir'
2169122419 hardcode_libdir_separator_FC=:
2169222420 ;;
2169322421
2169422422 osf4* | osf5*) # as osf3* with the addition of -msym flag
21695 if test "$GCC" = yes; then
21696 allow_undefined_flag_FC=' ${wl}-expect_unresolved ${wl}\*'
21697 archive_cmds_FC='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
21698 hardcode_libdir_flag_spec_FC='${wl}-rpath ${wl}$libdir'
22423 if test yes = "$GCC"; then
22424 allow_undefined_flag_FC=' $wl-expect_unresolved $wl\*'
22425 archive_cmds_FC='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
22426 hardcode_libdir_flag_spec_FC='$wl-rpath $wl$libdir'
2169922427 else
2170022428 allow_undefined_flag_FC=' -expect_unresolved \*'
21701 archive_cmds_FC='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
22429 archive_cmds_FC='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
2170222430 archive_expsym_cmds_FC='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
21703 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
22431 $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp'
2170422432
2170522433 # Both c and cxx compiler support -rpath directly
2170622434 hardcode_libdir_flag_spec_FC='-rpath $libdir'
2171122439
2171222440 solaris*)
2171322441 no_undefined_flag_FC=' -z defs'
21714 if test "$GCC" = yes; then
21715 wlarc='${wl}'
21716 archive_cmds_FC='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
22442 if test yes = "$GCC"; then
22443 wlarc='$wl'
22444 archive_cmds_FC='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
2171722445 archive_expsym_cmds_FC='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
21718 $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
22446 $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
2171922447 else
2172022448 case `$CC -V 2>&1` in
2172122449 *"Compilers 5.0"*)
2172222450 wlarc=''
21723 archive_cmds_FC='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
22451 archive_cmds_FC='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
2172422452 archive_expsym_cmds_FC='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
21725 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
22453 $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
2172622454 ;;
2172722455 *)
21728 wlarc='${wl}'
21729 archive_cmds_FC='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
22456 wlarc='$wl'
22457 archive_cmds_FC='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
2173022458 archive_expsym_cmds_FC='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
21731 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
22459 $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
2173222460 ;;
2173322461 esac
2173422462 fi
2173822466 solaris2.[0-5] | solaris2.[0-5].*) ;;
2173922467 *)
2174022468 # The compiler driver will combine and reorder linker options,
21741 # but understands `-z linker_flag'. GCC discards it without `$wl',
22469 # but understands '-z linker_flag'. GCC discards it without '$wl',
2174222470 # but is careful enough not to reorder.
2174322471 # Supported since Solaris 2.6 (maybe 2.5.1?)
21744 if test "$GCC" = yes; then
21745 whole_archive_flag_spec_FC='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
22472 if test yes = "$GCC"; then
22473 whole_archive_flag_spec_FC='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
2174622474 else
2174722475 whole_archive_flag_spec_FC='-z allextract$convenience -z defaultextract'
2174822476 fi
2175222480 ;;
2175322481
2175422482 sunos4*)
21755 if test "x$host_vendor" = xsequent; then
22483 if test sequent = "$host_vendor"; then
2175622484 # Use $CC to link under sequent, because it throws in some extra .o
2175722485 # files that make .init and .fini sections work.
21758 archive_cmds_FC='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
22486 archive_cmds_FC='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
2175922487 else
2176022488 archive_cmds_FC='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
2176122489 fi
2180422532 ;;
2180522533
2180622534 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
21807 no_undefined_flag_FC='${wl}-z,text'
22535 no_undefined_flag_FC='$wl-z,text'
2180822536 archive_cmds_need_lc_FC=no
2180922537 hardcode_shlibpath_var_FC=no
2181022538 runpath_var='LD_RUN_PATH'
2181122539
21812 if test "$GCC" = yes; then
21813 archive_cmds_FC='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21814 archive_expsym_cmds_FC='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
22540 if test yes = "$GCC"; then
22541 archive_cmds_FC='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
22542 archive_expsym_cmds_FC='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
2181522543 else
21816 archive_cmds_FC='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21817 archive_expsym_cmds_FC='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
22544 archive_cmds_FC='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
22545 archive_expsym_cmds_FC='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
2181822546 fi
2181922547 ;;
2182022548
2182122549 sysv5* | sco3.2v5* | sco5v6*)
21822 # Note: We can NOT use -z defs as we might desire, because we do not
22550 # Note: We CANNOT use -z defs as we might desire, because we do not
2182322551 # link with -lc, and that would cause any symbols used from libc to
2182422552 # always be unresolved, which means just about no library would
2182522553 # ever link correctly. If we're not using GNU ld we use -z text
2182622554 # though, which does catch some bad symbols but isn't as heavy-handed
2182722555 # as -z defs.
21828 no_undefined_flag_FC='${wl}-z,text'
21829 allow_undefined_flag_FC='${wl}-z,nodefs'
22556 no_undefined_flag_FC='$wl-z,text'
22557 allow_undefined_flag_FC='$wl-z,nodefs'
2183022558 archive_cmds_need_lc_FC=no
2183122559 hardcode_shlibpath_var_FC=no
21832 hardcode_libdir_flag_spec_FC='${wl}-R,$libdir'
22560 hardcode_libdir_flag_spec_FC='$wl-R,$libdir'
2183322561 hardcode_libdir_separator_FC=':'
2183422562 link_all_deplibs_FC=yes
21835 export_dynamic_flag_spec_FC='${wl}-Bexport'
22563 export_dynamic_flag_spec_FC='$wl-Bexport'
2183622564 runpath_var='LD_RUN_PATH'
2183722565
21838 if test "$GCC" = yes; then
21839 archive_cmds_FC='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21840 archive_expsym_cmds_FC='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
22566 if test yes = "$GCC"; then
22567 archive_cmds_FC='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
22568 archive_expsym_cmds_FC='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
2184122569 else
21842 archive_cmds_FC='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21843 archive_expsym_cmds_FC='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
22570 archive_cmds_FC='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
22571 archive_expsym_cmds_FC='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
2184422572 fi
2184522573 ;;
2184622574
2185522583 ;;
2185622584 esac
2185722585
21858 if test x$host_vendor = xsni; then
22586 if test sni = "$host_vendor"; then
2185922587 case $host in
2186022588 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
21861 export_dynamic_flag_spec_FC='${wl}-Blargedynsym'
22589 export_dynamic_flag_spec_FC='$wl-Blargedynsym'
2186222590 ;;
2186322591 esac
2186422592 fi
2186622594
2186722595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_FC" >&5
2186822596 $as_echo "$ld_shlibs_FC" >&6; }
21869 test "$ld_shlibs_FC" = no && can_build_shared=no
22597 test no = "$ld_shlibs_FC" && can_build_shared=no
2187022598
2187122599 with_gnu_ld_FC=$with_gnu_ld
2187222600
2188322611 # Assume -lc should be added
2188422612 archive_cmds_need_lc_FC=yes
2188522613
21886 if test "$enable_shared" = yes && test "$GCC" = yes; then
22614 if test yes,yes = "$GCC,$enable_shared"; then
2188722615 case $archive_cmds_FC in
2188822616 *'~'*)
2188922617 # FIXME: we may have to deal with multi-command sequences.
2201122739 library_names_spec=
2201222740 libname_spec='lib$name'
2201322741 soname_spec=
22014 shrext_cmds=".so"
22742 shrext_cmds=.so
2201522743 postinstall_cmds=
2201622744 postuninstall_cmds=
2201722745 finish_cmds=
2202822756 # flags to be left without arguments
2202922757 need_version=unknown
2203022758
22759
22760
2203122761 case $host_os in
2203222762 aix3*)
2203322763 version_type=linux # correct to gnu/linux during the next big refactor
22034 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
22764 library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
2203522765 shlibpath_var=LIBPATH
2203622766
2203722767 # AIX 3 has no versioning support, so we append a major version to the name.
22038 soname_spec='${libname}${release}${shared_ext}$major'
22768 soname_spec='$libname$release$shared_ext$major'
2203922769 ;;
2204022770
2204122771 aix[4-9]*)
2204322773 need_lib_prefix=no
2204422774 need_version=no
2204522775 hardcode_into_libs=yes
22046 if test "$host_cpu" = ia64; then
22776 if test ia64 = "$host_cpu"; then
2204722777 # AIX 5 supports IA64
22048 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
22778 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
2204922779 shlibpath_var=LD_LIBRARY_PATH
2205022780 else
2205122781 # With GCC up to 2.95.x, collect2 would create an import file
2205222782 # for dependence libraries. The import file would start with
22053 # the line `#! .'. This would cause the generated library to
22054 # depend on `.', always an invalid library. This was fixed in
22783 # the line '#! .'. This would cause the generated library to
22784 # depend on '.', always an invalid library. This was fixed in
2205522785 # development snapshots of GCC prior to 3.0.
2205622786 case $host_os in
2205722787 aix4 | aix4.[01] | aix4.[01].*)
2205822788 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
2205922789 echo ' yes '
22060 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
22790 echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
2206122791 :
2206222792 else
2206322793 can_build_shared=no
2206422794 fi
2206522795 ;;
2206622796 esac
22067 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
22797 # Using Import Files as archive members, it is possible to support
22798 # filename-based versioning of shared library archives on AIX. While
22799 # this would work for both with and without runtime linking, it will
22800 # prevent static linking of such archives. So we do filename-based
22801 # shared library versioning with .so extension only, which is used
22802 # when both runtime linking and shared linking is enabled.
22803 # Unfortunately, runtime linking may impact performance, so we do
22804 # not want this to be the default eventually. Also, we use the
22805 # versioned .so libs for executables only if there is the -brtl
22806 # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
22807 # To allow for filename-based versioning support, we need to create
22808 # libNAME.so.V as an archive file, containing:
22809 # *) an Import File, referring to the versioned filename of the
22810 # archive as well as the shared archive member, telling the
22811 # bitwidth (32 or 64) of that shared object, and providing the
22812 # list of exported symbols of that shared object, eventually
22813 # decorated with the 'weak' keyword
22814 # *) the shared object with the F_LOADONLY flag set, to really avoid
22815 # it being seen by the linker.
22816 # At run time we better use the real file rather than another symlink,
22817 # but for link time we create the symlink libNAME.so -> libNAME.so.V
22818
22819 case $with_aix_soname,$aix_use_runtimelinking in
22820 # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
2206822821 # soname into executable. Probably we can add versioning support to
2206922822 # collect2, so additional links can be useful in future.
22070 if test "$aix_use_runtimelinking" = yes; then
22823 aix,yes) # traditional libtool
22824 dynamic_linker='AIX unversionable lib.so'
2207122825 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
2207222826 # instead of lib<name>.a to let people know that these are not
2207322827 # typical AIX shared libraries.
22074 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22075 else
22828 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
22829 ;;
22830 aix,no) # traditional AIX only
22831 dynamic_linker='AIX lib.a(lib.so.V)'
2207622832 # We preserve .a as extension for shared libraries through AIX4.2
2207722833 # and later when we are not doing run time linking.
22078 library_names_spec='${libname}${release}.a $libname.a'
22079 soname_spec='${libname}${release}${shared_ext}$major'
22080 fi
22834 library_names_spec='$libname$release.a $libname.a'
22835 soname_spec='$libname$release$shared_ext$major'
22836 ;;
22837 svr4,*) # full svr4 only
22838 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
22839 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
22840 # We do not specify a path in Import Files, so LIBPATH fires.
22841 shlibpath_overrides_runpath=yes
22842 ;;
22843 *,yes) # both, prefer svr4
22844 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
22845 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
22846 # unpreferred sharedlib libNAME.a needs extra handling
22847 postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"'
22848 postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"'
22849 # We do not specify a path in Import Files, so LIBPATH fires.
22850 shlibpath_overrides_runpath=yes
22851 ;;
22852 *,no) # both, prefer aix
22853 dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
22854 library_names_spec='$libname$release.a $libname.a'
22855 soname_spec='$libname$release$shared_ext$major'
22856 # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
22857 postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)'
22858 postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"'
22859 ;;
22860 esac
2208122861 shlibpath_var=LIBPATH
2208222862 fi
2208322863 ;;
2208722867 powerpc)
2208822868 # Since July 2007 AmigaOS4 officially supports .so libraries.
2208922869 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
22090 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22870 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2209122871 ;;
2209222872 m68k)
2209322873 library_names_spec='$libname.ixlibrary $libname.a'
2209422874 # Create ${libname}_ixlibrary.a entries in /sys/libs.
22095 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
22875 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2209622876 ;;
2209722877 esac
2209822878 ;;
2209922879
2210022880 beos*)
22101 library_names_spec='${libname}${shared_ext}'
22881 library_names_spec='$libname$shared_ext'
2210222882 dynamic_linker="$host_os ld.so"
2210322883 shlibpath_var=LIBRARY_PATH
2210422884 ;;
2210622886 bsdi[45]*)
2210722887 version_type=linux # correct to gnu/linux during the next big refactor
2210822888 need_version=no
22109 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22110 soname_spec='${libname}${release}${shared_ext}$major'
22889 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
22890 soname_spec='$libname$release$shared_ext$major'
2211122891 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
2211222892 shlibpath_var=LD_LIBRARY_PATH
2211322893 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
2211922899
2212022900 cygwin* | mingw* | pw32* | cegcc*)
2212122901 version_type=windows
22122 shrext_cmds=".dll"
22902 shrext_cmds=.dll
2212322903 need_version=no
2212422904 need_lib_prefix=no
2212522905
2212822908 # gcc
2212922909 library_names_spec='$libname.dll.a'
2213022910 # DLL is installed to $(libdir)/../bin by postinstall_cmds
22131 postinstall_cmds='base_file=`basename \${file}`~
22132 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
22911 postinstall_cmds='base_file=`basename \$file`~
22912 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
2213322913 dldir=$destdir/`dirname \$dlpath`~
2213422914 test -d \$dldir || mkdir -p \$dldir~
2213522915 $install_prog $dir/$dlname \$dldir/$dlname~
2214522925 case $host_os in
2214622926 cygwin*)
2214722927 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
22148 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
22928 soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
2214922929
2215022930 ;;
2215122931 mingw* | cegcc*)
2215222932 # MinGW DLLs use traditional 'lib' prefix
22153 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
22933 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
2215422934 ;;
2215522935 pw32*)
2215622936 # pw32 DLLs use 'pw' prefix rather than 'lib'
22157 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
22937 library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
2215822938 ;;
2215922939 esac
2216022940 dynamic_linker='Win32 ld.exe'
2216322943 *,cl*)
2216422944 # Native MSVC
2216522945 libname_spec='$name'
22166 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
22167 library_names_spec='${libname}.dll.lib'
22946 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
22947 library_names_spec='$libname.dll.lib'
2216822948
2216922949 case $build_os in
2217022950 mingw*)
2219122971 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
2219222972 ;;
2219322973 *)
22194 sys_lib_search_path_spec="$LIB"
22974 sys_lib_search_path_spec=$LIB
2219522975 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
2219622976 # It is most probably a Windows format PATH.
2219722977 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
2220422984 esac
2220522985
2220622986 # DLL is installed to $(libdir)/../bin by postinstall_cmds
22207 postinstall_cmds='base_file=`basename \${file}`~
22208 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
22987 postinstall_cmds='base_file=`basename \$file`~
22988 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
2220922989 dldir=$destdir/`dirname \$dlpath`~
2221022990 test -d \$dldir || mkdir -p \$dldir~
2221122991 $install_prog $dir/$dlname \$dldir/$dlname'
2221822998
2221922999 *)
2222023000 # Assume MSVC wrapper
22221 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
23001 library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
2222223002 dynamic_linker='Win32 ld.exe'
2222323003 ;;
2222423004 esac
2223123011 version_type=darwin
2223223012 need_lib_prefix=no
2223323013 need_version=no
22234 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
22235 soname_spec='${libname}${release}${major}$shared_ext'
23014 library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
23015 soname_spec='$libname$release$major$shared_ext'
2223623016 shlibpath_overrides_runpath=yes
2223723017 shlibpath_var=DYLD_LIBRARY_PATH
2223823018 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
2224423024 version_type=linux # correct to gnu/linux during the next big refactor
2224523025 need_lib_prefix=no
2224623026 need_version=no
22247 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
22248 soname_spec='${libname}${release}${shared_ext}$major'
23027 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23028 soname_spec='$libname$release$shared_ext$major'
2224923029 shlibpath_var=LD_LIBRARY_PATH
2225023030 ;;
2225123031
2226323043 version_type=freebsd-$objformat
2226423044 case $version_type in
2226523045 freebsd-elf*)
22266 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
23046 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23047 soname_spec='$libname$release$shared_ext$major'
2226723048 need_version=no
2226823049 need_lib_prefix=no
2226923050 ;;
2227023051 freebsd-*)
22271 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
23052 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
2227223053 need_version=yes
2227323054 ;;
2227423055 esac
2229823079 need_lib_prefix=no
2229923080 need_version=no
2230023081 dynamic_linker="$host_os runtime_loader"
22301 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
22302 soname_spec='${libname}${release}${shared_ext}$major'
23082 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23083 soname_spec='$libname$release$shared_ext$major'
2230323084 shlibpath_var=LIBRARY_PATH
22304 shlibpath_overrides_runpath=yes
23085 shlibpath_overrides_runpath=no
2230523086 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
2230623087 hardcode_into_libs=yes
2230723088 ;;
2231923100 dynamic_linker="$host_os dld.so"
2232023101 shlibpath_var=LD_LIBRARY_PATH
2232123102 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
22322 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22323 soname_spec='${libname}${release}${shared_ext}$major'
22324 if test "X$HPUX_IA64_MODE" = X32; then
23103 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23104 soname_spec='$libname$release$shared_ext$major'
23105 if test 32 = "$HPUX_IA64_MODE"; then
2232523106 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
23107 sys_lib_dlsearch_path_spec=/usr/lib/hpux32
2232623108 else
2232723109 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
23110 sys_lib_dlsearch_path_spec=/usr/lib/hpux64
2232823111 fi
22329 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2233023112 ;;
2233123113 hppa*64*)
2233223114 shrext_cmds='.sl'
2233423116 dynamic_linker="$host_os dld.sl"
2233523117 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
2233623118 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
22337 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22338 soname_spec='${libname}${release}${shared_ext}$major'
23119 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23120 soname_spec='$libname$release$shared_ext$major'
2233923121 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
2234023122 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2234123123 ;;
2234423126 dynamic_linker="$host_os dld.sl"
2234523127 shlibpath_var=SHLIB_PATH
2234623128 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
22347 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22348 soname_spec='${libname}${release}${shared_ext}$major'
23129 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23130 soname_spec='$libname$release$shared_ext$major'
2234923131 ;;
2235023132 esac
2235123133 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
2235823140 version_type=linux # correct to gnu/linux during the next big refactor
2235923141 need_lib_prefix=no
2236023142 need_version=no
22361 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
22362 soname_spec='${libname}${release}${shared_ext}$major'
23143 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23144 soname_spec='$libname$release$shared_ext$major'
2236323145 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
2236423146 shlibpath_var=LD_LIBRARY_PATH
2236523147 shlibpath_overrides_runpath=no
2237023152 case $host_os in
2237123153 nonstopux*) version_type=nonstopux ;;
2237223154 *)
22373 if test "$lt_cv_prog_gnu_ld" = yes; then
23155 if test yes = "$lt_cv_prog_gnu_ld"; then
2237423156 version_type=linux # correct to gnu/linux during the next big refactor
2237523157 else
2237623158 version_type=irix
2237823160 esac
2237923161 need_lib_prefix=no
2238023162 need_version=no
22381 soname_spec='${libname}${release}${shared_ext}$major'
22382 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
23163 soname_spec='$libname$release$shared_ext$major'
23164 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
2238323165 case $host_os in
2238423166 irix5* | nonstopux*)
2238523167 libsuff= shlibsuff=
2239823180 esac
2239923181 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
2240023182 shlibpath_overrides_runpath=no
22401 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
22402 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
23183 sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
23184 sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
2240323185 hardcode_into_libs=yes
2240423186 ;;
2240523187
2240623188 # No shared lib support for Linux oldld, aout, or coff.
2240723189 linux*oldld* | linux*aout* | linux*coff*)
2240823190 dynamic_linker=no
23191 ;;
23192
23193 linux*android*)
23194 version_type=none # Android doesn't support versioned libraries.
23195 need_lib_prefix=no
23196 need_version=no
23197 library_names_spec='$libname$release$shared_ext'
23198 soname_spec='$libname$release$shared_ext'
23199 finish_cmds=
23200 shlibpath_var=LD_LIBRARY_PATH
23201 shlibpath_overrides_runpath=yes
23202
23203 # This implies no fast_install, which is unacceptable.
23204 # Some rework will be needed to allow for fast_install
23205 # before this can be enabled.
23206 hardcode_into_libs=yes
23207
23208 dynamic_linker='Android linker'
23209 # Don't embed -rpath directories since the linker doesn't support them.
23210 hardcode_libdir_flag_spec_FC='-L$libdir'
2240923211 ;;
2241023212
2241123213 # This must be glibc/ELF.
2241323215 version_type=linux # correct to gnu/linux during the next big refactor
2241423216 need_lib_prefix=no
2241523217 need_version=no
22416 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22417 soname_spec='${libname}${release}${shared_ext}$major'
23218 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23219 soname_spec='$libname$release$shared_ext$major'
2241823220 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
2241923221 shlibpath_var=LD_LIBRARY_PATH
2242023222 shlibpath_overrides_runpath=no
2245223254 # before this can be enabled.
2245323255 hardcode_into_libs=yes
2245423256
22455 # Append ld.so.conf contents to the search path
23257 # Ideally, we could use ldconfig to report *all* directores which are
23258 # searched for libraries, however this is still not possible. Aside from not
23259 # being certain /sbin/ldconfig is available, command
23260 # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
23261 # even though it is searched at run-time. Try to do the best guess by
23262 # appending ld.so.conf contents (and includes) to the search path.
2245623263 if test -f /etc/ld.so.conf; then
2245723264 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
2245823265 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
2246723274 dynamic_linker='GNU/Linux ld.so'
2246823275 ;;
2246923276
22470 netbsdelf*-gnu)
22471 version_type=linux
22472 need_lib_prefix=no
22473 need_version=no
22474 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
22475 soname_spec='${libname}${release}${shared_ext}$major'
22476 shlibpath_var=LD_LIBRARY_PATH
22477 shlibpath_overrides_runpath=no
22478 hardcode_into_libs=yes
22479 dynamic_linker='NetBSD ld.elf_so'
22480 ;;
22481
2248223277 netbsd*)
2248323278 version_type=sunos
2248423279 need_lib_prefix=no
2248523280 need_version=no
2248623281 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
22487 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
23282 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
2248823283 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2248923284 dynamic_linker='NetBSD (a.out) ld.so'
2249023285 else
22491 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
22492 soname_spec='${libname}${release}${shared_ext}$major'
23286 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23287 soname_spec='$libname$release$shared_ext$major'
2249323288 dynamic_linker='NetBSD ld.elf_so'
2249423289 fi
2249523290 shlibpath_var=LD_LIBRARY_PATH
2249923294
2250023295 newsos6)
2250123296 version_type=linux # correct to gnu/linux during the next big refactor
22502 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
23297 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2250323298 shlibpath_var=LD_LIBRARY_PATH
2250423299 shlibpath_overrides_runpath=yes
2250523300 ;;
2250823303 version_type=qnx
2250923304 need_lib_prefix=no
2251023305 need_version=no
22511 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22512 soname_spec='${libname}${release}${shared_ext}$major'
23306 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23307 soname_spec='$libname$release$shared_ext$major'
2251323308 shlibpath_var=LD_LIBRARY_PATH
2251423309 shlibpath_overrides_runpath=no
2251523310 hardcode_into_libs=yes
2251623311 dynamic_linker='ldqnx.so'
2251723312 ;;
2251823313
22519 openbsd*)
23314 openbsd* | bitrig*)
2252023315 version_type=sunos
22521 sys_lib_dlsearch_path_spec="/usr/lib"
23316 sys_lib_dlsearch_path_spec=/usr/lib
2252223317 need_lib_prefix=no
22523 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
22524 case $host_os in
22525 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
22526 *) need_version=no ;;
22527 esac
22528 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
23318 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
23319 need_version=no
23320 else
23321 need_version=yes
23322 fi
23323 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
2252923324 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
2253023325 shlibpath_var=LD_LIBRARY_PATH
22531 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
22532 case $host_os in
22533 openbsd2.[89] | openbsd2.[89].*)
22534 shlibpath_overrides_runpath=no
22535 ;;
22536 *)
22537 shlibpath_overrides_runpath=yes
22538 ;;
22539 esac
22540 else
22541 shlibpath_overrides_runpath=yes
22542 fi
23326 shlibpath_overrides_runpath=yes
2254323327 ;;
2254423328
2254523329 os2*)
2254623330 libname_spec='$name'
22547 shrext_cmds=".dll"
23331 version_type=windows
23332 shrext_cmds=.dll
23333 need_version=no
2254823334 need_lib_prefix=no
22549 library_names_spec='$libname${shared_ext} $libname.a'
23335 # OS/2 can only load a DLL with a base name of 8 characters or less.
23336 soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
23337 v=$($ECHO $release$versuffix | tr -d .-);
23338 n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
23339 $ECHO $n$v`$shared_ext'
23340 library_names_spec='${libname}_dll.$libext'
2255023341 dynamic_linker='OS/2 ld.exe'
22551 shlibpath_var=LIBPATH
23342 shlibpath_var=BEGINLIBPATH
23343 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
23344 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
23345 postinstall_cmds='base_file=`basename \$file`~
23346 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
23347 dldir=$destdir/`dirname \$dlpath`~
23348 test -d \$dldir || mkdir -p \$dldir~
23349 $install_prog $dir/$dlname \$dldir/$dlname~
23350 chmod a+x \$dldir/$dlname~
23351 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
23352 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
23353 fi'
23354 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
23355 dlpath=$dir/\$dldll~
23356 $RM \$dlpath'
2255223357 ;;
2255323358
2255423359 osf3* | osf4* | osf5*)
2255523360 version_type=osf
2255623361 need_lib_prefix=no
2255723362 need_version=no
22558 soname_spec='${libname}${release}${shared_ext}$major'
22559 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
23363 soname_spec='$libname$release$shared_ext$major'
23364 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2256023365 shlibpath_var=LD_LIBRARY_PATH
2256123366 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
22562 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
23367 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2256323368 ;;
2256423369
2256523370 rdos*)
2257023375 version_type=linux # correct to gnu/linux during the next big refactor
2257123376 need_lib_prefix=no
2257223377 need_version=no
22573 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22574 soname_spec='${libname}${release}${shared_ext}$major'
23378 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23379 soname_spec='$libname$release$shared_ext$major'
2257523380 shlibpath_var=LD_LIBRARY_PATH
2257623381 shlibpath_overrides_runpath=yes
2257723382 hardcode_into_libs=yes
2258123386
2258223387 sunos4*)
2258323388 version_type=sunos
22584 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
23389 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
2258523390 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
2258623391 shlibpath_var=LD_LIBRARY_PATH
2258723392 shlibpath_overrides_runpath=yes
22588 if test "$with_gnu_ld" = yes; then
23393 if test yes = "$with_gnu_ld"; then
2258923394 need_lib_prefix=no
2259023395 fi
2259123396 need_version=yes
2259323398
2259423399 sysv4 | sysv4.3*)
2259523400 version_type=linux # correct to gnu/linux during the next big refactor
22596 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22597 soname_spec='${libname}${release}${shared_ext}$major'
23401 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23402 soname_spec='$libname$release$shared_ext$major'
2259823403 shlibpath_var=LD_LIBRARY_PATH
2259923404 case $host_vendor in
2260023405 sni)
2261523420 ;;
2261623421
2261723422 sysv4*MP*)
22618 if test -d /usr/nec ;then
23423 if test -d /usr/nec; then
2261923424 version_type=linux # correct to gnu/linux during the next big refactor
22620 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
22621 soname_spec='$libname${shared_ext}.$major'
23425 library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
23426 soname_spec='$libname$shared_ext.$major'
2262223427 shlibpath_var=LD_LIBRARY_PATH
2262323428 fi
2262423429 ;;
2262523430
2262623431 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
22627 version_type=freebsd-elf
23432 version_type=sco
2262823433 need_lib_prefix=no
2262923434 need_version=no
22630 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
22631 soname_spec='${libname}${release}${shared_ext}$major'
23435 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
23436 soname_spec='$libname$release$shared_ext$major'
2263223437 shlibpath_var=LD_LIBRARY_PATH
2263323438 shlibpath_overrides_runpath=yes
2263423439 hardcode_into_libs=yes
22635 if test "$with_gnu_ld" = yes; then
23440 if test yes = "$with_gnu_ld"; then
2263623441 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
2263723442 else
2263823443 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
2265023455 version_type=linux # correct to gnu/linux during the next big refactor
2265123456 need_lib_prefix=no
2265223457 need_version=no
22653 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
23458 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2265423459 shlibpath_var=LD_LIBRARY_PATH
2265523460 shlibpath_overrides_runpath=no
2265623461 hardcode_into_libs=yes
2265823463
2265923464 uts4*)
2266023465 version_type=linux # correct to gnu/linux during the next big refactor
22661 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22662 soname_spec='${libname}${release}${shared_ext}$major'
23466 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23467 soname_spec='$libname$release$shared_ext$major'
2266323468 shlibpath_var=LD_LIBRARY_PATH
2266423469 ;;
2266523470
2266923474 esac
2267023475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
2267123476 $as_echo "$dynamic_linker" >&6; }
22672 test "$dynamic_linker" = no && can_build_shared=no
23477 test no = "$dynamic_linker" && can_build_shared=no
2267323478
2267423479 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
22675 if test "$GCC" = yes; then
23480 if test yes = "$GCC"; then
2267623481 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
2267723482 fi
2267823483
22679 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
22680 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
22681 fi
22682 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
22683 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
22684 fi
23484 if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
23485 sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
23486 fi
23487
23488 if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
23489 sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
23490 fi
23491
23492 # remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
23493 configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
23494
23495 # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
23496 func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
23497
23498 # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
23499 configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
23500
23501
2268523502
2268623503
2268723504
2272523542 hardcode_action_FC=
2272623543 if test -n "$hardcode_libdir_flag_spec_FC" ||
2272723544 test -n "$runpath_var_FC" ||
22728 test "X$hardcode_automatic_FC" = "Xyes" ; then
23545 test yes = "$hardcode_automatic_FC"; then
2272923546
2273023547 # We can hardcode non-existent directories.
22731 if test "$hardcode_direct_FC" != no &&
23548 if test no != "$hardcode_direct_FC" &&
2273223549 # If the only mechanism to avoid hardcoding is shlibpath_var, we
2273323550 # have to relink, otherwise we might link with an installed library
2273423551 # when we should be linking with a yet-to-be-installed one
22735 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, FC)" != no &&
22736 test "$hardcode_minus_L_FC" != no; then
23552 ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, FC)" &&
23553 test no != "$hardcode_minus_L_FC"; then
2273723554 # Linking always hardcodes the temporary library directory.
2273823555 hardcode_action_FC=relink
2273923556 else
2274823565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_FC" >&5
2274923566 $as_echo "$hardcode_action_FC" >&6; }
2275023567
22751 if test "$hardcode_action_FC" = relink ||
22752 test "$inherit_rpath_FC" = yes; then
23568 if test relink = "$hardcode_action_FC" ||
23569 test yes = "$inherit_rpath_FC"; then
2275323570 # Fast installation is not supported
2275423571 enable_fast_install=no
22755 elif test "$shlibpath_overrides_runpath" = yes ||
22756 test "$enable_shared" = no; then
23572 elif test yes = "$shlibpath_overrides_runpath" ||
23573 test no = "$enable_shared"; then
2275723574 # Fast installation is not necessary
2275823575 enable_fast_install=needless
2275923576 fi
2276923586 GCC=$lt_save_GCC
2277023587 CC=$lt_save_CC
2277123588 CFLAGS=$lt_save_CFLAGS
22772 fi # test "$_lt_disable_FC" != yes
23589 fi # test yes != "$_lt_disable_FC"
2277323590
2277423591 ac_ext=c
2277523592 ac_cpp='$CPP $CPPFLAGS'
2344424261 We can't simply define LARGE_OFF_T to be 9223372036854775807,
2344524262 since some C++ compilers masquerading as C compilers
2344624263 incorrectly reject 9223372036854775807. */
23447 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24264 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
2344824265 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
2344924266 && LARGE_OFF_T % 2147483647 == 1)
2345024267 ? 1 : -1];
2347624293 We can't simply define LARGE_OFF_T to be 9223372036854775807,
2347724294 since some C++ compilers masquerading as C compilers
2347824295 incorrectly reject 9223372036854775807. */
23479 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24296 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
2348024297 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
2348124298 && LARGE_OFF_T % 2147483647 == 1)
2348224299 ? 1 : -1];
2353224349 We can't simply define LARGE_OFF_T to be 9223372036854775807,
2353324350 since some C++ compilers masquerading as C compilers
2353424351 incorrectly reject 9223372036854775807. */
23535 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24352 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
2353624353 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
2353724354 && LARGE_OFF_T % 2147483647 == 1)
2353824355 ? 1 : -1];
2356424381 We can't simply define LARGE_OFF_T to be 9223372036854775807,
2356524382 since some C++ compilers masquerading as C compilers
2356624383 incorrectly reject 9223372036854775807. */
23567 #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
24384 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
2356824385 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
2356924386 && LARGE_OFF_T % 2147483647 == 1)
2357024387 ? 1 : -1];
2730828125 ;;
2730928126 esac
2731028127
28128 ## ----------------------------------------------------------------------
28129 ## Check if they would like to enable the internal memory allocation sanity
28130 ## checking code.
28131 ##
28132 ##AC_SUBST([MEMORYALLOCSANITYCHECK])
28133 ##AC_MSG_CHECKING([whether internal memory allocation sanity checking is used])
28134 ##AC_ARG_ENABLE([memory-alloc-sanity-check],
28135 ## [AS_HELP_STRING([--enable-memory-alloc-sanity-check],
28136 ## [Enable this option to turn on internal memory
28137 ## allocation sanity checking. This could cause
28138 ## more memory use and somewhat slower allocation.
28139 ## This option is orthogonal to the
28140 ## --enable-using-memchecker option.
28141 ## Default=no.])],
28142 ## [MEMORYALLOCSANITYCHECK=$enableval])
28143 ##
28144 ##case "X-$MEMORYALLOCSANITYCHECK" in
28145 ## X-yes)
28146 ## MEMORYALLOCSANITYCHECK=yes
28147 ## AC_MSG_RESULT([yes])
28148 ## AC_DEFINE([MEMORY_ALLOC_SANITY_CHECK], [1],
28149 ## [Define to enable internal memory allocation sanity checking.])
28150 ## ;;
28151 ## *)
28152 ## MEMORYALLOCSANITYCHECK=no
28153 ## AC_MSG_RESULT([no])
28154 ## ;;
28155 ##esac
28156
2731128157 ## Checkpoint the cache
2731228158 cat >confcache <<\_ACEOF
2731328159 # This file is a shell script that caches the results of configure
2791628762 ## ----------------------------------------------------------------------
2791728763 ## Check if Direct I/O driver is enabled by --enable-direct-vfd
2791828764 ##
27919 ## ----------------------------------------------------------------------
27920 ## Check if Direct I/O driver is enabled by --enable-direct-vfd
27921 ##
2792228765 if ${hdf5_cv_direct_io+:} false; then :
2792328766 $as_echo_n "(cached) " >&6
2792428767 else
2935330196 } >&5
2935430197
2935530198 lt_cl_help="\
29356 \`$as_me' creates a local libtool stub from the current configuration,
30199 '$as_me' creates a local libtool stub from the current configuration,
2935730200 for use in further configure time tests before the real libtool is
2935830201 generated.
2935930202
2936730210 Report bugs to <bug-libtool@gnu.org>."
2936830211
2936930212 lt_cl_version="\
29370 HDF5 config.lt 1.10.0-alpha0
30213 HDF5 config.lt 1.10.0-alpha1
2937130214 configured by $0, generated by GNU Autoconf 2.69.
2937230215
2937330216 Copyright (C) 2011 Free Software Foundation, Inc.
2937430217 This config.lt script is free software; the Free Software Foundation
2937530218 gives unlimited permision to copy, distribute and modify it."
2937630219
29377 while test $# != 0
30220 while test 0 != $#
2937830221 do
2937930222 case $1 in
2938030223 --version | --v* | -V )
2938730230 lt_cl_silent=: ;;
2938830231
2938930232 -*) as_fn_error $? "unrecognized option: $1
29390 Try \`$0 --help' for more information." "$LINENO" 5 ;;
30233 Try '$0 --help' for more information." "$LINENO" 5 ;;
2939130234
2939230235 *) as_fn_error $? "unrecognized argument: $1
29393 Try \`$0 --help' for more information." "$LINENO" 5 ;;
30236 Try '$0 --help' for more information." "$LINENO" 5 ;;
2939430237 esac
2939530238 shift
2939630239 done
2941630259 enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
2941730260 pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
2941830261 enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
30262 shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`'
2941930263 SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
2942030264 ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
2942130265 PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
2946530309 GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
2946630310 lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
2946730311 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
30312 lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`'
2946830313 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
2946930314 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
30315 lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`'
2947030316 nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
2947130317 lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
30318 lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`'
2947230319 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
2947330320 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
2947430321 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
2953330380 finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
2953430381 hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
2953530382 sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
29536 sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
30383 configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`'
30384 configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`'
2953730385 hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
2953830386 enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
2953930387 enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
2968630534 compiler \
2968730535 lt_cv_sys_global_symbol_pipe \
2968830536 lt_cv_sys_global_symbol_to_cdecl \
30537 lt_cv_sys_global_symbol_to_import \
2968930538 lt_cv_sys_global_symbol_to_c_name_address \
2969030539 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
30540 lt_cv_nm_interface \
2969130541 nm_file_list_spec \
30542 lt_cv_truncate_bin \
2969230543 lt_prog_compiler_no_builtin_flag \
2969330544 lt_prog_compiler_pic \
2969430545 lt_prog_compiler_wl \
2977930630 compiler_lib_search_path_FC; do
2978030631 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
2978130632 *[\\\\\\\`\\"\\\$]*)
29782 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
30633 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
2978330634 ;;
2978430635 *)
2978530636 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
2980630657 postuninstall_cmds \
2980730658 finish_cmds \
2980830659 sys_lib_search_path_spec \
29809 sys_lib_dlsearch_path_spec \
30660 configure_time_dlsearch_path \
30661 configure_time_lt_sys_library_path \
2981030662 reload_cmds_CXX \
2981130663 reload_cmds_FC \
2981230664 old_archive_cmds_CXX \
2983130683 postlink_cmds_FC; do
2983230684 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
2983330685 *[\\\\\\\`\\"\\\$]*)
29834 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
30686 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
2983530687 ;;
2983630688 *)
2983730689 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
2984030692 done
2984130693
2984230694 ac_aux_dir='$ac_aux_dir'
29843 xsi_shell='$xsi_shell'
29844 lt_shell_append='$lt_shell_append'
29845
29846 # See if we are running on zsh, and set the options which allow our
30695
30696 # See if we are running on zsh, and set the options that allow our
2984730697 # commands through without removal of \ escapes INIT.
29848 if test -n "\${ZSH_VERSION+set}" ; then
30698 if test -n "\${ZSH_VERSION+set}"; then
2984930699 setopt NO_GLOB_SUBST
2985030700 fi
2985130701
2985230702
2985330703 PACKAGE='$PACKAGE'
2985430704 VERSION='$VERSION'
29855 TIMESTAMP='$TIMESTAMP'
2985630705 RM='$RM'
2985730706 ofile='$ofile'
2985830707
2986930718 $as_echo "$as_me: creating $ofile" >&6;}
2987030719
2987130720
29872 # See if we are running on zsh, and set the options which allow our
30721 # See if we are running on zsh, and set the options that allow our
2987330722 # commands through without removal of \ escapes.
29874 if test -n "${ZSH_VERSION+set}" ; then
30723 if test -n "${ZSH_VERSION+set}"; then
2987530724 setopt NO_GLOB_SUBST
2987630725 fi
2987730726
29878 cfgfile="${ofile}T"
30727 cfgfile=${ofile}T
2987930728 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
2988030729 $RM "$cfgfile"
2988130730
2988230731 cat <<_LT_EOF >> "$cfgfile"
2988330732 #! $SHELL
29884
29885 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
29886 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
30733 # Generated automatically by $as_me ($PACKAGE) $VERSION
2988730734 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2988830735 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
30736
30737 # Provide generalized library-building support services.
30738 # Written by Gordon Matzigkeit, 1996
30739
30740 # Copyright (C) 2014 Free Software Foundation, Inc.
30741 # This is free software; see the source for copying conditions. There is NO
30742 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
30743
30744 # GNU Libtool is free software; you can redistribute it and/or modify
30745 # it under the terms of the GNU General Public License as published by
30746 # the Free Software Foundation; either version 2 of of the License, or
30747 # (at your option) any later version.
2988930748 #
29890 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
29891 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
29892 # Foundation, Inc.
29893 # Written by Gordon Matzigkeit, 1996
30749 # As a special exception to the GNU General Public License, if you
30750 # distribute this file as part of a program or library that is built
30751 # using GNU Libtool, you may include this file under the same
30752 # distribution terms that you use for the rest of that program.
2989430753 #
29895 # This file is part of GNU Libtool.
29896 #
29897 # GNU Libtool is free software; you can redistribute it and/or
29898 # modify it under the terms of the GNU General Public License as
29899 # published by the Free Software Foundation; either version 2 of
29900 # the License, or (at your option) any later version.
29901 #
29902 # As a special exception to the GNU General Public License,
29903 # if you distribute this file as part of a program or library that
29904 # is built using GNU Libtool, you may include this file under the
29905 # same distribution terms that you use for the rest of that program.
29906 #
29907 # GNU Libtool is distributed in the hope that it will be useful,
29908 # but WITHOUT ANY WARRANTY; without even the implied warranty of
30754 # GNU Libtool is distributed in the hope that it will be useful, but
30755 # WITHOUT ANY WARRANTY; without even the implied warranty of
2990930756 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2991030757 # GNU General Public License for more details.
2991130758 #
2991230759 # You should have received a copy of the GNU General Public License
29913 # along with GNU Libtool; see the file COPYING. If not, a copy
29914 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
29915 # obtained by writing to the Free Software Foundation, Inc.,
29916 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
30760 # along with this program. If not, see <http://www.gnu.org/licenses/>.
2991730761
2991830762
2991930763 # The names of the tagged configurations supported by this script.
29920 available_tags="CXX FC "
30764 available_tags='CXX FC '
30765
30766 # Configured defaults for sys_lib_dlsearch_path munging.
30767 : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
2992130768
2992230769 # ### BEGIN LIBTOOL CONFIG
2992330770
2993630783
2993730784 # Whether or not to optimize for fast installation.
2993830785 fast_install=$enable_fast_install
30786
30787 # Shared archive member basename,for filename based shared library versioning on AIX.
30788 shared_archive_member_spec=$shared_archive_member_spec
2993930789
2994030790 # Shell to use when invoking shell scripts.
2994130791 SHELL=$lt_SHELL
3005430904 # Transform the output of nm in a proper C declaration.
3005530905 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
3005630906
30907 # Transform the output of nm into a list of symbols to manually relocate.
30908 global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import
30909
3005730910 # Transform the output of nm in a C name address pair.
3005830911 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
3005930912
3006030913 # Transform the output of nm in a C name address pair when lib prefix is needed.
3006130914 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
3006230915
30916 # The name lister interface.
30917 nm_interface=$lt_lt_cv_nm_interface
30918
3006330919 # Specify filename containing input files for \$NM.
3006430920 nm_file_list_spec=$lt_nm_file_list_spec
3006530921
30066 # The root where to search for dependent libraries,and in which our libraries should be installed.
30922 # The root where to search for dependent libraries,and where our libraries should be installed.
3006730923 lt_sysroot=$lt_sysroot
30924
30925 # Command to truncate a binary pipe.
30926 lt_truncate_bin=$lt_lt_cv_truncate_bin
3006830927
3006930928 # The name of the directory that contains temporary libtool files.
3007030929 objdir=$objdir
3015631015 # Compile-time system search path for libraries.
3015731016 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
3015831017
30159 # Run-time system search path for libraries.
30160 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
31018 # Detected run-time system search path for libraries.
31019 sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path
31020
31021 # Explicit LT_SYS_LIBRARY_PATH set during ./configure time.
31022 configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path
3016131023
3016231024 # Whether dlopen is supported.
3016331025 dlopen_support=$enable_dlopen
3025031112 # Whether we need a single "-rpath" flag with a separated argument.
3025131113 hardcode_libdir_separator=$lt_hardcode_libdir_separator
3025231114
30253 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
31115 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3025431116 # DIR into the resulting binary.
3025531117 hardcode_direct=$hardcode_direct
3025631118
30257 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
31119 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3025831120 # DIR into the resulting binary and the resulting library dependency is
30259 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
31121 # "absolute",i.e impossible to change by setting \$shlibpath_var if the
3026031122 # library is relocated.
3026131123 hardcode_direct_absolute=$hardcode_direct_absolute
3026231124
3032231184
3032331185 _LT_EOF
3032431186
31187 cat <<'_LT_EOF' >> "$cfgfile"
31188
31189 # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
31190
31191 # func_munge_path_list VARIABLE PATH
31192 # -----------------------------------
31193 # VARIABLE is name of variable containing _space_ separated list of
31194 # directories to be munged by the contents of PATH, which is string
31195 # having a format:
31196 # "DIR[:DIR]:"
31197 # string "DIR[ DIR]" will be prepended to VARIABLE
31198 # ":DIR[:DIR]"
31199 # string "DIR[ DIR]" will be appended to VARIABLE
31200 # "DIRP[:DIRP]::[DIRA:]DIRA"
31201 # string "DIRP[ DIRP]" will be prepended to VARIABLE and string
31202 # "DIRA[ DIRA]" will be appended to VARIABLE
31203 # "DIR[:DIR]"
31204 # VARIABLE will be replaced by "DIR[ DIR]"
31205 func_munge_path_list ()
31206 {
31207 case x$2 in
31208 x)
31209 ;;
31210 *:)
31211 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
31212 ;;
31213 x:*)
31214 eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
31215 ;;
31216 *::*)
31217 eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
31218 eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
31219 ;;
31220 *)
31221 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
31222 ;;
31223 esac
31224 }
31225
31226
31227 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
31228 func_cc_basename ()
31229 {
31230 for cc_temp in $*""; do
31231 case $cc_temp in
31232 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
31233 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
31234 \-*) ;;
31235 *) break;;
31236 esac
31237 done
31238 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
31239 }
31240
31241
31242 # ### END FUNCTIONS SHARED WITH CONFIGURE
31243
31244 _LT_EOF
31245
3032531246 case $host_os in
3032631247 aix3*)
3032731248 cat <<\_LT_EOF >> "$cfgfile"
3032831249 # AIX sometimes has problems with the GCC collect2 program. For some
3032931250 # reason, if we set the COLLECT_NAMES environment variable, the problems
3033031251 # vanish in a puff of smoke.
30331 if test "X${COLLECT_NAMES+set}" != Xset; then
31252 if test set != "${COLLECT_NAMES+set}"; then
3033231253 COLLECT_NAMES=
3033331254 export COLLECT_NAMES
3033431255 fi
3033731258 esac
3033831259
3033931260
30340 ltmain="$ac_aux_dir/ltmain.sh"
31261 ltmain=$ac_aux_dir/ltmain.sh
3034131262
3034231263
3034331264 # We use sed instead of cat because bash on DJGPP gets confused if
3034731268 sed '$q' "$ltmain" >> "$cfgfile" \
3034831269 || (rm -f "$cfgfile"; exit 1)
3034931270
30350 if test x"$xsi_shell" = xyes; then
30351 sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
30352 func_dirname ()\
30353 {\
30354 \ case ${1} in\
30355 \ */*) func_dirname_result="${1%/*}${2}" ;;\
30356 \ * ) func_dirname_result="${3}" ;;\
30357 \ esac\
30358 } # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
30359 && mv -f "$cfgfile.tmp" "$cfgfile" \
30360 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30361 test 0 -eq $? || _lt_function_replace_fail=:
30362
30363
30364 sed -e '/^func_basename ()$/,/^} # func_basename /c\
30365 func_basename ()\
30366 {\
30367 \ func_basename_result="${1##*/}"\
30368 } # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
30369 && mv -f "$cfgfile.tmp" "$cfgfile" \
30370 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30371 test 0 -eq $? || _lt_function_replace_fail=:
30372
30373
30374 sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
30375 func_dirname_and_basename ()\
30376 {\
30377 \ case ${1} in\
30378 \ */*) func_dirname_result="${1%/*}${2}" ;;\
30379 \ * ) func_dirname_result="${3}" ;;\
30380 \ esac\
30381 \ func_basename_result="${1##*/}"\
30382 } # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
30383 && mv -f "$cfgfile.tmp" "$cfgfile" \
30384 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30385 test 0 -eq $? || _lt_function_replace_fail=:
30386
30387
30388 sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
30389 func_stripname ()\
30390 {\
30391 \ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
30392 \ # positional parameters, so assign one to ordinary parameter first.\
30393 \ func_stripname_result=${3}\
30394 \ func_stripname_result=${func_stripname_result#"${1}"}\
30395 \ func_stripname_result=${func_stripname_result%"${2}"}\
30396 } # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
30397 && mv -f "$cfgfile.tmp" "$cfgfile" \
30398 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30399 test 0 -eq $? || _lt_function_replace_fail=:
30400
30401
30402 sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
30403 func_split_long_opt ()\
30404 {\
30405 \ func_split_long_opt_name=${1%%=*}\
30406 \ func_split_long_opt_arg=${1#*=}\
30407 } # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
30408 && mv -f "$cfgfile.tmp" "$cfgfile" \
30409 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30410 test 0 -eq $? || _lt_function_replace_fail=:
30411
30412
30413 sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
30414 func_split_short_opt ()\
30415 {\
30416 \ func_split_short_opt_arg=${1#??}\
30417 \ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
30418 } # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
30419 && mv -f "$cfgfile.tmp" "$cfgfile" \
30420 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30421 test 0 -eq $? || _lt_function_replace_fail=:
30422
30423
30424 sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
30425 func_lo2o ()\
30426 {\
30427 \ case ${1} in\
30428 \ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
30429 \ *) func_lo2o_result=${1} ;;\
30430 \ esac\
30431 } # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
30432 && mv -f "$cfgfile.tmp" "$cfgfile" \
30433 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30434 test 0 -eq $? || _lt_function_replace_fail=:
30435
30436
30437 sed -e '/^func_xform ()$/,/^} # func_xform /c\
30438 func_xform ()\
30439 {\
30440 func_xform_result=${1%.*}.lo\
30441 } # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
30442 && mv -f "$cfgfile.tmp" "$cfgfile" \
30443 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30444 test 0 -eq $? || _lt_function_replace_fail=:
30445
30446
30447 sed -e '/^func_arith ()$/,/^} # func_arith /c\
30448 func_arith ()\
30449 {\
30450 func_arith_result=$(( $* ))\
30451 } # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
30452 && mv -f "$cfgfile.tmp" "$cfgfile" \
30453 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30454 test 0 -eq $? || _lt_function_replace_fail=:
30455
30456
30457 sed -e '/^func_len ()$/,/^} # func_len /c\
30458 func_len ()\
30459 {\
30460 func_len_result=${#1}\
30461 } # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
30462 && mv -f "$cfgfile.tmp" "$cfgfile" \
30463 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30464 test 0 -eq $? || _lt_function_replace_fail=:
30465
30466 fi
30467
30468 if test x"$lt_shell_append" = xyes; then
30469 sed -e '/^func_append ()$/,/^} # func_append /c\
30470 func_append ()\
30471 {\
30472 eval "${1}+=\\${2}"\
30473 } # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
30474 && mv -f "$cfgfile.tmp" "$cfgfile" \
30475 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30476 test 0 -eq $? || _lt_function_replace_fail=:
30477
30478
30479 sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
30480 func_append_quoted ()\
30481 {\
30482 \ func_quote_for_eval "${2}"\
30483 \ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
30484 } # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
30485 && mv -f "$cfgfile.tmp" "$cfgfile" \
30486 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30487 test 0 -eq $? || _lt_function_replace_fail=:
30488
30489
30490 # Save a `func_append' function call where possible by direct use of '+='
30491 sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
30492 && mv -f "$cfgfile.tmp" "$cfgfile" \
30493 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30494 test 0 -eq $? || _lt_function_replace_fail=:
30495 else
30496 # Save a `func_append' function call even when '+=' is not available
30497 sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
30498 && mv -f "$cfgfile.tmp" "$cfgfile" \
30499 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
30500 test 0 -eq $? || _lt_function_replace_fail=:
30501 fi
30502
30503 if test x"$_lt_function_replace_fail" = x":"; then
30504 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
30505 $as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
30506 fi
30507
30508
3050931271 mv -f "$cfgfile" "$ofile" ||
3051031272 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
3051131273 chmod +x "$ofile"
3059231354 # Whether we need a single "-rpath" flag with a separated argument.
3059331355 hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
3059431356
30595 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
31357 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3059631358 # DIR into the resulting binary.
3059731359 hardcode_direct=$hardcode_direct_CXX
3059831360
30599 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
31361 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3060031362 # DIR into the resulting binary and the resulting library dependency is
30601 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
31363 # "absolute",i.e impossible to change by setting \$shlibpath_var if the
3060231364 # library is relocated.
3060331365 hardcode_direct_absolute=$hardcode_direct_absolute_CXX
3060431366
3074531507 # Whether we need a single "-rpath" flag with a separated argument.
3074631508 hardcode_libdir_separator=$lt_hardcode_libdir_separator_FC
3074731509
30748 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
31510 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3074931511 # DIR into the resulting binary.
3075031512 hardcode_direct=$hardcode_direct_FC
3075131513
30752 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
31514 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3075331515 # DIR into the resulting binary and the resulting library dependency is
30754 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
31516 # "absolute",i.e impossible to change by setting \$shlibpath_var if the
3075531517 # library is relocated.
3075631518 hardcode_direct_absolute=$hardcode_direct_absolute_FC
3075731519
3082631588 # open by configure. Here we exec the FD to /dev/null, effectively closing
3082731589 # config.log, so it can be properly (re)opened and appended to by config.lt.
3082831590 lt_cl_success=:
30829 test "$silent" = yes &&
31591 test yes = "$silent" &&
3083031592 lt_config_lt_args="$lt_config_lt_args --quiet"
3083131593 exec 5>/dev/null
3083231594 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
3146332225 # report actual input values of CONFIG_FILES etc. instead of their
3146432226 # values after options handling.
3146532227 ac_log="
31466 This file was extended by HDF5 $as_me 1.10.0-alpha0, which was
32228 This file was extended by HDF5 $as_me 1.10.0-alpha1, which was
3146732229 generated by GNU Autoconf 2.69. Invocation command line was
3146832230
3146932231 CONFIG_FILES = $CONFIG_FILES
3152932291 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
3153032292 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
3153132293 ac_cs_version="\\
31532 HDF5 config.status 1.10.0-alpha0
32294 HDF5 config.status 1.10.0-alpha1
3153332295 configured by $0, generated by GNU Autoconf 2.69,
3153432296 with options \\"\$ac_cs_config\\"
3153532297
3166432426 enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
3166532427 pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
3166632428 enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
32429 shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`'
3166732430 SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
3166832431 ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
3166932432 PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
3171332476 GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
3171432477 lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
3171532478 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
32479 lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`'
3171632480 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
3171732481 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
32482 lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`'
3171832483 nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
3171932484 lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
32485 lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`'
3172032486 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
3172132487 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
3172232488 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
3178132547 finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
3178232548 hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
3178332549 sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
31784 sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
32550 configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`'
32551 configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`'
3178532552 hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
3178632553 enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
3178732554 enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
3193432701 compiler \
3193532702 lt_cv_sys_global_symbol_pipe \
3193632703 lt_cv_sys_global_symbol_to_cdecl \
32704 lt_cv_sys_global_symbol_to_import \
3193732705 lt_cv_sys_global_symbol_to_c_name_address \
3193832706 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
32707 lt_cv_nm_interface \
3193932708 nm_file_list_spec \
32709 lt_cv_truncate_bin \
3194032710 lt_prog_compiler_no_builtin_flag \
3194132711 lt_prog_compiler_pic \
3194232712 lt_prog_compiler_wl \
3202732797 compiler_lib_search_path_FC; do
3202832798 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
3202932799 *[\\\\\\\`\\"\\\$]*)
32030 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
32800 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
3203132801 ;;
3203232802 *)
3203332803 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
3205432824 postuninstall_cmds \
3205532825 finish_cmds \
3205632826 sys_lib_search_path_spec \
32057 sys_lib_dlsearch_path_spec \
32827 configure_time_dlsearch_path \
32828 configure_time_lt_sys_library_path \
3205832829 reload_cmds_CXX \
3205932830 reload_cmds_FC \
3206032831 old_archive_cmds_CXX \
3207932850 postlink_cmds_FC; do
3208032851 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
3208132852 *[\\\\\\\`\\"\\\$]*)
32082 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
32853 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
3208332854 ;;
3208432855 *)
3208532856 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
3208832859 done
3208932860
3209032861 ac_aux_dir='$ac_aux_dir'
32091 xsi_shell='$xsi_shell'
32092 lt_shell_append='$lt_shell_append'
32093
32094 # See if we are running on zsh, and set the options which allow our
32862
32863 # See if we are running on zsh, and set the options that allow our
3209532864 # commands through without removal of \ escapes INIT.
32096 if test -n "\${ZSH_VERSION+set}" ; then
32865 if test -n "\${ZSH_VERSION+set}"; then
3209732866 setopt NO_GLOB_SUBST
3209832867 fi
3209932868
3210032869
3210132870 PACKAGE='$PACKAGE'
3210232871 VERSION='$VERSION'
32103 TIMESTAMP='$TIMESTAMP'
3210432872 RM='$RM'
3210532873 ofile='$ofile'
3210632874
3292233690 "fortran/src/H5config_f.inc":H) cat fortran/src/H5config_f.inc | sed '1d;s%^/\* \(.*\) \*/%\1%;s/#define /#define H5_/;s/#undef /#undef H5_/' >fortran/src/H5config_f.inc.tmp; mv -f fortran/src/H5config_f.inc.tmp fortran/src/H5config_f.inc ;;
3292333691 "libtool":C)
3292433692
32925 # See if we are running on zsh, and set the options which allow our
33693 # See if we are running on zsh, and set the options that allow our
3292633694 # commands through without removal of \ escapes.
32927 if test -n "${ZSH_VERSION+set}" ; then
33695 if test -n "${ZSH_VERSION+set}"; then
3292833696 setopt NO_GLOB_SUBST
3292933697 fi
3293033698
32931 cfgfile="${ofile}T"
33699 cfgfile=${ofile}T
3293233700 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
3293333701 $RM "$cfgfile"
3293433702
3293533703 cat <<_LT_EOF >> "$cfgfile"
3293633704 #! $SHELL
32937
32938 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
32939 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
33705 # Generated automatically by $as_me ($PACKAGE) $VERSION
3294033706 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3294133707 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
33708
33709 # Provide generalized library-building support services.
33710 # Written by Gordon Matzigkeit, 1996
33711
33712 # Copyright (C) 2014 Free Software Foundation, Inc.
33713 # This is free software; see the source for copying conditions. There is NO
33714 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
33715
33716 # GNU Libtool is free software; you can redistribute it and/or modify
33717 # it under the terms of the GNU General Public License as published by
33718 # the Free Software Foundation; either version 2 of of the License, or
33719 # (at your option) any later version.
3294233720 #
32943 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
32944 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
32945 # Foundation, Inc.
32946 # Written by Gordon Matzigkeit, 1996
33721 # As a special exception to the GNU General Public License, if you
33722 # distribute this file as part of a program or library that is built
33723 # using GNU Libtool, you may include this file under the same
33724 # distribution terms that you use for the rest of that program.
3294733725 #
32948 # This file is part of GNU Libtool.
32949 #
32950 # GNU Libtool is free software; you can redistribute it and/or
32951 # modify it under the terms of the GNU General Public License as
32952 # published by the Free Software Foundation; either version 2 of
32953 # the License, or (at your option) any later version.
32954 #
32955 # As a special exception to the GNU General Public License,
32956 # if you distribute this file as part of a program or library that
32957 # is built using GNU Libtool, you may include this file under the
32958 # same distribution terms that you use for the rest of that program.
32959 #
32960 # GNU Libtool is distributed in the hope that it will be useful,
32961 # but WITHOUT ANY WARRANTY; without even the implied warranty of
33726 # GNU Libtool is distributed in the hope that it will be useful, but
33727 # WITHOUT ANY WARRANTY; without even the implied warranty of
3296233728 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3296333729 # GNU General Public License for more details.
3296433730 #
3296533731 # You should have received a copy of the GNU General Public License
32966 # along with GNU Libtool; see the file COPYING. If not, a copy
32967 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
32968 # obtained by writing to the Free Software Foundation, Inc.,
32969 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
33732 # along with this program. If not, see <http://www.gnu.org/licenses/>.
3297033733
3297133734
3297233735 # The names of the tagged configurations supported by this script.
32973 available_tags="CXX FC "
33736 available_tags='CXX FC '
33737
33738 # Configured defaults for sys_lib_dlsearch_path munging.
33739 : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
3297433740
3297533741 # ### BEGIN LIBTOOL CONFIG
3297633742
3298933755
3299033756 # Whether or not to optimize for fast installation.
3299133757 fast_install=$enable_fast_install
33758
33759 # Shared archive member basename,for filename based shared library versioning on AIX.
33760 shared_archive_member_spec=$shared_archive_member_spec
3299233761
3299333762 # Shell to use when invoking shell scripts.
3299433763 SHELL=$lt_SHELL
3310733876 # Transform the output of nm in a proper C declaration.
3310833877 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
3310933878
33879 # Transform the output of nm into a list of symbols to manually relocate.
33880 global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import
33881
3311033882 # Transform the output of nm in a C name address pair.
3311133883 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
3311233884
3311333885 # Transform the output of nm in a C name address pair when lib prefix is needed.
3311433886 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
3311533887
33888 # The name lister interface.
33889 nm_interface=$lt_lt_cv_nm_interface
33890
3311633891 # Specify filename containing input files for \$NM.
3311733892 nm_file_list_spec=$lt_nm_file_list_spec
3311833893
33119 # The root where to search for dependent libraries,and in which our libraries should be installed.
33894 # The root where to search for dependent libraries,and where our libraries should be installed.
3312033895 lt_sysroot=$lt_sysroot
33896
33897 # Command to truncate a binary pipe.
33898 lt_truncate_bin=$lt_lt_cv_truncate_bin
3312133899
3312233900 # The name of the directory that contains temporary libtool files.
3312333901 objdir=$objdir
3320933987 # Compile-time system search path for libraries.
3321033988 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
3321133989
33212 # Run-time system search path for libraries.
33213 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
33990 # Detected run-time system search path for libraries.
33991 sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path
33992
33993 # Explicit LT_SYS_LIBRARY_PATH set during ./configure time.
33994 configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path
3321433995
3321533996 # Whether dlopen is supported.
3321633997 dlopen_support=$enable_dlopen
3330334084 # Whether we need a single "-rpath" flag with a separated argument.
3330434085 hardcode_libdir_separator=$lt_hardcode_libdir_separator
3330534086
33306 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
34087 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3330734088 # DIR into the resulting binary.
3330834089 hardcode_direct=$hardcode_direct
3330934090
33310 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
34091 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3331134092 # DIR into the resulting binary and the resulting library dependency is
33312 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
34093 # "absolute",i.e impossible to change by setting \$shlibpath_var if the
3331334094 # library is relocated.
3331434095 hardcode_direct_absolute=$hardcode_direct_absolute
3331534096
3337534156
3337634157 _LT_EOF
3337734158
34159 cat <<'_LT_EOF' >> "$cfgfile"
34160
34161 # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
34162
34163 # func_munge_path_list VARIABLE PATH
34164 # -----------------------------------
34165 # VARIABLE is name of variable containing _space_ separated list of
34166 # directories to be munged by the contents of PATH, which is string
34167 # having a format:
34168 # "DIR[:DIR]:"
34169 # string "DIR[ DIR]" will be prepended to VARIABLE
34170 # ":DIR[:DIR]"
34171 # string "DIR[ DIR]" will be appended to VARIABLE
34172 # "DIRP[:DIRP]::[DIRA:]DIRA"
34173 # string "DIRP[ DIRP]" will be prepended to VARIABLE and string
34174 # "DIRA[ DIRA]" will be appended to VARIABLE
34175 # "DIR[:DIR]"
34176 # VARIABLE will be replaced by "DIR[ DIR]"
34177 func_munge_path_list ()
34178 {
34179 case x$2 in
34180 x)
34181 ;;
34182 *:)
34183 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
34184 ;;
34185 x:*)
34186 eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
34187 ;;
34188 *::*)
34189 eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
34190 eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
34191 ;;
34192 *)
34193 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
34194 ;;
34195 esac
34196 }
34197
34198
34199 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
34200 func_cc_basename ()
34201 {
34202 for cc_temp in $*""; do
34203 case $cc_temp in
34204 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
34205 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
34206 \-*) ;;
34207 *) break;;
34208 esac
34209 done
34210 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
34211 }
34212
34213
34214 # ### END FUNCTIONS SHARED WITH CONFIGURE
34215
34216 _LT_EOF
34217
3337834218 case $host_os in
3337934219 aix3*)
3338034220 cat <<\_LT_EOF >> "$cfgfile"
3338134221 # AIX sometimes has problems with the GCC collect2 program. For some
3338234222 # reason, if we set the COLLECT_NAMES environment variable, the problems
3338334223 # vanish in a puff of smoke.
33384 if test "X${COLLECT_NAMES+set}" != Xset; then
34224 if test set != "${COLLECT_NAMES+set}"; then
3338534225 COLLECT_NAMES=
3338634226 export COLLECT_NAMES
3338734227 fi
3339034230 esac
3339134231
3339234232
33393 ltmain="$ac_aux_dir/ltmain.sh"
34233 ltmain=$ac_aux_dir/ltmain.sh
3339434234
3339534235
3339634236 # We use sed instead of cat because bash on DJGPP gets confused if
3340034240 sed '$q' "$ltmain" >> "$cfgfile" \
3340134241 || (rm -f "$cfgfile"; exit 1)
3340234242
33403 if test x"$xsi_shell" = xyes; then
33404 sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
33405 func_dirname ()\
33406 {\
33407 \ case ${1} in\
33408 \ */*) func_dirname_result="${1%/*}${2}" ;;\
33409 \ * ) func_dirname_result="${3}" ;;\
33410 \ esac\
33411 } # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
33412 && mv -f "$cfgfile.tmp" "$cfgfile" \
33413 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33414 test 0 -eq $? || _lt_function_replace_fail=:
33415
33416
33417 sed -e '/^func_basename ()$/,/^} # func_basename /c\
33418 func_basename ()\
33419 {\
33420 \ func_basename_result="${1##*/}"\
33421 } # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
33422 && mv -f "$cfgfile.tmp" "$cfgfile" \
33423 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33424 test 0 -eq $? || _lt_function_replace_fail=:
33425
33426
33427 sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
33428 func_dirname_and_basename ()\
33429 {\
33430 \ case ${1} in\
33431 \ */*) func_dirname_result="${1%/*}${2}" ;;\
33432 \ * ) func_dirname_result="${3}" ;;\
33433 \ esac\
33434 \ func_basename_result="${1##*/}"\
33435 } # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
33436 && mv -f "$cfgfile.tmp" "$cfgfile" \
33437 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33438 test 0 -eq $? || _lt_function_replace_fail=:
33439
33440
33441 sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
33442 func_stripname ()\
33443 {\
33444 \ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
33445 \ # positional parameters, so assign one to ordinary parameter first.\
33446 \ func_stripname_result=${3}\
33447 \ func_stripname_result=${func_stripname_result#"${1}"}\
33448 \ func_stripname_result=${func_stripname_result%"${2}"}\
33449 } # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
33450 && mv -f "$cfgfile.tmp" "$cfgfile" \
33451 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33452 test 0 -eq $? || _lt_function_replace_fail=:
33453
33454
33455 sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
33456 func_split_long_opt ()\
33457 {\
33458 \ func_split_long_opt_name=${1%%=*}\
33459 \ func_split_long_opt_arg=${1#*=}\
33460 } # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
33461 && mv -f "$cfgfile.tmp" "$cfgfile" \
33462 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33463 test 0 -eq $? || _lt_function_replace_fail=:
33464
33465
33466 sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
33467 func_split_short_opt ()\
33468 {\
33469 \ func_split_short_opt_arg=${1#??}\
33470 \ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
33471 } # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
33472 && mv -f "$cfgfile.tmp" "$cfgfile" \
33473 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33474 test 0 -eq $? || _lt_function_replace_fail=:
33475
33476
33477 sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
33478 func_lo2o ()\
33479 {\
33480 \ case ${1} in\
33481 \ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
33482 \ *) func_lo2o_result=${1} ;;\
33483 \ esac\
33484 } # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
33485 && mv -f "$cfgfile.tmp" "$cfgfile" \
33486 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33487 test 0 -eq $? || _lt_function_replace_fail=:
33488
33489
33490 sed -e '/^func_xform ()$/,/^} # func_xform /c\
33491 func_xform ()\
33492 {\
33493 func_xform_result=${1%.*}.lo\
33494 } # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
33495 && mv -f "$cfgfile.tmp" "$cfgfile" \
33496 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33497 test 0 -eq $? || _lt_function_replace_fail=:
33498
33499
33500 sed -e '/^func_arith ()$/,/^} # func_arith /c\
33501 func_arith ()\
33502 {\
33503 func_arith_result=$(( $* ))\
33504 } # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
33505 && mv -f "$cfgfile.tmp" "$cfgfile" \
33506 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33507 test 0 -eq $? || _lt_function_replace_fail=:
33508
33509
33510 sed -e '/^func_len ()$/,/^} # func_len /c\
33511 func_len ()\
33512 {\
33513 func_len_result=${#1}\
33514 } # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
33515 && mv -f "$cfgfile.tmp" "$cfgfile" \
33516 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33517 test 0 -eq $? || _lt_function_replace_fail=:
33518
33519 fi
33520
33521 if test x"$lt_shell_append" = xyes; then
33522 sed -e '/^func_append ()$/,/^} # func_append /c\
33523 func_append ()\
33524 {\
33525 eval "${1}+=\\${2}"\
33526 } # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
33527 && mv -f "$cfgfile.tmp" "$cfgfile" \
33528 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33529 test 0 -eq $? || _lt_function_replace_fail=:
33530
33531
33532 sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
33533 func_append_quoted ()\
33534 {\
33535 \ func_quote_for_eval "${2}"\
33536 \ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
33537 } # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
33538 && mv -f "$cfgfile.tmp" "$cfgfile" \
33539 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33540 test 0 -eq $? || _lt_function_replace_fail=:
33541
33542
33543 # Save a `func_append' function call where possible by direct use of '+='
33544 sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
33545 && mv -f "$cfgfile.tmp" "$cfgfile" \
33546 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33547 test 0 -eq $? || _lt_function_replace_fail=:
33548 else
33549 # Save a `func_append' function call even when '+=' is not available
33550 sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
33551 && mv -f "$cfgfile.tmp" "$cfgfile" \
33552 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
33553 test 0 -eq $? || _lt_function_replace_fail=:
33554 fi
33555
33556 if test x"$_lt_function_replace_fail" = x":"; then
33557 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
33558 $as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
33559 fi
33560
33561
3356234243 mv -f "$cfgfile" "$ofile" ||
3356334244 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
3356434245 chmod +x "$ofile"
3364534326 # Whether we need a single "-rpath" flag with a separated argument.
3364634327 hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
3364734328
33648 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
34329 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3364934330 # DIR into the resulting binary.
3365034331 hardcode_direct=$hardcode_direct_CXX
3365134332
33652 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
34333 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3365334334 # DIR into the resulting binary and the resulting library dependency is
33654 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
34335 # "absolute",i.e impossible to change by setting \$shlibpath_var if the
3365534336 # library is relocated.
3365634337 hardcode_direct_absolute=$hardcode_direct_absolute_CXX
3365734338
3379834479 # Whether we need a single "-rpath" flag with a separated argument.
3379934480 hardcode_libdir_separator=$lt_hardcode_libdir_separator_FC
3380034481
33801 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
34482 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3380234483 # DIR into the resulting binary.
3380334484 hardcode_direct=$hardcode_direct_FC
3380434485
33805 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
34486 # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
3380634487 # DIR into the resulting binary and the resulting library dependency is
33807 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
34488 # "absolute",i.e impossible to change by setting \$shlibpath_var if the
3380834489 # library is relocated.
3380934490 hardcode_direct_absolute=$hardcode_direct_absolute_FC
3381034491
2525 ## NOTE: Do not forget to change the version number here when we do a
2626 ## release!!!
2727 ##
28 AC_INIT([HDF5], [1.10.0-alpha0], [help@hdfgroup.org])
28 AC_INIT([HDF5], [1.10.0-alpha1], [help@hdfgroup.org])
2929
3030 AC_CONFIG_SRCDIR([src/H5.c])
3131 AC_CONFIG_HEADERS([src/H5config.h])
5252 ## AM_MAINTAINER_MODE([enable])
5353 ##
5454 ## Maintainer mode is disabled in releases.
55 AM_MAINTAINER_MODE
55 AM_MAINTAINER_MODE([disable])
5656
5757 ## ----------------------------------------------------------------------
5858 ## Set prefix default (install directory) to a directory in the build area.
20462046 library. Enabling this causes the library to be
20472047 more picky about it's memory operations and also
20482048 disables the library's free space manager code.
2049 This option is orthogonal to the
2050 --enable-memory-alloc-sanity-check option.
20492051 Default=no.])],
20502052 [USINGMEMCHECKER=$enableval])
20512053
20632065 AC_MSG_RESULT([no])
20642066 ;;
20652067 esac
2068
2069 ## ----------------------------------------------------------------------
2070 ## Check if they would like to enable the internal memory allocation sanity
2071 ## checking code.
2072 ##
2073 ##AC_SUBST([MEMORYALLOCSANITYCHECK])
2074 ##AC_MSG_CHECKING([whether internal memory allocation sanity checking is used])
2075 ##AC_ARG_ENABLE([memory-alloc-sanity-check],
2076 ## [AS_HELP_STRING([--enable-memory-alloc-sanity-check],
2077 ## [Enable this option to turn on internal memory
2078 ## allocation sanity checking. This could cause
2079 ## more memory use and somewhat slower allocation.
2080 ## This option is orthogonal to the
2081 ## --enable-using-memchecker option.
2082 ## Default=no.])],
2083 ## [MEMORYALLOCSANITYCHECK=$enableval])
2084 ##
2085 ##case "X-$MEMORYALLOCSANITYCHECK" in
2086 ## X-yes)
2087 ## MEMORYALLOCSANITYCHECK=yes
2088 ## AC_MSG_RESULT([yes])
2089 ## AC_DEFINE([MEMORY_ALLOC_SANITY_CHECK], [1],
2090 ## [Define to enable internal memory allocation sanity checking.])
2091 ## ;;
2092 ## *)
2093 ## MEMORYALLOCSANITYCHECK=no
2094 ## AC_MSG_RESULT([no])
2095 ## ;;
2096 ##esac
20662097
20672098 ## Checkpoint the cache
20682099 AC_CACHE_SAVE
22522283 fi
22532284 fi
22542285
2255 ## ----------------------------------------------------------------------
2256 ## Check if Direct I/O driver is enabled by --enable-direct-vfd
2257 ##
22582286 ## ----------------------------------------------------------------------
22592287 ## Check if Direct I/O driver is enabled by --enable-direct-vfd
22602288 ##
461461 LN_S = @LN_S@
462462 LTLIBOBJS = @LTLIBOBJS@
463463 LT_STATIC_EXEC = @LT_STATIC_EXEC@
464 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
464465 MAINT = @MAINT@
465466 MAKEINFO = @MAKEINFO@
466467 MANIFEST_TOOL = @MANIFEST_TOOL@
517517 LN_S = @LN_S@
518518 LTLIBOBJS = @LTLIBOBJS@
519519 LT_STATIC_EXEC = @LT_STATIC_EXEC@
520 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
520521 MAINT = @MAINT@
521522 MAKEINFO = @MAKEINFO@
522523 MANIFEST_TOOL = @MANIFEST_TOOL@
466466 LN_S = @LN_S@
467467 LTLIBOBJS = @LTLIBOBJS@
468468 LT_STATIC_EXEC = @LT_STATIC_EXEC@
469 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
469470 MAINT = @MAINT@
470471 MAKEINFO = @MAKEINFO@
471472 MANIFEST_TOOL = @MANIFEST_TOOL@
561561 LN_S = @LN_S@
562562 LTLIBOBJS = @LTLIBOBJS@
563563 LT_STATIC_EXEC = @LT_STATIC_EXEC@
564 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
564565 MAINT = @MAINT@
565566 MAKEINFO = @MAKEINFO@
566567 MANIFEST_TOOL = @MANIFEST_TOOL@
737738 # After making changes, run bin/reconfigure to update other configure related
738739 # files like Makefile.in.
739740 LT_VERS_INTERFACE = 100
740 LT_VERS_REVISION = 900
741 LT_VERS_REVISION = 0
741742 LT_VERS_AGE = 0
742743 AM_FCLIBS = $(LIBHDF5)
743744
565565 LN_S = @LN_S@
566566 LTLIBOBJS = @LTLIBOBJS@
567567 LT_STATIC_EXEC = @LT_STATIC_EXEC@
568 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
568569 MAINT = @MAINT@
569570 MAKEINFO = @MAKEINFO@
570571 MANIFEST_TOOL = @MANIFEST_TOOL@
518518 LN_S = @LN_S@
519519 LTLIBOBJS = @LTLIBOBJS@
520520 LT_STATIC_EXEC = @LT_STATIC_EXEC@
521 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
521522 MAINT = @MAINT@
522523 MAKEINFO = @MAKEINFO@
523524 MANIFEST_TOOL = @MANIFEST_TOOL@
517517 LN_S = @LN_S@
518518 LTLIBOBJS = @LTLIBOBJS@
519519 LT_STATIC_EXEC = @LT_STATIC_EXEC@
520 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
520521 MAINT = @MAINT@
521522 MAKEINFO = @MAKEINFO@
522523 MANIFEST_TOOL = @MANIFEST_TOOL@
513513 LN_S = @LN_S@
514514 LTLIBOBJS = @LTLIBOBJS@
515515 LT_STATIC_EXEC = @LT_STATIC_EXEC@
516 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
516517 MAINT = @MAINT@
517518 MAKEINFO = @MAKEINFO@
518519 MANIFEST_TOOL = @MANIFEST_TOOL@
460460 LN_S = @LN_S@
461461 LTLIBOBJS = @LTLIBOBJS@
462462 LT_STATIC_EXEC = @LT_STATIC_EXEC@
463 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
463464 MAINT = @MAINT@
464465 MAKEINFO = @MAKEINFO@
465466 MANIFEST_TOOL = @MANIFEST_TOOL@
516516 LN_S = @LN_S@
517517 LTLIBOBJS = @LTLIBOBJS@
518518 LT_STATIC_EXEC = @LT_STATIC_EXEC@
519 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
519520 MAINT = @MAINT@
520521 MAKEINFO = @MAKEINFO@
521522 MANIFEST_TOOL = @MANIFEST_TOOL@
692693 # After making changes, run bin/reconfigure to update other configure related
693694 # files like Makefile.in.
694695 LT_VERS_INTERFACE = 100
695 LT_VERS_REVISION = 900
696 LT_VERS_REVISION = 0
696697 LT_VERS_AGE = 0
697698
698699 # This is our main target
513513 LN_S = @LN_S@
514514 LTLIBOBJS = @LTLIBOBJS@
515515 LT_STATIC_EXEC = @LT_STATIC_EXEC@
516 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
516517 MAINT = @MAINT@
517518 MAKEINFO = @MAKEINFO@
518519 MANIFEST_TOOL = @MANIFEST_TOOL@
460460 LN_S = @LN_S@
461461 LTLIBOBJS = @LTLIBOBJS@
462462 LT_STATIC_EXEC = @LT_STATIC_EXEC@
463 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
463464 MAINT = @MAINT@
464465 MAKEINFO = @MAKEINFO@
465466 MANIFEST_TOOL = @MANIFEST_TOOL@
517517 LN_S = @LN_S@
518518 LTLIBOBJS = @LTLIBOBJS@
519519 LT_STATIC_EXEC = @LT_STATIC_EXEC@
520 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
520521 MAINT = @MAINT@
521522 MAKEINFO = @MAKEINFO@
522523 MANIFEST_TOOL = @MANIFEST_TOOL@
466466 LN_S = @LN_S@
467467 LTLIBOBJS = @LTLIBOBJS@
468468 LT_STATIC_EXEC = @LT_STATIC_EXEC@
469 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
469470 MAINT = @MAINT@
470471 MAKEINFO = @MAKEINFO@
471472 MANIFEST_TOOL = @MANIFEST_TOOL@
544544 LN_S = @LN_S@
545545 LTLIBOBJS = @LTLIBOBJS@
546546 LT_STATIC_EXEC = @LT_STATIC_EXEC@
547 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
547548 MAINT = @MAINT@
548549 MAKEINFO = @MAKEINFO@
549550 MANIFEST_TOOL = @MANIFEST_TOOL@
720721 # After making changes, run bin/reconfigure to update other configure related
721722 # files like Makefile.in.
722723 LT_VERS_INTERFACE = 100
723 LT_VERS_REVISION = 900
724 LT_VERS_REVISION = 0
724725 LT_VERS_AGE = 0
725726
726727 # Our main target, the high-level fortran library
527527 LN_S = @LN_S@
528528 LTLIBOBJS = @LTLIBOBJS@
529529 LT_STATIC_EXEC = @LT_STATIC_EXEC@
530 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
530531 MAINT = @MAINT@
531532 MAKEINFO = @MAKEINFO@
532533 MANIFEST_TOOL = @MANIFEST_TOOL@
515515 LN_S = @LN_S@
516516 LTLIBOBJS = @LTLIBOBJS@
517517 LT_STATIC_EXEC = @LT_STATIC_EXEC@
518 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
518519 MAINT = @MAINT@
519520 MAKEINFO = @MAKEINFO@
520521 MANIFEST_TOOL = @MANIFEST_TOOL@
691692 # After making changes, run bin/reconfigure to update other configure related
692693 # files like Makefile.in.
693694 LT_VERS_INTERFACE = 100
694 LT_VERS_REVISION = 900
695 LT_VERS_REVISION = 0
695696 LT_VERS_AGE = 0
696697
697698 # This library is our main target.
565565 LN_S = @LN_S@
566566 LTLIBOBJS = @LTLIBOBJS@
567567 LT_STATIC_EXEC = @LT_STATIC_EXEC@
568 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
568569 MAINT = @MAINT@
569570 MAKEINFO = @MAKEINFO@
570571 MANIFEST_TOOL = @MANIFEST_TOOL@
514514 LN_S = @LN_S@
515515 LTLIBOBJS = @LTLIBOBJS@
516516 LT_STATIC_EXEC = @LT_STATIC_EXEC@
517 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
517518 MAINT = @MAINT@
518519 MAKEINFO = @MAKEINFO@
519520 MANIFEST_TOOL = @MANIFEST_TOOL@
528528 LN_S = @LN_S@
529529 LTLIBOBJS = @LTLIBOBJS@
530530 LT_STATIC_EXEC = @LT_STATIC_EXEC@
531 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
531532 MAINT = @MAINT@
532533 MAKEINFO = @MAKEINFO@
533534 MANIFEST_TOOL = @MANIFEST_TOOL@
531531 LN_S = @LN_S@
532532 LTLIBOBJS = @LTLIBOBJS@
533533 LT_STATIC_EXEC = @LT_STATIC_EXEC@
534 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
534535 MAINT = @MAINT@
535536 MAKEINFO = @MAKEINFO@
536537 MANIFEST_TOOL = @MANIFEST_TOOL@
html/Supplements/._H5_CompatFormat180 070730 v.xls less more
Binary diff not shown
00 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
11 #
2 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
3 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
4 # Foundation, Inc.
2 # Copyright (C) 1996-2001, 2003-2015 Free Software Foundation, Inc.
53 # Written by Gordon Matzigkeit, 1996
64 #
75 # This file is free software; the Free Software Foundation gives
97 # modifications, as long as this notice is preserved.
108
119 m4_define([_LT_COPYING], [dnl
12 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
13 # 2006, 2007, 2008, 2009, 2010, 2011 Free Software
14 # Foundation, Inc.
15 # Written by Gordon Matzigkeit, 1996
10 # Copyright (C) 2014 Free Software Foundation, Inc.
11 # This is free software; see the source for copying conditions. There is NO
12 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13
14 # GNU Libtool is free software; you can redistribute it and/or modify
15 # it under the terms of the GNU General Public License as published by
16 # the Free Software Foundation; either version 2 of of the License, or
17 # (at your option) any later version.
1618 #
17 # This file is part of GNU Libtool.
19 # As a special exception to the GNU General Public License, if you
20 # distribute this file as part of a program or library that is built
21 # using GNU Libtool, you may include this file under the same
22 # distribution terms that you use for the rest of that program.
1823 #
19 # GNU Libtool is free software; you can redistribute it and/or
20 # modify it under the terms of the GNU General Public License as
21 # published by the Free Software Foundation; either version 2 of
22 # the License, or (at your option) any later version.
23 #
24 # As a special exception to the GNU General Public License,
25 # if you distribute this file as part of a program or library that
26 # is built using GNU Libtool, you may include this file under the
27 # same distribution terms that you use for the rest of that program.
28 #
29 # GNU Libtool is distributed in the hope that it will be useful,
30 # but WITHOUT ANY WARRANTY; without even the implied warranty of
24 # GNU Libtool is distributed in the hope that it will be useful, but
25 # WITHOUT ANY WARRANTY; without even the implied warranty of
3126 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3227 # GNU General Public License for more details.
3328 #
3429 # You should have received a copy of the GNU General Public License
35 # along with GNU Libtool; see the file COPYING. If not, a copy
36 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
37 # obtained by writing to the Free Software Foundation, Inc.,
38 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
30 # along with this program. If not, see <http://www.gnu.org/licenses/>.
3931 ])
4032
41 # serial 57 LT_INIT
33 # serial 58 LT_INIT
4234
4335
4436 # LT_PREREQ(VERSION)
6658 # LT_INIT([OPTIONS])
6759 # ------------------
6860 AC_DEFUN([LT_INIT],
69 [AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
61 [AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK
7062 AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
7163 AC_BEFORE([$0], [LT_LANG])dnl
7264 AC_BEFORE([$0], [LT_OUTPUT])dnl
9082 _LT_SET_OPTIONS([$0], [$1])
9183
9284 # This can be used to rebuild libtool when needed
93 LIBTOOL_DEPS="$ltmain"
85 LIBTOOL_DEPS=$ltmain
9486
9587 # Always use our own libtool.
9688 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
110102 dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
111103
112104
105 # _LT_PREPARE_CC_BASENAME
106 # -----------------------
107 m4_defun([_LT_PREPARE_CC_BASENAME], [
108 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
109 func_cc_basename ()
110 {
111 for cc_temp in @S|@*""; do
112 case $cc_temp in
113 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
114 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
115 \-*) ;;
116 *) break;;
117 esac
118 done
119 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
120 }
121 ])# _LT_PREPARE_CC_BASENAME
122
123
113124 # _LT_CC_BASENAME(CC)
114125 # -------------------
115 # Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
126 # It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME,
127 # but that macro is also expanded into generated libtool script, which
128 # arranges for $SED and $ECHO to be set by different means.
116129 m4_defun([_LT_CC_BASENAME],
117 [for cc_temp in $1""; do
118 case $cc_temp in
119 compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
120 distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
121 \-*) ;;
122 *) break;;
123 esac
124 done
125 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
130 [m4_require([_LT_PREPARE_CC_BASENAME])dnl
131 AC_REQUIRE([_LT_DECL_SED])dnl
132 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
133 func_cc_basename $1
134 cc_basename=$func_cc_basename_result
126135 ])
127136
128137
129138 # _LT_FILEUTILS_DEFAULTS
130139 # ----------------------
131140 # It is okay to use these file commands and assume they have been set
132 # sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
141 # sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'.
133142 m4_defun([_LT_FILEUTILS_DEFAULTS],
134143 [: ${CP="cp -f"}
135144 : ${MV="mv -f"}
176185 m4_require([_LT_CMD_OLD_ARCHIVE])dnl
177186 m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
178187 m4_require([_LT_WITH_SYSROOT])dnl
188 m4_require([_LT_CMD_TRUNCATE])dnl
179189
180190 _LT_CONFIG_LIBTOOL_INIT([
181 # See if we are running on zsh, and set the options which allow our
191 # See if we are running on zsh, and set the options that allow our
182192 # commands through without removal of \ escapes INIT.
183 if test -n "\${ZSH_VERSION+set}" ; then
193 if test -n "\${ZSH_VERSION+set}"; then
184194 setopt NO_GLOB_SUBST
185195 fi
186196 ])
187 if test -n "${ZSH_VERSION+set}" ; then
197 if test -n "${ZSH_VERSION+set}"; then
188198 setopt NO_GLOB_SUBST
189199 fi
190200
197207 # AIX sometimes has problems with the GCC collect2 program. For some
198208 # reason, if we set the COLLECT_NAMES environment variable, the problems
199209 # vanish in a puff of smoke.
200 if test "X${COLLECT_NAMES+set}" != Xset; then
210 if test set != "${COLLECT_NAMES+set}"; then
201211 COLLECT_NAMES=
202212 export COLLECT_NAMES
203213 fi
208218 ofile=libtool
209219 can_build_shared=yes
210220
211 # All known linkers require a `.a' archive for static linking (except MSVC,
221 # All known linkers require a '.a' archive for static linking (except MSVC,
212222 # which needs '.lib').
213223 libext=a
214224
215 with_gnu_ld="$lt_cv_prog_gnu_ld"
216
217 old_CC="$CC"
218 old_CFLAGS="$CFLAGS"
225 with_gnu_ld=$lt_cv_prog_gnu_ld
226
227 old_CC=$CC
228 old_CFLAGS=$CFLAGS
219229
220230 # Set sane defaults for various variables
221231 test -z "$CC" && CC=cc
268278
269279 # _LT_PROG_LTMAIN
270280 # ---------------
271 # Note that this code is called both from `configure', and `config.status'
281 # Note that this code is called both from 'configure', and 'config.status'
272282 # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
273 # `config.status' has no value for ac_aux_dir unless we are using Automake,
283 # 'config.status' has no value for ac_aux_dir unless we are using Automake,
274284 # so we pass a copy along to make sure it has a sensible value anyway.
275285 m4_defun([_LT_PROG_LTMAIN],
276286 [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
277287 _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
278 ltmain="$ac_aux_dir/ltmain.sh"
288 ltmain=$ac_aux_dir/ltmain.sh
279289 ])# _LT_PROG_LTMAIN
280290
281291
285295
286296 # So that we can recreate a full libtool script including additional
287297 # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
288 # in macros and then make a single call at the end using the `libtool'
298 # in macros and then make a single call at the end using the 'libtool'
289299 # label.
290300
291301
420430
421431 # _LT_CONFIG_STATUS_DECLARE([VARNAME])
422432 # ------------------------------------
423 # Quote a variable value, and forward it to `config.status' so that its
424 # declaration there will have the same value as in `configure'. VARNAME
433 # Quote a variable value, and forward it to 'config.status' so that its
434 # declaration there will have the same value as in 'configure'. VARNAME
425435 # must have a single quote delimited value for this to work.
426436 m4_define([_LT_CONFIG_STATUS_DECLARE],
427437 [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
445455 # Output comment and list of tags supported by the script
446456 m4_defun([_LT_LIBTOOL_TAGS],
447457 [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
448 available_tags="_LT_TAGS"dnl
458 available_tags='_LT_TAGS'dnl
449459 ])
450460
451461
473483 # _LT_LIBTOOL_CONFIG_VARS
474484 # -----------------------
475485 # Produce commented declarations of non-tagged libtool config variables
476 # suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
486 # suitable for insertion in the LIBTOOL CONFIG section of the 'libtool'
477487 # script. Tagged libtool config variables (even for the LIBTOOL CONFIG
478488 # section) are produced by _LT_LIBTOOL_TAG_VARS.
479489 m4_defun([_LT_LIBTOOL_CONFIG_VARS],
499509 # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
500510 # variables for single and double quote escaping we saved from calls
501511 # to _LT_DECL, we can put quote escaped variables declarations
502 # into `config.status', and then the shell code to quote escape them in
503 # for loops in `config.status'. Finally, any additional code accumulated
512 # into 'config.status', and then the shell code to quote escape them in
513 # for loops in 'config.status'. Finally, any additional code accumulated
504514 # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
505515 m4_defun([_LT_CONFIG_COMMANDS],
506516 [AC_PROVIDE_IFELSE([LT_OUTPUT],
546556 ]], lt_decl_quote_varnames); do
547557 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
548558 *[[\\\\\\\`\\"\\\$]]*)
549 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
559 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
550560 ;;
551561 *)
552562 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
559569 ]], lt_decl_dquote_varnames); do
560570 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
561571 *[[\\\\\\\`\\"\\\$]]*)
562 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
572 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
563573 ;;
564574 *)
565575 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
575585 # Generate a child script FILE with all initialization necessary to
576586 # reuse the environment learned by the parent script, and make the
577587 # file executable. If COMMENT is supplied, it is inserted after the
578 # `#!' sequence but before initialization text begins. After this
588 # '#!' sequence but before initialization text begins. After this
579589 # macro, additional text can be appended to FILE to form the body of
580590 # the child script. The macro ends with non-zero status if the
581591 # file could not be fully written (such as if the disk is full).
597607 _AS_PREPARE
598608 exec AS_MESSAGE_FD>&1
599609 _ASEOF
600 test $lt_write_fail = 0 && chmod +x $1[]dnl
610 test 0 = "$lt_write_fail" && chmod +x $1[]dnl
601611 m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
602612
603613 # LT_OUTPUT
620630 } >&AS_MESSAGE_LOG_FD
621631
622632 lt_cl_help="\
623 \`$as_me' creates a local libtool stub from the current configuration,
633 '$as_me' creates a local libtool stub from the current configuration,
624634 for use in further configure time tests before the real libtool is
625635 generated.
626636
642652 This config.lt script is free software; the Free Software Foundation
643653 gives unlimited permision to copy, distribute and modify it."
644654
645 while test $[#] != 0
655 while test 0 != $[#]
646656 do
647657 case $[1] in
648658 --version | --v* | -V )
655665 lt_cl_silent=: ;;
656666
657667 -*) AC_MSG_ERROR([unrecognized option: $[1]
658 Try \`$[0] --help' for more information.]) ;;
668 Try '$[0] --help' for more information.]) ;;
659669
660670 *) AC_MSG_ERROR([unrecognized argument: $[1]
661 Try \`$[0] --help' for more information.]) ;;
671 Try '$[0] --help' for more information.]) ;;
662672 esac
663673 shift
664674 done
684694 # open by configure. Here we exec the FD to /dev/null, effectively closing
685695 # config.log, so it can be properly (re)opened and appended to by config.lt.
686696 lt_cl_success=:
687 test "$silent" = yes &&
697 test yes = "$silent" &&
688698 lt_config_lt_args="$lt_config_lt_args --quiet"
689699 exec AS_MESSAGE_LOG_FD>/dev/null
690700 $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
704714 _LT_CONFIG_SAVE_COMMANDS([
705715 m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
706716 m4_if(_LT_TAG, [C], [
707 # See if we are running on zsh, and set the options which allow our
717 # See if we are running on zsh, and set the options that allow our
708718 # commands through without removal of \ escapes.
709 if test -n "${ZSH_VERSION+set}" ; then
719 if test -n "${ZSH_VERSION+set}"; then
710720 setopt NO_GLOB_SUBST
711721 fi
712722
713 cfgfile="${ofile}T"
723 cfgfile=${ofile}T
714724 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
715725 $RM "$cfgfile"
716726
717727 cat <<_LT_EOF >> "$cfgfile"
718728 #! $SHELL
719
720 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
721 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
729 # Generated automatically by $as_me ($PACKAGE) $VERSION
722730 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
723731 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
724 #
732
733 # Provide generalized library-building support services.
734 # Written by Gordon Matzigkeit, 1996
735
725736 _LT_COPYING
726737 _LT_LIBTOOL_TAGS
738
739 # Configured defaults for sys_lib_dlsearch_path munging.
740 : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
727741
728742 # ### BEGIN LIBTOOL CONFIG
729743 _LT_LIBTOOL_CONFIG_VARS
730744 _LT_LIBTOOL_TAG_VARS
731745 # ### END LIBTOOL CONFIG
746
747 _LT_EOF
748
749 cat <<'_LT_EOF' >> "$cfgfile"
750
751 # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
752
753 _LT_PREPARE_MUNGE_PATH_LIST
754 _LT_PREPARE_CC_BASENAME
755
756 # ### END FUNCTIONS SHARED WITH CONFIGURE
732757
733758 _LT_EOF
734759
738763 # AIX sometimes has problems with the GCC collect2 program. For some
739764 # reason, if we set the COLLECT_NAMES environment variable, the problems
740765 # vanish in a puff of smoke.
741 if test "X${COLLECT_NAMES+set}" != Xset; then
766 if test set != "${COLLECT_NAMES+set}"; then
742767 COLLECT_NAMES=
743768 export COLLECT_NAMES
744769 fi
754779 # is reportedly fixed, but why not run on old versions too?
755780 sed '$q' "$ltmain" >> "$cfgfile" \
756781 || (rm -f "$cfgfile"; exit 1)
757
758 _LT_PROG_REPLACE_SHELLFNS
759782
760783 mv -f "$cfgfile" "$ofile" ||
761784 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
774797 [m4_if([$1], [], [
775798 PACKAGE='$PACKAGE'
776799 VERSION='$VERSION'
777 TIMESTAMP='$TIMESTAMP'
778800 RM='$RM'
779801 ofile='$ofile'], [])
780802 ])dnl /_LT_CONFIG_SAVE_COMMANDS
973995
974996 AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
975997 [lt_cv_apple_cc_single_mod=no
976 if test -z "${LT_MULTI_MODULE}"; then
998 if test -z "$LT_MULTI_MODULE"; then
977999 # By default we will add the -single_module flag. You can override
9781000 # by either setting the environment variable LT_MULTI_MODULE
9791001 # non-empty at configure time, or by adding -multi_module to the
9911013 cat conftest.err >&AS_MESSAGE_LOG_FD
9921014 # Otherwise, if the output was created with a 0 exit code from
9931015 # the compiler, it worked.
994 elif test -f libconftest.dylib && test $_lt_result -eq 0; then
1016 elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
9951017 lt_cv_apple_cc_single_mod=yes
9961018 else
9971019 cat conftest.err >&AS_MESSAGE_LOG_FD
10091031 AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
10101032 [lt_cv_ld_exported_symbols_list=yes],
10111033 [lt_cv_ld_exported_symbols_list=no])
1012 LDFLAGS="$save_LDFLAGS"
1034 LDFLAGS=$save_LDFLAGS
10131035 ])
10141036
10151037 AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
10311053 _lt_result=$?
10321054 if test -s conftest.err && $GREP force_load conftest.err; then
10331055 cat conftest.err >&AS_MESSAGE_LOG_FD
1034 elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
1056 elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
10351057 lt_cv_ld_force_load=yes
10361058 else
10371059 cat conftest.err >&AS_MESSAGE_LOG_FD
10411063 ])
10421064 case $host_os in
10431065 rhapsody* | darwin1.[[012]])
1044 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
1066 _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
10451067 darwin1.*)
1046 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1068 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10471069 darwin*) # darwin 5.x on
10481070 # if running on 10.5 or later, the deployment target defaults
10491071 # to the OS version, if on x86, and 10.4, the deployment
10501072 # target defaults to 10.4. Don't you love it?
10511073 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
10521074 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
1053 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1054 10.[[012]]*)
1055 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
1075 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
1076 10.[[012]][[,.]]*)
1077 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10561078 10.*)
1057 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
1079 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10581080 esac
10591081 ;;
10601082 esac
1061 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
1083 if test yes = "$lt_cv_apple_cc_single_mod"; then
10621084 _lt_dar_single_mod='$single_module'
10631085 fi
1064 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
1065 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
1086 if test yes = "$lt_cv_ld_exported_symbols_list"; then
1087 _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
10661088 else
1067 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
1089 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
10681090 fi
1069 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
1091 if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
10701092 _lt_dsymutil='~$DSYMUTIL $lib || :'
10711093 else
10721094 _lt_dsymutil=
10861108 _LT_TAGVAR(hardcode_direct, $1)=no
10871109 _LT_TAGVAR(hardcode_automatic, $1)=yes
10881110 _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
1089 if test "$lt_cv_ld_force_load" = "yes"; then
1090 _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
1111 if test yes = "$lt_cv_ld_force_load"; then
1112 _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
10911113 m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
10921114 [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
10931115 else
10941116 _LT_TAGVAR(whole_archive_flag_spec, $1)=''
10951117 fi
10961118 _LT_TAGVAR(link_all_deplibs, $1)=yes
1097 _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
1119 _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined
10981120 case $cc_basename in
1099 ifort*) _lt_dar_can_shared=yes ;;
1121 ifort*|nagfor*) _lt_dar_can_shared=yes ;;
11001122 *) _lt_dar_can_shared=$GCC ;;
11011123 esac
1102 if test "$_lt_dar_can_shared" = "yes"; then
1124 if test yes = "$_lt_dar_can_shared"; then
11031125 output_verbose_link_cmd=func_echo_all
1104 _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
1105 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
1106 _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
1107 _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
1126 _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
1127 _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
1128 _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil"
1129 _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil"
11081130 m4_if([$1], [CXX],
1109 [ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
1110 _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
1111 _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
1131 [ if test yes != "$lt_cv_apple_cc_single_mod"; then
1132 _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil"
1133 _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil"
11121134 fi
11131135 ],[])
11141136 else
11281150 # Allow to override them for all tags through lt_cv_aix_libpath.
11291151 m4_defun([_LT_SYS_MODULE_PATH_AIX],
11301152 [m4_require([_LT_DECL_SED])dnl
1131 if test "${lt_cv_aix_libpath+set}" = set; then
1153 if test set = "${lt_cv_aix_libpath+set}"; then
11321154 aix_libpath=$lt_cv_aix_libpath
11331155 else
11341156 AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
11461168 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
11471169 fi],[])
11481170 if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
1149 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
1171 _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib
11501172 fi
11511173 ])
11521174 aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
11661188 # -----------------------
11671189 # Find how we can fake an echo command that does not interpret backslash.
11681190 # In particular, with Autoconf 2.60 or later we add some code to the start
1169 # of the generated configure script which will find a shell with a builtin
1170 # printf (which we can use as an echo command).
1191 # of the generated configure script that will find a shell with a builtin
1192 # printf (that we can use as an echo command).
11711193 m4_defun([_LT_PROG_ECHO_BACKSLASH],
11721194 [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
11731195 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
11951217 # Invoke $ECHO with all args, space-separated.
11961218 func_echo_all ()
11971219 {
1198 $ECHO "$*"
1220 $ECHO "$*"
11991221 }
12001222
1201 case "$ECHO" in
1223 case $ECHO in
12021224 printf*) AC_MSG_RESULT([printf]) ;;
12031225 print*) AC_MSG_RESULT([print -r]) ;;
12041226 *) AC_MSG_RESULT([cat]) ;;
12241246 AC_DEFUN([_LT_WITH_SYSROOT],
12251247 [AC_MSG_CHECKING([for sysroot])
12261248 AC_ARG_WITH([sysroot],
1227 [ --with-sysroot[=DIR] Search for dependent libraries within DIR
1228 (or the compiler's sysroot if not specified).],
1249 [AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@],
1250 [Search for dependent libraries within DIR (or the compiler's sysroot
1251 if not specified).])],
12291252 [], [with_sysroot=no])
12301253
12311254 dnl lt_sysroot will always be passed unquoted. We quote it here
12321255 dnl in case the user passed a directory name.
12331256 lt_sysroot=
1234 case ${with_sysroot} in #(
1257 case $with_sysroot in #(
12351258 yes)
1236 if test "$GCC" = yes; then
1259 if test yes = "$GCC"; then
12371260 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
12381261 fi
12391262 ;; #(
12431266 no|'')
12441267 ;; #(
12451268 *)
1246 AC_MSG_RESULT([${with_sysroot}])
1269 AC_MSG_RESULT([$with_sysroot])
12471270 AC_MSG_ERROR([The sysroot must be an absolute path.])
12481271 ;;
12491272 esac
12501273
12511274 AC_MSG_RESULT([${lt_sysroot:-no}])
12521275 _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
1253 [dependent libraries, and in which our libraries should be installed.])])
1276 [dependent libraries, and where our libraries should be installed.])])
12541277
12551278 # _LT_ENABLE_LOCK
12561279 # ---------------
12581281 [AC_ARG_ENABLE([libtool-lock],
12591282 [AS_HELP_STRING([--disable-libtool-lock],
12601283 [avoid locking (might break parallel builds)])])
1261 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
1284 test no = "$enable_libtool_lock" || enable_libtool_lock=yes
12621285
12631286 # Some flags need to be propagated to the compiler or linker for good
12641287 # libtool support.
12651288 case $host in
12661289 ia64-*-hpux*)
1267 # Find out which ABI we are using.
1290 # Find out what ABI is being produced by ac_compile, and set mode
1291 # options accordingly.
12681292 echo 'int i;' > conftest.$ac_ext
12691293 if AC_TRY_EVAL(ac_compile); then
12701294 case `/usr/bin/file conftest.$ac_objext` in
12711295 *ELF-32*)
1272 HPUX_IA64_MODE="32"
1296 HPUX_IA64_MODE=32
12731297 ;;
12741298 *ELF-64*)
1275 HPUX_IA64_MODE="64"
1299 HPUX_IA64_MODE=64
12761300 ;;
12771301 esac
12781302 fi
12791303 rm -rf conftest*
12801304 ;;
12811305 *-*-irix6*)
1282 # Find out which ABI we are using.
1306 # Find out what ABI is being produced by ac_compile, and set linker
1307 # options accordingly.
12831308 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
12841309 if AC_TRY_EVAL(ac_compile); then
1285 if test "$lt_cv_prog_gnu_ld" = yes; then
1310 if test yes = "$lt_cv_prog_gnu_ld"; then
12861311 case `/usr/bin/file conftest.$ac_objext` in
12871312 *32-bit*)
12881313 LD="${LD-ld} -melf32bsmip"
13111336 rm -rf conftest*
13121337 ;;
13131338
1339 mips64*-*linux*)
1340 # Find out what ABI is being produced by ac_compile, and set linker
1341 # options accordingly.
1342 echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
1343 if AC_TRY_EVAL(ac_compile); then
1344 emul=elf
1345 case `/usr/bin/file conftest.$ac_objext` in
1346 *32-bit*)
1347 emul="${emul}32"
1348 ;;
1349 *64-bit*)
1350 emul="${emul}64"
1351 ;;
1352 esac
1353 case `/usr/bin/file conftest.$ac_objext` in
1354 *MSB*)
1355 emul="${emul}btsmip"
1356 ;;
1357 *LSB*)
1358 emul="${emul}ltsmip"
1359 ;;
1360 esac
1361 case `/usr/bin/file conftest.$ac_objext` in
1362 *N32*)
1363 emul="${emul}n32"
1364 ;;
1365 esac
1366 LD="${LD-ld} -m $emul"
1367 fi
1368 rm -rf conftest*
1369 ;;
1370
13141371 x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
13151372 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
1316 # Find out which ABI we are using.
1373 # Find out what ABI is being produced by ac_compile, and set linker
1374 # options accordingly. Note that the listed cases only cover the
1375 # situations where additional linker options are needed (such as when
1376 # doing 32-bit compilation for a host where ld defaults to 64-bit, or
1377 # vice versa); the common cases where no linker options are needed do
1378 # not appear in the list.
13171379 echo 'int i;' > conftest.$ac_ext
13181380 if AC_TRY_EVAL(ac_compile); then
13191381 case `/usr/bin/file conftest.o` in
13321394 ;;
13331395 esac
13341396 ;;
1335 powerpc64le-*)
1397 powerpc64le-*linux*)
13361398 LD="${LD-ld} -m elf32lppclinux"
13371399 ;;
1338 powerpc64-*)
1400 powerpc64-*linux*)
13391401 LD="${LD-ld} -m elf32ppclinux"
13401402 ;;
13411403 s390x-*linux*)
13541416 x86_64-*linux*)
13551417 LD="${LD-ld} -m elf_x86_64"
13561418 ;;
1357 powerpcle-*)
1419 powerpcle-*linux*)
13581420 LD="${LD-ld} -m elf64lppc"
13591421 ;;
1360 powerpc-*)
1422 powerpc-*linux*)
13611423 LD="${LD-ld} -m elf64ppc"
13621424 ;;
13631425 s390*-*linux*|s390*-*tpf*)
13751437
13761438 *-*-sco3.2v5*)
13771439 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
1378 SAVE_CFLAGS="$CFLAGS"
1440 SAVE_CFLAGS=$CFLAGS
13791441 CFLAGS="$CFLAGS -belf"
13801442 AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
13811443 [AC_LANG_PUSH(C)
13821444 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
13831445 AC_LANG_POP])
1384 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
1446 if test yes != "$lt_cv_cc_needs_belf"; then
13851447 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
1386 CFLAGS="$SAVE_CFLAGS"
1448 CFLAGS=$SAVE_CFLAGS
13871449 fi
13881450 ;;
13891451 *-*solaris*)
1390 # Find out which ABI we are using.
1452 # Find out what ABI is being produced by ac_compile, and set linker
1453 # options accordingly.
13911454 echo 'int i;' > conftest.$ac_ext
13921455 if AC_TRY_EVAL(ac_compile); then
13931456 case `/usr/bin/file conftest.o` in
13951458 case $lt_cv_prog_gnu_ld in
13961459 yes*)
13971460 case $host in
1398 i?86-*-solaris*)
1461 i?86-*-solaris*|x86_64-*-solaris*)
13991462 LD="${LD-ld} -m elf_x86_64"
14001463 ;;
14011464 sparc*-*-solaris*)
14041467 esac
14051468 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
14061469 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
1407 LD="${LD-ld}_sol2"
1470 LD=${LD-ld}_sol2
14081471 fi
14091472 ;;
14101473 *)
14201483 ;;
14211484 esac
14221485
1423 need_locks="$enable_libtool_lock"
1486 need_locks=$enable_libtool_lock
14241487 ])# _LT_ENABLE_LOCK
14251488
14261489
14391502 [echo conftest.$ac_objext > conftest.lst
14401503 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
14411504 AC_TRY_EVAL([lt_ar_try])
1442 if test "$ac_status" -eq 0; then
1505 if test 0 -eq "$ac_status"; then
14431506 # Ensure the archiver fails upon bogus file names.
14441507 rm -f conftest.$ac_objext libconftest.a
14451508 AC_TRY_EVAL([lt_ar_try])
1446 if test "$ac_status" -ne 0; then
1509 if test 0 -ne "$ac_status"; then
14471510 lt_cv_ar_at_file=@
14481511 fi
14491512 fi
14511514 ])
14521515 ])
14531516
1454 if test "x$lt_cv_ar_at_file" = xno; then
1517 if test no = "$lt_cv_ar_at_file"; then
14551518 archiver_list_spec=
14561519 else
14571520 archiver_list_spec=$lt_cv_ar_at_file
14821545
14831546 if test -n "$RANLIB"; then
14841547 case $host_os in
1485 openbsd*)
1548 bitrig* | openbsd*)
14861549 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
14871550 ;;
14881551 *)
15181581 [$2=no
15191582 m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
15201583 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
1521 lt_compiler_flag="$3"
1584 lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment
15221585 # Insert the option either (1) after the last *FLAGS variable, or
15231586 # (2) before a word containing "conftest.", or (3) at the end.
15241587 # Note that $ac_compile itself does not contain backslashes and begins
15451608 $RM conftest*
15461609 ])
15471610
1548 if test x"[$]$2" = xyes; then
1611 if test yes = "[$]$2"; then
15491612 m4_if([$5], , :, [$5])
15501613 else
15511614 m4_if([$6], , :, [$6])
15671630 m4_require([_LT_DECL_SED])dnl
15681631 AC_CACHE_CHECK([$1], [$2],
15691632 [$2=no
1570 save_LDFLAGS="$LDFLAGS"
1633 save_LDFLAGS=$LDFLAGS
15711634 LDFLAGS="$LDFLAGS $3"
15721635 echo "$lt_simple_link_test_code" > conftest.$ac_ext
15731636 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
15861649 fi
15871650 fi
15881651 $RM -r conftest*
1589 LDFLAGS="$save_LDFLAGS"
1652 LDFLAGS=$save_LDFLAGS
15901653 ])
15911654
1592 if test x"[$]$2" = xyes; then
1655 if test yes = "[$]$2"; then
15931656 m4_if([$4], , :, [$4])
15941657 else
15951658 m4_if([$5], , :, [$5])
16101673 AC_MSG_CHECKING([the maximum length of command line arguments])
16111674 AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
16121675 i=0
1613 teststring="ABCD"
1676 teststring=ABCD
16141677
16151678 case $build_os in
16161679 msdosdjgpp*)
16501713 lt_cv_sys_max_cmd_len=8192;
16511714 ;;
16521715
1653 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
1716 bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
16541717 # This has been around since 386BSD, at least. Likely further.
16551718 if test -x /sbin/sysctl; then
16561719 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
17011764 *)
17021765 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
17031766 if test -n "$lt_cv_sys_max_cmd_len" && \
1704 test undefined != "$lt_cv_sys_max_cmd_len"; then
1767 test undefined != "$lt_cv_sys_max_cmd_len"; then
17051768 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
17061769 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
17071770 else
17081771 # Make teststring a little bigger before we do anything with it.
17091772 # a 1K string should be a reasonable start.
1710 for i in 1 2 3 4 5 6 7 8 ; do
1773 for i in 1 2 3 4 5 6 7 8; do
17111774 teststring=$teststring$teststring
17121775 done
17131776 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
17141777 # If test is not a shell built-in, we'll probably end up computing a
17151778 # maximum length that is only half of the actual maximum length, but
17161779 # we can't tell.
1717 while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
1780 while { test X`env echo "$teststring$teststring" 2>/dev/null` \
17181781 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
1719 test $i != 17 # 1/2 MB should be enough
1782 test 17 != "$i" # 1/2 MB should be enough
17201783 do
17211784 i=`expr $i + 1`
17221785 teststring=$teststring$teststring
17321795 ;;
17331796 esac
17341797 ])
1735 if test -n $lt_cv_sys_max_cmd_len ; then
1798 if test -n "$lt_cv_sys_max_cmd_len"; then
17361799 AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
17371800 else
17381801 AC_MSG_RESULT(none)
17601823 # ----------------------------------------------------------------
17611824 m4_defun([_LT_TRY_DLOPEN_SELF],
17621825 [m4_require([_LT_HEADER_DLFCN])dnl
1763 if test "$cross_compiling" = yes; then :
1826 if test yes = "$cross_compiling"; then :
17641827 [$4]
17651828 else
17661829 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
18071870 # endif
18081871 #endif
18091872
1810 /* When -fvisbility=hidden is used, assume the code has been annotated
1873 /* When -fvisibility=hidden is used, assume the code has been annotated
18111874 correspondingly for the symbols needed. */
1812 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
1875 #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
18131876 int fnord () __attribute__((visibility("default")));
18141877 #endif
18151878
18351898 return status;
18361899 }]
18371900 _LT_EOF
1838 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
1901 if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then
18391902 (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
18401903 lt_status=$?
18411904 case x$lt_status in
18561919 # ------------------
18571920 AC_DEFUN([LT_SYS_DLOPEN_SELF],
18581921 [m4_require([_LT_HEADER_DLFCN])dnl
1859 if test "x$enable_dlopen" != xyes; then
1922 if test yes != "$enable_dlopen"; then
18601923 enable_dlopen=unknown
18611924 enable_dlopen_self=unknown
18621925 enable_dlopen_self_static=unknown
18661929
18671930 case $host_os in
18681931 beos*)
1869 lt_cv_dlopen="load_add_on"
1932 lt_cv_dlopen=load_add_on
18701933 lt_cv_dlopen_libs=
18711934 lt_cv_dlopen_self=yes
18721935 ;;
18731936
18741937 mingw* | pw32* | cegcc*)
1875 lt_cv_dlopen="LoadLibrary"
1938 lt_cv_dlopen=LoadLibrary
18761939 lt_cv_dlopen_libs=
18771940 ;;
18781941
18791942 cygwin*)
1880 lt_cv_dlopen="dlopen"
1943 lt_cv_dlopen=dlopen
18811944 lt_cv_dlopen_libs=
18821945 ;;
18831946
18841947 darwin*)
1885 # if libdl is installed we need to link against it
1948 # if libdl is installed we need to link against it
18861949 AC_CHECK_LIB([dl], [dlopen],
1887 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
1888 lt_cv_dlopen="dyld"
1950 [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[
1951 lt_cv_dlopen=dyld
18891952 lt_cv_dlopen_libs=
18901953 lt_cv_dlopen_self=yes
18911954 ])
18921955 ;;
18931956
1957 tpf*)
1958 # Don't try to run any link tests for TPF. We know it's impossible
1959 # because TPF is a cross-compiler, and we know how we open DSOs.
1960 lt_cv_dlopen=dlopen
1961 lt_cv_dlopen_libs=
1962 lt_cv_dlopen_self=no
1963 ;;
1964
18941965 *)
18951966 AC_CHECK_FUNC([shl_load],
1896 [lt_cv_dlopen="shl_load"],
1967 [lt_cv_dlopen=shl_load],
18971968 [AC_CHECK_LIB([dld], [shl_load],
1898 [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
1969 [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld],
18991970 [AC_CHECK_FUNC([dlopen],
1900 [lt_cv_dlopen="dlopen"],
1971 [lt_cv_dlopen=dlopen],
19011972 [AC_CHECK_LIB([dl], [dlopen],
1902 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
1973 [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],
19031974 [AC_CHECK_LIB([svld], [dlopen],
1904 [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
1975 [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld],
19051976 [AC_CHECK_LIB([dld], [dld_link],
1906 [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
1977 [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld])
19071978 ])
19081979 ])
19091980 ])
19121983 ;;
19131984 esac
19141985
1915 if test "x$lt_cv_dlopen" != xno; then
1986 if test no = "$lt_cv_dlopen"; then
1987 enable_dlopen=no
1988 else
19161989 enable_dlopen=yes
1917 else
1918 enable_dlopen=no
19191990 fi
19201991
19211992 case $lt_cv_dlopen in
19221993 dlopen)
1923 save_CPPFLAGS="$CPPFLAGS"
1924 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1925
1926 save_LDFLAGS="$LDFLAGS"
1994 save_CPPFLAGS=$CPPFLAGS
1995 test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
1996
1997 save_LDFLAGS=$LDFLAGS
19271998 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
19281999
1929 save_LIBS="$LIBS"
2000 save_LIBS=$LIBS
19302001 LIBS="$lt_cv_dlopen_libs $LIBS"
19312002
19322003 AC_CACHE_CHECK([whether a program can dlopen itself],
19362007 lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
19372008 ])
19382009
1939 if test "x$lt_cv_dlopen_self" = xyes; then
2010 if test yes = "$lt_cv_dlopen_self"; then
19402011 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
19412012 AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
19422013 lt_cv_dlopen_self_static, [dnl
19462017 ])
19472018 fi
19482019
1949 CPPFLAGS="$save_CPPFLAGS"
1950 LDFLAGS="$save_LDFLAGS"
1951 LIBS="$save_LIBS"
2020 CPPFLAGS=$save_CPPFLAGS
2021 LDFLAGS=$save_LDFLAGS
2022 LIBS=$save_LIBS
19522023 ;;
19532024 esac
19542025
20402111 m4_require([_LT_FILEUTILS_DEFAULTS])dnl
20412112 _LT_COMPILER_C_O([$1])
20422113
2043 hard_links="nottested"
2044 if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
2114 hard_links=nottested
2115 if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then
20452116 # do not overwrite the value of need_locks provided by the user
20462117 AC_MSG_CHECKING([if we can lock with hard links])
20472118 hard_links=yes
20512122 ln conftest.a conftest.b 2>&5 || hard_links=no
20522123 ln conftest.a conftest.b 2>/dev/null && hard_links=no
20532124 AC_MSG_RESULT([$hard_links])
2054 if test "$hard_links" = no; then
2055 AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
2125 if test no = "$hard_links"; then
2126 AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe])
20562127 need_locks=warn
20572128 fi
20582129 else
20792150 _LT_DECL([], [objdir], [0],
20802151 [The name of the directory that contains temporary libtool files])dnl
20812152 m4_pattern_allow([LT_OBJDIR])dnl
2082 AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
2083 [Define to the sub-directory in which libtool stores uninstalled libraries.])
2153 AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/",
2154 [Define to the sub-directory where libtool stores uninstalled libraries.])
20842155 ])# _LT_CHECK_OBJDIR
20852156
20862157
20922163 _LT_TAGVAR(hardcode_action, $1)=
20932164 if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
20942165 test -n "$_LT_TAGVAR(runpath_var, $1)" ||
2095 test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
2166 test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then
20962167
20972168 # We can hardcode non-existent directories.
2098 if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
2169 if test no != "$_LT_TAGVAR(hardcode_direct, $1)" &&
20992170 # If the only mechanism to avoid hardcoding is shlibpath_var, we
21002171 # have to relink, otherwise we might link with an installed library
21012172 # when we should be linking with a yet-to-be-installed one
2102 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
2103 test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
2173 ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" &&
2174 test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then
21042175 # Linking always hardcodes the temporary library directory.
21052176 _LT_TAGVAR(hardcode_action, $1)=relink
21062177 else
21142185 fi
21152186 AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
21162187
2117 if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
2118 test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
2188 if test relink = "$_LT_TAGVAR(hardcode_action, $1)" ||
2189 test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then
21192190 # Fast installation is not supported
21202191 enable_fast_install=no
2121 elif test "$shlibpath_overrides_runpath" = yes ||
2122 test "$enable_shared" = no; then
2192 elif test yes = "$shlibpath_overrides_runpath" ||
2193 test no = "$enable_shared"; then
21232194 # Fast installation is not necessary
21242195 enable_fast_install=needless
21252196 fi
21432214 # FIXME - insert some real tests, host_os isn't really good enough
21442215 case $host_os in
21452216 darwin*)
2146 if test -n "$STRIP" ; then
2217 if test -n "$STRIP"; then
21472218 striplib="$STRIP -x"
21482219 old_striplib="$STRIP -S"
21492220 AC_MSG_RESULT([yes])
21612232 ])# _LT_CMD_STRIPLIB
21622233
21632234
2235 # _LT_PREPARE_MUNGE_PATH_LIST
2236 # ---------------------------
2237 # Make sure func_munge_path_list() is defined correctly.
2238 m4_defun([_LT_PREPARE_MUNGE_PATH_LIST],
2239 [[# func_munge_path_list VARIABLE PATH
2240 # -----------------------------------
2241 # VARIABLE is name of variable containing _space_ separated list of
2242 # directories to be munged by the contents of PATH, which is string
2243 # having a format:
2244 # "DIR[:DIR]:"
2245 # string "DIR[ DIR]" will be prepended to VARIABLE
2246 # ":DIR[:DIR]"
2247 # string "DIR[ DIR]" will be appended to VARIABLE
2248 # "DIRP[:DIRP]::[DIRA:]DIRA"
2249 # string "DIRP[ DIRP]" will be prepended to VARIABLE and string
2250 # "DIRA[ DIRA]" will be appended to VARIABLE
2251 # "DIR[:DIR]"
2252 # VARIABLE will be replaced by "DIR[ DIR]"
2253 func_munge_path_list ()
2254 {
2255 case x@S|@2 in
2256 x)
2257 ;;
2258 *:)
2259 eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\"
2260 ;;
2261 x:*)
2262 eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\"
2263 ;;
2264 *::*)
2265 eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
2266 eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\"
2267 ;;
2268 *)
2269 eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\"
2270 ;;
2271 esac
2272 }
2273 ]])# _LT_PREPARE_PATH_LIST
2274
2275
21642276 # _LT_SYS_DYNAMIC_LINKER([TAG])
21652277 # -----------------------------
21662278 # PORTME Fill in your ld.so characteristics
21712283 m4_require([_LT_DECL_OBJDUMP])dnl
21722284 m4_require([_LT_DECL_SED])dnl
21732285 m4_require([_LT_CHECK_SHELL_FEATURES])dnl
2286 m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl
21742287 AC_MSG_CHECKING([dynamic linker characteristics])
21752288 m4_if([$1],
21762289 [], [
2177 if test "$GCC" = yes; then
2290 if test yes = "$GCC"; then
21782291 case $host_os in
2179 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
2180 *) lt_awk_arg="/^libraries:/" ;;
2292 darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
2293 *) lt_awk_arg='/^libraries:/' ;;
21812294 esac
21822295 case $host_os in
2183 mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
2184 *) lt_sed_strip_eq="s,=/,/,g" ;;
2296 mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;;
2297 *) lt_sed_strip_eq='s|=/|/|g' ;;
21852298 esac
21862299 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
21872300 case $lt_search_path_spec in
21972310 ;;
21982311 esac
21992312 # Ok, now we have the path, separated by spaces, we can step through it
2200 # and add multilib dir if necessary.
2313 # and add multilib dir if necessary...
22012314 lt_tmp_lt_search_path_spec=
2202 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2315 lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
2316 # ...but if some path component already ends with the multilib dir we assume
2317 # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
2318 case "$lt_multi_os_dir; $lt_search_path_spec " in
2319 "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
2320 lt_multi_os_dir=
2321 ;;
2322 esac
22032323 for lt_sys_path in $lt_search_path_spec; do
2204 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
2205 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
2206 else
2324 if test -d "$lt_sys_path$lt_multi_os_dir"; then
2325 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
2326 elif test -n "$lt_multi_os_dir"; then
22072327 test -d "$lt_sys_path" && \
22082328 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
22092329 fi
22102330 done
22112331 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
2212 BEGIN {RS=" "; FS="/|\n";} {
2213 lt_foo="";
2214 lt_count=0;
2332 BEGIN {RS = " "; FS = "/|\n";} {
2333 lt_foo = "";
2334 lt_count = 0;
22152335 for (lt_i = NF; lt_i > 0; lt_i--) {
22162336 if ($lt_i != "" && $lt_i != ".") {
22172337 if ($lt_i == "..") {
22182338 lt_count++;
22192339 } else {
22202340 if (lt_count == 0) {
2221 lt_foo="/" $lt_i lt_foo;
2341 lt_foo = "/" $lt_i lt_foo;
22222342 } else {
22232343 lt_count--;
22242344 }
22322352 # for these hosts.
22332353 case $host_os in
22342354 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
2235 $SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
2355 $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;;
22362356 esac
22372357 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
22382358 else
22412361 library_names_spec=
22422362 libname_spec='lib$name'
22432363 soname_spec=
2244 shrext_cmds=".so"
2364 shrext_cmds=.so
22452365 postinstall_cmds=
22462366 postuninstall_cmds=
22472367 finish_cmds=
22582378 # flags to be left without arguments
22592379 need_version=unknown
22602380
2381 AC_ARG_VAR([LT_SYS_LIBRARY_PATH],
2382 [User-defined run-time library search path.])
2383
22612384 case $host_os in
22622385 aix3*)
22632386 version_type=linux # correct to gnu/linux during the next big refactor
2264 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
2387 library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
22652388 shlibpath_var=LIBPATH
22662389
22672390 # AIX 3 has no versioning support, so we append a major version to the name.
2268 soname_spec='${libname}${release}${shared_ext}$major'
2391 soname_spec='$libname$release$shared_ext$major'
22692392 ;;
22702393
22712394 aix[[4-9]]*)
22732396 need_lib_prefix=no
22742397 need_version=no
22752398 hardcode_into_libs=yes
2276 if test "$host_cpu" = ia64; then
2399 if test ia64 = "$host_cpu"; then
22772400 # AIX 5 supports IA64
2278 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
2401 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
22792402 shlibpath_var=LD_LIBRARY_PATH
22802403 else
22812404 # With GCC up to 2.95.x, collect2 would create an import file
22822405 # for dependence libraries. The import file would start with
2283 # the line `#! .'. This would cause the generated library to
2284 # depend on `.', always an invalid library. This was fixed in
2406 # the line '#! .'. This would cause the generated library to
2407 # depend on '.', always an invalid library. This was fixed in
22852408 # development snapshots of GCC prior to 3.0.
22862409 case $host_os in
22872410 aix4 | aix4.[[01]] | aix4.[[01]].*)
22882411 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
22892412 echo ' yes '
2290 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
2413 echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
22912414 :
22922415 else
22932416 can_build_shared=no
22942417 fi
22952418 ;;
22962419 esac
2297 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
2420 # Using Import Files as archive members, it is possible to support
2421 # filename-based versioning of shared library archives on AIX. While
2422 # this would work for both with and without runtime linking, it will
2423 # prevent static linking of such archives. So we do filename-based
2424 # shared library versioning with .so extension only, which is used
2425 # when both runtime linking and shared linking is enabled.
2426 # Unfortunately, runtime linking may impact performance, so we do
2427 # not want this to be the default eventually. Also, we use the
2428 # versioned .so libs for executables only if there is the -brtl
2429 # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
2430 # To allow for filename-based versioning support, we need to create
2431 # libNAME.so.V as an archive file, containing:
2432 # *) an Import File, referring to the versioned filename of the
2433 # archive as well as the shared archive member, telling the
2434 # bitwidth (32 or 64) of that shared object, and providing the
2435 # list of exported symbols of that shared object, eventually
2436 # decorated with the 'weak' keyword
2437 # *) the shared object with the F_LOADONLY flag set, to really avoid
2438 # it being seen by the linker.
2439 # At run time we better use the real file rather than another symlink,
2440 # but for link time we create the symlink libNAME.so -> libNAME.so.V
2441
2442 case $with_aix_soname,$aix_use_runtimelinking in
2443 # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
22982444 # soname into executable. Probably we can add versioning support to
22992445 # collect2, so additional links can be useful in future.
2300 if test "$aix_use_runtimelinking" = yes; then
2446 aix,yes) # traditional libtool
2447 dynamic_linker='AIX unversionable lib.so'
23012448 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
23022449 # instead of lib<name>.a to let people know that these are not
23032450 # typical AIX shared libraries.
2304 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2305 else
2451 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2452 ;;
2453 aix,no) # traditional AIX only
2454 dynamic_linker='AIX lib.a[(]lib.so.V[)]'
23062455 # We preserve .a as extension for shared libraries through AIX4.2
23072456 # and later when we are not doing run time linking.
2308 library_names_spec='${libname}${release}.a $libname.a'
2309 soname_spec='${libname}${release}${shared_ext}$major'
2310 fi
2457 library_names_spec='$libname$release.a $libname.a'
2458 soname_spec='$libname$release$shared_ext$major'
2459 ;;
2460 svr4,*) # full svr4 only
2461 dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]"
2462 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
2463 # We do not specify a path in Import Files, so LIBPATH fires.
2464 shlibpath_overrides_runpath=yes
2465 ;;
2466 *,yes) # both, prefer svr4
2467 dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]"
2468 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
2469 # unpreferred sharedlib libNAME.a needs extra handling
2470 postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"'
2471 postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"'
2472 # We do not specify a path in Import Files, so LIBPATH fires.
2473 shlibpath_overrides_runpath=yes
2474 ;;
2475 *,no) # both, prefer aix
2476 dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]"
2477 library_names_spec='$libname$release.a $libname.a'
2478 soname_spec='$libname$release$shared_ext$major'
2479 # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
2480 postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)'
2481 postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"'
2482 ;;
2483 esac
23112484 shlibpath_var=LIBPATH
23122485 fi
23132486 ;;
23172490 powerpc)
23182491 # Since July 2007 AmigaOS4 officially supports .so libraries.
23192492 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
2320 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2493 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
23212494 ;;
23222495 m68k)
23232496 library_names_spec='$libname.ixlibrary $libname.a'
23242497 # Create ${libname}_ixlibrary.a entries in /sys/libs.
2325 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
2498 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
23262499 ;;
23272500 esac
23282501 ;;
23292502
23302503 beos*)
2331 library_names_spec='${libname}${shared_ext}'
2504 library_names_spec='$libname$shared_ext'
23322505 dynamic_linker="$host_os ld.so"
23332506 shlibpath_var=LIBRARY_PATH
23342507 ;;
23362509 bsdi[[45]]*)
23372510 version_type=linux # correct to gnu/linux during the next big refactor
23382511 need_version=no
2339 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2340 soname_spec='${libname}${release}${shared_ext}$major'
2512 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2513 soname_spec='$libname$release$shared_ext$major'
23412514 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
23422515 shlibpath_var=LD_LIBRARY_PATH
23432516 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
23492522
23502523 cygwin* | mingw* | pw32* | cegcc*)
23512524 version_type=windows
2352 shrext_cmds=".dll"
2525 shrext_cmds=.dll
23532526 need_version=no
23542527 need_lib_prefix=no
23552528
23582531 # gcc
23592532 library_names_spec='$libname.dll.a'
23602533 # DLL is installed to $(libdir)/../bin by postinstall_cmds
2361 postinstall_cmds='base_file=`basename \${file}`~
2362 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
2534 postinstall_cmds='base_file=`basename \$file`~
2535 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
23632536 dldir=$destdir/`dirname \$dlpath`~
23642537 test -d \$dldir || mkdir -p \$dldir~
23652538 $install_prog $dir/$dlname \$dldir/$dlname~
23752548 case $host_os in
23762549 cygwin*)
23772550 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
2378 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2551 soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
23792552 m4_if([$1], [],[
23802553 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
23812554 ;;
23822555 mingw* | cegcc*)
23832556 # MinGW DLLs use traditional 'lib' prefix
2384 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2557 soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
23852558 ;;
23862559 pw32*)
23872560 # pw32 DLLs use 'pw' prefix rather than 'lib'
2388 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2561 library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
23892562 ;;
23902563 esac
23912564 dynamic_linker='Win32 ld.exe'
23942567 *,cl*)
23952568 # Native MSVC
23962569 libname_spec='$name'
2397 soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
2398 library_names_spec='${libname}.dll.lib'
2570 soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext'
2571 library_names_spec='$libname.dll.lib'
23992572
24002573 case $build_os in
24012574 mingw*)
24222595 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
24232596 ;;
24242597 *)
2425 sys_lib_search_path_spec="$LIB"
2598 sys_lib_search_path_spec=$LIB
24262599 if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
24272600 # It is most probably a Windows format PATH.
24282601 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
24352608 esac
24362609
24372610 # DLL is installed to $(libdir)/../bin by postinstall_cmds
2438 postinstall_cmds='base_file=`basename \${file}`~
2439 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
2611 postinstall_cmds='base_file=`basename \$file`~
2612 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
24402613 dldir=$destdir/`dirname \$dlpath`~
24412614 test -d \$dldir || mkdir -p \$dldir~
24422615 $install_prog $dir/$dlname \$dldir/$dlname'
24492622
24502623 *)
24512624 # Assume MSVC wrapper
2452 library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
2625 library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib'
24532626 dynamic_linker='Win32 ld.exe'
24542627 ;;
24552628 esac
24622635 version_type=darwin
24632636 need_lib_prefix=no
24642637 need_version=no
2465 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
2466 soname_spec='${libname}${release}${major}$shared_ext'
2638 library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
2639 soname_spec='$libname$release$major$shared_ext'
24672640 shlibpath_overrides_runpath=yes
24682641 shlibpath_var=DYLD_LIBRARY_PATH
24692642 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
24762649 version_type=linux # correct to gnu/linux during the next big refactor
24772650 need_lib_prefix=no
24782651 need_version=no
2479 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
2480 soname_spec='${libname}${release}${shared_ext}$major'
2652 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2653 soname_spec='$libname$release$shared_ext$major'
24812654 shlibpath_var=LD_LIBRARY_PATH
24822655 ;;
24832656
24952668 version_type=freebsd-$objformat
24962669 case $version_type in
24972670 freebsd-elf*)
2498 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2671 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2672 soname_spec='$libname$release$shared_ext$major'
24992673 need_version=no
25002674 need_lib_prefix=no
25012675 ;;
25022676 freebsd-*)
2503 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
2677 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
25042678 need_version=yes
25052679 ;;
25062680 esac
25302704 need_lib_prefix=no
25312705 need_version=no
25322706 dynamic_linker="$host_os runtime_loader"
2533 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
2534 soname_spec='${libname}${release}${shared_ext}$major'
2707 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2708 soname_spec='$libname$release$shared_ext$major'
25352709 shlibpath_var=LIBRARY_PATH
2536 shlibpath_overrides_runpath=yes
2710 shlibpath_overrides_runpath=no
25372711 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
25382712 hardcode_into_libs=yes
25392713 ;;
25512725 dynamic_linker="$host_os dld.so"
25522726 shlibpath_var=LD_LIBRARY_PATH
25532727 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2554 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2555 soname_spec='${libname}${release}${shared_ext}$major'
2556 if test "X$HPUX_IA64_MODE" = X32; then
2728 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2729 soname_spec='$libname$release$shared_ext$major'
2730 if test 32 = "$HPUX_IA64_MODE"; then
25572731 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
2732 sys_lib_dlsearch_path_spec=/usr/lib/hpux32
25582733 else
25592734 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
2735 sys_lib_dlsearch_path_spec=/usr/lib/hpux64
25602736 fi
2561 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
25622737 ;;
25632738 hppa*64*)
25642739 shrext_cmds='.sl'
25662741 dynamic_linker="$host_os dld.sl"
25672742 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
25682743 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
2569 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2570 soname_spec='${libname}${release}${shared_ext}$major'
2744 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2745 soname_spec='$libname$release$shared_ext$major'
25712746 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
25722747 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
25732748 ;;
25762751 dynamic_linker="$host_os dld.sl"
25772752 shlibpath_var=SHLIB_PATH
25782753 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
2579 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2580 soname_spec='${libname}${release}${shared_ext}$major'
2754 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2755 soname_spec='$libname$release$shared_ext$major'
25812756 ;;
25822757 esac
25832758 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
25902765 version_type=linux # correct to gnu/linux during the next big refactor
25912766 need_lib_prefix=no
25922767 need_version=no
2593 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2594 soname_spec='${libname}${release}${shared_ext}$major'
2768 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2769 soname_spec='$libname$release$shared_ext$major'
25952770 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
25962771 shlibpath_var=LD_LIBRARY_PATH
25972772 shlibpath_overrides_runpath=no
26022777 case $host_os in
26032778 nonstopux*) version_type=nonstopux ;;
26042779 *)
2605 if test "$lt_cv_prog_gnu_ld" = yes; then
2780 if test yes = "$lt_cv_prog_gnu_ld"; then
26062781 version_type=linux # correct to gnu/linux during the next big refactor
26072782 else
26082783 version_type=irix
26102785 esac
26112786 need_lib_prefix=no
26122787 need_version=no
2613 soname_spec='${libname}${release}${shared_ext}$major'
2614 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
2788 soname_spec='$libname$release$shared_ext$major'
2789 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
26152790 case $host_os in
26162791 irix5* | nonstopux*)
26172792 libsuff= shlibsuff=
26302805 esac
26312806 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
26322807 shlibpath_overrides_runpath=no
2633 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
2634 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
2808 sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
2809 sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
26352810 hardcode_into_libs=yes
26362811 ;;
26372812
26382813 # No shared lib support for Linux oldld, aout, or coff.
26392814 linux*oldld* | linux*aout* | linux*coff*)
26402815 dynamic_linker=no
2816 ;;
2817
2818 linux*android*)
2819 version_type=none # Android doesn't support versioned libraries.
2820 need_lib_prefix=no
2821 need_version=no
2822 library_names_spec='$libname$release$shared_ext'
2823 soname_spec='$libname$release$shared_ext'
2824 finish_cmds=
2825 shlibpath_var=LD_LIBRARY_PATH
2826 shlibpath_overrides_runpath=yes
2827
2828 # This implies no fast_install, which is unacceptable.
2829 # Some rework will be needed to allow for fast_install
2830 # before this can be enabled.
2831 hardcode_into_libs=yes
2832
2833 dynamic_linker='Android linker'
2834 # Don't embed -rpath directories since the linker doesn't support them.
2835 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
26412836 ;;
26422837
26432838 # This must be glibc/ELF.
26452840 version_type=linux # correct to gnu/linux during the next big refactor
26462841 need_lib_prefix=no
26472842 need_version=no
2648 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2649 soname_spec='${libname}${release}${shared_ext}$major'
2843 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2844 soname_spec='$libname$release$shared_ext$major'
26502845 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
26512846 shlibpath_var=LD_LIBRARY_PATH
26522847 shlibpath_overrides_runpath=no
26712866 # before this can be enabled.
26722867 hardcode_into_libs=yes
26732868
2674 # Append ld.so.conf contents to the search path
2869 # Ideally, we could use ldconfig to report *all* directores which are
2870 # searched for libraries, however this is still not possible. Aside from not
2871 # being certain /sbin/ldconfig is available, command
2872 # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
2873 # even though it is searched at run-time. Try to do the best guess by
2874 # appending ld.so.conf contents (and includes) to the search path.
26752875 if test -f /etc/ld.so.conf; then
26762876 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
26772877 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
26862886 dynamic_linker='GNU/Linux ld.so'
26872887 ;;
26882888
2689 netbsdelf*-gnu)
2690 version_type=linux
2691 need_lib_prefix=no
2692 need_version=no
2693 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2694 soname_spec='${libname}${release}${shared_ext}$major'
2695 shlibpath_var=LD_LIBRARY_PATH
2696 shlibpath_overrides_runpath=no
2697 hardcode_into_libs=yes
2698 dynamic_linker='NetBSD ld.elf_so'
2699 ;;
2700
27012889 netbsd*)
27022890 version_type=sunos
27032891 need_lib_prefix=no
27042892 need_version=no
27052893 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
2706 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2894 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
27072895 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
27082896 dynamic_linker='NetBSD (a.out) ld.so'
27092897 else
2710 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
2711 soname_spec='${libname}${release}${shared_ext}$major'
2898 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2899 soname_spec='$libname$release$shared_ext$major'
27122900 dynamic_linker='NetBSD ld.elf_so'
27132901 fi
27142902 shlibpath_var=LD_LIBRARY_PATH
27182906
27192907 newsos6)
27202908 version_type=linux # correct to gnu/linux during the next big refactor
2721 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2909 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
27222910 shlibpath_var=LD_LIBRARY_PATH
27232911 shlibpath_overrides_runpath=yes
27242912 ;;
27272915 version_type=qnx
27282916 need_lib_prefix=no
27292917 need_version=no
2730 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2731 soname_spec='${libname}${release}${shared_ext}$major'
2918 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2919 soname_spec='$libname$release$shared_ext$major'
27322920 shlibpath_var=LD_LIBRARY_PATH
27332921 shlibpath_overrides_runpath=no
27342922 hardcode_into_libs=yes
27352923 dynamic_linker='ldqnx.so'
27362924 ;;
27372925
2738 openbsd*)
2926 openbsd* | bitrig*)
27392927 version_type=sunos
2740 sys_lib_dlsearch_path_spec="/usr/lib"
2928 sys_lib_dlsearch_path_spec=/usr/lib
27412929 need_lib_prefix=no
2742 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
2743 case $host_os in
2744 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
2745 *) need_version=no ;;
2746 esac
2747 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
2930 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
2931 need_version=no
2932 else
2933 need_version=yes
2934 fi
2935 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
27482936 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
27492937 shlibpath_var=LD_LIBRARY_PATH
2750 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
2751 case $host_os in
2752 openbsd2.[[89]] | openbsd2.[[89]].*)
2753 shlibpath_overrides_runpath=no
2754 ;;
2755 *)
2756 shlibpath_overrides_runpath=yes
2757 ;;
2758 esac
2759 else
2760 shlibpath_overrides_runpath=yes
2761 fi
2938 shlibpath_overrides_runpath=yes
27622939 ;;
27632940
27642941 os2*)
27652942 libname_spec='$name'
2766 shrext_cmds=".dll"
2943 version_type=windows
2944 shrext_cmds=.dll
2945 need_version=no
27672946 need_lib_prefix=no
2768 library_names_spec='$libname${shared_ext} $libname.a'
2947 # OS/2 can only load a DLL with a base name of 8 characters or less.
2948 soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
2949 v=$($ECHO $release$versuffix | tr -d .-);
2950 n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
2951 $ECHO $n$v`$shared_ext'
2952 library_names_spec='${libname}_dll.$libext'
27692953 dynamic_linker='OS/2 ld.exe'
2770 shlibpath_var=LIBPATH
2954 shlibpath_var=BEGINLIBPATH
2955 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
2956 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
2957 postinstall_cmds='base_file=`basename \$file`~
2958 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
2959 dldir=$destdir/`dirname \$dlpath`~
2960 test -d \$dldir || mkdir -p \$dldir~
2961 $install_prog $dir/$dlname \$dldir/$dlname~
2962 chmod a+x \$dldir/$dlname~
2963 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
2964 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
2965 fi'
2966 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
2967 dlpath=$dir/\$dldll~
2968 $RM \$dlpath'
27712969 ;;
27722970
27732971 osf3* | osf4* | osf5*)
27742972 version_type=osf
27752973 need_lib_prefix=no
27762974 need_version=no
2777 soname_spec='${libname}${release}${shared_ext}$major'
2778 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2975 soname_spec='$libname$release$shared_ext$major'
2976 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
27792977 shlibpath_var=LD_LIBRARY_PATH
27802978 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
2781 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
2979 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
27822980 ;;
27832981
27842982 rdos*)
27892987 version_type=linux # correct to gnu/linux during the next big refactor
27902988 need_lib_prefix=no
27912989 need_version=no
2792 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2793 soname_spec='${libname}${release}${shared_ext}$major'
2990 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
2991 soname_spec='$libname$release$shared_ext$major'
27942992 shlibpath_var=LD_LIBRARY_PATH
27952993 shlibpath_overrides_runpath=yes
27962994 hardcode_into_libs=yes
28002998
28012999 sunos4*)
28023000 version_type=sunos
2803 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
3001 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
28043002 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
28053003 shlibpath_var=LD_LIBRARY_PATH
28063004 shlibpath_overrides_runpath=yes
2807 if test "$with_gnu_ld" = yes; then
3005 if test yes = "$with_gnu_ld"; then
28083006 need_lib_prefix=no
28093007 fi
28103008 need_version=yes
28123010
28133011 sysv4 | sysv4.3*)
28143012 version_type=linux # correct to gnu/linux during the next big refactor
2815 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2816 soname_spec='${libname}${release}${shared_ext}$major'
3013 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3014 soname_spec='$libname$release$shared_ext$major'
28173015 shlibpath_var=LD_LIBRARY_PATH
28183016 case $host_vendor in
28193017 sni)
28343032 ;;
28353033
28363034 sysv4*MP*)
2837 if test -d /usr/nec ;then
3035 if test -d /usr/nec; then
28383036 version_type=linux # correct to gnu/linux during the next big refactor
2839 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
2840 soname_spec='$libname${shared_ext}.$major'
3037 library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
3038 soname_spec='$libname$shared_ext.$major'
28413039 shlibpath_var=LD_LIBRARY_PATH
28423040 fi
28433041 ;;
28443042
28453043 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
2846 version_type=freebsd-elf
3044 version_type=sco
28473045 need_lib_prefix=no
28483046 need_version=no
2849 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
2850 soname_spec='${libname}${release}${shared_ext}$major'
3047 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
3048 soname_spec='$libname$release$shared_ext$major'
28513049 shlibpath_var=LD_LIBRARY_PATH
28523050 shlibpath_overrides_runpath=yes
28533051 hardcode_into_libs=yes
2854 if test "$with_gnu_ld" = yes; then
3052 if test yes = "$with_gnu_ld"; then
28553053 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
28563054 else
28573055 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
28693067 version_type=linux # correct to gnu/linux during the next big refactor
28703068 need_lib_prefix=no
28713069 need_version=no
2872 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
3070 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
28733071 shlibpath_var=LD_LIBRARY_PATH
28743072 shlibpath_overrides_runpath=no
28753073 hardcode_into_libs=yes
28773075
28783076 uts4*)
28793077 version_type=linux # correct to gnu/linux during the next big refactor
2880 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
2881 soname_spec='${libname}${release}${shared_ext}$major'
3078 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
3079 soname_spec='$libname$release$shared_ext$major'
28823080 shlibpath_var=LD_LIBRARY_PATH
28833081 ;;
28843082
28873085 ;;
28883086 esac
28893087 AC_MSG_RESULT([$dynamic_linker])
2890 test "$dynamic_linker" = no && can_build_shared=no
3088 test no = "$dynamic_linker" && can_build_shared=no
28913089
28923090 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
2893 if test "$GCC" = yes; then
3091 if test yes = "$GCC"; then
28943092 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
28953093 fi
28963094
2897 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
2898 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
3095 if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
3096 sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
28993097 fi
2900 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
2901 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
3098
3099 if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
3100 sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
29023101 fi
3102
3103 # remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
3104 configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
3105
3106 # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
3107 func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
3108
3109 # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
3110 configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
29033111
29043112 _LT_DECL([], [variables_saved_for_relink], [1],
29053113 [Variables whose values should be saved in libtool wrapper scripts and
29333141 [Whether we should hardcode library paths into libraries])
29343142 _LT_DECL([], [sys_lib_search_path_spec], [2],
29353143 [Compile-time system search path for libraries])
2936 _LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
2937 [Run-time system search path for libraries])
3144 _LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2],
3145 [Detected run-time system search path for libraries])
3146 _LT_DECL([], [configure_time_lt_sys_library_path], [2],
3147 [Explicit LT_SYS_LIBRARY_PATH set during ./configure time])
29383148 ])# _LT_SYS_DYNAMIC_LINKER
29393149
29403150
29413151 # _LT_PATH_TOOL_PREFIX(TOOL)
29423152 # --------------------------
2943 # find a file program which can recognize shared library
3153 # find a file program that can recognize shared library
29443154 AC_DEFUN([_LT_PATH_TOOL_PREFIX],
29453155 [m4_require([_LT_DECL_EGREP])dnl
29463156 AC_MSG_CHECKING([for $1])
29473157 AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
29483158 [case $MAGIC_CMD in
29493159 [[\\/*] | ?:[\\/]*])
2950 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
3160 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
29513161 ;;
29523162 *)
2953 lt_save_MAGIC_CMD="$MAGIC_CMD"
2954 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3163 lt_save_MAGIC_CMD=$MAGIC_CMD
3164 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
29553165 dnl $ac_dummy forces splitting on constant user-supplied paths.
29563166 dnl POSIX.2 word splitting is done only on the output of word expansions,
29573167 dnl not every word. This closes a longstanding sh security hole.
29583168 ac_dummy="m4_if([$2], , $PATH, [$2])"
29593169 for ac_dir in $ac_dummy; do
2960 IFS="$lt_save_ifs"
3170 IFS=$lt_save_ifs
29613171 test -z "$ac_dir" && ac_dir=.
2962 if test -f $ac_dir/$1; then
2963 lt_cv_path_MAGIC_CMD="$ac_dir/$1"
3172 if test -f "$ac_dir/$1"; then
3173 lt_cv_path_MAGIC_CMD=$ac_dir/"$1"
29643174 if test -n "$file_magic_test_file"; then
29653175 case $deplibs_check_method in
29663176 "file_magic "*)
29673177 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
2968 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3178 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
29693179 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
29703180 $EGREP "$file_magic_regex" > /dev/null; then
29713181 :
29883198 break
29893199 fi
29903200 done
2991 IFS="$lt_save_ifs"
2992 MAGIC_CMD="$lt_save_MAGIC_CMD"
3201 IFS=$lt_save_ifs
3202 MAGIC_CMD=$lt_save_MAGIC_CMD
29933203 ;;
29943204 esac])
2995 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
3205 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
29963206 if test -n "$MAGIC_CMD"; then
29973207 AC_MSG_RESULT($MAGIC_CMD)
29983208 else
30103220
30113221 # _LT_PATH_MAGIC
30123222 # --------------
3013 # find a file program which can recognize a shared library
3223 # find a file program that can recognize a shared library
30143224 m4_defun([_LT_PATH_MAGIC],
30153225 [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
30163226 if test -z "$lt_cv_path_MAGIC_CMD"; then
30373247 AC_ARG_WITH([gnu-ld],
30383248 [AS_HELP_STRING([--with-gnu-ld],
30393249 [assume the C compiler uses GNU ld @<:@default=no@:>@])],
3040 [test "$withval" = no || with_gnu_ld=yes],
3250 [test no = "$withval" || with_gnu_ld=yes],
30413251 [with_gnu_ld=no])dnl
30423252
30433253 ac_prog=ld
3044 if test "$GCC" = yes; then
3254 if test yes = "$GCC"; then
30453255 # Check if gcc -print-prog-name=ld gives a path.
30463256 AC_MSG_CHECKING([for ld used by $CC])
30473257 case $host in
30483258 *-*-mingw*)
3049 # gcc leaves a trailing carriage return which upsets mingw
3259 # gcc leaves a trailing carriage return, which upsets mingw
30503260 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
30513261 *)
30523262 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
30603270 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
30613271 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
30623272 done
3063 test -z "$LD" && LD="$ac_prog"
3273 test -z "$LD" && LD=$ac_prog
30643274 ;;
30653275 "")
30663276 # If it fails, then pretend we aren't using GCC.
30713281 with_gnu_ld=unknown
30723282 ;;
30733283 esac
3074 elif test "$with_gnu_ld" = yes; then
3284 elif test yes = "$with_gnu_ld"; then
30753285 AC_MSG_CHECKING([for GNU ld])
30763286 else
30773287 AC_MSG_CHECKING([for non-GNU ld])
30783288 fi
30793289 AC_CACHE_VAL(lt_cv_path_LD,
30803290 [if test -z "$LD"; then
3081 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3291 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
30823292 for ac_dir in $PATH; do
3083 IFS="$lt_save_ifs"
3293 IFS=$lt_save_ifs
30843294 test -z "$ac_dir" && ac_dir=.
30853295 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3086 lt_cv_path_LD="$ac_dir/$ac_prog"
3296 lt_cv_path_LD=$ac_dir/$ac_prog
30873297 # Check to see if the program is GNU ld. I'd rather use --version,
30883298 # but apparently some variants of GNU ld only accept -v.
30893299 # Break only if it was the GNU/non-GNU ld that we prefer.
30903300 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
30913301 *GNU* | *'with BFD'*)
3092 test "$with_gnu_ld" != no && break
3302 test no != "$with_gnu_ld" && break
30933303 ;;
30943304 *)
3095 test "$with_gnu_ld" != yes && break
3305 test yes != "$with_gnu_ld" && break
30963306 ;;
30973307 esac
30983308 fi
30993309 done
3100 IFS="$lt_save_ifs"
3310 IFS=$lt_save_ifs
31013311 else
3102 lt_cv_path_LD="$LD" # Let the user override the test with a path.
3312 lt_cv_path_LD=$LD # Let the user override the test with a path.
31033313 fi])
3104 LD="$lt_cv_path_LD"
3314 LD=$lt_cv_path_LD
31053315 if test -n "$LD"; then
31063316 AC_MSG_RESULT($LD)
31073317 else
31553365 reload_cmds='$LD$reload_flag -o $output$reload_objs'
31563366 case $host_os in
31573367 cygwin* | mingw* | pw32* | cegcc*)
3158 if test "$GCC" != yes; then
3368 if test yes != "$GCC"; then
31593369 reload_cmds=false
31603370 fi
31613371 ;;
31623372 darwin*)
3163 if test "$GCC" = yes; then
3164 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
3373 if test yes = "$GCC"; then
3374 reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
31653375 else
31663376 reload_cmds='$LD$reload_flag -o $output$reload_objs'
31673377 fi
31703380 _LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl
31713381 _LT_TAGDECL([], [reload_cmds], [2])dnl
31723382 ])# _LT_CMD_RELOAD
3383
3384
3385 # _LT_PATH_DD
3386 # -----------
3387 # find a working dd
3388 m4_defun([_LT_PATH_DD],
3389 [AC_CACHE_CHECK([for a working dd], [ac_cv_path_lt_DD],
3390 [printf 0123456789abcdef0123456789abcdef >conftest.i
3391 cat conftest.i conftest.i >conftest2.i
3392 : ${lt_DD:=$DD}
3393 AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd],
3394 [if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
3395 cmp -s conftest.i conftest.out \
3396 && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
3397 fi])
3398 rm -f conftest.i conftest2.i conftest.out])
3399 ])# _LT_PATH_DD
3400
3401
3402 # _LT_CMD_TRUNCATE
3403 # ----------------
3404 # find command to truncate a binary pipe
3405 m4_defun([_LT_CMD_TRUNCATE],
3406 [m4_require([_LT_PATH_DD])
3407 AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin],
3408 [printf 0123456789abcdef0123456789abcdef >conftest.i
3409 cat conftest.i conftest.i >conftest2.i
3410 lt_cv_truncate_bin=
3411 if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
3412 cmp -s conftest.i conftest.out \
3413 && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
3414 fi
3415 rm -f conftest.i conftest2.i conftest.out
3416 test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"])
3417 _LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1],
3418 [Command to truncate a binary pipe])
3419 ])# _LT_CMD_TRUNCATE
31733420
31743421
31753422 # _LT_CHECK_MAGIC_METHOD
31873434 # Need to set the preceding variable on all platforms that support
31883435 # interlibrary dependencies.
31893436 # 'none' -- dependencies not supported.
3190 # `unknown' -- same as none, but documents that we really don't know.
3437 # 'unknown' -- same as none, but documents that we really don't know.
31913438 # 'pass_all' -- all dependencies passed with no checks.
31923439 # 'test_compile' -- check by making test program.
31933440 # 'file_magic [[regex]]' -- check by looking for files in library path
3194 # which responds to the $file_magic_cmd with a given extended regex.
3195 # If you have `file' or equivalent on your system and you're not sure
3196 # whether `pass_all' will *always* work, you probably want this one.
3441 # that responds to the $file_magic_cmd with a given extended regex.
3442 # If you have 'file' or equivalent on your system and you're not sure
3443 # whether 'pass_all' will *always* work, you probably want this one.
31973444
31983445 case $host_os in
31993446 aix[[4-9]]*)
32203467 # Base MSYS/MinGW do not provide the 'file' command needed by
32213468 # func_win32_libid shell function, so use a weaker test based on 'objdump',
32223469 # unless we find 'file', for example because we are cross-compiling.
3223 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
3224 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
3470 if ( file / ) >/dev/null 2>&1; then
32253471 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
32263472 lt_cv_file_magic_cmd='func_win32_libid'
32273473 else
32993545 lt_cv_deplibs_check_method=pass_all
33003546 ;;
33013547
3302 netbsd* | netbsdelf*-gnu)
3548 netbsd*)
33033549 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
33043550 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
33053551 else
33173563 lt_cv_deplibs_check_method=pass_all
33183564 ;;
33193565
3320 openbsd*)
3321 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
3566 openbsd* | bitrig*)
3567 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
33223568 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
33233569 else
33243570 lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
33713617 tpf*)
33723618 lt_cv_deplibs_check_method=pass_all
33733619 ;;
3620 os2*)
3621 lt_cv_deplibs_check_method=pass_all
3622 ;;
33743623 esac
33753624 ])
33763625
34113660 AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
34123661 [if test -n "$NM"; then
34133662 # Let the user override the test.
3414 lt_cv_path_NM="$NM"
3663 lt_cv_path_NM=$NM
34153664 else
3416 lt_nm_to_check="${ac_tool_prefix}nm"
3665 lt_nm_to_check=${ac_tool_prefix}nm
34173666 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
34183667 lt_nm_to_check="$lt_nm_to_check nm"
34193668 fi
34203669 for lt_tmp_nm in $lt_nm_to_check; do
3421 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
3670 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
34223671 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
3423 IFS="$lt_save_ifs"
3672 IFS=$lt_save_ifs
34243673 test -z "$ac_dir" && ac_dir=.
3425 tmp_nm="$ac_dir/$lt_tmp_nm"
3426 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
3674 tmp_nm=$ac_dir/$lt_tmp_nm
3675 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
34273676 # Check to see if the nm accepts a BSD-compat flag.
3428 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
3677 # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
34293678 # nm: unknown option "B" ignored
34303679 # Tru64's nm complains that /dev/null is an invalid object file
3431 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
3432 */dev/null* | *'Invalid file or object type'*)
3680 # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
3681 case $build_os in
3682 mingw*) lt_bad_file=conftest.nm/nofile ;;
3683 *) lt_bad_file=/dev/null ;;
3684 esac
3685 case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
3686 *$lt_bad_file* | *'Invalid file or object type'*)
34333687 lt_cv_path_NM="$tmp_nm -B"
3434 break
3688 break 2
34353689 ;;
34363690 *)
34373691 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
34383692 */dev/null*)
34393693 lt_cv_path_NM="$tmp_nm -p"
3440 break
3694 break 2
34413695 ;;
34423696 *)
34433697 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
34483702 esac
34493703 fi
34503704 done
3451 IFS="$lt_save_ifs"
3705 IFS=$lt_save_ifs
34523706 done
34533707 : ${lt_cv_path_NM=no}
34543708 fi])
3455 if test "$lt_cv_path_NM" != "no"; then
3456 NM="$lt_cv_path_NM"
3709 if test no != "$lt_cv_path_NM"; then
3710 NM=$lt_cv_path_NM
34573711 else
34583712 # Didn't find any BSD compatible name lister, look for dumpbin.
34593713 if test -n "$DUMPBIN"; then :
34603714 # Let the user override the test.
34613715 else
34623716 AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
3463 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
3717 case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
34643718 *COFF*)
3465 DUMPBIN="$DUMPBIN -symbols"
3719 DUMPBIN="$DUMPBIN -symbols -headers"
34663720 ;;
34673721 *)
34683722 DUMPBIN=:
34703724 esac
34713725 fi
34723726 AC_SUBST([DUMPBIN])
3473 if test "$DUMPBIN" != ":"; then
3474 NM="$DUMPBIN"
3727 if test : != "$DUMPBIN"; then
3728 NM=$DUMPBIN
34753729 fi
34763730 fi
34773731 test -z "$NM" && NM=nm
35173771
35183772 case $host_os in
35193773 cygwin* | mingw* | pw32* | cegcc*)
3520 # two different shell functions defined in ltmain.sh
3521 # decide which to use based on capabilities of $DLLTOOL
3774 # two different shell functions defined in ltmain.sh;
3775 # decide which one to use based on capabilities of $DLLTOOL
35223776 case `$DLLTOOL --help 2>&1` in
35233777 *--identify-strict*)
35243778 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
35303784 ;;
35313785 *)
35323786 # fallback: assume linklib IS sharedlib
3533 lt_cv_sharedlib_from_linklib_cmd="$ECHO"
3787 lt_cv_sharedlib_from_linklib_cmd=$ECHO
35343788 ;;
35353789 esac
35363790 ])
35573811 lt_cv_path_mainfest_tool=yes
35583812 fi
35593813 rm -f conftest*])
3560 if test "x$lt_cv_path_mainfest_tool" != xyes; then
3814 if test yes != "$lt_cv_path_mainfest_tool"; then
35613815 MANIFEST_TOOL=:
35623816 fi
35633817 _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
35643818 ])# _LT_PATH_MANIFEST_TOOL
3819
3820
3821 # _LT_DLL_DEF_P([FILE])
3822 # ---------------------
3823 # True iff FILE is a Windows DLL '.def' file.
3824 # Keep in sync with func_dll_def_p in the libtool script
3825 AC_DEFUN([_LT_DLL_DEF_P],
3826 [dnl
3827 test DEF = "`$SED -n dnl
3828 -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace
3829 -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments
3830 -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl
3831 -e q dnl Only consider the first "real" line
3832 $1`" dnl
3833 ])# _LT_DLL_DEF_P
35653834
35663835
35673836 # LT_LIB_M
35753844 # These system don't have libm, or don't need it
35763845 ;;
35773846 *-ncr-sysv4.3*)
3578 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
3847 AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw)
35793848 AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
35803849 ;;
35813850 *)
3582 AC_CHECK_LIB(m, cos, LIBM="-lm")
3851 AC_CHECK_LIB(m, cos, LIBM=-lm)
35833852 ;;
35843853 esac
35853854 AC_SUBST([LIBM])
35983867
35993868 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
36003869
3601 if test "$GCC" = yes; then
3870 if test yes = "$GCC"; then
36023871 case $cc_basename in
36033872 nvcc*)
36043873 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
36503919 symcode='[[ABCDGISTW]]'
36513920 ;;
36523921 hpux*)
3653 if test "$host_cpu" = ia64; then
3922 if test ia64 = "$host_cpu"; then
36543923 symcode='[[ABCDEGRST]]'
36553924 fi
36563925 ;;
36833952 symcode='[[ABCDGIRSTW]]' ;;
36843953 esac
36853954
3955 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
3956 # Gets list of data symbols to import.
3957 lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
3958 # Adjust the below global symbol transforms to fixup imported variables.
3959 lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
3960 lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'"
3961 lt_c_name_lib_hook="\
3962 -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\
3963 -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'"
3964 else
3965 # Disable hooks by default.
3966 lt_cv_sys_global_symbol_to_import=
3967 lt_cdecl_hook=
3968 lt_c_name_hook=
3969 lt_c_name_lib_hook=
3970 fi
3971
36863972 # Transform an extracted symbol line into a proper C declaration.
36873973 # Some systems (esp. on ia64) link data and code symbols differently,
36883974 # so use this general approach.
3689 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
3975 lt_cv_sys_global_symbol_to_cdecl="sed -n"\
3976 $lt_cdecl_hook\
3977 " -e 's/^T .* \(.*\)$/extern int \1();/p'"\
3978 " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
36903979
36913980 # Transform an extracted symbol line into symbol name and symbol address
3692 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
3693 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
3981 lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
3982 $lt_c_name_hook\
3983 " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
3984 " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'"
3985
3986 # Transform an extracted symbol line into symbol name with lib prefix and
3987 # symbol address.
3988 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
3989 $lt_c_name_lib_hook\
3990 " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
3991 " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\
3992 " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'"
36943993
36953994 # Handle CRLF in mingw tool chain
36963995 opt_cr=
37084007
37094008 # Write the raw and C identifiers.
37104009 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
3711 # Fake it for dumpbin and say T for any non-static function
3712 # and D for any global variable.
4010 # Fake it for dumpbin and say T for any non-static function,
4011 # D for any global variable and I for any imported variable.
37134012 # Also find C++ and __fastcall symbols from MSVC++,
37144013 # which start with @ or ?.
37154014 lt_cv_sys_global_symbol_pipe="$AWK ['"\
37164015 " {last_section=section; section=\$ 3};"\
37174016 " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
37184017 " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
4018 " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
4019 " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
4020 " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
37194021 " \$ 0!~/External *\|/{next};"\
37204022 " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
37214023 " {if(hide[section]) next};"\
3722 " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
3723 " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
3724 " s[1]~/^[@?]/{print s[1], s[1]; next};"\
3725 " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
4024 " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
4025 " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
4026 " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
4027 " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
37264028 " ' prfx=^$ac_symprfx]"
37274029 else
37284030 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
37624064 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
37634065 cat <<_LT_EOF > conftest.$ac_ext
37644066 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
3765 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
3766 /* DATA imports from DLLs on WIN32 con't be const, because runtime
4067 #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
4068 /* DATA imports from DLLs on WIN32 can't be const, because runtime
37674069 relocations are performed -- see ld's documentation on pseudo-relocs. */
37684070 # define LT@&t@_DLSYM_CONST
3769 #elif defined(__osf__)
4071 #elif defined __osf__
37704072 /* This system does not cope well with relocations in const data. */
37714073 # define LT@&t@_DLSYM_CONST
37724074 #else
37924094 {
37934095 { "@PROGRAM@", (void *) 0 },
37944096 _LT_EOF
3795 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
4097 $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
37964098 cat <<\_LT_EOF >> conftest.$ac_ext
37974099 {0, (void *) 0}
37984100 };
38124114 mv conftest.$ac_objext conftstm.$ac_objext
38134115 lt_globsym_save_LIBS=$LIBS
38144116 lt_globsym_save_CFLAGS=$CFLAGS
3815 LIBS="conftstm.$ac_objext"
4117 LIBS=conftstm.$ac_objext
38164118 CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
3817 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
4119 if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then
38184120 pipe_works=yes
38194121 fi
38204122 LIBS=$lt_globsym_save_LIBS
38354137 rm -rf conftest* conftst*
38364138
38374139 # Do not use the global_symbol_pipe unless it works.
3838 if test "$pipe_works" = yes; then
4140 if test yes = "$pipe_works"; then
38394141 break
38404142 else
38414143 lt_cv_sys_global_symbol_pipe=
38624164 [Take the output of nm and produce a listing of raw symbols and C names])
38634165 _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
38644166 [Transform the output of nm in a proper C declaration])
4167 _LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1],
4168 [Transform the output of nm into a list of symbols to manually relocate])
38654169 _LT_DECL([global_symbol_to_c_name_address],
38664170 [lt_cv_sys_global_symbol_to_c_name_address], [1],
38674171 [Transform the output of nm in a C name address pair])
38684172 _LT_DECL([global_symbol_to_c_name_address_lib_prefix],
38694173 [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
38704174 [Transform the output of nm in a C name address pair when lib prefix is needed])
4175 _LT_DECL([nm_interface], [lt_cv_nm_interface], [1],
4176 [The name lister interface])
38714177 _LT_DECL([], [nm_file_list_spec], [1],
38724178 [Specify filename containing input files for $NM])
38734179 ]) # _LT_CMD_GLOBAL_SYMBOLS
38834189
38844190 m4_if([$1], [CXX], [
38854191 # C++ specific cases for pic, static, wl, etc.
3886 if test "$GXX" = yes; then
4192 if test yes = "$GXX"; then
38874193 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
38884194 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
38894195
38904196 case $host_os in
38914197 aix*)
38924198 # All AIX code is PIC.
3893 if test "$host_cpu" = ia64; then
4199 if test ia64 = "$host_cpu"; then
38944200 # AIX 5 now supports IA64 processor
38954201 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
38964202 fi
4203 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
38974204 ;;
38984205
38994206 amigaos*)
39044211 ;;
39054212 m68k)
39064213 # FIXME: we need at least 68020 code to build shared libraries, but
3907 # adding the `-m68020' flag to GCC prevents building anything better,
3908 # like `-m68040'.
4214 # adding the '-m68020' flag to GCC prevents building anything better,
4215 # like '-m68040'.
39094216 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
39104217 ;;
39114218 esac
39214228 # (--disable-auto-import) libraries
39224229 m4_if([$1], [GCJ], [],
39234230 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4231 case $host_os in
4232 os2*)
4233 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
4234 ;;
4235 esac
39244236 ;;
39254237 darwin* | rhapsody*)
39264238 # PIC is the default on this platform
39704282 case $host_os in
39714283 aix[[4-9]]*)
39724284 # All AIX code is PIC.
3973 if test "$host_cpu" = ia64; then
4285 if test ia64 = "$host_cpu"; then
39744286 # AIX 5 now supports IA64 processor
39754287 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
39764288 else
40114323 case $cc_basename in
40124324 CC*)
40134325 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4014 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4015 if test "$host_cpu" != ia64; then
4326 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
4327 if test ia64 != "$host_cpu"; then
40164328 _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
40174329 fi
40184330 ;;
40194331 aCC*)
40204332 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4021 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4333 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
40224334 case $host_cpu in
40234335 hppa*64*|ia64*)
40244336 # +Z the default
40554367 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
40564368 ;;
40574369 ecpc* )
4058 # old Intel C++ for x86_64 which still supported -KPIC.
4370 # old Intel C++ for x86_64, which still supported -KPIC.
40594371 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
40604372 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
40614373 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
41114423 ;;
41124424 esac
41134425 ;;
4114 netbsd* | netbsdelf*-gnu)
4426 netbsd*)
41154427 ;;
41164428 *qnx* | *nto*)
41174429 # QNX uses GNU C++, but need to define -shared option too, otherwise
42004512 fi
42014513 ],
42024514 [
4203 if test "$GCC" = yes; then
4515 if test yes = "$GCC"; then
42044516 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
42054517 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
42064518
42074519 case $host_os in
42084520 aix*)
42094521 # All AIX code is PIC.
4210 if test "$host_cpu" = ia64; then
4522 if test ia64 = "$host_cpu"; then
42114523 # AIX 5 now supports IA64 processor
42124524 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
42134525 fi
4526 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
42144527 ;;
42154528
42164529 amigaos*)
42214534 ;;
42224535 m68k)
42234536 # FIXME: we need at least 68020 code to build shared libraries, but
4224 # adding the `-m68020' flag to GCC prevents building anything better,
4225 # like `-m68040'.
4537 # adding the '-m68020' flag to GCC prevents building anything better,
4538 # like '-m68040'.
42264539 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
42274540 ;;
42284541 esac
42394552 # (--disable-auto-import) libraries
42404553 m4_if([$1], [GCJ], [],
42414554 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4555 case $host_os in
4556 os2*)
4557 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
4558 ;;
4559 esac
42424560 ;;
42434561
42444562 darwin* | rhapsody*)
43094627 case $host_os in
43104628 aix*)
43114629 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4312 if test "$host_cpu" = ia64; then
4630 if test ia64 = "$host_cpu"; then
43134631 # AIX 5 now supports IA64 processor
43144632 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
43154633 else
43174635 fi
43184636 ;;
43194637
4638 darwin* | rhapsody*)
4639 # PIC is the default on this platform
4640 # Common symbols not allowed in MH_DYLIB files
4641 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
4642 case $cc_basename in
4643 nagfor*)
4644 # NAG Fortran compiler
4645 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
4646 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
4647 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4648 ;;
4649 esac
4650 ;;
4651
43204652 mingw* | cygwin* | pw32* | os2* | cegcc*)
43214653 # This hack is so that the source file can tell whether it is being
43224654 # built for inclusion in a dll (and should export symbols for example).
43234655 m4_if([$1], [GCJ], [],
43244656 [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
4657 case $host_os in
4658 os2*)
4659 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static'
4660 ;;
4661 esac
43254662 ;;
43264663
43274664 hpux9* | hpux10* | hpux11*)
43374674 ;;
43384675 esac
43394676 # Is there a better lt_prog_compiler_static that works with the bundled CC?
4340 _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
4677 _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive'
43414678 ;;
43424679
43434680 irix5* | irix6* | nonstopux*)
43484685
43494686 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
43504687 case $cc_basename in
4351 # old Intel for x86_64 which still supported -KPIC.
4688 # old Intel for x86_64, which still supported -KPIC.
43524689 ecc*)
43534690 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
43544691 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
43724709 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
43734710 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
43744711 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
4712 ;;
4713 tcc*)
4714 # Fabrice Bellard et al's Tiny C Compiler
4715 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
4716 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
4717 _LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
43754718 ;;
43764719 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
43774720 # Portland Group compilers (*not* the Pentium gcc compiler,
44704813 ;;
44714814
44724815 sysv4*MP*)
4473 if test -d /usr/nec ;then
4816 if test -d /usr/nec; then
44744817 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
44754818 _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
44764819 fi
44994842 fi
45004843 ])
45014844 case $host_os in
4502 # For platforms which do not support PIC, -DPIC is meaningless:
4845 # For platforms that do not support PIC, -DPIC is meaningless:
45034846 *djgpp*)
45044847 _LT_TAGVAR(lt_prog_compiler_pic, $1)=
45054848 ;;
45654908 case $host_os in
45664909 aix[[4-9]]*)
45674910 # If we're using GNU nm, then we don't want the "-C" option.
4568 # -C means demangle to AIX nm, but means don't demangle with GNU nm
4569 # Also, AIX nm treats weak defined symbols like other global defined
4570 # symbols, whereas GNU nm marks them as "W".
4911 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
4912 # Without the "-l" option, or with the "-B" option, AIX nm treats
4913 # weak defined symbols like other global defined symbols, whereas
4914 # GNU nm marks them as "W".
4915 # While the 'weak' keyword is ignored in the Export File, we need
4916 # it in the Import File for the 'aix-soname' feature, so we have
4917 # to replace the "-B" option with "-P" for AIX nm.
45714918 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4572 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4919 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
45734920 else
4574 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
4921 _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
45754922 fi
45764923 ;;
45774924 pw32*)
4578 _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
4925 _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds
45794926 ;;
45804927 cygwin* | mingw* | cegcc*)
45814928 case $cc_basename in
45874934 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
45884935 ;;
45894936 esac
4590 ;;
4591 linux* | k*bsd*-gnu | gnu*)
4592 _LT_TAGVAR(link_all_deplibs, $1)=no
45934937 ;;
45944938 *)
45954939 _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
46244968 # included in the symbol list
46254969 _LT_TAGVAR(include_expsyms, $1)=
46264970 # exclude_expsyms can be an extended regexp of symbols to exclude
4627 # it will be wrapped by ` (' and `)$', so one must not match beginning or
4628 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
4629 # as well as any symbol that contains `d'.
4971 # it will be wrapped by ' (' and ')$', so one must not match beginning or
4972 # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
4973 # as well as any symbol that contains 'd'.
46304974 _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
46314975 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
46324976 # platforms (ab)use it in PIC code, but their linkers get confused if
46424986 # FIXME: the MSVC++ port hasn't been tested in a loooong time
46434987 # When not using gcc, we currently assume that we are using
46444988 # Microsoft Visual C++.
4645 if test "$GCC" != yes; then
4989 if test yes != "$GCC"; then
46464990 with_gnu_ld=no
46474991 fi
46484992 ;;
46504994 # we just hope/assume this is gcc and not c89 (= MSVC++)
46514995 with_gnu_ld=yes
46524996 ;;
4653 openbsd*)
4997 openbsd* | bitrig*)
46544998 with_gnu_ld=no
4655 ;;
4656 linux* | k*bsd*-gnu | gnu*)
4657 _LT_TAGVAR(link_all_deplibs, $1)=no
46584999 ;;
46595000 esac
46605001
46635004 # On some targets, GNU ld is compatible enough with the native linker
46645005 # that we're better off using the native interface for both.
46655006 lt_use_gnu_ld_interface=no
4666 if test "$with_gnu_ld" = yes; then
5007 if test yes = "$with_gnu_ld"; then
46675008 case $host_os in
46685009 aix*)
46695010 # The AIX port of GNU ld has always aspired to compatibility
46855026 esac
46865027 fi
46875028
4688 if test "$lt_use_gnu_ld_interface" = yes; then
5029 if test yes = "$lt_use_gnu_ld_interface"; then
46895030 # If archive_cmds runs LD, not CC, wlarc should be empty
4690 wlarc='${wl}'
5031 wlarc='$wl'
46915032
46925033 # Set some defaults for GNU ld with shared library support. These
46935034 # are reset later if shared libraries are not supported. Putting them
46945035 # here allows them to be overridden if necessary.
46955036 runpath_var=LD_RUN_PATH
4696 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4697 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
5037 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5038 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
46985039 # ancient GNU ld didn't support --whole-archive et. al.
46995040 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
4700 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
5041 _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
47015042 else
47025043 _LT_TAGVAR(whole_archive_flag_spec, $1)=
47035044 fi
47045045 supports_anon_versioning=no
4705 case `$LD -v 2>&1` in
5046 case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in
47065047 *GNU\ gold*) supports_anon_versioning=yes ;;
47075048 *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
47085049 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
47155056 case $host_os in
47165057 aix[[3-9]]*)
47175058 # On AIX/PPC, the GNU linker is very broken
4718 if test "$host_cpu" != ia64; then
5059 if test ia64 != "$host_cpu"; then
47195060 _LT_TAGVAR(ld_shlibs, $1)=no
47205061 cat <<_LT_EOF 1>&2
47215062
47345075 case $host_cpu in
47355076 powerpc)
47365077 # see comment about AmigaOS4 .so support
4737 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5078 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
47385079 _LT_TAGVAR(archive_expsym_cmds, $1)=''
47395080 ;;
47405081 m68k)
47505091 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
47515092 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
47525093 # support --undefined. This deserves some investigation. FIXME
4753 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5094 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
47545095 else
47555096 _LT_TAGVAR(ld_shlibs, $1)=no
47565097 fi
47605101 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
47615102 # as there is no search path for DLLs.
47625103 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
4763 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
5104 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols'
47645105 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
47655106 _LT_TAGVAR(always_export_symbols, $1)=no
47665107 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
47685109 _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
47695110
47705111 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
4771 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
4772 # If the export-symbols file already is a .def file (1st line
4773 # is EXPORTS), use it as is; otherwise, prepend...
4774 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
4775 cp $export_symbols $output_objdir/$soname.def;
4776 else
4777 echo EXPORTS > $output_objdir/$soname.def;
4778 cat $export_symbols >> $output_objdir/$soname.def;
4779 fi~
4780 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5112 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
5113 # If the export-symbols file already is a .def file, use it as
5114 # is; otherwise, prepend EXPORTS...
5115 _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
5116 cp $export_symbols $output_objdir/$soname.def;
5117 else
5118 echo EXPORTS > $output_objdir/$soname.def;
5119 cat $export_symbols >> $output_objdir/$soname.def;
5120 fi~
5121 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
47815122 else
47825123 _LT_TAGVAR(ld_shlibs, $1)=no
47835124 fi
47845125 ;;
47855126
47865127 haiku*)
4787 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5128 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
47885129 _LT_TAGVAR(link_all_deplibs, $1)=yes
5130 ;;
5131
5132 os2*)
5133 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
5134 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5135 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5136 shrext_cmds=.dll
5137 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
5138 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
5139 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
5140 $ECHO EXPORTS >> $output_objdir/$libname.def~
5141 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
5142 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
5143 emximp -o $lib $output_objdir/$libname.def'
5144 _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
5145 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
5146 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
5147 $ECHO EXPORTS >> $output_objdir/$libname.def~
5148 prefix_cmds="$SED"~
5149 if test EXPORTS = "`$SED 1q $export_symbols`"; then
5150 prefix_cmds="$prefix_cmds -e 1d";
5151 fi~
5152 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
5153 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
5154 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
5155 emximp -o $lib $output_objdir/$libname.def'
5156 _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
5157 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
47895158 ;;
47905159
47915160 interix[[3-9]]*)
47925161 _LT_TAGVAR(hardcode_direct, $1)=no
47935162 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
4794 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
4795 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5163 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
5164 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
47965165 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
47975166 # Instead, shared libraries are loaded at an image base (0x10000000 by
47985167 # default) and relocated if they conflict, which is a slow very memory
47995168 # consuming and fragmenting process. To avoid this, we pick a random,
48005169 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
48015170 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
4802 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
4803 _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
5171 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
5172 _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
48045173 ;;
48055174
48065175 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
48075176 tmp_diet=no
4808 if test "$host_os" = linux-dietlibc; then
5177 if test linux-dietlibc = "$host_os"; then
48095178 case $cc_basename in
48105179 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
48115180 esac
48125181 fi
48135182 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
4814 && test "$tmp_diet" = no
5183 && test no = "$tmp_diet"
48155184 then
48165185 tmp_addflag=' $pic_flag'
48175186 tmp_sharedflag='-shared'
48185187 case $cc_basename,$host_cpu in
48195188 pgcc*) # Portland Group C compiler
4820 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
5189 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
48215190 tmp_addflag=' $pic_flag'
48225191 ;;
48235192 pgf77* | pgf90* | pgf95* | pgfortran*)
48245193 # Portland Group f77 and f90 compilers
4825 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
5194 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
48265195 tmp_addflag=' $pic_flag -Mnomain' ;;
48275196 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
48285197 tmp_addflag=' -i_dynamic' ;;
48335202 lf95*) # Lahey Fortran 8.1
48345203 _LT_TAGVAR(whole_archive_flag_spec, $1)=
48355204 tmp_sharedflag='--shared' ;;
5205 nagfor*) # NAGFOR 5.3
5206 tmp_sharedflag='-Wl,-shared' ;;
48365207 xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
48375208 tmp_sharedflag='-qmkshrobj'
48385209 tmp_addflag= ;;
48395210 nvcc*) # Cuda Compiler Driver 2.2
4840 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
5211 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
48415212 _LT_TAGVAR(compiler_needs_object, $1)=yes
48425213 ;;
48435214 esac
48445215 case `$CC -V 2>&1 | sed 5q` in
48455216 *Sun\ C*) # Sun C 5.9
4846 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
5217 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
48475218 _LT_TAGVAR(compiler_needs_object, $1)=yes
48485219 tmp_sharedflag='-G' ;;
48495220 *Sun\ F*) # Sun Fortran 8.3
48505221 tmp_sharedflag='-G' ;;
48515222 esac
4852 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4853
4854 if test "x$supports_anon_versioning" = xyes; then
5223 _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5224
5225 if test yes = "$supports_anon_versioning"; then
48555226 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
4856 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
4857 echo "local: *; };" >> $output_objdir/$libname.ver~
4858 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
5227 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5228 echo "local: *; };" >> $output_objdir/$libname.ver~
5229 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
48595230 fi
48605231
48615232 case $cc_basename in
5233 tcc*)
5234 _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic'
5235 ;;
48625236 xlf* | bgf* | bgxlf* | mpixlf*)
48635237 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
48645238 _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
4865 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5239 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
48665240 _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
4867 if test "x$supports_anon_versioning" = xyes; then
5241 if test yes = "$supports_anon_versioning"; then
48685242 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
4869 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
4870 echo "local: *; };" >> $output_objdir/$libname.ver~
4871 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
5243 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
5244 echo "local: *; };" >> $output_objdir/$libname.ver~
5245 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
48725246 fi
48735247 ;;
48745248 esac
48775251 fi
48785252 ;;
48795253
4880 netbsd* | netbsdelf*-gnu)
5254 netbsd*)
48815255 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
48825256 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
48835257 wlarc=
48845258 else
4885 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4886 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5259 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5260 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
48875261 fi
48885262 ;;
48895263
49015275
49025276 _LT_EOF
49035277 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4904 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4905 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5278 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5279 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
49065280 else
49075281 _LT_TAGVAR(ld_shlibs, $1)=no
49085282 fi
49145288 _LT_TAGVAR(ld_shlibs, $1)=no
49155289 cat <<_LT_EOF 1>&2
49165290
4917 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
5291 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
49185292 *** reliably create shared libraries on SCO systems. Therefore, libtool
49195293 *** is disabling shared libraries support. We urge you to upgrade GNU
49205294 *** binutils to release 2.16.91.0.3 or newer. Another option is to modify
49295303 # DT_RUNPATH tag from executables and libraries. But doing so
49305304 # requires that you compile everything twice, which is a pain.
49315305 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4932 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
4933 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4934 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5306 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
5307 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5308 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
49355309 else
49365310 _LT_TAGVAR(ld_shlibs, $1)=no
49375311 fi
49485322
49495323 *)
49505324 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
4951 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
4952 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5325 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
5326 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
49535327 else
49545328 _LT_TAGVAR(ld_shlibs, $1)=no
49555329 fi
49565330 ;;
49575331 esac
49585332
4959 if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
5333 if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then
49605334 runpath_var=
49615335 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
49625336 _LT_TAGVAR(export_dynamic_flag_spec, $1)=
49725346 # Note: this linker hardcodes the directories in LIBPATH if there
49735347 # are no directories specified by -L.
49745348 _LT_TAGVAR(hardcode_minus_L, $1)=yes
4975 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
5349 if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
49765350 # Neither direct hardcoding nor static linking is supported with a
49775351 # broken collect2.
49785352 _LT_TAGVAR(hardcode_direct, $1)=unsupported
49805354 ;;
49815355
49825356 aix[[4-9]]*)
4983 if test "$host_cpu" = ia64; then
5357 if test ia64 = "$host_cpu"; then
49845358 # On IA64, the linker does run time linking by default, so we don't
49855359 # have to do anything special.
49865360 aix_use_runtimelinking=no
49875361 exp_sym_flag='-Bexport'
4988 no_entry_flag=""
5362 no_entry_flag=
49895363 else
49905364 # If we're using GNU nm, then we don't want the "-C" option.
4991 # -C means demangle to AIX nm, but means don't demangle with GNU nm
4992 # Also, AIX nm treats weak defined symbols like other global
4993 # defined symbols, whereas GNU nm marks them as "W".
5365 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
5366 # Without the "-l" option, or with the "-B" option, AIX nm treats
5367 # weak defined symbols like other global defined symbols, whereas
5368 # GNU nm marks them as "W".
5369 # While the 'weak' keyword is ignored in the Export File, we need
5370 # it in the Import File for the 'aix-soname' feature, so we have
5371 # to replace the "-B" option with "-P" for AIX nm.
49945372 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
4995 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5373 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
49965374 else
4997 _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
5375 _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
49985376 fi
49995377 aix_use_runtimelinking=no
50005378
50015379 # Test if we are trying to use run time linking or normal
50025380 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
5003 # need to do runtime linking.
5381 # have runtime linking enabled, and use it for executables.
5382 # For shared libraries, we enable/disable runtime linking
5383 # depending on the kind of the shared library created -
5384 # when "with_aix_soname,aix_use_runtimelinking" is:
5385 # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
5386 # "aix,yes" lib.so shared, rtl:yes, for executables
5387 # lib.a static archive
5388 # "both,no" lib.so.V(shr.o) shared, rtl:yes
5389 # lib.a(lib.so.V) shared, rtl:no, for executables
5390 # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
5391 # lib.a(lib.so.V) shared, rtl:no
5392 # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
5393 # lib.a static archive
50045394 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
50055395 for ld_flag in $LDFLAGS; do
5006 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
5396 if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
50075397 aix_use_runtimelinking=yes
50085398 break
50095399 fi
50105400 done
5401 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
5402 # With aix-soname=svr4, we create the lib.so.V shared archives only,
5403 # so we don't have lib.a shared libs to link our executables.
5404 # We have to force runtime linking in this case.
5405 aix_use_runtimelinking=yes
5406 LDFLAGS="$LDFLAGS -Wl,-brtl"
5407 fi
50115408 ;;
50125409 esac
50135410
50265423 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
50275424 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
50285425 _LT_TAGVAR(link_all_deplibs, $1)=yes
5029 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
5030
5031 if test "$GCC" = yes; then
5426 _LT_TAGVAR(file_list_spec, $1)='$wl-f,'
5427 case $with_aix_soname,$aix_use_runtimelinking in
5428 aix,*) ;; # traditional, no import file
5429 svr4,* | *,yes) # use import file
5430 # The Import File defines what to hardcode.
5431 _LT_TAGVAR(hardcode_direct, $1)=no
5432 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
5433 ;;
5434 esac
5435
5436 if test yes = "$GCC"; then
50325437 case $host_os in aix4.[[012]]|aix4.[[012]].*)
50335438 # We only want to do this on AIX 4.2 and lower, the check
50345439 # below for broken collect2 doesn't work under 4.3+
5035 collect2name=`${CC} -print-prog-name=collect2`
5440 collect2name=`$CC -print-prog-name=collect2`
50365441 if test -f "$collect2name" &&
50375442 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
50385443 then
50515456 ;;
50525457 esac
50535458 shared_flag='-shared'
5054 if test "$aix_use_runtimelinking" = yes; then
5055 shared_flag="$shared_flag "'${wl}-G'
5459 if test yes = "$aix_use_runtimelinking"; then
5460 shared_flag="$shared_flag "'$wl-G'
50565461 fi
5057 _LT_TAGVAR(link_all_deplibs, $1)=no
5462 # Need to ensure runtime linking is disabled for the traditional
5463 # shared library, or the linker may eventually find shared libraries
5464 # /with/ Import File - we do not want to mix them.
5465 shared_flag_aix='-shared'
5466 shared_flag_svr4='-shared $wl-G'
50585467 else
50595468 # not using gcc
5060 if test "$host_cpu" = ia64; then
5469 if test ia64 = "$host_cpu"; then
50615470 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
50625471 # chokes on -Wl,-G. The following line is correct:
50635472 shared_flag='-G'
50645473 else
5065 if test "$aix_use_runtimelinking" = yes; then
5066 shared_flag='${wl}-G'
5474 if test yes = "$aix_use_runtimelinking"; then
5475 shared_flag='$wl-G'
50675476 else
5068 shared_flag='${wl}-bM:SRE'
5477 shared_flag='$wl-bM:SRE'
50695478 fi
5479 shared_flag_aix='$wl-bM:SRE'
5480 shared_flag_svr4='$wl-G'
50705481 fi
50715482 fi
50725483
5073 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
5484 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall'
50745485 # It seems that -bexpall does not export symbols beginning with
50755486 # underscore (_), so it is better to generate a list of symbols to export.
50765487 _LT_TAGVAR(always_export_symbols, $1)=yes
5077 if test "$aix_use_runtimelinking" = yes; then
5488 if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
50785489 # Warning - without using the other runtime loading flags (-brtl),
50795490 # -berok will link without error, but may produce a broken library.
50805491 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
50815492 # Determine the default libpath from the value encoded in an
50825493 # empty executable.
50835494 _LT_SYS_MODULE_PATH_AIX([$1])
5084 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5085 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
5495 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
5496 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
50865497 else
5087 if test "$host_cpu" = ia64; then
5088 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
5498 if test ia64 = "$host_cpu"; then
5499 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib'
50895500 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
5090 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
5501 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols"
50915502 else
50925503 # Determine the default libpath from the value encoded in an
50935504 # empty executable.
50945505 _LT_SYS_MODULE_PATH_AIX([$1])
5095 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
5506 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
50965507 # Warning - without using the other run time loading flags,
50975508 # -berok will link without error, but may produce a broken library.
5098 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
5099 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
5100 if test "$with_gnu_ld" = yes; then
5509 _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok'
5510 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok'
5511 if test yes = "$with_gnu_ld"; then
51015512 # We only use this code for GNU lds that support --whole-archive.
5102 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
5513 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
51035514 else
51045515 # Exported symbols can be pulled into shared objects from archives
51055516 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
51065517 fi
51075518 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
5108 # This is similar to how AIX traditionally builds its shared libraries.
5109 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
5519 _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
5520 # -brtl affects multiple linker settings, -berok does not and is overridden later
5521 compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`'
5522 if test svr4 != "$with_aix_soname"; then
5523 # This is similar to how AIX traditionally builds its shared libraries.
5524 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
5525 fi
5526 if test aix != "$with_aix_soname"; then
5527 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
5528 else
5529 # used by -dlpreopen to get the symbols
5530 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
5531 fi
5532 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d'
51105533 fi
51115534 fi
51125535 ;;
51155538 case $host_cpu in
51165539 powerpc)
51175540 # see comment about AmigaOS4 .so support
5118 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
5541 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
51195542 _LT_TAGVAR(archive_expsym_cmds, $1)=''
51205543 ;;
51215544 m68k)
51455568 # Tell ltmain to make .lib files, not .a files.
51465569 libext=lib
51475570 # Tell ltmain to make .dll files, not .so files.
5148 shrext_cmds=".dll"
5571 shrext_cmds=.dll
51495572 # FIXME: Setting linknames here is a bad hack.
5150 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
5151 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
5152 sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
5153 else
5154 sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
5155 fi~
5156 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
5157 linknames='
5573 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
5574 _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
5575 cp "$export_symbols" "$output_objdir/$soname.def";
5576 echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
5577 else
5578 $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
5579 fi~
5580 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
5581 linknames='
51585582 # The linker will not automatically build a static lib if we build a DLL.
51595583 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
51605584 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
51635587 # Don't use ranlib
51645588 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
51655589 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
5166 lt_tool_outputfile="@TOOL_OUTPUT@"~
5167 case $lt_outputfile in
5168 *.exe|*.EXE) ;;
5169 *)
5170 lt_outputfile="$lt_outputfile.exe"
5171 lt_tool_outputfile="$lt_tool_outputfile.exe"
5172 ;;
5173 esac~
5174 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
5175 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
5176 $RM "$lt_outputfile.manifest";
5177 fi'
5590 lt_tool_outputfile="@TOOL_OUTPUT@"~
5591 case $lt_outputfile in
5592 *.exe|*.EXE) ;;
5593 *)
5594 lt_outputfile=$lt_outputfile.exe
5595 lt_tool_outputfile=$lt_tool_outputfile.exe
5596 ;;
5597 esac~
5598 if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
5599 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
5600 $RM "$lt_outputfile.manifest";
5601 fi'
51785602 ;;
51795603 *)
51805604 # Assume MSVC wrapper
51835607 # Tell ltmain to make .lib files, not .a files.
51845608 libext=lib
51855609 # Tell ltmain to make .dll files, not .so files.
5186 shrext_cmds=".dll"
5610 shrext_cmds=.dll
51875611 # FIXME: Setting linknames here is a bad hack.
51885612 _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
51895613 # The linker will automatically build a .lib file if we build a DLL.
52335657 ;;
52345658
52355659 hpux9*)
5236 if test "$GCC" = yes; then
5237 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
5660 if test yes = "$GCC"; then
5661 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
52385662 else
5239 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
5663 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
52405664 fi
5241 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5665 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
52425666 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
52435667 _LT_TAGVAR(hardcode_direct, $1)=yes
52445668
52455669 # hardcode_minus_L: Not really in the search PATH,
52465670 # but as the default location of the library.
52475671 _LT_TAGVAR(hardcode_minus_L, $1)=yes
5248 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5672 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
52495673 ;;
52505674
52515675 hpux10*)
5252 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
5253 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5676 if test yes,no = "$GCC,$with_gnu_ld"; then
5677 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
52545678 else
52555679 _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
52565680 fi
5257 if test "$with_gnu_ld" = no; then
5258 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5681 if test no = "$with_gnu_ld"; then
5682 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
52595683 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
52605684 _LT_TAGVAR(hardcode_direct, $1)=yes
52615685 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5262 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5686 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
52635687 # hardcode_minus_L: Not really in the search PATH,
52645688 # but as the default location of the library.
52655689 _LT_TAGVAR(hardcode_minus_L, $1)=yes
52675691 ;;
52685692
52695693 hpux11*)
5270 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
5694 if test yes,no = "$GCC,$with_gnu_ld"; then
52715695 case $host_cpu in
52725696 hppa*64*)
5273 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5697 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
52745698 ;;
52755699 ia64*)
5276 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5700 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
52775701 ;;
52785702 *)
5279 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
5703 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
52805704 ;;
52815705 esac
52825706 else
52835707 case $host_cpu in
52845708 hppa*64*)
5285 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5709 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
52865710 ;;
52875711 ia64*)
5288 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
5712 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
52895713 ;;
52905714 *)
52915715 m4_if($1, [], [
52935717 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
52945718 _LT_LINKER_OPTION([if $CC understands -b],
52955719 _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
5296 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
5720 [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
52975721 [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
5298 [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
5722 [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
52995723 ;;
53005724 esac
53015725 fi
5302 if test "$with_gnu_ld" = no; then
5303 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
5726 if test no = "$with_gnu_ld"; then
5727 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
53045728 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
53055729
53065730 case $host_cpu in
53115735 *)
53125736 _LT_TAGVAR(hardcode_direct, $1)=yes
53135737 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5314 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5738 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
53155739
53165740 # hardcode_minus_L: Not really in the search PATH,
53175741 # but as the default location of the library.
53225746 ;;
53235747
53245748 irix5* | irix6* | nonstopux*)
5325 if test "$GCC" = yes; then
5326 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5749 if test yes = "$GCC"; then
5750 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
53275751 # Try to use the -exported_symbol ld option, if it does not
53285752 # work, assume that -exports_file does not work either and
53295753 # implicitly export all symbols.
53305754 # This should be the same for all languages, so no per-tag cache variable.
53315755 AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
53325756 [lt_cv_irix_exported_symbol],
5333 [save_LDFLAGS="$LDFLAGS"
5334 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
5757 [save_LDFLAGS=$LDFLAGS
5758 LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
53355759 AC_LINK_IFELSE(
53365760 [AC_LANG_SOURCE(
53375761 [AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
53445768 end]])])],
53455769 [lt_cv_irix_exported_symbol=yes],
53465770 [lt_cv_irix_exported_symbol=no])
5347 LDFLAGS="$save_LDFLAGS"])
5348 if test "$lt_cv_irix_exported_symbol" = yes; then
5349 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
5771 LDFLAGS=$save_LDFLAGS])
5772 if test yes = "$lt_cv_irix_exported_symbol"; then
5773 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
53505774 fi
53515775 else
5352 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5353 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
5776 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
5777 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib'
53545778 fi
53555779 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5356 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5780 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
53575781 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
53585782 _LT_TAGVAR(inherit_rpath, $1)=yes
53595783 _LT_TAGVAR(link_all_deplibs, $1)=yes
53605784 ;;
53615785
5362 netbsd* | netbsdelf*-gnu)
5786 linux*)
5787 case $cc_basename in
5788 tcc*)
5789 # Fabrice Bellard et al's Tiny C Compiler
5790 _LT_TAGVAR(ld_shlibs, $1)=yes
5791 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5792 ;;
5793 esac
5794 ;;
5795
5796 netbsd*)
53635797 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
53645798 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
53655799 else
53735807 newsos6)
53745808 _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
53755809 _LT_TAGVAR(hardcode_direct, $1)=yes
5376 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5810 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
53775811 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
53785812 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
53795813 ;;
53815815 *nto* | *qnx*)
53825816 ;;
53835817
5384 openbsd*)
5818 openbsd* | bitrig*)
53855819 if test -f /usr/libexec/ld.so; then
53865820 _LT_TAGVAR(hardcode_direct, $1)=yes
53875821 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
53885822 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
5389 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5823 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
53905824 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5391 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
5392 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5393 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
5825 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
5826 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
5827 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
53945828 else
5395 case $host_os in
5396 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
5397 _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
5398 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
5399 ;;
5400 *)
5401 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5402 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
5403 ;;
5404 esac
5829 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
5830 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
54055831 fi
54065832 else
54075833 _LT_TAGVAR(ld_shlibs, $1)=no
54125838 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
54135839 _LT_TAGVAR(hardcode_minus_L, $1)=yes
54145840 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
5415 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
5416 _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
5841 shrext_cmds=.dll
5842 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
5843 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
5844 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
5845 $ECHO EXPORTS >> $output_objdir/$libname.def~
5846 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
5847 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
5848 emximp -o $lib $output_objdir/$libname.def'
5849 _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
5850 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
5851 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
5852 $ECHO EXPORTS >> $output_objdir/$libname.def~
5853 prefix_cmds="$SED"~
5854 if test EXPORTS = "`$SED 1q $export_symbols`"; then
5855 prefix_cmds="$prefix_cmds -e 1d";
5856 fi~
5857 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
5858 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
5859 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
5860 emximp -o $lib $output_objdir/$libname.def'
5861 _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
5862 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
54175863 ;;
54185864
54195865 osf3*)
5420 if test "$GCC" = yes; then
5421 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5422 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5866 if test yes = "$GCC"; then
5867 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
5868 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
54235869 else
54245870 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5425 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5871 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
54265872 fi
54275873 _LT_TAGVAR(archive_cmds_need_lc, $1)='no'
5428 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5874 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
54295875 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
54305876 ;;
54315877
54325878 osf4* | osf5*) # as osf3* with the addition of -msym flag
5433 if test "$GCC" = yes; then
5434 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
5435 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
5436 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5879 if test yes = "$GCC"; then
5880 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
5881 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
5882 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
54375883 else
54385884 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
5439 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
5885 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
54405886 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
5441 $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
5887 $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp'
54425888
54435889 # Both c and cxx compiler support -rpath directly
54445890 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
54495895
54505896 solaris*)
54515897 _LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
5452 if test "$GCC" = yes; then
5453 wlarc='${wl}'
5454 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
5898 if test yes = "$GCC"; then
5899 wlarc='$wl'
5900 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
54555901 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5456 $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5902 $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
54575903 else
54585904 case `$CC -V 2>&1` in
54595905 *"Compilers 5.0"*)
54605906 wlarc=''
5461 _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
5907 _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
54625908 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5463 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
5909 $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
54645910 ;;
54655911 *)
5466 wlarc='${wl}'
5467 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
5912 wlarc='$wl'
5913 _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
54685914 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
5469 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
5915 $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
54705916 ;;
54715917 esac
54725918 fi
54765922 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
54775923 *)
54785924 # The compiler driver will combine and reorder linker options,
5479 # but understands `-z linker_flag'. GCC discards it without `$wl',
5925 # but understands '-z linker_flag'. GCC discards it without '$wl',
54805926 # but is careful enough not to reorder.
54815927 # Supported since Solaris 2.6 (maybe 2.5.1?)
5482 if test "$GCC" = yes; then
5483 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
5928 if test yes = "$GCC"; then
5929 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
54845930 else
54855931 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
54865932 fi
54905936 ;;
54915937
54925938 sunos4*)
5493 if test "x$host_vendor" = xsequent; then
5939 if test sequent = "$host_vendor"; then
54945940 # Use $CC to link under sequent, because it throws in some extra .o
54955941 # files that make .init and .fini sections work.
5496 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
5942 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
54975943 else
54985944 _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
54995945 fi
55425988 ;;
55435989
55445990 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
5545 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
5991 _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
55465992 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
55475993 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
55485994 runpath_var='LD_RUN_PATH'
55495995
5550 if test "$GCC" = yes; then
5551 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5552 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5996 if test yes = "$GCC"; then
5997 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5998 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
55535999 else
5554 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5555 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6000 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6001 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
55566002 fi
55576003 ;;
55586004
55596005 sysv5* | sco3.2v5* | sco5v6*)
5560 # Note: We can NOT use -z defs as we might desire, because we do not
6006 # Note: We CANNOT use -z defs as we might desire, because we do not
55616007 # link with -lc, and that would cause any symbols used from libc to
55626008 # always be unresolved, which means just about no library would
55636009 # ever link correctly. If we're not using GNU ld we use -z text
55646010 # though, which does catch some bad symbols but isn't as heavy-handed
55656011 # as -z defs.
5566 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
5567 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
6012 _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
6013 _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs'
55686014 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
55696015 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
5570 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
6016 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir'
55716017 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
55726018 _LT_TAGVAR(link_all_deplibs, $1)=yes
5573 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
6019 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport'
55746020 runpath_var='LD_RUN_PATH'
55756021
5576 if test "$GCC" = yes; then
5577 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5578 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6022 if test yes = "$GCC"; then
6023 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6024 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
55796025 else
5580 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
5581 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6026 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6027 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
55826028 fi
55836029 ;;
55846030
55936039 ;;
55946040 esac
55956041
5596 if test x$host_vendor = xsni; then
6042 if test sni = "$host_vendor"; then
55976043 case $host in
55986044 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
5599 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
6045 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym'
56006046 ;;
56016047 esac
56026048 fi
56036049 fi
56046050 ])
56056051 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
5606 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6052 test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no
56076053
56086054 _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
56096055
56206066 # Assume -lc should be added
56216067 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
56226068
5623 if test "$enable_shared" = yes && test "$GCC" = yes; then
6069 if test yes,yes = "$GCC,$enable_shared"; then
56246070 case $_LT_TAGVAR(archive_cmds, $1) in
56256071 *'~'*)
56266072 # FIXME: we may have to deal with multi-command sequences.
57006146 _LT_TAGDECL([], [hardcode_libdir_separator], [1],
57016147 [Whether we need a single "-rpath" flag with a separated argument])
57026148 _LT_TAGDECL([], [hardcode_direct], [0],
5703 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
6149 [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes
57046150 DIR into the resulting binary])
57056151 _LT_TAGDECL([], [hardcode_direct_absolute], [0],
5706 [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
6152 [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes
57076153 DIR into the resulting binary and the resulting library dependency is
5708 "absolute", i.e impossible to change by setting ${shlibpath_var} if the
6154 "absolute", i.e impossible to change by setting $shlibpath_var if the
57096155 library is relocated])
57106156 _LT_TAGDECL([], [hardcode_minus_L], [0],
57116157 [Set to "yes" if using the -LDIR flag during linking hardcodes DIR
57466192 # ------------------------
57476193 # Ensure that the configuration variables for a C compiler are suitably
57486194 # defined. These variables are subsequently used by _LT_CONFIG to write
5749 # the compiler configuration to `libtool'.
6195 # the compiler configuration to 'libtool'.
57506196 m4_defun([_LT_LANG_C_CONFIG],
57516197 [m4_require([_LT_DECL_EGREP])dnl
5752 lt_save_CC="$CC"
6198 lt_save_CC=$CC
57536199 AC_LANG_PUSH(C)
57546200
57556201 # Source file extension for C test sources.
57896235 LT_SYS_DLOPEN_SELF
57906236 _LT_CMD_STRIPLIB
57916237
5792 # Report which library types will actually be built
6238 # Report what library types will actually be built
57936239 AC_MSG_CHECKING([if libtool supports shared libraries])
57946240 AC_MSG_RESULT([$can_build_shared])
57956241
57966242 AC_MSG_CHECKING([whether to build shared libraries])
5797 test "$can_build_shared" = "no" && enable_shared=no
6243 test no = "$can_build_shared" && enable_shared=no
57986244
57996245 # On AIX, shared libraries and static libraries use the same namespace, and
58006246 # are all built from PIC.
58016247 case $host_os in
58026248 aix3*)
5803 test "$enable_shared" = yes && enable_static=no
6249 test yes = "$enable_shared" && enable_static=no
58046250 if test -n "$RANLIB"; then
58056251 archive_cmds="$archive_cmds~\$RANLIB \$lib"
58066252 postinstall_cmds='$RANLIB $lib'
58086254 ;;
58096255
58106256 aix[[4-9]]*)
5811 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
5812 test "$enable_shared" = yes && enable_static=no
6257 if test ia64 != "$host_cpu"; then
6258 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
6259 yes,aix,yes) ;; # shared object as lib.so file only
6260 yes,svr4,*) ;; # shared object as lib.so archive member only
6261 yes,*) enable_static=no ;; # shared object in lib.a archive as well
6262 esac
58136263 fi
58146264 ;;
58156265 esac
58176267
58186268 AC_MSG_CHECKING([whether to build static libraries])
58196269 # Make sure either enable_shared or enable_static is yes.
5820 test "$enable_shared" = yes || enable_static=yes
6270 test yes = "$enable_shared" || enable_static=yes
58216271 AC_MSG_RESULT([$enable_static])
58226272
58236273 _LT_CONFIG($1)
58246274 fi
58256275 AC_LANG_POP
5826 CC="$lt_save_CC"
6276 CC=$lt_save_CC
58276277 ])# _LT_LANG_C_CONFIG
58286278
58296279
58316281 # --------------------------
58326282 # Ensure that the configuration variables for a C++ compiler are suitably
58336283 # defined. These variables are subsequently used by _LT_CONFIG to write
5834 # the compiler configuration to `libtool'.
6284 # the compiler configuration to 'libtool'.
58356285 m4_defun([_LT_LANG_CXX_CONFIG],
58366286 [m4_require([_LT_FILEUTILS_DEFAULTS])dnl
58376287 m4_require([_LT_DECL_EGREP])dnl
58386288 m4_require([_LT_PATH_MANIFEST_TOOL])dnl
5839 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
5840 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
5841 (test "X$CXX" != "Xg++"))) ; then
6289 if test -n "$CXX" && ( test no != "$CXX" &&
6290 ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) ||
6291 (test g++ != "$CXX"))); then
58426292 AC_PROG_CXXCPP
58436293 else
58446294 _lt_caught_CXX_error=yes
58806330 # the CXX compiler isn't working. Some variables (like enable_shared)
58816331 # are currently assumed to apply to all compilers on this platform,
58826332 # and will be corrupted by setting them based on a non-working compiler.
5883 if test "$_lt_caught_CXX_error" != yes; then
6333 if test yes != "$_lt_caught_CXX_error"; then
58846334 # Code to be used in simple compile tests
58856335 lt_simple_compile_test_code="int some_variable = 0;"
58866336
59226372 if test -n "$compiler"; then
59236373 # We don't want -fno-exception when compiling C++ code, so set the
59246374 # no_builtin_flag separately
5925 if test "$GXX" = yes; then
6375 if test yes = "$GXX"; then
59266376 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
59276377 else
59286378 _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
59296379 fi
59306380
5931 if test "$GXX" = yes; then
6381 if test yes = "$GXX"; then
59326382 # Set up default GNU C++ configuration
59336383
59346384 LT_PATH_LD
59356385
59366386 # Check if GNU C++ uses GNU ld as the underlying linker, since the
59376387 # archiving commands below assume that GNU ld is being used.
5938 if test "$with_gnu_ld" = yes; then
5939 _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
5940 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
5941
5942 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
5943 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6388 if test yes = "$with_gnu_ld"; then
6389 _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
6390 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
6391
6392 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
6393 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
59446394
59456395 # If archive_cmds runs LD, not CC, wlarc should be empty
59466396 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
59476397 # investigate it a little bit more. (MM)
5948 wlarc='${wl}'
6398 wlarc='$wl'
59496399
59506400 # ancient GNU ld didn't support --whole-archive et. al.
59516401 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
59526402 $GREP 'no-whole-archive' > /dev/null; then
5953 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
6403 _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
59546404 else
59556405 _LT_TAGVAR(whole_archive_flag_spec, $1)=
59566406 fi
59866436 _LT_TAGVAR(ld_shlibs, $1)=no
59876437 ;;
59886438 aix[[4-9]]*)
5989 if test "$host_cpu" = ia64; then
6439 if test ia64 = "$host_cpu"; then
59906440 # On IA64, the linker does run time linking by default, so we don't
59916441 # have to do anything special.
59926442 aix_use_runtimelinking=no
59936443 exp_sym_flag='-Bexport'
5994 no_entry_flag=""
6444 no_entry_flag=
59956445 else
59966446 aix_use_runtimelinking=no
59976447
59986448 # Test if we are trying to use run time linking or normal
59996449 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
6000 # need to do runtime linking.
6450 # have runtime linking enabled, and use it for executables.
6451 # For shared libraries, we enable/disable runtime linking
6452 # depending on the kind of the shared library created -
6453 # when "with_aix_soname,aix_use_runtimelinking" is:
6454 # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
6455 # "aix,yes" lib.so shared, rtl:yes, for executables
6456 # lib.a static archive
6457 # "both,no" lib.so.V(shr.o) shared, rtl:yes
6458 # lib.a(lib.so.V) shared, rtl:no, for executables
6459 # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
6460 # lib.a(lib.so.V) shared, rtl:no
6461 # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
6462 # lib.a static archive
60016463 case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
60026464 for ld_flag in $LDFLAGS; do
60036465 case $ld_flag in
60076469 ;;
60086470 esac
60096471 done
6472 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
6473 # With aix-soname=svr4, we create the lib.so.V shared archives only,
6474 # so we don't have lib.a shared libs to link our executables.
6475 # We have to force runtime linking in this case.
6476 aix_use_runtimelinking=yes
6477 LDFLAGS="$LDFLAGS -Wl,-brtl"
6478 fi
60106479 ;;
60116480 esac
60126481
60256494 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
60266495 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
60276496 _LT_TAGVAR(link_all_deplibs, $1)=yes
6028 _LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
6029
6030 if test "$GXX" = yes; then
6497 _LT_TAGVAR(file_list_spec, $1)='$wl-f,'
6498 case $with_aix_soname,$aix_use_runtimelinking in
6499 aix,*) ;; # no import file
6500 svr4,* | *,yes) # use import file
6501 # The Import File defines what to hardcode.
6502 _LT_TAGVAR(hardcode_direct, $1)=no
6503 _LT_TAGVAR(hardcode_direct_absolute, $1)=no
6504 ;;
6505 esac
6506
6507 if test yes = "$GXX"; then
60316508 case $host_os in aix4.[[012]]|aix4.[[012]].*)
60326509 # We only want to do this on AIX 4.2 and lower, the check
60336510 # below for broken collect2 doesn't work under 4.3+
6034 collect2name=`${CC} -print-prog-name=collect2`
6511 collect2name=`$CC -print-prog-name=collect2`
60356512 if test -f "$collect2name" &&
60366513 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
60376514 then
60496526 fi
60506527 esac
60516528 shared_flag='-shared'
6052 if test "$aix_use_runtimelinking" = yes; then
6053 shared_flag="$shared_flag "'${wl}-G'
6529 if test yes = "$aix_use_runtimelinking"; then
6530 shared_flag=$shared_flag' $wl-G'
60546531 fi
6532 # Need to ensure runtime linking is disabled for the traditional
6533 # shared library, or the linker may eventually find shared libraries
6534 # /with/ Import File - we do not want to mix them.
6535 shared_flag_aix='-shared'
6536 shared_flag_svr4='-shared $wl-G'
60556537 else
60566538 # not using gcc
6057 if test "$host_cpu" = ia64; then
6539 if test ia64 = "$host_cpu"; then
60586540 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
60596541 # chokes on -Wl,-G. The following line is correct:
60606542 shared_flag='-G'
60616543 else
6062 if test "$aix_use_runtimelinking" = yes; then
6063 shared_flag='${wl}-G'
6544 if test yes = "$aix_use_runtimelinking"; then
6545 shared_flag='$wl-G'
60646546 else
6065 shared_flag='${wl}-bM:SRE'
6547 shared_flag='$wl-bM:SRE'
60666548 fi
6549 shared_flag_aix='$wl-bM:SRE'
6550 shared_flag_svr4='$wl-G'
60676551 fi
60686552 fi
60696553
6070 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
6554 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall'
60716555 # It seems that -bexpall does not export symbols beginning with
60726556 # underscore (_), so it is better to generate a list of symbols to
60736557 # export.
60746558 _LT_TAGVAR(always_export_symbols, $1)=yes
6075 if test "$aix_use_runtimelinking" = yes; then
6559 if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
60766560 # Warning - without using the other runtime loading flags (-brtl),
60776561 # -berok will link without error, but may produce a broken library.
6078 _LT_TAGVAR(allow_undefined_flag, $1)='-berok'
6562 # The "-G" linker flag allows undefined symbols.
6563 _LT_TAGVAR(no_undefined_flag, $1)='-bernotok'
60796564 # Determine the default libpath from the value encoded in an empty
60806565 # executable.
60816566 _LT_SYS_MODULE_PATH_AIX([$1])
6082 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6083
6084 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
6567 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
6568
6569 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
60856570 else
6086 if test "$host_cpu" = ia64; then
6087 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
6571 if test ia64 = "$host_cpu"; then
6572 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib'
60886573 _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
6089 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
6574 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols"
60906575 else
60916576 # Determine the default libpath from the value encoded in an
60926577 # empty executable.
60936578 _LT_SYS_MODULE_PATH_AIX([$1])
6094 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
6579 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath"
60956580 # Warning - without using the other run time loading flags,
60966581 # -berok will link without error, but may produce a broken library.
6097 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
6098 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
6099 if test "$with_gnu_ld" = yes; then
6582 _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok'
6583 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok'
6584 if test yes = "$with_gnu_ld"; then
61006585 # We only use this code for GNU lds that support --whole-archive.
6101 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6586 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
61026587 else
61036588 # Exported symbols can be pulled into shared objects from archives
61046589 _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
61056590 fi
61066591 _LT_TAGVAR(archive_cmds_need_lc, $1)=yes
6107 # This is similar to how AIX traditionally builds its shared
6108 # libraries.
6109 _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
6592 _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
6593 # -brtl affects multiple linker settings, -berok does not and is overridden later
6594 compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`'
6595 if test svr4 != "$with_aix_soname"; then
6596 # This is similar to how AIX traditionally builds its shared
6597 # libraries. Need -bnortl late, we may have -brtl in LDFLAGS.
6598 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
6599 fi
6600 if test aix != "$with_aix_soname"; then
6601 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
6602 else
6603 # used by -dlpreopen to get the symbols
6604 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
6605 fi
6606 _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d'
61106607 fi
61116608 fi
61126609 ;;
61166613 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
61176614 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
61186615 # support --undefined. This deserves some investigation. FIXME
6119 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6616 _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
61206617 else
61216618 _LT_TAGVAR(ld_shlibs, $1)=no
61226619 fi
61446641 # Tell ltmain to make .lib files, not .a files.
61456642 libext=lib
61466643 # Tell ltmain to make .dll files, not .so files.
6147 shrext_cmds=".dll"
6644 shrext_cmds=.dll
61486645 # FIXME: Setting linknames here is a bad hack.
6149 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
6150 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6151 $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
6152 else
6153 $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
6154 fi~
6155 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
6156 linknames='
6646 _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
6647 _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
6648 cp "$export_symbols" "$output_objdir/$soname.def";
6649 echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
6650 else
6651 $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
6652 fi~
6653 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
6654 linknames='
61576655 # The linker will not automatically build a static lib if we build a DLL.
61586656 # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
61596657 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
61606658 # Don't use ranlib
61616659 _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
61626660 _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
6163 lt_tool_outputfile="@TOOL_OUTPUT@"~
6164 case $lt_outputfile in
6165 *.exe|*.EXE) ;;
6166 *)
6167 lt_outputfile="$lt_outputfile.exe"
6168 lt_tool_outputfile="$lt_tool_outputfile.exe"
6169 ;;
6170 esac~
6171 func_to_tool_file "$lt_outputfile"~
6172 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
6173 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
6174 $RM "$lt_outputfile.manifest";
6175 fi'
6661 lt_tool_outputfile="@TOOL_OUTPUT@"~
6662 case $lt_outputfile in
6663 *.exe|*.EXE) ;;
6664 *)
6665 lt_outputfile=$lt_outputfile.exe
6666 lt_tool_outputfile=$lt_tool_outputfile.exe
6667 ;;
6668 esac~
6669 func_to_tool_file "$lt_outputfile"~
6670 if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
6671 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
6672 $RM "$lt_outputfile.manifest";
6673 fi'
61766674 ;;
61776675 *)
61786676 # g++
61796677 # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
61806678 # as there is no search path for DLLs.
61816679 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6182 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
6680 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols'
61836681 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
61846682 _LT_TAGVAR(always_export_symbols, $1)=no
61856683 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
61866684
61876685 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
6188 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6189 # If the export-symbols file already is a .def file (1st line
6190 # is EXPORTS), use it as is; otherwise, prepend...
6191 _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
6192 cp $export_symbols $output_objdir/$soname.def;
6193 else
6194 echo EXPORTS > $output_objdir/$soname.def;
6195 cat $export_symbols >> $output_objdir/$soname.def;
6196 fi~
6197 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6686 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
6687 # If the export-symbols file already is a .def file, use it as
6688 # is; otherwise, prepend EXPORTS...
6689 _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then
6690 cp $export_symbols $output_objdir/$soname.def;
6691 else
6692 echo EXPORTS > $output_objdir/$soname.def;
6693 cat $export_symbols >> $output_objdir/$soname.def;
6694 fi~
6695 $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
61986696 else
61996697 _LT_TAGVAR(ld_shlibs, $1)=no
62006698 fi
62036701 ;;
62046702 darwin* | rhapsody*)
62056703 _LT_DARWIN_LINKER_FEATURES($1)
6704 ;;
6705
6706 os2*)
6707 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
6708 _LT_TAGVAR(hardcode_minus_L, $1)=yes
6709 _LT_TAGVAR(allow_undefined_flag, $1)=unsupported
6710 shrext_cmds=.dll
6711 _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
6712 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
6713 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
6714 $ECHO EXPORTS >> $output_objdir/$libname.def~
6715 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
6716 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
6717 emximp -o $lib $output_objdir/$libname.def'
6718 _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
6719 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
6720 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
6721 $ECHO EXPORTS >> $output_objdir/$libname.def~
6722 prefix_cmds="$SED"~
6723 if test EXPORTS = "`$SED 1q $export_symbols`"; then
6724 prefix_cmds="$prefix_cmds -e 1d";
6725 fi~
6726 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
6727 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
6728 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
6729 emximp -o $lib $output_objdir/$libname.def'
6730 _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
6731 _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
62066732 ;;
62076733
62086734 dgux*)
62406766 ;;
62416767
62426768 haiku*)
6243 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6769 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
62446770 _LT_TAGVAR(link_all_deplibs, $1)=yes
62456771 ;;
62466772
62476773 hpux9*)
6248 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6774 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
62496775 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
6250 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6776 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
62516777 _LT_TAGVAR(hardcode_direct, $1)=yes
62526778 _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
62536779 # but as the default
62596785 _LT_TAGVAR(ld_shlibs, $1)=no
62606786 ;;
62616787 aCC*)
6262 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6788 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
62636789 # Commands to make compiler produce verbose output that lists
62646790 # what "hidden" libraries, object files and flags are used when
62656791 # linking a shared library.
62686794 # explicitly linking system object files so we need to strip them
62696795 # from the output so that they don't get included in the library
62706796 # dependencies.
6271 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6797 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
62726798 ;;
62736799 *)
6274 if test "$GXX" = yes; then
6275 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
6800 if test yes = "$GXX"; then
6801 _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib'
62766802 else
62776803 # FIXME: insert proper C++ library support
62786804 _LT_TAGVAR(ld_shlibs, $1)=no
62826808 ;;
62836809
62846810 hpux10*|hpux11*)
6285 if test $with_gnu_ld = no; then
6286 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
6811 if test no = "$with_gnu_ld"; then
6812 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir'
62876813 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
62886814
62896815 case $host_cpu in
62906816 hppa*64*|ia64*)
62916817 ;;
62926818 *)
6293 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6819 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
62946820 ;;
62956821 esac
62966822 fi
63166842 aCC*)
63176843 case $host_cpu in
63186844 hppa*64*)
6319 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6845 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
63206846 ;;
63216847 ia64*)
6322 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6848 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
63236849 ;;
63246850 *)
6325 _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6851 _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
63266852 ;;
63276853 esac
63286854 # Commands to make compiler produce verbose output that lists
63336859 # explicitly linking system object files so we need to strip them
63346860 # from the output so that they don't get included in the library
63356861 # dependencies.
6336 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6862 output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
63376863 ;;
63386864 *)
6339 if test "$GXX" = yes; then
6340 if test $with_gnu_ld = no; then
6865 if test yes = "$GXX"; then
6866 if test no = "$with_gnu_ld"; then
63416867 case $host_cpu in
63426868 hppa*64*)
6343 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6869 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
63446870 ;;
63456871 ia64*)
6346 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6872 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
63476873 ;;
63486874 *)
6349 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6875 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
63506876 ;;
63516877 esac
63526878 fi
63616887 interix[[3-9]]*)
63626888 _LT_TAGVAR(hardcode_direct, $1)=no
63636889 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6364 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6365 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6890 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
6891 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
63666892 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
63676893 # Instead, shared libraries are loaded at an image base (0x10000000 by
63686894 # default) and relocated if they conflict, which is a slow very memory
63696895 # consuming and fragmenting process. To avoid this, we pick a random,
63706896 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
63716897 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
6372 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6373 _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6898 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
6899 _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
63746900 ;;
63756901 irix5* | irix6*)
63766902 case $cc_basename in
63776903 CC*)
63786904 # SGI C++
6379 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6905 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
63806906
63816907 # Archives containing C++ object files must be created using
63826908 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
63856911 _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
63866912 ;;
63876913 *)
6388 if test "$GXX" = yes; then
6389 if test "$with_gnu_ld" = no; then
6390 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
6914 if test yes = "$GXX"; then
6915 if test no = "$with_gnu_ld"; then
6916 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
63916917 else
6392 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
6918 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib'
63936919 fi
63946920 fi
63956921 _LT_TAGVAR(link_all_deplibs, $1)=yes
63966922 ;;
63976923 esac
6398 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6924 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
63996925 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
64006926 _LT_TAGVAR(inherit_rpath, $1)=yes
64016927 ;;
64086934 # KCC will only create a shared library if the output file
64096935 # ends with ".so" (or ".sl" for HP-UX), so rename the library
64106936 # to its proper name (with version) after linking.
6411 _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
6412 _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
6937 _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
6938 _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib'
64136939 # Commands to make compiler produce verbose output that lists
64146940 # what "hidden" libraries, object files and flags are used when
64156941 # linking a shared library.
64186944 # explicitly linking system object files so we need to strip them
64196945 # from the output so that they don't get included in the library
64206946 # dependencies.
6421 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6422
6423 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6424 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6947 output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
6948
6949 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
6950 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
64256951
64266952 # Archives containing C++ object files must be created using
64276953 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
64356961 # earlier do not add the objects themselves.
64366962 case `$CC -V 2>&1` in
64376963 *"Version 7."*)
6438 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6439 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6964 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
6965 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
64406966 ;;
64416967 *) # Version 8.0 or newer
64426968 tmp_idyn=
64436969 case $host_cpu in
64446970 ia64*) tmp_idyn=' -i_dynamic';;
64456971 esac
6446 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6447 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
6972 _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
6973 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
64486974 ;;
64496975 esac
64506976 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
6451 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6452 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6453 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
6977 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
6978 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
6979 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive'
64546980 ;;
64556981 pgCC* | pgcpp*)
64566982 # Portland Group C++ compiler
64576983 case `$CC -V` in
64586984 *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
64596985 _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
6460 rm -rf $tpldir~
6461 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
6462 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
6986 rm -rf $tpldir~
6987 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
6988 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
64636989 _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
6464 rm -rf $tpldir~
6465 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
6466 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
6467 $RANLIB $oldlib'
6990 rm -rf $tpldir~
6991 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
6992 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
6993 $RANLIB $oldlib'
64686994 _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
6469 rm -rf $tpldir~
6470 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6471 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6995 rm -rf $tpldir~
6996 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6997 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
64726998 _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
6473 rm -rf $tpldir~
6474 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
6475 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
6999 rm -rf $tpldir~
7000 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
7001 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
64767002 ;;
64777003 *) # Version 6 and above use weak symbols
6478 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
6479 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
7004 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
7005 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
64807006 ;;
64817007 esac
64827008
6483 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
6484 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6485 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
7009 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir'
7010 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
7011 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
64867012 ;;
64877013 cxx*)
64887014 # Compaq C++
6489 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
6490 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
7015 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib'
7016 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols'
64917017
64927018 runpath_var=LD_RUN_PATH
64937019 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
65017027 # explicitly linking system object files so we need to strip them
65027028 # from the output so that they don't get included in the library
65037029 # dependencies.
6504 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
7030 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
65057031 ;;
65067032 xl* | mpixl* | bgxl*)
65077033 # IBM XL 8.0 on PPC, with GNU ld
6508 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
6509 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
6510 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
6511 if test "x$supports_anon_versioning" = xyes; then
7034 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
7035 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic'
7036 _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
7037 if test yes = "$supports_anon_versioning"; then
65127038 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
6513 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
6514 echo "local: *; };" >> $output_objdir/$libname.ver~
6515 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
7039 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
7040 echo "local: *; };" >> $output_objdir/$libname.ver~
7041 $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
65167042 fi
65177043 ;;
65187044 *)
65207046 *Sun\ C*)
65217047 # Sun C++ 5.9
65227048 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6523 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
6524 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
7049 _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7050 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols'
65257051 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
6526 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
7052 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
65277053 _LT_TAGVAR(compiler_needs_object, $1)=yes
65287054
65297055 # Not sure whether something based on
65817107 _LT_TAGVAR(ld_shlibs, $1)=yes
65827108 ;;
65837109
6584 openbsd2*)
6585 # C++ shared libraries are fairly broken
6586 _LT_TAGVAR(ld_shlibs, $1)=no
6587 ;;
6588
6589 openbsd*)
7110 openbsd* | bitrig*)
65907111 if test -f /usr/libexec/ld.so; then
65917112 _LT_TAGVAR(hardcode_direct, $1)=yes
65927113 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
65937114 _LT_TAGVAR(hardcode_direct_absolute, $1)=yes
65947115 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
6595 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
6596 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
6597 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
6598 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
6599 _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
7116 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
7117 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then
7118 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib'
7119 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E'
7120 _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
66007121 fi
66017122 output_verbose_link_cmd=func_echo_all
66027123 else
66127133 # KCC will only create a shared library if the output file
66137134 # ends with ".so" (or ".sl" for HP-UX), so rename the library
66147135 # to its proper name (with version) after linking.
6615 _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
6616
6617 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
7136 _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
7137
7138 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir'
66187139 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
66197140
66207141 # Archives containing C++ object files must be created using
66327153 cxx*)
66337154 case $host in
66347155 osf3*)
6635 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
6636 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
6637 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7156 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
7157 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
7158 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
66387159 ;;
66397160 *)
66407161 _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
6641 _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
7162 _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
66427163 _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
6643 echo "-hidden">> $lib.exp~
6644 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
6645 $RM $lib.exp'
7164 echo "-hidden">> $lib.exp~
7165 $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~
7166 $RM $lib.exp'
66467167 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
66477168 ;;
66487169 esac
66577178 # explicitly linking system object files so we need to strip them
66587179 # from the output so that they don't get included in the library
66597180 # dependencies.
6660 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
7181 output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
66617182 ;;
66627183 *)
6663 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6664 _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
7184 if test yes,no = "$GXX,$with_gnu_ld"; then
7185 _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*'
66657186 case $host in
66667187 osf3*)
6667 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7188 _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
66687189 ;;
66697190 *)
6670 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
7191 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
66717192 ;;
66727193 esac
66737194
6674 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
7195 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir'
66757196 _LT_TAGVAR(hardcode_libdir_separator, $1)=:
66767197
66777198 # Commands to make compiler produce verbose output that lists
67177238 # Sun C++ 4.2, 5.x and Centerline C++
67187239 _LT_TAGVAR(archive_cmds_need_lc,$1)=yes
67197240 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
6720 _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
7241 _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
67217242 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6722 $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7243 $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
67237244
67247245 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
67257246 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
67277248 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
67287249 *)
67297250 # The compiler driver will combine and reorder linker options,
6730 # but understands `-z linker_flag'.
7251 # but understands '-z linker_flag'.
67317252 # Supported since Solaris 2.6 (maybe 2.5.1?)
67327253 _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
67337254 ;;
67447265 ;;
67457266 gcx*)
67467267 # Green Hills C++ Compiler
6747 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7268 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
67487269
67497270 # The C++ compiler must be used to create the archive.
67507271 _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
67517272 ;;
67527273 *)
67537274 # GNU C++ compiler with Solaris linker
6754 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
6755 _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
7275 if test yes,no = "$GXX,$with_gnu_ld"; then
7276 _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs'
67567277 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
6757 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7278 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
67587279 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6759 $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7280 $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
67607281
67617282 # Commands to make compiler produce verbose output that lists
67627283 # what "hidden" libraries, object files and flags are used when
67637284 # linking a shared library.
67647285 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
67657286 else
6766 # g++ 2.7 appears to require `-G' NOT `-shared' on this
7287 # g++ 2.7 appears to require '-G' NOT '-shared' on this
67677288 # platform.
6768 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
7289 _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib'
67697290 _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
6770 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
7291 $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
67717292
67727293 # Commands to make compiler produce verbose output that lists
67737294 # what "hidden" libraries, object files and flags are used when
67757296 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
67767297 fi
67777298
6778 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
7299 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir'
67797300 case $host_os in
67807301 solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
67817302 *)
6782 _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
7303 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
67837304 ;;
67847305 esac
67857306 fi
67887309 ;;
67897310
67907311 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
6791 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
7312 _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
67927313 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
67937314 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
67947315 runpath_var='LD_RUN_PATH'
67957316
67967317 case $cc_basename in
67977318 CC*)
6798 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6799 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7319 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7320 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
68007321 ;;
68017322 *)
6802 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6803 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7323 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7324 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
68047325 ;;
68057326 esac
68067327 ;;
68077328
68087329 sysv5* | sco3.2v5* | sco5v6*)
6809 # Note: We can NOT use -z defs as we might desire, because we do not
7330 # Note: We CANNOT use -z defs as we might desire, because we do not
68107331 # link with -lc, and that would cause any symbols used from libc to
68117332 # always be unresolved, which means just about no library would
68127333 # ever link correctly. If we're not using GNU ld we use -z text
68137334 # though, which does catch some bad symbols but isn't as heavy-handed
68147335 # as -z defs.
6815 _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
6816 _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
7336 _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text'
7337 _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs'
68177338 _LT_TAGVAR(archive_cmds_need_lc, $1)=no
68187339 _LT_TAGVAR(hardcode_shlibpath_var, $1)=no
6819 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
7340 _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir'
68207341 _LT_TAGVAR(hardcode_libdir_separator, $1)=':'
68217342 _LT_TAGVAR(link_all_deplibs, $1)=yes
6822 _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
7343 _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport'
68237344 runpath_var='LD_RUN_PATH'
68247345
68257346 case $cc_basename in
68267347 CC*)
6827 _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6828 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7348 _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7349 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
68297350 _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
6830 '"$_LT_TAGVAR(old_archive_cmds, $1)"
7351 '"$_LT_TAGVAR(old_archive_cmds, $1)"
68317352 _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
6832 '"$_LT_TAGVAR(reload_cmds, $1)"
7353 '"$_LT_TAGVAR(reload_cmds, $1)"
68337354 ;;
68347355 *)
6835 _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
6836 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7356 _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
7357 _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
68377358 ;;
68387359 esac
68397360 ;;
68647385 esac
68657386
68667387 AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
6867 test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
6868
6869 _LT_TAGVAR(GCC, $1)="$GXX"
6870 _LT_TAGVAR(LD, $1)="$LD"
7388 test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no
7389
7390 _LT_TAGVAR(GCC, $1)=$GXX
7391 _LT_TAGVAR(LD, $1)=$LD
68717392
68727393 ## CAVEAT EMPTOR:
68737394 ## There is no encapsulation within the following macros, do not change
68947415 lt_cv_path_LD=$lt_save_path_LD
68957416 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
68967417 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
6897 fi # test "$_lt_caught_CXX_error" != yes
7418 fi # test yes != "$_lt_caught_CXX_error"
68987419
68997420 AC_LANG_POP
69007421 ])# _LT_LANG_CXX_CONFIG
69167437 AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
69177438 func_stripname_cnf ()
69187439 {
6919 case ${2} in
6920 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
6921 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
7440 case @S|@2 in
7441 .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;;
7442 *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;;
69227443 esac
69237444 } # func_stripname_cnf
69247445 ])# _LT_FUNC_STRIPNAME_CNF
7446
69257447
69267448 # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
69277449 # ---------------------------------
70067528 pre_test_object_deps_done=no
70077529
70087530 for p in `eval "$output_verbose_link_cmd"`; do
7009 case ${prev}${p} in
7531 case $prev$p in
70107532
70117533 -L* | -R* | -l*)
70127534 # Some compilers place space between "-{L,R}" and the path.
70137535 # Remove the space.
7014 if test $p = "-L" ||
7015 test $p = "-R"; then
7536 if test x-L = "$p" ||
7537 test x-R = "$p"; then
70167538 prev=$p
70177539 continue
70187540 fi
70287550 case $p in
70297551 =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
70307552 esac
7031 if test "$pre_test_object_deps_done" = no; then
7032 case ${prev} in
7553 if test no = "$pre_test_object_deps_done"; then
7554 case $prev in
70337555 -L | -R)
70347556 # Internal compiler library paths should come after those
70357557 # provided the user. The postdeps already come after the
70367558 # user supplied libs so there is no need to process them.
70377559 if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
7038 _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
7560 _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p
70397561 else
7040 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
7562 _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p"
70417563 fi
70427564 ;;
70437565 # The "-l" case would never come before the object being
70457567 esac
70467568 else
70477569 if test -z "$_LT_TAGVAR(postdeps, $1)"; then
7048 _LT_TAGVAR(postdeps, $1)="${prev}${p}"
7570 _LT_TAGVAR(postdeps, $1)=$prev$p
70497571 else
7050 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
7572 _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p"
70517573 fi
70527574 fi
70537575 prev=
70627584 continue
70637585 fi
70647586
7065 if test "$pre_test_object_deps_done" = no; then
7587 if test no = "$pre_test_object_deps_done"; then
70667588 if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
7067 _LT_TAGVAR(predep_objects, $1)="$p"
7589 _LT_TAGVAR(predep_objects, $1)=$p
70687590 else
70697591 _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
70707592 fi
70717593 else
70727594 if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
7073 _LT_TAGVAR(postdep_objects, $1)="$p"
7595 _LT_TAGVAR(postdep_objects, $1)=$p
70747596 else
70757597 _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
70767598 fi
71017623 _LT_TAGVAR(postdep_objects,$1)=
71027624 _LT_TAGVAR(postdeps,$1)=
71037625 ;;
7104
7105 linux*)
7106 case `$CC -V 2>&1 | sed 5q` in
7107 *Sun\ C*)
7108 # Sun C++ 5.9
7109
7110 # The more standards-conforming stlport4 library is
7111 # incompatible with the Cstd library. Avoid specifying
7112 # it if it's in CXXFLAGS. Ignore libCrun as
7113 # -library=stlport4 depends on it.
7114 case " $CXX $CXXFLAGS " in
7115 *" -library=stlport4 "*)
7116 solaris_use_stlport4=yes
7117 ;;
7118 esac
7119
7120 if test "$solaris_use_stlport4" != yes; then
7121 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
7122 fi
7123 ;;
7124 esac
7125 ;;
7126
7127 solaris*)
7128 case $cc_basename in
7129 CC* | sunCC*)
7130 # The more standards-conforming stlport4 library is
7131 # incompatible with the Cstd library. Avoid specifying
7132 # it if it's in CXXFLAGS. Ignore libCrun as
7133 # -library=stlport4 depends on it.
7134 case " $CXX $CXXFLAGS " in
7135 *" -library=stlport4 "*)
7136 solaris_use_stlport4=yes
7137 ;;
7138 esac
7139
7140 # Adding this requires a known-good setup of shared libraries for
7141 # Sun compiler versions before 5.6, else PIC objects from an old
7142 # archive will be linked into the output, leading to subtle bugs.
7143 if test "$solaris_use_stlport4" != yes; then
7144 _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
7145 fi
7146 ;;
7147 esac
7148 ;;
71497626 esac
71507627 ])
71517628
71547631 esac
71557632 _LT_TAGVAR(compiler_lib_search_dirs, $1)=
71567633 if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
7157 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
7634 _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'`
71587635 fi
71597636 _LT_TAGDECL([], [compiler_lib_search_dirs], [1],
71607637 [The directories searched by this compiler when creating a shared library])
71747651 # --------------------------
71757652 # Ensure that the configuration variables for a Fortran 77 compiler are
71767653 # suitably defined. These variables are subsequently used by _LT_CONFIG
7177 # to write the compiler configuration to `libtool'.
7654 # to write the compiler configuration to 'libtool'.
71787655 m4_defun([_LT_LANG_F77_CONFIG],
71797656 [AC_LANG_PUSH(Fortran 77)
7180 if test -z "$F77" || test "X$F77" = "Xno"; then
7657 if test -z "$F77" || test no = "$F77"; then
71817658 _lt_disable_F77=yes
71827659 fi
71837660
72147691 # the F77 compiler isn't working. Some variables (like enable_shared)
72157692 # are currently assumed to apply to all compilers on this platform,
72167693 # and will be corrupted by setting them based on a non-working compiler.
7217 if test "$_lt_disable_F77" != yes; then
7694 if test yes != "$_lt_disable_F77"; then
72187695 # Code to be used in simple compile tests
72197696 lt_simple_compile_test_code="\
72207697 subroutine t
72367713 _LT_LINKER_BOILERPLATE
72377714
72387715 # Allow CC to be a program name with arguments.
7239 lt_save_CC="$CC"
7716 lt_save_CC=$CC
72407717 lt_save_GCC=$GCC
72417718 lt_save_CFLAGS=$CFLAGS
72427719 CC=${F77-"f77"}
72507727 AC_MSG_RESULT([$can_build_shared])
72517728
72527729 AC_MSG_CHECKING([whether to build shared libraries])
7253 test "$can_build_shared" = "no" && enable_shared=no
7730 test no = "$can_build_shared" && enable_shared=no
72547731
72557732 # On AIX, shared libraries and static libraries use the same namespace, and
72567733 # are all built from PIC.
72577734 case $host_os in
72587735 aix3*)
7259 test "$enable_shared" = yes && enable_static=no
7736 test yes = "$enable_shared" && enable_static=no
72607737 if test -n "$RANLIB"; then
72617738 archive_cmds="$archive_cmds~\$RANLIB \$lib"
72627739 postinstall_cmds='$RANLIB $lib'
72637740 fi
72647741 ;;
72657742 aix[[4-9]]*)
7266 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7267 test "$enable_shared" = yes && enable_static=no
7743 if test ia64 != "$host_cpu"; then
7744 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
7745 yes,aix,yes) ;; # shared object as lib.so file only
7746 yes,svr4,*) ;; # shared object as lib.so archive member only
7747 yes,*) enable_static=no ;; # shared object in lib.a archive as well
7748 esac
72687749 fi
72697750 ;;
72707751 esac
72727753
72737754 AC_MSG_CHECKING([whether to build static libraries])
72747755 # Make sure either enable_shared or enable_static is yes.
7275 test "$enable_shared" = yes || enable_static=yes
7756 test yes = "$enable_shared" || enable_static=yes
72767757 AC_MSG_RESULT([$enable_static])
72777758
7278 _LT_TAGVAR(GCC, $1)="$G77"
7279 _LT_TAGVAR(LD, $1)="$LD"
7759 _LT_TAGVAR(GCC, $1)=$G77
7760 _LT_TAGVAR(LD, $1)=$LD
72807761
72817762 ## CAVEAT EMPTOR:
72827763 ## There is no encapsulation within the following macros, do not change
72937774 fi # test -n "$compiler"
72947775
72957776 GCC=$lt_save_GCC
7296 CC="$lt_save_CC"
7297 CFLAGS="$lt_save_CFLAGS"
7298 fi # test "$_lt_disable_F77" != yes
7777 CC=$lt_save_CC
7778 CFLAGS=$lt_save_CFLAGS
7779 fi # test yes != "$_lt_disable_F77"
72997780
73007781 AC_LANG_POP
73017782 ])# _LT_LANG_F77_CONFIG
73057786 # -------------------------
73067787 # Ensure that the configuration variables for a Fortran compiler are
73077788 # suitably defined. These variables are subsequently used by _LT_CONFIG
7308 # to write the compiler configuration to `libtool'.
7789 # to write the compiler configuration to 'libtool'.
73097790 m4_defun([_LT_LANG_FC_CONFIG],
73107791 [AC_LANG_PUSH(Fortran)
73117792
7312 if test -z "$FC" || test "X$FC" = "Xno"; then
7793 if test -z "$FC" || test no = "$FC"; then
73137794 _lt_disable_FC=yes
73147795 fi
73157796
73467827 # the FC compiler isn't working. Some variables (like enable_shared)
73477828 # are currently assumed to apply to all compilers on this platform,
73487829 # and will be corrupted by setting them based on a non-working compiler.
7349 if test "$_lt_disable_FC" != yes; then
7830 if test yes != "$_lt_disable_FC"; then
73507831 # Code to be used in simple compile tests
73517832 lt_simple_compile_test_code="\
73527833 subroutine t
73687849 _LT_LINKER_BOILERPLATE
73697850
73707851 # Allow CC to be a program name with arguments.
7371 lt_save_CC="$CC"
7852 lt_save_CC=$CC
73727853 lt_save_GCC=$GCC
73737854 lt_save_CFLAGS=$CFLAGS
73747855 CC=${FC-"f95"}
73847865 AC_MSG_RESULT([$can_build_shared])
73857866
73867867 AC_MSG_CHECKING([whether to build shared libraries])
7387 test "$can_build_shared" = "no" && enable_shared=no
7868 test no = "$can_build_shared" && enable_shared=no
73887869
73897870 # On AIX, shared libraries and static libraries use the same namespace, and
73907871 # are all built from PIC.
73917872 case $host_os in
73927873 aix3*)
7393 test "$enable_shared" = yes && enable_static=no
7874 test yes = "$enable_shared" && enable_static=no
73947875 if test -n "$RANLIB"; then
73957876 archive_cmds="$archive_cmds~\$RANLIB \$lib"
73967877 postinstall_cmds='$RANLIB $lib'
73977878 fi
73987879 ;;
73997880 aix[[4-9]]*)
7400 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
7401 test "$enable_shared" = yes && enable_static=no
7881 if test ia64 != "$host_cpu"; then
7882 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
7883 yes,aix,yes) ;; # shared object as lib.so file only
7884 yes,svr4,*) ;; # shared object as lib.so archive member only
7885 yes,*) enable_static=no ;; # shared object in lib.a archive as well
7886 esac
74027887 fi
74037888 ;;
74047889 esac
74067891
74077892 AC_MSG_CHECKING([whether to build static libraries])
74087893 # Make sure either enable_shared or enable_static is yes.
7409 test "$enable_shared" = yes || enable_static=yes
7894 test yes = "$enable_shared" || enable_static=yes
74107895 AC_MSG_RESULT([$enable_static])
74117896
7412 _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
7413 _LT_TAGVAR(LD, $1)="$LD"
7897 _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu
7898 _LT_TAGVAR(LD, $1)=$LD
74147899
74157900 ## CAVEAT EMPTOR:
74167901 ## There is no encapsulation within the following macros, do not change
74307915 GCC=$lt_save_GCC
74317916 CC=$lt_save_CC
74327917 CFLAGS=$lt_save_CFLAGS
7433 fi # test "$_lt_disable_FC" != yes
7918 fi # test yes != "$_lt_disable_FC"
74347919
74357920 AC_LANG_POP
74367921 ])# _LT_LANG_FC_CONFIG
74407925 # --------------------------
74417926 # Ensure that the configuration variables for the GNU Java Compiler compiler
74427927 # are suitably defined. These variables are subsequently used by _LT_CONFIG
7443 # to write the compiler configuration to `libtool'.
7928 # to write the compiler configuration to 'libtool'.
74447929 m4_defun([_LT_LANG_GCJ_CONFIG],
74457930 [AC_REQUIRE([LT_PROG_GCJ])dnl
74467931 AC_LANG_SAVE
74747959 CFLAGS=$GCJFLAGS
74757960 compiler=$CC
74767961 _LT_TAGVAR(compiler, $1)=$CC
7477 _LT_TAGVAR(LD, $1)="$LD"
7962 _LT_TAGVAR(LD, $1)=$LD
74787963 _LT_CC_BASENAME([$compiler])
74797964
74807965 # GCJ did not exist at the time GCC didn't implicitly link libc in.
75117996 # --------------------------
75127997 # Ensure that the configuration variables for the GNU Go compiler
75137998 # are suitably defined. These variables are subsequently used by _LT_CONFIG
7514 # to write the compiler configuration to `libtool'.
7999 # to write the compiler configuration to 'libtool'.
75158000 m4_defun([_LT_LANG_GO_CONFIG],
75168001 [AC_REQUIRE([LT_PROG_GO])dnl
75178002 AC_LANG_SAVE
75458030 CFLAGS=$GOFLAGS
75468031 compiler=$CC
75478032 _LT_TAGVAR(compiler, $1)=$CC
7548 _LT_TAGVAR(LD, $1)="$LD"
8033 _LT_TAGVAR(LD, $1)=$LD
75498034 _LT_CC_BASENAME([$compiler])
75508035
75518036 # Go did not exist at the time GCC didn't implicitly link libc in.
75828067 # -------------------------
75838068 # Ensure that the configuration variables for the Windows resource compiler
75848069 # are suitably defined. These variables are subsequently used by _LT_CONFIG
7585 # to write the compiler configuration to `libtool'.
8070 # to write the compiler configuration to 'libtool'.
75868071 m4_defun([_LT_LANG_RC_CONFIG],
75878072 [AC_REQUIRE([LT_PROG_RC])dnl
75888073 AC_LANG_SAVE
75988083 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
75998084
76008085 # Code to be used in simple link tests
7601 lt_simple_link_test_code="$lt_simple_compile_test_code"
8086 lt_simple_link_test_code=$lt_simple_compile_test_code
76028087
76038088 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
76048089 _LT_TAG_COMPILER
76088093 _LT_LINKER_BOILERPLATE
76098094
76108095 # Allow CC to be a program name with arguments.
7611 lt_save_CC="$CC"
8096 lt_save_CC=$CC
76128097 lt_save_CFLAGS=$CFLAGS
76138098 lt_save_GCC=$GCC
76148099 GCC=
76378122 [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
76388123 [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
76398124 [AC_CHECK_TOOL(GCJ, gcj,)
7640 test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
8125 test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2"
76418126 AC_SUBST(GCJFLAGS)])])[]dnl
76428127 ])
76438128
77488233 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
77498234 # along with /bin/sed that truncates output.
77508235 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
7751 test ! -f $lt_ac_sed && continue
8236 test ! -f "$lt_ac_sed" && continue
77528237 cat /dev/null > conftest.in
77538238 lt_ac_count=0
77548239 echo $ECHO_N "0123456789$ECHO_C" >conftest.in
77658250 $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
77668251 cmp -s conftest.out conftest.nl || break
77678252 # 10000 chars as input seems more than enough
7768 test $lt_ac_count -gt 10 && break
8253 test 10 -lt "$lt_ac_count" && break
77698254 lt_ac_count=`expr $lt_ac_count + 1`
7770 if test $lt_ac_count -gt $lt_ac_max; then
8255 if test "$lt_ac_count" -gt "$lt_ac_max"; then
77718256 lt_ac_max=$lt_ac_count
77728257 lt_cv_path_SED=$lt_ac_sed
77738258 fi
77918276 # Find out whether the shell is Bourne or XSI compatible,
77928277 # or has some other useful features.
77938278 m4_defun([_LT_CHECK_SHELL_FEATURES],
7794 [AC_MSG_CHECKING([whether the shell understands some XSI constructs])
7795 # Try some XSI features
7796 xsi_shell=no
7797 ( _lt_dummy="a/b/c"
7798 test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
7799 = c,a/b,b/c, \
7800 && eval 'test $(( 1 + 1 )) -eq 2 \
7801 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
7802 && xsi_shell=yes
7803 AC_MSG_RESULT([$xsi_shell])
7804 _LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
7805
7806 AC_MSG_CHECKING([whether the shell understands "+="])
7807 lt_shell_append=no
7808 ( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
7809 >/dev/null 2>&1 \
7810 && lt_shell_append=yes
7811 AC_MSG_RESULT([$lt_shell_append])
7812 _LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
7813
7814 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
8279 [if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
78158280 lt_unset=unset
78168281 else
78178282 lt_unset=false
78358300 ])# _LT_CHECK_SHELL_FEATURES
78368301
78378302
7838 # _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
7839 # ------------------------------------------------------
7840 # In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
7841 # '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
7842 m4_defun([_LT_PROG_FUNCTION_REPLACE],
7843 [dnl {
7844 sed -e '/^$1 ()$/,/^} # $1 /c\
7845 $1 ()\
7846 {\
7847 m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1])
7848 } # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
7849 && mv -f "$cfgfile.tmp" "$cfgfile" \
7850 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
7851 test 0 -eq $? || _lt_function_replace_fail=:
7852 ])
7853
7854
7855 # _LT_PROG_REPLACE_SHELLFNS
7856 # -------------------------
7857 # Replace existing portable implementations of several shell functions with
7858 # equivalent extended shell implementations where those features are available..
7859 m4_defun([_LT_PROG_REPLACE_SHELLFNS],
7860 [if test x"$xsi_shell" = xyes; then
7861 _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
7862 case ${1} in
7863 */*) func_dirname_result="${1%/*}${2}" ;;
7864 * ) func_dirname_result="${3}" ;;
7865 esac])
7866
7867 _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
7868 func_basename_result="${1##*/}"])
7869
7870 _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
7871 case ${1} in
7872 */*) func_dirname_result="${1%/*}${2}" ;;
7873 * ) func_dirname_result="${3}" ;;
7874 esac
7875 func_basename_result="${1##*/}"])
7876
7877 _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
7878 # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
7879 # positional parameters, so assign one to ordinary parameter first.
7880 func_stripname_result=${3}
7881 func_stripname_result=${func_stripname_result#"${1}"}
7882 func_stripname_result=${func_stripname_result%"${2}"}])
7883
7884 _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
7885 func_split_long_opt_name=${1%%=*}
7886 func_split_long_opt_arg=${1#*=}])
7887
7888 _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
7889 func_split_short_opt_arg=${1#??}
7890 func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
7891
7892 _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
7893 case ${1} in
7894 *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
7895 *) func_lo2o_result=${1} ;;
7896 esac])
7897
7898 _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo])
7899
7900 _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))])
7901
7902 _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}])
7903 fi
7904
7905 if test x"$lt_shell_append" = xyes; then
7906 _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"])
7907
7908 _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
7909 func_quote_for_eval "${2}"
7910 dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
7911 eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
7912
7913 # Save a `func_append' function call where possible by direct use of '+='
7914 sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
7915 && mv -f "$cfgfile.tmp" "$cfgfile" \
7916 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
7917 test 0 -eq $? || _lt_function_replace_fail=:
7918 else
7919 # Save a `func_append' function call even when '+=' is not available
7920 sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
7921 && mv -f "$cfgfile.tmp" "$cfgfile" \
7922 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
7923 test 0 -eq $? || _lt_function_replace_fail=:
7924 fi
7925
7926 if test x"$_lt_function_replace_fail" = x":"; then
7927 AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
7928 fi
7929 ])
7930
79318303 # _LT_PATH_CONVERSION_FUNCTIONS
79328304 # -----------------------------
7933 # Determine which file name conversion functions should be used by
8305 # Determine what file name conversion functions should be used by
79348306 # func_to_host_file (and, implicitly, by func_to_host_path). These are needed
79358307 # for certain cross-compile configurations and native mingw.
79368308 m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
00 # Helper functions for option handling. -*- Autoconf -*-
11 #
2 # Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation,
3 # Inc.
2 # Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software
3 # Foundation, Inc.
44 # Written by Gary V. Vaughan, 2004
55 #
66 # This file is free software; the Free Software Foundation gives
77 # unlimited permission to copy and/or distribute it, with or without
88 # modifications, as long as this notice is preserved.
99
10 # serial 7 ltoptions.m4
10 # serial 8 ltoptions.m4
1111
1212 # This is to help aclocal find these macros, as it can't see m4_define.
1313 AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
2828 [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
2929 m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
3030 _LT_MANGLE_DEFUN([$1], [$2]),
31 [m4_warning([Unknown $1 option `$2'])])[]dnl
31 [m4_warning([Unknown $1 option '$2'])])[]dnl
3232 ])
3333
3434
7474 dnl
7575 dnl If no reference was made to various pairs of opposing options, then
7676 dnl we run the default mode handler for the pair. For example, if neither
77 dnl `shared' nor `disable-shared' was passed, we enable building of shared
77 dnl 'shared' nor 'disable-shared' was passed, we enable building of shared
7878 dnl archives by default:
7979 _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
8080 _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
8181 _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
8282 _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
83 [_LT_ENABLE_FAST_INSTALL])
83 [_LT_ENABLE_FAST_INSTALL])
84 _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4],
85 [_LT_WITH_AIX_SONAME([aix])])
8486 ])
8587 ])# _LT_SET_OPTIONS
8688
111113 [_LT_SET_OPTION([LT_INIT], [dlopen])
112114 AC_DIAGNOSE([obsolete],
113115 [$0: Remove this warning and the call to _LT_SET_OPTION when you
114 put the `dlopen' option into LT_INIT's first parameter.])
116 put the 'dlopen' option into LT_INIT's first parameter.])
115117 ])
116118
117119 dnl aclocal-1.4 backwards compatibility:
147149 _LT_SET_OPTION([LT_INIT], [win32-dll])
148150 AC_DIAGNOSE([obsolete],
149151 [$0: Remove this warning and the call to _LT_SET_OPTION when you
150 put the `win32-dll' option into LT_INIT's first parameter.])
152 put the 'win32-dll' option into LT_INIT's first parameter.])
151153 ])
152154
153155 dnl aclocal-1.4 backwards compatibility:
156158
157159 # _LT_ENABLE_SHARED([DEFAULT])
158160 # ----------------------------
159 # implement the --enable-shared flag, and supports the `shared' and
160 # `disable-shared' LT_INIT options.
161 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
161 # implement the --enable-shared flag, and supports the 'shared' and
162 # 'disable-shared' LT_INIT options.
163 # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
162164 m4_define([_LT_ENABLE_SHARED],
163165 [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
164166 AC_ARG_ENABLE([shared],
171173 *)
172174 enable_shared=no
173175 # Look at the argument we got. We use all the common list separators.
174 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
176 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
175177 for pkg in $enableval; do
176 IFS="$lt_save_ifs"
178 IFS=$lt_save_ifs
177179 if test "X$pkg" = "X$p"; then
178180 enable_shared=yes
179181 fi
180182 done
181 IFS="$lt_save_ifs"
183 IFS=$lt_save_ifs
182184 ;;
183185 esac],
184186 [enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
210212
211213 # _LT_ENABLE_STATIC([DEFAULT])
212214 # ----------------------------
213 # implement the --enable-static flag, and support the `static' and
214 # `disable-static' LT_INIT options.
215 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
215 # implement the --enable-static flag, and support the 'static' and
216 # 'disable-static' LT_INIT options.
217 # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
216218 m4_define([_LT_ENABLE_STATIC],
217219 [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
218220 AC_ARG_ENABLE([static],
225227 *)
226228 enable_static=no
227229 # Look at the argument we got. We use all the common list separators.
228 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
230 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
229231 for pkg in $enableval; do
230 IFS="$lt_save_ifs"
232 IFS=$lt_save_ifs
231233 if test "X$pkg" = "X$p"; then
232234 enable_static=yes
233235 fi
234236 done
235 IFS="$lt_save_ifs"
237 IFS=$lt_save_ifs
236238 ;;
237239 esac],
238240 [enable_static=]_LT_ENABLE_STATIC_DEFAULT)
264266
265267 # _LT_ENABLE_FAST_INSTALL([DEFAULT])
266268 # ----------------------------------
267 # implement the --enable-fast-install flag, and support the `fast-install'
268 # and `disable-fast-install' LT_INIT options.
269 # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
269 # implement the --enable-fast-install flag, and support the 'fast-install'
270 # and 'disable-fast-install' LT_INIT options.
271 # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'.
270272 m4_define([_LT_ENABLE_FAST_INSTALL],
271273 [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
272274 AC_ARG_ENABLE([fast-install],
279281 *)
280282 enable_fast_install=no
281283 # Look at the argument we got. We use all the common list separators.
282 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
284 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
283285 for pkg in $enableval; do
284 IFS="$lt_save_ifs"
286 IFS=$lt_save_ifs
285287 if test "X$pkg" = "X$p"; then
286288 enable_fast_install=yes
287289 fi
288290 done
289 IFS="$lt_save_ifs"
291 IFS=$lt_save_ifs
290292 ;;
291293 esac],
292294 [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
303305 [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
304306 AC_DIAGNOSE([obsolete],
305307 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
306 the `fast-install' option into LT_INIT's first parameter.])
308 the 'fast-install' option into LT_INIT's first parameter.])
307309 ])
308310
309311 AU_DEFUN([AC_DISABLE_FAST_INSTALL],
310312 [_LT_SET_OPTION([LT_INIT], [disable-fast-install])
311313 AC_DIAGNOSE([obsolete],
312314 [$0: Remove this warning and the call to _LT_SET_OPTION when you put
313 the `disable-fast-install' option into LT_INIT's first parameter.])
315 the 'disable-fast-install' option into LT_INIT's first parameter.])
314316 ])
315317
316318 dnl aclocal-1.4 backwards compatibility:
318320 dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
319321
320322
323 # _LT_WITH_AIX_SONAME([DEFAULT])
324 # ----------------------------------
325 # implement the --with-aix-soname flag, and support the `aix-soname=aix'
326 # and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT
327 # is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'.
328 m4_define([_LT_WITH_AIX_SONAME],
329 [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl
330 shared_archive_member_spec=
331 case $host,$enable_shared in
332 power*-*-aix[[5-9]]*,yes)
333 AC_MSG_CHECKING([which variant of shared library versioning to provide])
334 AC_ARG_WITH([aix-soname],
335 [AS_HELP_STRING([--with-aix-soname=aix|svr4|both],
336 [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])],
337 [case $withval in
338 aix|svr4|both)
339 ;;
340 *)
341 AC_MSG_ERROR([Unknown argument to --with-aix-soname])
342 ;;
343 esac
344 lt_cv_with_aix_soname=$with_aix_soname],
345 [AC_CACHE_VAL([lt_cv_with_aix_soname],
346 [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT)
347 with_aix_soname=$lt_cv_with_aix_soname])
348 AC_MSG_RESULT([$with_aix_soname])
349 if test aix != "$with_aix_soname"; then
350 # For the AIX way of multilib, we name the shared archive member
351 # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
352 # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
353 # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
354 # the AIX toolchain works better with OBJECT_MODE set (default 32).
355 if test 64 = "${OBJECT_MODE-32}"; then
356 shared_archive_member_spec=shr_64
357 else
358 shared_archive_member_spec=shr
359 fi
360 fi
361 ;;
362 *)
363 with_aix_soname=aix
364 ;;
365 esac
366
367 _LT_DECL([], [shared_archive_member_spec], [0],
368 [Shared archive member basename, for filename based shared library versioning on AIX])dnl
369 ])# _LT_WITH_AIX_SONAME
370
371 LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])])
372 LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])])
373 LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])])
374
375
321376 # _LT_WITH_PIC([MODE])
322377 # --------------------
323 # implement the --with-pic flag, and support the `pic-only' and `no-pic'
378 # implement the --with-pic flag, and support the 'pic-only' and 'no-pic'
324379 # LT_INIT options.
325 # MODE is either `yes' or `no'. If omitted, it defaults to `both'.
380 # MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'.
326381 m4_define([_LT_WITH_PIC],
327382 [AC_ARG_WITH([pic],
328383 [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
333388 *)
334389 pic_mode=default
335390 # Look at the argument we got. We use all the common list separators.
336 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
391 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
337392 for lt_pkg in $withval; do
338 IFS="$lt_save_ifs"
393 IFS=$lt_save_ifs
339394 if test "X$lt_pkg" = "X$lt_p"; then
340395 pic_mode=yes
341396 fi
342397 done
343 IFS="$lt_save_ifs"
398 IFS=$lt_save_ifs
344399 ;;
345400 esac],
346 [pic_mode=default])
347
348 test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
401 [pic_mode=m4_default([$1], [default])])
349402
350403 _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
351404 ])# _LT_WITH_PIC
358411 [_LT_SET_OPTION([LT_INIT], [pic-only])
359412 AC_DIAGNOSE([obsolete],
360413 [$0: Remove this warning and the call to _LT_SET_OPTION when you
361 put the `pic-only' option into LT_INIT's first parameter.])
414 put the 'pic-only' option into LT_INIT's first parameter.])
362415 ])
363416
364417 dnl aclocal-1.4 backwards compatibility:
00 # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
11 #
2 # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
2 # Copyright (C) 2004-2005, 2007-2008, 2011-2015 Free Software
3 # Foundation, Inc.
34 # Written by Gary V. Vaughan, 2004
45 #
56 # This file is free software; the Free Software Foundation gives
3233 # ------------
3334 # Manipulate m4 lists.
3435 # These macros are necessary as long as will still need to support
35 # Autoconf-2.59 which quotes differently.
36 # Autoconf-2.59, which quotes differently.
3637 m4_define([lt_car], [[$1]])
3738 m4_define([lt_cdr],
3839 [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
4344
4445 # lt_append(MACRO-NAME, STRING, [SEPARATOR])
4546 # ------------------------------------------
46 # Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
47 # Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'.
4748 # Note that neither SEPARATOR nor STRING are expanded; they are appended
4849 # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
4950 # No SEPARATOR is output if MACRO-NAME was previously undefined (different
00 # ltversion.m4 -- version numbers -*- Autoconf -*-
11 #
2 # Copyright (C) 2004 Free Software Foundation, Inc.
2 # Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc.
33 # Written by Scott James Remnant, 2004
44 #
55 # This file is free software; the Free Software Foundation gives
88
99 # @configure_input@
1010
11 # serial 3337 ltversion.m4
11 # serial 4179 ltversion.m4
1212 # This file is part of GNU Libtool
1313
14 m4_define([LT_PACKAGE_VERSION], [2.4.2])
15 m4_define([LT_PACKAGE_REVISION], [1.3337])
14 m4_define([LT_PACKAGE_VERSION], [2.4.6])
15 m4_define([LT_PACKAGE_REVISION], [2.4.6])
1616
1717 AC_DEFUN([LTVERSION_VERSION],
18 [macro_version='2.4.2'
19 macro_revision='1.3337'
18 [macro_version='2.4.6'
19 macro_revision='2.4.6'
2020 _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
2121 _LT_DECL(, macro_revision, 0)
2222 ])
00 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
11 #
2 # Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc.
2 # Copyright (C) 2004-2005, 2007, 2009, 2011-2015 Free Software
3 # Foundation, Inc.
34 # Written by Scott James Remnant, 2004.
45 #
56 # This file is free software; the Free Software Foundation gives
1011
1112 # These exist entirely to fool aclocal when bootstrapping libtool.
1213 #
13 # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
14 # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN),
1415 # which have later been changed to m4_define as they aren't part of the
1516 # exported API, or moved to Autoconf or Automake where they belong.
1617 #
2425 # included after everything else. This provides aclocal with the
2526 # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
2627 # because those macros already exist, or will be overwritten later.
27 # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
28 # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
2829 #
2930 # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
3031 # Yes, that means every name once taken will need to remain here until
410410 set (HDF5_BUILD_PARALLEL_ALL OFF CACHE BOOL "Build Parallel Programs" FORCE)
411411 set (HDF5_ENABLE_COVERAGE OFF CACHE BOOL "Enable code coverage for Libraries and Programs" FORCE)
412412 set (HDF5_ENABLE_USING_MEMCHECKER OFF CACHE BOOL "Indicate that a memory checker is used" FORCE)
413 set (HDF5_MEMORY_ALLOC_SANITY_CHECK OFF CACHE BOOL "Indicate that internal memory allocation sanity checks are enabled" FORCE)
413414 set (HDF5_DISABLE_COMPILER_WARNINGS OFF CACHE BOOL "Disable compiler warnings" FORCE)
414415 set (HDF5_USE_FOLDERS ON CACHE BOOL "Enable folder grouping of projects in IDEs." FORCE)
415416 set (HDF5_USE_16_API_DEFAULT OFF CACHE BOOL "Use the HDF5 1.6.x API by default" FORCE)
586587 HDF5_ENABLE_PARALLEL "Enable parallel build (requires MPI)" OFF
587588 HDF5_ENABLE_TRACE "Enable API tracing capability" OFF
588589 HDF5_ENABLE_USING_MEMCHECKER "Indicate that a memory checker is used" OFF
590 HDF5_MEMORY_ALLOC_SANITY_CHECK "Indicate that internal memory allocation sanity checks are enabled" OFF
589591 HDF5_METADATA_TRACE_FILE "Enable metadata trace file collection" OFF
590592 HDF5_NO_PACKAGES "Do not include CPack Packaging" OFF
591593 HDF5_PACKAGE_EXTLIBS "CPACK - include external libraries" OFF
0 HDF5 version 1.10.0-alpha0 released on 2015-12-29
0 HDF5 version 1.10.0-alpha1 released on 2016-01-18
11 ================================================================================
22
33
44 INTRODUCTION
55
66 This document describes the differences between HDF5-1.8.* and
7 HDF5 1.10.0-alpha0 release, and contains information on the platforms
8 tested and known problems in HDF5-1.10.0-alpha0.
7 HDF5 1.10.0-alpha1 release, and contains information on the platforms
8 tested and known problems in HDF5-1.10.0-alpha1.
99
1010
1111 Links to HDF5 1.10.0-alpha* source code can be found on The HDF Group's
2525 CONTENTS
2626
2727 - New Features
28 - Issues Addressed in this Release
2829 - Tested Configuration Features Summary
2930 - More Tested Platforms
3031 - Known Problems
3233
3334 New Features
3435 ============
35 This alpha0 release supports the following new features:
36 This alpha1 release supports the following features:
37
38 Parallel Library:
39 -----------------
40 - Collective Metadata I/O
41
42 Calls for HDF5 metadata can result in many small reads and writes. On metadata
43 reads, collective metadata I/O can improve performance by allowing the library
44 to perform optimizations when reading the metadata, by having one rank read the
45 data and broadcasting it to all other ranks.
46
47 Collective metadata I/O improves metadata write performance through the
48 construction of an MPI derived datatype that is then written collectively
49 in a single call. For more information see
50 https://www.hdfgroup.org/HDF5/docNewFeatures/NewFeaturesCollectiveMetadataIoDocs.html
3651
3752 Library:
3853 --------
4055
4156 The Single Writer/ Multiple Reader or SWMR feature enables users to read
4257 data concurrently while writing it. Communications between the processes
43 and file locking are not required. The processes can run on the same or on different platforms,
44 as long as they share a common file system that is POSIX compliant.
45 For more information, see the Single-Writer/Multiple-Reader (SWMR) Documentation at
58 and file locking are not required. The processes can run on the same or
59 on different platforms, as long as they share a common file system that
60 is POSIX compliant.
61 For more information, see the Single-Writer/Multiple-Reader (SWMR)
62 Documentation at
4663 https://www.hdfgroup.org/HDF5/docNewFeatures/NewFeaturesSwmrDocs.html
4764
4865 - Virtual Dataset (VDS)
4966
50 The VDS feature enables data to be accessed across HDF5 files using standard HDF5 objects
51 such as groups and datasets without rewriting or rearranging the data. An HDF5 virtual
52 dataset (VDS) is an HDF5 dataset that is composed of source HDF5 datasets in a predefined
53 mapping. VDS can be used with the SWMR feature. For documentation check
67 The VDS feature enables data to be accessed across HDF5 files using standard
68 HDF5 objects such as groups and datasets without rewriting or rearranging
69 the data. An HDF5 virtual dataset (VDS) is an HDF5 dataset that is composed of
70 source HDF5 datasets in a predefined mapping. VDS can be used with the SWMR
71 feature. For documentation check
5472 https://www.hdfgroup.org/HDF5/docNewFeatures/NewFeaturesSwmrDocs.html
5573
5674 - Persistent Free File Space Tracking
5775
58 Usage patterns when working with an HDF5 file sometimes result in wasted space within
59 the file. This can also impair access times when working with the resulting files.
60 The new file space management feature provides strategies for managing space in a file
61 to improve performance in both of these areas. For more information see
76 Usage patterns when working with an HDF5 file sometimes result in wasted space
77 within the file. This can also impair access times when working with the
78 resulting files. The new file space management feature provides strategies
79 for managing space in a file to improve performance in both of these areas.
80 For more information see
6281 http://www.hdfgroup.org/HDF5/docNewFeatures/NewFeaturesFileSpaceMgmtDocs.html
6382
6483
6685 ------
6786 - h5watch
6887
69 Allows users to output new records appended to a dataset iunder SWMR access as it grows.
70 The functionality is similar to the Unix user command "tail" with the follow option, which
71 outputs appended data as the file grows.
88 Allows users to output new records appended to a dataset iunder SWMR access
89 as it grows. The functionality is similar to the Unix user command "tail"
90 with the follow option, which outputs appended data as the file grows.
7291 For more information see
7392 http://www.hdfgroup.org/HDF5/docNewFeatures/NewFeaturesSwmrDocs.html#Tools
7493
7594 - h5format_convert
7695
77 The tool allows users to convert the indexing type of a chunked dataset made with
78 a 1.10.x version of the HDF5 library when the latest file format is used to the 1.8.x
79 version 1 B-tree indexing type. For example, datasets created using SWMR access, can be converted
80 to be accessed by the HDF5 1.18 library and tools. The tools doesn't rewrite raw data, but
81 HDF5 metadata only.
96 The tool allows users to convert the indexing type of a chunked dataset made
97 with a 1.10.x version of the HDF5 library when the latest file format is used
98 to the 1.8.x version 1 B-tree indexing type. For example, datasets created
99 using SWMR access, can be converted to be accessed by the HDF5 1.18 library
100 and tools. The tools doesn't rewrite raw data, but HDF5 metadata only.
82101
83102 High-Level APIs:
84103 ------
95114 -------------
96115 See http://www.hdfgroup.org/HDF5/docNewFeatures/NewFeaturesSwmrDocs.html#Tools
97116
98
117 Issues Addressed in this Release
118 ================================
119 - h5format_convert tool didn't downgrade version of the superblock. Fixed. See
120 Known Problems section. EIP 2016-01-11.
121
122 - It was reported that alpha0 crashed when used with multiple threads.
123 The issue exists in the HDF5 library versions 1.8 and 1.9.
124 The problem is related to a shared file pointer used in the misc. data
125 structures. The thread-safe library exposed paths in the library where
126 file pointer becomes invalid. Alpha1 release contains the fixes for the specific
127 use case as decribed in HDFFV-9643.
128 We will keep working on identifying other paths in the library with similar problem
129 and fixing the issue. EIP 2016-01-15
99130
100131 Supported Platforms
101132 ===================
274305 WARNINGS: This section is under contsruction. It will be updated for the first HDF5 1.10.0-beta
275306 release.
276307
277
308 - h5format_convert only works with the files that contain chunked datasets.
309 - h5repack tool fails to downgrade object layout message to make file
310 1.8 compatible.
311
394394 H5_debug_g.open_stream = H5_debug_g.open_stream->next;
395395 (void)H5MM_free(tmp_open_stream);
396396 } /* end while */
397
398 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
399 /* Sanity check memory allocations */
400 H5MM_final_sanity_check();
401 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
397402
398403 /* Reset flag indicating that the library is being shut down */
399404 H5_TERM_GLOBAL = FALSE;
245245 --------------------------------------------------------------------------*/
246246 hid_t
247247 H5Acreate2(hid_t loc_id, const char *attr_name, hid_t type_id, hid_t space_id,
248 hid_t acpl_id, hid_t H5_ATTR_UNUSED aapl_id)
248 hid_t acpl_id, hid_t aapl_id)
249249 {
250250 H5A_t *attr = NULL; /* Attribute created */
251251 H5G_loc_t loc; /* Object location */
252252 H5T_t *type; /* Datatype to use for attribute */
253253 H5S_t *space; /* Dataspace to use for attribute */
254 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
254255 hid_t ret_value; /* Return value */
255256
256257 FUNC_ENTER_API(FAIL)
270271 if(NULL == (space = (H5S_t *)H5I_object_verify(space_id, H5I_DATASPACE)))
271272 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a data space")
272273
273 /* Go do the real work for attaching the attribute to the dataset */
274 if(NULL == (attr = H5A_create(&loc, attr_name, type, space, acpl_id, H5AC_dxpl_id)))
274 /* Verify access property list and get correct dxpl */
275 if(H5P_verify_and_set_dxpl(&aapl_id, H5P_ATTRIBUTE_ACCESS, H5P_ATTRIBUTE_ACCESS_DEFAULT,
276 &dxpl_id) < 0)
277 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
278
279 /* Go do the real work for attaching the attribute to the object */
280 if(NULL == (attr = H5A_create(&loc, attr_name, type, space, acpl_id, dxpl_id)))
275281 HGOTO_ERROR(H5E_ATTR, H5E_CANTINIT, FAIL, "unable to create attribute")
276282
277283 /* Register the new attribute and get an ID for it */
319325 --------------------------------------------------------------------------*/
320326 hid_t
321327 H5Acreate_by_name(hid_t loc_id, const char *obj_name, const char *attr_name,
322 hid_t type_id, hid_t space_id, hid_t acpl_id, hid_t H5_ATTR_UNUSED aapl_id,
328 hid_t type_id, hid_t space_id, hid_t acpl_id, hid_t aapl_id,
323329 hid_t lapl_id)
324330 {
325331 H5A_t *attr = NULL; /* Attribute created */
330336 hbool_t loc_found = FALSE; /* Entry at 'obj_name' found */
331337 H5T_t *type; /* Datatype to use for attribute */
332338 H5S_t *space; /* Dataspace to use for attribute */
339 hid_t dxpl_id; /* dxpl used by library */
333340 hid_t ret_value; /* Return value */
334341
335342 FUNC_ENTER_API(FAIL)
357364 obj_loc.path = &obj_path;
358365 H5G_loc_reset(&obj_loc);
359366
367 dxpl_id = H5AC_ind_dxpl_id;
368 /* Verify access property list and get correct dxpl */
369 if(H5P_verify_and_set_dxpl(&aapl_id, H5P_ATTRIBUTE_ACCESS, H5P_ATTRIBUTE_ACCESS_DEFAULT,
370 &dxpl_id) < 0)
371 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
372
360373 /* Find the object's location */
361 if(H5G_loc_find(&loc, obj_name, &obj_loc/*out*/, lapl_id, H5AC_ind_dxpl_id) < 0)
374 if(H5G_loc_find(&loc, obj_name, &obj_loc/*out*/, lapl_id, dxpl_id) < 0)
362375 HGOTO_ERROR(H5E_ATTR, H5E_NOTFOUND, FAIL, "object not found")
363376 loc_found = TRUE;
364377
378 dxpl_id = H5AC_dxpl_id;
379 /* Verify access property list and get correct dxpl */
380 if(H5P_verify_and_set_dxpl(&aapl_id, H5P_ATTRIBUTE_ACCESS, H5P_ATTRIBUTE_ACCESS_DEFAULT,
381 &dxpl_id) < 0)
382 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
383
365384 /* Go do the real work for attaching the attribute to the dataset */
366 if(NULL == (attr = H5A_create(&obj_loc, attr_name, type, space, acpl_id, H5AC_dxpl_id)))
385 if(NULL == (attr = H5A_create(&obj_loc, attr_name, type, space, acpl_id, dxpl_id)))
367386 HGOTO_ERROR(H5E_ATTR, H5E_CANTINIT, FAIL, "unable to create attribute")
368387
369388 /* Register the new attribute and get an ID for it */
400419 H5Aclose or resource leaks will develop.
401420 --------------------------------------------------------------------------*/
402421 hid_t
403 H5Aopen(hid_t loc_id, const char *attr_name, hid_t H5_ATTR_UNUSED aapl_id)
422 H5Aopen(hid_t loc_id, const char *attr_name, hid_t aapl_id)
404423 {
405424 H5G_loc_t loc; /* Object location */
406425 H5A_t *attr = NULL; /* Attribute opened */
426 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
407427 hid_t ret_value;
408428
409429 FUNC_ENTER_API(FAIL)
417437 if(!attr_name || !*attr_name)
418438 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no attribute name")
419439
440 /* Verify access property list and get correct dxpl */
441 if(H5P_verify_and_set_dxpl(&aapl_id, H5P_ATTRIBUTE_ACCESS, H5P_ATTRIBUTE_ACCESS_DEFAULT,
442 &dxpl_id) < 0)
443 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
444
420445 /* Read in attribute from object header */
421 if(NULL == (attr = H5O_attr_open_by_name(loc.oloc, attr_name, H5AC_ind_dxpl_id)))
446 if(NULL == (attr = H5O_attr_open_by_name(loc.oloc, attr_name, dxpl_id)))
422447 HGOTO_ERROR(H5E_ATTR, H5E_CANTINIT, FAIL, "unable to load attribute info from object header for attribute: '%s'", attr_name)
423448
424449 /* Finish initializing attribute */
462487 --------------------------------------------------------------------------*/
463488 hid_t
464489 H5Aopen_by_name(hid_t loc_id, const char *obj_name, const char *attr_name,
465 hid_t H5_ATTR_UNUSED aapl_id, hid_t lapl_id)
490 hid_t aapl_id, hid_t lapl_id)
466491 {
467492 H5G_loc_t loc; /* Object location */
468493 H5A_t *attr = NULL; /* Attribute opened */
494 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
469495 hid_t ret_value;
470496
471497 FUNC_ENTER_API(FAIL)
486512 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
487513 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
488514
515 /* Verify access property list and get correct dxpl */
516 if(H5P_verify_and_set_dxpl(&aapl_id, H5P_ATTRIBUTE_ACCESS, H5P_ATTRIBUTE_ACCESS_DEFAULT,
517 &dxpl_id) < 0)
518 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
519
489520 /* Open the attribute on the object header */
490 if(NULL == (attr = H5A_open_by_name(&loc, obj_name, attr_name, lapl_id, H5AC_ind_dxpl_id)))
521 if(NULL == (attr = H5A_open_by_name(&loc, obj_name, attr_name, lapl_id, dxpl_id)))
491522 HGOTO_ERROR(H5E_ATTR, H5E_CANTOPENOBJ, FAIL, "can't open attribute")
492523
493524 /* Register the attribute and get an ID for it */
530561 --------------------------------------------------------------------------*/
531562 hid_t
532563 H5Aopen_by_idx(hid_t loc_id, const char *obj_name, H5_index_t idx_type,
533 H5_iter_order_t order, hsize_t n, hid_t H5_ATTR_UNUSED aapl_id, hid_t lapl_id)
564 H5_iter_order_t order, hsize_t n, hid_t aapl_id, hid_t lapl_id)
534565 {
535566 H5A_t *attr = NULL; /* Attribute opened */
536567 H5G_loc_t loc; /* Object location */
568 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
537569 hid_t ret_value; /* Return value */
538570
539571 FUNC_ENTER_API(FAIL)
557589 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
558590 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
559591
592 /* Verify access property list and get correct dxpl */
593 if(H5P_verify_and_set_dxpl(&aapl_id, H5P_ATTRIBUTE_ACCESS, H5P_ATTRIBUTE_ACCESS_DEFAULT,
594 &dxpl_id) < 0)
595 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
596
560597 /* Open the attribute in the object header */
561 if(NULL == (attr = H5A_open_by_idx(&loc, obj_name, idx_type, order, n, lapl_id, H5AC_ind_dxpl_id)))
598 if(NULL == (attr = H5A_open_by_idx(&loc, obj_name, idx_type, order, n, lapl_id, dxpl_id)))
562599 HGOTO_ERROR(H5E_ATTR, H5E_CANTOPENOBJ, FAIL, "unable to open attribute")
563600
564601 /* Register the attribute and get an ID for it */
866903 {
867904 H5G_loc_t loc; /* Object location */
868905 H5A_t *attr = NULL; /* Attribute object for name */
906 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
869907 ssize_t ret_value; /* Return value */
870908
871909 FUNC_ENTER_API(FAIL)
883921 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid index type specified")
884922 if(order <= H5_ITER_UNKNOWN || order >= H5_ITER_N)
885923 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
886 if(H5P_DEFAULT == lapl_id)
887 lapl_id = H5P_LINK_ACCESS_DEFAULT;
888 else
889 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
890 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
924
925 /* Verify access property list and get correct dxpl */
926 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
927 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
891928
892929 /* Open the attribute on the object header */
893 if(NULL == (attr = H5A_open_by_idx(&loc, obj_name, idx_type, order, n, lapl_id, H5AC_ind_dxpl_id)))
930 if(NULL == (attr = H5A_open_by_idx(&loc, obj_name, idx_type, order, n, lapl_id, dxpl_id)))
894931 HGOTO_ERROR(H5E_ATTR, H5E_CANTOPENOBJ, FAIL, "can't open attribute")
895932
896933 /* Get the length of the name */
10041041 {
10051042 H5G_loc_t loc; /* Object location */
10061043 H5A_t *attr = NULL; /* Attribute object for name */
1044 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
10071045 herr_t ret_value = SUCCEED; /* Return value */
10081046
10091047 FUNC_ENTER_API(FAIL)
10201058 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no attribute name")
10211059 if(NULL == ainfo)
10221060 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid info pointer")
1023 if(H5P_DEFAULT == lapl_id)
1024 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1025 else
1026 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1027 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1061
1062 /* Verify access property list and get correct dxpl */
1063 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1064 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
10281065
10291066 /* Open the attribute on the object header */
1030 if(NULL == (attr = H5A_open_by_name(&loc, obj_name, attr_name, lapl_id, H5AC_ind_dxpl_id)))
1067 if(NULL == (attr = H5A_open_by_name(&loc, obj_name, attr_name, lapl_id, dxpl_id)))
10311068 HGOTO_ERROR(H5E_ATTR, H5E_CANTOPENOBJ, FAIL, "can't open attribute")
10321069
10331070 /* Get the attribute information */
10631100 {
10641101 H5G_loc_t loc; /* Object location */
10651102 H5A_t *attr = NULL; /* Attribute object for name */
1103 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
10661104 herr_t ret_value = SUCCEED; /* Return value */
10671105
10681106 FUNC_ENTER_API(FAIL)
10821120 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
10831121 if(NULL == ainfo)
10841122 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid info pointer")
1085 if(H5P_DEFAULT == lapl_id)
1086 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1087 else
1088 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1089 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1123
1124 /* Verify access property list and get correct dxpl */
1125 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1126 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
10901127
10911128 /* Open the attribute on the object header */
1092 if(NULL == (attr = H5A_open_by_idx(&loc, obj_name, idx_type, order, n, lapl_id, H5AC_ind_dxpl_id)))
1129 if(NULL == (attr = H5A_open_by_idx(&loc, obj_name, idx_type, order, n, lapl_id, dxpl_id)))
10931130 HGOTO_ERROR(H5E_ATTR, H5E_CANTOPENOBJ, FAIL, "can't open attribute")
10941131
10951132 /* Get the attribute information */
11661203 H5Arename_by_name(hid_t loc_id, const char *obj_name, const char *old_attr_name,
11671204 const char *new_attr_name, hid_t lapl_id)
11681205 {
1206 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by the library */
11691207 herr_t ret_value = SUCCEED; /* Return value */
11701208
11711209 FUNC_ENTER_API(FAIL)
11811219 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no old attribute name")
11821220 if(!new_attr_name || !*new_attr_name)
11831221 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no new attribute name")
1184 if(H5P_DEFAULT == lapl_id)
1185 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1186 else
1187 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1188 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1222
1223 /* Verify access property list and get correct dxpl */
1224 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1225 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
11891226
11901227 /* Avoid thrashing things if the names are the same */
11911228 if(HDstrcmp(old_attr_name, new_attr_name)) {
11951232 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a location")
11961233
11971234 /* Call private attribute rename routine */
1198 if(H5A_rename_by_name(loc, obj_name, old_attr_name, new_attr_name, lapl_id, H5AC_dxpl_id) < 0)
1235 if(H5A_rename_by_name(loc, obj_name, old_attr_name, new_attr_name, lapl_id, dxpl_id) < 0)
11991236 HGOTO_ERROR(H5E_ATTR, H5E_CANTRENAME, FAIL, "can't rename attribute")
12001237 } /* end if */
12011238
13401377 H5A_attr_iter_op_t attr_op; /* Attribute operator */
13411378 hsize_t start_idx; /* Index of attribute to start iterating at */
13421379 hsize_t last_attr; /* Index of last attribute examined */
1380 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
13431381 herr_t ret_value; /* Return value */
13441382
13451383 FUNC_ENTER_API(FAIL)
13571395 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid index type specified")
13581396 if(order <= H5_ITER_UNKNOWN || order >= H5_ITER_N)
13591397 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
1360 if(H5P_DEFAULT == lapl_id)
1361 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1362 else
1363 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1364 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1398
1399 /* Verify access property list and get correct dxpl */
1400 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1401 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
13651402
13661403 /* Set up opened group location to fill in */
13671404 obj_loc.oloc = &obj_oloc;
13691406 H5G_loc_reset(&obj_loc);
13701407
13711408 /* Find the object's location */
1372 if(H5G_loc_find(&loc, obj_name, &obj_loc/*out*/, lapl_id, H5AC_ind_dxpl_id) < 0)
1409 if(H5G_loc_find(&loc, obj_name, &obj_loc/*out*/, lapl_id, dxpl_id) < 0)
13731410 HGOTO_ERROR(H5E_ATTR, H5E_NOTFOUND, FAIL, "object not found")
13741411 loc_found = TRUE;
13751412
13761413 /* Open the object */
1377 if((obj_loc_id = H5O_open_by_loc(&obj_loc, lapl_id, H5AC_ind_dxpl_id, TRUE)) < 0)
1414 if((obj_loc_id = H5O_open_by_loc(&obj_loc, lapl_id, dxpl_id, TRUE)) < 0)
13781415 HGOTO_ERROR(H5E_ATTR, H5E_CANTOPENOBJ, FAIL, "unable to open object")
13791416
13801417 /* Build attribute operator info */
13831420
13841421 /* Call attribute iteration routine */
13851422 last_attr = start_idx = (idx ? *idx : 0);
1386 if((ret_value = H5O_attr_iterate(obj_loc_id, H5AC_ind_dxpl_id, idx_type, order, start_idx, &last_attr, &attr_op, op_data)) < 0)
1423 if((ret_value = H5O_attr_iterate(obj_loc_id, dxpl_id, idx_type, order, start_idx, &last_attr, &attr_op, op_data)) < 0)
13871424 HERROR(H5E_ATTR, H5E_BADITER, "error iterating over attributes");
13881425
13891426 /* Set the last attribute information */
14681505 H5G_name_t obj_path; /* Opened object group hier. path */
14691506 H5O_loc_t obj_oloc; /* Opened object object location */
14701507 hbool_t loc_found = FALSE; /* Entry at 'obj_name' found */
1508 hid_t dxpl_id; /* dxpl used by library */
14711509 herr_t ret_value = SUCCEED; /* Return value */
14721510
14731511 FUNC_ENTER_API(FAIL)
14821520 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no object name")
14831521 if(!attr_name || !*attr_name)
14841522 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no attribute name")
1485 if(H5P_DEFAULT == lapl_id)
1486 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1487 else
1488 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1489 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1523
1524 dxpl_id = H5AC_ind_dxpl_id;
1525 /* Verify access property list and get correct dxpl */
1526 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1527 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
14901528
14911529 /* Set up opened group location to fill in */
14921530 obj_loc.oloc = &obj_oloc;
14941532 H5G_loc_reset(&obj_loc);
14951533
14961534 /* Find the object's location */
1497 if(H5G_loc_find(&loc, obj_name, &obj_loc/*out*/, lapl_id, H5AC_ind_dxpl_id) < 0)
1535 if(H5G_loc_find(&loc, obj_name, &obj_loc/*out*/, lapl_id, dxpl_id) < 0)
14981536 HGOTO_ERROR(H5E_ATTR, H5E_NOTFOUND, FAIL, "object not found")
14991537 loc_found = TRUE;
15001538
1539 dxpl_id = H5AC_dxpl_id;
1540 /* Verify access property list and get correct dxpl */
1541 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1542 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
1543
15011544 /* Delete the attribute from the location */
1502 if(H5O_attr_remove(obj_loc.oloc, attr_name, H5AC_dxpl_id) < 0)
1545 if(H5O_attr_remove(obj_loc.oloc, attr_name, dxpl_id) < 0)
15031546 HGOTO_ERROR(H5E_ATTR, H5E_CANTDELETE, FAIL, "unable to delete attribute")
15041547
15051548 done:
15441587 H5G_name_t obj_path; /* Opened object group hier. path */
15451588 H5O_loc_t obj_oloc; /* Opened object object location */
15461589 hbool_t loc_found = FALSE; /* Entry at 'obj_name' found */
1590 hid_t dxpl_id; /* dxpl used by library */
15471591 herr_t ret_value = SUCCEED; /* Return value */
15481592
15491593 FUNC_ENTER_API(FAIL)
15601604 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid index type specified")
15611605 if(order <= H5_ITER_UNKNOWN || order >= H5_ITER_N)
15621606 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
1563 if(H5P_DEFAULT == lapl_id)
1564 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1565 else
1566 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1567 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1607
1608 dxpl_id = H5AC_ind_dxpl_id;
1609 /* Verify access property list and get correct dxpl */
1610 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1611 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
15681612
15691613 /* Set up opened group location to fill in */
15701614 obj_loc.oloc = &obj_oloc;
15721616 H5G_loc_reset(&obj_loc);
15731617
15741618 /* Find the object's location */
1575 if(H5G_loc_find(&loc, obj_name, &obj_loc/*out*/, lapl_id, H5AC_ind_dxpl_id) < 0)
1619 if(H5G_loc_find(&loc, obj_name, &obj_loc/*out*/, lapl_id, dxpl_id) < 0)
15761620 HGOTO_ERROR(H5E_ATTR, H5E_NOTFOUND, FAIL, "object not found")
15771621 loc_found = TRUE;
15781622
1623 dxpl_id = H5AC_dxpl_id;
1624 /* Verify access property list and get correct dxpl */
1625 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1626 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
1627
15791628 /* Delete the attribute from the location */
1580 if(H5O_attr_remove_by_idx(obj_loc.oloc, idx_type, order, n, H5AC_dxpl_id) < 0)
1629 if(H5O_attr_remove_by_idx(obj_loc.oloc, idx_type, order, n, dxpl_id) < 0)
15811630 HGOTO_ERROR(H5E_ATTR, H5E_CANTDELETE, FAIL, "unable to delete attribute")
15821631
15831632 done:
16831732 hid_t lapl_id)
16841733 {
16851734 H5G_loc_t loc; /* Object location */
1735 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
16861736 htri_t ret_value; /* Return value */
16871737
16881738 FUNC_ENTER_API(FAIL)
16971747 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no object name")
16981748 if(!attr_name || !*attr_name)
16991749 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no attribute name")
1700 if(H5P_DEFAULT == lapl_id)
1701 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1702 else
1703 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1704 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1705
1706 if((ret_value = H5A_exists_by_name(loc, obj_name, attr_name, lapl_id, H5AC_ind_dxpl_id)) < 0)
1750
1751 /* Verify access property list and get correct dxpl */
1752 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1753 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
1754
1755 if((ret_value = H5A_exists_by_name(loc, obj_name, attr_name, lapl_id, dxpl_id)) < 0)
17071756 HGOTO_ERROR(H5E_ATTR, H5E_CANTGET, FAIL, "unable to determine if attribute exists")
17081757
17091758 done:
8585 /*****************************/
8686
8787 /* Default dataset transfer property list for metadata I/O calls */
88 /* (Collective set, "block before metadata write" set and "library internal" set) */
88 /* (Collective set) */
8989 /* (Global variable definition, declaration is in H5ACprivate.h also) */
9090 hid_t H5AC_dxpl_id = (-1);
9191
9292 /* Dataset transfer property list for independent metadata I/O calls */
93 /* (just "library internal" set - i.e. independent transfer mode) */
9493 /* (Global variable definition, declaration is in H5ACprivate.h also) */
9594 H5P_genplist_t *H5AC_ind_dxpl_g = NULL;
9695 hid_t H5AC_ind_dxpl_id = (-1);
9796
97 hid_t H5AC_coll_write_coll_read_dxpl_id=(-1);
98 hid_t H5AC_ind_write_coll_read_dxpl_id=(-1);
9899
99100 /*******************/
100101 /* Local Variables */
179180 #ifdef H5_HAVE_PARALLEL
180181 H5P_genplist_t *xfer_plist; /* Dataset transfer property list object */
181182 unsigned coll_meta_write; /* "collective metadata write" property value */
183 H5P_coll_md_read_flag_t coll_meta_read;
182184 #endif /* H5_HAVE_PARALLEL */
183185 herr_t ret_value = SUCCEED; /* Return value */
184186
193195 HGOTO_ERROR(H5E_CACHE, H5E_CANTCREATE, FAIL, "unable to register property list")
194196
195197 /* Get the property list object */
196 if (NULL == (xfer_plist = (H5P_genplist_t *)H5I_object(H5AC_dxpl_id)))
198 if(NULL == (xfer_plist = (H5P_genplist_t *)H5I_object(H5AC_dxpl_id)))
197199 HGOTO_ERROR(H5E_CACHE, H5E_BADATOM, FAIL, "can't get new property list object")
198200
199201 /* Insert 'collective metadata write' property */
215217 if(H5P_insert(H5AC_ind_dxpl_g, H5AC_COLLECTIVE_META_WRITE_NAME, H5AC_COLLECTIVE_META_WRITE_SIZE, &coll_meta_write,
216218 NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL) < 0)
217219 HGOTO_ERROR(H5E_CACHE, H5E_CANTSET, FAIL, "can't insert metadata cache dxpl property")
220
221 /* Get an ID for H5AC_coll_write_coll_read_dxpl_id */
222 if((H5AC_coll_write_coll_read_dxpl_id = H5P_create_id(H5P_CLS_DATASET_XFER_g, FALSE)) < 0)
223 HGOTO_ERROR(H5E_CACHE, H5E_CANTCREATE, FAIL, "unable to register property list")
224
225 /* Get the property list object */
226 if (NULL == (xfer_plist = (H5P_genplist_t *)H5I_object(H5AC_coll_write_coll_read_dxpl_id)))
227 HGOTO_ERROR(H5E_CACHE, H5E_BADATOM, FAIL, "can't get new property list object")
228
229 /* Insert 'collective metadata write' property */
230 coll_meta_write = 1;
231 if(H5P_insert(xfer_plist, H5AC_COLLECTIVE_META_WRITE_NAME, H5AC_COLLECTIVE_META_WRITE_SIZE, &coll_meta_write,
232 NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL) < 0)
233 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't insert metadata cache dxpl property")
234
235 /* set 'collective metadata read' property */
236 coll_meta_read = H5P_USER_TRUE;
237 if(H5P_set(xfer_plist, H5_COLL_MD_READ_FLAG_NAME, &coll_meta_read) < 0)
238 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set collective metadata read flag")
239
240
241 /* Get an ID for H5AC_ind_write_coll_read_dxpl_id */
242 if((H5AC_ind_write_coll_read_dxpl_id = H5P_create_id(H5P_CLS_DATASET_XFER_g, FALSE)) < 0)
243 HGOTO_ERROR(H5E_CACHE, H5E_CANTCREATE, FAIL, "unable to register property list")
244
245 /* Get the property list object */
246 if (NULL == (xfer_plist = (H5P_genplist_t *)H5I_object(H5AC_ind_write_coll_read_dxpl_id)))
247 HGOTO_ERROR(H5E_CACHE, H5E_BADATOM, FAIL, "can't get new property list object")
248
249 /* Insert 'collective metadata write' property */
250 coll_meta_write = 0;
251 if(H5P_insert(xfer_plist, H5AC_COLLECTIVE_META_WRITE_NAME, H5AC_COLLECTIVE_META_WRITE_SIZE, &coll_meta_write,
252 NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL) < 0)
253 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't insert metadata cache dxpl property")
254 /* set 'collective metadata read' property */
255 coll_meta_read = H5P_USER_TRUE;
256 if(H5P_set(xfer_plist, H5_COLL_MD_READ_FLAG_NAME, &coll_meta_read) < 0)
257 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set collective metadata read flag")
258
218259 #else /* H5_HAVE_PARALLEL */
219260 /* Sanity check */
220261 HDassert(H5P_LST_DATASET_XFER_ID_g!=(-1));
221262
222263 H5AC_dxpl_id = H5P_DATASET_XFER_DEFAULT;
223264 H5AC_ind_dxpl_id = H5P_DATASET_XFER_DEFAULT;
265 H5AC_coll_write_coll_read_dxpl_id = H5P_DATASET_XFER_DEFAULT;
266 H5AC_ind_write_coll_read_dxpl_id = H5P_DATASET_XFER_DEFAULT;
224267
225268 /* Get the property list objects for the IDs */
226269 if(NULL == (H5AC_ind_dxpl_g = (H5P_genplist_t *)H5I_object(H5AC_ind_dxpl_id)))
255298
256299 if(H5_PKG_INIT_VAR) {
257300 #ifdef H5_HAVE_PARALLEL
258 if(H5AC_dxpl_id > 0 || H5AC_ind_dxpl_id > 0) {
301 if(H5AC_dxpl_id > 0 || H5AC_ind_dxpl_id > 0 ||
302 H5AC_coll_write_coll_read_dxpl_id > 0 ||
303 H5AC_ind_write_coll_read_dxpl_id > 0) {
259304 /* Indicate more work to do */
260305 n = 1; /* H5I */
261306
262307 /* Close H5AC dxpl */
263 if(H5I_dec_ref(H5AC_dxpl_id) < 0 || H5I_dec_ref(H5AC_ind_dxpl_id) < 0)
308 if(H5I_dec_ref(H5AC_dxpl_id) < 0 || H5I_dec_ref(H5AC_ind_dxpl_id) < 0 ||
309 H5I_dec_ref(H5AC_coll_write_coll_read_dxpl_id) < 0 ||
310 H5I_dec_ref(H5AC_ind_write_coll_read_dxpl_id) < 0)
264311 H5E_clear_stack(NULL); /*ignore error*/
265312 } /* end if */
266313 #endif /* H5_HAVE_PARALLEL */
267
314
268315 /* Reset static IDs */
269316 H5AC_dxpl_id = (-1);
270317 H5AC_ind_dxpl_id = (-1);
318 #ifdef H5_HAVE_PARALLEL
319 H5AC_coll_write_coll_read_dxpl_id = (-1);
320 H5AC_ind_write_coll_read_dxpl_id = (-1);
321 #endif /* H5_HAVE_PARALLEL */
271322
272323 /* Reset interface initialization flag */
273324 if(0 == n)
495546 } /* end if */
496547
497548 #ifdef H5_HAVE_PARALLEL
498 aux_ptr = H5C_get_aux_ptr(f->shared->cache);
549 /* destroying the cache, so clear all collective entries */
550 if(H5C_clear_coll_entries(f->shared->cache, 0) < 0)
551 HGOTO_ERROR(H5E_CACHE, H5E_CANTGET, FAIL, "H5C_clear_coll_entries() failed.")
552
553 aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(f->shared->cache);
499554 if(aux_ptr)
500555 /* Sanity check */
501556 HDassert(aux_ptr->magic == H5AC__H5AC_AUX_T_MAGIC);
695750 #endif /* H5AC__TRACE_FILE_ENABLED */
696751
697752 #ifdef H5_HAVE_PARALLEL
753 /* flushing the cache, so clear all collective entries */
754 if(H5C_clear_coll_entries(f->shared->cache, 0) < 0)
755 HGOTO_ERROR(H5E_CACHE, H5E_CANTGET, FAIL, "H5C_clear_coll_entries() failed.")
756
698757 /* Attempt to flush all entries from rank 0 & Bcast clean list to other ranks */
699758 if(H5AC__flush_entries(f, dxpl_id) < 0)
700759 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "Can't flush.")
864923 {
865924 H5AC_aux_t *aux_ptr;
866925
867 if(NULL != (aux_ptr = H5C_get_aux_ptr(f->shared->cache))) {
926 if(NULL != (aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(f->shared->cache))) {
868927 /* Log the new entry */
869928 if(H5AC__log_inserted_entry((H5AC_info_t *)thing) < 0)
870929 HGOTO_ERROR(H5E_CACHE, H5E_CANTINS, FAIL, "H5AC__log_inserted_entry() failed")
9431002 {
9441003 H5AC_aux_t *aux_ptr;
9451004
946 aux_ptr = H5C_get_aux_ptr(cache_ptr);
1005 aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(cache_ptr);
9471006 if((!entry_ptr->is_dirty) && (!entry_ptr->is_protected) &&
9481007 (entry_ptr->is_pinned) && (NULL != aux_ptr))
9491008 if(H5AC__log_dirtied_entry(entry_ptr) < 0)
10231082
10241083 #ifdef H5_HAVE_PARALLEL
10251084 /* Log moving the entry */
1026 if(NULL != (aux_ptr = H5C_get_aux_ptr(f->shared->cache)))
1085 if(NULL != (aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(f->shared->cache)))
10271086 if(H5AC__log_moved_entry(f, old_addr, new_addr) < 0)
10281087 HGOTO_ERROR(H5E_CACHE, H5E_CANTUNPROTECT, FAIL, "can't log moved entry")
10291088 #endif /* H5_HAVE_PARALLEL */
13621421 {
13631422 H5AC_aux_t *aux_ptr;
13641423
1365 aux_ptr = H5C_get_aux_ptr(cache_ptr);
1424 aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(cache_ptr);
13661425 if((!entry_ptr->is_dirty) && (NULL != aux_ptr))
13671426 if(H5AC__log_dirtied_entry(entry_ptr) < 0)
13681427 HGOTO_ERROR(H5E_CACHE, H5E_CANTMARKDIRTY, FAIL, "can't log dirtied entry")
16221681 } /* end if */
16231682
16241683 #ifdef H5_HAVE_PARALLEL
1625 if(NULL != (aux_ptr = H5C_get_aux_ptr(f->shared->cache))) {
1684 if(NULL != (aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(f->shared->cache))) {
16261685 if(dirtied && ((H5AC_info_t *)thing)->is_dirty == FALSE)
16271686 if(H5AC__log_dirtied_entry((H5AC_info_t *)thing) < 0)
16281687 HGOTO_ERROR(H5E_CACHE, H5E_CANTUNPROTECT, FAIL, "can't log dirtied entry")
17521811 {
17531812 H5AC_aux_t *aux_ptr;
17541813
1755 aux_ptr = H5C_get_aux_ptr(cache_ptr);
1814 aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(cache_ptr);
17561815 if((aux_ptr != NULL) && (aux_ptr->magic != H5AC__H5AC_AUX_T_MAGIC))
17571816 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Bad aux_ptr on entry.")
17581817 }
17991858 {
18001859 H5AC_aux_t *aux_ptr;
18011860
1802 if(NULL != (aux_ptr = H5C_get_aux_ptr(cache_ptr))) {
1861 if(NULL != (aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(cache_ptr))) {
18031862 config_ptr->dirty_bytes_threshold = aux_ptr->dirty_bytes_threshold;
18041863 config_ptr->metadata_write_strategy = aux_ptr->metadata_write_strategy;
18051864 } /* end if */
19472006 {
19482007 H5AC_aux_t *aux_ptr;
19492008
1950 aux_ptr = H5C_get_aux_ptr(cache_ptr);
2009 aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(cache_ptr);
19512010 if((aux_ptr != NULL) && (aux_ptr->magic != H5AC__H5AC_AUX_T_MAGIC))
19522011 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "bad aux_ptr on entry.")
19532012 }
19912050
19922051 /* Set parallel configuration values */
19932052 /* (Which are only held in the H5AC layer -QAK) */
1994 if(NULL != (aux_ptr = H5C_get_aux_ptr(cache_ptr))) {
2053 if(NULL != (aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(cache_ptr))) {
19952054 aux_ptr->dirty_bytes_threshold = config_ptr->dirty_bytes_threshold;
19962055 aux_ptr->metadata_write_strategy = config_ptr->metadata_write_strategy;
19972056 } /* end if */
22112270 {
22122271 H5AC_aux_t * aux_ptr;
22132272
2214 aux_ptr = H5C_get_aux_ptr(cache_ptr);
2273 aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(cache_ptr);
22152274 if(aux_ptr == NULL)
22162275 sprintf(file_name, "%s", trace_file_name);
22172276 else {
23922451 HDassert(f != NULL);
23932452 HDassert(f->shared != NULL);
23942453 HDassert(f->shared->cache != NULL);
2395 aux_ptr = H5C_get_aux_ptr(f->shared->cache);
2454 aux_ptr = (H5AC_aux_t *)H5C_get_aux_ptr(f->shared->cache);
23962455 if(aux_ptr != NULL) {
23972456 HDassert(aux_ptr->magic == H5AC__H5AC_AUX_T_MAGIC);
23982457
115115 \"messages\":\n\
116116 [\n\
117117 "
118 , (long long)time(NULL));
118 , (long long)HDtime(NULL));
119119
120120 /* Since we're about to override the current logging flag,
121121 * check the "log enabled" flag to see if we didn't get here
169169 \"close_time\":%lld,\n\
170170 }\n\
171171 "
172 , (long long)time(NULL));
172 , (long long)HDtime(NULL));
173173
174174 /* Since we're about to override the current logging flag,
175175 * check the "log enabled" flag to see if we didn't get here
225225 \"returned\":%d\
226226 },\n\
227227 "
228 , (long long)time(NULL), (int)fxn_ret_value);
228 , (long long)HDtime(NULL), (int)fxn_ret_value);
229229
230230 /* Write the log message to the file */
231231 if(H5C_write_log_message(cache, msg) < 0)
273273 \"returned\":%d\
274274 },\n\
275275 "
276 , (long long)time(NULL), (unsigned long)address, (int)type_id, (int)fxn_ret_value);
276 , (long long)HDtime(NULL), (unsigned long)address, (int)type_id, (int)fxn_ret_value);
277277
278278
279279 /* Write the log message to the file */
318318 \"returned\":%d\
319319 },\n\
320320 "
321 , (long long)time(NULL), (int)fxn_ret_value);
321 , (long long)HDtime(NULL), (int)fxn_ret_value);
322322
323323 /* Write the log message to the file */
324324 if(H5C_write_log_message(cache, msg) < 0)
371371 \"returned\":%d\
372372 },\n\
373373 "
374 , (long long)time(NULL), (unsigned long)address, flags, type_id,
374 , (long long)HDtime(NULL), (unsigned long)address, flags, type_id,
375375 (int)size, (int)fxn_ret_value);
376376
377377 /* Write the log message to the file */
419419 \"returned\":%d\
420420 },\n\
421421 "
422 , (long long)time(NULL), (unsigned long)entry->addr, (int)fxn_ret_value);
422 , (long long)HDtime(NULL), (unsigned long)entry->addr, (int)fxn_ret_value);
423423
424424 /* Write the log message to the file */
425425 if(H5C_write_log_message(cache, msg) < 0)
469469 \"returned\":%d\
470470 },\n\
471471 "
472 , (long long)time(NULL), (unsigned long)old_addr,
472 , (long long)HDtime(NULL), (unsigned long)old_addr,
473473 (unsigned long)new_addr, type_id, (int)fxn_ret_value);
474474
475475 /* Write the log message to the file */
517517 \"returned\":%d\
518518 },\n\
519519 "
520 , (long long)time(NULL), (unsigned long)entry->addr,
520 , (long long)HDtime(NULL), (unsigned long)entry->addr,
521521 (int)fxn_ret_value);
522522
523523 /* Write the log message to the file */
569569 \"returned\":%d\
570570 },\n\
571571 "
572 , (long long)time(NULL), (unsigned long)parent->addr,
572 , (long long)HDtime(NULL), (unsigned long)parent->addr,
573573 (unsigned long)child->addr, (int)fxn_ret_value);
574574
575575 /* Write the log message to the file */
626626 \"returned\":%d\
627627 },\n\
628628 "
629 , (long long)time(NULL), (unsigned long)entry->addr,
629 , (long long)HDtime(NULL), (unsigned long)entry->addr,
630630 rw_s, (int)entry->size, (int)fxn_ret_value);
631631
632632 /* Write the log message to the file */
676676 \"returned\":%d\
677677 },\n\
678678 "
679 , (long long)time(NULL), (unsigned long)entry->addr,
679 , (long long)HDtime(NULL), (unsigned long)entry->addr,
680680 (int)new_size, (int)fxn_ret_value);
681681
682682 /* Write the log message to the file */
724724 \"returned\":%d\
725725 },\n\
726726 "
727 , (long long)time(NULL), (unsigned long)entry->addr,
727 , (long long)HDtime(NULL), (unsigned long)entry->addr,
728728 (int)fxn_ret_value);
729729
730730 /* Write the log message to the file */
776776 \"returned\":%d\
777777 },\n\
778778 "
779 , (long long)time(NULL), (unsigned long)parent->addr,
779 , (long long)HDtime(NULL), (unsigned long)parent->addr,
780780 (unsigned long)child->addr, (int)fxn_ret_value);
781781
782782 /* Write the log message to the file */
828828 \"returned\":%d\
829829 },\n\
830830 "
831 , (long long)time(NULL), (unsigned long)entry->addr,
831 , (long long)HDtime(NULL), (unsigned long)entry->addr,
832832 type_id, flags, (int)fxn_ret_value);
833833
834834 HDsnprintf(msg, MSG_SIZE, " ");
877877 \"returned\":%d\
878878 },\n\
879879 "
880 , (long long)time(NULL), (int)fxn_ret_value);
880 , (long long)HDtime(NULL), (int)fxn_ret_value);
881881
882882
883883 /* Write the log message to the file */
215215 /* (Global variable declaration, definition is in H5AC.c) */
216216 H5_DLLVAR H5P_genplist_t *H5AC_ind_dxpl_g;
217217 H5_DLLVAR hid_t H5AC_ind_dxpl_id;
218
219 H5_DLLVAR hid_t H5AC_coll_write_coll_read_dxpl_id;
220 H5_DLLVAR hid_t H5AC_ind_write_coll_read_dxpl_id;
218221
219222
220223 /* Default cache configuration. */
4141 #include "H5private.h" /* Generic Functions */
4242 #include "H5B2pkg.h" /* v2 B-trees */
4343 #include "H5Eprivate.h" /* Error handling */
44 #include "H5MMprivate.h" /* Memory management */
4445
4546
4647 /****************/
596597 if(idx == 0) {
597598 if(H5B2_POS_LEFT == curr_pos || H5B2_POS_ROOT == curr_pos) {
598599 if(hdr->min_native_rec == NULL)
599 if(NULL == (hdr->min_native_rec = (uint8_t *)HDmalloc(hdr->cls->nrec_size)))
600 if(NULL == (hdr->min_native_rec = (uint8_t *)H5MM_malloc(hdr->cls->nrec_size)))
600601 HGOTO_ERROR(H5E_BTREE, H5E_CANTALLOC, FAIL, "memory allocation failed for v2 B-tree min record info")
601602 HDmemcpy(hdr->min_native_rec, H5B2_LEAF_NREC(leaf, hdr, idx), hdr->cls->nrec_size);
602603 } /* end if */
604605 if(idx == (unsigned)(leaf->nrec - 1)) {
605606 if(H5B2_POS_RIGHT == curr_pos || H5B2_POS_ROOT == curr_pos) {
606607 if(hdr->max_native_rec == NULL)
607 if(NULL == (hdr->max_native_rec = (uint8_t *)HDmalloc(hdr->cls->nrec_size)))
608 if(NULL == (hdr->max_native_rec = (uint8_t *)H5MM_malloc(hdr->cls->nrec_size)))
608609 HGOTO_ERROR(H5E_BTREE, H5E_CANTALLOC, FAIL, "memory allocation failed for v2 B-tree max record info")
609610 HDmemcpy(hdr->max_native_rec, H5B2_LEAF_NREC(leaf, hdr, idx), hdr->cls->nrec_size);
610611 } /* end if */
12701271 if(idx == 0) {
12711272 if(H5B2_POS_LEFT == curr_pos || H5B2_POS_ROOT == curr_pos) {
12721273 if(hdr->min_native_rec == NULL)
1273 if(NULL == (hdr->min_native_rec = (uint8_t *)HDmalloc(hdr->cls->nrec_size)))
1274 if(NULL == (hdr->min_native_rec = (uint8_t *)H5MM_malloc(hdr->cls->nrec_size)))
12741275 HGOTO_ERROR(H5E_BTREE, H5E_CANTALLOC, FAIL, "memory allocation failed for v2 B-tree min record info")
12751276 HDmemcpy(hdr->min_native_rec, H5B2_LEAF_NREC(leaf, hdr, idx), hdr->cls->nrec_size);
12761277 } /* end if */
12781279 if(idx == (unsigned)(leaf->nrec - 1)) {
12791280 if(H5B2_POS_RIGHT == curr_pos || H5B2_POS_ROOT == curr_pos) {
12801281 if(hdr->max_native_rec == NULL)
1281 if(NULL == (hdr->max_native_rec = (uint8_t *)HDmalloc(hdr->cls->nrec_size)))
1282 if(NULL == (hdr->max_native_rec = (uint8_t *)H5MM_malloc(hdr->cls->nrec_size)))
12821283 HGOTO_ERROR(H5E_BTREE, H5E_CANTALLOC, FAIL, "memory allocation failed for v2 B-tree max record info")
12831284 HDmemcpy(hdr->max_native_rec, H5B2_LEAF_NREC(leaf, hdr, idx), hdr->cls->nrec_size);
12841285 } /* end if */
15361537 FUNC_LEAVE_NOAPI(ret_value)
15371538 } /* end H5B2_depend() */
15381539
1540 /*-------------------------------------------------------------------------
1541 * Function: H5B2_patch_file
1542 *
1543 * Purpose: Patch the top-level file pointer contained in bt2
1544 * to point to idx_info->f if they are different.
1545 * This is possible because the file pointer in bt2 can be
1546 * closed out if bt2 remains open.
1547 *
1548 * Return: SUCCEED
1549 *
1550 *-------------------------------------------------------------------------
1551 */
1552 herr_t
1553 H5B2_patch_file(H5B2_t *bt2, H5F_t *f)
1554 {
1555 FUNC_ENTER_NOAPI_NOINIT_NOERR
1556
1557 #ifdef QAK
1558 HDfprintf(stderr, "%s: Called\n", FUNC);
1559 #endif /* QAK */
1560
1561 /*
1562 * Check arguments.
1563 */
1564 HDassert(bt2);
1565 HDassert(f);
1566
1567 if(bt2->f != f || bt2->hdr->f != f)
1568 bt2->f = bt2->hdr->f = f;
1569
1570 FUNC_LEAVE_NOAPI(SUCCEED)
1571 } /* H5B2_patch_file() */
3737 #include "H5B2pkg.h" /* v2 B-trees */
3838 #include "H5Eprivate.h" /* Error handling */
3939 #include "H5MFprivate.h" /* File memory management */
40 #include "H5VMprivate.h" /* Vectors and arrays */
40 #include "H5MMprivate.h" /* Memory management */
41 #include "H5VMprivate.h" /* Vectors and arrays */
4142
4243 /****************/
4344 /* Local Macros */
629630 } /* end if */
630631
631632 /* Release the min & max record info, if set */
632 if(hdr->min_native_rec) {
633 HDfree(hdr->min_native_rec);
634 hdr->min_native_rec = NULL;
635 } /* end if */
636 if(hdr->max_native_rec) {
637 HDfree(hdr->max_native_rec);
638 hdr->max_native_rec = NULL;
639 } /* end if */
633 if(hdr->min_native_rec)
634 hdr->min_native_rec = H5MM_xfree(hdr->min_native_rec);
635 if(hdr->max_native_rec)
636 hdr->max_native_rec = H5MM_xfree(hdr->max_native_rec);
640637
641638 /* Free B-tree header info */
642639 hdr = H5FL_FREE(H5B2_hdr_t, hdr);
3737 #include "H5B2pkg.h" /* v2 B-trees */
3838 #include "H5Eprivate.h" /* Error handling */
3939 #include "H5MFprivate.h" /* File memory management */
40 #include "H5VMprivate.h" /* Vectors and arrays */
40 #include "H5MMprivate.h" /* Memory management */
41 #include "H5VMprivate.h" /* Vectors and arrays */
4142
4243 /****************/
4344 /* Local Macros */
23352336 if(idx == 0) {
23362337 if(H5B2_POS_LEFT == curr_pos || H5B2_POS_ROOT == curr_pos) {
23372338 if(hdr->min_native_rec == NULL)
2338 if(NULL == (hdr->min_native_rec = (uint8_t *)HDmalloc(hdr->cls->nrec_size)))
2339 if(NULL == (hdr->min_native_rec = (uint8_t *)H5MM_malloc(hdr->cls->nrec_size)))
23392340 HGOTO_ERROR(H5E_BTREE, H5E_CANTALLOC, FAIL, "memory allocation failed for v2 B-tree min record info")
23402341 HDmemcpy(hdr->min_native_rec, H5B2_LEAF_NREC(leaf, hdr, idx), hdr->cls->nrec_size);
23412342 } /* end if */
23432344 if(idx == (unsigned)(leaf->nrec - 1)) {
23442345 if(H5B2_POS_RIGHT == curr_pos || H5B2_POS_ROOT == curr_pos) {
23452346 if(hdr->max_native_rec == NULL)
2346 if(NULL == (hdr->max_native_rec = (uint8_t *)HDmalloc(hdr->cls->nrec_size)))
2347 if(NULL == (hdr->max_native_rec = (uint8_t *)H5MM_malloc(hdr->cls->nrec_size)))
23472348 HGOTO_ERROR(H5E_BTREE, H5E_CANTALLOC, FAIL, "memory allocation failed for v2 B-tree max record info")
23482349 HDmemcpy(hdr->max_native_rec, H5B2_LEAF_NREC(leaf, hdr, idx), hdr->cls->nrec_size);
23492350 } /* end if */
29322933 /* (Don't use 'else' for the idx check, to allow for root leaf node) */
29332934 if(idx == 0) {
29342935 if(H5B2_POS_LEFT == curr_pos || H5B2_POS_ROOT == curr_pos) {
2935 if(hdr->min_native_rec) {
2936 HDfree(hdr->min_native_rec);
2937 hdr->min_native_rec = NULL;
2938 } /* end if */
2936 if(hdr->min_native_rec)
2937 hdr->min_native_rec = H5MM_xfree(hdr->min_native_rec);
29392938 } /* end if */
29402939 } /* end if */
29412940 if(idx == (unsigned)(leaf->nrec - 1)) {
29422941 if(H5B2_POS_RIGHT == curr_pos || H5B2_POS_ROOT == curr_pos) {
2943 if(hdr->max_native_rec) {
2944 HDfree(hdr->max_native_rec);
2945 hdr->max_native_rec = NULL;
2946 } /* end if */
2942 if(hdr->max_native_rec)
2943 hdr->max_native_rec = H5MM_xfree(hdr->max_native_rec);
29472944 } /* end if */
29482945 } /* end if */
29492946 } /* end if */
33293326 /* (Don't use 'else' for the idx check, to allow for root leaf node) */
33303327 if(idx == 0) {
33313328 if(H5B2_POS_LEFT == curr_pos || H5B2_POS_ROOT == curr_pos) {
3332 if(hdr->min_native_rec) {
3333 HDfree(hdr->min_native_rec);
3334 hdr->min_native_rec = NULL;
3335 } /* end if */
3329 if(hdr->min_native_rec)
3330 hdr->min_native_rec = H5MM_xfree(hdr->min_native_rec);
33363331 } /* end if */
33373332 } /* end if */
33383333 if(idx == (unsigned)(leaf->nrec - 1)) {
33393334 if(H5B2_POS_RIGHT == curr_pos || H5B2_POS_ROOT == curr_pos) {
3340 if(hdr->max_native_rec) {
3341 HDfree(hdr->max_native_rec);
3342 hdr->max_native_rec = NULL;
3343 } /* end if */
3335 if(hdr->max_native_rec)
3336 hdr->max_native_rec = H5MM_xfree(hdr->max_native_rec);
33443337 } /* end if */
33453338 } /* end if */
33463339 } /* end if */
158158 H5_DLL herr_t H5B2_unsupport(H5B2_t *bt2, hid_t dxpl_id, void *udata,
159159 H5AC_info_t *child);
160160 H5_DLL herr_t H5B2_depend(H5AC_info_t *parent_entry, H5B2_t *bt2);
161 H5_DLL herr_t H5B2_patch_file(H5B2_t *fa, H5F_t *f);
161162
162163 /* Statistics routines */
163164 H5_DLL herr_t H5B2_stat_info(H5B2_t *bt2, H5B2_stat_t *info);
8888 #include "H5Cpkg.h" /* Cache */
8989 #include "H5Eprivate.h" /* Error handling */
9090 #include "H5Fpkg.h" /* Files */
91 #include "H5FDprivate.h" /* File drivers */
9291 #include "H5FLprivate.h" /* Free Lists */
9392 #include "H5Iprivate.h" /* IDs */
9493 #include "H5MFprivate.h" /* File memory management */
156155
157156 static void * H5C_load_entry(H5F_t * f,
158157 hid_t dxpl_id,
158 #ifdef H5_HAVE_PARALLEL
159 hbool_t coll_access,
160 #endif /* H5_HAVE_PARALLEL */
159161 const H5C_class_t * type,
160162 haddr_t addr,
161163 void * udata);
189191 haddr_t addr,
190192 size_t *len,
191193 htri_t actual);
194
195 static herr_t H5C__generate_image(H5F_t *f, H5C_t * cache_ptr, H5C_cache_entry_t *entry_ptr,
196 hid_t dxpl_id, int64_t *entry_size_change_ptr);
192197
193198 #if H5C_DO_TAGGING_SANITY_CHECKS
194199 static herr_t H5C_verify_tag(int id, haddr_t tag);
497502 HDassert( max_type_id < H5C__MAX_NUM_TYPE_IDS );
498503 HDassert( type_name_table_ptr );
499504
500 HDassert( ( write_permitted == TRUE ) || ( write_permitted == FALSE ) );
501
502505 for ( i = 0; i <= max_type_id; i++ ) {
503506
504507 HDassert( (type_name_table_ptr)[i] );
602605 cache_ptr->LRU_list_size = (size_t)0;
603606 cache_ptr->LRU_head_ptr = NULL;
604607 cache_ptr->LRU_tail_ptr = NULL;
608
609 #ifdef H5_HAVE_PARALLEL
610 cache_ptr->coll_list_len = 0;
611 cache_ptr->coll_list_size = (size_t)0;
612 cache_ptr->coll_head_ptr = NULL;
613 cache_ptr->coll_tail_ptr = NULL;
614 #endif /* H5_HAVE_PARALLEL */
605615
606616 cache_ptr->cLRU_list_len = 0;
607617 cache_ptr->cLRU_list_size = (size_t)0;
10921102 HGOTO_ERROR(H5E_CACHE, H5E_CANTEXPUNGE, FAIL, "Target entry is protected.")
10931103 if(entry_ptr->is_pinned)
10941104 HGOTO_ERROR(H5E_CACHE, H5E_CANTEXPUNGE, FAIL, "Target entry is pinned.")
1105 #ifdef H5_HAVE_PARALLEL
1106 if(entry_ptr->coll_access) {
1107 entry_ptr->coll_access = FALSE;
1108 H5C__REMOVE_FROM_COLL_LIST(cache_ptr, entry_ptr, FAIL)
1109 } /* end if */
1110 #endif /* H5_HAVE_PARALLEL */
10951111
10961112 /* If we get this far, call H5C__flush_single_entry() with the
10971113 * H5C__FLUSH_INVALIDATE_FLAG and the H5C__FLUSH_CLEAR_ONLY_FLAG.
11091125 /* Delete the entry from the skip list on destroy */
11101126 flush_flags |= H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG;
11111127
1112 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, flush_flags, NULL) < 0)
1113 HGOTO_ERROR(H5E_CACHE, H5E_CANTEXPUNGE, FAIL, "can't flush entry")
1128 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, flush_flags, NULL, NULL) < 0)
1129 HGOTO_ERROR(H5E_CACHE, H5E_CANTEXPUNGE, FAIL, "H5C_flush_single_entry() failed.")
11141130
11151131 #if H5C_DO_SANITY_CHECKS
11161132 if ( entry_was_dirty )
21942210 void * thing,
21952211 unsigned int flags)
21962212 {
2197 H5C_t * cache_ptr;
2198 H5P_genplist_t *dxpl;
2213 H5C_t *cache_ptr;
2214 H5P_genplist_t *dxpl;
21992215 H5AC_ring_t ring = H5C_RING_UNDEFINED;
22002216 hbool_t insert_pinned;
22012217 hbool_t flush_last;
22022218 #ifdef H5_HAVE_PARALLEL
2219 hbool_t coll_access = FALSE; /* whether access to the cache entry is done collectively */
22032220 hbool_t flush_collectively;
22042221 #endif /* H5_HAVE_PARALLEL */
22052222 hbool_t set_flush_marker;
22062223 hbool_t write_permitted = TRUE;
22072224 size_t empty_space;
2208 H5C_cache_entry_t * entry_ptr;
2209 H5C_cache_entry_t * test_entry_ptr;
2225 H5C_cache_entry_t *entry_ptr;
2226 H5C_cache_entry_t *test_entry_ptr;
22102227 herr_t ret_value = SUCCEED; /* Return value */
22112228
22122229 FUNC_ENTER_NOAPI(FAIL)
23482365
23492366 entry_ptr->aux_next = NULL;
23502367 entry_ptr->aux_prev = NULL;
2368
2369 entry_ptr->coll_next = NULL;
2370 entry_ptr->coll_prev = NULL;
23512371
23522372 H5C__RESET_CACHE_ENTRY_STATS(entry_ptr)
23532373
24372457 #if H5C_DO_EXTREME_SANITY_CHECKS
24382458 if ( ( H5C_validate_protected_entry_list(cache_ptr) < 0 ) ||
24392459 ( H5C_validate_pinned_entry_list(cache_ptr) < 0 ) ||
2440 ( H5C_validate_lru_list(cache_ptr) < 0 ) ) {
2441
2442 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
2443 "an extreme sanity check failed just before done.\n");
2444 }
2460 ( H5C_validate_lru_list(cache_ptr) < 0 ) )
2461 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "an extreme sanity check failed just before done.\n")
24452462 #endif /* H5C_DO_EXTREME_SANITY_CHECKS */
24462463
24472464 /* If the entry's type has a 'notify' callback send a 'after insertion'
24532470
24542471 H5C__UPDATE_STATS_FOR_INSERTION(cache_ptr, entry_ptr)
24552472
2473 #ifdef H5_HAVE_PARALLEL
2474 /* Get the dataset transfer property list */
2475 if(NULL == (dxpl = (H5P_genplist_t *)H5I_object(dxpl_id)))
2476 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a property list");
2477
2478 if(H5F_HAS_FEATURE(f, H5FD_FEAT_HAS_MPI)) {
2479 coll_access = (H5P_USER_TRUE == f->coll_md_read ? TRUE : FALSE);
2480
2481 if(!coll_access && H5P_FORCE_FALSE != f->coll_md_read) {
2482 H5P_coll_md_read_flag_t prop_value;
2483
2484 /* Get the property value */
2485 if(H5P_get(dxpl, H5_COLL_MD_READ_FLAG_NAME, &prop_value) < 0)
2486 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "Can't get collective metadata access flag")
2487 coll_access = (H5P_USER_TRUE == prop_value ? TRUE : FALSE);
2488 } /* end if */
2489 } /* end if */
2490
2491 entry_ptr->coll_access = coll_access;
2492 if(coll_access) {
2493 H5C__INSERT_IN_COLL_LIST(cache_ptr, entry_ptr, FAIL)
2494
2495 /* Make sure the size of the collective entries in the cache remain in check */
2496 if(H5P_USER_TRUE == f->coll_md_read) {
2497 if(cache_ptr->max_cache_size*80 < cache_ptr->coll_list_size*100) {
2498 if(H5C_clear_coll_entries(cache_ptr, 1) < 0)
2499 HGOTO_ERROR(H5E_CACHE, H5E_CANTGET, FAIL, "H5C_clear_coll_entries() failed.")
2500 } /* end if */
2501 } /* end if */
2502 else {
2503 if(cache_ptr->max_cache_size*40 < cache_ptr->coll_list_size*100) {
2504 if(H5C_clear_coll_entries(cache_ptr, 1) < 0)
2505 HGOTO_ERROR(H5E_CACHE, H5E_CANTGET, FAIL, "H5C_clear_coll_entries() failed.")
2506 } /* end if */
2507 } /* end else */
2508 } /* end if */
2509 entry_ptr->ind_access_while_coll = FALSE;
2510 #endif
2511
24562512 done:
2457
24582513 #if H5C_DO_EXTREME_SANITY_CHECKS
24592514 if ( ( H5C_validate_protected_entry_list(cache_ptr) < 0 ) ||
24602515 ( H5C_validate_pinned_entry_list(cache_ptr) < 0 ) ||
2461 ( H5C_validate_lru_list(cache_ptr) < 0 ) ) {
2462
2463 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
2464 "an extreme sanity check failed on exit.\n");
2465 }
2516 ( H5C_validate_lru_list(cache_ptr) < 0 ) )
2517 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "an extreme sanity check failed on exit.\n")
24662518 #endif /* H5C_DO_EXTREME_SANITY_CHECKS */
24672519
24682520 FUNC_LEAVE_NOAPI(ret_value)
2469
24702521 } /* H5C_insert_entry() */
24712522
24722523
28412892 (cache_ptr->pl_size), \
28422893 (entry_ptr->size), (new_size))
28432894 } /* end if */
2895
2896 #ifdef H5_HAVE_PARALLEL
2897 if(entry_ptr->coll_access) {
2898 H5C__DLL_UPDATE_FOR_SIZE_CHANGE((cache_ptr->coll_list_len), \
2899 (cache_ptr->coll_list_size), \
2900 (entry_ptr->size), (new_size))
2901 } /* end if */
2902 #endif /* H5_HAVE_PARALLEL */
28442903
28452904 /* update the hash table */
28462905 H5C__UPDATE_INDEX_FOR_SIZE_CHANGE((cache_ptr), (entry_ptr->size),\
30713130 hbool_t flush_last;
30723131 #ifdef H5_HAVE_PARALLEL
30733132 hbool_t flush_collectively;
3133 hbool_t coll_access = FALSE; /* whether access to the cache entry is done collectively */
30743134 #endif /* H5_HAVE_PARALLEL */
30753135 hbool_t write_permitted;
30763136 size_t empty_space;
31153175 if((H5P_get(dxpl, H5AC_RING_NAME, &ring)) < 0)
31163176 HGOTO_ERROR(H5E_CACHE, H5E_CANTGET, NULL, "unable to query ring value")
31173177
3178 #ifdef H5_HAVE_PARALLEL
3179 if(H5F_HAS_FEATURE(f, H5FD_FEAT_HAS_MPI)) {
3180 coll_access = (H5P_USER_TRUE == f->coll_md_read ? TRUE : FALSE);
3181
3182 if(!coll_access && H5P_FORCE_FALSE != f->coll_md_read) {
3183 H5P_coll_md_read_flag_t prop_value;
3184
3185 /* get the property value */
3186 if(H5P_get(dxpl, H5_COLL_MD_READ_FLAG_NAME, &prop_value) < 0)
3187 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, NULL, "Can't get collective metadata access flag")
3188 coll_access = (H5P_USER_TRUE == prop_value ? TRUE : FALSE);
3189 } /* end if */
3190 } /* end if */
3191 #endif /* H5_HAVE_PARALLEL */
3192
31183193 /* first check to see if the target is in cache */
31193194 H5C__SEARCH_INDEX(cache_ptr, addr, entry_ptr, NULL)
31203195
31253200 /* Check for trying to load the wrong type of entry from an address */
31263201 if(entry_ptr->type != type)
31273202 HGOTO_ERROR(H5E_CACHE, H5E_BADTYPE, NULL, "incorrect cache entry type")
3203
3204 /* if this is a collective metadata read, the entry is not
3205 marked as collective, and is clean, it is possible that
3206 other processes will not have it in its cache and will
3207 expect a bcast of the entry from process 0. So process 0
3208 will bcast the entry to all other ranks. Ranks that do have
3209 the entry in their cache still have to participate in the
3210 bcast. */
3211 #ifdef H5_HAVE_PARALLEL
3212 if(H5F_HAS_FEATURE(f, H5FD_FEAT_HAS_MPI) && coll_access &&
3213 !(entry_ptr->is_dirty) && !(entry_ptr->coll_access)) {
3214 MPI_Comm comm; /* File MPI Communicator */
3215 int mpi_code; /* MPI error code */
3216 int buf_size;
3217
3218 if(MPI_COMM_NULL == (comm = H5F_mpi_get_comm(f)))
3219 HGOTO_ERROR(H5E_FILE, H5E_CANTGET, NULL, "get_comm request failed")
3220
3221 if(entry_ptr->image_ptr == NULL) {
3222 int mpi_rank;
3223 size_t image_size;
3224
3225 if((mpi_rank = H5F_mpi_get_rank(f)) < 0)
3226 HGOTO_ERROR(H5E_FILE, H5E_CANTGET, NULL, "Can't get MPI rank")
3227
3228 if(entry_ptr->compressed)
3229 image_size = entry_ptr->compressed_size;
3230 else
3231 image_size = entry_ptr->size;
3232 HDassert(image_size > 0);
3233
3234 if(NULL == (entry_ptr->image_ptr = H5MM_malloc(image_size + H5C_IMAGE_EXTRA_SPACE)))
3235 HGOTO_ERROR(H5E_CACHE, H5E_CANTALLOC, NULL, "memory allocation failed for on disk image buffer")
3236 #if H5C_DO_MEMORY_SANITY_CHECKS
3237 HDmemcpy(((uint8_t *)entry_ptr->image_ptr) + image_size,
3238 H5C_IMAGE_SANITY_VALUE, H5C_IMAGE_EXTRA_SPACE);
3239 #endif /* H5C_DO_MEMORY_SANITY_CHECKS */
3240 if(0 == mpi_rank)
3241 if(H5C__generate_image(f, cache_ptr, entry_ptr, dxpl_id, NULL) < 0)
3242 HGOTO_ERROR(H5E_CACHE, H5E_CANTGET, NULL, "Can't get Image")
3243 } /* end if */
3244
3245 HDassert(entry_ptr->image_ptr);
3246
3247 H5_CHECKED_ASSIGN(buf_size, int, entry_ptr->size, size_t);
3248 if(MPI_SUCCESS != (mpi_code = MPI_Bcast(entry_ptr->image_ptr, buf_size, MPI_BYTE, 0, comm)))
3249 HMPI_GOTO_ERROR(NULL, "MPI_Bcast failed", mpi_code)
3250
3251 entry_ptr->coll_access = TRUE;
3252
3253 H5C__INSERT_IN_COLL_LIST(cache_ptr, entry_ptr, NULL)
3254 } /* end if */
3255 else if(H5F_HAS_FEATURE(f, H5FD_FEAT_HAS_MPI) && coll_access && entry_ptr->coll_access) {
3256 H5C__MOVE_TO_TOP_IN_COLL_LIST(cache_ptr, entry_ptr, NULL)
3257 } /* end else-if */
3258 #endif /* H5_HAVE_PARALLEL */
31283259
31293260 #if H5C_DO_TAGGING_SANITY_CHECKS
31303261 {
31583289
31593290 hit = FALSE;
31603291
3161 thing = H5C_load_entry(f, dxpl_id, type, addr, udata);
3292 thing = H5C_load_entry(f, dxpl_id,
3293 #ifdef H5_HAVE_PARALLEL
3294 coll_access,
3295 #endif /* H5_HAVE_PARALLEL */
3296 type, addr, udata);
31623297
31633298 if ( thing == NULL ) {
31643299
31663301 }
31673302
31683303 entry_ptr = (H5C_cache_entry_t *)thing;
3304 entry_ptr->ring = ring;
3305 #ifdef H5_HAVE_PARALLEL
3306 if(H5F_HAS_FEATURE(f, H5FD_FEAT_HAS_MPI) && entry_ptr->coll_access)
3307 H5C__INSERT_IN_COLL_LIST(cache_ptr, entry_ptr, NULL)
3308 #endif /* H5_HAVE_PARALLEL */
31693309
31703310 entry_ptr->ring = ring;
31713311
34203560 HGOTO_ERROR(H5E_CACHE, H5E_CANTNOTIFY, NULL, "can't notify client about entry inserted into cache")
34213561 #endif
34223562
3563 #ifdef H5_HAVE_PARALLEL
3564 if(H5F_HAS_FEATURE(f, H5FD_FEAT_HAS_MPI)) {
3565 /* Make sure the size of the collective entries in the cache remain in check */
3566 if(TRUE == coll_access) {
3567 if(H5P_USER_TRUE == f->coll_md_read) {
3568 if(cache_ptr->max_cache_size * 80 < cache_ptr->coll_list_size * 100)
3569 if(H5C_clear_coll_entries(cache_ptr, 1) < 0)
3570 HGOTO_ERROR(H5E_CACHE, H5E_CANTGET, NULL, "H5C_clear_coll_entries() failed.")
3571 } /* end if */
3572 else {
3573 if(cache_ptr->max_cache_size * 40 < cache_ptr->coll_list_size * 100)
3574 if(H5C_clear_coll_entries(cache_ptr, 1) < 0)
3575 HGOTO_ERROR(H5E_CACHE, H5E_CANTGET, NULL, "H5C_clear_coll_entries() failed.")
3576 } /* end else */
3577 } /* end if */
3578 } /* end if */
3579 #endif /* H5_HAVE_PARALLEL */
3580
34233581 done:
34243582
34253583 #if H5C_DO_EXTREME_SANITY_CHECKS
34263584 if ( ( H5C_validate_protected_entry_list(cache_ptr) < 0 ) ||
34273585 ( H5C_validate_pinned_entry_list(cache_ptr) < 0 ) ||
3428 ( H5C_validate_lru_list(cache_ptr) < 0 ) ) {
3429
3430 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, NULL, \
3431 "an extreme sanity check failed on exit.\n");
3432 }
3586 ( H5C_validate_lru_list(cache_ptr) < 0 ) )
3587 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, NULL, "an extreme sanity check failed on exit.\n")
34333588 #endif /* H5C_DO_EXTREME_SANITY_CHECKS */
34343589
34353590 FUNC_LEAVE_NOAPI(ret_value)
37683923 *-------------------------------------------------------------------------
37693924 */
37703925 herr_t
3771 H5C_set_evictions_enabled(H5C_t *cache_ptr,
3772 hbool_t evictions_enabled)
3926 H5C_set_evictions_enabled(H5C_t *cache_ptr, hbool_t evictions_enabled)
37733927 {
37743928 herr_t ret_value = SUCCEED; /* Return value */
37753929
37763930 FUNC_ENTER_NOAPI(FAIL)
37773931
3778 if ( ( cache_ptr == NULL ) || ( cache_ptr->magic != H5C__H5C_T_MAGIC ) ) {
3779
3932 if((cache_ptr == NULL) || (cache_ptr->magic != H5C__H5C_T_MAGIC))
37803933 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Bad cache_ptr on entry.")
3781 }
3782
3783 if ( ( evictions_enabled != TRUE ) && ( evictions_enabled != FALSE ) ) {
3784
3785 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
3786 "Bad evictions_enabled on entry.")
3787 }
37883934
37893935 /* There is no fundamental reason why we should not permit
37903936 * evictions to be disabled while automatic resize is enabled.
37923938 * want to, and allowing it would greatly complicate testing
37933939 * the feature. Hence the following:
37943940 */
3795 if ( ( evictions_enabled != TRUE ) &&
3796 ( ( cache_ptr->resize_ctl.incr_mode != H5C_incr__off ) ||
3797 ( cache_ptr->resize_ctl.decr_mode != H5C_decr__off ) ) ) {
3798
3799 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
3800 "Can't disable evictions when auto resize enabled.")
3801 }
3941 if((evictions_enabled != TRUE) &&
3942 ((cache_ptr->resize_ctl.incr_mode != H5C_incr__off) ||
3943 (cache_ptr->resize_ctl.decr_mode != H5C_decr__off)))
3944 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't disable evictions when auto resize enabled.")
38023945
38033946 cache_ptr->evictions_enabled = evictions_enabled;
38043947
38053948 done:
3806
38073949 FUNC_LEAVE_NOAPI(ret_value)
3808
38093950 } /* H5C_set_evictions_enabled() */
38103951
38113952
51035244 /* Delete the entry from the skip list on destroy */
51045245 flush_flags |= H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG;
51055246
5106 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, flush_flags, NULL) < 0)
5247 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, flush_flags, NULL, NULL) < 0)
51075248 HGOTO_ERROR(H5E_CACHE, H5E_CANTUNPROTECT, FAIL, "Can't flush entry")
51085249
51095250 #if H5C_DO_SANITY_CHECKS
51295270 else if(test_entry_ptr != entry_ptr)
51305271 HGOTO_ERROR(H5E_CACHE, H5E_CANTUNPROTECT, FAIL, "hash table contains multiple entries for addr?!?.")
51315272
5132 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0)
5273 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL, NULL) < 0)
51335274 HGOTO_ERROR(H5E_CACHE, H5E_CANTUNPROTECT, FAIL, "Can't clear entry")
51345275 }
51355276 #endif /* H5_HAVE_PARALLEL */
51915332
51925333 if ( (tests & H5C_RESIZE_CFG__VALIDATE_GENERAL) != 0 ) {
51935334
5194 if ( ( config_ptr->set_initial_size != TRUE ) &&
5195 ( config_ptr->set_initial_size != FALSE ) ) {
5196
5197 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, \
5198 "set_initial_size must be either TRUE or FALSE");
5199 }
5200
5201 if ( config_ptr->max_size > H5C__MAX_MAX_CACHE_SIZE ) {
5202
5203 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "max_size too big");
5204 }
5205
5206 if ( config_ptr->min_size < H5C__MIN_MAX_CACHE_SIZE ) {
5207
5208 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "min_size too small");
5209 }
5210
5211 if ( config_ptr->min_size > config_ptr->max_size ) {
5212
5213 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "min_size > max_size");
5214 }
5335 if(config_ptr->max_size > H5C__MAX_MAX_CACHE_SIZE)
5336 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "max_size too big")
5337
5338 if(config_ptr->min_size < H5C__MIN_MAX_CACHE_SIZE)
5339 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "min_size too small")
5340
5341 if(config_ptr->min_size > config_ptr->max_size)
5342 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "min_size > max_size")
52155343
52165344 if ( ( config_ptr->set_initial_size ) &&
52175345 ( ( config_ptr->initial_size < config_ptr->min_size ) ||
52505378
52515379 if ( config_ptr->incr_mode == H5C_incr__threshold ) {
52525380
5253 if ( ( config_ptr->lower_hr_threshold < (double)0.0f ) ||
5254 ( config_ptr->lower_hr_threshold > (double)1.0f ) ) {
5255
5256 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, \
5257 "lower_hr_threshold must be in the range [0.0, 1.0]");
5258 }
5259
5260 if ( config_ptr->increment < (double)1.0f ) {
5261
5262 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, \
5263 "increment must be greater than or equal to 1.0");
5264 }
5265
5266 if ( ( config_ptr->apply_max_increment != TRUE ) &&
5267 ( config_ptr->apply_max_increment != FALSE ) ) {
5268
5269 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, \
5270 "apply_max_increment must be either TRUE or FALSE");
5271 }
5381 if((config_ptr->lower_hr_threshold < (double)0.0f) ||
5382 (config_ptr->lower_hr_threshold > (double)1.0f))
5383 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "lower_hr_threshold must be in the range [0.0, 1.0]")
5384
5385 if(config_ptr->increment < (double)1.0f)
5386 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "increment must be greater than or equal to 1.0")
52725387
52735388 /* no need to check max_increment, as it is a size_t,
52745389 * and thus must be non-negative.
53465461 "epochs_before_eviction must be positive");
53475462 }
53485463
5349 if ( config_ptr->epochs_before_eviction > H5C__MAX_EPOCH_MARKERS ) {
5350
5351 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, \
5352 "epochs_before_eviction too big");
5353 }
5354
5355 if ( ( config_ptr->apply_empty_reserve != TRUE ) &&
5356 ( config_ptr->apply_empty_reserve != FALSE ) ) {
5357
5358 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, \
5359 "apply_empty_reserve must be either TRUE or FALSE");
5360 }
5361
5362 if ( ( config_ptr->apply_empty_reserve ) &&
5363 ( ( config_ptr->empty_reserve > (double)1.0f ) ||
5364 ( config_ptr->empty_reserve < (double)0.0f ) ) ) {
5365
5366 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, \
5367 "empty_reserve must be in the interval [0.0, 1.0]");
5368 }
5464 if(config_ptr->epochs_before_eviction > H5C__MAX_EPOCH_MARKERS)
5465 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "epochs_before_eviction too big")
5466
5467 if((config_ptr->apply_empty_reserve) &&
5468 ((config_ptr->empty_reserve > (double)1.0f) ||
5469 (config_ptr->empty_reserve < (double)0.0f)))
5470 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "empty_reserve must be in the interval [0.0, 1.0]")
53695471
53705472 /* no need to check max_decrement as it is a size_t
53715473 * and thus must be non-negative.
63666468 cache_ptr->entries_removed_counter = 0;
63676469 cache_ptr->last_entry_removed_ptr = NULL;
63686470
6369 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__NO_FLAGS_SET, NULL) < 0)
6471 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__NO_FLAGS_SET, NULL, NULL) < 0)
63706472 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush entry")
63716473
63726474 if ( ( cache_ptr->entries_removed_counter > 1 ) ||
63786480
63796481 bytes_evicted += entry_ptr->size;
63806482
6381 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__FLUSH_INVALIDATE_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0 )
6483 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__FLUSH_INVALIDATE_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL, NULL) < 0 )
63826484 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush entry")
63836485 }
63846486
64616563 prev_ptr = entry_ptr->prev;
64626564
64636565 if ( ! (entry_ptr->is_dirty) ) {
6464
6465 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__FLUSH_INVALIDATE_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0)
6566 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__FLUSH_INVALIDATE_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL, NULL) < 0)
64666567 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush clean entry")
64676568 }
64686569 /* just skip the entry if it is dirty, as we can't do
72957396 entry_size_change = 0;
72967397 #endif /* H5C_DO_SANITY_CHECKS */
72977398
7298 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__NO_FLAGS_SET, entry_size_change_ptr) < 0)
7399 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__NO_FLAGS_SET, entry_size_change_ptr, NULL) < 0)
72997400 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "dirty pinned entry flush failed.")
7401
73007402 #if H5C_DO_SANITY_CHECKS
73017403 /* entry size may have changed during the flush.
73027404 * Update flushed_slist_size to account for this.
73367438
73377439 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr,
73387440 (cooked_flags | H5C__FLUSH_INVALIDATE_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG),
7339 entry_size_change_ptr) < 0)
7441 entry_size_change_ptr, NULL) < 0)
73407442 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "dirty entry flush destroy failed.")
7443
73417444 #if H5C_DO_SANITY_CHECKS
73427445 /* entry size may have changed during the flush.
73437446 * Update flushed_slist_size to account for this.
74497552
74507553 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr,
74517554 (cooked_flags | H5C__FLUSH_INVALIDATE_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG),
7452 NULL) < 0)
7555 NULL, NULL) < 0)
74537556 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "Entry flush destroy failed.")
74547557
74557558 if(entry_was_dirty) {
77907893 entry_size_change = 0;
77917894 #endif /* H5C_DO_SANITY_CHECKS */
77927895
7793 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, flags, entry_size_change_ptr) < 0)
7896 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, flags, entry_size_change_ptr, NULL) < 0)
77947897 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "dirty pinned entry flush failed.")
77957898
77967899 #if H5C_DO_SANITY_CHECKS
78257928 flushed_entries_size += (int64_t)entry_ptr->size;
78267929 entry_size_change = 0;
78277930 #endif /* H5C_DO_SANITY_CHECKS */
7828 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, flags, entry_size_change_ptr) < 0)
7931 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, flags, entry_size_change_ptr, NULL) < 0)
78297932 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "Can't flush entry.")
78307933
78317934 #if H5C_DO_SANITY_CHECKS
79478050 */
79488051 herr_t
79498052 H5C__flush_single_entry(const H5F_t *f, hid_t dxpl_id, H5C_cache_entry_t *entry_ptr,
7950 unsigned flags, int64_t *entry_size_change_ptr)
8053 unsigned flags, int64_t *entry_size_change_ptr, H5SL_t *collective_write_list)
79518054 {
79528055 H5C_t * cache_ptr; /* Cache for file */
79538056 hbool_t destroy; /* external flag */
79918094 destroy_entry = FALSE;
79928095 else
79938096 destroy_entry = destroy;
8097
8098 #ifdef H5_HAVE_PARALLEL
8099 HDassert(FALSE == entry_ptr->coll_access);
8100 #endif
79948101
79958102 /* we will write the entry to disk if it exists, is dirty, and if the
79968103 * clear only flag is not set.
83498456 else
83508457 image_size = entry_ptr->size;
83518458
8459 #ifdef H5_HAVE_PARALLEL
8460 if(collective_write_list) {
8461 H5C_collective_write_t *item = NULL;
8462
8463 if(NULL == (item = (H5C_collective_write_t *)H5MM_malloc(sizeof(H5C_collective_write_t))))
8464 HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "unable to allocate skip list item")
8465
8466 item->length = image_size;
8467 item->free_buf = FALSE;
8468 item->buf = entry_ptr->image_ptr;
8469 item->offset = entry_ptr->addr;
8470
8471 if(H5SL_insert(collective_write_list, item, &item->offset) < 0) {
8472 H5MM_free(item);
8473 HGOTO_ERROR(H5E_HEAP, H5E_CANTINSERT, FAIL, "unable to insert skip list item")
8474 } /* end if */
8475 } /* end if */
8476 else
8477 #endif /* H5_HAVE_PARALLEL */
83528478 if(H5F_block_write(f, entry_ptr->type->mem_type, entry_ptr->addr,
83538479 image_size, dxpl_id, entry_ptr->image_ptr) < 0)
83548480 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "Can't write image to file.")
87148840 static void *
87158841 H5C_load_entry(H5F_t * f,
87168842 hid_t dxpl_id,
8843 #ifdef H5_HAVE_PARALLEL
8844 hbool_t coll_access,
8845 #endif /* H5_HAVE_PARALLEL */
87178846 const H5C_class_t * type,
87188847 haddr_t addr,
87198848 void * udata)
87318860 void * thing = NULL; /* Pointer to thing loaded */
87328861 H5C_cache_entry_t * entry; /* Alias for thing loaded, as cache entry */
87338862 size_t len; /* Size of image in file */
8863 #ifdef H5_HAVE_PARALLEL
8864 int mpi_rank; /* MPI process rank */
8865 MPI_Comm comm; /* File MPI Communicator */
8866 int mpi_code; /* MPI error code */
8867 #endif /* H5_HAVE_PARALLEL */
87348868 void * ret_value = NULL; /* Return value */
87358869
87368870 FUNC_ENTER_NOAPI_NOINIT
88418975 HDmemcpy(image + len, H5C_IMAGE_SANITY_VALUE, H5C_IMAGE_EXTRA_SPACE);
88428976 #endif /* H5C_DO_MEMORY_SANITY_CHECKS */
88438977
8978 #ifdef H5_HAVE_PARALLEL
8979 if(H5F_HAS_FEATURE(f, H5FD_FEAT_HAS_MPI)) {
8980 if((mpi_rank = H5F_mpi_get_rank(f)) < 0)
8981 HGOTO_ERROR(H5E_FILE, H5E_CANTGET, NULL, "Can't get MPI rank")
8982 if((comm = H5F_mpi_get_comm(f)) == MPI_COMM_NULL)
8983 HGOTO_ERROR(H5E_FILE, H5E_CANTGET, NULL, "get_comm request failed")
8984 } /* end if */
8985 #endif /* H5_HAVE_PARALLEL */
8986
88448987 /* Get the on-disk entry image */
88458988 if ( 0 == (type->flags & H5C__CLASS_SKIP_READS) ) {
88468989 unsigned tries, max_tries; /* The # of read attempts */
88699012 image = (uint8_t *)new_image;
88709013 }
88719014
8872 if(H5F_block_read(f, type->mem_type, addr, len, dxpl_id, image) < 0)
8873 HGOTO_ERROR(H5E_CACHE, H5E_READERROR, NULL, "Can't read image*")
8874
9015 #ifdef H5_HAVE_PARALLEL
9016 if(!coll_access || 0 == mpi_rank) {
9017 #endif /* H5_HAVE_PARALLEL */
9018
9019 if(H5F_block_read(f, type->mem_type, addr, len, dxpl_id, image) < 0)
9020 HGOTO_ERROR(H5E_CACHE, H5E_READERROR, NULL, "Can't read image*")
9021
9022 #ifdef H5_HAVE_PARALLEL
9023 }
9024 /* if the collective metadata read optimization is turned on,
9025 bcast the metadata read from process 0 to all ranks in the file
9026 communicator */
9027 if(coll_access) {
9028 int buf_size;
9029
9030 H5_CHECKED_ASSIGN(buf_size, int, len, size_t);
9031 if(MPI_SUCCESS != (mpi_code = MPI_Bcast(image, buf_size, MPI_BYTE, 0, comm)))
9032 HMPI_GOTO_ERROR(NULL, "MPI_Bcast failed", mpi_code)
9033 } /* end if */
9034 #endif /* H5_HAVE_PARALLEL */
9035
88759036 actual_len = len;
88769037
88779038 if(type->get_load_size(image, udata, &len, &actual_len, &compressed, &compressed_size) < 0)
89199080 * loaded thing, go get the on-disk image again (the extra portion).
89209081 */
89219082 if(actual_len > len) {
9083 #ifdef H5_HAVE_PARALLEL
9084 if(!coll_access || 0 == mpi_rank) {
9085 #endif /* H5_HAVE_PARALLEL */
89229086 if(H5F_block_read(f, type->mem_type, addr+len, actual_len-len, dxpl_id, image+len) < 0)
89239087 HGOTO_ERROR(H5E_CACHE, H5E_CANTLOAD, NULL, "Can't read image")
9088 #ifdef H5_HAVE_PARALLEL
9089 }
9090 /* if the collective metadata read optimization is turned on,
9091 bcast the metadata read from process 0 to all ranks in the file
9092 communicator */
9093 if(coll_access) {
9094 int buf_size;
9095
9096 H5_CHECKED_ASSIGN(buf_size, int, actual_len-len, size_t);
9097 if(MPI_SUCCESS != (mpi_code = MPI_Bcast(image+len, buf_size, MPI_BYTE, 0, comm)))
9098 HMPI_GOTO_ERROR(NULL, "MPI_Bcast failed", mpi_code)
9099 }
9100 #endif /* H5_HAVE_PARALLEL */
89249101 }
89259102 } else { /* throw an error */
89269103 HGOTO_ERROR(H5E_CACHE, H5E_UNSUPPORTED, NULL, "size of non-speculative, non-compressed object changed")
89979174 #ifdef H5_HAVE_PARALLEL
89989175 entry->clear_on_unprotect = FALSE;
89999176 entry->flush_immediately = FALSE;
9177 entry->coll_access = coll_access;
9178 entry->ind_access_while_coll = FALSE;
90009179 #endif /* H5_HAVE_PARALLEL */
90019180 entry->flush_in_progress = FALSE;
90029181 entry->destroy_in_progress = FALSE;
90179196
90189197 entry->aux_next = NULL;
90199198 entry->aux_prev = NULL;
9199
9200 entry->coll_next = NULL;
9201 entry->coll_prev = NULL;
90209202
90219203 H5C__RESET_CACHE_ENTRY_STATS(entry);
90229204
92179399 cache_ptr->entries_removed_counter = 0;
92189400 cache_ptr->last_entry_removed_ptr = NULL;
92199401
9220 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__NO_FLAGS_SET, NULL) < 0)
9402 #ifdef H5_HAVE_PARALLEL
9403 if(TRUE == entry_ptr->coll_access) {
9404 entry_ptr->coll_access = FALSE;
9405 H5C__REMOVE_FROM_COLL_LIST(cache_ptr, entry_ptr, FAIL)
9406 } /* end if */
9407 #endif
9408
9409 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__NO_FLAGS_SET, NULL, NULL) < 0)
92219410 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush entry")
92229411
92239412 if ( ( cache_ptr->entries_removed_counter > 1 ) ||
92259414
92269415 restart_scan = TRUE;
92279416
9228 } else if ( (cache_ptr->index_size + space_needed)
9229 >
9230 cache_ptr->max_cache_size ) {
9417 } else if ( (cache_ptr->index_size + space_needed) > cache_ptr->max_cache_size
9418 #ifdef H5_HAVE_PARALLEL
9419 && !(entry_ptr->coll_access)
9420 #endif /* H5_HAVE_PARALLEL */
9421 ) {
92319422 #if H5C_COLLECT_CACHE_STATS
92329423 cache_ptr->entries_scanned_to_make_space++;
92339424 #endif /* H5C_COLLECT_CACHE_STATS */
92349425
9235 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__FLUSH_INVALIDATE_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0)
9426 #ifdef H5_HAVE_PARALLEL
9427 if(TRUE == entry_ptr->coll_access) {
9428 entry_ptr->coll_access = FALSE;
9429 H5C__REMOVE_FROM_COLL_LIST(cache_ptr, entry_ptr, FAIL)
9430 } /* end if */
9431 #endif
9432
9433 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__FLUSH_INVALIDATE_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL, NULL) < 0)
92369434 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush entry")
92379435 } else {
92389436 /* We have enough space so don't flush clean entry. */
93709568
93719569 prev_ptr = entry_ptr->aux_prev;
93729570
9373 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__FLUSH_INVALIDATE_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0)
9374 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush entry")
9571 #ifdef H5_HAVE_PARALLEL
9572 if(!(entry_ptr->coll_access)) {
9573 #endif /* H5_HAVE_PARALLEL */
9574 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr, H5C__FLUSH_INVALIDATE_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL, NULL) < 0)
9575 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to flush entry")
9576 #ifdef H5_HAVE_PARALLEL
9577 } /* end if */
9578 #endif /* H5_HAVE_PARALLEL */
93759579
93769580 /* we are scanning the clean LRU, so the serialize function
93779581 * will not be called on any entry -- thus there is no
1020510409
1020610410 if(H5C__flush_single_entry(f, dxpl_id, entry_ptr,
1020710411 H5C__FLUSH_INVALIDATE_FLAG | H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG,
10208 NULL) < 0)
10412 NULL, NULL) < 0)
1020910413
1021010414 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, \
1021110415 "Entry eviction failed.")
1080911013 } /* H5C__assert_flush_dep_nocycle() */
1081011014 #endif /* NDEBUG */
1081111015
11016 static herr_t
11017 H5C__generate_image(H5F_t *f, H5C_t * cache_ptr, H5C_cache_entry_t *entry_ptr,
11018 hid_t dxpl_id, int64_t *entry_size_change_ptr)
11019 {
11020 haddr_t new_addr = HADDR_UNDEF;
11021 haddr_t old_addr = HADDR_UNDEF;
11022 size_t new_len = 0;
11023 size_t new_compressed_len = 0;
11024 unsigned serialize_flags = H5C__SERIALIZE_NO_FLAGS_SET;
11025 herr_t ret_value = SUCCEED;
11026
11027 FUNC_ENTER_NOAPI_NOINIT
11028
11029 HDassert(!entry_ptr->image_up_to_date);
11030
11031 /* reset cache_ptr->slist_changed so we can detect slist
11032 * modifications in the pre_serialize call.
11033 */
11034 cache_ptr->slist_changed = FALSE;
11035
11036 /* make note of the entry's current address */
11037 old_addr = entry_ptr->addr;
11038
11039 /* Call client's pre-serialize callback, if there's one */
11040 if ( ( entry_ptr->type->pre_serialize != NULL ) &&
11041 ( (entry_ptr->type->pre_serialize)(f, dxpl_id,
11042 (void *)entry_ptr,
11043 entry_ptr->addr,
11044 entry_ptr->size,
11045 entry_ptr->compressed_size,
11046 &new_addr, &new_len,
11047 &new_compressed_len,
11048 &serialize_flags) < 0 ) ) {
11049 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, \
11050 "unable to pre-serialize entry");
11051 }
11052
11053 /* set cache_ptr->slist_change_in_pre_serialize if the
11054 * slist was modified.
11055 */
11056 if ( cache_ptr->slist_changed )
11057 cache_ptr->slist_change_in_pre_serialize = TRUE;
11058
11059 /* Check for any flags set in the pre-serialize callback */
11060 if ( serialize_flags != H5C__SERIALIZE_NO_FLAGS_SET ) {
11061 /* Check for unexpected flags from serialize callback */
11062 if ( serialize_flags & ~(H5C__SERIALIZE_RESIZED_FLAG |
11063 H5C__SERIALIZE_MOVED_FLAG |
11064 H5C__SERIALIZE_COMPRESSED_FLAG)) {
11065 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, \
11066 "unknown serialize flag(s)");
11067 }
11068
11069 #ifdef H5_HAVE_PARALLEL
11070 if ( cache_ptr->aux_ptr != NULL )
11071 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, \
11072 "resize/move in serialize occured in parallel case.");
11073 #endif
11074
11075 /* Resize the buffer if required */
11076 if ( ( ( ! entry_ptr->compressed ) &&
11077 ( serialize_flags & H5C__SERIALIZE_RESIZED_FLAG ) ) ||
11078 ( ( entry_ptr->compressed ) &&
11079 ( serialize_flags & H5C__SERIALIZE_COMPRESSED_FLAG ) ) ) {
11080 size_t new_image_size;
11081
11082 if ( entry_ptr->compressed )
11083 new_image_size = new_compressed_len;
11084 else
11085 new_image_size = new_len;
11086
11087 HDassert(new_image_size > 0);
11088
11089 /* Release the current image */
11090 if ( entry_ptr->image_ptr ) {
11091 entry_ptr->image_ptr = H5MM_xfree(entry_ptr->image_ptr);
11092 }
11093
11094 /* Allocate a new image buffer */
11095 entry_ptr->image_ptr =
11096 H5MM_malloc(new_image_size + H5C_IMAGE_EXTRA_SPACE);
11097
11098 if ( NULL == entry_ptr->image_ptr )
11099 {
11100 HGOTO_ERROR(H5E_CACHE, H5E_CANTALLOC, FAIL, \
11101 "memory allocation failed for on disk image buffer");
11102 }
11103
11104 #if H5C_DO_MEMORY_SANITY_CHECKS
11105
11106 HDmemcpy(((uint8_t *)entry_ptr->image_ptr) + new_image_size,
11107 H5C_IMAGE_SANITY_VALUE,
11108 H5C_IMAGE_EXTRA_SPACE);
11109
11110 #endif /* H5C_DO_MEMORY_SANITY_CHECKS */
11111
11112 } /* end if */
11113
11114 /* If required, update the entry and the cache data structures
11115 * for a resize.
11116 */
11117 if ( serialize_flags & H5C__SERIALIZE_RESIZED_FLAG ) {
11118
11119 H5C__UPDATE_STATS_FOR_ENTRY_SIZE_CHANGE(cache_ptr, \
11120 entry_ptr, new_len);
11121
11122 /* update the hash table for the size change*/
11123 H5C__UPDATE_INDEX_FOR_SIZE_CHANGE(cache_ptr, \
11124 entry_ptr->size, \
11125 new_len, entry_ptr, \
11126 !(entry_ptr->is_dirty));
11127
11128 /* The entry can't be protected since we are
11129 * in the process of flushing it. Thus we must
11130 * update the replacement policy data
11131 * structures for the size change. The macro
11132 * deals with the pinned case.
11133 */
11134 H5C__UPDATE_RP_FOR_SIZE_CHANGE(cache_ptr, entry_ptr, new_len);
11135
11136 /* as we haven't updated the cache data structures for
11137 * for the flush or flush destroy yet, the entry should
11138 * be in the slist. Thus update it for the size change.
11139 */
11140 HDassert(entry_ptr->in_slist);
11141 H5C__UPDATE_SLIST_FOR_SIZE_CHANGE(cache_ptr, entry_ptr->size, \
11142 new_len);
11143
11144 /* if defined, update *entry_size_change_ptr for the
11145 * change in entry size.
11146 */
11147 if ( entry_size_change_ptr != NULL )
11148 {
11149 *entry_size_change_ptr = (int64_t)new_len;
11150 *entry_size_change_ptr -= (int64_t)(entry_ptr->size);
11151 }
11152
11153 /* finally, update the entry for its new size */
11154 entry_ptr->size = new_len;
11155 } /* end if */
11156
11157 /* If required, udate the entry and the cache data structures
11158 * for a move
11159 */
11160 if(serialize_flags & H5C__SERIALIZE_MOVED_FLAG) {
11161 #if H5C_DO_SANITY_CHECKS
11162 int64_t saved_slist_len_increase;
11163 int64_t saved_slist_size_increase;
11164 #endif /* H5C_DO_SANITY_CHECKS */
11165
11166 H5C__UPDATE_STATS_FOR_MOVE(cache_ptr, entry_ptr);
11167
11168 if ( entry_ptr->addr == old_addr ) {
11169 /* we must update cache data structures for the
11170 * change in address.
11171 */
11172
11173 /* delete the entry from the hash table and the slist */
11174 H5C__DELETE_FROM_INDEX(cache_ptr, entry_ptr);
11175 H5C__REMOVE_ENTRY_FROM_SLIST(cache_ptr, entry_ptr);
11176
11177 /* update the entry for its new address */
11178 entry_ptr->addr = new_addr;
11179
11180 /* and then reinsert in the index and slist */
11181 H5C__INSERT_IN_INDEX(cache_ptr, entry_ptr, FAIL);
11182
11183 #if H5C_DO_SANITY_CHECKS
11184 /* save cache_ptr->slist_len_increase and
11185 * cache_ptr->slist_size_increase before the
11186 * reinsertion into the slist, and restore
11187 * them afterwards to avoid skewing our sanity
11188 * checking.
11189 */
11190 saved_slist_len_increase = cache_ptr->slist_len_increase;
11191 saved_slist_size_increase = cache_ptr->slist_size_increase;
11192 #endif /* H5C_DO_SANITY_CHECKS */
11193
11194 H5C__INSERT_ENTRY_IN_SLIST(cache_ptr, entry_ptr, FAIL);
11195
11196 #if H5C_DO_SANITY_CHECKS
11197 cache_ptr->slist_len_increase = saved_slist_len_increase;
11198 cache_ptr->slist_size_increase = saved_slist_size_increase;
11199 #endif /* H5C_DO_SANITY_CHECKS */
11200 }
11201 else {
11202 HDassert(entry_ptr->addr == new_addr);
11203 }
11204 } /* end if */
11205
11206 if ( serialize_flags & H5C__SERIALIZE_COMPRESSED_FLAG ) {
11207 /* just save the new compressed entry size in
11208 * entry_ptr->compressed_size. We don't need to
11209 * do more, as compressed size is only used for I/O.
11210 */
11211 HDassert(entry_ptr->compressed);
11212 entry_ptr->compressed_size = new_compressed_len;
11213 }
11214 } /* end if ( serialize_flags != H5C__SERIALIZE_NO_FLAGS_SET ) */
11215
11216 /* Serialize object into buffer */
11217 {
11218 size_t image_len;
11219
11220 if ( entry_ptr->compressed )
11221 image_len = entry_ptr->compressed_size;
11222 else
11223 image_len = entry_ptr->size;
11224
11225 /* reset cache_ptr->slist_changed so we can detect slist
11226 * modifications in the serialize call.
11227 */
11228 cache_ptr->slist_changed = FALSE;
11229
11230
11231 if ( entry_ptr->type->serialize(f, entry_ptr->image_ptr,
11232 image_len,
11233 (void *)entry_ptr) < 0) {
11234 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, \
11235 "unable to serialize entry");
11236 }
11237
11238 /* set cache_ptr->slist_change_in_serialize if the
11239 * slist was modified.
11240 */
11241 if ( cache_ptr->slist_changed )
11242 cache_ptr->slist_change_in_pre_serialize = TRUE;
11243
11244 #if H5C_DO_MEMORY_SANITY_CHECKS
11245
11246 HDassert(0 == HDmemcmp(((uint8_t *)entry_ptr->image_ptr) +
11247 image_len,
11248 H5C_IMAGE_SANITY_VALUE,
11249 H5C_IMAGE_EXTRA_SPACE));
11250
11251 #endif /* H5C_DO_MEMORY_SANITY_CHECKS */
11252
11253 entry_ptr->image_up_to_date = TRUE;
11254 }
11255
11256 done:
11257 FUNC_LEAVE_NOAPI(ret_value)
11258 } /* H5C__generate_image */
3838 #include "H5private.h" /* Generic Functions */
3939 #include "H5ACprivate.h" /* Metadata cache */
4040 #include "H5Cpkg.h" /* Cache */
41 #include "H5Dprivate.h" /* Datasets */
4142 #include "H5Eprivate.h" /* Error handling */
4243 #include "H5Fpkg.h" /* Files */
44 #include "H5FDprivate.h" /* File drivers */
4345 #include "H5Iprivate.h" /* IDs */
4446 #include "H5MMprivate.h" /* Memory management */
45
47 #include "H5Pprivate.h" /* Property lists */
48 #include "H5SLprivate.h" /* Skip lists */
4649
4750 #ifdef H5_HAVE_PARALLEL
4851
220223 H5C_cache_entry_t * entry_ptr = NULL;
221224 H5C_cache_entry_t * flush_ptr = NULL;
222225 H5C_cache_entry_t * delayed_ptr = NULL;
226 H5SL_t * collective_write_list = NULL;
223227 #if H5C_DO_SANITY_CHECKS
224228 haddr_t last_addr;
225229 #endif /* H5C_DO_SANITY_CHECKS */
251255 sprintf(&(tbl_buf[HDstrlen(tbl_buf)]), "\n");
252256 HDfprintf(stdout, "%s", tbl_buf);
253257 #endif /* H5C_APPLY_CANDIDATE_LIST__DEBUG */
258
259 if(f->coll_md_write) {
260 /* Create skip list of entries for collective write */
261 if(NULL == (collective_write_list = H5SL_create(H5SL_TYPE_HADDR, NULL)))
262 HGOTO_ERROR(H5E_DATASET, H5E_CANTCREATE, FAIL, "can't create skip list for entries")
263 }
254264
255265 n = num_candidates / mpi_size;
256266 m = num_candidates % mpi_size;
356366 entries_to_clear++;
357367 entry_ptr->clear_on_unprotect = TRUE;
358368 } /* end else */
369
370 /* Entries marked as collectively accessed and are in the
371 candidate list to clear from the cache have to be
372 removed from the coll list. This is OK since the
373 candidate list is collective and uniform across all
374 ranks. */
375 if(TRUE == entry_ptr->coll_access) {
376 entry_ptr->coll_access = FALSE;
377 H5C__REMOVE_FROM_COLL_LIST(cache_ptr, entry_ptr, FAIL)
378 }
359379 } /* end else */
360380 } /* end for */
361381
432452 * will not call either the pre_serialize or serialize callbacks.
433453 */
434454
435 if(H5C__flush_single_entry(f, dxpl_id, clear_ptr, H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0)
455 if(H5C__flush_single_entry(f, dxpl_id, clear_ptr,
456 H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG,
457 NULL, NULL) < 0)
436458 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't clear entry.")
437459 } /* end if */
438460
477499 cache_ptr->entries_removed_counter = 0;
478500 cache_ptr->last_entry_removed_ptr = NULL;
479501
480 if(H5C__flush_single_entry(f, dxpl_id, flush_ptr, H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0)
502 if(H5C__flush_single_entry(f, dxpl_id, flush_ptr, H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG,
503 NULL, collective_write_list) < 0)
481504 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't flush entry.")
482505
483506 if ( ( cache_ptr->entries_removed_counter > 1 ) ||
636659 (long long)clear_ptr->addr);
637660 #endif /* H5C_APPLY_CANDIDATE_LIST__DEBUG */
638661
639 if(H5C__flush_single_entry(f, dxpl_id, clear_ptr, H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0)
662 if(H5C__flush_single_entry(f, dxpl_id, clear_ptr,
663 H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG,
664 NULL, NULL) < 0)
640665 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't clear entry.")
641666 } /* end else-if */
642667
652677 (long long)flush_ptr->addr);
653678 #endif /* H5C_APPLY_CANDIDATE_LIST__DEBUG */
654679
655 if(H5C__flush_single_entry(f, dxpl_id, flush_ptr, H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0)
680 if(H5C__flush_single_entry(f, dxpl_id, flush_ptr, H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG,
681 NULL, collective_write_list) < 0)
656682 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't clear entry.")
657683 } /* end else-if */
658684 } /* end if */
686712 if (delayed_ptr) {
687713
688714 if (delayed_ptr->clear_on_unprotect) {
715 if(H5C__flush_single_entry(f, dxpl_id, delayed_ptr, H5C__FLUSH_CLEAR_ONLY_FLAG,
716 NULL, NULL) < 0)
717 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't flush entry collectively.")
718
689719 entry_ptr->clear_on_unprotect = FALSE;
690720 entries_cleared++;
691721 } else if (delayed_ptr->flush_immediately) {
722 if(H5C__flush_single_entry(f, dxpl_id, delayed_ptr, H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG,
723 NULL, collective_write_list) < 0)
724 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't flush entry collectively.")
725
692726 entry_ptr->flush_immediately = FALSE;
693727 entries_flushed++;
694728 } /* end if */
695729
696 if(H5C__flush_single_entry(f, dxpl_id, delayed_ptr, H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0)
697 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't flush entry collectively.")
698
699730 entries_flushed_collectively++;
700731 entries_flushed_or_cleared_last++;
701732 } /* end if */
702733
734 if(f->coll_md_write) {
735 HDassert(collective_write_list);
736
737 /* Write collective list */
738 if(H5C_collective_write(f,
739 dxpl_id,
740 collective_write_list) < 0)
741 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't write metadata collectively")
742 }
703743 /* ====================================================================== *
704744 * Finished flushing everything. *
705745 * ====================================================================== */
718758 done:
719759 if(candidate_assignment_table != NULL)
720760 candidate_assignment_table = (int *)H5MM_xfree((void *)candidate_assignment_table);
761
762 if(collective_write_list)
763 if(H5SL_destroy(collective_write_list, H5C_collective_write_free, NULL) < 0)
764 HDONE_ERROR(H5E_CACHE, H5E_CANTFREE, FAIL, "failed to destroy skip list")
721765
722766 FUNC_LEAVE_NOAPI(ret_value)
723767 } /* H5C_apply_candidate_list() */
10821126 * scan the LRU list shortly, and clear all those entries
10831127 * not currently protected.
10841128 */
1129
1130 /* Make sure first that we clear the collective flag from
1131 it so it can be cleared */
1132 if(TRUE == entry_ptr->coll_access) {
1133 entry_ptr->coll_access = FALSE;
1134 H5C__REMOVE_FROM_COLL_LIST(cache_ptr, entry_ptr, FAIL)
1135 }
1136
10851137 entry_ptr->clear_on_unprotect = TRUE;
10861138 #if H5C_DO_SANITY_CHECKS
10871139 if ( entry_ptr->is_protected ) {
11421194 entry_ptr = entry_ptr->prev;
11431195 entries_cleared++;
11441196
1145 if(H5C__flush_single_entry(f, dxpl_id, clear_ptr, H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0)
1197 if(H5C__flush_single_entry(f, dxpl_id, clear_ptr,
1198 H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG,
1199 NULL, NULL) < 0)
11461200 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't clear entry.")
11471201 } else {
11481202
11701224 entry_ptr = entry_ptr->next;
11711225 entries_cleared++;
11721226
1173 if(H5C__flush_single_entry(f, dxpl_id, clear_ptr, H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG, NULL) < 0 )
1227 if(H5C__flush_single_entry(f, dxpl_id, clear_ptr,
1228 H5C__FLUSH_CLEAR_ONLY_FLAG | H5C__DEL_FROM_SLIST_ON_DESTROY_FLAG,
1229 NULL, NULL) < 0 )
11741230 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, FAIL, "Can't clear entry.")
11751231 } else {
11761232
12151271 FUNC_LEAVE_NOAPI(ret_value)
12161272
12171273 } /* H5C_mark_entries_as_clean() */
1274
1275
1276 /*-------------------------------------------------------------------------
1277 *
1278 * Function: H5C_clear_coll_entries
1279 *
1280 * Purpose: Clear half or the entire list of collective entries and
1281 * mark them as independent.
1282 *
1283 * Return: FAIL if error is detected, SUCCEED otherwise.
1284 *
1285 * Programmer: Mohamad Chaarawi
1286 * April, 2015
1287 *
1288 *-------------------------------------------------------------------------
1289 */
1290 herr_t
1291 H5C_clear_coll_entries(H5C_t * cache_ptr, hbool_t partial)
1292 {
1293 int32_t list_len, coll_entries_cleared = 0;
1294 H5C_cache_entry_t * entry_ptr = NULL;
1295 H5C_cache_entry_t * prev_ptr;
1296 herr_t ret_value = SUCCEED;
1297
1298 FUNC_ENTER_NOAPI_NOINIT
1299
1300 entry_ptr = cache_ptr->coll_tail_ptr;
1301 list_len = cache_ptr->coll_list_len;
1302
1303 while(entry_ptr && (coll_entries_cleared < (partial ? list_len/2 : list_len))) {
1304 prev_ptr = entry_ptr->coll_prev;
1305
1306 HDassert(entry_ptr->coll_access);
1307
1308 entry_ptr->coll_access = FALSE;
1309 H5C__REMOVE_FROM_COLL_LIST(cache_ptr, entry_ptr, FAIL)
1310 coll_entries_cleared ++;
1311
1312 entry_ptr = prev_ptr;
1313 }
1314
1315 done:
1316 FUNC_LEAVE_NOAPI(ret_value)
1317 } /* H5C_clear_coll_entries */
1318
1319 herr_t
1320 H5C_collective_write(H5F_t *f,
1321 hid_t dxpl_id,
1322 H5SL_t *collective_write_list)
1323 {
1324 H5P_genplist_t *plist = NULL;
1325 H5FD_mpio_xfer_t xfer_mode = H5FD_MPIO_COLLECTIVE;
1326 H5FD_mpio_xfer_t orig_xfer_mode;
1327 H5SL_node_t *node;
1328 H5C_collective_write_t *item;
1329 int count;
1330 void *base_buf;
1331 int *length_array = NULL;
1332 MPI_Aint *buf_array = NULL;
1333 MPI_Aint *offset_array = NULL;
1334 MPI_Datatype btype;
1335 MPI_Datatype ftype;
1336 hbool_t btype_created = FALSE;
1337 hbool_t ftype_created = FALSE;
1338 int mpi_code;
1339 int i;
1340 herr_t ret_value = SUCCEED;
1341
1342 FUNC_ENTER_NOAPI_NOINIT
1343
1344 count = (int)H5SL_count(collective_write_list);
1345
1346 if(NULL == (plist = (H5P_genplist_t *)H5I_object(dxpl_id)))
1347 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a data transfer property list")
1348
1349 if(H5P_get(plist, H5D_XFER_IO_XFER_MODE_NAME, &orig_xfer_mode) < 0)
1350 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set MPI-I/O property")
1351
1352 if(count > 0) {
1353 if(H5P_set(plist, H5D_XFER_IO_XFER_MODE_NAME, &xfer_mode) < 0)
1354 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set MPI-I/O property")
1355
1356 /* Allocate arrays */
1357 if(NULL == (length_array = (int *)H5MM_malloc((size_t)count * sizeof(int))))
1358 HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed for collective write table length array")
1359 if(NULL == (buf_array = (MPI_Aint *)H5MM_malloc((size_t)count * sizeof(MPI_Aint))))
1360 HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed for collective buf table length array")
1361 if(NULL == (offset_array = (MPI_Aint *)H5MM_malloc((size_t)count * sizeof(MPI_Aint))))
1362 HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed for collective offset table length array")
1363
1364 /* Fill arrays */
1365 node = H5SL_first(collective_write_list);
1366 HDassert(node);
1367 if(NULL == (item = (H5C_collective_write_t *)H5SL_item(node)))
1368 HGOTO_ERROR(H5E_CACHE, H5E_NOTFOUND, FAIL, "can't retrieve skip list item")
1369
1370 length_array[0] = (int)item->length;
1371 base_buf = item->buf;
1372 buf_array[0] = (MPI_Aint)0;
1373 offset_array[0] = (MPI_Aint)item->offset;
1374
1375 node = H5SL_next(node);
1376 i = 1;
1377 while(node) {
1378 if(NULL == (item = (H5C_collective_write_t *)H5SL_item(node)))
1379 HGOTO_ERROR(H5E_CACHE, H5E_NOTFOUND, FAIL, "can't retrieve skip list item")
1380
1381 length_array[i] = (int)item->length;
1382 buf_array[i] = (MPI_Aint)item->buf - (MPI_Aint)base_buf;
1383 offset_array[i] = (MPI_Aint)item->offset;
1384 node = H5SL_next(node);
1385 i++;
1386 } /* end while */
1387
1388 /* Create memory mpi type */
1389 if(MPI_SUCCESS != (mpi_code = MPI_Type_create_hindexed(count, length_array, buf_array, MPI_BYTE, &btype)))
1390 HMPI_GOTO_ERROR(FAIL, "MPI_Type_create_hindexed failed", mpi_code)
1391 btype_created = TRUE;
1392 if(MPI_SUCCESS != (mpi_code = MPI_Type_commit(&btype)))
1393 HMPI_GOTO_ERROR(FAIL, "MPI_Type_commit failed", mpi_code)
1394
1395 /* Create file mpi type */
1396 if(MPI_SUCCESS != (mpi_code = MPI_Type_create_hindexed(count, length_array, offset_array, MPI_BYTE, &ftype)))
1397 HMPI_GOTO_ERROR(FAIL, "MPI_Type_create_hindexed failed", mpi_code)
1398 ftype_created = TRUE;
1399 if(MPI_SUCCESS != (mpi_code = MPI_Type_commit(&ftype)))
1400 HMPI_GOTO_ERROR(FAIL, "MPI_Type_commit failed", mpi_code)
1401
1402 /* Pass buf type, file type to the file driver. */
1403 if(H5FD_mpi_setup_collective(dxpl_id, &btype, &ftype) < 0)
1404 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set MPI-I/O properties")
1405
1406 /* Write data */
1407 if(H5F_block_write(f, H5FD_MEM_DEFAULT, (haddr_t)0, (size_t)1, dxpl_id, base_buf) < 0)
1408 HGOTO_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL, "unable to write entries collectively")
1409 } /* end if */
1410 else {
1411 MPI_Status mpi_stat;
1412 MPI_File mpi_fh_p;
1413 MPI_File mpi_fh;
1414
1415 if(H5F_get_mpi_handle(f, (MPI_File **)&mpi_fh_p) < 0)
1416 HGOTO_ERROR(H5E_FILE, H5E_CANTGET, FAIL, "can't get mpi file handle")
1417 mpi_fh = *(MPI_File*)mpi_fh_p;
1418
1419 /* just to match up with the 1st MPI_File_set_view from H5FD_mpio_write() */
1420 if(MPI_SUCCESS != (mpi_code = MPI_File_set_view(mpi_fh, (MPI_Offset)0, MPI_BYTE,
1421 MPI_BYTE, "native", MPI_INFO_NULL)))
1422 HMPI_GOTO_ERROR(FAIL, "MPI_File_set_view failed", mpi_code)
1423
1424 /* just to match up with MPI_File_write_at_all from H5FD_mpio_write() */
1425 HDmemset(&mpi_stat, 0, sizeof(MPI_Status));
1426 if(MPI_SUCCESS != (mpi_code = MPI_File_write_at_all(mpi_fh, (MPI_Offset)0, NULL, 0,
1427 MPI_BYTE, &mpi_stat)))
1428 HMPI_GOTO_ERROR(FAIL, "MPI_File_write_at_all failed", mpi_code)
1429
1430 /* just to match up with the 2nd MPI_File_set_view (reset) in H5FD_mpio_write() */
1431 if(MPI_SUCCESS != (mpi_code = MPI_File_set_view(mpi_fh, (MPI_Offset)0, MPI_BYTE,
1432 MPI_BYTE, "native", MPI_INFO_NULL)))
1433 HMPI_GOTO_ERROR(FAIL, "MPI_File_set_view failed", mpi_code)
1434 } /* end else */
1435
1436 done:
1437 /* Free arrays */
1438 length_array = (int *)H5MM_xfree(length_array);
1439 buf_array = (MPI_Aint *)H5MM_xfree(buf_array);
1440 offset_array = (MPI_Aint *)H5MM_xfree(offset_array);
1441
1442 /* Free MPI Types */
1443 if(btype_created && MPI_SUCCESS != (mpi_code = MPI_Type_free(&btype)))
1444 HMPI_DONE_ERROR(FAIL, "MPI_Type_free failed", mpi_code)
1445 if(ftype_created && MPI_SUCCESS != (mpi_code = MPI_Type_free(&ftype)))
1446 HMPI_DONE_ERROR(FAIL, "MPI_Type_free failed", mpi_code)
1447
1448 /* Reset dxpl */
1449 if(orig_xfer_mode != H5FD_MPIO_COLLECTIVE) {
1450 HDassert(plist);
1451 if(H5P_set(plist, H5D_XFER_IO_XFER_MODE_NAME, &orig_xfer_mode) < 0)
1452 HDONE_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set MPI-I/O property")
1453 } /* end if */
1454
1455 FUNC_LEAVE_NOAPI(ret_value);
1456 } /* end H5C_collective_write() */
1457
1458 herr_t
1459 H5C_collective_write_free(void *_item, void H5_ATTR_UNUSED *key, void H5_ATTR_UNUSED *op_data)
1460 {
1461 H5C_collective_write_t *item = (H5C_collective_write_t *)_item;
1462
1463 FUNC_ENTER_NOAPI_NOINIT_NOERR
1464
1465 HDassert(item);
1466
1467 if(item->free_buf)
1468 item->buf = H5MM_xfree(item->buf);
1469 /*!FIXME change to use free list for items */
1470 H5MM_free(item);
1471
1472 FUNC_LEAVE_NOAPI(SUCCEED)
1473 } /* end H5C_collective_write_free() */
12181474 #endif /* H5_HAVE_PARALLEL */
12191475
25322532 HDassert( ((entry_ptr)->ro_ref_count) == 0 ); \
25332533 HDassert( (entry_ptr)->size > 0 ); \
25342534 HDassert( new_size > 0 ); \
2535 \
2535 \
2536 if ( (entry_ptr)->coll_access ) { \
2537 \
2538 H5C__DLL_UPDATE_FOR_SIZE_CHANGE((cache_ptr)->coll_list_len, \
2539 (cache_ptr)->coll_list_size, \
2540 (entry_ptr)->size, \
2541 (new_size)); \
2542 \
2543 } \
2544 \
25362545 if ( (entry_ptr)->is_pinned ) { \
25372546 \
25382547 H5C__DLL_UPDATE_FOR_SIZE_CHANGE((cache_ptr)->pel_len, \
28822891
28832892 #endif /* H5C_MAINTAIN_CLEAN_AND_DIRTY_LRU_LISTS */
28842893
2894 #ifdef H5_HAVE_PARALLEL
2895
2896 #if H5C_DO_SANITY_CHECKS
2897
2898 #define H5C__COLL_DLL_PRE_REMOVE_SC(entry_ptr, hd_ptr, tail_ptr, len, Size, fv) \
2899 if ( ( (hd_ptr) == NULL ) || \
2900 ( (tail_ptr) == NULL ) || \
2901 ( (entry_ptr) == NULL ) || \
2902 ( (len) <= 0 ) || \
2903 ( (Size) < (entry_ptr)->size ) || \
2904 ( ( (Size) == (entry_ptr)->size ) && ( ! ( (len) == 1 ) ) ) || \
2905 ( ( (entry_ptr)->coll_prev == NULL ) && ( (hd_ptr) != (entry_ptr) ) ) || \
2906 ( ( (entry_ptr)->coll_next == NULL ) && ( (tail_ptr) != (entry_ptr) ) ) || \
2907 ( ( (len) == 1 ) && \
2908 ( ! ( ( (hd_ptr) == (entry_ptr) ) && ( (tail_ptr) == (entry_ptr) ) && \
2909 ( (entry_ptr)->coll_next == NULL ) && \
2910 ( (entry_ptr)->coll_prev == NULL ) && \
2911 ( (Size) == (entry_ptr)->size ) \
2912 ) \
2913 ) \
2914 ) \
2915 ) { \
2916 HDassert(0 && "coll DLL pre remove SC failed"); \
2917 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, (fv), "coll DLL pre remove SC failed") \
2918 }
2919
2920 #define H5C__COLL_DLL_SC(head_ptr, tail_ptr, len, Size, fv) \
2921 if ( ( ( ( (head_ptr) == NULL ) || ( (tail_ptr) == NULL ) ) && \
2922 ( (head_ptr) != (tail_ptr) ) \
2923 ) || \
2924 ( (len) < 0 ) || \
2925 ( (Size) < 0 ) || \
2926 ( ( (len) == 1 ) && \
2927 ( ( (head_ptr) != (tail_ptr) ) || ( (Size) <= 0 ) || \
2928 ( (head_ptr) == NULL ) || ( (head_ptr)->size != (Size) ) \
2929 ) \
2930 ) || \
2931 ( ( (len) >= 1 ) && \
2932 ( ( (head_ptr) == NULL ) || ( (head_ptr)->coll_prev != NULL ) || \
2933 ( (tail_ptr) == NULL ) || ( (tail_ptr)->coll_next != NULL ) \
2934 ) \
2935 ) \
2936 ) { \
2937 HDassert(0 && "COLL DLL sanity check failed"); \
2938 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, (fv), "COLL DLL sanity check failed") \
2939 }
2940
2941 #define H5C__COLL_DLL_PRE_INSERT_SC(entry_ptr, hd_ptr, tail_ptr, len, Size, fv) \
2942 if ( ( (entry_ptr) == NULL ) || \
2943 ( (entry_ptr)->coll_next != NULL ) || \
2944 ( (entry_ptr)->coll_prev != NULL ) || \
2945 ( ( ( (hd_ptr) == NULL ) || ( (tail_ptr) == NULL ) ) && \
2946 ( (hd_ptr) != (tail_ptr) ) \
2947 ) || \
2948 ( (len) < 0 ) || \
2949 ( ( (len) == 1 ) && \
2950 ( ( (hd_ptr) != (tail_ptr) ) || ( (Size) <= 0 ) || \
2951 ( (hd_ptr) == NULL ) || ( (hd_ptr)->size != (Size) ) \
2952 ) \
2953 ) || \
2954 ( ( (len) >= 1 ) && \
2955 ( ( (hd_ptr) == NULL ) || ( (hd_ptr)->coll_prev != NULL ) || \
2956 ( (tail_ptr) == NULL ) || ( (tail_ptr)->coll_next != NULL ) \
2957 ) \
2958 ) \
2959 ) { \
2960 HDassert(0 && "COLL DLL pre insert SC failed"); \
2961 HGOTO_ERROR(H5E_CACHE, H5E_SYSTEM, (fv), "COLL DLL pre insert SC failed") \
2962 }
2963
2964 #else /* H5C_DO_SANITY_CHECKS */
2965
2966 #define H5C__COLL_DLL_PRE_REMOVE_SC(entry_ptr, hd_ptr, tail_ptr, len, Size, fv)
2967 #define H5C__COLL_DLL_SC(head_ptr, tail_ptr, len, Size, fv)
2968 #define H5C__COLL_DLL_PRE_INSERT_SC(entry_ptr, hd_ptr, tail_ptr, len, Size, fv)
2969
2970 #endif /* H5C_DO_SANITY_CHECKS */
2971
2972
2973 #define H5C__COLL_DLL_APPEND(entry_ptr, head_ptr, tail_ptr, len, Size, fail_val) \
2974 { \
2975 H5C__COLL_DLL_PRE_INSERT_SC(entry_ptr, head_ptr, tail_ptr, len, Size, \
2976 fail_val) \
2977 if ( (head_ptr) == NULL ) \
2978 { \
2979 (head_ptr) = (entry_ptr); \
2980 (tail_ptr) = (entry_ptr); \
2981 } \
2982 else \
2983 { \
2984 (tail_ptr)->coll_next = (entry_ptr); \
2985 (entry_ptr)->coll_prev = (tail_ptr); \
2986 (tail_ptr) = (entry_ptr); \
2987 } \
2988 (len)++; \
2989 (Size) += entry_ptr->size; \
2990 } /* H5C__COLL_DLL_APPEND() */
2991
2992 #define H5C__COLL_DLL_PREPEND(entry_ptr, head_ptr, tail_ptr, len, Size, fv) \
2993 { \
2994 H5C__COLL_DLL_PRE_INSERT_SC(entry_ptr, head_ptr, tail_ptr, len, Size, fv)\
2995 if ( (head_ptr) == NULL ) \
2996 { \
2997 (head_ptr) = (entry_ptr); \
2998 (tail_ptr) = (entry_ptr); \
2999 } \
3000 else \
3001 { \
3002 (head_ptr)->coll_prev = (entry_ptr); \
3003 (entry_ptr)->coll_next = (head_ptr); \
3004 (head_ptr) = (entry_ptr); \
3005 } \
3006 (len)++; \
3007 (Size) += entry_ptr->size; \
3008 } /* H5C__COLL_DLL_PREPEND() */
3009
3010 #define H5C__COLL_DLL_REMOVE(entry_ptr, head_ptr, tail_ptr, len, Size, fv) \
3011 { \
3012 H5C__COLL_DLL_PRE_REMOVE_SC(entry_ptr, head_ptr, tail_ptr, len, Size, fv)\
3013 { \
3014 if ( (head_ptr) == (entry_ptr) ) \
3015 { \
3016 (head_ptr) = (entry_ptr)->coll_next; \
3017 if ( (head_ptr) != NULL ) \
3018 (head_ptr)->coll_prev = NULL; \
3019 } \
3020 else \
3021 { \
3022 (entry_ptr)->coll_prev->coll_next = (entry_ptr)->coll_next; \
3023 } \
3024 if ( (tail_ptr) == (entry_ptr) ) \
3025 { \
3026 (tail_ptr) = (entry_ptr)->coll_prev; \
3027 if ( (tail_ptr) != NULL ) \
3028 (tail_ptr)->coll_next = NULL; \
3029 } \
3030 else \
3031 (entry_ptr)->coll_next->coll_prev = (entry_ptr)->coll_prev; \
3032 entry_ptr->coll_next = NULL; \
3033 entry_ptr->coll_prev = NULL; \
3034 (len)--; \
3035 (Size) -= entry_ptr->size; \
3036 } \
3037 } /* H5C__COLL_DLL_REMOVE() */
3038
3039
3040 /*-------------------------------------------------------------------------
3041 *
3042 * Macro: H5C__INSERT_IN_COLL_LIST
3043 *
3044 * Purpose: Insert entry into collective entries list
3045 *
3046 * Return: N/A
3047 *
3048 * Programmer: Mohamad Chaarawi
3049 *
3050 *-------------------------------------------------------------------------
3051 */
3052
3053 #define H5C__INSERT_IN_COLL_LIST(cache_ptr, entry_ptr, fail_val) \
3054 { \
3055 HDassert( (cache_ptr) ); \
3056 HDassert( (cache_ptr)->magic == H5C__H5C_T_MAGIC ); \
3057 HDassert( (entry_ptr) ); \
3058 \
3059 /* insert the entry at the head of the list. */ \
3060 \
3061 H5C__COLL_DLL_PREPEND((entry_ptr), (cache_ptr)->coll_head_ptr, \
3062 (cache_ptr)->coll_tail_ptr, \
3063 (cache_ptr)->coll_list_len, \
3064 (cache_ptr)->coll_list_size, \
3065 (fail_val)) \
3066 \
3067 } /* H5C__INSERT_IN_COLL_LIST */
3068
3069
3070 /*-------------------------------------------------------------------------
3071 *
3072 * Macro: H5C__REMOVE_FROM_COLL_LIST
3073 *
3074 * Purpose: Remove entry from collective entries list
3075 *
3076 * Return: N/A
3077 *
3078 * Programmer: Mohamad Chaarawi
3079 *
3080 *-------------------------------------------------------------------------
3081 */
3082
3083 #define H5C__REMOVE_FROM_COLL_LIST(cache_ptr, entry_ptr, fail_val) \
3084 { \
3085 HDassert( (cache_ptr) ); \
3086 HDassert( (cache_ptr)->magic == H5C__H5C_T_MAGIC ); \
3087 HDassert( (entry_ptr) ); \
3088 \
3089 /* remove the entry from the list. */ \
3090 \
3091 H5C__COLL_DLL_REMOVE((entry_ptr), (cache_ptr)->coll_head_ptr, \
3092 (cache_ptr)->coll_tail_ptr, \
3093 (cache_ptr)->coll_list_len, \
3094 (cache_ptr)->coll_list_size, \
3095 (fail_val)) \
3096 \
3097 } /* H5C__REMOVE_FROM_COLL_LIST */
3098
3099
3100 /*-------------------------------------------------------------------------
3101 *
3102 * Macro: H5C__MOVE_TO_TOP_IN_COLL_LIST
3103 *
3104 * Purpose: Update entry position in collective entries list
3105 *
3106 * Return: N/A
3107 *
3108 * Programmer: Mohamad Chaarawi
3109 *
3110 *-------------------------------------------------------------------------
3111 */
3112
3113 #define H5C__MOVE_TO_TOP_IN_COLL_LIST(cache_ptr, entry_ptr, fail_val) \
3114 { \
3115 HDassert( (cache_ptr) ); \
3116 HDassert( (cache_ptr)->magic == H5C__H5C_T_MAGIC ); \
3117 HDassert( (entry_ptr) ); \
3118 \
3119 /* Remove entry and insert at the head of the list. */ \
3120 H5C__COLL_DLL_REMOVE((entry_ptr), (cache_ptr)->coll_head_ptr, \
3121 (cache_ptr)->coll_tail_ptr, \
3122 (cache_ptr)->coll_list_len, \
3123 (cache_ptr)->coll_list_size, \
3124 (fail_val)) \
3125 \
3126 H5C__COLL_DLL_PREPEND((entry_ptr), (cache_ptr)->coll_head_ptr, \
3127 (cache_ptr)->coll_tail_ptr, \
3128 (cache_ptr)->coll_list_len, \
3129 (cache_ptr)->coll_list_size, \
3130 (fail_val)) \
3131 \
3132 } /* H5C__MOVE_TO_TOP_IN_COLL_LIST */
3133 #endif /* H5_HAVE_PARALLEL */
3134
28853135
28863136 /****************************/
28873137 /* Package Private Typedefs */
39074157 size_t dLRU_list_size;
39084158 H5C_cache_entry_t * dLRU_head_ptr;
39094159 H5C_cache_entry_t * dLRU_tail_ptr;
4160
4161 #ifdef H5_HAVE_PARALLEL
4162 int32_t coll_list_len;
4163 size_t coll_list_size;
4164 H5C_cache_entry_t * coll_head_ptr;
4165 H5C_cache_entry_t * coll_tail_ptr;
4166 #endif /* H5_HAVE_PARALLEL */
39104167
39114168 /* Fields for automatic cache size adjustment */
39124169 hbool_t size_increase_possible;
40114268 #endif /* NDEBUG */
40124269 };
40134270
4271 #ifdef H5_HAVE_PARALLEL
4272 typedef struct H5C_collective_write_t {
4273 size_t length;
4274 hbool_t free_buf;
4275 void *buf;
4276 haddr_t offset;
4277 } H5C_collective_write_t;
4278 #endif /* H5_HAVE_PARALLEL */
4279
40144280 /*****************************/
40154281 /* Package Private Variables */
40164282 /*****************************/
40204286 /* Package Private Prototypes */
40214287 /******************************/
40224288 H5_DLL herr_t H5C__flush_single_entry(const H5F_t *f, hid_t dxpl_id,
4023 H5C_cache_entry_t *entry_ptr, unsigned flags, int64_t *entry_size_change_ptr);
4289 H5C_cache_entry_t *entry_ptr, unsigned flags, int64_t *entry_size_change_ptr, H5SL_t *collective_write_list);
4290 #ifdef H5_HAVE_PARALLEL
4291 H5_DLL herr_t H5C_collective_write(H5F_t *f, hid_t dxpl_id, H5SL_t *collective_write_list);
4292 H5_DLL herr_t H5C_collective_write_free(void *_item, void *key, void *op_data);
4293 #endif /* H5_HAVE_PARALLEL */
40244294
40254295 #endif /* _H5Cpkg_H */
40264296
17131713 hbool_t flush_me_collectively;
17141714 hbool_t clear_on_unprotect;
17151715 hbool_t flush_immediately;
1716 hbool_t coll_access;
1717 hbool_t ind_access_while_coll;
17161718 #endif /* H5_HAVE_PARALLEL */
17171719 hbool_t flush_in_progress;
17181720 hbool_t destroy_in_progress;
17381740 struct H5C_cache_entry_t * prev;
17391741 struct H5C_cache_entry_t * aux_next;
17401742 struct H5C_cache_entry_t * aux_prev;
1743 struct H5C_cache_entry_t * coll_next;
1744 struct H5C_cache_entry_t * coll_prev;
17411745
17421746 #if H5C_COLLECT_CACHE_ENTRY_STATS
17431747 /* cache entry stats fields */
21162120 int mpi_rank, int mpi_size);
21172121 H5_DLL herr_t H5C_construct_candidate_list__clean_cache(H5C_t *cache_ptr);
21182122 H5_DLL herr_t H5C_construct_candidate_list__min_clean(H5C_t *cache_ptr);
2123 H5_DLL herr_t H5C_clear_coll_entries(H5C_t * cache_ptr, hbool_t partial);
21192124 H5_DLL herr_t H5C_mark_entries_as_clean(H5F_t *f, hid_t dxpl_id, int32_t ce_array_len,
21202125 haddr_t *ce_array_ptr);
21212126 #endif /* H5_HAVE_PARALLEL */
108108 H5G_loc_t loc; /* Object location to insert dataset into */
109109 H5D_t *dset = NULL; /* New dataset's info */
110110 const H5S_t *space; /* Dataspace for dataset */
111 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
111112 hid_t ret_value; /* Return value */
112113
113114 FUNC_ENTER_API(FAIL)
136137 if(TRUE != H5P_isa_class(dcpl_id, H5P_DATASET_CREATE))
137138 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not dataset create property list ID")
138139
139 /* Get correct property list */
140 if(H5P_DEFAULT == dapl_id)
141 dapl_id = H5P_DATASET_ACCESS_DEFAULT;
142 else
143 if(TRUE != H5P_isa_class(dapl_id, H5P_DATASET_ACCESS))
144 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not dataset access property list")
140 /* Verify access property list and get correct dxpl */
141 if(H5P_verify_and_set_dxpl(&dapl_id, H5P_DATASET_ACCESS, H5P_DATASET_ACCESS_DEFAULT, &dxpl_id) < 0)
142 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
145143
146144 /* Create the new dataset & get its ID */
147 if(NULL == (dset = H5D__create_named(&loc, name, type_id, space, lcpl_id, dcpl_id, dapl_id, H5AC_dxpl_id)))
145 if(NULL == (dset = H5D__create_named(&loc, name, type_id, space, lcpl_id, dcpl_id, dapl_id, dxpl_id)))
148146 HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to create dataset")
149147 if((ret_value = H5I_register(H5I_DATASET, dset, TRUE)) < 0)
150148 HGOTO_ERROR(H5E_DATASET, H5E_CANTREGISTER, FAIL, "unable to register dataset")
200198 H5G_loc_t loc; /* Object location to insert dataset into */
201199 H5D_t *dset = NULL; /* New dataset's info */
202200 const H5S_t *space; /* Dataspace for dataset */
201 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
203202 hid_t ret_value; /* Return value */
204203
205204 FUNC_ENTER_API(FAIL)
218217 if(TRUE != H5P_isa_class(dcpl_id, H5P_DATASET_CREATE))
219218 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not dataset create property list ID")
220219
221 /* Get correct property list */
222 if(H5P_DEFAULT == dapl_id)
223 dapl_id = H5P_DATASET_ACCESS_DEFAULT;
224 else
225 if(TRUE != H5P_isa_class(dapl_id, H5P_DATASET_ACCESS))
226 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not dataset access property list")
220 /* Verify access property list and get correct dxpl */
221 if(H5P_verify_and_set_dxpl(&dapl_id, H5P_DATASET_ACCESS, H5P_DATASET_ACCESS_DEFAULT, &dxpl_id) < 0)
222 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
227223
228224 /* build and open the new dataset */
229 if(NULL == (dset = H5D__create(loc.oloc->file, type_id, space, dcpl_id, dapl_id, H5AC_dxpl_id)))
225 if(NULL == (dset = H5D__create(loc.oloc->file, type_id, space, dcpl_id, dapl_id, dxpl_id)))
230226 HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to create dataset")
231227
232228 /* Register the new dataset to get an ID for it */
243239 HDONE_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "unable to get object location of dataset")
244240
245241 /* Decrement refcount on dataset's object header in memory */
246 if(H5O_dec_rc_by_loc(oloc, H5AC_dxpl_id) < 0)
242 if(H5O_dec_rc_by_loc(oloc, dxpl_id) < 0)
247243 HDONE_ERROR(H5E_DATASET, H5E_CANTDEC, FAIL, "unable to decrement refcount on newly created object")
248244 } /* end if */
249245
290286 if(!name || !*name)
291287 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name")
292288
293 /* Get correct property list */
294 if(H5P_DEFAULT == dapl_id)
295 dapl_id = H5P_DATASET_ACCESS_DEFAULT;
296 else
297 if(TRUE != H5P_isa_class(dapl_id, H5P_DATASET_ACCESS))
298 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not dataset access property list")
289 /* Verify access property list and get correct dxpl */
290 if(H5P_verify_and_set_dxpl(&dapl_id, H5P_DATASET_ACCESS, H5P_DATASET_ACCESS_DEFAULT, &dxpl_id) < 0)
291 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
299292
300293 /* Open the dataset */
301294 if(NULL == (dset = H5D__open_name(&loc, name, dapl_id, dxpl_id)))
309302 if(ret_value < 0)
310303 if(dset && H5D_close(dset) < 0)
311304 HDONE_ERROR(H5E_DATASET, H5E_CLOSEERROR, FAIL, "unable to release dataset")
312
313305 FUNC_LEAVE_API(ret_value)
314306 } /* end H5Dopen2() */
315307
917909 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no size specified")
918910
919911 /* Private function */
920 if(H5D__set_extent(dset, size, H5AC_dxpl_id) < 0)
921 HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to set extend dataset")
912 if(H5D__set_extent(dset, size, H5AC_coll_write_coll_read_dxpl_id) < 0)
913 HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to set extent on dataset")
922914
923915 done:
924916 FUNC_LEAVE_API(ret_value)
10131013 HDassert(H5F_addr_defined(udata->chunk_block.offset));
10141014
10151015 /* Check if the v2 B-tree is open yet */
1016 if(NULL == idx_info->storage->u.btree2.bt2)
1016 if(NULL == idx_info->storage->u.btree2.bt2) {
10171017 /* Open existing v2 B-tree */
10181018 if(H5D__bt2_idx_open(idx_info) < 0)
10191019 HGOTO_ERROR(H5E_DATASET, H5E_CANTOPENOBJ, FAIL, "can't open v2 B-tree")
1020 } else /* Patch the top level file pointer contained in bt2 if needed */
1021 H5B2_patch_file(idx_info->storage->u.btree2.bt2, idx_info->f);
10201022
10211023 /* Set convenience pointer to v2 B-tree structure */
10221024 bt2 = idx_info->storage->u.btree2.bt2;
11131115 HDassert(udata);
11141116
11151117 /* Check if the v2 B-tree is open yet */
1116 if(NULL == idx_info->storage->u.btree2.bt2)
1118 if(NULL == idx_info->storage->u.btree2.bt2) {
11171119 /* Open existing v2 B-tree */
11181120 if(H5D__bt2_idx_open(idx_info) < 0)
11191121 HGOTO_ERROR(H5E_DATASET, H5E_CANTOPENOBJ, FAIL, "can't open v2 B-tree")
1122 } else /* Patch the top level file pointer contained in bt2 if needed */
1123 H5B2_patch_file(idx_info->storage->u.btree2.bt2, idx_info->f);
11201124
11211125 /* Set convenience pointer to v2 B-tree structure */
11221126 bt2 = idx_info->storage->u.btree2.bt2;
12321236 HDassert(chunk_udata);
12331237
12341238 /* Check if the v2 B-tree is open yet */
1235 if(NULL == idx_info->storage->u.btree2.bt2)
1239 if(NULL == idx_info->storage->u.btree2.bt2) {
12361240 /* Open existing v2 B-tree */
12371241 if(H5D__bt2_idx_open(idx_info) < 0)
12381242 HGOTO_ERROR(H5E_DATASET, H5E_CANTOPENOBJ, FAIL, "can't open v2 B-tree")
1243 } else /* Patch the top level file pointer contained in bt2 if needed */
1244 H5B2_patch_file(idx_info->storage->u.btree2.bt2, idx_info->f);
12391245
12401246 /* Set convenience pointer to v2 B-tree structure */
12411247 bt2 = idx_info->storage->u.btree2.bt2;
4444 /****************/
4545
4646 #include "H5Dmodule.h" /* This source code file is part of the H5D module */
47
47 #define H5F_FRIEND /*suppress error about including H5Fpkg */
4848
4949 /***********/
5050 /* Headers */
5555 #endif /* H5_HAVE_PARALLEL */
5656 #include "H5Dpkg.h" /* Dataset functions */
5757 #include "H5Eprivate.h" /* Error handling */
58 #include "H5Fpkg.h" /* File functions */
5859 #include "H5FLprivate.h" /* Free Lists */
5960 #include "H5Iprivate.h" /* IDs */
6061 #include "H5MMprivate.h" /* Memory management */
106107
107108 /*#define H5D_CHUNK_DEBUG */
108109
110 /* Flags for the "edge_chunk_state" field below */
111 #define H5D_RDCC_DISABLE_FILTERS 0x01u /* Disable filters on this chunk */
112 #define H5D_RDCC_NEWLY_DISABLED_FILTERS 0x02u /* Filters have been disabled since
113 * the last flush */
114
109115
110116 /******************/
111117 /* Local Typedefs */
112118 /******************/
119
120 /* Raw data chunks are cached. Each entry in the cache is: */
121 typedef struct H5D_rdcc_ent_t {
122 hbool_t locked; /*entry is locked in cache */
123 hbool_t dirty; /*needs to be written to disk? */
124 hbool_t deleted; /*chunk about to be deleted */
125 unsigned edge_chunk_state; /*states related to edge chunks (see above) */
126 hsize_t scaled[H5O_LAYOUT_NDIMS]; /*scaled chunk 'name' (coordinates) */
127 uint32_t rd_count; /*bytes remaining to be read */
128 uint32_t wr_count; /*bytes remaining to be written */
129 H5F_block_t chunk_block; /*offset/length of chunk in file */
130 hsize_t chunk_idx; /*index of chunk in dataset */
131 uint8_t *chunk; /*the unfiltered chunk data */
132 unsigned idx; /*index in hash table */
133 struct H5D_rdcc_ent_t *next;/*next item in doubly-linked list */
134 struct H5D_rdcc_ent_t *prev;/*previous item in doubly-linked list */
135 struct H5D_rdcc_ent_t *tmp_next;/*next item in temporary doubly-linked list */
136 struct H5D_rdcc_ent_t *tmp_prev;/*previous item in temporary doubly-linked list */
137 } H5D_rdcc_ent_t;
138 typedef H5D_rdcc_ent_t *H5D_rdcc_ent_ptr_t; /* For free lists */
113139
114140 /* Callback info for iteration to prune chunks */
115141 typedef struct H5D_chunk_it_ud1_t {
262288 const H5D_dxpl_cache_t *dxpl_cache, H5D_rdcc_ent_t *ent, hbool_t flush);
263289 static hbool_t H5D__chunk_is_partial_edge_chunk(const hsize_t *chunk_scaled,
264290 unsigned dset_ndims, const hsize_t *dset_dims, const uint32_t *chunk_dims);
291 static void *H5D__chunk_lock(const H5D_io_info_t *io_info,
292 H5D_chunk_ud_t *udata, hbool_t relax, hbool_t prev_unfilt_chunk);
293 static herr_t H5D__chunk_unlock(const H5D_io_info_t *io_info,
294 const H5D_chunk_ud_t *udata, hbool_t dirty, void *chunk,
295 uint32_t naccessed);
265296 static herr_t H5D__chunk_cache_prune(const H5D_t *dset, hid_t dxpl_id,
266297 const H5D_dxpl_cache_t *dxpl_cache, size_t size);
267298 static herr_t H5D__chunk_prune_fill(H5D_chunk_it_ud1_t *udata, hbool_t new_unfilt_chunk);
26592690 /* Check for cached information */
26602691 if(!H5D__chunk_cinfo_cache_found(&dset->shared->cache.chunk.last, udata)) {
26612692 H5D_chk_idx_info_t idx_info; /* Chunked index info */
2693 #ifdef H5_HAVE_PARALLEL
2694 H5P_coll_md_read_flag_t temp_flag; /* temp flag to hold the coll metadata read setting */
2695 #endif /* H5_HAVE_PARALLEL */
26622696
26632697 /* Compose chunked index info struct */
26642698 idx_info.f = dset->oloc.file;
26672701 idx_info.layout = &dset->shared->layout.u.chunk;
26682702 idx_info.storage = &dset->shared->layout.storage.u.chunk;
26692703
2704 #ifdef H5_HAVE_PARALLEL
2705 if(H5F_HAS_FEATURE(idx_info.f, H5FD_FEAT_HAS_MPI)) {
2706 /* disable collective metadata read for chunk indexes
2707 as it is highly unlikely that users would read the
2708 same chunks from all processes. MSC - might turn on
2709 for root node? */
2710 temp_flag = idx_info.f->coll_md_read;
2711 idx_info.f->coll_md_read = H5P_FORCE_FALSE;
2712 }
2713 #endif /* H5_HAVE_PARALLEL */
2714
26702715 /* Go get the chunk information */
26712716 if((dset->shared->layout.storage.u.chunk.ops->get_addr)(&idx_info, udata) < 0)
26722717 HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't query chunk address")
2718
2719 #ifdef H5_HAVE_PARALLEL
2720 if(H5F_HAS_FEATURE(idx_info.f, H5FD_FEAT_HAS_MPI)) {
2721 idx_info.f->coll_md_read = temp_flag;
2722 }
2723 #endif /* H5_HAVE_PARALLEL */
26732724
26742725 /* Cache the information retrieved */
26752726 H5D__chunk_cinfo_cache_update(&dset->shared->cache.chunk.last, udata);
30833134 *
30843135 *-------------------------------------------------------------------------
30853136 */
3086 void *
3137 static void *
30873138 H5D__chunk_lock(const H5D_io_info_t *io_info, H5D_chunk_ud_t *udata,
30883139 hbool_t relax, hbool_t prev_unfilt_chunk)
30893140 {
31013152 void *chunk = NULL; /*the file chunk */
31023153 void *ret_value = NULL; /* Return value */
31033154
3104 FUNC_ENTER_PACKAGE
3155 FUNC_ENTER_STATIC
31053156
31063157 HDassert(io_info);
31073158 HDassert(io_info->dxpl_cache);
34793530 *
34803531 *-------------------------------------------------------------------------
34813532 */
3482 herr_t
3533 static herr_t
34833534 H5D__chunk_unlock(const H5D_io_info_t *io_info, const H5D_chunk_ud_t *udata,
34843535 hbool_t dirty, void *chunk, uint32_t naccessed)
34853536 {
34873538 const H5D_rdcc_t *rdcc = &(io_info->dset->shared->cache.chunk);
34883539 herr_t ret_value = SUCCEED; /* Return value */
34893540
3490 FUNC_ENTER_PACKAGE
3541 FUNC_ENTER_STATIC
34913542
34923543 HDassert(io_info);
34933544 HDassert(udata);
40034054 write collectively at the end */
40044055 /* allocate/resize address array if no more space left */
40054056 if(0 == chunk_info.num_io % 1024)
4006 if(NULL == (chunk_info.addr = (haddr_t *)HDrealloc(chunk_info.addr, (chunk_info.num_io + 1024) * sizeof(haddr_t))))
4057 if(NULL == (chunk_info.addr = (haddr_t *)H5MM_realloc(chunk_info.addr, (chunk_info.num_io + 1024) * sizeof(haddr_t))))
40074058 HGOTO_ERROR(H5E_DATASET, H5E_CANTALLOC, FAIL, "memory allocation failed for chunk addresses")
40084059
40094060 /* Store the chunk's address for later */
40964147
40974148 #ifdef H5_HAVE_PARALLEL
40984149 if(using_mpi && chunk_info.addr)
4099 HDfree(chunk_info.addr);
4150 H5MM_free(chunk_info.addr);
41004151 #endif
41014152
41024153 FUNC_LEAVE_NOAPI_TAG(ret_value, FAIL)
439439 HDassert(storage_src);
440440 HDassert(f_dst);
441441 HDassert(storage_dst);
442 HDassert(storage_dst->buf);
442443 HDassert(dt_src);
443444
444445 /* Create datatype ID for src datatype, so it gets freed */
140140 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not dataset create property list ID")
141141
142142 /* Build and open the new dataset */
143 if(NULL == (dset = H5D__create_named(&loc, name, type_id, space, H5P_LINK_CREATE_DEFAULT, dcpl_id, H5P_DATASET_ACCESS_DEFAULT, H5AC_dxpl_id)))
143 if(NULL == (dset = H5D__create_named(&loc, name, type_id, space, H5P_LINK_CREATE_DEFAULT,
144 dcpl_id, H5P_DATASET_ACCESS_DEFAULT, H5AC_dxpl_id)))
144145 HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to create dataset")
145146
146147 /* Register the new dataset to get an ID for it */
10371037 HDassert(udata);
10381038
10391039 /* Check if the extensible array is open yet */
1040 if(NULL == idx_info->storage->u.earray.ea)
1040 if(NULL == idx_info->storage->u.earray.ea) {
10411041 /* Open the extensible array in file */
10421042 if(H5D__earray_idx_open(idx_info) < 0)
10431043 HGOTO_ERROR(H5E_DATASET, H5E_CANTOPENOBJ, FAIL, "can't open extensible array")
1044 } else /* Patch the top level file pointer contained in ea if needed */
1045 H5EA_patch_file(idx_info->storage->u.earray.ea, idx_info->f);
10441046
10451047 /* Set convenience pointer to extensible array structure */
10461048 ea = idx_info->storage->u.earray.ea;
11061108 HDassert(udata);
11071109
11081110 /* Check if the extensible array is open yet */
1109 if(NULL == idx_info->storage->u.earray.ea)
1111 if(NULL == idx_info->storage->u.earray.ea) {
11101112 /* Open the extensible array in file */
11111113 if(H5D__earray_idx_open(idx_info) < 0)
11121114 HGOTO_ERROR(H5E_DATASET, H5E_CANTOPENOBJ, FAIL, "can't open extensible array")
1115 } else /* Patch the top level file pointer contained in ea if needed */
1116 H5EA_patch_file(idx_info->storage->u.earray.ea, idx_info->f);
11131117
11141118 /* Set convenience pointer to extensible array structure */
11151119 ea = idx_info->storage->u.earray.ea;
13081312 HDassert(chunk_udata);
13091313
13101314 /* Check if the extensible array is open yet */
1311 if(NULL == idx_info->storage->u.earray.ea)
1315 if(NULL == idx_info->storage->u.earray.ea) {
13121316 /* Open the extensible array in file */
13131317 if(H5D__earray_idx_open(idx_info) < 0)
13141318 HGOTO_ERROR(H5E_DATASET, H5E_CANTOPENOBJ, FAIL, "can't open extensible array")
1319 } else /* Patch the top level file pointer contained in ea if needed */
1320 H5EA_patch_file(idx_info->storage->u.earray.ea, idx_info->f);
13151321
13161322 /* Set convenience pointer to extensible array structure */
13171323 ea = idx_info->storage->u.earray.ea;
988988 HDassert(udata);
989989
990990 /* Check if the fixed array is open yet */
991 if(NULL == idx_info->storage->u.farray.fa)
991 if(NULL == idx_info->storage->u.farray.fa) {
992992 /* Open the fixed array in file */
993993 if(H5D__farray_idx_open(idx_info) < 0)
994994 HGOTO_ERROR(H5E_DATASET, H5E_CANTOPENOBJ, FAIL, "can't open fixed array")
995 } else /* Patch the top level file pointer contained in fa if needed */
996 H5FA_patch_file(idx_info->storage->u.farray.fa, idx_info->f);
995997
996998 /* Set convenience pointer to fixed array structure */
997999 fa = idx_info->storage->u.farray.fa;
10571059 HDassert(udata);
10581060
10591061 /* Check if the fixed array is open yet */
1060 if(NULL == idx_info->storage->u.farray.fa)
1062 if(NULL == idx_info->storage->u.farray.fa) {
10611063 /* Open the fixed array in file */
10621064 if(H5D__farray_idx_open(idx_info) < 0)
10631065 HGOTO_ERROR(H5E_DATASET, H5E_CANTOPENOBJ, FAIL, "can't open fixed array")
1066 } else /* Patch the top level file pointer contained in fa if needed */
1067 H5FA_patch_file(idx_info->storage->u.farray.fa, idx_info->f);
10641068
10651069 /* Set convenience pointer to fixed array structure */
10661070 fa = idx_info->storage->u.farray.fa;
11951199 HDassert(chunk_udata);
11961200
11971201 /* Check if the fixed array is open yet */
1198 if(NULL == idx_info->storage->u.farray.fa)
1202 if(NULL == idx_info->storage->u.farray.fa) {
11991203 /* Open the fixed array in file */
12001204 if(H5D__farray_idx_open(idx_info) < 0)
12011205 HGOTO_ERROR(H5E_DATASET, H5E_CANTOPENOBJ, FAIL, "can't open fixed array")
1206 } else /* Patch the top level file pointer contained in fa if needed */
1207 H5FA_patch_file(idx_info->storage->u.farray.fa, idx_info->f);
12021208
12031209 /* Set convenience pointer to fixed array structure */
12041210 fa = idx_info->storage->u.farray.fa;
411411 if(H5D__get_dxpl_cache(dxpl_id, &dxpl_cache) < 0)
412412 HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't fill dxpl cache")
413413
414 /* Patch the top level file pointer for dt->shared->u.vlen.f if needed */
415 H5T_patch_vlen_file(dataset->shared->type, dataset->oloc.file);
416
414417 /* Set up datatype info for operation */
415418 if(H5D__typeinfo_init(dataset, dxpl_cache, dxpl_id, mem_type_id, FALSE, &type_info) < 0)
416419 HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to set up type info")
631634 if(H5D__get_dxpl_cache(dxpl_id, &dxpl_cache) < 0)
632635 HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't fill dxpl cache")
633636
637 /* Patch the top level file pointer for dt->shared->u.vlen.f if needed */
638 H5T_patch_vlen_file(dataset->shared->type, dataset->oloc.file);
639
634640 /* Set up datatype info for operation */
635641 if(H5D__typeinfo_init(dataset, dxpl_cache, dxpl_id, mem_type_id, TRUE, &type_info) < 0)
636642 HGOTO_ERROR(H5E_DATASET, H5E_CANTINIT, FAIL, "unable to set up type info")
16791679 MPI_Comm comm;
16801680 int ic, root;
16811681 int mpi_code;
1682 hbool_t mem_cleanup = FALSE;
16831682 #ifdef H5_HAVE_INSTRUMENTED_LIBRARY
16841683 int new_value;
16851684 htri_t check_prop;
17141713 threshold_nproc_per_chunk = mpi_size * percent_nproc_per_chunk/100;
17151714
17161715 /* Allocate memory */
1717 io_mode_info = (uint8_t *)H5MM_calloc(total_chunks);
1718 mergebuf = H5MM_malloc((sizeof(haddr_t) + 1) * total_chunks);
1716 if(NULL == (io_mode_info = (uint8_t *)H5MM_calloc(total_chunks)))
1717 HGOTO_ERROR(H5E_DATASET, H5E_CANTALLOC, FAIL, "couldn't allocate I/O mode info buffer")
1718 if(NULL == (mergebuf = H5MM_malloc((sizeof(haddr_t) + 1) * total_chunks)))
1719 HGOTO_ERROR(H5E_DATASET, H5E_CANTALLOC, FAIL, "couldn't allocate mergebuf buffer")
17191720 tempbuf = mergebuf + total_chunks;
17201721 if(mpi_rank == root)
1721 recv_io_mode_info = (uint8_t *)H5MM_malloc(total_chunks * mpi_size);
1722 mem_cleanup = TRUE;
1722 if(NULL == (recv_io_mode_info = (uint8_t *)H5MM_malloc(total_chunks * mpi_size)))
1723 HGOTO_ERROR(H5E_DATASET, H5E_CANTALLOC, FAIL, "couldn't allocate recv I/O mode info buffer")
17231724
17241725 /* Obtain the regularity and selection information for all chunks in this process. */
17251726 chunk_node = H5SL_first(fm->sel_chunks);
17411742
17421743 /* pre-computing: calculate number of processes and
17431744 regularity of the selection occupied in each chunk */
1744 nproc_per_chunk = (int*)H5MM_calloc(total_chunks * sizeof(int));
1745 if(NULL == (nproc_per_chunk = (int*)H5MM_calloc(total_chunks * sizeof(int))))
1746 HGOTO_ERROR(H5E_DATASET, H5E_CANTALLOC, FAIL, "couldn't allocate nproc_per_chunk buffer")
17451747
17461748 /* calculating the chunk address */
17471749 if(H5D__chunk_addrmap(io_info, chunk_addr) < 0) {
1748 HDfree(nproc_per_chunk);
1750 H5MM_free(nproc_per_chunk);
17491751 HGOTO_ERROR(H5E_DATASET, H5E_CANTGET, FAIL, "can't get chunk address")
17501752 } /* end if */
17511753
17731775 HDmemcpy(mergebuf, assign_io_mode, total_chunks);
17741776 HDmemcpy(tempbuf, chunk_addr, sizeof(haddr_t) * total_chunks);
17751777
1776 HDfree(nproc_per_chunk);
1778 H5MM_free(nproc_per_chunk);
17771779 } /* end if */
17781780
17791781 /* Broadcasting the MPI_IO option info. and chunk address info. */
18231825 #endif
18241826
18251827 done:
1826 if(mem_cleanup) {
1827 HDfree(io_mode_info);
1828 HDfree(mergebuf);
1829 if(mpi_rank == root)
1830 HDfree(recv_io_mode_info);
1828 if(io_mode_info)
1829 H5MM_free(io_mode_info);
1830 if(mergebuf)
1831 H5MM_free(mergebuf);
1832 if(recv_io_mode_info) {
1833 HDassert(mpi_rank == root);
1834 H5MM_free(recv_io_mode_info);
18311835 } /* end if */
18321836
18331837 FUNC_LEAVE_NOAPI(ret_value)
403403 } H5D_virtual_held_file_t;
404404
405405 /* The raw data chunk cache */
406 struct H5D_rdcc_ent_t; /* Forward declaration of struct used below */
406407 typedef struct H5D_rdcc_t {
407408 struct {
408409 unsigned ninits; /* Number of chunk creations */
534535 hsize_t size; /* Accumulated number of bytes for the selection */
535536 } H5D_vlen_bufsize_t;
536537
537 /* Flags for the "edge_chunk_state" field below */
538 #define H5D_RDCC_DISABLE_FILTERS 0x01u /* Disable filters on this chunk */
539 #define H5D_RDCC_NEWLY_DISABLED_FILTERS 0x02u /* Filters have been disabled since
540 * the last flush */
541
542 /* Raw data chunks are cached. Each entry in the cache is: */
543 typedef struct H5D_rdcc_ent_t {
544 hbool_t locked; /*entry is locked in cache */
545 hbool_t dirty; /*needs to be written to disk? */
546 hbool_t deleted; /*chunk about to be deleted */
547 unsigned edge_chunk_state; /*states related to edge chunks (see above) */
548 hsize_t scaled[H5O_LAYOUT_NDIMS]; /*scaled chunk 'name' (coordinates) */
549 uint32_t rd_count; /*bytes remaining to be read */
550 uint32_t wr_count; /*bytes remaining to be written */
551 H5F_block_t chunk_block; /*offset/length of chunk in file */
552 hsize_t chunk_idx; /*index of chunk in dataset */
553 uint8_t *chunk; /*the unfiltered chunk data */
554 unsigned idx; /*index in hash table */
555 struct H5D_rdcc_ent_t *next;/*next item in doubly-linked list */
556 struct H5D_rdcc_ent_t *prev;/*previous item in doubly-linked list */
557 struct H5D_rdcc_ent_t *tmp_next;/*next item in temporary doubly-linked list */
558 struct H5D_rdcc_ent_t *tmp_prev;/*previous item in temporary doubly-linked list */
559 } H5D_rdcc_ent_t;
560 typedef H5D_rdcc_ent_t *H5D_rdcc_ent_ptr_t; /* For free lists */
561
562538
563539 /*****************************/
564540 /* Package Private Variables */
684660 H5_DLL hbool_t H5D__chunk_is_space_alloc(const H5O_storage_t *storage);
685661 H5_DLL herr_t H5D__chunk_lookup(const H5D_t *dset, hid_t dxpl_id,
686662 const hsize_t *scaled, H5D_chunk_ud_t *udata);
687 H5_DLL void *H5D__chunk_lock(const H5D_io_info_t *io_info,
688 H5D_chunk_ud_t *udata, hbool_t relax, hbool_t prev_unfilt_chunk);
689 H5_DLL herr_t H5D__chunk_unlock(const H5D_io_info_t *io_info,
690 const H5D_chunk_ud_t *udata, hbool_t dirty, void *chunk,
691 uint32_t naccessed);
692663 H5_DLL herr_t H5D__chunk_allocated(H5D_t *dset, hid_t dxpl_id, hsize_t *nbytes);
693664 H5_DLL herr_t H5D__chunk_allocate(const H5D_t *dset, hid_t dxpl_id,
694665 hbool_t full_overwrite, hsize_t old_dim[]);
448448
449449 /* Copy original source names */
450450 if(NULL == (layout->storage.u.virt.list[i].source_file_name
451 = HDstrdup(orig_list[i].source_file_name)))
451 = H5MM_strdup(orig_list[i].source_file_name)))
452452 HGOTO_ERROR(H5E_DATASET, H5E_RESOURCE, FAIL, "unable to duplicate source file name")
453453 if(NULL == (layout->storage.u.virt.list[i].source_dset_name
454 = HDstrdup(orig_list[i].source_dset_name)))
454 = H5MM_strdup(orig_list[i].source_dset_name)))
455455 HGOTO_ERROR(H5E_DATASET, H5E_RESOURCE, FAIL, "unable to duplicate source dataset name")
456456
457457 /* Copy source selection */
490490 } /* end if */
491491 else
492492 if(NULL == (layout->storage.u.virt.list[i].source_dset.file_name
493 = HDstrdup(orig_list[i].source_dset.file_name)))
493 = H5MM_strdup(orig_list[i].source_dset.file_name)))
494494 HGOTO_ERROR(H5E_DATASET, H5E_RESOURCE, FAIL, "unable to duplicate source file name")
495495 } /* end if */
496496 if(orig_list[i].source_dset.dset_name) {
506506 } /* end if */
507507 else
508508 if(NULL == (layout->storage.u.virt.list[i].source_dset.dset_name
509 = HDstrdup(orig_list[i].source_dset.dset_name)))
509 = H5MM_strdup(orig_list[i].source_dset.dset_name)))
510510 HGOTO_ERROR(H5E_DATASET, H5E_RESOURCE, FAIL, "unable to duplicate source dataset name")
511511 } /* end if */
512512
11261126
11271127 /* Duplicate name segment */
11281128 if(p_src->name_segment) {
1129 if(NULL == ((*p_dst)->name_segment = HDstrdup(p_src->name_segment)))
1129 if(NULL == ((*p_dst)->name_segment = H5MM_strdup(p_src->name_segment)))
11301130 HGOTO_ERROR(H5E_RESOURCE, H5E_CANTALLOC, FAIL, "unable to duplicate name segment")
11311131 } /* end if */
11321132
14161416 done:
14171417 if(va_started)
14181418 va_end(ap);
1419 #ifdef H5_HAVE_VASPRINTF
1420 if(tmp)
1421 HDfree(tmp);
1422 #else /* H5_HAVE_VASPRINTF */
14191423 if(tmp)
14201424 H5MM_xfree(tmp);
1425 #endif /* H5_HAVE_VASPRINTF */
14211426
14221427 FUNC_LEAVE_API(ret_value)
14231428 } /* end H5Epush2() */
11141114 elmt = H5FL_BLK_FREE(ea_native_elmt, elmt);
11151115
11161116 END_FUNC(PRIV) /* end H5EA_iterate() */
1117
1118 /*-------------------------------------------------------------------------
1119 * Function: H5EA_patch_file
1120 *
1121 * Purpose: Patch the top-level file pointer contained in ea
1122 * to point to idx_info->f if they are different.
1123 * This is possible because the file pointer in ea can be
1124 * closed out if ea remains open.
1125 *
1126 * Return: SUCCEED
1127 *
1128 *-------------------------------------------------------------------------
1129 */
1130 BEGIN_FUNC(PRIV, NOERR,
1131 herr_t, SUCCEED, -,
1132 H5EA_patch_file(H5EA_t *ea, H5F_t *f))
1133
1134 /* Local variables */
1135
1136 #ifdef H5EA_DEBUG
1137 HDfprintf(stderr, "%s: Called\n", FUNC);
1138 #endif /* H5EA_DEBUG */
1139
1140 /*
1141 * Check arguments.
1142 */
1143 HDassert(ea);
1144 HDassert(f);
1145
1146 if(ea->f != f || ea->hdr->f != f)
1147 ea->f = ea->hdr->f = f;
1148
1149 END_FUNC(PRIV) /* end H5EA_patch_file() */
145145 H5_DLL herr_t H5EA_iterate(H5EA_t *fa, hid_t dxpl_id, H5EA_operator_t op, void *udata);
146146 H5_DLL herr_t H5EA_close(H5EA_t *ea, hid_t dxpl_id);
147147 H5_DLL herr_t H5EA_delete(H5F_t *f, hid_t dxpl_id, haddr_t ea_addr, void *ctx_udata);
148 H5_DLL herr_t H5EA_patch_file(H5EA_t *fa, H5F_t *f);
148149
149150 /* Statistics routines */
150151 H5_DLL herr_t H5EA_get_stats(const H5EA_t *ea, H5EA_stat_t *stats);
2020 #define _H5Edefin_H
2121
2222 /* Major error IDs */
23 hid_t H5E_FUNC_g = FAIL; /* Function entry/exit */
24 hid_t H5E_FILE_g = FAIL; /* File accessibilty */
25 hid_t H5E_SOHM_g = FAIL; /* Shared Object Header Messages */
26 hid_t H5E_SYM_g = FAIL; /* Symbol table */
27 hid_t H5E_PLUGIN_g = FAIL; /* Plugin for dynamically loaded library */
28 hid_t H5E_VFL_g = FAIL; /* Virtual File Layer */
29 hid_t H5E_INTERNAL_g = FAIL; /* Internal error (too specific to document in detail) */
30 hid_t H5E_BTREE_g = FAIL; /* B-Tree node */
31 hid_t H5E_REFERENCE_g = FAIL; /* References */
32 hid_t H5E_DATASPACE_g = FAIL; /* Dataspace */
33 hid_t H5E_RESOURCE_g = FAIL; /* Resource unavailable */
34 hid_t H5E_RS_g = FAIL; /* Reference Counted Strings */
35 hid_t H5E_FARRAY_g = FAIL; /* Fixed Array */
36 hid_t H5E_HEAP_g = FAIL; /* Heap */
37 hid_t H5E_ATTR_g = FAIL; /* Attribute */
38 hid_t H5E_IO_g = FAIL; /* Low-level I/O */
39 hid_t H5E_EFL_g = FAIL; /* External file list */
40 hid_t H5E_TST_g = FAIL; /* Ternary Search Trees */
2341 hid_t H5E_FSPACE_g = FAIL; /* Free Space Manager */
42 hid_t H5E_DATASET_g = FAIL; /* Dataset */
43 hid_t H5E_STORAGE_g = FAIL; /* Data storage */
44 hid_t H5E_LINK_g = FAIL; /* Links */
2445 hid_t H5E_PLIST_g = FAIL; /* Property lists */
25 hid_t H5E_RS_g = FAIL; /* Reference Counted Strings */
2646 hid_t H5E_DATATYPE_g = FAIL; /* Datatype */
27 hid_t H5E_ERROR_g = FAIL; /* Error API */
28 hid_t H5E_DATASPACE_g = FAIL; /* Dataspace */
29 hid_t H5E_FARRAY_g = FAIL; /* Fixed Array */
30 hid_t H5E_INTERNAL_g = FAIL; /* Internal error (too specific to document in detail) */
31 hid_t H5E_PLUGIN_g = FAIL; /* Plugin for dynamically loaded library */
32 hid_t H5E_CACHE_g = FAIL; /* Object cache */
33 hid_t H5E_FUNC_g = FAIL; /* Function entry/exit */
34 hid_t H5E_EARRAY_g = FAIL; /* Extensible Array */
35 hid_t H5E_IO_g = FAIL; /* Low-level I/O */
47 hid_t H5E_OHDR_g = FAIL; /* Object header */
48 hid_t H5E_ATOM_g = FAIL; /* Object atom */
3649 hid_t H5E_NONE_MAJOR_g = FAIL; /* No error */
3750 hid_t H5E_SLIST_g = FAIL; /* Skip Lists */
38 hid_t H5E_RESOURCE_g = FAIL; /* Resource unavailable */
39 hid_t H5E_SYM_g = FAIL; /* Symbol table */
40 hid_t H5E_ATOM_g = FAIL; /* Object atom */
41 hid_t H5E_REFERENCE_g = FAIL; /* References */
51 hid_t H5E_ARGS_g = FAIL; /* Invalid arguments to routine */
52 hid_t H5E_EARRAY_g = FAIL; /* Extensible Array */
4253 hid_t H5E_PLINE_g = FAIL; /* Data filters */
43 hid_t H5E_ARGS_g = FAIL; /* Invalid arguments to routine */
44 hid_t H5E_SOHM_g = FAIL; /* Shared Object Header Messages */
45 hid_t H5E_DATASET_g = FAIL; /* Dataset */
46 hid_t H5E_STORAGE_g = FAIL; /* Data storage */
47 hid_t H5E_EFL_g = FAIL; /* External file list */
48 hid_t H5E_FILE_g = FAIL; /* File accessibilty */
49 hid_t H5E_TST_g = FAIL; /* Ternary Search Trees */
50 hid_t H5E_ATTR_g = FAIL; /* Attribute */
51 hid_t H5E_HEAP_g = FAIL; /* Heap */
52 hid_t H5E_LINK_g = FAIL; /* Links */
53 hid_t H5E_BTREE_g = FAIL; /* B-Tree node */
54 hid_t H5E_OHDR_g = FAIL; /* Object header */
55 hid_t H5E_VFL_g = FAIL; /* Virtual File Layer */
54 hid_t H5E_ERROR_g = FAIL; /* Error API */
55 hid_t H5E_CACHE_g = FAIL; /* Object cache */
5656
5757 /* Minor error IDs */
58
59 /* Free space errors */
60 hid_t H5E_CANTMERGE_g = FAIL; /* Can't merge objects */
61 hid_t H5E_CANTREVIVE_g = FAIL; /* Can't revive object */
62 hid_t H5E_CANTSHRINK_g = FAIL; /* Can't shrink container */
63
64 /* Heap errors */
65 hid_t H5E_CANTRESTORE_g = FAIL; /* Can't restore condition */
66 hid_t H5E_CANTCOMPUTE_g = FAIL; /* Can't compute value */
67 hid_t H5E_CANTEXTEND_g = FAIL; /* Can't extend heap's space */
68 hid_t H5E_CANTATTACH_g = FAIL; /* Can't attach object */
69 hid_t H5E_CANTUPDATE_g = FAIL; /* Can't update object */
70 hid_t H5E_CANTOPERATE_g = FAIL; /* Can't operate on object */
71
72 /* System level errors */
73 hid_t H5E_SYSERRSTR_g = FAIL; /* System error message */
74
75 /* Argument errors */
76 hid_t H5E_UNINITIALIZED_g = FAIL; /* Information is uinitialized */
77 hid_t H5E_UNSUPPORTED_g = FAIL; /* Feature is unsupported */
78 hid_t H5E_BADTYPE_g = FAIL; /* Inappropriate type */
79 hid_t H5E_BADRANGE_g = FAIL; /* Out of range */
80 hid_t H5E_BADVALUE_g = FAIL; /* Bad value */
81
82 /* Datatype conversion errors */
83 hid_t H5E_CANTCONVERT_g = FAIL; /* Can't convert datatypes */
84 hid_t H5E_BADSIZE_g = FAIL; /* Bad size for object */
85
86 /* File accessibilty errors */
87 hid_t H5E_FILEEXISTS_g = FAIL; /* File already exists */
88 hid_t H5E_FILEOPEN_g = FAIL; /* File already open */
89 hid_t H5E_CANTCREATE_g = FAIL; /* Unable to create file */
90 hid_t H5E_CANTOPENFILE_g = FAIL; /* Unable to open file */
91 hid_t H5E_CANTCLOSEFILE_g = FAIL; /* Unable to close file */
92 hid_t H5E_NOTHDF5_g = FAIL; /* Not an HDF5 file */
93 hid_t H5E_BADFILE_g = FAIL; /* Bad file ID accessed */
94 hid_t H5E_TRUNCATED_g = FAIL; /* File has been truncated */
95 hid_t H5E_MOUNT_g = FAIL; /* File mount error */
96
97 /* Object atom related errors */
98 hid_t H5E_BADATOM_g = FAIL; /* Unable to find atom information (already closed?) */
99 hid_t H5E_BADGROUP_g = FAIL; /* Unable to find ID group information */
100 hid_t H5E_CANTREGISTER_g = FAIL; /* Unable to register new atom */
101 hid_t H5E_CANTINC_g = FAIL; /* Unable to increment reference count */
102 hid_t H5E_CANTDEC_g = FAIL; /* Unable to decrement reference count */
103 hid_t H5E_NOIDS_g = FAIL; /* Out of IDs for group */
104
105 /* Property list errors */
106 hid_t H5E_CANTGET_g = FAIL; /* Can't get value */
107 hid_t H5E_CANTSET_g = FAIL; /* Can't set value */
108 hid_t H5E_DUPCLASS_g = FAIL; /* Duplicate class name in parent class */
109 hid_t H5E_SETDISALLOWED_g = FAIL; /* Disallowed operation */
11058
11159 /* Generic low-level file I/O errors */
11260 hid_t H5E_SEEKERROR_g = FAIL; /* Seek failed */
11563 hid_t H5E_CLOSEERROR_g = FAIL; /* Close failed */
11664 hid_t H5E_OVERFLOW_g = FAIL; /* Address overflowed */
11765 hid_t H5E_FCNTL_g = FAIL; /* File control (fcntl) failed */
118
119 /* Dataspace errors */
120 hid_t H5E_CANTCLIP_g = FAIL; /* Can't clip hyperslab region */
121 hid_t H5E_CANTCOUNT_g = FAIL; /* Can't count elements */
122 hid_t H5E_CANTSELECT_g = FAIL; /* Can't select hyperslab */
123 hid_t H5E_CANTNEXT_g = FAIL; /* Can't move to next iterator location */
124 hid_t H5E_BADSELECT_g = FAIL; /* Invalid selection */
125 hid_t H5E_CANTCOMPARE_g = FAIL; /* Can't compare objects */
126 hid_t H5E_CANTAPPEND_g = FAIL; /* Can't append object */
127
128 /* Link related errors */
129 hid_t H5E_TRAVERSE_g = FAIL; /* Link traversal failure */
130 hid_t H5E_NLINKS_g = FAIL; /* Too many soft links in path */
131 hid_t H5E_NOTREGISTERED_g = FAIL; /* Link class not registered */
132 hid_t H5E_CANTMOVE_g = FAIL; /* Can't move object */
133 hid_t H5E_CANTSORT_g = FAIL; /* Can't sort objects */
13466
13567 /* Resource errors */
13668 hid_t H5E_NOSPACE_g = FAIL; /* No space available for allocation */
14476 hid_t H5E_CANTGETSIZE_g = FAIL; /* Unable to compute size */
14577 hid_t H5E_OBJOPEN_g = FAIL; /* Object is already open */
14678
147 /* Parallel MPI errors */
148 hid_t H5E_MPI_g = FAIL; /* Some MPI function failed */
149 hid_t H5E_MPIERRSTR_g = FAIL; /* MPI Error String */
150 hid_t H5E_CANTRECV_g = FAIL; /* Can't receive data */
79 /* Heap errors */
80 hid_t H5E_CANTRESTORE_g = FAIL; /* Can't restore condition */
81 hid_t H5E_CANTCOMPUTE_g = FAIL; /* Can't compute value */
82 hid_t H5E_CANTEXTEND_g = FAIL; /* Can't extend heap's space */
83 hid_t H5E_CANTATTACH_g = FAIL; /* Can't attach object */
84 hid_t H5E_CANTUPDATE_g = FAIL; /* Can't update object */
85 hid_t H5E_CANTOPERATE_g = FAIL; /* Can't operate on object */
86
87 /* Function entry/exit interface errors */
88 hid_t H5E_CANTINIT_g = FAIL; /* Unable to initialize object */
89 hid_t H5E_ALREADYINIT_g = FAIL; /* Object already initialized */
90 hid_t H5E_CANTRELEASE_g = FAIL; /* Unable to release object */
91
92 /* Property list errors */
93 hid_t H5E_CANTGET_g = FAIL; /* Can't get value */
94 hid_t H5E_CANTSET_g = FAIL; /* Can't set value */
95 hid_t H5E_DUPCLASS_g = FAIL; /* Duplicate class name in parent class */
96 hid_t H5E_SETDISALLOWED_g = FAIL; /* Disallowed operation */
97
98 /* Free space errors */
99 hid_t H5E_CANTMERGE_g = FAIL; /* Can't merge objects */
100 hid_t H5E_CANTREVIVE_g = FAIL; /* Can't revive object */
101 hid_t H5E_CANTSHRINK_g = FAIL; /* Can't shrink container */
151102
152103 /* Object header related errors */
153104 hid_t H5E_LINKCOUNT_g = FAIL; /* Bad object header link count */
160111 hid_t H5E_CANTRESET_g = FAIL; /* Can't reset object */
161112 hid_t H5E_CANTRENAME_g = FAIL; /* Unable to rename object */
162113
163 /* Group related errors */
164 hid_t H5E_CANTOPENOBJ_g = FAIL; /* Can't open object */
165 hid_t H5E_CANTCLOSEOBJ_g = FAIL; /* Can't close object */
166 hid_t H5E_COMPLEN_g = FAIL; /* Name component is too long */
167 hid_t H5E_PATH_g = FAIL; /* Problem with path to object */
114 /* System level errors */
115 hid_t H5E_SYSERRSTR_g = FAIL; /* System error message */
168116
169117 /* I/O pipeline errors */
170118 hid_t H5E_NOFILTER_g = FAIL; /* Requested filter is not available */
173121 hid_t H5E_SETLOCAL_g = FAIL; /* Error from filter 'set local' callback */
174122 hid_t H5E_NOENCODER_g = FAIL; /* Filter present but encoding disabled */
175123 hid_t H5E_CANTFILTER_g = FAIL; /* Filter operation failed */
124
125 /* Group related errors */
126 hid_t H5E_CANTOPENOBJ_g = FAIL; /* Can't open object */
127 hid_t H5E_CANTCLOSEOBJ_g = FAIL; /* Can't close object */
128 hid_t H5E_COMPLEN_g = FAIL; /* Name component is too long */
129 hid_t H5E_PATH_g = FAIL; /* Problem with path to object */
130
131 /* No error */
132 hid_t H5E_NONE_MINOR_g = FAIL; /* No error */
133
134 /* Plugin errors */
135 hid_t H5E_OPENERROR_g = FAIL; /* Can't open directory or file */
136
137 /* File accessibilty errors */
138 hid_t H5E_FILEEXISTS_g = FAIL; /* File already exists */
139 hid_t H5E_FILEOPEN_g = FAIL; /* File already open */
140 hid_t H5E_CANTCREATE_g = FAIL; /* Unable to create file */
141 hid_t H5E_CANTOPENFILE_g = FAIL; /* Unable to open file */
142 hid_t H5E_CANTCLOSEFILE_g = FAIL; /* Unable to close file */
143 hid_t H5E_NOTHDF5_g = FAIL; /* Not an HDF5 file */
144 hid_t H5E_BADFILE_g = FAIL; /* Bad file ID accessed */
145 hid_t H5E_TRUNCATED_g = FAIL; /* File has been truncated */
146 hid_t H5E_MOUNT_g = FAIL; /* File mount error */
147
148 /* Object atom related errors */
149 hid_t H5E_BADATOM_g = FAIL; /* Unable to find atom information (already closed?) */
150 hid_t H5E_BADGROUP_g = FAIL; /* Unable to find ID group information */
151 hid_t H5E_CANTREGISTER_g = FAIL; /* Unable to register new atom */
152 hid_t H5E_CANTINC_g = FAIL; /* Unable to increment reference count */
153 hid_t H5E_CANTDEC_g = FAIL; /* Unable to decrement reference count */
154 hid_t H5E_NOIDS_g = FAIL; /* Out of IDs for group */
176155
177156 /* Cache related errors */
178157 hid_t H5E_CANTFLUSH_g = FAIL; /* Unable to flush data from cache */
198177 hid_t H5E_CANTCORK_g = FAIL; /* Unable to cork an object */
199178 hid_t H5E_CANTUNCORK_g = FAIL; /* Unable to uncork an object */
200179
180 /* Link related errors */
181 hid_t H5E_TRAVERSE_g = FAIL; /* Link traversal failure */
182 hid_t H5E_NLINKS_g = FAIL; /* Too many soft links in path */
183 hid_t H5E_NOTREGISTERED_g = FAIL; /* Link class not registered */
184 hid_t H5E_CANTMOVE_g = FAIL; /* Can't move object */
185 hid_t H5E_CANTSORT_g = FAIL; /* Can't sort objects */
186
187 /* Parallel MPI errors */
188 hid_t H5E_MPI_g = FAIL; /* Some MPI function failed */
189 hid_t H5E_MPIERRSTR_g = FAIL; /* MPI Error String */
190 hid_t H5E_CANTRECV_g = FAIL; /* Can't receive data */
191
192 /* Dataspace errors */
193 hid_t H5E_CANTCLIP_g = FAIL; /* Can't clip hyperslab region */
194 hid_t H5E_CANTCOUNT_g = FAIL; /* Can't count elements */
195 hid_t H5E_CANTSELECT_g = FAIL; /* Can't select hyperslab */
196 hid_t H5E_CANTNEXT_g = FAIL; /* Can't move to next iterator location */
197 hid_t H5E_BADSELECT_g = FAIL; /* Invalid selection */
198 hid_t H5E_CANTCOMPARE_g = FAIL; /* Can't compare objects */
199 hid_t H5E_CANTAPPEND_g = FAIL; /* Can't append object */
200
201 /* Argument errors */
202 hid_t H5E_UNINITIALIZED_g = FAIL; /* Information is uinitialized */
203 hid_t H5E_UNSUPPORTED_g = FAIL; /* Feature is unsupported */
204 hid_t H5E_BADTYPE_g = FAIL; /* Inappropriate type */
205 hid_t H5E_BADRANGE_g = FAIL; /* Out of range */
206 hid_t H5E_BADVALUE_g = FAIL; /* Bad value */
207
201208 /* B-tree related errors */
202209 hid_t H5E_NOTFOUND_g = FAIL; /* Object not found */
203210 hid_t H5E_EXISTS_g = FAIL; /* Object already exists */
211218 hid_t H5E_CANTMODIFY_g = FAIL; /* Unable to modify record */
212219 hid_t H5E_CANTREMOVE_g = FAIL; /* Unable to remove object */
213220
214 /* Function entry/exit interface errors */
215 hid_t H5E_CANTINIT_g = FAIL; /* Unable to initialize object */
216 hid_t H5E_ALREADYINIT_g = FAIL; /* Object already initialized */
217 hid_t H5E_CANTRELEASE_g = FAIL; /* Unable to release object */
218
219 /* Plugin errors */
220 hid_t H5E_OPENERROR_g = FAIL; /* Can't open directory or file */
221
222 /* No error */
223 hid_t H5E_NONE_MINOR_g = FAIL; /* No error */
221 /* Datatype conversion errors */
222 hid_t H5E_CANTCONVERT_g = FAIL; /* Can't convert datatypes */
223 hid_t H5E_BADSIZE_g = FAIL; /* Bad size for object */
224224
225225 #endif /* H5Edefin_H */
2323 /* Major error codes */
2424 /*********************/
2525
26 assert(H5E_FUNC_g==(-1));
27 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Function entry/exit"))==NULL)
28 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
29 if((H5E_FUNC_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
30 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
31 assert(H5E_FILE_g==(-1));
32 if((msg = H5E_create_msg(cls, H5E_MAJOR, "File accessibilty"))==NULL)
33 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
34 if((H5E_FILE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
35 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
36 assert(H5E_SOHM_g==(-1));
37 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Shared Object Header Messages"))==NULL)
38 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
39 if((H5E_SOHM_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
40 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
41 assert(H5E_SYM_g==(-1));
42 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Symbol table"))==NULL)
43 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
44 if((H5E_SYM_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
45 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
46 assert(H5E_PLUGIN_g==(-1));
47 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Plugin for dynamically loaded library"))==NULL)
48 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
49 if((H5E_PLUGIN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
50 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
51 assert(H5E_VFL_g==(-1));
52 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Virtual File Layer"))==NULL)
53 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
54 if((H5E_VFL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
55 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
56 assert(H5E_INTERNAL_g==(-1));
57 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Internal error (too specific to document in detail)"))==NULL)
58 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
59 if((H5E_INTERNAL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
60 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
61 assert(H5E_BTREE_g==(-1));
62 if((msg = H5E_create_msg(cls, H5E_MAJOR, "B-Tree node"))==NULL)
63 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
64 if((H5E_BTREE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
65 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
66 assert(H5E_REFERENCE_g==(-1));
67 if((msg = H5E_create_msg(cls, H5E_MAJOR, "References"))==NULL)
68 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
69 if((H5E_REFERENCE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
70 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
71 assert(H5E_DATASPACE_g==(-1));
72 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Dataspace"))==NULL)
73 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
74 if((H5E_DATASPACE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
75 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
76 assert(H5E_RESOURCE_g==(-1));
77 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Resource unavailable"))==NULL)
78 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
79 if((H5E_RESOURCE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
80 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
81 assert(H5E_RS_g==(-1));
82 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Reference Counted Strings"))==NULL)
83 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
84 if((H5E_RS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
85 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
86 assert(H5E_FARRAY_g==(-1));
87 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Fixed Array"))==NULL)
88 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
89 if((H5E_FARRAY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
90 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
91 assert(H5E_HEAP_g==(-1));
92 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Heap"))==NULL)
93 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
94 if((H5E_HEAP_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
95 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
96 assert(H5E_ATTR_g==(-1));
97 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Attribute"))==NULL)
98 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
99 if((H5E_ATTR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
100 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
101 assert(H5E_IO_g==(-1));
102 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Low-level I/O"))==NULL)
103 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
104 if((H5E_IO_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
105 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
106 assert(H5E_EFL_g==(-1));
107 if((msg = H5E_create_msg(cls, H5E_MAJOR, "External file list"))==NULL)
108 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
109 if((H5E_EFL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
110 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
111 assert(H5E_TST_g==(-1));
112 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Ternary Search Trees"))==NULL)
113 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
114 if((H5E_TST_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
115 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
26116 assert(H5E_FSPACE_g==(-1));
27117 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Free Space Manager"))==NULL)
28118 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
29119 if((H5E_FSPACE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
30120 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
121 assert(H5E_DATASET_g==(-1));
122 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Dataset"))==NULL)
123 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
124 if((H5E_DATASET_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
125 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
126 assert(H5E_STORAGE_g==(-1));
127 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Data storage"))==NULL)
128 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
129 if((H5E_STORAGE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
130 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
131 assert(H5E_LINK_g==(-1));
132 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Links"))==NULL)
133 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
134 if((H5E_LINK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
135 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
31136 assert(H5E_PLIST_g==(-1));
32137 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Property lists"))==NULL)
33138 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
34139 if((H5E_PLIST_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
35140 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
36 assert(H5E_RS_g==(-1));
37 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Reference Counted Strings"))==NULL)
38 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
39 if((H5E_RS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
40 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
41141 assert(H5E_DATATYPE_g==(-1));
42142 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Datatype"))==NULL)
43143 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
44144 if((H5E_DATATYPE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
45145 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
146 assert(H5E_OHDR_g==(-1));
147 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Object header"))==NULL)
148 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
149 if((H5E_OHDR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
150 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
151 assert(H5E_ATOM_g==(-1));
152 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Object atom"))==NULL)
153 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
154 if((H5E_ATOM_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
155 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
156 assert(H5E_NONE_MAJOR_g==(-1));
157 if((msg = H5E_create_msg(cls, H5E_MAJOR, "No error"))==NULL)
158 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
159 if((H5E_NONE_MAJOR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
160 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
161 assert(H5E_SLIST_g==(-1));
162 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Skip Lists"))==NULL)
163 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
164 if((H5E_SLIST_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
165 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
166 assert(H5E_ARGS_g==(-1));
167 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Invalid arguments to routine"))==NULL)
168 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
169 if((H5E_ARGS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
170 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
171 assert(H5E_EARRAY_g==(-1));
172 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Extensible Array"))==NULL)
173 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
174 if((H5E_EARRAY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
175 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
176 assert(H5E_PLINE_g==(-1));
177 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Data filters"))==NULL)
178 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
179 if((H5E_PLINE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
180 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
46181 assert(H5E_ERROR_g==(-1));
47182 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Error API"))==NULL)
48183 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
49184 if((H5E_ERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
50185 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
51 assert(H5E_DATASPACE_g==(-1));
52 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Dataspace"))==NULL)
53 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
54 if((H5E_DATASPACE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
55 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
56 assert(H5E_FARRAY_g==(-1));
57 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Fixed Array"))==NULL)
58 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
59 if((H5E_FARRAY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
60 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
61 assert(H5E_INTERNAL_g==(-1));
62 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Internal error (too specific to document in detail)"))==NULL)
63 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
64 if((H5E_INTERNAL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
65 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
66 assert(H5E_PLUGIN_g==(-1));
67 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Plugin for dynamically loaded library"))==NULL)
68 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
69 if((H5E_PLUGIN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
70 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
71186 assert(H5E_CACHE_g==(-1));
72187 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Object cache"))==NULL)
73188 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
74189 if((H5E_CACHE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
75 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
76 assert(H5E_FUNC_g==(-1));
77 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Function entry/exit"))==NULL)
78 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
79 if((H5E_FUNC_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
80 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
81 assert(H5E_EARRAY_g==(-1));
82 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Extensible Array"))==NULL)
83 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
84 if((H5E_EARRAY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
85 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
86 assert(H5E_IO_g==(-1));
87 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Low-level I/O"))==NULL)
88 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
89 if((H5E_IO_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
90 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
91 assert(H5E_NONE_MAJOR_g==(-1));
92 if((msg = H5E_create_msg(cls, H5E_MAJOR, "No error"))==NULL)
93 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
94 if((H5E_NONE_MAJOR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
95 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
96 assert(H5E_SLIST_g==(-1));
97 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Skip Lists"))==NULL)
98 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
99 if((H5E_SLIST_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
100 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
101 assert(H5E_RESOURCE_g==(-1));
102 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Resource unavailable"))==NULL)
103 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
104 if((H5E_RESOURCE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
105 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
106 assert(H5E_SYM_g==(-1));
107 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Symbol table"))==NULL)
108 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
109 if((H5E_SYM_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
110 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
111 assert(H5E_ATOM_g==(-1));
112 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Object atom"))==NULL)
113 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
114 if((H5E_ATOM_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
115 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
116 assert(H5E_REFERENCE_g==(-1));
117 if((msg = H5E_create_msg(cls, H5E_MAJOR, "References"))==NULL)
118 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
119 if((H5E_REFERENCE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
120 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
121 assert(H5E_PLINE_g==(-1));
122 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Data filters"))==NULL)
123 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
124 if((H5E_PLINE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
125 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
126 assert(H5E_ARGS_g==(-1));
127 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Invalid arguments to routine"))==NULL)
128 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
129 if((H5E_ARGS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
130 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
131 assert(H5E_SOHM_g==(-1));
132 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Shared Object Header Messages"))==NULL)
133 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
134 if((H5E_SOHM_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
135 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
136 assert(H5E_DATASET_g==(-1));
137 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Dataset"))==NULL)
138 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
139 if((H5E_DATASET_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
140 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
141 assert(H5E_STORAGE_g==(-1));
142 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Data storage"))==NULL)
143 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
144 if((H5E_STORAGE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
145 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
146 assert(H5E_EFL_g==(-1));
147 if((msg = H5E_create_msg(cls, H5E_MAJOR, "External file list"))==NULL)
148 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
149 if((H5E_EFL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
150 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
151 assert(H5E_FILE_g==(-1));
152 if((msg = H5E_create_msg(cls, H5E_MAJOR, "File accessibilty"))==NULL)
153 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
154 if((H5E_FILE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
155 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
156 assert(H5E_TST_g==(-1));
157 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Ternary Search Trees"))==NULL)
158 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
159 if((H5E_TST_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
160 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
161 assert(H5E_ATTR_g==(-1));
162 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Attribute"))==NULL)
163 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
164 if((H5E_ATTR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
165 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
166 assert(H5E_HEAP_g==(-1));
167 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Heap"))==NULL)
168 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
169 if((H5E_HEAP_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
170 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
171 assert(H5E_LINK_g==(-1));
172 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Links"))==NULL)
173 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
174 if((H5E_LINK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
175 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
176 assert(H5E_BTREE_g==(-1));
177 if((msg = H5E_create_msg(cls, H5E_MAJOR, "B-Tree node"))==NULL)
178 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
179 if((H5E_BTREE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
180 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
181 assert(H5E_OHDR_g==(-1));
182 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Object header"))==NULL)
183 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
184 if((H5E_OHDR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
185 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
186 assert(H5E_VFL_g==(-1));
187 if((msg = H5E_create_msg(cls, H5E_MAJOR, "Virtual File Layer"))==NULL)
188 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
189 if((H5E_VFL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
190190 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
191191
192192 /*********************/
194194 /*********************/
195195
196196
197 /* Generic low-level file I/O errors */
198 assert(H5E_SEEKERROR_g==(-1));
199 if((msg = H5E_create_msg(cls, H5E_MINOR, "Seek failed"))==NULL)
200 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
201 if((H5E_SEEKERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
202 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
203 assert(H5E_READERROR_g==(-1));
204 if((msg = H5E_create_msg(cls, H5E_MINOR, "Read failed"))==NULL)
205 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
206 if((H5E_READERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
207 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
208 assert(H5E_WRITEERROR_g==(-1));
209 if((msg = H5E_create_msg(cls, H5E_MINOR, "Write failed"))==NULL)
210 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
211 if((H5E_WRITEERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
212 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
213 assert(H5E_CLOSEERROR_g==(-1));
214 if((msg = H5E_create_msg(cls, H5E_MINOR, "Close failed"))==NULL)
215 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
216 if((H5E_CLOSEERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
217 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
218 assert(H5E_OVERFLOW_g==(-1));
219 if((msg = H5E_create_msg(cls, H5E_MINOR, "Address overflowed"))==NULL)
220 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
221 if((H5E_OVERFLOW_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
222 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
223 assert(H5E_FCNTL_g==(-1));
224 if((msg = H5E_create_msg(cls, H5E_MINOR, "File control (fcntl) failed"))==NULL)
225 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
226 if((H5E_FCNTL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
227 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
228
229 /* Resource errors */
230 assert(H5E_NOSPACE_g==(-1));
231 if((msg = H5E_create_msg(cls, H5E_MINOR, "No space available for allocation"))==NULL)
232 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
233 if((H5E_NOSPACE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
234 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
235 assert(H5E_CANTALLOC_g==(-1));
236 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't allocate space"))==NULL)
237 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
238 if((H5E_CANTALLOC_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
239 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
240 assert(H5E_CANTCOPY_g==(-1));
241 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to copy object"))==NULL)
242 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
243 if((H5E_CANTCOPY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
244 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
245 assert(H5E_CANTFREE_g==(-1));
246 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to free object"))==NULL)
247 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
248 if((H5E_CANTFREE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
249 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
250 assert(H5E_ALREADYEXISTS_g==(-1));
251 if((msg = H5E_create_msg(cls, H5E_MINOR, "Object already exists"))==NULL)
252 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
253 if((H5E_ALREADYEXISTS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
254 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
255 assert(H5E_CANTLOCK_g==(-1));
256 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to lock object"))==NULL)
257 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
258 if((H5E_CANTLOCK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
259 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
260 assert(H5E_CANTUNLOCK_g==(-1));
261 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to unlock object"))==NULL)
262 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
263 if((H5E_CANTUNLOCK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
264 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
265 assert(H5E_CANTGC_g==(-1));
266 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to garbage collect"))==NULL)
267 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
268 if((H5E_CANTGC_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
269 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
270 assert(H5E_CANTGETSIZE_g==(-1));
271 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to compute size"))==NULL)
272 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
273 if((H5E_CANTGETSIZE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
274 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
275 assert(H5E_OBJOPEN_g==(-1));
276 if((msg = H5E_create_msg(cls, H5E_MINOR, "Object is already open"))==NULL)
277 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
278 if((H5E_OBJOPEN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
279 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
280
281 /* Heap errors */
282 assert(H5E_CANTRESTORE_g==(-1));
283 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't restore condition"))==NULL)
284 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
285 if((H5E_CANTRESTORE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
286 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
287 assert(H5E_CANTCOMPUTE_g==(-1));
288 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't compute value"))==NULL)
289 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
290 if((H5E_CANTCOMPUTE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
291 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
292 assert(H5E_CANTEXTEND_g==(-1));
293 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't extend heap's space"))==NULL)
294 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
295 if((H5E_CANTEXTEND_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
296 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
297 assert(H5E_CANTATTACH_g==(-1));
298 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't attach object"))==NULL)
299 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
300 if((H5E_CANTATTACH_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
301 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
302 assert(H5E_CANTUPDATE_g==(-1));
303 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't update object"))==NULL)
304 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
305 if((H5E_CANTUPDATE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
306 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
307 assert(H5E_CANTOPERATE_g==(-1));
308 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't operate on object"))==NULL)
309 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
310 if((H5E_CANTOPERATE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
311 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
312
313 /* Function entry/exit interface errors */
314 assert(H5E_CANTINIT_g==(-1));
315 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to initialize object"))==NULL)
316 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
317 if((H5E_CANTINIT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
318 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
319 assert(H5E_ALREADYINIT_g==(-1));
320 if((msg = H5E_create_msg(cls, H5E_MINOR, "Object already initialized"))==NULL)
321 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
322 if((H5E_ALREADYINIT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
323 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
324 assert(H5E_CANTRELEASE_g==(-1));
325 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to release object"))==NULL)
326 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
327 if((H5E_CANTRELEASE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
328 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
329
330 /* Property list errors */
331 assert(H5E_CANTGET_g==(-1));
332 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't get value"))==NULL)
333 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
334 if((H5E_CANTGET_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
335 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
336 assert(H5E_CANTSET_g==(-1));
337 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't set value"))==NULL)
338 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
339 if((H5E_CANTSET_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
340 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
341 assert(H5E_DUPCLASS_g==(-1));
342 if((msg = H5E_create_msg(cls, H5E_MINOR, "Duplicate class name in parent class"))==NULL)
343 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
344 if((H5E_DUPCLASS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
345 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
346 assert(H5E_SETDISALLOWED_g==(-1));
347 if((msg = H5E_create_msg(cls, H5E_MINOR, "Disallowed operation"))==NULL)
348 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
349 if((H5E_SETDISALLOWED_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
350 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
351
197352 /* Free space errors */
198353 assert(H5E_CANTMERGE_g==(-1));
199354 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't merge objects"))==NULL)
211366 if((H5E_CANTSHRINK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
212367 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
213368
214 /* Heap errors */
215 assert(H5E_CANTRESTORE_g==(-1));
216 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't restore condition"))==NULL)
217 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
218 if((H5E_CANTRESTORE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
219 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
220 assert(H5E_CANTCOMPUTE_g==(-1));
221 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't compute value"))==NULL)
222 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
223 if((H5E_CANTCOMPUTE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
224 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
225 assert(H5E_CANTEXTEND_g==(-1));
226 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't extend heap's space"))==NULL)
227 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
228 if((H5E_CANTEXTEND_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
229 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
230 assert(H5E_CANTATTACH_g==(-1));
231 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't attach object"))==NULL)
232 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
233 if((H5E_CANTATTACH_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
234 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
235 assert(H5E_CANTUPDATE_g==(-1));
236 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't update object"))==NULL)
237 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
238 if((H5E_CANTUPDATE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
239 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
240 assert(H5E_CANTOPERATE_g==(-1));
241 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't operate on object"))==NULL)
242 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
243 if((H5E_CANTOPERATE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
369 /* Object header related errors */
370 assert(H5E_LINKCOUNT_g==(-1));
371 if((msg = H5E_create_msg(cls, H5E_MINOR, "Bad object header link count"))==NULL)
372 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
373 if((H5E_LINKCOUNT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
374 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
375 assert(H5E_VERSION_g==(-1));
376 if((msg = H5E_create_msg(cls, H5E_MINOR, "Wrong version number"))==NULL)
377 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
378 if((H5E_VERSION_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
379 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
380 assert(H5E_ALIGNMENT_g==(-1));
381 if((msg = H5E_create_msg(cls, H5E_MINOR, "Alignment error"))==NULL)
382 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
383 if((H5E_ALIGNMENT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
384 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
385 assert(H5E_BADMESG_g==(-1));
386 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unrecognized message"))==NULL)
387 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
388 if((H5E_BADMESG_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
389 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
390 assert(H5E_CANTDELETE_g==(-1));
391 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't delete message"))==NULL)
392 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
393 if((H5E_CANTDELETE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
394 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
395 assert(H5E_BADITER_g==(-1));
396 if((msg = H5E_create_msg(cls, H5E_MINOR, "Iteration failed"))==NULL)
397 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
398 if((H5E_BADITER_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
399 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
400 assert(H5E_CANTPACK_g==(-1));
401 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't pack messages"))==NULL)
402 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
403 if((H5E_CANTPACK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
404 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
405 assert(H5E_CANTRESET_g==(-1));
406 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't reset object"))==NULL)
407 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
408 if((H5E_CANTRESET_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
409 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
410 assert(H5E_CANTRENAME_g==(-1));
411 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to rename object"))==NULL)
412 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
413 if((H5E_CANTRENAME_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
244414 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
245415
246416 /* System level errors */
250420 if((H5E_SYSERRSTR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
251421 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
252422
423 /* I/O pipeline errors */
424 assert(H5E_NOFILTER_g==(-1));
425 if((msg = H5E_create_msg(cls, H5E_MINOR, "Requested filter is not available"))==NULL)
426 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
427 if((H5E_NOFILTER_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
428 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
429 assert(H5E_CALLBACK_g==(-1));
430 if((msg = H5E_create_msg(cls, H5E_MINOR, "Callback failed"))==NULL)
431 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
432 if((H5E_CALLBACK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
433 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
434 assert(H5E_CANAPPLY_g==(-1));
435 if((msg = H5E_create_msg(cls, H5E_MINOR, "Error from filter 'can apply' callback"))==NULL)
436 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
437 if((H5E_CANAPPLY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
438 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
439 assert(H5E_SETLOCAL_g==(-1));
440 if((msg = H5E_create_msg(cls, H5E_MINOR, "Error from filter 'set local' callback"))==NULL)
441 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
442 if((H5E_SETLOCAL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
443 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
444 assert(H5E_NOENCODER_g==(-1));
445 if((msg = H5E_create_msg(cls, H5E_MINOR, "Filter present but encoding disabled"))==NULL)
446 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
447 if((H5E_NOENCODER_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
448 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
449 assert(H5E_CANTFILTER_g==(-1));
450 if((msg = H5E_create_msg(cls, H5E_MINOR, "Filter operation failed"))==NULL)
451 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
452 if((H5E_CANTFILTER_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
453 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
454
455 /* Group related errors */
456 assert(H5E_CANTOPENOBJ_g==(-1));
457 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't open object"))==NULL)
458 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
459 if((H5E_CANTOPENOBJ_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
460 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
461 assert(H5E_CANTCLOSEOBJ_g==(-1));
462 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't close object"))==NULL)
463 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
464 if((H5E_CANTCLOSEOBJ_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
465 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
466 assert(H5E_COMPLEN_g==(-1));
467 if((msg = H5E_create_msg(cls, H5E_MINOR, "Name component is too long"))==NULL)
468 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
469 if((H5E_COMPLEN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
470 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
471 assert(H5E_PATH_g==(-1));
472 if((msg = H5E_create_msg(cls, H5E_MINOR, "Problem with path to object"))==NULL)
473 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
474 if((H5E_PATH_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
475 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
476
477 /* No error */
478 assert(H5E_NONE_MINOR_g==(-1));
479 if((msg = H5E_create_msg(cls, H5E_MINOR, "No error"))==NULL)
480 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
481 if((H5E_NONE_MINOR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
482 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
483
484 /* Plugin errors */
485 assert(H5E_OPENERROR_g==(-1));
486 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't open directory or file"))==NULL)
487 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
488 if((H5E_OPENERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
489 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
490
491 /* File accessibilty errors */
492 assert(H5E_FILEEXISTS_g==(-1));
493 if((msg = H5E_create_msg(cls, H5E_MINOR, "File already exists"))==NULL)
494 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
495 if((H5E_FILEEXISTS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
496 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
497 assert(H5E_FILEOPEN_g==(-1));
498 if((msg = H5E_create_msg(cls, H5E_MINOR, "File already open"))==NULL)
499 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
500 if((H5E_FILEOPEN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
501 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
502 assert(H5E_CANTCREATE_g==(-1));
503 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to create file"))==NULL)
504 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
505 if((H5E_CANTCREATE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
506 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
507 assert(H5E_CANTOPENFILE_g==(-1));
508 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to open file"))==NULL)
509 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
510 if((H5E_CANTOPENFILE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
511 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
512 assert(H5E_CANTCLOSEFILE_g==(-1));
513 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to close file"))==NULL)
514 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
515 if((H5E_CANTCLOSEFILE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
516 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
517 assert(H5E_NOTHDF5_g==(-1));
518 if((msg = H5E_create_msg(cls, H5E_MINOR, "Not an HDF5 file"))==NULL)
519 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
520 if((H5E_NOTHDF5_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
521 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
522 assert(H5E_BADFILE_g==(-1));
523 if((msg = H5E_create_msg(cls, H5E_MINOR, "Bad file ID accessed"))==NULL)
524 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
525 if((H5E_BADFILE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
526 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
527 assert(H5E_TRUNCATED_g==(-1));
528 if((msg = H5E_create_msg(cls, H5E_MINOR, "File has been truncated"))==NULL)
529 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
530 if((H5E_TRUNCATED_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
531 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
532 assert(H5E_MOUNT_g==(-1));
533 if((msg = H5E_create_msg(cls, H5E_MINOR, "File mount error"))==NULL)
534 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
535 if((H5E_MOUNT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
536 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
537
538 /* Object atom related errors */
539 assert(H5E_BADATOM_g==(-1));
540 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to find atom information (already closed?)"))==NULL)
541 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
542 if((H5E_BADATOM_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
543 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
544 assert(H5E_BADGROUP_g==(-1));
545 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to find ID group information"))==NULL)
546 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
547 if((H5E_BADGROUP_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
548 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
549 assert(H5E_CANTREGISTER_g==(-1));
550 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to register new atom"))==NULL)
551 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
552 if((H5E_CANTREGISTER_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
553 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
554 assert(H5E_CANTINC_g==(-1));
555 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to increment reference count"))==NULL)
556 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
557 if((H5E_CANTINC_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
558 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
559 assert(H5E_CANTDEC_g==(-1));
560 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to decrement reference count"))==NULL)
561 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
562 if((H5E_CANTDEC_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
563 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
564 assert(H5E_NOIDS_g==(-1));
565 if((msg = H5E_create_msg(cls, H5E_MINOR, "Out of IDs for group"))==NULL)
566 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
567 if((H5E_NOIDS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
568 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
569
570 /* Cache related errors */
571 assert(H5E_CANTFLUSH_g==(-1));
572 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to flush data from cache"))==NULL)
573 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
574 if((H5E_CANTFLUSH_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
575 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
576 assert(H5E_CANTSERIALIZE_g==(-1));
577 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to serialize data from cache"))==NULL)
578 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
579 if((H5E_CANTSERIALIZE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
580 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
581 assert(H5E_CANTTAG_g==(-1));
582 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to tag metadata in the cache"))==NULL)
583 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
584 if((H5E_CANTTAG_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
585 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
586 assert(H5E_CANTLOAD_g==(-1));
587 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to load metadata into cache"))==NULL)
588 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
589 if((H5E_CANTLOAD_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
590 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
591 assert(H5E_PROTECT_g==(-1));
592 if((msg = H5E_create_msg(cls, H5E_MINOR, "Protected metadata error"))==NULL)
593 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
594 if((H5E_PROTECT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
595 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
596 assert(H5E_NOTCACHED_g==(-1));
597 if((msg = H5E_create_msg(cls, H5E_MINOR, "Metadata not currently cached"))==NULL)
598 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
599 if((H5E_NOTCACHED_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
600 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
601 assert(H5E_SYSTEM_g==(-1));
602 if((msg = H5E_create_msg(cls, H5E_MINOR, "Internal error detected"))==NULL)
603 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
604 if((H5E_SYSTEM_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
605 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
606 assert(H5E_CANTINS_g==(-1));
607 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to insert metadata into cache"))==NULL)
608 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
609 if((H5E_CANTINS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
610 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
611 assert(H5E_CANTPROTECT_g==(-1));
612 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to protect metadata"))==NULL)
613 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
614 if((H5E_CANTPROTECT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
615 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
616 assert(H5E_CANTUNPROTECT_g==(-1));
617 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to unprotect metadata"))==NULL)
618 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
619 if((H5E_CANTUNPROTECT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
620 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
621 assert(H5E_CANTPIN_g==(-1));
622 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to pin cache entry"))==NULL)
623 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
624 if((H5E_CANTPIN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
625 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
626 assert(H5E_CANTUNPIN_g==(-1));
627 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to un-pin cache entry"))==NULL)
628 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
629 if((H5E_CANTUNPIN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
630 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
631 assert(H5E_CANTMARKDIRTY_g==(-1));
632 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to mark a pinned entry as dirty"))==NULL)
633 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
634 if((H5E_CANTMARKDIRTY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
635 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
636 assert(H5E_CANTDIRTY_g==(-1));
637 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to mark metadata as dirty"))==NULL)
638 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
639 if((H5E_CANTDIRTY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
640 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
641 assert(H5E_CANTEXPUNGE_g==(-1));
642 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to expunge a metadata cache entry"))==NULL)
643 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
644 if((H5E_CANTEXPUNGE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
645 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
646 assert(H5E_CANTRESIZE_g==(-1));
647 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to resize a metadata cache entry"))==NULL)
648 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
649 if((H5E_CANTRESIZE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
650 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
651 assert(H5E_CANTDEPEND_g==(-1));
652 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to create a flush dependency"))==NULL)
653 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
654 if((H5E_CANTDEPEND_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
655 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
656 assert(H5E_CANTUNDEPEND_g==(-1));
657 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to destroy a flush dependency"))==NULL)
658 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
659 if((H5E_CANTUNDEPEND_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
660 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
661 assert(H5E_CANTNOTIFY_g==(-1));
662 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to notify object about action"))==NULL)
663 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
664 if((H5E_CANTNOTIFY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
665 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
666 assert(H5E_LOGFAIL_g==(-1));
667 if((msg = H5E_create_msg(cls, H5E_MINOR, "Failure in the cache logging framework"))==NULL)
668 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
669 if((H5E_LOGFAIL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
670 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
671 assert(H5E_CANTCORK_g==(-1));
672 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to cork an object"))==NULL)
673 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
674 if((H5E_CANTCORK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
675 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
676 assert(H5E_CANTUNCORK_g==(-1));
677 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to uncork an object"))==NULL)
678 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
679 if((H5E_CANTUNCORK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
680 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
681
682 /* Link related errors */
683 assert(H5E_TRAVERSE_g==(-1));
684 if((msg = H5E_create_msg(cls, H5E_MINOR, "Link traversal failure"))==NULL)
685 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
686 if((H5E_TRAVERSE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
687 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
688 assert(H5E_NLINKS_g==(-1));
689 if((msg = H5E_create_msg(cls, H5E_MINOR, "Too many soft links in path"))==NULL)
690 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
691 if((H5E_NLINKS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
692 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
693 assert(H5E_NOTREGISTERED_g==(-1));
694 if((msg = H5E_create_msg(cls, H5E_MINOR, "Link class not registered"))==NULL)
695 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
696 if((H5E_NOTREGISTERED_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
697 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
698 assert(H5E_CANTMOVE_g==(-1));
699 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't move object"))==NULL)
700 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
701 if((H5E_CANTMOVE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
702 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
703 assert(H5E_CANTSORT_g==(-1));
704 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't sort objects"))==NULL)
705 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
706 if((H5E_CANTSORT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
707 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
708
709 /* Parallel MPI errors */
710 assert(H5E_MPI_g==(-1));
711 if((msg = H5E_create_msg(cls, H5E_MINOR, "Some MPI function failed"))==NULL)
712 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
713 if((H5E_MPI_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
714 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
715 assert(H5E_MPIERRSTR_g==(-1));
716 if((msg = H5E_create_msg(cls, H5E_MINOR, "MPI Error String"))==NULL)
717 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
718 if((H5E_MPIERRSTR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
719 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
720 assert(H5E_CANTRECV_g==(-1));
721 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't receive data"))==NULL)
722 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
723 if((H5E_CANTRECV_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
724 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
725
726 /* Dataspace errors */
727 assert(H5E_CANTCLIP_g==(-1));
728 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't clip hyperslab region"))==NULL)
729 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
730 if((H5E_CANTCLIP_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
731 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
732 assert(H5E_CANTCOUNT_g==(-1));
733 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't count elements"))==NULL)
734 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
735 if((H5E_CANTCOUNT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
736 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
737 assert(H5E_CANTSELECT_g==(-1));
738 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't select hyperslab"))==NULL)
739 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
740 if((H5E_CANTSELECT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
741 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
742 assert(H5E_CANTNEXT_g==(-1));
743 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't move to next iterator location"))==NULL)
744 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
745 if((H5E_CANTNEXT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
746 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
747 assert(H5E_BADSELECT_g==(-1));
748 if((msg = H5E_create_msg(cls, H5E_MINOR, "Invalid selection"))==NULL)
749 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
750 if((H5E_BADSELECT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
751 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
752 assert(H5E_CANTCOMPARE_g==(-1));
753 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't compare objects"))==NULL)
754 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
755 if((H5E_CANTCOMPARE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
756 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
757 assert(H5E_CANTAPPEND_g==(-1));
758 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't append object"))==NULL)
759 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
760 if((H5E_CANTAPPEND_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
761 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
762
253763 /* Argument errors */
254764 assert(H5E_UNINITIALIZED_g==(-1));
255765 if((msg = H5E_create_msg(cls, H5E_MINOR, "Information is uinitialized"))==NULL)
277787 if((H5E_BADVALUE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
278788 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
279789
790 /* B-tree related errors */
791 assert(H5E_NOTFOUND_g==(-1));
792 if((msg = H5E_create_msg(cls, H5E_MINOR, "Object not found"))==NULL)
793 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
794 if((H5E_NOTFOUND_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
795 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
796 assert(H5E_EXISTS_g==(-1));
797 if((msg = H5E_create_msg(cls, H5E_MINOR, "Object already exists"))==NULL)
798 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
799 if((H5E_EXISTS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
800 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
801 assert(H5E_CANTENCODE_g==(-1));
802 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to encode value"))==NULL)
803 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
804 if((H5E_CANTENCODE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
805 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
806 assert(H5E_CANTDECODE_g==(-1));
807 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to decode value"))==NULL)
808 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
809 if((H5E_CANTDECODE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
810 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
811 assert(H5E_CANTSPLIT_g==(-1));
812 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to split node"))==NULL)
813 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
814 if((H5E_CANTSPLIT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
815 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
816 assert(H5E_CANTREDISTRIBUTE_g==(-1));
817 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to redistribute records"))==NULL)
818 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
819 if((H5E_CANTREDISTRIBUTE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
820 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
821 assert(H5E_CANTSWAP_g==(-1));
822 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to swap records"))==NULL)
823 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
824 if((H5E_CANTSWAP_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
825 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
826 assert(H5E_CANTINSERT_g==(-1));
827 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to insert object"))==NULL)
828 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
829 if((H5E_CANTINSERT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
830 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
831 assert(H5E_CANTLIST_g==(-1));
832 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to list node"))==NULL)
833 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
834 if((H5E_CANTLIST_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
835 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
836 assert(H5E_CANTMODIFY_g==(-1));
837 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to modify record"))==NULL)
838 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
839 if((H5E_CANTMODIFY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
840 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
841 assert(H5E_CANTREMOVE_g==(-1));
842 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to remove object"))==NULL)
843 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
844 if((H5E_CANTREMOVE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
845 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
846
280847 /* Datatype conversion errors */
281848 assert(H5E_CANTCONVERT_g==(-1));
282849 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't convert datatypes"))==NULL)
289856 if((H5E_BADSIZE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
290857 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
291858
292 /* File accessibilty errors */
293 assert(H5E_FILEEXISTS_g==(-1));
294 if((msg = H5E_create_msg(cls, H5E_MINOR, "File already exists"))==NULL)
295 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
296 if((H5E_FILEEXISTS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
297 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
298 assert(H5E_FILEOPEN_g==(-1));
299 if((msg = H5E_create_msg(cls, H5E_MINOR, "File already open"))==NULL)
300 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
301 if((H5E_FILEOPEN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
302 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
303 assert(H5E_CANTCREATE_g==(-1));
304 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to create file"))==NULL)
305 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
306 if((H5E_CANTCREATE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
307 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
308 assert(H5E_CANTOPENFILE_g==(-1));
309 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to open file"))==NULL)
310 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
311 if((H5E_CANTOPENFILE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
312 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
313 assert(H5E_CANTCLOSEFILE_g==(-1));
314 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to close file"))==NULL)
315 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
316 if((H5E_CANTCLOSEFILE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
317 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
318 assert(H5E_NOTHDF5_g==(-1));
319 if((msg = H5E_create_msg(cls, H5E_MINOR, "Not an HDF5 file"))==NULL)
320 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
321 if((H5E_NOTHDF5_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
322 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
323 assert(H5E_BADFILE_g==(-1));
324 if((msg = H5E_create_msg(cls, H5E_MINOR, "Bad file ID accessed"))==NULL)
325 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
326 if((H5E_BADFILE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
327 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
328 assert(H5E_TRUNCATED_g==(-1));
329 if((msg = H5E_create_msg(cls, H5E_MINOR, "File has been truncated"))==NULL)
330 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
331 if((H5E_TRUNCATED_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
332 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
333 assert(H5E_MOUNT_g==(-1));
334 if((msg = H5E_create_msg(cls, H5E_MINOR, "File mount error"))==NULL)
335 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
336 if((H5E_MOUNT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
337 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
338
339 /* Object atom related errors */
340 assert(H5E_BADATOM_g==(-1));
341 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to find atom information (already closed?)"))==NULL)
342 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
343 if((H5E_BADATOM_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
344 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
345 assert(H5E_BADGROUP_g==(-1));
346 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to find ID group information"))==NULL)
347 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
348 if((H5E_BADGROUP_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
349 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
350 assert(H5E_CANTREGISTER_g==(-1));
351 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to register new atom"))==NULL)
352 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
353 if((H5E_CANTREGISTER_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
354 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
355 assert(H5E_CANTINC_g==(-1));
356 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to increment reference count"))==NULL)
357 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
358 if((H5E_CANTINC_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
359 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
360 assert(H5E_CANTDEC_g==(-1));
361 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to decrement reference count"))==NULL)
362 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
363 if((H5E_CANTDEC_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
364 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
365 assert(H5E_NOIDS_g==(-1));
366 if((msg = H5E_create_msg(cls, H5E_MINOR, "Out of IDs for group"))==NULL)
367 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
368 if((H5E_NOIDS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
369 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
370
371 /* Property list errors */
372 assert(H5E_CANTGET_g==(-1));
373 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't get value"))==NULL)
374 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
375 if((H5E_CANTGET_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
376 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
377 assert(H5E_CANTSET_g==(-1));
378 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't set value"))==NULL)
379 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
380 if((H5E_CANTSET_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
381 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
382 assert(H5E_DUPCLASS_g==(-1));
383 if((msg = H5E_create_msg(cls, H5E_MINOR, "Duplicate class name in parent class"))==NULL)
384 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
385 if((H5E_DUPCLASS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
386 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
387 assert(H5E_SETDISALLOWED_g==(-1));
388 if((msg = H5E_create_msg(cls, H5E_MINOR, "Disallowed operation"))==NULL)
389 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
390 if((H5E_SETDISALLOWED_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
391 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
392
393 /* Generic low-level file I/O errors */
394 assert(H5E_SEEKERROR_g==(-1));
395 if((msg = H5E_create_msg(cls, H5E_MINOR, "Seek failed"))==NULL)
396 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
397 if((H5E_SEEKERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
398 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
399 assert(H5E_READERROR_g==(-1));
400 if((msg = H5E_create_msg(cls, H5E_MINOR, "Read failed"))==NULL)
401 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
402 if((H5E_READERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
403 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
404 assert(H5E_WRITEERROR_g==(-1));
405 if((msg = H5E_create_msg(cls, H5E_MINOR, "Write failed"))==NULL)
406 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
407 if((H5E_WRITEERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
408 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
409 assert(H5E_CLOSEERROR_g==(-1));
410 if((msg = H5E_create_msg(cls, H5E_MINOR, "Close failed"))==NULL)
411 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
412 if((H5E_CLOSEERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
413 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
414 assert(H5E_OVERFLOW_g==(-1));
415 if((msg = H5E_create_msg(cls, H5E_MINOR, "Address overflowed"))==NULL)
416 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
417 if((H5E_OVERFLOW_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
418 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
419 assert(H5E_FCNTL_g==(-1));
420 if((msg = H5E_create_msg(cls, H5E_MINOR, "File control (fcntl) failed"))==NULL)
421 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
422 if((H5E_FCNTL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
423 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
424
425 /* Dataspace errors */
426 assert(H5E_CANTCLIP_g==(-1));
427 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't clip hyperslab region"))==NULL)
428 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
429 if((H5E_CANTCLIP_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
430 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
431 assert(H5E_CANTCOUNT_g==(-1));
432 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't count elements"))==NULL)
433 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
434 if((H5E_CANTCOUNT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
435 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
436 assert(H5E_CANTSELECT_g==(-1));
437 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't select hyperslab"))==NULL)
438 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
439 if((H5E_CANTSELECT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
440 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
441 assert(H5E_CANTNEXT_g==(-1));
442 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't move to next iterator location"))==NULL)
443 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
444 if((H5E_CANTNEXT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
445 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
446 assert(H5E_BADSELECT_g==(-1));
447 if((msg = H5E_create_msg(cls, H5E_MINOR, "Invalid selection"))==NULL)
448 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
449 if((H5E_BADSELECT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
450 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
451 assert(H5E_CANTCOMPARE_g==(-1));
452 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't compare objects"))==NULL)
453 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
454 if((H5E_CANTCOMPARE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
455 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
456 assert(H5E_CANTAPPEND_g==(-1));
457 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't append object"))==NULL)
458 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
459 if((H5E_CANTAPPEND_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
460 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
461
462 /* Link related errors */
463 assert(H5E_TRAVERSE_g==(-1));
464 if((msg = H5E_create_msg(cls, H5E_MINOR, "Link traversal failure"))==NULL)
465 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
466 if((H5E_TRAVERSE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
467 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
468 assert(H5E_NLINKS_g==(-1));
469 if((msg = H5E_create_msg(cls, H5E_MINOR, "Too many soft links in path"))==NULL)
470 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
471 if((H5E_NLINKS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
472 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
473 assert(H5E_NOTREGISTERED_g==(-1));
474 if((msg = H5E_create_msg(cls, H5E_MINOR, "Link class not registered"))==NULL)
475 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
476 if((H5E_NOTREGISTERED_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
477 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
478 assert(H5E_CANTMOVE_g==(-1));
479 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't move object"))==NULL)
480 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
481 if((H5E_CANTMOVE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
482 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
483 assert(H5E_CANTSORT_g==(-1));
484 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't sort objects"))==NULL)
485 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
486 if((H5E_CANTSORT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
487 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
488
489 /* Resource errors */
490 assert(H5E_NOSPACE_g==(-1));
491 if((msg = H5E_create_msg(cls, H5E_MINOR, "No space available for allocation"))==NULL)
492 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
493 if((H5E_NOSPACE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
494 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
495 assert(H5E_CANTALLOC_g==(-1));
496 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't allocate space"))==NULL)
497 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
498 if((H5E_CANTALLOC_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
499 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
500 assert(H5E_CANTCOPY_g==(-1));
501 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to copy object"))==NULL)
502 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
503 if((H5E_CANTCOPY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
504 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
505 assert(H5E_CANTFREE_g==(-1));
506 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to free object"))==NULL)
507 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
508 if((H5E_CANTFREE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
509 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
510 assert(H5E_ALREADYEXISTS_g==(-1));
511 if((msg = H5E_create_msg(cls, H5E_MINOR, "Object already exists"))==NULL)
512 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
513 if((H5E_ALREADYEXISTS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
514 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
515 assert(H5E_CANTLOCK_g==(-1));
516 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to lock object"))==NULL)
517 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
518 if((H5E_CANTLOCK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
519 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
520 assert(H5E_CANTUNLOCK_g==(-1));
521 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to unlock object"))==NULL)
522 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
523 if((H5E_CANTUNLOCK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
524 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
525 assert(H5E_CANTGC_g==(-1));
526 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to garbage collect"))==NULL)
527 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
528 if((H5E_CANTGC_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
529 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
530 assert(H5E_CANTGETSIZE_g==(-1));
531 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to compute size"))==NULL)
532 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
533 if((H5E_CANTGETSIZE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
534 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
535 assert(H5E_OBJOPEN_g==(-1));
536 if((msg = H5E_create_msg(cls, H5E_MINOR, "Object is already open"))==NULL)
537 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
538 if((H5E_OBJOPEN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
539 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
540
541 /* Parallel MPI errors */
542 assert(H5E_MPI_g==(-1));
543 if((msg = H5E_create_msg(cls, H5E_MINOR, "Some MPI function failed"))==NULL)
544 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
545 if((H5E_MPI_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
546 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
547 assert(H5E_MPIERRSTR_g==(-1));
548 if((msg = H5E_create_msg(cls, H5E_MINOR, "MPI Error String"))==NULL)
549 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
550 if((H5E_MPIERRSTR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
551 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
552 assert(H5E_CANTRECV_g==(-1));
553 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't receive data"))==NULL)
554 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
555 if((H5E_CANTRECV_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
556 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
557
558 /* Object header related errors */
559 assert(H5E_LINKCOUNT_g==(-1));
560 if((msg = H5E_create_msg(cls, H5E_MINOR, "Bad object header link count"))==NULL)
561 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
562 if((H5E_LINKCOUNT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
563 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
564 assert(H5E_VERSION_g==(-1));
565 if((msg = H5E_create_msg(cls, H5E_MINOR, "Wrong version number"))==NULL)
566 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
567 if((H5E_VERSION_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
568 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
569 assert(H5E_ALIGNMENT_g==(-1));
570 if((msg = H5E_create_msg(cls, H5E_MINOR, "Alignment error"))==NULL)
571 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
572 if((H5E_ALIGNMENT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
573 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
574 assert(H5E_BADMESG_g==(-1));
575 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unrecognized message"))==NULL)
576 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
577 if((H5E_BADMESG_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
578 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
579 assert(H5E_CANTDELETE_g==(-1));
580 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't delete message"))==NULL)
581 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
582 if((H5E_CANTDELETE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
583 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
584 assert(H5E_BADITER_g==(-1));
585 if((msg = H5E_create_msg(cls, H5E_MINOR, "Iteration failed"))==NULL)
586 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
587 if((H5E_BADITER_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
588 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
589 assert(H5E_CANTPACK_g==(-1));
590 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't pack messages"))==NULL)
591 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
592 if((H5E_CANTPACK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
593 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
594 assert(H5E_CANTRESET_g==(-1));
595 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't reset object"))==NULL)
596 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
597 if((H5E_CANTRESET_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
598 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
599 assert(H5E_CANTRENAME_g==(-1));
600 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to rename object"))==NULL)
601 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
602 if((H5E_CANTRENAME_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
603 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
604
605 /* Group related errors */
606 assert(H5E_CANTOPENOBJ_g==(-1));
607 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't open object"))==NULL)
608 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
609 if((H5E_CANTOPENOBJ_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
610 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
611 assert(H5E_CANTCLOSEOBJ_g==(-1));
612 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't close object"))==NULL)
613 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
614 if((H5E_CANTCLOSEOBJ_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
615 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
616 assert(H5E_COMPLEN_g==(-1));
617 if((msg = H5E_create_msg(cls, H5E_MINOR, "Name component is too long"))==NULL)
618 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
619 if((H5E_COMPLEN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
620 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
621 assert(H5E_PATH_g==(-1));
622 if((msg = H5E_create_msg(cls, H5E_MINOR, "Problem with path to object"))==NULL)
623 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
624 if((H5E_PATH_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
625 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
626
627 /* I/O pipeline errors */
628 assert(H5E_NOFILTER_g==(-1));
629 if((msg = H5E_create_msg(cls, H5E_MINOR, "Requested filter is not available"))==NULL)
630 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
631 if((H5E_NOFILTER_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
632 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
633 assert(H5E_CALLBACK_g==(-1));
634 if((msg = H5E_create_msg(cls, H5E_MINOR, "Callback failed"))==NULL)
635 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
636 if((H5E_CALLBACK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
637 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
638 assert(H5E_CANAPPLY_g==(-1));
639 if((msg = H5E_create_msg(cls, H5E_MINOR, "Error from filter 'can apply' callback"))==NULL)
640 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
641 if((H5E_CANAPPLY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
642 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
643 assert(H5E_SETLOCAL_g==(-1));
644 if((msg = H5E_create_msg(cls, H5E_MINOR, "Error from filter 'set local' callback"))==NULL)
645 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
646 if((H5E_SETLOCAL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
647 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
648 assert(H5E_NOENCODER_g==(-1));
649 if((msg = H5E_create_msg(cls, H5E_MINOR, "Filter present but encoding disabled"))==NULL)
650 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
651 if((H5E_NOENCODER_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
652 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
653 assert(H5E_CANTFILTER_g==(-1));
654 if((msg = H5E_create_msg(cls, H5E_MINOR, "Filter operation failed"))==NULL)
655 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
656 if((H5E_CANTFILTER_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
657 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
658
659 /* Cache related errors */
660 assert(H5E_CANTFLUSH_g==(-1));
661 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to flush data from cache"))==NULL)
662 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
663 if((H5E_CANTFLUSH_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
664 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
665 assert(H5E_CANTSERIALIZE_g==(-1));
666 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to serialize data from cache"))==NULL)
667 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
668 if((H5E_CANTSERIALIZE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
669 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
670 assert(H5E_CANTTAG_g==(-1));
671 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to tag metadata in the cache"))==NULL)
672 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
673 if((H5E_CANTTAG_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
674 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
675 assert(H5E_CANTLOAD_g==(-1));
676 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to load metadata into cache"))==NULL)
677 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
678 if((H5E_CANTLOAD_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
679 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
680 assert(H5E_PROTECT_g==(-1));
681 if((msg = H5E_create_msg(cls, H5E_MINOR, "Protected metadata error"))==NULL)
682 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
683 if((H5E_PROTECT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
684 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
685 assert(H5E_NOTCACHED_g==(-1));
686 if((msg = H5E_create_msg(cls, H5E_MINOR, "Metadata not currently cached"))==NULL)
687 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
688 if((H5E_NOTCACHED_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
689 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
690 assert(H5E_SYSTEM_g==(-1));
691 if((msg = H5E_create_msg(cls, H5E_MINOR, "Internal error detected"))==NULL)
692 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
693 if((H5E_SYSTEM_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
694 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
695 assert(H5E_CANTINS_g==(-1));
696 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to insert metadata into cache"))==NULL)
697 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
698 if((H5E_CANTINS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
699 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
700 assert(H5E_CANTPROTECT_g==(-1));
701 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to protect metadata"))==NULL)
702 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
703 if((H5E_CANTPROTECT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
704 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
705 assert(H5E_CANTUNPROTECT_g==(-1));
706 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to unprotect metadata"))==NULL)
707 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
708 if((H5E_CANTUNPROTECT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
709 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
710 assert(H5E_CANTPIN_g==(-1));
711 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to pin cache entry"))==NULL)
712 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
713 if((H5E_CANTPIN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
714 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
715 assert(H5E_CANTUNPIN_g==(-1));
716 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to un-pin cache entry"))==NULL)
717 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
718 if((H5E_CANTUNPIN_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
719 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
720 assert(H5E_CANTMARKDIRTY_g==(-1));
721 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to mark a pinned entry as dirty"))==NULL)
722 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
723 if((H5E_CANTMARKDIRTY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
724 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
725 assert(H5E_CANTDIRTY_g==(-1));
726 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to mark metadata as dirty"))==NULL)
727 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
728 if((H5E_CANTDIRTY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
729 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
730 assert(H5E_CANTEXPUNGE_g==(-1));
731 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to expunge a metadata cache entry"))==NULL)
732 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
733 if((H5E_CANTEXPUNGE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
734 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
735 assert(H5E_CANTRESIZE_g==(-1));
736 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to resize a metadata cache entry"))==NULL)
737 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
738 if((H5E_CANTRESIZE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
739 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
740 assert(H5E_CANTDEPEND_g==(-1));
741 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to create a flush dependency"))==NULL)
742 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
743 if((H5E_CANTDEPEND_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
744 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
745 assert(H5E_CANTUNDEPEND_g==(-1));
746 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to destroy a flush dependency"))==NULL)
747 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
748 if((H5E_CANTUNDEPEND_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
749 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
750 assert(H5E_CANTNOTIFY_g==(-1));
751 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to notify object about action"))==NULL)
752 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
753 if((H5E_CANTNOTIFY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
754 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
755 assert(H5E_LOGFAIL_g==(-1));
756 if((msg = H5E_create_msg(cls, H5E_MINOR, "Failure in the cache logging framework"))==NULL)
757 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
758 if((H5E_LOGFAIL_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
759 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
760 assert(H5E_CANTCORK_g==(-1));
761 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to cork an object"))==NULL)
762 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
763 if((H5E_CANTCORK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
764 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
765 assert(H5E_CANTUNCORK_g==(-1));
766 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to uncork an object"))==NULL)
767 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
768 if((H5E_CANTUNCORK_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
769 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
770
771 /* B-tree related errors */
772 assert(H5E_NOTFOUND_g==(-1));
773 if((msg = H5E_create_msg(cls, H5E_MINOR, "Object not found"))==NULL)
774 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
775 if((H5E_NOTFOUND_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
776 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
777 assert(H5E_EXISTS_g==(-1));
778 if((msg = H5E_create_msg(cls, H5E_MINOR, "Object already exists"))==NULL)
779 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
780 if((H5E_EXISTS_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
781 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
782 assert(H5E_CANTENCODE_g==(-1));
783 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to encode value"))==NULL)
784 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
785 if((H5E_CANTENCODE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
786 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
787 assert(H5E_CANTDECODE_g==(-1));
788 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to decode value"))==NULL)
789 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
790 if((H5E_CANTDECODE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
791 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
792 assert(H5E_CANTSPLIT_g==(-1));
793 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to split node"))==NULL)
794 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
795 if((H5E_CANTSPLIT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
796 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
797 assert(H5E_CANTREDISTRIBUTE_g==(-1));
798 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to redistribute records"))==NULL)
799 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
800 if((H5E_CANTREDISTRIBUTE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
801 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
802 assert(H5E_CANTSWAP_g==(-1));
803 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to swap records"))==NULL)
804 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
805 if((H5E_CANTSWAP_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
806 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
807 assert(H5E_CANTINSERT_g==(-1));
808 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to insert object"))==NULL)
809 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
810 if((H5E_CANTINSERT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
811 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
812 assert(H5E_CANTLIST_g==(-1));
813 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to list node"))==NULL)
814 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
815 if((H5E_CANTLIST_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
816 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
817 assert(H5E_CANTMODIFY_g==(-1));
818 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to modify record"))==NULL)
819 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
820 if((H5E_CANTMODIFY_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
821 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
822 assert(H5E_CANTREMOVE_g==(-1));
823 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to remove object"))==NULL)
824 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
825 if((H5E_CANTREMOVE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
826 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
827
828 /* Function entry/exit interface errors */
829 assert(H5E_CANTINIT_g==(-1));
830 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to initialize object"))==NULL)
831 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
832 if((H5E_CANTINIT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
833 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
834 assert(H5E_ALREADYINIT_g==(-1));
835 if((msg = H5E_create_msg(cls, H5E_MINOR, "Object already initialized"))==NULL)
836 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
837 if((H5E_ALREADYINIT_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
838 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
839 assert(H5E_CANTRELEASE_g==(-1));
840 if((msg = H5E_create_msg(cls, H5E_MINOR, "Unable to release object"))==NULL)
841 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
842 if((H5E_CANTRELEASE_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
843 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
844
845 /* Plugin errors */
846 assert(H5E_OPENERROR_g==(-1));
847 if((msg = H5E_create_msg(cls, H5E_MINOR, "Can't open directory or file"))==NULL)
848 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
849 if((H5E_OPENERROR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
850 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
851
852 /* No error */
853 assert(H5E_NONE_MINOR_g==(-1));
854 if((msg = H5E_create_msg(cls, H5E_MINOR, "No error"))==NULL)
855 HGOTO_ERROR(H5E_ERROR, H5E_CANTINIT, FAIL, "error message initialization failed")
856 if((H5E_NONE_MINOR_g = H5I_register(H5I_ERROR_MSG, msg, FALSE))<0)
857 HGOTO_ERROR(H5E_ERROR, H5E_CANTREGISTER, FAIL, "can't register error message")
858
859859 #endif /* H5Einit_H */
742742 done:
743743 if(va_started)
744744 va_end(ap);
745 #ifdef H5_HAVE_VASPRINTF
746 if(tmp)
747 HDfree(tmp);
748 #else /* H5_HAVE_VASPRINTF */
745749 if(tmp)
746750 H5MM_xfree(tmp);
751 #endif /* H5_HAVE_VASPRINTF */
747752
748753 FUNC_LEAVE_NOAPI(ret_value)
749754 } /* end H5E_printf_stack() */
124124
125125 #define HMPI_ERROR(mpierr){ \
126126 MPI_Error_string(mpierr, H5E_mpi_error_str, &H5E_mpi_error_str_len); \
127 HERROR(H5E_INTERNAL, H5E_MPIERRSTR, H5E_mpi_error_str); \
127 HERROR(H5E_INTERNAL, H5E_MPIERRSTR, "%s", H5E_mpi_error_str); \
128128 }
129129 #define HMPI_DONE_ERROR(retcode, str, mpierr){ \
130130 HMPI_ERROR(mpierr); \
1919 #ifndef _H5Epubgen_H
2020 #define _H5Epubgen_H
2121
22 #ifdef __cplusplus
23 extern "C" {
24 #endif
25
2226 /*********************/
2327 /* Major error codes */
2428 /*********************/
2529
30 #define H5E_FUNC (H5OPEN H5E_FUNC_g)
31 #define H5E_FILE (H5OPEN H5E_FILE_g)
32 #define H5E_SOHM (H5OPEN H5E_SOHM_g)
33 #define H5E_SYM (H5OPEN H5E_SYM_g)
34 #define H5E_PLUGIN (H5OPEN H5E_PLUGIN_g)
35 #define H5E_VFL (H5OPEN H5E_VFL_g)
36 #define H5E_INTERNAL (H5OPEN H5E_INTERNAL_g)
37 #define H5E_BTREE (H5OPEN H5E_BTREE_g)
38 #define H5E_REFERENCE (H5OPEN H5E_REFERENCE_g)
39 #define H5E_DATASPACE (H5OPEN H5E_DATASPACE_g)
40 #define H5E_RESOURCE (H5OPEN H5E_RESOURCE_g)
41 #define H5E_RS (H5OPEN H5E_RS_g)
42 #define H5E_FARRAY (H5OPEN H5E_FARRAY_g)
43 #define H5E_HEAP (H5OPEN H5E_HEAP_g)
44 #define H5E_ATTR (H5OPEN H5E_ATTR_g)
45 #define H5E_IO (H5OPEN H5E_IO_g)
46 #define H5E_EFL (H5OPEN H5E_EFL_g)
47 #define H5E_TST (H5OPEN H5E_TST_g)
2648 #define H5E_FSPACE (H5OPEN H5E_FSPACE_g)
49 #define H5E_DATASET (H5OPEN H5E_DATASET_g)
50 #define H5E_STORAGE (H5OPEN H5E_STORAGE_g)
51 #define H5E_LINK (H5OPEN H5E_LINK_g)
2752 #define H5E_PLIST (H5OPEN H5E_PLIST_g)
28 #define H5E_RS (H5OPEN H5E_RS_g)
2953 #define H5E_DATATYPE (H5OPEN H5E_DATATYPE_g)
30 #define H5E_ERROR (H5OPEN H5E_ERROR_g)
31 #define H5E_DATASPACE (H5OPEN H5E_DATASPACE_g)
32 #define H5E_FARRAY (H5OPEN H5E_FARRAY_g)
33 #define H5E_INTERNAL (H5OPEN H5E_INTERNAL_g)
34 #define H5E_PLUGIN (H5OPEN H5E_PLUGIN_g)
35 #define H5E_CACHE (H5OPEN H5E_CACHE_g)
36 #define H5E_FUNC (H5OPEN H5E_FUNC_g)
37 #define H5E_EARRAY (H5OPEN H5E_EARRAY_g)
38 #define H5E_IO (H5OPEN H5E_IO_g)
54 #define H5E_OHDR (H5OPEN H5E_OHDR_g)
55 #define H5E_ATOM (H5OPEN H5E_ATOM_g)
3956 #define H5E_NONE_MAJOR (H5OPEN H5E_NONE_MAJOR_g)
4057 #define H5E_SLIST (H5OPEN H5E_SLIST_g)
41 #define H5E_RESOURCE (H5OPEN H5E_RESOURCE_g)
42 #define H5E_SYM (H5OPEN H5E_SYM_g)
43 #define H5E_ATOM (H5OPEN H5E_ATOM_g)
44 #define H5E_REFERENCE (H5OPEN H5E_REFERENCE_g)
58 #define H5E_ARGS (H5OPEN H5E_ARGS_g)
59 #define H5E_EARRAY (H5OPEN H5E_EARRAY_g)
4560 #define H5E_PLINE (H5OPEN H5E_PLINE_g)
46 #define H5E_ARGS (H5OPEN H5E_ARGS_g)
47 #define H5E_SOHM (H5OPEN H5E_SOHM_g)
48 #define H5E_DATASET (H5OPEN H5E_DATASET_g)
49 #define H5E_STORAGE (H5OPEN H5E_STORAGE_g)
50 #define H5E_EFL (H5OPEN H5E_EFL_g)
51 #define H5E_FILE (H5OPEN H5E_FILE_g)
52 #define H5E_TST (H5OPEN H5E_TST_g)
53 #define H5E_ATTR (H5OPEN H5E_ATTR_g)
54 #define H5E_HEAP (H5OPEN H5E_HEAP_g)
55 #define H5E_LINK (H5OPEN H5E_LINK_g)
56 #define H5E_BTREE (H5OPEN H5E_BTREE_g)
57 #define H5E_OHDR (H5OPEN H5E_OHDR_g)
58 #define H5E_VFL (H5OPEN H5E_VFL_g)
61 #define H5E_ERROR (H5OPEN H5E_ERROR_g)
62 #define H5E_CACHE (H5OPEN H5E_CACHE_g)
63 H5_DLLVAR hid_t H5E_FUNC_g; /* Function entry/exit */
64 H5_DLLVAR hid_t H5E_FILE_g; /* File accessibilty */
65 H5_DLLVAR hid_t H5E_SOHM_g; /* Shared Object Header Messages */
66 H5_DLLVAR hid_t H5E_SYM_g; /* Symbol table */
67 H5_DLLVAR hid_t H5E_PLUGIN_g; /* Plugin for dynamically loaded library */
68 H5_DLLVAR hid_t H5E_VFL_g; /* Virtual File Layer */
69 H5_DLLVAR hid_t H5E_INTERNAL_g; /* Internal error (too specific to document in detail) */
70 H5_DLLVAR hid_t H5E_BTREE_g; /* B-Tree node */
71 H5_DLLVAR hid_t H5E_REFERENCE_g; /* References */
72 H5_DLLVAR hid_t H5E_DATASPACE_g; /* Dataspace */
73 H5_DLLVAR hid_t H5E_RESOURCE_g; /* Resource unavailable */
74 H5_DLLVAR hid_t H5E_RS_g; /* Reference Counted Strings */
75 H5_DLLVAR hid_t H5E_FARRAY_g; /* Fixed Array */
76 H5_DLLVAR hid_t H5E_HEAP_g; /* Heap */
77 H5_DLLVAR hid_t H5E_ATTR_g; /* Attribute */
78 H5_DLLVAR hid_t H5E_IO_g; /* Low-level I/O */
79 H5_DLLVAR hid_t H5E_EFL_g; /* External file list */
80 H5_DLLVAR hid_t H5E_TST_g; /* Ternary Search Trees */
5981 H5_DLLVAR hid_t H5E_FSPACE_g; /* Free Space Manager */
82 H5_DLLVAR hid_t H5E_DATASET_g; /* Dataset */
83 H5_DLLVAR hid_t H5E_STORAGE_g; /* Data storage */
84 H5_DLLVAR hid_t H5E_LINK_g; /* Links */
6085 H5_DLLVAR hid_t H5E_PLIST_g; /* Property lists */
61 H5_DLLVAR hid_t H5E_RS_g; /* Reference Counted Strings */
6286 H5_DLLVAR hid_t H5E_DATATYPE_g; /* Datatype */
63 H5_DLLVAR hid_t H5E_ERROR_g; /* Error API */
64 H5_DLLVAR hid_t H5E_DATASPACE_g; /* Dataspace */
65 H5_DLLVAR hid_t H5E_FARRAY_g; /* Fixed Array */
66 H5_DLLVAR hid_t H5E_INTERNAL_g; /* Internal error (too specific to document in detail) */
67 H5_DLLVAR hid_t H5E_PLUGIN_g; /* Plugin for dynamically loaded library */
68 H5_DLLVAR hid_t H5E_CACHE_g; /* Object cache */
69 H5_DLLVAR hid_t H5E_FUNC_g; /* Function entry/exit */
70 H5_DLLVAR hid_t H5E_EARRAY_g; /* Extensible Array */
71 H5_DLLVAR hid_t H5E_IO_g; /* Low-level I/O */
87 H5_DLLVAR hid_t H5E_OHDR_g; /* Object header */
88 H5_DLLVAR hid_t H5E_ATOM_g; /* Object atom */
7289 H5_DLLVAR hid_t H5E_NONE_MAJOR_g; /* No error */
7390 H5_DLLVAR hid_t H5E_SLIST_g; /* Skip Lists */
74 H5_DLLVAR hid_t H5E_RESOURCE_g; /* Resource unavailable */
75 H5_DLLVAR hid_t H5E_SYM_g; /* Symbol table */
76 H5_DLLVAR hid_t H5E_ATOM_g; /* Object atom */
77 H5_DLLVAR hid_t H5E_REFERENCE_g; /* References */
91 H5_DLLVAR hid_t H5E_ARGS_g; /* Invalid arguments to routine */
92 H5_DLLVAR hid_t H5E_EARRAY_g; /* Extensible Array */
7893 H5_DLLVAR hid_t H5E_PLINE_g; /* Data filters */
79 H5_DLLVAR hid_t H5E_ARGS_g; /* Invalid arguments to routine */
80 H5_DLLVAR hid_t H5E_SOHM_g; /* Shared Object Header Messages */
81 H5_DLLVAR hid_t H5E_DATASET_g; /* Dataset */
82 H5_DLLVAR hid_t H5E_STORAGE_g; /* Data storage */
83 H5_DLLVAR hid_t H5E_EFL_g; /* External file list */
84 H5_DLLVAR hid_t H5E_FILE_g; /* File accessibilty */
85 H5_DLLVAR hid_t H5E_TST_g; /* Ternary Search Trees */
86 H5_DLLVAR hid_t H5E_ATTR_g; /* Attribute */
87 H5_DLLVAR hid_t H5E_HEAP_g; /* Heap */
88 H5_DLLVAR hid_t H5E_LINK_g; /* Links */
89 H5_DLLVAR hid_t H5E_BTREE_g; /* B-Tree node */
90 H5_DLLVAR hid_t H5E_OHDR_g; /* Object header */
91 H5_DLLVAR hid_t H5E_VFL_g; /* Virtual File Layer */
94 H5_DLLVAR hid_t H5E_ERROR_g; /* Error API */
95 H5_DLLVAR hid_t H5E_CACHE_g; /* Object cache */
9296
9397 /*********************/
9498 /* Minor error codes */
9599 /*********************/
96
97 /* Free space errors */
98 #define H5E_CANTMERGE (H5OPEN H5E_CANTMERGE_g)
99 #define H5E_CANTREVIVE (H5OPEN H5E_CANTREVIVE_g)
100 #define H5E_CANTSHRINK (H5OPEN H5E_CANTSHRINK_g)
101 H5_DLLVAR hid_t H5E_CANTMERGE_g; /* Can't merge objects */
102 H5_DLLVAR hid_t H5E_CANTREVIVE_g; /* Can't revive object */
103 H5_DLLVAR hid_t H5E_CANTSHRINK_g; /* Can't shrink container */
104
105 /* Heap errors */
106 #define H5E_CANTRESTORE (H5OPEN H5E_CANTRESTORE_g)
107 #define H5E_CANTCOMPUTE (H5OPEN H5E_CANTCOMPUTE_g)
108 #define H5E_CANTEXTEND (H5OPEN H5E_CANTEXTEND_g)
109 #define H5E_CANTATTACH (H5OPEN H5E_CANTATTACH_g)
110 #define H5E_CANTUPDATE (H5OPEN H5E_CANTUPDATE_g)
111 #define H5E_CANTOPERATE (H5OPEN H5E_CANTOPERATE_g)
112 H5_DLLVAR hid_t H5E_CANTRESTORE_g; /* Can't restore condition */
113 H5_DLLVAR hid_t H5E_CANTCOMPUTE_g; /* Can't compute value */
114 H5_DLLVAR hid_t H5E_CANTEXTEND_g; /* Can't extend heap's space */
115 H5_DLLVAR hid_t H5E_CANTATTACH_g; /* Can't attach object */
116 H5_DLLVAR hid_t H5E_CANTUPDATE_g; /* Can't update object */
117 H5_DLLVAR hid_t H5E_CANTOPERATE_g; /* Can't operate on object */
118
119 /* System level errors */
120 #define H5E_SYSERRSTR (H5OPEN H5E_SYSERRSTR_g)
121 H5_DLLVAR hid_t H5E_SYSERRSTR_g; /* System error message */
122
123 /* Argument errors */
124 #define H5E_UNINITIALIZED (H5OPEN H5E_UNINITIALIZED_g)
125 #define H5E_UNSUPPORTED (H5OPEN H5E_UNSUPPORTED_g)
126 #define H5E_BADTYPE (H5OPEN H5E_BADTYPE_g)
127 #define H5E_BADRANGE (H5OPEN H5E_BADRANGE_g)
128 #define H5E_BADVALUE (H5OPEN H5E_BADVALUE_g)
129 H5_DLLVAR hid_t H5E_UNINITIALIZED_g; /* Information is uinitialized */
130 H5_DLLVAR hid_t H5E_UNSUPPORTED_g; /* Feature is unsupported */
131 H5_DLLVAR hid_t H5E_BADTYPE_g; /* Inappropriate type */
132 H5_DLLVAR hid_t H5E_BADRANGE_g; /* Out of range */
133 H5_DLLVAR hid_t H5E_BADVALUE_g; /* Bad value */
134
135 /* Datatype conversion errors */
136 #define H5E_CANTCONVERT (H5OPEN H5E_CANTCONVERT_g)
137 #define H5E_BADSIZE (H5OPEN H5E_BADSIZE_g)
138 H5_DLLVAR hid_t H5E_CANTCONVERT_g; /* Can't convert datatypes */
139 H5_DLLVAR hid_t H5E_BADSIZE_g; /* Bad size for object */
140
141 /* File accessibilty errors */
142 #define H5E_FILEEXISTS (H5OPEN H5E_FILEEXISTS_g)
143 #define H5E_FILEOPEN (H5OPEN H5E_FILEOPEN_g)
144 #define H5E_CANTCREATE (H5OPEN H5E_CANTCREATE_g)
145 #define H5E_CANTOPENFILE (H5OPEN H5E_CANTOPENFILE_g)
146 #define H5E_CANTCLOSEFILE (H5OPEN H5E_CANTCLOSEFILE_g)
147 #define H5E_NOTHDF5 (H5OPEN H5E_NOTHDF5_g)
148 #define H5E_BADFILE (H5OPEN H5E_BADFILE_g)
149 #define H5E_TRUNCATED (H5OPEN H5E_TRUNCATED_g)
150 #define H5E_MOUNT (H5OPEN H5E_MOUNT_g)
151 H5_DLLVAR hid_t H5E_FILEEXISTS_g; /* File already exists */
152 H5_DLLVAR hid_t H5E_FILEOPEN_g; /* File already open */
153 H5_DLLVAR hid_t H5E_CANTCREATE_g; /* Unable to create file */
154 H5_DLLVAR hid_t H5E_CANTOPENFILE_g; /* Unable to open file */
155 H5_DLLVAR hid_t H5E_CANTCLOSEFILE_g; /* Unable to close file */
156 H5_DLLVAR hid_t H5E_NOTHDF5_g; /* Not an HDF5 file */
157 H5_DLLVAR hid_t H5E_BADFILE_g; /* Bad file ID accessed */
158 H5_DLLVAR hid_t H5E_TRUNCATED_g; /* File has been truncated */
159 H5_DLLVAR hid_t H5E_MOUNT_g; /* File mount error */
160
161 /* Object atom related errors */
162 #define H5E_BADATOM (H5OPEN H5E_BADATOM_g)
163 #define H5E_BADGROUP (H5OPEN H5E_BADGROUP_g)
164 #define H5E_CANTREGISTER (H5OPEN H5E_CANTREGISTER_g)
165 #define H5E_CANTINC (H5OPEN H5E_CANTINC_g)
166 #define H5E_CANTDEC (H5OPEN H5E_CANTDEC_g)
167 #define H5E_NOIDS (H5OPEN H5E_NOIDS_g)
168 H5_DLLVAR hid_t H5E_BADATOM_g; /* Unable to find atom information (already closed?) */
169 H5_DLLVAR hid_t H5E_BADGROUP_g; /* Unable to find ID group information */
170 H5_DLLVAR hid_t H5E_CANTREGISTER_g; /* Unable to register new atom */
171 H5_DLLVAR hid_t H5E_CANTINC_g; /* Unable to increment reference count */
172 H5_DLLVAR hid_t H5E_CANTDEC_g; /* Unable to decrement reference count */
173 H5_DLLVAR hid_t H5E_NOIDS_g; /* Out of IDs for group */
174
175 /* Property list errors */
176 #define H5E_CANTGET (H5OPEN H5E_CANTGET_g)
177 #define H5E_CANTSET (H5OPEN H5E_CANTSET_g)
178 #define H5E_DUPCLASS (H5OPEN H5E_DUPCLASS_g)
179 #define H5E_SETDISALLOWED (H5OPEN H5E_SETDISALLOWED_g)
180 H5_DLLVAR hid_t H5E_CANTGET_g; /* Can't get value */
181 H5_DLLVAR hid_t H5E_CANTSET_g; /* Can't set value */
182 H5_DLLVAR hid_t H5E_DUPCLASS_g; /* Duplicate class name in parent class */
183 H5_DLLVAR hid_t H5E_SETDISALLOWED_g; /* Disallowed operation */
184100
185101 /* Generic low-level file I/O errors */
186102 #define H5E_SEEKERROR (H5OPEN H5E_SEEKERROR_g)
195111 H5_DLLVAR hid_t H5E_CLOSEERROR_g; /* Close failed */
196112 H5_DLLVAR hid_t H5E_OVERFLOW_g; /* Address overflowed */
197113 H5_DLLVAR hid_t H5E_FCNTL_g; /* File control (fcntl) failed */
198
199 /* Dataspace errors */
200 #define H5E_CANTCLIP (H5OPEN H5E_CANTCLIP_g)
201 #define H5E_CANTCOUNT (H5OPEN H5E_CANTCOUNT_g)
202 #define H5E_CANTSELECT (H5OPEN H5E_CANTSELECT_g)
203 #define H5E_CANTNEXT (H5OPEN H5E_CANTNEXT_g)
204 #define H5E_BADSELECT (H5OPEN H5E_BADSELECT_g)
205 #define H5E_CANTCOMPARE (H5OPEN H5E_CANTCOMPARE_g)
206 #define H5E_CANTAPPEND (H5OPEN H5E_CANTAPPEND_g)
207 H5_DLLVAR hid_t H5E_CANTCLIP_g; /* Can't clip hyperslab region */
208 H5_DLLVAR hid_t H5E_CANTCOUNT_g; /* Can't count elements */
209 H5_DLLVAR hid_t H5E_CANTSELECT_g; /* Can't select hyperslab */
210 H5_DLLVAR hid_t H5E_CANTNEXT_g; /* Can't move to next iterator location */
211 H5_DLLVAR hid_t H5E_BADSELECT_g; /* Invalid selection */
212 H5_DLLVAR hid_t H5E_CANTCOMPARE_g; /* Can't compare objects */
213 H5_DLLVAR hid_t H5E_CANTAPPEND_g; /* Can't append object */
214
215 /* Link related errors */
216 #define H5E_TRAVERSE (H5OPEN H5E_TRAVERSE_g)
217 #define H5E_NLINKS (H5OPEN H5E_NLINKS_g)
218 #define H5E_NOTREGISTERED (H5OPEN H5E_NOTREGISTERED_g)
219 #define H5E_CANTMOVE (H5OPEN H5E_CANTMOVE_g)
220 #define H5E_CANTSORT (H5OPEN H5E_CANTSORT_g)
221 H5_DLLVAR hid_t H5E_TRAVERSE_g; /* Link traversal failure */
222 H5_DLLVAR hid_t H5E_NLINKS_g; /* Too many soft links in path */
223 H5_DLLVAR hid_t H5E_NOTREGISTERED_g; /* Link class not registered */
224 H5_DLLVAR hid_t H5E_CANTMOVE_g; /* Can't move object */
225 H5_DLLVAR hid_t H5E_CANTSORT_g; /* Can't sort objects */
226114
227115 /* Resource errors */
228116 #define H5E_NOSPACE (H5OPEN H5E_NOSPACE_g)
246134 H5_DLLVAR hid_t H5E_CANTGETSIZE_g; /* Unable to compute size */
247135 H5_DLLVAR hid_t H5E_OBJOPEN_g; /* Object is already open */
248136
249 /* Parallel MPI errors */
250 #define H5E_MPI (H5OPEN H5E_MPI_g)
251 #define H5E_MPIERRSTR (H5OPEN H5E_MPIERRSTR_g)
252 #define H5E_CANTRECV (H5OPEN H5E_CANTRECV_g)
253 H5_DLLVAR hid_t H5E_MPI_g; /* Some MPI function failed */
254 H5_DLLVAR hid_t H5E_MPIERRSTR_g; /* MPI Error String */
255 H5_DLLVAR hid_t H5E_CANTRECV_g; /* Can't receive data */
137 /* Heap errors */
138 #define H5E_CANTRESTORE (H5OPEN H5E_CANTRESTORE_g)
139 #define H5E_CANTCOMPUTE (H5OPEN H5E_CANTCOMPUTE_g)
140 #define H5E_CANTEXTEND (H5OPEN H5E_CANTEXTEND_g)
141 #define H5E_CANTATTACH (H5OPEN H5E_CANTATTACH_g)
142 #define H5E_CANTUPDATE (H5OPEN H5E_CANTUPDATE_g)
143 #define H5E_CANTOPERATE (H5OPEN H5E_CANTOPERATE_g)
144 H5_DLLVAR hid_t H5E_CANTRESTORE_g; /* Can't restore condition */
145 H5_DLLVAR hid_t H5E_CANTCOMPUTE_g; /* Can't compute value */
146 H5_DLLVAR hid_t H5E_CANTEXTEND_g; /* Can't extend heap's space */
147 H5_DLLVAR hid_t H5E_CANTATTACH_g; /* Can't attach object */
148 H5_DLLVAR hid_t H5E_CANTUPDATE_g; /* Can't update object */
149 H5_DLLVAR hid_t H5E_CANTOPERATE_g; /* Can't operate on object */
150
151 /* Function entry/exit interface errors */
152 #define H5E_CANTINIT (H5OPEN H5E_CANTINIT_g)
153 #define H5E_ALREADYINIT (H5OPEN H5E_ALREADYINIT_g)
154 #define H5E_CANTRELEASE (H5OPEN H5E_CANTRELEASE_g)
155 H5_DLLVAR hid_t H5E_CANTINIT_g; /* Unable to initialize object */
156 H5_DLLVAR hid_t H5E_ALREADYINIT_g; /* Object already initialized */
157 H5_DLLVAR hid_t H5E_CANTRELEASE_g; /* Unable to release object */
158
159 /* Property list errors */
160 #define H5E_CANTGET (H5OPEN H5E_CANTGET_g)
161 #define H5E_CANTSET (H5OPEN H5E_CANTSET_g)
162 #define H5E_DUPCLASS (H5OPEN H5E_DUPCLASS_g)
163 #define H5E_SETDISALLOWED (H5OPEN H5E_SETDISALLOWED_g)
164 H5_DLLVAR hid_t H5E_CANTGET_g; /* Can't get value */
165 H5_DLLVAR hid_t H5E_CANTSET_g; /* Can't set value */
166 H5_DLLVAR hid_t H5E_DUPCLASS_g; /* Duplicate class name in parent class */
167 H5_DLLVAR hid_t H5E_SETDISALLOWED_g; /* Disallowed operation */
168
169 /* Free space errors */
170 #define H5E_CANTMERGE (H5OPEN H5E_CANTMERGE_g)
171 #define H5E_CANTREVIVE (H5OPEN H5E_CANTREVIVE_g)
172 #define H5E_CANTSHRINK (H5OPEN H5E_CANTSHRINK_g)
173 H5_DLLVAR hid_t H5E_CANTMERGE_g; /* Can't merge objects */
174 H5_DLLVAR hid_t H5E_CANTREVIVE_g; /* Can't revive object */
175 H5_DLLVAR hid_t H5E_CANTSHRINK_g; /* Can't shrink container */
256176
257177 /* Object header related errors */
258178 #define H5E_LINKCOUNT (H5OPEN H5E_LINKCOUNT_g)
274194 H5_DLLVAR hid_t H5E_CANTRESET_g; /* Can't reset object */
275195 H5_DLLVAR hid_t H5E_CANTRENAME_g; /* Unable to rename object */
276196
277 /* Group related errors */
278 #define H5E_CANTOPENOBJ (H5OPEN H5E_CANTOPENOBJ_g)
279 #define H5E_CANTCLOSEOBJ (H5OPEN H5E_CANTCLOSEOBJ_g)
280 #define H5E_COMPLEN (H5OPEN H5E_COMPLEN_g)
281 #define H5E_PATH (H5OPEN H5E_PATH_g)
282 H5_DLLVAR hid_t H5E_CANTOPENOBJ_g; /* Can't open object */
283 H5_DLLVAR hid_t H5E_CANTCLOSEOBJ_g; /* Can't close object */
284 H5_DLLVAR hid_t H5E_COMPLEN_g; /* Name component is too long */
285 H5_DLLVAR hid_t H5E_PATH_g; /* Problem with path to object */
197 /* System level errors */
198 #define H5E_SYSERRSTR (H5OPEN H5E_SYSERRSTR_g)
199 H5_DLLVAR hid_t H5E_SYSERRSTR_g; /* System error message */
286200
287201 /* I/O pipeline errors */
288202 #define H5E_NOFILTER (H5OPEN H5E_NOFILTER_g)
297211 H5_DLLVAR hid_t H5E_SETLOCAL_g; /* Error from filter 'set local' callback */
298212 H5_DLLVAR hid_t H5E_NOENCODER_g; /* Filter present but encoding disabled */
299213 H5_DLLVAR hid_t H5E_CANTFILTER_g; /* Filter operation failed */
214
215 /* Group related errors */
216 #define H5E_CANTOPENOBJ (H5OPEN H5E_CANTOPENOBJ_g)
217 #define H5E_CANTCLOSEOBJ (H5OPEN H5E_CANTCLOSEOBJ_g)
218 #define H5E_COMPLEN (H5OPEN H5E_COMPLEN_g)
219 #define H5E_PATH (H5OPEN H5E_PATH_g)
220 H5_DLLVAR hid_t H5E_CANTOPENOBJ_g; /* Can't open object */
221 H5_DLLVAR hid_t H5E_CANTCLOSEOBJ_g; /* Can't close object */
222 H5_DLLVAR hid_t H5E_COMPLEN_g; /* Name component is too long */
223 H5_DLLVAR hid_t H5E_PATH_g; /* Problem with path to object */
224
225 /* No error */
226 #define H5E_NONE_MINOR (H5OPEN H5E_NONE_MINOR_g)
227 H5_DLLVAR hid_t H5E_NONE_MINOR_g; /* No error */
228
229 /* Plugin errors */
230 #define H5E_OPENERROR (H5OPEN H5E_OPENERROR_g)
231 H5_DLLVAR hid_t H5E_OPENERROR_g; /* Can't open directory or file */
232
233 /* File accessibilty errors */
234 #define H5E_FILEEXISTS (H5OPEN H5E_FILEEXISTS_g)
235 #define H5E_FILEOPEN (H5OPEN H5E_FILEOPEN_g)
236 #define H5E_CANTCREATE (H5OPEN H5E_CANTCREATE_g)
237 #define H5E_CANTOPENFILE (H5OPEN H5E_CANTOPENFILE_g)
238 #define H5E_CANTCLOSEFILE (H5OPEN H5E_CANTCLOSEFILE_g)
239 #define H5E_NOTHDF5 (H5OPEN H5E_NOTHDF5_g)
240 #define H5E_BADFILE (H5OPEN H5E_BADFILE_g)
241 #define H5E_TRUNCATED (H5OPEN H5E_TRUNCATED_g)
242 #define H5E_MOUNT (H5OPEN H5E_MOUNT_g)
243 H5_DLLVAR hid_t H5E_FILEEXISTS_g; /* File already exists */
244 H5_DLLVAR hid_t H5E_FILEOPEN_g; /* File already open */
245 H5_DLLVAR hid_t H5E_CANTCREATE_g; /* Unable to create file */
246 H5_DLLVAR hid_t H5E_CANTOPENFILE_g; /* Unable to open file */
247 H5_DLLVAR hid_t H5E_CANTCLOSEFILE_g; /* Unable to close file */
248 H5_DLLVAR hid_t H5E_NOTHDF5_g; /* Not an HDF5 file */
249 H5_DLLVAR hid_t H5E_BADFILE_g; /* Bad file ID accessed */
250 H5_DLLVAR hid_t H5E_TRUNCATED_g; /* File has been truncated */
251 H5_DLLVAR hid_t H5E_MOUNT_g; /* File mount error */
252
253 /* Object atom related errors */
254 #define H5E_BADATOM (H5OPEN H5E_BADATOM_g)
255 #define H5E_BADGROUP (H5OPEN H5E_BADGROUP_g)
256 #define H5E_CANTREGISTER (H5OPEN H5E_CANTREGISTER_g)
257 #define H5E_CANTINC (H5OPEN H5E_CANTINC_g)
258 #define H5E_CANTDEC (H5OPEN H5E_CANTDEC_g)
259 #define H5E_NOIDS (H5OPEN H5E_NOIDS_g)
260 H5_DLLVAR hid_t H5E_BADATOM_g; /* Unable to find atom information (already closed?) */
261 H5_DLLVAR hid_t H5E_BADGROUP_g; /* Unable to find ID group information */
262 H5_DLLVAR hid_t H5E_CANTREGISTER_g; /* Unable to register new atom */
263 H5_DLLVAR hid_t H5E_CANTINC_g; /* Unable to increment reference count */
264 H5_DLLVAR hid_t H5E_CANTDEC_g; /* Unable to decrement reference count */
265 H5_DLLVAR hid_t H5E_NOIDS_g; /* Out of IDs for group */
300266
301267 /* Cache related errors */
302268 #define H5E_CANTFLUSH (H5OPEN H5E_CANTFLUSH_g)
344310 H5_DLLVAR hid_t H5E_CANTCORK_g; /* Unable to cork an object */
345311 H5_DLLVAR hid_t H5E_CANTUNCORK_g; /* Unable to uncork an object */
346312
313 /* Link related errors */
314 #define H5E_TRAVERSE (H5OPEN H5E_TRAVERSE_g)
315 #define H5E_NLINKS (H5OPEN H5E_NLINKS_g)
316 #define H5E_NOTREGISTERED (H5OPEN H5E_NOTREGISTERED_g)
317 #define H5E_CANTMOVE (H5OPEN H5E_CANTMOVE_g)
318 #define H5E_CANTSORT (H5OPEN H5E_CANTSORT_g)
319 H5_DLLVAR hid_t H5E_TRAVERSE_g; /* Link traversal failure */
320 H5_DLLVAR hid_t H5E_NLINKS_g; /* Too many soft links in path */
321 H5_DLLVAR hid_t H5E_NOTREGISTERED_g; /* Link class not registered */
322 H5_DLLVAR hid_t H5E_CANTMOVE_g; /* Can't move object */
323 H5_DLLVAR hid_t H5E_CANTSORT_g; /* Can't sort objects */
324
325 /* Parallel MPI errors */
326 #define H5E_MPI (H5OPEN H5E_MPI_g)
327 #define H5E_MPIERRSTR (H5OPEN H5E_MPIERRSTR_g)
328 #define H5E_CANTRECV (H5OPEN H5E_CANTRECV_g)
329 H5_DLLVAR hid_t H5E_MPI_g; /* Some MPI function failed */
330 H5_DLLVAR hid_t H5E_MPIERRSTR_g; /* MPI Error String */
331 H5_DLLVAR hid_t H5E_CANTRECV_g; /* Can't receive data */
332
333 /* Dataspace errors */
334 #define H5E_CANTCLIP (H5OPEN H5E_CANTCLIP_g)
335 #define H5E_CANTCOUNT (H5OPEN H5E_CANTCOUNT_g)
336 #define H5E_CANTSELECT (H5OPEN H5E_CANTSELECT_g)
337 #define H5E_CANTNEXT (H5OPEN H5E_CANTNEXT_g)
338 #define H5E_BADSELECT (H5OPEN H5E_BADSELECT_g)
339 #define H5E_CANTCOMPARE (H5OPEN H5E_CANTCOMPARE_g)
340 #define H5E_CANTAPPEND (H5OPEN H5E_CANTAPPEND_g)
341 H5_DLLVAR hid_t H5E_CANTCLIP_g; /* Can't clip hyperslab region */
342 H5_DLLVAR hid_t H5E_CANTCOUNT_g; /* Can't count elements */
343 H5_DLLVAR hid_t H5E_CANTSELECT_g; /* Can't select hyperslab */
344 H5_DLLVAR hid_t H5E_CANTNEXT_g; /* Can't move to next iterator location */
345 H5_DLLVAR hid_t H5E_BADSELECT_g; /* Invalid selection */
346 H5_DLLVAR hid_t H5E_CANTCOMPARE_g; /* Can't compare objects */
347 H5_DLLVAR hid_t H5E_CANTAPPEND_g; /* Can't append object */
348
349 /* Argument errors */
350 #define H5E_UNINITIALIZED (H5OPEN H5E_UNINITIALIZED_g)
351 #define H5E_UNSUPPORTED (H5OPEN H5E_UNSUPPORTED_g)
352 #define H5E_BADTYPE (H5OPEN H5E_BADTYPE_g)
353 #define H5E_BADRANGE (H5OPEN H5E_BADRANGE_g)
354 #define H5E_BADVALUE (H5OPEN H5E_BADVALUE_g)
355 H5_DLLVAR hid_t H5E_UNINITIALIZED_g; /* Information is uinitialized */
356 H5_DLLVAR hid_t H5E_UNSUPPORTED_g; /* Feature is unsupported */
357 H5_DLLVAR hid_t H5E_BADTYPE_g; /* Inappropriate type */
358 H5_DLLVAR hid_t H5E_BADRANGE_g; /* Out of range */
359 H5_DLLVAR hid_t H5E_BADVALUE_g; /* Bad value */
360
347361 /* B-tree related errors */
348362 #define H5E_NOTFOUND (H5OPEN H5E_NOTFOUND_g)
349363 #define H5E_EXISTS (H5OPEN H5E_EXISTS_g)
368382 H5_DLLVAR hid_t H5E_CANTMODIFY_g; /* Unable to modify record */
369383 H5_DLLVAR hid_t H5E_CANTREMOVE_g; /* Unable to remove object */
370384
371 /* Function entry/exit interface errors */
372 #define H5E_CANTINIT (H5OPEN H5E_CANTINIT_g)
373 #define H5E_ALREADYINIT (H5OPEN H5E_ALREADYINIT_g)
374 #define H5E_CANTRELEASE (H5OPEN H5E_CANTRELEASE_g)
375 H5_DLLVAR hid_t H5E_CANTINIT_g; /* Unable to initialize object */
376 H5_DLLVAR hid_t H5E_ALREADYINIT_g; /* Object already initialized */
377 H5_DLLVAR hid_t H5E_CANTRELEASE_g; /* Unable to release object */
378
379 /* Plugin errors */
380 #define H5E_OPENERROR (H5OPEN H5E_OPENERROR_g)
381 H5_DLLVAR hid_t H5E_OPENERROR_g; /* Can't open directory or file */
382
383 /* No error */
384 #define H5E_NONE_MINOR (H5OPEN H5E_NONE_MINOR_g)
385 H5_DLLVAR hid_t H5E_NONE_MINOR_g; /* No error */
385 /* Datatype conversion errors */
386 #define H5E_CANTCONVERT (H5OPEN H5E_CANTCONVERT_g)
387 #define H5E_BADSIZE (H5OPEN H5E_BADSIZE_g)
388 H5_DLLVAR hid_t H5E_CANTCONVERT_g; /* Can't convert datatypes */
389 H5_DLLVAR hid_t H5E_BADSIZE_g; /* Bad size for object */
390
391 #ifdef __cplusplus
392 }
393 #endif
386394
387395 #endif /* H5Epubgen_H */
2121
2222 /* Reset major error IDs */
2323
24 H5E_FUNC_g=
25 H5E_FILE_g=
26 H5E_SOHM_g=
27 H5E_SYM_g=
28 H5E_PLUGIN_g=
29 H5E_VFL_g=
30 H5E_INTERNAL_g=
31 H5E_BTREE_g=
32 H5E_REFERENCE_g=
33 H5E_DATASPACE_g=
34 H5E_RESOURCE_g=
35 H5E_RS_g=
36 H5E_FARRAY_g=
37 H5E_HEAP_g=
38 H5E_ATTR_g=
39 H5E_IO_g=
40 H5E_EFL_g=
41 H5E_TST_g=
2442 H5E_FSPACE_g=
43 H5E_DATASET_g=
44 H5E_STORAGE_g=
45 H5E_LINK_g=
2546 H5E_PLIST_g=
26 H5E_RS_g=
2747 H5E_DATATYPE_g=
28 H5E_ERROR_g=
29 H5E_DATASPACE_g=
30 H5E_FARRAY_g=
31 H5E_INTERNAL_g=
32 H5E_PLUGIN_g=
33 H5E_CACHE_g=
34 H5E_FUNC_g=
35 H5E_EARRAY_g=
36 H5E_IO_g=
48 H5E_OHDR_g=
49 H5E_ATOM_g=
3750 H5E_NONE_MAJOR_g=
3851 H5E_SLIST_g=
39 H5E_RESOURCE_g=
40 H5E_SYM_g=
41 H5E_ATOM_g=
42 H5E_REFERENCE_g=
52 H5E_ARGS_g=
53 H5E_EARRAY_g=
4354 H5E_PLINE_g=
44 H5E_ARGS_g=
45 H5E_SOHM_g=
46 H5E_DATASET_g=
47 H5E_STORAGE_g=
48 H5E_EFL_g=
49 H5E_FILE_g=
50 H5E_TST_g=
51 H5E_ATTR_g=
52 H5E_HEAP_g=
53 H5E_LINK_g=
54 H5E_BTREE_g=
55 H5E_OHDR_g=
56 H5E_VFL_g= (-1);
55 H5E_ERROR_g=
56 H5E_CACHE_g= (-1);
5757
5858 /* Reset minor error IDs */
5959
60
61 /* Free space errors */
62 H5E_CANTMERGE_g=
63 H5E_CANTREVIVE_g=
64 H5E_CANTSHRINK_g=
65
66 /* Heap errors */
67 H5E_CANTRESTORE_g=
68 H5E_CANTCOMPUTE_g=
69 H5E_CANTEXTEND_g=
70 H5E_CANTATTACH_g=
71 H5E_CANTUPDATE_g=
72 H5E_CANTOPERATE_g=
73
74 /* System level errors */
75 H5E_SYSERRSTR_g=
76
77 /* Argument errors */
78 H5E_UNINITIALIZED_g=
79 H5E_UNSUPPORTED_g=
80 H5E_BADTYPE_g=
81 H5E_BADRANGE_g=
82 H5E_BADVALUE_g=
83
84 /* Datatype conversion errors */
85 H5E_CANTCONVERT_g=
86 H5E_BADSIZE_g=
87
88 /* File accessibilty errors */
89 H5E_FILEEXISTS_g=
90 H5E_FILEOPEN_g=
91 H5E_CANTCREATE_g=
92 H5E_CANTOPENFILE_g=
93 H5E_CANTCLOSEFILE_g=
94 H5E_NOTHDF5_g=
95 H5E_BADFILE_g=
96 H5E_TRUNCATED_g=
97 H5E_MOUNT_g=
98
99 /* Object atom related errors */
100 H5E_BADATOM_g=
101 H5E_BADGROUP_g=
102 H5E_CANTREGISTER_g=
103 H5E_CANTINC_g=
104 H5E_CANTDEC_g=
105 H5E_NOIDS_g=
106
107 /* Property list errors */
108 H5E_CANTGET_g=
109 H5E_CANTSET_g=
110 H5E_DUPCLASS_g=
111 H5E_SETDISALLOWED_g=
11260
11361 /* Generic low-level file I/O errors */
11462 H5E_SEEKERROR_g=
11765 H5E_CLOSEERROR_g=
11866 H5E_OVERFLOW_g=
11967 H5E_FCNTL_g=
120
121 /* Dataspace errors */
122 H5E_CANTCLIP_g=
123 H5E_CANTCOUNT_g=
124 H5E_CANTSELECT_g=
125 H5E_CANTNEXT_g=
126 H5E_BADSELECT_g=
127 H5E_CANTCOMPARE_g=
128 H5E_CANTAPPEND_g=
129
130 /* Link related errors */
131 H5E_TRAVERSE_g=
132 H5E_NLINKS_g=
133 H5E_NOTREGISTERED_g=
134 H5E_CANTMOVE_g=
135 H5E_CANTSORT_g=
13668
13769 /* Resource errors */
13870 H5E_NOSPACE_g=
14678 H5E_CANTGETSIZE_g=
14779 H5E_OBJOPEN_g=
14880
149 /* Parallel MPI errors */
150 H5E_MPI_g=
151 H5E_MPIERRSTR_g=
152 H5E_CANTRECV_g=
81 /* Heap errors */
82 H5E_CANTRESTORE_g=
83 H5E_CANTCOMPUTE_g=
84 H5E_CANTEXTEND_g=
85 H5E_CANTATTACH_g=
86 H5E_CANTUPDATE_g=
87 H5E_CANTOPERATE_g=
88
89 /* Function entry/exit interface errors */
90 H5E_CANTINIT_g=
91 H5E_ALREADYINIT_g=
92 H5E_CANTRELEASE_g=
93
94 /* Property list errors */
95 H5E_CANTGET_g=
96 H5E_CANTSET_g=
97 H5E_DUPCLASS_g=
98 H5E_SETDISALLOWED_g=
99
100 /* Free space errors */
101 H5E_CANTMERGE_g=
102 H5E_CANTREVIVE_g=
103 H5E_CANTSHRINK_g=
153104
154105 /* Object header related errors */
155106 H5E_LINKCOUNT_g=
162113 H5E_CANTRESET_g=
163114 H5E_CANTRENAME_g=
164115
165 /* Group related errors */
166 H5E_CANTOPENOBJ_g=
167 H5E_CANTCLOSEOBJ_g=
168 H5E_COMPLEN_g=
169 H5E_PATH_g=
116 /* System level errors */
117 H5E_SYSERRSTR_g=
170118
171119 /* I/O pipeline errors */
172120 H5E_NOFILTER_g=
175123 H5E_SETLOCAL_g=
176124 H5E_NOENCODER_g=
177125 H5E_CANTFILTER_g=
126
127 /* Group related errors */
128 H5E_CANTOPENOBJ_g=
129 H5E_CANTCLOSEOBJ_g=
130 H5E_COMPLEN_g=
131 H5E_PATH_g=
132
133 /* No error */
134 H5E_NONE_MINOR_g=
135
136 /* Plugin errors */
137 H5E_OPENERROR_g=
138
139 /* File accessibilty errors */
140 H5E_FILEEXISTS_g=
141 H5E_FILEOPEN_g=
142 H5E_CANTCREATE_g=
143 H5E_CANTOPENFILE_g=
144 H5E_CANTCLOSEFILE_g=
145 H5E_NOTHDF5_g=
146 H5E_BADFILE_g=
147 H5E_TRUNCATED_g=
148 H5E_MOUNT_g=
149
150 /* Object atom related errors */
151 H5E_BADATOM_g=
152 H5E_BADGROUP_g=
153 H5E_CANTREGISTER_g=
154 H5E_CANTINC_g=
155 H5E_CANTDEC_g=
156 H5E_NOIDS_g=
178157
179158 /* Cache related errors */
180159 H5E_CANTFLUSH_g=
200179 H5E_CANTCORK_g=
201180 H5E_CANTUNCORK_g=
202181
182 /* Link related errors */
183 H5E_TRAVERSE_g=
184 H5E_NLINKS_g=
185 H5E_NOTREGISTERED_g=
186 H5E_CANTMOVE_g=
187 H5E_CANTSORT_g=
188
189 /* Parallel MPI errors */
190 H5E_MPI_g=
191 H5E_MPIERRSTR_g=
192 H5E_CANTRECV_g=
193
194 /* Dataspace errors */
195 H5E_CANTCLIP_g=
196 H5E_CANTCOUNT_g=
197 H5E_CANTSELECT_g=
198 H5E_CANTNEXT_g=
199 H5E_BADSELECT_g=
200 H5E_CANTCOMPARE_g=
201 H5E_CANTAPPEND_g=
202
203 /* Argument errors */
204 H5E_UNINITIALIZED_g=
205 H5E_UNSUPPORTED_g=
206 H5E_BADTYPE_g=
207 H5E_BADRANGE_g=
208 H5E_BADVALUE_g=
209
203210 /* B-tree related errors */
204211 H5E_NOTFOUND_g=
205212 H5E_EXISTS_g=
213220 H5E_CANTMODIFY_g=
214221 H5E_CANTREMOVE_g=
215222
216 /* Function entry/exit interface errors */
217 H5E_CANTINIT_g=
218 H5E_ALREADYINIT_g=
219 H5E_CANTRELEASE_g=
220
221 /* Plugin errors */
222 H5E_OPENERROR_g=
223
224 /* No error */
225 H5E_NONE_MINOR_g= (-1);
223 /* Datatype conversion errors */
224 H5E_CANTCONVERT_g=
225 H5E_BADSIZE_g= (-1);
226226
227227 #endif /* H5Eterm_H */
445445 H5Fcreate(const char *filename, unsigned flags, hid_t fcpl_id, hid_t fapl_id)
446446 {
447447 H5F_t *new_file = NULL; /*file struct for new file */
448 hid_t ret_value; /*return value */
448 hid_t dxpl_id = H5AC_dxpl_id; /*dxpl used by library */
449 hid_t ret_value; /*return value */
449450
450451 FUNC_ENTER_API(FAIL)
451452 H5TRACE4("i", "*sIuii", filename, flags, fcpl_id, fapl_id);
469470 if(TRUE != H5P_isa_class(fcpl_id, H5P_FILE_CREATE))
470471 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not file create property list")
471472
472 /* Check the file access property list */
473 if(H5P_DEFAULT == fapl_id)
474 fapl_id = H5P_FILE_ACCESS_DEFAULT;
475 else
476 if(TRUE != H5P_isa_class(fapl_id, H5P_FILE_ACCESS))
477 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not file access property list")
473 /* Verify access property list and get correct dxpl */
474 if(H5P_verify_and_set_dxpl(&fapl_id, H5P_FILE_ACCESS, H5P_FILE_ACCESS_DEFAULT, &dxpl_id) < 0)
475 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
478476
479477 /*
480478 * Adjust bit flags by turning on the creation bit and making sure that
488486 /*
489487 * Create a new file or truncate an existing file.
490488 */
491 if(NULL == (new_file = H5F_open(filename, flags, fcpl_id, fapl_id, H5AC_dxpl_id)))
489 if(NULL == (new_file = H5F_open(filename, flags, fcpl_id, fapl_id, dxpl_id)))
492490 HGOTO_ERROR(H5E_FILE, H5E_CANTOPENFILE, FAIL, "unable to create file")
493491
494492 /* Get an atom for the file */
551549 H5Fopen(const char *filename, unsigned flags, hid_t fapl_id)
552550 {
553551 H5F_t *new_file = NULL; /*file struct for new file */
554 hid_t ret_value; /*return value */
552 hid_t dxpl_id = H5AC_dxpl_id; /*dxpl used by library */
553 hid_t ret_value; /*return value */
555554
556555 FUNC_ENTER_API(FAIL)
557556 H5TRACE3("i", "*sIui", filename, flags, fapl_id);
569568 /* Asking for SWMR read access on a non-read-only file is invalid */
570569 if((flags & H5F_ACC_SWMR_READ) && (flags & H5F_ACC_RDWR))
571570 HGOTO_ERROR(H5E_FILE, H5E_CANTOPENFILE, FAIL, "SWMR read access on a file open for read-write access is not allowed")
572 if(H5P_DEFAULT == fapl_id)
573 fapl_id = H5P_FILE_ACCESS_DEFAULT;
574 else
575 if(TRUE != H5P_isa_class(fapl_id, H5P_FILE_ACCESS))
576 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not file access property list")
571
572 /* Verify access property list and get correct dxpl */
573 if(H5P_verify_and_set_dxpl(&fapl_id, H5P_FILE_ACCESS, H5P_FILE_ACCESS_DEFAULT, &dxpl_id) < 0)
574 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
577575
578576 /* Open the file */
579 if(NULL == (new_file = H5F_open(filename, flags, H5P_FILE_CREATE_DEFAULT, fapl_id, H5AC_dxpl_id)))
577 if(NULL == (new_file = H5F_open(filename, flags, H5P_FILE_CREATE_DEFAULT, fapl_id, dxpl_id)))
580578 HGOTO_ERROR(H5E_FILE, H5E_CANTOPENFILE, FAIL, "unable to open file")
581579
582580 /* Get an atom for the file */
18711869 FUNC_LEAVE_API(ret_value)
18721870
18731871 } /* H5Fstop_mdc_logging() */
1872
1873
1874 /*-------------------------------------------------------------------------
1875 * Function: H5Fformat_convert_super (Internal)
1876 *
1877 * Purpose: Downgrade the superblock version for the tool h5format_convert.
1878 * (NOTE: more needs to be done to this routine)
1879 *
1880 * Return: Non-negative on success/Negative on failure
1881 *
1882 * Programmer: Vailin Choi; Jan 2016
1883 *
1884 *-------------------------------------------------------------------------
1885 */
1886 herr_t
1887 H5Fformat_convert_super(hid_t fid)
1888 {
1889 H5F_t *f = NULL; /* File to flush */
1890 herr_t ret_value = SUCCEED; /* Return value */
1891
1892 FUNC_ENTER_API(FAIL)
1893 H5TRACE1("e", "i", fid);
1894
1895 switch(H5I_get_type(fid)) {
1896 case H5I_FILE:
1897 if(NULL == (f = (H5F_t *)H5I_object(fid)))
1898 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "invalid file identifier")
1899 if(f->shared->sblock->super_vers < HDF5_SUPERBLOCK_VERSION_LATEST)
1900 HGOTO_DONE(SUCCEED)
1901 f->shared->sblock->super_vers = HDF5_SUPERBLOCK_VERSION_LATEST - 1;
1902
1903 /* Mark superblock as dirty */
1904 if(H5F_super_dirty(f) < 0)
1905 HDONE_ERROR(H5E_FILE, H5E_CANTMARKDIRTY, FAIL, "unable to mark superblock as dirty")
1906
1907 break;
1908
1909 case H5I_GROUP:
1910 case H5I_DATATYPE:
1911 case H5I_DATASET:
1912 case H5I_ATTR:
1913 case H5I_UNINIT:
1914 case H5I_BADID:
1915 case H5I_DATASPACE:
1916 case H5I_REFERENCE:
1917 case H5I_VFL:
1918 case H5I_GENPROP_CLS:
1919 case H5I_GENPROP_LST:
1920 case H5I_ERROR_CLASS:
1921 case H5I_ERROR_MSG:
1922 case H5I_ERROR_STACK:
1923 case H5I_NTYPES:
1924 default:
1925 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a file or file object")
1926 } /* end switch */
1927
1928 done:
1929 FUNC_LEAVE_API(ret_value)
1930 } /* end H5Fformat_convert_super() */
849849 CATCH
850850
851851 END_FUNC(PRIV) /* end H5FA_undepend() */
852
853 /*-------------------------------------------------------------------------
854 * Function: H5FA_patch_file
855 *
856 * Purpose: Patch the top-level file pointer contained in fa
857 * to point to idx_info->f if they are different.
858 * This is possible because the file pointer in fa can be
859 * closed out if fa remains open.
860 *
861 * Return: SUCCEED
862 *
863 *-------------------------------------------------------------------------
864 */
865 BEGIN_FUNC(PRIV, NOERR,
866 herr_t, SUCCEED, -,
867 H5FA_patch_file(H5FA_t *fa, H5F_t *f))
868
869 /* Local variables */
870
871 #ifdef H5FA_DEBUG
872 HDfprintf(stderr, "%s: Called\n", FUNC);
873 #endif /* H5FA_DEBUG */
874
875 /*
876 * Check arguments.
877 */
878 HDassert(fa);
879 HDassert(f);
880
881 if(fa->f != f || fa->hdr->f != f)
882 fa->f = fa->hdr->f = f;
883
884 END_FUNC(PRIV) /* end H5FA_patch_file() */
130130 H5_DLL herr_t H5FA_iterate(H5FA_t *fa, hid_t dxpl_id, H5FA_operator_t op, void *udata);
131131 H5_DLL herr_t H5FA_close(H5FA_t *fa, hid_t dxpl_id);
132132 H5_DLL herr_t H5FA_delete(H5F_t *f, hid_t dxpl_id, haddr_t fa_addr, void *ctx_udata);
133 H5_DLL herr_t H5FA_patch_file(H5FA_t *fa, H5F_t *f);
133134
134135 /* Statistics routines */
135136 H5_DLL herr_t H5FA_get_stats(const H5FA_t *ea, H5FA_stat_t *stats);
405405
406406 /* Deep copy the log file name */
407407 if(old_fa->logfile != NULL)
408 if(NULL == (new_fa->logfile = H5MM_xstrdup(old_fa->logfile)))
408 if(NULL == (new_fa->logfile = H5MM_strdup(old_fa->logfile)))
409409 HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, NULL, "unable to allocate log file name")
410410
411411 /* Set return value */
415415 if(NULL == ret_value)
416416 if(new_fa) {
417417 if(new_fa->logfile)
418 H5MM_free(new_fa->logfile);
418 new_fa->logfile = H5MM_xfree(new_fa->logfile);
419419 H5MM_free(new_fa);
420420 } /* end if */
421421
444444
445445 /* Free the fapl information */
446446 if(fa->logfile)
447 H5MM_xfree(fa->logfile);
447 fa->logfile = H5MM_xfree(fa->logfile);
448448 H5MM_xfree(fa);
449449
450450 FUNC_LEAVE_NOAPI(SUCCEED)
593593 /* Get the flags for logging */
594594 file->fa.flags = fa->flags;
595595 if(fa->logfile)
596 file->fa.logfile = HDstrdup(fa->logfile);
596 file->fa.logfile = H5MM_strdup(fa->logfile);
597597 else
598598 file->fa.logfile = NULL;
599599 file->fa.buf_size = fa->buf_size;
797797 HDfclose(file->logfp);
798798 } /* end if */
799799
800 if(file->fa.logfile) {
801 HDfree(file->fa.logfile);
802 file->fa.logfile = NULL;
803 }
800 if(file->fa.logfile)
801 file->fa.logfile = H5MM_xfree(file->fa.logfile);
804802
805803 /* Release the file info */
806804 file = H5FL_FREE(H5FD_log_t, file);
14351435 #endif
14361436
14371437 /* Only look for MPI views for raw data transfers */
1438 if(type==H5FD_MEM_DRAW) {
1438 if(type == H5FD_MEM_DRAW) {
14391439 H5FD_mpio_xfer_t xfer_mode; /* I/O tranfer mode */
14401440
14411441 /* Obtain the data transfer properties */
17011701 int size_i;
17021702 hbool_t use_view_this_time = FALSE;
17031703 H5P_genplist_t *plist = NULL; /* Property list pointer */
1704 H5FD_mpio_xfer_t xfer_mode; /* I/O tranfer mode */
17041705 herr_t ret_value = SUCCEED;
17051706
17061707 FUNC_ENTER_NOAPI_NOINIT
17311732 fprintf(stdout, "in H5FD_mpio_write mpi_off=%ld size_i=%d\n", (long)mpi_off, size_i);
17321733 #endif
17331734
1734 if(type == H5FD_MEM_DRAW) {
1735 H5FD_mpio_xfer_t xfer_mode; /* I/O tranfer mode */
1736
1737 /* Obtain the data transfer properties */
1738 if(NULL == (plist = (H5P_genplist_t *)H5I_object(dxpl_id)))
1739 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a file access property list")
1740
1741 /* get the transfer mode from the dxpl */
1742 if(H5P_get(plist, H5D_XFER_IO_XFER_MODE_NAME, &xfer_mode)<0)
1743 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't get MPI-I/O transfer mode")
1735 /* Obtain the data transfer properties */
1736 if(NULL == (plist = (H5P_genplist_t *)H5I_object(dxpl_id)))
1737 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a file access property list")
1738
1739 /* get the transfer mode from the dxpl */
1740 if(H5P_get(plist, H5D_XFER_IO_XFER_MODE_NAME, &xfer_mode)<0)
1741 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't get MPI-I/O transfer mode")
1742
1743 /*
1744 * Set up for a fancy xfer using complex types, or single byte block. We
1745 * wouldn't need to rely on the use_view field if MPI semantics allowed
1746 * us to test that btype=ftype=MPI_BYTE (or even MPI_TYPE_NULL, which
1747 * could mean "use MPI_BYTE" by convention).
1748 */
1749 if(xfer_mode == H5FD_MPIO_COLLECTIVE) {
1750 MPI_Datatype file_type;
1751
1752 /* Remember that views are used */
1753 use_view_this_time = TRUE;
1754
1755 /* prepare for a full-blown xfer using btype, ftype, and disp */
1756 if(H5P_get(plist, H5FD_MPI_XFER_MEM_MPI_TYPE_NAME, &buf_type) < 0)
1757 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't get MPI-I/O type property")
1758 if(H5P_get(plist, H5FD_MPI_XFER_FILE_MPI_TYPE_NAME, &file_type) < 0)
1759 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't get MPI-I/O type property")
17441760
17451761 /*
1746 * Set up for a fancy xfer using complex types, or single byte block. We
1747 * wouldn't need to rely on the use_view field if MPI semantics allowed
1748 * us to test that btype=ftype=MPI_BYTE (or even MPI_TYPE_NULL, which
1749 * could mean "use MPI_BYTE" by convention).
1762 * Set the file view when we are using MPI derived types
17501763 */
1751 if(xfer_mode == H5FD_MPIO_COLLECTIVE) {
1752 MPI_Datatype file_type;
1753
1754 /* Remember that views are used */
1755 use_view_this_time = TRUE;
1756
1757 /* prepare for a full-blown xfer using btype, ftype, and disp */
1758 if(H5P_get(plist, H5FD_MPI_XFER_MEM_MPI_TYPE_NAME, &buf_type) < 0)
1759 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't get MPI-I/O type property")
1760 if(H5P_get(plist, H5FD_MPI_XFER_FILE_MPI_TYPE_NAME, &file_type) < 0)
1761 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't get MPI-I/O type property")
1762
1763 /*
1764 * Set the file view when we are using MPI derived types
1765 */
1766 if(MPI_SUCCESS != (mpi_code = MPI_File_set_view(file->f, mpi_off, MPI_BYTE, file_type, H5FD_mpi_native_g, file->info)))
1767 HMPI_GOTO_ERROR(FAIL, "MPI_File_set_view failed", mpi_code)
1768
1769 /* When using types, use the address as the displacement for
1770 * MPI_File_set_view and reset the address for the read to zero
1771 */
1772 mpi_off = 0;
1773 } /* end if */
1774 } /* end if */
1775 else {
1776 #if 0 /* JRM -- 3/23/10 */ /* this is no longer always the case */
1777 /* Only one process can do the actual metadata write */
1778 if(file->mpi_rank != H5_PAR_META_WRITE)
1779 #ifdef LATER
1780 HGOTO_ERROR(H5E_IO, H5E_WRITEERROR, FAIL, "can't write metadata from non-zero rank")
1781 #else /* LATER */
1782 HGOTO_DONE(SUCCEED) /* skip the actual write */
1783 #endif /* LATER */
1784 #endif /* JRM */
1764 if(MPI_SUCCESS != (mpi_code = MPI_File_set_view(file->f, mpi_off, MPI_BYTE, file_type, H5FD_mpi_native_g, file->info)))
1765 HMPI_GOTO_ERROR(FAIL, "MPI_File_set_view failed", mpi_code)
1766
1767 /* When using types, use the address as the displacement for
1768 * MPI_File_set_view and reset the address for the read to zero
1769 */
1770 mpi_off = 0;
17851771 } /* end if */
17861772
17871773 /* Write the data. */
17921778 if(H5FD_mpio_Debug[(int)'t'])
17931779 fprintf(stdout, "H5FD_mpio_write: using MPIO collective mode\n");
17941780 #endif
1781
17951782 /* Get the collective_opt property to check whether the application wants to do IO individually. */
17961783 HDassert(plist);
17971784 /* get the transfer mode from the dxpl */
18071794 HMPI_GOTO_ERROR(FAIL, "MPI_File_write_at_all failed", mpi_code)
18081795 } /* end if */
18091796 else {
1797 if(type != H5FD_MEM_DRAW)
1798 HGOTO_ERROR(H5E_PLIST, H5E_BADTYPE, FAIL, "Metadata Coll opt property should be collective at this point")
18101799 #ifdef H5FDmpio_DEBUG
18111800 if(H5FD_mpio_Debug[(int)'t'])
18121801 fprintf(stdout, "H5FD_mpio_write: doing MPI independent IO\n");
183183 efc_size = H5F_efc_max_nfiles(f->shared->efc);
184184 if(H5P_set(new_plist, H5F_ACS_EFC_SIZE_NAME, &efc_size) < 0)
185185 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't set elink file cache size")
186 #ifdef H5_HAVE_PARALLEL
187 if(H5P_set(new_plist, H5_COLL_MD_READ_FLAG_NAME, &(f->coll_md_read)) < 0)
188 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't set collective metadata read flag")
189 #endif /* H5_HAVE_PARALLEL */
186190
187191 /* Prepare the driver property */
188192 driver_prop.driver_id = f->shared->lf->driver_id;
654658 if(efc_size > 0)
655659 if(NULL == (f->shared->efc = H5F_efc_create(efc_size)))
656660 HGOTO_ERROR(H5E_FILE, H5E_CANTINIT, NULL, "can't create external file cache")
661 #ifdef H5_HAVE_PARALLEL
662 if(H5P_get(plist, H5_COLL_MD_READ_FLAG_NAME, &(f->coll_md_read)) < 0)
663 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, NULL, "can't get collective metadata read flag")
664 if(H5P_get(plist, H5F_ACS_COLL_MD_WRITE_FLAG_NAME, &(f->coll_md_write)) < 0)
665 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, NULL, "can't get collective metadata write flag")
666 #endif /* H5_HAVE_PARALLEL */
657667
658668 /* Get the VFD values to cache */
659669 f->shared->maxaddr = H5FD_get_maxaddr(lf);
7676
7777
7878 #ifdef H5_HAVE_PARALLEL
79
80 /*-------------------------------------------------------------------------
81 * Function: H5F_get_mpi_handle
82 *
83 * Purpose: Retrieves MPI File handle.
84 *
85 * Return: Success: The size (positive)
86 * Failure: Negative
87 *
88 *-------------------------------------------------------------------------
89 */
90 herr_t
91 H5F_get_mpi_handle(const H5F_t *f, MPI_File **f_handle)
92 {
93 herr_t ret_value = SUCCEED;
94 hid_t fapl = -1;
95
96 FUNC_ENTER_NOAPI(FAIL)
97
98 assert(f && f->shared);
99
100 /* Dispatch to driver */
101 if ((ret_value = H5FD_get_vfd_handle(f->shared->lf, fapl, (void **)f_handle)) < 0)
102 HGOTO_ERROR(H5E_FILE, H5E_CANTGET, FAIL, "can't get mpi file handle")
103
104 done:
105 FUNC_LEAVE_NOAPI(ret_value)
106 } /* end H5F_get_mpi_handle() */
107
79108
80109 /*-------------------------------------------------------------------------
81110 * Function: H5F_mpi_get_rank
351351 hbool_t closing; /* File is in the process of being closed */
352352 struct H5F_t *parent; /* Parent file that this file is mounted to */
353353 unsigned nmounts; /* Number of children mounted to this file */
354 #ifdef H5_HAVE_PARALLEL
355 H5P_coll_md_read_flag_t coll_md_read; /* Do all metadata reads collectively */
356 hbool_t coll_md_write; /* Do all metadata writes collectively */
357 #endif /* H5_HAVE_PARALLEL */
354358 };
355359
356360
464464
465465 #define H5F_ACS_CORE_WRITE_TRACKING_FLAG_NAME "core_write_tracking_flag" /* Whether or not core VFD backing store write tracking is enabled */
466466 #define H5F_ACS_CORE_WRITE_TRACKING_PAGE_SIZE_NAME "core_write_tracking_page_size" /* The page size in kiB when core VFD write tracking is enabled */
467 #define H5F_ACS_COLL_MD_WRITE_FLAG_NAME "collective_metadata_write" /* property indicating whether metadata writes are done collectively or not */
467468
468469 /* ======================== File Mount properties ====================*/
469470 #define H5F_MNT_SYM_LOCAL_NAME "local" /* Whether absolute symlinks local to file. */
742743
743744 /* Parallel I/O (i.e. MPI) related routines */
744745 #ifdef H5_HAVE_PARALLEL
746 H5_DLL herr_t H5F_get_mpi_handle(const H5F_t *f, MPI_File **f_handle);
745747 H5_DLL int H5F_mpi_get_rank(const H5F_t *f);
746748 H5_DLL MPI_Comm H5F_mpi_get_comm(const H5F_t *f);
747749 H5_DLL int H5F_mpi_get_size(const H5F_t *f);
3131 #define H5CHECK
3232 #endif /* _H5private_H */
3333
34 /* When this header is included from a private HDF5 header, don't make calls to H5open() */
35 #undef H5OPEN
36 #ifndef _H5private_H
37 #define H5OPEN H5open(),
38 #else /* _H5private_H */
39 #define H5OPEN
40 #endif /* _H5private_H */
41
3442 /*
3543 * These are the bits that can be passed to the `flags' argument of
3644 * H5Fcreate() and H5Fopen(). Use the bit-wise OR operator (|) to combine
4351 * Note that H5F_ACC_DEBUG is deprecated (nonfuncational) but retained as a
4452 * symbol for backward compatibility.
4553 */
46 #define H5F_ACC_RDONLY (H5CHECK 0x0000u) /*absence of rdwr => rd-only */
47 #define H5F_ACC_RDWR (H5CHECK 0x0001u) /*open for read and write */
48 #define H5F_ACC_TRUNC (H5CHECK 0x0002u) /*overwrite existing files */
49 #define H5F_ACC_EXCL (H5CHECK 0x0004u) /*fail if file already exists*/
54 #define H5F_ACC_RDONLY (H5CHECK H5OPEN 0x0000u) /*absence of rdwr => rd-only */
55 #define H5F_ACC_RDWR (H5CHECK H5OPEN 0x0001u) /*open for read and write */
56 #define H5F_ACC_TRUNC (H5CHECK H5OPEN 0x0002u) /*overwrite existing files */
57 #define H5F_ACC_EXCL (H5CHECK H5OPEN 0x0004u) /*fail if file already exists*/
5058 /* NOTE: 0x0008u was H5F_ACC_DEBUG, now deprecated */
51 #define H5F_ACC_CREAT (H5CHECK 0x0010u) /*create non-existing files */
52 #define H5F_ACC_SWMR_WRITE (H5CHECK 0x0020u) /*indicate that this file is
53 * open for writing in a
54 * single-writer/multi-reader (SWMR)
55 * scenario. Note that the
56 * process(es) opening the file
57 * for reading must open the file
58 * with RDONLY access, and use
59 * the special "SWMR_READ" access
60 * flag. */
61 #define H5F_ACC_SWMR_READ (H5CHECK 0x0040u) /*indicate that this file is
62 * open for reading in a
63 * single-writer/multi-reader (SWMR)
64 * scenario. Note that the
65 * process(es) opening the file
66 * for SWMR reading must also
67 * open the file with the RDONLY
68 * flag. */
69
59 #define H5F_ACC_CREAT (H5CHECK H5OPEN 0x0010u) /*create non-existing files */
60
61 #define H5F_ACC_SWMR_WRITE (H5CHECK H5OPEN 0x0020u) /*indicate that this file is
62 * open for writing in a
63 * single-writer/multi-reader (SWMR)
64 * scenario. Note that the
65 * process(es) opening the file
66 * for reading must open the file
67 * with RDONLY access, and use
68 * the special "SWMR_READ" access
69 * flag. */
70 #define H5F_ACC_SWMR_READ (H5CHECK H5OPEN 0x0040u) /*indicate that this file is
71 * open for reading in a
72 * single-writer/multi-reader (SWMR)
73 * scenario. Note that the
74 * process(es) opening the file
75 * for SWMR reading must also
76 * open the file with the RDONLY
77 * flag. */
7078 /* Value passed to H5Pset_elink_acc_flags to cause flags to be taken from the
7179 * parent file. */
72 #define H5F_ACC_DEFAULT (H5CHECK 0xffffu) /*ignore setting on lapl */
80 #define H5F_ACC_DEFAULT (H5CHECK H5OPEN 0xffffu) /*ignore setting on lapl */
7381
7482 /* Flags for H5Fget_obj_count() & H5Fget_obj_ids() calls */
7583 #define H5F_OBJ_FILE (0x0001u) /* File objects */
245253 H5_DLL herr_t H5Fget_mdc_logging_status(hid_t file_id,
246254 /*OUT*/ hbool_t *is_enabled,
247255 /*OUT*/ hbool_t *is_currently_logging);
256 H5_DLL herr_t H5Fformat_convert_super(hid_t fid);
248257 #ifdef H5_HAVE_PARALLEL
249258 H5_DLL herr_t H5Fset_mpi_atomicity(hid_t file_id, hbool_t flag);
250259 H5_DLL herr_t H5Fget_mpi_atomicity(hid_t file_id, hbool_t *flag);
257266 #ifndef H5_NO_DEPRECATED_SYMBOLS
258267
259268 /* Macros */
260 #define H5F_ACC_DEBUG (H5CHECK 0x0000u) /*print debug info (deprecated)*/
269 #define H5F_ACC_DEBUG (H5CHECK H5OPEN 0x0000u) /*print debug info (deprecated)*/
261270
262271 /* Typedefs */
263272
545545 HGOTO_ERROR(H5E_FILE, H5E_CANTGET, FAIL, "driver info message not present")
546546
547547 /* Validate and decode driver information */
548 if(H5FD_sb_load(f->shared->lf, drvinfo.name, drvinfo.buf) < 0)
548 if(H5FD_sb_load(f->shared->lf, drvinfo.name, drvinfo.buf) < 0) {
549 H5O_msg_reset(H5O_DRVINFO_ID, &drvinfo);
549550 HGOTO_ERROR(H5E_FILE, H5E_CANTDECODE, FAIL, "unable to decode driver information")
551 } /* end if */
550552
551553 /* Reset driver info message */
552554 H5O_msg_reset(H5O_DRVINFO_ID, &drvinfo);
289289 {
290290 H5G_loc_t loc; /* Location to create group */
291291 H5G_t *grp = NULL; /* New group created */
292 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
292293 hid_t ret_value; /* Return value */
293294
294295 FUNC_ENTER_API(FAIL)
314315 if(TRUE != H5P_isa_class(gcpl_id, H5P_GROUP_CREATE))
315316 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not group create property list")
316317
317 /* Check the group access property list */
318 if(H5P_DEFAULT == gapl_id)
319 gapl_id = H5P_GROUP_ACCESS_DEFAULT;
320 else
321 if(TRUE != H5P_isa_class(gapl_id, H5P_GROUP_ACCESS))
322 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not group access property list")
318 /* Verify access property list and get correct dxpl */
319 if(H5P_verify_and_set_dxpl(&gapl_id, H5P_GROUP_ACCESS, H5P_GROUP_ACCESS_DEFAULT, &dxpl_id) < 0)
320 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
323321
324322 /* Create the new group & get its ID */
325 if(NULL == (grp = H5G__create_named(&loc, name, lcpl_id, gcpl_id, gapl_id, H5AC_dxpl_id)))
323 if(NULL == (grp = H5G__create_named(&loc, name, lcpl_id, gcpl_id, gapl_id, dxpl_id)))
326324 HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "unable to create group")
327325 if((ret_value = H5I_register(H5I_GROUP, grp, TRUE)) < 0)
328326 HGOTO_ERROR(H5E_ATOM, H5E_CANTREGISTER, FAIL, "unable to register group")
377375 H5G_loc_t loc;
378376 H5G_t *grp = NULL;
379377 H5G_obj_create_t gcrt_info; /* Information for group creation */
378 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
380379 hid_t ret_value;
381380
382381 FUNC_ENTER_API(FAIL)
393392 if(TRUE != H5P_isa_class(gcpl_id, H5P_GROUP_CREATE))
394393 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not group create property list")
395394
396 /* Check the group access property list */
397 if(H5P_DEFAULT == gapl_id)
398 gapl_id = H5P_GROUP_ACCESS_DEFAULT;
399 else
400 if(TRUE != H5P_isa_class(gapl_id, H5P_GROUP_ACCESS))
401 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not group access property list")
395 /* Verify access property list and get correct dxpl */
396 if(H5P_verify_and_set_dxpl(&gapl_id, H5P_GROUP_ACCESS, H5P_GROUP_ACCESS_DEFAULT, &dxpl_id) < 0)
397 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
402398
403399 /* Set up group creation info */
404400 gcrt_info.gcpl_id = gcpl_id;
406402 HDmemset(&gcrt_info.cache, 0, sizeof(gcrt_info.cache));
407403
408404 /* Create the new group & get its ID */
409 if(NULL == (grp = H5G__create(loc.oloc->file, &gcrt_info, H5AC_dxpl_id)))
405 if(NULL == (grp = H5G__create(loc.oloc->file, &gcrt_info, dxpl_id)))
410406 HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "unable to create group")
411407 if((ret_value = H5I_register(H5I_GROUP, grp, TRUE)) < 0)
412408 HGOTO_ERROR(H5E_ATOM, H5E_CANTREGISTER, FAIL, "unable to register group")
421417 HDONE_ERROR(H5E_SYM, H5E_CANTGET, FAIL, "unable to get object location of group")
422418
423419 /* Decrement refcount on group's object header in memory */
424 if(H5O_dec_rc_by_loc(oloc, H5AC_dxpl_id) < 0)
420 if(H5O_dec_rc_by_loc(oloc, dxpl_id) < 0)
425421 HDONE_ERROR(H5E_SYM, H5E_CANTDEC, FAIL, "unable to decrement refcount on newly created object")
426422 } /* end if */
427423
456452 {
457453 H5G_t *grp = NULL; /* Group opened */
458454 H5G_loc_t loc; /* Location of parent for group */
455 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
459456 hid_t ret_value; /* Return value */
460457
461458 FUNC_ENTER_API(FAIL)
467464 if(!name || !*name)
468465 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name")
469466
470 /* Check the group access property list */
471 if(H5P_DEFAULT == gapl_id)
472 gapl_id = H5P_GROUP_ACCESS_DEFAULT;
473 else
474 if(TRUE != H5P_isa_class(gapl_id, H5P_GROUP_ACCESS))
475 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not group access property list")
467 /* Verify access property list and get correct dxpl */
468 if(H5P_verify_and_set_dxpl(&gapl_id, H5P_GROUP_ACCESS, H5P_GROUP_ACCESS_DEFAULT, &dxpl_id) < 0)
469 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
476470
477471 /* Open the group */
478 if((grp = H5G__open_name(&loc, name, gapl_id, H5AC_ind_dxpl_id)) == NULL)
472 if((grp = H5G__open_name(&loc, name, gapl_id, dxpl_id)) == NULL)
479473 HGOTO_ERROR(H5E_SYM, H5E_CANTOPENOBJ, FAIL, "unable to open group")
480474
481475 /* Register an ID for the group */
594588 H5G_name_t grp_path; /* Opened object group hier. path */
595589 H5O_loc_t grp_oloc; /* Opened object object location */
596590 hbool_t loc_found = FALSE; /* Location at 'name' found */
591 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
597592 herr_t ret_value = SUCCEED; /* Return value */
598593
599594 FUNC_ENTER_API(FAIL)
606601 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name")
607602 if(!grp_info)
608603 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no info struct")
609 if(H5P_DEFAULT == lapl_id)
610 lapl_id = H5P_LINK_ACCESS_DEFAULT;
611 else
612 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
613 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
604
605 /* Verify access property list and get correct dxpl */
606 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
607 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
614608
615609 /* Set up opened group location to fill in */
616610 grp_loc.oloc = &grp_oloc;
618612 H5G_loc_reset(&grp_loc);
619613
620614 /* Find the group object */
621 if(H5G_loc_find(&loc, name, &grp_loc/*out*/, lapl_id, H5AC_ind_dxpl_id) < 0)
615 if(H5G_loc_find(&loc, name, &grp_loc/*out*/, lapl_id, dxpl_id) < 0)
622616 HGOTO_ERROR(H5E_SYM, H5E_NOTFOUND, FAIL, "group not found")
623617 loc_found = TRUE;
624618
625619 /* Retrieve the group's information */
626 if(H5G__obj_info(grp_loc.oloc, grp_info/*out*/, H5AC_ind_dxpl_id) < 0)
620 if(H5G__obj_info(grp_loc.oloc, grp_info/*out*/, dxpl_id) < 0)
627621 HGOTO_ERROR(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve group info")
628622
629623 done:
657651 H5G_name_t grp_path; /* Opened object group hier. path */
658652 H5O_loc_t grp_oloc; /* Opened object object location */
659653 hbool_t loc_found = FALSE; /* Entry at 'name' found */
654 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
660655 herr_t ret_value = SUCCEED; /* Return value */
661656
662657 FUNC_ENTER_API(FAIL)
674669 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
675670 if(!grp_info)
676671 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no info struct")
677 if(H5P_DEFAULT == lapl_id)
678 lapl_id = H5P_LINK_ACCESS_DEFAULT;
679 else
680 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
681 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
672
673 /* Verify access property list and get correct dxpl */
674 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
675 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
682676
683677 /* Set up opened group location to fill in */
684678 grp_loc.oloc = &grp_oloc;
686680 H5G_loc_reset(&grp_loc);
687681
688682 /* Find the object's location, according to the order in the index */
689 if(H5G_loc_find_by_idx(&loc, group_name, idx_type, order, n, &grp_loc/*out*/, lapl_id, H5AC_ind_dxpl_id) < 0)
683 if(H5G_loc_find_by_idx(&loc, group_name, idx_type, order, n, &grp_loc/*out*/,
684 lapl_id, dxpl_id) < 0)
690685 HGOTO_ERROR(H5E_SYM, H5E_NOTFOUND, FAIL, "group not found")
691686 loc_found = TRUE;
692687
693688 /* Retrieve the group's information */
694 if(H5G__obj_info(grp_loc.oloc, grp_info/*out*/, H5AC_ind_dxpl_id) < 0)
689 if(H5G__obj_info(grp_loc.oloc, grp_info/*out*/, dxpl_id) < 0)
695690 HGOTO_ERROR(H5E_SYM, H5E_CANTGET, FAIL, "can't retrieve group info")
696691
697692 done:
321321 {
322322 H5G_loc_t src_loc, *src_loc_p;
323323 H5G_loc_t dst_loc, *dst_loc_p;
324 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
324325 herr_t ret_value=SUCCEED; /* Return value */
325326
326327 FUNC_ENTER_API(FAIL)
349350 else if(dst_loc_id == H5L_SAME_LOC)
350351 dst_loc_p = src_loc_p;
351352
353 /* Verify access property list and get correct dxpl */
354 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
355 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
356
352357 /* Move the link */
353358 if(H5L_move(src_loc_p, src_name, dst_loc_p, dst_name, FALSE, lcpl_id,
354 lapl_id, H5AC_dxpl_id) < 0)
359 lapl_id, dxpl_id) < 0)
355360 HGOTO_ERROR(H5E_LINK, H5E_CANTMOVE, FAIL, "unable to move link")
356361
357362 done:
379384 {
380385 H5G_loc_t src_loc, *src_loc_p;
381386 H5G_loc_t dst_loc, *dst_loc_p;
387 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
382388 herr_t ret_value=SUCCEED; /* Return value */
383389
384390 FUNC_ENTER_API(FAIL)
407413 else if(dst_loc_id == H5L_SAME_LOC)
408414 dst_loc_p = src_loc_p;
409415
416 /* Verify access property list and get correct dxpl */
417 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
418 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
419
410420 /* Copy the link */
411421 if(H5L_move(src_loc_p, src_name, dst_loc_p, dst_name, TRUE, lcpl_id,
412 lapl_id, H5AC_dxpl_id) < 0)
422 lapl_id, dxpl_id) < 0)
413423 HGOTO_ERROR(H5E_LINK, H5E_CANTMOVE, FAIL, "unable to move link")
414424
415425 done:
440450 hid_t link_loc_id, const char *link_name, hid_t lcpl_id, hid_t lapl_id)
441451 {
442452 H5G_loc_t link_loc; /* Group location for new link */
453 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
443454 herr_t ret_value = SUCCEED; /* Return value */
444455
445456 FUNC_ENTER_API(FAIL)
455466 if(lcpl_id != H5P_DEFAULT && (TRUE != H5P_isa_class(lcpl_id, H5P_LINK_CREATE)))
456467 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a link creation property list")
457468
469 /* Verify access property list and get correct dxpl */
470 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
471 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
472
458473 /* Create the link */
459 if(H5L_create_soft(link_target, &link_loc, link_name, lcpl_id, lapl_id, H5AC_dxpl_id) < 0)
474 if(H5L_create_soft(link_target, &link_loc, link_name, lcpl_id, lapl_id, dxpl_id) < 0)
460475 HGOTO_ERROR(H5E_LINK, H5E_CANTINIT, FAIL, "unable to create link")
461476
462477 done:
486501 {
487502 H5G_loc_t cur_loc, *cur_loc_p;
488503 H5G_loc_t new_loc, *new_loc_p;
504 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
489505 herr_t ret_value = SUCCEED; /* Return value */
490506
491507 FUNC_ENTER_API(FAIL)
516532 else if(cur_loc_p->oloc->file != new_loc_p->oloc->file)
517533 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "source and destination should be in the same file.")
518534
535 /* Verify access property list and get correct dxpl */
536 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
537 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
538
519539 /* Create the link */
520540 if(H5L_create_hard(cur_loc_p, cur_name, new_loc_p, new_name,
521 lcpl_id, lapl_id, H5AC_dxpl_id) < 0)
541 lcpl_id, lapl_id, dxpl_id) < 0)
522542 HGOTO_ERROR(H5E_LINK, H5E_CANTINIT, FAIL, "unable to create link")
523543
524544 done:
555575 const void *udata, size_t udata_size, hid_t lcpl_id, hid_t lapl_id)
556576 {
557577 H5G_loc_t link_loc;
578 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
558579 herr_t ret_value = SUCCEED; /* Return value */
559580
560581 FUNC_ENTER_API(FAIL)
569590 if(link_type < H5L_TYPE_UD_MIN || link_type > H5L_TYPE_MAX)
570591 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid link class")
571592
593 /* Verify access property list and get correct dxpl */
594 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
595 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
596
572597 /* Create external link */
573 if(H5L_create_ud(&link_loc, link_name, udata, udata_size, link_type, lcpl_id, lapl_id, H5AC_dxpl_id) < 0)
598 if(H5L_create_ud(&link_loc, link_name, udata, udata_size, link_type, lcpl_id, lapl_id, dxpl_id) < 0)
574599 HGOTO_ERROR(H5E_LINK, H5E_CANTINIT, FAIL, "unable to create link")
575600
576601 done:
599624 H5Ldelete(hid_t loc_id, const char *name, hid_t lapl_id)
600625 {
601626 H5G_loc_t loc; /* Group's location */
627 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
602628 herr_t ret_value = SUCCEED; /* Return value */
603629
604630 FUNC_ENTER_API(FAIL)
610636 if(!name || !*name)
611637 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name")
612638
639 /* Verify access property list and get correct dxpl */
640 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
641 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
642
613643 /* Unlink */
614 if(H5L_delete(&loc, name, lapl_id, H5AC_dxpl_id) < 0)
644 if(H5L_delete(&loc, name, lapl_id, dxpl_id) < 0)
615645 HGOTO_ERROR(H5E_LINK, H5E_CANTDELETE, FAIL, "unable to delete link")
616646
617647 done:
644674 {
645675 H5G_loc_t loc; /* Group's location */
646676 H5L_trav_rmbi_t udata; /* User data for callback */
677 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
647678 herr_t ret_value = SUCCEED; /* Return value */
648679
649680 FUNC_ENTER_API(FAIL)
658689 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid index type specified")
659690 if(order <= H5_ITER_UNKNOWN || order >= H5_ITER_N)
660691 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
661 if(H5P_DEFAULT == lapl_id)
662 lapl_id = H5P_LINK_ACCESS_DEFAULT;
663 else
664 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
665 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
692
693 /* Verify access property list and get correct dxpl */
694 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
695 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
666696
667697 /* Set up user data for unlink operation */
668698 udata.idx_type = idx_type;
671701 udata.dxpl_id = H5AC_dxpl_id;
672702
673703 /* Traverse the group hierarchy to remove the link */
674 if(H5G_traverse(&loc, group_name, H5G_TARGET_SLINK|H5G_TARGET_UDLINK|H5G_TARGET_MOUNT, H5L_delete_by_idx_cb, &udata, lapl_id, H5AC_dxpl_id) < 0)
704 if(H5G_traverse(&loc, group_name, H5G_TARGET_SLINK|H5G_TARGET_UDLINK|H5G_TARGET_MOUNT,
705 H5L_delete_by_idx_cb, &udata, lapl_id, dxpl_id) < 0)
675706 HGOTO_ERROR(H5E_SYM, H5E_EXISTS, FAIL, "name doesn't exist")
676707
677708 done:
703734 hid_t lapl_id)
704735 {
705736 H5G_loc_t loc; /* Group location for location to query */
737 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
706738 herr_t ret_value = SUCCEED; /* Return value */
707739
708740 FUNC_ENTER_API(FAIL)
713745 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a location")
714746 if(!name || !*name)
715747 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name specified")
716 if(H5P_DEFAULT == lapl_id)
717 lapl_id = H5P_LINK_ACCESS_DEFAULT;
718 else
719 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
720 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
748
749 /* Verify access property list and get correct dxpl */
750 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
751 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
721752
722753 /* Get the link value */
723 if(H5L_get_val(&loc, name, buf, size, lapl_id, H5AC_ind_dxpl_id) < 0)
754 if(H5L_get_val(&loc, name, buf, size, lapl_id, dxpl_id) < 0)
724755 HGOTO_ERROR(H5E_SYM, H5E_NOTFOUND, FAIL, "unable to get link value for '%s'", name)
725756
726757 done:
753784 {
754785 H5G_loc_t loc; /* Group location for location to query */
755786 H5L_trav_gvbi_t udata; /* User data for callback */
787 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
756788 herr_t ret_value = SUCCEED; /* Return value */
757789
758790 FUNC_ENTER_API(FAIL)
768800 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid index type specified")
769801 if(order <= H5_ITER_UNKNOWN || order >= H5_ITER_N)
770802 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
771 if(H5P_DEFAULT == lapl_id)
772 lapl_id = H5P_LINK_ACCESS_DEFAULT;
773 else
774 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
775 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
803
804 /* Verify access property list and get correct dxpl */
805 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
806 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
776807
777808 /* Set up user data for retrieving information */
778809 udata.idx_type = idx_type;
779810 udata.order = order;
780811 udata.n = n;
781 udata.dxpl_id = H5AC_ind_dxpl_id;
812 udata.dxpl_id = dxpl_id;
782813 udata.buf = buf;
783814 udata.size = size;
784815
785816 /* Traverse the group hierarchy to locate the object to get info about */
786 if(H5G_traverse(&loc, group_name, H5G_TARGET_SLINK | H5G_TARGET_UDLINK, H5L_get_val_by_idx_cb, &udata, lapl_id, H5AC_ind_dxpl_id) < 0)
817 if(H5G_traverse(&loc, group_name, H5G_TARGET_SLINK | H5G_TARGET_UDLINK, H5L_get_val_by_idx_cb,
818 &udata, lapl_id, dxpl_id) < 0)
787819 HGOTO_ERROR(H5E_SYM, H5E_NOTFOUND, FAIL, "name doesn't exist")
788820
789821
809841 H5Lexists(hid_t loc_id, const char *name, hid_t lapl_id)
810842 {
811843 H5G_loc_t loc;
844 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
812845 htri_t ret_value;
813846
814847 FUNC_ENTER_API(FAIL)
819852 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a location")
820853 if(!name || !*name)
821854 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name specified")
822 if(H5P_DEFAULT == lapl_id)
823 lapl_id = H5P_LINK_ACCESS_DEFAULT;
824 else
825 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
826 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
855
856 /* Verify access property list and get correct dxpl */
857 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
858 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
827859
828860 /* Check for the existence of the link */
829 if((ret_value = H5L_exists(&loc, name, lapl_id, H5AC_ind_dxpl_id)) < 0)
861 if((ret_value = H5L_exists(&loc, name, lapl_id, dxpl_id)) < 0)
830862 HGOTO_ERROR(H5E_SYM, H5E_NOTFOUND, FAIL, "unable to get link info")
831863
832864 done:
853885 hid_t lapl_id)
854886 {
855887 H5G_loc_t loc;
888 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
856889 herr_t ret_value = SUCCEED;
857890
858891 FUNC_ENTER_API(FAIL)
863896 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a location")
864897 if(!name || !*name)
865898 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name specified")
866 if(H5P_DEFAULT == lapl_id)
867 lapl_id = H5P_LINK_ACCESS_DEFAULT;
868 else
869 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
870 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
899
900 /* Verify access property list and get correct dxpl */
901 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
902 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
871903
872904 /* Get the link information */
873 if(H5L_get_info(&loc, name, linfo, lapl_id, H5AC_ind_dxpl_id) < 0)
905 if(H5L_get_info(&loc, name, linfo, lapl_id, dxpl_id) < 0)
874906 HGOTO_ERROR(H5E_SYM, H5E_NOTFOUND, FAIL, "unable to get link info")
875907
876908 done:
899931 {
900932 H5G_loc_t loc; /* Group location for group to query */
901933 H5L_trav_gibi_t udata; /* User data for callback */
934 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
902935 herr_t ret_value = SUCCEED; /* Return value */
903936
904937 FUNC_ENTER_API(FAIL)
914947 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid index type specified")
915948 if(order <= H5_ITER_UNKNOWN || order >= H5_ITER_N)
916949 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
917 if(H5P_DEFAULT == lapl_id)
918 lapl_id = H5P_LINK_ACCESS_DEFAULT;
919 else
920 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
921 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
950
951 /* Verify access property list and get correct dxpl */
952 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
953 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
922954
923955 /* Set up user data for callback */
924956 udata.idx_type = idx_type;
925957 udata.order = order;
926958 udata.n = n;
927 udata.dxpl_id = H5AC_ind_dxpl_id;
959 udata.dxpl_id = dxpl_id;
928960 udata.linfo = linfo;
929961
930962 /* Traverse the group hierarchy to locate the object to get info about */
931 if(H5G_traverse(&loc, group_name, H5G_TARGET_SLINK|H5G_TARGET_UDLINK, H5L_get_info_by_idx_cb, &udata, lapl_id, H5AC_ind_dxpl_id) < 0)
963 if(H5G_traverse(&loc, group_name, H5G_TARGET_SLINK|H5G_TARGET_UDLINK,
964 H5L_get_info_by_idx_cb, &udata, lapl_id, dxpl_id) < 0)
932965 HGOTO_ERROR(H5E_SYM, H5E_NOTFOUND, FAIL, "unable to get link info")
933966
934967
10881121 {
10891122 H5G_loc_t loc; /* Location of group */
10901123 H5L_trav_gnbi_t udata; /* User data for callback */
1124 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
10911125 ssize_t ret_value; /* Return value */
10921126
10931127 FUNC_ENTER_API(FAIL)
11031137 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid index type specified")
11041138 if(order <= H5_ITER_UNKNOWN || order >= H5_ITER_N)
11051139 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
1106 if(H5P_DEFAULT == lapl_id)
1107 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1108 else
1109 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1110 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1140
1141 /* Verify access property list and get correct dxpl */
1142 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1143 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
11111144
11121145 /* Set up user data for callback */
11131146 udata.idx_type = idx_type;
11141147 udata.order = order;
11151148 udata.n = n;
1116 udata.dxpl_id = H5AC_ind_dxpl_id;
1149 udata.dxpl_id = dxpl_id;
11171150 udata.name = name;
11181151 udata.size = size;
11191152 udata.name_len = -1;
11201153
11211154 /* Traverse the group hierarchy to locate the link to get name of */
1122 if(H5G_traverse(&loc, group_name, H5G_TARGET_SLINK|H5G_TARGET_UDLINK, H5L_get_name_by_idx_cb, &udata, lapl_id, H5AC_ind_dxpl_id) < 0)
1155 if(H5G_traverse(&loc, group_name, H5G_TARGET_SLINK|H5G_TARGET_UDLINK,
1156 H5L_get_name_by_idx_cb, &udata, lapl_id, dxpl_id) < 0)
11231157 HGOTO_ERROR(H5E_SYM, H5E_EXISTS, FAIL, "name doesn't exist")
11241158
11251159 /* Set the return value */
11851219 lnk_op.op_func.op_new = op;
11861220
11871221 /* Iterate over the links */
1188 if((ret_value = H5G_iterate(grp_id, ".", idx_type, order, idx, &last_lnk, &lnk_op, op_data, H5P_DEFAULT, H5AC_ind_dxpl_id)) < 0)
1222 if((ret_value = H5G_iterate(grp_id, ".", idx_type, order, idx, &last_lnk, &lnk_op,
1223 op_data, H5P_DEFAULT, H5AC_ind_dxpl_id)) < 0)
11891224 HGOTO_ERROR(H5E_SYM, H5E_BADITER, FAIL, "link iteration failed")
11901225
11911226 /* Set the index we stopped at */
12271262 H5G_link_iterate_t lnk_op; /* Link operator */
12281263 hsize_t last_lnk; /* Index of last object looked at */
12291264 hsize_t idx; /* Internal location to hold index */
1265 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
12301266 herr_t ret_value; /* Return value */
12311267
12321268 FUNC_ENTER_API(FAIL)
12421278 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
12431279 if(!op)
12441280 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no operator specified")
1245 if(H5P_DEFAULT == lapl_id)
1246 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1247 else
1248 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1249 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1281
1282 /* Verify access property list and get correct dxpl */
1283 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1284 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
12501285
12511286 /* Set up iteration beginning/end info */
12521287 idx = (idx_p == NULL ? 0 : *idx_p);
12571292 lnk_op.op_func.op_new = op;
12581293
12591294 /* Iterate over the links */
1260 if((ret_value = H5G_iterate(loc_id, group_name, idx_type, order, idx, &last_lnk, &lnk_op, op_data, lapl_id, H5AC_ind_dxpl_id)) < 0)
1295 if((ret_value = H5G_iterate(loc_id, group_name, idx_type, order, idx, &last_lnk, &lnk_op,
1296 op_data, lapl_id, dxpl_id)) < 0)
12611297 HGOTO_ERROR(H5E_SYM, H5E_BADITER, FAIL, "link iteration failed")
12621298
12631299 /* Set the index we stopped at */
13591395 H5Lvisit_by_name(hid_t loc_id, const char *group_name, H5_index_t idx_type,
13601396 H5_iter_order_t order, H5L_iterate_t op, void *op_data, hid_t lapl_id)
13611397 {
1398 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
13621399 herr_t ret_value; /* Return value */
13631400
13641401 FUNC_ENTER_API(FAIL)
13741411 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
13751412 if(!op)
13761413 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no callback operator specified")
1377 if(H5P_DEFAULT == lapl_id)
1378 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1379 else
1380 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1381 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1414
1415 /* Verify access property list and get correct dxpl */
1416 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1417 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
13821418
13831419 /* Call internal group visitation routine */
1384 if((ret_value = H5G_visit(loc_id, group_name, idx_type, order, op, op_data, lapl_id, H5AC_ind_dxpl_id)) < 0)
1420 if((ret_value = H5G_visit(loc_id, group_name, idx_type, order, op, op_data, lapl_id, dxpl_id)) < 0)
13851421 HGOTO_ERROR(H5E_SYM, H5E_BADITER, FAIL, "link visitation failed")
13861422
13871423 done:
562562 size_t file_name_len; /* Length of file name string */
563563 size_t norm_obj_name_len; /* Length of normalized object name string */
564564 uint8_t *p; /* Pointer into external link buffer */
565 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
565566 herr_t ret_value = SUCCEED; /* Return value */
566567
567568 FUNC_ENTER_API(FAIL)
596597 p += file_name_len;
597598 HDstrncpy((char *)p, norm_obj_name, buf_size - (file_name_len + 1)); /* External link's object */
598599
600 /* Verify access property list and get correct dxpl */
601 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
602 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
603
599604 /* Create an external link */
600 if(H5L_create_ud(&link_loc, link_name, ext_link_buf, buf_size, H5L_TYPE_EXTERNAL, lcpl_id, lapl_id, H5AC_dxpl_id) < 0)
605 if(H5L_create_ud(&link_loc, link_name, ext_link_buf, buf_size, H5L_TYPE_EXTERNAL, lcpl_id, lapl_id, dxpl_id) < 0)
601606 HGOTO_ERROR(H5E_LINK, H5E_CANTINIT, FAIL, "unable to create link")
602607
603608 done:
2424 */
2525
2626
27 #include "H5private.h"
28 #include "H5Eprivate.h"
29 #include "H5MMprivate.h"
27 /****************/
28 /* Module Setup */
29 /****************/
30
31
32 /***********/
33 /* Headers */
34 /***********/
35 #include "H5private.h" /* Generic Functions */
36 #include "H5Eprivate.h" /* Error handling */
37 #include "H5MMprivate.h" /* Memory management */
38
39
40 /****************/
41 /* Local Macros */
42 /****************/
43 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
44 #define H5MM_SIG_SIZE 4
45 #define H5MM_HEAD_GUARD_SIZE 8
46 #define H5MM_TAIL_GUARD_SIZE 8
47 #define H5MM_BLOCK_FROM_BUF(mem) ((H5MM_block_t *)((unsigned char *)mem - (offsetof(H5MM_block_t, b) + H5MM_HEAD_GUARD_SIZE)))
48 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
49
50
51 /******************/
52 /* Local Typedefs */
53 /******************/
54
55 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
56 /* Memory allocation "block", wrapped around each allocation */
57 struct H5MM_block_t; /* Forward declaration for typedef */
58 typedef struct H5MM_block_t {
59 unsigned char sig[H5MM_SIG_SIZE]; /* Signature for the block, to indicate it was allocated with H5MM* interface */
60 struct H5MM_block_t *next; /* Pointer to next block in the list of allocated blocks */
61 struct H5MM_block_t *prev; /* Pointer to previous block in the list of allocated blocks */
62 union {
63 struct {
64 size_t size; /* Size of allocated block */
65 hbool_t in_use; /* Whether the block is in use or is free */
66 } info;
67 double _align; /* Align following buffer (b) to double boundary (unused) */
68 } u;
69 unsigned char b[]; /* Buffer for caller (includes header and footer) */
70 } H5MM_block_t;
71 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
72
73
74 /********************/
75 /* Local Prototypes */
76 /********************/
77 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
78 static hbool_t H5MM__is_our_block(void *mem);
79 static void H5MM__sanity_check_block(const H5MM_block_t *block);
80 static void H5MM__sanity_check(void *mem);
81 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
82
83
84 /*********************/
85 /* Package Variables */
86 /*********************/
87
88
89 /*****************************/
90 /* Library Private Variables */
91 /*****************************/
92
93
94 /*******************/
95 /* Local Variables */
96 /*******************/
97
98 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
99 /* Constant strings for block signature, head & tail guards */
100 static const char H5MM_block_signature_s[H5MM_SIG_SIZE] = {'H', '5', 'M', 'M'};
101 static const char H5MM_block_head_guard_s[H5MM_HEAD_GUARD_SIZE] = {'D', 'E', 'A', 'D', 'B', 'E', 'E', 'F'};
102 static const char H5MM_block_tail_guard_s[H5MM_TAIL_GUARD_SIZE] = {'B', 'E', 'E', 'F', 'D', 'E', 'A', 'D'};
103
104 /* Flag to indicate the the interface has been initialized */
105 static hbool_t H5MM_init_s = FALSE;
106
107 /* Head of the list of allocated blocks */
108 static H5MM_block_t H5MM_block_head_s;
109
110 /* Statistics about block allocations */
111 static unsigned long long H5MM_total_alloc_bytes_s = 0;
112 static unsigned long long H5MM_curr_alloc_bytes_s = 0;
113 static unsigned long long H5MM_peak_alloc_bytes_s = 0;
114 static size_t H5MM_max_block_size_s = 0;
115 static size_t H5MM_total_alloc_blocks_count_s = 0;
116 static size_t H5MM_curr_alloc_blocks_count_s = 0;
117 static size_t H5MM_peak_alloc_blocks_count_s = 0;
118 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
119
120
121 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
122
123 /*-------------------------------------------------------------------------
124 * Function: H5MM__is_our_block
125 *
126 * Purpose: Try to determine if a memory buffer has been allocated through
127 * the H5MM* interface, instead of the system's malloc() routines.
128 *
129 * Return: Success: TRUE/FALSE
130 * Failure: (Can't fail)
131 *
132 * Programmer: Quincey Koziol
133 * Dec 30 2015
134 *
135 *-------------------------------------------------------------------------
136 */
137 static hbool_t
138 H5MM__is_our_block(void *mem)
139 {
140 H5MM_block_t *block = H5MM_BLOCK_FROM_BUF(mem);
141
142 return(0 == HDmemcmp(block->sig, H5MM_block_signature_s, H5MM_SIG_SIZE));
143 }
144
145
146 /*-------------------------------------------------------------------------
147 * Function: H5MM__sanity_check_block
148 *
149 * Purpose: Check a block wrapper around a buffer to validate it.
150 *
151 * Return: N/A (void)
152 *
153 * Programmer: Quincey Koziol
154 * Dec 30 2015
155 *
156 *-------------------------------------------------------------------------
157 */
158 static void
159 H5MM__sanity_check_block(const H5MM_block_t *block)
160 {
161 HDassert(block->u.info.size > 0);
162 HDassert(block->u.info.in_use);
163 /* Check for head & tail guards, if not head of linked list */
164 if(block->u.info.size != SIZET_MAX) {
165 HDassert(0 == HDmemcmp(block->b, H5MM_block_head_guard_s, H5MM_HEAD_GUARD_SIZE));
166 HDassert(0 == HDmemcmp(block->b + H5MM_HEAD_GUARD_SIZE + block->u.info.size, H5MM_block_tail_guard_s, H5MM_TAIL_GUARD_SIZE));
167 }
168 }
169
170
171 /*-------------------------------------------------------------------------
172 * Function: H5MM__sanity_check
173 *
174 * Purpose: Check a buffer to validate it (just calls
175 * H5MM__sanity_check_block after finding block for buffer)
176 *
177 * Return: N/A (void)
178 *
179 * Programmer: Quincey Koziol
180 * Dec 30 2015
181 *
182 *-------------------------------------------------------------------------
183 */
184 static void
185 H5MM__sanity_check(void *mem)
186 {
187 H5MM_block_t *block = H5MM_BLOCK_FROM_BUF(mem);
188
189 H5MM__sanity_check_block(block);
190 }
191
192
193 /*-------------------------------------------------------------------------
194 * Function: H5MM_sanity_check_all
195 *
196 * Purpose: Sanity check all current memory allocations.
197 *
198 * Return: N/A (void)
199 *
200 * Programmer: Quincey Koziol
201 * Jan 5 2016
202 *
203 *-------------------------------------------------------------------------
204 */
205 void
206 H5MM_sanity_check_all(void)
207 {
208 H5MM_block_t *curr;
209
210 curr = H5MM_block_head_s.next;
211 while(curr != &H5MM_block_head_s) {
212 H5MM__sanity_check_block(curr);
213 curr = curr->next;
214 } /* end while */
215 } /* end H5MM_sanity_check_all() */
216
217
218 /*-------------------------------------------------------------------------
219 * Function: H5MM_final_sanity_check
220 *
221 * Purpose: Final sanity checks on memory allocation.
222 *
223 * Return: N/A (void)
224 *
225 * Programmer: Quincey Koziol
226 * Jan 1 2016
227 *
228 *-------------------------------------------------------------------------
229 */
230 void
231 H5MM_final_sanity_check(void)
232 {
233 HDassert(0 == H5MM_curr_alloc_bytes_s);
234 HDassert(0 == H5MM_curr_alloc_blocks_count_s);
235 HDassert(H5MM_block_head_s.next == &H5MM_block_head_s);
236 HDassert(H5MM_block_head_s.prev == &H5MM_block_head_s);
237 #ifdef H5MM_PRINT_MEMORY_STATS
238 HDfprintf(stderr, "%s: H5MM_total_alloc_bytes_s = %llu\n", __func__, H5MM_total_alloc_bytes_s);
239 HDfprintf(stderr, "%s: H5MM_peak_alloc_bytes_s = %llu\n", __func__, H5MM_peak_alloc_bytes_s);
240 HDfprintf(stderr, "%s: H5MM_max_block_size_s = %zu\n", __func__, H5MM_max_block_size_s);
241 HDfprintf(stderr, "%s: H5MM_total_alloc_blocks_count_s = %zu\n", __func__, H5MM_total_alloc_blocks_count_s);
242 HDfprintf(stderr, "%s: H5MM_peak_alloc_blocks_count_s = %zu\n", __func__, H5MM_peak_alloc_blocks_count_s);
243 #endif /* H5MM_PRINT_MEMORY_STATS */
244 }
245 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
30246
31247
32248 /*-------------------------------------------------------------------------
41257 * bytes usually indicate problems.
42258 *
43259 * Return: Success: Pointer new memory
44 *
45260 * Failure: NULL
46261 *
47262 * Programmer: Quincey Koziol
59274 /* Use FUNC_ENTER_NOAPI_NOINIT_NOERR here to avoid performance issues */
60275 FUNC_ENTER_NOAPI_NOINIT_NOERR
61276
62 if(size)
277 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
278 /* Initialize block list head singleton */
279 if(!H5MM_init_s) {
280 HDmemcpy(H5MM_block_head_s.sig, H5MM_block_signature_s, H5MM_SIG_SIZE);
281 H5MM_block_head_s.next = &H5MM_block_head_s;
282 H5MM_block_head_s.prev = &H5MM_block_head_s;
283 H5MM_block_head_s.u.info.size = SIZET_MAX;
284 H5MM_block_head_s.u.info.in_use = TRUE;
285
286 H5MM_init_s = TRUE;
287 } /* end if */
288 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
289
290 if(size) {
291 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
292 H5MM_block_t *block;
293 size_t alloc_size = sizeof(H5MM_block_t) + size + H5MM_HEAD_GUARD_SIZE + H5MM_TAIL_GUARD_SIZE;
294
295 if(NULL != (block = (H5MM_block_t *)HDmalloc(alloc_size))) {
296 /* Set up block */
297 HDmemcpy(block->sig, H5MM_block_signature_s, H5MM_SIG_SIZE);
298 block->next = H5MM_block_head_s.next;
299 H5MM_block_head_s.next = block;
300 block->next->prev = block;
301 block->prev = &H5MM_block_head_s;
302 block->u.info.size = size;
303 block->u.info.in_use = TRUE;
304 HDmemcpy(block->b, H5MM_block_head_guard_s, H5MM_HEAD_GUARD_SIZE);
305 HDmemcpy(block->b + H5MM_HEAD_GUARD_SIZE + size, H5MM_block_tail_guard_s, H5MM_TAIL_GUARD_SIZE);
306
307 /* Update statistics */
308 H5MM_total_alloc_bytes_s += size;
309 H5MM_curr_alloc_bytes_s += size;
310 if(H5MM_curr_alloc_bytes_s > H5MM_peak_alloc_bytes_s)
311 H5MM_peak_alloc_bytes_s = H5MM_curr_alloc_bytes_s;
312 if(size > H5MM_max_block_size_s)
313 H5MM_max_block_size_s = size;
314 H5MM_total_alloc_blocks_count_s++;
315 H5MM_curr_alloc_blocks_count_s++;
316 if(H5MM_curr_alloc_blocks_count_s > H5MM_peak_alloc_blocks_count_s)
317 H5MM_peak_alloc_blocks_count_s = H5MM_curr_alloc_blocks_count_s;
318
319 /* Set buffer to return */
320 ret_value = block->b + H5MM_HEAD_GUARD_SIZE;
321 } /* end if */
322 else
323 ret_value = NULL;
324 #else /* H5_MEMORY_ALLOC_SANITY_CHECK */
63325 ret_value = HDmalloc(size);
326 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
327 } /* end if */
64328 else
65329 ret_value = NULL;
66330
67 FUNC_LEAVE_NOAPI(ret_value);
331 FUNC_LEAVE_NOAPI(ret_value)
68332 } /* end H5MM_malloc() */
69333
70334
82346 *
83347 *
84348 * Return: Success: Pointer new memory
85 *
86349 * Failure: NULL
87350 *
88351 * Programmer: Quincey Koziol
100363 /* Use FUNC_ENTER_NOAPI_NOINIT_NOERR here to avoid performance issues */
101364 FUNC_ENTER_NOAPI_NOINIT_NOERR
102365
103 if(size)
366 if(size) {
367 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
368 if(NULL != (ret_value = H5MM_malloc(size)))
369 HDmemset(ret_value, 0, size);
370 #else /* H5_MEMORY_ALLOC_SANITY_CHECK */
104371 ret_value = HDcalloc((size_t)1, size);
372 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
373 } /* end if */
105374 else
106375 ret_value = NULL;
107376
108 FUNC_LEAVE_NOAPI(ret_value);
377 FUNC_LEAVE_NOAPI(ret_value)
109378 } /* end H5MM_calloc() */
110379
111380
122391 * Note that the (NULL, 0) combination is undefined behavior
123392 * in the C standard.
124393 *
125 * Return: Success: Ptr to new memory if size > 0
126 * NULL if size is zero
127 *
394 * Return: Success: Ptr to new memory if size > 0, NULL if size is zero
128395 * Failure: NULL (input buffer is unchanged on failure)
129396 *
130397 * Programmer: Robb Matzke
142409
143410 HDassert(mem || size);
144411
145 if(NULL == mem && 0 == size) {
412 if(NULL == mem && 0 == size)
146413 /* Not defined in the standard, return NULL */
147414 ret_value = NULL;
148 }
149415 else {
416 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
417 if(size > 0) {
418 if(mem) {
419 if(H5MM__is_our_block(mem)) {
420 H5MM_block_t *block = H5MM_BLOCK_FROM_BUF(mem);
421 size_t old_size = block->u.info.size;
422
423 H5MM__sanity_check(mem);
424
425 ret_value = H5MM_malloc(size);
426 HDmemcpy(ret_value, mem, MIN(size, old_size));
427 H5MM_xfree(mem);
428 } /* end if */
429 else
430 ret_value = HDrealloc(mem, size);
431 }
432 else
433 ret_value = H5MM_malloc(size);
434 }
435 else
436 ret_value = H5MM_xfree(mem);
437 #else /* H5_MEMORY_ALLOC_SANITY_CHECK */
150438 ret_value = HDrealloc(mem, size);
151439
152440 /* Some platforms do not return NULL if size is zero. */
153441 if(0 == size)
154442 ret_value = NULL;
155 }
443 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
444 } /* end else */
156445
157446 FUNC_LEAVE_NOAPI(ret_value)
158447 } /* end H5MM_realloc() */
249538 /* Use FUNC_ENTER_NOAPI_NOINIT_NOERR here to avoid performance issues */
250539 FUNC_ENTER_NOAPI_NOINIT_NOERR
251540
252 if(mem)
541 if(mem) {
542 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
543 if(H5MM__is_our_block(mem)) {
544 H5MM_block_t *block = H5MM_BLOCK_FROM_BUF(mem);
545
546 /* Run sanity checks on this block and its neighbors */
547 H5MM__sanity_check(mem);
548 H5MM__sanity_check_block(block->next);
549 H5MM__sanity_check_block(block->prev);
550
551 /* Update statistics */
552 H5MM_curr_alloc_bytes_s -= block->u.info.size;
553 H5MM_curr_alloc_blocks_count_s--;
554
555 /* Reset block info */
556 HDmemset(block->sig, 0, H5MM_SIG_SIZE);
557 block->next->prev = block->prev;
558 block->prev->next = block->next;
559 block->next = NULL;
560 block->prev = NULL;
561 block->u.info.in_use = FALSE;
562
563 /* Free the block (finally!) */
564 HDfree(block);
565 }
566 else
567 HDfree(mem);
568 #else /* H5_MEMORY_ALLOC_SANITY_CHECK */
253569 HDfree(mem);
254
255 FUNC_LEAVE_NOAPI(NULL);
570 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
571 } /* end if */
572
573 FUNC_LEAVE_NOAPI(NULL)
256574 } /* end H5MM_xfree() */
575
2020 *
2121 * Purpose: Private header for memory management.
2222 *
23 * Modifications:
24 *
2523 *-------------------------------------------------------------------------
2624 */
2725 #ifndef _H5MMprivate_H
3230 /* Private headers needed by this file */
3331 #include "H5private.h"
3432
33 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
34 /*#define H5MM_PRINT_MEMORY_STATS */
35 #define H5MM_free(Z) H5MM_xfree(Z)
36 #else /* H5_MEMORY_ALLOC_SANITY_CHECK */
3537 #define H5MM_free(Z) HDfree(Z)
38 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
3639
3740 /*
3841 * Library prototypes...
4346 H5_DLL char *H5MM_xstrdup(const char *s);
4447 H5_DLL char *H5MM_strdup(const char *s);
4548 H5_DLL void *H5MM_xfree(void *mem);
49 #if defined H5_MEMORY_ALLOC_SANITY_CHECK
50 H5_DLL void H5MM_sanity_check_all(void);
51 H5_DLL void H5MM_final_sanity_check(void);
52 #endif /* H5_MEMORY_ALLOC_SANITY_CHECK */
4653
47 #endif
54 #endif /* _H5MMprivate_H */
55
281281 H5G_loc_t obj_loc; /* Location used to open group */
282282 H5G_name_t obj_path; /* Opened object group hier. path */
283283 H5O_loc_t obj_oloc; /* Opened object object location */
284 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
284285 hbool_t loc_found = FALSE; /* Entry at 'name' found */
285286 hid_t ret_value = FAIL;
286287
296297 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid index type specified")
297298 if(order <= H5_ITER_UNKNOWN || order >= H5_ITER_N)
298299 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
299 if(H5P_DEFAULT == lapl_id)
300 lapl_id = H5P_LINK_ACCESS_DEFAULT;
301 else
302 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
303 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
300
301 /* Verify access property list and get correct dxpl */
302 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
303 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
304304
305305 /* Set up opened group location to fill in */
306306 obj_loc.oloc = &obj_oloc;
308308 H5G_loc_reset(&obj_loc);
309309
310310 /* Find the object's location, according to the order in the index */
311 if(H5G_loc_find_by_idx(&loc, group_name, idx_type, order, n, &obj_loc/*out*/, lapl_id, H5AC_ind_dxpl_id) < 0)
311 if(H5G_loc_find_by_idx(&loc, group_name, idx_type, order, n, &obj_loc/*out*/, lapl_id, dxpl_id) < 0)
312312 HGOTO_ERROR(H5E_OHDR, H5E_NOTFOUND, FAIL, "group not found")
313313 loc_found = TRUE;
314314
315315 /* Open the object */
316 if((ret_value = H5O_open_by_loc(&obj_loc, lapl_id, H5AC_ind_dxpl_id, TRUE)) < 0)
316 if((ret_value = H5O_open_by_loc(&obj_loc, lapl_id, dxpl_id, TRUE)) < 0)
317317 HGOTO_ERROR(H5E_OHDR, H5E_CANTOPENOBJ, FAIL, "unable to open object")
318318
319319 done:
425425 {
426426 H5G_loc_t new_loc;
427427 H5G_loc_t obj_loc;
428 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
428429 herr_t ret_value = SUCCEED; /* Return value */
429430
430431 FUNC_ENTER_API(FAIL)
447448 if(lcpl_id != H5P_DEFAULT && (TRUE != H5P_isa_class(lcpl_id, H5P_LINK_CREATE)))
448449 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a link creation property list")
449450
451 /* Verify access property list and get correct dxpl */
452 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
453 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
454
450455 /* Link to the object */
451 if(H5L_link(&new_loc, new_name, &obj_loc, lcpl_id, lapl_id, H5AC_dxpl_id) < 0)
456 if(H5L_link(&new_loc, new_name, &obj_loc, lcpl_id, lapl_id, dxpl_id) < 0)
452457 HGOTO_ERROR(H5E_OHDR, H5E_CANTINIT, FAIL, "unable to create link")
453458
454459 done:
555560 H5Oexists_by_name(hid_t loc_id, const char *name, hid_t lapl_id)
556561 {
557562 H5G_loc_t loc; /* Location info */
563 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
558564 htri_t ret_value = FAIL; /* Return value */
559565
560566 FUNC_ENTER_API(FAIL)
565571 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a location")
566572 if(!name || !*name)
567573 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name")
568 if(H5P_DEFAULT == lapl_id)
569 lapl_id = H5P_LINK_ACCESS_DEFAULT;
570 else
571 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
572 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
574
575 /* Verify access property list and get correct dxpl */
576 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
577 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
573578
574579 /* Check if the object exists */
575 if((ret_value = H5G_loc_exists(&loc, name, lapl_id, H5AC_ind_dxpl_id)) < 0)
580 if((ret_value = H5G_loc_exists(&loc, name, lapl_id, dxpl_id)) < 0)
576581 HGOTO_ERROR(H5E_OHDR, H5E_CANTGET, FAIL, "unable to determine if '%s' exists", name)
577582
578583 done:
634639 H5Oget_info_by_name(hid_t loc_id, const char *name, H5O_info_t *oinfo, hid_t lapl_id)
635640 {
636641 H5G_loc_t loc; /* Location of group */
642 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
637643 herr_t ret_value = SUCCEED; /* Return value */
638644
639645 FUNC_ENTER_API(FAIL)
646652 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name")
647653 if(!oinfo)
648654 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no info struct")
649 if(H5P_DEFAULT == lapl_id)
650 lapl_id = H5P_LINK_ACCESS_DEFAULT;
651 else
652 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
653 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
655
656 /* Verify access property list and get correct dxpl */
657 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
658 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
654659
655660 /* Retrieve the object's information */
656 if(H5G_loc_info(&loc, name, TRUE, oinfo/*out*/, lapl_id, H5AC_ind_dxpl_id) < 0)
661 if(H5G_loc_info(&loc, name, TRUE, oinfo/*out*/, lapl_id, dxpl_id) < 0)
657662 HGOTO_ERROR(H5E_OHDR, H5E_NOTFOUND, FAIL, "object not found")
658663
659664 done:
684689 H5G_name_t obj_path; /* Opened object group hier. path */
685690 H5O_loc_t obj_oloc; /* Opened object object location */
686691 hbool_t loc_found = FALSE; /* Entry at 'name' found */
692 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
687693 herr_t ret_value = SUCCEED; /* Return value */
688694
689695 FUNC_ENTER_API(FAIL)
701707 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
702708 if(!oinfo)
703709 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no info struct")
704 if(H5P_DEFAULT == lapl_id)
705 lapl_id = H5P_LINK_ACCESS_DEFAULT;
706 else
707 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
708 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
710
711 /* Verify access property list and get correct dxpl */
712 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
713 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
709714
710715 /* Set up opened group location to fill in */
711716 obj_loc.oloc = &obj_oloc;
713718 H5G_loc_reset(&obj_loc);
714719
715720 /* Find the object's location, according to the order in the index */
716 if(H5G_loc_find_by_idx(&loc, group_name, idx_type, order, n, &obj_loc/*out*/, lapl_id, H5AC_ind_dxpl_id) < 0)
721 if(H5G_loc_find_by_idx(&loc, group_name, idx_type, order, n, &obj_loc/*out*/, lapl_id, dxpl_id) < 0)
717722 HGOTO_ERROR(H5E_OHDR, H5E_NOTFOUND, FAIL, "group not found")
718723 loc_found = TRUE;
719724
791796 hid_t lapl_id)
792797 {
793798 H5G_loc_t loc; /* Location of group */
799 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
794800 herr_t ret_value = SUCCEED; /* Return value */
795801
796802 FUNC_ENTER_API(FAIL)
801807 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a location")
802808 if(!name || !*name)
803809 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name")
804 if(H5P_DEFAULT == lapl_id)
805 lapl_id = H5P_LINK_ACCESS_DEFAULT;
806 else
807 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
808 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
810
811 /* Verify access property list and get correct dxpl */
812 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
813 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
809814
810815 /* (Re)set the object's comment */
811 if(H5G_loc_set_comment(&loc, name, comment, lapl_id, H5AC_ind_dxpl_id) < 0)
816 if(H5G_loc_set_comment(&loc, name, comment, lapl_id, dxpl_id) < 0)
812817 HGOTO_ERROR(H5E_OHDR, H5E_NOTFOUND, FAIL, "object not found")
813818
814819 done:
875880 hid_t lapl_id)
876881 {
877882 H5G_loc_t loc; /* Location of group */
883 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
878884 ssize_t ret_value; /* Return value */
879885
880886 FUNC_ENTER_API(FAIL)
885891 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not a location")
886892 if(!name || !*name)
887893 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name")
888 if(H5P_DEFAULT == lapl_id)
889 lapl_id = H5P_LINK_ACCESS_DEFAULT;
890 else
891 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
892 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
894
895 /* Verify access property list and get correct dxpl */
896 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
897 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
893898
894899 /* Retrieve the object's comment */
895 if((ret_value = H5G_loc_get_comment(&loc, name, comment/*out*/, bufsize, lapl_id, H5AC_ind_dxpl_id)) < 0)
900 if((ret_value = H5G_loc_get_comment(&loc, name, comment/*out*/, bufsize, lapl_id, dxpl_id)) < 0)
896901 HGOTO_ERROR(H5E_OHDR, H5E_NOTFOUND, FAIL, "object not found")
897902
898903 done:
994999 H5Ovisit_by_name(hid_t loc_id, const char *obj_name, H5_index_t idx_type,
9951000 H5_iter_order_t order, H5O_iterate_t op, void *op_data, hid_t lapl_id)
9961001 {
1002 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
9971003 herr_t ret_value; /* Return value */
9981004
9991005 FUNC_ENTER_API(FAIL)
10091015 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid iteration order specified")
10101016 if(!op)
10111017 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no callback operator specified")
1012 if(H5P_DEFAULT == lapl_id)
1013 lapl_id = H5P_LINK_ACCESS_DEFAULT;
1014 else
1015 if(TRUE != H5P_isa_class(lapl_id, H5P_LINK_ACCESS))
1016 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not link access property list ID")
1018
1019 /* Verify access property list and get correct dxpl */
1020 if(H5P_verify_and_set_dxpl(&lapl_id, H5P_LINK_ACCESS, H5P_LINK_ACCESS_DEFAULT, &dxpl_id) < 0)
1021 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
10171022
10181023 /* Call internal object visitation routine */
1019 if((ret_value = H5O_visit(loc_id, obj_name, idx_type, order, op, op_data, lapl_id, H5AC_ind_dxpl_id)) < 0)
1024 if((ret_value = H5O_visit(loc_id, obj_name, idx_type, order, op, op_data, lapl_id, dxpl_id)) < 0)
10201025 HGOTO_ERROR(H5E_OHDR, H5E_BADITER, FAIL, "object visitation failed")
10211026
10221027 done:
12771282
12781283 /* Create object header proxy if doing SWMR writes */
12791284 if(H5F_INTENT(f) & H5F_ACC_SWMR_WRITE) {
1280 if(H5O_proxy_create(f, dxpl_id, oh) < 0)
1285 if(H5O__proxy_create(f, dxpl_id, oh) < 0)
12811286 HGOTO_ERROR(H5E_OHDR, H5E_CANTCREATE, FAIL, "can't create object header proxy")
12821287 } /* end if */
12831288 else
14651470 H5G_name_t obj_path; /* Opened object group hier. path */
14661471 H5O_loc_t obj_oloc; /* Opened object object location */
14671472 hbool_t loc_found = FALSE; /* Entry at 'name' found */
1468 hid_t dxpl_id = H5AC_ind_dxpl_id; /* transfer property list used for this operation */
1473 hid_t dxpl_id = H5AC_ind_dxpl_id; /* dxpl used by library */
14691474 hid_t ret_value = FAIL;
14701475
14711476 FUNC_ENTER_NOAPI(FAIL)
37003705 HGOTO_ERROR(H5E_OHDR, H5E_CANTPROTECT, NULL, "unable to protect object header")
37013706
37023707 /* Pin object header proxy */
3703 if(NULL == (proxy = H5O_proxy_pin(loc->file, dxpl_id, oh)))
3708 if(NULL == (proxy = H5O__proxy_pin(loc->file, dxpl_id, oh)))
37043709 HGOTO_ERROR(H5E_OHDR, H5E_CANTPIN, NULL, "unable to pin object header proxy")
37053710
37063711 /* Set the return value */
37123717 HDONE_ERROR(H5E_OHDR, H5E_CANTUNPROTECT, NULL, "unable to release object header")
37133718
37143719 if(!ret_value)
3715 if(proxy && H5O_proxy_unpin(proxy) < 0)
3720 if(proxy && H5O__proxy_unpin(proxy) < 0)
37163721 HDONE_ERROR(H5E_OHDR, H5E_CANTUNPIN, NULL, "unable to release object header proxy")
37173722
37183723 FUNC_LEAVE_NOAPI(ret_value)
37463751 HDassert(oh);
37473752
37483753 /* Pin object header proxy */
3749 if(NULL == (ret_value = H5O_proxy_pin(f, dxpl_id, oh)))
3754 if(NULL == (ret_value = H5O__proxy_pin(f, dxpl_id, oh)))
37503755 HGOTO_ERROR(H5E_OHDR, H5E_CANTPIN, NULL, "unable to pin object header proxy")
37513756
37523757 done:
3753
37543758 FUNC_LEAVE_NOAPI(ret_value)
37553759 } /* end H5O_pin_flush_dep_proxy_oh() */
37563760
37783782 HDassert(proxy);
37793783
37803784 /* Unin object header proxy */
3781 if(H5O_proxy_unpin(proxy) < 0)
3785 if(H5O__proxy_unpin(proxy) < 0)
37823786 HGOTO_ERROR(H5E_OHDR, H5E_CANTUNPIN, FAIL, "unable to unpin object header proxy")
37833787
37843788 done:
466466 /* Create object header proxy if doing SWMR writes */
467467 HDassert(!oh->proxy_present);
468468 if(H5F_INTENT(udata->common.f) & H5F_ACC_SWMR_WRITE) {
469 if(H5O_proxy_create(udata->common.f, udata->common.dxpl_id, oh) < 0)
469 if(H5O__proxy_create(udata->common.f, udata->common.dxpl_id, oh) < 0)
470470 HGOTO_ERROR(H5E_OHDR, H5E_CANTCREATE, NULL, "can't create object header proxy")
471471 } /* end if */
472472 else
11211121
11221122 /* Add flush dependency on object header proxy, if proxy exists */
11231123 if(chk_proxy->oh->proxy_present)
1124 if(H5O_proxy_depend(chk_proxy->f, H5AC_ind_dxpl_id, chk_proxy->oh, chk_proxy) < 0)
1124 if(H5O__proxy_depend(chk_proxy->f, H5AC_ind_dxpl_id, chk_proxy->oh, chk_proxy) < 0)
11251125 HGOTO_ERROR(H5E_OHDR, H5E_CANTDEPEND, FAIL, "can't create flush dependency on object header proxy")
11261126
11271127 case H5AC_NOTIFY_ACTION_AFTER_FLUSH:
409409 if(H5F_INTENT(f) & H5F_ACC_SWMR_WRITE) {
410410 /* Remove flush dependency on object header proxy, if proxy exists */
411411 if(oh->proxy_present)
412 if(H5O_proxy_undepend(f, dxpl_id, oh, chk_proxy) < 0)
412 if(H5O__proxy_undepend(f, dxpl_id, oh, chk_proxy) < 0)
413413 HGOTO_ERROR(H5E_OHDR, H5E_CANTUNDEPEND, FAIL, "can't destroy flush dependency on object header proxy")
414414 } /* end if */
415415 else
474474
475475 /* Create object header proxy if doing SWMR writes */
476476 if(H5F_INTENT(oloc_dst->file) & H5F_ACC_SWMR_WRITE) {
477 if(H5O_proxy_create(oloc_dst->file, dxpl_id, oh_dst) < 0)
477 if(H5O__proxy_create(oloc_dst->file, dxpl_id, oh_dst) < 0)
478478 HGOTO_ERROR(H5E_OHDR, H5E_CANTCREATE, FAIL, "can't create object header proxy")
479479 } /* end if */
480480 else
496496 /* Allocate memory for "deleted" array. This array marks the message in
497497 * the source that shouldn't be copied to the destination.
498498 */
499 if(NULL == (deleted = (hbool_t *)HDmalloc(sizeof(hbool_t) * oh_src->nmesgs)))
499 if(NULL == (deleted = (hbool_t *)H5MM_malloc(sizeof(hbool_t) * oh_src->nmesgs)))
500500 HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed")
501501 HDmemset(deleted, FALSE, sizeof(hbool_t) * oh_src->nmesgs);
502502
903903 done:
904904 /* Free deleted array */
905905 if(deleted)
906 HDfree(deleted);
906 H5MM_free(deleted);
907907
908908 /* Release pointer to source object header and its derived objects */
909909 if(oh_src && H5O_unprotect(oloc_src, dxpl_id, oh_src, H5AC__NO_FLAGS_SET) < 0)
709709 hsize_t *nattrs);
710710
711711 /* Object header proxy operators */
712 H5_DLL herr_t H5O_proxy_create(H5F_t *f, hid_t dxpl_id, H5O_t *oh);
713 H5_DLL H5O_proxy_t *H5O_proxy_pin(H5F_t *f, hid_t dxpl_id, H5O_t *oh);
714 H5_DLL herr_t H5O_proxy_unpin(H5O_proxy_t *proxy);
715 H5_DLL herr_t H5O_proxy_depend(H5F_t *f, hid_t dxpl_id, H5O_t *oh, void *parent);
716 H5_DLL herr_t H5O_proxy_undepend(H5F_t *f, hid_t dxpl_id, H5O_t *oh, void *parent);
712 H5_DLL herr_t H5O__proxy_create(H5F_t *f, hid_t dxpl_id, H5O_t *oh);
713 H5_DLL H5O_proxy_t *H5O__proxy_pin(H5F_t *f, hid_t dxpl_id, H5O_t *oh);
714 H5_DLL herr_t H5O__proxy_unpin(H5O_proxy_t *proxy);
715 H5_DLL herr_t H5O__proxy_depend(H5F_t *f, hid_t dxpl_id, H5O_t *oh, void *parent);
716 H5_DLL herr_t H5O__proxy_undepend(H5F_t *f, hid_t dxpl_id, H5O_t *oh, void *parent);
717717
718718 /* Testing functions */
719719 #ifdef H5O_TESTING
7070 /********************/
7171
7272 /* Metadata cache (H5AC) callbacks */
73 static herr_t H5O__cache_proxy_get_load_size(const void *image, void *udata,
73 static herr_t H5O__proxy_get_load_size(const void *image, void *udata,
7474 size_t *image_len, size_t *actual_len,
7575 hbool_t *compressed_ptr, size_t *compressed_image_len_ptr);
76 static void *H5O__cache_proxy_deserialize(const void *image, size_t len, void *udata, hbool_t *dirty);
77 static herr_t H5O__cache_proxy_image_len(const void *thing, size_t *image_len, hbool_t *compressed_ptr,
76 static void *H5O__proxy_deserialize(const void *image, size_t len, void *udata, hbool_t *dirty);
77 static herr_t H5O__proxy_image_len(const void *thing, size_t *image_len, hbool_t *compressed_ptr,
7878 size_t *compressed_image_len_ptr);
79 static herr_t H5O__cache_proxy_serialize(const H5F_t *f, void *image, size_t len, void *thing);
80 static herr_t H5O__cache_proxy_notify(H5AC_notify_action_t action, void *thing);
81 static herr_t H5O__cache_proxy_free_icr(void *thing);
82
83 static herr_t H5O_proxy_depend_core(void *parent, H5O_proxy_t *proxy);
84 static herr_t H5O__cache_proxy_dest(H5O_proxy_t *proxy);
85 static herr_t H5O_proxy_undepend_core(void *parent, H5O_proxy_t *proxy);
79 static herr_t H5O__proxy_serialize(const H5F_t *f, void *image, size_t len, void *thing);
80 static herr_t H5O__proxy_notify(H5AC_notify_action_t action, void *thing);
81 static herr_t H5O__proxy_free_icr(void *thing);
82
83 /* Helper routines */
84 static herr_t H5O__proxy_depend_core(void *parent, H5O_proxy_t *proxy);
85 static herr_t H5O__proxy_dest(H5O_proxy_t *proxy);
86 static herr_t H5O__proxy_undepend_core(void *parent, H5O_proxy_t *proxy);
8687
8788 /*********************/
8889 /* Package Variables */
9394 "Object header proxy", /* Metadata client name (for debugging) */
9495 H5FD_MEM_OHDR, /* File space memory type for client */
9596 H5AC__CLASS_SKIP_READS|H5AC__CLASS_SKIP_WRITES, /* Client class behavior flags */
96 H5O__cache_proxy_get_load_size, /* 'get_load_size' callback */
97 H5O__proxy_get_load_size, /* 'get_load_size' callback */
9798 NULL, /* 'verify_chksum' callback */
98 H5O__cache_proxy_deserialize, /* 'deserialize' callback */
99 H5O__cache_proxy_image_len, /* 'image_len' callback */
99 H5O__proxy_deserialize, /* 'deserialize' callback */
100 H5O__proxy_image_len, /* 'image_len' callback */
100101 NULL, /* 'pre_serialize' callback */
101 H5O__cache_proxy_serialize, /* 'serialize' callback */
102 H5O__cache_proxy_notify, /* 'notify' callback */
103 H5O__cache_proxy_free_icr, /* 'free_icr' callback */
102 H5O__proxy_serialize, /* 'serialize' callback */
103 H5O__proxy_notify, /* 'notify' callback */
104 H5O__proxy_free_icr, /* 'free_icr' callback */
104105 NULL, /* 'clear' callback */
105106 NULL, /* 'fsf_size' callback */
106107 }};
132133
133134
134135 /*-------------------------------------------------------------------------
135 * Function: H5O__cache_proxy_get_load_size
136 * Function: H5O__proxy_get_load_size
136137 *
137138 * Purpose: Compute the size of the data structure on disk.
138139 *
145146 *-------------------------------------------------------------------------
146147 */
147148 static herr_t
148 H5O__cache_proxy_get_load_size(const void *_image, void H5_ATTR_UNUSED *_udata,
149 H5O__proxy_get_load_size(const void *_image, void H5_ATTR_UNUSED *_udata,
149150 size_t *image_len, size_t H5_ATTR_UNUSED *actual_len,
150151 hbool_t H5_ATTR_UNUSED *compressed_ptr,
151152 size_t H5_ATTR_UNUSED *compressed_image_len_ptr)
161162 /* Set the image length size */
162163 /* Object header proxies are represented as 1 byte in cache */
163164 /* (would be 0 bytes, but cache won't allow it currently. See
164 * H5D_cache_proxy_size) */
165 * H5D_proxy_size) */
165166 *image_len = 1;
166167 }
167168 /* Nothing to do for non-NULL image: no need to compute actual_len */
168169
169170 FUNC_LEAVE_NOAPI(SUCCEED)
170 } /* end H5O__cache_proxy_get_load_size() */
171
172
173 /*-------------------------------------------------------------------------
174 * Function: H5O__cache_proxy_deserialize
171 } /* end H5O__proxy_get_load_size() */
172
173
174 /*-------------------------------------------------------------------------
175 * Function: H5O__proxy_deserialize
175176 *
176177 * Purpose: Creates an object header proxy and creates flush
177178 * dependencies from all object header chunks on this proxy.
185186 *-------------------------------------------------------------------------
186187 */
187188 static void *
188 H5O__cache_proxy_deserialize(const void H5_ATTR_UNUSED *_image, size_t H5_ATTR_UNUSED len, void *_udata,
189 H5O__proxy_deserialize(const void H5_ATTR_UNUSED *_image, size_t H5_ATTR_UNUSED len, void *_udata,
189190 hbool_t H5_ATTR_UNUSED *dirty)
190191 {
191192 H5O_proxy_t *proxy = NULL; /* Object header proxy */
218219
219220 done:
220221 if(!ret_value && proxy)
221 if(H5O__cache_proxy_dest(proxy) < 0)
222 if(H5O__proxy_dest(proxy) < 0)
222223 HDONE_ERROR(H5E_OHDR, H5E_CANTFREE, NULL, "unable to destroy object header proxy")
223224
224225 FUNC_LEAVE_NOAPI(ret_value)
225 } /* end H5O__cache_proxy_deserialize() */
226
227
228 /*-------------------------------------------------------------------------
229 * Function: H5B2__cache_hdr_image_len
226 } /* end H5O__proxy_deserialize() */
227
228
229 /*-------------------------------------------------------------------------
230 * Function: H5O__proxy_image_len
230231 *
231232 * Purpose: Compute the size of the data structure on disk.
232233 *
239240 *-------------------------------------------------------------------------
240241 */
241242 static herr_t
242 H5O__cache_proxy_image_len(const void H5_ATTR_UNUSED *_thing, size_t *image_len,
243 H5O__proxy_image_len(const void H5_ATTR_UNUSED *_thing, size_t *image_len,
243244 hbool_t H5_ATTR_UNUSED *compressed_ptr, size_t H5_ATTR_UNUSED *compressed_image_len_ptr)
244245 {
245246 FUNC_ENTER_STATIC_NOERR
250251 /* Set the image length size */
251252 /* Object header proxies are represented as 1 byte in cache */
252253 /* (would be 0 bytes, but cache won't allow it currently. See
253 * H5D_cache_proxy_size) */
254 * H5D_proxy_size) */
254255 *image_len = 1;
255256
256257 FUNC_LEAVE_NOAPI(SUCCEED)
257 } /* end H5O__cache_proxy_image_len() */
258
259
260 /*-------------------------------------------------------------------------
261 * Function: H5O__cache_proxy_serialize
258 } /* end H5O__proxy_image_len() */
259
260
261 /*-------------------------------------------------------------------------
262 * Function: H5O__proxy_serialize
262263 *
263264 * Purpose: A no-op
264265 *
271272 *-------------------------------------------------------------------------
272273 */
273274 static herr_t
274 H5O__cache_proxy_serialize(const H5F_t H5_ATTR_UNUSED *f, void H5_ATTR_UNUSED *_image, size_t H5_ATTR_UNUSED len,
275 H5O__proxy_serialize(const H5F_t H5_ATTR_UNUSED *f, void H5_ATTR_UNUSED *_image, size_t H5_ATTR_UNUSED len,
275276 void H5_ATTR_UNUSED *_thing)
276277 {
277278 FUNC_ENTER_STATIC_NOERR
279280 /* A no-op */
280281
281282 FUNC_LEAVE_NOAPI(SUCCEED)
282 } /* H5O__cache_proxy_serialize() */
283
284
285 /*-------------------------------------------------------------------------
286 * Function: H5O__cache_proxy_notify
283 } /* H5O__proxy_serialize() */
284
285
286 /*-------------------------------------------------------------------------
287 * Function: H5O__proxy_notify
287288 *
288289 * Purpose: Handle cache action notifications
289290 *
296297 *-------------------------------------------------------------------------
297298 */
298299 static herr_t
299 H5O__cache_proxy_notify(H5AC_notify_action_t action, void *_thing)
300 H5O__proxy_notify(H5AC_notify_action_t action, void *_thing)
300301 {
301302 H5O_proxy_t *proxy = (H5O_proxy_t *)_thing;
302303 H5O_chunk_proxy_t *chk_proxy = NULL; /* Object header chunk proxy */
303 unsigned i; /* Local index variable */
304 unsigned u; /* Local index variable */
304305 herr_t ret_value = SUCCEED; /* Return value */
305306
306 FUNC_ENTER_NOAPI_NOINIT
307 FUNC_ENTER_STATIC
307308
308309 /*
309310 * Check arguments.
317318 case H5AC_NOTIFY_ACTION_AFTER_INSERT:
318319 case H5AC_NOTIFY_ACTION_AFTER_LOAD:
319320 /* Create flush dependency on object header chunk 0 */
320 if(H5O_proxy_depend_core(proxy->oh, proxy) < 0)
321 if(H5O__proxy_depend_core(proxy->oh, proxy) < 0)
321322 HGOTO_ERROR(H5E_OHDR, H5E_CANTDEPEND, FAIL, "unable to create flush dependency")
322323
323324 /* Create flush dependencies on all other object header chunks */
324 for(i = 1; i < proxy->oh->nchunks; i++) {
325 if(NULL == (chk_proxy = H5O_chunk_protect(proxy->f, H5AC_ind_dxpl_id, proxy->oh, i)))
325 for(u = 1; u < proxy->oh->nchunks; u++) {
326 if(NULL == (chk_proxy = H5O_chunk_protect(proxy->f, H5AC_ind_dxpl_id, proxy->oh, u)))
326327 HGOTO_ERROR(H5E_OHDR, H5E_CANTPROTECT, FAIL, "unable to load object header chunk")
327328 /* same as before, but looks backward...need to check into that..(proxy, chk_proxy) */
328 if(H5O_proxy_depend_core(chk_proxy, proxy) < 0)
329 if(H5O__proxy_depend_core(chk_proxy, proxy) < 0)
329330 HGOTO_ERROR(H5E_OHDR, H5E_CANTDEPEND, FAIL, "unable to create flush dependency")
330331 if(H5O_chunk_unprotect(proxy->f, H5AC_ind_dxpl_id, chk_proxy, FALSE) < 0)
331332 HGOTO_ERROR(H5E_OHDR, H5E_CANTUNPROTECT, FAIL, "unable to unprotect object header chunk")
345346 HDassert(proxy->oh_fd_parent_addr != HADDR_UNDEF);
346347 HDassert(proxy->oh_fd_parent_ptr != NULL);
347348
348 if(H5O_proxy_undepend_core(proxy->oh_fd_parent_ptr, proxy) < 0)
349 if(H5O__proxy_undepend_core(proxy->oh_fd_parent_ptr, proxy) < 0)
349350 HGOTO_ERROR(H5E_OHDR, H5E_CANTUNDEPEND, FAIL, "unable to destroy flush dependency with object header")
350351
351 while(proxy->chk_fd_parent_count > 0){
352
353 i = proxy->chk_fd_parent_count - 1;
354
355 if(H5O_proxy_undepend_core(proxy->chk_fd_parent_ptrs[i], proxy)<0)
352 while(proxy->chk_fd_parent_count > 0) {
353 u = proxy->chk_fd_parent_count - 1;
354
355 if(H5O__proxy_undepend_core(proxy->chk_fd_parent_ptrs[u], proxy)<0)
356356 HGOTO_ERROR(H5E_OHDR, H5E_CANTUNDEPEND, FAIL, "unable to destroy flush dependency with object header continuation chunk")
357 }
357 } /* end while */
358358
359359 /* Mark proxy as not present on the object header */
360360 proxy->oh->proxy_present = FALSE;
376376 } /* end if */
377377
378378 FUNC_LEAVE_NOAPI(ret_value)
379
380 } /* end H5O__cache_proxy_notify() */
381
382
383 /*-------------------------------------------------------------------------
384 * Function: H5O__cache_proxy_free_icr
379 } /* end H5O__proxy_notify() */
380
381
382 /*-------------------------------------------------------------------------
383 * Function: H5O__proxy_free_icr
385384 *
386385 * Purpose: Destroy/release an "in core representation" of a data
387386 * structure
394393 *-------------------------------------------------------------------------
395394 */
396395 static herr_t
397 H5O__cache_proxy_free_icr(void *_thing)
396 H5O__proxy_free_icr(void *_thing)
398397 {
399398 H5O_proxy_t *proxy = (H5O_proxy_t *)_thing;
400399 herr_t ret_value = SUCCEED; /* Return value */
401400
402 FUNC_ENTER_NOAPI_NOINIT
403
404 if(H5O__cache_proxy_dest(proxy) < 0)
401 FUNC_ENTER_STATIC
402
403 if(H5O__proxy_dest(proxy) < 0)
405404 HGOTO_ERROR(H5E_OHDR, H5E_CANTFREE, FAIL, "unable to destroy object header proxy")
406405
407406 done:
408407 FUNC_LEAVE_NOAPI(ret_value)
409 } /* H5O__cache_proxy_free_icr() */
410
411
412 /*-------------------------------------------------------------------------
413 * Function: H5O_cache_proxy_dest
408 } /* H5O__proxy_free_icr() */
409
410
411 /*-------------------------------------------------------------------------
412 * Function: H5O_proxy_dest
414413 *
415414 * Purpose: Destroys an object header proxy in memory.
416415 *
422421 *-------------------------------------------------------------------------
423422 */
424423 static herr_t
425 H5O__cache_proxy_dest(H5O_proxy_t *proxy)
424 H5O__proxy_dest(H5O_proxy_t *proxy)
426425 {
427426 herr_t ret_value = SUCCEED; /* Return value */
428427
429 FUNC_ENTER_NOAPI_NOINIT_NOERR
428 FUNC_ENTER_STATIC_NOERR
430429
431430 HDassert(proxy);
432431 HDassert(proxy->oh);
435434 proxy = H5FL_FREE(H5O_proxy_t, proxy);
436435
437436 FUNC_LEAVE_NOAPI(ret_value)
438 } /* end H5O__cache_proxy_dest() */
439
440
441 /*-------------------------------------------------------------------------
442 * Function: H5O_proxy_create
437 } /* end H5O__proxy_dest() */
438
439
440 /*-------------------------------------------------------------------------
441 * Function: H5O__proxy_create
443442 *
444443 * Purpose: Allocate temporary space for the object header proxy. We
445444 * save the actual creation of the proxy to the "load"
458457 *-------------------------------------------------------------------------
459458 */
460459 herr_t
461 H5O_proxy_create(H5F_t *f, hid_t H5_ATTR_UNUSED dxpl_id, H5O_t *oh)
460 H5O__proxy_create(H5F_t *f, hid_t H5_ATTR_UNUSED dxpl_id, H5O_t *oh)
462461 {
463462 herr_t ret_value = SUCCEED; /* Return value */
464463
465 FUNC_ENTER_NOAPI(FAIL)
464 FUNC_ENTER_PACKAGE
466465
467466 HDassert(f);
468467 HDassert(oh);
473472
474473 done:
475474 FUNC_LEAVE_NOAPI(ret_value)
476 } /* end H5O_proxy_create() */
477
478
479 /*-------------------------------------------------------------------------
480 * Function: H5O_proxy_pin
475 } /* end H5O__proxy_create() */
476
477
478 /*-------------------------------------------------------------------------
479 * Function: H5O__proxy_pin
481480 *
482481 * Purpose: Returns the proxy object for the specified object header,
483482 * pinned. This proxy can be used as a flush dependency
492491 *-------------------------------------------------------------------------
493492 */
494493 H5O_proxy_t *
495 H5O_proxy_pin(H5F_t *f, hid_t dxpl_id, H5O_t *oh)
494 H5O__proxy_pin(H5F_t *f, hid_t dxpl_id, H5O_t *oh)
496495 {
497496 H5O_proxy_t *proxy = NULL; /* Object header proxy */
498497 H5O_proxy_cache_ud_t udata; /* User-data for callback */
499498 H5O_proxy_t *ret_value = NULL; /* Return value */
500499
501 FUNC_ENTER_NOAPI_NOINIT
500 FUNC_ENTER_PACKAGE
502501
503502 HDassert(f);
504503 HDassert(oh);
526525 } /* end if */
527526
528527 FUNC_LEAVE_NOAPI(ret_value)
529 } /* end H5O_proxy_pin() */
530
531
532 /*-------------------------------------------------------------------------
533 * Function: H5O_proxy_unpin
528 } /* end H5O__proxy_pin() */
529
530
531 /*-------------------------------------------------------------------------
532 * Function: H5O__proxy_unpin
534533 *
535534 * Purpose: Unpins the specified object header proxy from the cache.
536535 *
542541 *-------------------------------------------------------------------------
543542 */
544543 herr_t
545 H5O_proxy_unpin(H5O_proxy_t *proxy)
544 H5O__proxy_unpin(H5O_proxy_t *proxy)
546545 {
547546 herr_t ret_value = SUCCEED; /* Return value */
548547
549 FUNC_ENTER_NOAPI_NOINIT
548 FUNC_ENTER_PACKAGE
550549
551550 HDassert(proxy);
552551
556555
557556 done:
558557 FUNC_LEAVE_NOAPI(ret_value)
559 } /* end H5O_proxy_unpin() */
560
561
562 /*-------------------------------------------------------------------------
563 * Function: H5O_proxy_depend
558 } /* end H5O__proxy_unpin() */
559
560
561 /*-------------------------------------------------------------------------
562 * Function: H5O__proxy_depend
564563 *
565564 * Purpose: Creates a flush dependency between the object header proxy
566565 * (as child) and the specified object (as parent).
573572 *-------------------------------------------------------------------------
574573 */
575574 herr_t
576 H5O_proxy_depend(H5F_t *f, hid_t dxpl_id, H5O_t *oh, void *parent)
575 H5O__proxy_depend(H5F_t *f, hid_t dxpl_id, H5O_t *oh, void *parent)
577576 {
578577 H5O_proxy_t *proxy = NULL; /* Object header proxy */
579578 H5O_proxy_cache_ud_t udata; /* User-data for callback */
580579 herr_t ret_value = SUCCEED; /* Return value */
581580
582 FUNC_ENTER_NOAPI_NOINIT
581 FUNC_ENTER_PACKAGE
583582
584583 HDassert(f);
585584 HDassert(oh);
586585
587586 HDassert(H5F_addr_defined(oh->proxy_addr));
588587 HDassert(parent);
589 HDassert(((H5C_cache_entry_t *)parent)->magic ==
590 H5C__H5C_CACHE_ENTRY_T_MAGIC);
588 HDassert(((H5C_cache_entry_t *)parent)->magic == H5C__H5C_CACHE_ENTRY_T_MAGIC);
591589 HDassert(((H5C_cache_entry_t *)parent)->type);
592590 HDassert((((H5C_cache_entry_t *)(parent))->type->id == H5AC_OHDR_ID) ||
593591 (((H5C_cache_entry_t *)(parent))->type->id == H5AC_OHDR_CHK_ID));
594592
593 /* Protect the object header proxy */
595594 udata.f = f;
596595 udata.oh = oh;
597 /* Protect the object header proxy */
598596 if(NULL == (proxy = (H5O_proxy_t *)H5AC_protect(f, dxpl_id, H5AC_OHDR_PROXY, oh->proxy_addr, &udata, H5AC__READ_ONLY_FLAG)))
599597 HGOTO_ERROR(H5E_OHDR, H5E_CANTPROTECT, FAIL, "unable to protect object header proxy");
600598
601599 /* Add the flush dependency on the parent object */
602 if(H5O_proxy_depend_core(parent, proxy) < 0)
600 if(H5O__proxy_depend_core(parent, proxy) < 0)
603601 HGOTO_ERROR(H5E_OHDR, H5E_CANTDEPEND, FAIL, "unable to create flush dependency")
604602
605603 /* Unprotect the object header proxy */
608606 proxy = NULL;
609607
610608 done:
611 if(proxy) {
612 HDassert(ret_value < 0);
613 if(H5AC_unprotect(f, dxpl_id, H5AC_OHDR_PROXY, oh->proxy_addr, proxy, H5AC__NO_FLAGS_SET) < 0)
614 HDONE_ERROR(H5E_OHDR, H5E_CANTUNPROTECT, FAIL, "unable to unprotect object header proxy");
615 } /* end if */
616
617 FUNC_LEAVE_NOAPI(ret_value)
618 } /* end H5O_proxy_depend() */
619
620
621
622 /*-------------------------------------------------------------------------
623 * Function: H5O_proxy_depend_core
609 if(proxy && H5AC_unprotect(f, dxpl_id, H5AC_OHDR_PROXY, oh->proxy_addr, proxy, H5AC__NO_FLAGS_SET) < 0)
610 HDONE_ERROR(H5E_OHDR, H5E_CANTUNPROTECT, FAIL, "unable to unprotect object header proxy")
611
612 FUNC_LEAVE_NOAPI(ret_value)
613 } /* end H5O__proxy_depend() */
614
615
616 /*-------------------------------------------------------------------------
617 * Function: H5O__proxy_depend_core
624618 *
625619 * Purpose: Creates a flush dependency between the object header proxy
626620 * (as child) and the specified object (as parent).
641635 *-------------------------------------------------------------------------
642636 */
643637 static herr_t
644 H5O_proxy_depend_core(void *parent, H5O_proxy_t *proxy)
638 H5O__proxy_depend_core(void *parent, H5O_proxy_t *proxy)
645639 {
646640 herr_t ret_value = SUCCEED; /* Return value */
647641
648 FUNC_ENTER_NOAPI_NOINIT
642 FUNC_ENTER_STATIC
649643
650644 HDassert(parent);
651645 HDassert(((H5C_cache_entry_t *)parent)->magic ==
728722 }
729723
730724 done:
731
732 FUNC_LEAVE_NOAPI(ret_value)
733
734 } /* end H5O_proxy_depend_core() */
735
736
737
738 /*-------------------------------------------------------------------------
739 * Function: H5O_proxy_undepend
725 FUNC_LEAVE_NOAPI(ret_value)
726 } /* end H5O__proxy_depend_core() */
727
728
729 /*-------------------------------------------------------------------------
730 * Function: H5O__proxy_undepend
740731 *
741732 * Purpose: Destroys the flush dependency between the object header
742733 * proxy (as child) and the specified object (as parent).
753744 *-------------------------------------------------------------------------
754745 */
755746 herr_t
756 H5O_proxy_undepend(H5F_t *f, hid_t dxpl_id, H5O_t *oh, void *parent)
747 H5O__proxy_undepend(H5F_t *f, hid_t dxpl_id, H5O_t *oh, void *parent)
757748 {
758749 H5O_proxy_t *proxy = NULL; /* Object header proxy */
759750 H5O_proxy_cache_ud_t udata; /* User-data for callback */
760751 herr_t ret_value = SUCCEED; /* Return value */
761752
762 FUNC_ENTER_NOAPI_NOINIT
763
753 FUNC_ENTER_PACKAGE
754
755 /* Sanity checks */
764756 HDassert(f);
765757 HDassert(oh);
766758 HDassert(H5F_addr_defined(oh->proxy_addr));
767759 HDassert(parent);
768760
761 /* Protect the object header proxy */
769762 udata.f = f;
770763 udata.oh = oh;
771 /* Protect the object header proxy */
772764 if(NULL == (proxy = (H5O_proxy_t *)H5AC_protect(f, dxpl_id, H5AC_OHDR_PROXY, oh->proxy_addr, &udata, H5AC__READ_ONLY_FLAG)))
773765 HGOTO_ERROR(H5E_OHDR, H5E_CANTPROTECT, FAIL, "unable to protect object header proxy");
774766
775 /* destroy the flush dependency on the parent object */
776 if(H5O_proxy_undepend_core(parent, proxy) < 0)
767 /* Destroy the flush dependency on the parent object */
768 if(H5O__proxy_undepend_core(parent, proxy) < 0)
777769 HGOTO_ERROR(H5E_OHDR, H5E_CANTUNDEPEND, FAIL, "unable to destroy flush dependency")
778770
779771 /* Unprotect the object header proxy */
782774 proxy = NULL;
783775
784776 done:
785 if(proxy) {
786 HDassert(ret_value < 0);
787 if(H5AC_unprotect(f, dxpl_id, H5AC_OHDR_PROXY, oh->proxy_addr, proxy, H5AC__NO_FLAGS_SET) < 0)
788 HDONE_ERROR(H5E_OHDR, H5E_CANTUNPROTECT, FAIL, "unable to unprotect object header proxy");
789 } /* end if */
790
791 FUNC_LEAVE_NOAPI(ret_value)
792 } /* end H5O_proxy_undepend() */
793
794
795
796 /*-------------------------------------------------------------------------
797 * Function: H5O_proxy_undepend_core
777 if(proxy && H5AC_unprotect(f, dxpl_id, H5AC_OHDR_PROXY, oh->proxy_addr, proxy, H5AC__NO_FLAGS_SET) < 0)
778 HDONE_ERROR(H5E_OHDR, H5E_CANTUNPROTECT, FAIL, "unable to unprotect object header proxy");
779
780 FUNC_LEAVE_NOAPI(ret_value)
781 } /* end H5O__proxy_undepend() */
782
783
784 /*-------------------------------------------------------------------------
785 * Function: H5O__proxy_undepend_core
798786 *
799787 * Purpose: Destroys the flush dependency between the object header
800788 * proxy (as child) and the specified object (as parent).
817805 *-------------------------------------------------------------------------
818806 */
819807 static herr_t
820 H5O_proxy_undepend_core(void *parent, H5O_proxy_t *proxy)
821 {
822 unsigned i;
808 H5O__proxy_undepend_core(void *parent, H5O_proxy_t *proxy)
809 {
810 unsigned u; /* Local index variable */
823811 herr_t ret_value = SUCCEED; /* Return value */
824812
825 FUNC_ENTER_NOAPI_NOINIT
813 FUNC_ENTER_STATIC
826814
827815 HDassert(parent);
828816
829817 #ifndef NDEBUG
830 /* do sanity checks */
818 /* Sanity checks */
831819 HDassert(parent);
832 HDassert(((H5C_cache_entry_t *)parent)->magic ==
833 H5C__H5C_CACHE_ENTRY_T_MAGIC);
820 HDassert(((H5C_cache_entry_t *)parent)->magic == H5C__H5C_CACHE_ENTRY_T_MAGIC);
834821 HDassert(((H5C_cache_entry_t *)parent)->type);
835822 HDassert((((H5C_cache_entry_t *)(parent))->type->id == H5AC_OHDR_ID) ||
836823 (((H5C_cache_entry_t *)(parent))->type->id == H5AC_OHDR_CHK_ID));
837824
838825 if ( (((H5C_cache_entry_t *)(parent))->type->id == H5AC_OHDR_ID) ) {
839
840826 HDassert(proxy->oh_fd_parent_addr != HADDR_UNDEF);
841827 HDassert(proxy->oh_fd_parent_ptr != NULL);
842 HDassert(proxy->oh_fd_parent_addr ==
843 (((H5C_cache_entry_t *)(parent))->addr));
828 HDassert(proxy->oh_fd_parent_addr == (((H5C_cache_entry_t *)(parent))->addr));
844829 HDassert(proxy->oh_fd_parent_ptr == parent);
845
846 } else {
847
830 } /* end if */
831 else {
848832 hbool_t found = FALSE;
849833
850834 HDassert(proxy->chk_fd_parent_alloc > 0);
852836 HDassert(proxy->chk_fd_parent_addrs);
853837 HDassert(proxy->chk_fd_parent_ptrs);
854838
855 for( i = 0; i < proxy->chk_fd_parent_count; i++ ) {
856
857 if ( proxy->chk_fd_parent_ptrs[i] == parent ) {
858
839 for(u = 0; u < proxy->chk_fd_parent_count; u++)
840 if(proxy->chk_fd_parent_ptrs[u] == parent) {
859841 found = TRUE;
860842 break;
861 }
862 }
843 } /* end if */
863844
864845 HDassert(found);
865 HDassert(proxy->chk_fd_parent_addrs[i] ==
866 (((H5C_cache_entry_t *)(parent))->addr));
867 }
846 HDassert(proxy->chk_fd_parent_addrs[u] == (((H5C_cache_entry_t *)(parent))->addr));
847 } /* end else */
868848 #endif /* NDEBUG */
869849
870 /* destroy the flush dependency on the parent object */
850 /* Destroy the flush dependency on the parent object */
871851 if(H5AC_destroy_flush_dependency(parent, proxy) < 0)
872852 HGOTO_ERROR(H5E_OHDR, H5E_CANTUNDEPEND, FAIL, "unable to destroy flush dependency")
873853
874 /* delete parent from object header's list of parents */
875 if ( (((H5C_cache_entry_t *)(parent))->type->id == H5AC_OHDR_ID) ) {
876
854 /* Delete parent from object header's list of parents */
855 if((((H5C_cache_entry_t *)(parent))->type->id == H5AC_OHDR_ID)) {
877856 proxy->oh_fd_parent_addr = HADDR_UNDEF;
878857 proxy->oh_fd_parent_ptr = NULL;
879
880 } else {
881
882 /* find parent in parent ptrs array */
883 for ( i = 0; i < proxy->chk_fd_parent_count; i++ ) {
884
885 if ( proxy->chk_fd_parent_ptrs[i] == parent ) {
886
858 } /* end if */
859 else {
860 /* Find parent in parent ptrs array */
861 for(u = 0; u < proxy->chk_fd_parent_count; u++)
862 if(proxy->chk_fd_parent_ptrs[u] == parent)
887863 break;
888 }
889 }
890
891 if ( i == proxy->chk_fd_parent_count )
892
864 if(u == proxy->chk_fd_parent_count)
893865 HGOTO_ERROR(H5E_OHDR, H5E_CANTUNDEPEND, FAIL, "Parent entry isn't in chunk fd parent list")
894866
895867 /* Remove parent entry from chunk fd parent ptr and addr lists */
896 if ( i < proxy->chk_fd_parent_count - 1 ) {
897
898 HDmemmove(&proxy->chk_fd_parent_addrs[i],
899 &proxy->chk_fd_parent_addrs[i+1],
900 (proxy->chk_fd_parent_count - i - 1)
901 * sizeof(proxy->chk_fd_parent_addrs[0]));
902
903 HDmemmove(&proxy->chk_fd_parent_ptrs[i],
904 &proxy->chk_fd_parent_ptrs[i+1],
905 (proxy->chk_fd_parent_count - i - 1)
906 * sizeof(proxy->chk_fd_parent_ptrs[0]));
907 }
868 if(u < proxy->chk_fd_parent_count - 1) {
869 HDmemmove(&proxy->chk_fd_parent_addrs[u],
870 &proxy->chk_fd_parent_addrs[u + 1],
871 (proxy->chk_fd_parent_count - u - 1) * sizeof(proxy->chk_fd_parent_addrs[0]));
872
873 HDmemmove(&proxy->chk_fd_parent_ptrs[u],
874 &proxy->chk_fd_parent_ptrs[u + 1],
875 (proxy->chk_fd_parent_count - u - 1) * sizeof(proxy->chk_fd_parent_ptrs[0]));
876 } /* end if */
908877
909878 proxy->chk_fd_parent_count--;
910879
911880 /* shrink or free the fd parent ptr and addr lists as appropriate */
912 if( proxy->chk_fd_parent_count == 0 ) {
913
914 proxy->chk_fd_parent_addrs = (haddr_t *)
915 H5FL_BLK_FREE(parent_addr, proxy->chk_fd_parent_addrs);
916
917 proxy->chk_fd_parent_ptrs = (void **)
918 H5FL_BLK_FREE(parent_ptr, proxy->chk_fd_parent_ptrs);
919
881 if(proxy->chk_fd_parent_count == 0) {
882 proxy->chk_fd_parent_addrs = (haddr_t *)H5FL_BLK_FREE(parent_addr, proxy->chk_fd_parent_addrs);
883 proxy->chk_fd_parent_ptrs = (void **)H5FL_BLK_FREE(parent_ptr, proxy->chk_fd_parent_ptrs);
920884 proxy->chk_fd_parent_alloc = 0;
921
922 }
923 else if ( ( proxy->chk_fd_parent_count > H5O_FD_PAR_LIST_BASE ) &&
924 ( proxy->chk_fd_parent_count <=
925 (proxy->chk_fd_parent_alloc / 4) ) ) {
926
927 if ( NULL == (proxy->chk_fd_parent_addrs = (haddr_t *)
928 H5FL_BLK_REALLOC(parent_addr, proxy->chk_fd_parent_addrs,
929 (proxy->chk_fd_parent_alloc / 4) *
930 sizeof(haddr_t))) )
931
885 } /* end if */
886 else if((proxy->chk_fd_parent_count > H5O_FD_PAR_LIST_BASE) &&
887 (proxy->chk_fd_parent_count <= (proxy->chk_fd_parent_alloc / 4))) {
888 if(NULL == (proxy->chk_fd_parent_addrs = (haddr_t *)H5FL_BLK_REALLOC(parent_addr, proxy->chk_fd_parent_addrs, (proxy->chk_fd_parent_alloc / 4) * sizeof(haddr_t))))
932889 HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory reallocation failed for chk fd parent addr list")
933
934 if ( NULL == (proxy->chk_fd_parent_ptrs = (void **)
935 H5FL_BLK_REALLOC(parent_ptr, proxy->chk_fd_parent_ptrs,
936 (proxy->chk_fd_parent_alloc / 4) *
937 sizeof(void *))) )
938
890 if(NULL == (proxy->chk_fd_parent_ptrs = (void **)H5FL_BLK_REALLOC(parent_ptr, proxy->chk_fd_parent_ptrs, (proxy->chk_fd_parent_alloc / 4) * sizeof(void *))))
939891 HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory reallocation failed for chk fd parent ptr list")
940
941892 proxy->chk_fd_parent_alloc /= 4;
942
943893 } /* end if */
944 }
894 } /* end else */
945895
946896 done:
947
948 FUNC_LEAVE_NOAPI(ret_value)
949
950 } /* end H5O_proxy_undepend_core() */
951
897 FUNC_LEAVE_NOAPI(ret_value)
898 } /* end H5O__proxy_undepend_core() */
899
412412 */
413413 origin_dl_path = HDgetenv("HDF5_PLUGIN_PATH");
414414 if(NULL == origin_dl_path)
415 dl_path = HDstrdup(H5PL_DEFAULT_PATH);
415 dl_path = H5MM_strdup(H5PL_DEFAULT_PATH);
416416 else
417 dl_path = HDstrdup(origin_dl_path);
417 dl_path = H5MM_strdup(origin_dl_path);
418418 if(NULL == dl_path)
419419 HGOTO_ERROR(H5E_PLUGIN, H5E_CANTALLOC, FAIL, "can't allocate memory for path")
420420
424424 /* Check for too many directories in path */
425425 if(H5PL_num_paths_g == H5PL_MAX_PATH_NUM)
426426 HGOTO_ERROR(H5E_PLUGIN, H5E_NOSPACE, FAIL, "too many directories in path for table")
427 if(NULL == (H5PL_path_table_g[H5PL_num_paths_g] = HDstrdup(dir)))
427 if(NULL == (H5PL_path_table_g[H5PL_num_paths_g] = H5MM_strdup(dir)))
428428 HGOTO_ERROR(H5E_PLUGIN, H5E_CANTALLOC, FAIL, "can't allocate memory for path")
429429 H5PL_num_paths_g++;
430430 dir = HDstrtok(NULL, H5PL_PATH_SEPARATOR);
22262226 HDmemset(ent, 0, sizeof(H5O_storage_virtual_ent_t)); /* Clear before starting to set up */
22272227 if(NULL == (ent->source_dset.virtual_select = H5S_copy(vspace, FALSE, TRUE)))
22282228 HGOTO_ERROR(H5E_PLIST, H5E_CANTCOPY, FAIL, "unable to copy virtual selection")
2229 if(NULL == (ent->source_file_name = HDstrdup(src_file_name)))
2229 if(NULL == (ent->source_file_name = H5MM_xstrdup(src_file_name)))
22302230 HGOTO_ERROR(H5E_PLIST, H5E_RESOURCE, FAIL, "can't duplicate source file name")
2231 if(NULL == (ent->source_dset_name = HDstrdup(src_dset_name)))
2231 if(NULL == (ent->source_dset_name = H5MM_xstrdup(src_dset_name)))
22322232 HGOTO_ERROR(H5E_PLIST, H5E_RESOURCE, FAIL, "can't duplicate source file name")
22332233 if(NULL == (ent->source_select = H5S_copy(src_space, FALSE, TRUE)))
22342234 HGOTO_ERROR(H5E_PLIST, H5E_CANTCOPY, FAIL, "unable to copy source selection")
175175 #define H5AC_XFER_RING_ENC H5P__encode_unsigned
176176 #define H5AC_XFER_RING_DEC H5P__decode_unsigned
177177
178 /* Definition for reading metadata collectively */
179 #define H5D_XFER_COLL_MD_READ_SIZE sizeof(H5P_coll_md_read_flag_t)
180 #define H5D_XFER_COLL_MD_READ_DEF H5P_USER_FALSE
181 #define H5D_XFER_COLL_MD_READ_ENC H5P__encode_coll_md_read_flag_t
182 #define H5D_XFER_COLL_MD_READ_DEC H5P__decode_coll_md_read_flag_t
183
178184 /******************/
179185 /* Local Typedefs */
180186 /******************/
279285 static const uint32_t H5D_def_direct_chunk_filters_g = H5D_XFER_DIRECT_CHUNK_WRITE_FILTERS_DEF; /* Default value for the filters of direct chunk write */
280286 static const hsize_t *H5D_def_direct_chunk_offset_g = H5D_XFER_DIRECT_CHUNK_WRITE_OFFSET_DEF; /* Default value for the offset of direct chunk write */
281287 static const uint32_t H5D_def_direct_chunk_datasize_g = H5D_XFER_DIRECT_CHUNK_WRITE_DATASIZE_DEF; /* Default value for the datasize of direct chunk write */
288 static const H5P_coll_md_read_flag_t H5D_def_coll_md_read_g = H5D_XFER_COLL_MD_READ_DEF; /* Default setting for the collective metedata read flag */
282289 static const H5AC_ring_t H5D_ring_g = H5AC_XFER_RING_DEF; /* Default value for the cache entry ring type */
283290
284291
473480 NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL) < 0)
474481 HGOTO_ERROR(H5E_PLIST, H5E_CANTINSERT, FAIL, "can't insert property into class")
475482
476 /* Register the data transform property */
483 /* Register the metadata collective read flag */
484 if(H5P_register_real(pclass, H5_COLL_MD_READ_FLAG_NAME, H5D_XFER_COLL_MD_READ_SIZE,
485 &H5D_def_coll_md_read_g,
486 NULL, NULL, NULL, H5D_XFER_COLL_MD_READ_ENC, H5D_XFER_COLL_MD_READ_DEC,
487 NULL, NULL, NULL, NULL) < 0)
488 HGOTO_ERROR(H5E_PLIST, H5E_CANTINSERT, FAIL, "can't insert property into class")
489
490 /* Register the ring property (private) */
477491 if(H5P_register_real(pclass, H5AC_RING_NAME, H5AC_XFER_RING_SIZE, &H5D_ring_g,
478492 NULL, NULL, NULL, H5AC_XFER_RING_ENC, H5AC_XFER_RING_DEC,
479493 NULL, NULL, NULL, NULL) < 0)
207207 #define H5F_ACS_START_MDC_LOG_ON_ACCESS_DEF FALSE
208208 #define H5F_ACS_START_MDC_LOG_ON_ACCESS_ENC H5P__encode_hbool_t
209209 #define H5F_ACS_START_MDC_LOG_ON_ACCESS_DEC H5P__decode_hbool_t
210
210 /* Definition of collective metadata read mode flag */
211 #define H5F_ACS_COLL_MD_READ_FLAG_SIZE sizeof(H5P_coll_md_read_flag_t)
212 #define H5F_ACS_COLL_MD_READ_FLAG_DEF H5P_USER_FALSE
213 #define H5F_ACS_COLL_MD_READ_FLAG_ENC H5P__encode_coll_md_read_flag_t
214 #define H5F_ACS_COLL_MD_READ_FLAG_DEC H5P__decode_coll_md_read_flag_t
215 /* Definition of collective metadata write mode flag */
216 #define H5F_ACS_COLL_MD_WRITE_FLAG_SIZE sizeof(hbool_t)
217 #define H5F_ACS_COLL_MD_WRITE_FLAG_DEF FALSE
218 #define H5F_ACS_COLL_MD_WRITE_FLAG_ENC H5P__encode_hbool_t
219 #define H5F_ACS_COLL_MD_WRITE_FLAG_DEC H5P__decode_hbool_t
211220
212221 /******************/
213222 /* Local Typedefs */
324333 static const hbool_t H5F_def_use_mdc_logging_g = H5F_ACS_USE_MDC_LOGGING_DEF; /* Default metadata cache logging flag */
325334 static const char *H5F_def_mdc_log_location_g = H5F_ACS_MDC_LOG_LOCATION_DEF; /* Default mdc log location */
326335 static const hbool_t H5F_def_start_mdc_log_on_access_g = H5F_ACS_START_MDC_LOG_ON_ACCESS_DEF; /* Default mdc log start on access flag */
327
336 static const H5P_coll_md_read_flag_t H5F_def_coll_md_read_flag_g = H5F_ACS_COLL_MD_READ_FLAG_DEF; /* Default setting for the collective metedata read flag */
337 static const hbool_t H5F_def_coll_md_write_flag_g = H5F_ACS_COLL_MD_WRITE_FLAG_DEF; /* Default setting for the collective metedata write flag */
328338
329339
330340 /*-------------------------------------------------------------------------
512522 /* Register the flag that indicates whether mdc logging starts on file access. */
513523 if(H5P_register_real(pclass, H5F_ACS_START_MDC_LOG_ON_ACCESS_NAME, H5F_ACS_START_MDC_LOG_ON_ACCESS_SIZE, &H5F_def_start_mdc_log_on_access_g,
514524 NULL, NULL, NULL, H5F_ACS_START_MDC_LOG_ON_ACCESS_ENC, H5F_ACS_START_MDC_LOG_ON_ACCESS_DEC, NULL, NULL, NULL, NULL) < 0)
525 HGOTO_ERROR(H5E_PLIST, H5E_CANTINSERT, FAIL, "can't insert property into class")
526
527 /* Register the metadata collective read flag */
528 if(H5P_register_real(pclass, H5_COLL_MD_READ_FLAG_NAME, H5F_ACS_COLL_MD_READ_FLAG_SIZE,
529 &H5F_def_coll_md_read_flag_g,
530 NULL, NULL, NULL, H5F_ACS_COLL_MD_READ_FLAG_ENC, H5F_ACS_COLL_MD_READ_FLAG_DEC,
531 NULL, NULL, NULL, NULL) < 0)
532 HGOTO_ERROR(H5E_PLIST, H5E_CANTINSERT, FAIL, "can't insert property into class")
533
534 /* Register the metadata collective write flag */
535 if(H5P_register_real(pclass, H5F_ACS_COLL_MD_WRITE_FLAG_NAME, H5F_ACS_COLL_MD_WRITE_FLAG_SIZE,
536 &H5F_def_coll_md_write_flag_g,
537 NULL, NULL, NULL, H5F_ACS_COLL_MD_WRITE_FLAG_ENC, H5F_ACS_COLL_MD_WRITE_FLAG_DEC,
538 NULL, NULL, NULL, NULL) < 0)
515539 HGOTO_ERROR(H5E_PLIST, H5E_CANTINSERT, FAIL, "can't insert property into class")
516540
517541 done:
40254049 FUNC_LEAVE_NOAPI(SUCCEED)
40264050 } /* end H5P_facc_mdc_log_location_close() */
40274051
4052
4053 /*-------------------------------------------------------------------------
4054 * Function: H5P__encode_coll_md_read_flag_t
4055 *
4056 * Purpose: Generic encoding callback routine for 'coll_md_read_flag' properties.
4057 *
4058 * Return: Success: Non-negative
4059 * Failure: Negative
4060 *
4061 * Programmer: Mohamad Chaarawi
4062 *
4063 *-------------------------------------------------------------------------
4064 */
4065 herr_t
4066 H5P__encode_coll_md_read_flag_t(const void *value, void **_pp, size_t *size)
4067 {
4068 const H5P_coll_md_read_flag_t *coll_md_read_flag = (const H5P_coll_md_read_flag_t *)value;
4069 uint8_t **pp = (uint8_t **)_pp;
4070
4071 FUNC_ENTER_PACKAGE_NOERR
4072
4073 /* Sanity checks */
4074 HDassert(coll_md_read_flag);
4075 HDassert(size);
4076
4077 if(NULL != *pp) {
4078 /* Encode the value */
4079 HDmemcpy(*pp, coll_md_read_flag, sizeof(H5P_coll_md_read_flag_t));
4080 *pp += sizeof(H5P_coll_md_read_flag_t);
4081 } /* end if */
4082
4083 /* Set size needed for encoding */
4084 *size += sizeof(H5P_coll_md_read_flag_t);
4085
4086 FUNC_LEAVE_NOAPI(SUCCEED)
4087 } /* end H5P__encode_coll_md_read_flag_t() */
4088
4089
4090 /*-------------------------------------------------------------------------
4091 * Function: H5P__decode_coll_md_read_flag_t
4092 *
4093 * Purpose: Generic decoding callback routine for 'coll_md_read_flag' properties.
4094 *
4095 * Return: Success: Non-negative
4096 * Failure: Negative
4097 *
4098 * Programmer: Mohamad Chaarawi
4099 *
4100 *-------------------------------------------------------------------------
4101 */
4102 herr_t
4103 H5P__decode_coll_md_read_flag_t(const void **_pp, void *_value)
4104 {
4105 H5P_coll_md_read_flag_t *coll_md_read_flag = (H5P_coll_md_read_flag_t *)_value; /* File close degree */
4106 const uint8_t **pp = (const uint8_t **)_pp;
4107
4108 FUNC_ENTER_STATIC_NOERR
4109
4110 /* Sanity checks */
4111 HDassert(pp);
4112 HDassert(*pp);
4113 HDassert(coll_md_read_flag);
4114
4115 /* Decode file close degree */
4116 *coll_md_read_flag = (H5P_coll_md_read_flag_t)*(*pp);
4117 *pp += sizeof(H5P_coll_md_read_flag_t);
4118
4119 FUNC_LEAVE_NOAPI(SUCCEED)
4120 } /* end H5P__decode_coll_md_read_flag_t() */
4121
4122 #ifdef H5_HAVE_PARALLEL
4123
4124 /*-------------------------------------------------------------------------
4125 * Function: H5Pset_coll_metadata_read
4126 *
4127 * Purpose: Tell the library whether the metadata read operations will
4128 * be done collectively (1) or not (0). Default is independent. With
4129 * collective mode, the library will optimize access to metdata
4130 * operations on the file.
4131 *
4132 * Return: Non-negative on success/Negative on failure
4133 *
4134 *-------------------------------------------------------------------------
4135 */
4136 herr_t
4137 H5Pset_coll_metadata_read(hid_t plist_id, hbool_t is_collective)
4138 {
4139 H5P_genplist_t *plist; /* Property list pointer */
4140 herr_t ret_value = SUCCEED; /* return value */
4141
4142 FUNC_ENTER_API(FAIL)
4143 H5TRACE2("e", "ib", plist_id, is_collective);
4144
4145 /* Compare the property list's class against the other class */
4146 if(TRUE != H5P_isa_class(plist_id, H5P_LINK_ACCESS) &&
4147 TRUE != H5P_isa_class(plist_id, H5P_FILE_ACCESS) &&
4148 TRUE != H5P_isa_class(plist_id, H5P_DATASET_XFER))
4149 HGOTO_ERROR(H5E_PLIST, H5E_CANTREGISTER, FAIL, "property list is not an access plist")
4150
4151 /* set property to either TRUE if > 0, or FALSE otherwise */
4152 if(is_collective > 0)
4153 is_collective = TRUE;
4154 else
4155 is_collective = FALSE;
4156
4157 /* Get the plist structure */
4158 if(NULL == (plist = (H5P_genplist_t *)H5I_object(plist_id)))
4159 HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "can't find object for ID")
4160
4161 /* Set values */
4162 if(H5P_set(plist, H5_COLL_MD_READ_FLAG_NAME, &is_collective) < 0)
4163 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set collective metadata read flag")
4164
4165 done:
4166 FUNC_LEAVE_API(ret_value)
4167 } /* H5Pset_coll_metadata_read */
4168
4169
4170 /*-------------------------------------------------------------------------
4171 * Function: H5Pget_coll_metadata_read
4172 *
4173 * Purpose: Gets information about collective metadata read mode.
4174 *
4175 * Return: Non-negative on success/Negative on failure
4176 *
4177 *-------------------------------------------------------------------------
4178 */
4179 herr_t
4180 H5Pget_coll_metadata_read(hid_t plist_id, hbool_t *is_collective)
4181 {
4182 herr_t ret_value = SUCCEED; /* return value */
4183
4184 FUNC_ENTER_API(FAIL)
4185 H5TRACE2("e", "i*b", plist_id, is_collective);
4186
4187 /* Compare the property list's class against the other class */
4188 if(TRUE != H5P_isa_class(plist_id, H5P_LINK_ACCESS) &&
4189 TRUE != H5P_isa_class(plist_id, H5P_FILE_ACCESS) &&
4190 TRUE != H5P_isa_class(plist_id, H5P_DATASET_XFER))
4191 HGOTO_ERROR(H5E_PLIST, H5E_CANTREGISTER, FAIL, "property list is not an access plist")
4192
4193 /* Get value */
4194 if(is_collective) {
4195 H5P_coll_md_read_flag_t internal_flag; /* property setting. we need to convert to either TRUE or FALSE */
4196 H5P_genplist_t *plist; /* Property list pointer */
4197
4198 /* Get the plist structure */
4199 if(NULL == (plist = (H5P_genplist_t *)H5I_object(plist_id)))
4200 HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "can't find object for ID")
4201
4202 if(H5P_get(plist, H5_COLL_MD_READ_FLAG_NAME, &internal_flag) < 0)
4203 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't get core collective metadata read flag")
4204
4205 if(internal_flag < 0)
4206 *is_collective = FALSE;
4207 else
4208 *is_collective = (hbool_t)internal_flag;
4209 } /* end if */
4210
4211 done:
4212 FUNC_LEAVE_API(ret_value)
4213 } /* H5Pget_coll_metadata_read */
4214
4215
4216 /*-------------------------------------------------------------------------
4217 * Function: H5Pset_coll_metadata_write
4218 *
4219 * Purpose: Tell the library whether the metadata write operations will
4220 * be done collectively (1) or not (0). Default is collective.
4221 *
4222 * Return: Non-negative on success/Negative on failure
4223 *
4224 *-------------------------------------------------------------------------
4225 */
4226 herr_t
4227 H5Pset_coll_metadata_write(hid_t plist_id, hbool_t is_collective)
4228 {
4229 H5P_genplist_t *plist; /* Property list pointer */
4230 herr_t ret_value = SUCCEED; /* return value */
4231
4232 FUNC_ENTER_API(FAIL)
4233 H5TRACE2("e", "ib", plist_id, is_collective);
4234
4235 /* Compare the property list's class against the other class */
4236 if(TRUE != H5P_isa_class(plist_id, H5P_FILE_ACCESS))
4237 HGOTO_ERROR(H5E_PLIST, H5E_CANTREGISTER, FAIL, "property list is not a file access plist")
4238
4239 /* Get the plist structure */
4240 if(NULL == (plist = (H5P_genplist_t *)H5I_object(plist_id)))
4241 HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "can't find object for ID")
4242
4243 /* Set values */
4244 if(H5P_set(plist, H5F_ACS_COLL_MD_WRITE_FLAG_NAME, &is_collective) < 0)
4245 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set collective metadata write flag")
4246
4247 done:
4248 FUNC_LEAVE_API(ret_value)
4249 } /* H5Pset_coll_metadata_write */
4250
4251
4252 /*-------------------------------------------------------------------------
4253 * Function: H5Pget_coll_metadata_write
4254 *
4255 * Purpose: Gets information about collective metadata write mode.
4256 *
4257 * Return: Non-negative on success/Negative on failure
4258 *
4259 *-------------------------------------------------------------------------
4260 */
4261 herr_t
4262 H5Pget_coll_metadata_write(hid_t plist_id, hbool_t *is_collective)
4263 {
4264 H5P_genplist_t *plist; /* Property list pointer */
4265 herr_t ret_value = SUCCEED; /* return value */
4266
4267 FUNC_ENTER_API(FAIL)
4268 H5TRACE2("e", "i*b", plist_id, is_collective);
4269
4270 /* Compare the property list's class against the other class */
4271 if(TRUE != H5P_isa_class(plist_id, H5P_FILE_ACCESS))
4272 HGOTO_ERROR(H5E_PLIST, H5E_CANTREGISTER, FAIL, "property list is not an access plist")
4273
4274 /* Get the plist structure */
4275 if(NULL == (plist = (H5P_genplist_t *)H5I_object(plist_id)))
4276 HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "can't find object for ID")
4277
4278 if(H5P_get(plist, H5F_ACS_COLL_MD_WRITE_FLAG_NAME, is_collective) < 0)
4279 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't get collective metadata write flag")
4280
4281 done:
4282 FUNC_LEAVE_API(ret_value)
4283 } /* H5Pget_coll_metadata_write */
4284
4285 #endif /* H5_HAVE_PARALLEL */
2828 /* Headers */
2929 /***********/
3030 #include "H5private.h" /* Generic Functions */
31 #include "H5ACprivate.h" /* Metadata cache */
3132 #include "H5Eprivate.h" /* Error handling */
3233 #include "H5FLprivate.h" /* Free lists */
3334 #include "H5Iprivate.h" /* IDs */
138139 H5P_genclass_t *H5P_CLS_DATATYPE_ACCESS_g = NULL;
139140 hid_t H5P_CLS_ATTRIBUTE_CREATE_ID_g = FAIL;
140141 H5P_genclass_t *H5P_CLS_ATTRIBUTE_CREATE_g = NULL;
142 hid_t H5P_CLS_ATTRIBUTE_ACCESS_ID_g = FAIL;
143 H5P_genclass_t *H5P_CLS_ATTRIBUTE_ACCESS_g = NULL;
141144 hid_t H5P_CLS_OBJECT_COPY_ID_g = FAIL;
142145 H5P_genclass_t *H5P_CLS_OBJECT_COPY_g = NULL;
143146 hid_t H5P_CLS_LINK_CREATE_ID_g = FAIL;
162165 hid_t H5P_LST_DATATYPE_CREATE_ID_g = FAIL;
163166 hid_t H5P_LST_DATATYPE_ACCESS_ID_g = FAIL;
164167 hid_t H5P_LST_ATTRIBUTE_CREATE_ID_g = FAIL;
168 hid_t H5P_LST_ATTRIBUTE_ACCESS_ID_g = FAIL;
165169 hid_t H5P_LST_OBJECT_COPY_ID_g = FAIL;
166170 hid_t H5P_LST_LINK_CREATE_ID_g = FAIL;
167171 hid_t H5P_LST_LINK_ACCESS_ID_g = FAIL;
175179 &H5P_CLS_ROOT_g, /* Pointer to class */
176180 &H5P_CLS_ROOT_ID_g, /* Pointer to class ID */
177181 NULL, /* Pointer to default property list ID */
182 NULL, /* Default property registration routine */
183
184 NULL, /* Class creation callback */
185 NULL, /* Class creation callback info */
186 NULL, /* Class copy callback */
187 NULL, /* Class copy callback info */
188 NULL, /* Class close callback */
189 NULL /* Class close callback info */
190 }};
191
192 /* Attribute access property list class library initialization object */
193 /* (move to proper source code file when used for real) */
194 const H5P_libclass_t H5P_CLS_AACC[1] = {{
195 "attribute access", /* Class name for debugging */
196 H5P_TYPE_ATTRIBUTE_ACCESS, /* Class type */
197
198 &H5P_CLS_LINK_ACCESS_g, /* Parent class */
199 &H5P_CLS_ATTRIBUTE_ACCESS_g, /* Pointer to class */
200 &H5P_CLS_ATTRIBUTE_ACCESS_ID_g, /* Pointer to class ID */
201 &H5P_LST_ATTRIBUTE_ACCESS_ID_g, /* Pointer to default property list ID */
178202 NULL, /* Default property registration routine */
179203
180204 NULL, /* Class creation callback */
296320 H5P_CLS_TCRT, /* Datatype creation */
297321 H5P_CLS_TACC, /* Datatype access */
298322 H5P_CLS_ACRT, /* Attribute creation */
323 H5P_CLS_AACC, /* Attribute access */
299324 H5P_CLS_LCRT /* Link creation */
300325 };
301326
486511 H5P_LST_DATATYPE_CREATE_ID_g =
487512 H5P_LST_DATATYPE_ACCESS_ID_g =
488513 H5P_LST_ATTRIBUTE_CREATE_ID_g =
514 H5P_LST_ATTRIBUTE_ACCESS_ID_g =
489515 H5P_LST_OBJECT_COPY_ID_g =
490516 H5P_LST_LINK_CREATE_ID_g =
491517 H5P_LST_LINK_ACCESS_ID_g =
512538 H5P_CLS_DATATYPE_ACCESS_g =
513539 H5P_CLS_STRING_CREATE_g =
514540 H5P_CLS_ATTRIBUTE_CREATE_g =
541 H5P_CLS_ATTRIBUTE_ACCESS_g =
515542 H5P_CLS_OBJECT_COPY_g =
516543 H5P_CLS_LINK_CREATE_g =
517544 H5P_CLS_LINK_ACCESS_g =
530557 H5P_CLS_DATATYPE_ACCESS_ID_g =
531558 H5P_CLS_STRING_CREATE_ID_g =
532559 H5P_CLS_ATTRIBUTE_CREATE_ID_g =
560 H5P_CLS_ATTRIBUTE_ACCESS_ID_g =
533561 H5P_CLS_OBJECT_COPY_ID_g =
534562 H5P_CLS_LINK_CREATE_ID_g =
535563 H5P_CLS_LINK_ACCESS_ID_g =
11861214
11871215 /* Check if the property has been deleted from list */
11881216 if(H5SL_search(plist->del,name) != NULL) {
1189 HGOTO_ERROR(H5E_PLIST, H5E_NOTFOUND, NULL, "can't find property in skip list")
1217 HGOTO_ERROR(H5E_PLIST, H5E_NOTFOUND, NULL, "property deleted from skip list")
11901218 } /* end if */
11911219 else {
11921220 /* Get the property data from the skip list */
52525280 FUNC_ENTER_PACKAGE
52535281
52545282 /* Sanity checks */
5255 HDcompile_assert(H5P_TYPE_LINK_ACCESS == (H5P_TYPE_MAX_TYPE - 1));
5283 HDcompile_assert(H5P_TYPE_ATTRIBUTE_ACCESS == (H5P_TYPE_MAX_TYPE - 1));
52565284 HDassert(type >= H5P_TYPE_USER && type <= H5P_TYPE_LINK_ACCESS);
52575285
52585286 /* Check arguments */
53135341
53145342 case H5P_TYPE_ATTRIBUTE_CREATE:
53155343 class_id = H5P_CLS_ATTRIBUTE_CREATE_ID_g;
5344 break;
5345
5346 case H5P_TYPE_ATTRIBUTE_ACCESS:
5347 class_id = H5P_CLS_ATTRIBUTE_ACCESS_ID_g;
53165348 break;
53175349
53185350 case H5P_TYPE_OBJECT_COPY:
54025434 FUNC_LEAVE_NOAPI(plist->pclass)
54035435 } /* end H5P_get_class() */
54045436
5437 herr_t
5438 H5P_verify_and_set_dxpl(hid_t *acspl_id, hid_t pclass_id, hid_t default_id, hid_t *dxpl_id)
5439 {
5440 herr_t ret_value = SUCCEED; /* Return value */
5441
5442 FUNC_ENTER_NOAPI_NOINIT
5443
5444 HDassert(acspl_id);
5445
5446 /* Check the access property list */
5447 if(H5P_DEFAULT == *acspl_id)
5448 *acspl_id = default_id;
5449
5450 if(TRUE != H5P_isa_class(*acspl_id, pclass_id))
5451 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "Not the required access property list")
5452
5453 if(dxpl_id) {
5454 H5P_coll_md_read_flag_t is_collective;
5455 H5P_genplist_t *plist; /* Property list pointer */
5456
5457 /* Get the plist structure */
5458 if(NULL == (plist = (H5P_genplist_t *)H5I_object_verify(*acspl_id, H5I_GENPROP_LST)))
5459 HGOTO_ERROR(H5E_ATOM, H5E_BADATOM, FAIL, "can't find object for ID")
5460
5461 if(H5P_get(plist, H5_COLL_MD_READ_FLAG_NAME, &is_collective) < 0)
5462 HGOTO_ERROR(H5E_PLIST, H5E_CANTGET, FAIL, "can't get core collective metadata read flag")
5463
5464 if(TRUE == is_collective && *dxpl_id == H5AC_dxpl_id)
5465 *dxpl_id = H5AC_coll_write_coll_read_dxpl_id;
5466 else if(TRUE == is_collective && *dxpl_id == H5AC_ind_dxpl_id)
5467 *dxpl_id = H5AC_ind_write_coll_read_dxpl_id;
5468 }
5469
5470 done:
5471 FUNC_LEAVE_NOAPI(ret_value)
5472 } /* end H5P_verify_and_set_dxpl */
8787 #define H5L_ACS_ELINK_CB_SIZE sizeof(H5L_elink_cb_t)
8888 #define H5L_ACS_ELINK_CB_DEF {NULL,NULL}
8989
90 /* Definition for reading metadata collectively */
91 #define H5L_ACS_COLL_MD_READ_SIZE sizeof(H5P_coll_md_read_flag_t)
92 #define H5L_ACS_COLL_MD_READ_DEF H5P_USER_FALSE
93 #define H5L_ACS_COLL_MD_READ_ENC H5P__encode_coll_md_read_flag_t
94 #define H5L_ACS_COLL_MD_READ_DEC H5P__decode_coll_md_read_flag_t
9095
9196 /******************/
9297 /* Local Typedefs */
163168 static const hid_t H5L_def_fapl_id_g = H5L_ACS_ELINK_FAPL_DEF; /* Default fapl for external link access */
164169 static const unsigned H5L_def_elink_flags_g = H5L_ACS_ELINK_FLAGS_DEF; /* Default file access flags for external link traversal */
165170 static const H5L_elink_cb_t H5L_def_elink_cb_g = H5L_ACS_ELINK_CB_DEF; /* Default external link traversal callback */
166
171 static const H5P_coll_md_read_flag_t H5L_def_coll_md_read_g = H5L_ACS_COLL_MD_READ_DEF; /* Default setting for the collective metedata read flag */
167172
168173
169174 /*-------------------------------------------------------------------------
214219 if(H5P_register_real(pclass, H5L_ACS_ELINK_CB_NAME, H5L_ACS_ELINK_CB_SIZE, &H5L_def_elink_cb_g,
215220 NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL) < 0)
216221 HGOTO_ERROR(H5E_PLIST, H5E_CANTINSERT, FAIL, "can't insert property into class")
222
223 /* Register the metadata collective read flag */
224 if(H5P_register_real(pclass, H5_COLL_MD_READ_FLAG_NAME, H5L_ACS_COLL_MD_READ_SIZE,
225 &H5L_def_coll_md_read_g,
226 NULL, NULL, NULL, H5L_ACS_COLL_MD_READ_ENC, H5L_ACS_COLL_MD_READ_DEC,
227 NULL, NULL, NULL, NULL) < 0)
228 HGOTO_ERROR(H5E_PLIST, H5E_CANTINSERT, FAIL, "can't insert property into class")
217229
218230 done:
219231 FUNC_LEAVE_NOAPI(ret_value)
218218 H5_DLL herr_t H5P__decode_uint8_t(const void **_pp, void *value);
219219 H5_DLL herr_t H5P__decode_hbool_t(const void **_pp, void *value);
220220 H5_DLL herr_t H5P__decode_double(const void **_pp, void *value);
221 H5_DLL herr_t H5P__encode_coll_md_read_flag_t(const void *value, void **_pp, size_t *size);
222 H5_DLL herr_t H5P__decode_coll_md_read_flag_t(const void **_pp, void *value);
221223
222224 /* Private OCPL routines */
223225 H5_DLL herr_t H5P_get_filter(const struct H5Z_filter_info_t *filter,
4545 /* Library Private Typedefs */
4646 /****************************/
4747
48 #define H5_COLL_MD_READ_FLAG_NAME "collective_metadata_read"
49
50 typedef enum H5P_coll_md_read_flag_t {
51 H5P_FORCE_FALSE = -1,
52 H5P_USER_FALSE = 0,
53 H5P_USER_TRUE = 1
54 } H5P_coll_md_read_flag_t;
55
4856 /* Forward declarations (for prototypes & type definitions) */
4957 struct H5O_fill_t;
5058 struct H5T_t;
7280 H5P_TYPE_OBJECT_COPY = 15,
7381 H5P_TYPE_LINK_CREATE = 16,
7482 H5P_TYPE_LINK_ACCESS = 17,
83 H5P_TYPE_ATTRIBUTE_ACCESS = 18,
7584 H5P_TYPE_MAX_TYPE
7685 } H5P_plist_type_t;
7786
93102 H5_DLLVAR H5P_genclass_t *H5P_CLS_DATATYPE_CREATE_g;
94103 H5_DLLVAR H5P_genclass_t *H5P_CLS_DATATYPE_ACCESS_g;
95104 H5_DLLVAR H5P_genclass_t *H5P_CLS_ATTRIBUTE_CREATE_g;
105 H5_DLLVAR H5P_genclass_t *H5P_CLS_ATTRIBUTE_ACCESS_g;
96106 H5_DLLVAR H5P_genclass_t *H5P_CLS_OBJECT_COPY_g;
97107 H5_DLLVAR H5P_genclass_t *H5P_CLS_LINK_CREATE_g;
98108 H5_DLLVAR H5P_genclass_t *H5P_CLS_LINK_ACCESS_g;
163173 H5_DLL herr_t H5P_get_fill_value(H5P_genplist_t *plist, const struct H5T_t *type,
164174 void *value, hid_t dxpl_id);
165175
176 H5_DLL herr_t H5P_verify_and_set_dxpl(hid_t *acspl_id, hid_t pclass_id, hid_t default_id, hid_t *dxpl_id);
166177 #endif /* _H5Pprivate_H */
167178
6565 #define H5P_DATATYPE_ACCESS (H5OPEN H5P_CLS_DATATYPE_ACCESS_ID_g)
6666 #define H5P_STRING_CREATE (H5OPEN H5P_CLS_STRING_CREATE_ID_g)
6767 #define H5P_ATTRIBUTE_CREATE (H5OPEN H5P_CLS_ATTRIBUTE_CREATE_ID_g)
68 #define H5P_ATTRIBUTE_ACCESS (H5OPEN H5P_CLS_ATTRIBUTE_ACCESS_ID_g)
6869 #define H5P_OBJECT_COPY (H5OPEN H5P_CLS_OBJECT_COPY_ID_g)
6970 #define H5P_LINK_CREATE (H5OPEN H5P_CLS_LINK_CREATE_ID_g)
7071 #define H5P_LINK_ACCESS (H5OPEN H5P_CLS_LINK_ACCESS_ID_g)
8384 #define H5P_DATATYPE_CREATE_DEFAULT (H5OPEN H5P_LST_DATATYPE_CREATE_ID_g)
8485 #define H5P_DATATYPE_ACCESS_DEFAULT (H5OPEN H5P_LST_DATATYPE_ACCESS_ID_g)
8586 #define H5P_ATTRIBUTE_CREATE_DEFAULT (H5OPEN H5P_LST_ATTRIBUTE_CREATE_ID_g)
87 #define H5P_ATTRIBUTE_ACCESS_DEFAULT (H5OPEN H5P_LST_ATTRIBUTE_ACCESS_ID_g)
8688 #define H5P_OBJECT_COPY_DEFAULT (H5OPEN H5P_LST_OBJECT_COPY_ID_g)
8789 #define H5P_LINK_CREATE_DEFAULT (H5OPEN H5P_LST_LINK_CREATE_ID_g)
8890 #define H5P_LINK_ACCESS_DEFAULT (H5OPEN H5P_LST_LINK_ACCESS_ID_g)
188190 H5_DLLVAR hid_t H5P_CLS_DATATYPE_ACCESS_ID_g;
189191 H5_DLLVAR hid_t H5P_CLS_STRING_CREATE_ID_g;
190192 H5_DLLVAR hid_t H5P_CLS_ATTRIBUTE_CREATE_ID_g;
193 H5_DLLVAR hid_t H5P_CLS_ATTRIBUTE_ACCESS_ID_g;
191194 H5_DLLVAR hid_t H5P_CLS_OBJECT_COPY_ID_g;
192195 H5_DLLVAR hid_t H5P_CLS_LINK_CREATE_ID_g;
193196 H5_DLLVAR hid_t H5P_CLS_LINK_ACCESS_ID_g;
205208 H5_DLLVAR hid_t H5P_LST_DATATYPE_CREATE_ID_g;
206209 H5_DLLVAR hid_t H5P_LST_DATATYPE_ACCESS_ID_g;
207210 H5_DLLVAR hid_t H5P_LST_ATTRIBUTE_CREATE_ID_g;
211 H5_DLLVAR hid_t H5P_LST_ATTRIBUTE_ACCESS_ID_g;
208212 H5_DLLVAR hid_t H5P_LST_OBJECT_COPY_ID_g;
209213 H5_DLLVAR hid_t H5P_LST_LINK_CREATE_ID_g;
210214 H5_DLLVAR hid_t H5P_LST_LINK_ACCESS_ID_g;
352356 H5_DLL herr_t H5Pget_object_flush_cb(hid_t plist_id, H5F_flush_cb_t *func, void **udata);
353357 H5_DLL herr_t H5Pset_mdc_log_options(hid_t plist_id, hbool_t is_enabled, const char *location, hbool_t start_on_access);
354358 H5_DLL herr_t H5Pget_mdc_log_options(hid_t plist_id, hbool_t *is_enabled, char *location, size_t *location_size, hbool_t *start_on_access);
359 #ifdef H5_HAVE_PARALLEL
360 H5_DLL herr_t H5Pset_coll_metadata_read(hid_t plist_id, hbool_t is_collective);
361 H5_DLL herr_t H5Pget_coll_metadata_read(hid_t plist_id, hbool_t *is_collective);
362 H5_DLL herr_t H5Pset_coll_metadata_write(hid_t plist_id, hbool_t is_collective);
363 H5_DLL herr_t H5Pget_coll_metadata_write(hid_t plist_id, hbool_t *is_collective);
364 #endif /* H5_HAVE_PARALLEL */
355365
356366 /* Dataset creation property list (DCPL) routines */
357367 H5_DLL herr_t H5Pset_layout(hid_t plist_id, H5D_layout_t layout);
54655465
54665466
54675467 /*-------------------------------------------------------------------------
5468 * Function: H5T_patch_vlen_file
5469 *
5470 * Purpose: Patch the top-level file pointer contained in (dt->shared->u.vlen.f)
5471 * to point to f. This is possible because
5472 * the top-level file pointer can be closed out from under
5473 * dt while dt is contained in the shared file's cache.
5474 *
5475 * Return: SUCCEED
5476 *
5477 *-------------------------------------------------------------------------
5478 */
5479 herr_t
5480 H5T_patch_vlen_file(H5T_t *dt, H5F_t *f)
5481 {
5482 FUNC_ENTER_NOAPI_NOINIT_NOERR
5483
5484 /* Sanity check */
5485 HDassert(dt);
5486 HDassert(dt->shared);
5487 HDassert(f);
5488
5489 if((dt->shared->type == H5T_VLEN) && dt->shared->u.vlen.f != f)
5490 dt->shared->u.vlen.f = f;
5491
5492 FUNC_LEAVE_NOAPI(SUCCEED)
5493 } /* end H5T_patch_vlen_file() */
5494
5495
5496 /*-------------------------------------------------------------------------
54685497 * Function: H5Tflush
54695498 *
54705499 * Purpose: Flushes all buffers associated with a named datatype to disk.
9898 {
9999 H5G_loc_t loc; /* Location to create datatype */
100100 H5T_t *type; /* Datatype for ID */
101 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
101102 herr_t ret_value = SUCCEED; /* Return value */
102103
103104 FUNC_ENTER_API(FAIL)
125126 if(TRUE != H5P_isa_class(tcpl_id, H5P_DATATYPE_CREATE))
126127 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not datatype creation property list")
127128
128 /* Get correct property list */
129 if(H5P_DEFAULT == tapl_id)
130 tapl_id = H5P_DATATYPE_ACCESS_DEFAULT;
131 else
132 if(TRUE != H5P_isa_class(tapl_id, H5P_DATATYPE_ACCESS))
133 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not datatype access property list")
129 /* Verify access property list and get correct dxpl */
130 if(H5P_verify_and_set_dxpl(&tapl_id, H5P_DATATYPE_ACCESS, H5P_DATATYPE_ACCESS_DEFAULT, &dxpl_id) < 0)
131 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
134132
135133 /* Commit the type */
136 if(H5T__commit_named(&loc, name, type, lcpl_id, tcpl_id, tapl_id, H5AC_dxpl_id) < 0)
134 if(H5T__commit_named(&loc, name, type, lcpl_id, tcpl_id, tapl_id, dxpl_id) < 0)
137135 HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "unable to commit datatype")
138136
139137 done:
247245 {
248246 H5G_loc_t loc; /* Group location for location */
249247 H5T_t *type = NULL; /* Datatype created */
248 hid_t dxpl_id = H5AC_dxpl_id; /* dxpl used by library */
250249 herr_t ret_value = SUCCEED; /* Return value */
251250
252251 FUNC_ENTER_API(FAIL)
265264 if(TRUE != H5P_isa_class(tcpl_id, H5P_DATATYPE_CREATE))
266265 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not datatype creation property list")
267266
268 /* Get correct property list */
269 if(H5P_DEFAULT == tapl_id)
270 tapl_id = H5P_DATATYPE_ACCESS_DEFAULT;
271 else
272 if(TRUE != H5P_isa_class(tapl_id, H5P_DATATYPE_ACCESS))
273 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not datatype access property list")
267 /* Verify access property list and get correct dxpl */
268 if(H5P_verify_and_set_dxpl(&tapl_id, H5P_DATATYPE_ACCESS, H5P_DATATYPE_ACCESS_DEFAULT, &dxpl_id) < 0)
269 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
274270
275271 /* Commit the type */
276 if(H5T__commit(loc.oloc->file, type, tcpl_id, H5AC_dxpl_id) < 0)
272 if(H5T__commit(loc.oloc->file, type, tcpl_id, dxpl_id) < 0)
277273 HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "unable to commit datatype")
278274
279275 /* Release the datatype's object header */
285281 HGOTO_ERROR(H5E_DATATYPE, H5E_CANTGET, FAIL, "unable to get object location of committed datatype")
286282
287283 /* Decrement refcount on committed datatype's object header in memory */
288 if(H5O_dec_rc_by_loc(oloc, H5AC_dxpl_id) < 0)
284 if(H5O_dec_rc_by_loc(oloc, dxpl_id) < 0)
289285 HGOTO_ERROR(H5E_DATATYPE, H5E_CANTDEC, FAIL, "unable to decrement refcount on newly created object")
290286 } /* end if */
291287
544540 if(!name || !*name)
545541 HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "no name")
546542
547 /* Get correct property list */
548 if(H5P_DEFAULT == tapl_id)
549 tapl_id = H5P_DATATYPE_ACCESS_DEFAULT;
550 else
551 if(TRUE != H5P_isa_class(tapl_id, H5P_DATATYPE_ACCESS))
552 HGOTO_ERROR(H5E_ARGS, H5E_BADTYPE, FAIL, "not datatype access property list")
543 /* Verify access property list and get correct dxpl */
544 if(H5P_verify_and_set_dxpl(&tapl_id, H5P_DATATYPE_ACCESS, H5P_DATATYPE_ACCESS_DEFAULT, &dxpl_id) < 0)
545 HGOTO_ERROR(H5E_PLIST, H5E_CANTSET, FAIL, "can't set access and transfer property lists")
553546
554547 /* Set up datatype location to fill in */
555548 type_loc.oloc = &oloc;
422422 with special algorithm. */
423423 #undef LONG_TO_LDOUBLE_SPECIAL
424424
425 /* Define to the sub-directory in which libtool stores uninstalled libraries.
426 */
425 /* Define to the sub-directory where libtool stores uninstalled libraries. */
427426 #undef LT_OBJDIR
428427
429428 /* Define if the metadata trace file code is to be compiled in */
9494 #define H5_VERS_MAJOR 1 /* For major interface/format changes */
9595 #define H5_VERS_MINOR 10 /* For minor interface/format changes */
9696 #define H5_VERS_RELEASE 0 /* For tweaks, bug-fixes, or development */
97 #define H5_VERS_SUBRELEASE "alpha0" /* For pre-releases like snap0 */
97 #define H5_VERS_SUBRELEASE "alpha1" /* For pre-releases like snap0 */
9898 /* Empty string for real releases. */
99 #define H5_VERS_INFO "HDF5 library version: 1.10.0-alpha0" /* Full version string */
99 #define H5_VERS_INFO "HDF5 library version: 1.10.0-alpha1" /* Full version string */
100100
101101 #define H5check() H5check_version(H5_VERS_MAJOR,H5_VERS_MINOR, \
102102 H5_VERS_RELEASE)
641641 LN_S = @LN_S@
642642 LTLIBOBJS = @LTLIBOBJS@
643643 LT_STATIC_EXEC = @LT_STATIC_EXEC@
644 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
644645 MAINT = @MAINT@
645646 MAKEINFO = @MAKEINFO@
646647 MANIFEST_TOOL = @MANIFEST_TOOL@
817818 # After making changes, run bin/reconfigure to update other configure related
818819 # files like Makefile.in.
819820 LT_VERS_INTERFACE = 100
820 LT_VERS_REVISION = 900
821 LT_VERS_REVISION = 0
821822 LT_VERS_AGE = 0
822823
823824 # Our main target, the HDF5 library
10591059 LN_S = @LN_S@
10601060 LTLIBOBJS = @LTLIBOBJS@
10611061 LT_STATIC_EXEC = @LT_STATIC_EXEC@
1062 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
10621063 MAINT = @MAINT@
10631064 MAKEINFO = @MAKEINFO@
10641065 MANIFEST_TOOL = @MANIFEST_TOOL@
8080 void *outbuf = NULL; /* Pointer to new buffer */
8181 unsigned char *dst; /* Temporary pointer to destination buffer */
8282
83 dst = (unsigned char *)(outbuf = malloc(nbytes + SUFFIX_LEN));
83 dst = (unsigned char *)(outbuf = H5allocate_memory(nbytes + SUFFIX_LEN, 0));
8484
8585 /* Copy raw data */
8686 memcpy((void*)dst, (void*)(*buf), nbytes);
9090 memcpy(dst, (void*)GROUP_SUFFIX, SUFFIX_LEN);
9191
9292 /* Free input buffer */
93 free(*buf);
93 H5free_memory(*buf);
9494
9595 /* Set return values */
9696 *buf_size = nbytes + SUFFIX_LEN;
497497 if(err_num != 0) TEST_ERROR
498498
499499 /* Push an error with a long description */
500 if(H5Epush(estack_id, __FILE__, err_func, __LINE__, ERR_CLS, ERR_MAJ_TEST, ERR_MIN_SUBROUTINE, err_msg) < 0) TEST_ERROR;
500 if(H5Epush(estack_id, __FILE__, err_func, __LINE__, ERR_CLS, ERR_MAJ_TEST, ERR_MIN_SUBROUTINE, "%s", err_msg) < 0) TEST_ERROR;
501501
502502 /* Check the number of errors on stack */
503503 err_num = H5Eget_num(estack_id);
542542 herr_t ret; /* Generic return value */
543543
544544 /* Push an error with a long description */
545 if(H5Epush(H5E_DEFAULT, __FILE__, err_func, __LINE__, ERR_CLS, ERR_MAJ_TEST, ERR_MIN_SUBROUTINE, err_msg) < 0) TEST_ERROR;
545 if(H5Epush(H5E_DEFAULT, __FILE__, err_func, __LINE__, ERR_CLS, ERR_MAJ_TEST, ERR_MIN_SUBROUTINE, "%s", err_msg) < 0) TEST_ERROR;
546546
547547 /* Check the number of errors on stack */
548548 err_num = H5Eget_num(H5E_DEFAULT);
2525
2626 #include "hdf5.h"
2727
28 #define FILENAME "tarray1.h5"
29 #define TESTFILE "tarrold.h5"
28 #define FILENAME "tarray1.h5"
29 #define TESTFILE "tarrold.h5"
3030
3131 /* 1-D array datatype */
32 #define ARRAY1_RANK 1
33 #define ARRAY1_DIM1 4
32 #define ARRAY1_RANK 1
33 #define ARRAY1_DIM1 4
3434
3535 /* 3-D array datatype */
36 #define ARRAY2_RANK 3
37 #define ARRAY2_DIM1 3
38 #define ARRAY2_DIM2 4
39 #define ARRAY2_DIM3 5
36 #define ARRAY2_RANK 3
37 #define ARRAY2_DIM1 3
38 #define ARRAY2_DIM2 4
39 #define ARRAY2_DIM3 5
4040
4141 /* 2-D array datatype */
42 #define ARRAY3_RANK 2
43 #define ARRAY3_DIM1 6
44 #define ARRAY3_DIM2 3
42 #define ARRAY3_RANK 2
43 #define ARRAY3_DIM1 6
44 #define ARRAY3_DIM2 3
4545
4646 /* 1-D dataset with fixed dimensions */
47 #define SPACE1_RANK 1
48 #define SPACE1_DIM1 4
49
50 /****************************************************************
51 **
52 ** test_array_atomic_1d(): Test basic array datatype code.
53 ** Tests 1-D array of atomic datatypes
54 **
55 ****************************************************************/
47 #define SPACE1_RANK 1
48 #define SPACE1_DIM1 4
49
50 /* Parameters used with the test_array_bkg() test */
51 #define FIELDNAME "ArrayofStructures"
52 #define LENGTH 5
53 #define ALEN 10
54 #define RANK 1
55 #define NMAX 100
56
57 /* Struct used with test_array_bkg() test */
58 typedef struct
59 {
60 int nsubfields;
61 char *name[NMAX];
62 size_t offset[NMAX];
63 hid_t datatype[NMAX];
64
65 } CmpDTSinfo;
66
67 /* Forward declarations for custom vlen memory manager functions */
68 void *test_array_alloc_custom(size_t size, void *info);
69 void test_array_free_custom(void *mem, void *info);
70
71
72 /*-------------------------------------------------------------------------
73 * Function: test_array_atomic_1d
74 *
75 * Purpose: Test basic array datatype code.
76 * Tests 1-D array of atomic datatypes.
77 *
78 * Return: void
79 *
80 *-------------------------------------------------------------------------
81 */
5682 static void
5783 test_array_atomic_1d(void)
5884 {
59 int wdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information to write */
60 int rdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information read in */
61 hid_t fid1; /* HDF5 File IDs */
62 hid_t dataset; /* Dataset ID */
63 hid_t sid1; /* Dataspace ID */
64 hid_t tid1; /* Datatype ID */
65 hsize_t sdims1[] = {SPACE1_DIM1};
66 hsize_t tdims1[] = {ARRAY1_DIM1};
67 int ndims; /* Array rank for reading */
68 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
69 int i,j; /* counting variables */
70 herr_t ret; /* Generic return value */
85 int wdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information to write */
86 int rdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information read in */
87 hid_t fid1; /* HDF5 File IDs */
88 hid_t dataset; /* Dataset ID */
89 hid_t sid1; /* Dataspace ID */
90 hid_t tid1; /* Datatype ID */
91 hsize_t sdims1[] = {SPACE1_DIM1};
92 hsize_t tdims1[] = {ARRAY1_DIM1};
93 int ndims; /* Array rank for reading */
94 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
95 int i,j; /* counting variables */
96 herr_t ret; /* Generic return value */
7197
7298 /* Output message about test being performed */
7399 MESSAGE(5, ("Testing 1-D Array of Atomic Datatypes Functionality\n"));
166192 CHECK(ret, FAIL, "H5Fclose");
167193 } /* end test_array_atomic_1d() */
168194
169 /****************************************************************
170 **
171 ** test_array_funcs(): Test some type functions that are and
172 ** aren't supposed to work with array type.
173 **
174 ****************************************************************/
195
196 /*-------------------------------------------------------------------------
197 * Function: test_array_funcs
198 *
199 * Purpose: Test some type functions that are and aren't supposed to
200 * work with array type.
201 *
202 * Return: void
203 *
204 *-------------------------------------------------------------------------
205 */
175206 static void
176207 test_array_funcs(void)
177208 {
178 hid_t type; /* Datatype ID */
179 hsize_t tdims1[] = {ARRAY1_DIM1};
180 int size;
181 H5T_pad_t inpad;
182 H5T_norm_t norm;
183 H5T_cset_t cset;
184 H5T_str_t strpad;
185 herr_t ret; /* Generic return value */
209 hid_t type; /* Datatype ID */
210 hsize_t tdims1[] = {ARRAY1_DIM1};
211 size_t size;
212 H5T_pad_t inpad;
213 H5T_norm_t norm;
214 H5T_cset_t cset;
215 H5T_str_t strpad;
216 herr_t ret; /* Generic return value */
186217
187218 /* Create a datatype to refer to */
188219 type = H5Tarray_create2(H5T_IEEE_F32BE, ARRAY1_RANK, tdims1);
189220 CHECK(type, FAIL, "H5Tarray_create2");
190221
191222 size=H5Tget_precision(type);
192 CHECK(size, FAIL, "H5Tget_precision");
223 CHECK(size, 0, "H5Tget_precision");
193224
194225 size=H5Tget_size(type);
195 CHECK(size, FAIL, "H5Tget_size");
226 CHECK(size, 0, "H5Tget_size");
196227
197228 size=H5Tget_ebias(type);
198 CHECK(size, FAIL, "H5Tget_ebias");
229 CHECK(size, 0, "H5Tget_ebias");
199230
200231 ret=H5Tset_pad(type, H5T_PAD_ZERO, H5T_PAD_ONE);
201232 CHECK(ret, FAIL, "H5Tset_pad");
222253 /* Close datatype */
223254 ret = H5Tclose(type);
224255 CHECK(ret, FAIL, "H5Tclose");
225 } /* end test_array_funcs */
226
227 /****************************************************************
228 **
229 ** test_array_atomic_3d(): Test basic array datatype code.
230 ** Tests 3-D array of atomic datatypes
231 **
232 ****************************************************************/
256 } /* end test_array_funcs() */
257
258
259 /*-------------------------------------------------------------------------
260 * Function: test_array_atomic_3d
261 *
262 * Purpose: Test basic array datatype code.
263 * Tests 3-D array of atomic datatypes.
264 *
265 * Return: void
266 *
267 *-------------------------------------------------------------------------
268 */
233269 static void
234270 test_array_atomic_3d(void)
235271 {
236272 int wdata[SPACE1_DIM1][ARRAY2_DIM1][ARRAY2_DIM2][ARRAY2_DIM3]; /* Information to write */
237273 int rdata[SPACE1_DIM1][ARRAY2_DIM1][ARRAY2_DIM2][ARRAY2_DIM3]; /* Information read in */
238 hid_t fid; /* HDF5 File IDs */
239 hid_t dataset; /* Dataset ID */
240 hid_t sid; /* Dataspace ID */
241 hid_t tid; /* Datatype ID */
242 hsize_t sdims1[] = {SPACE1_DIM1};
243 hsize_t tdims2[] = {ARRAY2_DIM1,ARRAY2_DIM2,ARRAY2_DIM3};
244 int ndims; /* Array rank for reading */
245 hsize_t rdims2[H5S_MAX_RANK]; /* Array dimensions for reading */
246 int i,j,k,l; /* counting variables */
247 herr_t ret; /* Generic return value */
274 hid_t fid; /* HDF5 File IDs */
275 hid_t dataset; /* Dataset ID */
276 hid_t sid; /* Dataspace ID */
277 hid_t tid; /* Datatype ID */
278 hsize_t sdims1[] = {SPACE1_DIM1};
279 hsize_t tdims2[] = {ARRAY2_DIM1,ARRAY2_DIM2,ARRAY2_DIM3};
280 int ndims; /* Array rank for reading */
281 hsize_t rdims2[H5S_MAX_RANK]; /* Array dimensions for reading */
282 int i,j,k,l; /* counting variables */
283 herr_t ret; /* Generic return value */
248284
249285 /* Output message about test being performed */
250286 MESSAGE(5, ("Testing 3-D Array of Atomic Datatypes Functionality\n"));
348384
349385 } /* end test_array_atomic_3d() */
350386
351 /****************************************************************
352 **
353 ** test_array_array_atomic(): Test basic array datatype code.
354 ** Tests 1-D array 2-D arrays of atomic datatypes
355 **
356 ****************************************************************/
387
388 /*-------------------------------------------------------------------------
389 * Function: test_array_array_atomic
390 *
391 * Purpose: Test basic array datatype code.
392 * Tests 1-D array 2-D arrays of atomic datatypes.
393 *
394 * Return: void
395 *
396 *-------------------------------------------------------------------------
397 */
357398 static void
358399 test_array_array_atomic(void)
359400 {
360401 int wdata[SPACE1_DIM1][ARRAY1_DIM1][ARRAY3_DIM1][ARRAY3_DIM2]; /* Information to write */
361402 int rdata[SPACE1_DIM1][ARRAY1_DIM1][ARRAY3_DIM1][ARRAY3_DIM2]; /* Information read in */
362 hid_t fid; /* HDF5 File IDs */
363 hid_t dataset; /* Dataset ID */
364 hid_t sid; /* Dataspace ID */
365 hid_t tid1; /* 1-D array Datatype ID */
366 hid_t tid2; /* 2-D array Datatype ID */
367 hsize_t sdims1[] = {SPACE1_DIM1};
368 hsize_t tdims1[] = {ARRAY1_DIM1};
369 hsize_t tdims2[] = {ARRAY3_DIM1,ARRAY3_DIM2};
370 int ndims1; /* Array rank for reading */
371 int ndims2; /* Array rank for reading */
372 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
373 hsize_t rdims2[H5S_MAX_RANK]; /* Array dimensions for reading */
374 int i,j,k,l; /* counting variables */
375 herr_t ret; /* Generic return value */
403 hid_t fid; /* HDF5 File IDs */
404 hid_t dataset; /* Dataset ID */
405 hid_t sid; /* Dataspace ID */
406 hid_t tid1; /* 1-D array Datatype ID */
407 hid_t tid2; /* 2-D array Datatype ID */
408 hsize_t sdims1[] = {SPACE1_DIM1};
409 hsize_t tdims1[] = {ARRAY1_DIM1};
410 hsize_t tdims2[] = {ARRAY3_DIM1,ARRAY3_DIM2};
411 int ndims1; /* Array rank for reading */
412 int ndims2; /* Array rank for reading */
413 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
414 hsize_t rdims2[H5S_MAX_RANK]; /* Array dimensions for reading */
415 int i,j,k,l; /* counting variables */
416 herr_t ret; /* Generic return value */
376417
377418 /* Output message about test being performed */
378419 MESSAGE(5, ("Testing 1-D Array 2-D Arrays of Atomic Datatypes Functionality\n"));
502543 CHECK(ret, FAIL, "H5Fclose");
503544 } /* end test_array_array_atomic() */
504545
505 /****************************************************************
506 **
507 ** test_array_compound_atomic(): Test basic array datatype code.
508 ** Tests 1-D array of compound datatypes (with no array fields)
509 **
510 ****************************************************************/
546
547 /*-------------------------------------------------------------------------
548 * Function: test_array_compound_atomic
549 *
550 * Purpose: Test basic array datatype code.
551 * Tests 1-D array of compound datatypes (with no array fields).
552 *
553 * Return: void
554 *
555 *-------------------------------------------------------------------------
556 */
511557 static void
512558 test_array_compound_atomic(void)
513559 {
515561 int i;
516562 float f;
517563 } s1_t;
518 s1_t wdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information to write */
519 s1_t rdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information read in */
520 hid_t fid1; /* HDF5 File IDs */
521 hid_t dataset; /* Dataset ID */
522 hid_t sid1; /* Dataspace ID */
523 hid_t tid1; /* Array Datatype ID */
524 hid_t tid2; /* Compound Datatype ID */
525 hsize_t sdims1[] = {SPACE1_DIM1};
526 hsize_t tdims1[] = {ARRAY1_DIM1};
527 int ndims; /* Array rank for reading */
528 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
529 int nmemb; /* Number of compound members */
530 char *mname; /* Name of compound field */
531 size_t off; /* Offset of compound field */
532 hid_t mtid; /* Datatype ID for field */
533 int i,j; /* counting variables */
534 herr_t ret; /* Generic return value */
564
565 s1_t wdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information to write */
566 s1_t rdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information read in */
567 hid_t fid1; /* HDF5 File IDs */
568 hid_t dataset; /* Dataset ID */
569 hid_t sid1; /* Dataspace ID */
570 hid_t tid1; /* Array Datatype ID */
571 hid_t tid2; /* Compound Datatype ID */
572 hsize_t sdims1[] = {SPACE1_DIM1};
573 hsize_t tdims1[] = {ARRAY1_DIM1};
574 int ndims; /* Array rank for reading */
575 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
576 int nmemb; /* Number of compound members */
577 char *mname; /* Name of compound field */
578 size_t off; /* Offset of compound field */
579 hid_t mtid; /* Datatype ID for field */
580 int i,j; /* counting variables */
581 herr_t ret; /* Generic return value */
535582
536583 /* Output message about test being performed */
537584 MESSAGE(5, ("Testing 1-D Array of Compound Atomic Datatypes Functionality\n"));
540587 for(i = 0; i < SPACE1_DIM1; i++)
541588 for(j = 0; j < ARRAY1_DIM1; j++) {
542589 wdata[i][j].i = i * 10 + j;
543 wdata[i][j].f = (float)(i * 2.5F + j);
590 wdata[i][j].f = (float)i * 2.5F + (float)j;
544591 } /* end for */
545592
546593 /* Create file */
703750 CHECK(ret, FAIL, "H5Fclose");
704751 } /* end test_array_compound_atomic() */
705752
706 /****************************************************************
707 **
708 ** test_array_compound_array(): Test basic array datatype code.
709 ** Tests 1-D array of compound datatypes (with array fields)
710 **
711 ****************************************************************/
753
754 /*-------------------------------------------------------------------------
755 * Function: test_array_compound_array
756 *
757 * Purpose: Test basic array datatype code.
758 * Tests 1-D array of compound datatypes (with array fields).
759 *
760 * Return: void
761 *
762 *-------------------------------------------------------------------------
763 */
712764 static void
713765 test_array_compound_array(void)
714766 {
716768 int i;
717769 float f[ARRAY1_DIM1];
718770 } s1_t;
719 s1_t wdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information to write */
720 s1_t rdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information read in */
721 hid_t fid1; /* HDF5 File IDs */
722 hid_t dataset; /* Dataset ID */
723 hid_t sid1; /* Dataspace ID */
724 hid_t tid1; /* Array Datatype ID */
725 hid_t tid2; /* Compound Datatype ID */
726 hid_t tid3; /* Nested Array Datatype ID */
727 hsize_t sdims1[] = {SPACE1_DIM1};
728 hsize_t tdims1[] = {ARRAY1_DIM1};
729 int ndims; /* Array rank for reading */
730 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
731 int nmemb; /* Number of compound members */
732 char *mname; /* Name of compound field */
733 size_t off; /* Offset of compound field */
734 hid_t mtid; /* Datatype ID for field */
735 H5T_class_t mclass; /* Datatype class for field */
736 int i,j,k; /* counting variables */
737 herr_t ret; /* Generic return value */
771
772 s1_t wdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information to write */
773 s1_t rdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information read in */
774 hid_t fid1; /* HDF5 File IDs */
775 hid_t dataset; /* Dataset ID */
776 hid_t sid1; /* Dataspace ID */
777 hid_t tid1; /* Array Datatype ID */
778 hid_t tid2; /* Compound Datatype ID */
779 hid_t tid3; /* Nested Array Datatype ID */
780 hsize_t sdims1[] = {SPACE1_DIM1};
781 hsize_t tdims1[] = {ARRAY1_DIM1};
782 int ndims; /* Array rank for reading */
783 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
784 int nmemb; /* Number of compound members */
785 char *mname; /* Name of compound field */
786 size_t off; /* Offset of compound field */
787 hid_t mtid; /* Datatype ID for field */
788 H5T_class_t mclass; /* Datatype class for field */
789 int i,j,k; /* counting variables */
790 herr_t ret; /* Generic return value */
738791
739792 /* Output message about test being performed */
740793 MESSAGE(5, ("Testing 1-D Array of Compound Array Datatypes Functionality\n"));
744797 for(j=0; j<ARRAY1_DIM1; j++) {
745798 wdata[i][j].i=i*10+j;
746799 for(k=0; k<ARRAY1_DIM1; k++)
747 wdata[i][j].f[k]=(float)(i * 10.0F + j * 2.5F + k);
800 wdata[i][j].f[k] = (float)i * 10.0F + (float)j * 2.5F + (float)k;
748801 } /* end for */
749802
750803 /* Create file */
9481001
9491002 } /* end test_array_compound_array() */
9501003
951 void *test_array_alloc_custom(size_t size, void *info);
952 void test_array_free_custom(void *mem, void *info);
953
9541004 /****************************************************************
9551005 **
9561006 ** test_array_alloc_custom(): Test VL datatype custom memory
9591009 ** allocated.
9601010 **
9611011 ****************************************************************/
962 void *test_array_alloc_custom(size_t size, void *info)
1012
1013 /*-------------------------------------------------------------------------
1014 * Function: test_array_alloc_custom
1015 *
1016 * Purpose: Memory allocator for testing VL datatype custom memory
1017 * allocation routines.
1018 *
1019 * This routine just uses malloc to allocate the memory and
1020 * increments the amount of memory allocated.
1021 *
1022 * Return:
1023 *
1024 * Success: A memory buffer
1025 * Failure: NULL
1026 *
1027 *-------------------------------------------------------------------------
1028 */
1029 void *
1030 test_array_alloc_custom(size_t size, void *info)
9631031 {
964 void *ret_value=NULL; /* Pointer to return */
965 int *mem_used=(int *)info; /* Get the pointer to the memory used */
966 size_t extra; /* Extra space needed */
1032 void *ret_value = NULL; /* Pointer to return */
1033 size_t *mem_used = (size_t *)info; /* Pointer to the memory used */
1034 size_t extra; /* Extra space needed */
9671035
9681036 /*
9691037 * This weird contortion is required on the DEC Alpha to keep the
9701038 * alignment correct - QAK
9711039 */
972 extra=MAX(sizeof(void *),sizeof(size_t));
973
974 if((ret_value=HDmalloc(extra+size))!=NULL) {
975 *(size_t *)ret_value=size;
976 *mem_used+=size;
1040 extra = MAX(sizeof(void *), sizeof(size_t));
1041
1042 if((ret_value = HDmalloc(extra+size)) != NULL) {
1043 *(size_t *)ret_value = size;
1044 *mem_used += size;
9771045 } /* end if */
978 ret_value=((unsigned char *)ret_value)+extra;
979 return(ret_value);
980 }
981
982 /****************************************************************
983 **
984 ** test_array_free_custom(): Test VL datatype custom memory
985 ** allocation routines. This routine just uses free to
986 ** release the memory and decrements the amount of memory
987 ** allocated.
988 **
989 ****************************************************************/
990 void test_array_free_custom(void *_mem, void *info)
1046
1047 ret_value = ((unsigned char *)ret_value) + extra;
1048 return ret_value;
1049 } /* end test_array_alloc_custom() */
1050
1051
1052 /*-------------------------------------------------------------------------
1053 * Function: test_array_free_custom
1054 *
1055 * Purpose: Memory free function for testing VL datatype custom memory
1056 * allocation routines.
1057 *
1058 * This routine just uses free to free the memory and
1059 * decrements the amount of memory allocated.
1060 *
1061 * Return: void
1062 *
1063 *-------------------------------------------------------------------------
1064 */
1065 void
1066 test_array_free_custom(void *_mem, void *info)
9911067 {
992 unsigned char *mem;
993 int *mem_used=(int *)info; /* Get the pointer to the memory used */
994 size_t extra; /* Extra space needed */
1068 unsigned char *mem = NULL; /* Pointer to mem to be freed */
1069 size_t *mem_used = (size_t *)info; /* Pointer to the memory used */
1070 size_t extra; /* Extra space needed */
9951071
9961072 /*
9971073 * This weird contortion is required on the DEC Alpha to keep the
9981074 * alignment correct - QAK
9991075 */
1000 extra=MAX(sizeof(void *),sizeof(size_t));
1001
1002 if(_mem!=NULL) {
1003 mem=((unsigned char *)_mem)-extra;
1004 *mem_used-=*(size_t *)mem;
1076 extra = MAX(sizeof(void *), sizeof(size_t));
1077
1078 if(_mem != NULL) {
1079 mem = ((unsigned char *)_mem) - extra;
1080 *mem_used -= *(size_t *)mem;
10051081 HDfree(mem);
10061082 } /* end if */
1007 }
1008
1009 /****************************************************************
1010 **
1011 ** test_array_vlen_atomic(): Test basic array datatype code.
1012 ** Tests 1-D array of atomic VL datatypes
1013 **
1014 ****************************************************************/
1083
1084 return;
1085 } /* end test_array_free_custom() */
1086
1087
1088 /*-------------------------------------------------------------------------
1089 * Function: test_array_vlen_atomic
1090 *
1091 * Purpose: Test basic array datatype code.
1092 * Tests 1-D array of atomic VL datatypes.
1093 *
1094 * Return: void
1095 *
1096 *-------------------------------------------------------------------------
1097 */
10151098 static void
10161099 test_array_vlen_atomic(void)
10171100 {
1018 hvl_t wdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information to write */
1019 hvl_t rdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information read in */
1020 hid_t fid1; /* HDF5 File IDs */
1021 hid_t dataset; /* Dataset ID */
1022 hid_t sid1; /* Dataspace ID */
1023 hid_t tid1; /* Array Datatype ID */
1024 hid_t tid2; /* VL Datatype ID */
1025 hid_t tid3; /* Atomic Datatype ID */
1026 hsize_t sdims1[] = {SPACE1_DIM1};
1027 hsize_t tdims1[] = {ARRAY1_DIM1};
1028 int ndims; /* Array rank for reading */
1029 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
1030 H5T_class_t mclass; /* Datatype class for VL */
1031 hid_t xfer_pid; /* Dataset transfer property list ID */
1032 hsize_t size; /* Number of bytes which will be used */
1033 int mem_used=0; /* Memory used during allocation */
1034 int i,j,k; /* counting variables */
1035 herr_t ret; /* Generic return value */
1101 hvl_t wdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information to write */
1102 hvl_t rdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information read in */
1103 hid_t fid1; /* HDF5 File IDs */
1104 hid_t dataset; /* Dataset ID */
1105 hid_t sid1; /* Dataspace ID */
1106 hid_t tid1; /* Array Datatype ID */
1107 hid_t tid2; /* VL Datatype ID */
1108 hid_t tid3; /* Atomic Datatype ID */
1109 hsize_t sdims1[] = {SPACE1_DIM1};
1110 hsize_t tdims1[] = {ARRAY1_DIM1};
1111 int ndims; /* Array rank for reading */
1112 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
1113 H5T_class_t mclass; /* Datatype class for VL */
1114 hid_t xfer_pid; /* Dataset transfer property list ID */
1115 hsize_t size; /* Number of bytes which will be used */
1116 size_t mem_used=0; /* Memory used during allocation */
1117 int i,j,k; /* counting variables */
1118 herr_t ret; /* Generic return value */
10361119
10371120 /* Output message about test being performed */
10381121 MESSAGE(5, ("Testing 1-D Array of Atomic Variable-Length Datatypes Functionality\n"));
10401123 /* Initialize array data to write */
10411124 for(i=0; i<SPACE1_DIM1; i++)
10421125 for(j=0; j<ARRAY1_DIM1; j++) {
1043 wdata[i][j].p=HDmalloc((i+j+1)*sizeof(unsigned int));
1044 wdata[i][j].len=i+j+1;
1126 wdata[i][j].p=HDmalloc((size_t)(i+j+1) * sizeof(unsigned int));
1127 wdata[i][j].len = (size_t)(i+j+1);
10451128 for(k=0; k<(i+j+1); k++)
1046 ((unsigned int *)wdata[i][j].p)[k]=i*100+j*10+k;
1129 ((unsigned int *)wdata[i][j].p)[k] = (unsigned int)(i*100+j*10+k);
10471130 } /* end for */
10481131
10491132 /* Create file */
12161299
12171300 } /* end test_array_vlen_atomic() */
12181301
1219 /****************************************************************
1220 **
1221 ** test_array_vlen_array(): Test basic array datatype code.
1222 ** Tests 1-D array of 1-D array VL datatypes
1223 **
1224 ****************************************************************/
1302
1303 /*-------------------------------------------------------------------------
1304 * Function: test_array_vlen_array
1305 *
1306 * Purpose: Test basic array datatype code.
1307 * Tests 1-D array of 1-D array VL datatypes.
1308 *
1309 * Return: void
1310 *
1311 *-------------------------------------------------------------------------
1312 */
12251313 static void
12261314 test_array_vlen_array(void)
12271315 {
1228 hvl_t wdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information to write */
1229 hvl_t rdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information read in */
1230 hid_t fid1; /* HDF5 File IDs */
1231 hid_t dataset; /* Dataset ID */
1232 hid_t sid1; /* Dataspace ID */
1233 hid_t tid1; /* Array Datatype ID */
1234 hid_t tid2; /* VL Datatype ID */
1235 hid_t tid3; /* Nested Array Datatype ID */
1236 hid_t tid4; /* Atomic Datatype ID */
1237 hsize_t sdims1[] = {SPACE1_DIM1};
1238 hsize_t tdims1[] = {ARRAY1_DIM1};
1239 int ndims; /* Array rank for reading */
1240 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
1241 H5T_class_t mclass; /* Datatype class for VL */
1242 hid_t xfer_pid; /* Dataset transfer property list ID */
1243 hsize_t size; /* Number of bytes which will be used */
1244 int mem_used=0; /* Memory used during allocation */
1245 int i,j,k,l; /* Index variables */
1246 herr_t ret; /* Generic return value */
1316 hvl_t wdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information to write */
1317 hvl_t rdata[SPACE1_DIM1][ARRAY1_DIM1]; /* Information read in */
1318 hid_t fid1; /* HDF5 File IDs */
1319 hid_t dataset; /* Dataset ID */
1320 hid_t sid1; /* Dataspace ID */
1321 hid_t tid1; /* Array Datatype ID */
1322 hid_t tid2; /* VL Datatype ID */
1323 hid_t tid3; /* Nested Array Datatype ID */
1324 hid_t tid4; /* Atomic Datatype ID */
1325 hsize_t sdims1[] = {SPACE1_DIM1};
1326 hsize_t tdims1[] = {ARRAY1_DIM1};
1327 int ndims; /* Array rank for reading */
1328 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
1329 H5T_class_t mclass; /* Datatype class for VL */
1330 hid_t xfer_pid; /* Dataset transfer property list ID */
1331 hsize_t size; /* Number of bytes which will be used */
1332 size_t mem_used=0; /* Memory used during allocation */
1333 int i,j,k,l; /* Index variables */
1334 herr_t ret; /* Generic return value */
12471335
12481336 /* Output message about test being performed */
12491337 MESSAGE(5, ("Testing 1-D Array of 1-D Array Variable-Length Datatypes Functionality\n"));
12511339 /* Initialize array data to write */
12521340 for(i=0; i<SPACE1_DIM1; i++)
12531341 for(j=0; j<ARRAY1_DIM1; j++) {
1254 wdata[i][j].p=HDmalloc((i+j+1)*(sizeof(unsigned int)*ARRAY1_DIM1));
1255 wdata[i][j].len=i+j+1;
1342 wdata[i][j].p = HDmalloc((size_t)(i+j+1) * sizeof(unsigned int) * (size_t)ARRAY1_DIM1);
1343 wdata[i][j].len = (size_t)(i+j+1);
12561344 for(k=0; k<(i+j+1); k++)
12571345 for(l=0; l<ARRAY1_DIM1; l++)
1258 ((unsigned int *)wdata[i][j].p)[k*ARRAY1_DIM1+l]=i*1000+j*100+k*10+l;
1346 ((unsigned int *)wdata[i][j].p)[k*ARRAY1_DIM1+l] = (unsigned int)(i*1000+j*100+k*10+l);
12591347 } /* end for */
12601348
12611349 /* Create file */
14661554
14671555 } /* end test_array_vlen_array() */
14681556
1469 #define FIELDNAME "ArrayofStructures"
1470 #define LENGTH 5
1471 #define ALEN 10
1472 #define RANK 1
1473 #define NMAX 100
1474
1475 typedef struct
1476 {
1477 int nsubfields;
1478 char *name[NMAX];
1479 size_t offset[NMAX];
1480 hid_t datatype[NMAX];
1481
1482 } CmpDTSinfo;
1483
1484 /****************************************************************
1485 **
1486 ** test_array_bkg(): Test basic array datatype code.
1487 ** Tests reading compound datatype with array fields and
1488 ** writing partial fields.
1489 **
1490 ****************************************************************/
1557
1558 /*-------------------------------------------------------------------------
1559 * Function: test_array_bkg
1560 *
1561 * Purpose: Test basic array datatype code.
1562 * Tests reading compound datatype with array fields and
1563 * writing partial fields.
1564 *
1565 * Return: void
1566 *
1567 *-------------------------------------------------------------------------
1568 */
14911569 static void
14921570 test_array_bkg(void)
14931571 {
15041582 int i, j;
15051583 unsigned ndims[3] = {1,1,1};
15061584
1507 typedef struct
1508 {
1585 typedef struct {
15091586 int a[ALEN];
15101587 float b[ALEN];
15111588 double c[ALEN];
15131590
15141591 CmpField cf[LENGTH];
15151592 CmpField cfr[LENGTH];
1516 CmpDTSinfo dtsinfo;
1517
1518 typedef struct
1519 {
1593 CmpDTSinfo *dtsinfo = NULL;
1594
1595 typedef struct {
15201596 float b[ALEN];
15211597 } fld_t;
15221598
15281604
15291605 /* Initialize the data */
15301606 /* ------------------- */
1531 for (i = 0; i < LENGTH; i++)
1532 {
1533 for (j = 0; j < ALEN; j++)
1534 {
1535 cf[i].a[j] = 100*(i+1) + j;
1536 cf[i].b[j] = (float)(100.0F*(i+1) + 0.01F*j);
1537 cf[i].c[j] = (double)(100.0F*(i+1) + 0.02F*j);
1538 }
1539 }
1607 dtsinfo = (CmpDTSinfo *)HDmalloc(sizeof(CmpDTSinfo));
1608 CHECK(dtsinfo, NULL, "HDmalloc");
1609 HDmemset(dtsinfo, 0, sizeof(CmpDTSinfo));
1610 for (i = 0; i < LENGTH; i++) {
1611 for (j = 0; j < ALEN; j++) {
1612 cf[i].a[j] = 100 * (i + 1) + j;
1613 cf[i].b[j] = 100.0F * ((float)i + 1.0F) + 0.01F * (float)j;
1614 cf[i].c[j] = (double)(100.0F * ((float)i + 1.0F) + 0.02F * (float)j);
1615 } /* end for */
1616 } /* end for */
15401617
15411618
15421619 /* Set the number of data members */
15431620 /* ------------------------------ */
1544 dtsinfo.nsubfields = 3;
1621 dtsinfo->nsubfields = 3;
15451622
15461623 /* Initialize the offsets */
15471624 /* ----------------------- */
1548 dtsinfo.offset[0] = HOFFSET(CmpField, a);
1549 dtsinfo.offset[1] = HOFFSET(CmpField, b);
1550 dtsinfo.offset[2] = HOFFSET(CmpField, c);
1625 dtsinfo->offset[0] = HOFFSET(CmpField, a);
1626 dtsinfo->offset[1] = HOFFSET(CmpField, b);
1627 dtsinfo->offset[2] = HOFFSET(CmpField, c);
15511628
15521629 /* Initialize the data type IDs */
15531630 /* ---------------------------- */
1554 dtsinfo.datatype[0] = H5T_NATIVE_INT;
1555 dtsinfo.datatype[1] = H5T_NATIVE_FLOAT;
1556 dtsinfo.datatype[2] = H5T_NATIVE_DOUBLE;
1631 dtsinfo->datatype[0] = H5T_NATIVE_INT;
1632 dtsinfo->datatype[1] = H5T_NATIVE_FLOAT;
1633 dtsinfo->datatype[2] = H5T_NATIVE_DOUBLE;
15571634
15581635
15591636 /* Initialize the names of data members */
15601637 /* ------------------------------------ */
1561 for (i = 0; i < dtsinfo.nsubfields; i++)
1562 dtsinfo.name[i] = (char *)HDcalloc((size_t)20, sizeof(char));
1563
1564 strcpy(dtsinfo.name[0], "One");
1565 strcpy(dtsinfo.name[1], "Two");
1566 strcpy(dtsinfo.name[2], "Three");
1638 for (i = 0; i < dtsinfo->nsubfields; i++)
1639 dtsinfo->name[i] = (char *)HDcalloc((size_t)20, sizeof(char));
1640
1641 HDstrcpy(dtsinfo->name[0], "One");
1642 HDstrcpy(dtsinfo->name[1], "Two");
1643 HDstrcpy(dtsinfo->name[2], "Three");
15671644
15681645
15691646 /* Create file */
15841661
15851662 /* Add members to the compound data type */
15861663 /* -------------------------------------- */
1587 for ( i = 0; i < dtsinfo.nsubfields; i++)
1588 {
1589 array_dt = H5Tarray_create2(dtsinfo.datatype[i], ndims[i], dima);
1664 for ( i = 0; i < dtsinfo->nsubfields; i++) {
1665 array_dt = H5Tarray_create2(dtsinfo->datatype[i], ndims[i], dima);
15901666 CHECK(array_dt, FAIL, "H5Tarray_create2");
15911667
1592 status = H5Tinsert (type, dtsinfo.name[i], dtsinfo.offset[i], array_dt);
1668 status = H5Tinsert (type, dtsinfo->name[i], dtsinfo->offset[i], array_dt);
15931669 CHECK(status, FAIL, "H5Tinsert");
15941670
15951671 status = H5Tclose(array_dt);
15961672 CHECK(status, FAIL, "H5Tclose");
1597 }
1673 } /* end for */
15981674
15991675 /* Create the dataset */
16001676 /* ------------------ */
16161692 if(cf[i].a[j]!=cfr[i].a[j]) {
16171693 TestErrPrintf("Field a data doesn't match, cf[%d].a[%d]=%d, cfr[%d].a[%d]=%d\n",(int)i,(int)j,(int)cf[i].a[j],(int)i,(int)j,(int)cfr[i].a[j]);
16181694 continue;
1619 }
1695 } /* end if */
16201696 if(!H5_FLT_ABS_EQUAL(cf[i].b[j],cfr[i].b[j])) {
16211697 TestErrPrintf("Field b data doesn't match, cf[%d].b[%d]=%f, cfr[%d].b[%d]=%f\n",(int)i,(int)j,(double)cf[i].b[j],(int)i,(int)j,(double)cfr[i].b[j]);
16221698 continue;
1623 }
1699 } /* end if */
16241700 if(!H5_DBL_ABS_EQUAL(cf[i].c[j],cfr[i].c[j])) {
16251701 TestErrPrintf("Field c data doesn't match, cf[%d].b[%d]=%f, cfr[%d].b[%d]=%f\n",(int)i,(int)j,(double)cf[i].c[j],(int)i,(int)j,(double)cfr[i].c[j]);
16261702 continue;
1627 }
1628 }
1629 }
1703 } /* end if */
1704 } /* end for */
1705 } /* end for */
16301706
16311707
16321708 /* Release memory resources */
16331709 /* ------------------------ */
1634 for (i = 0; i < dtsinfo.nsubfields; i++)
1635 HDfree(dtsinfo.name[i]);
1710 for (i = 0; i < dtsinfo->nsubfields; i++)
1711 HDfree(dtsinfo->name[i]);
16361712
16371713
16381714 /* Release IDs */
16501726 CHECK(status, FAIL, "H5Fclose");
16511727
16521728
1653 /******************************/
1654 /* Reopen the file and update */
1655 /******************************/
1729 /******************************/
1730 /* Reopen the file and update */
1731 /******************************/
16561732
16571733 fid = H5Fopen(FILENAME, H5F_ACC_RDWR, H5P_DEFAULT);
16581734 CHECK(fid, FAIL, "H5Fopen");
16731749 /* -------------------------------- */
16741750 for (i=0; i< LENGTH; i++)
16751751 for (j = 0; j < ALEN; j++)
1676 cf[i].b[j]=fld[i].b[j] = 1.313F;
1752 cf[i].b[j] = fld[i].b[j] = 1.313F;
16771753
16781754 status = H5Dwrite (dataset, type, H5S_ALL, H5S_ALL, H5P_DEFAULT, fld);
16791755 CHECK(status, FAIL, "H5Dwrite");
16871763 if(!H5_FLT_ABS_EQUAL(fld[i].b[j],fldr[i].b[j])) {
16881764 TestErrPrintf("Field data doesn't match, fld[%d].b[%d]=%f, fldr[%d].b[%d]=%f\n",(int)i,(int)j,(double)fld[i].b[j],(int)i,(int)j,(double)fldr[i].b[j]);
16891765 continue;
1690 }
1766 } /* end if */
16911767
16921768 status = H5Tclose (type);
16931769 CHECK(status, FAIL, "H5Tclose");
17091785 if(cf[i].a[j]!=cfr[i].a[j]) {
17101786 TestErrPrintf("Field a data doesn't match, cf[%d].a[%d]=%d, cfr[%d].a[%d]=%d\n",(int)i,(int)j,(int)cf[i].a[j],(int)i,(int)j,(int)cfr[i].a[j]);
17111787 continue;
1712 }
1788 } /* end if */
17131789 if(!H5_FLT_ABS_EQUAL(cf[i].b[j],cfr[i].b[j])) {
17141790 TestErrPrintf("Field b data doesn't match, cf[%d].b[%d]=%f, cfr[%d].b[%d]=%f\n",(int)i,(int)j,(double)cf[i].b[j],(int)i,(int)j,(double)cfr[i].b[j]);
17151791 continue;
1716 }
1792 } /* end if */
17171793 if(!H5_DBL_ABS_EQUAL(cf[i].c[j],cfr[i].c[j])) {
17181794 TestErrPrintf("Field c data doesn't match, cf[%d].b[%d]=%f, cfr[%d].b[%d]=%f\n",(int)i,(int)j,(double)cf[i].c[j],(int)i,(int)j,(double)cfr[i].c[j]);
17191795 continue;
1720 }
1721 }
1722 }
1796 } /* end if */
1797 } /* end for */
1798 } /* end for */
17231799
17241800 status = H5Dclose(dataset);
17251801 CHECK(status, FAIL, "H5Dclose");
17301806 status = H5Fclose(fid);
17311807 CHECK(status, FAIL, "H5Fclose");
17321808
1733 /****************************************************/
1734 /* Reopen the file and print out all the data again */
1735 /****************************************************/
1809 /****************************************************/
1810 /* Reopen the file and print out all the data again */
1811 /****************************************************/
17361812
17371813 fid = H5Fopen(FILENAME, H5F_ACC_RDWR, H5P_DEFAULT);
17381814 CHECK(fid, FAIL, "H5Fopen");
17461822
17471823 /* Reset the data to read in */
17481824 /* ------------------------- */
1749 memset(cfr, 0, sizeof(CmpField)*LENGTH);
1825 HDmemset(cfr, 0, sizeof(CmpField)*LENGTH);
17501826
17511827 status = H5Dread(dataset, type, H5S_ALL, H5S_ALL, H5P_DEFAULT, cfr);
17521828 CHECK(status, FAIL, "H5Dread");
17581834 if(cf[i].a[j]!=cfr[i].a[j]) {
17591835 TestErrPrintf("Field a data doesn't match, cf[%d].a[%d]=%d, cfr[%d].a[%d]=%d\n",(int)i,(int)j,(int)cf[i].a[j],(int)i,(int)j,(int)cfr[i].a[j]);
17601836 continue;
1761 }
1837 } /* end if */
17621838 if(!H5_FLT_ABS_EQUAL(cf[i].b[j],cfr[i].b[j])) {
17631839 TestErrPrintf("Field b data doesn't match, cf[%d].b[%d]=%f, cfr[%d].b[%d]=%f\n",(int)i,(int)j,(double)cf[i].b[j],(int)i,(int)j,(double)cfr[i].b[j]);
17641840 continue;
1765 }
1841 } /* end if */
17661842 if(!H5_DBL_ABS_EQUAL(cf[i].c[j],cfr[i].c[j])) {
17671843 TestErrPrintf("Field c data doesn't match, cf[%d].b[%d]=%f, cfr[%d].b[%d]=%f\n",(int)i,(int)j,(double)cf[i].c[j],(int)i,(int)j,(double)cfr[i].c[j]);
17681844 continue;
1769 }
1770 }
1771 }
1845 } /* end if */
1846 } /* end for */
1847 } /* end for */
17721848
17731849 status = H5Dclose(dataset);
17741850 CHECK(status, FAIL, "H5Dclose");
17781854
17791855 status = H5Fclose(fid);
17801856 CHECK(status, FAIL, "H5Fclose");
1857
1858 HDfree(dtsinfo);
17811859 } /* end test_array_bkg() */
17821860
1783 /****************************************************************
1784 **
1785 ** test_compat(): Test array datatype compatibility code.
1786 ** Reads file containing old version of datatype object header
1787 ** messages for compound datatypes and verifies reading the older
1788 ** version of the is working correctly.
1789 **
1790 ****************************************************************/
1861
1862 /*-------------------------------------------------------------------------
1863 * Function: test_compat
1864 *
1865 * Purpose: Test array datatype compatibility code.
1866 *
1867 * Reads file containing old version of datatype object header
1868 * messages for compound datatypes and verifies reading the older
1869 * version of the is working correctly.
1870 *
1871 * Return: void
1872 *
1873 *-------------------------------------------------------------------------
1874 */
17911875 static void
17921876 test_compat(void)
17931877 {
17941878 const char *testfile = H5_get_srcdir_filename(TESTFILE); /* Corrected test file name */
1795 hid_t fid1; /* HDF5 File IDs */
1796 hid_t dataset; /* Dataset ID */
1797 hid_t tid1; /* Array Datatype ID */
1798 hid_t tid2; /* Datatype ID */
1799 hsize_t tdims1[] = {ARRAY1_DIM1};
1800 int ndims; /* Array rank for reading */
1801 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
1802 H5T_class_t mclass; /* Datatype class for VL */
1803 int nmemb; /* Number of compound members */
1804 char *mname; /* Name of compound field */
1805 size_t off; /* Offset of compound field */
1806 hid_t mtid; /* Datatype ID for field */
1807 int i; /* Index variables */
1808 herr_t ret; /* Generic return value */
1879 hid_t fid1; /* HDF5 File IDs */
1880 hid_t dataset; /* Dataset ID */
1881 hid_t tid1; /* Array Datatype ID */
1882 hid_t tid2; /* Datatype ID */
1883 hsize_t tdims1[] = {ARRAY1_DIM1};
1884 int ndims; /* Array rank for reading */
1885 hsize_t rdims1[H5S_MAX_RANK]; /* Array dimensions for reading */
1886 H5T_class_t mclass; /* Datatype class for VL */
1887 int nmemb; /* Number of compound members */
1888 char *mname; /* Name of compound field */
1889 size_t off; /* Offset of compound field */
1890 hid_t mtid; /* Datatype ID for field */
1891 int i; /* Index variables */
1892 herr_t ret; /* Generic return value */
18091893
18101894 /* Output message about test being performed */
18111895 MESSAGE(5, ("Testing Array Datatypes Compatibility Functionality\n"));
20632147 /* Close the file */
20642148 ret = H5Fclose(fid1);
20652149 CHECK_I(ret, "H5Fclose");
2066 }
2150 } /* end if */
20672151 else
20682152 printf("***cannot open the pre-created compound datatype test file (%s)\n",testfile);
20692153
20702154 } /* end test_compat() */
20712155
2072 /****************************************************************
2073 **
2074 ** test_array(): Main array datatype testing routine.
2075 **
2076 ****************************************************************/
2156
2157 /*-------------------------------------------------------------------------
2158 * Function: test_array
2159 *
2160 * Purpose: Main array datatype testing routine.
2161 *
2162 * Return: void
2163 *
2164 *-------------------------------------------------------------------------
2165 */
20772166 void
20782167 test_array(void)
20792168 {
20812170 MESSAGE(5, ("Testing Array Datatypes\n"));
20822171
20832172 /* These tests use the same file... */
2084 test_array_atomic_1d(); /* Test 1-D array of atomic datatypes */
2085 test_array_atomic_3d(); /* Test 3-D array of atomic datatypes */
2086 test_array_array_atomic(); /* Test 1-D array of 2-D arrays of atomic datatypes */
2087 test_array_compound_atomic(); /* Test 1-D array of compound datatypes (with no array fields) */
2088 test_array_compound_array(); /* Test 1-D array of compound datatypes (with array fields) */
2089 test_array_vlen_atomic(); /* Test 1-D array of atomic VL datatypes */
2090 test_array_vlen_array(); /* Test 1-D array of 1-D array VL datatypes */
2091 test_array_funcs(); /* Test type functions with array types */
2092
2093 test_array_bkg(); /* Read compound datatype with array fields and background fields read */
2173 test_array_atomic_1d(); /* Test 1-D array of atomic datatypes */
2174 test_array_atomic_3d(); /* Test 3-D array of atomic datatypes */
2175 test_array_array_atomic(); /* Test 1-D array of 2-D arrays of atomic datatypes */
2176 test_array_compound_atomic(); /* Test 1-D array of compound datatypes (with no array fields) */
2177 test_array_compound_array(); /* Test 1-D array of compound datatypes (with array fields) */
2178 test_array_vlen_atomic(); /* Test 1-D array of atomic VL datatypes */
2179 test_array_vlen_array(); /* Test 1-D array of 1-D array VL datatypes */
2180 test_array_funcs(); /* Test type functions with array types */
2181
2182 test_array_bkg(); /* Read compound datatype with array fields and background fields read */
20942183
20952184 /* This test uses a custom file */
2096 test_compat(); /* Test compatibility changes for compound datatype fields */
2097 } /* test_array() */
2185 test_compat(); /* Test compatibility changes for compound datatype fields */
2186
2187 } /* end test_array() */
20982188
20992189
21002190 /*-------------------------------------------------------------------------
2101 * Function: cleanup_array
2102 *
2103 * Purpose: Cleanup temporary test files
2104 *
2105 * Return: none
2106 *
2107 * Programmer: Quincey Koziol
2191 * Function: cleanup_array
2192 *
2193 * Purpose: Cleanup temporary test files
2194 *
2195 * Return: void
2196 *
2197 * Programmer: Quincey Koziol
21082198 * June 8, 1999
2109 *
2110 * Modifications:
21112199 *
21122200 *-------------------------------------------------------------------------
21132201 */
21152203 cleanup_array(void)
21162204 {
21172205 remove(FILENAME);
2118 }
2119
2206 } /* end cleanup_array() */
2207
21222122
21232123 /****************************************************************
21242124 **
2125 ** test_file_double_file_dataset_open():
2126 ** This test checks multi-opens of files & datasets:
2127 ** It simulates the multi-thread test program from DLS
2128 ** which exposes the file pointer segmentation fault failure.
2129 ** NOTE: The order on when the files and datasets are open/close
2130 ** is important.
2131 **
2132 *****************************************************************/
2133 static void
2134 test_file_double_file_dataset_open(hbool_t new)
2135 {
2136 hid_t fapl = -1; /* File access property list */
2137 hid_t dcpl = -1; /* Dataset creation property list */
2138 hid_t fid1 = -1, fid2 = -1; /* File IDs */
2139 hid_t did1 = -1, did2 = -1; /* Dataset IDs */
2140 hid_t sid1 = -1, sid2 = -1; /* Dataspace IDs */
2141 hid_t tid1 = -1, tid2 = -1; /* Datatype IDs */
2142 hsize_t dims[1] = {4}, dims2[2] = {1, 4}; /* Dimension sizes */
2143 hsize_t max_dims0[1] = {8}; /* Maximum dimension sizes */
2144 hsize_t max_dims1[1] = {H5S_UNLIMITED}; /* Maximum dimesion sizes for extensible array index */
2145 hsize_t max_dims2[2] = {H5S_UNLIMITED, H5S_UNLIMITED}; /* Maximum dimension sizes for v2 B-tree index */
2146 hsize_t chunks[1] = {4}, chunks2[2] = {4, 5}; /* Chunk dimension sizes */
2147 char* data[] = {"String 1", "String 2", "String 3", "String 4"}; /* Input Data */
2148 char* buffer[4]; /* Output buffer */
2149 int wbuf[4] = {1, 2, 3, 4}; /* Input data */
2150 herr_t ret; /* Generic return value */
2151
2152 /* Output message about test being performed */
2153 MESSAGE(5, ("Testing double file and dataset open/close\n"));
2154
2155 /* Setting up test file */
2156
2157 fapl = H5Pcreate(H5P_FILE_ACCESS);
2158 CHECK(fapl, FAIL, "H5Pcreate");
2159
2160 if(new) {
2161 ret = H5Pset_libver_bounds(fapl, H5F_LIBVER_LATEST, H5F_LIBVER_LATEST);
2162 CHECK(ret, FAIL, "H5Pset_libver_bounds");
2163 }
2164
2165 /* Create the test file */
2166 fid1 = H5Fcreate(FILE1, H5F_ACC_TRUNC, H5P_DEFAULT, fapl);
2167 CHECK(fid1, FAIL, "H5Fcreate");
2168
2169 /* Create a chunked dataset with fixed array indexing */
2170 sid1 = H5Screate_simple(1, dims, max_dims0);
2171 CHECK(sid1, FAIL, "H5Screate");
2172 tid1 = H5Tcopy(H5T_C_S1);
2173 CHECK(tid1, FAIL, "H5Tcopy");
2174 ret = H5Tset_size(tid1, H5T_VARIABLE);
2175 CHECK(ret, FAIL, "H5Tset_size");
2176
2177 dcpl = H5Pcreate(H5P_DATASET_CREATE);
2178 CHECK(dcpl, FAIL, "H5Pcreate");
2179 ret = H5Pset_chunk(dcpl, 1, chunks);
2180 CHECK(ret, FAIL, "H5Pset_chunk");
2181
2182 did1 = H5Dcreate2(fid1, "dset_fa", tid1, sid1, H5P_DEFAULT, dcpl, H5P_DEFAULT);
2183 CHECK(did1, FAIL, "H5Dcreate2");
2184
2185 /* Closing */
2186 ret = H5Dclose(did1);
2187 CHECK(ret, FAIL, "H5Dclose");
2188 ret = H5Tclose(tid1);
2189 CHECK(ret, FAIL, "H5Tclose");
2190 ret = H5Sclose(sid1);
2191 CHECK(ret, FAIL, "H5Sclose");
2192 ret = H5Pclose(dcpl);
2193 CHECK(ret, FAIL, "H5Dclose");
2194
2195 /* Create a chunked dataset with extensible array indexing */
2196 sid1 = H5Screate_simple(1, dims, max_dims1);
2197 CHECK(sid1, FAIL, "H5Screate");
2198 tid1 = H5Tcopy(H5T_C_S1);
2199 CHECK(tid1, FAIL, "H5Tcopy");
2200 ret = H5Tset_size(tid1, H5T_VARIABLE);
2201 CHECK(ret, FAIL, "H5Tset_size");
2202
2203 dcpl = H5Pcreate(H5P_DATASET_CREATE);
2204 CHECK(dcpl, FAIL, "H5Pcreate");
2205 ret = H5Pset_chunk(dcpl, 1, chunks);
2206 CHECK(ret, FAIL, "H5Pset_chunk");
2207
2208 did1 = H5Dcreate2(fid1, "dset_ea", tid1, sid1, H5P_DEFAULT, dcpl, H5P_DEFAULT);
2209 CHECK(did1, FAIL, "H5Dcreate2");
2210
2211 /* Write to the dataset */
2212 ret = H5Dwrite(did1, tid1, H5S_ALL, H5S_ALL, H5P_DEFAULT, data);
2213 CHECK(ret, FAIL, "H5Dwrite");
2214
2215 /* Closing */
2216 ret = H5Dclose(did1);
2217 CHECK(ret, FAIL, "H5Dclose");
2218 ret = H5Tclose(tid1);
2219 CHECK(ret, FAIL, "H5Tclose");
2220 ret = H5Sclose(sid1);
2221 CHECK(ret, FAIL, "H5Sclose");
2222 ret = H5Pclose(dcpl);
2223 CHECK(ret, FAIL, "H5Dclose");
2224
2225 /* Create a chunked dataset with v2 btree indexing */
2226 sid2 = H5Screate_simple(2, dims2, max_dims2);
2227 CHECK(sid2, FAIL, "H5Screate");
2228
2229 dcpl = H5Pcreate(H5P_DATASET_CREATE);
2230 CHECK(dcpl, FAIL, "H5Pcreate");
2231 ret = H5Pset_chunk(dcpl, 2, chunks2);
2232 CHECK(ret, FAIL, "H5Pset_chunk");
2233
2234 did2 = H5Dcreate2(fid1, "dset_bt2", H5T_NATIVE_INT, sid2, H5P_DEFAULT, dcpl, H5P_DEFAULT);
2235 CHECK(did2, FAIL, "H5Dcreate2");
2236
2237 /* Write to the dataset */
2238 ret = H5Dwrite(did2, H5T_NATIVE_INT, H5S_ALL, H5S_ALL, H5P_DEFAULT, wbuf);
2239 CHECK(ret, FAIL, "H5Dwrite");
2240
2241 /* Closing */
2242 ret = H5Dclose(did2);
2243 CHECK(ret, FAIL, "H5Dclose");
2244
2245 ret = H5Sclose(sid2);
2246 CHECK(ret, FAIL, "H5Sclose");
2247 ret = H5Pclose(dcpl);
2248 CHECK(ret, FAIL, "H5Pclose");
2249 ret = H5Pclose(fapl);
2250 CHECK(ret, FAIL, "H5Pclose");
2251 ret = H5Fclose(fid1);
2252 CHECK(ret, FAIL, "H5Fclose");
2253
2254 /*
2255 * Scenario 1
2256 */
2257
2258 /* First file open */
2259 fid1 = H5Fopen(FILE1, H5F_ACC_RDWR, H5P_DEFAULT);
2260 CHECK(fid1, FAIL, "H5Fopen");
2261
2262 /* First file's dataset open */
2263 did1 = H5Dopen2(fid1, "/dset_fa", H5P_DEFAULT);
2264 CHECK(did1, FAIL, "H5Dopen2");
2265
2266 tid1 = H5Tcopy(did1);
2267 CHECK(tid1, FAIL, "H5Tcopy");
2268
2269 /* First file's dataset write */
2270 ret = H5Dwrite(did1, tid1, H5S_ALL, H5S_ALL, H5P_DEFAULT, data);
2271 CHECK(ret, FAIL, "H5Dwrite");
2272
2273 /* Second file open */
2274 fid2 = H5Fopen(FILE1, H5F_ACC_RDWR, H5P_DEFAULT);
2275 CHECK(fid2, FAIL, "H5Fopen");
2276
2277 /* Second file's dataset open */
2278 did2 = H5Dopen2(fid2, "/dset_fa", H5P_DEFAULT );
2279 CHECK(did2, FAIL, "H5Dopen2");
2280
2281 tid2 = H5Tcopy(did2);
2282 CHECK(tid2, FAIL, "H5Tcopy");
2283
2284 /* First file's dataset close */
2285 ret = H5Dclose(did1);
2286 CHECK(ret, FAIL, "H5Dclose");
2287
2288 /* First file close */
2289 ret = H5Fclose(fid1);
2290 CHECK(ret, FAIL, "H5Fclose");
2291
2292 /* Second file's dataset write */
2293 ret = H5Dwrite(did2, tid2, H5S_ALL, H5S_ALL, H5P_DEFAULT, data);
2294 CHECK(ret, FAIL, "H5Dwrite");
2295
2296 /* Second file's dataset close */
2297 ret = H5Dclose(did2);
2298 CHECK(ret, FAIL, "H5Dclose");
2299
2300 /* Second file close */
2301 ret = H5Fclose(fid2);
2302 CHECK(ret, FAIL, "H5Fclose");
2303
2304 /* Closing */
2305 ret = H5Tclose(tid1);
2306 CHECK(ret, FAIL, "H5Tclose");
2307 ret = H5Tclose(tid2);
2308 CHECK(ret, FAIL, "H5Tclose");
2309
2310 /*
2311 * Scenario 2
2312 */
2313
2314 /* First file open */
2315 fid1 = H5Fopen(FILE1, H5F_ACC_RDONLY, H5P_DEFAULT);
2316 CHECK(fid1, FAIL, "H5Fopen");
2317
2318 /* Second file open */
2319 fid2 = H5Fopen(FILE1, H5F_ACC_RDONLY, H5P_DEFAULT);
2320 CHECK(fid2, FAIL, "H5Fopen");
2321
2322 /* Second file's dataset open */
2323 did2 = H5Dopen2(fid2, "/dset_ea", H5P_DEFAULT );
2324 CHECK(did2, FAIL, "H5Dopen2");
2325
2326 tid2 = H5Tcopy(did2);
2327 CHECK(tid2, FAIL, "H5Tcopy");
2328
2329 /* First file's dataset open */
2330 did1 = H5Dopen2(fid1, "/dset_ea", H5P_DEFAULT);
2331 CHECK(did1, FAIL, "H5Dopen2");
2332
2333 tid1 = H5Tcopy(did1);
2334 CHECK(tid1, FAIL, "H5Tcopy");
2335
2336 /* Second file's dataset read */
2337 HDmemset(buffer, 0, sizeof(char*) * 4);
2338 ret = H5Dread(did2, tid2, H5S_ALL, H5S_ALL, H5P_DEFAULT, buffer);
2339 CHECK(ret, FAIL, "H5Dread");
2340
2341 /* Second file's dataset close */
2342 ret = H5Dclose(did2);
2343 CHECK(ret, FAIL, "H5Dclose");
2344
2345 /* Second file close */
2346 ret = H5Fclose(fid2);
2347 CHECK(ret, FAIL, "H5Fclose");
2348
2349 /* First file's dataset read */
2350 HDmemset(buffer, 0, sizeof(char*) * 4);
2351 ret = H5Dread(did1, tid1, H5S_ALL, H5S_ALL, H5P_DEFAULT, buffer);
2352
2353 /* First file's dataset close */
2354 ret = H5Dclose(did1);
2355 CHECK(ret, FAIL, "H5Dclose");
2356
2357 /* First file close */
2358 ret = H5Fclose(fid1);
2359 CHECK(ret, FAIL, "H5Fclose");
2360
2361 /* Closing */
2362 ret = H5Tclose(tid1);
2363 CHECK(ret, FAIL, "H5Tclose");
2364
2365 ret = H5Tclose(tid2);
2366 CHECK(ret, FAIL, "H5Tclose");
2367
2368 /*
2369 * Scenario 3
2370 */
2371
2372 /* First file open */
2373 fid1 = H5Fopen(FILE1, H5F_ACC_RDONLY, H5P_DEFAULT);
2374 CHECK(fid1, FAIL, "H5Fopen");
2375
2376 /* First file's dataset open */
2377 did1 = H5Dopen2(fid1, "/dset_bt2", H5P_DEFAULT);
2378 CHECK(did1, FAIL, "H5Dopen2");
2379
2380 /* First file's get storage size */
2381 ret = H5Dget_storage_size(did1);
2382 CHECK(ret, FAIL, "H5Dget_storage_size");
2383
2384 /* Second file open */
2385 fid2 = H5Fopen(FILE1, H5F_ACC_RDONLY, H5P_DEFAULT);
2386 CHECK(fid2, FAIL, "H5Fopen");
2387
2388 /* Second file's dataset open */
2389 did2 = H5Dopen2(fid2, "/dset_bt2", H5P_DEFAULT );
2390 CHECK(did2, FAIL, "H5Dopen2");
2391
2392 /* First file's dataset close */
2393 ret = H5Dclose(did1);
2394 CHECK(ret, FAIL, "H5Dclose");
2395
2396 /* First file close */
2397 ret = H5Fclose(fid1);
2398 CHECK(ret, FAIL, "H5Fclose");
2399
2400 /* Second file's get storage size */
2401 ret = H5Dget_storage_size(did2);
2402 CHECK(ret, FAIL, "H5Dget_storage_size");
2403
2404 /* Second file's dataset close */
2405 ret = H5Dclose(did2);
2406 CHECK(ret, FAIL, "H5Dclose");
2407
2408 /* Second file close */
2409 ret = H5Fclose(fid2);
2410 CHECK(ret, FAIL, "H5Fclose");
2411
2412 } /* end test_file_double_dataset_open() */
2413
2414 /****************************************************************
2415 **
21252416 ** test_file_double_datatype_open(): low-level file test routine.
21262417 ** This test checks whether opening the same named datatype from two
21272418 ** different files works correctly.
36933984 test_file_double_group_open(); /* Test opening same group from two files works properly */
36943985 test_file_double_dataset_open(); /* Test opening same dataset from two files works properly */
36953986 test_file_double_datatype_open(); /* Test opening same named datatype from two files works properly */
3987 test_file_double_file_dataset_open(TRUE);
3988 test_file_double_file_dataset_open(FALSE);
36963989 test_userblock_file_size(); /* Tests that files created with a userblock have the correct size */
36973990 test_cached_stab_info(); /* Tests that files are created with cached stab info in the superblock */
36983991 test_rw_noupdate(); /* Test to ensure that RW permissions don't write the file unless dirtied */
37404033 HDremove(FILE3);
37414034 HDremove(FILE4);
37424035 HDremove(FILE5);
4036 HDremove(FILE6);
4037 HDremove(FILE7);
37434038 }
37444039
546546 LN_S = @LN_S@
547547 LTLIBOBJS = @LTLIBOBJS@
548548 LT_STATIC_EXEC = @LT_STATIC_EXEC@
549 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
549550 MAINT = @MAINT@
550551 MAKEINFO = @MAKEINFO@
551552 MANIFEST_TOOL = @MANIFEST_TOOL@
503503 static hbool_t smoke_check_3(int metadata_write_strategy);
504504 static hbool_t smoke_check_4(int metadata_write_strategy);
505505 static hbool_t smoke_check_5(int metadata_write_strategy);
506 static hbool_t smoke_check_6(int metadata_write_strategy);
506507 static hbool_t trace_file_check(int metadata_write_strategy);
507508
508509
71897190
71907191 /*****************************************************************************
71917192 *
7193 * Function: smoke_check_6()
7194 *
7195 * Purpose: Sixth smoke check for the parallel cache.
7196 *
7197 * Return: Success: TRUE
7198 *
7199 * Failure: FALSE
7200 *
7201 * Programmer: JRM -- 1/13/06
7202 *
7203 *****************************************************************************/
7204 static hbool_t
7205 smoke_check_6(int metadata_write_strategy)
7206 {
7207 hbool_t success = TRUE;
7208 int i;
7209 int max_nerrors;
7210 int min_count;
7211 int max_count;
7212 int min_idx;
7213 int max_idx;
7214 hid_t fid = -1;
7215 H5F_t * file_ptr = NULL;
7216 H5C_t * cache_ptr = NULL;
7217 struct mssg_t mssg;
7218
7219 switch ( metadata_write_strategy ) {
7220
7221 case H5AC_METADATA_WRITE_STRATEGY__PROCESS_0_ONLY:
7222 if ( world_mpi_rank == 0 ) {
7223 TESTING("smoke check #6 -- process 0 only md write strategy");
7224 }
7225 break;
7226
7227 case H5AC_METADATA_WRITE_STRATEGY__DISTRIBUTED:
7228 if ( world_mpi_rank == 0 ) {
7229 TESTING("smoke check #6 -- distributed md write strategy");
7230 }
7231 break;
7232
7233 default:
7234 if ( world_mpi_rank == 0 ) {
7235 TESTING("smoke check #6 -- unknown md write strategy");
7236 }
7237 break;
7238 }
7239
7240 nerrors = 0;
7241 init_data();
7242 reset_stats();
7243
7244 if ( world_mpi_rank == world_server_mpi_rank ) {
7245
7246 if ( ! server_main() ) {
7247
7248 /* some error occured in the server -- report failure */
7249 nerrors++;
7250 if ( verbose ) {
7251 HDfprintf(stdout, "%d:%s: server_main() failed.\n",
7252 world_mpi_rank, FUNC);
7253 }
7254 }
7255 }
7256 else /* run the clients */
7257 {
7258 int temp;
7259
7260 if ( ! setup_cache_for_test(&fid, &file_ptr, &cache_ptr,
7261 metadata_write_strategy) ) {
7262
7263 nerrors++;
7264 fid = -1;
7265 cache_ptr = NULL;
7266 if ( verbose ) {
7267 HDfprintf(stdout, "%d:%s: setup_cache_for_test() failed.\n",
7268 world_mpi_rank, FUNC);
7269 }
7270 }
7271
7272 min_count = 100 / ((file_mpi_rank + 1) * (file_mpi_rank + 1));
7273 max_count = min_count + 50;
7274
7275 temp = virt_num_data_entries;
7276 virt_num_data_entries = NUM_DATA_ENTRIES;
7277
7278 /* insert the first half collectively */
7279 file_ptr->coll_md_read = H5P_USER_TRUE;
7280 for ( i = 0; i < virt_num_data_entries/2; i++ )
7281 {
7282 struct datum * entry_ptr;
7283 entry_ptr = &(data[i]);
7284
7285 insert_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
7286
7287 if(TRUE != entry_ptr->header.coll_access) {
7288 nerrors++;
7289 if ( verbose ) {
7290 HDfprintf(stdout, "%d:%s: Entry inserted not marked as collective.\n",
7291 world_mpi_rank, FUNC);
7292 }
7293 }
7294
7295 /* Make sure coll entries do not cross the 80% threshold */
7296 HDassert(cache_ptr->max_cache_size*0.8 > cache_ptr->coll_list_size);
7297 }
7298
7299 /* insert the other half independently */
7300 file_ptr->coll_md_read = H5P_USER_FALSE;
7301 for ( i = virt_num_data_entries/2; i < virt_num_data_entries; i++ )
7302 {
7303 struct datum * entry_ptr;
7304 entry_ptr = &(data[i]);
7305
7306 insert_entry(cache_ptr, file_ptr, i, H5AC__NO_FLAGS_SET);
7307
7308 if(FALSE != entry_ptr->header.coll_access) {
7309 nerrors++;
7310 if ( verbose ) {
7311 HDfprintf(stdout, "%d:%s: Entry inserted indepedently marked as collective.\n",
7312 world_mpi_rank, FUNC);
7313 }
7314 }
7315
7316 /* Make sure coll entries do not cross the 80% threshold */
7317 HDassert(cache_ptr->max_cache_size*0.8 > cache_ptr->coll_list_size);
7318 }
7319
7320 /* flush the file */
7321 if ( H5Fflush(fid, H5F_SCOPE_GLOBAL) < 0 ) {
7322 nerrors++;
7323 if ( verbose ) {
7324 HDfprintf(stdout, "%d:%s: H5Fflush() failed.\n",
7325 world_mpi_rank, FUNC);
7326 }
7327 }
7328
7329 /* Protect the first half of the entries collectively */
7330 file_ptr->coll_md_read = H5P_USER_TRUE;
7331 for ( i = 0; i < (virt_num_data_entries / 2); i++ )
7332 {
7333 struct datum * entry_ptr;
7334 entry_ptr = &(data[i]);
7335
7336 lock_entry(file_ptr, i);
7337
7338 if(TRUE != entry_ptr->header.coll_access) {
7339 nerrors++;
7340 if ( verbose ) {
7341 HDfprintf(stdout, "%d:%s: Entry protected not marked as collective.\n",
7342 world_mpi_rank, FUNC);
7343 }
7344 }
7345
7346 /* Make sure coll entries do not cross the 80% threshold */
7347 HDassert(cache_ptr->max_cache_size*0.8 > cache_ptr->coll_list_size);
7348 }
7349
7350 /* protect the other half independently */
7351 file_ptr->coll_md_read = H5P_USER_FALSE;
7352 for ( i = virt_num_data_entries/2; i < virt_num_data_entries; i++ )
7353 {
7354 struct datum * entry_ptr;
7355 entry_ptr = &(data[i]);
7356
7357 lock_entry(file_ptr, i);
7358
7359 if(FALSE != entry_ptr->header.coll_access) {
7360 nerrors++;
7361 if ( verbose ) {
7362 HDfprintf(stdout, "%d:%s: Entry inserted indepedently marked as collective.\n",
7363 world_mpi_rank, FUNC);
7364 }
7365 }
7366
7367 /* Make sure coll entries do not cross the 80% threshold */
7368 HDassert(cache_ptr->max_cache_size*0.8 > cache_ptr->coll_list_size);
7369 }
7370
7371 for ( i = 0; i < (virt_num_data_entries); i++ )
7372 {
7373 unlock_entry(file_ptr, i, H5AC__NO_FLAGS_SET);
7374 }
7375
7376 if ( fid >= 0 ) {
7377
7378 if ( ! take_down_cache(fid, cache_ptr) ) {
7379
7380 nerrors++;
7381 if ( verbose ) {
7382 HDfprintf(stdout, "%d:%s: take_down_cache() failed.\n",
7383 world_mpi_rank, FUNC);
7384 }
7385 }
7386 }
7387
7388 /* verify that all instances of datum are back where the started
7389 * and are clean.
7390 */
7391
7392 for ( i = 0; i < NUM_DATA_ENTRIES; i++ )
7393 {
7394 HDassert( data_index[i] == i );
7395 HDassert( ! (data[i].dirty) );
7396 }
7397
7398 /* compose the done message */
7399 mssg.req = DONE_REQ_CODE;
7400 mssg.src = world_mpi_rank;
7401 mssg.dest = world_server_mpi_rank;
7402 mssg.mssg_num = -1; /* set by send function */
7403 mssg.base_addr = 0; /* not used */
7404 mssg.len = 0; /* not used */
7405 mssg.ver = 0; /* not used */
7406 mssg.count = 0; /* not used */
7407 mssg.magic = MSSG_MAGIC;
7408
7409 if ( success ) {
7410
7411
7412 success = send_mssg(&mssg, FALSE);
7413
7414 if ( ! success ) {
7415
7416 nerrors++;
7417 if ( verbose ) {
7418 HDfprintf(stdout, "%d:%s: send_mssg() failed on done.\n",
7419 world_mpi_rank, FUNC);
7420 }
7421 }
7422 }
7423 virt_num_data_entries = temp;
7424 }
7425
7426 max_nerrors = get_max_nerrors();
7427
7428 if ( world_mpi_rank == 0 ) {
7429
7430 if ( max_nerrors == 0 ) {
7431
7432 PASSED();
7433
7434 } else {
7435
7436 failures++;
7437 H5_FAILED();
7438 }
7439 }
7440
7441 success = ( ( success ) && ( max_nerrors == 0 ) );
7442
7443 return(success);
7444
7445 } /* smoke_check_6() */
7446
7447
7448 /*****************************************************************************
7449 *
71927450 * Function: main()
71937451 *
71947452 * Purpose: Main function for the parallel cache test.
73797637 smoke_check_5(H5AC_METADATA_WRITE_STRATEGY__PROCESS_0_ONLY);
73807638 smoke_check_5(H5AC_METADATA_WRITE_STRATEGY__DISTRIBUTED);
73817639 #endif
7640 /* enable the collective metadata read property */
7641 if ( world_mpi_rank != world_server_mpi_rank ) {
7642 if ( H5Pset_coll_metadata_read(fapl, 1) < 0 ) {
7643
7644 nerrors++;
7645 if ( verbose ) {
7646 HDfprintf(stdout, "%d:%s: H5Pset_coll_metadata_read() failed 1.\n",
7647 world_mpi_rank, FUNC);
7648 }
7649 }
7650 }
7651 #if 1
7652 smoke_check_6(H5AC_METADATA_WRITE_STRATEGY__PROCESS_0_ONLY);
7653 smoke_check_6(H5AC_METADATA_WRITE_STRATEGY__DISTRIBUTED);
7654 #endif
7655
73827656 #if 1
73837657 trace_file_check(H5AC_METADATA_WRITE_STRATEGY__PROCESS_0_ONLY);
73847658 trace_file_check(H5AC_METADATA_WRITE_STRATEGY__DISTRIBUTED);
456456 VRFY((acc_tpl >= 0), "");
457457
458458 /* open the file collectively */
459 fid=H5Fopen(filename,H5F_ACC_RDONLY,acc_tpl);
459 fid = H5Fopen(filename, H5F_ACC_RDONLY, acc_tpl);
460460 VRFY((fid >= 0), "");
461461
462462 /* Release file-access template */
887887 MPI_Comm_rank(MPI_COMM_WORLD, &mpi_rank);
888888
889889 plist = create_faccess_plist(MPI_COMM_WORLD, MPI_INFO_NULL, facc_type);
890 H5Pset_coll_metadata_read(plist, 0);
890891 fid = H5Fopen(filename, H5F_ACC_RDONLY, plist);
891892 H5Pclose(plist);
892893
49474947 /* set Parallel access with communicator */
49484948 ret = H5Pset_fapl_mpio(ret_pl, comm, info);
49494949 VRFY((ret >= 0), "");
4950 ret = H5Pset_coll_metadata_read(ret_pl, true);
4951 VRFY((ret >= 0), "");
4952 ret = H5Pset_coll_metadata_write(ret_pl, true);
4953 VRFY((ret >= 0), "");
49504954 return(ret_pl);
49514955 }
49524956
271271 /* set Parallel access with communicator */
272272 ret = H5Pset_fapl_mpio(ret_pl, comm, info);
273273 VRFY((ret >= 0), "");
274 ret = H5Pset_coll_metadata_read(ret_pl, true);
275 VRFY((ret >= 0), "");
276 ret = H5Pset_coll_metadata_write(ret_pl, true);
277 VRFY((ret >= 0), "");
274278 return(ret_pl);
275279 }
276280
514514 LN_S = @LN_S@
515515 LTLIBOBJS = @LTLIBOBJS@
516516 LT_STATIC_EXEC = @LT_STATIC_EXEC@
517 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
517518 MAINT = @MAINT@
518519 MAKEINFO = @MAKEINFO@
519520 MANIFEST_TOOL = @MANIFEST_TOOL@
522522 LN_S = @LN_S@
523523 LTLIBOBJS = @LTLIBOBJS@
524524 LT_STATIC_EXEC = @LT_STATIC_EXEC@
525 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
525526 MAINT = @MAINT@
526527 MAKEINFO = @MAKEINFO@
527528 MANIFEST_TOOL = @MANIFEST_TOOL@
529529 LN_S = @LN_S@
530530 LTLIBOBJS = @LTLIBOBJS@
531531 LT_STATIC_EXEC = @LT_STATIC_EXEC@
532 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
532533 MAINT = @MAINT@
533534 MAKEINFO = @MAKEINFO@
534535 MANIFEST_TOOL = @MANIFEST_TOOL@
33 ### T E S T I N G ###
44 ##############################################################################
55 ##############################################################################
6
6
77 # --------------------------------------------------------------------
88 # Copy all the HDF5 files from the test directory into the source directory
99 # --------------------------------------------------------------------
1111 ${HDF5_TOOLS_SRC_DIR}/testfiles/charsets.ddl
1212 ${HDF5_TOOLS_SRC_DIR}/testfiles/file_space.ddl
1313 ${HDF5_TOOLS_SRC_DIR}/testfiles/filter_fail.ddl
14 ${HDF5_TOOLS_SRC_DIR}/testfiles/non_existing.ddl
1415 ${HDF5_TOOLS_SRC_DIR}/testfiles/packedbits.ddl
1516 ${HDF5_TOOLS_SRC_DIR}/testfiles/tall-1.ddl
1617 ${HDF5_TOOLS_SRC_DIR}/testfiles/tall-2.ddl
283284 )
284285 set (HDF5_ERROR_REFERENCE_TEST_FILES
285286 ${PROJECT_SOURCE_DIR}/errfiles/filter_fail.err
287 ${PROJECT_SOURCE_DIR}/errfiles/non_existing.err
286288 ${PROJECT_SOURCE_DIR}/errfiles/tall-1.err
287289 ${PROJECT_SOURCE_DIR}/errfiles/tall-2A.err
288290 ${PROJECT_SOURCE_DIR}/errfiles/tall-2A0.err
324326 ARGS -E copy_if_different ${tst_h5_file} ${dest}
325327 )
326328 endforeach (tst_h5_file ${HDF5_REFERENCE_TEST_FILES})
327
329
328330 foreach (tst_exp_file ${HDF5_REFERENCE_EXP_FILES})
329331 if (WIN32)
330332 file (READ ${HDF5_TOOLS_SRC_DIR}/testfiles/${tst_exp_file} TEST_STREAM)
372374 COMMAND ${CMAKE_COMMAND}
373375 ARGS -E copy_if_different ${HDF5_TOOLS_SOURCE_DIR}/testfiles/tbin1.ddl ${PROJECT_BINARY_DIR}/testfiles/std/tbin1LE.ddl
374376 )
375
377
376378 if (WIN32)
377379 file (READ ${HDF5_TOOLS_SRC_DIR}/testfiles/tbinregR.exp TEST_STREAM)
378380 file (WRITE ${PROJECT_BINARY_DIR}/testfiles/std/tbinregR.exp "${TEST_STREAM}")
384386 ARGS -E copy_if_different ${HDF5_TOOLS_SRC_DIR}/testfiles/tbinregR.exp ${PROJECT_BINARY_DIR}/testfiles/std/tbinregR.exp
385387 )
386388 endif (WIN32)
387
389
388390 ##############################################################################
389391 ##############################################################################
390392 ### T H E T E S T S M A C R O S ###
729731 add_test (
730732 NAME H5DUMP-clearall-objects
731733 COMMAND ${CMAKE_COMMAND}
732 -E remove
734 -E remove
733735 h5dump-help.out
734736 charsets.out
735737 charsets.out.err
737739 file_space.out.err
738740 filter_fail.out
739741 filter_fail.out.err
742 non_existing.out
743 non_existing.out.err
740744 packedbits.out
741745 packedbits.out.err
742746 tall-1.out
10741078 ADD_H5_TEST_EXPORT (trawdatafile packedbits.h5 0 --enable-error-stack -y -o)
10751079 ADD_H5_TEST_EXPORT (tnoddlfile packedbits.h5 0 --enable-error-stack -O -y -o)
10761080 ADD_H5_TEST_EXPORT (trawssetfile tdset.h5 0 --enable-error-stack -d "/dset1[1,1;;;]" -y -o)
1077
1081
10781082 ADD_H5_TEST_EXPORT_DDL (twithddlfile packedbits.h5 0 twithddl --enable-error-stack --ddl=twithddl.txt -y -o)
1079
1083
10801084 # test for maximum display datasets
10811085 ADD_H5_TEST (twidedisplay 0 --enable-error-stack -w0 packedbits.h5)
10821086
11461150 # test for named data types
11471151 ADD_H5_TEST (tcomp-2 0 --enable-error-stack -t /type1 --datatype /type2 --datatype=/group1/type3 tcompound.h5)
11481152 ADD_H5_TEST_N (tcomp-2 0 --enable-error-stack -N /type1 --any_path /type2 --any_path=/group1/type3 tcompound.h5)
1149 # test for unamed type
1153 # test for unamed type
11501154 ADD_H5ERR_MASK_TEST (tcomp-3 0 "--enable-error-stack;-t;/#6632;-g;/group2;tcompound.h5")
11511155 # test complicated compound datatype
11521156 ADD_H5_TEST (tcomp-4 0 --enable-error-stack tcompound_complex.h5)
11681172 # test for loop detection
11691173 ADD_H5_TEST (tloop-1 0 --enable-error-stack tloop.h5)
11701174
1171 # test for string
1175 # test for string
11721176 ADD_H5_TEST (tstr-1 0 --enable-error-stack tstr.h5)
11731177 ADD_H5_TEST (tstr-2 0 --enable-error-stack tstr2.h5)
11741178
12011205 #ADD_H5_MASK_TEST (tstarfile 0 --enable-error-stack -H -d Dataset1 tarr*.h5)
12021206 #ADD_H5_MASK_TEST (tqmarkfile 0 --enable-error-stack -H -d Dataset1 tarray?.h5)
12031207 ADD_H5_TEST (tmultifile 0 --enable-error-stack -H -d Dataset1 tarray2.h5 tarray3.h5 tarray4.h5 tarray5.h5 tarray6.h5 tarray7.h5)
1204
1208
12051209 # test for files with empty data
12061210 ADD_H5_TEST (tempty 0 --enable-error-stack tempty.h5)
12071211
12621266 ADD_H5_TEST (tcontiguos 0 --enable-error-stack -H -p -d contiguous tfilters.h5)
12631267 # chunked
12641268 ADD_H5_TEST (tchunked 0 --enable-error-stack -H -p -d chunked tfilters.h5)
1265 # external
1269 # external
12661270 ADD_H5_TEST (texternal 0 --enable-error-stack -H -p -d external tfilters.h5)
12671271
12681272 # fill values
13301334 # don't have). Do this by searching H5pubconf.h to see which
13311335 # filters are defined.
13321336
1333 # detect whether the encoder is present.
1337 # detect whether the encoder is present.
13341338 if (H5_HAVE_FILTER_DEFLATE)
13351339 set (USE_FILTER_DEFLATE "true")
13361340 endif (H5_HAVE_FILTER_DEFLATE)
13511355 # test for displaying objects with very long names
13521356 ADD_H5_TEST (tlonglinks 0 --enable-error-stack tlonglinks.h5)
13531357
1354 # dimensions over 4GB, print boundary
1358 # dimensions over 4GB, print boundary
13551359 ADD_H5_TEST (tbigdims 0 --enable-error-stack -d dset4gb -s 4294967284 -c 22 tbigdims.h5)
13561360
13571361 # hyperslab read
13581362 ADD_H5_TEST (thyperslab 0 --enable-error-stack thyperslab.h5)
1359
1363
13601364 # test for displaying dataset and attribute of null space
13611365 ADD_H5_TEST (tnullspace 0 --enable-error-stack tnullspace.h5)
13621366
13901394 ADD_H5_TEST (tbin4 0 --enable-error-stack -d double -b FILE -o tbin4.bin tbinary.h5)
13911395 endif (NOT HDF5_ENABLE_USING_MEMCHECKER)
13921396
1393 # test for dataset region references
1397 # test for dataset region references
13941398 ADD_H5_TEST (tdatareg 0 --enable-error-stack tdatareg.h5)
13951399 ADD_H5ERR_MASK_TEST (tdataregR 0 --enable-error-stack -R tdatareg.h5)
13961400 ADD_H5ERR_MASK_TEST (tattrregR 0 -R --enable-error-stack tattrreg.h5)
14131417 # tests for link references and order
14141418 ADD_H5ERR_MASK_TEST (torderlinks1 0 --enable-error-stack --sort_by=name --sort_order=ascending tfcontents1.h5)
14151419 ADD_H5ERR_MASK_TEST (torderlinks2 0 --enable-error-stack --sort_by=name --sort_order=descending tfcontents1.h5)
1416
1420
14171421 # tests for floating point user defined printf format
14181422 ADD_H5_TEST (tfpformat 0 --enable-error-stack -m %.7f tfpformat.h5)
14191423
14291433
14301434 # test for -o -y for dataset with attributes
14311435 ADD_H5_TEST_EXPORT (tall-6 tall.h5 0 --enable-error-stack -d /g1/g1.1/dset1.1.1 -y -o)
1436
1437 # test for non-existing file
1438 ADD_H5_TEST (non_existing 1 --enable-error-stack tgroup.h5 non_existing.h5)
529529 LN_S = @LN_S@
530530 LTLIBOBJS = @LTLIBOBJS@
531531 LT_STATIC_EXEC = @LT_STATIC_EXEC@
532 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
532533 MAINT = @MAINT@
533534 MAKEINFO = @MAKEINFO@
534535 MANIFEST_TOOL = @MANIFEST_TOOL@
0 h5dump error: unable to open file "non_existing.h5"
619619 size_count++;
620620
621621 last_digit = 1;
622 }
622 }
623623 else {
624624 last_digit = 0;
625625 }
642642 }
643643 d->data = p_list;
644644 d->len = size_count;
645
645
646646 return;
647647 }
648648
704704 *
705705 * Purpose: Parse a list of comma or space separated integers and fill
706706 * the packed_bits list and counter. The string being passed into this function
707 * should be at the start of the list you want to parse.
707 * should be at the start of the list you want to parse.
708708 *
709709 * Return: Success: SUCCEED
710710 *
830830 free_handler(struct handler_t *hand, int len)
831831 {
832832 int i;
833
833
834834 if(hand) {
835835 for (i = 0; i < len; i++) {
836836 if(hand[i].obj) {
11601160 }
11611161 if (HDstrcmp(opt_arg,":") == 0) {
11621162 xmlnsprefix = "";
1163 }
1163 }
11641164 else {
11651165 xmlnsprefix = opt_arg;
11661166 }
11861186 * the two.
11871187 */
11881188 s = last_dset->subset_info;
1189 }
1189 }
11901190 else {
11911191 last_dset->subset_info = s = (struct subset_t *)HDcalloc(1, sizeof(struct subset_t));
11921192 }
13571357 /* Disable tools error reporting */
13581358 H5Eget_auto2(H5tools_ERR_STACK_g, &tools_func, &tools_edata);
13591359 H5Eset_auto2(H5tools_ERR_STACK_g, NULL, NULL);
1360
1360
13611361 if((hand = parse_command_line(argc, argv))==NULL) {
13621362 goto done;
13631363 }
14431443 if (xml_dtd_uri == NULL) {
14441444 if (useschema) {
14451445 xml_dtd_uri = DEFAULT_XSD;
1446 }
1446 }
14471447 else {
14481448 xml_dtd_uri = DEFAULT_DTD;
14491449 xmlnsprefix = "";
14501450 }
1451 }
1451 }
14521452 else {
14531453 if (useschema && HDstrcmp(xmlnsprefix,"")) {
14541454 error_msg("Cannot set Schema URL for a qualified namespace--use -X or -U option with -D \n");
14851485 /* start to dump - display file header information */
14861486 if (!doxml) {
14871487 begin_obj(h5tools_dump_header_format->filebegin, fname, h5tools_dump_header_format->fileblockbegin);
1488 }
1488 }
14891489 else {
14901490 PRINTVALSTREAM(rawoutstream, "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n");
14911491
14941494 if (HDstrcmp(xmlnsprefix,"") == 0) {
14951495 PRINTSTREAM(rawoutstream, "<HDF5-File xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:noNamespaceSchemaLocation=\"%s\">\n",
14961496 xml_dtd_uri);
1497 }
1497 }
14981498 else {
14991499 /* TO DO: make -url option work in this case (may need new option) */
15001500 char *ns;
15101510 "http://www.hdfgroup.org/HDF5/XML/schema/HDF5-File.xsd\">\n",xmlnsprefix,ns);
15111511 HDfree(ns);
15121512 }
1513 }
1513 }
15141514 else {
15151515 PRINTSTREAM(rawoutstream, "<!DOCTYPE HDF5-File PUBLIC \"HDF5-File.dtd\" \"%s\">\n", xml_dtd_uri);
15161516 PRINTVALSTREAM(rawoutstream, "<HDF5-File>\n");
15691569 if (!doxml) {
15701570 end_obj(h5tools_dump_header_format->fileend, h5tools_dump_header_format->fileblockend);
15711571 PRINTVALSTREAM(rawoutstream, "\n");
1572 }
1572 }
15731573 else {
15741574 PRINTSTREAM(rawoutstream, "</%sHDF5-File>\n", xmlnsprefix);
15751575 }
15801580 if (H5Fclose(fid) < 0)
15811581 h5tools_setstatus(EXIT_FAILURE);
15821582
1583 if(prefix)
1583 if(prefix) {
15841584 HDfree(prefix);
1585 if(fname)
1585 prefix = NULL;
1586 }
1587 if(fname) {
15861588 HDfree(fname);
1589 fname = NULL;
1590 }
15871591 } /* end while */
15881592
1589 if(hand)
1593 if(hand)
15901594 free_handler(hand, argc);
15911595
15921596 /* To Do: clean up XML table */
16001604 if(fid >=0)
16011605 if (H5Fclose(fid) < 0)
16021606 h5tools_setstatus(EXIT_FAILURE);
1603
1604 if(prefix)
1607
1608 if(prefix) {
16051609 HDfree(prefix);
1606 if(fname)
1610 prefix = NULL;
1611 }
1612 if(fname) {
16071613 HDfree(fname);
1608
1609 if(hand)
1614 fname = NULL;
1615 }
1616
1617 if(hand)
16101618 free_handler(hand, argc);
16111619
16121620 /* To Do: clean up XML table */
16591667 if (!HDstrcmp(name, "sec2")) {
16601668 /* Unix read() and write() system calls */
16611669 if (H5Pset_fapl_sec2(fapl)<0) return -1;
1662 }
1670 }
16631671 else if (!HDstrcmp(name, "stdio")) {
16641672 /* Standard C fread() and fwrite() system calls */
16651673 if (H5Pset_fapl_stdio(fapl)<0) return -1;
1666 }
1674 }
16671675 else if (!HDstrcmp(name, "core")) {
16681676 /* In-core temporary file with 1MB increment */
16691677 if (H5Pset_fapl_core(fapl, 1024*1024, FALSE)<0) return -1;
1670 }
1678 }
16711679 else if (!HDstrcmp(name, "split")) {
16721680 /* Split meta data and raw data each using default driver */
16731681 if (H5Pset_fapl_split(fapl, "-m.h5", H5P_DEFAULT, "-r.h5", H5P_DEFAULT) < 0)
16741682 return -1;
1675 }
1683 }
16761684 else if (!HDstrcmp(name, "multi")) {
16771685 /* Multi-file driver, general case of the split driver */
16781686 H5FD_mem_t memb_map[H5FD_MEM_NTYPES];
16981706
16991707 if (H5Pset_fapl_multi(fapl, memb_map, memb_fapl, memb_name, memb_addr, FALSE) < 0)
17001708 return -1;
1701 }
1709 }
17021710 else if (!HDstrcmp(name, "family")) {
17031711 hsize_t fam_size = 100*1024*1024; /*100 MB*/
17041712
17071715 fam_size = (hsize_t)(HDstrtod(val, NULL) * 1024*1024);
17081716 if (H5Pset_fapl_family(fapl, fam_size, H5P_DEFAULT)<0)
17091717 return -1;
1710 }
1718 }
17111719 else if (!HDstrcmp(name, "log")) {
17121720 long log_flags = H5FD_LOG_LOC_IO;
17131721
17171725
17181726 if (H5Pset_fapl_log(fapl, NULL, (unsigned)log_flags, 0) < 0)
17191727 return -1;
1720 }
1728 }
17211729 else if (!HDstrcmp(name, "direct")) {
17221730 /* Substitute Direct I/O driver with sec2 driver temporarily because
17231731 * some output has sec2 driver as the standard. */
17241732 if (H5Pset_fapl_sec2(fapl)<0) return -1;
1725 }
1733 }
17261734 else {
17271735 /* Unknown driver */
17281736 return -1;
2626 DUMPER=h5dump # The tool name
2727 DUMPER_BIN=`pwd`/$DUMPER # The path of the tool binary
2828
29 H5DIFF=../h5diff/h5diff # The h5diff tool name
29 H5DIFF=../h5diff/h5diff # The h5diff tool name
3030 H5DIFF_BIN=`pwd`/$H5DIFF # The path of the h5diff tool binary
3131
32 H5IMPORT=../h5import/h5import # The h5import tool name
32 H5IMPORT=../h5import/h5import # The h5import tool name
3333 H5IMPORT_BIN=`pwd`/$H5IMPORT # The path of the h5import tool binary
3434
3535 RM='rm -rf'
175175 $SRC_H5DUMP_TESTFILES/charsets.ddl
176176 $SRC_H5DUMP_TESTFILES/file_space.ddl
177177 $SRC_H5DUMP_TESTFILES/filter_fail.ddl
178 $SRC_H5DUMP_TESTFILES/non_existing.ddl
178179 $SRC_H5DUMP_TESTFILES/packedbits.ddl
179180 $SRC_H5DUMP_TESTFILES/tall-1.ddl
180181 $SRC_H5DUMP_TESTFILES/tall-2.ddl
265266 $SRC_H5DUMP_TESTFILES/tindicesyes.ddl
266267 $SRC_H5DUMP_TESTFILES/tintsattrs.ddl
267268 $SRC_H5DUMP_TESTFILES/tlarge_objname.ddl
268 #$SRC_H5DUMP_TESTFILES/tldouble.ddl
269 #$SRC_H5DUMP_TESTFILES/tldouble.ddl
269270 $SRC_H5DUMP_TESTFILES/tlonglinks.ddl
270271 $SRC_H5DUMP_TESTFILES/tloop-1.ddl
271272 $SRC_H5DUMP_TESTFILES/tmulti.ddl
346347
347348 LIST_ERROR_TEST_FILES="
348349 ${SRC_H5DUMP_ERRORFILES}/filter_fail.err
350 ${SRC_H5DUMP_ERRORFILES}/non_existing.err
349351 ${SRC_H5DUMP_ERRORFILES}/tall-1.err
350352 ${SRC_H5DUMP_ERRORFILES}/tall-2A.err
351353 ${SRC_H5DUMP_ERRORFILES}/tall-2A0.err
392394 INODE_SDIR=`$LS -i -d $SDIR | $AWK -F' ' '{print $1}'`
393395 INODE_DDIR=`$LS -i -d $TESTDIR | $AWK -F' ' '{print $1}'`
394396 if [ "$INODE_SDIR" != "$INODE_DDIR" ]; then
395 $CP -f $tstfile $TESTDIR
397 $CP -f $tstfile $TESTDIR
396398 if [ $? -ne 0 ]; then
397399 echo "Error: FAILED to copy $tstfile ."
398
400
399401 # Comment out this to CREATE expected file
400402 exit $EXIT_FAILURE
401403 fi
440442 TOOLTEST() {
441443 # check if caseless compare and diff requested
442444 if [ "$1" = ignorecase ]; then
443 caseless="-i"
444 # replace cmp with diff which runs much longer.
445 xCMP="$DIFF -i"
446 shift
445 caseless="-i"
446 # replace cmp with diff which runs much longer.
447 xCMP="$DIFF -i"
448 shift
447449 else
448 caseless=""
449 # stick with faster cmp if ignorecase is not requested.
450 xCMP="$CMP"
450 caseless=""
451 # stick with faster cmp if ignorecase is not requested.
452 xCMP="$CMP"
451453 fi
452454
453455 expect="$TESTDIR/$1"
536538 nerrors="`expr $nerrors + 1`"
537539 test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /'
538540 fi
539
541
540542 # Clean up output file
541543 if test -z "$HDF5_NOCLEANUP"; then
542544 rm -f $actual $actualdata $actual_err
544546
545547 }
546548
547 # same as TOOLTEST2 but compares generated file to expected ddl file
549 # same as TOOLTEST2 but compares generated file to expected ddl file
548550 # and compares the generated data file to the expected data file
549551 # used for the binary tests that expect a full path in -o without -b
550552 # ADD_H5_TEST_EXPORT
602604 nerrors="`expr $nerrors + 1`"
603605 test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /'
604606 fi
605
607
606608 # Clean up output file
607609 if test -z "$HDF5_NOCLEANUP"; then
608610 rm -f $actual $actualdata $actual_err $actualmeta
641643 nerrors="`expr $nerrors + 1`"
642644 test yes = "$verbose" && $DIFF $expectdata $actualdata |sed 's/^/ /'
643645 fi
644
646
645647 # Clean up output file
646648 if test -z "$HDF5_NOCLEANUP"; then
647649 rm -f $actual $actualdata $actual_err
858860 echo " Expected output (*.txt) differs from actual output (*.out)"
859861 nerrors="`expr $nerrors + 1`"
860862 fi
861
863
862864 # Clean up output file
863865 if test -z "$HDF5_NOCLEANUP"; then
864866 rm -f $actual $actual_err
871873 TESTING $DUMPER $@
872874 echo " -SKIP-"
873875 }
874
876
875877 # Print a line-line message left justified in a field of 70 characters
876878 #
877879 PRINT_H5DIFF() {
882884
883885 # Call the h5diff tool
884886 #
885 DIFFTEST()
887 DIFFTEST()
886888 {
887889 PRINT_H5DIFF $@
888890 (
896898 else
897899 echo " PASSED"
898900 fi
899
901
900902 }
901903
902904 # Print a line-line message left justified in a field of 70 characters
909911
910912 # Call the h5import tool
911913 #
912 IMPORTTEST()
914 IMPORTTEST()
913915 {
914916 # remove the output hdf5 file if it exists
915917 hdf5_file="$TESTDIR/$5"
920922 PRINT_H5IMPORT $@
921923 (
922924 cd $TESTDIR
923 $RUNSERIAL $H5IMPORT_BIN "$@"
925 $RUNSERIAL $H5IMPORT_BIN "$@"
924926 )
925927 RET=$?
926928 if [ $RET != 0 ] ; then
929931 else
930932 echo " PASSED"
931933 fi
932
934
933935 }
934936
935937
10201022 # test for named data types
10211023 TOOLTEST tcomp-2.ddl --enable-error-stack -t /type1 --datatype /type2 --datatype=/group1/type3 tcompound.h5
10221024 TOOLTEST tcomp-2.ddl --enable-error-stack -N /type1 --any_path /type2 --any_path=/group1/type3 tcompound.h5
1023 # test for unamed type
1025 # test for unamed type
10241026 TOOLTEST4 tcomp-3.ddl --enable-error-stack -t /#6632 -g /group2 tcompound.h5
10251027 # test complicated compound datatype
10261028 TOOLTEST tcomp-4.ddl --enable-error-stack tcompound_complex.h5
10401042 # test for loop detection
10411043 TOOLTEST tloop-1.ddl --enable-error-stack tloop.h5
10421044
1043 # test for string
1045 # test for string
10441046 TOOLTEST tstr-1.ddl --enable-error-stack tstr.h5
10451047 TOOLTEST tstr-2.ddl --enable-error-stack tstr2.h5
10461048
11351137 TOOLTEST tcontiguos.ddl --enable-error-stack -H -p -d contiguous tfilters.h5
11361138 # chunked
11371139 TOOLTEST tchunked.ddl --enable-error-stack -H -p -d chunked tfilters.h5
1138 # external
1140 # external
11391141 TOOLTEST texternal.ddl --enable-error-stack -H -p -d external tfilters.h5
11401142
11411143 # fill values
12041206 # test for displaying objects with very long names
12051207 TOOLTEST tlonglinks.ddl --enable-error-stack tlonglinks.h5
12061208
1207 # dimensions over 4GB, print boundary
1209 # dimensions over 4GB, print boundary
12081210 TOOLTEST tbigdims.ddl --enable-error-stack -d dset4gb -s 4294967284 -c 22 tbigdims.h5
12091211
12101212 # hyperslab read
12121214
12131215
12141216 #
1215
1217
12161218 # test for displaying dataset and attribute of null space
12171219 TOOLTEST tnullspace.ddl --enable-error-stack tnullspace.h5
12181220
12511253 DIFFTEST tbinary.h5 out3D.h5 /integer /integer
12521254
12531255 TOOLTEST tbin4.ddl --enable-error-stack -d double -b FILE -o out4.bin tbinary.h5
1254
1256
12551257 # Clean up binary output files
12561258 if test -z "$HDF5_NOCLEANUP"; then
12571259 rm -f out[1-4].bin
12591261 rm -f out3.h5
12601262 fi
12611263
1262 # test for dataset region references
1264 # test for dataset region references
12631265 TOOLTEST tdatareg.ddl --enable-error-stack tdatareg.h5
12641266 TOOLTEST4 tdataregR.ddl --enable-error-stack -R tdatareg.h5
12651267 TOOLTEST tattrreg.ddl --enable-error-stack tattrreg.h5
13041306
13051307 # test for -o -y for dataset with attributes
13061308 TOOLTEST2 tall-6.exp --enable-error-stack -y -o tall-6.txt -d /g1/g1.1/dset1.1.1 tall.h5
1309
1310 # test for non-existing file
1311 TOOLTEST3 non_existing.ddl --enable-error-stack tgroup.h5 non_existing.h5
13071312
13081313 # Clean up temporary files/directories
13091314 CLEAN_TESTFILES_AND_TESTDIR
527527 LN_S = @LN_S@
528528 LTLIBOBJS = @LTLIBOBJS@
529529 LT_STATIC_EXEC = @LT_STATIC_EXEC@
530 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
530531 MAINT = @MAINT@
531532 MAKEINFO = @MAKEINFO@
532533 MANIFEST_TOOL = @MANIFEST_TOOL@
171171 {
172172 hid_t fid = -1; /* file id */
173173 hid_t fapl = -1; /* file access property list */
174 hid_t fcpl = -1; /* file creation property list */
174175 hid_t gid = -1; /* group id */
175176 hid_t sid = -1; /* space id */
176177 hid_t dcpl = -1; /* dataset creation property id */
187188 if(H5Pset_libver_bounds(fapl, H5F_LIBVER_LATEST, H5F_LIBVER_LATEST) < 0)
188189 goto error;
189190
190 if((fid = H5Fcreate(fname, H5F_ACC_TRUNC, H5P_DEFAULT, fapl)) < 0)
191 if((fcpl = H5Pcreate(H5P_FILE_CREATE)) < 0)
192 goto error;
193 if(H5Pset_shared_mesg_nindexes(fcpl, 4) < 0)
194 goto error;
195
196 if((fid = H5Fcreate(fname, H5F_ACC_TRUNC, fcpl, fapl)) < 0)
191197 goto error;
192198
193199 /* Create a group */
364370 gen_non(const char *fname)
365371 {
366372 hid_t fid = -1; /* file id */
373 hid_t fcpl = -1; /* file creation property list */
367374 hid_t gid = -1; /* group id */
368375 hid_t sid = -1; /* space id */
369376 hid_t dcpl = -1; /* dataset creation property id */
375382 int i; /* local index variable */
376383 int buf[24]; /* data buffer */
377384
385 if((fcpl = H5Pcreate(H5P_FILE_CREATE)) < 0)
386 goto error;
387 if(H5Pset_shared_mesg_nindexes(fcpl, 4) < 0)
388 goto error;
389 if(H5Pset_istore_k(fcpl, 64) < 0)
390 goto error;
391
378392 /* Create a new file with SWMR_WRITE + non-latest-format */
379 if((fid = H5Fcreate(fname, H5F_ACC_TRUNC|H5F_ACC_SWMR_WRITE, H5P_DEFAULT, H5P_DEFAULT)) < 0)
393 if((fid = H5Fcreate(fname, H5F_ACC_TRUNC|H5F_ACC_SWMR_WRITE, fcpl, H5P_DEFAULT)) < 0)
380394 goto error;
381395
382396 /* Create a group */
376376 H5E_auto2_t func;
377377 void *edata;
378378 hid_t fid = -1;
379 hid_t fcpl = -1;
380 H5F_file_space_type_t strategy;
381 hsize_t threshold;
379382
380383 h5tools_setprogname(PROGRAMNAME);
381384 h5tools_setstatus(EXIT_SUCCESS);
403406 goto done;
404407 } else if(verbose_g)
405408 printf("Open the file %s\n", fname_g);
409
410 /* A temporaray fix:
411 * need to handle H5O_FSINFO_ID message when downgrade superblock version from 3 to 2
412 */
413 if((fcpl = H5Fget_create_plist(fid)) < 0) {
414 error_msg("unable to get file creation property list for \"%s\"\n", fname_g);
415 h5tools_setstatus(EXIT_FAILURE);
416 goto done;
417 }
418 if(H5Pget_file_space(fcpl, &strategy, &threshold) < 0) {
419 error_msg("unable to get file space strategy/threshold\n");
420 h5tools_setstatus(EXIT_FAILURE);
421 goto done;
422 }
423 /* Check for non-default strategy/threshold:
424 * --whether there is H5O_FSINFO_ID message in the superblock extension
425 */
426 if(strategy != H5F_FILE_SPACE_ALL || threshold != 1) {
427 error_msg("unable to convert due to non-default file space strategy/threshold\n");
428 h5tools_setstatus(EXIT_FAILURE);
429 goto done;
430 }
406431
407432 if(dset_g) { /* Convert a specified dataset in the file */
408433 if(verbose_g)
416441 goto done;
417442 }
418443
444 if(verbose_g) {
445 if(noop_g) {
446 printf("Not processing the file's superblock version...\n");
447 h5tools_setstatus(EXIT_SUCCESS);
448 goto done;
449 }
450 printf("Processing the file's superblock version...\n");
451 }
452
453 if(H5Fformat_convert_super(fid) < 0) {
454 error_msg("unable to convert file's superblock version\"%s\"\n", fname_g);
455 h5tools_setstatus(EXIT_FAILURE);
456 goto done;
457 }
458
419459 done:
420460 /* Close the file */
421461 if(fid >= 0) {
2222 Chunk indexing type is already version 1 B-tree: no further action
2323 Close the dataset
2424 Close the dataset creation property list
25 Processing the file's superblock version...
2526 Close the file
77 Chunk indexing type is already version 1 B-tree: no further action
88 Close the dataset
99 Close the dataset creation property list
10 Processing the file's superblock version...
1011 Close the file
99 Not converting the dataset
1010 Close the dataset
1111 Close the dataset creation property list
12 Not processing the file's superblock version...
1213 Close the file
4343 Dataset is not chunked: no further action
4444 Close the dataset
4545 Close the dataset creation property list
46 Not processing the file's superblock version...
4647 Close the file
88 Chunk indexing type is already version 1 B-tree: no further action
99 Close the dataset
1010 Close the dataset creation property list
11 Not processing the file's superblock version...
1112 Close the file
55 Dataset is not chunked: no further action
66 Close the dataset
77 Close the dataset creation property list
8 Processing the file's superblock version...
89 Close the file
522522 LN_S = @LN_S@
523523 LTLIBOBJS = @LTLIBOBJS@
524524 LT_STATIC_EXEC = @LT_STATIC_EXEC@
525 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
525526 MAINT = @MAINT@
526527 MAKEINFO = @MAKEINFO@
527528 MANIFEST_TOOL = @MANIFEST_TOOL@
534534 LN_S = @LN_S@
535535 LTLIBOBJS = @LTLIBOBJS@
536536 LT_STATIC_EXEC = @LT_STATIC_EXEC@
537 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
537538 MAINT = @MAINT@
538539 MAKEINFO = @MAKEINFO@
539540 MANIFEST_TOOL = @MANIFEST_TOOL@
514514 LN_S = @LN_S@
515515 LTLIBOBJS = @LTLIBOBJS@
516516 LT_STATIC_EXEC = @LT_STATIC_EXEC@
517 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
517518 MAINT = @MAINT@
518519 MAKEINFO = @MAKEINFO@
519520 MANIFEST_TOOL = @MANIFEST_TOOL@
546546 LN_S = @LN_S@
547547 LTLIBOBJS = @LTLIBOBJS@
548548 LT_STATIC_EXEC = @LT_STATIC_EXEC@
549 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
549550 MAINT = @MAINT@
550551 MAKEINFO = @MAKEINFO@
551552 MANIFEST_TOOL = @MANIFEST_TOOL@
16021602
16031603 puts("All h5repack tests passed.");
16041604
1605 h5tools_close();
1606
16051607 return 0;
16061608
16071609 error:
524524 LN_S = @LN_S@
525525 LTLIBOBJS = @LTLIBOBJS@
526526 LT_STATIC_EXEC = @LT_STATIC_EXEC@
527 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
527528 MAINT = @MAINT@
528529 MAKEINFO = @MAKEINFO@
529530 MANIFEST_TOOL = @MANIFEST_TOOL@
511511 LN_S = @LN_S@
512512 LTLIBOBJS = @LTLIBOBJS@
513513 LT_STATIC_EXEC = @LT_STATIC_EXEC@
514 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
514515 MAINT = @MAINT@
515516 MAKEINFO = @MAKEINFO@
516517 MANIFEST_TOOL = @MANIFEST_TOOL@
609609 LN_S = @LN_S@
610610 LTLIBOBJS = @LTLIBOBJS@
611611 LT_STATIC_EXEC = @LT_STATIC_EXEC@
612 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
612613 MAINT = @MAINT@
613614 MAKEINFO = @MAKEINFO@
614615 MANIFEST_TOOL = @MANIFEST_TOOL@
530530 LN_S = @LN_S@
531531 LTLIBOBJS = @LTLIBOBJS@
532532 LT_STATIC_EXEC = @LT_STATIC_EXEC@
533 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
533534 MAINT = @MAINT@
534535 MAKEINFO = @MAKEINFO@
535536 MANIFEST_TOOL = @MANIFEST_TOOL@
552552 LN_S = @LN_S@
553553 LTLIBOBJS = @LTLIBOBJS@
554554 LT_STATIC_EXEC = @LT_STATIC_EXEC@
555 LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@
555556 MAINT = @MAINT@
556557 MAKEINFO = @MAKEINFO@
557558 MANIFEST_TOOL = @MANIFEST_TOOL@
0 HDF5 "tgroup.h5" {
1 GROUP "/" {
2 GROUP "g1" {
3 GROUP "g1.1" {
4 }
5 GROUP "g1.2" {
6 }
7 }
8 GROUP "g2" {
9 GROUP "g2.1" {
10 GROUP "g2.1.1" {
11 }
12 GROUP "g2.1.2" {
13 }
14 GROUP "g2.1.3" {
15 }
16 }
17 }
18 GROUP "g3" {
19 GROUP "g3.1" {
20 }
21 GROUP "g3.2" {
22 }
23 GROUP "g3.3" {
24 }
25 GROUP "g3.4" {
26 }
27 }
28 }
29 }
30 h5dump error: unable to open file "non_existing.h5"