OverviewFilesCommitsIssuesDocsReleasesPeers

opencog-CompactHash commits / 92a0918

Converting from autoconf to cmake
92a091853413ff00c6bb220aa183510ad8e81235
by brobey <brobey@lanl.gov> · 2016-01-24T05:22:25.000Z

Changed files (25) +495 -36670

CMakeLists.txt +117 -0
……@@ -0,0 +1,117 @@
1cmake_minimum_required(VERSION 2.6)
2project (CompactHash)
3# The version number.
4set (COMPACTHASH_VERSION_MAJOR 1)
5set (COMPACTHASH_VERSION_MINOR 2.0)
6set (COMPACTHASH_VERSION "${COMPACTHASH_VERSION_MAJOR}.${COMPACTHASH_VERSION_MINOR}")
7
8set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
9# --- custom targets: ---
10INCLUDE( cmake/Modules/TargetDistclean.cmake OPTIONAL)
11
12if (NOT CMAKE_BUILD_TYPE)
13# set(CMAKE_BUILD_TYPE RelWithDebInfo)
14 set(CMAKE_BUILD_TYPE Release)
15endif(NOT CMAKE_BUILD_TYPE)
16
17# uncomment to build debug
18#set(CMAKE_BUILD_TYPE Debug)
19
20if ("${CMAKE_C_COMPILER_ID}" STREQUAL "Clang")
21 # using Clang
22 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -ftree-vectorize")
23 #set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -ftree-vectorize -ftree-vectorizer-verbose=5")
24elseif ("${CMAKE_C_COMPILER_ID}" STREQUAL "GNU")
25 # using GCC
26 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -ftree-vectorize -std=c99")
27 #set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -ftree-vectorize -ftree-vectorizer-verbose=5")
28elseif ("${CMAKE_C_COMPILER_ID}" STREQUAL "Intel")
29 # using Intel C
30# set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -vec-report3 -std=c99")
31 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
32elseif ("${CMAKE_C_COMPILER_ID}" STREQUAL "MSVC")
33 # using Visual Studio C++
34endif()
35
36set(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -Wall -g -O0 -Wextra")
37set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -O3")
38set(CMAKE_C_FLAGS_RELWITHDEBINFO "${CMAKE_C_FLAGS_RELDEBINFO} -g -O3")
39
40if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
41 # using Clang
42 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ftree-vectorize")
43 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ftree-vectorize")
44 #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ftree-vectorize -ftree-vectorizer-verbose=5")
45elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
46 # using GCC
47 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ftree-vectorize")
48 #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ftree-vectorize -ftree-vectorizer-verbose=5")
49elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Intel")
50 # using Intel C++
51 #set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -vec-report3")
52elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC")
53 # using Visual Studio C++
54endif()
55
56set(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -Wall -g -O0 -Wextra")
57set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -O3")
58set(CMAKE_C_FLAGS_RELWITHDEBINFO "${CMAKE_C_FLAGS_RELDEBINFO} -g -O3")
59
60set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -Wall -g -O0 -Wextra")
61set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -O3")
62set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELDEBINFO} -g -O3")
63
64if (MIC_NATIVE)
65 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -static-intel -mmic")
66 link_directories("/projects/opt/intel/compilers/parallel_studio_xe_2013/composer_xe_2013_sp1.2.144/compiler/lib/mic")
67endif (MIC_NATIVE)
68
69#message("CMAKE_C_FLAGS ${CMAKE_C_FLAGS}")
70
71#if (NOT MIC_NATIVE)
72 find_package(OpenCL)
73 # OPENCL_FOUND : TRUE if found, FALSE otherwise
74 # OPENCL_INCLUDE_DIRS : Include directories for OpenCL
75 # OPENCL_LIBRARIES : The libraries to link against
76 if (OPENCL_FOUND)
77 include_directories(${OPENCL_INCLUDE_DIRS})
78 endif (OPENCL_FOUND)
79#endif (NOT MIC_NATIVE)
80
81#find_package(MPI)
82#if (MPI_FOUND)
83# include_directories(${MPI_INCLUDE_PATH})
84#endif (MPI_FOUND)
85
86add_subdirectory(HashFactory)
87add_subdirectory(kdtree)
88add_subdirectory(timer)
89add_subdirectory(simplehash)
90
91#### global settings #######
92
93set (NEIGH2D_SRCS neigh2d.c gpu.c)
94set (NEIGH2D_HDRS gpu.h)
95
96########### embed source target ############
97
98#add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/neigh2d_kern.inc
99# COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/embed_source.pl
100# ${CMAKE_CURRENT_SOURCE_DIR}/neigh2d_kern.cl >
101# ${CMAKE_CURRENT_BINARY_DIR}/neigh2d_kern.inc
102# DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/neigh2d_kern.cl ${CMAKE_CURRENT_SOURCE_DIR}/embed_source.pl)
103#add_custom_target(neigh2d_kernel_source ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/neigh2d_kern.inc)
104
105########### neigh2d target ###############
106
107add_executable(neigh2d ${NEIGH2D_SRCS} ${NEIGH2D_HDRS})
108target_link_libraries(neigh2d HashFactory simplehash kdtree timer m)
109if (OPENCL_FOUND)
110 set_target_properties(neigh2d PROPERTIES COMPILE_DEFINITIONS "HAVE_OPENCL")
111 target_link_libraries(neigh2d ${OPENCL_LIBRARIES})
112# add_dependencies(neigh2d neigh2d_kernel_source)
113endif(OPENCL_FOUND)
114
115########### clean
116SET_DIRECTORY_PROPERTIES(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES
117 "")
HashFactory/CMakeLists.txt +51 -0
……@@ -0,0 +1,51 @@
1set(libHashFactory_LIB_SRCS CLHash_Utilities.c HashFactory.c CLHash_Utilities.h HashFactory.h)
2
3set(INDENT indent)
4set(CPREPROCESSOR cpp)
5
6#COMMAND ${CPREPROCESSOR} -CC -x c -imacros HashFactory.hm HashFactory.hp | ${INDENT} -linux -brf -o HashFactory.h
7
8########### generate sources target ###############
9add_custom_target(HashFactory.h ALL
10 DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/HashFactory.hm ${CMAKE_CURRENT_SOURCE_DIR}/HashFactory.hp
11 ${CMAKE_CURRENT_SOURCE_DIR}/perfectHash.hm ${CMAKE_CURRENT_SOURCE_DIR}/compactHash.hm
12 COMMAND cpp -P -CC -x c -imacros HashFactory.hm HashFactory.hp | indent -linux -brf -o HashFactory.h)
13
14add_custom_target(HashFactory.c ALL
15 DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/HashFactory.cm ${CMAKE_CURRENT_SOURCE_DIR}/HashFactory.cp
16 ${CMAKE_CURRENT_SOURCE_DIR}/perfectHash.cm ${CMAKE_CURRENT_SOURCE_DIR}/compactHash.cm
17 HashFactory.cl HashFactory.h
18 COMMAND cpp -P -CC -x c -imacros HashFactory.cm HashFactory.cp | indent -linux -brf |
19 sed -e '/OMP_PRAGMA_PARALLEL_FOR/s/[[:space:]]*OMP_PRAGMA_PARALLEL_FOR\;/\#pragma omp parallel for/' > HashFactory.c &&
20 ${CMAKE_CURRENT_SOURCE_DIR}/embed_source.pl HashFactory.cl >> ${CMAKE_CURRENT_BINARY_DIR}/HashFactory.c)
21
22add_custom_target(HashFactory.cl ALL
23 DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/HashFactory.clp ${CMAKE_CURRENT_SOURCE_DIR}/HashFactory.cm
24 ${CMAKE_CURRENT_SOURCE_DIR}/perfectHash.cm ${CMAKE_CURRENT_SOURCE_DIR}/compactHash.cm
25 COMMAND cpp -P -CC -x c -imacros HashFactory.cm HashFactory.clp | indent -linux -brf -o HashFactory.cl)
26
27########### embed source target ###############
28add_custom_target(HashFactory_source.inc ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/HashFactory.cl
29 COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/embed_source.pl
30 ${CMAKE_CURRENT_SOURCE_DIR}/HashFactory.cl > ${CMAKE_CURRENT_BINARY_DIR}/HashFactory_source.inc
31 DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/HashFactory.cl ${CMAKE_CURRENT_SOURCE_DIR}/embed_source.pl)
32
33########## HashFactory target ##############
34add_library(HashFactory STATIC ${libHashFactory_LIB_SRCS})
35if (OPENCL_FOUND)
36 set_target_properties(HashFactory PROPERTIES COMPILE_DEFINITIONS "HAVE_OPENCL")
37 add_dependencies(HashFactory HashFactory_source.inc)
38endif (OPENCL_FOUND)
39
40########## HashFactory_openmp target ##############
41if (OPENMP_FOUND)
42 add_library(HashFactory_openmp STATIC ${libHashFactory_LIB_SRCS})
43 set_target_properties(HashFactory_openmp PROPERTIES COMPILE_FLAGS "${OpenMP_C_FLAGS}")
44 if (OPENCL_FOUND)
45 set_target_properties(HashFactory_openmp PROPERTIES COMPILE_DEFINITIONS "HAVE_OPENCL")
46 endif (OPENCL_FOUND)
47endif (OPENMP_FOUND)
48
49########### clean files ################
50SET_DIRECTORY_PROPERTIES(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES
51"HashFactory_source.inc;")
HashFactory/Makefile.am +0 -36
……@@ -1,36 +0,0 @@
1default: HashFactory.c CLHash_Utilities.c HashFactory.cl libHashFactory.la
2all: HashFactory.c CLHash_Utilities.c HashFactory.cl libHashFactory.la
3test: hashTest
4
5AM_MAKEFLAGS = -j 4
6
7DEFAULT_INCLUDES=-I. -I..
8
9lib_LTLIBRARIES = libHashFactory.la
10include_HEADERS = HashFactory.h
11bin_PROGRAMS = hashTest
12
13hashTest_CPPFLAGS = -DHAVE_OPENCL -DHAVE_CL_DOUBLE -I$(OPENCL_INCLUDE)
14
15H_SRCS = HashFactory.h CLHash_Utilities.h
16
17C_SRCS = HashFactory.c CLHash_Utilities.c
18
19libHashFactory_la_SOURCES = ${C_SRCS} ${H_SRCS}
20hashTest_SOURCES = testHelper.c hashTest.c
21hashTest_LDADD = libHashFactory.la
22
23HashFactory.h: HashFactory.hp HashFactory.hm perfectHash.hm compactHash.hm
24 ${CPREPROCESSOR} -CC -x c -imacros HashFactory.hm HashFactory.hp | ${INDENT} -linux -brf -o HashFactory.h
25
26HashFactory.c: HashFactory.cp HashFactory.cm HashFactory.cl perfectHash.cm compactHash.cm HashFactory.h
27 ${CPREPROCESSOR} -CC -x c -imacros HashFactory.cm HashFactory.cp | ${INDENT} -linux -brf | \
28 sed -e '/OMP_PRAGMA_PARALLEL_FOR/s/[[:space:]]*OMP_PRAGMA_PARALLEL_FOR;/#pragma omp parallel for/' > HashFactory.c
29 ./embed_source.pl HashFactory.cl >> HashFactory.c
30
31HashFactory.cl: HashFactory.clp HashFactory.cm perfectHash.cm compactHash.cm
32 ${CPREPROCESSOR} -CC -x c -imacros HashFactory.cm HashFactory.clp | ${INDENT} -linux -brf -o HashFactory.cl
33
34EXTRA_DIST = perfectHash.cm perfectHash.hm primetest.c testHelper.h HashFactory.hp \
35 HashFactory.hm HashFactory.cp HashFactory.cm HashFactory.h HashFactory.c HashFactory.cl HashFactory.clp embed_source.pl \
36 compactHash.cm compactHash.hm baseHash.cm baseHash.hm
HashFactory/Makefile.in +0 -782
……@@ -1,782 +0,0 @@
1# Makefile.in generated by automake 1.13.4 from Makefile.am.
2# @configure_input@
3
4# Copyright (C) 1994-2013 Free Software Foundation, Inc.
5
6# This Makefile.in is free software; the Free Software Foundation
7# gives unlimited permission to copy and/or distribute it,
8# with or without modifications, as long as this notice is preserved.
9
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
12# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
13# PARTICULAR PURPOSE.
14
15@SET_MAKE@
16
17
18
19VPATH = @srcdir@
20am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
21am__make_running_with_option = \
22 case $${target_option-} in \
23 ?) ;; \
24 *) echo "am__make_running_with_option: internal error: invalid" \
25 "target option '$${target_option-}' specified" >&2; \
26 exit 1;; \
27 esac; \
28 has_opt=no; \
29 sane_makeflags=$$MAKEFLAGS; \
30 if $(am__is_gnu_make); then \
31 sane_makeflags=$$MFLAGS; \
32 else \
33 case $$MAKEFLAGS in \
34 *\\[\ \ ]*) \
35 bs=\\; \
36 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
37 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
38 esac; \
39 fi; \
40 skip_next=no; \
41 strip_trailopt () \
42 { \
43 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
44 }; \
45 for flg in $$sane_makeflags; do \
46 test $$skip_next = yes && { skip_next=no; continue; }; \
47 case $$flg in \
48 *=*|--*) continue;; \
49 -*I) strip_trailopt 'I'; skip_next=yes;; \
50 -*I?*) strip_trailopt 'I';; \
51 -*O) strip_trailopt 'O'; skip_next=yes;; \
52 -*O?*) strip_trailopt 'O';; \
53 -*l) strip_trailopt 'l'; skip_next=yes;; \
54 -*l?*) strip_trailopt 'l';; \
55 -[dEDm]) skip_next=yes;; \
56 -[JT]) skip_next=yes;; \
57 esac; \
58 case $$flg in \
59 *$$target_option*) has_opt=yes; break;; \
60 esac; \
61 done; \
62 test $$has_opt = yes
63am__make_dryrun = (target_option=n; $(am__make_running_with_option))
64am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
65pkgdatadir = $(datadir)/@PACKAGE@
66pkgincludedir = $(includedir)/@PACKAGE@
67pkglibdir = $(libdir)/@PACKAGE@
68pkglibexecdir = $(libexecdir)/@PACKAGE@
69am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
70install_sh_DATA = $(install_sh) -c -m 644
71install_sh_PROGRAM = $(install_sh) -c
72install_sh_SCRIPT = $(install_sh) -c
73INSTALL_HEADER = $(INSTALL_DATA)
74transform = $(program_transform_name)
75NORMAL_INSTALL = :
76PRE_INSTALL = :
77POST_INSTALL = :
78NORMAL_UNINSTALL = :
79PRE_UNINSTALL = :
80POST_UNINSTALL = :
81build_triplet = @build@
82host_triplet = @host@
83bin_PROGRAMS = hashTest$(EXEEXT)
84subdir = HashFactory
85DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
86 $(top_srcdir)/./config/depcomp $(include_HEADERS) README
87ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
88am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
89 $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
90 $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
91 $(top_srcdir)/configure.ac
92am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
93 $(ACLOCAL_M4)
94mkinstalldirs = $(install_sh) -d
95CONFIG_CLEAN_FILES =
96CONFIG_CLEAN_VPATH_FILES =
97am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
98am__vpath_adj = case $$p in \
99 $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
100 *) f=$$p;; \
101 esac;
102am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
103am__install_max = 40
104am__nobase_strip_setup = \
105 srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
106am__nobase_strip = \
107 for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
108am__nobase_list = $(am__nobase_strip_setup); \
109 for p in $$list; do echo "$$p $$p"; done | \
110 sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
111 $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
112 if (++n[$$2] == $(am__install_max)) \
113 { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
114 END { for (dir in files) print dir, files[dir] }'
115am__base_list = \
116 sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
117 sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
118am__uninstall_files_from_dir = { \
119 test -z "$$files" \
120 || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
121 || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
122 $(am__cd) "$$dir" && rm -f $$files; }; \
123 }
124am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(bindir)" \
125 "$(DESTDIR)$(includedir)"
126LTLIBRARIES = $(lib_LTLIBRARIES)
127libHashFactory_la_LIBADD =
128am__objects_1 = HashFactory.lo CLHash_Utilities.lo
129am__objects_2 =
130am_libHashFactory_la_OBJECTS = $(am__objects_1) $(am__objects_2)
131libHashFactory_la_OBJECTS = $(am_libHashFactory_la_OBJECTS)
132AM_V_lt = $(am__v_lt_@AM_V@)
133am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
134am__v_lt_0 = --silent
135am__v_lt_1 =
136PROGRAMS = $(bin_PROGRAMS)
137am_hashTest_OBJECTS = hashTest-testHelper.$(OBJEXT) \
138 hashTest-hashTest.$(OBJEXT)
139hashTest_OBJECTS = $(am_hashTest_OBJECTS)
140hashTest_DEPENDENCIES = libHashFactory.la
141AM_V_P = $(am__v_P_@AM_V@)
142am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
143am__v_P_0 = false
144am__v_P_1 = :
145AM_V_GEN = $(am__v_GEN_@AM_V@)
146am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
147am__v_GEN_0 = @echo " GEN " $@;
148am__v_GEN_1 =
149AM_V_at = $(am__v_at_@AM_V@)
150am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
151am__v_at_0 = @
152am__v_at_1 =
153depcomp = $(SHELL) $(top_srcdir)/./config/depcomp
154am__depfiles_maybe = depfiles
155am__mv = mv -f
156COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
157 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
158LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
159 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
160 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
161 $(AM_CFLAGS) $(CFLAGS)
162AM_V_CC = $(am__v_CC_@AM_V@)
163am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
164am__v_CC_0 = @echo " CC " $@;
165am__v_CC_1 =
166CCLD = $(CC)
167LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
168 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
169 $(AM_LDFLAGS) $(LDFLAGS) -o $@
170AM_V_CCLD = $(am__v_CCLD_@AM_V@)
171am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
172am__v_CCLD_0 = @echo " CCLD " $@;
173am__v_CCLD_1 =
174SOURCES = $(libHashFactory_la_SOURCES) $(hashTest_SOURCES)
175DIST_SOURCES = $(libHashFactory_la_SOURCES) $(hashTest_SOURCES)
176am__can_run_installinfo = \
177 case $$AM_UPDATE_INFO_DIR in \
178 n|no|NO) false;; \
179 *) (install-info --version) >/dev/null 2>&1;; \
180 esac
181HEADERS = $(include_HEADERS)
182am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
183# Read a list of newline-separated strings from the standard input,
184# and print each of them once, without duplicates. Input order is
185# *not* preserved.
186am__uniquify_input = $(AWK) '\
187 BEGIN { nonempty = 0; } \
188 { items[$$0] = 1; nonempty = 1; } \
189 END { if (nonempty) { for (i in items) print i; }; } \
190'
191# Make sure the list of sources is unique. This is necessary because,
192# e.g., the same source file might be shared among _SOURCES variables
193# for different programs/libraries.
194am__define_uniq_tagged_files = \
195 list='$(am__tagged_files)'; \
196 unique=`for i in $$list; do \
197 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
198 done | $(am__uniquify_input)`
199ETAGS = etags
200CTAGS = ctags
201DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
202ACLOCAL = @ACLOCAL@
203AMTAR = @AMTAR@
204AM_CPPFLAGS = @AM_CPPFLAGS@
205AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
206AR = @AR@
207AUTOCONF = @AUTOCONF@
208AUTOHEADER = @AUTOHEADER@
209AUTOMAKE = @AUTOMAKE@
210AWK = @AWK@
211CC = @CC@
212CCDEPMODE = @CCDEPMODE@
213CFLAGS = @CFLAGS@
214CPP = @CPP@
215CPPFLAGS = @CPPFLAGS@
216CPREPROCESSOR = @CPREPROCESSOR@
217CXX = @CXX@
218CXXCPP = @CXXCPP@
219CXXDEPMODE = @CXXDEPMODE@
220CXXFLAGS = @CXXFLAGS@
221CYGPATH_W = @CYGPATH_W@
222DEFS = @DEFS@
223DEPDIR = @DEPDIR@
224DLLTOOL = @DLLTOOL@
225DSYMUTIL = @DSYMUTIL@
226DUMPBIN = @DUMPBIN@
227ECHO_C = @ECHO_C@
228ECHO_N = @ECHO_N@
229ECHO_T = @ECHO_T@
230EGREP = @EGREP@
231EXEEXT = @EXEEXT@
232FGREP = @FGREP@
233GREP = @GREP@
234HAVE_ADDR2LINE = @HAVE_ADDR2LINE@
235INDENT = @INDENT@
236INSTALL = @INSTALL@
237INSTALL_DATA = @INSTALL_DATA@
238INSTALL_PROGRAM = @INSTALL_PROGRAM@
239INSTALL_SCRIPT = @INSTALL_SCRIPT@
240INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
241LD = @LD@
242LDFLAGS = @LDFLAGS@
243LIBOBJS = @LIBOBJS@
244LIBS = @LIBS@
245LIBTOOL = @LIBTOOL@
246LIPO = @LIPO@
247LN_S = @LN_S@
248LTLIBOBJS = @LTLIBOBJS@
249MAKEINFO = @MAKEINFO@
250MANIFEST_TOOL = @MANIFEST_TOOL@
251MKDIR_P = @MKDIR_P@
252NM = @NM@
253NMEDIT = @NMEDIT@
254OBJDUMP = @OBJDUMP@
255OBJEXT = @OBJEXT@
256OTOOL = @OTOOL@
257OTOOL64 = @OTOOL64@
258PACKAGE = @PACKAGE@
259PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
260PACKAGE_NAME = @PACKAGE_NAME@
261PACKAGE_STRING = @PACKAGE_STRING@
262PACKAGE_TARNAME = @PACKAGE_TARNAME@
263PACKAGE_URL = @PACKAGE_URL@
264PACKAGE_VERSION = @PACKAGE_VERSION@
265PATH_SEPARATOR = @PATH_SEPARATOR@
266RANLIB = @RANLIB@
267SED = @SED@
268SET_MAKE = @SET_MAKE@
269SHELL = @SHELL@
270STRIP = @STRIP@
271VERSION = @VERSION@
272abs_builddir = @abs_builddir@
273abs_srcdir = @abs_srcdir@
274abs_top_builddir = @abs_top_builddir@
275abs_top_srcdir = @abs_top_srcdir@
276ac_ct_AR = @ac_ct_AR@
277ac_ct_CC = @ac_ct_CC@
278ac_ct_CXX = @ac_ct_CXX@
279ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
280am__include = @am__include@
281am__leading_dot = @am__leading_dot@
282am__quote = @am__quote@
283am__tar = @am__tar@
284am__untar = @am__untar@
285bindir = @bindir@
286build = @build@
287build_alias = @build_alias@
288build_cpu = @build_cpu@
289build_os = @build_os@
290build_vendor = @build_vendor@
291builddir = @builddir@
292datadir = @datadir@
293datarootdir = @datarootdir@
294docdir = @docdir@
295dvidir = @dvidir@
296exec_prefix = @exec_prefix@
297host = @host@
298host_alias = @host_alias@
299host_cpu = @host_cpu@
300host_os = @host_os@
301host_vendor = @host_vendor@
302htmldir = @htmldir@
303includedir = @includedir@
304infodir = @infodir@
305install_sh = @install_sh@
306libdir = @libdir@
307libexecdir = @libexecdir@
308localedir = @localedir@
309localstatedir = @localstatedir@
310lspci_found = @lspci_found@
311mandir = @mandir@
312mkdir_p = @mkdir_p@
313oldincludedir = @oldincludedir@
314pdfdir = @pdfdir@
315prefix = @prefix@
316program_transform_name = @program_transform_name@
317psdir = @psdir@
318sbindir = @sbindir@
319sharedstatedir = @sharedstatedir@
320srcdir = @srcdir@
321sysconfdir = @sysconfdir@
322target_alias = @target_alias@
323top_build_prefix = @top_build_prefix@
324top_builddir = @top_builddir@
325top_srcdir = @top_srcdir@
326AM_MAKEFLAGS = -j 4
327DEFAULT_INCLUDES = -I. -I..
328lib_LTLIBRARIES = libHashFactory.la
329include_HEADERS = HashFactory.h
330hashTest_CPPFLAGS = -DHAVE_OPENCL -DHAVE_CL_DOUBLE -I$(OPENCL_INCLUDE)
331H_SRCS = HashFactory.h CLHash_Utilities.h
332C_SRCS = HashFactory.c CLHash_Utilities.c
333libHashFactory_la_SOURCES = ${C_SRCS} ${H_SRCS}
334hashTest_SOURCES = testHelper.c hashTest.c
335hashTest_LDADD = libHashFactory.la
336EXTRA_DIST = perfectHash.cm perfectHash.hm primetest.c testHelper.h HashFactory.hp \
337 HashFactory.hm HashFactory.cp HashFactory.cm HashFactory.h HashFactory.c HashFactory.cl HashFactory.clp embed_source.pl \
338 compactHash.cm compactHash.hm baseHash.cm baseHash.hm
339
340all: all-am
341
342.SUFFIXES:
343.SUFFIXES: .c .lo .o .obj
344$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
345 @for dep in $?; do \
346 case '$(am__configure_deps)' in \
347 *$$dep*) \
348 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
349 && { if test -f $@; then exit 0; else break; fi; }; \
350 exit 1;; \
351 esac; \
352 done; \
353 echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign HashFactory/Makefile'; \
354 $(am__cd) $(top_srcdir) && \
355 $(AUTOMAKE) --foreign HashFactory/Makefile
356.PRECIOUS: Makefile
357Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
358 @case '$?' in \
359 *config.status*) \
360 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
361 *) \
362 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
363 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
364 esac;
365
366$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
367 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
368
369$(top_srcdir)/configure: $(am__configure_deps)
370 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
371$(ACLOCAL_M4): $(am__aclocal_m4_deps)
372 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
373$(am__aclocal_m4_deps):
374
375install-libLTLIBRARIES: $(lib_LTLIBRARIES)
376 @$(NORMAL_INSTALL)
377 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
378 list2=; for p in $$list; do \
379 if test -f $$p; then \
380 list2="$$list2 $$p"; \
381 else :; fi; \
382 done; \
383 test -z "$$list2" || { \
384 echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \
385 $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \
386 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \
387 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \
388 }
389
390uninstall-libLTLIBRARIES:
391 @$(NORMAL_UNINSTALL)
392 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
393 for p in $$list; do \
394 $(am__strip_dir) \
395 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \
396 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \
397 done
398
399clean-libLTLIBRARIES:
400 -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES)
401 @list='$(lib_LTLIBRARIES)'; \
402 locs=`for p in $$list; do echo $$p; done | \
403 sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
404 sort -u`; \
405 test -z "$$locs" || { \
406 echo rm -f $${locs}; \
407 rm -f $${locs}; \
408 }
409
410libHashFactory.la: $(libHashFactory_la_OBJECTS) $(libHashFactory_la_DEPENDENCIES) $(EXTRA_libHashFactory_la_DEPENDENCIES)
411 $(AM_V_CCLD)$(LINK) -rpath $(libdir) $(libHashFactory_la_OBJECTS) $(libHashFactory_la_LIBADD) $(LIBS)
412install-binPROGRAMS: $(bin_PROGRAMS)
413 @$(NORMAL_INSTALL)
414 @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
415 if test -n "$$list"; then \
416 echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \
417 $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \
418 fi; \
419 for p in $$list; do echo "$$p $$p"; done | \
420 sed 's/$(EXEEXT)$$//' | \
421 while read p p1; do if test -f $$p \
422 || test -f $$p1 \
423 ; then echo "$$p"; echo "$$p"; else :; fi; \
424 done | \
425 sed -e 'p;s,.*/,,;n;h' \
426 -e 's|.*|.|' \
427 -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
428 sed 'N;N;N;s,\n, ,g' | \
429 $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
430 { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
431 if ($$2 == $$4) files[d] = files[d] " " $$1; \
432 else { print "f", $$3 "/" $$4, $$1; } } \
433 END { for (d in files) print "f", d, files[d] }' | \
434 while read type dir files; do \
435 if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
436 test -z "$$files" || { \
437 echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \
438 $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \
439 } \
440 ; done
441
442uninstall-binPROGRAMS:
443 @$(NORMAL_UNINSTALL)
444 @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
445 files=`for p in $$list; do echo "$$p"; done | \
446 sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
447 -e 's/$$/$(EXEEXT)/' \
448 `; \
449 test -n "$$list" || exit 0; \
450 echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
451 cd "$(DESTDIR)$(bindir)" && rm -f $$files
452
453clean-binPROGRAMS:
454 @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \
455 echo " rm -f" $$list; \
456 rm -f $$list || exit $$?; \
457 test -n "$(EXEEXT)" || exit 0; \
458 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
459 echo " rm -f" $$list; \
460 rm -f $$list
461
462hashTest$(EXEEXT): $(hashTest_OBJECTS) $(hashTest_DEPENDENCIES) $(EXTRA_hashTest_DEPENDENCIES)
463 @rm -f hashTest$(EXEEXT)
464 $(AM_V_CCLD)$(LINK) $(hashTest_OBJECTS) $(hashTest_LDADD) $(LIBS)
465
466mostlyclean-compile:
467 -rm -f *.$(OBJEXT)
468
469distclean-compile:
470 -rm -f *.tab.c
471
472@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/CLHash_Utilities.Plo@am__quote@
473@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/HashFactory.Plo@am__quote@
474@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hashTest-hashTest.Po@am__quote@
475@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hashTest-testHelper.Po@am__quote@
476
477.c.o:
478@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
479@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
480@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
481@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
482@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c $<
483
484.c.obj:
485@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
486@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
487@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
488@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
489@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c `$(CYGPATH_W) '$<'`
490
491.c.lo:
492@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
493@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
494@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
495@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
496@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
497
498hashTest-testHelper.o: testHelper.c
499@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(hashTest_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hashTest-testHelper.o -MD -MP -MF $(DEPDIR)/hashTest-testHelper.Tpo -c -o hashTest-testHelper.o `test -f 'testHelper.c' || echo '$(srcdir)/'`testHelper.c
500@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/hashTest-testHelper.Tpo $(DEPDIR)/hashTest-testHelper.Po
501@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='testHelper.c' object='hashTest-testHelper.o' libtool=no @AMDEPBACKSLASH@
502@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
503@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(hashTest_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hashTest-testHelper.o `test -f 'testHelper.c' || echo '$(srcdir)/'`testHelper.c
504
505hashTest-testHelper.obj: testHelper.c
506@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(hashTest_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hashTest-testHelper.obj -MD -MP -MF $(DEPDIR)/hashTest-testHelper.Tpo -c -o hashTest-testHelper.obj `if test -f 'testHelper.c'; then $(CYGPATH_W) 'testHelper.c'; else $(CYGPATH_W) '$(srcdir)/testHelper.c'; fi`
507@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/hashTest-testHelper.Tpo $(DEPDIR)/hashTest-testHelper.Po
508@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='testHelper.c' object='hashTest-testHelper.obj' libtool=no @AMDEPBACKSLASH@
509@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
510@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(hashTest_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hashTest-testHelper.obj `if test -f 'testHelper.c'; then $(CYGPATH_W) 'testHelper.c'; else $(CYGPATH_W) '$(srcdir)/testHelper.c'; fi`
511
512hashTest-hashTest.o: hashTest.c
513@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(hashTest_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hashTest-hashTest.o -MD -MP -MF $(DEPDIR)/hashTest-hashTest.Tpo -c -o hashTest-hashTest.o `test -f 'hashTest.c' || echo '$(srcdir)/'`hashTest.c
514@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/hashTest-hashTest.Tpo $(DEPDIR)/hashTest-hashTest.Po
515@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='hashTest.c' object='hashTest-hashTest.o' libtool=no @AMDEPBACKSLASH@
516@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
517@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(hashTest_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hashTest-hashTest.o `test -f 'hashTest.c' || echo '$(srcdir)/'`hashTest.c
518
519hashTest-hashTest.obj: hashTest.c
520@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(hashTest_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hashTest-hashTest.obj -MD -MP -MF $(DEPDIR)/hashTest-hashTest.Tpo -c -o hashTest-hashTest.obj `if test -f 'hashTest.c'; then $(CYGPATH_W) 'hashTest.c'; else $(CYGPATH_W) '$(srcdir)/hashTest.c'; fi`
521@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/hashTest-hashTest.Tpo $(DEPDIR)/hashTest-hashTest.Po
522@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='hashTest.c' object='hashTest-hashTest.obj' libtool=no @AMDEPBACKSLASH@
523@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
524@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(hashTest_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hashTest-hashTest.obj `if test -f 'hashTest.c'; then $(CYGPATH_W) 'hashTest.c'; else $(CYGPATH_W) '$(srcdir)/hashTest.c'; fi`
525
526mostlyclean-libtool:
527 -rm -f *.lo
528
529clean-libtool:
530 -rm -rf .libs _libs
531install-includeHEADERS: $(include_HEADERS)
532 @$(NORMAL_INSTALL)
533 @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \
534 if test -n "$$list"; then \
535 echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \
536 $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \
537 fi; \
538 for p in $$list; do \
539 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
540 echo "$$d$$p"; \
541 done | $(am__base_list) | \
542 while read files; do \
543 echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \
544 $(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \
545 done
546
547uninstall-includeHEADERS:
548 @$(NORMAL_UNINSTALL)
549 @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \
550 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
551 dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir)
552
553ID: $(am__tagged_files)
554 $(am__define_uniq_tagged_files); mkid -fID $$unique
555tags: tags-am
556TAGS: tags
557
558tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
559 set x; \
560 here=`pwd`; \
561 $(am__define_uniq_tagged_files); \
562 shift; \
563 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
564 test -n "$$unique" || unique=$$empty_fix; \
565 if test $$# -gt 0; then \
566 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
567 "$$@" $$unique; \
568 else \
569 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
570 $$unique; \
571 fi; \
572 fi
573ctags: ctags-am
574
575CTAGS: ctags
576ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
577 $(am__define_uniq_tagged_files); \
578 test -z "$(CTAGS_ARGS)$$unique" \
579 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
580 $$unique
581
582GTAGS:
583 here=`$(am__cd) $(top_builddir) && pwd` \
584 && $(am__cd) $(top_srcdir) \
585 && gtags -i $(GTAGS_ARGS) "$$here"
586cscopelist: cscopelist-am
587
588cscopelist-am: $(am__tagged_files)
589 list='$(am__tagged_files)'; \
590 case "$(srcdir)" in \
591 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
592 *) sdir=$(subdir)/$(srcdir) ;; \
593 esac; \
594 for i in $$list; do \
595 if test -f "$$i"; then \
596 echo "$(subdir)/$$i"; \
597 else \
598 echo "$$sdir/$$i"; \
599 fi; \
600 done >> $(top_builddir)/cscope.files
601
602distclean-tags:
603 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
604
605distdir: $(DISTFILES)
606 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
607 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
608 list='$(DISTFILES)'; \
609 dist_files=`for file in $$list; do echo $$file; done | \
610 sed -e "s|^$$srcdirstrip/||;t" \
611 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
612 case $$dist_files in \
613 */*) $(MKDIR_P) `echo "$$dist_files" | \
614 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
615 sort -u` ;; \
616 esac; \
617 for file in $$dist_files; do \
618 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
619 if test -d $$d/$$file; then \
620 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
621 if test -d "$(distdir)/$$file"; then \
622 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
623 fi; \
624 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
625 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
626 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
627 fi; \
628 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
629 else \
630 test -f "$(distdir)/$$file" \
631 || cp -p $$d/$$file "$(distdir)/$$file" \
632 || exit 1; \
633 fi; \
634 done
635check-am: all-am
636check: check-am
637all-am: Makefile $(LTLIBRARIES) $(PROGRAMS) $(HEADERS)
638install-binPROGRAMS: install-libLTLIBRARIES
639
640installdirs:
641 for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(bindir)" "$(DESTDIR)$(includedir)"; do \
642 test -z "$$dir" || $(MKDIR_P) "$$dir"; \
643 done
644install: install-am
645install-exec: install-exec-am
646install-data: install-data-am
647uninstall: uninstall-am
648
649install-am: all-am
650 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
651
652installcheck: installcheck-am
653install-strip:
654 if test -z '$(STRIP)'; then \
655 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
656 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
657 install; \
658 else \
659 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
660 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
661 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
662 fi
663mostlyclean-generic:
664
665clean-generic:
666
667distclean-generic:
668 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
669 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
670
671maintainer-clean-generic:
672 @echo "This command is intended for maintainers to use"
673 @echo "it deletes files that may require special tools to rebuild."
674clean: clean-am
675
676clean-am: clean-binPROGRAMS clean-generic clean-libLTLIBRARIES \
677 clean-libtool mostlyclean-am
678
679distclean: distclean-am
680 -rm -rf ./$(DEPDIR)
681 -rm -f Makefile
682distclean-am: clean-am distclean-compile distclean-generic \
683 distclean-tags
684
685dvi: dvi-am
686
687dvi-am:
688
689html: html-am
690
691html-am:
692
693info: info-am
694
695info-am:
696
697install-data-am: install-includeHEADERS
698
699install-dvi: install-dvi-am
700
701install-dvi-am:
702
703install-exec-am: install-binPROGRAMS install-libLTLIBRARIES
704
705install-html: install-html-am
706
707install-html-am:
708
709install-info: install-info-am
710
711install-info-am:
712
713install-man:
714
715install-pdf: install-pdf-am
716
717install-pdf-am:
718
719install-ps: install-ps-am
720
721install-ps-am:
722
723installcheck-am:
724
725maintainer-clean: maintainer-clean-am
726 -rm -rf ./$(DEPDIR)
727 -rm -f Makefile
728maintainer-clean-am: distclean-am maintainer-clean-generic
729
730mostlyclean: mostlyclean-am
731
732mostlyclean-am: mostlyclean-compile mostlyclean-generic \
733 mostlyclean-libtool
734
735pdf: pdf-am
736
737pdf-am:
738
739ps: ps-am
740
741ps-am:
742
743uninstall-am: uninstall-binPROGRAMS uninstall-includeHEADERS \
744 uninstall-libLTLIBRARIES
745
746.MAKE: install-am install-strip
747
748.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean \
749 clean-binPROGRAMS clean-generic clean-libLTLIBRARIES \
750 clean-libtool cscopelist-am ctags ctags-am distclean \
751 distclean-compile distclean-generic distclean-libtool \
752 distclean-tags distdir dvi dvi-am html html-am info info-am \
753 install install-am install-binPROGRAMS install-data \
754 install-data-am install-dvi install-dvi-am install-exec \
755 install-exec-am install-html install-html-am \
756 install-includeHEADERS install-info install-info-am \
757 install-libLTLIBRARIES install-man install-pdf install-pdf-am \
758 install-ps install-ps-am install-strip installcheck \
759 installcheck-am installdirs maintainer-clean \
760 maintainer-clean-generic mostlyclean mostlyclean-compile \
761 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
762 tags tags-am uninstall uninstall-am uninstall-binPROGRAMS \
763 uninstall-includeHEADERS uninstall-libLTLIBRARIES
764
765default: HashFactory.c CLHash_Utilities.c HashFactory.cl libHashFactory.la
766all: HashFactory.c CLHash_Utilities.c HashFactory.cl libHashFactory.la
767test: hashTest
768
769HashFactory.h: HashFactory.hp HashFactory.hm perfectHash.hm compactHash.hm
770 ${CPREPROCESSOR} -CC -x c -imacros HashFactory.hm HashFactory.hp | ${INDENT} -linux -brf -o HashFactory.h
771
772HashFactory.c: HashFactory.cp HashFactory.cm HashFactory.cl perfectHash.cm compactHash.cm HashFactory.h
773 ${CPREPROCESSOR} -CC -x c -imacros HashFactory.cm HashFactory.cp | ${INDENT} -linux -brf | \
774 sed -e '/OMP_PRAGMA_PARALLEL_FOR/s/[[:space:]]*OMP_PRAGMA_PARALLEL_FOR;/#pragma omp parallel for/' > HashFactory.c
775 ./embed_source.pl HashFactory.cl >> HashFactory.c
776
777HashFactory.cl: HashFactory.clp HashFactory.cm perfectHash.cm compactHash.cm
778 ${CPREPROCESSOR} -CC -x c -imacros HashFactory.cm HashFactory.clp | ${INDENT} -linux -brf -o HashFactory.cl
779
780# Tell versions [3.59,3.63) of GNU make to not export all variables.
781# Otherwise a system limit (for SysV at least) may be exceeded.
782.NOEXPORT:
Makefile.am +0 -41
……@@ -1,41 +0,0 @@
1bin_PROGRAMS = neigh2d # neigh2d_memopts
2
3ACLOCAL_AMFLAGS = -I m4
4
5SUBDIRS = kdtree HashFactory simplehash timer
6
7neigh2d_C_SRCS = neigh2d.c gpu.c
8neigh2d_H_SRCS = gpu.h
9neigh2d_SOURCES = ${neigh2d_C_SRCS} ${neigh2d_H_SRCS}
10neigh2d_LDADD = kdtree/libkdtree.la HashFactory/libHashFactory.la simplehash/libsimplehash.la timer/libtimer.la
11
12LDADD = -lm
13
14EXTRA_DIST = neigh2d_kern.cl APACHE_LICENSE-2_0 AUTHORS README LICENSE \
15 Papers.bib NOTICE README.md ReleaseAuthorization.pdf Todo libtool
16
17kdtree/libkdtree.la:
18 cd kdtree
19 make
20
21timer/libtimer.la:
22 cd timer
23 make
24
25HashFactory/libHashFactory.la:
26 cd HashFactory
27 make
28
29simplehash/libsimplehash.la:
30 cd simplehash
31 make
32
33clean-local:
34 rm -f *.inc
35 rm -f memory.out
36
37distclean-local:
38 rm -f hash-v*.tar.gz
39 rm -rf build
40 rm -rf autom4te.cache
41 rm -f hash/stamp-h? stamp-h?
Makefile.in +0 -953
……@@ -1,953 +0,0 @@
1# Makefile.in generated by automake 1.13.4 from Makefile.am.
2# @configure_input@
3
4# Copyright (C) 1994-2013 Free Software Foundation, Inc.
5
6# This Makefile.in is free software; the Free Software Foundation
7# gives unlimited permission to copy and/or distribute it,
8# with or without modifications, as long as this notice is preserved.
9
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
12# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
13# PARTICULAR PURPOSE.
14
15@SET_MAKE@
16
17VPATH = @srcdir@
18am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
19am__make_running_with_option = \
20 case $${target_option-} in \
21 ?) ;; \
22 *) echo "am__make_running_with_option: internal error: invalid" \
23 "target option '$${target_option-}' specified" >&2; \
24 exit 1;; \
25 esac; \
26 has_opt=no; \
27 sane_makeflags=$$MAKEFLAGS; \
28 if $(am__is_gnu_make); then \
29 sane_makeflags=$$MFLAGS; \
30 else \
31 case $$MAKEFLAGS in \
32 *\\[\ \ ]*) \
33 bs=\\; \
34 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
35 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
36 esac; \
37 fi; \
38 skip_next=no; \
39 strip_trailopt () \
40 { \
41 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
42 }; \
43 for flg in $$sane_makeflags; do \
44 test $$skip_next = yes && { skip_next=no; continue; }; \
45 case $$flg in \
46 *=*|--*) continue;; \
47 -*I) strip_trailopt 'I'; skip_next=yes;; \
48 -*I?*) strip_trailopt 'I';; \
49 -*O) strip_trailopt 'O'; skip_next=yes;; \
50 -*O?*) strip_trailopt 'O';; \
51 -*l) strip_trailopt 'l'; skip_next=yes;; \
52 -*l?*) strip_trailopt 'l';; \
53 -[dEDm]) skip_next=yes;; \
54 -[JT]) skip_next=yes;; \
55 esac; \
56 case $$flg in \
57 *$$target_option*) has_opt=yes; break;; \
58 esac; \
59 done; \
60 test $$has_opt = yes
61am__make_dryrun = (target_option=n; $(am__make_running_with_option))
62am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
63pkgdatadir = $(datadir)/@PACKAGE@
64pkgincludedir = $(includedir)/@PACKAGE@
65pkglibdir = $(libdir)/@PACKAGE@
66pkglibexecdir = $(libexecdir)/@PACKAGE@
67am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
68install_sh_DATA = $(install_sh) -c -m 644
69install_sh_PROGRAM = $(install_sh) -c
70install_sh_SCRIPT = $(install_sh) -c
71INSTALL_HEADER = $(INSTALL_DATA)
72transform = $(program_transform_name)
73NORMAL_INSTALL = :
74PRE_INSTALL = :
75POST_INSTALL = :
76NORMAL_UNINSTALL = :
77PRE_UNINSTALL = :
78POST_UNINSTALL = :
79build_triplet = @build@
80host_triplet = @host@
81bin_PROGRAMS = neigh2d$(EXEEXT)
82subdir = .
83DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
84 $(top_srcdir)/configure $(am__configure_deps) \
85 $(top_srcdir)/./config/depcomp AUTHORS README ./config/compile \
86 ./config/config.guess ./config/config.sub ./config/depcomp \
87 ./config/install-sh ./config/missing ./config/ltmain.sh \
88 $(top_srcdir)/./config/compile \
89 $(top_srcdir)/./config/config.guess \
90 $(top_srcdir)/./config/config.sub \
91 $(top_srcdir)/./config/install-sh \
92 $(top_srcdir)/./config/ltmain.sh \
93 $(top_srcdir)/./config/missing
94ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
95am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
96 $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
97 $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
98 $(top_srcdir)/configure.ac
99am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
100 $(ACLOCAL_M4)
101am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
102 configure.lineno config.status.lineno
103mkinstalldirs = $(install_sh) -d
104CONFIG_CLEAN_FILES =
105CONFIG_CLEAN_VPATH_FILES =
106am__installdirs = "$(DESTDIR)$(bindir)"
107PROGRAMS = $(bin_PROGRAMS)
108am__objects_1 = neigh2d.$(OBJEXT) gpu.$(OBJEXT)
109am__objects_2 =
110am_neigh2d_OBJECTS = $(am__objects_1) $(am__objects_2)
111neigh2d_OBJECTS = $(am_neigh2d_OBJECTS)
112neigh2d_DEPENDENCIES = kdtree/libkdtree.la \
113 HashFactory/libHashFactory.la simplehash/libsimplehash.la \
114 timer/libtimer.la
115AM_V_lt = $(am__v_lt_@AM_V@)
116am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
117am__v_lt_0 = --silent
118am__v_lt_1 =
119AM_V_P = $(am__v_P_@AM_V@)
120am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
121am__v_P_0 = false
122am__v_P_1 = :
123AM_V_GEN = $(am__v_GEN_@AM_V@)
124am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
125am__v_GEN_0 = @echo " GEN " $@;
126am__v_GEN_1 =
127AM_V_at = $(am__v_at_@AM_V@)
128am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
129am__v_at_0 = @
130am__v_at_1 =
131DEFAULT_INCLUDES = -I.@am__isrc@
132depcomp = $(SHELL) $(top_srcdir)/./config/depcomp
133am__depfiles_maybe = depfiles
134am__mv = mv -f
135COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
136 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
137LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
138 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
139 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
140 $(AM_CFLAGS) $(CFLAGS)
141AM_V_CC = $(am__v_CC_@AM_V@)
142am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
143am__v_CC_0 = @echo " CC " $@;
144am__v_CC_1 =
145CCLD = $(CC)
146LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
147 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
148 $(AM_LDFLAGS) $(LDFLAGS) -o $@
149AM_V_CCLD = $(am__v_CCLD_@AM_V@)
150am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
151am__v_CCLD_0 = @echo " CCLD " $@;
152am__v_CCLD_1 =
153SOURCES = $(neigh2d_SOURCES)
154DIST_SOURCES = $(neigh2d_SOURCES)
155RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
156 ctags-recursive dvi-recursive html-recursive info-recursive \
157 install-data-recursive install-dvi-recursive \
158 install-exec-recursive install-html-recursive \
159 install-info-recursive install-pdf-recursive \
160 install-ps-recursive install-recursive installcheck-recursive \
161 installdirs-recursive pdf-recursive ps-recursive \
162 tags-recursive uninstall-recursive
163am__can_run_installinfo = \
164 case $$AM_UPDATE_INFO_DIR in \
165 n|no|NO) false;; \
166 *) (install-info --version) >/dev/null 2>&1;; \
167 esac
168RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
169 distclean-recursive maintainer-clean-recursive
170am__recursive_targets = \
171 $(RECURSIVE_TARGETS) \
172 $(RECURSIVE_CLEAN_TARGETS) \
173 $(am__extra_recursive_targets)
174AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
175 cscope distdir dist dist-all distcheck
176am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
177# Read a list of newline-separated strings from the standard input,
178# and print each of them once, without duplicates. Input order is
179# *not* preserved.
180am__uniquify_input = $(AWK) '\
181 BEGIN { nonempty = 0; } \
182 { items[$$0] = 1; nonempty = 1; } \
183 END { if (nonempty) { for (i in items) print i; }; } \
184'
185# Make sure the list of sources is unique. This is necessary because,
186# e.g., the same source file might be shared among _SOURCES variables
187# for different programs/libraries.
188am__define_uniq_tagged_files = \
189 list='$(am__tagged_files)'; \
190 unique=`for i in $$list; do \
191 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
192 done | $(am__uniquify_input)`
193ETAGS = etags
194CTAGS = ctags
195CSCOPE = cscope
196DIST_SUBDIRS = $(SUBDIRS)
197DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
198distdir = $(PACKAGE)-$(VERSION)
199top_distdir = $(distdir)
200am__remove_distdir = \
201 if test -d "$(distdir)"; then \
202 find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \
203 && rm -rf "$(distdir)" \
204 || { sleep 5 && rm -rf "$(distdir)"; }; \
205 else :; fi
206am__post_remove_distdir = $(am__remove_distdir)
207am__relativize = \
208 dir0=`pwd`; \
209 sed_first='s,^\([^/]*\)/.*$$,\1,'; \
210 sed_rest='s,^[^/]*/*,,'; \
211 sed_last='s,^.*/\([^/]*\)$$,\1,'; \
212 sed_butlast='s,/*[^/]*$$,,'; \
213 while test -n "$$dir1"; do \
214 first=`echo "$$dir1" | sed -e "$$sed_first"`; \
215 if test "$$first" != "."; then \
216 if test "$$first" = ".."; then \
217 dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
218 dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
219 else \
220 first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
221 if test "$$first2" = "$$first"; then \
222 dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
223 else \
224 dir2="../$$dir2"; \
225 fi; \
226 dir0="$$dir0"/"$$first"; \
227 fi; \
228 fi; \
229 dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
230 done; \
231 reldir="$$dir2"
232DIST_ARCHIVES = $(distdir).tar.gz
233GZIP_ENV = --best
234DIST_TARGETS = dist-gzip
235distuninstallcheck_listfiles = find . -type f -print
236am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \
237 | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$'
238distcleancheck_listfiles = find . -type f -print
239ACLOCAL = @ACLOCAL@
240AMTAR = @AMTAR@
241AM_CPPFLAGS = @AM_CPPFLAGS@
242AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
243AR = @AR@
244AUTOCONF = @AUTOCONF@
245AUTOHEADER = @AUTOHEADER@
246AUTOMAKE = @AUTOMAKE@
247AWK = @AWK@
248CC = @CC@
249CCDEPMODE = @CCDEPMODE@
250CFLAGS = @CFLAGS@
251CPP = @CPP@
252CPPFLAGS = @CPPFLAGS@
253CPREPROCESSOR = @CPREPROCESSOR@
254CXX = @CXX@
255CXXCPP = @CXXCPP@
256CXXDEPMODE = @CXXDEPMODE@
257CXXFLAGS = @CXXFLAGS@
258CYGPATH_W = @CYGPATH_W@
259DEFS = @DEFS@
260DEPDIR = @DEPDIR@
261DLLTOOL = @DLLTOOL@
262DSYMUTIL = @DSYMUTIL@
263DUMPBIN = @DUMPBIN@
264ECHO_C = @ECHO_C@
265ECHO_N = @ECHO_N@
266ECHO_T = @ECHO_T@
267EGREP = @EGREP@
268EXEEXT = @EXEEXT@
269FGREP = @FGREP@
270GREP = @GREP@
271HAVE_ADDR2LINE = @HAVE_ADDR2LINE@
272INDENT = @INDENT@
273INSTALL = @INSTALL@
274INSTALL_DATA = @INSTALL_DATA@
275INSTALL_PROGRAM = @INSTALL_PROGRAM@
276INSTALL_SCRIPT = @INSTALL_SCRIPT@
277INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
278LD = @LD@
279LDFLAGS = @LDFLAGS@
280LIBOBJS = @LIBOBJS@
281LIBS = @LIBS@
282LIBTOOL = @LIBTOOL@
283LIPO = @LIPO@
284LN_S = @LN_S@
285LTLIBOBJS = @LTLIBOBJS@
286MAKEINFO = @MAKEINFO@
287MANIFEST_TOOL = @MANIFEST_TOOL@
288MKDIR_P = @MKDIR_P@
289NM = @NM@
290NMEDIT = @NMEDIT@
291OBJDUMP = @OBJDUMP@
292OBJEXT = @OBJEXT@
293OTOOL = @OTOOL@
294OTOOL64 = @OTOOL64@
295PACKAGE = @PACKAGE@
296PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
297PACKAGE_NAME = @PACKAGE_NAME@
298PACKAGE_STRING = @PACKAGE_STRING@
299PACKAGE_TARNAME = @PACKAGE_TARNAME@
300PACKAGE_URL = @PACKAGE_URL@
301PACKAGE_VERSION = @PACKAGE_VERSION@
302PATH_SEPARATOR = @PATH_SEPARATOR@
303RANLIB = @RANLIB@
304SED = @SED@
305SET_MAKE = @SET_MAKE@
306SHELL = @SHELL@
307STRIP = @STRIP@
308VERSION = @VERSION@
309abs_builddir = @abs_builddir@
310abs_srcdir = @abs_srcdir@
311abs_top_builddir = @abs_top_builddir@
312abs_top_srcdir = @abs_top_srcdir@
313ac_ct_AR = @ac_ct_AR@
314ac_ct_CC = @ac_ct_CC@
315ac_ct_CXX = @ac_ct_CXX@
316ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
317am__include = @am__include@
318am__leading_dot = @am__leading_dot@
319am__quote = @am__quote@
320am__tar = @am__tar@
321am__untar = @am__untar@
322bindir = @bindir@
323build = @build@
324build_alias = @build_alias@
325build_cpu = @build_cpu@
326build_os = @build_os@
327build_vendor = @build_vendor@
328builddir = @builddir@
329datadir = @datadir@
330datarootdir = @datarootdir@
331docdir = @docdir@
332dvidir = @dvidir@
333exec_prefix = @exec_prefix@
334host = @host@
335host_alias = @host_alias@
336host_cpu = @host_cpu@
337host_os = @host_os@
338host_vendor = @host_vendor@
339htmldir = @htmldir@
340includedir = @includedir@
341infodir = @infodir@
342install_sh = @install_sh@
343libdir = @libdir@
344libexecdir = @libexecdir@
345localedir = @localedir@
346localstatedir = @localstatedir@
347lspci_found = @lspci_found@
348mandir = @mandir@
349mkdir_p = @mkdir_p@
350oldincludedir = @oldincludedir@
351pdfdir = @pdfdir@
352prefix = @prefix@
353program_transform_name = @program_transform_name@
354psdir = @psdir@
355sbindir = @sbindir@
356sharedstatedir = @sharedstatedir@
357srcdir = @srcdir@
358sysconfdir = @sysconfdir@
359target_alias = @target_alias@
360top_build_prefix = @top_build_prefix@
361top_builddir = @top_builddir@
362top_srcdir = @top_srcdir@
363ACLOCAL_AMFLAGS = -I m4
364SUBDIRS = kdtree HashFactory simplehash timer
365neigh2d_C_SRCS = neigh2d.c gpu.c
366neigh2d_H_SRCS = gpu.h
367neigh2d_SOURCES = ${neigh2d_C_SRCS} ${neigh2d_H_SRCS}
368neigh2d_LDADD = kdtree/libkdtree.la HashFactory/libHashFactory.la simplehash/libsimplehash.la timer/libtimer.la
369LDADD = -lm
370EXTRA_DIST = neigh2d_kern.cl APACHE_LICENSE-2_0 AUTHORS README LICENSE \
371 Papers.bib NOTICE README.md ReleaseAuthorization.pdf Todo libtool
372
373all: all-recursive
374
375.SUFFIXES:
376.SUFFIXES: .c .lo .o .obj
377am--refresh: Makefile
378 @:
379$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
380 @for dep in $?; do \
381 case '$(am__configure_deps)' in \
382 *$$dep*) \
383 echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \
384 $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \
385 && exit 0; \
386 exit 1;; \
387 esac; \
388 done; \
389 echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \
390 $(am__cd) $(top_srcdir) && \
391 $(AUTOMAKE) --foreign Makefile
392.PRECIOUS: Makefile
393Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
394 @case '$?' in \
395 *config.status*) \
396 echo ' $(SHELL) ./config.status'; \
397 $(SHELL) ./config.status;; \
398 *) \
399 echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
400 cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
401 esac;
402
403$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
404 $(SHELL) ./config.status --recheck
405
406$(top_srcdir)/configure: $(am__configure_deps)
407 $(am__cd) $(srcdir) && $(AUTOCONF)
408$(ACLOCAL_M4): $(am__aclocal_m4_deps)
409 $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
410$(am__aclocal_m4_deps):
411install-binPROGRAMS: $(bin_PROGRAMS)
412 @$(NORMAL_INSTALL)
413 @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
414 if test -n "$$list"; then \
415 echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \
416 $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \
417 fi; \
418 for p in $$list; do echo "$$p $$p"; done | \
419 sed 's/$(EXEEXT)$$//' | \
420 while read p p1; do if test -f $$p \
421 || test -f $$p1 \
422 ; then echo "$$p"; echo "$$p"; else :; fi; \
423 done | \
424 sed -e 'p;s,.*/,,;n;h' \
425 -e 's|.*|.|' \
426 -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
427 sed 'N;N;N;s,\n, ,g' | \
428 $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
429 { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \
430 if ($$2 == $$4) files[d] = files[d] " " $$1; \
431 else { print "f", $$3 "/" $$4, $$1; } } \
432 END { for (d in files) print "f", d, files[d] }' | \
433 while read type dir files; do \
434 if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \
435 test -z "$$files" || { \
436 echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \
437 $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \
438 } \
439 ; done
440
441uninstall-binPROGRAMS:
442 @$(NORMAL_UNINSTALL)
443 @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
444 files=`for p in $$list; do echo "$$p"; done | \
445 sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
446 -e 's/$$/$(EXEEXT)/' \
447 `; \
448 test -n "$$list" || exit 0; \
449 echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
450 cd "$(DESTDIR)$(bindir)" && rm -f $$files
451
452clean-binPROGRAMS:
453 @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \
454 echo " rm -f" $$list; \
455 rm -f $$list || exit $$?; \
456 test -n "$(EXEEXT)" || exit 0; \
457 list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
458 echo " rm -f" $$list; \
459 rm -f $$list
460
461neigh2d$(EXEEXT): $(neigh2d_OBJECTS) $(neigh2d_DEPENDENCIES) $(EXTRA_neigh2d_DEPENDENCIES)
462 @rm -f neigh2d$(EXEEXT)
463 $(AM_V_CCLD)$(LINK) $(neigh2d_OBJECTS) $(neigh2d_LDADD) $(LIBS)
464
465mostlyclean-compile:
466 -rm -f *.$(OBJEXT)
467
468distclean-compile:
469 -rm -f *.tab.c
470
471@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gpu.Po@am__quote@
472@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/neigh2d.Po@am__quote@
473
474.c.o:
475@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
476@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
477@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
478@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
479@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c $<
480
481.c.obj:
482@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
483@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
484@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
485@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
486@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c `$(CYGPATH_W) '$<'`
487
488.c.lo:
489@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
490@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
491@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
492@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
493@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
494
495mostlyclean-libtool:
496 -rm -f *.lo
497
498clean-libtool:
499 -rm -rf .libs _libs
500
501distclean-libtool:
502 -rm -f libtool config.lt
503
504# This directory's subdirectories are mostly independent; you can cd
505# into them and run 'make' without going through this Makefile.
506# To change the values of 'make' variables: instead of editing Makefiles,
507# (1) if the variable is set in 'config.status', edit 'config.status'
508# (which will cause the Makefiles to be regenerated when you run 'make');
509# (2) otherwise, pass the desired values on the 'make' command line.
510$(am__recursive_targets):
511 @fail=; \
512 if $(am__make_keepgoing); then \
513 failcom='fail=yes'; \
514 else \
515 failcom='exit 1'; \
516 fi; \
517 dot_seen=no; \
518 target=`echo $@ | sed s/-recursive//`; \
519 case "$@" in \
520 distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
521 *) list='$(SUBDIRS)' ;; \
522 esac; \
523 for subdir in $$list; do \
524 echo "Making $$target in $$subdir"; \
525 if test "$$subdir" = "."; then \
526 dot_seen=yes; \
527 local_target="$$target-am"; \
528 else \
529 local_target="$$target"; \
530 fi; \
531 ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
532 || eval $$failcom; \
533 done; \
534 if test "$$dot_seen" = "no"; then \
535 $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
536 fi; test -z "$$fail"
537
538ID: $(am__tagged_files)
539 $(am__define_uniq_tagged_files); mkid -fID $$unique
540tags: tags-recursive
541TAGS: tags
542
543tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
544 set x; \
545 here=`pwd`; \
546 if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
547 include_option=--etags-include; \
548 empty_fix=.; \
549 else \
550 include_option=--include; \
551 empty_fix=; \
552 fi; \
553 list='$(SUBDIRS)'; for subdir in $$list; do \
554 if test "$$subdir" = .; then :; else \
555 test ! -f $$subdir/TAGS || \
556 set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
557 fi; \
558 done; \
559 $(am__define_uniq_tagged_files); \
560 shift; \
561 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
562 test -n "$$unique" || unique=$$empty_fix; \
563 if test $$# -gt 0; then \
564 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
565 "$$@" $$unique; \
566 else \
567 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
568 $$unique; \
569 fi; \
570 fi
571ctags: ctags-recursive
572
573CTAGS: ctags
574ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
575 $(am__define_uniq_tagged_files); \
576 test -z "$(CTAGS_ARGS)$$unique" \
577 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
578 $$unique
579
580GTAGS:
581 here=`$(am__cd) $(top_builddir) && pwd` \
582 && $(am__cd) $(top_srcdir) \
583 && gtags -i $(GTAGS_ARGS) "$$here"
584cscope: cscope.files
585 test ! -s cscope.files \
586 || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS)
587clean-cscope:
588 -rm -f cscope.files
589cscope.files: clean-cscope cscopelist
590cscopelist: cscopelist-recursive
591
592cscopelist-am: $(am__tagged_files)
593 list='$(am__tagged_files)'; \
594 case "$(srcdir)" in \
595 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
596 *) sdir=$(subdir)/$(srcdir) ;; \
597 esac; \
598 for i in $$list; do \
599 if test -f "$$i"; then \
600 echo "$(subdir)/$$i"; \
601 else \
602 echo "$$sdir/$$i"; \
603 fi; \
604 done >> $(top_builddir)/cscope.files
605
606distclean-tags:
607 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
608 -rm -f cscope.out cscope.in.out cscope.po.out cscope.files
609
610distdir: $(DISTFILES)
611 $(am__remove_distdir)
612 test -d "$(distdir)" || mkdir "$(distdir)"
613 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
614 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
615 list='$(DISTFILES)'; \
616 dist_files=`for file in $$list; do echo $$file; done | \
617 sed -e "s|^$$srcdirstrip/||;t" \
618 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
619 case $$dist_files in \
620 */*) $(MKDIR_P) `echo "$$dist_files" | \
621 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
622 sort -u` ;; \
623 esac; \
624 for file in $$dist_files; do \
625 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
626 if test -d $$d/$$file; then \
627 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
628 if test -d "$(distdir)/$$file"; then \
629 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
630 fi; \
631 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
632 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
633 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
634 fi; \
635 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
636 else \
637 test -f "$(distdir)/$$file" \
638 || cp -p $$d/$$file "$(distdir)/$$file" \
639 || exit 1; \
640 fi; \
641 done
642 @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
643 if test "$$subdir" = .; then :; else \
644 $(am__make_dryrun) \
645 || test -d "$(distdir)/$$subdir" \
646 || $(MKDIR_P) "$(distdir)/$$subdir" \
647 || exit 1; \
648 dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
649 $(am__relativize); \
650 new_distdir=$$reldir; \
651 dir1=$$subdir; dir2="$(top_distdir)"; \
652 $(am__relativize); \
653 new_top_distdir=$$reldir; \
654 echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
655 echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
656 ($(am__cd) $$subdir && \
657 $(MAKE) $(AM_MAKEFLAGS) \
658 top_distdir="$$new_top_distdir" \
659 distdir="$$new_distdir" \
660 am__remove_distdir=: \
661 am__skip_length_check=: \
662 am__skip_mode_fix=: \
663 distdir) \
664 || exit 1; \
665 fi; \
666 done
667 -test -n "$(am__skip_mode_fix)" \
668 || find "$(distdir)" -type d ! -perm -755 \
669 -exec chmod u+rwx,go+rx {} \; -o \
670 ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
671 ! -type d ! -perm -400 -exec chmod a+r {} \; -o \
672 ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \
673 || chmod -R a+r "$(distdir)"
674dist-gzip: distdir
675 tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
676 $(am__post_remove_distdir)
677
678dist-bzip2: distdir
679 tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2
680 $(am__post_remove_distdir)
681
682dist-lzip: distdir
683 tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz
684 $(am__post_remove_distdir)
685
686dist-xz: distdir
687 tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz
688 $(am__post_remove_distdir)
689
690dist-tarZ: distdir
691 tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
692 $(am__post_remove_distdir)
693
694dist-shar: distdir
695 shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
696 $(am__post_remove_distdir)
697
698dist-zip: distdir
699 -rm -f $(distdir).zip
700 zip -rq $(distdir).zip $(distdir)
701 $(am__post_remove_distdir)
702
703dist dist-all:
704 $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:'
705 $(am__post_remove_distdir)
706
707# This target untars the dist file and tries a VPATH configuration. Then
708# it guarantees that the distribution is self-contained by making another
709# tarfile.
710distcheck: dist
711 case '$(DIST_ARCHIVES)' in \
712 *.tar.gz*) \
713 GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\
714 *.tar.bz2*) \
715 bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
716 *.tar.lz*) \
717 lzip -dc $(distdir).tar.lz | $(am__untar) ;;\
718 *.tar.xz*) \
719 xz -dc $(distdir).tar.xz | $(am__untar) ;;\
720 *.tar.Z*) \
721 uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
722 *.shar.gz*) \
723 GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\
724 *.zip*) \
725 unzip $(distdir).zip ;;\
726 esac
727 chmod -R a-w $(distdir)
728 chmod u+w $(distdir)
729 mkdir $(distdir)/_build $(distdir)/_inst
730 chmod a-w $(distdir)
731 test -d $(distdir)/_build || exit 0; \
732 dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
733 && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
734 && am__cwd=`pwd` \
735 && $(am__cd) $(distdir)/_build \
736 && ../configure --srcdir=.. --prefix="$$dc_install_base" \
737 $(AM_DISTCHECK_CONFIGURE_FLAGS) \
738 $(DISTCHECK_CONFIGURE_FLAGS) \
739 && $(MAKE) $(AM_MAKEFLAGS) \
740 && $(MAKE) $(AM_MAKEFLAGS) dvi \
741 && $(MAKE) $(AM_MAKEFLAGS) check \
742 && $(MAKE) $(AM_MAKEFLAGS) install \
743 && $(MAKE) $(AM_MAKEFLAGS) installcheck \
744 && $(MAKE) $(AM_MAKEFLAGS) uninstall \
745 && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \
746 distuninstallcheck \
747 && chmod -R a-w "$$dc_install_base" \
748 && ({ \
749 (cd ../.. && umask 077 && mkdir "$$dc_destdir") \
750 && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \
751 && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \
752 && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \
753 distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \
754 } || { rm -rf "$$dc_destdir"; exit 1; }) \
755 && rm -rf "$$dc_destdir" \
756 && $(MAKE) $(AM_MAKEFLAGS) dist \
757 && rm -rf $(DIST_ARCHIVES) \
758 && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \
759 && cd "$$am__cwd" \
760 || exit 1
761 $(am__post_remove_distdir)
762 @(echo "$(distdir) archives ready for distribution: "; \
763 list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
764 sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
765distuninstallcheck:
766 @test -n '$(distuninstallcheck_dir)' || { \
767 echo 'ERROR: trying to run $@ with an empty' \
768 '$$(distuninstallcheck_dir)' >&2; \
769 exit 1; \
770 }; \
771 $(am__cd) '$(distuninstallcheck_dir)' || { \
772 echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \
773 exit 1; \
774 }; \
775 test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \
776 || { echo "ERROR: files left after uninstall:" ; \
777 if test -n "$(DESTDIR)"; then \
778 echo " (check DESTDIR support)"; \
779 fi ; \
780 $(distuninstallcheck_listfiles) ; \
781 exit 1; } >&2
782distcleancheck: distclean
783 @if test '$(srcdir)' = . ; then \
784 echo "ERROR: distcleancheck can only run from a VPATH build" ; \
785 exit 1 ; \
786 fi
787 @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \
788 || { echo "ERROR: files left in build directory after distclean:" ; \
789 $(distcleancheck_listfiles) ; \
790 exit 1; } >&2
791check-am: all-am
792check: check-recursive
793all-am: Makefile $(PROGRAMS)
794installdirs: installdirs-recursive
795installdirs-am:
796 for dir in "$(DESTDIR)$(bindir)"; do \
797 test -z "$$dir" || $(MKDIR_P) "$$dir"; \
798 done
799install: install-recursive
800install-exec: install-exec-recursive
801install-data: install-data-recursive
802uninstall: uninstall-recursive
803
804install-am: all-am
805 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
806
807installcheck: installcheck-recursive
808install-strip:
809 if test -z '$(STRIP)'; then \
810 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
811 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
812 install; \
813 else \
814 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
815 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
816 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
817 fi
818mostlyclean-generic:
819
820clean-generic:
821
822distclean-generic:
823 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
824 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
825
826maintainer-clean-generic:
827 @echo "This command is intended for maintainers to use"
828 @echo "it deletes files that may require special tools to rebuild."
829clean: clean-recursive
830
831clean-am: clean-binPROGRAMS clean-generic clean-libtool clean-local \
832 mostlyclean-am
833
834distclean: distclean-recursive
835 -rm -f $(am__CONFIG_DISTCLEAN_FILES)
836 -rm -rf ./$(DEPDIR)
837 -rm -f Makefile
838distclean-am: clean-am distclean-compile distclean-generic \
839 distclean-libtool distclean-local distclean-tags
840
841dvi: dvi-recursive
842
843dvi-am:
844
845html: html-recursive
846
847html-am:
848
849info: info-recursive
850
851info-am:
852
853install-data-am:
854
855install-dvi: install-dvi-recursive
856
857install-dvi-am:
858
859install-exec-am: install-binPROGRAMS
860
861install-html: install-html-recursive
862
863install-html-am:
864
865install-info: install-info-recursive
866
867install-info-am:
868
869install-man:
870
871install-pdf: install-pdf-recursive
872
873install-pdf-am:
874
875install-ps: install-ps-recursive
876
877install-ps-am:
878
879installcheck-am:
880
881maintainer-clean: maintainer-clean-recursive
882 -rm -f $(am__CONFIG_DISTCLEAN_FILES)
883 -rm -rf $(top_srcdir)/autom4te.cache
884 -rm -rf ./$(DEPDIR)
885 -rm -f Makefile
886maintainer-clean-am: distclean-am maintainer-clean-generic
887
888mostlyclean: mostlyclean-recursive
889
890mostlyclean-am: mostlyclean-compile mostlyclean-generic \
891 mostlyclean-libtool
892
893pdf: pdf-recursive
894
895pdf-am:
896
897ps: ps-recursive
898
899ps-am:
900
901uninstall-am: uninstall-binPROGRAMS
902
903.MAKE: $(am__recursive_targets) install-am install-strip
904
905.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \
906 am--refresh check check-am clean clean-binPROGRAMS \
907 clean-cscope clean-generic clean-libtool clean-local cscope \
908 cscopelist-am ctags ctags-am dist dist-all dist-bzip2 \
909 dist-gzip dist-lzip dist-shar dist-tarZ dist-xz dist-zip \
910 distcheck distclean distclean-compile distclean-generic \
911 distclean-libtool distclean-local distclean-tags \
912 distcleancheck distdir distuninstallcheck dvi dvi-am html \
913 html-am info info-am install install-am install-binPROGRAMS \
914 install-data install-data-am install-dvi install-dvi-am \
915 install-exec install-exec-am install-html install-html-am \
916 install-info install-info-am install-man install-pdf \
917 install-pdf-am install-ps install-ps-am install-strip \
918 installcheck installcheck-am installdirs installdirs-am \
919 maintainer-clean maintainer-clean-generic mostlyclean \
920 mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
921 pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am \
922 uninstall-binPROGRAMS
923
924
925kdtree/libkdtree.la:
926 cd kdtree
927 make
928
929timer/libtimer.la:
930 cd timer
931 make
932
933HashFactory/libHashFactory.la:
934 cd HashFactory
935 make
936
937simplehash/libsimplehash.la:
938 cd simplehash
939 make
940
941clean-local:
942 rm -f *.inc
943 rm -f memory.out
944
945distclean-local:
946 rm -f hash-v*.tar.gz
947 rm -rf build
948 rm -rf autom4te.cache
949 rm -f hash/stamp-h? stamp-h?
950
951# Tell versions [3.59,3.63) of GNU make to not export all variables.
952# Otherwise a system limit (for SysV at least) may be exceeded.
953.NOEXPORT:
cmake/Modules/FindOpenCL.cmake +114 -0
……@@ -0,0 +1,114 @@
1#
2# This file taken from FindOpenCL project @ http://gitorious.com/findopencl
3#
4# - Try to find OpenCL
5# This module tries to find an OpenCL implementation on your system. It supports
6# AMD / ATI, Apple and NVIDIA implementations, but shoudl work, too.
7#
8# Once done this will define
9# OPENCL_FOUND - system has OpenCL
10# OPENCL_INCLUDE_DIRS - the OpenCL include directory
11# OPENCL_LIBRARIES - link these to use OpenCL
12# HAVE_CL_DOUBLE
13#
14# WIN32 should work, but is untested
15
16FIND_PACKAGE( PackageHandleStandardArgs )
17
18SET (OPENCL_VERSION_STRING "0.1.0")
19SET (OPENCL_VERSION_MAJOR 0)
20SET (OPENCL_VERSION_MINOR 1)
21SET (OPENCL_VERSION_PATCH 0)
22
23IF (APPLE)
24
25FIND_LIBRARY(OPENCL_LIBRARIES OpenCL DOC "OpenCL lib for OSX")
26FIND_PATH(OPENCL_INCLUDE_DIRS OpenCL/cl.h DOC "Include for OpenCL on OSX")
27FIND_PATH(_OPENCL_CPP_INCLUDE_DIRS OpenCL/cl.hpp DOC "Include for OpenCL CPP bindings on OSX")
28
29ELSE (APPLE)
30
31IF (WIN32)
32
33FIND_PATH(OPENCL_INCLUDE_DIRS CL/cl.h)
34FIND_PATH(_OPENCL_CPP_INCLUDE_DIRS CL/cl.hpp)
35
36# The AMD SDK currently installs both x86 and x86_64 libraries
37# This is only a hack to find out architecture
38IF( ${CMAKE_SYSTEM_PROCESSOR} STREQUAL "AMD64" )
39SET(OPENCL_LIB_DIR "$ENV{ATISTREAMSDKROOT}/lib/x86_64")
40SET(OPENCL_LIB_DIR "$ENV{ATIINTERNALSTREAMSDKROOT}/lib/x86_64")
41ELSE (${CMAKE_SYSTEM_PROCESSOR} STREQUAL "AMD64")
42SET(OPENCL_LIB_DIR "$ENV{ATISTREAMSDKROOT}/lib/x86")
43SET(OPENCL_LIB_DIR "$ENV{ATIINTERNALSTREAMSDKROOT}/lib/x86")
44ENDIF( ${CMAKE_SYSTEM_PROCESSOR} STREQUAL "AMD64" )
45
46# find out if the user asked for a 64-bit build, and use the corresponding
47# 64 or 32 bit NVIDIA library paths to the search:
48STRING(REGEX MATCH "Win64" ISWIN64 ${CMAKE_GENERATOR})
49IF("${ISWIN64}" STREQUAL "Win64")
50FIND_LIBRARY(OPENCL_LIBRARIES OpenCL.lib ${OPENCL_LIB_DIR} $ENV{CUDA_LIB_PATH} $ENV{CUDA_PATH}/lib/x64)
51ELSE("${ISWIN64}" STREQUAL "Win64")
52FIND_LIBRARY(OPENCL_LIBRARIES OpenCL.lib ${OPENCL_LIB_DIR} $ENV{CUDA_LIB_PATH} $ENV{CUDA_PATH}/lib/Win32)
53ENDIF("${ISWIN64}" STREQUAL "Win64")
54
55GET_FILENAME_COMPONENT(_OPENCL_INC_CAND ${OPENCL_LIB_DIR}/../../include ABSOLUTE)
56
57# On Win32 search relative to the library
58FIND_PATH(OPENCL_INCLUDE_DIRS CL/cl.h PATHS "${_OPENCL_INC_CAND}" $ENV{CUDA_INC_PATH} $ENV{CUDA_PATH}/include)
59FIND_PATH(_OPENCL_CPP_INCLUDE_DIRS CL/cl.hpp PATHS "${_OPENCL_INC_CAND}" $ENV{CUDA_INC_PATH} $ENV{CUDA_PATH}/include)
60
61ELSE (WIN32)
62
63# Unix style platforms
64FIND_PATH(OPENCL_INCLUDE_DIRS CL/cl.h PATHS
65/usr/local/NVIDIA_GPU_Computing_SDK/OpenCL/common/inc
66/usr/local/cuda/include
67/usr/projects/hpcsoft/moonlight/cudatoolkit-4.2/include
68/home/cuda/cuda4.2/include
69/opt/cudatoolkit-5.0/include
70/opt/cudatoolkit-4.1/include
71/projects/opt/opencl1d2_additional_files/include
72)
73
74FIND_LIBRARY(OPENCL_LIBRARIES OpenCL
75ENV LD_LIBRARY_PATH
76/usr/lib
77/usr/lib64
78)
79
80GET_FILENAME_COMPONENT(OPENCL_LIB_DIR ${OPENCL_LIBRARIES} PATH)
81GET_FILENAME_COMPONENT(_OPENCL_INC_CAND ${OPENCL_LIB_DIR}/../../include ABSOLUTE)
82
83# The AMD SDK currently does not place its headers
84# in /usr/include, therefore also search relative
85# to the library
86FIND_PATH(OPENCL_INCLUDE_DIRS CL/cl.h PATHS ${_OPENCL_INC_CAND} "/usr/local/cuda/include")
87FIND_PATH(_OPENCL_CPP_INCLUDE_DIRS CL/cl.hpp PATHS ${_OPENCL_INC_CAND} "/usr/local/cuda/include")
88
89ENDIF (WIN32)
90
91ENDIF (APPLE)
92
93FIND_PACKAGE_HANDLE_STANDARD_ARGS( OpenCL DEFAULT_MSG OPENCL_LIBRARIES OPENCL_INCLUDE_DIRS )
94
95IF( _OPENCL_CPP_INCLUDE_DIRS )
96SET( OPENCL_HAS_CPP_BINDINGS TRUE )
97LIST( APPEND OPENCL_INCLUDE_DIRS ${_OPENCL_CPP_INCLUDE_DIRS} )
98# This is often the same, so clean up
99LIST( REMOVE_DUPLICATES OPENCL_INCLUDE_DIRS )
100ENDIF( _OPENCL_CPP_INCLUDE_DIRS )
101
102#IF (APPLE)
103# set(HAVE_CL_DOUBLE OFF CACHE BOOL "Have OpenCL Double")
104# set(NO_CL_DOUBLE ON)
105#ELSE (APPLE)
106 set(HAVE_CL_DOUBLE ON CACHE BOOL "Have OpenCL Double")
107 set(NO_CL_DOUBLE OFF)
108#ENDIF (APPLE)
109
110MARK_AS_ADVANCED(
111OPENCL_INCLUDE_DIRS
112)
113
114
cmake/Modules/TargetDistclean.cmake +50 -0
……@@ -0,0 +1,50 @@
1# add custom target distclean
2# cleans and removes cmake generated files etc.
3# Jan Woetzel 04/2003
4#
5
6IF (UNIX)
7 ADD_CUSTOM_TARGET (distclean @echo cleaning for source distribution)
8 SET(DISTCLEANED
9 cmake.depends
10 cmake.check_depends
11 CMakeCache.txt
12 */CMakeCache.txt
13 */*/CMakeCache.txt
14 cmake.check_cache
15 *.cmake
16 *.a
17 */*.a
18 */*/*.a
19 Makefile
20 */Makefile
21 */*/Makefile
22 */tests/Makefile
23 core core.*
24 gmon.out
25 *~
26 CMakeFiles
27 */CMakeFiles
28 */*/CMakeFiles
29 */CTestTestfile.cmake
30 */*/CTestTestfile.cmake
31 */Testing
32 */*/Testing
33 cmake_install.cmake
34 */cmake_install.cmake
35 */*/cmake_install.cmake
36 install_manifest.txt
37 */install_manifest.txt
38 *.dSYM
39 */*.dSYM
40 */*/*.dSYM
41 )
42
43 ADD_CUSTOM_COMMAND(
44 DEPENDS clean
45 COMMENT "distribution clean"
46 COMMAND rm
47 ARGS -Rf CMakeTmp ${DISTCLEANED}
48 TARGET distclean
49 )
50ENDIF(UNIX)
config/compile +0 -143
……@@ -1,143 +0,0 @@
1#! /bin/sh
2# Wrapper for compilers which do not understand `-c -o'.
3
4scriptversion=2009-10-06.20; # UTC
5
6# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2009 Free Software
7# Foundation, Inc.
8# Written by Tom Tromey <tromey@cygnus.com>.
9#
10# This program is free software; you can redistribute it and/or modify
11# it under the terms of the GNU General Public License as published by
12# the Free Software Foundation; either version 2, or (at your option)
13# any later version.
14#
15# This program is distributed in the hope that it will be useful,
16# but WITHOUT ANY WARRANTY; without even the implied warranty of
17# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18# GNU General Public License for more details.
19#
20# You should have received a copy of the GNU General Public License
21# along with this program. If not, see <http://www.gnu.org/licenses/>.
22
23# As a special exception to the GNU General Public License, if you
24# distribute this file as part of a program that contains a
25# configuration script generated by Autoconf, you may include it under
26# the same distribution terms that you use for the rest of that program.
27
28# This file is maintained in Automake, please report
29# bugs to <bug-automake@gnu.org> or send patches to
30# <automake-patches@gnu.org>.
31
32case $1 in
33 '')
34 echo "$0: No command. Try \`$0 --help' for more information." 1>&2
35 exit 1;
36 ;;
37 -h | --h*)
38 cat <<\EOF
39Usage: compile [--help] [--version] PROGRAM [ARGS]
40
41Wrapper for compilers which do not understand `-c -o'.
42Remove `-o dest.o' from ARGS, run PROGRAM with the remaining
43arguments, and rename the output as expected.
44
45If you are trying to build a whole package this is not the
46right script to run: please start by reading the file `INSTALL'.
47
48Report bugs to <bug-automake@gnu.org>.
49EOF
50 exit $?
51 ;;
52 -v | --v*)
53 echo "compile $scriptversion"
54 exit $?
55 ;;
56esac
57
58ofile=
59cfile=
60eat=
61
62for arg
63do
64 if test -n "$eat"; then
65 eat=
66 else
67 case $1 in
68 -o)
69 # configure might choose to run compile as `compile cc -o foo foo.c'.
70 # So we strip `-o arg' only if arg is an object.
71 eat=1
72 case $2 in
73 *.o | *.obj)
74 ofile=$2
75 ;;
76 *)
77 set x "$@" -o "$2"
78 shift
79 ;;
80 esac
81 ;;
82 *.c)
83 cfile=$1
84 set x "$@" "$1"
85 shift
86 ;;
87 *)
88 set x "$@" "$1"
89 shift
90 ;;
91 esac
92 fi
93 shift
94done
95
96if test -z "$ofile" || test -z "$cfile"; then
97 # If no `-o' option was seen then we might have been invoked from a
98 # pattern rule where we don't need one. That is ok -- this is a
99 # normal compilation that the losing compiler can handle. If no
100 # `.c' file was seen then we are probably linking. That is also
101 # ok.
102 exec "$@"
103fi
104
105# Name of file we expect compiler to create.
106cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'`
107
108# Create the lock directory.
109# Note: use `[/\\:.-]' here to ensure that we don't use the same name
110# that we are using for the .o file. Also, base the name on the expected
111# object file name, since that is what matters with a parallel build.
112lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d
113while true; do
114 if mkdir "$lockdir" >/dev/null 2>&1; then
115 break
116 fi
117 sleep 1
118done
119# FIXME: race condition here if user kills between mkdir and trap.
120trap "rmdir '$lockdir'; exit 1" 1 2 15
121
122# Run the compile.
123"$@"
124ret=$?
125
126if test -f "$cofile"; then
127 test "$cofile" = "$ofile" || mv "$cofile" "$ofile"
128elif test -f "${cofile}bj"; then
129 test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile"
130fi
131
132rmdir "$lockdir"
133exit $ret
134
135# Local Variables:
136# mode: shell-script
137# sh-indentation: 2
138# eval: (add-hook 'write-file-hooks 'time-stamp)
139# time-stamp-start: "scriptversion="
140# time-stamp-format: "%:y-%02m-%02d.%02H"
141# time-stamp-time-zone: "UTC"
142# time-stamp-end: "; # UTC"
143# End:
config/config.guess +0 -1501
……@@ -1,1501 +0,0 @@
1#! /bin/sh
2# Attempt to guess a canonical system name.
3# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
4# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
5# Free Software Foundation, Inc.
6
7timestamp='2009-11-20'
8
9# This file is free software; you can redistribute it and/or modify it
10# under the terms of the GNU General Public License as published by
11# the Free Software Foundation; either version 2 of the License, or
12# (at your option) any later version.
13#
14# This program is distributed in the hope that it will be useful, but
15# WITHOUT ANY WARRANTY; without even the implied warranty of
16# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17# General Public License for more details.
18#
19# You should have received a copy of the GNU General Public License
20# along with this program; if not, write to the Free Software
21# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
22# 02110-1301, USA.
23#
24# As a special exception to the GNU General Public License, if you
25# distribute this file as part of a program that contains a
26# configuration script generated by Autoconf, you may include it under
27# the same distribution terms that you use for the rest of that program.
28
29
30# Originally written by Per Bothner. Please send patches (context
31# diff format) to <config-patches@gnu.org> and include a ChangeLog
32# entry.
33#
34# This script attempts to guess a canonical system name similar to
35# config.sub. If it succeeds, it prints the system name on stdout, and
36# exits with 0. Otherwise, it exits with 1.
37#
38# You can get the latest version of this script from:
39# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
40
41me=`echo "$0" | sed -e 's,.*/,,'`
42
43usage="\
44Usage: $0 [OPTION]
45
46Output the configuration name of the system \`$me' is run on.
47
48Operation modes:
49 -h, --help print this help, then exit
50 -t, --time-stamp print date of last modification, then exit
51 -v, --version print version number, then exit
52
53Report bugs and patches to <config-patches@gnu.org>."
54
55version="\
56GNU config.guess ($timestamp)
57
58Originally written by Per Bothner.
59Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
602002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
61
62This is free software; see the source for copying conditions. There is NO
63warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
64
65help="
66Try \`$me --help' for more information."
67
68# Parse command line
69while test $# -gt 0 ; do
70 case $1 in
71 --time-stamp | --time* | -t )
72 echo "$timestamp" ; exit ;;
73 --version | -v )
74 echo "$version" ; exit ;;
75 --help | --h* | -h )
76 echo "$usage"; exit ;;
77 -- ) # Stop option processing
78 shift; break ;;
79 - ) # Use stdin as input.
80 break ;;
81 -* )
82 echo "$me: invalid option $1$help" >&2
83 exit 1 ;;
84 * )
85 break ;;
86 esac
87done
88
89if test $# != 0; then
90 echo "$me: too many arguments$help" >&2
91 exit 1
92fi
93
94trap 'exit 1' 1 2 15
95
96# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
97# compiler to aid in system detection is discouraged as it requires
98# temporary files to be created and, as you can see below, it is a
99# headache to deal with in a portable fashion.
100
101# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
102# use `HOST_CC' if defined, but it is deprecated.
103
104# Portable tmp directory creation inspired by the Autoconf team.
105
106set_cc_for_build='
107trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
108trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
109: ${TMPDIR=/tmp} ;
110 { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
111 { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
112 { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
113 { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
114dummy=$tmp/dummy ;
115tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ;
116case $CC_FOR_BUILD,$HOST_CC,$CC in
117 ,,) echo "int x;" > $dummy.c ;
118 for c in cc gcc c89 c99 ; do
119 if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then
120 CC_FOR_BUILD="$c"; break ;
121 fi ;
122 done ;
123 if test x"$CC_FOR_BUILD" = x ; then
124 CC_FOR_BUILD=no_compiler_found ;
125 fi
126 ;;
127 ,,*) CC_FOR_BUILD=$CC ;;
128 ,*,*) CC_FOR_BUILD=$HOST_CC ;;
129esac ; set_cc_for_build= ;'
130
131# This is needed to find uname on a Pyramid OSx when run in the BSD universe.
132# (ghazi@noc.rutgers.edu 1994-08-24)
133if (test -f /.attbin/uname) >/dev/null 2>&1 ; then
134 PATH=$PATH:/.attbin ; export PATH
135fi
136
137UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown
138UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown
139UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown
140UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown
141
142# Note: order is significant - the case branches are not exclusive.
143
144case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
145 *:NetBSD:*:*)
146 # NetBSD (nbsd) targets should (where applicable) match one or
147 # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*,
148 # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently
149 # switched to ELF, *-*-netbsd* would select the old
150 # object file format. This provides both forward
151 # compatibility and a consistent mechanism for selecting the
152 # object file format.
153 #
154 # Note: NetBSD doesn't particularly care about the vendor
155 # portion of the name. We always set it to "unknown".
156 sysctl="sysctl -n hw.machine_arch"
157 UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \
158 /usr/sbin/$sysctl 2>/dev/null || echo unknown)`
159 case "${UNAME_MACHINE_ARCH}" in
160 armeb) machine=armeb-unknown ;;
161 arm*) machine=arm-unknown ;;
162 sh3el) machine=shl-unknown ;;
163 sh3eb) machine=sh-unknown ;;
164 sh5el) machine=sh5le-unknown ;;
165 *) machine=${UNAME_MACHINE_ARCH}-unknown ;;
166 esac
167 # The Operating System including object format, if it has switched
168 # to ELF recently, or will in the future.
169 case "${UNAME_MACHINE_ARCH}" in
170 arm*|i386|m68k|ns32k|sh3*|sparc|vax)
171 eval $set_cc_for_build
172 if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \
173 | grep -q __ELF__
174 then
175 # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout).
176 # Return netbsd for either. FIX?
177 os=netbsd
178 else
179 os=netbsdelf
180 fi
181 ;;
182 *)
183 os=netbsd
184 ;;
185 esac
186 # The OS release
187 # Debian GNU/NetBSD machines have a different userland, and
188 # thus, need a distinct triplet. However, they do not need
189 # kernel version information, so it can be replaced with a
190 # suitable tag, in the style of linux-gnu.
191 case "${UNAME_VERSION}" in
192 Debian*)
193 release='-gnu'
194 ;;
195 *)
196 release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
197 ;;
198 esac
199 # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
200 # contains redundant information, the shorter form:
201 # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
202 echo "${machine}-${os}${release}"
203 exit ;;
204 *:OpenBSD:*:*)
205 UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'`
206 echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE}
207 exit ;;
208 *:ekkoBSD:*:*)
209 echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
210 exit ;;
211 *:SolidBSD:*:*)
212 echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE}
213 exit ;;
214 macppc:MirBSD:*:*)
215 echo powerpc-unknown-mirbsd${UNAME_RELEASE}
216 exit ;;
217 *:MirBSD:*:*)
218 echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
219 exit ;;
220 alpha:OSF1:*:*)
221 case $UNAME_RELEASE in
222 *4.0)
223 UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
224 ;;
225 *5.*)
226 UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'`
227 ;;
228 esac
229 # According to Compaq, /usr/sbin/psrinfo has been available on
230 # OSF/1 and Tru64 systems produced since 1995. I hope that
231 # covers most systems running today. This code pipes the CPU
232 # types through head -n 1, so we only detect the type of CPU 0.
233 ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1`
234 case "$ALPHA_CPU_TYPE" in
235 "EV4 (21064)")
236 UNAME_MACHINE="alpha" ;;
237 "EV4.5 (21064)")
238 UNAME_MACHINE="alpha" ;;
239 "LCA4 (21066/21068)")
240 UNAME_MACHINE="alpha" ;;
241 "EV5 (21164)")
242 UNAME_MACHINE="alphaev5" ;;
243 "EV5.6 (21164A)")
244 UNAME_MACHINE="alphaev56" ;;
245 "EV5.6 (21164PC)")
246 UNAME_MACHINE="alphapca56" ;;
247 "EV5.7 (21164PC)")
248 UNAME_MACHINE="alphapca57" ;;
249 "EV6 (21264)")
250 UNAME_MACHINE="alphaev6" ;;
251 "EV6.7 (21264A)")
252 UNAME_MACHINE="alphaev67" ;;
253 "EV6.8CB (21264C)")
254 UNAME_MACHINE="alphaev68" ;;
255 "EV6.8AL (21264B)")
256 UNAME_MACHINE="alphaev68" ;;
257 "EV6.8CX (21264D)")
258 UNAME_MACHINE="alphaev68" ;;
259 "EV6.9A (21264/EV69A)")
260 UNAME_MACHINE="alphaev69" ;;
261 "EV7 (21364)")
262 UNAME_MACHINE="alphaev7" ;;
263 "EV7.9 (21364A)")
264 UNAME_MACHINE="alphaev79" ;;
265 esac
266 # A Pn.n version is a patched version.
267 # A Vn.n version is a released version.
268 # A Tn.n version is a released field test version.
269 # A Xn.n version is an unreleased experimental baselevel.
270 # 1.2 uses "1.2" for uname -r.
271 echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
272 exit ;;
273 Alpha\ *:Windows_NT*:*)
274 # How do we know it's Interix rather than the generic POSIX subsystem?
275 # Should we change UNAME_MACHINE based on the output of uname instead
276 # of the specific Alpha model?
277 echo alpha-pc-interix
278 exit ;;
279 21064:Windows_NT:50:3)
280 echo alpha-dec-winnt3.5
281 exit ;;
282 Amiga*:UNIX_System_V:4.0:*)
283 echo m68k-unknown-sysv4
284 exit ;;
285 *:[Aa]miga[Oo][Ss]:*:*)
286 echo ${UNAME_MACHINE}-unknown-amigaos
287 exit ;;
288 *:[Mm]orph[Oo][Ss]:*:*)
289 echo ${UNAME_MACHINE}-unknown-morphos
290 exit ;;
291 *:OS/390:*:*)
292 echo i370-ibm-openedition
293 exit ;;
294 *:z/VM:*:*)
295 echo s390-ibm-zvmoe
296 exit ;;
297 *:OS400:*:*)
298 echo powerpc-ibm-os400
299 exit ;;
300 arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
301 echo arm-acorn-riscix${UNAME_RELEASE}
302 exit ;;
303 arm:riscos:*:*|arm:RISCOS:*:*)
304 echo arm-unknown-riscos
305 exit ;;
306 SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*)
307 echo hppa1.1-hitachi-hiuxmpp
308 exit ;;
309 Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*)
310 # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE.
311 if test "`(/bin/universe) 2>/dev/null`" = att ; then
312 echo pyramid-pyramid-sysv3
313 else
314 echo pyramid-pyramid-bsd
315 fi
316 exit ;;
317 NILE*:*:*:dcosx)
318 echo pyramid-pyramid-svr4
319 exit ;;
320 DRS?6000:unix:4.0:6*)
321 echo sparc-icl-nx6
322 exit ;;
323 DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*)
324 case `/usr/bin/uname -p` in
325 sparc) echo sparc-icl-nx7; exit ;;
326 esac ;;
327 s390x:SunOS:*:*)
328 echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
329 exit ;;
330 sun4H:SunOS:5.*:*)
331 echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
332 exit ;;
333 sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
334 echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
335 exit ;;
336 i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*)
337 echo i386-pc-auroraux${UNAME_RELEASE}
338 exit ;;
339 i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
340 eval $set_cc_for_build
341 SUN_ARCH="i386"
342 # If there is a compiler, see if it is configured for 64-bit objects.
343 # Note that the Sun cc does not turn __LP64__ into 1 like gcc does.
344 # This test works for both compilers.
345 if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
346 if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \
347 (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
348 grep IS_64BIT_ARCH >/dev/null
349 then
350 SUN_ARCH="x86_64"
351 fi
352 fi
353 echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
354 exit ;;
355 sun4*:SunOS:6*:*)
356 # According to config.sub, this is the proper way to canonicalize
357 # SunOS6. Hard to guess exactly what SunOS6 will be like, but
358 # it's likely to be more like Solaris than SunOS4.
359 echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
360 exit ;;
361 sun4*:SunOS:*:*)
362 case "`/usr/bin/arch -k`" in
363 Series*|S4*)
364 UNAME_RELEASE=`uname -v`
365 ;;
366 esac
367 # Japanese Language versions have a version number like `4.1.3-JL'.
368 echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'`
369 exit ;;
370 sun3*:SunOS:*:*)
371 echo m68k-sun-sunos${UNAME_RELEASE}
372 exit ;;
373 sun*:*:4.2BSD:*)
374 UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null`
375 test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3
376 case "`/bin/arch`" in
377 sun3)
378 echo m68k-sun-sunos${UNAME_RELEASE}
379 ;;
380 sun4)
381 echo sparc-sun-sunos${UNAME_RELEASE}
382 ;;
383 esac
384 exit ;;
385 aushp:SunOS:*:*)
386 echo sparc-auspex-sunos${UNAME_RELEASE}
387 exit ;;
388 # The situation for MiNT is a little confusing. The machine name
389 # can be virtually everything (everything which is not
390 # "atarist" or "atariste" at least should have a processor
391 # > m68000). The system name ranges from "MiNT" over "FreeMiNT"
392 # to the lowercase version "mint" (or "freemint"). Finally
393 # the system name "TOS" denotes a system which is actually not
394 # MiNT. But MiNT is downward compatible to TOS, so this should
395 # be no problem.
396 atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*)
397 echo m68k-atari-mint${UNAME_RELEASE}
398 exit ;;
399 atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*)
400 echo m68k-atari-mint${UNAME_RELEASE}
401 exit ;;
402 *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*)
403 echo m68k-atari-mint${UNAME_RELEASE}
404 exit ;;
405 milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*)
406 echo m68k-milan-mint${UNAME_RELEASE}
407 exit ;;
408 hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*)
409 echo m68k-hades-mint${UNAME_RELEASE}
410 exit ;;
411 *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
412 echo m68k-unknown-mint${UNAME_RELEASE}
413 exit ;;
414 m68k:machten:*:*)
415 echo m68k-apple-machten${UNAME_RELEASE}
416 exit ;;
417 powerpc:machten:*:*)
418 echo powerpc-apple-machten${UNAME_RELEASE}
419 exit ;;
420 RISC*:Mach:*:*)
421 echo mips-dec-mach_bsd4.3
422 exit ;;
423 RISC*:ULTRIX:*:*)
424 echo mips-dec-ultrix${UNAME_RELEASE}
425 exit ;;
426 VAX*:ULTRIX*:*:*)
427 echo vax-dec-ultrix${UNAME_RELEASE}
428 exit ;;
429 2020:CLIX:*:* | 2430:CLIX:*:*)
430 echo clipper-intergraph-clix${UNAME_RELEASE}
431 exit ;;
432 mips:*:*:UMIPS | mips:*:*:RISCos)
433 eval $set_cc_for_build
434 sed 's/^ //' << EOF >$dummy.c
435#ifdef __cplusplus
436#include <stdio.h> /* for printf() prototype */
437 int main (int argc, char *argv[]) {
438#else
439 int main (argc, argv) int argc; char *argv[]; {
440#endif
441 #if defined (host_mips) && defined (MIPSEB)
442 #if defined (SYSTYPE_SYSV)
443 printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0);
444 #endif
445 #if defined (SYSTYPE_SVR4)
446 printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0);
447 #endif
448 #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD)
449 printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0);
450 #endif
451 #endif
452 exit (-1);
453 }
454EOF
455 $CC_FOR_BUILD -o $dummy $dummy.c &&
456 dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` &&
457 SYSTEM_NAME=`$dummy $dummyarg` &&
458 { echo "$SYSTEM_NAME"; exit; }
459 echo mips-mips-riscos${UNAME_RELEASE}
460 exit ;;
461 Motorola:PowerMAX_OS:*:*)
462 echo powerpc-motorola-powermax
463 exit ;;
464 Motorola:*:4.3:PL8-*)
465 echo powerpc-harris-powermax
466 exit ;;
467 Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*)
468 echo powerpc-harris-powermax
469 exit ;;
470 Night_Hawk:Power_UNIX:*:*)
471 echo powerpc-harris-powerunix
472 exit ;;
473 m88k:CX/UX:7*:*)
474 echo m88k-harris-cxux7
475 exit ;;
476 m88k:*:4*:R4*)
477 echo m88k-motorola-sysv4
478 exit ;;
479 m88k:*:3*:R3*)
480 echo m88k-motorola-sysv3
481 exit ;;
482 AViiON:dgux:*:*)
483 # DG/UX returns AViiON for all architectures
484 UNAME_PROCESSOR=`/usr/bin/uname -p`
485 if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ]
486 then
487 if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \
488 [ ${TARGET_BINARY_INTERFACE}x = x ]
489 then
490 echo m88k-dg-dgux${UNAME_RELEASE}
491 else
492 echo m88k-dg-dguxbcs${UNAME_RELEASE}
493 fi
494 else
495 echo i586-dg-dgux${UNAME_RELEASE}
496 fi
497 exit ;;
498 M88*:DolphinOS:*:*) # DolphinOS (SVR3)
499 echo m88k-dolphin-sysv3
500 exit ;;
501 M88*:*:R3*:*)
502 # Delta 88k system running SVR3
503 echo m88k-motorola-sysv3
504 exit ;;
505 XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3)
506 echo m88k-tektronix-sysv3
507 exit ;;
508 Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD)
509 echo m68k-tektronix-bsd
510 exit ;;
511 *:IRIX*:*:*)
512 echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'`
513 exit ;;
514 ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX.
515 echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id
516 exit ;; # Note that: echo "'`uname -s`'" gives 'AIX '
517 i*86:AIX:*:*)
518 echo i386-ibm-aix
519 exit ;;
520 ia64:AIX:*:*)
521 if [ -x /usr/bin/oslevel ] ; then
522 IBM_REV=`/usr/bin/oslevel`
523 else
524 IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
525 fi
526 echo ${UNAME_MACHINE}-ibm-aix${IBM_REV}
527 exit ;;
528 *:AIX:2:3)
529 if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then
530 eval $set_cc_for_build
531 sed 's/^ //' << EOF >$dummy.c
532 #include <sys/systemcfg.h>
533
534 main()
535 {
536 if (!__power_pc())
537 exit(1);
538 puts("powerpc-ibm-aix3.2.5");
539 exit(0);
540 }
541EOF
542 if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy`
543 then
544 echo "$SYSTEM_NAME"
545 else
546 echo rs6000-ibm-aix3.2.5
547 fi
548 elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
549 echo rs6000-ibm-aix3.2.4
550 else
551 echo rs6000-ibm-aix3.2
552 fi
553 exit ;;
554 *:AIX:*:[456])
555 IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
556 if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
557 IBM_ARCH=rs6000
558 else
559 IBM_ARCH=powerpc
560 fi
561 if [ -x /usr/bin/oslevel ] ; then
562 IBM_REV=`/usr/bin/oslevel`
563 else
564 IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE}
565 fi
566 echo ${IBM_ARCH}-ibm-aix${IBM_REV}
567 exit ;;
568 *:AIX:*:*)
569 echo rs6000-ibm-aix
570 exit ;;
571 ibmrt:4.4BSD:*|romp-ibm:BSD:*)
572 echo romp-ibm-bsd4.4
573 exit ;;
574 ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and
575 echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to
576 exit ;; # report: romp-ibm BSD 4.3
577 *:BOSX:*:*)
578 echo rs6000-bull-bosx
579 exit ;;
580 DPX/2?00:B.O.S.:*:*)
581 echo m68k-bull-sysv3
582 exit ;;
583 9000/[34]??:4.3bsd:1.*:*)
584 echo m68k-hp-bsd
585 exit ;;
586 hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*)
587 echo m68k-hp-bsd4.4
588 exit ;;
589 9000/[34678]??:HP-UX:*:*)
590 HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
591 case "${UNAME_MACHINE}" in
592 9000/31? ) HP_ARCH=m68000 ;;
593 9000/[34]?? ) HP_ARCH=m68k ;;
594 9000/[678][0-9][0-9])
595 if [ -x /usr/bin/getconf ]; then
596 sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null`
597 sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null`
598 case "${sc_cpu_version}" in
599 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0
600 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1
601 532) # CPU_PA_RISC2_0
602 case "${sc_kernel_bits}" in
603 32) HP_ARCH="hppa2.0n" ;;
604 64) HP_ARCH="hppa2.0w" ;;
605 '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20
606 esac ;;
607 esac
608 fi
609 if [ "${HP_ARCH}" = "" ]; then
610 eval $set_cc_for_build
611 sed 's/^ //' << EOF >$dummy.c
612
613 #define _HPUX_SOURCE
614 #include <stdlib.h>
615 #include <unistd.h>
616
617 int main ()
618 {
619 #if defined(_SC_KERNEL_BITS)
620 long bits = sysconf(_SC_KERNEL_BITS);
621 #endif
622 long cpu = sysconf (_SC_CPU_VERSION);
623
624 switch (cpu)
625 {
626 case CPU_PA_RISC1_0: puts ("hppa1.0"); break;
627 case CPU_PA_RISC1_1: puts ("hppa1.1"); break;
628 case CPU_PA_RISC2_0:
629 #if defined(_SC_KERNEL_BITS)
630 switch (bits)
631 {
632 case 64: puts ("hppa2.0w"); break;
633 case 32: puts ("hppa2.0n"); break;
634 default: puts ("hppa2.0"); break;
635 } break;
636 #else /* !defined(_SC_KERNEL_BITS) */
637 puts ("hppa2.0"); break;
638 #endif
639 default: puts ("hppa1.0"); break;
640 }
641 exit (0);
642 }
643EOF
644 (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy`
645 test -z "$HP_ARCH" && HP_ARCH=hppa
646 fi ;;
647 esac
648 if [ ${HP_ARCH} = "hppa2.0w" ]
649 then
650 eval $set_cc_for_build
651
652 # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating
653 # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler
654 # generating 64-bit code. GNU and HP use different nomenclature:
655 #
656 # $ CC_FOR_BUILD=cc ./config.guess
657 # => hppa2.0w-hp-hpux11.23
658 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess
659 # => hppa64-hp-hpux11.23
660
661 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) |
662 grep -q __LP64__
663 then
664 HP_ARCH="hppa2.0w"
665 else
666 HP_ARCH="hppa64"
667 fi
668 fi
669 echo ${HP_ARCH}-hp-hpux${HPUX_REV}
670 exit ;;
671 ia64:HP-UX:*:*)
672 HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'`
673 echo ia64-hp-hpux${HPUX_REV}
674 exit ;;
675 3050*:HI-UX:*:*)
676 eval $set_cc_for_build
677 sed 's/^ //' << EOF >$dummy.c
678 #include <unistd.h>
679 int
680 main ()
681 {
682 long cpu = sysconf (_SC_CPU_VERSION);
683 /* The order matters, because CPU_IS_HP_MC68K erroneously returns
684 true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct
685 results, however. */
686 if (CPU_IS_PA_RISC (cpu))
687 {
688 switch (cpu)
689 {
690 case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break;
691 case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break;
692 case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break;
693 default: puts ("hppa-hitachi-hiuxwe2"); break;
694 }
695 }
696 else if (CPU_IS_HP_MC68K (cpu))
697 puts ("m68k-hitachi-hiuxwe2");
698 else puts ("unknown-hitachi-hiuxwe2");
699 exit (0);
700 }
701EOF
702 $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` &&
703 { echo "$SYSTEM_NAME"; exit; }
704 echo unknown-hitachi-hiuxwe2
705 exit ;;
706 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
707 echo hppa1.1-hp-bsd
708 exit ;;
709 9000/8??:4.3bsd:*:*)
710 echo hppa1.0-hp-bsd
711 exit ;;
712 *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*)
713 echo hppa1.0-hp-mpeix
714 exit ;;
715 hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* )
716 echo hppa1.1-hp-osf
717 exit ;;
718 hp8??:OSF1:*:*)
719 echo hppa1.0-hp-osf
720 exit ;;
721 i*86:OSF1:*:*)
722 if [ -x /usr/sbin/sysversion ] ; then
723 echo ${UNAME_MACHINE}-unknown-osf1mk
724 else
725 echo ${UNAME_MACHINE}-unknown-osf1
726 fi
727 exit ;;
728 parisc*:Lites*:*:*)
729 echo hppa1.1-hp-lites
730 exit ;;
731 C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*)
732 echo c1-convex-bsd
733 exit ;;
734 C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*)
735 if getsysinfo -f scalar_acc
736 then echo c32-convex-bsd
737 else echo c2-convex-bsd
738 fi
739 exit ;;
740 C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*)
741 echo c34-convex-bsd
742 exit ;;
743 C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*)
744 echo c38-convex-bsd
745 exit ;;
746 C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*)
747 echo c4-convex-bsd
748 exit ;;
749 CRAY*Y-MP:*:*:*)
750 echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
751 exit ;;
752 CRAY*[A-Z]90:*:*:*)
753 echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \
754 | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \
755 -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \
756 -e 's/\.[^.]*$/.X/'
757 exit ;;
758 CRAY*TS:*:*:*)
759 echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
760 exit ;;
761 CRAY*T3E:*:*:*)
762 echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
763 exit ;;
764 CRAY*SV1:*:*:*)
765 echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
766 exit ;;
767 *:UNICOS/mp:*:*)
768 echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
769 exit ;;
770 F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
771 FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
772 FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
773 FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
774 echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
775 exit ;;
776 5000:UNIX_System_V:4.*:*)
777 FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
778 FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
779 echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
780 exit ;;
781 i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
782 echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
783 exit ;;
784 sparc*:BSD/OS:*:*)
785 echo sparc-unknown-bsdi${UNAME_RELEASE}
786 exit ;;
787 *:BSD/OS:*:*)
788 echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
789 exit ;;
790 *:FreeBSD:*:*)
791 case ${UNAME_MACHINE} in
792 pc98)
793 echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
794 amd64)
795 echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
796 *)
797 echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
798 esac
799 exit ;;
800 i*:CYGWIN*:*)
801 echo ${UNAME_MACHINE}-pc-cygwin
802 exit ;;
803 *:MINGW*:*)
804 echo ${UNAME_MACHINE}-pc-mingw32
805 exit ;;
806 i*:windows32*:*)
807 # uname -m includes "-pc" on this system.
808 echo ${UNAME_MACHINE}-mingw32
809 exit ;;
810 i*:PW*:*)
811 echo ${UNAME_MACHINE}-pc-pw32
812 exit ;;
813 *:Interix*:*)
814 case ${UNAME_MACHINE} in
815 x86)
816 echo i586-pc-interix${UNAME_RELEASE}
817 exit ;;
818 authenticamd | genuineintel | EM64T)
819 echo x86_64-unknown-interix${UNAME_RELEASE}
820 exit ;;
821 IA64)
822 echo ia64-unknown-interix${UNAME_RELEASE}
823 exit ;;
824 esac ;;
825 [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
826 echo i${UNAME_MACHINE}-pc-mks
827 exit ;;
828 8664:Windows_NT:*)
829 echo x86_64-pc-mks
830 exit ;;
831 i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
832 # How do we know it's Interix rather than the generic POSIX subsystem?
833 # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
834 # UNAME_MACHINE based on the output of uname instead of i386?
835 echo i586-pc-interix
836 exit ;;
837 i*:UWIN*:*)
838 echo ${UNAME_MACHINE}-pc-uwin
839 exit ;;
840 amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*)
841 echo x86_64-unknown-cygwin
842 exit ;;
843 p*:CYGWIN*:*)
844 echo powerpcle-unknown-cygwin
845 exit ;;
846 prep*:SunOS:5.*:*)
847 echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
848 exit ;;
849 *:GNU:*:*)
850 # the GNU system
851 echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
852 exit ;;
853 *:GNU/*:*:*)
854 # other systems with GNU libc and userland
855 echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu
856 exit ;;
857 i*86:Minix:*:*)
858 echo ${UNAME_MACHINE}-pc-minix
859 exit ;;
860 alpha:Linux:*:*)
861 case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in
862 EV5) UNAME_MACHINE=alphaev5 ;;
863 EV56) UNAME_MACHINE=alphaev56 ;;
864 PCA56) UNAME_MACHINE=alphapca56 ;;
865 PCA57) UNAME_MACHINE=alphapca56 ;;
866 EV6) UNAME_MACHINE=alphaev6 ;;
867 EV67) UNAME_MACHINE=alphaev67 ;;
868 EV68*) UNAME_MACHINE=alphaev68 ;;
869 esac
870 objdump --private-headers /bin/sh | grep -q ld.so.1
871 if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi
872 echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC}
873 exit ;;
874 arm*:Linux:*:*)
875 eval $set_cc_for_build
876 if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
877 | grep -q __ARM_EABI__
878 then
879 echo ${UNAME_MACHINE}-unknown-linux-gnu
880 else
881 echo ${UNAME_MACHINE}-unknown-linux-gnueabi
882 fi
883 exit ;;
884 avr32*:Linux:*:*)
885 echo ${UNAME_MACHINE}-unknown-linux-gnu
886 exit ;;
887 cris:Linux:*:*)
888 echo cris-axis-linux-gnu
889 exit ;;
890 crisv32:Linux:*:*)
891 echo crisv32-axis-linux-gnu
892 exit ;;
893 frv:Linux:*:*)
894 echo frv-unknown-linux-gnu
895 exit ;;
896 i*86:Linux:*:*)
897 LIBC=gnu
898 eval $set_cc_for_build
899 sed 's/^ //' << EOF >$dummy.c
900 #ifdef __dietlibc__
901 LIBC=dietlibc
902 #endif
903EOF
904 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'`
905 echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
906 exit ;;
907 ia64:Linux:*:*)
908 echo ${UNAME_MACHINE}-unknown-linux-gnu
909 exit ;;
910 m32r*:Linux:*:*)
911 echo ${UNAME_MACHINE}-unknown-linux-gnu
912 exit ;;
913 m68*:Linux:*:*)
914 echo ${UNAME_MACHINE}-unknown-linux-gnu
915 exit ;;
916 mips:Linux:*:* | mips64:Linux:*:*)
917 eval $set_cc_for_build
918 sed 's/^ //' << EOF >$dummy.c
919 #undef CPU
920 #undef ${UNAME_MACHINE}
921 #undef ${UNAME_MACHINE}el
922 #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
923 CPU=${UNAME_MACHINE}el
924 #else
925 #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
926 CPU=${UNAME_MACHINE}
927 #else
928 CPU=
929 #endif
930 #endif
931EOF
932 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'`
933 test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
934 ;;
935 or32:Linux:*:*)
936 echo or32-unknown-linux-gnu
937 exit ;;
938 padre:Linux:*:*)
939 echo sparc-unknown-linux-gnu
940 exit ;;
941 parisc64:Linux:*:* | hppa64:Linux:*:*)
942 echo hppa64-unknown-linux-gnu
943 exit ;;
944 parisc:Linux:*:* | hppa:Linux:*:*)
945 # Look for CPU level
946 case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in
947 PA7*) echo hppa1.1-unknown-linux-gnu ;;
948 PA8*) echo hppa2.0-unknown-linux-gnu ;;
949 *) echo hppa-unknown-linux-gnu ;;
950 esac
951 exit ;;
952 ppc64:Linux:*:*)
953 echo powerpc64-unknown-linux-gnu
954 exit ;;
955 ppc:Linux:*:*)
956 echo powerpc-unknown-linux-gnu
957 exit ;;
958 s390:Linux:*:* | s390x:Linux:*:*)
959 echo ${UNAME_MACHINE}-ibm-linux
960 exit ;;
961 sh64*:Linux:*:*)
962 echo ${UNAME_MACHINE}-unknown-linux-gnu
963 exit ;;
964 sh*:Linux:*:*)
965 echo ${UNAME_MACHINE}-unknown-linux-gnu
966 exit ;;
967 sparc:Linux:*:* | sparc64:Linux:*:*)
968 echo ${UNAME_MACHINE}-unknown-linux-gnu
969 exit ;;
970 vax:Linux:*:*)
971 echo ${UNAME_MACHINE}-dec-linux-gnu
972 exit ;;
973 x86_64:Linux:*:*)
974 echo x86_64-unknown-linux-gnu
975 exit ;;
976 xtensa*:Linux:*:*)
977 echo ${UNAME_MACHINE}-unknown-linux-gnu
978 exit ;;
979 i*86:DYNIX/ptx:4*:*)
980 # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there.
981 # earlier versions are messed up and put the nodename in both
982 # sysname and nodename.
983 echo i386-sequent-sysv4
984 exit ;;
985 i*86:UNIX_SV:4.2MP:2.*)
986 # Unixware is an offshoot of SVR4, but it has its own version
987 # number series starting with 2...
988 # I am not positive that other SVR4 systems won't match this,
989 # I just have to hope. -- rms.
990 # Use sysv4.2uw... so that sysv4* matches it.
991 echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
992 exit ;;
993 i*86:OS/2:*:*)
994 # If we were able to find `uname', then EMX Unix compatibility
995 # is probably installed.
996 echo ${UNAME_MACHINE}-pc-os2-emx
997 exit ;;
998 i*86:XTS-300:*:STOP)
999 echo ${UNAME_MACHINE}-unknown-stop
1000 exit ;;
1001 i*86:atheos:*:*)
1002 echo ${UNAME_MACHINE}-unknown-atheos
1003 exit ;;
1004 i*86:syllable:*:*)
1005 echo ${UNAME_MACHINE}-pc-syllable
1006 exit ;;
1007 i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*)
1008 echo i386-unknown-lynxos${UNAME_RELEASE}
1009 exit ;;
1010 i*86:*DOS:*:*)
1011 echo ${UNAME_MACHINE}-pc-msdosdjgpp
1012 exit ;;
1013 i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*)
1014 UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'`
1015 if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
1016 echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL}
1017 else
1018 echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL}
1019 fi
1020 exit ;;
1021 i*86:*:5:[678]*)
1022 # UnixWare 7.x, OpenUNIX and OpenServer 6.
1023 case `/bin/uname -X | grep "^Machine"` in
1024 *486*) UNAME_MACHINE=i486 ;;
1025 *Pentium) UNAME_MACHINE=i586 ;;
1026 *Pent*|*Celeron) UNAME_MACHINE=i686 ;;
1027 esac
1028 echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION}
1029 exit ;;
1030 i*86:*:3.2:*)
1031 if test -f /usr/options/cb.name; then
1032 UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
1033 echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
1034 elif /bin/uname -X 2>/dev/null >/dev/null ; then
1035 UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
1036 (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
1037 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \
1038 && UNAME_MACHINE=i586
1039 (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \
1040 && UNAME_MACHINE=i686
1041 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
1042 && UNAME_MACHINE=i686
1043 echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
1044 else
1045 echo ${UNAME_MACHINE}-pc-sysv32
1046 fi
1047 exit ;;
1048 pc:*:*:*)
1049 # Left here for compatibility:
1050 # uname -m prints for DJGPP always 'pc', but it prints nothing about
1051 # the processor, so we play safe by assuming i586.
1052 # Note: whatever this is, it MUST be the same as what config.sub
1053 # prints for the "djgpp" host, or else GDB configury will decide that
1054 # this is a cross-build.
1055 echo i586-pc-msdosdjgpp
1056 exit ;;
1057 Intel:Mach:3*:*)
1058 echo i386-pc-mach3
1059 exit ;;
1060 paragon:*:*:*)
1061 echo i860-intel-osf1
1062 exit ;;
1063 i860:*:4.*:*) # i860-SVR4
1064 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then
1065 echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4
1066 else # Add other i860-SVR4 vendors below as they are discovered.
1067 echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4
1068 fi
1069 exit ;;
1070 mini*:CTIX:SYS*5:*)
1071 # "miniframe"
1072 echo m68010-convergent-sysv
1073 exit ;;
1074 mc68k:UNIX:SYSTEM5:3.51m)
1075 echo m68k-convergent-sysv
1076 exit ;;
1077 M680?0:D-NIX:5.3:*)
1078 echo m68k-diab-dnix
1079 exit ;;
1080 M68*:*:R3V[5678]*:*)
1081 test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;;
1082 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0)
1083 OS_REL=''
1084 test -r /etc/.relid \
1085 && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
1086 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1087 && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
1088 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
1089 && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
1090 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*)
1091 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1092 && { echo i486-ncr-sysv4; exit; } ;;
1093 NCR*:*:4.2:* | MPRAS*:*:4.2:*)
1094 OS_REL='.3'
1095 test -r /etc/.relid \
1096 && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
1097 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \
1098 && { echo i486-ncr-sysv4.3${OS_REL}; exit; }
1099 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \
1100 && { echo i586-ncr-sysv4.3${OS_REL}; exit; }
1101 /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \
1102 && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;;
1103 m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*)
1104 echo m68k-unknown-lynxos${UNAME_RELEASE}
1105 exit ;;
1106 mc68030:UNIX_System_V:4.*:*)
1107 echo m68k-atari-sysv4
1108 exit ;;
1109 TSUNAMI:LynxOS:2.*:*)
1110 echo sparc-unknown-lynxos${UNAME_RELEASE}
1111 exit ;;
1112 rs6000:LynxOS:2.*:*)
1113 echo rs6000-unknown-lynxos${UNAME_RELEASE}
1114 exit ;;
1115 PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*)
1116 echo powerpc-unknown-lynxos${UNAME_RELEASE}
1117 exit ;;
1118 SM[BE]S:UNIX_SV:*:*)
1119 echo mips-dde-sysv${UNAME_RELEASE}
1120 exit ;;
1121 RM*:ReliantUNIX-*:*:*)
1122 echo mips-sni-sysv4
1123 exit ;;
1124 RM*:SINIX-*:*:*)
1125 echo mips-sni-sysv4
1126 exit ;;
1127 *:SINIX-*:*:*)
1128 if uname -p 2>/dev/null >/dev/null ; then
1129 UNAME_MACHINE=`(uname -p) 2>/dev/null`
1130 echo ${UNAME_MACHINE}-sni-sysv4
1131 else
1132 echo ns32k-sni-sysv
1133 fi
1134 exit ;;
1135 PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort
1136 # says <Richard.M.Bartel@ccMail.Census.GOV>
1137 echo i586-unisys-sysv4
1138 exit ;;
1139 *:UNIX_System_V:4*:FTX*)
1140 # From Gerald Hewes <hewes@openmarket.com>.
1141 # How about differentiating between stratus architectures? -djm
1142 echo hppa1.1-stratus-sysv4
1143 exit ;;
1144 *:*:*:FTX*)
1145 # From seanf@swdc.stratus.com.
1146 echo i860-stratus-sysv4
1147 exit ;;
1148 i*86:VOS:*:*)
1149 # From Paul.Green@stratus.com.
1150 echo ${UNAME_MACHINE}-stratus-vos
1151 exit ;;
1152 *:VOS:*:*)
1153 # From Paul.Green@stratus.com.
1154 echo hppa1.1-stratus-vos
1155 exit ;;
1156 mc68*:A/UX:*:*)
1157 echo m68k-apple-aux${UNAME_RELEASE}
1158 exit ;;
1159 news*:NEWS-OS:6*:*)
1160 echo mips-sony-newsos6
1161 exit ;;
1162 R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*)
1163 if [ -d /usr/nec ]; then
1164 echo mips-nec-sysv${UNAME_RELEASE}
1165 else
1166 echo mips-unknown-sysv${UNAME_RELEASE}
1167 fi
1168 exit ;;
1169 BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only.
1170 echo powerpc-be-beos
1171 exit ;;
1172 BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only.
1173 echo powerpc-apple-beos
1174 exit ;;
1175 BePC:BeOS:*:*) # BeOS running on Intel PC compatible.
1176 echo i586-pc-beos
1177 exit ;;
1178 BePC:Haiku:*:*) # Haiku running on Intel PC compatible.
1179 echo i586-pc-haiku
1180 exit ;;
1181 SX-4:SUPER-UX:*:*)
1182 echo sx4-nec-superux${UNAME_RELEASE}
1183 exit ;;
1184 SX-5:SUPER-UX:*:*)
1185 echo sx5-nec-superux${UNAME_RELEASE}
1186 exit ;;
1187 SX-6:SUPER-UX:*:*)
1188 echo sx6-nec-superux${UNAME_RELEASE}
1189 exit ;;
1190 SX-7:SUPER-UX:*:*)
1191 echo sx7-nec-superux${UNAME_RELEASE}
1192 exit ;;
1193 SX-8:SUPER-UX:*:*)
1194 echo sx8-nec-superux${UNAME_RELEASE}
1195 exit ;;
1196 SX-8R:SUPER-UX:*:*)
1197 echo sx8r-nec-superux${UNAME_RELEASE}
1198 exit ;;
1199 Power*:Rhapsody:*:*)
1200 echo powerpc-apple-rhapsody${UNAME_RELEASE}
1201 exit ;;
1202 *:Rhapsody:*:*)
1203 echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
1204 exit ;;
1205 *:Darwin:*:*)
1206 UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
1207 case $UNAME_PROCESSOR in
1208 i386)
1209 eval $set_cc_for_build
1210 if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then
1211 if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \
1212 (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \
1213 grep IS_64BIT_ARCH >/dev/null
1214 then
1215 UNAME_PROCESSOR="x86_64"
1216 fi
1217 fi ;;
1218 unknown) UNAME_PROCESSOR=powerpc ;;
1219 esac
1220 echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
1221 exit ;;
1222 *:procnto*:*:* | *:QNX:[0123456789]*:*)
1223 UNAME_PROCESSOR=`uname -p`
1224 if test "$UNAME_PROCESSOR" = "x86"; then
1225 UNAME_PROCESSOR=i386
1226 UNAME_MACHINE=pc
1227 fi
1228 echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE}
1229 exit ;;
1230 *:QNX:*:4*)
1231 echo i386-pc-qnx
1232 exit ;;
1233 NSE-?:NONSTOP_KERNEL:*:*)
1234 echo nse-tandem-nsk${UNAME_RELEASE}
1235 exit ;;
1236 NSR-?:NONSTOP_KERNEL:*:*)
1237 echo nsr-tandem-nsk${UNAME_RELEASE}
1238 exit ;;
1239 *:NonStop-UX:*:*)
1240 echo mips-compaq-nonstopux
1241 exit ;;
1242 BS2000:POSIX*:*:*)
1243 echo bs2000-siemens-sysv
1244 exit ;;
1245 DS/*:UNIX_System_V:*:*)
1246 echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE}
1247 exit ;;
1248 *:Plan9:*:*)
1249 # "uname -m" is not consistent, so use $cputype instead. 386
1250 # is converted to i386 for consistency with other x86
1251 # operating systems.
1252 if test "$cputype" = "386"; then
1253 UNAME_MACHINE=i386
1254 else
1255 UNAME_MACHINE="$cputype"
1256 fi
1257 echo ${UNAME_MACHINE}-unknown-plan9
1258 exit ;;
1259 *:TOPS-10:*:*)
1260 echo pdp10-unknown-tops10
1261 exit ;;
1262 *:TENEX:*:*)
1263 echo pdp10-unknown-tenex
1264 exit ;;
1265 KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*)
1266 echo pdp10-dec-tops20
1267 exit ;;
1268 XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*)
1269 echo pdp10-xkl-tops20
1270 exit ;;
1271 *:TOPS-20:*:*)
1272 echo pdp10-unknown-tops20
1273 exit ;;
1274 *:ITS:*:*)
1275 echo pdp10-unknown-its
1276 exit ;;
1277 SEI:*:*:SEIUX)
1278 echo mips-sei-seiux${UNAME_RELEASE}
1279 exit ;;
1280 *:DragonFly:*:*)
1281 echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
1282 exit ;;
1283 *:*VMS:*:*)
1284 UNAME_MACHINE=`(uname -p) 2>/dev/null`
1285 case "${UNAME_MACHINE}" in
1286 A*) echo alpha-dec-vms ; exit ;;
1287 I*) echo ia64-dec-vms ; exit ;;
1288 V*) echo vax-dec-vms ; exit ;;
1289 esac ;;
1290 *:XENIX:*:SysV)
1291 echo i386-pc-xenix
1292 exit ;;
1293 i*86:skyos:*:*)
1294 echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//'
1295 exit ;;
1296 i*86:rdos:*:*)
1297 echo ${UNAME_MACHINE}-pc-rdos
1298 exit ;;
1299 i*86:AROS:*:*)
1300 echo ${UNAME_MACHINE}-pc-aros
1301 exit ;;
1302esac
1303
1304#echo '(No uname command or uname output not recognized.)' 1>&2
1305#echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2
1306
1307eval $set_cc_for_build
1308cat >$dummy.c <<EOF
1309#ifdef _SEQUENT_
1310# include <sys/types.h>
1311# include <sys/utsname.h>
1312#endif
1313main ()
1314{
1315#if defined (sony)
1316#if defined (MIPSEB)
1317 /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed,
1318 I don't know.... */
1319 printf ("mips-sony-bsd\n"); exit (0);
1320#else
1321#include <sys/param.h>
1322 printf ("m68k-sony-newsos%s\n",
1323#ifdef NEWSOS4
1324 "4"
1325#else
1326 ""
1327#endif
1328 ); exit (0);
1329#endif
1330#endif
1331
1332#if defined (__arm) && defined (__acorn) && defined (__unix)
1333 printf ("arm-acorn-riscix\n"); exit (0);
1334#endif
1335
1336#if defined (hp300) && !defined (hpux)
1337 printf ("m68k-hp-bsd\n"); exit (0);
1338#endif
1339
1340#if defined (NeXT)
1341#if !defined (__ARCHITECTURE__)
1342#define __ARCHITECTURE__ "m68k"
1343#endif
1344 int version;
1345 version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`;
1346 if (version < 4)
1347 printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version);
1348 else
1349 printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version);
1350 exit (0);
1351#endif
1352
1353#if defined (MULTIMAX) || defined (n16)
1354#if defined (UMAXV)
1355 printf ("ns32k-encore-sysv\n"); exit (0);
1356#else
1357#if defined (CMU)
1358 printf ("ns32k-encore-mach\n"); exit (0);
1359#else
1360 printf ("ns32k-encore-bsd\n"); exit (0);
1361#endif
1362#endif
1363#endif
1364
1365#if defined (__386BSD__)
1366 printf ("i386-pc-bsd\n"); exit (0);
1367#endif
1368
1369#if defined (sequent)
1370#if defined (i386)
1371 printf ("i386-sequent-dynix\n"); exit (0);
1372#endif
1373#if defined (ns32000)
1374 printf ("ns32k-sequent-dynix\n"); exit (0);
1375#endif
1376#endif
1377
1378#if defined (_SEQUENT_)
1379 struct utsname un;
1380
1381 uname(&un);
1382
1383 if (strncmp(un.version, "V2", 2) == 0) {
1384 printf ("i386-sequent-ptx2\n"); exit (0);
1385 }
1386 if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */
1387 printf ("i386-sequent-ptx1\n"); exit (0);
1388 }
1389 printf ("i386-sequent-ptx\n"); exit (0);
1390
1391#endif
1392
1393#if defined (vax)
1394# if !defined (ultrix)
1395# include <sys/param.h>
1396# if defined (BSD)
1397# if BSD == 43
1398 printf ("vax-dec-bsd4.3\n"); exit (0);
1399# else
1400# if BSD == 199006
1401 printf ("vax-dec-bsd4.3reno\n"); exit (0);
1402# else
1403 printf ("vax-dec-bsd\n"); exit (0);
1404# endif
1405# endif
1406# else
1407 printf ("vax-dec-bsd\n"); exit (0);
1408# endif
1409# else
1410 printf ("vax-dec-ultrix\n"); exit (0);
1411# endif
1412#endif
1413
1414#if defined (alliant) && defined (i860)
1415 printf ("i860-alliant-bsd\n"); exit (0);
1416#endif
1417
1418 exit (1);
1419}
1420EOF
1421
1422$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` &&
1423 { echo "$SYSTEM_NAME"; exit; }
1424
1425# Apollos put the system type in the environment.
1426
1427test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; }
1428
1429# Convex versions that predate uname can use getsysinfo(1)
1430
1431if [ -x /usr/convex/getsysinfo ]
1432then
1433 case `getsysinfo -f cpu_type` in
1434 c1*)
1435 echo c1-convex-bsd
1436 exit ;;
1437 c2*)
1438 if getsysinfo -f scalar_acc
1439 then echo c32-convex-bsd
1440 else echo c2-convex-bsd
1441 fi
1442 exit ;;
1443 c34*)
1444 echo c34-convex-bsd
1445 exit ;;
1446 c38*)
1447 echo c38-convex-bsd
1448 exit ;;
1449 c4*)
1450 echo c4-convex-bsd
1451 exit ;;
1452 esac
1453fi
1454
1455cat >&2 <<EOF
1456$0: unable to guess system type
1457
1458This script, last modified $timestamp, has failed to recognize
1459the operating system you are using. It is advised that you
1460download the most up to date version of the config scripts from
1461
1462 http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
1463and
1464 http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
1465
1466If the version you run ($0) is already up to date, please
1467send the following data and any information you think might be
1468pertinent to <config-patches@gnu.org> in order to provide the needed
1469information to handle your system.
1470
1471config.guess timestamp = $timestamp
1472
1473uname -m = `(uname -m) 2>/dev/null || echo unknown`
1474uname -r = `(uname -r) 2>/dev/null || echo unknown`
1475uname -s = `(uname -s) 2>/dev/null || echo unknown`
1476uname -v = `(uname -v) 2>/dev/null || echo unknown`
1477
1478/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null`
1479/bin/uname -X = `(/bin/uname -X) 2>/dev/null`
1480
1481hostinfo = `(hostinfo) 2>/dev/null`
1482/bin/universe = `(/bin/universe) 2>/dev/null`
1483/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null`
1484/bin/arch = `(/bin/arch) 2>/dev/null`
1485/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null`
1486/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null`
1487
1488UNAME_MACHINE = ${UNAME_MACHINE}
1489UNAME_RELEASE = ${UNAME_RELEASE}
1490UNAME_SYSTEM = ${UNAME_SYSTEM}
1491UNAME_VERSION = ${UNAME_VERSION}
1492EOF
1493
1494exit 1
1495
1496# Local variables:
1497# eval: (add-hook 'write-file-hooks 'time-stamp)
1498# time-stamp-start: "timestamp='"
1499# time-stamp-format: "%:y-%02m-%02d"
1500# time-stamp-end: "'"
1501# End:
config/config.sub +0 -1705
……@@ -1,1705 +0,0 @@
1#! /bin/sh
2# Configuration validation subroutine script.
3# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
4# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
5# Free Software Foundation, Inc.
6
7timestamp='2009-11-20'
8
9# This file is (in principle) common to ALL GNU software.
10# The presence of a machine in this file suggests that SOME GNU software
11# can handle that machine. It does not imply ALL GNU software can.
12#
13# This file is free software; you can redistribute it and/or modify
14# it under the terms of the GNU General Public License as published by
15# the Free Software Foundation; either version 2 of the License, or
16# (at your option) any later version.
17#
18# This program is distributed in the hope that it will be useful,
19# but WITHOUT ANY WARRANTY; without even the implied warranty of
20# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21# GNU General Public License for more details.
22#
23# You should have received a copy of the GNU General Public License
24# along with this program; if not, write to the Free Software
25# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
26# 02110-1301, USA.
27#
28# As a special exception to the GNU General Public License, if you
29# distribute this file as part of a program that contains a
30# configuration script generated by Autoconf, you may include it under
31# the same distribution terms that you use for the rest of that program.
32
33
34# Please send patches to <config-patches@gnu.org>. Submit a context
35# diff and a properly formatted GNU ChangeLog entry.
36#
37# Configuration subroutine to validate and canonicalize a configuration type.
38# Supply the specified configuration type as an argument.
39# If it is invalid, we print an error message on stderr and exit with code 1.
40# Otherwise, we print the canonical config type on stdout and succeed.
41
42# You can get the latest version of this script from:
43# http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
44
45# This file is supposed to be the same for all GNU packages
46# and recognize all the CPU types, system types and aliases
47# that are meaningful with *any* GNU software.
48# Each package is responsible for reporting which valid configurations
49# it does not support. The user should be able to distinguish
50# a failure to support a valid configuration from a meaningless
51# configuration.
52
53# The goal of this file is to map all the various variations of a given
54# machine specification into a single specification in the form:
55# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM
56# or in some cases, the newer four-part form:
57# CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM
58# It is wrong to echo any other type of specification.
59
60me=`echo "$0" | sed -e 's,.*/,,'`
61
62usage="\
63Usage: $0 [OPTION] CPU-MFR-OPSYS
64 $0 [OPTION] ALIAS
65
66Canonicalize a configuration name.
67
68Operation modes:
69 -h, --help print this help, then exit
70 -t, --time-stamp print date of last modification, then exit
71 -v, --version print version number, then exit
72
73Report bugs and patches to <config-patches@gnu.org>."
74
75version="\
76GNU config.sub ($timestamp)
77
78Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
792002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
80
81This is free software; see the source for copying conditions. There is NO
82warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
83
84help="
85Try \`$me --help' for more information."
86
87# Parse command line
88while test $# -gt 0 ; do
89 case $1 in
90 --time-stamp | --time* | -t )
91 echo "$timestamp" ; exit ;;
92 --version | -v )
93 echo "$version" ; exit ;;
94 --help | --h* | -h )
95 echo "$usage"; exit ;;
96 -- ) # Stop option processing
97 shift; break ;;
98 - ) # Use stdin as input.
99 break ;;
100 -* )
101 echo "$me: invalid option $1$help"
102 exit 1 ;;
103
104 *local*)
105 # First pass through any local machine types.
106 echo $1
107 exit ;;
108
109 * )
110 break ;;
111 esac
112done
113
114case $# in
115 0) echo "$me: missing argument$help" >&2
116 exit 1;;
117 1) ;;
118 *) echo "$me: too many arguments$help" >&2
119 exit 1;;
120esac
121
122# Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any).
123# Here we must recognize all the valid KERNEL-OS combinations.
124maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
125case $maybe_os in
126 nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \
127 uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \
128 kopensolaris*-gnu* | \
129 storm-chaos* | os2-emx* | rtmk-nova*)
130 os=-$maybe_os
131 basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
132 ;;
133 *)
134 basic_machine=`echo $1 | sed 's/-[^-]*$//'`
135 if [ $basic_machine != $1 ]
136 then os=`echo $1 | sed 's/.*-/-/'`
137 else os=; fi
138 ;;
139esac
140
141### Let's recognize common machines as not being operating systems so
142### that things like config.sub decstation-3100 work. We also
143### recognize some manufacturers as not being operating systems, so we
144### can provide default operating systems below.
145case $os in
146 -sun*os*)
147 # Prevent following clause from handling this invalid input.
148 ;;
149 -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \
150 -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \
151 -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \
152 -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\
153 -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \
154 -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \
155 -apple | -axis | -knuth | -cray | -microblaze)
156 os=
157 basic_machine=$1
158 ;;
159 -bluegene*)
160 os=-cnk
161 ;;
162 -sim | -cisco | -oki | -wec | -winbond)
163 os=
164 basic_machine=$1
165 ;;
166 -scout)
167 ;;
168 -wrs)
169 os=-vxworks
170 basic_machine=$1
171 ;;
172 -chorusos*)
173 os=-chorusos
174 basic_machine=$1
175 ;;
176 -chorusrdb)
177 os=-chorusrdb
178 basic_machine=$1
179 ;;
180 -hiux*)
181 os=-hiuxwe2
182 ;;
183 -sco6)
184 os=-sco5v6
185 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
186 ;;
187 -sco5)
188 os=-sco3.2v5
189 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
190 ;;
191 -sco4)
192 os=-sco3.2v4
193 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
194 ;;
195 -sco3.2.[4-9]*)
196 os=`echo $os | sed -e 's/sco3.2./sco3.2v/'`
197 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
198 ;;
199 -sco3.2v[4-9]*)
200 # Don't forget version if it is 3.2v4 or newer.
201 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
202 ;;
203 -sco5v6*)
204 # Don't forget version if it is 3.2v4 or newer.
205 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
206 ;;
207 -sco*)
208 os=-sco3.2v2
209 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
210 ;;
211 -udk*)
212 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
213 ;;
214 -isc)
215 os=-isc2.2
216 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
217 ;;
218 -clix*)
219 basic_machine=clipper-intergraph
220 ;;
221 -isc*)
222 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
223 ;;
224 -lynx*)
225 os=-lynxos
226 ;;
227 -ptx*)
228 basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'`
229 ;;
230 -windowsnt*)
231 os=`echo $os | sed -e 's/windowsnt/winnt/'`
232 ;;
233 -psos*)
234 os=-psos
235 ;;
236 -mint | -mint[0-9]*)
237 basic_machine=m68k-atari
238 os=-mint
239 ;;
240esac
241
242# Decode aliases for certain CPU-COMPANY combinations.
243case $basic_machine in
244 # Recognize the basic CPU types without company name.
245 # Some are omitted here because they have special meanings below.
246 1750a | 580 \
247 | a29k \
248 | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
249 | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
250 | am33_2.0 \
251 | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \
252 | bfin \
253 | c4x | clipper \
254 | d10v | d30v | dlx | dsp16xx \
255 | fido | fr30 | frv \
256 | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
257 | i370 | i860 | i960 | ia64 \
258 | ip2k | iq2000 \
259 | lm32 \
260 | m32c | m32r | m32rle | m68000 | m68k | m88k \
261 | maxq | mb | microblaze | mcore | mep | metag \
262 | mips | mipsbe | mipseb | mipsel | mipsle \
263 | mips16 \
264 | mips64 | mips64el \
265 | mips64octeon | mips64octeonel \
266 | mips64orion | mips64orionel \
267 | mips64r5900 | mips64r5900el \
268 | mips64vr | mips64vrel \
269 | mips64vr4100 | mips64vr4100el \
270 | mips64vr4300 | mips64vr4300el \
271 | mips64vr5000 | mips64vr5000el \
272 | mips64vr5900 | mips64vr5900el \
273 | mipsisa32 | mipsisa32el \
274 | mipsisa32r2 | mipsisa32r2el \
275 | mipsisa64 | mipsisa64el \
276 | mipsisa64r2 | mipsisa64r2el \
277 | mipsisa64sb1 | mipsisa64sb1el \
278 | mipsisa64sr71k | mipsisa64sr71kel \
279 | mipstx39 | mipstx39el \
280 | mn10200 | mn10300 \
281 | moxie \
282 | mt \
283 | msp430 \
284 | nios | nios2 \
285 | ns16k | ns32k \
286 | or32 \
287 | pdp10 | pdp11 | pj | pjl \
288 | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
289 | pyramid \
290 | rx \
291 | score \
292 | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
293 | sh64 | sh64le \
294 | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \
295 | sparcv8 | sparcv9 | sparcv9b | sparcv9v \
296 | spu | strongarm \
297 | tahoe | thumb | tic4x | tic80 | tron \
298 | ubicom32 \
299 | v850 | v850e \
300 | we32k \
301 | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \
302 | z8k | z80)
303 basic_machine=$basic_machine-unknown
304 ;;
305 m6811 | m68hc11 | m6812 | m68hc12 | picochip)
306 # Motorola 68HC11/12.
307 basic_machine=$basic_machine-unknown
308 os=-none
309 ;;
310 m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k)
311 ;;
312 ms1)
313 basic_machine=mt-unknown
314 ;;
315
316 # We use `pc' rather than `unknown'
317 # because (1) that's what they normally are, and
318 # (2) the word "unknown" tends to confuse beginning users.
319 i*86 | x86_64)
320 basic_machine=$basic_machine-pc
321 ;;
322 # Object if more than one company name word.
323 *-*-*)
324 echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
325 exit 1
326 ;;
327 # Recognize the basic CPU types with company name.
328 580-* \
329 | a29k-* \
330 | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \
331 | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
332 | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
333 | arm-* | armbe-* | armle-* | armeb-* | armv*-* \
334 | avr-* | avr32-* \
335 | bfin-* | bs2000-* \
336 | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
337 | clipper-* | craynv-* | cydra-* \
338 | d10v-* | d30v-* | dlx-* \
339 | elxsi-* \
340 | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \
341 | h8300-* | h8500-* \
342 | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
343 | i*86-* | i860-* | i960-* | ia64-* \
344 | ip2k-* | iq2000-* \
345 | lm32-* \
346 | m32c-* | m32r-* | m32rle-* \
347 | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
348 | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \
349 | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
350 | mips16-* \
351 | mips64-* | mips64el-* \
352 | mips64octeon-* | mips64octeonel-* \
353 | mips64orion-* | mips64orionel-* \
354 | mips64r5900-* | mips64r5900el-* \
355 | mips64vr-* | mips64vrel-* \
356 | mips64vr4100-* | mips64vr4100el-* \
357 | mips64vr4300-* | mips64vr4300el-* \
358 | mips64vr5000-* | mips64vr5000el-* \
359 | mips64vr5900-* | mips64vr5900el-* \
360 | mipsisa32-* | mipsisa32el-* \
361 | mipsisa32r2-* | mipsisa32r2el-* \
362 | mipsisa64-* | mipsisa64el-* \
363 | mipsisa64r2-* | mipsisa64r2el-* \
364 | mipsisa64sb1-* | mipsisa64sb1el-* \
365 | mipsisa64sr71k-* | mipsisa64sr71kel-* \
366 | mipstx39-* | mipstx39el-* \
367 | mmix-* \
368 | mt-* \
369 | msp430-* \
370 | nios-* | nios2-* \
371 | none-* | np1-* | ns16k-* | ns32k-* \
372 | orion-* \
373 | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
374 | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
375 | pyramid-* \
376 | romp-* | rs6000-* | rx-* \
377 | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
378 | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
379 | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
380 | sparclite-* \
381 | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \
382 | tahoe-* | thumb-* \
383 | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* | tile-* \
384 | tron-* \
385 | ubicom32-* \
386 | v850-* | v850e-* | vax-* \
387 | we32k-* \
388 | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \
389 | xstormy16-* | xtensa*-* \
390 | ymp-* \
391 | z8k-* | z80-*)
392 ;;
393 # Recognize the basic CPU types without company name, with glob match.
394 xtensa*)
395 basic_machine=$basic_machine-unknown
396 ;;
397 # Recognize the various machine names and aliases which stand
398 # for a CPU type and a company and sometimes even an OS.
399 386bsd)
400 basic_machine=i386-unknown
401 os=-bsd
402 ;;
403 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc)
404 basic_machine=m68000-att
405 ;;
406 3b*)
407 basic_machine=we32k-att
408 ;;
409 a29khif)
410 basic_machine=a29k-amd
411 os=-udi
412 ;;
413 abacus)
414 basic_machine=abacus-unknown
415 ;;
416 adobe68k)
417 basic_machine=m68010-adobe
418 os=-scout
419 ;;
420 alliant | fx80)
421 basic_machine=fx80-alliant
422 ;;
423 altos | altos3068)
424 basic_machine=m68k-altos
425 ;;
426 am29k)
427 basic_machine=a29k-none
428 os=-bsd
429 ;;
430 amd64)
431 basic_machine=x86_64-pc
432 ;;
433 amd64-*)
434 basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'`
435 ;;
436 amdahl)
437 basic_machine=580-amdahl
438 os=-sysv
439 ;;
440 amiga | amiga-*)
441 basic_machine=m68k-unknown
442 ;;
443 amigaos | amigados)
444 basic_machine=m68k-unknown
445 os=-amigaos
446 ;;
447 amigaunix | amix)
448 basic_machine=m68k-unknown
449 os=-sysv4
450 ;;
451 apollo68)
452 basic_machine=m68k-apollo
453 os=-sysv
454 ;;
455 apollo68bsd)
456 basic_machine=m68k-apollo
457 os=-bsd
458 ;;
459 aros)
460 basic_machine=i386-pc
461 os=-aros
462 ;;
463 aux)
464 basic_machine=m68k-apple
465 os=-aux
466 ;;
467 balance)
468 basic_machine=ns32k-sequent
469 os=-dynix
470 ;;
471 blackfin)
472 basic_machine=bfin-unknown
473 os=-linux
474 ;;
475 blackfin-*)
476 basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'`
477 os=-linux
478 ;;
479 bluegene*)
480 basic_machine=powerpc-ibm
481 os=-cnk
482 ;;
483 c90)
484 basic_machine=c90-cray
485 os=-unicos
486 ;;
487 cegcc)
488 basic_machine=arm-unknown
489 os=-cegcc
490 ;;
491 convex-c1)
492 basic_machine=c1-convex
493 os=-bsd
494 ;;
495 convex-c2)
496 basic_machine=c2-convex
497 os=-bsd
498 ;;
499 convex-c32)
500 basic_machine=c32-convex
501 os=-bsd
502 ;;
503 convex-c34)
504 basic_machine=c34-convex
505 os=-bsd
506 ;;
507 convex-c38)
508 basic_machine=c38-convex
509 os=-bsd
510 ;;
511 cray | j90)
512 basic_machine=j90-cray
513 os=-unicos
514 ;;
515 craynv)
516 basic_machine=craynv-cray
517 os=-unicosmp
518 ;;
519 cr16)
520 basic_machine=cr16-unknown
521 os=-elf
522 ;;
523 crds | unos)
524 basic_machine=m68k-crds
525 ;;
526 crisv32 | crisv32-* | etraxfs*)
527 basic_machine=crisv32-axis
528 ;;
529 cris | cris-* | etrax*)
530 basic_machine=cris-axis
531 ;;
532 crx)
533 basic_machine=crx-unknown
534 os=-elf
535 ;;
536 da30 | da30-*)
537 basic_machine=m68k-da30
538 ;;
539 decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn)
540 basic_machine=mips-dec
541 ;;
542 decsystem10* | dec10*)
543 basic_machine=pdp10-dec
544 os=-tops10
545 ;;
546 decsystem20* | dec20*)
547 basic_machine=pdp10-dec
548 os=-tops20
549 ;;
550 delta | 3300 | motorola-3300 | motorola-delta \
551 | 3300-motorola | delta-motorola)
552 basic_machine=m68k-motorola
553 ;;
554 delta88)
555 basic_machine=m88k-motorola
556 os=-sysv3
557 ;;
558 dicos)
559 basic_machine=i686-pc
560 os=-dicos
561 ;;
562 djgpp)
563 basic_machine=i586-pc
564 os=-msdosdjgpp
565 ;;
566 dpx20 | dpx20-*)
567 basic_machine=rs6000-bull
568 os=-bosx
569 ;;
570 dpx2* | dpx2*-bull)
571 basic_machine=m68k-bull
572 os=-sysv3
573 ;;
574 ebmon29k)
575 basic_machine=a29k-amd
576 os=-ebmon
577 ;;
578 elxsi)
579 basic_machine=elxsi-elxsi
580 os=-bsd
581 ;;
582 encore | umax | mmax)
583 basic_machine=ns32k-encore
584 ;;
585 es1800 | OSE68k | ose68k | ose | OSE)
586 basic_machine=m68k-ericsson
587 os=-ose
588 ;;
589 fx2800)
590 basic_machine=i860-alliant
591 ;;
592 genix)
593 basic_machine=ns32k-ns
594 ;;
595 gmicro)
596 basic_machine=tron-gmicro
597 os=-sysv
598 ;;
599 go32)
600 basic_machine=i386-pc
601 os=-go32
602 ;;
603 h3050r* | hiux*)
604 basic_machine=hppa1.1-hitachi
605 os=-hiuxwe2
606 ;;
607 h8300hms)
608 basic_machine=h8300-hitachi
609 os=-hms
610 ;;
611 h8300xray)
612 basic_machine=h8300-hitachi
613 os=-xray
614 ;;
615 h8500hms)
616 basic_machine=h8500-hitachi
617 os=-hms
618 ;;
619 harris)
620 basic_machine=m88k-harris
621 os=-sysv3
622 ;;
623 hp300-*)
624 basic_machine=m68k-hp
625 ;;
626 hp300bsd)
627 basic_machine=m68k-hp
628 os=-bsd
629 ;;
630 hp300hpux)
631 basic_machine=m68k-hp
632 os=-hpux
633 ;;
634 hp3k9[0-9][0-9] | hp9[0-9][0-9])
635 basic_machine=hppa1.0-hp
636 ;;
637 hp9k2[0-9][0-9] | hp9k31[0-9])
638 basic_machine=m68000-hp
639 ;;
640 hp9k3[2-9][0-9])
641 basic_machine=m68k-hp
642 ;;
643 hp9k6[0-9][0-9] | hp6[0-9][0-9])
644 basic_machine=hppa1.0-hp
645 ;;
646 hp9k7[0-79][0-9] | hp7[0-79][0-9])
647 basic_machine=hppa1.1-hp
648 ;;
649 hp9k78[0-9] | hp78[0-9])
650 # FIXME: really hppa2.0-hp
651 basic_machine=hppa1.1-hp
652 ;;
653 hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893)
654 # FIXME: really hppa2.0-hp
655 basic_machine=hppa1.1-hp
656 ;;
657 hp9k8[0-9][13679] | hp8[0-9][13679])
658 basic_machine=hppa1.1-hp
659 ;;
660 hp9k8[0-9][0-9] | hp8[0-9][0-9])
661 basic_machine=hppa1.0-hp
662 ;;
663 hppa-next)
664 os=-nextstep3
665 ;;
666 hppaosf)
667 basic_machine=hppa1.1-hp
668 os=-osf
669 ;;
670 hppro)
671 basic_machine=hppa1.1-hp
672 os=-proelf
673 ;;
674 i370-ibm* | ibm*)
675 basic_machine=i370-ibm
676 ;;
677# I'm not sure what "Sysv32" means. Should this be sysv3.2?
678 i*86v32)
679 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
680 os=-sysv32
681 ;;
682 i*86v4*)
683 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
684 os=-sysv4
685 ;;
686 i*86v)
687 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
688 os=-sysv
689 ;;
690 i*86sol2)
691 basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'`
692 os=-solaris2
693 ;;
694 i386mach)
695 basic_machine=i386-mach
696 os=-mach
697 ;;
698 i386-vsta | vsta)
699 basic_machine=i386-unknown
700 os=-vsta
701 ;;
702 iris | iris4d)
703 basic_machine=mips-sgi
704 case $os in
705 -irix*)
706 ;;
707 *)
708 os=-irix4
709 ;;
710 esac
711 ;;
712 isi68 | isi)
713 basic_machine=m68k-isi
714 os=-sysv
715 ;;
716 m68knommu)
717 basic_machine=m68k-unknown
718 os=-linux
719 ;;
720 m68knommu-*)
721 basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'`
722 os=-linux
723 ;;
724 m88k-omron*)
725 basic_machine=m88k-omron
726 ;;
727 magnum | m3230)
728 basic_machine=mips-mips
729 os=-sysv
730 ;;
731 merlin)
732 basic_machine=ns32k-utek
733 os=-sysv
734 ;;
735 microblaze)
736 basic_machine=microblaze-xilinx
737 ;;
738 mingw32)
739 basic_machine=i386-pc
740 os=-mingw32
741 ;;
742 mingw32ce)
743 basic_machine=arm-unknown
744 os=-mingw32ce
745 ;;
746 miniframe)
747 basic_machine=m68000-convergent
748 ;;
749 *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*)
750 basic_machine=m68k-atari
751 os=-mint
752 ;;
753 mips3*-*)
754 basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`
755 ;;
756 mips3*)
757 basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown
758 ;;
759 monitor)
760 basic_machine=m68k-rom68k
761 os=-coff
762 ;;
763 morphos)
764 basic_machine=powerpc-unknown
765 os=-morphos
766 ;;
767 msdos)
768 basic_machine=i386-pc
769 os=-msdos
770 ;;
771 ms1-*)
772 basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'`
773 ;;
774 mvs)
775 basic_machine=i370-ibm
776 os=-mvs
777 ;;
778 ncr3000)
779 basic_machine=i486-ncr
780 os=-sysv4
781 ;;
782 netbsd386)
783 basic_machine=i386-unknown
784 os=-netbsd
785 ;;
786 netwinder)
787 basic_machine=armv4l-rebel
788 os=-linux
789 ;;
790 news | news700 | news800 | news900)
791 basic_machine=m68k-sony
792 os=-newsos
793 ;;
794 news1000)
795 basic_machine=m68030-sony
796 os=-newsos
797 ;;
798 news-3600 | risc-news)
799 basic_machine=mips-sony
800 os=-newsos
801 ;;
802 necv70)
803 basic_machine=v70-nec
804 os=-sysv
805 ;;
806 next | m*-next )
807 basic_machine=m68k-next
808 case $os in
809 -nextstep* )
810 ;;
811 -ns2*)
812 os=-nextstep2
813 ;;
814 *)
815 os=-nextstep3
816 ;;
817 esac
818 ;;
819 nh3000)
820 basic_machine=m68k-harris
821 os=-cxux
822 ;;
823 nh[45]000)
824 basic_machine=m88k-harris
825 os=-cxux
826 ;;
827 nindy960)
828 basic_machine=i960-intel
829 os=-nindy
830 ;;
831 mon960)
832 basic_machine=i960-intel
833 os=-mon960
834 ;;
835 nonstopux)
836 basic_machine=mips-compaq
837 os=-nonstopux
838 ;;
839 np1)
840 basic_machine=np1-gould
841 ;;
842 nsr-tandem)
843 basic_machine=nsr-tandem
844 ;;
845 op50n-* | op60c-*)
846 basic_machine=hppa1.1-oki
847 os=-proelf
848 ;;
849 openrisc | openrisc-*)
850 basic_machine=or32-unknown
851 ;;
852 os400)
853 basic_machine=powerpc-ibm
854 os=-os400
855 ;;
856 OSE68000 | ose68000)
857 basic_machine=m68000-ericsson
858 os=-ose
859 ;;
860 os68k)
861 basic_machine=m68k-none
862 os=-os68k
863 ;;
864 pa-hitachi)
865 basic_machine=hppa1.1-hitachi
866 os=-hiuxwe2
867 ;;
868 paragon)
869 basic_machine=i860-intel
870 os=-osf
871 ;;
872 parisc)
873 basic_machine=hppa-unknown
874 os=-linux
875 ;;
876 parisc-*)
877 basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'`
878 os=-linux
879 ;;
880 pbd)
881 basic_machine=sparc-tti
882 ;;
883 pbb)
884 basic_machine=m68k-tti
885 ;;
886 pc532 | pc532-*)
887 basic_machine=ns32k-pc532
888 ;;
889 pc98)
890 basic_machine=i386-pc
891 ;;
892 pc98-*)
893 basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'`
894 ;;
895 pentium | p5 | k5 | k6 | nexgen | viac3)
896 basic_machine=i586-pc
897 ;;
898 pentiumpro | p6 | 6x86 | athlon | athlon_*)
899 basic_machine=i686-pc
900 ;;
901 pentiumii | pentium2 | pentiumiii | pentium3)
902 basic_machine=i686-pc
903 ;;
904 pentium4)
905 basic_machine=i786-pc
906 ;;
907 pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
908 basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
909 ;;
910 pentiumpro-* | p6-* | 6x86-* | athlon-*)
911 basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
912 ;;
913 pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
914 basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
915 ;;
916 pentium4-*)
917 basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'`
918 ;;
919 pn)
920 basic_machine=pn-gould
921 ;;
922 power) basic_machine=power-ibm
923 ;;
924 ppc) basic_machine=powerpc-unknown
925 ;;
926 ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
927 ;;
928 ppcle | powerpclittle | ppc-le | powerpc-little)
929 basic_machine=powerpcle-unknown
930 ;;
931 ppcle-* | powerpclittle-*)
932 basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'`
933 ;;
934 ppc64) basic_machine=powerpc64-unknown
935 ;;
936 ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'`
937 ;;
938 ppc64le | powerpc64little | ppc64-le | powerpc64-little)
939 basic_machine=powerpc64le-unknown
940 ;;
941 ppc64le-* | powerpc64little-*)
942 basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'`
943 ;;
944 ps2)
945 basic_machine=i386-ibm
946 ;;
947 pw32)
948 basic_machine=i586-unknown
949 os=-pw32
950 ;;
951 rdos)
952 basic_machine=i386-pc
953 os=-rdos
954 ;;
955 rom68k)
956 basic_machine=m68k-rom68k
957 os=-coff
958 ;;
959 rm[46]00)
960 basic_machine=mips-siemens
961 ;;
962 rtpc | rtpc-*)
963 basic_machine=romp-ibm
964 ;;
965 s390 | s390-*)
966 basic_machine=s390-ibm
967 ;;
968 s390x | s390x-*)
969 basic_machine=s390x-ibm
970 ;;
971 sa29200)
972 basic_machine=a29k-amd
973 os=-udi
974 ;;
975 sb1)
976 basic_machine=mipsisa64sb1-unknown
977 ;;
978 sb1el)
979 basic_machine=mipsisa64sb1el-unknown
980 ;;
981 sde)
982 basic_machine=mipsisa32-sde
983 os=-elf
984 ;;
985 sei)
986 basic_machine=mips-sei
987 os=-seiux
988 ;;
989 sequent)
990 basic_machine=i386-sequent
991 ;;
992 sh)
993 basic_machine=sh-hitachi
994 os=-hms
995 ;;
996 sh5el)
997 basic_machine=sh5le-unknown
998 ;;
999 sh64)
1000 basic_machine=sh64-unknown
1001 ;;
1002 sparclite-wrs | simso-wrs)
1003 basic_machine=sparclite-wrs
1004 os=-vxworks
1005 ;;
1006 sps7)
1007 basic_machine=m68k-bull
1008 os=-sysv2
1009 ;;
1010 spur)
1011 basic_machine=spur-unknown
1012 ;;
1013 st2000)
1014 basic_machine=m68k-tandem
1015 ;;
1016 stratus)
1017 basic_machine=i860-stratus
1018 os=-sysv4
1019 ;;
1020 sun2)
1021 basic_machine=m68000-sun
1022 ;;
1023 sun2os3)
1024 basic_machine=m68000-sun
1025 os=-sunos3
1026 ;;
1027 sun2os4)
1028 basic_machine=m68000-sun
1029 os=-sunos4
1030 ;;
1031 sun3os3)
1032 basic_machine=m68k-sun
1033 os=-sunos3
1034 ;;
1035 sun3os4)
1036 basic_machine=m68k-sun
1037 os=-sunos4
1038 ;;
1039 sun4os3)
1040 basic_machine=sparc-sun
1041 os=-sunos3
1042 ;;
1043 sun4os4)
1044 basic_machine=sparc-sun
1045 os=-sunos4
1046 ;;
1047 sun4sol2)
1048 basic_machine=sparc-sun
1049 os=-solaris2
1050 ;;
1051 sun3 | sun3-*)
1052 basic_machine=m68k-sun
1053 ;;
1054 sun4)
1055 basic_machine=sparc-sun
1056 ;;
1057 sun386 | sun386i | roadrunner)
1058 basic_machine=i386-sun
1059 ;;
1060 sv1)
1061 basic_machine=sv1-cray
1062 os=-unicos
1063 ;;
1064 symmetry)
1065 basic_machine=i386-sequent
1066 os=-dynix
1067 ;;
1068 t3e)
1069 basic_machine=alphaev5-cray
1070 os=-unicos
1071 ;;
1072 t90)
1073 basic_machine=t90-cray
1074 os=-unicos
1075 ;;
1076 tic54x | c54x*)
1077 basic_machine=tic54x-unknown
1078 os=-coff
1079 ;;
1080 tic55x | c55x*)
1081 basic_machine=tic55x-unknown
1082 os=-coff
1083 ;;
1084 tic6x | c6x*)
1085 basic_machine=tic6x-unknown
1086 os=-coff
1087 ;;
1088 tile*)
1089 basic_machine=tile-unknown
1090 os=-linux-gnu
1091 ;;
1092 tx39)
1093 basic_machine=mipstx39-unknown
1094 ;;
1095 tx39el)
1096 basic_machine=mipstx39el-unknown
1097 ;;
1098 toad1)
1099 basic_machine=pdp10-xkl
1100 os=-tops20
1101 ;;
1102 tower | tower-32)
1103 basic_machine=m68k-ncr
1104 ;;
1105 tpf)
1106 basic_machine=s390x-ibm
1107 os=-tpf
1108 ;;
1109 udi29k)
1110 basic_machine=a29k-amd
1111 os=-udi
1112 ;;
1113 ultra3)
1114 basic_machine=a29k-nyu
1115 os=-sym1
1116 ;;
1117 v810 | necv810)
1118 basic_machine=v810-nec
1119 os=-none
1120 ;;
1121 vaxv)
1122 basic_machine=vax-dec
1123 os=-sysv
1124 ;;
1125 vms)
1126 basic_machine=vax-dec
1127 os=-vms
1128 ;;
1129 vpp*|vx|vx-*)
1130 basic_machine=f301-fujitsu
1131 ;;
1132 vxworks960)
1133 basic_machine=i960-wrs
1134 os=-vxworks
1135 ;;
1136 vxworks68)
1137 basic_machine=m68k-wrs
1138 os=-vxworks
1139 ;;
1140 vxworks29k)
1141 basic_machine=a29k-wrs
1142 os=-vxworks
1143 ;;
1144 w65*)
1145 basic_machine=w65-wdc
1146 os=-none
1147 ;;
1148 w89k-*)
1149 basic_machine=hppa1.1-winbond
1150 os=-proelf
1151 ;;
1152 xbox)
1153 basic_machine=i686-pc
1154 os=-mingw32
1155 ;;
1156 xps | xps100)
1157 basic_machine=xps100-honeywell
1158 ;;
1159 ymp)
1160 basic_machine=ymp-cray
1161 os=-unicos
1162 ;;
1163 z8k-*-coff)
1164 basic_machine=z8k-unknown
1165 os=-sim
1166 ;;
1167 z80-*-coff)
1168 basic_machine=z80-unknown
1169 os=-sim
1170 ;;
1171 none)
1172 basic_machine=none-none
1173 os=-none
1174 ;;
1175
1176# Here we handle the default manufacturer of certain CPU types. It is in
1177# some cases the only manufacturer, in others, it is the most popular.
1178 w89k)
1179 basic_machine=hppa1.1-winbond
1180 ;;
1181 op50n)
1182 basic_machine=hppa1.1-oki
1183 ;;
1184 op60c)
1185 basic_machine=hppa1.1-oki
1186 ;;
1187 romp)
1188 basic_machine=romp-ibm
1189 ;;
1190 mmix)
1191 basic_machine=mmix-knuth
1192 ;;
1193 rs6000)
1194 basic_machine=rs6000-ibm
1195 ;;
1196 vax)
1197 basic_machine=vax-dec
1198 ;;
1199 pdp10)
1200 # there are many clones, so DEC is not a safe bet
1201 basic_machine=pdp10-unknown
1202 ;;
1203 pdp11)
1204 basic_machine=pdp11-dec
1205 ;;
1206 we32k)
1207 basic_machine=we32k-att
1208 ;;
1209 sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele)
1210 basic_machine=sh-unknown
1211 ;;
1212 sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v)
1213 basic_machine=sparc-sun
1214 ;;
1215 cydra)
1216 basic_machine=cydra-cydrome
1217 ;;
1218 orion)
1219 basic_machine=orion-highlevel
1220 ;;
1221 orion105)
1222 basic_machine=clipper-highlevel
1223 ;;
1224 mac | mpw | mac-mpw)
1225 basic_machine=m68k-apple
1226 ;;
1227 pmac | pmac-mpw)
1228 basic_machine=powerpc-apple
1229 ;;
1230 *-unknown)
1231 # Make sure to match an already-canonicalized machine name.
1232 ;;
1233 *)
1234 echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2
1235 exit 1
1236 ;;
1237esac
1238
1239# Here we canonicalize certain aliases for manufacturers.
1240case $basic_machine in
1241 *-digital*)
1242 basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'`
1243 ;;
1244 *-commodore*)
1245 basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'`
1246 ;;
1247 *)
1248 ;;
1249esac
1250
1251# Decode manufacturer-specific aliases for certain operating systems.
1252
1253if [ x"$os" != x"" ]
1254then
1255case $os in
1256 # First match some system type aliases
1257 # that might get confused with valid system types.
1258 # -solaris* is a basic system type, with this one exception.
1259 -auroraux)
1260 os=-auroraux
1261 ;;
1262 -solaris1 | -solaris1.*)
1263 os=`echo $os | sed -e 's|solaris1|sunos4|'`
1264 ;;
1265 -solaris)
1266 os=-solaris2
1267 ;;
1268 -svr4*)
1269 os=-sysv4
1270 ;;
1271 -unixware*)
1272 os=-sysv4.2uw
1273 ;;
1274 -gnu/linux*)
1275 os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'`
1276 ;;
1277 # First accept the basic system types.
1278 # The portable systems comes first.
1279 # Each alternative MUST END IN A *, to match a version number.
1280 # -sysv* is not here because it comes later, after sysvr4.
1281 -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \
1282 | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\
1283 | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \
1284 | -sym* | -kopensolaris* \
1285 | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \
1286 | -aos* | -aros* \
1287 | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
1288 | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
1289 | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
1290 | -openbsd* | -solidbsd* \
1291 | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
1292 | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
1293 | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
1294 | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
1295 | -chorusos* | -chorusrdb* | -cegcc* \
1296 | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
1297 | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \
1298 | -uxpv* | -beos* | -mpeix* | -udk* \
1299 | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
1300 | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
1301 | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
1302 | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
1303 | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
1304 | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
1305 | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*)
1306 # Remember, each alternative MUST END IN *, to match a version number.
1307 ;;
1308 -qnx*)
1309 case $basic_machine in
1310 x86-* | i*86-*)
1311 ;;
1312 *)
1313 os=-nto$os
1314 ;;
1315 esac
1316 ;;
1317 -nto-qnx*)
1318 ;;
1319 -nto*)
1320 os=`echo $os | sed -e 's|nto|nto-qnx|'`
1321 ;;
1322 -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
1323 | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \
1324 | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*)
1325 ;;
1326 -mac*)
1327 os=`echo $os | sed -e 's|mac|macos|'`
1328 ;;
1329 -linux-dietlibc)
1330 os=-linux-dietlibc
1331 ;;
1332 -linux*)
1333 os=`echo $os | sed -e 's|linux|linux-gnu|'`
1334 ;;
1335 -sunos5*)
1336 os=`echo $os | sed -e 's|sunos5|solaris2|'`
1337 ;;
1338 -sunos6*)
1339 os=`echo $os | sed -e 's|sunos6|solaris3|'`
1340 ;;
1341 -opened*)
1342 os=-openedition
1343 ;;
1344 -os400*)
1345 os=-os400
1346 ;;
1347 -wince*)
1348 os=-wince
1349 ;;
1350 -osfrose*)
1351 os=-osfrose
1352 ;;
1353 -osf*)
1354 os=-osf
1355 ;;
1356 -utek*)
1357 os=-bsd
1358 ;;
1359 -dynix*)
1360 os=-bsd
1361 ;;
1362 -acis*)
1363 os=-aos
1364 ;;
1365 -atheos*)
1366 os=-atheos
1367 ;;
1368 -syllable*)
1369 os=-syllable
1370 ;;
1371 -386bsd)
1372 os=-bsd
1373 ;;
1374 -ctix* | -uts*)
1375 os=-sysv
1376 ;;
1377 -nova*)
1378 os=-rtmk-nova
1379 ;;
1380 -ns2 )
1381 os=-nextstep2
1382 ;;
1383 -nsk*)
1384 os=-nsk
1385 ;;
1386 # Preserve the version number of sinix5.
1387 -sinix5.*)
1388 os=`echo $os | sed -e 's|sinix|sysv|'`
1389 ;;
1390 -sinix*)
1391 os=-sysv4
1392 ;;
1393 -tpf*)
1394 os=-tpf
1395 ;;
1396 -triton*)
1397 os=-sysv3
1398 ;;
1399 -oss*)
1400 os=-sysv3
1401 ;;
1402 -svr4)
1403 os=-sysv4
1404 ;;
1405 -svr3)
1406 os=-sysv3
1407 ;;
1408 -sysvr4)
1409 os=-sysv4
1410 ;;
1411 # This must come after -sysvr4.
1412 -sysv*)
1413 ;;
1414 -ose*)
1415 os=-ose
1416 ;;
1417 -es1800*)
1418 os=-ose
1419 ;;
1420 -xenix)
1421 os=-xenix
1422 ;;
1423 -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
1424 os=-mint
1425 ;;
1426 -aros*)
1427 os=-aros
1428 ;;
1429 -kaos*)
1430 os=-kaos
1431 ;;
1432 -zvmoe)
1433 os=-zvmoe
1434 ;;
1435 -dicos*)
1436 os=-dicos
1437 ;;
1438 -none)
1439 ;;
1440 *)
1441 # Get rid of the `-' at the beginning of $os.
1442 os=`echo $os | sed 's/[^-]*-//'`
1443 echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2
1444 exit 1
1445 ;;
1446esac
1447else
1448
1449# Here we handle the default operating systems that come with various machines.
1450# The value should be what the vendor currently ships out the door with their
1451# machine or put another way, the most popular os provided with the machine.
1452
1453# Note that if you're going to try to match "-MANUFACTURER" here (say,
1454# "-sun"), then you have to tell the case statement up towards the top
1455# that MANUFACTURER isn't an operating system. Otherwise, code above
1456# will signal an error saying that MANUFACTURER isn't an operating
1457# system, and we'll never get to this point.
1458
1459case $basic_machine in
1460 score-*)
1461 os=-elf
1462 ;;
1463 spu-*)
1464 os=-elf
1465 ;;
1466 *-acorn)
1467 os=-riscix1.2
1468 ;;
1469 arm*-rebel)
1470 os=-linux
1471 ;;
1472 arm*-semi)
1473 os=-aout
1474 ;;
1475 c4x-* | tic4x-*)
1476 os=-coff
1477 ;;
1478 # This must come before the *-dec entry.
1479 pdp10-*)
1480 os=-tops20
1481 ;;
1482 pdp11-*)
1483 os=-none
1484 ;;
1485 *-dec | vax-*)
1486 os=-ultrix4.2
1487 ;;
1488 m68*-apollo)
1489 os=-domain
1490 ;;
1491 i386-sun)
1492 os=-sunos4.0.2
1493 ;;
1494 m68000-sun)
1495 os=-sunos3
1496 # This also exists in the configure program, but was not the
1497 # default.
1498 # os=-sunos4
1499 ;;
1500 m68*-cisco)
1501 os=-aout
1502 ;;
1503 mep-*)
1504 os=-elf
1505 ;;
1506 mips*-cisco)
1507 os=-elf
1508 ;;
1509 mips*-*)
1510 os=-elf
1511 ;;
1512 or32-*)
1513 os=-coff
1514 ;;
1515 *-tti) # must be before sparc entry or we get the wrong os.
1516 os=-sysv3
1517 ;;
1518 sparc-* | *-sun)
1519 os=-sunos4.1.1
1520 ;;
1521 *-be)
1522 os=-beos
1523 ;;
1524 *-haiku)
1525 os=-haiku
1526 ;;
1527 *-ibm)
1528 os=-aix
1529 ;;
1530 *-knuth)
1531 os=-mmixware
1532 ;;
1533 *-wec)
1534 os=-proelf
1535 ;;
1536 *-winbond)
1537 os=-proelf
1538 ;;
1539 *-oki)
1540 os=-proelf
1541 ;;
1542 *-hp)
1543 os=-hpux
1544 ;;
1545 *-hitachi)
1546 os=-hiux
1547 ;;
1548 i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent)
1549 os=-sysv
1550 ;;
1551 *-cbm)
1552 os=-amigaos
1553 ;;
1554 *-dg)
1555 os=-dgux
1556 ;;
1557 *-dolphin)
1558 os=-sysv3
1559 ;;
1560 m68k-ccur)
1561 os=-rtu
1562 ;;
1563 m88k-omron*)
1564 os=-luna
1565 ;;
1566 *-next )
1567 os=-nextstep
1568 ;;
1569 *-sequent)
1570 os=-ptx
1571 ;;
1572 *-crds)
1573 os=-unos
1574 ;;
1575 *-ns)
1576 os=-genix
1577 ;;
1578 i370-*)
1579 os=-mvs
1580 ;;
1581 *-next)
1582 os=-nextstep3
1583 ;;
1584 *-gould)
1585 os=-sysv
1586 ;;
1587 *-highlevel)
1588 os=-bsd
1589 ;;
1590 *-encore)
1591 os=-bsd
1592 ;;
1593 *-sgi)
1594 os=-irix
1595 ;;
1596 *-siemens)
1597 os=-sysv4
1598 ;;
1599 *-masscomp)
1600 os=-rtu
1601 ;;
1602 f30[01]-fujitsu | f700-fujitsu)
1603 os=-uxpv
1604 ;;
1605 *-rom68k)
1606 os=-coff
1607 ;;
1608 *-*bug)
1609 os=-coff
1610 ;;
1611 *-apple)
1612 os=-macos
1613 ;;
1614 *-atari*)
1615 os=-mint
1616 ;;
1617 *)
1618 os=-none
1619 ;;
1620esac
1621fi
1622
1623# Here we handle the case where we know the os, and the CPU type, but not the
1624# manufacturer. We pick the logical manufacturer.
1625vendor=unknown
1626case $basic_machine in
1627 *-unknown)
1628 case $os in
1629 -riscix*)
1630 vendor=acorn
1631 ;;
1632 -sunos*)
1633 vendor=sun
1634 ;;
1635 -cnk*|-aix*)
1636 vendor=ibm
1637 ;;
1638 -beos*)
1639 vendor=be
1640 ;;
1641 -hpux*)
1642 vendor=hp
1643 ;;
1644 -mpeix*)
1645 vendor=hp
1646 ;;
1647 -hiux*)
1648 vendor=hitachi
1649 ;;
1650 -unos*)
1651 vendor=crds
1652 ;;
1653 -dgux*)
1654 vendor=dg
1655 ;;
1656 -luna*)
1657 vendor=omron
1658 ;;
1659 -genix*)
1660 vendor=ns
1661 ;;
1662 -mvs* | -opened*)
1663 vendor=ibm
1664 ;;
1665 -os400*)
1666 vendor=ibm
1667 ;;
1668 -ptx*)
1669 vendor=sequent
1670 ;;
1671 -tpf*)
1672 vendor=ibm
1673 ;;
1674 -vxsim* | -vxworks* | -windiss*)
1675 vendor=wrs
1676 ;;
1677 -aux*)
1678 vendor=apple
1679 ;;
1680 -hms*)
1681 vendor=hitachi
1682 ;;
1683 -mpw* | -macos*)
1684 vendor=apple
1685 ;;
1686 -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
1687 vendor=atari
1688 ;;
1689 -vos*)
1690 vendor=stratus
1691 ;;
1692 esac
1693 basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"`
1694 ;;
1695esac
1696
1697echo $basic_machine$os
1698exit
1699
1700# Local variables:
1701# eval: (add-hook 'write-file-hooks 'time-stamp)
1702# time-stamp-start: "timestamp='"
1703# time-stamp-format: "%:y-%02m-%02d"
1704# time-stamp-end: "'"
1705# End:
config/depcomp +0 -630
……@@ -1,630 +0,0 @@
1#! /bin/sh
2# depcomp - compile a program generating dependencies as side-effects
3
4scriptversion=2009-04-28.21; # UTC
5
6# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009 Free
7# Software Foundation, Inc.
8
9# This program is free software; you can redistribute it and/or modify
10# it under the terms of the GNU General Public License as published by
11# the Free Software Foundation; either version 2, or (at your option)
12# any later version.
13
14# This program is distributed in the hope that it will be useful,
15# but WITHOUT ANY WARRANTY; without even the implied warranty of
16# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17# GNU General Public License for more details.
18
19# You should have received a copy of the GNU General Public License
20# along with this program. If not, see <http://www.gnu.org/licenses/>.
21
22# As a special exception to the GNU General Public License, if you
23# distribute this file as part of a program that contains a
24# configuration script generated by Autoconf, you may include it under
25# the same distribution terms that you use for the rest of that program.
26
27# Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>.
28
29case $1 in
30 '')
31 echo "$0: No command. Try \`$0 --help' for more information." 1>&2
32 exit 1;
33 ;;
34 -h | --h*)
35 cat <<\EOF
36Usage: depcomp [--help] [--version] PROGRAM [ARGS]
37
38Run PROGRAMS ARGS to compile a file, generating dependencies
39as side-effects.
40
41Environment variables:
42 depmode Dependency tracking mode.
43 source Source file read by `PROGRAMS ARGS'.
44 object Object file output by `PROGRAMS ARGS'.
45 DEPDIR directory where to store dependencies.
46 depfile Dependency file to output.
47 tmpdepfile Temporary file to use when outputing dependencies.
48 libtool Whether libtool is used (yes/no).
49
50Report bugs to <bug-automake@gnu.org>.
51EOF
52 exit $?
53 ;;
54 -v | --v*)
55 echo "depcomp $scriptversion"
56 exit $?
57 ;;
58esac
59
60if test -z "$depmode" || test -z "$source" || test -z "$object"; then
61 echo "depcomp: Variables source, object and depmode must be set" 1>&2
62 exit 1
63fi
64
65# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po.
66depfile=${depfile-`echo "$object" |
67 sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`}
68tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
69
70rm -f "$tmpdepfile"
71
72# Some modes work just like other modes, but use different flags. We
73# parameterize here, but still list the modes in the big case below,
74# to make depend.m4 easier to write. Note that we *cannot* use a case
75# here, because this file can only contain one case statement.
76if test "$depmode" = hp; then
77 # HP compiler uses -M and no extra arg.
78 gccflag=-M
79 depmode=gcc
80fi
81
82if test "$depmode" = dashXmstdout; then
83 # This is just like dashmstdout with a different argument.
84 dashmflag=-xM
85 depmode=dashmstdout
86fi
87
88cygpath_u="cygpath -u -f -"
89if test "$depmode" = msvcmsys; then
90 # This is just like msvisualcpp but w/o cygpath translation.
91 # Just convert the backslash-escaped backslashes to single forward
92 # slashes to satisfy depend.m4
93 cygpath_u="sed s,\\\\\\\\,/,g"
94 depmode=msvisualcpp
95fi
96
97case "$depmode" in
98gcc3)
99## gcc 3 implements dependency tracking that does exactly what
100## we want. Yay! Note: for some reason libtool 1.4 doesn't like
101## it if -MD -MP comes after the -MF stuff. Hmm.
102## Unfortunately, FreeBSD c89 acceptance of flags depends upon
103## the command line argument order; so add the flags where they
104## appear in depend2.am. Note that the slowdown incurred here
105## affects only configure: in makefiles, %FASTDEP% shortcuts this.
106 for arg
107 do
108 case $arg in
109 -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;;
110 *) set fnord "$@" "$arg" ;;
111 esac
112 shift # fnord
113 shift # $arg
114 done
115 "$@"
116 stat=$?
117 if test $stat -eq 0; then :
118 else
119 rm -f "$tmpdepfile"
120 exit $stat
121 fi
122 mv "$tmpdepfile" "$depfile"
123 ;;
124
125gcc)
126## There are various ways to get dependency output from gcc. Here's
127## why we pick this rather obscure method:
128## - Don't want to use -MD because we'd like the dependencies to end
129## up in a subdir. Having to rename by hand is ugly.
130## (We might end up doing this anyway to support other compilers.)
131## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
132## -MM, not -M (despite what the docs say).
133## - Using -M directly means running the compiler twice (even worse
134## than renaming).
135 if test -z "$gccflag"; then
136 gccflag=-MD,
137 fi
138 "$@" -Wp,"$gccflag$tmpdepfile"
139 stat=$?
140 if test $stat -eq 0; then :
141 else
142 rm -f "$tmpdepfile"
143 exit $stat
144 fi
145 rm -f "$depfile"
146 echo "$object : \\" > "$depfile"
147 alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
148## The second -e expression handles DOS-style file names with drive letters.
149 sed -e 's/^[^:]*: / /' \
150 -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile"
151## This next piece of magic avoids the `deleted header file' problem.
152## The problem is that when a header file which appears in a .P file
153## is deleted, the dependency causes make to die (because there is
154## typically no way to rebuild the header). We avoid this by adding
155## dummy dependencies for each header file. Too bad gcc doesn't do
156## this for us directly.
157 tr ' ' '
158' < "$tmpdepfile" |
159## Some versions of gcc put a space before the `:'. On the theory
160## that the space means something, we add a space to the output as
161## well.
162## Some versions of the HPUX 10.20 sed can't process this invocation
163## correctly. Breaking it into two sed invocations is a workaround.
164 sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
165 rm -f "$tmpdepfile"
166 ;;
167
168hp)
169 # This case exists only to let depend.m4 do its work. It works by
170 # looking at the text of this script. This case will never be run,
171 # since it is checked for above.
172 exit 1
173 ;;
174
175sgi)
176 if test "$libtool" = yes; then
177 "$@" "-Wp,-MDupdate,$tmpdepfile"
178 else
179 "$@" -MDupdate "$tmpdepfile"
180 fi
181 stat=$?
182 if test $stat -eq 0; then :
183 else
184 rm -f "$tmpdepfile"
185 exit $stat
186 fi
187 rm -f "$depfile"
188
189 if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files
190 echo "$object : \\" > "$depfile"
191
192 # Clip off the initial element (the dependent). Don't try to be
193 # clever and replace this with sed code, as IRIX sed won't handle
194 # lines with more than a fixed number of characters (4096 in
195 # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines;
196 # the IRIX cc adds comments like `#:fec' to the end of the
197 # dependency line.
198 tr ' ' '
199' < "$tmpdepfile" \
200 | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \
201 tr '
202' ' ' >> "$depfile"
203 echo >> "$depfile"
204
205 # The second pass generates a dummy entry for each header file.
206 tr ' ' '
207' < "$tmpdepfile" \
208 | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
209 >> "$depfile"
210 else
211 # The sourcefile does not contain any dependencies, so just
212 # store a dummy comment line, to avoid errors with the Makefile
213 # "include basename.Plo" scheme.
214 echo "#dummy" > "$depfile"
215 fi
216 rm -f "$tmpdepfile"
217 ;;
218
219aix)
220 # The C for AIX Compiler uses -M and outputs the dependencies
221 # in a .u file. In older versions, this file always lives in the
222 # current directory. Also, the AIX compiler puts `$object:' at the
223 # start of each line; $object doesn't have directory information.
224 # Version 6 uses the directory in both cases.
225 dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
226 test "x$dir" = "x$object" && dir=
227 base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
228 if test "$libtool" = yes; then
229 tmpdepfile1=$dir$base.u
230 tmpdepfile2=$base.u
231 tmpdepfile3=$dir.libs/$base.u
232 "$@" -Wc,-M
233 else
234 tmpdepfile1=$dir$base.u
235 tmpdepfile2=$dir$base.u
236 tmpdepfile3=$dir$base.u
237 "$@" -M
238 fi
239 stat=$?
240
241 if test $stat -eq 0; then :
242 else
243 rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
244 exit $stat
245 fi
246
247 for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
248 do
249 test -f "$tmpdepfile" && break
250 done
251 if test -f "$tmpdepfile"; then
252 # Each line is of the form `foo.o: dependent.h'.
253 # Do two passes, one to just change these to
254 # `$object: dependent.h' and one to simply `dependent.h:'.
255 sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile"
256 # That's a tab and a space in the [].
257 sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile"
258 else
259 # The sourcefile does not contain any dependencies, so just
260 # store a dummy comment line, to avoid errors with the Makefile
261 # "include basename.Plo" scheme.
262 echo "#dummy" > "$depfile"
263 fi
264 rm -f "$tmpdepfile"
265 ;;
266
267icc)
268 # Intel's C compiler understands `-MD -MF file'. However on
269 # icc -MD -MF foo.d -c -o sub/foo.o sub/foo.c
270 # ICC 7.0 will fill foo.d with something like
271 # foo.o: sub/foo.c
272 # foo.o: sub/foo.h
273 # which is wrong. We want:
274 # sub/foo.o: sub/foo.c
275 # sub/foo.o: sub/foo.h
276 # sub/foo.c:
277 # sub/foo.h:
278 # ICC 7.1 will output
279 # foo.o: sub/foo.c sub/foo.h
280 # and will wrap long lines using \ :
281 # foo.o: sub/foo.c ... \
282 # sub/foo.h ... \
283 # ...
284
285 "$@" -MD -MF "$tmpdepfile"
286 stat=$?
287 if test $stat -eq 0; then :
288 else
289 rm -f "$tmpdepfile"
290 exit $stat
291 fi
292 rm -f "$depfile"
293 # Each line is of the form `foo.o: dependent.h',
294 # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'.
295 # Do two passes, one to just change these to
296 # `$object: dependent.h' and one to simply `dependent.h:'.
297 sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile"
298 # Some versions of the HPUX 10.20 sed can't process this invocation
299 # correctly. Breaking it into two sed invocations is a workaround.
300 sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" |
301 sed -e 's/$/ :/' >> "$depfile"
302 rm -f "$tmpdepfile"
303 ;;
304
305hp2)
306 # The "hp" stanza above does not work with aCC (C++) and HP's ia64
307 # compilers, which have integrated preprocessors. The correct option
308 # to use with these is +Maked; it writes dependencies to a file named
309 # 'foo.d', which lands next to the object file, wherever that
310 # happens to be.
311 # Much of this is similar to the tru64 case; see comments there.
312 dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
313 test "x$dir" = "x$object" && dir=
314 base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
315 if test "$libtool" = yes; then
316 tmpdepfile1=$dir$base.d
317 tmpdepfile2=$dir.libs/$base.d
318 "$@" -Wc,+Maked
319 else
320 tmpdepfile1=$dir$base.d
321 tmpdepfile2=$dir$base.d
322 "$@" +Maked
323 fi
324 stat=$?
325 if test $stat -eq 0; then :
326 else
327 rm -f "$tmpdepfile1" "$tmpdepfile2"
328 exit $stat
329 fi
330
331 for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2"
332 do
333 test -f "$tmpdepfile" && break
334 done
335 if test -f "$tmpdepfile"; then
336 sed -e "s,^.*\.[a-z]*:,$object:," "$tmpdepfile" > "$depfile"
337 # Add `dependent.h:' lines.
338 sed -ne '2,${
339 s/^ *//
340 s/ \\*$//
341 s/$/:/
342 p
343 }' "$tmpdepfile" >> "$depfile"
344 else
345 echo "#dummy" > "$depfile"
346 fi
347 rm -f "$tmpdepfile" "$tmpdepfile2"
348 ;;
349
350tru64)
351 # The Tru64 compiler uses -MD to generate dependencies as a side
352 # effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'.
353 # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put
354 # dependencies in `foo.d' instead, so we check for that too.
355 # Subdirectories are respected.
356 dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
357 test "x$dir" = "x$object" && dir=
358 base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
359
360 if test "$libtool" = yes; then
361 # With Tru64 cc, shared objects can also be used to make a
362 # static library. This mechanism is used in libtool 1.4 series to
363 # handle both shared and static libraries in a single compilation.
364 # With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d.
365 #
366 # With libtool 1.5 this exception was removed, and libtool now
367 # generates 2 separate objects for the 2 libraries. These two
368 # compilations output dependencies in $dir.libs/$base.o.d and
369 # in $dir$base.o.d. We have to check for both files, because
370 # one of the two compilations can be disabled. We should prefer
371 # $dir$base.o.d over $dir.libs/$base.o.d because the latter is
372 # automatically cleaned when .libs/ is deleted, while ignoring
373 # the former would cause a distcleancheck panic.
374 tmpdepfile1=$dir.libs/$base.lo.d # libtool 1.4
375 tmpdepfile2=$dir$base.o.d # libtool 1.5
376 tmpdepfile3=$dir.libs/$base.o.d # libtool 1.5
377 tmpdepfile4=$dir.libs/$base.d # Compaq CCC V6.2-504
378 "$@" -Wc,-MD
379 else
380 tmpdepfile1=$dir$base.o.d
381 tmpdepfile2=$dir$base.d
382 tmpdepfile3=$dir$base.d
383 tmpdepfile4=$dir$base.d
384 "$@" -MD
385 fi
386
387 stat=$?
388 if test $stat -eq 0; then :
389 else
390 rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4"
391 exit $stat
392 fi
393
394 for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4"
395 do
396 test -f "$tmpdepfile" && break
397 done
398 if test -f "$tmpdepfile"; then
399 sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile"
400 # That's a tab and a space in the [].
401 sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile"
402 else
403 echo "#dummy" > "$depfile"
404 fi
405 rm -f "$tmpdepfile"
406 ;;
407
408#nosideeffect)
409 # This comment above is used by automake to tell side-effect
410 # dependency tracking mechanisms from slower ones.
411
412dashmstdout)
413 # Important note: in order to support this mode, a compiler *must*
414 # always write the preprocessed file to stdout, regardless of -o.
415 "$@" || exit $?
416
417 # Remove the call to Libtool.
418 if test "$libtool" = yes; then
419 while test "X$1" != 'X--mode=compile'; do
420 shift
421 done
422 shift
423 fi
424
425 # Remove `-o $object'.
426 IFS=" "
427 for arg
428 do
429 case $arg in
430 -o)
431 shift
432 ;;
433 $object)
434 shift
435 ;;
436 *)
437 set fnord "$@" "$arg"
438 shift # fnord
439 shift # $arg
440 ;;
441 esac
442 done
443
444 test -z "$dashmflag" && dashmflag=-M
445 # Require at least two characters before searching for `:'
446 # in the target name. This is to cope with DOS-style filenames:
447 # a dependency such as `c:/foo/bar' could be seen as target `c' otherwise.
448 "$@" $dashmflag |
449 sed 's:^[ ]*[^: ][^:][^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile"
450 rm -f "$depfile"
451 cat < "$tmpdepfile" > "$depfile"
452 tr ' ' '
453' < "$tmpdepfile" | \
454## Some versions of the HPUX 10.20 sed can't process this invocation
455## correctly. Breaking it into two sed invocations is a workaround.
456 sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
457 rm -f "$tmpdepfile"
458 ;;
459
460dashXmstdout)
461 # This case only exists to satisfy depend.m4. It is never actually
462 # run, as this mode is specially recognized in the preamble.
463 exit 1
464 ;;
465
466makedepend)
467 "$@" || exit $?
468 # Remove any Libtool call
469 if test "$libtool" = yes; then
470 while test "X$1" != 'X--mode=compile'; do
471 shift
472 done
473 shift
474 fi
475 # X makedepend
476 shift
477 cleared=no eat=no
478 for arg
479 do
480 case $cleared in
481 no)
482 set ""; shift
483 cleared=yes ;;
484 esac
485 if test $eat = yes; then
486 eat=no
487 continue
488 fi
489 case "$arg" in
490 -D*|-I*)
491 set fnord "$@" "$arg"; shift ;;
492 # Strip any option that makedepend may not understand. Remove
493 # the object too, otherwise makedepend will parse it as a source file.
494 -arch)
495 eat=yes ;;
496 -*|$object)
497 ;;
498 *)
499 set fnord "$@" "$arg"; shift ;;
500 esac
501 done
502 obj_suffix=`echo "$object" | sed 's/^.*\././'`
503 touch "$tmpdepfile"
504 ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
505 rm -f "$depfile"
506 cat < "$tmpdepfile" > "$depfile"
507 sed '1,2d' "$tmpdepfile" | tr ' ' '
508' | \
509## Some versions of the HPUX 10.20 sed can't process this invocation
510## correctly. Breaking it into two sed invocations is a workaround.
511 sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
512 rm -f "$tmpdepfile" "$tmpdepfile".bak
513 ;;
514
515cpp)
516 # Important note: in order to support this mode, a compiler *must*
517 # always write the preprocessed file to stdout.
518 "$@" || exit $?
519
520 # Remove the call to Libtool.
521 if test "$libtool" = yes; then
522 while test "X$1" != 'X--mode=compile'; do
523 shift
524 done
525 shift
526 fi
527
528 # Remove `-o $object'.
529 IFS=" "
530 for arg
531 do
532 case $arg in
533 -o)
534 shift
535 ;;
536 $object)
537 shift
538 ;;
539 *)
540 set fnord "$@" "$arg"
541 shift # fnord
542 shift # $arg
543 ;;
544 esac
545 done
546
547 "$@" -E |
548 sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \
549 -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' |
550 sed '$ s: \\$::' > "$tmpdepfile"
551 rm -f "$depfile"
552 echo "$object : \\" > "$depfile"
553 cat < "$tmpdepfile" >> "$depfile"
554 sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile"
555 rm -f "$tmpdepfile"
556 ;;
557
558msvisualcpp)
559 # Important note: in order to support this mode, a compiler *must*
560 # always write the preprocessed file to stdout.
561 "$@" || exit $?
562
563 # Remove the call to Libtool.
564 if test "$libtool" = yes; then
565 while test "X$1" != 'X--mode=compile'; do
566 shift
567 done
568 shift
569 fi
570
571 IFS=" "
572 for arg
573 do
574 case "$arg" in
575 -o)
576 shift
577 ;;
578 $object)
579 shift
580 ;;
581 "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
582 set fnord "$@"
583 shift
584 shift
585 ;;
586 *)
587 set fnord "$@" "$arg"
588 shift
589 shift
590 ;;
591 esac
592 done
593 "$@" -E 2>/dev/null |
594 sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile"
595 rm -f "$depfile"
596 echo "$object : \\" > "$depfile"
597 sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile"
598 echo " " >> "$depfile"
599 sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile"
600 rm -f "$tmpdepfile"
601 ;;
602
603msvcmsys)
604 # This case exists only to let depend.m4 do its work. It works by
605 # looking at the text of this script. This case will never be run,
606 # since it is checked for above.
607 exit 1
608 ;;
609
610none)
611 exec "$@"
612 ;;
613
614*)
615 echo "Unknown depmode $depmode" 1>&2
616 exit 1
617 ;;
618esac
619
620exit 0
621
622# Local Variables:
623# mode: shell-script
624# sh-indentation: 2
625# eval: (add-hook 'write-file-hooks 'time-stamp)
626# time-stamp-start: "scriptversion="
627# time-stamp-format: "%:y-%02m-%02d.%02H"
628# time-stamp-time-zone: "UTC"
629# time-stamp-end: "; # UTC"
630# End:
config/install-sh +0 -520
……@@ -1,520 +0,0 @@
1#!/bin/sh
2# install - install a program, script, or datafile
3
4scriptversion=2009-04-28.21; # UTC
5
6# This originates from X11R5 (mit/util/scripts/install.sh), which was
7# later released in X11R6 (xc/config/util/install.sh) with the
8# following copyright and license.
9#
10# Copyright (C) 1994 X Consortium
11#
12# Permission is hereby granted, free of charge, to any person obtaining a copy
13# of this software and associated documentation files (the "Software"), to
14# deal in the Software without restriction, including without limitation the
15# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
16# sell copies of the Software, and to permit persons to whom the Software is
17# furnished to do so, subject to the following conditions:
18#
19# The above copyright notice and this permission notice shall be included in
20# all copies or substantial portions of the Software.
21#
22# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
23# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
24# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
25# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
26# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC-
27# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
28#
29# Except as contained in this notice, the name of the X Consortium shall not
30# be used in advertising or otherwise to promote the sale, use or other deal-
31# ings in this Software without prior written authorization from the X Consor-
32# tium.
33#
34#
35# FSF changes to this file are in the public domain.
36#
37# Calling this script install-sh is preferred over install.sh, to prevent
38# `make' implicit rules from creating a file called install from it
39# when there is no Makefile.
40#
41# This script is compatible with the BSD install script, but was written
42# from scratch.
43
44nl='
45'
46IFS=" "" $nl"
47
48# set DOITPROG to echo to test this script
49
50# Don't use :- since 4.3BSD and earlier shells don't like it.
51doit=${DOITPROG-}
52if test -z "$doit"; then
53 doit_exec=exec
54else
55 doit_exec=$doit
56fi
57
58# Put in absolute file names if you don't have them in your path;
59# or use environment vars.
60
61chgrpprog=${CHGRPPROG-chgrp}
62chmodprog=${CHMODPROG-chmod}
63chownprog=${CHOWNPROG-chown}
64cmpprog=${CMPPROG-cmp}
65cpprog=${CPPROG-cp}
66mkdirprog=${MKDIRPROG-mkdir}
67mvprog=${MVPROG-mv}
68rmprog=${RMPROG-rm}
69stripprog=${STRIPPROG-strip}
70
71posix_glob='?'
72initialize_posix_glob='
73 test "$posix_glob" != "?" || {
74 if (set -f) 2>/dev/null; then
75 posix_glob=
76 else
77 posix_glob=:
78 fi
79 }
80'
81
82posix_mkdir=
83
84# Desired mode of installed file.
85mode=0755
86
87chgrpcmd=
88chmodcmd=$chmodprog
89chowncmd=
90mvcmd=$mvprog
91rmcmd="$rmprog -f"
92stripcmd=
93
94src=
95dst=
96dir_arg=
97dst_arg=
98
99copy_on_change=false
100no_target_directory=
101
102usage="\
103Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE
104 or: $0 [OPTION]... SRCFILES... DIRECTORY
105 or: $0 [OPTION]... -t DIRECTORY SRCFILES...
106 or: $0 [OPTION]... -d DIRECTORIES...
107
108In the 1st form, copy SRCFILE to DSTFILE.
109In the 2nd and 3rd, copy all SRCFILES to DIRECTORY.
110In the 4th, create DIRECTORIES.
111
112Options:
113 --help display this help and exit.
114 --version display version info and exit.
115
116 -c (ignored)
117 -C install only if different (preserve the last data modification time)
118 -d create directories instead of installing files.
119 -g GROUP $chgrpprog installed files to GROUP.
120 -m MODE $chmodprog installed files to MODE.
121 -o USER $chownprog installed files to USER.
122 -s $stripprog installed files.
123 -t DIRECTORY install into DIRECTORY.
124 -T report an error if DSTFILE is a directory.
125
126Environment variables override the default commands:
127 CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG
128 RMPROG STRIPPROG
129"
130
131while test $# -ne 0; do
132 case $1 in
133 -c) ;;
134
135 -C) copy_on_change=true;;
136
137 -d) dir_arg=true;;
138
139 -g) chgrpcmd="$chgrpprog $2"
140 shift;;
141
142 --help) echo "$usage"; exit $?;;
143
144 -m) mode=$2
145 case $mode in
146 *' '* | *' '* | *'
147'* | *'*'* | *'?'* | *'['*)
148 echo "$0: invalid mode: $mode" >&2
149 exit 1;;
150 esac
151 shift;;
152
153 -o) chowncmd="$chownprog $2"
154 shift;;
155
156 -s) stripcmd=$stripprog;;
157
158 -t) dst_arg=$2
159 shift;;
160
161 -T) no_target_directory=true;;
162
163 --version) echo "$0 $scriptversion"; exit $?;;
164
165 --) shift
166 break;;
167
168 -*) echo "$0: invalid option: $1" >&2
169 exit 1;;
170
171 *) break;;
172 esac
173 shift
174done
175
176if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then
177 # When -d is used, all remaining arguments are directories to create.
178 # When -t is used, the destination is already specified.
179 # Otherwise, the last argument is the destination. Remove it from $@.
180 for arg
181 do
182 if test -n "$dst_arg"; then
183 # $@ is not empty: it contains at least $arg.
184 set fnord "$@" "$dst_arg"
185 shift # fnord
186 fi
187 shift # arg
188 dst_arg=$arg
189 done
190fi
191
192if test $# -eq 0; then
193 if test -z "$dir_arg"; then
194 echo "$0: no input file specified." >&2
195 exit 1
196 fi
197 # It's OK to call `install-sh -d' without argument.
198 # This can happen when creating conditional directories.
199 exit 0
200fi
201
202if test -z "$dir_arg"; then
203 trap '(exit $?); exit' 1 2 13 15
204
205 # Set umask so as not to create temps with too-generous modes.
206 # However, 'strip' requires both read and write access to temps.
207 case $mode in
208 # Optimize common cases.
209 *644) cp_umask=133;;
210 *755) cp_umask=22;;
211
212 *[0-7])
213 if test -z "$stripcmd"; then
214 u_plus_rw=
215 else
216 u_plus_rw='% 200'
217 fi
218 cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;;
219 *)
220 if test -z "$stripcmd"; then
221 u_plus_rw=
222 else
223 u_plus_rw=,u+rw
224 fi
225 cp_umask=$mode$u_plus_rw;;
226 esac
227fi
228
229for src
230do
231 # Protect names starting with `-'.
232 case $src in
233 -*) src=./$src;;
234 esac
235
236 if test -n "$dir_arg"; then
237 dst=$src
238 dstdir=$dst
239 test -d "$dstdir"
240 dstdir_status=$?
241 else
242
243 # Waiting for this to be detected by the "$cpprog $src $dsttmp" command
244 # might cause directories to be created, which would be especially bad
245 # if $src (and thus $dsttmp) contains '*'.
246 if test ! -f "$src" && test ! -d "$src"; then
247 echo "$0: $src does not exist." >&2
248 exit 1
249 fi
250
251 if test -z "$dst_arg"; then
252 echo "$0: no destination specified." >&2
253 exit 1
254 fi
255
256 dst=$dst_arg
257 # Protect names starting with `-'.
258 case $dst in
259 -*) dst=./$dst;;
260 esac
261
262 # If destination is a directory, append the input filename; won't work
263 # if double slashes aren't ignored.
264 if test -d "$dst"; then
265 if test -n "$no_target_directory"; then
266 echo "$0: $dst_arg: Is a directory" >&2
267 exit 1
268 fi
269 dstdir=$dst
270 dst=$dstdir/`basename "$src"`
271 dstdir_status=0
272 else
273 # Prefer dirname, but fall back on a substitute if dirname fails.
274 dstdir=`
275 (dirname "$dst") 2>/dev/null ||
276 expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
277 X"$dst" : 'X\(//\)[^/]' \| \
278 X"$dst" : 'X\(//\)$' \| \
279 X"$dst" : 'X\(/\)' \| . 2>/dev/null ||
280 echo X"$dst" |
281 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
282 s//\1/
283 q
284 }
285 /^X\(\/\/\)[^/].*/{
286 s//\1/
287 q
288 }
289 /^X\(\/\/\)$/{
290 s//\1/
291 q
292 }
293 /^X\(\/\).*/{
294 s//\1/
295 q
296 }
297 s/.*/./; q'
298 `
299
300 test -d "$dstdir"
301 dstdir_status=$?
302 fi
303 fi
304
305 obsolete_mkdir_used=false
306
307 if test $dstdir_status != 0; then
308 case $posix_mkdir in
309 '')
310 # Create intermediate dirs using mode 755 as modified by the umask.
311 # This is like FreeBSD 'install' as of 1997-10-28.
312 umask=`umask`
313 case $stripcmd.$umask in
314 # Optimize common cases.
315 *[2367][2367]) mkdir_umask=$umask;;
316 .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;;
317
318 *[0-7])
319 mkdir_umask=`expr $umask + 22 \
320 - $umask % 100 % 40 + $umask % 20 \
321 - $umask % 10 % 4 + $umask % 2
322 `;;
323 *) mkdir_umask=$umask,go-w;;
324 esac
325
326 # With -d, create the new directory with the user-specified mode.
327 # Otherwise, rely on $mkdir_umask.
328 if test -n "$dir_arg"; then
329 mkdir_mode=-m$mode
330 else
331 mkdir_mode=
332 fi
333
334 posix_mkdir=false
335 case $umask in
336 *[123567][0-7][0-7])
337 # POSIX mkdir -p sets u+wx bits regardless of umask, which
338 # is incompatible with FreeBSD 'install' when (umask & 300) != 0.
339 ;;
340 *)
341 tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$
342 trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0
343
344 if (umask $mkdir_umask &&
345 exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1
346 then
347 if test -z "$dir_arg" || {
348 # Check for POSIX incompatibilities with -m.
349 # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or
350 # other-writeable bit of parent directory when it shouldn't.
351 # FreeBSD 6.1 mkdir -m -p sets mode of existing directory.
352 ls_ld_tmpdir=`ls -ld "$tmpdir"`
353 case $ls_ld_tmpdir in
354 d????-?r-*) different_mode=700;;
355 d????-?--*) different_mode=755;;
356 *) false;;
357 esac &&
358 $mkdirprog -m$different_mode -p -- "$tmpdir" && {
359 ls_ld_tmpdir_1=`ls -ld "$tmpdir"`
360 test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1"
361 }
362 }
363 then posix_mkdir=:
364 fi
365 rmdir "$tmpdir/d" "$tmpdir"
366 else
367 # Remove any dirs left behind by ancient mkdir implementations.
368 rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null
369 fi
370 trap '' 0;;
371 esac;;
372 esac
373
374 if
375 $posix_mkdir && (
376 umask $mkdir_umask &&
377 $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir"
378 )
379 then :
380 else
381
382 # The umask is ridiculous, or mkdir does not conform to POSIX,
383 # or it failed possibly due to a race condition. Create the
384 # directory the slow way, step by step, checking for races as we go.
385
386 case $dstdir in
387 /*) prefix='/';;
388 -*) prefix='./';;
389 *) prefix='';;
390 esac
391
392 eval "$initialize_posix_glob"
393
394 oIFS=$IFS
395 IFS=/
396 $posix_glob set -f
397 set fnord $dstdir
398 shift
399 $posix_glob set +f
400 IFS=$oIFS
401
402 prefixes=
403
404 for d
405 do
406 test -z "$d" && continue
407
408 prefix=$prefix$d
409 if test -d "$prefix"; then
410 prefixes=
411 else
412 if $posix_mkdir; then
413 (umask=$mkdir_umask &&
414 $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break
415 # Don't fail if two instances are running concurrently.
416 test -d "$prefix" || exit 1
417 else
418 case $prefix in
419 *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;;
420 *) qprefix=$prefix;;
421 esac
422 prefixes="$prefixes '$qprefix'"
423 fi
424 fi
425 prefix=$prefix/
426 done
427
428 if test -n "$prefixes"; then
429 # Don't fail if two instances are running concurrently.
430 (umask $mkdir_umask &&
431 eval "\$doit_exec \$mkdirprog $prefixes") ||
432 test -d "$dstdir" || exit 1
433 obsolete_mkdir_used=true
434 fi
435 fi
436 fi
437
438 if test -n "$dir_arg"; then
439 { test -z "$chowncmd" || $doit $chowncmd "$dst"; } &&
440 { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } &&
441 { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false ||
442 test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1
443 else
444
445 # Make a couple of temp file names in the proper directory.
446 dsttmp=$dstdir/_inst.$$_
447 rmtmp=$dstdir/_rm.$$_
448
449 # Trap to clean up those temp files at exit.
450 trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0
451
452 # Copy the file name to the temp name.
453 (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") &&
454
455 # and set any options; do chmod last to preserve setuid bits.
456 #
457 # If any of these fail, we abort the whole thing. If we want to
458 # ignore errors from any of these, just make sure not to ignore
459 # errors from the above "$doit $cpprog $src $dsttmp" command.
460 #
461 { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } &&
462 { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } &&
463 { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } &&
464 { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } &&
465
466 # If -C, don't bother to copy if it wouldn't change the file.
467 if $copy_on_change &&
468 old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` &&
469 new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` &&
470
471 eval "$initialize_posix_glob" &&
472 $posix_glob set -f &&
473 set X $old && old=:$2:$4:$5:$6 &&
474 set X $new && new=:$2:$4:$5:$6 &&
475 $posix_glob set +f &&
476
477 test "$old" = "$new" &&
478 $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1
479 then
480 rm -f "$dsttmp"
481 else
482 # Rename the file to the real destination.
483 $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null ||
484
485 # The rename failed, perhaps because mv can't rename something else
486 # to itself, or perhaps because mv is so ancient that it does not
487 # support -f.
488 {
489 # Now remove or move aside any old file at destination location.
490 # We try this two ways since rm can't unlink itself on some
491 # systems and the destination file might be busy for other
492 # reasons. In this case, the final cleanup might fail but the new
493 # file should still install successfully.
494 {
495 test ! -f "$dst" ||
496 $doit $rmcmd -f "$dst" 2>/dev/null ||
497 { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null &&
498 { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; }
499 } ||
500 { echo "$0: cannot unlink or rename $dst" >&2
501 (exit 1); exit 1
502 }
503 } &&
504
505 # Now rename the file to the real destination.
506 $doit $mvcmd "$dsttmp" "$dst"
507 }
508 fi || exit 1
509
510 trap '' 0
511 fi
512done
513
514# Local variables:
515# eval: (add-hook 'write-file-hooks 'time-stamp)
516# time-stamp-start: "scriptversion="
517# time-stamp-format: "%:y-%02m-%02d.%02H"
518# time-stamp-time-zone: "UTC"
519# time-stamp-end: "; # UTC"
520# End:
config/ltmain.sh +0 -9655
……@@ -1,9655 +0,0 @@
1
2# libtool (GNU libtool) 2.4.2
3# Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
4
5# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006,
6# 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
7# This is free software; see the source for copying conditions. There is NO
8# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
9
10# GNU Libtool is free software; you can redistribute it and/or modify
11# it under the terms of the GNU General Public License as published by
12# the Free Software Foundation; either version 2 of the License, or
13# (at your option) any later version.
14#
15# As a special exception to the GNU General Public License,
16# if you distribute this file as part of a program or library that
17# is built using GNU Libtool, you may include this file under the
18# same distribution terms that you use for the rest of that program.
19#
20# GNU Libtool is distributed in the hope that it will be useful, but
21# WITHOUT ANY WARRANTY; without even the implied warranty of
22# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
23# General Public License for more details.
24#
25# You should have received a copy of the GNU General Public License
26# along with GNU Libtool; see the file COPYING. If not, a copy
27# can be downloaded from http://www.gnu.org/licenses/gpl.html,
28# or obtained by writing to the Free Software Foundation, Inc.,
29# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
30
31# Usage: $progname [OPTION]... [MODE-ARG]...
32#
33# Provide generalized library-building support services.
34#
35# --config show all configuration variables
36# --debug enable verbose shell tracing
37# -n, --dry-run display commands without modifying any files
38# --features display basic configuration information and exit
39# --mode=MODE use operation mode MODE
40# --preserve-dup-deps don't remove duplicate dependency libraries
41# --quiet, --silent don't print informational messages
42# --no-quiet, --no-silent
43# print informational messages (default)
44# --no-warn don't display warning messages
45# --tag=TAG use configuration variables from tag TAG
46# -v, --verbose print more informational messages than default
47# --no-verbose don't print the extra informational messages
48# --version print version information
49# -h, --help, --help-all print short, long, or detailed help message
50#
51# MODE must be one of the following:
52#
53# clean remove files from the build directory
54# compile compile a source file into a libtool object
55# execute automatically set library path, then run a program
56# finish complete the installation of libtool libraries
57# install install libraries or executables
58# link create a library or an executable
59# uninstall remove libraries from an installed directory
60#
61# MODE-ARGS vary depending on the MODE. When passed as first option,
62# `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that.
63# Try `$progname --help --mode=MODE' for a more detailed description of MODE.
64#
65# When reporting a bug, please describe a test case to reproduce it and
66# include the following information:
67#
68# host-triplet: $host
69# shell: $SHELL
70# compiler: $LTCC
71# compiler flags: $LTCFLAGS
72# linker: $LD (gnu? $with_gnu_ld)
73# $progname: (GNU libtool) 2.4.2
74# automake: $automake_version
75# autoconf: $autoconf_version
76#
77# Report bugs to <bug-libtool@gnu.org>.
78# GNU libtool home page: <http://www.gnu.org/software/libtool/>.
79# General help using GNU software: <http://www.gnu.org/gethelp/>.
80
81PROGRAM=libtool
82PACKAGE=libtool
83VERSION=2.4.2
84TIMESTAMP=""
85package_revision=1.3337
86
87# Be Bourne compatible
88if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
89 emulate sh
90 NULLCMD=:
91 # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
92 # is contrary to our usage. Disable this feature.
93 alias -g '${1+"$@"}'='"$@"'
94 setopt NO_GLOB_SUBST
95else
96 case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac
97fi
98BIN_SH=xpg4; export BIN_SH # for Tru64
99DUALCASE=1; export DUALCASE # for MKS sh
100
101# A function that is used when there is no print builtin or printf.
102func_fallback_echo ()
103{
104 eval 'cat <<_LTECHO_EOF
105$1
106_LTECHO_EOF'
107}
108
109# NLS nuisances: We save the old values to restore during execute mode.
110lt_user_locale=
111lt_safe_locale=
112for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
113do
114 eval "if test \"\${$lt_var+set}\" = set; then
115 save_$lt_var=\$$lt_var
116 $lt_var=C
117 export $lt_var
118 lt_user_locale=\"$lt_var=\\\$save_\$lt_var; \$lt_user_locale\"
119 lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\"
120 fi"
121done
122LC_ALL=C
123LANGUAGE=C
124export LANGUAGE LC_ALL
125
126$lt_unset CDPATH
127
128
129# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh
130# is ksh but when the shell is invoked as "sh" and the current value of
131# the _XPG environment variable is not equal to 1 (one), the special
132# positional parameter $0, within a function call, is the name of the
133# function.
134progpath="$0"
135
136
137
138: ${CP="cp -f"}
139test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'}
140: ${MAKE="make"}
141: ${MKDIR="mkdir"}
142: ${MV="mv -f"}
143: ${RM="rm -f"}
144: ${SHELL="${CONFIG_SHELL-/bin/sh}"}
145: ${Xsed="$SED -e 1s/^X//"}
146
147# Global variables:
148EXIT_SUCCESS=0
149EXIT_FAILURE=1
150EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing.
151EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake.
152
153exit_status=$EXIT_SUCCESS
154
155# Make sure IFS has a sensible default
156lt_nl='
157'
158IFS=" $lt_nl"
159
160dirname="s,/[^/]*$,,"
161basename="s,^.*/,,"
162
163# func_dirname file append nondir_replacement
164# Compute the dirname of FILE. If nonempty, add APPEND to the result,
165# otherwise set result to NONDIR_REPLACEMENT.
166func_dirname ()
167{
168 func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
169 if test "X$func_dirname_result" = "X${1}"; then
170 func_dirname_result="${3}"
171 else
172 func_dirname_result="$func_dirname_result${2}"
173 fi
174} # func_dirname may be replaced by extended shell implementation
175
176
177# func_basename file
178func_basename ()
179{
180 func_basename_result=`$ECHO "${1}" | $SED "$basename"`
181} # func_basename may be replaced by extended shell implementation
182
183
184# func_dirname_and_basename file append nondir_replacement
185# perform func_basename and func_dirname in a single function
186# call:
187# dirname: Compute the dirname of FILE. If nonempty,
188# add APPEND to the result, otherwise set result
189# to NONDIR_REPLACEMENT.
190# value returned in "$func_dirname_result"
191# basename: Compute filename of FILE.
192# value retuned in "$func_basename_result"
193# Implementation must be kept synchronized with func_dirname
194# and func_basename. For efficiency, we do not delegate to
195# those functions but instead duplicate the functionality here.
196func_dirname_and_basename ()
197{
198 # Extract subdirectory from the argument.
199 func_dirname_result=`$ECHO "${1}" | $SED -e "$dirname"`
200 if test "X$func_dirname_result" = "X${1}"; then
201 func_dirname_result="${3}"
202 else
203 func_dirname_result="$func_dirname_result${2}"
204 fi
205 func_basename_result=`$ECHO "${1}" | $SED -e "$basename"`
206} # func_dirname_and_basename may be replaced by extended shell implementation
207
208
209# func_stripname prefix suffix name
210# strip PREFIX and SUFFIX off of NAME.
211# PREFIX and SUFFIX must not contain globbing or regex special
212# characters, hashes, percent signs, but SUFFIX may contain a leading
213# dot (in which case that matches only a dot).
214# func_strip_suffix prefix name
215func_stripname ()
216{
217 case ${2} in
218 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
219 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
220 esac
221} # func_stripname may be replaced by extended shell implementation
222
223
224# These SED scripts presuppose an absolute path with a trailing slash.
225pathcar='s,^/\([^/]*\).*$,\1,'
226pathcdr='s,^/[^/]*,,'
227removedotparts=':dotsl
228 s@/\./@/@g
229 t dotsl
230 s,/\.$,/,'
231collapseslashes='s@/\{1,\}@/@g'
232finalslash='s,/*$,/,'
233
234# func_normal_abspath PATH
235# Remove doubled-up and trailing slashes, "." path components,
236# and cancel out any ".." path components in PATH after making
237# it an absolute path.
238# value returned in "$func_normal_abspath_result"
239func_normal_abspath ()
240{
241 # Start from root dir and reassemble the path.
242 func_normal_abspath_result=
243 func_normal_abspath_tpath=$1
244 func_normal_abspath_altnamespace=
245 case $func_normal_abspath_tpath in
246 "")
247 # Empty path, that just means $cwd.
248 func_stripname '' '/' "`pwd`"
249 func_normal_abspath_result=$func_stripname_result
250 return
251 ;;
252 # The next three entries are used to spot a run of precisely
253 # two leading slashes without using negated character classes;
254 # we take advantage of case's first-match behaviour.
255 ///*)
256 # Unusual form of absolute path, do nothing.
257 ;;
258 //*)
259 # Not necessarily an ordinary path; POSIX reserves leading '//'
260 # and for example Cygwin uses it to access remote file shares
261 # over CIFS/SMB, so we conserve a leading double slash if found.
262 func_normal_abspath_altnamespace=/
263 ;;
264 /*)
265 # Absolute path, do nothing.
266 ;;
267 *)
268 # Relative path, prepend $cwd.
269 func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath
270 ;;
271 esac
272 # Cancel out all the simple stuff to save iterations. We also want
273 # the path to end with a slash for ease of parsing, so make sure
274 # there is one (and only one) here.
275 func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
276 -e "$removedotparts" -e "$collapseslashes" -e "$finalslash"`
277 while :; do
278 # Processed it all yet?
279 if test "$func_normal_abspath_tpath" = / ; then
280 # If we ascended to the root using ".." the result may be empty now.
281 if test -z "$func_normal_abspath_result" ; then
282 func_normal_abspath_result=/
283 fi
284 break
285 fi
286 func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \
287 -e "$pathcar"`
288 func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \
289 -e "$pathcdr"`
290 # Figure out what to do with it
291 case $func_normal_abspath_tcomponent in
292 "")
293 # Trailing empty path component, ignore it.
294 ;;
295 ..)
296 # Parent dir; strip last assembled component from result.
297 func_dirname "$func_normal_abspath_result"
298 func_normal_abspath_result=$func_dirname_result
299 ;;
300 *)
301 # Actual path component, append it.
302 func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent
303 ;;
304 esac
305 done
306 # Restore leading double-slash if one was found on entry.
307 func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result
308}
309
310# func_relative_path SRCDIR DSTDIR
311# generates a relative path from SRCDIR to DSTDIR, with a trailing
312# slash if non-empty, suitable for immediately appending a filename
313# without needing to append a separator.
314# value returned in "$func_relative_path_result"
315func_relative_path ()
316{
317 func_relative_path_result=
318 func_normal_abspath "$1"
319 func_relative_path_tlibdir=$func_normal_abspath_result
320 func_normal_abspath "$2"
321 func_relative_path_tbindir=$func_normal_abspath_result
322
323 # Ascend the tree starting from libdir
324 while :; do
325 # check if we have found a prefix of bindir
326 case $func_relative_path_tbindir in
327 $func_relative_path_tlibdir)
328 # found an exact match
329 func_relative_path_tcancelled=
330 break
331 ;;
332 $func_relative_path_tlibdir*)
333 # found a matching prefix
334 func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir"
335 func_relative_path_tcancelled=$func_stripname_result
336 if test -z "$func_relative_path_result"; then
337 func_relative_path_result=.
338 fi
339 break
340 ;;
341 *)
342 func_dirname $func_relative_path_tlibdir
343 func_relative_path_tlibdir=${func_dirname_result}
344 if test "x$func_relative_path_tlibdir" = x ; then
345 # Have to descend all the way to the root!
346 func_relative_path_result=../$func_relative_path_result
347 func_relative_path_tcancelled=$func_relative_path_tbindir
348 break
349 fi
350 func_relative_path_result=../$func_relative_path_result
351 ;;
352 esac
353 done
354
355 # Now calculate path; take care to avoid doubling-up slashes.
356 func_stripname '' '/' "$func_relative_path_result"
357 func_relative_path_result=$func_stripname_result
358 func_stripname '/' '/' "$func_relative_path_tcancelled"
359 if test "x$func_stripname_result" != x ; then
360 func_relative_path_result=${func_relative_path_result}/${func_stripname_result}
361 fi
362
363 # Normalisation. If bindir is libdir, return empty string,
364 # else relative path ending with a slash; either way, target
365 # file name can be directly appended.
366 if test ! -z "$func_relative_path_result"; then
367 func_stripname './' '' "$func_relative_path_result/"
368 func_relative_path_result=$func_stripname_result
369 fi
370}
371
372# The name of this program:
373func_dirname_and_basename "$progpath"
374progname=$func_basename_result
375
376# Make sure we have an absolute path for reexecution:
377case $progpath in
378 [\\/]*|[A-Za-z]:\\*) ;;
379 *[\\/]*)
380 progdir=$func_dirname_result
381 progdir=`cd "$progdir" && pwd`
382 progpath="$progdir/$progname"
383 ;;
384 *)
385 save_IFS="$IFS"
386 IFS=${PATH_SEPARATOR-:}
387 for progdir in $PATH; do
388 IFS="$save_IFS"
389 test -x "$progdir/$progname" && break
390 done
391 IFS="$save_IFS"
392 test -n "$progdir" || progdir=`pwd`
393 progpath="$progdir/$progname"
394 ;;
395esac
396
397# Sed substitution that helps us do robust quoting. It backslashifies
398# metacharacters that are still active within double-quoted strings.
399Xsed="${SED}"' -e 1s/^X//'
400sed_quote_subst='s/\([`"$\\]\)/\\\1/g'
401
402# Same as above, but do not quote variable references.
403double_quote_subst='s/\(["`\\]\)/\\\1/g'
404
405# Sed substitution that turns a string into a regex matching for the
406# string literally.
407sed_make_literal_regex='s,[].[^$\\*\/],\\&,g'
408
409# Sed substitution that converts a w32 file name or path
410# which contains forward slashes, into one that contains
411# (escaped) backslashes. A very naive implementation.
412lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g'
413
414# Re-`\' parameter expansions in output of double_quote_subst that were
415# `\'-ed in input to the same. If an odd number of `\' preceded a '$'
416# in input to double_quote_subst, that '$' was protected from expansion.
417# Since each input `\' is now two `\'s, look for any number of runs of
418# four `\'s followed by two `\'s and then a '$'. `\' that '$'.
419bs='\\'
420bs2='\\\\'
421bs4='\\\\\\\\'
422dollar='\$'
423sed_double_backslash="\
424 s/$bs4/&\\
425/g
426 s/^$bs2$dollar/$bs&/
427 s/\\([^$bs]\\)$bs2$dollar/\\1$bs2$bs$dollar/g
428 s/\n//g"
429
430# Standard options:
431opt_dry_run=false
432opt_help=false
433opt_quiet=false
434opt_verbose=false
435opt_warning=:
436
437# func_echo arg...
438# Echo program name prefixed message, along with the current mode
439# name if it has been set yet.
440func_echo ()
441{
442 $ECHO "$progname: ${opt_mode+$opt_mode: }$*"
443}
444
445# func_verbose arg...
446# Echo program name prefixed message in verbose mode only.
447func_verbose ()
448{
449 $opt_verbose && func_echo ${1+"$@"}
450
451 # A bug in bash halts the script if the last line of a function
452 # fails when set -e is in force, so we need another command to
453 # work around that:
454 :
455}
456
457# func_echo_all arg...
458# Invoke $ECHO with all args, space-separated.
459func_echo_all ()
460{
461 $ECHO "$*"
462}
463
464# func_error arg...
465# Echo program name prefixed message to standard error.
466func_error ()
467{
468 $ECHO "$progname: ${opt_mode+$opt_mode: }"${1+"$@"} 1>&2
469}
470
471# func_warning arg...
472# Echo program name prefixed warning message to standard error.
473func_warning ()
474{
475 $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2
476
477 # bash bug again:
478 :
479}
480
481# func_fatal_error arg...
482# Echo program name prefixed message to standard error, and exit.
483func_fatal_error ()
484{
485 func_error ${1+"$@"}
486 exit $EXIT_FAILURE
487}
488
489# func_fatal_help arg...
490# Echo program name prefixed message to standard error, followed by
491# a help hint, and exit.
492func_fatal_help ()
493{
494 func_error ${1+"$@"}
495 func_fatal_error "$help"
496}
497help="Try \`$progname --help' for more information." ## default
498
499
500# func_grep expression filename
501# Check whether EXPRESSION matches any line of FILENAME, without output.
502func_grep ()
503{
504 $GREP "$1" "$2" >/dev/null 2>&1
505}
506
507
508# func_mkdir_p directory-path
509# Make sure the entire path to DIRECTORY-PATH is available.
510func_mkdir_p ()
511{
512 my_directory_path="$1"
513 my_dir_list=
514
515 if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then
516
517 # Protect directory names starting with `-'
518 case $my_directory_path in
519 -*) my_directory_path="./$my_directory_path" ;;
520 esac
521
522 # While some portion of DIR does not yet exist...
523 while test ! -d "$my_directory_path"; do
524 # ...make a list in topmost first order. Use a colon delimited
525 # list incase some portion of path contains whitespace.
526 my_dir_list="$my_directory_path:$my_dir_list"
527
528 # If the last portion added has no slash in it, the list is done
529 case $my_directory_path in */*) ;; *) break ;; esac
530
531 # ...otherwise throw away the child directory and loop
532 my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"`
533 done
534 my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'`
535
536 save_mkdir_p_IFS="$IFS"; IFS=':'
537 for my_dir in $my_dir_list; do
538 IFS="$save_mkdir_p_IFS"
539 # mkdir can fail with a `File exist' error if two processes
540 # try to create one of the directories concurrently. Don't
541 # stop in that case!
542 $MKDIR "$my_dir" 2>/dev/null || :
543 done
544 IFS="$save_mkdir_p_IFS"
545
546 # Bail out if we (or some other process) failed to create a directory.
547 test -d "$my_directory_path" || \
548 func_fatal_error "Failed to create \`$1'"
549 fi
550}
551
552
553# func_mktempdir [string]
554# Make a temporary directory that won't clash with other running
555# libtool processes, and avoids race conditions if possible. If
556# given, STRING is the basename for that directory.
557func_mktempdir ()
558{
559 my_template="${TMPDIR-/tmp}/${1-$progname}"
560
561 if test "$opt_dry_run" = ":"; then
562 # Return a directory name, but don't create it in dry-run mode
563 my_tmpdir="${my_template}-$$"
564 else
565
566 # If mktemp works, use that first and foremost
567 my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null`
568
569 if test ! -d "$my_tmpdir"; then
570 # Failing that, at least try and use $RANDOM to avoid a race
571 my_tmpdir="${my_template}-${RANDOM-0}$$"
572
573 save_mktempdir_umask=`umask`
574 umask 0077
575 $MKDIR "$my_tmpdir"
576 umask $save_mktempdir_umask
577 fi
578
579 # If we're not in dry-run mode, bomb out on failure
580 test -d "$my_tmpdir" || \
581 func_fatal_error "cannot create temporary directory \`$my_tmpdir'"
582 fi
583
584 $ECHO "$my_tmpdir"
585}
586
587
588# func_quote_for_eval arg
589# Aesthetically quote ARG to be evaled later.
590# This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT
591# is double-quoted, suitable for a subsequent eval, whereas
592# FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters
593# which are still active within double quotes backslashified.
594func_quote_for_eval ()
595{
596 case $1 in
597 *[\\\`\"\$]*)
598 func_quote_for_eval_unquoted_result=`$ECHO "$1" | $SED "$sed_quote_subst"` ;;
599 *)
600 func_quote_for_eval_unquoted_result="$1" ;;
601 esac
602
603 case $func_quote_for_eval_unquoted_result in
604 # Double-quote args containing shell metacharacters to delay
605 # word splitting, command substitution and and variable
606 # expansion for a subsequent eval.
607 # Many Bourne shells cannot handle close brackets correctly
608 # in scan sets, so we specify it separately.
609 *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"")
610 func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\""
611 ;;
612 *)
613 func_quote_for_eval_result="$func_quote_for_eval_unquoted_result"
614 esac
615}
616
617
618# func_quote_for_expand arg
619# Aesthetically quote ARG to be evaled later; same as above,
620# but do not quote variable references.
621func_quote_for_expand ()
622{
623 case $1 in
624 *[\\\`\"]*)
625 my_arg=`$ECHO "$1" | $SED \
626 -e "$double_quote_subst" -e "$sed_double_backslash"` ;;
627 *)
628 my_arg="$1" ;;
629 esac
630
631 case $my_arg in
632 # Double-quote args containing shell metacharacters to delay
633 # word splitting and command substitution for a subsequent eval.
634 # Many Bourne shells cannot handle close brackets correctly
635 # in scan sets, so we specify it separately.
636 *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"")
637 my_arg="\"$my_arg\""
638 ;;
639 esac
640
641 func_quote_for_expand_result="$my_arg"
642}
643
644
645# func_show_eval cmd [fail_exp]
646# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is
647# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP
648# is given, then evaluate it.
649func_show_eval ()
650{
651 my_cmd="$1"
652 my_fail_exp="${2-:}"
653
654 ${opt_silent-false} || {
655 func_quote_for_expand "$my_cmd"
656 eval "func_echo $func_quote_for_expand_result"
657 }
658
659 if ${opt_dry_run-false}; then :; else
660 eval "$my_cmd"
661 my_status=$?
662 if test "$my_status" -eq 0; then :; else
663 eval "(exit $my_status); $my_fail_exp"
664 fi
665 fi
666}
667
668
669# func_show_eval_locale cmd [fail_exp]
670# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is
671# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP
672# is given, then evaluate it. Use the saved locale for evaluation.
673func_show_eval_locale ()
674{
675 my_cmd="$1"
676 my_fail_exp="${2-:}"
677
678 ${opt_silent-false} || {
679 func_quote_for_expand "$my_cmd"
680 eval "func_echo $func_quote_for_expand_result"
681 }
682
683 if ${opt_dry_run-false}; then :; else
684 eval "$lt_user_locale
685 $my_cmd"
686 my_status=$?
687 eval "$lt_safe_locale"
688 if test "$my_status" -eq 0; then :; else
689 eval "(exit $my_status); $my_fail_exp"
690 fi
691 fi
692}
693
694# func_tr_sh
695# Turn $1 into a string suitable for a shell variable name.
696# Result is stored in $func_tr_sh_result. All characters
697# not in the set a-zA-Z0-9_ are replaced with '_'. Further,
698# if $1 begins with a digit, a '_' is prepended as well.
699func_tr_sh ()
700{
701 case $1 in
702 [0-9]* | *[!a-zA-Z0-9_]*)
703 func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'`
704 ;;
705 * )
706 func_tr_sh_result=$1
707 ;;
708 esac
709}
710
711
712# func_version
713# Echo version message to standard output and exit.
714func_version ()
715{
716 $opt_debug
717
718 $SED -n '/(C)/!b go
719 :more
720 /\./!{
721 N
722 s/\n# / /
723 b more
724 }
725 :go
726 /^# '$PROGRAM' (GNU /,/# warranty; / {
727 s/^# //
728 s/^# *$//
729 s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/
730 p
731 }' < "$progpath"
732 exit $?
733}
734
735# func_usage
736# Echo short help message to standard output and exit.
737func_usage ()
738{
739 $opt_debug
740
741 $SED -n '/^# Usage:/,/^# *.*--help/ {
742 s/^# //
743 s/^# *$//
744 s/\$progname/'$progname'/
745 p
746 }' < "$progpath"
747 echo
748 $ECHO "run \`$progname --help | more' for full usage"
749 exit $?
750}
751
752# func_help [NOEXIT]
753# Echo long help message to standard output and exit,
754# unless 'noexit' is passed as argument.
755func_help ()
756{
757 $opt_debug
758
759 $SED -n '/^# Usage:/,/# Report bugs to/ {
760 :print
761 s/^# //
762 s/^# *$//
763 s*\$progname*'$progname'*
764 s*\$host*'"$host"'*
765 s*\$SHELL*'"$SHELL"'*
766 s*\$LTCC*'"$LTCC"'*
767 s*\$LTCFLAGS*'"$LTCFLAGS"'*
768 s*\$LD*'"$LD"'*
769 s/\$with_gnu_ld/'"$with_gnu_ld"'/
770 s/\$automake_version/'"`(${AUTOMAKE-automake} --version) 2>/dev/null |$SED 1q`"'/
771 s/\$autoconf_version/'"`(${AUTOCONF-autoconf} --version) 2>/dev/null |$SED 1q`"'/
772 p
773 d
774 }
775 /^# .* home page:/b print
776 /^# General help using/b print
777 ' < "$progpath"
778 ret=$?
779 if test -z "$1"; then
780 exit $ret
781 fi
782}
783
784# func_missing_arg argname
785# Echo program name prefixed message to standard error and set global
786# exit_cmd.
787func_missing_arg ()
788{
789 $opt_debug
790
791 func_error "missing argument for $1."
792 exit_cmd=exit
793}
794
795
796# func_split_short_opt shortopt
797# Set func_split_short_opt_name and func_split_short_opt_arg shell
798# variables after splitting SHORTOPT after the 2nd character.
799func_split_short_opt ()
800{
801 my_sed_short_opt='1s/^\(..\).*$/\1/;q'
802 my_sed_short_rest='1s/^..\(.*\)$/\1/;q'
803
804 func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"`
805 func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"`
806} # func_split_short_opt may be replaced by extended shell implementation
807
808
809# func_split_long_opt longopt
810# Set func_split_long_opt_name and func_split_long_opt_arg shell
811# variables after splitting LONGOPT at the `=' sign.
812func_split_long_opt ()
813{
814 my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q'
815 my_sed_long_arg='1s/^--[^=]*=//'
816
817 func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"`
818 func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"`
819} # func_split_long_opt may be replaced by extended shell implementation
820
821exit_cmd=:
822
823
824
825
826
827magic="%%%MAGIC variable%%%"
828magic_exe="%%%MAGIC EXE variable%%%"
829
830# Global variables.
831nonopt=
832preserve_args=
833lo2o="s/\\.lo\$/.${objext}/"
834o2lo="s/\\.${objext}\$/.lo/"
835extracted_archives=
836extracted_serial=0
837
838# If this variable is set in any of the actions, the command in it
839# will be execed at the end. This prevents here-documents from being
840# left over by shells.
841exec_cmd=
842
843# func_append var value
844# Append VALUE to the end of shell variable VAR.
845func_append ()
846{
847 eval "${1}=\$${1}\${2}"
848} # func_append may be replaced by extended shell implementation
849
850# func_append_quoted var value
851# Quote VALUE and append to the end of shell variable VAR, separated
852# by a space.
853func_append_quoted ()
854{
855 func_quote_for_eval "${2}"
856 eval "${1}=\$${1}\\ \$func_quote_for_eval_result"
857} # func_append_quoted may be replaced by extended shell implementation
858
859
860# func_arith arithmetic-term...
861func_arith ()
862{
863 func_arith_result=`expr "${@}"`
864} # func_arith may be replaced by extended shell implementation
865
866
867# func_len string
868# STRING may not start with a hyphen.
869func_len ()
870{
871 func_len_result=`expr "${1}" : ".*" 2>/dev/null || echo $max_cmd_len`
872} # func_len may be replaced by extended shell implementation
873
874
875# func_lo2o object
876func_lo2o ()
877{
878 func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
879} # func_lo2o may be replaced by extended shell implementation
880
881
882# func_xform libobj-or-source
883func_xform ()
884{
885 func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
886} # func_xform may be replaced by extended shell implementation
887
888
889# func_fatal_configuration arg...
890# Echo program name prefixed message to standard error, followed by
891# a configuration failure hint, and exit.
892func_fatal_configuration ()
893{
894 func_error ${1+"$@"}
895 func_error "See the $PACKAGE documentation for more information."
896 func_fatal_error "Fatal configuration error."
897}
898
899
900# func_config
901# Display the configuration for all the tags in this script.
902func_config ()
903{
904 re_begincf='^# ### BEGIN LIBTOOL'
905 re_endcf='^# ### END LIBTOOL'
906
907 # Default configuration.
908 $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath"
909
910 # Now print the configurations for the tags.
911 for tagname in $taglist; do
912 $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath"
913 done
914
915 exit $?
916}
917
918# func_features
919# Display the features supported by this script.
920func_features ()
921{
922 echo "host: $host"
923 if test "$build_libtool_libs" = yes; then
924 echo "enable shared libraries"
925 else
926 echo "disable shared libraries"
927 fi
928 if test "$build_old_libs" = yes; then
929 echo "enable static libraries"
930 else
931 echo "disable static libraries"
932 fi
933
934 exit $?
935}
936
937# func_enable_tag tagname
938# Verify that TAGNAME is valid, and either flag an error and exit, or
939# enable the TAGNAME tag. We also add TAGNAME to the global $taglist
940# variable here.
941func_enable_tag ()
942{
943 # Global variable:
944 tagname="$1"
945
946 re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$"
947 re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$"
948 sed_extractcf="/$re_begincf/,/$re_endcf/p"
949
950 # Validate tagname.
951 case $tagname in
952 *[!-_A-Za-z0-9,/]*)
953 func_fatal_error "invalid tag name: $tagname"
954 ;;
955 esac
956
957 # Don't test for the "default" C tag, as we know it's
958 # there but not specially marked.
959 case $tagname in
960 CC) ;;
961 *)
962 if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then
963 taglist="$taglist $tagname"
964
965 # Evaluate the configuration. Be careful to quote the path
966 # and the sed script, to avoid splitting on whitespace, but
967 # also don't use non-portable quotes within backquotes within
968 # quotes we have to do it in 2 steps:
969 extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"`
970 eval "$extractedcf"
971 else
972 func_error "ignoring unknown tag $tagname"
973 fi
974 ;;
975 esac
976}
977
978# func_check_version_match
979# Ensure that we are using m4 macros, and libtool script from the same
980# release of libtool.
981func_check_version_match ()
982{
983 if test "$package_revision" != "$macro_revision"; then
984 if test "$VERSION" != "$macro_version"; then
985 if test -z "$macro_version"; then
986 cat >&2 <<_LT_EOF
987$progname: Version mismatch error. This is $PACKAGE $VERSION, but the
988$progname: definition of this LT_INIT comes from an older release.
989$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
990$progname: and run autoconf again.
991_LT_EOF
992 else
993 cat >&2 <<_LT_EOF
994$progname: Version mismatch error. This is $PACKAGE $VERSION, but the
995$progname: definition of this LT_INIT comes from $PACKAGE $macro_version.
996$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
997$progname: and run autoconf again.
998_LT_EOF
999 fi
1000 else
1001 cat >&2 <<_LT_EOF
1002$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision,
1003$progname: but the definition of this LT_INIT comes from revision $macro_revision.
1004$progname: You should recreate aclocal.m4 with macros from revision $package_revision
1005$progname: of $PACKAGE $VERSION and run autoconf again.
1006_LT_EOF
1007 fi
1008
1009 exit $EXIT_MISMATCH
1010 fi
1011}
1012
1013
1014# Shorthand for --mode=foo, only valid as the first argument
1015case $1 in
1016clean|clea|cle|cl)
1017 shift; set dummy --mode clean ${1+"$@"}; shift
1018 ;;
1019compile|compil|compi|comp|com|co|c)
1020 shift; set dummy --mode compile ${1+"$@"}; shift
1021 ;;
1022execute|execut|execu|exec|exe|ex|e)
1023 shift; set dummy --mode execute ${1+"$@"}; shift
1024 ;;
1025finish|finis|fini|fin|fi|f)
1026 shift; set dummy --mode finish ${1+"$@"}; shift
1027 ;;
1028install|instal|insta|inst|ins|in|i)
1029 shift; set dummy --mode install ${1+"$@"}; shift
1030 ;;
1031link|lin|li|l)
1032 shift; set dummy --mode link ${1+"$@"}; shift
1033 ;;
1034uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
1035 shift; set dummy --mode uninstall ${1+"$@"}; shift
1036 ;;
1037esac
1038
1039
1040
1041# Option defaults:
1042opt_debug=:
1043opt_dry_run=false
1044opt_config=false
1045opt_preserve_dup_deps=false
1046opt_features=false
1047opt_finish=false
1048opt_help=false
1049opt_help_all=false
1050opt_silent=:
1051opt_warning=:
1052opt_verbose=:
1053opt_silent=false
1054opt_verbose=false
1055
1056
1057# Parse options once, thoroughly. This comes as soon as possible in the
1058# script to make things like `--version' happen as quickly as we can.
1059{
1060 # this just eases exit handling
1061 while test $# -gt 0; do
1062 opt="$1"
1063 shift
1064 case $opt in
1065 --debug|-x) opt_debug='set -x'
1066 func_echo "enabling shell trace mode"
1067 $opt_debug
1068 ;;
1069 --dry-run|--dryrun|-n)
1070 opt_dry_run=:
1071 ;;
1072 --config)
1073 opt_config=:
1074func_config
1075 ;;
1076 --dlopen|-dlopen)
1077 optarg="$1"
1078 opt_dlopen="${opt_dlopen+$opt_dlopen
1079}$optarg"
1080 shift
1081 ;;
1082 --preserve-dup-deps)
1083 opt_preserve_dup_deps=:
1084 ;;
1085 --features)
1086 opt_features=:
1087func_features
1088 ;;
1089 --finish)
1090 opt_finish=:
1091set dummy --mode finish ${1+"$@"}; shift
1092 ;;
1093 --help)
1094 opt_help=:
1095 ;;
1096 --help-all)
1097 opt_help_all=:
1098opt_help=': help-all'
1099 ;;
1100 --mode)
1101 test $# = 0 && func_missing_arg $opt && break
1102 optarg="$1"
1103 opt_mode="$optarg"
1104case $optarg in
1105 # Valid mode arguments:
1106 clean|compile|execute|finish|install|link|relink|uninstall) ;;
1107
1108 # Catch anything else as an error
1109 *) func_error "invalid argument for $opt"
1110 exit_cmd=exit
1111 break
1112 ;;
1113esac
1114 shift
1115 ;;
1116 --no-silent|--no-quiet)
1117 opt_silent=false
1118func_append preserve_args " $opt"
1119 ;;
1120 --no-warning|--no-warn)
1121 opt_warning=false
1122func_append preserve_args " $opt"
1123 ;;
1124 --no-verbose)
1125 opt_verbose=false
1126func_append preserve_args " $opt"
1127 ;;
1128 --silent|--quiet)
1129 opt_silent=:
1130func_append preserve_args " $opt"
1131 opt_verbose=false
1132 ;;
1133 --verbose|-v)
1134 opt_verbose=:
1135func_append preserve_args " $opt"
1136opt_silent=false
1137 ;;
1138 --tag)
1139 test $# = 0 && func_missing_arg $opt && break
1140 optarg="$1"
1141 opt_tag="$optarg"
1142func_append preserve_args " $opt $optarg"
1143func_enable_tag "$optarg"
1144 shift
1145 ;;
1146
1147 -\?|-h) func_usage ;;
1148 --help) func_help ;;
1149 --version) func_version ;;
1150
1151 # Separate optargs to long options:
1152 --*=*)
1153 func_split_long_opt "$opt"
1154 set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"}
1155 shift
1156 ;;
1157
1158 # Separate non-argument short options:
1159 -\?*|-h*|-n*|-v*)
1160 func_split_short_opt "$opt"
1161 set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"}
1162 shift
1163 ;;
1164
1165 --) break ;;
1166 -*) func_fatal_help "unrecognized option \`$opt'" ;;
1167 *) set dummy "$opt" ${1+"$@"}; shift; break ;;
1168 esac
1169 done
1170
1171 # Validate options:
1172
1173 # save first non-option argument
1174 if test "$#" -gt 0; then
1175 nonopt="$opt"
1176 shift
1177 fi
1178
1179 # preserve --debug
1180 test "$opt_debug" = : || func_append preserve_args " --debug"
1181
1182 case $host in
1183 *cygwin* | *mingw* | *pw32* | *cegcc*)
1184 # don't eliminate duplications in $postdeps and $predeps
1185 opt_duplicate_compiler_generated_deps=:
1186 ;;
1187 *)
1188 opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps
1189 ;;
1190 esac
1191
1192 $opt_help || {
1193 # Sanity checks first:
1194 func_check_version_match
1195
1196 if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then
1197 func_fatal_configuration "not configured to build any kind of library"
1198 fi
1199
1200 # Darwin sucks
1201 eval std_shrext=\"$shrext_cmds\"
1202
1203 # Only execute mode is allowed to have -dlopen flags.
1204 if test -n "$opt_dlopen" && test "$opt_mode" != execute; then
1205 func_error "unrecognized option \`-dlopen'"
1206 $ECHO "$help" 1>&2
1207 exit $EXIT_FAILURE
1208 fi
1209
1210 # Change the help message to a mode-specific one.
1211 generic_help="$help"
1212 help="Try \`$progname --help --mode=$opt_mode' for more information."
1213 }
1214
1215
1216 # Bail if the options were screwed
1217 $exit_cmd $EXIT_FAILURE
1218}
1219
1220
1221
1222
1223## ----------- ##
1224## Main. ##
1225## ----------- ##
1226
1227# func_lalib_p file
1228# True iff FILE is a libtool `.la' library or `.lo' object file.
1229# This function is only a basic sanity check; it will hardly flush out
1230# determined imposters.
1231func_lalib_p ()
1232{
1233 test -f "$1" &&
1234 $SED -e 4q "$1" 2>/dev/null \
1235 | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1
1236}
1237
1238# func_lalib_unsafe_p file
1239# True iff FILE is a libtool `.la' library or `.lo' object file.
1240# This function implements the same check as func_lalib_p without
1241# resorting to external programs. To this end, it redirects stdin and
1242# closes it afterwards, without saving the original file descriptor.
1243# As a safety measure, use it only where a negative result would be
1244# fatal anyway. Works if `file' does not exist.
1245func_lalib_unsafe_p ()
1246{
1247 lalib_p=no
1248 if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then
1249 for lalib_p_l in 1 2 3 4
1250 do
1251 read lalib_p_line
1252 case "$lalib_p_line" in
1253 \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;;
1254 esac
1255 done
1256 exec 0<&5 5<&-
1257 fi
1258 test "$lalib_p" = yes
1259}
1260
1261# func_ltwrapper_script_p file
1262# True iff FILE is a libtool wrapper script
1263# This function is only a basic sanity check; it will hardly flush out
1264# determined imposters.
1265func_ltwrapper_script_p ()
1266{
1267 func_lalib_p "$1"
1268}
1269
1270# func_ltwrapper_executable_p file
1271# True iff FILE is a libtool wrapper executable
1272# This function is only a basic sanity check; it will hardly flush out
1273# determined imposters.
1274func_ltwrapper_executable_p ()
1275{
1276 func_ltwrapper_exec_suffix=
1277 case $1 in
1278 *.exe) ;;
1279 *) func_ltwrapper_exec_suffix=.exe ;;
1280 esac
1281 $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1
1282}
1283
1284# func_ltwrapper_scriptname file
1285# Assumes file is an ltwrapper_executable
1286# uses $file to determine the appropriate filename for a
1287# temporary ltwrapper_script.
1288func_ltwrapper_scriptname ()
1289{
1290 func_dirname_and_basename "$1" "" "."
1291 func_stripname '' '.exe' "$func_basename_result"
1292 func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper"
1293}
1294
1295# func_ltwrapper_p file
1296# True iff FILE is a libtool wrapper script or wrapper executable
1297# This function is only a basic sanity check; it will hardly flush out
1298# determined imposters.
1299func_ltwrapper_p ()
1300{
1301 func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1"
1302}
1303
1304
1305# func_execute_cmds commands fail_cmd
1306# Execute tilde-delimited COMMANDS.
1307# If FAIL_CMD is given, eval that upon failure.
1308# FAIL_CMD may read-access the current command in variable CMD!
1309func_execute_cmds ()
1310{
1311 $opt_debug
1312 save_ifs=$IFS; IFS='~'
1313 for cmd in $1; do
1314 IFS=$save_ifs
1315 eval cmd=\"$cmd\"
1316 func_show_eval "$cmd" "${2-:}"
1317 done
1318 IFS=$save_ifs
1319}
1320
1321
1322# func_source file
1323# Source FILE, adding directory component if necessary.
1324# Note that it is not necessary on cygwin/mingw to append a dot to
1325# FILE even if both FILE and FILE.exe exist: automatic-append-.exe
1326# behavior happens only for exec(3), not for open(2)! Also, sourcing
1327# `FILE.' does not work on cygwin managed mounts.
1328func_source ()
1329{
1330 $opt_debug
1331 case $1 in
1332 */* | *\\*) . "$1" ;;
1333 *) . "./$1" ;;
1334 esac
1335}
1336
1337
1338# func_resolve_sysroot PATH
1339# Replace a leading = in PATH with a sysroot. Store the result into
1340# func_resolve_sysroot_result
1341func_resolve_sysroot ()
1342{
1343 func_resolve_sysroot_result=$1
1344 case $func_resolve_sysroot_result in
1345 =*)
1346 func_stripname '=' '' "$func_resolve_sysroot_result"
1347 func_resolve_sysroot_result=$lt_sysroot$func_stripname_result
1348 ;;
1349 esac
1350}
1351
1352# func_replace_sysroot PATH
1353# If PATH begins with the sysroot, replace it with = and
1354# store the result into func_replace_sysroot_result.
1355func_replace_sysroot ()
1356{
1357 case "$lt_sysroot:$1" in
1358 ?*:"$lt_sysroot"*)
1359 func_stripname "$lt_sysroot" '' "$1"
1360 func_replace_sysroot_result="=$func_stripname_result"
1361 ;;
1362 *)
1363 # Including no sysroot.
1364 func_replace_sysroot_result=$1
1365 ;;
1366 esac
1367}
1368
1369# func_infer_tag arg
1370# Infer tagged configuration to use if any are available and
1371# if one wasn't chosen via the "--tag" command line option.
1372# Only attempt this if the compiler in the base compile
1373# command doesn't match the default compiler.
1374# arg is usually of the form 'gcc ...'
1375func_infer_tag ()
1376{
1377 $opt_debug
1378 if test -n "$available_tags" && test -z "$tagname"; then
1379 CC_quoted=
1380 for arg in $CC; do
1381 func_append_quoted CC_quoted "$arg"
1382 done
1383 CC_expanded=`func_echo_all $CC`
1384 CC_quoted_expanded=`func_echo_all $CC_quoted`
1385 case $@ in
1386 # Blanks in the command may have been stripped by the calling shell,
1387 # but not from the CC environment variable when configure was run.
1388 " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \
1389 " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;;
1390 # Blanks at the start of $base_compile will cause this to fail
1391 # if we don't check for them as well.
1392 *)
1393 for z in $available_tags; do
1394 if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then
1395 # Evaluate the configuration.
1396 eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`"
1397 CC_quoted=
1398 for arg in $CC; do
1399 # Double-quote args containing other shell metacharacters.
1400 func_append_quoted CC_quoted "$arg"
1401 done
1402 CC_expanded=`func_echo_all $CC`
1403 CC_quoted_expanded=`func_echo_all $CC_quoted`
1404 case "$@ " in
1405 " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \
1406 " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*)
1407 # The compiler in the base compile command matches
1408 # the one in the tagged configuration.
1409 # Assume this is the tagged configuration we want.
1410 tagname=$z
1411 break
1412 ;;
1413 esac
1414 fi
1415 done
1416 # If $tagname still isn't set, then no tagged configuration
1417 # was found and let the user know that the "--tag" command
1418 # line option must be used.
1419 if test -z "$tagname"; then
1420 func_echo "unable to infer tagged configuration"
1421 func_fatal_error "specify a tag with \`--tag'"
1422# else
1423# func_verbose "using $tagname tagged configuration"
1424 fi
1425 ;;
1426 esac
1427 fi
1428}
1429
1430
1431
1432# func_write_libtool_object output_name pic_name nonpic_name
1433# Create a libtool object file (analogous to a ".la" file),
1434# but don't create it if we're doing a dry run.
1435func_write_libtool_object ()
1436{
1437 write_libobj=${1}
1438 if test "$build_libtool_libs" = yes; then
1439 write_lobj=\'${2}\'
1440 else
1441 write_lobj=none
1442 fi
1443
1444 if test "$build_old_libs" = yes; then
1445 write_oldobj=\'${3}\'
1446 else
1447 write_oldobj=none
1448 fi
1449
1450 $opt_dry_run || {
1451 cat >${write_libobj}T <<EOF
1452# $write_libobj - a libtool object file
1453# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
1454#
1455# Please DO NOT delete this file!
1456# It is necessary for linking the library.
1457
1458# Name of the PIC object.
1459pic_object=$write_lobj
1460
1461# Name of the non-PIC object
1462non_pic_object=$write_oldobj
1463
1464EOF
1465 $MV "${write_libobj}T" "${write_libobj}"
1466 }
1467}
1468
1469
1470##################################################
1471# FILE NAME AND PATH CONVERSION HELPER FUNCTIONS #
1472##################################################
1473
1474# func_convert_core_file_wine_to_w32 ARG
1475# Helper function used by file name conversion functions when $build is *nix,
1476# and $host is mingw, cygwin, or some other w32 environment. Relies on a
1477# correctly configured wine environment available, with the winepath program
1478# in $build's $PATH.
1479#
1480# ARG is the $build file name to be converted to w32 format.
1481# Result is available in $func_convert_core_file_wine_to_w32_result, and will
1482# be empty on error (or when ARG is empty)
1483func_convert_core_file_wine_to_w32 ()
1484{
1485 $opt_debug
1486 func_convert_core_file_wine_to_w32_result="$1"
1487 if test -n "$1"; then
1488 # Unfortunately, winepath does not exit with a non-zero error code, so we
1489 # are forced to check the contents of stdout. On the other hand, if the
1490 # command is not found, the shell will set an exit code of 127 and print
1491 # *an error message* to stdout. So we must check for both error code of
1492 # zero AND non-empty stdout, which explains the odd construction:
1493 func_convert_core_file_wine_to_w32_tmp=`winepath -w "$1" 2>/dev/null`
1494 if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then
1495 func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" |
1496 $SED -e "$lt_sed_naive_backslashify"`
1497 else
1498 func_convert_core_file_wine_to_w32_result=
1499 fi
1500 fi
1501}
1502# end: func_convert_core_file_wine_to_w32
1503
1504
1505# func_convert_core_path_wine_to_w32 ARG
1506# Helper function used by path conversion functions when $build is *nix, and
1507# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly
1508# configured wine environment available, with the winepath program in $build's
1509# $PATH. Assumes ARG has no leading or trailing path separator characters.
1510#
1511# ARG is path to be converted from $build format to win32.
1512# Result is available in $func_convert_core_path_wine_to_w32_result.
1513# Unconvertible file (directory) names in ARG are skipped; if no directory names
1514# are convertible, then the result may be empty.
1515func_convert_core_path_wine_to_w32 ()
1516{
1517 $opt_debug
1518 # unfortunately, winepath doesn't convert paths, only file names
1519 func_convert_core_path_wine_to_w32_result=""
1520 if test -n "$1"; then
1521 oldIFS=$IFS
1522 IFS=:
1523 for func_convert_core_path_wine_to_w32_f in $1; do
1524 IFS=$oldIFS
1525 func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f"
1526 if test -n "$func_convert_core_file_wine_to_w32_result" ; then
1527 if test -z "$func_convert_core_path_wine_to_w32_result"; then
1528 func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result"
1529 else
1530 func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result"
1531 fi
1532 fi
1533 done
1534 IFS=$oldIFS
1535 fi
1536}
1537# end: func_convert_core_path_wine_to_w32
1538
1539
1540# func_cygpath ARGS...
1541# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when
1542# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2)
1543# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or
1544# (2), returns the Cygwin file name or path in func_cygpath_result (input
1545# file name or path is assumed to be in w32 format, as previously converted
1546# from $build's *nix or MSYS format). In case (3), returns the w32 file name
1547# or path in func_cygpath_result (input file name or path is assumed to be in
1548# Cygwin format). Returns an empty string on error.
1549#
1550# ARGS are passed to cygpath, with the last one being the file name or path to
1551# be converted.
1552#
1553# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH
1554# environment variable; do not put it in $PATH.
1555func_cygpath ()
1556{
1557 $opt_debug
1558 if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then
1559 func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null`
1560 if test "$?" -ne 0; then
1561 # on failure, ensure result is empty
1562 func_cygpath_result=
1563 fi
1564 else
1565 func_cygpath_result=
1566 func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'"
1567 fi
1568}
1569#end: func_cygpath
1570
1571
1572# func_convert_core_msys_to_w32 ARG
1573# Convert file name or path ARG from MSYS format to w32 format. Return
1574# result in func_convert_core_msys_to_w32_result.
1575func_convert_core_msys_to_w32 ()
1576{
1577 $opt_debug
1578 # awkward: cmd appends spaces to result
1579 func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null |
1580 $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"`
1581}
1582#end: func_convert_core_msys_to_w32
1583
1584
1585# func_convert_file_check ARG1 ARG2
1586# Verify that ARG1 (a file name in $build format) was converted to $host
1587# format in ARG2. Otherwise, emit an error message, but continue (resetting
1588# func_to_host_file_result to ARG1).
1589func_convert_file_check ()
1590{
1591 $opt_debug
1592 if test -z "$2" && test -n "$1" ; then
1593 func_error "Could not determine host file name corresponding to"
1594 func_error " \`$1'"
1595 func_error "Continuing, but uninstalled executables may not work."
1596 # Fallback:
1597 func_to_host_file_result="$1"
1598 fi
1599}
1600# end func_convert_file_check
1601
1602
1603# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH
1604# Verify that FROM_PATH (a path in $build format) was converted to $host
1605# format in TO_PATH. Otherwise, emit an error message, but continue, resetting
1606# func_to_host_file_result to a simplistic fallback value (see below).
1607func_convert_path_check ()
1608{
1609 $opt_debug
1610 if test -z "$4" && test -n "$3"; then
1611 func_error "Could not determine the host path corresponding to"
1612 func_error " \`$3'"
1613 func_error "Continuing, but uninstalled executables may not work."
1614 # Fallback. This is a deliberately simplistic "conversion" and
1615 # should not be "improved". See libtool.info.
1616 if test "x$1" != "x$2"; then
1617 lt_replace_pathsep_chars="s|$1|$2|g"
1618 func_to_host_path_result=`echo "$3" |
1619 $SED -e "$lt_replace_pathsep_chars"`
1620 else
1621 func_to_host_path_result="$3"
1622 fi
1623 fi
1624}
1625# end func_convert_path_check
1626
1627
1628# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG
1629# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT
1630# and appending REPL if ORIG matches BACKPAT.
1631func_convert_path_front_back_pathsep ()
1632{
1633 $opt_debug
1634 case $4 in
1635 $1 ) func_to_host_path_result="$3$func_to_host_path_result"
1636 ;;
1637 esac
1638 case $4 in
1639 $2 ) func_append func_to_host_path_result "$3"
1640 ;;
1641 esac
1642}
1643# end func_convert_path_front_back_pathsep
1644
1645
1646##################################################
1647# $build to $host FILE NAME CONVERSION FUNCTIONS #
1648##################################################
1649# invoked via `$to_host_file_cmd ARG'
1650#
1651# In each case, ARG is the path to be converted from $build to $host format.
1652# Result will be available in $func_to_host_file_result.
1653
1654
1655# func_to_host_file ARG
1656# Converts the file name ARG from $build format to $host format. Return result
1657# in func_to_host_file_result.
1658func_to_host_file ()
1659{
1660 $opt_debug
1661 $to_host_file_cmd "$1"
1662}
1663# end func_to_host_file
1664
1665
1666# func_to_tool_file ARG LAZY
1667# converts the file name ARG from $build format to toolchain format. Return
1668# result in func_to_tool_file_result. If the conversion in use is listed
1669# in (the comma separated) LAZY, no conversion takes place.
1670func_to_tool_file ()
1671{
1672 $opt_debug
1673 case ,$2, in
1674 *,"$to_tool_file_cmd",*)
1675 func_to_tool_file_result=$1
1676 ;;
1677 *)
1678 $to_tool_file_cmd "$1"
1679 func_to_tool_file_result=$func_to_host_file_result
1680 ;;
1681 esac
1682}
1683# end func_to_tool_file
1684
1685
1686# func_convert_file_noop ARG
1687# Copy ARG to func_to_host_file_result.
1688func_convert_file_noop ()
1689{
1690 func_to_host_file_result="$1"
1691}
1692# end func_convert_file_noop
1693
1694
1695# func_convert_file_msys_to_w32 ARG
1696# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic
1697# conversion to w32 is not available inside the cwrapper. Returns result in
1698# func_to_host_file_result.
1699func_convert_file_msys_to_w32 ()
1700{
1701 $opt_debug
1702 func_to_host_file_result="$1"
1703 if test -n "$1"; then
1704 func_convert_core_msys_to_w32 "$1"
1705 func_to_host_file_result="$func_convert_core_msys_to_w32_result"
1706 fi
1707 func_convert_file_check "$1" "$func_to_host_file_result"
1708}
1709# end func_convert_file_msys_to_w32
1710
1711
1712# func_convert_file_cygwin_to_w32 ARG
1713# Convert file name ARG from Cygwin to w32 format. Returns result in
1714# func_to_host_file_result.
1715func_convert_file_cygwin_to_w32 ()
1716{
1717 $opt_debug
1718 func_to_host_file_result="$1"
1719 if test -n "$1"; then
1720 # because $build is cygwin, we call "the" cygpath in $PATH; no need to use
1721 # LT_CYGPATH in this case.
1722 func_to_host_file_result=`cygpath -m "$1"`
1723 fi
1724 func_convert_file_check "$1" "$func_to_host_file_result"
1725}
1726# end func_convert_file_cygwin_to_w32
1727
1728
1729# func_convert_file_nix_to_w32 ARG
1730# Convert file name ARG from *nix to w32 format. Requires a wine environment
1731# and a working winepath. Returns result in func_to_host_file_result.
1732func_convert_file_nix_to_w32 ()
1733{
1734 $opt_debug
1735 func_to_host_file_result="$1"
1736 if test -n "$1"; then
1737 func_convert_core_file_wine_to_w32 "$1"
1738 func_to_host_file_result="$func_convert_core_file_wine_to_w32_result"
1739 fi
1740 func_convert_file_check "$1" "$func_to_host_file_result"
1741}
1742# end func_convert_file_nix_to_w32
1743
1744
1745# func_convert_file_msys_to_cygwin ARG
1746# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set.
1747# Returns result in func_to_host_file_result.
1748func_convert_file_msys_to_cygwin ()
1749{
1750 $opt_debug
1751 func_to_host_file_result="$1"
1752 if test -n "$1"; then
1753 func_convert_core_msys_to_w32 "$1"
1754 func_cygpath -u "$func_convert_core_msys_to_w32_result"
1755 func_to_host_file_result="$func_cygpath_result"
1756 fi
1757 func_convert_file_check "$1" "$func_to_host_file_result"
1758}
1759# end func_convert_file_msys_to_cygwin
1760
1761
1762# func_convert_file_nix_to_cygwin ARG
1763# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed
1764# in a wine environment, working winepath, and LT_CYGPATH set. Returns result
1765# in func_to_host_file_result.
1766func_convert_file_nix_to_cygwin ()
1767{
1768 $opt_debug
1769 func_to_host_file_result="$1"
1770 if test -n "$1"; then
1771 # convert from *nix to w32, then use cygpath to convert from w32 to cygwin.
1772 func_convert_core_file_wine_to_w32 "$1"
1773 func_cygpath -u "$func_convert_core_file_wine_to_w32_result"
1774 func_to_host_file_result="$func_cygpath_result"
1775 fi
1776 func_convert_file_check "$1" "$func_to_host_file_result"
1777}
1778# end func_convert_file_nix_to_cygwin
1779
1780
1781#############################################
1782# $build to $host PATH CONVERSION FUNCTIONS #
1783#############################################
1784# invoked via `$to_host_path_cmd ARG'
1785#
1786# In each case, ARG is the path to be converted from $build to $host format.
1787# The result will be available in $func_to_host_path_result.
1788#
1789# Path separators are also converted from $build format to $host format. If
1790# ARG begins or ends with a path separator character, it is preserved (but
1791# converted to $host format) on output.
1792#
1793# All path conversion functions are named using the following convention:
1794# file name conversion function : func_convert_file_X_to_Y ()
1795# path conversion function : func_convert_path_X_to_Y ()
1796# where, for any given $build/$host combination the 'X_to_Y' value is the
1797# same. If conversion functions are added for new $build/$host combinations,
1798# the two new functions must follow this pattern, or func_init_to_host_path_cmd
1799# will break.
1800
1801
1802# func_init_to_host_path_cmd
1803# Ensures that function "pointer" variable $to_host_path_cmd is set to the
1804# appropriate value, based on the value of $to_host_file_cmd.
1805to_host_path_cmd=
1806func_init_to_host_path_cmd ()
1807{
1808 $opt_debug
1809 if test -z "$to_host_path_cmd"; then
1810 func_stripname 'func_convert_file_' '' "$to_host_file_cmd"
1811 to_host_path_cmd="func_convert_path_${func_stripname_result}"
1812 fi
1813}
1814
1815
1816# func_to_host_path ARG
1817# Converts the path ARG from $build format to $host format. Return result
1818# in func_to_host_path_result.
1819func_to_host_path ()
1820{
1821 $opt_debug
1822 func_init_to_host_path_cmd
1823 $to_host_path_cmd "$1"
1824}
1825# end func_to_host_path
1826
1827
1828# func_convert_path_noop ARG
1829# Copy ARG to func_to_host_path_result.
1830func_convert_path_noop ()
1831{
1832 func_to_host_path_result="$1"
1833}
1834# end func_convert_path_noop
1835
1836
1837# func_convert_path_msys_to_w32 ARG
1838# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic
1839# conversion to w32 is not available inside the cwrapper. Returns result in
1840# func_to_host_path_result.
1841func_convert_path_msys_to_w32 ()
1842{
1843 $opt_debug
1844 func_to_host_path_result="$1"
1845 if test -n "$1"; then
1846 # Remove leading and trailing path separator characters from ARG. MSYS
1847 # behavior is inconsistent here; cygpath turns them into '.;' and ';.';
1848 # and winepath ignores them completely.
1849 func_stripname : : "$1"
1850 func_to_host_path_tmp1=$func_stripname_result
1851 func_convert_core_msys_to_w32 "$func_to_host_path_tmp1"
1852 func_to_host_path_result="$func_convert_core_msys_to_w32_result"
1853 func_convert_path_check : ";" \
1854 "$func_to_host_path_tmp1" "$func_to_host_path_result"
1855 func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
1856 fi
1857}
1858# end func_convert_path_msys_to_w32
1859
1860
1861# func_convert_path_cygwin_to_w32 ARG
1862# Convert path ARG from Cygwin to w32 format. Returns result in
1863# func_to_host_file_result.
1864func_convert_path_cygwin_to_w32 ()
1865{
1866 $opt_debug
1867 func_to_host_path_result="$1"
1868 if test -n "$1"; then
1869 # See func_convert_path_msys_to_w32:
1870 func_stripname : : "$1"
1871 func_to_host_path_tmp1=$func_stripname_result
1872 func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"`
1873 func_convert_path_check : ";" \
1874 "$func_to_host_path_tmp1" "$func_to_host_path_result"
1875 func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
1876 fi
1877}
1878# end func_convert_path_cygwin_to_w32
1879
1880
1881# func_convert_path_nix_to_w32 ARG
1882# Convert path ARG from *nix to w32 format. Requires a wine environment and
1883# a working winepath. Returns result in func_to_host_file_result.
1884func_convert_path_nix_to_w32 ()
1885{
1886 $opt_debug
1887 func_to_host_path_result="$1"
1888 if test -n "$1"; then
1889 # See func_convert_path_msys_to_w32:
1890 func_stripname : : "$1"
1891 func_to_host_path_tmp1=$func_stripname_result
1892 func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1"
1893 func_to_host_path_result="$func_convert_core_path_wine_to_w32_result"
1894 func_convert_path_check : ";" \
1895 "$func_to_host_path_tmp1" "$func_to_host_path_result"
1896 func_convert_path_front_back_pathsep ":*" "*:" ";" "$1"
1897 fi
1898}
1899# end func_convert_path_nix_to_w32
1900
1901
1902# func_convert_path_msys_to_cygwin ARG
1903# Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set.
1904# Returns result in func_to_host_file_result.
1905func_convert_path_msys_to_cygwin ()
1906{
1907 $opt_debug
1908 func_to_host_path_result="$1"
1909 if test -n "$1"; then
1910 # See func_convert_path_msys_to_w32:
1911 func_stripname : : "$1"
1912 func_to_host_path_tmp1=$func_stripname_result
1913 func_convert_core_msys_to_w32 "$func_to_host_path_tmp1"
1914 func_cygpath -u -p "$func_convert_core_msys_to_w32_result"
1915 func_to_host_path_result="$func_cygpath_result"
1916 func_convert_path_check : : \
1917 "$func_to_host_path_tmp1" "$func_to_host_path_result"
1918 func_convert_path_front_back_pathsep ":*" "*:" : "$1"
1919 fi
1920}
1921# end func_convert_path_msys_to_cygwin
1922
1923
1924# func_convert_path_nix_to_cygwin ARG
1925# Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a
1926# a wine environment, working winepath, and LT_CYGPATH set. Returns result in
1927# func_to_host_file_result.
1928func_convert_path_nix_to_cygwin ()
1929{
1930 $opt_debug
1931 func_to_host_path_result="$1"
1932 if test -n "$1"; then
1933 # Remove leading and trailing path separator characters from
1934 # ARG. msys behavior is inconsistent here, cygpath turns them
1935 # into '.;' and ';.', and winepath ignores them completely.
1936 func_stripname : : "$1"
1937 func_to_host_path_tmp1=$func_stripname_result
1938 func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1"
1939 func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result"
1940 func_to_host_path_result="$func_cygpath_result"
1941 func_convert_path_check : : \
1942 "$func_to_host_path_tmp1" "$func_to_host_path_result"
1943 func_convert_path_front_back_pathsep ":*" "*:" : "$1"
1944 fi
1945}
1946# end func_convert_path_nix_to_cygwin
1947
1948
1949# func_mode_compile arg...
1950func_mode_compile ()
1951{
1952 $opt_debug
1953 # Get the compilation command and the source file.
1954 base_compile=
1955 srcfile="$nonopt" # always keep a non-empty value in "srcfile"
1956 suppress_opt=yes
1957 suppress_output=
1958 arg_mode=normal
1959 libobj=
1960 later=
1961 pie_flag=
1962
1963 for arg
1964 do
1965 case $arg_mode in
1966 arg )
1967 # do not "continue". Instead, add this to base_compile
1968 lastarg="$arg"
1969 arg_mode=normal
1970 ;;
1971
1972 target )
1973 libobj="$arg"
1974 arg_mode=normal
1975 continue
1976 ;;
1977
1978 normal )
1979 # Accept any command-line options.
1980 case $arg in
1981 -o)
1982 test -n "$libobj" && \
1983 func_fatal_error "you cannot specify \`-o' more than once"
1984 arg_mode=target
1985 continue
1986 ;;
1987
1988 -pie | -fpie | -fPIE)
1989 func_append pie_flag " $arg"
1990 continue
1991 ;;
1992
1993 -shared | -static | -prefer-pic | -prefer-non-pic)
1994 func_append later " $arg"
1995 continue
1996 ;;
1997
1998 -no-suppress)
1999 suppress_opt=no
2000 continue
2001 ;;
2002
2003 -Xcompiler)
2004 arg_mode=arg # the next one goes into the "base_compile" arg list
2005 continue # The current "srcfile" will either be retained or
2006 ;; # replaced later. I would guess that would be a bug.
2007
2008 -Wc,*)
2009 func_stripname '-Wc,' '' "$arg"
2010 args=$func_stripname_result
2011 lastarg=
2012 save_ifs="$IFS"; IFS=','
2013 for arg in $args; do
2014 IFS="$save_ifs"
2015 func_append_quoted lastarg "$arg"
2016 done
2017 IFS="$save_ifs"
2018 func_stripname ' ' '' "$lastarg"
2019 lastarg=$func_stripname_result
2020
2021 # Add the arguments to base_compile.
2022 func_append base_compile " $lastarg"
2023 continue
2024 ;;
2025
2026 *)
2027 # Accept the current argument as the source file.
2028 # The previous "srcfile" becomes the current argument.
2029 #
2030 lastarg="$srcfile"
2031 srcfile="$arg"
2032 ;;
2033 esac # case $arg
2034 ;;
2035 esac # case $arg_mode
2036
2037 # Aesthetically quote the previous argument.
2038 func_append_quoted base_compile "$lastarg"
2039 done # for arg
2040
2041 case $arg_mode in
2042 arg)
2043 func_fatal_error "you must specify an argument for -Xcompile"
2044 ;;
2045 target)
2046 func_fatal_error "you must specify a target with \`-o'"
2047 ;;
2048 *)
2049 # Get the name of the library object.
2050 test -z "$libobj" && {
2051 func_basename "$srcfile"
2052 libobj="$func_basename_result"
2053 }
2054 ;;
2055 esac
2056
2057 # Recognize several different file suffixes.
2058 # If the user specifies -o file.o, it is replaced with file.lo
2059 case $libobj in
2060 *.[cCFSifmso] | \
2061 *.ada | *.adb | *.ads | *.asm | \
2062 *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \
2063 *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup)
2064 func_xform "$libobj"
2065 libobj=$func_xform_result
2066 ;;
2067 esac
2068
2069 case $libobj in
2070 *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;;
2071 *)
2072 func_fatal_error "cannot determine name of library object from \`$libobj'"
2073 ;;
2074 esac
2075
2076 func_infer_tag $base_compile
2077
2078 for arg in $later; do
2079 case $arg in
2080 -shared)
2081 test "$build_libtool_libs" != yes && \
2082 func_fatal_configuration "can not build a shared library"
2083 build_old_libs=no
2084 continue
2085 ;;
2086
2087 -static)
2088 build_libtool_libs=no
2089 build_old_libs=yes
2090 continue
2091 ;;
2092
2093 -prefer-pic)
2094 pic_mode=yes
2095 continue
2096 ;;
2097
2098 -prefer-non-pic)
2099 pic_mode=no
2100 continue
2101 ;;
2102 esac
2103 done
2104
2105 func_quote_for_eval "$libobj"
2106 test "X$libobj" != "X$func_quote_for_eval_result" \
2107 && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \
2108 && func_warning "libobj name \`$libobj' may not contain shell special characters."
2109 func_dirname_and_basename "$obj" "/" ""
2110 objname="$func_basename_result"
2111 xdir="$func_dirname_result"
2112 lobj=${xdir}$objdir/$objname
2113
2114 test -z "$base_compile" && \
2115 func_fatal_help "you must specify a compilation command"
2116
2117 # Delete any leftover library objects.
2118 if test "$build_old_libs" = yes; then
2119 removelist="$obj $lobj $libobj ${libobj}T"
2120 else
2121 removelist="$lobj $libobj ${libobj}T"
2122 fi
2123
2124 # On Cygwin there's no "real" PIC flag so we must build both object types
2125 case $host_os in
2126 cygwin* | mingw* | pw32* | os2* | cegcc*)
2127 pic_mode=default
2128 ;;
2129 esac
2130 if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then
2131 # non-PIC code in shared libraries is not supported
2132 pic_mode=default
2133 fi
2134
2135 # Calculate the filename of the output object if compiler does
2136 # not support -o with -c
2137 if test "$compiler_c_o" = no; then
2138 output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.${objext}
2139 lockfile="$output_obj.lock"
2140 else
2141 output_obj=
2142 need_locks=no
2143 lockfile=
2144 fi
2145
2146 # Lock this critical section if it is needed
2147 # We use this script file to make the link, it avoids creating a new file
2148 if test "$need_locks" = yes; then
2149 until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do
2150 func_echo "Waiting for $lockfile to be removed"
2151 sleep 2
2152 done
2153 elif test "$need_locks" = warn; then
2154 if test -f "$lockfile"; then
2155 $ECHO "\
2156*** ERROR, $lockfile exists and contains:
2157`cat $lockfile 2>/dev/null`
2158
2159This indicates that another process is trying to use the same
2160temporary object file, and libtool could not work around it because
2161your compiler does not support \`-c' and \`-o' together. If you
2162repeat this compilation, it may succeed, by chance, but you had better
2163avoid parallel builds (make -j) in this platform, or get a better
2164compiler."
2165
2166 $opt_dry_run || $RM $removelist
2167 exit $EXIT_FAILURE
2168 fi
2169 func_append removelist " $output_obj"
2170 $ECHO "$srcfile" > "$lockfile"
2171 fi
2172
2173 $opt_dry_run || $RM $removelist
2174 func_append removelist " $lockfile"
2175 trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15
2176
2177 func_to_tool_file "$srcfile" func_convert_file_msys_to_w32
2178 srcfile=$func_to_tool_file_result
2179 func_quote_for_eval "$srcfile"
2180 qsrcfile=$func_quote_for_eval_result
2181
2182 # Only build a PIC object if we are building libtool libraries.
2183 if test "$build_libtool_libs" = yes; then
2184 # Without this assignment, base_compile gets emptied.
2185 fbsd_hideous_sh_bug=$base_compile
2186
2187 if test "$pic_mode" != no; then
2188 command="$base_compile $qsrcfile $pic_flag"
2189 else
2190 # Don't build PIC code
2191 command="$base_compile $qsrcfile"
2192 fi
2193
2194 func_mkdir_p "$xdir$objdir"
2195
2196 if test -z "$output_obj"; then
2197 # Place PIC objects in $objdir
2198 func_append command " -o $lobj"
2199 fi
2200
2201 func_show_eval_locale "$command" \
2202 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE'
2203
2204 if test "$need_locks" = warn &&
2205 test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then
2206 $ECHO "\
2207*** ERROR, $lockfile contains:
2208`cat $lockfile 2>/dev/null`
2209
2210but it should contain:
2211$srcfile
2212
2213This indicates that another process is trying to use the same
2214temporary object file, and libtool could not work around it because
2215your compiler does not support \`-c' and \`-o' together. If you
2216repeat this compilation, it may succeed, by chance, but you had better
2217avoid parallel builds (make -j) in this platform, or get a better
2218compiler."
2219
2220 $opt_dry_run || $RM $removelist
2221 exit $EXIT_FAILURE
2222 fi
2223
2224 # Just move the object if needed, then go on to compile the next one
2225 if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then
2226 func_show_eval '$MV "$output_obj" "$lobj"' \
2227 'error=$?; $opt_dry_run || $RM $removelist; exit $error'
2228 fi
2229
2230 # Allow error messages only from the first compilation.
2231 if test "$suppress_opt" = yes; then
2232 suppress_output=' >/dev/null 2>&1'
2233 fi
2234 fi
2235
2236 # Only build a position-dependent object if we build old libraries.
2237 if test "$build_old_libs" = yes; then
2238 if test "$pic_mode" != yes; then
2239 # Don't build PIC code
2240 command="$base_compile $qsrcfile$pie_flag"
2241 else
2242 command="$base_compile $qsrcfile $pic_flag"
2243 fi
2244 if test "$compiler_c_o" = yes; then
2245 func_append command " -o $obj"
2246 fi
2247
2248 # Suppress compiler output if we already did a PIC compilation.
2249 func_append command "$suppress_output"
2250 func_show_eval_locale "$command" \
2251 '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE'
2252
2253 if test "$need_locks" = warn &&
2254 test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then
2255 $ECHO "\
2256*** ERROR, $lockfile contains:
2257`cat $lockfile 2>/dev/null`
2258
2259but it should contain:
2260$srcfile
2261
2262This indicates that another process is trying to use the same
2263temporary object file, and libtool could not work around it because
2264your compiler does not support \`-c' and \`-o' together. If you
2265repeat this compilation, it may succeed, by chance, but you had better
2266avoid parallel builds (make -j) in this platform, or get a better
2267compiler."
2268
2269 $opt_dry_run || $RM $removelist
2270 exit $EXIT_FAILURE
2271 fi
2272
2273 # Just move the object if needed
2274 if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then
2275 func_show_eval '$MV "$output_obj" "$obj"' \
2276 'error=$?; $opt_dry_run || $RM $removelist; exit $error'
2277 fi
2278 fi
2279
2280 $opt_dry_run || {
2281 func_write_libtool_object "$libobj" "$objdir/$objname" "$objname"
2282
2283 # Unlock the critical section if it was locked
2284 if test "$need_locks" != no; then
2285 removelist=$lockfile
2286 $RM "$lockfile"
2287 fi
2288 }
2289
2290 exit $EXIT_SUCCESS
2291}
2292
2293$opt_help || {
2294 test "$opt_mode" = compile && func_mode_compile ${1+"$@"}
2295}
2296
2297func_mode_help ()
2298{
2299 # We need to display help for each of the modes.
2300 case $opt_mode in
2301 "")
2302 # Generic help is extracted from the usage comments
2303 # at the start of this file.
2304 func_help
2305 ;;
2306
2307 clean)
2308 $ECHO \
2309"Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE...
2310
2311Remove files from the build directory.
2312
2313RM is the name of the program to use to delete files associated with each FILE
2314(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed
2315to RM.
2316
2317If FILE is a libtool library, object or program, all the files associated
2318with it are deleted. Otherwise, only FILE itself is deleted using RM."
2319 ;;
2320
2321 compile)
2322 $ECHO \
2323"Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE
2324
2325Compile a source file into a libtool library object.
2326
2327This mode accepts the following additional options:
2328
2329 -o OUTPUT-FILE set the output file name to OUTPUT-FILE
2330 -no-suppress do not suppress compiler output for multiple passes
2331 -prefer-pic try to build PIC objects only
2332 -prefer-non-pic try to build non-PIC objects only
2333 -shared do not build a \`.o' file suitable for static linking
2334 -static only build a \`.o' file suitable for static linking
2335 -Wc,FLAG pass FLAG directly to the compiler
2336
2337COMPILE-COMMAND is a command to be used in creating a \`standard' object file
2338from the given SOURCEFILE.
2339
2340The output file name is determined by removing the directory component from
2341SOURCEFILE, then substituting the C source code suffix \`.c' with the
2342library object suffix, \`.lo'."
2343 ;;
2344
2345 execute)
2346 $ECHO \
2347"Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]...
2348
2349Automatically set library path, then run a program.
2350
2351This mode accepts the following additional options:
2352
2353 -dlopen FILE add the directory containing FILE to the library path
2354
2355This mode sets the library path environment variable according to \`-dlopen'
2356flags.
2357
2358If any of the ARGS are libtool executable wrappers, then they are translated
2359into their corresponding uninstalled binary, and any of their required library
2360directories are added to the library path.
2361
2362Then, COMMAND is executed, with ARGS as arguments."
2363 ;;
2364
2365 finish)
2366 $ECHO \
2367"Usage: $progname [OPTION]... --mode=finish [LIBDIR]...
2368
2369Complete the installation of libtool libraries.
2370
2371Each LIBDIR is a directory that contains libtool libraries.
2372
2373The commands that this mode executes may require superuser privileges. Use
2374the \`--dry-run' option if you just want to see what would be executed."
2375 ;;
2376
2377 install)
2378 $ECHO \
2379"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND...
2380
2381Install executables or libraries.
2382
2383INSTALL-COMMAND is the installation command. The first component should be
2384either the \`install' or \`cp' program.
2385
2386The following components of INSTALL-COMMAND are treated specially:
2387
2388 -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation
2389
2390The rest of the components are interpreted as arguments to that command (only
2391BSD-compatible install options are recognized)."
2392 ;;
2393
2394 link)
2395 $ECHO \
2396"Usage: $progname [OPTION]... --mode=link LINK-COMMAND...
2397
2398Link object files or libraries together to form another library, or to
2399create an executable program.
2400
2401LINK-COMMAND is a command using the C compiler that you would use to create
2402a program from several object files.
2403
2404The following components of LINK-COMMAND are treated specially:
2405
2406 -all-static do not do any dynamic linking at all
2407 -avoid-version do not add a version suffix if possible
2408 -bindir BINDIR specify path to binaries directory (for systems where
2409 libraries must be found in the PATH setting at runtime)
2410 -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime
2411 -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols
2412 -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3)
2413 -export-symbols SYMFILE
2414 try to export only the symbols listed in SYMFILE
2415 -export-symbols-regex REGEX
2416 try to export only the symbols matching REGEX
2417 -LLIBDIR search LIBDIR for required installed libraries
2418 -lNAME OUTPUT-FILE requires the installed library libNAME
2419 -module build a library that can dlopened
2420 -no-fast-install disable the fast-install mode
2421 -no-install link a not-installable executable
2422 -no-undefined declare that a library does not refer to external symbols
2423 -o OUTPUT-FILE create OUTPUT-FILE from the specified objects
2424 -objectlist FILE Use a list of object files found in FILE to specify objects
2425 -precious-files-regex REGEX
2426 don't remove output files matching REGEX
2427 -release RELEASE specify package release information
2428 -rpath LIBDIR the created library will eventually be installed in LIBDIR
2429 -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries
2430 -shared only do dynamic linking of libtool libraries
2431 -shrext SUFFIX override the standard shared library file extension
2432 -static do not do any dynamic linking of uninstalled libtool libraries
2433 -static-libtool-libs
2434 do not do any dynamic linking of libtool libraries
2435 -version-info CURRENT[:REVISION[:AGE]]
2436 specify library version info [each variable defaults to 0]
2437 -weak LIBNAME declare that the target provides the LIBNAME interface
2438 -Wc,FLAG
2439 -Xcompiler FLAG pass linker-specific FLAG directly to the compiler
2440 -Wl,FLAG
2441 -Xlinker FLAG pass linker-specific FLAG directly to the linker
2442 -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC)
2443
2444All other options (arguments beginning with \`-') are ignored.
2445
2446Every other argument is treated as a filename. Files ending in \`.la' are
2447treated as uninstalled libtool libraries, other files are standard or library
2448object files.
2449
2450If the OUTPUT-FILE ends in \`.la', then a libtool library is created,
2451only library objects (\`.lo' files) may be specified, and \`-rpath' is
2452required, except when creating a convenience library.
2453
2454If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created
2455using \`ar' and \`ranlib', or on Windows using \`lib'.
2456
2457If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file
2458is created, otherwise an executable program is created."
2459 ;;
2460
2461 uninstall)
2462 $ECHO \
2463"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE...
2464
2465Remove libraries from an installation directory.
2466
2467RM is the name of the program to use to delete files associated with each FILE
2468(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed
2469to RM.
2470
2471If FILE is a libtool library, all the files associated with it are deleted.
2472Otherwise, only FILE itself is deleted using RM."
2473 ;;
2474
2475 *)
2476 func_fatal_help "invalid operation mode \`$opt_mode'"
2477 ;;
2478 esac
2479
2480 echo
2481 $ECHO "Try \`$progname --help' for more information about other modes."
2482}
2483
2484# Now that we've collected a possible --mode arg, show help if necessary
2485if $opt_help; then
2486 if test "$opt_help" = :; then
2487 func_mode_help
2488 else
2489 {
2490 func_help noexit
2491 for opt_mode in compile link execute install finish uninstall clean; do
2492 func_mode_help
2493 done
2494 } | sed -n '1p; 2,$s/^Usage:/ or: /p'
2495 {
2496 func_help noexit
2497 for opt_mode in compile link execute install finish uninstall clean; do
2498 echo
2499 func_mode_help
2500 done
2501 } |
2502 sed '1d
2503 /^When reporting/,/^Report/{
2504 H
2505 d
2506 }
2507 $x
2508 /information about other modes/d
2509 /more detailed .*MODE/d
2510 s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/'
2511 fi
2512 exit $?
2513fi
2514
2515
2516# func_mode_execute arg...
2517func_mode_execute ()
2518{
2519 $opt_debug
2520 # The first argument is the command name.
2521 cmd="$nonopt"
2522 test -z "$cmd" && \
2523 func_fatal_help "you must specify a COMMAND"
2524
2525 # Handle -dlopen flags immediately.
2526 for file in $opt_dlopen; do
2527 test -f "$file" \
2528 || func_fatal_help "\`$file' is not a file"
2529
2530 dir=
2531 case $file in
2532 *.la)
2533 func_resolve_sysroot "$file"
2534 file=$func_resolve_sysroot_result
2535
2536 # Check to see that this really is a libtool archive.
2537 func_lalib_unsafe_p "$file" \
2538 || func_fatal_help "\`$lib' is not a valid libtool archive"
2539
2540 # Read the libtool library.
2541 dlname=
2542 library_names=
2543 func_source "$file"
2544
2545 # Skip this library if it cannot be dlopened.
2546 if test -z "$dlname"; then
2547 # Warn if it was a shared library.
2548 test -n "$library_names" && \
2549 func_warning "\`$file' was not linked with \`-export-dynamic'"
2550 continue
2551 fi
2552
2553 func_dirname "$file" "" "."
2554 dir="$func_dirname_result"
2555
2556 if test -f "$dir/$objdir/$dlname"; then
2557 func_append dir "/$objdir"
2558 else
2559 if test ! -f "$dir/$dlname"; then
2560 func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'"
2561 fi
2562 fi
2563 ;;
2564
2565 *.lo)
2566 # Just add the directory containing the .lo file.
2567 func_dirname "$file" "" "."
2568 dir="$func_dirname_result"
2569 ;;
2570
2571 *)
2572 func_warning "\`-dlopen' is ignored for non-libtool libraries and objects"
2573 continue
2574 ;;
2575 esac
2576
2577 # Get the absolute pathname.
2578 absdir=`cd "$dir" && pwd`
2579 test -n "$absdir" && dir="$absdir"
2580
2581 # Now add the directory to shlibpath_var.
2582 if eval "test -z \"\$$shlibpath_var\""; then
2583 eval "$shlibpath_var=\"\$dir\""
2584 else
2585 eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\""
2586 fi
2587 done
2588
2589 # This variable tells wrapper scripts just to set shlibpath_var
2590 # rather than running their programs.
2591 libtool_execute_magic="$magic"
2592
2593 # Check if any of the arguments is a wrapper script.
2594 args=
2595 for file
2596 do
2597 case $file in
2598 -* | *.la | *.lo ) ;;
2599 *)
2600 # Do a test to see if this is really a libtool program.
2601 if func_ltwrapper_script_p "$file"; then
2602 func_source "$file"
2603 # Transform arg to wrapped name.
2604 file="$progdir/$program"
2605 elif func_ltwrapper_executable_p "$file"; then
2606 func_ltwrapper_scriptname "$file"
2607 func_source "$func_ltwrapper_scriptname_result"
2608 # Transform arg to wrapped name.
2609 file="$progdir/$program"
2610 fi
2611 ;;
2612 esac
2613 # Quote arguments (to preserve shell metacharacters).
2614 func_append_quoted args "$file"
2615 done
2616
2617 if test "X$opt_dry_run" = Xfalse; then
2618 if test -n "$shlibpath_var"; then
2619 # Export the shlibpath_var.
2620 eval "export $shlibpath_var"
2621 fi
2622
2623 # Restore saved environment variables
2624 for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
2625 do
2626 eval "if test \"\${save_$lt_var+set}\" = set; then
2627 $lt_var=\$save_$lt_var; export $lt_var
2628 else
2629 $lt_unset $lt_var
2630 fi"
2631 done
2632
2633 # Now prepare to actually exec the command.
2634 exec_cmd="\$cmd$args"
2635 else
2636 # Display what would be done.
2637 if test -n "$shlibpath_var"; then
2638 eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\""
2639 echo "export $shlibpath_var"
2640 fi
2641 $ECHO "$cmd$args"
2642 exit $EXIT_SUCCESS
2643 fi
2644}
2645
2646test "$opt_mode" = execute && func_mode_execute ${1+"$@"}
2647
2648
2649# func_mode_finish arg...
2650func_mode_finish ()
2651{
2652 $opt_debug
2653 libs=
2654 libdirs=
2655 admincmds=
2656
2657 for opt in "$nonopt" ${1+"$@"}
2658 do
2659 if test -d "$opt"; then
2660 func_append libdirs " $opt"
2661
2662 elif test -f "$opt"; then
2663 if func_lalib_unsafe_p "$opt"; then
2664 func_append libs " $opt"
2665 else
2666 func_warning "\`$opt' is not a valid libtool archive"
2667 fi
2668
2669 else
2670 func_fatal_error "invalid argument \`$opt'"
2671 fi
2672 done
2673
2674 if test -n "$libs"; then
2675 if test -n "$lt_sysroot"; then
2676 sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"`
2677 sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;"
2678 else
2679 sysroot_cmd=
2680 fi
2681
2682 # Remove sysroot references
2683 if $opt_dry_run; then
2684 for lib in $libs; do
2685 echo "removing references to $lt_sysroot and \`=' prefixes from $lib"
2686 done
2687 else
2688 tmpdir=`func_mktempdir`
2689 for lib in $libs; do
2690 sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \
2691 > $tmpdir/tmp-la
2692 mv -f $tmpdir/tmp-la $lib
2693 done
2694 ${RM}r "$tmpdir"
2695 fi
2696 fi
2697
2698 if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
2699 for libdir in $libdirs; do
2700 if test -n "$finish_cmds"; then
2701 # Do each command in the finish commands.
2702 func_execute_cmds "$finish_cmds" 'admincmds="$admincmds
2703'"$cmd"'"'
2704 fi
2705 if test -n "$finish_eval"; then
2706 # Do the single finish_eval.
2707 eval cmds=\"$finish_eval\"
2708 $opt_dry_run || eval "$cmds" || func_append admincmds "
2709 $cmds"
2710 fi
2711 done
2712 fi
2713
2714 # Exit here if they wanted silent mode.
2715 $opt_silent && exit $EXIT_SUCCESS
2716
2717 if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
2718 echo "----------------------------------------------------------------------"
2719 echo "Libraries have been installed in:"
2720 for libdir in $libdirs; do
2721 $ECHO " $libdir"
2722 done
2723 echo
2724 echo "If you ever happen to want to link against installed libraries"
2725 echo "in a given directory, LIBDIR, you must either use libtool, and"
2726 echo "specify the full pathname of the library, or use the \`-LLIBDIR'"
2727 echo "flag during linking and do at least one of the following:"
2728 if test -n "$shlibpath_var"; then
2729 echo " - add LIBDIR to the \`$shlibpath_var' environment variable"
2730 echo " during execution"
2731 fi
2732 if test -n "$runpath_var"; then
2733 echo " - add LIBDIR to the \`$runpath_var' environment variable"
2734 echo " during linking"
2735 fi
2736 if test -n "$hardcode_libdir_flag_spec"; then
2737 libdir=LIBDIR
2738 eval flag=\"$hardcode_libdir_flag_spec\"
2739
2740 $ECHO " - use the \`$flag' linker flag"
2741 fi
2742 if test -n "$admincmds"; then
2743 $ECHO " - have your system administrator run these commands:$admincmds"
2744 fi
2745 if test -f /etc/ld.so.conf; then
2746 echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
2747 fi
2748 echo
2749
2750 echo "See any operating system documentation about shared libraries for"
2751 case $host in
2752 solaris2.[6789]|solaris2.1[0-9])
2753 echo "more information, such as the ld(1), crle(1) and ld.so(8) manual"
2754 echo "pages."
2755 ;;
2756 *)
2757 echo "more information, such as the ld(1) and ld.so(8) manual pages."
2758 ;;
2759 esac
2760 echo "----------------------------------------------------------------------"
2761 fi
2762 exit $EXIT_SUCCESS
2763}
2764
2765test "$opt_mode" = finish && func_mode_finish ${1+"$@"}
2766
2767
2768# func_mode_install arg...
2769func_mode_install ()
2770{
2771 $opt_debug
2772 # There may be an optional sh(1) argument at the beginning of
2773 # install_prog (especially on Windows NT).
2774 if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh ||
2775 # Allow the use of GNU shtool's install command.
2776 case $nonopt in *shtool*) :;; *) false;; esac; then
2777 # Aesthetically quote it.
2778 func_quote_for_eval "$nonopt"
2779 install_prog="$func_quote_for_eval_result "
2780 arg=$1
2781 shift
2782 else
2783 install_prog=
2784 arg=$nonopt
2785 fi
2786
2787 # The real first argument should be the name of the installation program.
2788 # Aesthetically quote it.
2789 func_quote_for_eval "$arg"
2790 func_append install_prog "$func_quote_for_eval_result"
2791 install_shared_prog=$install_prog
2792 case " $install_prog " in
2793 *[\\\ /]cp\ *) install_cp=: ;;
2794 *) install_cp=false ;;
2795 esac
2796
2797 # We need to accept at least all the BSD install flags.
2798 dest=
2799 files=
2800 opts=
2801 prev=
2802 install_type=
2803 isdir=no
2804 stripme=
2805 no_mode=:
2806 for arg
2807 do
2808 arg2=
2809 if test -n "$dest"; then
2810 func_append files " $dest"
2811 dest=$arg
2812 continue
2813 fi
2814
2815 case $arg in
2816 -d) isdir=yes ;;
2817 -f)
2818 if $install_cp; then :; else
2819 prev=$arg
2820 fi
2821 ;;
2822 -g | -m | -o)
2823 prev=$arg
2824 ;;
2825 -s)
2826 stripme=" -s"
2827 continue
2828 ;;
2829 -*)
2830 ;;
2831 *)
2832 # If the previous option needed an argument, then skip it.
2833 if test -n "$prev"; then
2834 if test "x$prev" = x-m && test -n "$install_override_mode"; then
2835 arg2=$install_override_mode
2836 no_mode=false
2837 fi
2838 prev=
2839 else
2840 dest=$arg
2841 continue
2842 fi
2843 ;;
2844 esac
2845
2846 # Aesthetically quote the argument.
2847 func_quote_for_eval "$arg"
2848 func_append install_prog " $func_quote_for_eval_result"
2849 if test -n "$arg2"; then
2850 func_quote_for_eval "$arg2"
2851 fi
2852 func_append install_shared_prog " $func_quote_for_eval_result"
2853 done
2854
2855 test -z "$install_prog" && \
2856 func_fatal_help "you must specify an install program"
2857
2858 test -n "$prev" && \
2859 func_fatal_help "the \`$prev' option requires an argument"
2860
2861 if test -n "$install_override_mode" && $no_mode; then
2862 if $install_cp; then :; else
2863 func_quote_for_eval "$install_override_mode"
2864 func_append install_shared_prog " -m $func_quote_for_eval_result"
2865 fi
2866 fi
2867
2868 if test -z "$files"; then
2869 if test -z "$dest"; then
2870 func_fatal_help "no file or destination specified"
2871 else
2872 func_fatal_help "you must specify a destination"
2873 fi
2874 fi
2875
2876 # Strip any trailing slash from the destination.
2877 func_stripname '' '/' "$dest"
2878 dest=$func_stripname_result
2879
2880 # Check to see that the destination is a directory.
2881 test -d "$dest" && isdir=yes
2882 if test "$isdir" = yes; then
2883 destdir="$dest"
2884 destname=
2885 else
2886 func_dirname_and_basename "$dest" "" "."
2887 destdir="$func_dirname_result"
2888 destname="$func_basename_result"
2889
2890 # Not a directory, so check to see that there is only one file specified.
2891 set dummy $files; shift
2892 test "$#" -gt 1 && \
2893 func_fatal_help "\`$dest' is not a directory"
2894 fi
2895 case $destdir in
2896 [\\/]* | [A-Za-z]:[\\/]*) ;;
2897 *)
2898 for file in $files; do
2899 case $file in
2900 *.lo) ;;
2901 *)
2902 func_fatal_help "\`$destdir' must be an absolute directory name"
2903 ;;
2904 esac
2905 done
2906 ;;
2907 esac
2908
2909 # This variable tells wrapper scripts just to set variables rather
2910 # than running their programs.
2911 libtool_install_magic="$magic"
2912
2913 staticlibs=
2914 future_libdirs=
2915 current_libdirs=
2916 for file in $files; do
2917
2918 # Do each installation.
2919 case $file in
2920 *.$libext)
2921 # Do the static libraries later.
2922 func_append staticlibs " $file"
2923 ;;
2924
2925 *.la)
2926 func_resolve_sysroot "$file"
2927 file=$func_resolve_sysroot_result
2928
2929 # Check to see that this really is a libtool archive.
2930 func_lalib_unsafe_p "$file" \
2931 || func_fatal_help "\`$file' is not a valid libtool archive"
2932
2933 library_names=
2934 old_library=
2935 relink_command=
2936 func_source "$file"
2937
2938 # Add the libdir to current_libdirs if it is the destination.
2939 if test "X$destdir" = "X$libdir"; then
2940 case "$current_libdirs " in
2941 *" $libdir "*) ;;
2942 *) func_append current_libdirs " $libdir" ;;
2943 esac
2944 else
2945 # Note the libdir as a future libdir.
2946 case "$future_libdirs " in
2947 *" $libdir "*) ;;
2948 *) func_append future_libdirs " $libdir" ;;
2949 esac
2950 fi
2951
2952 func_dirname "$file" "/" ""
2953 dir="$func_dirname_result"
2954 func_append dir "$objdir"
2955
2956 if test -n "$relink_command"; then
2957 # Determine the prefix the user has applied to our future dir.
2958 inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"`
2959
2960 # Don't allow the user to place us outside of our expected
2961 # location b/c this prevents finding dependent libraries that
2962 # are installed to the same prefix.
2963 # At present, this check doesn't affect windows .dll's that
2964 # are installed into $libdir/../bin (currently, that works fine)
2965 # but it's something to keep an eye on.
2966 test "$inst_prefix_dir" = "$destdir" && \
2967 func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir"
2968
2969 if test -n "$inst_prefix_dir"; then
2970 # Stick the inst_prefix_dir data into the link command.
2971 relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"`
2972 else
2973 relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"`
2974 fi
2975
2976 func_warning "relinking \`$file'"
2977 func_show_eval "$relink_command" \
2978 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"'
2979 fi
2980
2981 # See the names of the shared library.
2982 set dummy $library_names; shift
2983 if test -n "$1"; then
2984 realname="$1"
2985 shift
2986
2987 srcname="$realname"
2988 test -n "$relink_command" && srcname="$realname"T
2989
2990 # Install the shared library and build the symlinks.
2991 func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \
2992 'exit $?'
2993 tstripme="$stripme"
2994 case $host_os in
2995 cygwin* | mingw* | pw32* | cegcc*)
2996 case $realname in
2997 *.dll.a)
2998 tstripme=""
2999 ;;
3000 esac
3001 ;;
3002 esac
3003 if test -n "$tstripme" && test -n "$striplib"; then
3004 func_show_eval "$striplib $destdir/$realname" 'exit $?'
3005 fi
3006
3007 if test "$#" -gt 0; then
3008 # Delete the old symlinks, and create new ones.
3009 # Try `ln -sf' first, because the `ln' binary might depend on
3010 # the symlink we replace! Solaris /bin/ln does not understand -f,
3011 # so we also need to try rm && ln -s.
3012 for linkname
3013 do
3014 test "$linkname" != "$realname" \
3015 && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })"
3016 done
3017 fi
3018
3019 # Do each command in the postinstall commands.
3020 lib="$destdir/$realname"
3021 func_execute_cmds "$postinstall_cmds" 'exit $?'
3022 fi
3023
3024 # Install the pseudo-library for information purposes.
3025 func_basename "$file"
3026 name="$func_basename_result"
3027 instname="$dir/$name"i
3028 func_show_eval "$install_prog $instname $destdir/$name" 'exit $?'
3029
3030 # Maybe install the static library, too.
3031 test -n "$old_library" && func_append staticlibs " $dir/$old_library"
3032 ;;
3033
3034 *.lo)
3035 # Install (i.e. copy) a libtool object.
3036
3037 # Figure out destination file name, if it wasn't already specified.
3038 if test -n "$destname"; then
3039 destfile="$destdir/$destname"
3040 else
3041 func_basename "$file"
3042 destfile="$func_basename_result"
3043 destfile="$destdir/$destfile"
3044 fi
3045
3046 # Deduce the name of the destination old-style object file.
3047 case $destfile in
3048 *.lo)
3049 func_lo2o "$destfile"
3050 staticdest=$func_lo2o_result
3051 ;;
3052 *.$objext)
3053 staticdest="$destfile"
3054 destfile=
3055 ;;
3056 *)
3057 func_fatal_help "cannot copy a libtool object to \`$destfile'"
3058 ;;
3059 esac
3060
3061 # Install the libtool object if requested.
3062 test -n "$destfile" && \
3063 func_show_eval "$install_prog $file $destfile" 'exit $?'
3064
3065 # Install the old object if enabled.
3066 if test "$build_old_libs" = yes; then
3067 # Deduce the name of the old-style object file.
3068 func_lo2o "$file"
3069 staticobj=$func_lo2o_result
3070 func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?'
3071 fi
3072 exit $EXIT_SUCCESS
3073 ;;
3074
3075 *)
3076 # Figure out destination file name, if it wasn't already specified.
3077 if test -n "$destname"; then
3078 destfile="$destdir/$destname"
3079 else
3080 func_basename "$file"
3081 destfile="$func_basename_result"
3082 destfile="$destdir/$destfile"
3083 fi
3084
3085 # If the file is missing, and there is a .exe on the end, strip it
3086 # because it is most likely a libtool script we actually want to
3087 # install
3088 stripped_ext=""
3089 case $file in
3090 *.exe)
3091 if test ! -f "$file"; then
3092 func_stripname '' '.exe' "$file"
3093 file=$func_stripname_result
3094 stripped_ext=".exe"
3095 fi
3096 ;;
3097 esac
3098
3099 # Do a test to see if this is really a libtool program.
3100 case $host in
3101 *cygwin* | *mingw*)
3102 if func_ltwrapper_executable_p "$file"; then
3103 func_ltwrapper_scriptname "$file"
3104 wrapper=$func_ltwrapper_scriptname_result
3105 else
3106 func_stripname '' '.exe' "$file"
3107 wrapper=$func_stripname_result
3108 fi
3109 ;;
3110 *)
3111 wrapper=$file
3112 ;;
3113 esac
3114 if func_ltwrapper_script_p "$wrapper"; then
3115 notinst_deplibs=
3116 relink_command=
3117
3118 func_source "$wrapper"
3119
3120 # Check the variables that should have been set.
3121 test -z "$generated_by_libtool_version" && \
3122 func_fatal_error "invalid libtool wrapper script \`$wrapper'"
3123
3124 finalize=yes
3125 for lib in $notinst_deplibs; do
3126 # Check to see that each library is installed.
3127 libdir=
3128 if test -f "$lib"; then
3129 func_source "$lib"
3130 fi
3131 libfile="$libdir/"`$ECHO "$lib" | $SED 's%^.*/%%g'` ### testsuite: skip nested quoting test
3132 if test -n "$libdir" && test ! -f "$libfile"; then
3133 func_warning "\`$lib' has not been installed in \`$libdir'"
3134 finalize=no
3135 fi
3136 done
3137
3138 relink_command=
3139 func_source "$wrapper"
3140
3141 outputname=
3142 if test "$fast_install" = no && test -n "$relink_command"; then
3143 $opt_dry_run || {
3144 if test "$finalize" = yes; then
3145 tmpdir=`func_mktempdir`
3146 func_basename "$file$stripped_ext"
3147 file="$func_basename_result"
3148 outputname="$tmpdir/$file"
3149 # Replace the output file specification.
3150 relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'`
3151
3152 $opt_silent || {
3153 func_quote_for_expand "$relink_command"
3154 eval "func_echo $func_quote_for_expand_result"
3155 }
3156 if eval "$relink_command"; then :
3157 else
3158 func_error "error: relink \`$file' with the above command before installing it"
3159 $opt_dry_run || ${RM}r "$tmpdir"
3160 continue
3161 fi
3162 file="$outputname"
3163 else
3164 func_warning "cannot relink \`$file'"
3165 fi
3166 }
3167 else
3168 # Install the binary that we compiled earlier.
3169 file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"`
3170 fi
3171 fi
3172
3173 # remove .exe since cygwin /usr/bin/install will append another
3174 # one anyway
3175 case $install_prog,$host in
3176 */usr/bin/install*,*cygwin*)
3177 case $file:$destfile in
3178 *.exe:*.exe)
3179 # this is ok
3180 ;;
3181 *.exe:*)
3182 destfile=$destfile.exe
3183 ;;
3184 *:*.exe)
3185 func_stripname '' '.exe' "$destfile"
3186 destfile=$func_stripname_result
3187 ;;
3188 esac
3189 ;;
3190 esac
3191 func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?'
3192 $opt_dry_run || if test -n "$outputname"; then
3193 ${RM}r "$tmpdir"
3194 fi
3195 ;;
3196 esac
3197 done
3198
3199 for file in $staticlibs; do
3200 func_basename "$file"
3201 name="$func_basename_result"
3202
3203 # Set up the ranlib parameters.
3204 oldlib="$destdir/$name"
3205 func_to_tool_file "$oldlib" func_convert_file_msys_to_w32
3206 tool_oldlib=$func_to_tool_file_result
3207
3208 func_show_eval "$install_prog \$file \$oldlib" 'exit $?'
3209
3210 if test -n "$stripme" && test -n "$old_striplib"; then
3211 func_show_eval "$old_striplib $tool_oldlib" 'exit $?'
3212 fi
3213
3214 # Do each command in the postinstall commands.
3215 func_execute_cmds "$old_postinstall_cmds" 'exit $?'
3216 done
3217
3218 test -n "$future_libdirs" && \
3219 func_warning "remember to run \`$progname --finish$future_libdirs'"
3220
3221 if test -n "$current_libdirs"; then
3222 # Maybe just do a dry run.
3223 $opt_dry_run && current_libdirs=" -n$current_libdirs"
3224 exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs'
3225 else
3226 exit $EXIT_SUCCESS
3227 fi
3228}
3229
3230test "$opt_mode" = install && func_mode_install ${1+"$@"}
3231
3232
3233# func_generate_dlsyms outputname originator pic_p
3234# Extract symbols from dlprefiles and create ${outputname}S.o with
3235# a dlpreopen symbol table.
3236func_generate_dlsyms ()
3237{
3238 $opt_debug
3239 my_outputname="$1"
3240 my_originator="$2"
3241 my_pic_p="${3-no}"
3242 my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'`
3243 my_dlsyms=
3244
3245 if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
3246 if test -n "$NM" && test -n "$global_symbol_pipe"; then
3247 my_dlsyms="${my_outputname}S.c"
3248 else
3249 func_error "not configured to extract global symbols from dlpreopened files"
3250 fi
3251 fi
3252
3253 if test -n "$my_dlsyms"; then
3254 case $my_dlsyms in
3255 "") ;;
3256 *.c)
3257 # Discover the nlist of each of the dlfiles.
3258 nlist="$output_objdir/${my_outputname}.nm"
3259
3260 func_show_eval "$RM $nlist ${nlist}S ${nlist}T"
3261
3262 # Parse the name list into a source file.
3263 func_verbose "creating $output_objdir/$my_dlsyms"
3264
3265 $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\
3266/* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */
3267/* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */
3268
3269#ifdef __cplusplus
3270extern \"C\" {
3271#endif
3272
3273#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4))
3274#pragma GCC diagnostic ignored \"-Wstrict-prototypes\"
3275#endif
3276
3277/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
3278#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
3279/* DATA imports from DLLs on WIN32 con't be const, because runtime
3280 relocations are performed -- see ld's documentation on pseudo-relocs. */
3281# define LT_DLSYM_CONST
3282#elif defined(__osf__)
3283/* This system does not cope well with relocations in const data. */
3284# define LT_DLSYM_CONST
3285#else
3286# define LT_DLSYM_CONST const
3287#endif
3288
3289/* External symbol declarations for the compiler. */\
3290"
3291
3292 if test "$dlself" = yes; then
3293 func_verbose "generating symbol list for \`$output'"
3294
3295 $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist"
3296
3297 # Add our own program objects to the symbol list.
3298 progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP`
3299 for progfile in $progfiles; do
3300 func_to_tool_file "$progfile" func_convert_file_msys_to_w32
3301 func_verbose "extracting global C symbols from \`$func_to_tool_file_result'"
3302 $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'"
3303 done
3304
3305 if test -n "$exclude_expsyms"; then
3306 $opt_dry_run || {
3307 eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T'
3308 eval '$MV "$nlist"T "$nlist"'
3309 }
3310 fi
3311
3312 if test -n "$export_symbols_regex"; then
3313 $opt_dry_run || {
3314 eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T'
3315 eval '$MV "$nlist"T "$nlist"'
3316 }
3317 fi
3318
3319 # Prepare the list of exported symbols
3320 if test -z "$export_symbols"; then
3321 export_symbols="$output_objdir/$outputname.exp"
3322 $opt_dry_run || {
3323 $RM $export_symbols
3324 eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"'
3325 case $host in
3326 *cygwin* | *mingw* | *cegcc* )
3327 eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
3328 eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"'
3329 ;;
3330 esac
3331 }
3332 else
3333 $opt_dry_run || {
3334 eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"'
3335 eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T'
3336 eval '$MV "$nlist"T "$nlist"'
3337 case $host in
3338 *cygwin* | *mingw* | *cegcc* )
3339 eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
3340 eval 'cat "$nlist" >> "$output_objdir/$outputname.def"'
3341 ;;
3342 esac
3343 }
3344 fi
3345 fi
3346
3347 for dlprefile in $dlprefiles; do
3348 func_verbose "extracting global C symbols from \`$dlprefile'"
3349 func_basename "$dlprefile"
3350 name="$func_basename_result"
3351 case $host in
3352 *cygwin* | *mingw* | *cegcc* )
3353 # if an import library, we need to obtain dlname
3354 if func_win32_import_lib_p "$dlprefile"; then
3355 func_tr_sh "$dlprefile"
3356 eval "curr_lafile=\$libfile_$func_tr_sh_result"
3357 dlprefile_dlbasename=""
3358 if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then
3359 # Use subshell, to avoid clobbering current variable values
3360 dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"`
3361 if test -n "$dlprefile_dlname" ; then
3362 func_basename "$dlprefile_dlname"
3363 dlprefile_dlbasename="$func_basename_result"
3364 else
3365 # no lafile. user explicitly requested -dlpreopen <import library>.
3366 $sharedlib_from_linklib_cmd "$dlprefile"
3367 dlprefile_dlbasename=$sharedlib_from_linklib_result
3368 fi
3369 fi
3370 $opt_dry_run || {
3371 if test -n "$dlprefile_dlbasename" ; then
3372 eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"'
3373 else
3374 func_warning "Could not compute DLL name from $name"
3375 eval '$ECHO ": $name " >> "$nlist"'
3376 fi
3377 func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
3378 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe |
3379 $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'"
3380 }
3381 else # not an import lib
3382 $opt_dry_run || {
3383 eval '$ECHO ": $name " >> "$nlist"'
3384 func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
3385 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'"
3386 }
3387 fi
3388 ;;
3389 *)
3390 $opt_dry_run || {
3391 eval '$ECHO ": $name " >> "$nlist"'
3392 func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32
3393 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'"
3394 }
3395 ;;
3396 esac
3397 done
3398
3399 $opt_dry_run || {
3400 # Make sure we have at least an empty file.
3401 test -f "$nlist" || : > "$nlist"
3402
3403 if test -n "$exclude_expsyms"; then
3404 $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T
3405 $MV "$nlist"T "$nlist"
3406 fi
3407
3408 # Try sorting and uniquifying the output.
3409 if $GREP -v "^: " < "$nlist" |
3410 if sort -k 3 </dev/null >/dev/null 2>&1; then
3411 sort -k 3
3412 else
3413 sort +2
3414 fi |
3415 uniq > "$nlist"S; then
3416 :
3417 else
3418 $GREP -v "^: " < "$nlist" > "$nlist"S
3419 fi
3420
3421 if test -f "$nlist"S; then
3422 eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"'
3423 else
3424 echo '/* NONE */' >> "$output_objdir/$my_dlsyms"
3425 fi
3426
3427 echo >> "$output_objdir/$my_dlsyms" "\
3428
3429/* The mapping between symbol names and symbols. */
3430typedef struct {
3431 const char *name;
3432 void *address;
3433} lt_dlsymlist;
3434extern LT_DLSYM_CONST lt_dlsymlist
3435lt_${my_prefix}_LTX_preloaded_symbols[];
3436LT_DLSYM_CONST lt_dlsymlist
3437lt_${my_prefix}_LTX_preloaded_symbols[] =
3438{\
3439 { \"$my_originator\", (void *) 0 },"
3440
3441 case $need_lib_prefix in
3442 no)
3443 eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms"
3444 ;;
3445 *)
3446 eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms"
3447 ;;
3448 esac
3449 echo >> "$output_objdir/$my_dlsyms" "\
3450 {0, (void *) 0}
3451};
3452
3453/* This works around a problem in FreeBSD linker */
3454#ifdef FREEBSD_WORKAROUND
3455static const void *lt_preloaded_setup() {
3456 return lt_${my_prefix}_LTX_preloaded_symbols;
3457}
3458#endif
3459
3460#ifdef __cplusplus
3461}
3462#endif\
3463"
3464 } # !$opt_dry_run
3465
3466 pic_flag_for_symtable=
3467 case "$compile_command " in
3468 *" -static "*) ;;
3469 *)
3470 case $host in
3471 # compiling the symbol table file with pic_flag works around
3472 # a FreeBSD bug that causes programs to crash when -lm is
3473 # linked before any other PIC object. But we must not use
3474 # pic_flag when linking with -static. The problem exists in
3475 # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1.
3476 *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*)
3477 pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;;
3478 *-*-hpux*)
3479 pic_flag_for_symtable=" $pic_flag" ;;
3480 *)
3481 if test "X$my_pic_p" != Xno; then
3482 pic_flag_for_symtable=" $pic_flag"
3483 fi
3484 ;;
3485 esac
3486 ;;
3487 esac
3488 symtab_cflags=
3489 for arg in $LTCFLAGS; do
3490 case $arg in
3491 -pie | -fpie | -fPIE) ;;
3492 *) func_append symtab_cflags " $arg" ;;
3493 esac
3494 done
3495
3496 # Now compile the dynamic symbol file.
3497 func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?'
3498
3499 # Clean up the generated files.
3500 func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"'
3501
3502 # Transform the symbol file into the correct name.
3503 symfileobj="$output_objdir/${my_outputname}S.$objext"
3504 case $host in
3505 *cygwin* | *mingw* | *cegcc* )
3506 if test -f "$output_objdir/$my_outputname.def"; then
3507 compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
3508 finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
3509 else
3510 compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"`
3511 finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"`
3512 fi
3513 ;;
3514 *)
3515 compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"`
3516 finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"`
3517 ;;
3518 esac
3519 ;;
3520 *)
3521 func_fatal_error "unknown suffix for \`$my_dlsyms'"
3522 ;;
3523 esac
3524 else
3525 # We keep going just in case the user didn't refer to
3526 # lt_preloaded_symbols. The linker will fail if global_symbol_pipe
3527 # really was required.
3528
3529 # Nullify the symbol file.
3530 compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"`
3531 finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"`
3532 fi
3533}
3534
3535# func_win32_libid arg
3536# return the library type of file 'arg'
3537#
3538# Need a lot of goo to handle *both* DLLs and import libs
3539# Has to be a shell function in order to 'eat' the argument
3540# that is supplied when $file_magic_command is called.
3541# Despite the name, also deal with 64 bit binaries.
3542func_win32_libid ()
3543{
3544 $opt_debug
3545 win32_libid_type="unknown"
3546 win32_fileres=`file -L $1 2>/dev/null`
3547 case $win32_fileres in
3548 *ar\ archive\ import\ library*) # definitely import
3549 win32_libid_type="x86 archive import"
3550 ;;
3551 *ar\ archive*) # could be an import, or static
3552 # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD.
3553 if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null |
3554 $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then
3555 func_to_tool_file "$1" func_convert_file_msys_to_w32
3556 win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" |
3557 $SED -n -e '
3558 1,100{
3559 / I /{
3560 s,.*,import,
3561 p
3562 q
3563 }
3564 }'`
3565 case $win32_nmres in
3566 import*) win32_libid_type="x86 archive import";;
3567 *) win32_libid_type="x86 archive static";;
3568 esac
3569 fi
3570 ;;
3571 *DLL*)
3572 win32_libid_type="x86 DLL"
3573 ;;
3574 *executable*) # but shell scripts are "executable" too...
3575 case $win32_fileres in
3576 *MS\ Windows\ PE\ Intel*)
3577 win32_libid_type="x86 DLL"
3578 ;;
3579 esac
3580 ;;
3581 esac
3582 $ECHO "$win32_libid_type"
3583}
3584
3585# func_cygming_dll_for_implib ARG
3586#
3587# Platform-specific function to extract the
3588# name of the DLL associated with the specified
3589# import library ARG.
3590# Invoked by eval'ing the libtool variable
3591# $sharedlib_from_linklib_cmd
3592# Result is available in the variable
3593# $sharedlib_from_linklib_result
3594func_cygming_dll_for_implib ()
3595{
3596 $opt_debug
3597 sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"`
3598}
3599
3600# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs
3601#
3602# The is the core of a fallback implementation of a
3603# platform-specific function to extract the name of the
3604# DLL associated with the specified import library LIBNAME.
3605#
3606# SECTION_NAME is either .idata$6 or .idata$7, depending
3607# on the platform and compiler that created the implib.
3608#
3609# Echos the name of the DLL associated with the
3610# specified import library.
3611func_cygming_dll_for_implib_fallback_core ()
3612{
3613 $opt_debug
3614 match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"`
3615 $OBJDUMP -s --section "$1" "$2" 2>/dev/null |
3616 $SED '/^Contents of section '"$match_literal"':/{
3617 # Place marker at beginning of archive member dllname section
3618 s/.*/====MARK====/
3619 p
3620 d
3621 }
3622 # These lines can sometimes be longer than 43 characters, but
3623 # are always uninteresting
3624 /:[ ]*file format pe[i]\{,1\}-/d
3625 /^In archive [^:]*:/d
3626 # Ensure marker is printed
3627 /^====MARK====/p
3628 # Remove all lines with less than 43 characters
3629 /^.\{43\}/!d
3630 # From remaining lines, remove first 43 characters
3631 s/^.\{43\}//' |
3632 $SED -n '
3633 # Join marker and all lines until next marker into a single line
3634 /^====MARK====/ b para
3635 H
3636 $ b para
3637 b
3638 :para
3639 x
3640 s/\n//g
3641 # Remove the marker
3642 s/^====MARK====//
3643 # Remove trailing dots and whitespace
3644 s/[\. \t]*$//
3645 # Print
3646 /./p' |
3647 # we now have a list, one entry per line, of the stringified
3648 # contents of the appropriate section of all members of the
3649 # archive which possess that section. Heuristic: eliminate
3650 # all those which have a first or second character that is
3651 # a '.' (that is, objdump's representation of an unprintable
3652 # character.) This should work for all archives with less than
3653 # 0x302f exports -- but will fail for DLLs whose name actually
3654 # begins with a literal '.' or a single character followed by
3655 # a '.'.
3656 #
3657 # Of those that remain, print the first one.
3658 $SED -e '/^\./d;/^.\./d;q'
3659}
3660
3661# func_cygming_gnu_implib_p ARG
3662# This predicate returns with zero status (TRUE) if
3663# ARG is a GNU/binutils-style import library. Returns
3664# with nonzero status (FALSE) otherwise.
3665func_cygming_gnu_implib_p ()
3666{
3667 $opt_debug
3668 func_to_tool_file "$1" func_convert_file_msys_to_w32
3669 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)$'`
3670 test -n "$func_cygming_gnu_implib_tmp"
3671}
3672
3673# func_cygming_ms_implib_p ARG
3674# This predicate returns with zero status (TRUE) if
3675# ARG is an MS-style import library. Returns
3676# with nonzero status (FALSE) otherwise.
3677func_cygming_ms_implib_p ()
3678{
3679 $opt_debug
3680 func_to_tool_file "$1" func_convert_file_msys_to_w32
3681 func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'`
3682 test -n "$func_cygming_ms_implib_tmp"
3683}
3684
3685# func_cygming_dll_for_implib_fallback ARG
3686# Platform-specific function to extract the
3687# name of the DLL associated with the specified
3688# import library ARG.
3689#
3690# This fallback implementation is for use when $DLLTOOL
3691# does not support the --identify-strict option.
3692# Invoked by eval'ing the libtool variable
3693# $sharedlib_from_linklib_cmd
3694# Result is available in the variable
3695# $sharedlib_from_linklib_result
3696func_cygming_dll_for_implib_fallback ()
3697{
3698 $opt_debug
3699 if func_cygming_gnu_implib_p "$1" ; then
3700 # binutils import library
3701 sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"`
3702 elif func_cygming_ms_implib_p "$1" ; then
3703 # ms-generated import library
3704 sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"`
3705 else
3706 # unknown
3707 sharedlib_from_linklib_result=""
3708 fi
3709}
3710
3711
3712# func_extract_an_archive dir oldlib
3713func_extract_an_archive ()
3714{
3715 $opt_debug
3716 f_ex_an_ar_dir="$1"; shift
3717 f_ex_an_ar_oldlib="$1"
3718 if test "$lock_old_archive_extraction" = yes; then
3719 lockfile=$f_ex_an_ar_oldlib.lock
3720 until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do
3721 func_echo "Waiting for $lockfile to be removed"
3722 sleep 2
3723 done
3724 fi
3725 func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \
3726 'stat=$?; rm -f "$lockfile"; exit $stat'
3727 if test "$lock_old_archive_extraction" = yes; then
3728 $opt_dry_run || rm -f "$lockfile"
3729 fi
3730 if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then
3731 :
3732 else
3733 func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib"
3734 fi
3735}
3736
3737
3738# func_extract_archives gentop oldlib ...
3739func_extract_archives ()
3740{
3741 $opt_debug
3742 my_gentop="$1"; shift
3743 my_oldlibs=${1+"$@"}
3744 my_oldobjs=""
3745 my_xlib=""
3746 my_xabs=""
3747 my_xdir=""
3748
3749 for my_xlib in $my_oldlibs; do
3750 # Extract the objects.
3751 case $my_xlib in
3752 [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;;
3753 *) my_xabs=`pwd`"/$my_xlib" ;;
3754 esac
3755 func_basename "$my_xlib"
3756 my_xlib="$func_basename_result"
3757 my_xlib_u=$my_xlib
3758 while :; do
3759 case " $extracted_archives " in
3760 *" $my_xlib_u "*)
3761 func_arith $extracted_serial + 1
3762 extracted_serial=$func_arith_result
3763 my_xlib_u=lt$extracted_serial-$my_xlib ;;
3764 *) break ;;
3765 esac
3766 done
3767 extracted_archives="$extracted_archives $my_xlib_u"
3768 my_xdir="$my_gentop/$my_xlib_u"
3769
3770 func_mkdir_p "$my_xdir"
3771
3772 case $host in
3773 *-darwin*)
3774 func_verbose "Extracting $my_xabs"
3775 # Do not bother doing anything if just a dry run
3776 $opt_dry_run || {
3777 darwin_orig_dir=`pwd`
3778 cd $my_xdir || exit $?
3779 darwin_archive=$my_xabs
3780 darwin_curdir=`pwd`
3781 darwin_base_archive=`basename "$darwin_archive"`
3782 darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true`
3783 if test -n "$darwin_arches"; then
3784 darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'`
3785 darwin_arch=
3786 func_verbose "$darwin_base_archive has multiple architectures $darwin_arches"
3787 for darwin_arch in $darwin_arches ; do
3788 func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}"
3789 $LIPO -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}"
3790 cd "unfat-$$/${darwin_base_archive}-${darwin_arch}"
3791 func_extract_an_archive "`pwd`" "${darwin_base_archive}"
3792 cd "$darwin_curdir"
3793 $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}"
3794 done # $darwin_arches
3795 ## Okay now we've a bunch of thin objects, gotta fatten them up :)
3796 darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$basename" | sort -u`
3797 darwin_file=
3798 darwin_files=
3799 for darwin_file in $darwin_filelist; do
3800 darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP`
3801 $LIPO -create -output "$darwin_file" $darwin_files
3802 done # $darwin_filelist
3803 $RM -rf unfat-$$
3804 cd "$darwin_orig_dir"
3805 else
3806 cd $darwin_orig_dir
3807 func_extract_an_archive "$my_xdir" "$my_xabs"
3808 fi # $darwin_arches
3809 } # !$opt_dry_run
3810 ;;
3811 *)
3812 func_extract_an_archive "$my_xdir" "$my_xabs"
3813 ;;
3814 esac
3815 my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP`
3816 done
3817
3818 func_extract_archives_result="$my_oldobjs"
3819}
3820
3821
3822# func_emit_wrapper [arg=no]
3823#
3824# Emit a libtool wrapper script on stdout.
3825# Don't directly open a file because we may want to
3826# incorporate the script contents within a cygwin/mingw
3827# wrapper executable. Must ONLY be called from within
3828# func_mode_link because it depends on a number of variables
3829# set therein.
3830#
3831# ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR
3832# variable will take. If 'yes', then the emitted script
3833# will assume that the directory in which it is stored is
3834# the $objdir directory. This is a cygwin/mingw-specific
3835# behavior.
3836func_emit_wrapper ()
3837{
3838 func_emit_wrapper_arg1=${1-no}
3839
3840 $ECHO "\
3841#! $SHELL
3842
3843# $output - temporary wrapper script for $objdir/$outputname
3844# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
3845#
3846# The $output program cannot be directly executed until all the libtool
3847# libraries that it depends on are installed.
3848#
3849# This wrapper script should never be moved out of the build directory.
3850# If it is, it will not operate correctly.
3851
3852# Sed substitution that helps us do robust quoting. It backslashifies
3853# metacharacters that are still active within double-quoted strings.
3854sed_quote_subst='$sed_quote_subst'
3855
3856# Be Bourne compatible
3857if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then
3858 emulate sh
3859 NULLCMD=:
3860 # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which
3861 # is contrary to our usage. Disable this feature.
3862 alias -g '\${1+\"\$@\"}'='\"\$@\"'
3863 setopt NO_GLOB_SUBST
3864else
3865 case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac
3866fi
3867BIN_SH=xpg4; export BIN_SH # for Tru64
3868DUALCASE=1; export DUALCASE # for MKS sh
3869
3870# The HP-UX ksh and POSIX shell print the target directory to stdout
3871# if CDPATH is set.
3872(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
3873
3874relink_command=\"$relink_command\"
3875
3876# This environment variable determines our operation mode.
3877if test \"\$libtool_install_magic\" = \"$magic\"; then
3878 # install mode needs the following variables:
3879 generated_by_libtool_version='$macro_version'
3880 notinst_deplibs='$notinst_deplibs'
3881else
3882 # When we are sourced in execute mode, \$file and \$ECHO are already set.
3883 if test \"\$libtool_execute_magic\" != \"$magic\"; then
3884 file=\"\$0\""
3885
3886 qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"`
3887 $ECHO "\
3888
3889# A function that is used when there is no print builtin or printf.
3890func_fallback_echo ()
3891{
3892 eval 'cat <<_LTECHO_EOF
3893\$1
3894_LTECHO_EOF'
3895}
3896 ECHO=\"$qECHO\"
3897 fi
3898
3899# Very basic option parsing. These options are (a) specific to
3900# the libtool wrapper, (b) are identical between the wrapper
3901# /script/ and the wrapper /executable/ which is used only on
3902# windows platforms, and (c) all begin with the string "--lt-"
3903# (application programs are unlikely to have options which match
3904# this pattern).
3905#
3906# There are only two supported options: --lt-debug and
3907# --lt-dump-script. There is, deliberately, no --lt-help.
3908#
3909# The first argument to this parsing function should be the
3910# script's $0 value, followed by "$@".
3911lt_option_debug=
3912func_parse_lt_options ()
3913{
3914 lt_script_arg0=\$0
3915 shift
3916 for lt_opt
3917 do
3918 case \"\$lt_opt\" in
3919 --lt-debug) lt_option_debug=1 ;;
3920 --lt-dump-script)
3921 lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\`
3922 test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=.
3923 lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\`
3924 cat \"\$lt_dump_D/\$lt_dump_F\"
3925 exit 0
3926 ;;
3927 --lt-*)
3928 \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2
3929 exit 1
3930 ;;
3931 esac
3932 done
3933
3934 # Print the debug banner immediately:
3935 if test -n \"\$lt_option_debug\"; then
3936 echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2
3937 fi
3938}
3939
3940# Used when --lt-debug. Prints its arguments to stdout
3941# (redirection is the responsibility of the caller)
3942func_lt_dump_args ()
3943{
3944 lt_dump_args_N=1;
3945 for lt_arg
3946 do
3947 \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\"
3948 lt_dump_args_N=\`expr \$lt_dump_args_N + 1\`
3949 done
3950}
3951
3952# Core function for launching the target application
3953func_exec_program_core ()
3954{
3955"
3956 case $host in
3957 # Backslashes separate directories on plain windows
3958 *-*-mingw | *-*-os2* | *-cegcc*)
3959 $ECHO "\
3960 if test -n \"\$lt_option_debug\"; then
3961 \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2
3962 func_lt_dump_args \${1+\"\$@\"} 1>&2
3963 fi
3964 exec \"\$progdir\\\\\$program\" \${1+\"\$@\"}
3965"
3966 ;;
3967
3968 *)
3969 $ECHO "\
3970 if test -n \"\$lt_option_debug\"; then
3971 \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2
3972 func_lt_dump_args \${1+\"\$@\"} 1>&2
3973 fi
3974 exec \"\$progdir/\$program\" \${1+\"\$@\"}
3975"
3976 ;;
3977 esac
3978 $ECHO "\
3979 \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2
3980 exit 1
3981}
3982
3983# A function to encapsulate launching the target application
3984# Strips options in the --lt-* namespace from \$@ and
3985# launches target application with the remaining arguments.
3986func_exec_program ()
3987{
3988 case \" \$* \" in
3989 *\\ --lt-*)
3990 for lt_wr_arg
3991 do
3992 case \$lt_wr_arg in
3993 --lt-*) ;;
3994 *) set x \"\$@\" \"\$lt_wr_arg\"; shift;;
3995 esac
3996 shift
3997 done ;;
3998 esac
3999 func_exec_program_core \${1+\"\$@\"}
4000}
4001
4002 # Parse options
4003 func_parse_lt_options \"\$0\" \${1+\"\$@\"}
4004
4005 # Find the directory that this script lives in.
4006 thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\`
4007 test \"x\$thisdir\" = \"x\$file\" && thisdir=.
4008
4009 # Follow symbolic links until we get to the real thisdir.
4010 file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\`
4011 while test -n \"\$file\"; do
4012 destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\`
4013
4014 # If there was a directory component, then change thisdir.
4015 if test \"x\$destdir\" != \"x\$file\"; then
4016 case \"\$destdir\" in
4017 [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;;
4018 *) thisdir=\"\$thisdir/\$destdir\" ;;
4019 esac
4020 fi
4021
4022 file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\`
4023 file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\`
4024 done
4025
4026 # Usually 'no', except on cygwin/mingw when embedded into
4027 # the cwrapper.
4028 WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1
4029 if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then
4030 # special case for '.'
4031 if test \"\$thisdir\" = \".\"; then
4032 thisdir=\`pwd\`
4033 fi
4034 # remove .libs from thisdir
4035 case \"\$thisdir\" in
4036 *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;;
4037 $objdir ) thisdir=. ;;
4038 esac
4039 fi
4040
4041 # Try to get the absolute directory name.
4042 absdir=\`cd \"\$thisdir\" && pwd\`
4043 test -n \"\$absdir\" && thisdir=\"\$absdir\"
4044"
4045
4046 if test "$fast_install" = yes; then
4047 $ECHO "\
4048 program=lt-'$outputname'$exeext
4049 progdir=\"\$thisdir/$objdir\"
4050
4051 if test ! -f \"\$progdir/\$program\" ||
4052 { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\
4053 test \"X\$file\" != \"X\$progdir/\$program\"; }; then
4054
4055 file=\"\$\$-\$program\"
4056
4057 if test ! -d \"\$progdir\"; then
4058 $MKDIR \"\$progdir\"
4059 else
4060 $RM \"\$progdir/\$file\"
4061 fi"
4062
4063 $ECHO "\
4064
4065 # relink executable if necessary
4066 if test -n \"\$relink_command\"; then
4067 if relink_command_output=\`eval \$relink_command 2>&1\`; then :
4068 else
4069 $ECHO \"\$relink_command_output\" >&2
4070 $RM \"\$progdir/\$file\"
4071 exit 1
4072 fi
4073 fi
4074
4075 $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null ||
4076 { $RM \"\$progdir/\$program\";
4077 $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; }
4078 $RM \"\$progdir/\$file\"
4079 fi"
4080 else
4081 $ECHO "\
4082 program='$outputname'
4083 progdir=\"\$thisdir/$objdir\"
4084"
4085 fi
4086
4087 $ECHO "\
4088
4089 if test -f \"\$progdir/\$program\"; then"
4090
4091 # fixup the dll searchpath if we need to.
4092 #
4093 # Fix the DLL searchpath if we need to. Do this before prepending
4094 # to shlibpath, because on Windows, both are PATH and uninstalled
4095 # libraries must come first.
4096 if test -n "$dllsearchpath"; then
4097 $ECHO "\
4098 # Add the dll search path components to the executable PATH
4099 PATH=$dllsearchpath:\$PATH
4100"
4101 fi
4102
4103 # Export our shlibpath_var if we have one.
4104 if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
4105 $ECHO "\
4106 # Add our own library path to $shlibpath_var
4107 $shlibpath_var=\"$temp_rpath\$$shlibpath_var\"
4108
4109 # Some systems cannot cope with colon-terminated $shlibpath_var
4110 # The second colon is a workaround for a bug in BeOS R4 sed
4111 $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\`
4112
4113 export $shlibpath_var
4114"
4115 fi
4116
4117 $ECHO "\
4118 if test \"\$libtool_execute_magic\" != \"$magic\"; then
4119 # Run the actual program with our arguments.
4120 func_exec_program \${1+\"\$@\"}
4121 fi
4122 else
4123 # The program doesn't exist.
4124 \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2
4125 \$ECHO \"This script is just a wrapper for \$program.\" 1>&2
4126 \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2
4127 exit 1
4128 fi
4129fi\
4130"
4131}
4132
4133
4134# func_emit_cwrapperexe_src
4135# emit the source code for a wrapper executable on stdout
4136# Must ONLY be called from within func_mode_link because
4137# it depends on a number of variable set therein.
4138func_emit_cwrapperexe_src ()
4139{
4140 cat <<EOF
4141
4142/* $cwrappersource - temporary wrapper executable for $objdir/$outputname
4143 Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
4144
4145 The $output program cannot be directly executed until all the libtool
4146 libraries that it depends on are installed.
4147
4148 This wrapper executable should never be moved out of the build directory.
4149 If it is, it will not operate correctly.
4150*/
4151EOF
4152 cat <<"EOF"
4153#ifdef _MSC_VER
4154# define _CRT_SECURE_NO_DEPRECATE 1
4155#endif
4156#include <stdio.h>
4157#include <stdlib.h>
4158#ifdef _MSC_VER
4159# include <direct.h>
4160# include <process.h>
4161# include <io.h>
4162#else
4163# include <unistd.h>
4164# include <stdint.h>
4165# ifdef __CYGWIN__
4166# include <io.h>
4167# endif
4168#endif
4169#include <malloc.h>
4170#include <stdarg.h>
4171#include <assert.h>
4172#include <string.h>
4173#include <ctype.h>
4174#include <errno.h>
4175#include <fcntl.h>
4176#include <sys/stat.h>
4177
4178/* declarations of non-ANSI functions */
4179#if defined(__MINGW32__)
4180# ifdef __STRICT_ANSI__
4181int _putenv (const char *);
4182# endif
4183#elif defined(__CYGWIN__)
4184# ifdef __STRICT_ANSI__
4185char *realpath (const char *, char *);
4186int putenv (char *);
4187int setenv (const char *, const char *, int);
4188# endif
4189/* #elif defined (other platforms) ... */
4190#endif
4191
4192/* portability defines, excluding path handling macros */
4193#if defined(_MSC_VER)
4194# define setmode _setmode
4195# define stat _stat
4196# define chmod _chmod
4197# define getcwd _getcwd
4198# define putenv _putenv
4199# define S_IXUSR _S_IEXEC
4200# ifndef _INTPTR_T_DEFINED
4201# define _INTPTR_T_DEFINED
4202# define intptr_t int
4203# endif
4204#elif defined(__MINGW32__)
4205# define setmode _setmode
4206# define stat _stat
4207# define chmod _chmod
4208# define getcwd _getcwd
4209# define putenv _putenv
4210#elif defined(__CYGWIN__)
4211# define HAVE_SETENV
4212# define FOPEN_WB "wb"
4213/* #elif defined (other platforms) ... */
4214#endif
4215
4216#if defined(PATH_MAX)
4217# define LT_PATHMAX PATH_MAX
4218#elif defined(MAXPATHLEN)
4219# define LT_PATHMAX MAXPATHLEN
4220#else
4221# define LT_PATHMAX 1024
4222#endif
4223
4224#ifndef S_IXOTH
4225# define S_IXOTH 0
4226#endif
4227#ifndef S_IXGRP
4228# define S_IXGRP 0
4229#endif
4230
4231/* path handling portability macros */
4232#ifndef DIR_SEPARATOR
4233# define DIR_SEPARATOR '/'
4234# define PATH_SEPARATOR ':'
4235#endif
4236
4237#if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \
4238 defined (__OS2__)
4239# define HAVE_DOS_BASED_FILE_SYSTEM
4240# define FOPEN_WB "wb"
4241# ifndef DIR_SEPARATOR_2
4242# define DIR_SEPARATOR_2 '\\'
4243# endif
4244# ifndef PATH_SEPARATOR_2
4245# define PATH_SEPARATOR_2 ';'
4246# endif
4247#endif
4248
4249#ifndef DIR_SEPARATOR_2
4250# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR)
4251#else /* DIR_SEPARATOR_2 */
4252# define IS_DIR_SEPARATOR(ch) \
4253 (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2))
4254#endif /* DIR_SEPARATOR_2 */
4255
4256#ifndef PATH_SEPARATOR_2
4257# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR)
4258#else /* PATH_SEPARATOR_2 */
4259# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2)
4260#endif /* PATH_SEPARATOR_2 */
4261
4262#ifndef FOPEN_WB
4263# define FOPEN_WB "w"
4264#endif
4265#ifndef _O_BINARY
4266# define _O_BINARY 0
4267#endif
4268
4269#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type)))
4270#define XFREE(stale) do { \
4271 if (stale) { free ((void *) stale); stale = 0; } \
4272} while (0)
4273
4274#if defined(LT_DEBUGWRAPPER)
4275static int lt_debug = 1;
4276#else
4277static int lt_debug = 0;
4278#endif
4279
4280const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */
4281
4282void *xmalloc (size_t num);
4283char *xstrdup (const char *string);
4284const char *base_name (const char *name);
4285char *find_executable (const char *wrapper);
4286char *chase_symlinks (const char *pathspec);
4287int make_executable (const char *path);
4288int check_executable (const char *path);
4289char *strendzap (char *str, const char *pat);
4290void lt_debugprintf (const char *file, int line, const char *fmt, ...);
4291void lt_fatal (const char *file, int line, const char *message, ...);
4292static const char *nonnull (const char *s);
4293static const char *nonempty (const char *s);
4294void lt_setenv (const char *name, const char *value);
4295char *lt_extend_str (const char *orig_value, const char *add, int to_end);
4296void lt_update_exe_path (const char *name, const char *value);
4297void lt_update_lib_path (const char *name, const char *value);
4298char **prepare_spawn (char **argv);
4299void lt_dump_script (FILE *f);
4300EOF
4301
4302 cat <<EOF
4303volatile const char * MAGIC_EXE = "$magic_exe";
4304const char * LIB_PATH_VARNAME = "$shlibpath_var";
4305EOF
4306
4307 if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
4308 func_to_host_path "$temp_rpath"
4309 cat <<EOF
4310const char * LIB_PATH_VALUE = "$func_to_host_path_result";
4311EOF
4312 else
4313 cat <<"EOF"
4314const char * LIB_PATH_VALUE = "";
4315EOF
4316 fi
4317
4318 if test -n "$dllsearchpath"; then
4319 func_to_host_path "$dllsearchpath:"
4320 cat <<EOF
4321const char * EXE_PATH_VARNAME = "PATH";
4322const char * EXE_PATH_VALUE = "$func_to_host_path_result";
4323EOF
4324 else
4325 cat <<"EOF"
4326const char * EXE_PATH_VARNAME = "";
4327const char * EXE_PATH_VALUE = "";
4328EOF
4329 fi
4330
4331 if test "$fast_install" = yes; then
4332 cat <<EOF
4333const char * TARGET_PROGRAM_NAME = "lt-$outputname"; /* hopefully, no .exe */
4334EOF
4335 else
4336 cat <<EOF
4337const char * TARGET_PROGRAM_NAME = "$outputname"; /* hopefully, no .exe */
4338EOF
4339 fi
4340
4341
4342 cat <<"EOF"
4343
4344#define LTWRAPPER_OPTION_PREFIX "--lt-"
4345
4346static const char *ltwrapper_option_prefix = LTWRAPPER_OPTION_PREFIX;
4347static const char *dumpscript_opt = LTWRAPPER_OPTION_PREFIX "dump-script";
4348static const char *debug_opt = LTWRAPPER_OPTION_PREFIX "debug";
4349
4350int
4351main (int argc, char *argv[])
4352{
4353 char **newargz;
4354 int newargc;
4355 char *tmp_pathspec;
4356 char *actual_cwrapper_path;
4357 char *actual_cwrapper_name;
4358 char *target_name;
4359 char *lt_argv_zero;
4360 intptr_t rval = 127;
4361
4362 int i;
4363
4364 program_name = (char *) xstrdup (base_name (argv[0]));
4365 newargz = XMALLOC (char *, argc + 1);
4366
4367 /* very simple arg parsing; don't want to rely on getopt
4368 * also, copy all non cwrapper options to newargz, except
4369 * argz[0], which is handled differently
4370 */
4371 newargc=0;
4372 for (i = 1; i < argc; i++)
4373 {
4374 if (strcmp (argv[i], dumpscript_opt) == 0)
4375 {
4376EOF
4377 case "$host" in
4378 *mingw* | *cygwin* )
4379 # make stdout use "unix" line endings
4380 echo " setmode(1,_O_BINARY);"
4381 ;;
4382 esac
4383
4384 cat <<"EOF"
4385 lt_dump_script (stdout);
4386 return 0;
4387 }
4388 if (strcmp (argv[i], debug_opt) == 0)
4389 {
4390 lt_debug = 1;
4391 continue;
4392 }
4393 if (strcmp (argv[i], ltwrapper_option_prefix) == 0)
4394 {
4395 /* however, if there is an option in the LTWRAPPER_OPTION_PREFIX
4396 namespace, but it is not one of the ones we know about and
4397 have already dealt with, above (inluding dump-script), then
4398 report an error. Otherwise, targets might begin to believe
4399 they are allowed to use options in the LTWRAPPER_OPTION_PREFIX
4400 namespace. The first time any user complains about this, we'll
4401 need to make LTWRAPPER_OPTION_PREFIX a configure-time option
4402 or a configure.ac-settable value.
4403 */
4404 lt_fatal (__FILE__, __LINE__,
4405 "unrecognized %s option: '%s'",
4406 ltwrapper_option_prefix, argv[i]);
4407 }
4408 /* otherwise ... */
4409 newargz[++newargc] = xstrdup (argv[i]);
4410 }
4411 newargz[++newargc] = NULL;
4412
4413EOF
4414 cat <<EOF
4415 /* The GNU banner must be the first non-error debug message */
4416 lt_debugprintf (__FILE__, __LINE__, "libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\n");
4417EOF
4418 cat <<"EOF"
4419 lt_debugprintf (__FILE__, __LINE__, "(main) argv[0]: %s\n", argv[0]);
4420 lt_debugprintf (__FILE__, __LINE__, "(main) program_name: %s\n", program_name);
4421
4422 tmp_pathspec = find_executable (argv[0]);
4423 if (tmp_pathspec == NULL)
4424 lt_fatal (__FILE__, __LINE__, "couldn't find %s", argv[0]);
4425 lt_debugprintf (__FILE__, __LINE__,
4426 "(main) found exe (before symlink chase) at: %s\n",
4427 tmp_pathspec);
4428
4429 actual_cwrapper_path = chase_symlinks (tmp_pathspec);
4430 lt_debugprintf (__FILE__, __LINE__,
4431 "(main) found exe (after symlink chase) at: %s\n",
4432 actual_cwrapper_path);
4433 XFREE (tmp_pathspec);
4434
4435 actual_cwrapper_name = xstrdup (base_name (actual_cwrapper_path));
4436 strendzap (actual_cwrapper_path, actual_cwrapper_name);
4437
4438 /* wrapper name transforms */
4439 strendzap (actual_cwrapper_name, ".exe");
4440 tmp_pathspec = lt_extend_str (actual_cwrapper_name, ".exe", 1);
4441 XFREE (actual_cwrapper_name);
4442 actual_cwrapper_name = tmp_pathspec;
4443 tmp_pathspec = 0;
4444
4445 /* target_name transforms -- use actual target program name; might have lt- prefix */
4446 target_name = xstrdup (base_name (TARGET_PROGRAM_NAME));
4447 strendzap (target_name, ".exe");
4448 tmp_pathspec = lt_extend_str (target_name, ".exe", 1);
4449 XFREE (target_name);
4450 target_name = tmp_pathspec;
4451 tmp_pathspec = 0;
4452
4453 lt_debugprintf (__FILE__, __LINE__,
4454 "(main) libtool target name: %s\n",
4455 target_name);
4456EOF
4457
4458 cat <<EOF
4459 newargz[0] =
4460 XMALLOC (char, (strlen (actual_cwrapper_path) +
4461 strlen ("$objdir") + 1 + strlen (actual_cwrapper_name) + 1));
4462 strcpy (newargz[0], actual_cwrapper_path);
4463 strcat (newargz[0], "$objdir");
4464 strcat (newargz[0], "/");
4465EOF
4466
4467 cat <<"EOF"
4468 /* stop here, and copy so we don't have to do this twice */
4469 tmp_pathspec = xstrdup (newargz[0]);
4470
4471 /* do NOT want the lt- prefix here, so use actual_cwrapper_name */
4472 strcat (newargz[0], actual_cwrapper_name);
4473
4474 /* DO want the lt- prefix here if it exists, so use target_name */
4475 lt_argv_zero = lt_extend_str (tmp_pathspec, target_name, 1);
4476 XFREE (tmp_pathspec);
4477 tmp_pathspec = NULL;
4478EOF
4479
4480 case $host_os in
4481 mingw*)
4482 cat <<"EOF"
4483 {
4484 char* p;
4485 while ((p = strchr (newargz[0], '\\')) != NULL)
4486 {
4487 *p = '/';
4488 }
4489 while ((p = strchr (lt_argv_zero, '\\')) != NULL)
4490 {
4491 *p = '/';
4492 }
4493 }
4494EOF
4495 ;;
4496 esac
4497
4498 cat <<"EOF"
4499 XFREE (target_name);
4500 XFREE (actual_cwrapper_path);
4501 XFREE (actual_cwrapper_name);
4502
4503 lt_setenv ("BIN_SH", "xpg4"); /* for Tru64 */
4504 lt_setenv ("DUALCASE", "1"); /* for MSK sh */
4505 /* Update the DLL searchpath. EXE_PATH_VALUE ($dllsearchpath) must
4506 be prepended before (that is, appear after) LIB_PATH_VALUE ($temp_rpath)
4507 because on Windows, both *_VARNAMEs are PATH but uninstalled
4508 libraries must come first. */
4509 lt_update_exe_path (EXE_PATH_VARNAME, EXE_PATH_VALUE);
4510 lt_update_lib_path (LIB_PATH_VARNAME, LIB_PATH_VALUE);
4511
4512 lt_debugprintf (__FILE__, __LINE__, "(main) lt_argv_zero: %s\n",
4513 nonnull (lt_argv_zero));
4514 for (i = 0; i < newargc; i++)
4515 {
4516 lt_debugprintf (__FILE__, __LINE__, "(main) newargz[%d]: %s\n",
4517 i, nonnull (newargz[i]));
4518 }
4519
4520EOF
4521
4522 case $host_os in
4523 mingw*)
4524 cat <<"EOF"
4525 /* execv doesn't actually work on mingw as expected on unix */
4526 newargz = prepare_spawn (newargz);
4527 rval = _spawnv (_P_WAIT, lt_argv_zero, (const char * const *) newargz);
4528 if (rval == -1)
4529 {
4530 /* failed to start process */
4531 lt_debugprintf (__FILE__, __LINE__,
4532 "(main) failed to launch target \"%s\": %s\n",
4533 lt_argv_zero, nonnull (strerror (errno)));
4534 return 127;
4535 }
4536 return rval;
4537EOF
4538 ;;
4539 *)
4540 cat <<"EOF"
4541 execv (lt_argv_zero, newargz);
4542 return rval; /* =127, but avoids unused variable warning */
4543EOF
4544 ;;
4545 esac
4546
4547 cat <<"EOF"
4548}
4549
4550void *
4551xmalloc (size_t num)
4552{
4553 void *p = (void *) malloc (num);
4554 if (!p)
4555 lt_fatal (__FILE__, __LINE__, "memory exhausted");
4556
4557 return p;
4558}
4559
4560char *
4561xstrdup (const char *string)
4562{
4563 return string ? strcpy ((char *) xmalloc (strlen (string) + 1),
4564 string) : NULL;
4565}
4566
4567const char *
4568base_name (const char *name)
4569{
4570 const char *base;
4571
4572#if defined (HAVE_DOS_BASED_FILE_SYSTEM)
4573 /* Skip over the disk name in MSDOS pathnames. */
4574 if (isalpha ((unsigned char) name[0]) && name[1] == ':')
4575 name += 2;
4576#endif
4577
4578 for (base = name; *name; name++)
4579 if (IS_DIR_SEPARATOR (*name))
4580 base = name + 1;
4581 return base;
4582}
4583
4584int
4585check_executable (const char *path)
4586{
4587 struct stat st;
4588
4589 lt_debugprintf (__FILE__, __LINE__, "(check_executable): %s\n",
4590 nonempty (path));
4591 if ((!path) || (!*path))
4592 return 0;
4593
4594 if ((stat (path, &st) >= 0)
4595 && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH)))
4596 return 1;
4597 else
4598 return 0;
4599}
4600
4601int
4602make_executable (const char *path)
4603{
4604 int rval = 0;
4605 struct stat st;
4606
4607 lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n",
4608 nonempty (path));
4609 if ((!path) || (!*path))
4610 return 0;
4611
4612 if (stat (path, &st) >= 0)
4613 {
4614 rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR);
4615 }
4616 return rval;
4617}
4618
4619/* Searches for the full path of the wrapper. Returns
4620 newly allocated full path name if found, NULL otherwise
4621 Does not chase symlinks, even on platforms that support them.
4622*/
4623char *
4624find_executable (const char *wrapper)
4625{
4626 int has_slash = 0;
4627 const char *p;
4628 const char *p_next;
4629 /* static buffer for getcwd */
4630 char tmp[LT_PATHMAX + 1];
4631 int tmp_len;
4632 char *concat_name;
4633
4634 lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n",
4635 nonempty (wrapper));
4636
4637 if ((wrapper == NULL) || (*wrapper == '\0'))
4638 return NULL;
4639
4640 /* Absolute path? */
4641#if defined (HAVE_DOS_BASED_FILE_SYSTEM)
4642 if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':')
4643 {
4644 concat_name = xstrdup (wrapper);
4645 if (check_executable (concat_name))
4646 return concat_name;
4647 XFREE (concat_name);
4648 }
4649 else
4650 {
4651#endif
4652 if (IS_DIR_SEPARATOR (wrapper[0]))
4653 {
4654 concat_name = xstrdup (wrapper);
4655 if (check_executable (concat_name))
4656 return concat_name;
4657 XFREE (concat_name);
4658 }
4659#if defined (HAVE_DOS_BASED_FILE_SYSTEM)
4660 }
4661#endif
4662
4663 for (p = wrapper; *p; p++)
4664 if (*p == '/')
4665 {
4666 has_slash = 1;
4667 break;
4668 }
4669 if (!has_slash)
4670 {
4671 /* no slashes; search PATH */
4672 const char *path = getenv ("PATH");
4673 if (path != NULL)
4674 {
4675 for (p = path; *p; p = p_next)
4676 {
4677 const char *q;
4678 size_t p_len;
4679 for (q = p; *q; q++)
4680 if (IS_PATH_SEPARATOR (*q))
4681 break;
4682 p_len = q - p;
4683 p_next = (*q == '\0' ? q : q + 1);
4684 if (p_len == 0)
4685 {
4686 /* empty path: current directory */
4687 if (getcwd (tmp, LT_PATHMAX) == NULL)
4688 lt_fatal (__FILE__, __LINE__, "getcwd failed: %s",
4689 nonnull (strerror (errno)));
4690 tmp_len = strlen (tmp);
4691 concat_name =
4692 XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1);
4693 memcpy (concat_name, tmp, tmp_len);
4694 concat_name[tmp_len] = '/';
4695 strcpy (concat_name + tmp_len + 1, wrapper);
4696 }
4697 else
4698 {
4699 concat_name =
4700 XMALLOC (char, p_len + 1 + strlen (wrapper) + 1);
4701 memcpy (concat_name, p, p_len);
4702 concat_name[p_len] = '/';
4703 strcpy (concat_name + p_len + 1, wrapper);
4704 }
4705 if (check_executable (concat_name))
4706 return concat_name;
4707 XFREE (concat_name);
4708 }
4709 }
4710 /* not found in PATH; assume curdir */
4711 }
4712 /* Relative path | not found in path: prepend cwd */
4713 if (getcwd (tmp, LT_PATHMAX) == NULL)
4714 lt_fatal (__FILE__, __LINE__, "getcwd failed: %s",
4715 nonnull (strerror (errno)));
4716 tmp_len = strlen (tmp);
4717 concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1);
4718 memcpy (concat_name, tmp, tmp_len);
4719 concat_name[tmp_len] = '/';
4720 strcpy (concat_name + tmp_len + 1, wrapper);
4721
4722 if (check_executable (concat_name))
4723 return concat_name;
4724 XFREE (concat_name);
4725 return NULL;
4726}
4727
4728char *
4729chase_symlinks (const char *pathspec)
4730{
4731#ifndef S_ISLNK
4732 return xstrdup (pathspec);
4733#else
4734 char buf[LT_PATHMAX];
4735 struct stat s;
4736 char *tmp_pathspec = xstrdup (pathspec);
4737 char *p;
4738 int has_symlinks = 0;
4739 while (strlen (tmp_pathspec) && !has_symlinks)
4740 {
4741 lt_debugprintf (__FILE__, __LINE__,
4742 "checking path component for symlinks: %s\n",
4743 tmp_pathspec);
4744 if (lstat (tmp_pathspec, &s) == 0)
4745 {
4746 if (S_ISLNK (s.st_mode) != 0)
4747 {
4748 has_symlinks = 1;
4749 break;
4750 }
4751
4752 /* search backwards for last DIR_SEPARATOR */
4753 p = tmp_pathspec + strlen (tmp_pathspec) - 1;
4754 while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p)))
4755 p--;
4756 if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p)))
4757 {
4758 /* no more DIR_SEPARATORS left */
4759 break;
4760 }
4761 *p = '\0';
4762 }
4763 else
4764 {
4765 lt_fatal (__FILE__, __LINE__,
4766 "error accessing file \"%s\": %s",
4767 tmp_pathspec, nonnull (strerror (errno)));
4768 }
4769 }
4770 XFREE (tmp_pathspec);
4771
4772 if (!has_symlinks)
4773 {
4774 return xstrdup (pathspec);
4775 }
4776
4777 tmp_pathspec = realpath (pathspec, buf);
4778 if (tmp_pathspec == 0)
4779 {
4780 lt_fatal (__FILE__, __LINE__,
4781 "could not follow symlinks for %s", pathspec);
4782 }
4783 return xstrdup (tmp_pathspec);
4784#endif
4785}
4786
4787char *
4788strendzap (char *str, const char *pat)
4789{
4790 size_t len, patlen;
4791
4792 assert (str != NULL);
4793 assert (pat != NULL);
4794
4795 len = strlen (str);
4796 patlen = strlen (pat);
4797
4798 if (patlen <= len)
4799 {
4800 str += len - patlen;
4801 if (strcmp (str, pat) == 0)
4802 *str = '\0';
4803 }
4804 return str;
4805}
4806
4807void
4808lt_debugprintf (const char *file, int line, const char *fmt, ...)
4809{
4810 va_list args;
4811 if (lt_debug)
4812 {
4813 (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line);
4814 va_start (args, fmt);
4815 (void) vfprintf (stderr, fmt, args);
4816 va_end (args);
4817 }
4818}
4819
4820static void
4821lt_error_core (int exit_status, const char *file,
4822 int line, const char *mode,
4823 const char *message, va_list ap)
4824{
4825 fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode);
4826 vfprintf (stderr, message, ap);
4827 fprintf (stderr, ".\n");
4828
4829 if (exit_status >= 0)
4830 exit (exit_status);
4831}
4832
4833void
4834lt_fatal (const char *file, int line, const char *message, ...)
4835{
4836 va_list ap;
4837 va_start (ap, message);
4838 lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap);
4839 va_end (ap);
4840}
4841
4842static const char *
4843nonnull (const char *s)
4844{
4845 return s ? s : "(null)";
4846}
4847
4848static const char *
4849nonempty (const char *s)
4850{
4851 return (s && !*s) ? "(empty)" : nonnull (s);
4852}
4853
4854void
4855lt_setenv (const char *name, const char *value)
4856{
4857 lt_debugprintf (__FILE__, __LINE__,
4858 "(lt_setenv) setting '%s' to '%s'\n",
4859 nonnull (name), nonnull (value));
4860 {
4861#ifdef HAVE_SETENV
4862 /* always make a copy, for consistency with !HAVE_SETENV */
4863 char *str = xstrdup (value);
4864 setenv (name, str, 1);
4865#else
4866 int len = strlen (name) + 1 + strlen (value) + 1;
4867 char *str = XMALLOC (char, len);
4868 sprintf (str, "%s=%s", name, value);
4869 if (putenv (str) != EXIT_SUCCESS)
4870 {
4871 XFREE (str);
4872 }
4873#endif
4874 }
4875}
4876
4877char *
4878lt_extend_str (const char *orig_value, const char *add, int to_end)
4879{
4880 char *new_value;
4881 if (orig_value && *orig_value)
4882 {
4883 int orig_value_len = strlen (orig_value);
4884 int add_len = strlen (add);
4885 new_value = XMALLOC (char, add_len + orig_value_len + 1);
4886 if (to_end)
4887 {
4888 strcpy (new_value, orig_value);
4889 strcpy (new_value + orig_value_len, add);
4890 }
4891 else
4892 {
4893 strcpy (new_value, add);
4894 strcpy (new_value + add_len, orig_value);
4895 }
4896 }
4897 else
4898 {
4899 new_value = xstrdup (add);
4900 }
4901 return new_value;
4902}
4903
4904void
4905lt_update_exe_path (const char *name, const char *value)
4906{
4907 lt_debugprintf (__FILE__, __LINE__,
4908 "(lt_update_exe_path) modifying '%s' by prepending '%s'\n",
4909 nonnull (name), nonnull (value));
4910
4911 if (name && *name && value && *value)
4912 {
4913 char *new_value = lt_extend_str (getenv (name), value, 0);
4914 /* some systems can't cope with a ':'-terminated path #' */
4915 int len = strlen (new_value);
4916 while (((len = strlen (new_value)) > 0) && IS_PATH_SEPARATOR (new_value[len-1]))
4917 {
4918 new_value[len-1] = '\0';
4919 }
4920 lt_setenv (name, new_value);
4921 XFREE (new_value);
4922 }
4923}
4924
4925void
4926lt_update_lib_path (const char *name, const char *value)
4927{
4928 lt_debugprintf (__FILE__, __LINE__,
4929 "(lt_update_lib_path) modifying '%s' by prepending '%s'\n",
4930 nonnull (name), nonnull (value));
4931
4932 if (name && *name && value && *value)
4933 {
4934 char *new_value = lt_extend_str (getenv (name), value, 0);
4935 lt_setenv (name, new_value);
4936 XFREE (new_value);
4937 }
4938}
4939
4940EOF
4941 case $host_os in
4942 mingw*)
4943 cat <<"EOF"
4944
4945/* Prepares an argument vector before calling spawn().
4946 Note that spawn() does not by itself call the command interpreter
4947 (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") :
4948 ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
4949 GetVersionEx(&v);
4950 v.dwPlatformId == VER_PLATFORM_WIN32_NT;
4951 }) ? "cmd.exe" : "command.com").
4952 Instead it simply concatenates the arguments, separated by ' ', and calls
4953 CreateProcess(). We must quote the arguments since Win32 CreateProcess()
4954 interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a
4955 special way:
4956 - Space and tab are interpreted as delimiters. They are not treated as
4957 delimiters if they are surrounded by double quotes: "...".
4958 - Unescaped double quotes are removed from the input. Their only effect is
4959 that within double quotes, space and tab are treated like normal
4960 characters.
4961 - Backslashes not followed by double quotes are not special.
4962 - But 2*n+1 backslashes followed by a double quote become
4963 n backslashes followed by a double quote (n >= 0):
4964 \" -> "
4965 \\\" -> \"
4966 \\\\\" -> \\"
4967 */
4968#define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037"
4969#define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037"
4970char **
4971prepare_spawn (char **argv)
4972{
4973 size_t argc;
4974 char **new_argv;
4975 size_t i;
4976
4977 /* Count number of arguments. */
4978 for (argc = 0; argv[argc] != NULL; argc++)
4979 ;
4980
4981 /* Allocate new argument vector. */
4982 new_argv = XMALLOC (char *, argc + 1);
4983
4984 /* Put quoted arguments into the new argument vector. */
4985 for (i = 0; i < argc; i++)
4986 {
4987 const char *string = argv[i];
4988
4989 if (string[0] == '\0')
4990 new_argv[i] = xstrdup ("\"\"");
4991 else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL)
4992 {
4993 int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL);
4994 size_t length;
4995 unsigned int backslashes;
4996 const char *s;
4997 char *quoted_string;
4998 char *p;
4999
5000 length = 0;
5001 backslashes = 0;
5002 if (quote_around)
5003 length++;
5004 for (s = string; *s != '\0'; s++)
5005 {
5006 char c = *s;
5007 if (c == '"')
5008 length += backslashes + 1;
5009 length++;
5010 if (c == '\\')
5011 backslashes++;
5012 else
5013 backslashes = 0;
5014 }
5015 if (quote_around)
5016 length += backslashes + 1;
5017
5018 quoted_string = XMALLOC (char, length + 1);
5019
5020 p = quoted_string;
5021 backslashes = 0;
5022 if (quote_around)
5023 *p++ = '"';
5024 for (s = string; *s != '\0'; s++)
5025 {
5026 char c = *s;
5027 if (c == '"')
5028 {
5029 unsigned int j;
5030 for (j = backslashes + 1; j > 0; j--)
5031 *p++ = '\\';
5032 }
5033 *p++ = c;
5034 if (c == '\\')
5035 backslashes++;
5036 else
5037 backslashes = 0;
5038 }
5039 if (quote_around)
5040 {
5041 unsigned int j;
5042 for (j = backslashes; j > 0; j--)
5043 *p++ = '\\';
5044 *p++ = '"';
5045 }
5046 *p = '\0';
5047
5048 new_argv[i] = quoted_string;
5049 }
5050 else
5051 new_argv[i] = (char *) string;
5052 }
5053 new_argv[argc] = NULL;
5054
5055 return new_argv;
5056}
5057EOF
5058 ;;
5059 esac
5060
5061 cat <<"EOF"
5062void lt_dump_script (FILE* f)
5063{
5064EOF
5065 func_emit_wrapper yes |
5066 $SED -n -e '
5067s/^\(.\{79\}\)\(..*\)/\1\
5068\2/
5069h
5070s/\([\\"]\)/\\\1/g
5071s/$/\\n/
5072s/\([^\n]*\).*/ fputs ("\1", f);/p
5073g
5074D'
5075 cat <<"EOF"
5076}
5077EOF
5078}
5079# end: func_emit_cwrapperexe_src
5080
5081# func_win32_import_lib_p ARG
5082# True if ARG is an import lib, as indicated by $file_magic_cmd
5083func_win32_import_lib_p ()
5084{
5085 $opt_debug
5086 case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in
5087 *import*) : ;;
5088 *) false ;;
5089 esac
5090}
5091
5092# func_mode_link arg...
5093func_mode_link ()
5094{
5095 $opt_debug
5096 case $host in
5097 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
5098 # It is impossible to link a dll without this setting, and
5099 # we shouldn't force the makefile maintainer to figure out
5100 # which system we are compiling for in order to pass an extra
5101 # flag for every libtool invocation.
5102 # allow_undefined=no
5103
5104 # FIXME: Unfortunately, there are problems with the above when trying
5105 # to make a dll which has undefined symbols, in which case not
5106 # even a static library is built. For now, we need to specify
5107 # -no-undefined on the libtool link line when we can be certain
5108 # that all symbols are satisfied, otherwise we get a static library.
5109 allow_undefined=yes
5110 ;;
5111 *)
5112 allow_undefined=yes
5113 ;;
5114 esac
5115 libtool_args=$nonopt
5116 base_compile="$nonopt $@"
5117 compile_command=$nonopt
5118 finalize_command=$nonopt
5119
5120 compile_rpath=
5121 finalize_rpath=
5122 compile_shlibpath=
5123 finalize_shlibpath=
5124 convenience=
5125 old_convenience=
5126 deplibs=
5127 old_deplibs=
5128 compiler_flags=
5129 linker_flags=
5130 dllsearchpath=
5131 lib_search_path=`pwd`
5132 inst_prefix_dir=
5133 new_inherited_linker_flags=
5134
5135 avoid_version=no
5136 bindir=
5137 dlfiles=
5138 dlprefiles=
5139 dlself=no
5140 export_dynamic=no
5141 export_symbols=
5142 export_symbols_regex=
5143 generated=
5144 libobjs=
5145 ltlibs=
5146 module=no
5147 no_install=no
5148 objs=
5149 non_pic_objects=
5150 precious_files_regex=
5151 prefer_static_libs=no
5152 preload=no
5153 prev=
5154 prevarg=
5155 release=
5156 rpath=
5157 xrpath=
5158 perm_rpath=
5159 temp_rpath=
5160 thread_safe=no
5161 vinfo=
5162 vinfo_number=no
5163 weak_libs=
5164 single_module="${wl}-single_module"
5165 func_infer_tag $base_compile
5166
5167 # We need to know -static, to get the right output filenames.
5168 for arg
5169 do
5170 case $arg in
5171 -shared)
5172 test "$build_libtool_libs" != yes && \
5173 func_fatal_configuration "can not build a shared library"
5174 build_old_libs=no
5175 break
5176 ;;
5177 -all-static | -static | -static-libtool-libs)
5178 case $arg in
5179 -all-static)
5180 if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then
5181 func_warning "complete static linking is impossible in this configuration"
5182 fi
5183 if test -n "$link_static_flag"; then
5184 dlopen_self=$dlopen_self_static
5185 fi
5186 prefer_static_libs=yes
5187 ;;
5188 -static)
5189 if test -z "$pic_flag" && test -n "$link_static_flag"; then
5190 dlopen_self=$dlopen_self_static
5191 fi
5192 prefer_static_libs=built
5193 ;;
5194 -static-libtool-libs)
5195 if test -z "$pic_flag" && test -n "$link_static_flag"; then
5196 dlopen_self=$dlopen_self_static
5197 fi
5198 prefer_static_libs=yes
5199 ;;
5200 esac
5201 build_libtool_libs=no
5202 build_old_libs=yes
5203 break
5204 ;;
5205 esac
5206 done
5207
5208 # See if our shared archives depend on static archives.
5209 test -n "$old_archive_from_new_cmds" && build_old_libs=yes
5210
5211 # Go through the arguments, transforming them on the way.
5212 while test "$#" -gt 0; do
5213 arg="$1"
5214 shift
5215 func_quote_for_eval "$arg"
5216 qarg=$func_quote_for_eval_unquoted_result
5217 func_append libtool_args " $func_quote_for_eval_result"
5218
5219 # If the previous option needs an argument, assign it.
5220 if test -n "$prev"; then
5221 case $prev in
5222 output)
5223 func_append compile_command " @OUTPUT@"
5224 func_append finalize_command " @OUTPUT@"
5225 ;;
5226 esac
5227
5228 case $prev in
5229 bindir)
5230 bindir="$arg"
5231 prev=
5232 continue
5233 ;;
5234 dlfiles|dlprefiles)
5235 if test "$preload" = no; then
5236 # Add the symbol object into the linking commands.
5237 func_append compile_command " @SYMFILE@"
5238 func_append finalize_command " @SYMFILE@"
5239 preload=yes
5240 fi
5241 case $arg in
5242 *.la | *.lo) ;; # We handle these cases below.
5243 force)
5244 if test "$dlself" = no; then
5245 dlself=needless
5246 export_dynamic=yes
5247 fi
5248 prev=
5249 continue
5250 ;;
5251 self)
5252 if test "$prev" = dlprefiles; then
5253 dlself=yes
5254 elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then
5255 dlself=yes
5256 else
5257 dlself=needless
5258 export_dynamic=yes
5259 fi
5260 prev=
5261 continue
5262 ;;
5263 *)
5264 if test "$prev" = dlfiles; then
5265 func_append dlfiles " $arg"
5266 else
5267 func_append dlprefiles " $arg"
5268 fi
5269 prev=
5270 continue
5271 ;;
5272 esac
5273 ;;
5274 expsyms)
5275 export_symbols="$arg"
5276 test -f "$arg" \
5277 || func_fatal_error "symbol file \`$arg' does not exist"
5278 prev=
5279 continue
5280 ;;
5281 expsyms_regex)
5282 export_symbols_regex="$arg"
5283 prev=
5284 continue
5285 ;;
5286 framework)
5287 case $host in
5288 *-*-darwin*)
5289 case "$deplibs " in
5290 *" $qarg.ltframework "*) ;;
5291 *) func_append deplibs " $qarg.ltframework" # this is fixed later
5292 ;;
5293 esac
5294 ;;
5295 esac
5296 prev=
5297 continue
5298 ;;
5299 inst_prefix)
5300 inst_prefix_dir="$arg"
5301 prev=
5302 continue
5303 ;;
5304 objectlist)
5305 if test -f "$arg"; then
5306 save_arg=$arg
5307 moreargs=
5308 for fil in `cat "$save_arg"`
5309 do
5310# func_append moreargs " $fil"
5311 arg=$fil
5312 # A libtool-controlled object.
5313
5314 # Check to see that this really is a libtool object.
5315 if func_lalib_unsafe_p "$arg"; then
5316 pic_object=
5317 non_pic_object=
5318
5319 # Read the .lo file
5320 func_source "$arg"
5321
5322 if test -z "$pic_object" ||
5323 test -z "$non_pic_object" ||
5324 test "$pic_object" = none &&
5325 test "$non_pic_object" = none; then
5326 func_fatal_error "cannot find name of object for \`$arg'"
5327 fi
5328
5329 # Extract subdirectory from the argument.
5330 func_dirname "$arg" "/" ""
5331 xdir="$func_dirname_result"
5332
5333 if test "$pic_object" != none; then
5334 # Prepend the subdirectory the object is found in.
5335 pic_object="$xdir$pic_object"
5336
5337 if test "$prev" = dlfiles; then
5338 if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
5339 func_append dlfiles " $pic_object"
5340 prev=
5341 continue
5342 else
5343 # If libtool objects are unsupported, then we need to preload.
5344 prev=dlprefiles
5345 fi
5346 fi
5347
5348 # CHECK ME: I think I busted this. -Ossama
5349 if test "$prev" = dlprefiles; then
5350 # Preload the old-style object.
5351 func_append dlprefiles " $pic_object"
5352 prev=
5353 fi
5354
5355 # A PIC object.
5356 func_append libobjs " $pic_object"
5357 arg="$pic_object"
5358 fi
5359
5360 # Non-PIC object.
5361 if test "$non_pic_object" != none; then
5362 # Prepend the subdirectory the object is found in.
5363 non_pic_object="$xdir$non_pic_object"
5364
5365 # A standard non-PIC object
5366 func_append non_pic_objects " $non_pic_object"
5367 if test -z "$pic_object" || test "$pic_object" = none ; then
5368 arg="$non_pic_object"
5369 fi
5370 else
5371 # If the PIC object exists, use it instead.
5372 # $xdir was prepended to $pic_object above.
5373 non_pic_object="$pic_object"
5374 func_append non_pic_objects " $non_pic_object"
5375 fi
5376 else
5377 # Only an error if not doing a dry-run.
5378 if $opt_dry_run; then
5379 # Extract subdirectory from the argument.
5380 func_dirname "$arg" "/" ""
5381 xdir="$func_dirname_result"
5382
5383 func_lo2o "$arg"
5384 pic_object=$xdir$objdir/$func_lo2o_result
5385 non_pic_object=$xdir$func_lo2o_result
5386 func_append libobjs " $pic_object"
5387 func_append non_pic_objects " $non_pic_object"
5388 else
5389 func_fatal_error "\`$arg' is not a valid libtool object"
5390 fi
5391 fi
5392 done
5393 else
5394 func_fatal_error "link input file \`$arg' does not exist"
5395 fi
5396 arg=$save_arg
5397 prev=
5398 continue
5399 ;;
5400 precious_regex)
5401 precious_files_regex="$arg"
5402 prev=
5403 continue
5404 ;;
5405 release)
5406 release="-$arg"
5407 prev=
5408 continue
5409 ;;
5410 rpath | xrpath)
5411 # We need an absolute path.
5412 case $arg in
5413 [\\/]* | [A-Za-z]:[\\/]*) ;;
5414 *)
5415 func_fatal_error "only absolute run-paths are allowed"
5416 ;;
5417 esac
5418 if test "$prev" = rpath; then
5419 case "$rpath " in
5420 *" $arg "*) ;;
5421 *) func_append rpath " $arg" ;;
5422 esac
5423 else
5424 case "$xrpath " in
5425 *" $arg "*) ;;
5426 *) func_append xrpath " $arg" ;;
5427 esac
5428 fi
5429 prev=
5430 continue
5431 ;;
5432 shrext)
5433 shrext_cmds="$arg"
5434 prev=
5435 continue
5436 ;;
5437 weak)
5438 func_append weak_libs " $arg"
5439 prev=
5440 continue
5441 ;;
5442 xcclinker)
5443 func_append linker_flags " $qarg"
5444 func_append compiler_flags " $qarg"
5445 prev=
5446 func_append compile_command " $qarg"
5447 func_append finalize_command " $qarg"
5448 continue
5449 ;;
5450 xcompiler)
5451 func_append compiler_flags " $qarg"
5452 prev=
5453 func_append compile_command " $qarg"
5454 func_append finalize_command " $qarg"
5455 continue
5456 ;;
5457 xlinker)
5458 func_append linker_flags " $qarg"
5459 func_append compiler_flags " $wl$qarg"
5460 prev=
5461 func_append compile_command " $wl$qarg"
5462 func_append finalize_command " $wl$qarg"
5463 continue
5464 ;;
5465 *)
5466 eval "$prev=\"\$arg\""
5467 prev=
5468 continue
5469 ;;
5470 esac
5471 fi # test -n "$prev"
5472
5473 prevarg="$arg"
5474
5475 case $arg in
5476 -all-static)
5477 if test -n "$link_static_flag"; then
5478 # See comment for -static flag below, for more details.
5479 func_append compile_command " $link_static_flag"
5480 func_append finalize_command " $link_static_flag"
5481 fi
5482 continue
5483 ;;
5484
5485 -allow-undefined)
5486 # FIXME: remove this flag sometime in the future.
5487 func_fatal_error "\`-allow-undefined' must not be used because it is the default"
5488 ;;
5489
5490 -avoid-version)
5491 avoid_version=yes
5492 continue
5493 ;;
5494
5495 -bindir)
5496 prev=bindir
5497 continue
5498 ;;
5499
5500 -dlopen)
5501 prev=dlfiles
5502 continue
5503 ;;
5504
5505 -dlpreopen)
5506 prev=dlprefiles
5507 continue
5508 ;;
5509
5510 -export-dynamic)
5511 export_dynamic=yes
5512 continue
5513 ;;
5514
5515 -export-symbols | -export-symbols-regex)
5516 if test -n "$export_symbols" || test -n "$export_symbols_regex"; then
5517 func_fatal_error "more than one -exported-symbols argument is not allowed"
5518 fi
5519 if test "X$arg" = "X-export-symbols"; then
5520 prev=expsyms
5521 else
5522 prev=expsyms_regex
5523 fi
5524 continue
5525 ;;
5526
5527 -framework)
5528 prev=framework
5529 continue
5530 ;;
5531
5532 -inst-prefix-dir)
5533 prev=inst_prefix
5534 continue
5535 ;;
5536
5537 # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:*
5538 # so, if we see these flags be careful not to treat them like -L
5539 -L[A-Z][A-Z]*:*)
5540 case $with_gcc/$host in
5541 no/*-*-irix* | /*-*-irix*)
5542 func_append compile_command " $arg"
5543 func_append finalize_command " $arg"
5544 ;;
5545 esac
5546 continue
5547 ;;
5548
5549 -L*)
5550 func_stripname "-L" '' "$arg"
5551 if test -z "$func_stripname_result"; then
5552 if test "$#" -gt 0; then
5553 func_fatal_error "require no space between \`-L' and \`$1'"
5554 else
5555 func_fatal_error "need path for \`-L' option"
5556 fi
5557 fi
5558 func_resolve_sysroot "$func_stripname_result"
5559 dir=$func_resolve_sysroot_result
5560 # We need an absolute path.
5561 case $dir in
5562 [\\/]* | [A-Za-z]:[\\/]*) ;;
5563 *)
5564 absdir=`cd "$dir" && pwd`
5565 test -z "$absdir" && \
5566 func_fatal_error "cannot determine absolute directory name of \`$dir'"
5567 dir="$absdir"
5568 ;;
5569 esac
5570 case "$deplibs " in
5571 *" -L$dir "* | *" $arg "*)
5572 # Will only happen for absolute or sysroot arguments
5573 ;;
5574 *)
5575 # Preserve sysroot, but never include relative directories
5576 case $dir in
5577 [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;;
5578 *) func_append deplibs " -L$dir" ;;
5579 esac
5580 func_append lib_search_path " $dir"
5581 ;;
5582 esac
5583 case $host in
5584 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
5585 testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'`
5586 case :$dllsearchpath: in
5587 *":$dir:"*) ;;
5588 ::) dllsearchpath=$dir;;
5589 *) func_append dllsearchpath ":$dir";;
5590 esac
5591 case :$dllsearchpath: in
5592 *":$testbindir:"*) ;;
5593 ::) dllsearchpath=$testbindir;;
5594 *) func_append dllsearchpath ":$testbindir";;
5595 esac
5596 ;;
5597 esac
5598 continue
5599 ;;
5600
5601 -l*)
5602 if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then
5603 case $host in
5604 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*)
5605 # These systems don't actually have a C or math library (as such)
5606 continue
5607 ;;
5608 *-*-os2*)
5609 # These systems don't actually have a C library (as such)
5610 test "X$arg" = "X-lc" && continue
5611 ;;
5612 *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
5613 # Do not include libc due to us having libc/libc_r.
5614 test "X$arg" = "X-lc" && continue
5615 ;;
5616 *-*-rhapsody* | *-*-darwin1.[012])
5617 # Rhapsody C and math libraries are in the System framework
5618 func_append deplibs " System.ltframework"
5619 continue
5620 ;;
5621 *-*-sco3.2v5* | *-*-sco5v6*)
5622 # Causes problems with __ctype
5623 test "X$arg" = "X-lc" && continue
5624 ;;
5625 *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*)
5626 # Compiler inserts libc in the correct place for threads to work
5627 test "X$arg" = "X-lc" && continue
5628 ;;
5629 esac
5630 elif test "X$arg" = "X-lc_r"; then
5631 case $host in
5632 *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
5633 # Do not include libc_r directly, use -pthread flag.
5634 continue
5635 ;;
5636 esac
5637 fi
5638 func_append deplibs " $arg"
5639 continue
5640 ;;
5641
5642 -module)
5643 module=yes
5644 continue
5645 ;;
5646
5647 # Tru64 UNIX uses -model [arg] to determine the layout of C++
5648 # classes, name mangling, and exception handling.
5649 # Darwin uses the -arch flag to determine output architecture.
5650 -model|-arch|-isysroot|--sysroot)
5651 func_append compiler_flags " $arg"
5652 func_append compile_command " $arg"
5653 func_append finalize_command " $arg"
5654 prev=xcompiler
5655 continue
5656 ;;
5657
5658 -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \
5659 |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*)
5660 func_append compiler_flags " $arg"
5661 func_append compile_command " $arg"
5662 func_append finalize_command " $arg"
5663 case "$new_inherited_linker_flags " in
5664 *" $arg "*) ;;
5665 * ) func_append new_inherited_linker_flags " $arg" ;;
5666 esac
5667 continue
5668 ;;
5669
5670 -multi_module)
5671 single_module="${wl}-multi_module"
5672 continue
5673 ;;
5674
5675 -no-fast-install)
5676 fast_install=no
5677 continue
5678 ;;
5679
5680 -no-install)
5681 case $host in
5682 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*)
5683 # The PATH hackery in wrapper scripts is required on Windows
5684 # and Darwin in order for the loader to find any dlls it needs.
5685 func_warning "\`-no-install' is ignored for $host"
5686 func_warning "assuming \`-no-fast-install' instead"
5687 fast_install=no
5688 ;;
5689 *) no_install=yes ;;
5690 esac
5691 continue
5692 ;;
5693
5694 -no-undefined)
5695 allow_undefined=no
5696 continue
5697 ;;
5698
5699 -objectlist)
5700 prev=objectlist
5701 continue
5702 ;;
5703
5704 -o) prev=output ;;
5705
5706 -precious-files-regex)
5707 prev=precious_regex
5708 continue
5709 ;;
5710
5711 -release)
5712 prev=release
5713 continue
5714 ;;
5715
5716 -rpath)
5717 prev=rpath
5718 continue
5719 ;;
5720
5721 -R)
5722 prev=xrpath
5723 continue
5724 ;;
5725
5726 -R*)
5727 func_stripname '-R' '' "$arg"
5728 dir=$func_stripname_result
5729 # We need an absolute path.
5730 case $dir in
5731 [\\/]* | [A-Za-z]:[\\/]*) ;;
5732 =*)
5733 func_stripname '=' '' "$dir"
5734 dir=$lt_sysroot$func_stripname_result
5735 ;;
5736 *)
5737 func_fatal_error "only absolute run-paths are allowed"
5738 ;;
5739 esac
5740 case "$xrpath " in
5741 *" $dir "*) ;;
5742 *) func_append xrpath " $dir" ;;
5743 esac
5744 continue
5745 ;;
5746
5747 -shared)
5748 # The effects of -shared are defined in a previous loop.
5749 continue
5750 ;;
5751
5752 -shrext)
5753 prev=shrext
5754 continue
5755 ;;
5756
5757 -static | -static-libtool-libs)
5758 # The effects of -static are defined in a previous loop.
5759 # We used to do the same as -all-static on platforms that
5760 # didn't have a PIC flag, but the assumption that the effects
5761 # would be equivalent was wrong. It would break on at least
5762 # Digital Unix and AIX.
5763 continue
5764 ;;
5765
5766 -thread-safe)
5767 thread_safe=yes
5768 continue
5769 ;;
5770
5771 -version-info)
5772 prev=vinfo
5773 continue
5774 ;;
5775
5776 -version-number)
5777 prev=vinfo
5778 vinfo_number=yes
5779 continue
5780 ;;
5781
5782 -weak)
5783 prev=weak
5784 continue
5785 ;;
5786
5787 -Wc,*)
5788 func_stripname '-Wc,' '' "$arg"
5789 args=$func_stripname_result
5790 arg=
5791 save_ifs="$IFS"; IFS=','
5792 for flag in $args; do
5793 IFS="$save_ifs"
5794 func_quote_for_eval "$flag"
5795 func_append arg " $func_quote_for_eval_result"
5796 func_append compiler_flags " $func_quote_for_eval_result"
5797 done
5798 IFS="$save_ifs"
5799 func_stripname ' ' '' "$arg"
5800 arg=$func_stripname_result
5801 ;;
5802
5803 -Wl,*)
5804 func_stripname '-Wl,' '' "$arg"
5805 args=$func_stripname_result
5806 arg=
5807 save_ifs="$IFS"; IFS=','
5808 for flag in $args; do
5809 IFS="$save_ifs"
5810 func_quote_for_eval "$flag"
5811 func_append arg " $wl$func_quote_for_eval_result"
5812 func_append compiler_flags " $wl$func_quote_for_eval_result"
5813 func_append linker_flags " $func_quote_for_eval_result"
5814 done
5815 IFS="$save_ifs"
5816 func_stripname ' ' '' "$arg"
5817 arg=$func_stripname_result
5818 ;;
5819
5820 -Xcompiler)
5821 prev=xcompiler
5822 continue
5823 ;;
5824
5825 -Xlinker)
5826 prev=xlinker
5827 continue
5828 ;;
5829
5830 -XCClinker)
5831 prev=xcclinker
5832 continue
5833 ;;
5834
5835 # -msg_* for osf cc
5836 -msg_*)
5837 func_quote_for_eval "$arg"
5838 arg="$func_quote_for_eval_result"
5839 ;;
5840
5841 # Flags to be passed through unchanged, with rationale:
5842 # -64, -mips[0-9] enable 64-bit mode for the SGI compiler
5843 # -r[0-9][0-9]* specify processor for the SGI compiler
5844 # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler
5845 # +DA*, +DD* enable 64-bit mode for the HP compiler
5846 # -q* compiler args for the IBM compiler
5847 # -m*, -t[45]*, -txscale* architecture-specific flags for GCC
5848 # -F/path path to uninstalled frameworks, gcc on darwin
5849 # -p, -pg, --coverage, -fprofile-* profiling flags for GCC
5850 # @file GCC response files
5851 # -tp=* Portland pgcc target processor selection
5852 # --sysroot=* for sysroot support
5853 # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization
5854 -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
5855 -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \
5856 -O*|-flto*|-fwhopr*|-fuse-linker-plugin)
5857 func_quote_for_eval "$arg"
5858 arg="$func_quote_for_eval_result"
5859 func_append compile_command " $arg"
5860 func_append finalize_command " $arg"
5861 func_append compiler_flags " $arg"
5862 continue
5863 ;;
5864
5865 # Some other compiler flag.
5866 -* | +*)
5867 func_quote_for_eval "$arg"
5868 arg="$func_quote_for_eval_result"
5869 ;;
5870
5871 *.$objext)
5872 # A standard object.
5873 func_append objs " $arg"
5874 ;;
5875
5876 *.lo)
5877 # A libtool-controlled object.
5878
5879 # Check to see that this really is a libtool object.
5880 if func_lalib_unsafe_p "$arg"; then
5881 pic_object=
5882 non_pic_object=
5883
5884 # Read the .lo file
5885 func_source "$arg"
5886
5887 if test -z "$pic_object" ||
5888 test -z "$non_pic_object" ||
5889 test "$pic_object" = none &&
5890 test "$non_pic_object" = none; then
5891 func_fatal_error "cannot find name of object for \`$arg'"
5892 fi
5893
5894 # Extract subdirectory from the argument.
5895 func_dirname "$arg" "/" ""
5896 xdir="$func_dirname_result"
5897
5898 if test "$pic_object" != none; then
5899 # Prepend the subdirectory the object is found in.
5900 pic_object="$xdir$pic_object"
5901
5902 if test "$prev" = dlfiles; then
5903 if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
5904 func_append dlfiles " $pic_object"
5905 prev=
5906 continue
5907 else
5908 # If libtool objects are unsupported, then we need to preload.
5909 prev=dlprefiles
5910 fi
5911 fi
5912
5913 # CHECK ME: I think I busted this. -Ossama
5914 if test "$prev" = dlprefiles; then
5915 # Preload the old-style object.
5916 func_append dlprefiles " $pic_object"
5917 prev=
5918 fi
5919
5920 # A PIC object.
5921 func_append libobjs " $pic_object"
5922 arg="$pic_object"
5923 fi
5924
5925 # Non-PIC object.
5926 if test "$non_pic_object" != none; then
5927 # Prepend the subdirectory the object is found in.
5928 non_pic_object="$xdir$non_pic_object"
5929
5930 # A standard non-PIC object
5931 func_append non_pic_objects " $non_pic_object"
5932 if test -z "$pic_object" || test "$pic_object" = none ; then
5933 arg="$non_pic_object"
5934 fi
5935 else
5936 # If the PIC object exists, use it instead.
5937 # $xdir was prepended to $pic_object above.
5938 non_pic_object="$pic_object"
5939 func_append non_pic_objects " $non_pic_object"
5940 fi
5941 else
5942 # Only an error if not doing a dry-run.
5943 if $opt_dry_run; then
5944 # Extract subdirectory from the argument.
5945 func_dirname "$arg" "/" ""
5946 xdir="$func_dirname_result"
5947
5948 func_lo2o "$arg"
5949 pic_object=$xdir$objdir/$func_lo2o_result
5950 non_pic_object=$xdir$func_lo2o_result
5951 func_append libobjs " $pic_object"
5952 func_append non_pic_objects " $non_pic_object"
5953 else
5954 func_fatal_error "\`$arg' is not a valid libtool object"
5955 fi
5956 fi
5957 ;;
5958
5959 *.$libext)
5960 # An archive.
5961 func_append deplibs " $arg"
5962 func_append old_deplibs " $arg"
5963 continue
5964 ;;
5965
5966 *.la)
5967 # A libtool-controlled library.
5968
5969 func_resolve_sysroot "$arg"
5970 if test "$prev" = dlfiles; then
5971 # This library was specified with -dlopen.
5972 func_append dlfiles " $func_resolve_sysroot_result"
5973 prev=
5974 elif test "$prev" = dlprefiles; then
5975 # The library was specified with -dlpreopen.
5976 func_append dlprefiles " $func_resolve_sysroot_result"
5977 prev=
5978 else
5979 func_append deplibs " $func_resolve_sysroot_result"
5980 fi
5981 continue
5982 ;;
5983
5984 # Some other compiler argument.
5985 *)
5986 # Unknown arguments in both finalize_command and compile_command need
5987 # to be aesthetically quoted because they are evaled later.
5988 func_quote_for_eval "$arg"
5989 arg="$func_quote_for_eval_result"
5990 ;;
5991 esac # arg
5992
5993 # Now actually substitute the argument into the commands.
5994 if test -n "$arg"; then
5995 func_append compile_command " $arg"
5996 func_append finalize_command " $arg"
5997 fi
5998 done # argument parsing loop
5999
6000 test -n "$prev" && \
6001 func_fatal_help "the \`$prevarg' option requires an argument"
6002
6003 if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then
6004 eval arg=\"$export_dynamic_flag_spec\"
6005 func_append compile_command " $arg"
6006 func_append finalize_command " $arg"
6007 fi
6008
6009 oldlibs=
6010 # calculate the name of the file, without its directory
6011 func_basename "$output"
6012 outputname="$func_basename_result"
6013 libobjs_save="$libobjs"
6014
6015 if test -n "$shlibpath_var"; then
6016 # get the directories listed in $shlibpath_var
6017 eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\`
6018 else
6019 shlib_search_path=
6020 fi
6021 eval sys_lib_search_path=\"$sys_lib_search_path_spec\"
6022 eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\"
6023
6024 func_dirname "$output" "/" ""
6025 output_objdir="$func_dirname_result$objdir"
6026 func_to_tool_file "$output_objdir/"
6027 tool_output_objdir=$func_to_tool_file_result
6028 # Create the object directory.
6029 func_mkdir_p "$output_objdir"
6030
6031 # Determine the type of output
6032 case $output in
6033 "")
6034 func_fatal_help "you must specify an output file"
6035 ;;
6036 *.$libext) linkmode=oldlib ;;
6037 *.lo | *.$objext) linkmode=obj ;;
6038 *.la) linkmode=lib ;;
6039 *) linkmode=prog ;; # Anything else should be a program.
6040 esac
6041
6042 specialdeplibs=
6043
6044 libs=
6045 # Find all interdependent deplibs by searching for libraries
6046 # that are linked more than once (e.g. -la -lb -la)
6047 for deplib in $deplibs; do
6048 if $opt_preserve_dup_deps ; then
6049 case "$libs " in
6050 *" $deplib "*) func_append specialdeplibs " $deplib" ;;
6051 esac
6052 fi
6053 func_append libs " $deplib"
6054 done
6055
6056 if test "$linkmode" = lib; then
6057 libs="$predeps $libs $compiler_lib_search_path $postdeps"
6058
6059 # Compute libraries that are listed more than once in $predeps
6060 # $postdeps and mark them as special (i.e., whose duplicates are
6061 # not to be eliminated).
6062 pre_post_deps=
6063 if $opt_duplicate_compiler_generated_deps; then
6064 for pre_post_dep in $predeps $postdeps; do
6065 case "$pre_post_deps " in
6066 *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;;
6067 esac
6068 func_append pre_post_deps " $pre_post_dep"
6069 done
6070 fi
6071 pre_post_deps=
6072 fi
6073
6074 deplibs=
6075 newdependency_libs=
6076 newlib_search_path=
6077 need_relink=no # whether we're linking any uninstalled libtool libraries
6078 notinst_deplibs= # not-installed libtool libraries
6079 notinst_path= # paths that contain not-installed libtool libraries
6080
6081 case $linkmode in
6082 lib)
6083 passes="conv dlpreopen link"
6084 for file in $dlfiles $dlprefiles; do
6085 case $file in
6086 *.la) ;;
6087 *)
6088 func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file"
6089 ;;
6090 esac
6091 done
6092 ;;
6093 prog)
6094 compile_deplibs=
6095 finalize_deplibs=
6096 alldeplibs=no
6097 newdlfiles=
6098 newdlprefiles=
6099 passes="conv scan dlopen dlpreopen link"
6100 ;;
6101 *) passes="conv"
6102 ;;
6103 esac
6104
6105 for pass in $passes; do
6106 # The preopen pass in lib mode reverses $deplibs; put it back here
6107 # so that -L comes before libs that need it for instance...
6108 if test "$linkmode,$pass" = "lib,link"; then
6109 ## FIXME: Find the place where the list is rebuilt in the wrong
6110 ## order, and fix it there properly
6111 tmp_deplibs=
6112 for deplib in $deplibs; do
6113 tmp_deplibs="$deplib $tmp_deplibs"
6114 done
6115 deplibs="$tmp_deplibs"
6116 fi
6117
6118 if test "$linkmode,$pass" = "lib,link" ||
6119 test "$linkmode,$pass" = "prog,scan"; then
6120 libs="$deplibs"
6121 deplibs=
6122 fi
6123 if test "$linkmode" = prog; then
6124 case $pass in
6125 dlopen) libs="$dlfiles" ;;
6126 dlpreopen) libs="$dlprefiles" ;;
6127 link) libs="$deplibs %DEPLIBS% $dependency_libs" ;;
6128 esac
6129 fi
6130 if test "$linkmode,$pass" = "lib,dlpreopen"; then
6131 # Collect and forward deplibs of preopened libtool libs
6132 for lib in $dlprefiles; do
6133 # Ignore non-libtool-libs
6134 dependency_libs=
6135 func_resolve_sysroot "$lib"
6136 case $lib in
6137 *.la) func_source "$func_resolve_sysroot_result" ;;
6138 esac
6139
6140 # Collect preopened libtool deplibs, except any this library
6141 # has declared as weak libs
6142 for deplib in $dependency_libs; do
6143 func_basename "$deplib"
6144 deplib_base=$func_basename_result
6145 case " $weak_libs " in
6146 *" $deplib_base "*) ;;
6147 *) func_append deplibs " $deplib" ;;
6148 esac
6149 done
6150 done
6151 libs="$dlprefiles"
6152 fi
6153 if test "$pass" = dlopen; then
6154 # Collect dlpreopened libraries
6155 save_deplibs="$deplibs"
6156 deplibs=
6157 fi
6158
6159 for deplib in $libs; do
6160 lib=
6161 found=no
6162 case $deplib in
6163 -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \
6164 |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*)
6165 if test "$linkmode,$pass" = "prog,link"; then
6166 compile_deplibs="$deplib $compile_deplibs"
6167 finalize_deplibs="$deplib $finalize_deplibs"
6168 else
6169 func_append compiler_flags " $deplib"
6170 if test "$linkmode" = lib ; then
6171 case "$new_inherited_linker_flags " in
6172 *" $deplib "*) ;;
6173 * ) func_append new_inherited_linker_flags " $deplib" ;;
6174 esac
6175 fi
6176 fi
6177 continue
6178 ;;
6179 -l*)
6180 if test "$linkmode" != lib && test "$linkmode" != prog; then
6181 func_warning "\`-l' is ignored for archives/objects"
6182 continue
6183 fi
6184 func_stripname '-l' '' "$deplib"
6185 name=$func_stripname_result
6186 if test "$linkmode" = lib; then
6187 searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path"
6188 else
6189 searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path"
6190 fi
6191 for searchdir in $searchdirs; do
6192 for search_ext in .la $std_shrext .so .a; do
6193 # Search the libtool library
6194 lib="$searchdir/lib${name}${search_ext}"
6195 if test -f "$lib"; then
6196 if test "$search_ext" = ".la"; then
6197 found=yes
6198 else
6199 found=no
6200 fi
6201 break 2
6202 fi
6203 done
6204 done
6205 if test "$found" != yes; then
6206 # deplib doesn't seem to be a libtool library
6207 if test "$linkmode,$pass" = "prog,link"; then
6208 compile_deplibs="$deplib $compile_deplibs"
6209 finalize_deplibs="$deplib $finalize_deplibs"
6210 else
6211 deplibs="$deplib $deplibs"
6212 test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
6213 fi
6214 continue
6215 else # deplib is a libtool library
6216 # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib,
6217 # We need to do some special things here, and not later.
6218 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
6219 case " $predeps $postdeps " in
6220 *" $deplib "*)
6221 if func_lalib_p "$lib"; then
6222 library_names=
6223 old_library=
6224 func_source "$lib"
6225 for l in $old_library $library_names; do
6226 ll="$l"
6227 done
6228 if test "X$ll" = "X$old_library" ; then # only static version available
6229 found=no
6230 func_dirname "$lib" "" "."
6231 ladir="$func_dirname_result"
6232 lib=$ladir/$old_library
6233 if test "$linkmode,$pass" = "prog,link"; then
6234 compile_deplibs="$deplib $compile_deplibs"
6235 finalize_deplibs="$deplib $finalize_deplibs"
6236 else
6237 deplibs="$deplib $deplibs"
6238 test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
6239 fi
6240 continue
6241 fi
6242 fi
6243 ;;
6244 *) ;;
6245 esac
6246 fi
6247 fi
6248 ;; # -l
6249 *.ltframework)
6250 if test "$linkmode,$pass" = "prog,link"; then
6251 compile_deplibs="$deplib $compile_deplibs"
6252 finalize_deplibs="$deplib $finalize_deplibs"
6253 else
6254 deplibs="$deplib $deplibs"
6255 if test "$linkmode" = lib ; then
6256 case "$new_inherited_linker_flags " in
6257 *" $deplib "*) ;;
6258 * ) func_append new_inherited_linker_flags " $deplib" ;;
6259 esac
6260 fi
6261 fi
6262 continue
6263 ;;
6264 -L*)
6265 case $linkmode in
6266 lib)
6267 deplibs="$deplib $deplibs"
6268 test "$pass" = conv && continue
6269 newdependency_libs="$deplib $newdependency_libs"
6270 func_stripname '-L' '' "$deplib"
6271 func_resolve_sysroot "$func_stripname_result"
6272 func_append newlib_search_path " $func_resolve_sysroot_result"
6273 ;;
6274 prog)
6275 if test "$pass" = conv; then
6276 deplibs="$deplib $deplibs"
6277 continue
6278 fi
6279 if test "$pass" = scan; then
6280 deplibs="$deplib $deplibs"
6281 else
6282 compile_deplibs="$deplib $compile_deplibs"
6283 finalize_deplibs="$deplib $finalize_deplibs"
6284 fi
6285 func_stripname '-L' '' "$deplib"
6286 func_resolve_sysroot "$func_stripname_result"
6287 func_append newlib_search_path " $func_resolve_sysroot_result"
6288 ;;
6289 *)
6290 func_warning "\`-L' is ignored for archives/objects"
6291 ;;
6292 esac # linkmode
6293 continue
6294 ;; # -L
6295 -R*)
6296 if test "$pass" = link; then
6297 func_stripname '-R' '' "$deplib"
6298 func_resolve_sysroot "$func_stripname_result"
6299 dir=$func_resolve_sysroot_result
6300 # Make sure the xrpath contains only unique directories.
6301 case "$xrpath " in
6302 *" $dir "*) ;;
6303 *) func_append xrpath " $dir" ;;
6304 esac
6305 fi
6306 deplibs="$deplib $deplibs"
6307 continue
6308 ;;
6309 *.la)
6310 func_resolve_sysroot "$deplib"
6311 lib=$func_resolve_sysroot_result
6312 ;;
6313 *.$libext)
6314 if test "$pass" = conv; then
6315 deplibs="$deplib $deplibs"
6316 continue
6317 fi
6318 case $linkmode in
6319 lib)
6320 # Linking convenience modules into shared libraries is allowed,
6321 # but linking other static libraries is non-portable.
6322 case " $dlpreconveniencelibs " in
6323 *" $deplib "*) ;;
6324 *)
6325 valid_a_lib=no
6326 case $deplibs_check_method in
6327 match_pattern*)
6328 set dummy $deplibs_check_method; shift
6329 match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
6330 if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \
6331 | $EGREP "$match_pattern_regex" > /dev/null; then
6332 valid_a_lib=yes
6333 fi
6334 ;;
6335 pass_all)
6336 valid_a_lib=yes
6337 ;;
6338 esac
6339 if test "$valid_a_lib" != yes; then
6340 echo
6341 $ECHO "*** Warning: Trying to link with static lib archive $deplib."
6342 echo "*** I have the capability to make that library automatically link in when"
6343 echo "*** you link to this library. But I can only do this if you have a"
6344 echo "*** shared version of the library, which you do not appear to have"
6345 echo "*** because the file extensions .$libext of this argument makes me believe"
6346 echo "*** that it is just a static archive that I should not use here."
6347 else
6348 echo
6349 $ECHO "*** Warning: Linking the shared library $output against the"
6350 $ECHO "*** static library $deplib is not portable!"
6351 deplibs="$deplib $deplibs"
6352 fi
6353 ;;
6354 esac
6355 continue
6356 ;;
6357 prog)
6358 if test "$pass" != link; then
6359 deplibs="$deplib $deplibs"
6360 else
6361 compile_deplibs="$deplib $compile_deplibs"
6362 finalize_deplibs="$deplib $finalize_deplibs"
6363 fi
6364 continue
6365 ;;
6366 esac # linkmode
6367 ;; # *.$libext
6368 *.lo | *.$objext)
6369 if test "$pass" = conv; then
6370 deplibs="$deplib $deplibs"
6371 elif test "$linkmode" = prog; then
6372 if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then
6373 # If there is no dlopen support or we're linking statically,
6374 # we need to preload.
6375 func_append newdlprefiles " $deplib"
6376 compile_deplibs="$deplib $compile_deplibs"
6377 finalize_deplibs="$deplib $finalize_deplibs"
6378 else
6379 func_append newdlfiles " $deplib"
6380 fi
6381 fi
6382 continue
6383 ;;
6384 %DEPLIBS%)
6385 alldeplibs=yes
6386 continue
6387 ;;
6388 esac # case $deplib
6389
6390 if test "$found" = yes || test -f "$lib"; then :
6391 else
6392 func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'"
6393 fi
6394
6395 # Check to see that this really is a libtool archive.
6396 func_lalib_unsafe_p "$lib" \
6397 || func_fatal_error "\`$lib' is not a valid libtool archive"
6398
6399 func_dirname "$lib" "" "."
6400 ladir="$func_dirname_result"
6401
6402 dlname=
6403 dlopen=
6404 dlpreopen=
6405 libdir=
6406 library_names=
6407 old_library=
6408 inherited_linker_flags=
6409 # If the library was installed with an old release of libtool,
6410 # it will not redefine variables installed, or shouldnotlink
6411 installed=yes
6412 shouldnotlink=no
6413 avoidtemprpath=
6414
6415
6416 # Read the .la file
6417 func_source "$lib"
6418
6419 # Convert "-framework foo" to "foo.ltframework"
6420 if test -n "$inherited_linker_flags"; then
6421 tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'`
6422 for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do
6423 case " $new_inherited_linker_flags " in
6424 *" $tmp_inherited_linker_flag "*) ;;
6425 *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";;
6426 esac
6427 done
6428 fi
6429 dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
6430 if test "$linkmode,$pass" = "lib,link" ||
6431 test "$linkmode,$pass" = "prog,scan" ||
6432 { test "$linkmode" != prog && test "$linkmode" != lib; }; then
6433 test -n "$dlopen" && func_append dlfiles " $dlopen"
6434 test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen"
6435 fi
6436
6437 if test "$pass" = conv; then
6438 # Only check for convenience libraries
6439 deplibs="$lib $deplibs"
6440 if test -z "$libdir"; then
6441 if test -z "$old_library"; then
6442 func_fatal_error "cannot find name of link library for \`$lib'"
6443 fi
6444 # It is a libtool convenience library, so add in its objects.
6445 func_append convenience " $ladir/$objdir/$old_library"
6446 func_append old_convenience " $ladir/$objdir/$old_library"
6447 elif test "$linkmode" != prog && test "$linkmode" != lib; then
6448 func_fatal_error "\`$lib' is not a convenience library"
6449 fi
6450 tmp_libs=
6451 for deplib in $dependency_libs; do
6452 deplibs="$deplib $deplibs"
6453 if $opt_preserve_dup_deps ; then
6454 case "$tmp_libs " in
6455 *" $deplib "*) func_append specialdeplibs " $deplib" ;;
6456 esac
6457 fi
6458 func_append tmp_libs " $deplib"
6459 done
6460 continue
6461 fi # $pass = conv
6462
6463
6464 # Get the name of the library we link against.
6465 linklib=
6466 if test -n "$old_library" &&
6467 { test "$prefer_static_libs" = yes ||
6468 test "$prefer_static_libs,$installed" = "built,no"; }; then
6469 linklib=$old_library
6470 else
6471 for l in $old_library $library_names; do
6472 linklib="$l"
6473 done
6474 fi
6475 if test -z "$linklib"; then
6476 func_fatal_error "cannot find name of link library for \`$lib'"
6477 fi
6478
6479 # This library was specified with -dlopen.
6480 if test "$pass" = dlopen; then
6481 if test -z "$libdir"; then
6482 func_fatal_error "cannot -dlopen a convenience library: \`$lib'"
6483 fi
6484 if test -z "$dlname" ||
6485 test "$dlopen_support" != yes ||
6486 test "$build_libtool_libs" = no; then
6487 # If there is no dlname, no dlopen support or we're linking
6488 # statically, we need to preload. We also need to preload any
6489 # dependent libraries so libltdl's deplib preloader doesn't
6490 # bomb out in the load deplibs phase.
6491 func_append dlprefiles " $lib $dependency_libs"
6492 else
6493 func_append newdlfiles " $lib"
6494 fi
6495 continue
6496 fi # $pass = dlopen
6497
6498 # We need an absolute path.
6499 case $ladir in
6500 [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;;
6501 *)
6502 abs_ladir=`cd "$ladir" && pwd`
6503 if test -z "$abs_ladir"; then
6504 func_warning "cannot determine absolute directory name of \`$ladir'"
6505 func_warning "passing it literally to the linker, although it might fail"
6506 abs_ladir="$ladir"
6507 fi
6508 ;;
6509 esac
6510 func_basename "$lib"
6511 laname="$func_basename_result"
6512
6513 # Find the relevant object directory and library name.
6514 if test "X$installed" = Xyes; then
6515 if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
6516 func_warning "library \`$lib' was moved."
6517 dir="$ladir"
6518 absdir="$abs_ladir"
6519 libdir="$abs_ladir"
6520 else
6521 dir="$lt_sysroot$libdir"
6522 absdir="$lt_sysroot$libdir"
6523 fi
6524 test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes
6525 else
6526 if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then
6527 dir="$ladir"
6528 absdir="$abs_ladir"
6529 # Remove this search path later
6530 func_append notinst_path " $abs_ladir"
6531 else
6532 dir="$ladir/$objdir"
6533 absdir="$abs_ladir/$objdir"
6534 # Remove this search path later
6535 func_append notinst_path " $abs_ladir"
6536 fi
6537 fi # $installed = yes
6538 func_stripname 'lib' '.la' "$laname"
6539 name=$func_stripname_result
6540
6541 # This library was specified with -dlpreopen.
6542 if test "$pass" = dlpreopen; then
6543 if test -z "$libdir" && test "$linkmode" = prog; then
6544 func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'"
6545 fi
6546 case "$host" in
6547 # special handling for platforms with PE-DLLs.
6548 *cygwin* | *mingw* | *cegcc* )
6549 # Linker will automatically link against shared library if both
6550 # static and shared are present. Therefore, ensure we extract
6551 # symbols from the import library if a shared library is present
6552 # (otherwise, the dlopen module name will be incorrect). We do
6553 # this by putting the import library name into $newdlprefiles.
6554 # We recover the dlopen module name by 'saving' the la file
6555 # name in a special purpose variable, and (later) extracting the
6556 # dlname from the la file.
6557 if test -n "$dlname"; then
6558 func_tr_sh "$dir/$linklib"
6559 eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname"
6560 func_append newdlprefiles " $dir/$linklib"
6561 else
6562 func_append newdlprefiles " $dir/$old_library"
6563 # Keep a list of preopened convenience libraries to check
6564 # that they are being used correctly in the link pass.
6565 test -z "$libdir" && \
6566 func_append dlpreconveniencelibs " $dir/$old_library"
6567 fi
6568 ;;
6569 * )
6570 # Prefer using a static library (so that no silly _DYNAMIC symbols
6571 # are required to link).
6572 if test -n "$old_library"; then
6573 func_append newdlprefiles " $dir/$old_library"
6574 # Keep a list of preopened convenience libraries to check
6575 # that they are being used correctly in the link pass.
6576 test -z "$libdir" && \
6577 func_append dlpreconveniencelibs " $dir/$old_library"
6578 # Otherwise, use the dlname, so that lt_dlopen finds it.
6579 elif test -n "$dlname"; then
6580 func_append newdlprefiles " $dir/$dlname"
6581 else
6582 func_append newdlprefiles " $dir/$linklib"
6583 fi
6584 ;;
6585 esac
6586 fi # $pass = dlpreopen
6587
6588 if test -z "$libdir"; then
6589 # Link the convenience library
6590 if test "$linkmode" = lib; then
6591 deplibs="$dir/$old_library $deplibs"
6592 elif test "$linkmode,$pass" = "prog,link"; then
6593 compile_deplibs="$dir/$old_library $compile_deplibs"
6594 finalize_deplibs="$dir/$old_library $finalize_deplibs"
6595 else
6596 deplibs="$lib $deplibs" # used for prog,scan pass
6597 fi
6598 continue
6599 fi
6600
6601
6602 if test "$linkmode" = prog && test "$pass" != link; then
6603 func_append newlib_search_path " $ladir"
6604 deplibs="$lib $deplibs"
6605
6606 linkalldeplibs=no
6607 if test "$link_all_deplibs" != no || test -z "$library_names" ||
6608 test "$build_libtool_libs" = no; then
6609 linkalldeplibs=yes
6610 fi
6611
6612 tmp_libs=
6613 for deplib in $dependency_libs; do
6614 case $deplib in
6615 -L*) func_stripname '-L' '' "$deplib"
6616 func_resolve_sysroot "$func_stripname_result"
6617 func_append newlib_search_path " $func_resolve_sysroot_result"
6618 ;;
6619 esac
6620 # Need to link against all dependency_libs?
6621 if test "$linkalldeplibs" = yes; then
6622 deplibs="$deplib $deplibs"
6623 else
6624 # Need to hardcode shared library paths
6625 # or/and link against static libraries
6626 newdependency_libs="$deplib $newdependency_libs"
6627 fi
6628 if $opt_preserve_dup_deps ; then
6629 case "$tmp_libs " in
6630 *" $deplib "*) func_append specialdeplibs " $deplib" ;;
6631 esac
6632 fi
6633 func_append tmp_libs " $deplib"
6634 done # for deplib
6635 continue
6636 fi # $linkmode = prog...
6637
6638 if test "$linkmode,$pass" = "prog,link"; then
6639 if test -n "$library_names" &&
6640 { { test "$prefer_static_libs" = no ||
6641 test "$prefer_static_libs,$installed" = "built,yes"; } ||
6642 test -z "$old_library"; }; then
6643 # We need to hardcode the library path
6644 if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then
6645 # Make sure the rpath contains only unique directories.
6646 case "$temp_rpath:" in
6647 *"$absdir:"*) ;;
6648 *) func_append temp_rpath "$absdir:" ;;
6649 esac
6650 fi
6651
6652 # Hardcode the library path.
6653 # Skip directories that are in the system default run-time
6654 # search path.
6655 case " $sys_lib_dlsearch_path " in
6656 *" $absdir "*) ;;
6657 *)
6658 case "$compile_rpath " in
6659 *" $absdir "*) ;;
6660 *) func_append compile_rpath " $absdir" ;;
6661 esac
6662 ;;
6663 esac
6664 case " $sys_lib_dlsearch_path " in
6665 *" $libdir "*) ;;
6666 *)
6667 case "$finalize_rpath " in
6668 *" $libdir "*) ;;
6669 *) func_append finalize_rpath " $libdir" ;;
6670 esac
6671 ;;
6672 esac
6673 fi # $linkmode,$pass = prog,link...
6674
6675 if test "$alldeplibs" = yes &&
6676 { test "$deplibs_check_method" = pass_all ||
6677 { test "$build_libtool_libs" = yes &&
6678 test -n "$library_names"; }; }; then
6679 # We only need to search for static libraries
6680 continue
6681 fi
6682 fi
6683
6684 link_static=no # Whether the deplib will be linked statically
6685 use_static_libs=$prefer_static_libs
6686 if test "$use_static_libs" = built && test "$installed" = yes; then
6687 use_static_libs=no
6688 fi
6689 if test -n "$library_names" &&
6690 { test "$use_static_libs" = no || test -z "$old_library"; }; then
6691 case $host in
6692 *cygwin* | *mingw* | *cegcc*)
6693 # No point in relinking DLLs because paths are not encoded
6694 func_append notinst_deplibs " $lib"
6695 need_relink=no
6696 ;;
6697 *)
6698 if test "$installed" = no; then
6699 func_append notinst_deplibs " $lib"
6700 need_relink=yes
6701 fi
6702 ;;
6703 esac
6704 # This is a shared library
6705
6706 # Warn about portability, can't link against -module's on some
6707 # systems (darwin). Don't bleat about dlopened modules though!
6708 dlopenmodule=""
6709 for dlpremoduletest in $dlprefiles; do
6710 if test "X$dlpremoduletest" = "X$lib"; then
6711 dlopenmodule="$dlpremoduletest"
6712 break
6713 fi
6714 done
6715 if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then
6716 echo
6717 if test "$linkmode" = prog; then
6718 $ECHO "*** Warning: Linking the executable $output against the loadable module"
6719 else
6720 $ECHO "*** Warning: Linking the shared library $output against the loadable module"
6721 fi
6722 $ECHO "*** $linklib is not portable!"
6723 fi
6724 if test "$linkmode" = lib &&
6725 test "$hardcode_into_libs" = yes; then
6726 # Hardcode the library path.
6727 # Skip directories that are in the system default run-time
6728 # search path.
6729 case " $sys_lib_dlsearch_path " in
6730 *" $absdir "*) ;;
6731 *)
6732 case "$compile_rpath " in
6733 *" $absdir "*) ;;
6734 *) func_append compile_rpath " $absdir" ;;
6735 esac
6736 ;;
6737 esac
6738 case " $sys_lib_dlsearch_path " in
6739 *" $libdir "*) ;;
6740 *)
6741 case "$finalize_rpath " in
6742 *" $libdir "*) ;;
6743 *) func_append finalize_rpath " $libdir" ;;
6744 esac
6745 ;;
6746 esac
6747 fi
6748
6749 if test -n "$old_archive_from_expsyms_cmds"; then
6750 # figure out the soname
6751 set dummy $library_names
6752 shift
6753 realname="$1"
6754 shift
6755 libname=`eval "\\$ECHO \"$libname_spec\""`
6756 # use dlname if we got it. it's perfectly good, no?
6757 if test -n "$dlname"; then
6758 soname="$dlname"
6759 elif test -n "$soname_spec"; then
6760 # bleh windows
6761 case $host in
6762 *cygwin* | mingw* | *cegcc*)
6763 func_arith $current - $age
6764 major=$func_arith_result
6765 versuffix="-$major"
6766 ;;
6767 esac
6768 eval soname=\"$soname_spec\"
6769 else
6770 soname="$realname"
6771 fi
6772
6773 # Make a new name for the extract_expsyms_cmds to use
6774 soroot="$soname"
6775 func_basename "$soroot"
6776 soname="$func_basename_result"
6777 func_stripname 'lib' '.dll' "$soname"
6778 newlib=libimp-$func_stripname_result.a
6779
6780 # If the library has no export list, then create one now
6781 if test -f "$output_objdir/$soname-def"; then :
6782 else
6783 func_verbose "extracting exported symbol list from \`$soname'"
6784 func_execute_cmds "$extract_expsyms_cmds" 'exit $?'
6785 fi
6786
6787 # Create $newlib
6788 if test -f "$output_objdir/$newlib"; then :; else
6789 func_verbose "generating import library for \`$soname'"
6790 func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?'
6791 fi
6792 # make sure the library variables are pointing to the new library
6793 dir=$output_objdir
6794 linklib=$newlib
6795 fi # test -n "$old_archive_from_expsyms_cmds"
6796
6797 if test "$linkmode" = prog || test "$opt_mode" != relink; then
6798 add_shlibpath=
6799 add_dir=
6800 add=
6801 lib_linked=yes
6802 case $hardcode_action in
6803 immediate | unsupported)
6804 if test "$hardcode_direct" = no; then
6805 add="$dir/$linklib"
6806 case $host in
6807 *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;;
6808 *-*-sysv4*uw2*) add_dir="-L$dir" ;;
6809 *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \
6810 *-*-unixware7*) add_dir="-L$dir" ;;
6811 *-*-darwin* )
6812 # if the lib is a (non-dlopened) module then we can not
6813 # link against it, someone is ignoring the earlier warnings
6814 if /usr/bin/file -L $add 2> /dev/null |
6815 $GREP ": [^:]* bundle" >/dev/null ; then
6816 if test "X$dlopenmodule" != "X$lib"; then
6817 $ECHO "*** Warning: lib $linklib is a module, not a shared library"
6818 if test -z "$old_library" ; then
6819 echo
6820 echo "*** And there doesn't seem to be a static archive available"
6821 echo "*** The link will probably fail, sorry"
6822 else
6823 add="$dir/$old_library"
6824 fi
6825 elif test -n "$old_library"; then
6826 add="$dir/$old_library"
6827 fi
6828 fi
6829 esac
6830 elif test "$hardcode_minus_L" = no; then
6831 case $host in
6832 *-*-sunos*) add_shlibpath="$dir" ;;
6833 esac
6834 add_dir="-L$dir"
6835 add="-l$name"
6836 elif test "$hardcode_shlibpath_var" = no; then
6837 add_shlibpath="$dir"
6838 add="-l$name"
6839 else
6840 lib_linked=no
6841 fi
6842 ;;
6843 relink)
6844 if test "$hardcode_direct" = yes &&
6845 test "$hardcode_direct_absolute" = no; then
6846 add="$dir/$linklib"
6847 elif test "$hardcode_minus_L" = yes; then
6848 add_dir="-L$absdir"
6849 # Try looking first in the location we're being installed to.
6850 if test -n "$inst_prefix_dir"; then
6851 case $libdir in
6852 [\\/]*)
6853 func_append add_dir " -L$inst_prefix_dir$libdir"
6854 ;;
6855 esac
6856 fi
6857 add="-l$name"
6858 elif test "$hardcode_shlibpath_var" = yes; then
6859 add_shlibpath="$dir"
6860 add="-l$name"
6861 else
6862 lib_linked=no
6863 fi
6864 ;;
6865 *) lib_linked=no ;;
6866 esac
6867
6868 if test "$lib_linked" != yes; then
6869 func_fatal_configuration "unsupported hardcode properties"
6870 fi
6871
6872 if test -n "$add_shlibpath"; then
6873 case :$compile_shlibpath: in
6874 *":$add_shlibpath:"*) ;;
6875 *) func_append compile_shlibpath "$add_shlibpath:" ;;
6876 esac
6877 fi
6878 if test "$linkmode" = prog; then
6879 test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs"
6880 test -n "$add" && compile_deplibs="$add $compile_deplibs"
6881 else
6882 test -n "$add_dir" && deplibs="$add_dir $deplibs"
6883 test -n "$add" && deplibs="$add $deplibs"
6884 if test "$hardcode_direct" != yes &&
6885 test "$hardcode_minus_L" != yes &&
6886 test "$hardcode_shlibpath_var" = yes; then
6887 case :$finalize_shlibpath: in
6888 *":$libdir:"*) ;;
6889 *) func_append finalize_shlibpath "$libdir:" ;;
6890 esac
6891 fi
6892 fi
6893 fi
6894
6895 if test "$linkmode" = prog || test "$opt_mode" = relink; then
6896 add_shlibpath=
6897 add_dir=
6898 add=
6899 # Finalize command for both is simple: just hardcode it.
6900 if test "$hardcode_direct" = yes &&
6901 test "$hardcode_direct_absolute" = no; then
6902 add="$libdir/$linklib"
6903 elif test "$hardcode_minus_L" = yes; then
6904 add_dir="-L$libdir"
6905 add="-l$name"
6906 elif test "$hardcode_shlibpath_var" = yes; then
6907 case :$finalize_shlibpath: in
6908 *":$libdir:"*) ;;
6909 *) func_append finalize_shlibpath "$libdir:" ;;
6910 esac
6911 add="-l$name"
6912 elif test "$hardcode_automatic" = yes; then
6913 if test -n "$inst_prefix_dir" &&
6914 test -f "$inst_prefix_dir$libdir/$linklib" ; then
6915 add="$inst_prefix_dir$libdir/$linklib"
6916 else
6917 add="$libdir/$linklib"
6918 fi
6919 else
6920 # We cannot seem to hardcode it, guess we'll fake it.
6921 add_dir="-L$libdir"
6922 # Try looking first in the location we're being installed to.
6923 if test -n "$inst_prefix_dir"; then
6924 case $libdir in
6925 [\\/]*)
6926 func_append add_dir " -L$inst_prefix_dir$libdir"
6927 ;;
6928 esac
6929 fi
6930 add="-l$name"
6931 fi
6932
6933 if test "$linkmode" = prog; then
6934 test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs"
6935 test -n "$add" && finalize_deplibs="$add $finalize_deplibs"
6936 else
6937 test -n "$add_dir" && deplibs="$add_dir $deplibs"
6938 test -n "$add" && deplibs="$add $deplibs"
6939 fi
6940 fi
6941 elif test "$linkmode" = prog; then
6942 # Here we assume that one of hardcode_direct or hardcode_minus_L
6943 # is not unsupported. This is valid on all known static and
6944 # shared platforms.
6945 if test "$hardcode_direct" != unsupported; then
6946 test -n "$old_library" && linklib="$old_library"
6947 compile_deplibs="$dir/$linklib $compile_deplibs"
6948 finalize_deplibs="$dir/$linklib $finalize_deplibs"
6949 else
6950 compile_deplibs="-l$name -L$dir $compile_deplibs"
6951 finalize_deplibs="-l$name -L$dir $finalize_deplibs"
6952 fi
6953 elif test "$build_libtool_libs" = yes; then
6954 # Not a shared library
6955 if test "$deplibs_check_method" != pass_all; then
6956 # We're trying link a shared library against a static one
6957 # but the system doesn't support it.
6958
6959 # Just print a warning and add the library to dependency_libs so
6960 # that the program can be linked against the static library.
6961 echo
6962 $ECHO "*** Warning: This system can not link to static lib archive $lib."
6963 echo "*** I have the capability to make that library automatically link in when"
6964 echo "*** you link to this library. But I can only do this if you have a"
6965 echo "*** shared version of the library, which you do not appear to have."
6966 if test "$module" = yes; then
6967 echo "*** But as you try to build a module library, libtool will still create "
6968 echo "*** a static module, that should work as long as the dlopening application"
6969 echo "*** is linked with the -dlopen flag to resolve symbols at runtime."
6970 if test -z "$global_symbol_pipe"; then
6971 echo
6972 echo "*** However, this would only work if libtool was able to extract symbol"
6973 echo "*** lists from a program, using \`nm' or equivalent, but libtool could"
6974 echo "*** not find such a program. So, this module is probably useless."
6975 echo "*** \`nm' from GNU binutils and a full rebuild may help."
6976 fi
6977 if test "$build_old_libs" = no; then
6978 build_libtool_libs=module
6979 build_old_libs=yes
6980 else
6981 build_libtool_libs=no
6982 fi
6983 fi
6984 else
6985 deplibs="$dir/$old_library $deplibs"
6986 link_static=yes
6987 fi
6988 fi # link shared/static library?
6989
6990 if test "$linkmode" = lib; then
6991 if test -n "$dependency_libs" &&
6992 { test "$hardcode_into_libs" != yes ||
6993 test "$build_old_libs" = yes ||
6994 test "$link_static" = yes; }; then
6995 # Extract -R from dependency_libs
6996 temp_deplibs=
6997 for libdir in $dependency_libs; do
6998 case $libdir in
6999 -R*) func_stripname '-R' '' "$libdir"
7000 temp_xrpath=$func_stripname_result
7001 case " $xrpath " in
7002 *" $temp_xrpath "*) ;;
7003 *) func_append xrpath " $temp_xrpath";;
7004 esac;;
7005 *) func_append temp_deplibs " $libdir";;
7006 esac
7007 done
7008 dependency_libs="$temp_deplibs"
7009 fi
7010
7011 func_append newlib_search_path " $absdir"
7012 # Link against this library
7013 test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs"
7014 # ... and its dependency_libs
7015 tmp_libs=
7016 for deplib in $dependency_libs; do
7017 newdependency_libs="$deplib $newdependency_libs"
7018 case $deplib in
7019 -L*) func_stripname '-L' '' "$deplib"
7020 func_resolve_sysroot "$func_stripname_result";;
7021 *) func_resolve_sysroot "$deplib" ;;
7022 esac
7023 if $opt_preserve_dup_deps ; then
7024 case "$tmp_libs " in
7025 *" $func_resolve_sysroot_result "*)
7026 func_append specialdeplibs " $func_resolve_sysroot_result" ;;
7027 esac
7028 fi
7029 func_append tmp_libs " $func_resolve_sysroot_result"
7030 done
7031
7032 if test "$link_all_deplibs" != no; then
7033 # Add the search paths of all dependency libraries
7034 for deplib in $dependency_libs; do
7035 path=
7036 case $deplib in
7037 -L*) path="$deplib" ;;
7038 *.la)
7039 func_resolve_sysroot "$deplib"
7040 deplib=$func_resolve_sysroot_result
7041 func_dirname "$deplib" "" "."
7042 dir=$func_dirname_result
7043 # We need an absolute path.
7044 case $dir in
7045 [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;;
7046 *)
7047 absdir=`cd "$dir" && pwd`
7048 if test -z "$absdir"; then
7049 func_warning "cannot determine absolute directory name of \`$dir'"
7050 absdir="$dir"
7051 fi
7052 ;;
7053 esac
7054 if $GREP "^installed=no" $deplib > /dev/null; then
7055 case $host in
7056 *-*-darwin*)
7057 depdepl=
7058 eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib`
7059 if test -n "$deplibrary_names" ; then
7060 for tmp in $deplibrary_names ; do
7061 depdepl=$tmp
7062 done
7063 if test -f "$absdir/$objdir/$depdepl" ; then
7064 depdepl="$absdir/$objdir/$depdepl"
7065 darwin_install_name=`${OTOOL} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'`
7066 if test -z "$darwin_install_name"; then
7067 darwin_install_name=`${OTOOL64} -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'`
7068 fi
7069 func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}"
7070 func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}"
7071 path=
7072 fi
7073 fi
7074 ;;
7075 *)
7076 path="-L$absdir/$objdir"
7077 ;;
7078 esac
7079 else
7080 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
7081 test -z "$libdir" && \
7082 func_fatal_error "\`$deplib' is not a valid libtool archive"
7083 test "$absdir" != "$libdir" && \
7084 func_warning "\`$deplib' seems to be moved"
7085
7086 path="-L$absdir"
7087 fi
7088 ;;
7089 esac
7090 case " $deplibs " in
7091 *" $path "*) ;;
7092 *) deplibs="$path $deplibs" ;;
7093 esac
7094 done
7095 fi # link_all_deplibs != no
7096 fi # linkmode = lib
7097 done # for deplib in $libs
7098 if test "$pass" = link; then
7099 if test "$linkmode" = "prog"; then
7100 compile_deplibs="$new_inherited_linker_flags $compile_deplibs"
7101 finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs"
7102 else
7103 compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
7104 fi
7105 fi
7106 dependency_libs="$newdependency_libs"
7107 if test "$pass" = dlpreopen; then
7108 # Link the dlpreopened libraries before other libraries
7109 for deplib in $save_deplibs; do
7110 deplibs="$deplib $deplibs"
7111 done
7112 fi
7113 if test "$pass" != dlopen; then
7114 if test "$pass" != conv; then
7115 # Make sure lib_search_path contains only unique directories.
7116 lib_search_path=
7117 for dir in $newlib_search_path; do
7118 case "$lib_search_path " in
7119 *" $dir "*) ;;
7120 *) func_append lib_search_path " $dir" ;;
7121 esac
7122 done
7123 newlib_search_path=
7124 fi
7125
7126 if test "$linkmode,$pass" != "prog,link"; then
7127 vars="deplibs"
7128 else
7129 vars="compile_deplibs finalize_deplibs"
7130 fi
7131 for var in $vars dependency_libs; do
7132 # Add libraries to $var in reverse order
7133 eval tmp_libs=\"\$$var\"
7134 new_libs=
7135 for deplib in $tmp_libs; do
7136 # FIXME: Pedantically, this is the right thing to do, so
7137 # that some nasty dependency loop isn't accidentally
7138 # broken:
7139 #new_libs="$deplib $new_libs"
7140 # Pragmatically, this seems to cause very few problems in
7141 # practice:
7142 case $deplib in
7143 -L*) new_libs="$deplib $new_libs" ;;
7144 -R*) ;;
7145 *)
7146 # And here is the reason: when a library appears more
7147 # than once as an explicit dependence of a library, or
7148 # is implicitly linked in more than once by the
7149 # compiler, it is considered special, and multiple
7150 # occurrences thereof are not removed. Compare this
7151 # with having the same library being listed as a
7152 # dependency of multiple other libraries: in this case,
7153 # we know (pedantically, we assume) the library does not
7154 # need to be listed more than once, so we keep only the
7155 # last copy. This is not always right, but it is rare
7156 # enough that we require users that really mean to play
7157 # such unportable linking tricks to link the library
7158 # using -Wl,-lname, so that libtool does not consider it
7159 # for duplicate removal.
7160 case " $specialdeplibs " in
7161 *" $deplib "*) new_libs="$deplib $new_libs" ;;
7162 *)
7163 case " $new_libs " in
7164 *" $deplib "*) ;;
7165 *) new_libs="$deplib $new_libs" ;;
7166 esac
7167 ;;
7168 esac
7169 ;;
7170 esac
7171 done
7172 tmp_libs=
7173 for deplib in $new_libs; do
7174 case $deplib in
7175 -L*)
7176 case " $tmp_libs " in
7177 *" $deplib "*) ;;
7178 *) func_append tmp_libs " $deplib" ;;
7179 esac
7180 ;;
7181 *) func_append tmp_libs " $deplib" ;;
7182 esac
7183 done
7184 eval $var=\"$tmp_libs\"
7185 done # for var
7186 fi
7187 # Last step: remove runtime libs from dependency_libs
7188 # (they stay in deplibs)
7189 tmp_libs=
7190 for i in $dependency_libs ; do
7191 case " $predeps $postdeps $compiler_lib_search_path " in
7192 *" $i "*)
7193 i=""
7194 ;;
7195 esac
7196 if test -n "$i" ; then
7197 func_append tmp_libs " $i"
7198 fi
7199 done
7200 dependency_libs=$tmp_libs
7201 done # for pass
7202 if test "$linkmode" = prog; then
7203 dlfiles="$newdlfiles"
7204 fi
7205 if test "$linkmode" = prog || test "$linkmode" = lib; then
7206 dlprefiles="$newdlprefiles"
7207 fi
7208
7209 case $linkmode in
7210 oldlib)
7211 if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
7212 func_warning "\`-dlopen' is ignored for archives"
7213 fi
7214
7215 case " $deplibs" in
7216 *\ -l* | *\ -L*)
7217 func_warning "\`-l' and \`-L' are ignored for archives" ;;
7218 esac
7219
7220 test -n "$rpath" && \
7221 func_warning "\`-rpath' is ignored for archives"
7222
7223 test -n "$xrpath" && \
7224 func_warning "\`-R' is ignored for archives"
7225
7226 test -n "$vinfo" && \
7227 func_warning "\`-version-info/-version-number' is ignored for archives"
7228
7229 test -n "$release" && \
7230 func_warning "\`-release' is ignored for archives"
7231
7232 test -n "$export_symbols$export_symbols_regex" && \
7233 func_warning "\`-export-symbols' is ignored for archives"
7234
7235 # Now set the variables for building old libraries.
7236 build_libtool_libs=no
7237 oldlibs="$output"
7238 func_append objs "$old_deplibs"
7239 ;;
7240
7241 lib)
7242 # Make sure we only generate libraries of the form `libNAME.la'.
7243 case $outputname in
7244 lib*)
7245 func_stripname 'lib' '.la' "$outputname"
7246 name=$func_stripname_result
7247 eval shared_ext=\"$shrext_cmds\"
7248 eval libname=\"$libname_spec\"
7249 ;;
7250 *)
7251 test "$module" = no && \
7252 func_fatal_help "libtool library \`$output' must begin with \`lib'"
7253
7254 if test "$need_lib_prefix" != no; then
7255 # Add the "lib" prefix for modules if required
7256 func_stripname '' '.la' "$outputname"
7257 name=$func_stripname_result
7258 eval shared_ext=\"$shrext_cmds\"
7259 eval libname=\"$libname_spec\"
7260 else
7261 func_stripname '' '.la' "$outputname"
7262 libname=$func_stripname_result
7263 fi
7264 ;;
7265 esac
7266
7267 if test -n "$objs"; then
7268 if test "$deplibs_check_method" != pass_all; then
7269 func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs"
7270 else
7271 echo
7272 $ECHO "*** Warning: Linking the shared library $output against the non-libtool"
7273 $ECHO "*** objects $objs is not portable!"
7274 func_append libobjs " $objs"
7275 fi
7276 fi
7277
7278 test "$dlself" != no && \
7279 func_warning "\`-dlopen self' is ignored for libtool libraries"
7280
7281 set dummy $rpath
7282 shift
7283 test "$#" -gt 1 && \
7284 func_warning "ignoring multiple \`-rpath's for a libtool library"
7285
7286 install_libdir="$1"
7287
7288 oldlibs=
7289 if test -z "$rpath"; then
7290 if test "$build_libtool_libs" = yes; then
7291 # Building a libtool convenience library.
7292 # Some compilers have problems with a `.al' extension so
7293 # convenience libraries should have the same extension an
7294 # archive normally would.
7295 oldlibs="$output_objdir/$libname.$libext $oldlibs"
7296 build_libtool_libs=convenience
7297 build_old_libs=yes
7298 fi
7299
7300 test -n "$vinfo" && \
7301 func_warning "\`-version-info/-version-number' is ignored for convenience libraries"
7302
7303 test -n "$release" && \
7304 func_warning "\`-release' is ignored for convenience libraries"
7305 else
7306
7307 # Parse the version information argument.
7308 save_ifs="$IFS"; IFS=':'
7309 set dummy $vinfo 0 0 0
7310 shift
7311 IFS="$save_ifs"
7312
7313 test -n "$7" && \
7314 func_fatal_help "too many parameters to \`-version-info'"
7315
7316 # convert absolute version numbers to libtool ages
7317 # this retains compatibility with .la files and attempts
7318 # to make the code below a bit more comprehensible
7319
7320 case $vinfo_number in
7321 yes)
7322 number_major="$1"
7323 number_minor="$2"
7324 number_revision="$3"
7325 #
7326 # There are really only two kinds -- those that
7327 # use the current revision as the major version
7328 # and those that subtract age and use age as
7329 # a minor version. But, then there is irix
7330 # which has an extra 1 added just for fun
7331 #
7332 case $version_type in
7333 # correct linux to gnu/linux during the next big refactor
7334 darwin|linux|osf|windows|none)
7335 func_arith $number_major + $number_minor
7336 current=$func_arith_result
7337 age="$number_minor"
7338 revision="$number_revision"
7339 ;;
7340 freebsd-aout|freebsd-elf|qnx|sunos)
7341 current="$number_major"
7342 revision="$number_minor"
7343 age="0"
7344 ;;
7345 irix|nonstopux)
7346 func_arith $number_major + $number_minor
7347 current=$func_arith_result
7348 age="$number_minor"
7349 revision="$number_minor"
7350 lt_irix_increment=no
7351 ;;
7352 esac
7353 ;;
7354 no)
7355 current="$1"
7356 revision="$2"
7357 age="$3"
7358 ;;
7359 esac
7360
7361 # Check that each of the things are valid numbers.
7362 case $current in
7363 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]) ;;
7364 *)
7365 func_error "CURRENT \`$current' must be a nonnegative integer"
7366 func_fatal_error "\`$vinfo' is not valid version information"
7367 ;;
7368 esac
7369
7370 case $revision in
7371 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]) ;;
7372 *)
7373 func_error "REVISION \`$revision' must be a nonnegative integer"
7374 func_fatal_error "\`$vinfo' is not valid version information"
7375 ;;
7376 esac
7377
7378 case $age in
7379 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]) ;;
7380 *)
7381 func_error "AGE \`$age' must be a nonnegative integer"
7382 func_fatal_error "\`$vinfo' is not valid version information"
7383 ;;
7384 esac
7385
7386 if test "$age" -gt "$current"; then
7387 func_error "AGE \`$age' is greater than the current interface number \`$current'"
7388 func_fatal_error "\`$vinfo' is not valid version information"
7389 fi
7390
7391 # Calculate the version variables.
7392 major=
7393 versuffix=
7394 verstring=
7395 case $version_type in
7396 none) ;;
7397
7398 darwin)
7399 # Like Linux, but with the current version available in
7400 # verstring for coding it into the library header
7401 func_arith $current - $age
7402 major=.$func_arith_result
7403 versuffix="$major.$age.$revision"
7404 # Darwin ld doesn't like 0 for these options...
7405 func_arith $current + 1
7406 minor_current=$func_arith_result
7407 xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision"
7408 verstring="-compatibility_version $minor_current -current_version $minor_current.$revision"
7409 ;;
7410
7411 freebsd-aout)
7412 major=".$current"
7413 versuffix=".$current.$revision";
7414 ;;
7415
7416 freebsd-elf)
7417 major=".$current"
7418 versuffix=".$current"
7419 ;;
7420
7421 irix | nonstopux)
7422 if test "X$lt_irix_increment" = "Xno"; then
7423 func_arith $current - $age
7424 else
7425 func_arith $current - $age + 1
7426 fi
7427 major=$func_arith_result
7428
7429 case $version_type in
7430 nonstopux) verstring_prefix=nonstopux ;;
7431 *) verstring_prefix=sgi ;;
7432 esac
7433 verstring="$verstring_prefix$major.$revision"
7434
7435 # Add in all the interfaces that we are compatible with.
7436 loop=$revision
7437 while test "$loop" -ne 0; do
7438 func_arith $revision - $loop
7439 iface=$func_arith_result
7440 func_arith $loop - 1
7441 loop=$func_arith_result
7442 verstring="$verstring_prefix$major.$iface:$verstring"
7443 done
7444
7445 # Before this point, $major must not contain `.'.
7446 major=.$major
7447 versuffix="$major.$revision"
7448 ;;
7449
7450 linux) # correct to gnu/linux during the next big refactor
7451 func_arith $current - $age
7452 major=.$func_arith_result
7453 versuffix="$major.$age.$revision"
7454 ;;
7455
7456 osf)
7457 func_arith $current - $age
7458 major=.$func_arith_result
7459 versuffix=".$current.$age.$revision"
7460 verstring="$current.$age.$revision"
7461
7462 # Add in all the interfaces that we are compatible with.
7463 loop=$age
7464 while test "$loop" -ne 0; do
7465 func_arith $current - $loop
7466 iface=$func_arith_result
7467 func_arith $loop - 1
7468 loop=$func_arith_result
7469 verstring="$verstring:${iface}.0"
7470 done
7471
7472 # Make executables depend on our current version.
7473 func_append verstring ":${current}.0"
7474 ;;
7475
7476 qnx)
7477 major=".$current"
7478 versuffix=".$current"
7479 ;;
7480
7481 sunos)
7482 major=".$current"
7483 versuffix=".$current.$revision"
7484 ;;
7485
7486 windows)
7487 # Use '-' rather than '.', since we only want one
7488 # extension on DOS 8.3 filesystems.
7489 func_arith $current - $age
7490 major=$func_arith_result
7491 versuffix="-$major"
7492 ;;
7493
7494 *)
7495 func_fatal_configuration "unknown library version type \`$version_type'"
7496 ;;
7497 esac
7498
7499 # Clear the version info if we defaulted, and they specified a release.
7500 if test -z "$vinfo" && test -n "$release"; then
7501 major=
7502 case $version_type in
7503 darwin)
7504 # we can't check for "0.0" in archive_cmds due to quoting
7505 # problems, so we reset it completely
7506 verstring=
7507 ;;
7508 *)
7509 verstring="0.0"
7510 ;;
7511 esac
7512 if test "$need_version" = no; then
7513 versuffix=
7514 else
7515 versuffix=".0.0"
7516 fi
7517 fi
7518
7519 # Remove version info from name if versioning should be avoided
7520 if test "$avoid_version" = yes && test "$need_version" = no; then
7521 major=
7522 versuffix=
7523 verstring=""
7524 fi
7525
7526 # Check to see if the archive will have undefined symbols.
7527 if test "$allow_undefined" = yes; then
7528 if test "$allow_undefined_flag" = unsupported; then
7529 func_warning "undefined symbols not allowed in $host shared libraries"
7530 build_libtool_libs=no
7531 build_old_libs=yes
7532 fi
7533 else
7534 # Don't allow undefined symbols.
7535 allow_undefined_flag="$no_undefined_flag"
7536 fi
7537
7538 fi
7539
7540 func_generate_dlsyms "$libname" "$libname" "yes"
7541 func_append libobjs " $symfileobj"
7542 test "X$libobjs" = "X " && libobjs=
7543
7544 if test "$opt_mode" != relink; then
7545 # Remove our outputs, but don't remove object files since they
7546 # may have been created when compiling PIC objects.
7547 removelist=
7548 tempremovelist=`$ECHO "$output_objdir/*"`
7549 for p in $tempremovelist; do
7550 case $p in
7551 *.$objext | *.gcno)
7552 ;;
7553 $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*)
7554 if test "X$precious_files_regex" != "X"; then
7555 if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1
7556 then
7557 continue
7558 fi
7559 fi
7560 func_append removelist " $p"
7561 ;;
7562 *) ;;
7563 esac
7564 done
7565 test -n "$removelist" && \
7566 func_show_eval "${RM}r \$removelist"
7567 fi
7568
7569 # Now set the variables for building old libraries.
7570 if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then
7571 func_append oldlibs " $output_objdir/$libname.$libext"
7572
7573 # Transform .lo files to .o files.
7574 oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $lo2o" | $NL2SP`
7575 fi
7576
7577 # Eliminate all temporary directories.
7578 #for path in $notinst_path; do
7579 # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"`
7580 # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"`
7581 # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"`
7582 #done
7583
7584 if test -n "$xrpath"; then
7585 # If the user specified any rpath flags, then add them.
7586 temp_xrpath=
7587 for libdir in $xrpath; do
7588 func_replace_sysroot "$libdir"
7589 func_append temp_xrpath " -R$func_replace_sysroot_result"
7590 case "$finalize_rpath " in
7591 *" $libdir "*) ;;
7592 *) func_append finalize_rpath " $libdir" ;;
7593 esac
7594 done
7595 if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then
7596 dependency_libs="$temp_xrpath $dependency_libs"
7597 fi
7598 fi
7599
7600 # Make sure dlfiles contains only unique files that won't be dlpreopened
7601 old_dlfiles="$dlfiles"
7602 dlfiles=
7603 for lib in $old_dlfiles; do
7604 case " $dlprefiles $dlfiles " in
7605 *" $lib "*) ;;
7606 *) func_append dlfiles " $lib" ;;
7607 esac
7608 done
7609
7610 # Make sure dlprefiles contains only unique files
7611 old_dlprefiles="$dlprefiles"
7612 dlprefiles=
7613 for lib in $old_dlprefiles; do
7614 case "$dlprefiles " in
7615 *" $lib "*) ;;
7616 *) func_append dlprefiles " $lib" ;;
7617 esac
7618 done
7619
7620 if test "$build_libtool_libs" = yes; then
7621 if test -n "$rpath"; then
7622 case $host in
7623 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*)
7624 # these systems don't actually have a c library (as such)!
7625 ;;
7626 *-*-rhapsody* | *-*-darwin1.[012])
7627 # Rhapsody C library is in the System framework
7628 func_append deplibs " System.ltframework"
7629 ;;
7630 *-*-netbsd*)
7631 # Don't link with libc until the a.out ld.so is fixed.
7632 ;;
7633 *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
7634 # Do not include libc due to us having libc/libc_r.
7635 ;;
7636 *-*-sco3.2v5* | *-*-sco5v6*)
7637 # Causes problems with __ctype
7638 ;;
7639 *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*)
7640 # Compiler inserts libc in the correct place for threads to work
7641 ;;
7642 *)
7643 # Add libc to deplibs on all other systems if necessary.
7644 if test "$build_libtool_need_lc" = "yes"; then
7645 func_append deplibs " -lc"
7646 fi
7647 ;;
7648 esac
7649 fi
7650
7651 # Transform deplibs into only deplibs that can be linked in shared.
7652 name_save=$name
7653 libname_save=$libname
7654 release_save=$release
7655 versuffix_save=$versuffix
7656 major_save=$major
7657 # I'm not sure if I'm treating the release correctly. I think
7658 # release should show up in the -l (ie -lgmp5) so we don't want to
7659 # add it in twice. Is that correct?
7660 release=""
7661 versuffix=""
7662 major=""
7663 newdeplibs=
7664 droppeddeps=no
7665 case $deplibs_check_method in
7666 pass_all)
7667 # Don't check for shared/static. Everything works.
7668 # This might be a little naive. We might want to check
7669 # whether the library exists or not. But this is on
7670 # osf3 & osf4 and I'm not really sure... Just
7671 # implementing what was already the behavior.
7672 newdeplibs=$deplibs
7673 ;;
7674 test_compile)
7675 # This code stresses the "libraries are programs" paradigm to its
7676 # limits. Maybe even breaks it. We compile a program, linking it
7677 # against the deplibs as a proxy for the library. Then we can check
7678 # whether they linked in statically or dynamically with ldd.
7679 $opt_dry_run || $RM conftest.c
7680 cat > conftest.c <<EOF
7681 int main() { return 0; }
7682EOF
7683 $opt_dry_run || $RM conftest
7684 if $LTCC $LTCFLAGS -o conftest conftest.c $deplibs; then
7685 ldd_output=`ldd conftest`
7686 for i in $deplibs; do
7687 case $i in
7688 -l*)
7689 func_stripname -l '' "$i"
7690 name=$func_stripname_result
7691 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7692 case " $predeps $postdeps " in
7693 *" $i "*)
7694 func_append newdeplibs " $i"
7695 i=""
7696 ;;
7697 esac
7698 fi
7699 if test -n "$i" ; then
7700 libname=`eval "\\$ECHO \"$libname_spec\""`
7701 deplib_matches=`eval "\\$ECHO \"$library_names_spec\""`
7702 set dummy $deplib_matches; shift
7703 deplib_match=$1
7704 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
7705 func_append newdeplibs " $i"
7706 else
7707 droppeddeps=yes
7708 echo
7709 $ECHO "*** Warning: dynamic linker does not accept needed library $i."
7710 echo "*** I have the capability to make that library automatically link in when"
7711 echo "*** you link to this library. But I can only do this if you have a"
7712 echo "*** shared version of the library, which I believe you do not have"
7713 echo "*** because a test_compile did reveal that the linker did not use it for"
7714 echo "*** its dynamic dependency list that programs get resolved with at runtime."
7715 fi
7716 fi
7717 ;;
7718 *)
7719 func_append newdeplibs " $i"
7720 ;;
7721 esac
7722 done
7723 else
7724 # Error occurred in the first compile. Let's try to salvage
7725 # the situation: Compile a separate program for each library.
7726 for i in $deplibs; do
7727 case $i in
7728 -l*)
7729 func_stripname -l '' "$i"
7730 name=$func_stripname_result
7731 $opt_dry_run || $RM conftest
7732 if $LTCC $LTCFLAGS -o conftest conftest.c $i; then
7733 ldd_output=`ldd conftest`
7734 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7735 case " $predeps $postdeps " in
7736 *" $i "*)
7737 func_append newdeplibs " $i"
7738 i=""
7739 ;;
7740 esac
7741 fi
7742 if test -n "$i" ; then
7743 libname=`eval "\\$ECHO \"$libname_spec\""`
7744 deplib_matches=`eval "\\$ECHO \"$library_names_spec\""`
7745 set dummy $deplib_matches; shift
7746 deplib_match=$1
7747 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
7748 func_append newdeplibs " $i"
7749 else
7750 droppeddeps=yes
7751 echo
7752 $ECHO "*** Warning: dynamic linker does not accept needed library $i."
7753 echo "*** I have the capability to make that library automatically link in when"
7754 echo "*** you link to this library. But I can only do this if you have a"
7755 echo "*** shared version of the library, which you do not appear to have"
7756 echo "*** because a test_compile did reveal that the linker did not use this one"
7757 echo "*** as a dynamic dependency that programs can get resolved with at runtime."
7758 fi
7759 fi
7760 else
7761 droppeddeps=yes
7762 echo
7763 $ECHO "*** Warning! Library $i is needed by this library but I was not able to"
7764 echo "*** make it link in! You will probably need to install it or some"
7765 echo "*** library that it depends on before this library will be fully"
7766 echo "*** functional. Installing it before continuing would be even better."
7767 fi
7768 ;;
7769 *)
7770 func_append newdeplibs " $i"
7771 ;;
7772 esac
7773 done
7774 fi
7775 ;;
7776 file_magic*)
7777 set dummy $deplibs_check_method; shift
7778 file_magic_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
7779 for a_deplib in $deplibs; do
7780 case $a_deplib in
7781 -l*)
7782 func_stripname -l '' "$a_deplib"
7783 name=$func_stripname_result
7784 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7785 case " $predeps $postdeps " in
7786 *" $a_deplib "*)
7787 func_append newdeplibs " $a_deplib"
7788 a_deplib=""
7789 ;;
7790 esac
7791 fi
7792 if test -n "$a_deplib" ; then
7793 libname=`eval "\\$ECHO \"$libname_spec\""`
7794 if test -n "$file_magic_glob"; then
7795 libnameglob=`func_echo_all "$libname" | $SED -e $file_magic_glob`
7796 else
7797 libnameglob=$libname
7798 fi
7799 test "$want_nocaseglob" = yes && nocaseglob=`shopt -p nocaseglob`
7800 for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
7801 if test "$want_nocaseglob" = yes; then
7802 shopt -s nocaseglob
7803 potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null`
7804 $nocaseglob
7805 else
7806 potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null`
7807 fi
7808 for potent_lib in $potential_libs; do
7809 # Follow soft links.
7810 if ls -lLd "$potent_lib" 2>/dev/null |
7811 $GREP " -> " >/dev/null; then
7812 continue
7813 fi
7814 # The statement above tries to avoid entering an
7815 # endless loop below, in case of cyclic links.
7816 # We might still enter an endless loop, since a link
7817 # loop can be closed while we follow links,
7818 # but so what?
7819 potlib="$potent_lib"
7820 while test -h "$potlib" 2>/dev/null; do
7821 potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'`
7822 case $potliblink in
7823 [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";;
7824 *) potlib=`$ECHO "$potlib" | $SED 's,[^/]*$,,'`"$potliblink";;
7825 esac
7826 done
7827 if eval $file_magic_cmd \"\$potlib\" 2>/dev/null |
7828 $SED -e 10q |
7829 $EGREP "$file_magic_regex" > /dev/null; then
7830 func_append newdeplibs " $a_deplib"
7831 a_deplib=""
7832 break 2
7833 fi
7834 done
7835 done
7836 fi
7837 if test -n "$a_deplib" ; then
7838 droppeddeps=yes
7839 echo
7840 $ECHO "*** Warning: linker path does not have real file for library $a_deplib."
7841 echo "*** I have the capability to make that library automatically link in when"
7842 echo "*** you link to this library. But I can only do this if you have a"
7843 echo "*** shared version of the library, which you do not appear to have"
7844 echo "*** because I did check the linker path looking for a file starting"
7845 if test -z "$potlib" ; then
7846 $ECHO "*** with $libname but no candidates were found. (...for file magic test)"
7847 else
7848 $ECHO "*** with $libname and none of the candidates passed a file format test"
7849 $ECHO "*** using a file magic. Last file checked: $potlib"
7850 fi
7851 fi
7852 ;;
7853 *)
7854 # Add a -L argument.
7855 func_append newdeplibs " $a_deplib"
7856 ;;
7857 esac
7858 done # Gone through all deplibs.
7859 ;;
7860 match_pattern*)
7861 set dummy $deplibs_check_method; shift
7862 match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
7863 for a_deplib in $deplibs; do
7864 case $a_deplib in
7865 -l*)
7866 func_stripname -l '' "$a_deplib"
7867 name=$func_stripname_result
7868 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7869 case " $predeps $postdeps " in
7870 *" $a_deplib "*)
7871 func_append newdeplibs " $a_deplib"
7872 a_deplib=""
7873 ;;
7874 esac
7875 fi
7876 if test -n "$a_deplib" ; then
7877 libname=`eval "\\$ECHO \"$libname_spec\""`
7878 for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
7879 potential_libs=`ls $i/$libname[.-]* 2>/dev/null`
7880 for potent_lib in $potential_libs; do
7881 potlib="$potent_lib" # see symlink-check above in file_magic test
7882 if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \
7883 $EGREP "$match_pattern_regex" > /dev/null; then
7884 func_append newdeplibs " $a_deplib"
7885 a_deplib=""
7886 break 2
7887 fi
7888 done
7889 done
7890 fi
7891 if test -n "$a_deplib" ; then
7892 droppeddeps=yes
7893 echo
7894 $ECHO "*** Warning: linker path does not have real file for library $a_deplib."
7895 echo "*** I have the capability to make that library automatically link in when"
7896 echo "*** you link to this library. But I can only do this if you have a"
7897 echo "*** shared version of the library, which you do not appear to have"
7898 echo "*** because I did check the linker path looking for a file starting"
7899 if test -z "$potlib" ; then
7900 $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)"
7901 else
7902 $ECHO "*** with $libname and none of the candidates passed a file format test"
7903 $ECHO "*** using a regex pattern. Last file checked: $potlib"
7904 fi
7905 fi
7906 ;;
7907 *)
7908 # Add a -L argument.
7909 func_append newdeplibs " $a_deplib"
7910 ;;
7911 esac
7912 done # Gone through all deplibs.
7913 ;;
7914 none | unknown | *)
7915 newdeplibs=""
7916 tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'`
7917 if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
7918 for i in $predeps $postdeps ; do
7919 # can't use Xsed below, because $i might contain '/'
7920 tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"`
7921 done
7922 fi
7923 case $tmp_deplibs in
7924 *[!\ \ ]*)
7925 echo
7926 if test "X$deplibs_check_method" = "Xnone"; then
7927 echo "*** Warning: inter-library dependencies are not supported in this platform."
7928 else
7929 echo "*** Warning: inter-library dependencies are not known to be supported."
7930 fi
7931 echo "*** All declared inter-library dependencies are being dropped."
7932 droppeddeps=yes
7933 ;;
7934 esac
7935 ;;
7936 esac
7937 versuffix=$versuffix_save
7938 major=$major_save
7939 release=$release_save
7940 libname=$libname_save
7941 name=$name_save
7942
7943 case $host in
7944 *-*-rhapsody* | *-*-darwin1.[012])
7945 # On Rhapsody replace the C library with the System framework
7946 newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'`
7947 ;;
7948 esac
7949
7950 if test "$droppeddeps" = yes; then
7951 if test "$module" = yes; then
7952 echo
7953 echo "*** Warning: libtool could not satisfy all declared inter-library"
7954 $ECHO "*** dependencies of module $libname. Therefore, libtool will create"
7955 echo "*** a static module, that should work as long as the dlopening"
7956 echo "*** application is linked with the -dlopen flag."
7957 if test -z "$global_symbol_pipe"; then
7958 echo
7959 echo "*** However, this would only work if libtool was able to extract symbol"
7960 echo "*** lists from a program, using \`nm' or equivalent, but libtool could"
7961 echo "*** not find such a program. So, this module is probably useless."
7962 echo "*** \`nm' from GNU binutils and a full rebuild may help."
7963 fi
7964 if test "$build_old_libs" = no; then
7965 oldlibs="$output_objdir/$libname.$libext"
7966 build_libtool_libs=module
7967 build_old_libs=yes
7968 else
7969 build_libtool_libs=no
7970 fi
7971 else
7972 echo "*** The inter-library dependencies that have been dropped here will be"
7973 echo "*** automatically added whenever a program is linked with this library"
7974 echo "*** or is declared to -dlopen it."
7975
7976 if test "$allow_undefined" = no; then
7977 echo
7978 echo "*** Since this library must not contain undefined symbols,"
7979 echo "*** because either the platform does not support them or"
7980 echo "*** it was explicitly requested with -no-undefined,"
7981 echo "*** libtool will only create a static version of it."
7982 if test "$build_old_libs" = no; then
7983 oldlibs="$output_objdir/$libname.$libext"
7984 build_libtool_libs=module
7985 build_old_libs=yes
7986 else
7987 build_libtool_libs=no
7988 fi
7989 fi
7990 fi
7991 fi
7992 # Done checking deplibs!
7993 deplibs=$newdeplibs
7994 fi
7995 # Time to change all our "foo.ltframework" stuff back to "-framework foo"
7996 case $host in
7997 *-*-darwin*)
7998 newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
7999 new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
8000 deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
8001 ;;
8002 esac
8003
8004 # move library search paths that coincide with paths to not yet
8005 # installed libraries to the beginning of the library search list
8006 new_libs=
8007 for path in $notinst_path; do
8008 case " $new_libs " in
8009 *" -L$path/$objdir "*) ;;
8010 *)
8011 case " $deplibs " in
8012 *" -L$path/$objdir "*)
8013 func_append new_libs " -L$path/$objdir" ;;
8014 esac
8015 ;;
8016 esac
8017 done
8018 for deplib in $deplibs; do
8019 case $deplib in
8020 -L*)
8021 case " $new_libs " in
8022 *" $deplib "*) ;;
8023 *) func_append new_libs " $deplib" ;;
8024 esac
8025 ;;
8026 *) func_append new_libs " $deplib" ;;
8027 esac
8028 done
8029 deplibs="$new_libs"
8030
8031 # All the library-specific variables (install_libdir is set above).
8032 library_names=
8033 old_library=
8034 dlname=
8035
8036 # Test again, we may have decided not to build it any more
8037 if test "$build_libtool_libs" = yes; then
8038 # Remove ${wl} instances when linking with ld.
8039 # FIXME: should test the right _cmds variable.
8040 case $archive_cmds in
8041 *\$LD\ *) wl= ;;
8042 esac
8043 if test "$hardcode_into_libs" = yes; then
8044 # Hardcode the library paths
8045 hardcode_libdirs=
8046 dep_rpath=
8047 rpath="$finalize_rpath"
8048 test "$opt_mode" != relink && rpath="$compile_rpath$rpath"
8049 for libdir in $rpath; do
8050 if test -n "$hardcode_libdir_flag_spec"; then
8051 if test -n "$hardcode_libdir_separator"; then
8052 func_replace_sysroot "$libdir"
8053 libdir=$func_replace_sysroot_result
8054 if test -z "$hardcode_libdirs"; then
8055 hardcode_libdirs="$libdir"
8056 else
8057 # Just accumulate the unique libdirs.
8058 case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
8059 *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
8060 ;;
8061 *)
8062 func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
8063 ;;
8064 esac
8065 fi
8066 else
8067 eval flag=\"$hardcode_libdir_flag_spec\"
8068 func_append dep_rpath " $flag"
8069 fi
8070 elif test -n "$runpath_var"; then
8071 case "$perm_rpath " in
8072 *" $libdir "*) ;;
8073 *) func_append perm_rpath " $libdir" ;;
8074 esac
8075 fi
8076 done
8077 # Substitute the hardcoded libdirs into the rpath.
8078 if test -n "$hardcode_libdir_separator" &&
8079 test -n "$hardcode_libdirs"; then
8080 libdir="$hardcode_libdirs"
8081 eval "dep_rpath=\"$hardcode_libdir_flag_spec\""
8082 fi
8083 if test -n "$runpath_var" && test -n "$perm_rpath"; then
8084 # We should set the runpath_var.
8085 rpath=
8086 for dir in $perm_rpath; do
8087 func_append rpath "$dir:"
8088 done
8089 eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var"
8090 fi
8091 test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs"
8092 fi
8093
8094 shlibpath="$finalize_shlibpath"
8095 test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath"
8096 if test -n "$shlibpath"; then
8097 eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var"
8098 fi
8099
8100 # Get the real and link names of the library.
8101 eval shared_ext=\"$shrext_cmds\"
8102 eval library_names=\"$library_names_spec\"
8103 set dummy $library_names
8104 shift
8105 realname="$1"
8106 shift
8107
8108 if test -n "$soname_spec"; then
8109 eval soname=\"$soname_spec\"
8110 else
8111 soname="$realname"
8112 fi
8113 if test -z "$dlname"; then
8114 dlname=$soname
8115 fi
8116
8117 lib="$output_objdir/$realname"
8118 linknames=
8119 for link
8120 do
8121 func_append linknames " $link"
8122 done
8123
8124 # Use standard objects if they are pic
8125 test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP`
8126 test "X$libobjs" = "X " && libobjs=
8127
8128 delfiles=
8129 if test -n "$export_symbols" && test -n "$include_expsyms"; then
8130 $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp"
8131 export_symbols="$output_objdir/$libname.uexp"
8132 func_append delfiles " $export_symbols"
8133 fi
8134
8135 orig_export_symbols=
8136 case $host_os in
8137 cygwin* | mingw* | cegcc*)
8138 if test -n "$export_symbols" && test -z "$export_symbols_regex"; then
8139 # exporting using user supplied symfile
8140 if test "x`$SED 1q $export_symbols`" != xEXPORTS; then
8141 # and it's NOT already a .def file. Must figure out
8142 # which of the given symbols are data symbols and tag
8143 # them as such. So, trigger use of export_symbols_cmds.
8144 # export_symbols gets reassigned inside the "prepare
8145 # the list of exported symbols" if statement, so the
8146 # include_expsyms logic still works.
8147 orig_export_symbols="$export_symbols"
8148 export_symbols=
8149 always_export_symbols=yes
8150 fi
8151 fi
8152 ;;
8153 esac
8154
8155 # Prepare the list of exported symbols
8156 if test -z "$export_symbols"; then
8157 if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then
8158 func_verbose "generating symbol list for \`$libname.la'"
8159 export_symbols="$output_objdir/$libname.exp"
8160 $opt_dry_run || $RM $export_symbols
8161 cmds=$export_symbols_cmds
8162 save_ifs="$IFS"; IFS='~'
8163 for cmd1 in $cmds; do
8164 IFS="$save_ifs"
8165 # Take the normal branch if the nm_file_list_spec branch
8166 # doesn't work or if tool conversion is not needed.
8167 case $nm_file_list_spec~$to_tool_file_cmd in
8168 *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*)
8169 try_normal_branch=yes
8170 eval cmd=\"$cmd1\"
8171 func_len " $cmd"
8172 len=$func_len_result
8173 ;;
8174 *)
8175 try_normal_branch=no
8176 ;;
8177 esac
8178 if test "$try_normal_branch" = yes \
8179 && { test "$len" -lt "$max_cmd_len" \
8180 || test "$max_cmd_len" -le -1; }
8181 then
8182 func_show_eval "$cmd" 'exit $?'
8183 skipped_export=false
8184 elif test -n "$nm_file_list_spec"; then
8185 func_basename "$output"
8186 output_la=$func_basename_result
8187 save_libobjs=$libobjs
8188 save_output=$output
8189 output=${output_objdir}/${output_la}.nm
8190 func_to_tool_file "$output"
8191 libobjs=$nm_file_list_spec$func_to_tool_file_result
8192 func_append delfiles " $output"
8193 func_verbose "creating $NM input file list: $output"
8194 for obj in $save_libobjs; do
8195 func_to_tool_file "$obj"
8196 $ECHO "$func_to_tool_file_result"
8197 done > "$output"
8198 eval cmd=\"$cmd1\"
8199 func_show_eval "$cmd" 'exit $?'
8200 output=$save_output
8201 libobjs=$save_libobjs
8202 skipped_export=false
8203 else
8204 # The command line is too long to execute in one step.
8205 func_verbose "using reloadable object file for export list..."
8206 skipped_export=:
8207 # Break out early, otherwise skipped_export may be
8208 # set to false by a later but shorter cmd.
8209 break
8210 fi
8211 done
8212 IFS="$save_ifs"
8213 if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then
8214 func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"'
8215 func_show_eval '$MV "${export_symbols}T" "$export_symbols"'
8216 fi
8217 fi
8218 fi
8219
8220 if test -n "$export_symbols" && test -n "$include_expsyms"; then
8221 tmp_export_symbols="$export_symbols"
8222 test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
8223 $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
8224 fi
8225
8226 if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then
8227 # The given exports_symbols file has to be filtered, so filter it.
8228 func_verbose "filter symbol list for \`$libname.la' to tag DATA exports"
8229 # FIXME: $output_objdir/$libname.filter potentially contains lots of
8230 # 's' commands which not all seds can handle. GNU sed should be fine
8231 # though. Also, the filter scales superlinearly with the number of
8232 # global variables. join(1) would be nice here, but unfortunately
8233 # isn't a blessed tool.
8234 $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter
8235 func_append delfiles " $export_symbols $output_objdir/$libname.filter"
8236 export_symbols=$output_objdir/$libname.def
8237 $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
8238 fi
8239
8240 tmp_deplibs=
8241 for test_deplib in $deplibs; do
8242 case " $convenience " in
8243 *" $test_deplib "*) ;;
8244 *)
8245 func_append tmp_deplibs " $test_deplib"
8246 ;;
8247 esac
8248 done
8249 deplibs="$tmp_deplibs"
8250
8251 if test -n "$convenience"; then
8252 if test -n "$whole_archive_flag_spec" &&
8253 test "$compiler_needs_object" = yes &&
8254 test -z "$libobjs"; then
8255 # extract the archives, so we have objects to list.
8256 # TODO: could optimize this to just extract one archive.
8257 whole_archive_flag_spec=
8258 fi
8259 if test -n "$whole_archive_flag_spec"; then
8260 save_libobjs=$libobjs
8261 eval libobjs=\"\$libobjs $whole_archive_flag_spec\"
8262 test "X$libobjs" = "X " && libobjs=
8263 else
8264 gentop="$output_objdir/${outputname}x"
8265 func_append generated " $gentop"
8266
8267 func_extract_archives $gentop $convenience
8268 func_append libobjs " $func_extract_archives_result"
8269 test "X$libobjs" = "X " && libobjs=
8270 fi
8271 fi
8272
8273 if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then
8274 eval flag=\"$thread_safe_flag_spec\"
8275 func_append linker_flags " $flag"
8276 fi
8277
8278 # Make a backup of the uninstalled library when relinking
8279 if test "$opt_mode" = relink; then
8280 $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $?
8281 fi
8282
8283 # Do each of the archive commands.
8284 if test "$module" = yes && test -n "$module_cmds" ; then
8285 if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then
8286 eval test_cmds=\"$module_expsym_cmds\"
8287 cmds=$module_expsym_cmds
8288 else
8289 eval test_cmds=\"$module_cmds\"
8290 cmds=$module_cmds
8291 fi
8292 else
8293 if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then
8294 eval test_cmds=\"$archive_expsym_cmds\"
8295 cmds=$archive_expsym_cmds
8296 else
8297 eval test_cmds=\"$archive_cmds\"
8298 cmds=$archive_cmds
8299 fi
8300 fi
8301
8302 if test "X$skipped_export" != "X:" &&
8303 func_len " $test_cmds" &&
8304 len=$func_len_result &&
8305 test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then
8306 :
8307 else
8308 # The command line is too long to link in one step, link piecewise
8309 # or, if using GNU ld and skipped_export is not :, use a linker
8310 # script.
8311
8312 # Save the value of $output and $libobjs because we want to
8313 # use them later. If we have whole_archive_flag_spec, we
8314 # want to use save_libobjs as it was before
8315 # whole_archive_flag_spec was expanded, because we can't
8316 # assume the linker understands whole_archive_flag_spec.
8317 # This may have to be revisited, in case too many
8318 # convenience libraries get linked in and end up exceeding
8319 # the spec.
8320 if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then
8321 save_libobjs=$libobjs
8322 fi
8323 save_output=$output
8324 func_basename "$output"
8325 output_la=$func_basename_result
8326
8327 # Clear the reloadable object creation command queue and
8328 # initialize k to one.
8329 test_cmds=
8330 concat_cmds=
8331 objlist=
8332 last_robj=
8333 k=1
8334
8335 if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then
8336 output=${output_objdir}/${output_la}.lnkscript
8337 func_verbose "creating GNU ld script: $output"
8338 echo 'INPUT (' > $output
8339 for obj in $save_libobjs
8340 do
8341 func_to_tool_file "$obj"
8342 $ECHO "$func_to_tool_file_result" >> $output
8343 done
8344 echo ')' >> $output
8345 func_append delfiles " $output"
8346 func_to_tool_file "$output"
8347 output=$func_to_tool_file_result
8348 elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then
8349 output=${output_objdir}/${output_la}.lnk
8350 func_verbose "creating linker input file list: $output"
8351 : > $output
8352 set x $save_libobjs
8353 shift
8354 firstobj=
8355 if test "$compiler_needs_object" = yes; then
8356 firstobj="$1 "
8357 shift
8358 fi
8359 for obj
8360 do
8361 func_to_tool_file "$obj"
8362 $ECHO "$func_to_tool_file_result" >> $output
8363 done
8364 func_append delfiles " $output"
8365 func_to_tool_file "$output"
8366 output=$firstobj\"$file_list_spec$func_to_tool_file_result\"
8367 else
8368 if test -n "$save_libobjs"; then
8369 func_verbose "creating reloadable object files..."
8370 output=$output_objdir/$output_la-${k}.$objext
8371 eval test_cmds=\"$reload_cmds\"
8372 func_len " $test_cmds"
8373 len0=$func_len_result
8374 len=$len0
8375
8376 # Loop over the list of objects to be linked.
8377 for obj in $save_libobjs
8378 do
8379 func_len " $obj"
8380 func_arith $len + $func_len_result
8381 len=$func_arith_result
8382 if test "X$objlist" = X ||
8383 test "$len" -lt "$max_cmd_len"; then
8384 func_append objlist " $obj"
8385 else
8386 # The command $test_cmds is almost too long, add a
8387 # command to the queue.
8388 if test "$k" -eq 1 ; then
8389 # The first file doesn't have a previous command to add.
8390 reload_objs=$objlist
8391 eval concat_cmds=\"$reload_cmds\"
8392 else
8393 # All subsequent reloadable object files will link in
8394 # the last one created.
8395 reload_objs="$objlist $last_robj"
8396 eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\"
8397 fi
8398 last_robj=$output_objdir/$output_la-${k}.$objext
8399 func_arith $k + 1
8400 k=$func_arith_result
8401 output=$output_objdir/$output_la-${k}.$objext
8402 objlist=" $obj"
8403 func_len " $last_robj"
8404 func_arith $len0 + $func_len_result
8405 len=$func_arith_result
8406 fi
8407 done
8408 # Handle the remaining objects by creating one last
8409 # reloadable object file. All subsequent reloadable object
8410 # files will link in the last one created.
8411 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
8412 reload_objs="$objlist $last_robj"
8413 eval concat_cmds=\"\${concat_cmds}$reload_cmds\"
8414 if test -n "$last_robj"; then
8415 eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\"
8416 fi
8417 func_append delfiles " $output"
8418
8419 else
8420 output=
8421 fi
8422
8423 if ${skipped_export-false}; then
8424 func_verbose "generating symbol list for \`$libname.la'"
8425 export_symbols="$output_objdir/$libname.exp"
8426 $opt_dry_run || $RM $export_symbols
8427 libobjs=$output
8428 # Append the command to create the export file.
8429 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
8430 eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\"
8431 if test -n "$last_robj"; then
8432 eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\"
8433 fi
8434 fi
8435
8436 test -n "$save_libobjs" &&
8437 func_verbose "creating a temporary reloadable object file: $output"
8438
8439 # Loop through the commands generated above and execute them.
8440 save_ifs="$IFS"; IFS='~'
8441 for cmd in $concat_cmds; do
8442 IFS="$save_ifs"
8443 $opt_silent || {
8444 func_quote_for_expand "$cmd"
8445 eval "func_echo $func_quote_for_expand_result"
8446 }
8447 $opt_dry_run || eval "$cmd" || {
8448 lt_exit=$?
8449
8450 # Restore the uninstalled library and exit
8451 if test "$opt_mode" = relink; then
8452 ( cd "$output_objdir" && \
8453 $RM "${realname}T" && \
8454 $MV "${realname}U" "$realname" )
8455 fi
8456
8457 exit $lt_exit
8458 }
8459 done
8460 IFS="$save_ifs"
8461
8462 if test -n "$export_symbols_regex" && ${skipped_export-false}; then
8463 func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"'
8464 func_show_eval '$MV "${export_symbols}T" "$export_symbols"'
8465 fi
8466 fi
8467
8468 if ${skipped_export-false}; then
8469 if test -n "$export_symbols" && test -n "$include_expsyms"; then
8470 tmp_export_symbols="$export_symbols"
8471 test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
8472 $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"'
8473 fi
8474
8475 if test -n "$orig_export_symbols"; then
8476 # The given exports_symbols file has to be filtered, so filter it.
8477 func_verbose "filter symbol list for \`$libname.la' to tag DATA exports"
8478 # FIXME: $output_objdir/$libname.filter potentially contains lots of
8479 # 's' commands which not all seds can handle. GNU sed should be fine
8480 # though. Also, the filter scales superlinearly with the number of
8481 # global variables. join(1) would be nice here, but unfortunately
8482 # isn't a blessed tool.
8483 $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter
8484 func_append delfiles " $export_symbols $output_objdir/$libname.filter"
8485 export_symbols=$output_objdir/$libname.def
8486 $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
8487 fi
8488 fi
8489
8490 libobjs=$output
8491 # Restore the value of output.
8492 output=$save_output
8493
8494 if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then
8495 eval libobjs=\"\$libobjs $whole_archive_flag_spec\"
8496 test "X$libobjs" = "X " && libobjs=
8497 fi
8498 # Expand the library linking commands again to reset the
8499 # value of $libobjs for piecewise linking.
8500
8501 # Do each of the archive commands.
8502 if test "$module" = yes && test -n "$module_cmds" ; then
8503 if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then
8504 cmds=$module_expsym_cmds
8505 else
8506 cmds=$module_cmds
8507 fi
8508 else
8509 if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then
8510 cmds=$archive_expsym_cmds
8511 else
8512 cmds=$archive_cmds
8513 fi
8514 fi
8515 fi
8516
8517 if test -n "$delfiles"; then
8518 # Append the command to remove temporary files to $cmds.
8519 eval cmds=\"\$cmds~\$RM $delfiles\"
8520 fi
8521
8522 # Add any objects from preloaded convenience libraries
8523 if test -n "$dlprefiles"; then
8524 gentop="$output_objdir/${outputname}x"
8525 func_append generated " $gentop"
8526
8527 func_extract_archives $gentop $dlprefiles
8528 func_append libobjs " $func_extract_archives_result"
8529 test "X$libobjs" = "X " && libobjs=
8530 fi
8531
8532 save_ifs="$IFS"; IFS='~'
8533 for cmd in $cmds; do
8534 IFS="$save_ifs"
8535 eval cmd=\"$cmd\"
8536 $opt_silent || {
8537 func_quote_for_expand "$cmd"
8538 eval "func_echo $func_quote_for_expand_result"
8539 }
8540 $opt_dry_run || eval "$cmd" || {
8541 lt_exit=$?
8542
8543 # Restore the uninstalled library and exit
8544 if test "$opt_mode" = relink; then
8545 ( cd "$output_objdir" && \
8546 $RM "${realname}T" && \
8547 $MV "${realname}U" "$realname" )
8548 fi
8549
8550 exit $lt_exit
8551 }
8552 done
8553 IFS="$save_ifs"
8554
8555 # Restore the uninstalled library and exit
8556 if test "$opt_mode" = relink; then
8557 $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $?
8558
8559 if test -n "$convenience"; then
8560 if test -z "$whole_archive_flag_spec"; then
8561 func_show_eval '${RM}r "$gentop"'
8562 fi
8563 fi
8564
8565 exit $EXIT_SUCCESS
8566 fi
8567
8568 # Create links to the real library.
8569 for linkname in $linknames; do
8570 if test "$realname" != "$linkname"; then
8571 func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?'
8572 fi
8573 done
8574
8575 # If -module or -export-dynamic was specified, set the dlname.
8576 if test "$module" = yes || test "$export_dynamic" = yes; then
8577 # On all known operating systems, these are identical.
8578 dlname="$soname"
8579 fi
8580 fi
8581 ;;
8582
8583 obj)
8584 if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
8585 func_warning "\`-dlopen' is ignored for objects"
8586 fi
8587
8588 case " $deplibs" in
8589 *\ -l* | *\ -L*)
8590 func_warning "\`-l' and \`-L' are ignored for objects" ;;
8591 esac
8592
8593 test -n "$rpath" && \
8594 func_warning "\`-rpath' is ignored for objects"
8595
8596 test -n "$xrpath" && \
8597 func_warning "\`-R' is ignored for objects"
8598
8599 test -n "$vinfo" && \
8600 func_warning "\`-version-info' is ignored for objects"
8601
8602 test -n "$release" && \
8603 func_warning "\`-release' is ignored for objects"
8604
8605 case $output in
8606 *.lo)
8607 test -n "$objs$old_deplibs" && \
8608 func_fatal_error "cannot build library object \`$output' from non-libtool objects"
8609
8610 libobj=$output
8611 func_lo2o "$libobj"
8612 obj=$func_lo2o_result
8613 ;;
8614 *)
8615 libobj=
8616 obj="$output"
8617 ;;
8618 esac
8619
8620 # Delete the old objects.
8621 $opt_dry_run || $RM $obj $libobj
8622
8623 # Objects from convenience libraries. This assumes
8624 # single-version convenience libraries. Whenever we create
8625 # different ones for PIC/non-PIC, this we'll have to duplicate
8626 # the extraction.
8627 reload_conv_objs=
8628 gentop=
8629 # reload_cmds runs $LD directly, so let us get rid of
8630 # -Wl from whole_archive_flag_spec and hope we can get by with
8631 # turning comma into space..
8632 wl=
8633
8634 if test -n "$convenience"; then
8635 if test -n "$whole_archive_flag_spec"; then
8636 eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\"
8637 reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'`
8638 else
8639 gentop="$output_objdir/${obj}x"
8640 func_append generated " $gentop"
8641
8642 func_extract_archives $gentop $convenience
8643 reload_conv_objs="$reload_objs $func_extract_archives_result"
8644 fi
8645 fi
8646
8647 # If we're not building shared, we need to use non_pic_objs
8648 test "$build_libtool_libs" != yes && libobjs="$non_pic_objects"
8649
8650 # Create the old-style object.
8651 reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test
8652
8653 output="$obj"
8654 func_execute_cmds "$reload_cmds" 'exit $?'
8655
8656 # Exit if we aren't doing a library object file.
8657 if test -z "$libobj"; then
8658 if test -n "$gentop"; then
8659 func_show_eval '${RM}r "$gentop"'
8660 fi
8661
8662 exit $EXIT_SUCCESS
8663 fi
8664
8665 if test "$build_libtool_libs" != yes; then
8666 if test -n "$gentop"; then
8667 func_show_eval '${RM}r "$gentop"'
8668 fi
8669
8670 # Create an invalid libtool object if no PIC, so that we don't
8671 # accidentally link it into a program.
8672 # $show "echo timestamp > $libobj"
8673 # $opt_dry_run || eval "echo timestamp > $libobj" || exit $?
8674 exit $EXIT_SUCCESS
8675 fi
8676
8677 if test -n "$pic_flag" || test "$pic_mode" != default; then
8678 # Only do commands if we really have different PIC objects.
8679 reload_objs="$libobjs $reload_conv_objs"
8680 output="$libobj"
8681 func_execute_cmds "$reload_cmds" 'exit $?'
8682 fi
8683
8684 if test -n "$gentop"; then
8685 func_show_eval '${RM}r "$gentop"'
8686 fi
8687
8688 exit $EXIT_SUCCESS
8689 ;;
8690
8691 prog)
8692 case $host in
8693 *cygwin*) func_stripname '' '.exe' "$output"
8694 output=$func_stripname_result.exe;;
8695 esac
8696 test -n "$vinfo" && \
8697 func_warning "\`-version-info' is ignored for programs"
8698
8699 test -n "$release" && \
8700 func_warning "\`-release' is ignored for programs"
8701
8702 test "$preload" = yes \
8703 && test "$dlopen_support" = unknown \
8704 && test "$dlopen_self" = unknown \
8705 && test "$dlopen_self_static" = unknown && \
8706 func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support."
8707
8708 case $host in
8709 *-*-rhapsody* | *-*-darwin1.[012])
8710 # On Rhapsody replace the C library is the System framework
8711 compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'`
8712 finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'`
8713 ;;
8714 esac
8715
8716 case $host in
8717 *-*-darwin*)
8718 # Don't allow lazy linking, it breaks C++ global constructors
8719 # But is supposedly fixed on 10.4 or later (yay!).
8720 if test "$tagname" = CXX ; then
8721 case ${MACOSX_DEPLOYMENT_TARGET-10.0} in
8722 10.[0123])
8723 func_append compile_command " ${wl}-bind_at_load"
8724 func_append finalize_command " ${wl}-bind_at_load"
8725 ;;
8726 esac
8727 fi
8728 # Time to change all our "foo.ltframework" stuff back to "-framework foo"
8729 compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
8730 finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'`
8731 ;;
8732 esac
8733
8734
8735 # move library search paths that coincide with paths to not yet
8736 # installed libraries to the beginning of the library search list
8737 new_libs=
8738 for path in $notinst_path; do
8739 case " $new_libs " in
8740 *" -L$path/$objdir "*) ;;
8741 *)
8742 case " $compile_deplibs " in
8743 *" -L$path/$objdir "*)
8744 func_append new_libs " -L$path/$objdir" ;;
8745 esac
8746 ;;
8747 esac
8748 done
8749 for deplib in $compile_deplibs; do
8750 case $deplib in
8751 -L*)
8752 case " $new_libs " in
8753 *" $deplib "*) ;;
8754 *) func_append new_libs " $deplib" ;;
8755 esac
8756 ;;
8757 *) func_append new_libs " $deplib" ;;
8758 esac
8759 done
8760 compile_deplibs="$new_libs"
8761
8762
8763 func_append compile_command " $compile_deplibs"
8764 func_append finalize_command " $finalize_deplibs"
8765
8766 if test -n "$rpath$xrpath"; then
8767 # If the user specified any rpath flags, then add them.
8768 for libdir in $rpath $xrpath; do
8769 # This is the magic to use -rpath.
8770 case "$finalize_rpath " in
8771 *" $libdir "*) ;;
8772 *) func_append finalize_rpath " $libdir" ;;
8773 esac
8774 done
8775 fi
8776
8777 # Now hardcode the library paths
8778 rpath=
8779 hardcode_libdirs=
8780 for libdir in $compile_rpath $finalize_rpath; do
8781 if test -n "$hardcode_libdir_flag_spec"; then
8782 if test -n "$hardcode_libdir_separator"; then
8783 if test -z "$hardcode_libdirs"; then
8784 hardcode_libdirs="$libdir"
8785 else
8786 # Just accumulate the unique libdirs.
8787 case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
8788 *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
8789 ;;
8790 *)
8791 func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
8792 ;;
8793 esac
8794 fi
8795 else
8796 eval flag=\"$hardcode_libdir_flag_spec\"
8797 func_append rpath " $flag"
8798 fi
8799 elif test -n "$runpath_var"; then
8800 case "$perm_rpath " in
8801 *" $libdir "*) ;;
8802 *) func_append perm_rpath " $libdir" ;;
8803 esac
8804 fi
8805 case $host in
8806 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*)
8807 testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'`
8808 case :$dllsearchpath: in
8809 *":$libdir:"*) ;;
8810 ::) dllsearchpath=$libdir;;
8811 *) func_append dllsearchpath ":$libdir";;
8812 esac
8813 case :$dllsearchpath: in
8814 *":$testbindir:"*) ;;
8815 ::) dllsearchpath=$testbindir;;
8816 *) func_append dllsearchpath ":$testbindir";;
8817 esac
8818 ;;
8819 esac
8820 done
8821 # Substitute the hardcoded libdirs into the rpath.
8822 if test -n "$hardcode_libdir_separator" &&
8823 test -n "$hardcode_libdirs"; then
8824 libdir="$hardcode_libdirs"
8825 eval rpath=\" $hardcode_libdir_flag_spec\"
8826 fi
8827 compile_rpath="$rpath"
8828
8829 rpath=
8830 hardcode_libdirs=
8831 for libdir in $finalize_rpath; do
8832 if test -n "$hardcode_libdir_flag_spec"; then
8833 if test -n "$hardcode_libdir_separator"; then
8834 if test -z "$hardcode_libdirs"; then
8835 hardcode_libdirs="$libdir"
8836 else
8837 # Just accumulate the unique libdirs.
8838 case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
8839 *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
8840 ;;
8841 *)
8842 func_append hardcode_libdirs "$hardcode_libdir_separator$libdir"
8843 ;;
8844 esac
8845 fi
8846 else
8847 eval flag=\"$hardcode_libdir_flag_spec\"
8848 func_append rpath " $flag"
8849 fi
8850 elif test -n "$runpath_var"; then
8851 case "$finalize_perm_rpath " in
8852 *" $libdir "*) ;;
8853 *) func_append finalize_perm_rpath " $libdir" ;;
8854 esac
8855 fi
8856 done
8857 # Substitute the hardcoded libdirs into the rpath.
8858 if test -n "$hardcode_libdir_separator" &&
8859 test -n "$hardcode_libdirs"; then
8860 libdir="$hardcode_libdirs"
8861 eval rpath=\" $hardcode_libdir_flag_spec\"
8862 fi
8863 finalize_rpath="$rpath"
8864
8865 if test -n "$libobjs" && test "$build_old_libs" = yes; then
8866 # Transform all the library objects into standard objects.
8867 compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP`
8868 finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP`
8869 fi
8870
8871 func_generate_dlsyms "$outputname" "@PROGRAM@" "no"
8872
8873 # template prelinking step
8874 if test -n "$prelink_cmds"; then
8875 func_execute_cmds "$prelink_cmds" 'exit $?'
8876 fi
8877
8878 wrappers_required=yes
8879 case $host in
8880 *cegcc* | *mingw32ce*)
8881 # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway.
8882 wrappers_required=no
8883 ;;
8884 *cygwin* | *mingw* )
8885 if test "$build_libtool_libs" != yes; then
8886 wrappers_required=no
8887 fi
8888 ;;
8889 *)
8890 if test "$need_relink" = no || test "$build_libtool_libs" != yes; then
8891 wrappers_required=no
8892 fi
8893 ;;
8894 esac
8895 if test "$wrappers_required" = no; then
8896 # Replace the output file specification.
8897 compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'`
8898 link_command="$compile_command$compile_rpath"
8899
8900 # We have no uninstalled library dependencies, so finalize right now.
8901 exit_status=0
8902 func_show_eval "$link_command" 'exit_status=$?'
8903
8904 if test -n "$postlink_cmds"; then
8905 func_to_tool_file "$output"
8906 postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
8907 func_execute_cmds "$postlink_cmds" 'exit $?'
8908 fi
8909
8910 # Delete the generated files.
8911 if test -f "$output_objdir/${outputname}S.${objext}"; then
8912 func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"'
8913 fi
8914
8915 exit $exit_status
8916 fi
8917
8918 if test -n "$compile_shlibpath$finalize_shlibpath"; then
8919 compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command"
8920 fi
8921 if test -n "$finalize_shlibpath"; then
8922 finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command"
8923 fi
8924
8925 compile_var=
8926 finalize_var=
8927 if test -n "$runpath_var"; then
8928 if test -n "$perm_rpath"; then
8929 # We should set the runpath_var.
8930 rpath=
8931 for dir in $perm_rpath; do
8932 func_append rpath "$dir:"
8933 done
8934 compile_var="$runpath_var=\"$rpath\$$runpath_var\" "
8935 fi
8936 if test -n "$finalize_perm_rpath"; then
8937 # We should set the runpath_var.
8938 rpath=
8939 for dir in $finalize_perm_rpath; do
8940 func_append rpath "$dir:"
8941 done
8942 finalize_var="$runpath_var=\"$rpath\$$runpath_var\" "
8943 fi
8944 fi
8945
8946 if test "$no_install" = yes; then
8947 # We don't need to create a wrapper script.
8948 link_command="$compile_var$compile_command$compile_rpath"
8949 # Replace the output file specification.
8950 link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'`
8951 # Delete the old output file.
8952 $opt_dry_run || $RM $output
8953 # Link the executable and exit
8954 func_show_eval "$link_command" 'exit $?'
8955
8956 if test -n "$postlink_cmds"; then
8957 func_to_tool_file "$output"
8958 postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
8959 func_execute_cmds "$postlink_cmds" 'exit $?'
8960 fi
8961
8962 exit $EXIT_SUCCESS
8963 fi
8964
8965 if test "$hardcode_action" = relink; then
8966 # Fast installation is not supported
8967 link_command="$compile_var$compile_command$compile_rpath"
8968 relink_command="$finalize_var$finalize_command$finalize_rpath"
8969
8970 func_warning "this platform does not like uninstalled shared libraries"
8971 func_warning "\`$output' will be relinked during installation"
8972 else
8973 if test "$fast_install" != no; then
8974 link_command="$finalize_var$compile_command$finalize_rpath"
8975 if test "$fast_install" = yes; then
8976 relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'`
8977 else
8978 # fast_install is set to needless
8979 relink_command=
8980 fi
8981 else
8982 link_command="$compile_var$compile_command$compile_rpath"
8983 relink_command="$finalize_var$finalize_command$finalize_rpath"
8984 fi
8985 fi
8986
8987 # Replace the output file specification.
8988 link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'`
8989
8990 # Delete the old output files.
8991 $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname
8992
8993 func_show_eval "$link_command" 'exit $?'
8994
8995 if test -n "$postlink_cmds"; then
8996 func_to_tool_file "$output_objdir/$outputname"
8997 postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'`
8998 func_execute_cmds "$postlink_cmds" 'exit $?'
8999 fi
9000
9001 # Now create the wrapper script.
9002 func_verbose "creating $output"
9003
9004 # Quote the relink command for shipping.
9005 if test -n "$relink_command"; then
9006 # Preserve any variables that may affect compiler behavior
9007 for var in $variables_saved_for_relink; do
9008 if eval test -z \"\${$var+set}\"; then
9009 relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command"
9010 elif eval var_value=\$$var; test -z "$var_value"; then
9011 relink_command="$var=; export $var; $relink_command"
9012 else
9013 func_quote_for_eval "$var_value"
9014 relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command"
9015 fi
9016 done
9017 relink_command="(cd `pwd`; $relink_command)"
9018 relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"`
9019 fi
9020
9021 # Only actually do things if not in dry run mode.
9022 $opt_dry_run || {
9023 # win32 will think the script is a binary if it has
9024 # a .exe suffix, so we strip it off here.
9025 case $output in
9026 *.exe) func_stripname '' '.exe' "$output"
9027 output=$func_stripname_result ;;
9028 esac
9029 # test for cygwin because mv fails w/o .exe extensions
9030 case $host in
9031 *cygwin*)
9032 exeext=.exe
9033 func_stripname '' '.exe' "$outputname"
9034 outputname=$func_stripname_result ;;
9035 *) exeext= ;;
9036 esac
9037 case $host in
9038 *cygwin* | *mingw* )
9039 func_dirname_and_basename "$output" "" "."
9040 output_name=$func_basename_result
9041 output_path=$func_dirname_result
9042 cwrappersource="$output_path/$objdir/lt-$output_name.c"
9043 cwrapper="$output_path/$output_name.exe"
9044 $RM $cwrappersource $cwrapper
9045 trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15
9046
9047 func_emit_cwrapperexe_src > $cwrappersource
9048
9049 # The wrapper executable is built using the $host compiler,
9050 # because it contains $host paths and files. If cross-
9051 # compiling, it, like the target executable, must be
9052 # executed on the $host or under an emulation environment.
9053 $opt_dry_run || {
9054 $LTCC $LTCFLAGS -o $cwrapper $cwrappersource
9055 $STRIP $cwrapper
9056 }
9057
9058 # Now, create the wrapper script for func_source use:
9059 func_ltwrapper_scriptname $cwrapper
9060 $RM $func_ltwrapper_scriptname_result
9061 trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15
9062 $opt_dry_run || {
9063 # note: this script will not be executed, so do not chmod.
9064 if test "x$build" = "x$host" ; then
9065 $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result
9066 else
9067 func_emit_wrapper no > $func_ltwrapper_scriptname_result
9068 fi
9069 }
9070 ;;
9071 * )
9072 $RM $output
9073 trap "$RM $output; exit $EXIT_FAILURE" 1 2 15
9074
9075 func_emit_wrapper no > $output
9076 chmod +x $output
9077 ;;
9078 esac
9079 }
9080 exit $EXIT_SUCCESS
9081 ;;
9082 esac
9083
9084 # See if we need to build an old-fashioned archive.
9085 for oldlib in $oldlibs; do
9086
9087 if test "$build_libtool_libs" = convenience; then
9088 oldobjs="$libobjs_save $symfileobj"
9089 addlibs="$convenience"
9090 build_libtool_libs=no
9091 else
9092 if test "$build_libtool_libs" = module; then
9093 oldobjs="$libobjs_save"
9094 build_libtool_libs=no
9095 else
9096 oldobjs="$old_deplibs $non_pic_objects"
9097 if test "$preload" = yes && test -f "$symfileobj"; then
9098 func_append oldobjs " $symfileobj"
9099 fi
9100 fi
9101 addlibs="$old_convenience"
9102 fi
9103
9104 if test -n "$addlibs"; then
9105 gentop="$output_objdir/${outputname}x"
9106 func_append generated " $gentop"
9107
9108 func_extract_archives $gentop $addlibs
9109 func_append oldobjs " $func_extract_archives_result"
9110 fi
9111
9112 # Do each command in the archive commands.
9113 if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then
9114 cmds=$old_archive_from_new_cmds
9115 else
9116
9117 # Add any objects from preloaded convenience libraries
9118 if test -n "$dlprefiles"; then
9119 gentop="$output_objdir/${outputname}x"
9120 func_append generated " $gentop"
9121
9122 func_extract_archives $gentop $dlprefiles
9123 func_append oldobjs " $func_extract_archives_result"
9124 fi
9125
9126 # POSIX demands no paths to be encoded in archives. We have
9127 # to avoid creating archives with duplicate basenames if we
9128 # might have to extract them afterwards, e.g., when creating a
9129 # static archive out of a convenience library, or when linking
9130 # the entirety of a libtool archive into another (currently
9131 # not supported by libtool).
9132 if (for obj in $oldobjs
9133 do
9134 func_basename "$obj"
9135 $ECHO "$func_basename_result"
9136 done | sort | sort -uc >/dev/null 2>&1); then
9137 :
9138 else
9139 echo "copying selected object files to avoid basename conflicts..."
9140 gentop="$output_objdir/${outputname}x"
9141 func_append generated " $gentop"
9142 func_mkdir_p "$gentop"
9143 save_oldobjs=$oldobjs
9144 oldobjs=
9145 counter=1
9146 for obj in $save_oldobjs
9147 do
9148 func_basename "$obj"
9149 objbase="$func_basename_result"
9150 case " $oldobjs " in
9151 " ") oldobjs=$obj ;;
9152 *[\ /]"$objbase "*)
9153 while :; do
9154 # Make sure we don't pick an alternate name that also
9155 # overlaps.
9156 newobj=lt$counter-$objbase
9157 func_arith $counter + 1
9158 counter=$func_arith_result
9159 case " $oldobjs " in
9160 *[\ /]"$newobj "*) ;;
9161 *) if test ! -f "$gentop/$newobj"; then break; fi ;;
9162 esac
9163 done
9164 func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj"
9165 func_append oldobjs " $gentop/$newobj"
9166 ;;
9167 *) func_append oldobjs " $obj" ;;
9168 esac
9169 done
9170 fi
9171 func_to_tool_file "$oldlib" func_convert_file_msys_to_w32
9172 tool_oldlib=$func_to_tool_file_result
9173 eval cmds=\"$old_archive_cmds\"
9174
9175 func_len " $cmds"
9176 len=$func_len_result
9177 if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then
9178 cmds=$old_archive_cmds
9179 elif test -n "$archiver_list_spec"; then
9180 func_verbose "using command file archive linking..."
9181 for obj in $oldobjs
9182 do
9183 func_to_tool_file "$obj"
9184 $ECHO "$func_to_tool_file_result"
9185 done > $output_objdir/$libname.libcmd
9186 func_to_tool_file "$output_objdir/$libname.libcmd"
9187 oldobjs=" $archiver_list_spec$func_to_tool_file_result"
9188 cmds=$old_archive_cmds
9189 else
9190 # the command line is too long to link in one step, link in parts
9191 func_verbose "using piecewise archive linking..."
9192 save_RANLIB=$RANLIB
9193 RANLIB=:
9194 objlist=
9195 concat_cmds=
9196 save_oldobjs=$oldobjs
9197 oldobjs=
9198 # Is there a better way of finding the last object in the list?
9199 for obj in $save_oldobjs
9200 do
9201 last_oldobj=$obj
9202 done
9203 eval test_cmds=\"$old_archive_cmds\"
9204 func_len " $test_cmds"
9205 len0=$func_len_result
9206 len=$len0
9207 for obj in $save_oldobjs
9208 do
9209 func_len " $obj"
9210 func_arith $len + $func_len_result
9211 len=$func_arith_result
9212 func_append objlist " $obj"
9213 if test "$len" -lt "$max_cmd_len"; then
9214 :
9215 else
9216 # the above command should be used before it gets too long
9217 oldobjs=$objlist
9218 if test "$obj" = "$last_oldobj" ; then
9219 RANLIB=$save_RANLIB
9220 fi
9221 test -z "$concat_cmds" || concat_cmds=$concat_cmds~
9222 eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\"
9223 objlist=
9224 len=$len0
9225 fi
9226 done
9227 RANLIB=$save_RANLIB
9228 oldobjs=$objlist
9229 if test "X$oldobjs" = "X" ; then
9230 eval cmds=\"\$concat_cmds\"
9231 else
9232 eval cmds=\"\$concat_cmds~\$old_archive_cmds\"
9233 fi
9234 fi
9235 fi
9236 func_execute_cmds "$cmds" 'exit $?'
9237 done
9238
9239 test -n "$generated" && \
9240 func_show_eval "${RM}r$generated"
9241
9242 # Now create the libtool archive.
9243 case $output in
9244 *.la)
9245 old_library=
9246 test "$build_old_libs" = yes && old_library="$libname.$libext"
9247 func_verbose "creating $output"
9248
9249 # Preserve any variables that may affect compiler behavior
9250 for var in $variables_saved_for_relink; do
9251 if eval test -z \"\${$var+set}\"; then
9252 relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command"
9253 elif eval var_value=\$$var; test -z "$var_value"; then
9254 relink_command="$var=; export $var; $relink_command"
9255 else
9256 func_quote_for_eval "$var_value"
9257 relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command"
9258 fi
9259 done
9260 # Quote the link command for shipping.
9261 relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)"
9262 relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"`
9263 if test "$hardcode_automatic" = yes ; then
9264 relink_command=
9265 fi
9266
9267 # Only create the output if not a dry run.
9268 $opt_dry_run || {
9269 for installed in no yes; do
9270 if test "$installed" = yes; then
9271 if test -z "$install_libdir"; then
9272 break
9273 fi
9274 output="$output_objdir/$outputname"i
9275 # Replace all uninstalled libtool libraries with the installed ones
9276 newdependency_libs=
9277 for deplib in $dependency_libs; do
9278 case $deplib in
9279 *.la)
9280 func_basename "$deplib"
9281 name="$func_basename_result"
9282 func_resolve_sysroot "$deplib"
9283 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result`
9284 test -z "$libdir" && \
9285 func_fatal_error "\`$deplib' is not a valid libtool archive"
9286 func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name"
9287 ;;
9288 -L*)
9289 func_stripname -L '' "$deplib"
9290 func_replace_sysroot "$func_stripname_result"
9291 func_append newdependency_libs " -L$func_replace_sysroot_result"
9292 ;;
9293 -R*)
9294 func_stripname -R '' "$deplib"
9295 func_replace_sysroot "$func_stripname_result"
9296 func_append newdependency_libs " -R$func_replace_sysroot_result"
9297 ;;
9298 *) func_append newdependency_libs " $deplib" ;;
9299 esac
9300 done
9301 dependency_libs="$newdependency_libs"
9302 newdlfiles=
9303
9304 for lib in $dlfiles; do
9305 case $lib in
9306 *.la)
9307 func_basename "$lib"
9308 name="$func_basename_result"
9309 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
9310 test -z "$libdir" && \
9311 func_fatal_error "\`$lib' is not a valid libtool archive"
9312 func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name"
9313 ;;
9314 *) func_append newdlfiles " $lib" ;;
9315 esac
9316 done
9317 dlfiles="$newdlfiles"
9318 newdlprefiles=
9319 for lib in $dlprefiles; do
9320 case $lib in
9321 *.la)
9322 # Only pass preopened files to the pseudo-archive (for
9323 # eventual linking with the app. that links it) if we
9324 # didn't already link the preopened objects directly into
9325 # the library:
9326 func_basename "$lib"
9327 name="$func_basename_result"
9328 eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
9329 test -z "$libdir" && \
9330 func_fatal_error "\`$lib' is not a valid libtool archive"
9331 func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name"
9332 ;;
9333 esac
9334 done
9335 dlprefiles="$newdlprefiles"
9336 else
9337 newdlfiles=
9338 for lib in $dlfiles; do
9339 case $lib in
9340 [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
9341 *) abs=`pwd`"/$lib" ;;
9342 esac
9343 func_append newdlfiles " $abs"
9344 done
9345 dlfiles="$newdlfiles"
9346 newdlprefiles=
9347 for lib in $dlprefiles; do
9348 case $lib in
9349 [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
9350 *) abs=`pwd`"/$lib" ;;
9351 esac
9352 func_append newdlprefiles " $abs"
9353 done
9354 dlprefiles="$newdlprefiles"
9355 fi
9356 $RM $output
9357 # place dlname in correct position for cygwin
9358 # In fact, it would be nice if we could use this code for all target
9359 # systems that can't hard-code library paths into their executables
9360 # and that have no shared library path variable independent of PATH,
9361 # but it turns out we can't easily determine that from inspecting
9362 # libtool variables, so we have to hard-code the OSs to which it
9363 # applies here; at the moment, that means platforms that use the PE
9364 # object format with DLL files. See the long comment at the top of
9365 # tests/bindir.at for full details.
9366 tdlname=$dlname
9367 case $host,$output,$installed,$module,$dlname in
9368 *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll)
9369 # If a -bindir argument was supplied, place the dll there.
9370 if test "x$bindir" != x ;
9371 then
9372 func_relative_path "$install_libdir" "$bindir"
9373 tdlname=$func_relative_path_result$dlname
9374 else
9375 # Otherwise fall back on heuristic.
9376 tdlname=../bin/$dlname
9377 fi
9378 ;;
9379 esac
9380 $ECHO > $output "\
9381# $outputname - a libtool library file
9382# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
9383#
9384# Please DO NOT delete this file!
9385# It is necessary for linking the library.
9386
9387# The name that we can dlopen(3).
9388dlname='$tdlname'
9389
9390# Names of this library.
9391library_names='$library_names'
9392
9393# The name of the static archive.
9394old_library='$old_library'
9395
9396# Linker flags that can not go in dependency_libs.
9397inherited_linker_flags='$new_inherited_linker_flags'
9398
9399# Libraries that this one depends upon.
9400dependency_libs='$dependency_libs'
9401
9402# Names of additional weak libraries provided by this library
9403weak_library_names='$weak_libs'
9404
9405# Version information for $libname.
9406current=$current
9407age=$age
9408revision=$revision
9409
9410# Is this an already installed library?
9411installed=$installed
9412
9413# Should we warn about portability when linking against -modules?
9414shouldnotlink=$module
9415
9416# Files to dlopen/dlpreopen
9417dlopen='$dlfiles'
9418dlpreopen='$dlprefiles'
9419
9420# Directory that this library needs to be installed in:
9421libdir='$install_libdir'"
9422 if test "$installed" = no && test "$need_relink" = yes; then
9423 $ECHO >> $output "\
9424relink_command=\"$relink_command\""
9425 fi
9426 done
9427 }
9428
9429 # Do a symbolic link so that the libtool archive can be found in
9430 # LD_LIBRARY_PATH before the program is installed.
9431 func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?'
9432 ;;
9433 esac
9434 exit $EXIT_SUCCESS
9435}
9436
9437{ test "$opt_mode" = link || test "$opt_mode" = relink; } &&
9438 func_mode_link ${1+"$@"}
9439
9440
9441# func_mode_uninstall arg...
9442func_mode_uninstall ()
9443{
9444 $opt_debug
9445 RM="$nonopt"
9446 files=
9447 rmforce=
9448 exit_status=0
9449
9450 # This variable tells wrapper scripts just to set variables rather
9451 # than running their programs.
9452 libtool_install_magic="$magic"
9453
9454 for arg
9455 do
9456 case $arg in
9457 -f) func_append RM " $arg"; rmforce=yes ;;
9458 -*) func_append RM " $arg" ;;
9459 *) func_append files " $arg" ;;
9460 esac
9461 done
9462
9463 test -z "$RM" && \
9464 func_fatal_help "you must specify an RM program"
9465
9466 rmdirs=
9467
9468 for file in $files; do
9469 func_dirname "$file" "" "."
9470 dir="$func_dirname_result"
9471 if test "X$dir" = X.; then
9472 odir="$objdir"
9473 else
9474 odir="$dir/$objdir"
9475 fi
9476 func_basename "$file"
9477 name="$func_basename_result"
9478 test "$opt_mode" = uninstall && odir="$dir"
9479
9480 # Remember odir for removal later, being careful to avoid duplicates
9481 if test "$opt_mode" = clean; then
9482 case " $rmdirs " in
9483 *" $odir "*) ;;
9484 *) func_append rmdirs " $odir" ;;
9485 esac
9486 fi
9487
9488 # Don't error if the file doesn't exist and rm -f was used.
9489 if { test -L "$file"; } >/dev/null 2>&1 ||
9490 { test -h "$file"; } >/dev/null 2>&1 ||
9491 test -f "$file"; then
9492 :
9493 elif test -d "$file"; then
9494 exit_status=1
9495 continue
9496 elif test "$rmforce" = yes; then
9497 continue
9498 fi
9499
9500 rmfiles="$file"
9501
9502 case $name in
9503 *.la)
9504 # Possibly a libtool archive, so verify it.
9505 if func_lalib_p "$file"; then
9506 func_source $dir/$name
9507
9508 # Delete the libtool libraries and symlinks.
9509 for n in $library_names; do
9510 func_append rmfiles " $odir/$n"
9511 done
9512 test -n "$old_library" && func_append rmfiles " $odir/$old_library"
9513
9514 case "$opt_mode" in
9515 clean)
9516 case " $library_names " in
9517 *" $dlname "*) ;;
9518 *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;;
9519 esac
9520 test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i"
9521 ;;
9522 uninstall)
9523 if test -n "$library_names"; then
9524 # Do each command in the postuninstall commands.
9525 func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1'
9526 fi
9527
9528 if test -n "$old_library"; then
9529 # Do each command in the old_postuninstall commands.
9530 func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1'
9531 fi
9532 # FIXME: should reinstall the best remaining shared library.
9533 ;;
9534 esac
9535 fi
9536 ;;
9537
9538 *.lo)
9539 # Possibly a libtool object, so verify it.
9540 if func_lalib_p "$file"; then
9541
9542 # Read the .lo file
9543 func_source $dir/$name
9544
9545 # Add PIC object to the list of files to remove.
9546 if test -n "$pic_object" &&
9547 test "$pic_object" != none; then
9548 func_append rmfiles " $dir/$pic_object"
9549 fi
9550
9551 # Add non-PIC object to the list of files to remove.
9552 if test -n "$non_pic_object" &&
9553 test "$non_pic_object" != none; then
9554 func_append rmfiles " $dir/$non_pic_object"
9555 fi
9556 fi
9557 ;;
9558
9559 *)
9560 if test "$opt_mode" = clean ; then
9561 noexename=$name
9562 case $file in
9563 *.exe)
9564 func_stripname '' '.exe' "$file"
9565 file=$func_stripname_result
9566 func_stripname '' '.exe' "$name"
9567 noexename=$func_stripname_result
9568 # $file with .exe has already been added to rmfiles,
9569 # add $file without .exe
9570 func_append rmfiles " $file"
9571 ;;
9572 esac
9573 # Do a test to see if this is a libtool program.
9574 if func_ltwrapper_p "$file"; then
9575 if func_ltwrapper_executable_p "$file"; then
9576 func_ltwrapper_scriptname "$file"
9577 relink_command=
9578 func_source $func_ltwrapper_scriptname_result
9579 func_append rmfiles " $func_ltwrapper_scriptname_result"
9580 else
9581 relink_command=
9582 func_source $dir/$noexename
9583 fi
9584
9585 # note $name still contains .exe if it was in $file originally
9586 # as does the version of $file that was added into $rmfiles
9587 func_append rmfiles " $odir/$name $odir/${name}S.${objext}"
9588 if test "$fast_install" = yes && test -n "$relink_command"; then
9589 func_append rmfiles " $odir/lt-$name"
9590 fi
9591 if test "X$noexename" != "X$name" ; then
9592 func_append rmfiles " $odir/lt-${noexename}.c"
9593 fi
9594 fi
9595 fi
9596 ;;
9597 esac
9598 func_show_eval "$RM $rmfiles" 'exit_status=1'
9599 done
9600
9601 # Try to remove the ${objdir}s in the directories where we deleted files
9602 for dir in $rmdirs; do
9603 if test -d "$dir"; then
9604 func_show_eval "rmdir $dir >/dev/null 2>&1"
9605 fi
9606 done
9607
9608 exit $exit_status
9609}
9610
9611{ test "$opt_mode" = uninstall || test "$opt_mode" = clean; } &&
9612 func_mode_uninstall ${1+"$@"}
9613
9614test -z "$opt_mode" && {
9615 help="$generic_help"
9616 func_fatal_help "you must specify a MODE"
9617}
9618
9619test -z "$exec_cmd" && \
9620 func_fatal_help "invalid operation mode \`$opt_mode'"
9621
9622if test -n "$exec_cmd"; then
9623 eval exec "$exec_cmd"
9624 exit $EXIT_FAILURE
9625fi
9626
9627exit $exit_status
9628
9629
9630# The TAGs below are defined such that we never get into a situation
9631# in which we disable both kinds of libraries. Given conflicting
9632# choices, we go for a static library, that is the most portable,
9633# since we can't tell whether shared libraries were disabled because
9634# the user asked for that or because the platform doesn't support
9635# them. This is particularly important on AIX, because we don't
9636# support having both static and shared libraries enabled at the same
9637# time on that platform, so we default to a shared-only configuration.
9638# If a disable-shared tag is given, we'll fallback to a static-only
9639# configuration. But we'll never go from static-only to shared-only.
9640
9641# ### BEGIN LIBTOOL TAG CONFIG: disable-shared
9642build_libtool_libs=no
9643build_old_libs=yes
9644# ### END LIBTOOL TAG CONFIG: disable-shared
9645
9646# ### BEGIN LIBTOOL TAG CONFIG: disable-static
9647build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac`
9648# ### END LIBTOOL TAG CONFIG: disable-static
9649
9650# Local Variables:
9651# mode:shell-script
9652# sh-indentation:2
9653# End:
9654# vi:sw=2
9655
config/missing +0 -215
……@@ -1,215 +0,0 @@
1#! /bin/sh
2# Common wrapper for a few potentially missing GNU programs.
3
4scriptversion=2013-10-28.13; # UTC
5
6# Copyright (C) 1996-2013 Free Software Foundation, Inc.
7# Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
8
9# This program is free software; you can redistribute it and/or modify
10# it under the terms of the GNU General Public License as published by
11# the Free Software Foundation; either version 2, or (at your option)
12# any later version.
13
14# This program is distributed in the hope that it will be useful,
15# but WITHOUT ANY WARRANTY; without even the implied warranty of
16# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17# GNU General Public License for more details.
18
19# You should have received a copy of the GNU General Public License
20# along with this program. If not, see <http://www.gnu.org/licenses/>.
21
22# As a special exception to the GNU General Public License, if you
23# distribute this file as part of a program that contains a
24# configuration script generated by Autoconf, you may include it under
25# the same distribution terms that you use for the rest of that program.
26
27if test $# -eq 0; then
28 echo 1>&2 "Try '$0 --help' for more information"
29 exit 1
30fi
31
32case $1 in
33
34 --is-lightweight)
35 # Used by our autoconf macros to check whether the available missing
36 # script is modern enough.
37 exit 0
38 ;;
39
40 --run)
41 # Back-compat with the calling convention used by older automake.
42 shift
43 ;;
44
45 -h|--h|--he|--hel|--help)
46 echo "\
47$0 [OPTION]... PROGRAM [ARGUMENT]...
48
49Run 'PROGRAM [ARGUMENT]...', returning a proper advice when this fails due
50to PROGRAM being missing or too old.
51
52Options:
53 -h, --help display this help and exit
54 -v, --version output version information and exit
55
56Supported PROGRAM values:
57 aclocal autoconf autoheader autom4te automake makeinfo
58 bison yacc flex lex help2man
59
60Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and
61'g' are ignored when checking the name.
62
63Send bug reports to <bug-automake@gnu.org>."
64 exit $?
65 ;;
66
67 -v|--v|--ve|--ver|--vers|--versi|--versio|--version)
68 echo "missing $scriptversion (GNU Automake)"
69 exit $?
70 ;;
71
72 -*)
73 echo 1>&2 "$0: unknown '$1' option"
74 echo 1>&2 "Try '$0 --help' for more information"
75 exit 1
76 ;;
77
78esac
79
80# Run the given program, remember its exit status.
81"$@"; st=$?
82
83# If it succeeded, we are done.
84test $st -eq 0 && exit 0
85
86# Also exit now if we it failed (or wasn't found), and '--version' was
87# passed; such an option is passed most likely to detect whether the
88# program is present and works.
89case $2 in --version|--help) exit $st;; esac
90
91# Exit code 63 means version mismatch. This often happens when the user
92# tries to use an ancient version of a tool on a file that requires a
93# minimum version.
94if test $st -eq 63; then
95 msg="probably too old"
96elif test $st -eq 127; then
97 # Program was missing.
98 msg="missing on your system"
99else
100 # Program was found and executed, but failed. Give up.
101 exit $st
102fi
103
104perl_URL=http://www.perl.org/
105flex_URL=http://flex.sourceforge.net/
106gnu_software_URL=http://www.gnu.org/software
107
108program_details ()
109{
110 case $1 in
111 aclocal|automake)
112 echo "The '$1' program is part of the GNU Automake package:"
113 echo "<$gnu_software_URL/automake>"
114 echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:"
115 echo "<$gnu_software_URL/autoconf>"
116 echo "<$gnu_software_URL/m4/>"
117 echo "<$perl_URL>"
118 ;;
119 autoconf|autom4te|autoheader)
120 echo "The '$1' program is part of the GNU Autoconf package:"
121 echo "<$gnu_software_URL/autoconf/>"
122 echo "It also requires GNU m4 and Perl in order to run:"
123 echo "<$gnu_software_URL/m4/>"
124 echo "<$perl_URL>"
125 ;;
126 esac
127}
128
129give_advice ()
130{
131 # Normalize program name to check for.
132 normalized_program=`echo "$1" | sed '
133 s/^gnu-//; t
134 s/^gnu//; t
135 s/^g//; t'`
136
137 printf '%s\n' "'$1' is $msg."
138
139 configure_deps="'configure.ac' or m4 files included by 'configure.ac'"
140 case $normalized_program in
141 autoconf*)
142 echo "You should only need it if you modified 'configure.ac',"
143 echo "or m4 files included by it."
144 program_details 'autoconf'
145 ;;
146 autoheader*)
147 echo "You should only need it if you modified 'acconfig.h' or"
148 echo "$configure_deps."
149 program_details 'autoheader'
150 ;;
151 automake*)
152 echo "You should only need it if you modified 'Makefile.am' or"
153 echo "$configure_deps."
154 program_details 'automake'
155 ;;
156 aclocal*)
157 echo "You should only need it if you modified 'acinclude.m4' or"
158 echo "$configure_deps."
159 program_details 'aclocal'
160 ;;
161 autom4te*)
162 echo "You might have modified some maintainer files that require"
163 echo "the 'autom4te' program to be rebuilt."
164 program_details 'autom4te'
165 ;;
166 bison*|yacc*)
167 echo "You should only need it if you modified a '.y' file."
168 echo "You may want to install the GNU Bison package:"
169 echo "<$gnu_software_URL/bison/>"
170 ;;
171 lex*|flex*)
172 echo "You should only need it if you modified a '.l' file."
173 echo "You may want to install the Fast Lexical Analyzer package:"
174 echo "<$flex_URL>"
175 ;;
176 help2man*)
177 echo "You should only need it if you modified a dependency" \
178 "of a man page."
179 echo "You may want to install the GNU Help2man package:"
180 echo "<$gnu_software_URL/help2man/>"
181 ;;
182 makeinfo*)
183 echo "You should only need it if you modified a '.texi' file, or"
184 echo "any other file indirectly affecting the aspect of the manual."
185 echo "You might want to install the Texinfo package:"
186 echo "<$gnu_software_URL/texinfo/>"
187 echo "The spurious makeinfo call might also be the consequence of"
188 echo "using a buggy 'make' (AIX, DU, IRIX), in which case you might"
189 echo "want to install GNU make:"
190 echo "<$gnu_software_URL/make/>"
191 ;;
192 *)
193 echo "You might have modified some files without having the proper"
194 echo "tools for further handling them. Check the 'README' file, it"
195 echo "often tells you about the needed prerequisites for installing"
196 echo "this package. You may also peek at any GNU archive site, in"
197 echo "case some other package contains this missing '$1' program."
198 ;;
199 esac
200}
201
202give_advice "$1" | sed -e '1s/^/WARNING: /' \
203 -e '2,$s/^/ /' >&2
204
205# Propagate the correct exit status (expected to be 127 for a program
206# not found, 63 for a program that failed due to version mismatch).
207exit $st
208
209# Local variables:
210# eval: (add-hook 'write-file-hooks 'time-stamp)
211# time-stamp-start: "scriptversion="
212# time-stamp-format: "%:y-%02m-%02d.%02H"
213# time-stamp-time-zone: "UTC"
214# time-stamp-end: "; # UTC"
215# End:
configure +0 -18719
……@@ -1,18719 +0,0 @@
1#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.69 for CompactHash v1.2.
4#
5#
6# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
7#
8#
9# This configure script is free software; the Free Software Foundation
10# gives unlimited permission to copy, distribute and modify it.
11## -------------------- ##
12## M4sh Initialization. ##
13## -------------------- ##
14
15# Be more Bourne compatible
16DUALCASE=1; export DUALCASE # for MKS sh
17if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
18 emulate sh
19 NULLCMD=:
20 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
21 # is contrary to our usage. Disable this feature.
22 alias -g '${1+"$@"}'='"$@"'
23 setopt NO_GLOB_SUBST
24else
25 case `(set -o) 2>/dev/null` in #(
26 *posix*) :
27 set -o posix ;; #(
28 *) :
29 ;;
30esac
31fi
32
33
34as_nl='
35'
36export as_nl
37# Printing a long string crashes Solaris 7 /usr/bin/printf.
38as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
39as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
40as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
41# Prefer a ksh shell builtin over an external printf program on Solaris,
42# but without wasting forks for bash or zsh.
43if test -z "$BASH_VERSION$ZSH_VERSION" \
44 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
45 as_echo='print -r --'
46 as_echo_n='print -rn --'
47elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48 as_echo='printf %s\n'
49 as_echo_n='printf %s'
50else
51 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
52 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
53 as_echo_n='/usr/ucb/echo -n'
54 else
55 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
56 as_echo_n_body='eval
57 arg=$1;
58 case $arg in #(
59 *"$as_nl"*)
60 expr "X$arg" : "X\\(.*\\)$as_nl";
61 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
62 esac;
63 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
64 '
65 export as_echo_n_body
66 as_echo_n='sh -c $as_echo_n_body as_echo'
67 fi
68 export as_echo_body
69 as_echo='sh -c $as_echo_body as_echo'
70fi
71
72# The user is always right.
73if test "${PATH_SEPARATOR+set}" != set; then
74 PATH_SEPARATOR=:
75 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
76 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
77 PATH_SEPARATOR=';'
78 }
79fi
80
81
82# IFS
83# We need space, tab and new line, in precisely that order. Quoting is
84# there to prevent editors from complaining about space-tab.
85# (If _AS_PATH_WALK were called with IFS unset, it would disable word
86# splitting by setting IFS to empty value.)
87IFS=" "" $as_nl"
88
89# Find who we are. Look in the path if we contain no directory separator.
90as_myself=
91case $0 in #((
92 *[\\/]* ) as_myself=$0 ;;
93 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
94for as_dir in $PATH
95do
96 IFS=$as_save_IFS
97 test -z "$as_dir" && as_dir=.
98 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
99 done
100IFS=$as_save_IFS
101
102 ;;
103esac
104# We did not find ourselves, most probably we were run as `sh COMMAND'
105# in which case we are not to be found in the path.
106if test "x$as_myself" = x; then
107 as_myself=$0
108fi
109if test ! -f "$as_myself"; then
110 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
111 exit 1
112fi
113
114# Unset variables that we do not need and which cause bugs (e.g. in
115# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
116# suppresses any "Segmentation fault" message there. '((' could
117# trigger a bug in pdksh 5.2.14.
118for as_var in BASH_ENV ENV MAIL MAILPATH
119do eval test x\${$as_var+set} = xset \
120 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
121done
122PS1='$ '
123PS2='> '
124PS4='+ '
125
126# NLS nuisances.
127LC_ALL=C
128export LC_ALL
129LANGUAGE=C
130export LANGUAGE
131
132# CDPATH.
133(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
134
135# Use a proper internal environment variable to ensure we don't fall
136 # into an infinite loop, continuously re-executing ourselves.
137 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
138 _as_can_reexec=no; export _as_can_reexec;
139 # We cannot yet assume a decent shell, so we have to provide a
140# neutralization value for shells without unset; and this also
141# works around shells that cannot unset nonexistent variables.
142# Preserve -v and -x to the replacement shell.
143BASH_ENV=/dev/null
144ENV=/dev/null
145(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
146case $- in # ((((
147 *v*x* | *x*v* ) as_opts=-vx ;;
148 *v* ) as_opts=-v ;;
149 *x* ) as_opts=-x ;;
150 * ) as_opts= ;;
151esac
152exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
153# Admittedly, this is quite paranoid, since all the known shells bail
154# out after a failed `exec'.
155$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
156as_fn_exit 255
157 fi
158 # We don't want this to propagate to other subprocesses.
159 { _as_can_reexec=; unset _as_can_reexec;}
160if test "x$CONFIG_SHELL" = x; then
161 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
162 emulate sh
163 NULLCMD=:
164 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
165 # is contrary to our usage. Disable this feature.
166 alias -g '\${1+\"\$@\"}'='\"\$@\"'
167 setopt NO_GLOB_SUBST
168else
169 case \`(set -o) 2>/dev/null\` in #(
170 *posix*) :
171 set -o posix ;; #(
172 *) :
173 ;;
174esac
175fi
176"
177 as_required="as_fn_return () { (exit \$1); }
178as_fn_success () { as_fn_return 0; }
179as_fn_failure () { as_fn_return 1; }
180as_fn_ret_success () { return 0; }
181as_fn_ret_failure () { return 1; }
182
183exitcode=0
184as_fn_success || { exitcode=1; echo as_fn_success failed.; }
185as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
186as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
187as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
188if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
189
190else
191 exitcode=1; echo positional parameters were not saved.
192fi
193test x\$exitcode = x0 || exit 1
194test -x / || exit 1"
195 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
196 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
197 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
198 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
199
200 test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
201 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
202 ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
203 ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
204 PATH=/empty FPATH=/empty; export PATH FPATH
205 test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
206 || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1
207test \$(( 1 + 1 )) = 2 || exit 1"
208 if (eval "$as_required") 2>/dev/null; then :
209 as_have_required=yes
210else
211 as_have_required=no
212fi
213 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
214
215else
216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
217as_found=false
218for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
219do
220 IFS=$as_save_IFS
221 test -z "$as_dir" && as_dir=.
222 as_found=:
223 case $as_dir in #(
224 /*)
225 for as_base in sh bash ksh sh5; do
226 # Try only shells that exist, to save several forks.
227 as_shell=$as_dir/$as_base
228 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
229 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
230 CONFIG_SHELL=$as_shell as_have_required=yes
231 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
232 break 2
233fi
234fi
235 done;;
236 esac
237 as_found=false
238done
239$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
240 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
241 CONFIG_SHELL=$SHELL as_have_required=yes
242fi; }
243IFS=$as_save_IFS
244
245
246 if test "x$CONFIG_SHELL" != x; then :
247 export CONFIG_SHELL
248 # We cannot yet assume a decent shell, so we have to provide a
249# neutralization value for shells without unset; and this also
250# works around shells that cannot unset nonexistent variables.
251# Preserve -v and -x to the replacement shell.
252BASH_ENV=/dev/null
253ENV=/dev/null
254(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
255case $- in # ((((
256 *v*x* | *x*v* ) as_opts=-vx ;;
257 *v* ) as_opts=-v ;;
258 *x* ) as_opts=-x ;;
259 * ) as_opts= ;;
260esac
261exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
262# Admittedly, this is quite paranoid, since all the known shells bail
263# out after a failed `exec'.
264$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
265exit 255
266fi
267
268 if test x$as_have_required = xno; then :
269 $as_echo "$0: This script requires a shell more modern than all"
270 $as_echo "$0: the shells that I found on your system."
271 if test x${ZSH_VERSION+set} = xset ; then
272 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
273 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
274 else
275 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
276$0: including any error possibly output before this
277$0: message. Then install a modern shell, or manually run
278$0: the script under such a shell if you do have one."
279 fi
280 exit 1
281fi
282fi
283fi
284SHELL=${CONFIG_SHELL-/bin/sh}
285export SHELL
286# Unset more variables known to interfere with behavior of common tools.
287CLICOLOR_FORCE= GREP_OPTIONS=
288unset CLICOLOR_FORCE GREP_OPTIONS
289
290## --------------------- ##
291## M4sh Shell Functions. ##
292## --------------------- ##
293# as_fn_unset VAR
294# ---------------
295# Portably unset VAR.
296as_fn_unset ()
297{
298 { eval $1=; unset $1;}
299}
300as_unset=as_fn_unset
301
302# as_fn_set_status STATUS
303# -----------------------
304# Set $? to STATUS, without forking.
305as_fn_set_status ()
306{
307 return $1
308} # as_fn_set_status
309
310# as_fn_exit STATUS
311# -----------------
312# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
313as_fn_exit ()
314{
315 set +e
316 as_fn_set_status $1
317 exit $1
318} # as_fn_exit
319
320# as_fn_mkdir_p
321# -------------
322# Create "$as_dir" as a directory, including parents if necessary.
323as_fn_mkdir_p ()
324{
325
326 case $as_dir in #(
327 -*) as_dir=./$as_dir;;
328 esac
329 test -d "$as_dir" || eval $as_mkdir_p || {
330 as_dirs=
331 while :; do
332 case $as_dir in #(
333 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
334 *) as_qdir=$as_dir;;
335 esac
336 as_dirs="'$as_qdir' $as_dirs"
337 as_dir=`$as_dirname -- "$as_dir" ||
338$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
339 X"$as_dir" : 'X\(//\)[^/]' \| \
340 X"$as_dir" : 'X\(//\)$' \| \
341 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
342$as_echo X"$as_dir" |
343 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
344 s//\1/
345 q
346 }
347 /^X\(\/\/\)[^/].*/{
348 s//\1/
349 q
350 }
351 /^X\(\/\/\)$/{
352 s//\1/
353 q
354 }
355 /^X\(\/\).*/{
356 s//\1/
357 q
358 }
359 s/.*/./; q'`
360 test -d "$as_dir" && break
361 done
362 test -z "$as_dirs" || eval "mkdir $as_dirs"
363 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
364
365
366} # as_fn_mkdir_p
367
368# as_fn_executable_p FILE
369# -----------------------
370# Test if FILE is an executable regular file.
371as_fn_executable_p ()
372{
373 test -f "$1" && test -x "$1"
374} # as_fn_executable_p
375# as_fn_append VAR VALUE
376# ----------------------
377# Append the text in VALUE to the end of the definition contained in VAR. Take
378# advantage of any shell optimizations that allow amortized linear growth over
379# repeated appends, instead of the typical quadratic growth present in naive
380# implementations.
381if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
382 eval 'as_fn_append ()
383 {
384 eval $1+=\$2
385 }'
386else
387 as_fn_append ()
388 {
389 eval $1=\$$1\$2
390 }
391fi # as_fn_append
392
393# as_fn_arith ARG...
394# ------------------
395# Perform arithmetic evaluation on the ARGs, and store the result in the
396# global $as_val. Take advantage of shells that can avoid forks. The arguments
397# must be portable across $(()) and expr.
398if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
399 eval 'as_fn_arith ()
400 {
401 as_val=$(( $* ))
402 }'
403else
404 as_fn_arith ()
405 {
406 as_val=`expr "$@" || test $? -eq 1`
407 }
408fi # as_fn_arith
409
410
411# as_fn_error STATUS ERROR [LINENO LOG_FD]
412# ----------------------------------------
413# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
414# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
415# script with STATUS, using 1 if that was 0.
416as_fn_error ()
417{
418 as_status=$1; test $as_status -eq 0 && as_status=1
419 if test "$4"; then
420 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
421 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
422 fi
423 $as_echo "$as_me: error: $2" >&2
424 as_fn_exit $as_status
425} # as_fn_error
426
427if expr a : '\(a\)' >/dev/null 2>&1 &&
428 test "X`expr 00001 : '.*\(...\)'`" = X001; then
429 as_expr=expr
430else
431 as_expr=false
432fi
433
434if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
435 as_basename=basename
436else
437 as_basename=false
438fi
439
440if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
441 as_dirname=dirname
442else
443 as_dirname=false
444fi
445
446as_me=`$as_basename -- "$0" ||
447$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
448 X"$0" : 'X\(//\)$' \| \
449 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
450$as_echo X/"$0" |
451 sed '/^.*\/\([^/][^/]*\)\/*$/{
452 s//\1/
453 q
454 }
455 /^X\/\(\/\/\)$/{
456 s//\1/
457 q
458 }
459 /^X\/\(\/\).*/{
460 s//\1/
461 q
462 }
463 s/.*/./; q'`
464
465# Avoid depending upon Character Ranges.
466as_cr_letters='abcdefghijklmnopqrstuvwxyz'
467as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
468as_cr_Letters=$as_cr_letters$as_cr_LETTERS
469as_cr_digits='0123456789'
470as_cr_alnum=$as_cr_Letters$as_cr_digits
471
472
473 as_lineno_1=$LINENO as_lineno_1a=$LINENO
474 as_lineno_2=$LINENO as_lineno_2a=$LINENO
475 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
476 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
477 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
478 sed -n '
479 p
480 /[$]LINENO/=
481 ' <$as_myself |
482 sed '
483 s/[$]LINENO.*/&-/
484 t lineno
485 b
486 :lineno
487 N
488 :loop
489 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
490 t loop
491 s/-\n.*//
492 ' >$as_me.lineno &&
493 chmod +x "$as_me.lineno" ||
494 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
495
496 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
497 # already done that, so ensure we don't try to do so again and fall
498 # in an infinite loop. This has already happened in practice.
499 _as_can_reexec=no; export _as_can_reexec
500 # Don't try to exec as it changes $[0], causing all sort of problems
501 # (the dirname of $[0] is not the place where we might find the
502 # original and so on. Autoconf is especially sensitive to this).
503 . "./$as_me.lineno"
504 # Exit status is that of the last command.
505 exit
506}
507
508ECHO_C= ECHO_N= ECHO_T=
509case `echo -n x` in #(((((
510-n*)
511 case `echo 'xy\c'` in
512 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
513 xy) ECHO_C='\c';;
514 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
515 ECHO_T=' ';;
516 esac;;
517*)
518 ECHO_N='-n';;
519esac
520
521rm -f conf$$ conf$$.exe conf$$.file
522if test -d conf$$.dir; then
523 rm -f conf$$.dir/conf$$.file
524else
525 rm -f conf$$.dir
526 mkdir conf$$.dir 2>/dev/null
527fi
528if (echo >conf$$.file) 2>/dev/null; then
529 if ln -s conf$$.file conf$$ 2>/dev/null; then
530 as_ln_s='ln -s'
531 # ... but there are two gotchas:
532 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
533 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
534 # In both cases, we have to default to `cp -pR'.
535 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
536 as_ln_s='cp -pR'
537 elif ln conf$$.file conf$$ 2>/dev/null; then
538 as_ln_s=ln
539 else
540 as_ln_s='cp -pR'
541 fi
542else
543 as_ln_s='cp -pR'
544fi
545rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
546rmdir conf$$.dir 2>/dev/null
547
548if mkdir -p . 2>/dev/null; then
549 as_mkdir_p='mkdir -p "$as_dir"'
550else
551 test -d ./-p && rmdir ./-p
552 as_mkdir_p=false
553fi
554
555as_test_x='test -x'
556as_executable_p=as_fn_executable_p
557
558# Sed expression to map a string onto a valid CPP name.
559as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
560
561# Sed expression to map a string onto a valid variable name.
562as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
563
564SHELL=${CONFIG_SHELL-/bin/sh}
565
566
567test -n "$DJDIR" || exec 7<&0 </dev/null
568exec 6>&1
569
570# Name of the host.
571# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
572# so uname gets run too.
573ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
574
575#
576# Initializations.
577#
578ac_default_prefix=/usr/local
579ac_clean_files=
580ac_config_libobj_dir=.
581LIBOBJS=
582cross_compiling=no
583subdirs=
584MFLAGS=
585MAKEFLAGS=
586
587# Identity of this package.
588PACKAGE_NAME='CompactHash'
589PACKAGE_TARNAME='compacthash'
590PACKAGE_VERSION='v1.2'
591PACKAGE_STRING='CompactHash v1.2'
592PACKAGE_BUGREPORT=''
593PACKAGE_URL=''
594
595# Factoring default headers for most tests.
596ac_includes_default="\
597#include <stdio.h>
598#ifdef HAVE_SYS_TYPES_H
599# include <sys/types.h>
600#endif
601#ifdef HAVE_SYS_STAT_H
602# include <sys/stat.h>
603#endif
604#ifdef STDC_HEADERS
605# include <stdlib.h>
606# include <stddef.h>
607#else
608# ifdef HAVE_STDLIB_H
609# include <stdlib.h>
610# endif
611#endif
612#ifdef HAVE_STRING_H
613# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
614# include <memory.h>
615# endif
616# include <string.h>
617#endif
618#ifdef HAVE_STRINGS_H
619# include <strings.h>
620#endif
621#ifdef HAVE_INTTYPES_H
622# include <inttypes.h>
623#endif
624#ifdef HAVE_STDINT_H
625# include <stdint.h>
626#endif
627#ifdef HAVE_UNISTD_H
628# include <unistd.h>
629#endif"
630
631ac_subst_vars='am__EXEEXT_FALSE
632am__EXEEXT_TRUE
633LTLIBOBJS
634LIBOBJS
635CPREPROCESSOR
636INDENT
637AM_CPPFLAGS
638lspci_found
639HAVE_ADDR2LINE
640CXXCPP
641CPP
642OTOOL64
643OTOOL
644LIPO
645NMEDIT
646DSYMUTIL
647MANIFEST_TOOL
648RANLIB
649ac_ct_AR
650AR
651DLLTOOL
652OBJDUMP
653LN_S
654NM
655ac_ct_DUMPBIN
656DUMPBIN
657LD
658FGREP
659EGREP
660GREP
661SED
662host_os
663host_vendor
664host_cpu
665host
666build_os
667build_vendor
668build_cpu
669build
670LIBTOOL
671am__fastdepCXX_FALSE
672am__fastdepCXX_TRUE
673CXXDEPMODE
674ac_ct_CXX
675CXXFLAGS
676CXX
677am__fastdepCC_FALSE
678am__fastdepCC_TRUE
679CCDEPMODE
680am__nodep
681AMDEPBACKSLASH
682AMDEP_FALSE
683AMDEP_TRUE
684am__quote
685am__include
686DEPDIR
687OBJEXT
688EXEEXT
689ac_ct_CC
690CPPFLAGS
691LDFLAGS
692CFLAGS
693CC
694AM_BACKSLASH
695AM_DEFAULT_VERBOSITY
696AM_DEFAULT_V
697AM_V
698am__untar
699am__tar
700AMTAR
701am__leading_dot
702SET_MAKE
703AWK
704mkdir_p
705MKDIR_P
706INSTALL_STRIP_PROGRAM
707STRIP
708install_sh
709MAKEINFO
710AUTOHEADER
711AUTOMAKE
712AUTOCONF
713ACLOCAL
714VERSION
715PACKAGE
716CYGPATH_W
717am__isrc
718INSTALL_DATA
719INSTALL_SCRIPT
720INSTALL_PROGRAM
721target_alias
722host_alias
723build_alias
724LIBS
725ECHO_T
726ECHO_N
727ECHO_C
728DEFS
729mandir
730localedir
731libdir
732psdir
733pdfdir
734dvidir
735htmldir
736infodir
737docdir
738oldincludedir
739includedir
740localstatedir
741sharedstatedir
742sysconfdir
743datadir
744datarootdir
745libexecdir
746sbindir
747bindir
748program_transform_name
749prefix
750exec_prefix
751PACKAGE_URL
752PACKAGE_BUGREPORT
753PACKAGE_STRING
754PACKAGE_VERSION
755PACKAGE_TARNAME
756PACKAGE_NAME
757PATH_SEPARATOR
758SHELL'
759ac_subst_files=''
760ac_user_opts='
761enable_option_checking
762enable_silent_rules
763enable_debug
764enable_bounds_check
765enable_prof
766enable_opencl
767enable_detailed_timing
768enable_write_mem_usage
769enable_dependency_tracking
770enable_shared
771enable_static
772with_pic
773enable_fast_install
774with_gnu_ld
775with_sysroot
776enable_libtool_lock
777enable_largefile
778'
779 ac_precious_vars='build_alias
780host_alias
781target_alias
782CC
783CFLAGS
784LDFLAGS
785LIBS
786CPPFLAGS
787CXX
788CXXFLAGS
789CCC
790CPP
791CXXCPP'
792
793
794# Initialize some variables set by options.
795ac_init_help=
796ac_init_version=false
797ac_unrecognized_opts=
798ac_unrecognized_sep=
799# The variables have the same names as the options, with
800# dashes changed to underlines.
801cache_file=/dev/null
802exec_prefix=NONE
803no_create=
804no_recursion=
805prefix=NONE
806program_prefix=NONE
807program_suffix=NONE
808program_transform_name=s,x,x,
809silent=
810site=
811srcdir=
812verbose=
813x_includes=NONE
814x_libraries=NONE
815
816# Installation directory options.
817# These are left unexpanded so users can "make install exec_prefix=/foo"
818# and all the variables that are supposed to be based on exec_prefix
819# by default will actually change.
820# Use braces instead of parens because sh, perl, etc. also accept them.
821# (The list follows the same order as the GNU Coding Standards.)
822bindir='${exec_prefix}/bin'
823sbindir='${exec_prefix}/sbin'
824libexecdir='${exec_prefix}/libexec'
825datarootdir='${prefix}/share'
826datadir='${datarootdir}'
827sysconfdir='${prefix}/etc'
828sharedstatedir='${prefix}/com'
829localstatedir='${prefix}/var'
830includedir='${prefix}/include'
831oldincludedir='/usr/include'
832docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
833infodir='${datarootdir}/info'
834htmldir='${docdir}'
835dvidir='${docdir}'
836pdfdir='${docdir}'
837psdir='${docdir}'
838libdir='${exec_prefix}/lib'
839localedir='${datarootdir}/locale'
840mandir='${datarootdir}/man'
841
842ac_prev=
843ac_dashdash=
844for ac_option
845do
846 # If the previous option needs an argument, assign it.
847 if test -n "$ac_prev"; then
848 eval $ac_prev=\$ac_option
849 ac_prev=
850 continue
851 fi
852
853 case $ac_option in
854 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
855 *=) ac_optarg= ;;
856 *) ac_optarg=yes ;;
857 esac
858
859 # Accept the important Cygnus configure options, so we can diagnose typos.
860
861 case $ac_dashdash$ac_option in
862 --)
863 ac_dashdash=yes ;;
864
865 -bindir | --bindir | --bindi | --bind | --bin | --bi)
866 ac_prev=bindir ;;
867 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
868 bindir=$ac_optarg ;;
869
870 -build | --build | --buil | --bui | --bu)
871 ac_prev=build_alias ;;
872 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
873 build_alias=$ac_optarg ;;
874
875 -cache-file | --cache-file | --cache-fil | --cache-fi \
876 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
877 ac_prev=cache_file ;;
878 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
879 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
880 cache_file=$ac_optarg ;;
881
882 --config-cache | -C)
883 cache_file=config.cache ;;
884
885 -datadir | --datadir | --datadi | --datad)
886 ac_prev=datadir ;;
887 -datadir=* | --datadir=* | --datadi=* | --datad=*)
888 datadir=$ac_optarg ;;
889
890 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
891 | --dataroo | --dataro | --datar)
892 ac_prev=datarootdir ;;
893 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
894 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
895 datarootdir=$ac_optarg ;;
896
897 -disable-* | --disable-*)
898 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
899 # Reject names that are not valid shell variable names.
900 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
901 as_fn_error $? "invalid feature name: $ac_useropt"
902 ac_useropt_orig=$ac_useropt
903 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
904 case $ac_user_opts in
905 *"
906"enable_$ac_useropt"
907"*) ;;
908 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
909 ac_unrecognized_sep=', ';;
910 esac
911 eval enable_$ac_useropt=no ;;
912
913 -docdir | --docdir | --docdi | --doc | --do)
914 ac_prev=docdir ;;
915 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
916 docdir=$ac_optarg ;;
917
918 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
919 ac_prev=dvidir ;;
920 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
921 dvidir=$ac_optarg ;;
922
923 -enable-* | --enable-*)
924 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
925 # Reject names that are not valid shell variable names.
926 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
927 as_fn_error $? "invalid feature name: $ac_useropt"
928 ac_useropt_orig=$ac_useropt
929 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
930 case $ac_user_opts in
931 *"
932"enable_$ac_useropt"
933"*) ;;
934 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
935 ac_unrecognized_sep=', ';;
936 esac
937 eval enable_$ac_useropt=\$ac_optarg ;;
938
939 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
940 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
941 | --exec | --exe | --ex)
942 ac_prev=exec_prefix ;;
943 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
944 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
945 | --exec=* | --exe=* | --ex=*)
946 exec_prefix=$ac_optarg ;;
947
948 -gas | --gas | --ga | --g)
949 # Obsolete; use --with-gas.
950 with_gas=yes ;;
951
952 -help | --help | --hel | --he | -h)
953 ac_init_help=long ;;
954 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
955 ac_init_help=recursive ;;
956 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
957 ac_init_help=short ;;
958
959 -host | --host | --hos | --ho)
960 ac_prev=host_alias ;;
961 -host=* | --host=* | --hos=* | --ho=*)
962 host_alias=$ac_optarg ;;
963
964 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
965 ac_prev=htmldir ;;
966 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
967 | --ht=*)
968 htmldir=$ac_optarg ;;
969
970 -includedir | --includedir | --includedi | --included | --include \
971 | --includ | --inclu | --incl | --inc)
972 ac_prev=includedir ;;
973 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
974 | --includ=* | --inclu=* | --incl=* | --inc=*)
975 includedir=$ac_optarg ;;
976
977 -infodir | --infodir | --infodi | --infod | --info | --inf)
978 ac_prev=infodir ;;
979 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
980 infodir=$ac_optarg ;;
981
982 -libdir | --libdir | --libdi | --libd)
983 ac_prev=libdir ;;
984 -libdir=* | --libdir=* | --libdi=* | --libd=*)
985 libdir=$ac_optarg ;;
986
987 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
988 | --libexe | --libex | --libe)
989 ac_prev=libexecdir ;;
990 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
991 | --libexe=* | --libex=* | --libe=*)
992 libexecdir=$ac_optarg ;;
993
994 -localedir | --localedir | --localedi | --localed | --locale)
995 ac_prev=localedir ;;
996 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
997 localedir=$ac_optarg ;;
998
999 -localstatedir | --localstatedir | --localstatedi | --localstated \
1000 | --localstate | --localstat | --localsta | --localst | --locals)
1001 ac_prev=localstatedir ;;
1002 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1003 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1004 localstatedir=$ac_optarg ;;
1005
1006 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1007 ac_prev=mandir ;;
1008 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1009 mandir=$ac_optarg ;;
1010
1011 -nfp | --nfp | --nf)
1012 # Obsolete; use --without-fp.
1013 with_fp=no ;;
1014
1015 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1016 | --no-cr | --no-c | -n)
1017 no_create=yes ;;
1018
1019 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1020 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1021 no_recursion=yes ;;
1022
1023 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1024 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1025 | --oldin | --oldi | --old | --ol | --o)
1026 ac_prev=oldincludedir ;;
1027 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1028 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1029 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1030 oldincludedir=$ac_optarg ;;
1031
1032 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1033 ac_prev=prefix ;;
1034 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1035 prefix=$ac_optarg ;;
1036
1037 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1038 | --program-pre | --program-pr | --program-p)
1039 ac_prev=program_prefix ;;
1040 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1041 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1042 program_prefix=$ac_optarg ;;
1043
1044 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1045 | --program-suf | --program-su | --program-s)
1046 ac_prev=program_suffix ;;
1047 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1048 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1049 program_suffix=$ac_optarg ;;
1050
1051 -program-transform-name | --program-transform-name \
1052 | --program-transform-nam | --program-transform-na \
1053 | --program-transform-n | --program-transform- \
1054 | --program-transform | --program-transfor \
1055 | --program-transfo | --program-transf \
1056 | --program-trans | --program-tran \
1057 | --progr-tra | --program-tr | --program-t)
1058 ac_prev=program_transform_name ;;
1059 -program-transform-name=* | --program-transform-name=* \
1060 | --program-transform-nam=* | --program-transform-na=* \
1061 | --program-transform-n=* | --program-transform-=* \
1062 | --program-transform=* | --program-transfor=* \
1063 | --program-transfo=* | --program-transf=* \
1064 | --program-trans=* | --program-tran=* \
1065 | --progr-tra=* | --program-tr=* | --program-t=*)
1066 program_transform_name=$ac_optarg ;;
1067
1068 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1069 ac_prev=pdfdir ;;
1070 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1071 pdfdir=$ac_optarg ;;
1072
1073 -psdir | --psdir | --psdi | --psd | --ps)
1074 ac_prev=psdir ;;
1075 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1076 psdir=$ac_optarg ;;
1077
1078 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1079 | -silent | --silent | --silen | --sile | --sil)
1080 silent=yes ;;
1081
1082 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1083 ac_prev=sbindir ;;
1084 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1085 | --sbi=* | --sb=*)
1086 sbindir=$ac_optarg ;;
1087
1088 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1089 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1090 | --sharedst | --shareds | --shared | --share | --shar \
1091 | --sha | --sh)
1092 ac_prev=sharedstatedir ;;
1093 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1094 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1095 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1096 | --sha=* | --sh=*)
1097 sharedstatedir=$ac_optarg ;;
1098
1099 -site | --site | --sit)
1100 ac_prev=site ;;
1101 -site=* | --site=* | --sit=*)
1102 site=$ac_optarg ;;
1103
1104 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1105 ac_prev=srcdir ;;
1106 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1107 srcdir=$ac_optarg ;;
1108
1109 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1110 | --syscon | --sysco | --sysc | --sys | --sy)
1111 ac_prev=sysconfdir ;;
1112 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1113 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1114 sysconfdir=$ac_optarg ;;
1115
1116 -target | --target | --targe | --targ | --tar | --ta | --t)
1117 ac_prev=target_alias ;;
1118 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1119 target_alias=$ac_optarg ;;
1120
1121 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1122 verbose=yes ;;
1123
1124 -version | --version | --versio | --versi | --vers | -V)
1125 ac_init_version=: ;;
1126
1127 -with-* | --with-*)
1128 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1129 # Reject names that are not valid shell variable names.
1130 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1131 as_fn_error $? "invalid package name: $ac_useropt"
1132 ac_useropt_orig=$ac_useropt
1133 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1134 case $ac_user_opts in
1135 *"
1136"with_$ac_useropt"
1137"*) ;;
1138 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1139 ac_unrecognized_sep=', ';;
1140 esac
1141 eval with_$ac_useropt=\$ac_optarg ;;
1142
1143 -without-* | --without-*)
1144 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1145 # Reject names that are not valid shell variable names.
1146 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1147 as_fn_error $? "invalid package name: $ac_useropt"
1148 ac_useropt_orig=$ac_useropt
1149 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1150 case $ac_user_opts in
1151 *"
1152"with_$ac_useropt"
1153"*) ;;
1154 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1155 ac_unrecognized_sep=', ';;
1156 esac
1157 eval with_$ac_useropt=no ;;
1158
1159 --x)
1160 # Obsolete; use --with-x.
1161 with_x=yes ;;
1162
1163 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1164 | --x-incl | --x-inc | --x-in | --x-i)
1165 ac_prev=x_includes ;;
1166 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1167 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1168 x_includes=$ac_optarg ;;
1169
1170 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1171 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1172 ac_prev=x_libraries ;;
1173 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1174 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1175 x_libraries=$ac_optarg ;;
1176
1177 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1178Try \`$0 --help' for more information"
1179 ;;
1180
1181 *=*)
1182 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1183 # Reject names that are not valid shell variable names.
1184 case $ac_envvar in #(
1185 '' | [0-9]* | *[!_$as_cr_alnum]* )
1186 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1187 esac
1188 eval $ac_envvar=\$ac_optarg
1189 export $ac_envvar ;;
1190
1191 *)
1192 # FIXME: should be removed in autoconf 3.0.
1193 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1194 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1195 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1196 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1197 ;;
1198
1199 esac
1200done
1201
1202if test -n "$ac_prev"; then
1203 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1204 as_fn_error $? "missing argument to $ac_option"
1205fi
1206
1207if test -n "$ac_unrecognized_opts"; then
1208 case $enable_option_checking in
1209 no) ;;
1210 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1211 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1212 esac
1213fi
1214
1215# Check all directory arguments for consistency.
1216for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1217 datadir sysconfdir sharedstatedir localstatedir includedir \
1218 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1219 libdir localedir mandir
1220do
1221 eval ac_val=\$$ac_var
1222 # Remove trailing slashes.
1223 case $ac_val in
1224 */ )
1225 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1226 eval $ac_var=\$ac_val;;
1227 esac
1228 # Be sure to have absolute directory names.
1229 case $ac_val in
1230 [\\/$]* | ?:[\\/]* ) continue;;
1231 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1232 esac
1233 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1234done
1235
1236# There might be people who depend on the old broken behavior: `$host'
1237# used to hold the argument of --host etc.
1238# FIXME: To remove some day.
1239build=$build_alias
1240host=$host_alias
1241target=$target_alias
1242
1243# FIXME: To remove some day.
1244if test "x$host_alias" != x; then
1245 if test "x$build_alias" = x; then
1246 cross_compiling=maybe
1247 elif test "x$build_alias" != "x$host_alias"; then
1248 cross_compiling=yes
1249 fi
1250fi
1251
1252ac_tool_prefix=
1253test -n "$host_alias" && ac_tool_prefix=$host_alias-
1254
1255test "$silent" = yes && exec 6>/dev/null
1256
1257
1258ac_pwd=`pwd` && test -n "$ac_pwd" &&
1259ac_ls_di=`ls -di .` &&
1260ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1261 as_fn_error $? "working directory cannot be determined"
1262test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1263 as_fn_error $? "pwd does not report name of working directory"
1264
1265
1266# Find the source files, if location was not specified.
1267if test -z "$srcdir"; then
1268 ac_srcdir_defaulted=yes
1269 # Try the directory containing this script, then the parent directory.
1270 ac_confdir=`$as_dirname -- "$as_myself" ||
1271$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1272 X"$as_myself" : 'X\(//\)[^/]' \| \
1273 X"$as_myself" : 'X\(//\)$' \| \
1274 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1275$as_echo X"$as_myself" |
1276 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1277 s//\1/
1278 q
1279 }
1280 /^X\(\/\/\)[^/].*/{
1281 s//\1/
1282 q
1283 }
1284 /^X\(\/\/\)$/{
1285 s//\1/
1286 q
1287 }
1288 /^X\(\/\).*/{
1289 s//\1/
1290 q
1291 }
1292 s/.*/./; q'`
1293 srcdir=$ac_confdir
1294 if test ! -r "$srcdir/$ac_unique_file"; then
1295 srcdir=..
1296 fi
1297else
1298 ac_srcdir_defaulted=no
1299fi
1300if test ! -r "$srcdir/$ac_unique_file"; then
1301 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1302 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1303fi
1304ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1305ac_abs_confdir=`(
1306 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1307 pwd)`
1308# When building in place, set srcdir=.
1309if test "$ac_abs_confdir" = "$ac_pwd"; then
1310 srcdir=.
1311fi
1312# Remove unnecessary trailing slashes from srcdir.
1313# Double slashes in file names in object file debugging info
1314# mess up M-x gdb in Emacs.
1315case $srcdir in
1316*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1317esac
1318for ac_var in $ac_precious_vars; do
1319 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1320 eval ac_env_${ac_var}_value=\$${ac_var}
1321 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1322 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1323done
1324
1325#
1326# Report the --help message.
1327#
1328if test "$ac_init_help" = "long"; then
1329 # Omit some internal or obsolete options to make the list less imposing.
1330 # This message is too long to be a string in the A/UX 3.1 sh.
1331 cat <<_ACEOF
1332\`configure' configures CompactHash v1.2 to adapt to many kinds of systems.
1333
1334Usage: $0 [OPTION]... [VAR=VALUE]...
1335
1336To assign environment variables (e.g., CC, CFLAGS...), specify them as
1337VAR=VALUE. See below for descriptions of some of the useful variables.
1338
1339Defaults for the options are specified in brackets.
1340
1341Configuration:
1342 -h, --help display this help and exit
1343 --help=short display options specific to this package
1344 --help=recursive display the short help of all the included packages
1345 -V, --version display version information and exit
1346 -q, --quiet, --silent do not print \`checking ...' messages
1347 --cache-file=FILE cache test results in FILE [disabled]
1348 -C, --config-cache alias for \`--cache-file=config.cache'
1349 -n, --no-create do not create output files
1350 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1351
1352Installation directories:
1353 --prefix=PREFIX install architecture-independent files in PREFIX
1354 [$ac_default_prefix]
1355 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1356 [PREFIX]
1357
1358By default, \`make install' will install all the files in
1359\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1360an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1361for instance \`--prefix=\$HOME'.
1362
1363For better control, use the options below.
1364
1365Fine tuning of the installation directories:
1366 --bindir=DIR user executables [EPREFIX/bin]
1367 --sbindir=DIR system admin executables [EPREFIX/sbin]
1368 --libexecdir=DIR program executables [EPREFIX/libexec]
1369 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1370 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1371 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1372 --libdir=DIR object code libraries [EPREFIX/lib]
1373 --includedir=DIR C header files [PREFIX/include]
1374 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1375 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1376 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1377 --infodir=DIR info documentation [DATAROOTDIR/info]
1378 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1379 --mandir=DIR man documentation [DATAROOTDIR/man]
1380 --docdir=DIR documentation root [DATAROOTDIR/doc/compacthash]
1381 --htmldir=DIR html documentation [DOCDIR]
1382 --dvidir=DIR dvi documentation [DOCDIR]
1383 --pdfdir=DIR pdf documentation [DOCDIR]
1384 --psdir=DIR ps documentation [DOCDIR]
1385_ACEOF
1386
1387 cat <<\_ACEOF
1388
1389Program names:
1390 --program-prefix=PREFIX prepend PREFIX to installed program names
1391 --program-suffix=SUFFIX append SUFFIX to installed program names
1392 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1393
1394System types:
1395 --build=BUILD configure for building on BUILD [guessed]
1396 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1397_ACEOF
1398fi
1399
1400if test -n "$ac_init_help"; then
1401 case $ac_init_help in
1402 short | recursive ) echo "Configuration of CompactHash v1.2:";;
1403 esac
1404 cat <<\_ACEOF
1405
1406Optional Features:
1407 --disable-option-checking ignore unrecognized --enable/--with options
1408 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1409 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1410 --enable-silent-rules less verbose build output (undo: "make V=1")
1411 --disable-silent-rules verbose build output (undo: "make V=0")
1412 --enable-debug compiles code with debug flags [default=no]
1413 --enable-bounds-check compiles code with bounds check flags [default=no]
1414 --enable-prof compiles code with profiling flags [default=no]
1415 --enable-opencl compiles code with opencl library [default=yes]
1416 --enable-detailed-timing
1417 compiles code with detailed timing on [default=no]
1418 --enable-write-mem-usage
1419 compiles code with write memory usage on
1420 [default=no]
1421 --enable-dependency-tracking
1422 do not reject slow dependency extractors
1423 --disable-dependency-tracking
1424 speeds up one-time build
1425 --enable-shared[=PKGS] build shared libraries [default=yes]
1426 --enable-static[=PKGS] build static libraries [default=yes]
1427 --enable-fast-install[=PKGS]
1428 optimize for fast installation [default=yes]
1429 --disable-libtool-lock avoid locking (might break parallel builds)
1430 --disable-largefile omit support for large files
1431
1432Optional Packages:
1433 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1434 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1435 --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use
1436 both]
1437 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1438 --with-sysroot=DIR Search for dependent libraries within DIR
1439 (or the compiler's sysroot if not specified).
1440
1441Some influential environment variables:
1442 CC C compiler command
1443 CFLAGS C compiler flags
1444 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1445 nonstandard directory <lib dir>
1446 LIBS libraries to pass to the linker, e.g. -l<library>
1447 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1448 you have headers in a nonstandard directory <include dir>
1449 CXX C++ compiler command
1450 CXXFLAGS C++ compiler flags
1451 CPP C preprocessor
1452 CXXCPP C++ preprocessor
1453
1454Use these variables to override the choices made by `configure' or to help
1455it to find libraries and programs with nonstandard names/locations.
1456
1457Report bugs to the package provider.
1458_ACEOF
1459ac_status=$?
1460fi
1461
1462if test "$ac_init_help" = "recursive"; then
1463 # If there are subdirs, report their specific --help.
1464 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1465 test -d "$ac_dir" ||
1466 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1467 continue
1468 ac_builddir=.
1469
1470case "$ac_dir" in
1471.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1472*)
1473 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1474 # A ".." for each directory in $ac_dir_suffix.
1475 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1476 case $ac_top_builddir_sub in
1477 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1478 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1479 esac ;;
1480esac
1481ac_abs_top_builddir=$ac_pwd
1482ac_abs_builddir=$ac_pwd$ac_dir_suffix
1483# for backward compatibility:
1484ac_top_builddir=$ac_top_build_prefix
1485
1486case $srcdir in
1487 .) # We are building in place.
1488 ac_srcdir=.
1489 ac_top_srcdir=$ac_top_builddir_sub
1490 ac_abs_top_srcdir=$ac_pwd ;;
1491 [\\/]* | ?:[\\/]* ) # Absolute name.
1492 ac_srcdir=$srcdir$ac_dir_suffix;
1493 ac_top_srcdir=$srcdir
1494 ac_abs_top_srcdir=$srcdir ;;
1495 *) # Relative name.
1496 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1497 ac_top_srcdir=$ac_top_build_prefix$srcdir
1498 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1499esac
1500ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1501
1502 cd "$ac_dir" || { ac_status=$?; continue; }
1503 # Check for guested configure.
1504 if test -f "$ac_srcdir/configure.gnu"; then
1505 echo &&
1506 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1507 elif test -f "$ac_srcdir/configure"; then
1508 echo &&
1509 $SHELL "$ac_srcdir/configure" --help=recursive
1510 else
1511 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1512 fi || ac_status=$?
1513 cd "$ac_pwd" || { ac_status=$?; break; }
1514 done
1515fi
1516
1517test -n "$ac_init_help" && exit $ac_status
1518if $ac_init_version; then
1519 cat <<\_ACEOF
1520CompactHash configure v1.2
1521generated by GNU Autoconf 2.69
1522
1523Copyright (C) 2012 Free Software Foundation, Inc.
1524This configure script is free software; the Free Software Foundation
1525gives unlimited permission to copy, distribute and modify it.
1526_ACEOF
1527 exit
1528fi
1529
1530## ------------------------ ##
1531## Autoconf initialization. ##
1532## ------------------------ ##
1533
1534# ac_fn_c_try_compile LINENO
1535# --------------------------
1536# Try to compile conftest.$ac_ext, and return whether this succeeded.
1537ac_fn_c_try_compile ()
1538{
1539 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1540 rm -f conftest.$ac_objext
1541 if { { ac_try="$ac_compile"
1542case "(($ac_try" in
1543 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1544 *) ac_try_echo=$ac_try;;
1545esac
1546eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1547$as_echo "$ac_try_echo"; } >&5
1548 (eval "$ac_compile") 2>conftest.err
1549 ac_status=$?
1550 if test -s conftest.err; then
1551 grep -v '^ *+' conftest.err >conftest.er1
1552 cat conftest.er1 >&5
1553 mv -f conftest.er1 conftest.err
1554 fi
1555 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1556 test $ac_status = 0; } && {
1557 test -z "$ac_c_werror_flag" ||
1558 test ! -s conftest.err
1559 } && test -s conftest.$ac_objext; then :
1560 ac_retval=0
1561else
1562 $as_echo "$as_me: failed program was:" >&5
1563sed 's/^/| /' conftest.$ac_ext >&5
1564
1565 ac_retval=1
1566fi
1567 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1568 as_fn_set_status $ac_retval
1569
1570} # ac_fn_c_try_compile
1571
1572# ac_fn_cxx_try_compile LINENO
1573# ----------------------------
1574# Try to compile conftest.$ac_ext, and return whether this succeeded.
1575ac_fn_cxx_try_compile ()
1576{
1577 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1578 rm -f conftest.$ac_objext
1579 if { { ac_try="$ac_compile"
1580case "(($ac_try" in
1581 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1582 *) ac_try_echo=$ac_try;;
1583esac
1584eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1585$as_echo "$ac_try_echo"; } >&5
1586 (eval "$ac_compile") 2>conftest.err
1587 ac_status=$?
1588 if test -s conftest.err; then
1589 grep -v '^ *+' conftest.err >conftest.er1
1590 cat conftest.er1 >&5
1591 mv -f conftest.er1 conftest.err
1592 fi
1593 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1594 test $ac_status = 0; } && {
1595 test -z "$ac_cxx_werror_flag" ||
1596 test ! -s conftest.err
1597 } && test -s conftest.$ac_objext; then :
1598 ac_retval=0
1599else
1600 $as_echo "$as_me: failed program was:" >&5
1601sed 's/^/| /' conftest.$ac_ext >&5
1602
1603 ac_retval=1
1604fi
1605 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1606 as_fn_set_status $ac_retval
1607
1608} # ac_fn_cxx_try_compile
1609
1610# ac_fn_c_try_link LINENO
1611# -----------------------
1612# Try to link conftest.$ac_ext, and return whether this succeeded.
1613ac_fn_c_try_link ()
1614{
1615 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1616 rm -f conftest.$ac_objext conftest$ac_exeext
1617 if { { ac_try="$ac_link"
1618case "(($ac_try" in
1619 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1620 *) ac_try_echo=$ac_try;;
1621esac
1622eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1623$as_echo "$ac_try_echo"; } >&5
1624 (eval "$ac_link") 2>conftest.err
1625 ac_status=$?
1626 if test -s conftest.err; then
1627 grep -v '^ *+' conftest.err >conftest.er1
1628 cat conftest.er1 >&5
1629 mv -f conftest.er1 conftest.err
1630 fi
1631 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1632 test $ac_status = 0; } && {
1633 test -z "$ac_c_werror_flag" ||
1634 test ! -s conftest.err
1635 } && test -s conftest$ac_exeext && {
1636 test "$cross_compiling" = yes ||
1637 test -x conftest$ac_exeext
1638 }; then :
1639 ac_retval=0
1640else
1641 $as_echo "$as_me: failed program was:" >&5
1642sed 's/^/| /' conftest.$ac_ext >&5
1643
1644 ac_retval=1
1645fi
1646 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1647 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1648 # interfere with the next link command; also delete a directory that is
1649 # left behind by Apple's compiler. We do this before executing the actions.
1650 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1651 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1652 as_fn_set_status $ac_retval
1653
1654} # ac_fn_c_try_link
1655
1656# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1657# -------------------------------------------------------
1658# Tests whether HEADER exists and can be compiled using the include files in
1659# INCLUDES, setting the cache variable VAR accordingly.
1660ac_fn_c_check_header_compile ()
1661{
1662 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1664$as_echo_n "checking for $2... " >&6; }
1665if eval \${$3+:} false; then :
1666 $as_echo_n "(cached) " >&6
1667else
1668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1669/* end confdefs.h. */
1670$4
1671#include <$2>
1672_ACEOF
1673if ac_fn_c_try_compile "$LINENO"; then :
1674 eval "$3=yes"
1675else
1676 eval "$3=no"
1677fi
1678rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1679fi
1680eval ac_res=\$$3
1681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1682$as_echo "$ac_res" >&6; }
1683 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1684
1685} # ac_fn_c_check_header_compile
1686
1687# ac_fn_c_try_cpp LINENO
1688# ----------------------
1689# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1690ac_fn_c_try_cpp ()
1691{
1692 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1693 if { { ac_try="$ac_cpp conftest.$ac_ext"
1694case "(($ac_try" in
1695 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1696 *) ac_try_echo=$ac_try;;
1697esac
1698eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1699$as_echo "$ac_try_echo"; } >&5
1700 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1701 ac_status=$?
1702 if test -s conftest.err; then
1703 grep -v '^ *+' conftest.err >conftest.er1
1704 cat conftest.er1 >&5
1705 mv -f conftest.er1 conftest.err
1706 fi
1707 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1708 test $ac_status = 0; } > conftest.i && {
1709 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1710 test ! -s conftest.err
1711 }; then :
1712 ac_retval=0
1713else
1714 $as_echo "$as_me: failed program was:" >&5
1715sed 's/^/| /' conftest.$ac_ext >&5
1716
1717 ac_retval=1
1718fi
1719 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1720 as_fn_set_status $ac_retval
1721
1722} # ac_fn_c_try_cpp
1723
1724# ac_fn_c_try_run LINENO
1725# ----------------------
1726# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1727# that executables *can* be run.
1728ac_fn_c_try_run ()
1729{
1730 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1731 if { { ac_try="$ac_link"
1732case "(($ac_try" in
1733 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1734 *) ac_try_echo=$ac_try;;
1735esac
1736eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1737$as_echo "$ac_try_echo"; } >&5
1738 (eval "$ac_link") 2>&5
1739 ac_status=$?
1740 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1741 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1742 { { case "(($ac_try" in
1743 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1744 *) ac_try_echo=$ac_try;;
1745esac
1746eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1747$as_echo "$ac_try_echo"; } >&5
1748 (eval "$ac_try") 2>&5
1749 ac_status=$?
1750 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1751 test $ac_status = 0; }; }; then :
1752 ac_retval=0
1753else
1754 $as_echo "$as_me: program exited with status $ac_status" >&5
1755 $as_echo "$as_me: failed program was:" >&5
1756sed 's/^/| /' conftest.$ac_ext >&5
1757
1758 ac_retval=$ac_status
1759fi
1760 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1761 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1762 as_fn_set_status $ac_retval
1763
1764} # ac_fn_c_try_run
1765
1766# ac_fn_c_check_func LINENO FUNC VAR
1767# ----------------------------------
1768# Tests whether FUNC exists, setting the cache variable VAR accordingly
1769ac_fn_c_check_func ()
1770{
1771 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1773$as_echo_n "checking for $2... " >&6; }
1774if eval \${$3+:} false; then :
1775 $as_echo_n "(cached) " >&6
1776else
1777 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1778/* end confdefs.h. */
1779/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1780 For example, HP-UX 11i <limits.h> declares gettimeofday. */
1781#define $2 innocuous_$2
1782
1783/* System header to define __stub macros and hopefully few prototypes,
1784 which can conflict with char $2 (); below.
1785 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
1786 <limits.h> exists even on freestanding compilers. */
1787
1788#ifdef __STDC__
1789# include <limits.h>
1790#else
1791# include <assert.h>
1792#endif
1793
1794#undef $2
1795
1796/* Override any GCC internal prototype to avoid an error.
1797 Use char because int might match the return type of a GCC
1798 builtin and then its argument prototype would still apply. */
1799#ifdef __cplusplus
1800extern "C"
1801#endif
1802char $2 ();
1803/* The GNU C library defines this for functions which it implements
1804 to always fail with ENOSYS. Some functions are actually named
1805 something starting with __ and the normal name is an alias. */
1806#if defined __stub_$2 || defined __stub___$2
1807choke me
1808#endif
1809
1810int
1811main ()
1812{
1813return $2 ();
1814 ;
1815 return 0;
1816}
1817_ACEOF
1818if ac_fn_c_try_link "$LINENO"; then :
1819 eval "$3=yes"
1820else
1821 eval "$3=no"
1822fi
1823rm -f core conftest.err conftest.$ac_objext \
1824 conftest$ac_exeext conftest.$ac_ext
1825fi
1826eval ac_res=\$$3
1827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1828$as_echo "$ac_res" >&6; }
1829 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1830
1831} # ac_fn_c_check_func
1832
1833# ac_fn_cxx_try_cpp LINENO
1834# ------------------------
1835# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1836ac_fn_cxx_try_cpp ()
1837{
1838 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1839 if { { ac_try="$ac_cpp conftest.$ac_ext"
1840case "(($ac_try" in
1841 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1842 *) ac_try_echo=$ac_try;;
1843esac
1844eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1845$as_echo "$ac_try_echo"; } >&5
1846 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1847 ac_status=$?
1848 if test -s conftest.err; then
1849 grep -v '^ *+' conftest.err >conftest.er1
1850 cat conftest.er1 >&5
1851 mv -f conftest.er1 conftest.err
1852 fi
1853 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1854 test $ac_status = 0; } > conftest.i && {
1855 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
1856 test ! -s conftest.err
1857 }; then :
1858 ac_retval=0
1859else
1860 $as_echo "$as_me: failed program was:" >&5
1861sed 's/^/| /' conftest.$ac_ext >&5
1862
1863 ac_retval=1
1864fi
1865 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1866 as_fn_set_status $ac_retval
1867
1868} # ac_fn_cxx_try_cpp
1869
1870# ac_fn_cxx_try_link LINENO
1871# -------------------------
1872# Try to link conftest.$ac_ext, and return whether this succeeded.
1873ac_fn_cxx_try_link ()
1874{
1875 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1876 rm -f conftest.$ac_objext conftest$ac_exeext
1877 if { { ac_try="$ac_link"
1878case "(($ac_try" in
1879 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1880 *) ac_try_echo=$ac_try;;
1881esac
1882eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1883$as_echo "$ac_try_echo"; } >&5
1884 (eval "$ac_link") 2>conftest.err
1885 ac_status=$?
1886 if test -s conftest.err; then
1887 grep -v '^ *+' conftest.err >conftest.er1
1888 cat conftest.er1 >&5
1889 mv -f conftest.er1 conftest.err
1890 fi
1891 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1892 test $ac_status = 0; } && {
1893 test -z "$ac_cxx_werror_flag" ||
1894 test ! -s conftest.err
1895 } && test -s conftest$ac_exeext && {
1896 test "$cross_compiling" = yes ||
1897 test -x conftest$ac_exeext
1898 }; then :
1899 ac_retval=0
1900else
1901 $as_echo "$as_me: failed program was:" >&5
1902sed 's/^/| /' conftest.$ac_ext >&5
1903
1904 ac_retval=1
1905fi
1906 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1907 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1908 # interfere with the next link command; also delete a directory that is
1909 # left behind by Apple's compiler. We do this before executing the actions.
1910 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1911 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1912 as_fn_set_status $ac_retval
1913
1914} # ac_fn_cxx_try_link
1915cat >config.log <<_ACEOF
1916This file contains any messages produced by compilers while
1917running configure, to aid debugging if configure makes a mistake.
1918
1919It was created by CompactHash $as_me v1.2, which was
1920generated by GNU Autoconf 2.69. Invocation command line was
1921
1922 $ $0 $@
1923
1924_ACEOF
1925exec 5>>config.log
1926{
1927cat <<_ASUNAME
1928## --------- ##
1929## Platform. ##
1930## --------- ##
1931
1932hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1933uname -m = `(uname -m) 2>/dev/null || echo unknown`
1934uname -r = `(uname -r) 2>/dev/null || echo unknown`
1935uname -s = `(uname -s) 2>/dev/null || echo unknown`
1936uname -v = `(uname -v) 2>/dev/null || echo unknown`
1937
1938/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1939/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
1940
1941/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
1942/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
1943/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1944/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
1945/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
1946/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
1947/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
1948
1949_ASUNAME
1950
1951as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1952for as_dir in $PATH
1953do
1954 IFS=$as_save_IFS
1955 test -z "$as_dir" && as_dir=.
1956 $as_echo "PATH: $as_dir"
1957 done
1958IFS=$as_save_IFS
1959
1960} >&5
1961
1962cat >&5 <<_ACEOF
1963
1964
1965## ----------- ##
1966## Core tests. ##
1967## ----------- ##
1968
1969_ACEOF
1970
1971
1972# Keep a trace of the command line.
1973# Strip out --no-create and --no-recursion so they do not pile up.
1974# Strip out --silent because we don't want to record it for future runs.
1975# Also quote any args containing shell meta-characters.
1976# Make two passes to allow for proper duplicate-argument suppression.
1977ac_configure_args=
1978ac_configure_args0=
1979ac_configure_args1=
1980ac_must_keep_next=false
1981for ac_pass in 1 2
1982do
1983 for ac_arg
1984 do
1985 case $ac_arg in
1986 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1987 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1988 | -silent | --silent | --silen | --sile | --sil)
1989 continue ;;
1990 *\'*)
1991 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1992 esac
1993 case $ac_pass in
1994 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
1995 2)
1996 as_fn_append ac_configure_args1 " '$ac_arg'"
1997 if test $ac_must_keep_next = true; then
1998 ac_must_keep_next=false # Got value, back to normal.
1999 else
2000 case $ac_arg in
2001 *=* | --config-cache | -C | -disable-* | --disable-* \
2002 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2003 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2004 | -with-* | --with-* | -without-* | --without-* | --x)
2005 case "$ac_configure_args0 " in
2006 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2007 esac
2008 ;;
2009 -* ) ac_must_keep_next=true ;;
2010 esac
2011 fi
2012 as_fn_append ac_configure_args " '$ac_arg'"
2013 ;;
2014 esac
2015 done
2016done
2017{ ac_configure_args0=; unset ac_configure_args0;}
2018{ ac_configure_args1=; unset ac_configure_args1;}
2019
2020# When interrupted or exit'd, cleanup temporary files, and complete
2021# config.log. We remove comments because anyway the quotes in there
2022# would cause problems or look ugly.
2023# WARNING: Use '\'' to represent an apostrophe within the trap.
2024# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2025trap 'exit_status=$?
2026 # Save into config.log some information that might help in debugging.
2027 {
2028 echo
2029
2030 $as_echo "## ---------------- ##
2031## Cache variables. ##
2032## ---------------- ##"
2033 echo
2034 # The following way of writing the cache mishandles newlines in values,
2035(
2036 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2037 eval ac_val=\$$ac_var
2038 case $ac_val in #(
2039 *${as_nl}*)
2040 case $ac_var in #(
2041 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2042$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2043 esac
2044 case $ac_var in #(
2045 _ | IFS | as_nl) ;; #(
2046 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2047 *) { eval $ac_var=; unset $ac_var;} ;;
2048 esac ;;
2049 esac
2050 done
2051 (set) 2>&1 |
2052 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2053 *${as_nl}ac_space=\ *)
2054 sed -n \
2055 "s/'\''/'\''\\\\'\'''\''/g;
2056 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2057 ;; #(
2058 *)
2059 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2060 ;;
2061 esac |
2062 sort
2063)
2064 echo
2065
2066 $as_echo "## ----------------- ##
2067## Output variables. ##
2068## ----------------- ##"
2069 echo
2070 for ac_var in $ac_subst_vars
2071 do
2072 eval ac_val=\$$ac_var
2073 case $ac_val in
2074 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2075 esac
2076 $as_echo "$ac_var='\''$ac_val'\''"
2077 done | sort
2078 echo
2079
2080 if test -n "$ac_subst_files"; then
2081 $as_echo "## ------------------- ##
2082## File substitutions. ##
2083## ------------------- ##"
2084 echo
2085 for ac_var in $ac_subst_files
2086 do
2087 eval ac_val=\$$ac_var
2088 case $ac_val in
2089 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2090 esac
2091 $as_echo "$ac_var='\''$ac_val'\''"
2092 done | sort
2093 echo
2094 fi
2095
2096 if test -s confdefs.h; then
2097 $as_echo "## ----------- ##
2098## confdefs.h. ##
2099## ----------- ##"
2100 echo
2101 cat confdefs.h
2102 echo
2103 fi
2104 test "$ac_signal" != 0 &&
2105 $as_echo "$as_me: caught signal $ac_signal"
2106 $as_echo "$as_me: exit $exit_status"
2107 } >&5
2108 rm -f core *.core core.conftest.* &&
2109 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2110 exit $exit_status
2111' 0
2112for ac_signal in 1 2 13 15; do
2113 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2114done
2115ac_signal=0
2116
2117# confdefs.h avoids OS command line length limits that DEFS can exceed.
2118rm -f -r conftest* confdefs.h
2119
2120$as_echo "/* confdefs.h */" > confdefs.h
2121
2122# Predefined preprocessor variables.
2123
2124cat >>confdefs.h <<_ACEOF
2125#define PACKAGE_NAME "$PACKAGE_NAME"
2126_ACEOF
2127
2128cat >>confdefs.h <<_ACEOF
2129#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2130_ACEOF
2131
2132cat >>confdefs.h <<_ACEOF
2133#define PACKAGE_VERSION "$PACKAGE_VERSION"
2134_ACEOF
2135
2136cat >>confdefs.h <<_ACEOF
2137#define PACKAGE_STRING "$PACKAGE_STRING"
2138_ACEOF
2139
2140cat >>confdefs.h <<_ACEOF
2141#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2142_ACEOF
2143
2144cat >>confdefs.h <<_ACEOF
2145#define PACKAGE_URL "$PACKAGE_URL"
2146_ACEOF
2147
2148
2149# Let the site file select an alternate cache file if it wants to.
2150# Prefer an explicitly selected file to automatically selected ones.
2151ac_site_file1=NONE
2152ac_site_file2=NONE
2153if test -n "$CONFIG_SITE"; then
2154 # We do not want a PATH search for config.site.
2155 case $CONFIG_SITE in #((
2156 -*) ac_site_file1=./$CONFIG_SITE;;
2157 */*) ac_site_file1=$CONFIG_SITE;;
2158 *) ac_site_file1=./$CONFIG_SITE;;
2159 esac
2160elif test "x$prefix" != xNONE; then
2161 ac_site_file1=$prefix/share/config.site
2162 ac_site_file2=$prefix/etc/config.site
2163else
2164 ac_site_file1=$ac_default_prefix/share/config.site
2165 ac_site_file2=$ac_default_prefix/etc/config.site
2166fi
2167for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2168do
2169 test "x$ac_site_file" = xNONE && continue
2170 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2171 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2172$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2173 sed 's/^/| /' "$ac_site_file" >&5
2174 . "$ac_site_file" \
2175 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2176$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2177as_fn_error $? "failed to load site script $ac_site_file
2178See \`config.log' for more details" "$LINENO" 5; }
2179 fi
2180done
2181
2182if test -r "$cache_file"; then
2183 # Some versions of bash will fail to source /dev/null (special files
2184 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2185 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2186 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2187$as_echo "$as_me: loading cache $cache_file" >&6;}
2188 case $cache_file in
2189 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2190 *) . "./$cache_file";;
2191 esac
2192 fi
2193else
2194 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2195$as_echo "$as_me: creating cache $cache_file" >&6;}
2196 >$cache_file
2197fi
2198
2199# Check that the precious variables saved in the cache have kept the same
2200# value.
2201ac_cache_corrupted=false
2202for ac_var in $ac_precious_vars; do
2203 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2204 eval ac_new_set=\$ac_env_${ac_var}_set
2205 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2206 eval ac_new_val=\$ac_env_${ac_var}_value
2207 case $ac_old_set,$ac_new_set in
2208 set,)
2209 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2210$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2211 ac_cache_corrupted=: ;;
2212 ,set)
2213 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2214$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2215 ac_cache_corrupted=: ;;
2216 ,);;
2217 *)
2218 if test "x$ac_old_val" != "x$ac_new_val"; then
2219 # differences in whitespace do not lead to failure.
2220 ac_old_val_w=`echo x $ac_old_val`
2221 ac_new_val_w=`echo x $ac_new_val`
2222 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2223 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2224$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2225 ac_cache_corrupted=:
2226 else
2227 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2228$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2229 eval $ac_var=\$ac_old_val
2230 fi
2231 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2232$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2233 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2234$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2235 fi;;
2236 esac
2237 # Pass precious variables to config.status.
2238 if test "$ac_new_set" = set; then
2239 case $ac_new_val in
2240 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2241 *) ac_arg=$ac_var=$ac_new_val ;;
2242 esac
2243 case " $ac_configure_args " in
2244 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2245 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2246 esac
2247 fi
2248done
2249if $ac_cache_corrupted; then
2250 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2251$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2252 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2253$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2254 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2255fi
2256## -------------------- ##
2257## Main body of script. ##
2258## -------------------- ##
2259
2260ac_ext=c
2261ac_cpp='$CPP $CPPFLAGS'
2262ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2263ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2264ac_compiler_gnu=$ac_cv_c_compiler_gnu
2265
2266
2267
2268ac_aux_dir=
2269for ac_dir in ./config "$srcdir"/./config; do
2270 if test -f "$ac_dir/install-sh"; then
2271 ac_aux_dir=$ac_dir
2272 ac_install_sh="$ac_aux_dir/install-sh -c"
2273 break
2274 elif test -f "$ac_dir/install.sh"; then
2275 ac_aux_dir=$ac_dir
2276 ac_install_sh="$ac_aux_dir/install.sh -c"
2277 break
2278 elif test -f "$ac_dir/shtool"; then
2279 ac_aux_dir=$ac_dir
2280 ac_install_sh="$ac_aux_dir/shtool install -c"
2281 break
2282 fi
2283done
2284if test -z "$ac_aux_dir"; then
2285 as_fn_error $? "cannot find install-sh, install.sh, or shtool in ./config \"$srcdir\"/./config" "$LINENO" 5
2286fi
2287
2288# These three variables are undocumented and unsupported,
2289# and are intended to be withdrawn in a future Autoconf release.
2290# They can cause serious problems if a builder's source tree is in a directory
2291# whose full name contains unusual characters.
2292ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
2293ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
2294ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
2295
2296
2297
2298am__api_version='1.13'
2299
2300# Find a good install program. We prefer a C program (faster),
2301# so one script is as good as another. But avoid the broken or
2302# incompatible versions:
2303# SysV /etc/install, /usr/sbin/install
2304# SunOS /usr/etc/install
2305# IRIX /sbin/install
2306# AIX /bin/install
2307# AmigaOS /C/install, which installs bootblocks on floppy discs
2308# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2309# AFS /usr/afsws/bin/install, which mishandles nonexistent args
2310# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2311# OS/2's system install, which has a completely different semantic
2312# ./install, which can be erroneously created by make from ./install.sh.
2313# Reject install programs that cannot install multiple files.
2314{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
2315$as_echo_n "checking for a BSD-compatible install... " >&6; }
2316if test -z "$INSTALL"; then
2317if ${ac_cv_path_install+:} false; then :
2318 $as_echo_n "(cached) " >&6
2319else
2320 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2321for as_dir in $PATH
2322do
2323 IFS=$as_save_IFS
2324 test -z "$as_dir" && as_dir=.
2325 # Account for people who put trailing slashes in PATH elements.
2326case $as_dir/ in #((
2327 ./ | .// | /[cC]/* | \
2328 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
2329 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
2330 /usr/ucb/* ) ;;
2331 *)
2332 # OSF1 and SCO ODT 3.0 have their own names for install.
2333 # Don't use installbsd from OSF since it installs stuff as root
2334 # by default.
2335 for ac_prog in ginstall scoinst install; do
2336 for ac_exec_ext in '' $ac_executable_extensions; do
2337 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
2338 if test $ac_prog = install &&
2339 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2340 # AIX install. It has an incompatible calling convention.
2341 :
2342 elif test $ac_prog = install &&
2343 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2344 # program-specific install script used by HP pwplus--don't use.
2345 :
2346 else
2347 rm -rf conftest.one conftest.two conftest.dir
2348 echo one > conftest.one
2349 echo two > conftest.two
2350 mkdir conftest.dir
2351 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
2352 test -s conftest.one && test -s conftest.two &&
2353 test -s conftest.dir/conftest.one &&
2354 test -s conftest.dir/conftest.two
2355 then
2356 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
2357 break 3
2358 fi
2359 fi
2360 fi
2361 done
2362 done
2363 ;;
2364esac
2365
2366 done
2367IFS=$as_save_IFS
2368
2369rm -rf conftest.one conftest.two conftest.dir
2370
2371fi
2372 if test "${ac_cv_path_install+set}" = set; then
2373 INSTALL=$ac_cv_path_install
2374 else
2375 # As a last resort, use the slow shell script. Don't cache a
2376 # value for INSTALL within a source directory, because that will
2377 # break other packages using the cache if that directory is
2378 # removed, or if the value is a relative name.
2379 INSTALL=$ac_install_sh
2380 fi
2381fi
2382{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
2383$as_echo "$INSTALL" >&6; }
2384
2385# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2386# It thinks the first close brace ends the variable substitution.
2387test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2388
2389test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2390
2391test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2392
2393{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
2394$as_echo_n "checking whether build environment is sane... " >&6; }
2395# Reject unsafe characters in $srcdir or the absolute working directory
2396# name. Accept space and tab only in the latter.
2397am_lf='
2398'
2399case `pwd` in
2400 *[\\\"\#\$\&\'\`$am_lf]*)
2401 as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
2402esac
2403case $srcdir in
2404 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
2405 as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
2406esac
2407
2408# Do 'set' in a subshell so we don't clobber the current shell's
2409# arguments. Must try -L first in case configure is actually a
2410# symlink; some systems play weird games with the mod time of symlinks
2411# (eg FreeBSD returns the mod time of the symlink's containing
2412# directory).
2413if (
2414 am_has_slept=no
2415 for am_try in 1 2; do
2416 echo "timestamp, slept: $am_has_slept" > conftest.file
2417 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
2418 if test "$*" = "X"; then
2419 # -L didn't work.
2420 set X `ls -t "$srcdir/configure" conftest.file`
2421 fi
2422 if test "$*" != "X $srcdir/configure conftest.file" \
2423 && test "$*" != "X conftest.file $srcdir/configure"; then
2424
2425 # If neither matched, then we have a broken ls. This can happen
2426 # if, for instance, CONFIG_SHELL is bash and it inherits a
2427 # broken ls alias from the environment. This has actually
2428 # happened. Such a system could not be considered "sane".
2429 as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
2430 alias in your environment" "$LINENO" 5
2431 fi
2432 if test "$2" = conftest.file || test $am_try -eq 2; then
2433 break
2434 fi
2435 # Just in case.
2436 sleep 1
2437 am_has_slept=yes
2438 done
2439 test "$2" = conftest.file
2440 )
2441then
2442 # Ok.
2443 :
2444else
2445 as_fn_error $? "newly created file is older than distributed files!
2446Check your system clock" "$LINENO" 5
2447fi
2448{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
2449$as_echo "yes" >&6; }
2450# If we didn't sleep, we still need to ensure time stamps of config.status and
2451# generated files are strictly newer.
2452am_sleep_pid=
2453if grep 'slept: no' conftest.file >/dev/null 2>&1; then
2454 ( sleep 1 ) &
2455 am_sleep_pid=$!
2456fi
2457
2458rm -f conftest.file
2459
2460test "$program_prefix" != NONE &&
2461 program_transform_name="s&^&$program_prefix&;$program_transform_name"
2462# Use a double $ so make ignores it.
2463test "$program_suffix" != NONE &&
2464 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
2465# Double any \ or $.
2466# By default was `s,x,x', remove it if useless.
2467ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
2468program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
2469
2470# expand $ac_aux_dir to an absolute path
2471am_aux_dir=`cd $ac_aux_dir && pwd`
2472
2473if test x"${MISSING+set}" != xset; then
2474 case $am_aux_dir in
2475 *\ * | *\ *)
2476 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
2477 *)
2478 MISSING="\${SHELL} $am_aux_dir/missing" ;;
2479 esac
2480fi
2481# Use eval to expand $SHELL
2482if eval "$MISSING --is-lightweight"; then
2483 am_missing_run="$MISSING "
2484else
2485 am_missing_run=
2486 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
2487$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
2488fi
2489
2490if test x"${install_sh}" != xset; then
2491 case $am_aux_dir in
2492 *\ * | *\ *)
2493 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
2494 *)
2495 install_sh="\${SHELL} $am_aux_dir/install-sh"
2496 esac
2497fi
2498
2499# Installed binaries are usually stripped using 'strip' when the user
2500# run "make install-strip". However 'strip' might not be the right
2501# tool to use in cross-compilation environments, therefore Automake
2502# will honor the 'STRIP' environment variable to overrule this program.
2503if test "$cross_compiling" != no; then
2504 if test -n "$ac_tool_prefix"; then
2505 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
2506set dummy ${ac_tool_prefix}strip; ac_word=$2
2507{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2508$as_echo_n "checking for $ac_word... " >&6; }
2509if ${ac_cv_prog_STRIP+:} false; then :
2510 $as_echo_n "(cached) " >&6
2511else
2512 if test -n "$STRIP"; then
2513 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2514else
2515as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2516for as_dir in $PATH
2517do
2518 IFS=$as_save_IFS
2519 test -z "$as_dir" && as_dir=.
2520 for ac_exec_ext in '' $ac_executable_extensions; do
2521 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2522 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
2523 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2524 break 2
2525 fi
2526done
2527 done
2528IFS=$as_save_IFS
2529
2530fi
2531fi
2532STRIP=$ac_cv_prog_STRIP
2533if test -n "$STRIP"; then
2534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
2535$as_echo "$STRIP" >&6; }
2536else
2537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2538$as_echo "no" >&6; }
2539fi
2540
2541
2542fi
2543if test -z "$ac_cv_prog_STRIP"; then
2544 ac_ct_STRIP=$STRIP
2545 # Extract the first word of "strip", so it can be a program name with args.
2546set dummy strip; ac_word=$2
2547{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2548$as_echo_n "checking for $ac_word... " >&6; }
2549if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
2550 $as_echo_n "(cached) " >&6
2551else
2552 if test -n "$ac_ct_STRIP"; then
2553 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
2554else
2555as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2556for as_dir in $PATH
2557do
2558 IFS=$as_save_IFS
2559 test -z "$as_dir" && as_dir=.
2560 for ac_exec_ext in '' $ac_executable_extensions; do
2561 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2562 ac_cv_prog_ac_ct_STRIP="strip"
2563 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2564 break 2
2565 fi
2566done
2567 done
2568IFS=$as_save_IFS
2569
2570fi
2571fi
2572ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
2573if test -n "$ac_ct_STRIP"; then
2574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
2575$as_echo "$ac_ct_STRIP" >&6; }
2576else
2577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2578$as_echo "no" >&6; }
2579fi
2580
2581 if test "x$ac_ct_STRIP" = x; then
2582 STRIP=":"
2583 else
2584 case $cross_compiling:$ac_tool_warned in
2585yes:)
2586{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2587$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2588ac_tool_warned=yes ;;
2589esac
2590 STRIP=$ac_ct_STRIP
2591 fi
2592else
2593 STRIP="$ac_cv_prog_STRIP"
2594fi
2595
2596fi
2597INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
2598
2599{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
2600$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
2601if test -z "$MKDIR_P"; then
2602 if ${ac_cv_path_mkdir+:} false; then :
2603 $as_echo_n "(cached) " >&6
2604else
2605 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2606for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
2607do
2608 IFS=$as_save_IFS
2609 test -z "$as_dir" && as_dir=.
2610 for ac_prog in mkdir gmkdir; do
2611 for ac_exec_ext in '' $ac_executable_extensions; do
2612 as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
2613 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
2614 'mkdir (GNU coreutils) '* | \
2615 'mkdir (coreutils) '* | \
2616 'mkdir (fileutils) '4.1*)
2617 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
2618 break 3;;
2619 esac
2620 done
2621 done
2622 done
2623IFS=$as_save_IFS
2624
2625fi
2626
2627 test -d ./--version && rmdir ./--version
2628 if test "${ac_cv_path_mkdir+set}" = set; then
2629 MKDIR_P="$ac_cv_path_mkdir -p"
2630 else
2631 # As a last resort, use the slow shell script. Don't cache a
2632 # value for MKDIR_P within a source directory, because that will
2633 # break other packages using the cache if that directory is
2634 # removed, or if the value is a relative name.
2635 MKDIR_P="$ac_install_sh -d"
2636 fi
2637fi
2638{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
2639$as_echo "$MKDIR_P" >&6; }
2640
2641for ac_prog in gawk mawk nawk awk
2642do
2643 # Extract the first word of "$ac_prog", so it can be a program name with args.
2644set dummy $ac_prog; ac_word=$2
2645{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2646$as_echo_n "checking for $ac_word... " >&6; }
2647if ${ac_cv_prog_AWK+:} false; then :
2648 $as_echo_n "(cached) " >&6
2649else
2650 if test -n "$AWK"; then
2651 ac_cv_prog_AWK="$AWK" # Let the user override the test.
2652else
2653as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2654for as_dir in $PATH
2655do
2656 IFS=$as_save_IFS
2657 test -z "$as_dir" && as_dir=.
2658 for ac_exec_ext in '' $ac_executable_extensions; do
2659 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2660 ac_cv_prog_AWK="$ac_prog"
2661 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2662 break 2
2663 fi
2664done
2665 done
2666IFS=$as_save_IFS
2667
2668fi
2669fi
2670AWK=$ac_cv_prog_AWK
2671if test -n "$AWK"; then
2672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
2673$as_echo "$AWK" >&6; }
2674else
2675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2676$as_echo "no" >&6; }
2677fi
2678
2679
2680 test -n "$AWK" && break
2681done
2682
2683{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
2684$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
2685set x ${MAKE-make}
2686ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
2687if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
2688 $as_echo_n "(cached) " >&6
2689else
2690 cat >conftest.make <<\_ACEOF
2691SHELL = /bin/sh
2692all:
2693 @echo '@@@%%%=$(MAKE)=@@@%%%'
2694_ACEOF
2695# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
2696case `${MAKE-make} -f conftest.make 2>/dev/null` in
2697 *@@@%%%=?*=@@@%%%*)
2698 eval ac_cv_prog_make_${ac_make}_set=yes;;
2699 *)
2700 eval ac_cv_prog_make_${ac_make}_set=no;;
2701esac
2702rm -f conftest.make
2703fi
2704if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
2705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
2706$as_echo "yes" >&6; }
2707 SET_MAKE=
2708else
2709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2710$as_echo "no" >&6; }
2711 SET_MAKE="MAKE=${MAKE-make}"
2712fi
2713
2714rm -rf .tst 2>/dev/null
2715mkdir .tst 2>/dev/null
2716if test -d .tst; then
2717 am__leading_dot=.
2718else
2719 am__leading_dot=_
2720fi
2721rmdir .tst 2>/dev/null
2722
2723# Check whether --enable-silent-rules was given.
2724if test "${enable_silent_rules+set}" = set; then :
2725 enableval=$enable_silent_rules;
2726fi
2727
2728case $enable_silent_rules in # (((
2729 yes) AM_DEFAULT_VERBOSITY=0;;
2730 no) AM_DEFAULT_VERBOSITY=1;;
2731 *) AM_DEFAULT_VERBOSITY=1;;
2732esac
2733am_make=${MAKE-make}
2734{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
2735$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
2736if ${am_cv_make_support_nested_variables+:} false; then :
2737 $as_echo_n "(cached) " >&6
2738else
2739 if $as_echo 'TRUE=$(BAR$(V))
2740BAR0=false
2741BAR1=true
2742V=1
2743am__doit:
2744 @$(TRUE)
2745.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
2746 am_cv_make_support_nested_variables=yes
2747else
2748 am_cv_make_support_nested_variables=no
2749fi
2750fi
2751{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
2752$as_echo "$am_cv_make_support_nested_variables" >&6; }
2753if test $am_cv_make_support_nested_variables = yes; then
2754 AM_V='$(V)'
2755 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
2756else
2757 AM_V=$AM_DEFAULT_VERBOSITY
2758 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
2759fi
2760AM_BACKSLASH='\'
2761
2762if test "`cd $srcdir && pwd`" != "`pwd`"; then
2763 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
2764 # is not polluted with repeated "-I."
2765 am__isrc=' -I$(srcdir)'
2766 # test to see if srcdir already configured
2767 if test -f $srcdir/config.status; then
2768 as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
2769 fi
2770fi
2771
2772# test whether we have cygpath
2773if test -z "$CYGPATH_W"; then
2774 if (cygpath --version) >/dev/null 2>/dev/null; then
2775 CYGPATH_W='cygpath -w'
2776 else
2777 CYGPATH_W=echo
2778 fi
2779fi
2780
2781
2782# Define the identity of the package.
2783 PACKAGE='compacthash'
2784 VERSION='v1.2'
2785
2786
2787cat >>confdefs.h <<_ACEOF
2788#define PACKAGE "$PACKAGE"
2789_ACEOF
2790
2791
2792cat >>confdefs.h <<_ACEOF
2793#define VERSION "$VERSION"
2794_ACEOF
2795
2796# Some tools Automake needs.
2797
2798ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
2799
2800
2801AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
2802
2803
2804AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
2805
2806
2807AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
2808
2809
2810MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
2811
2812# For better backward compatibility. To be removed once Automake 1.9.x
2813# dies out for good. For more background, see:
2814# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
2815# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
2816mkdir_p='$(MKDIR_P)'
2817
2818# We need awk for the "check" target. The system "awk" is bad on
2819# some platforms.
2820# Always define AMTAR for backward compatibility. Yes, it's still used
2821# in the wild :-( We should find a proper way to deprecate it ...
2822AMTAR='$${TAR-tar}'
2823
2824
2825# We'll loop over all known methods to create a tar archive until one works.
2826_am_tools='gnutar pax cpio none'
2827
2828am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838#
2839echo "Configuring hash with $ac_configure_args"
2840#
2841
2842# Check whether --enable-debug was given.
2843if test "${enable_debug+set}" = set; then :
2844 enableval=$enable_debug;
2845else
2846 enable_debug=no
2847
2848fi
2849
2850
2851# Check whether --enable-bounds-check was given.
2852if test "${enable_bounds_check+set}" = set; then :
2853 enableval=$enable_bounds_check;
2854else
2855 enable_bounds_check=no
2856
2857fi
2858
2859
2860# Check whether --enable-prof was given.
2861if test "${enable_prof+set}" = set; then :
2862 enableval=$enable_prof;
2863else
2864 enable_prof=no
2865
2866fi
2867
2868
2869# Check whether --enable-opencl was given.
2870if test "${enable_opencl+set}" = set; then :
2871 enableval=$enable_opencl;
2872else
2873 enable_opencl=yes
2874
2875fi
2876
2877
2878# Check whether --enable-detailed-timing was given.
2879if test "${enable_detailed_timing+set}" = set; then :
2880 enableval=$enable_detailed_timing;
2881else
2882 enable_detailed_timing=no
2883
2884fi
2885
2886
2887# Check whether --enable-write-mem-usage was given.
2888if test "${enable_write_mem_usage+set}" = set; then :
2889 enableval=$enable_write_mem_usage;
2890else
2891 enable_write_mem_usage=no
2892
2893fi
2894
2895
2896#AM_WITH_DMALLOC
2897
2898
2899# Checks for programs
2900ac_ext=c
2901ac_cpp='$CPP $CPPFLAGS'
2902ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2903ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2904ac_compiler_gnu=$ac_cv_c_compiler_gnu
2905if test -n "$ac_tool_prefix"; then
2906 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2907set dummy ${ac_tool_prefix}gcc; ac_word=$2
2908{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2909$as_echo_n "checking for $ac_word... " >&6; }
2910if ${ac_cv_prog_CC+:} false; then :
2911 $as_echo_n "(cached) " >&6
2912else
2913 if test -n "$CC"; then
2914 ac_cv_prog_CC="$CC" # Let the user override the test.
2915else
2916as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2917for as_dir in $PATH
2918do
2919 IFS=$as_save_IFS
2920 test -z "$as_dir" && as_dir=.
2921 for ac_exec_ext in '' $ac_executable_extensions; do
2922 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2923 ac_cv_prog_CC="${ac_tool_prefix}gcc"
2924 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2925 break 2
2926 fi
2927done
2928 done
2929IFS=$as_save_IFS
2930
2931fi
2932fi
2933CC=$ac_cv_prog_CC
2934if test -n "$CC"; then
2935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2936$as_echo "$CC" >&6; }
2937else
2938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2939$as_echo "no" >&6; }
2940fi
2941
2942
2943fi
2944if test -z "$ac_cv_prog_CC"; then
2945 ac_ct_CC=$CC
2946 # Extract the first word of "gcc", so it can be a program name with args.
2947set dummy gcc; ac_word=$2
2948{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2949$as_echo_n "checking for $ac_word... " >&6; }
2950if ${ac_cv_prog_ac_ct_CC+:} false; then :
2951 $as_echo_n "(cached) " >&6
2952else
2953 if test -n "$ac_ct_CC"; then
2954 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2955else
2956as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2957for as_dir in $PATH
2958do
2959 IFS=$as_save_IFS
2960 test -z "$as_dir" && as_dir=.
2961 for ac_exec_ext in '' $ac_executable_extensions; do
2962 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2963 ac_cv_prog_ac_ct_CC="gcc"
2964 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2965 break 2
2966 fi
2967done
2968 done
2969IFS=$as_save_IFS
2970
2971fi
2972fi
2973ac_ct_CC=$ac_cv_prog_ac_ct_CC
2974if test -n "$ac_ct_CC"; then
2975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2976$as_echo "$ac_ct_CC" >&6; }
2977else
2978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2979$as_echo "no" >&6; }
2980fi
2981
2982 if test "x$ac_ct_CC" = x; then
2983 CC=""
2984 else
2985 case $cross_compiling:$ac_tool_warned in
2986yes:)
2987{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2988$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2989ac_tool_warned=yes ;;
2990esac
2991 CC=$ac_ct_CC
2992 fi
2993else
2994 CC="$ac_cv_prog_CC"
2995fi
2996
2997if test -z "$CC"; then
2998 if test -n "$ac_tool_prefix"; then
2999 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3000set dummy ${ac_tool_prefix}cc; ac_word=$2
3001{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3002$as_echo_n "checking for $ac_word... " >&6; }
3003if ${ac_cv_prog_CC+:} false; then :
3004 $as_echo_n "(cached) " >&6
3005else
3006 if test -n "$CC"; then
3007 ac_cv_prog_CC="$CC" # Let the user override the test.
3008else
3009as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3010for as_dir in $PATH
3011do
3012 IFS=$as_save_IFS
3013 test -z "$as_dir" && as_dir=.
3014 for ac_exec_ext in '' $ac_executable_extensions; do
3015 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3016 ac_cv_prog_CC="${ac_tool_prefix}cc"
3017 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3018 break 2
3019 fi
3020done
3021 done
3022IFS=$as_save_IFS
3023
3024fi
3025fi
3026CC=$ac_cv_prog_CC
3027if test -n "$CC"; then
3028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3029$as_echo "$CC" >&6; }
3030else
3031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3032$as_echo "no" >&6; }
3033fi
3034
3035
3036 fi
3037fi
3038if test -z "$CC"; then
3039 # Extract the first word of "cc", so it can be a program name with args.
3040set dummy cc; ac_word=$2
3041{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3042$as_echo_n "checking for $ac_word... " >&6; }
3043if ${ac_cv_prog_CC+:} false; then :
3044 $as_echo_n "(cached) " >&6
3045else
3046 if test -n "$CC"; then
3047 ac_cv_prog_CC="$CC" # Let the user override the test.
3048else
3049 ac_prog_rejected=no
3050as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3051for as_dir in $PATH
3052do
3053 IFS=$as_save_IFS
3054 test -z "$as_dir" && as_dir=.
3055 for ac_exec_ext in '' $ac_executable_extensions; do
3056 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3057 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3058 ac_prog_rejected=yes
3059 continue
3060 fi
3061 ac_cv_prog_CC="cc"
3062 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3063 break 2
3064 fi
3065done
3066 done
3067IFS=$as_save_IFS
3068
3069if test $ac_prog_rejected = yes; then
3070 # We found a bogon in the path, so make sure we never use it.
3071 set dummy $ac_cv_prog_CC
3072 shift
3073 if test $# != 0; then
3074 # We chose a different compiler from the bogus one.
3075 # However, it has the same basename, so the bogon will be chosen
3076 # first if we set CC to just the basename; use the full file name.
3077 shift
3078 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3079 fi
3080fi
3081fi
3082fi
3083CC=$ac_cv_prog_CC
3084if test -n "$CC"; then
3085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3086$as_echo "$CC" >&6; }
3087else
3088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3089$as_echo "no" >&6; }
3090fi
3091
3092
3093fi
3094if test -z "$CC"; then
3095 if test -n "$ac_tool_prefix"; then
3096 for ac_prog in cl.exe
3097 do
3098 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3099set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3100{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3101$as_echo_n "checking for $ac_word... " >&6; }
3102if ${ac_cv_prog_CC+:} false; then :
3103 $as_echo_n "(cached) " >&6
3104else
3105 if test -n "$CC"; then
3106 ac_cv_prog_CC="$CC" # Let the user override the test.
3107else
3108as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3109for as_dir in $PATH
3110do
3111 IFS=$as_save_IFS
3112 test -z "$as_dir" && as_dir=.
3113 for ac_exec_ext in '' $ac_executable_extensions; do
3114 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3115 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3116 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3117 break 2
3118 fi
3119done
3120 done
3121IFS=$as_save_IFS
3122
3123fi
3124fi
3125CC=$ac_cv_prog_CC
3126if test -n "$CC"; then
3127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3128$as_echo "$CC" >&6; }
3129else
3130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3131$as_echo "no" >&6; }
3132fi
3133
3134
3135 test -n "$CC" && break
3136 done
3137fi
3138if test -z "$CC"; then
3139 ac_ct_CC=$CC
3140 for ac_prog in cl.exe
3141do
3142 # Extract the first word of "$ac_prog", so it can be a program name with args.
3143set dummy $ac_prog; ac_word=$2
3144{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3145$as_echo_n "checking for $ac_word... " >&6; }
3146if ${ac_cv_prog_ac_ct_CC+:} false; then :
3147 $as_echo_n "(cached) " >&6
3148else
3149 if test -n "$ac_ct_CC"; then
3150 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3151else
3152as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3153for as_dir in $PATH
3154do
3155 IFS=$as_save_IFS
3156 test -z "$as_dir" && as_dir=.
3157 for ac_exec_ext in '' $ac_executable_extensions; do
3158 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3159 ac_cv_prog_ac_ct_CC="$ac_prog"
3160 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3161 break 2
3162 fi
3163done
3164 done
3165IFS=$as_save_IFS
3166
3167fi
3168fi
3169ac_ct_CC=$ac_cv_prog_ac_ct_CC
3170if test -n "$ac_ct_CC"; then
3171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3172$as_echo "$ac_ct_CC" >&6; }
3173else
3174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3175$as_echo "no" >&6; }
3176fi
3177
3178
3179 test -n "$ac_ct_CC" && break
3180done
3181
3182 if test "x$ac_ct_CC" = x; then
3183 CC=""
3184 else
3185 case $cross_compiling:$ac_tool_warned in
3186yes:)
3187{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3188$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3189ac_tool_warned=yes ;;
3190esac
3191 CC=$ac_ct_CC
3192 fi
3193fi
3194
3195fi
3196
3197
3198test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3199$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3200as_fn_error $? "no acceptable C compiler found in \$PATH
3201See \`config.log' for more details" "$LINENO" 5; }
3202
3203# Provide some information about the compiler.
3204$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3205set X $ac_compile
3206ac_compiler=$2
3207for ac_option in --version -v -V -qversion; do
3208 { { ac_try="$ac_compiler $ac_option >&5"
3209case "(($ac_try" in
3210 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3211 *) ac_try_echo=$ac_try;;
3212esac
3213eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3214$as_echo "$ac_try_echo"; } >&5
3215 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3216 ac_status=$?
3217 if test -s conftest.err; then
3218 sed '10a\
3219... rest of stderr output deleted ...
3220 10q' conftest.err >conftest.er1
3221 cat conftest.er1 >&5
3222 fi
3223 rm -f conftest.er1 conftest.err
3224 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3225 test $ac_status = 0; }
3226done
3227
3228cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3229/* end confdefs.h. */
3230
3231int
3232main ()
3233{
3234
3235 ;
3236 return 0;
3237}
3238_ACEOF
3239ac_clean_files_save=$ac_clean_files
3240ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3241# Try to create an executable without -o first, disregard a.out.
3242# It will help us diagnose broken compilers, and finding out an intuition
3243# of exeext.
3244{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3245$as_echo_n "checking whether the C compiler works... " >&6; }
3246ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3247
3248# The possible output files:
3249ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3250
3251ac_rmfiles=
3252for ac_file in $ac_files
3253do
3254 case $ac_file in
3255 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3256 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3257 esac
3258done
3259rm -f $ac_rmfiles
3260
3261if { { ac_try="$ac_link_default"
3262case "(($ac_try" in
3263 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3264 *) ac_try_echo=$ac_try;;
3265esac
3266eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3267$as_echo "$ac_try_echo"; } >&5
3268 (eval "$ac_link_default") 2>&5
3269 ac_status=$?
3270 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3271 test $ac_status = 0; }; then :
3272 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3273# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3274# in a Makefile. We should not override ac_cv_exeext if it was cached,
3275# so that the user can short-circuit this test for compilers unknown to
3276# Autoconf.
3277for ac_file in $ac_files ''
3278do
3279 test -f "$ac_file" || continue
3280 case $ac_file in
3281 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3282 ;;
3283 [ab].out )
3284 # We found the default executable, but exeext='' is most
3285 # certainly right.
3286 break;;
3287 *.* )
3288 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3289 then :; else
3290 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3291 fi
3292 # We set ac_cv_exeext here because the later test for it is not
3293 # safe: cross compilers may not add the suffix if given an `-o'
3294 # argument, so we may need to know it at that point already.
3295 # Even if this section looks crufty: it has the advantage of
3296 # actually working.
3297 break;;
3298 * )
3299 break;;
3300 esac
3301done
3302test "$ac_cv_exeext" = no && ac_cv_exeext=
3303
3304else
3305 ac_file=''
3306fi
3307if test -z "$ac_file"; then :
3308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3309$as_echo "no" >&6; }
3310$as_echo "$as_me: failed program was:" >&5
3311sed 's/^/| /' conftest.$ac_ext >&5
3312
3313{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3314$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3315as_fn_error 77 "C compiler cannot create executables
3316See \`config.log' for more details" "$LINENO" 5; }
3317else
3318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3319$as_echo "yes" >&6; }
3320fi
3321{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
3322$as_echo_n "checking for C compiler default output file name... " >&6; }
3323{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
3324$as_echo "$ac_file" >&6; }
3325ac_exeext=$ac_cv_exeext
3326
3327rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3328ac_clean_files=$ac_clean_files_save
3329{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3330$as_echo_n "checking for suffix of executables... " >&6; }
3331if { { ac_try="$ac_link"
3332case "(($ac_try" in
3333 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3334 *) ac_try_echo=$ac_try;;
3335esac
3336eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3337$as_echo "$ac_try_echo"; } >&5
3338 (eval "$ac_link") 2>&5
3339 ac_status=$?
3340 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3341 test $ac_status = 0; }; then :
3342 # If both `conftest.exe' and `conftest' are `present' (well, observable)
3343# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
3344# work properly (i.e., refer to `conftest.exe'), while it won't with
3345# `rm'.
3346for ac_file in conftest.exe conftest conftest.*; do
3347 test -f "$ac_file" || continue
3348 case $ac_file in
3349 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3350 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3351 break;;
3352 * ) break;;
3353 esac
3354done
3355else
3356 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3357$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3358as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3359See \`config.log' for more details" "$LINENO" 5; }
3360fi
3361rm -f conftest conftest$ac_cv_exeext
3362{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3363$as_echo "$ac_cv_exeext" >&6; }
3364
3365rm -f conftest.$ac_ext
3366EXEEXT=$ac_cv_exeext
3367ac_exeext=$EXEEXT
3368cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3369/* end confdefs.h. */
3370#include <stdio.h>
3371int
3372main ()
3373{
3374FILE *f = fopen ("conftest.out", "w");
3375 return ferror (f) || fclose (f) != 0;
3376
3377 ;
3378 return 0;
3379}
3380_ACEOF
3381ac_clean_files="$ac_clean_files conftest.out"
3382# Check that the compiler produces executables we can run. If not, either
3383# the compiler is broken, or we cross compile.
3384{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3385$as_echo_n "checking whether we are cross compiling... " >&6; }
3386if test "$cross_compiling" != yes; then
3387 { { ac_try="$ac_link"
3388case "(($ac_try" in
3389 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3390 *) ac_try_echo=$ac_try;;
3391esac
3392eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3393$as_echo "$ac_try_echo"; } >&5
3394 (eval "$ac_link") 2>&5
3395 ac_status=$?
3396 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3397 test $ac_status = 0; }
3398 if { ac_try='./conftest$ac_cv_exeext'
3399 { { case "(($ac_try" in
3400 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3401 *) ac_try_echo=$ac_try;;
3402esac
3403eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3404$as_echo "$ac_try_echo"; } >&5
3405 (eval "$ac_try") 2>&5
3406 ac_status=$?
3407 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3408 test $ac_status = 0; }; }; then
3409 cross_compiling=no
3410 else
3411 if test "$cross_compiling" = maybe; then
3412 cross_compiling=yes
3413 else
3414 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3415$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3416as_fn_error $? "cannot run C compiled programs.
3417If you meant to cross compile, use \`--host'.
3418See \`config.log' for more details" "$LINENO" 5; }
3419 fi
3420 fi
3421fi
3422{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3423$as_echo "$cross_compiling" >&6; }
3424
3425rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3426ac_clean_files=$ac_clean_files_save
3427{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3428$as_echo_n "checking for suffix of object files... " >&6; }
3429if ${ac_cv_objext+:} false; then :
3430 $as_echo_n "(cached) " >&6
3431else
3432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3433/* end confdefs.h. */
3434
3435int
3436main ()
3437{
3438
3439 ;
3440 return 0;
3441}
3442_ACEOF
3443rm -f conftest.o conftest.obj
3444if { { ac_try="$ac_compile"
3445case "(($ac_try" in
3446 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3447 *) ac_try_echo=$ac_try;;
3448esac
3449eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3450$as_echo "$ac_try_echo"; } >&5
3451 (eval "$ac_compile") 2>&5
3452 ac_status=$?
3453 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3454 test $ac_status = 0; }; then :
3455 for ac_file in conftest.o conftest.obj conftest.*; do
3456 test -f "$ac_file" || continue;
3457 case $ac_file in
3458 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3459 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3460 break;;
3461 esac
3462done
3463else
3464 $as_echo "$as_me: failed program was:" >&5
3465sed 's/^/| /' conftest.$ac_ext >&5
3466
3467{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3468$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3469as_fn_error $? "cannot compute suffix of object files: cannot compile
3470See \`config.log' for more details" "$LINENO" 5; }
3471fi
3472rm -f conftest.$ac_cv_objext conftest.$ac_ext
3473fi
3474{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3475$as_echo "$ac_cv_objext" >&6; }
3476OBJEXT=$ac_cv_objext
3477ac_objext=$OBJEXT
3478{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3479$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3480if ${ac_cv_c_compiler_gnu+:} false; then :
3481 $as_echo_n "(cached) " >&6
3482else
3483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3484/* end confdefs.h. */
3485
3486int
3487main ()
3488{
3489#ifndef __GNUC__
3490 choke me
3491#endif
3492
3493 ;
3494 return 0;
3495}
3496_ACEOF
3497if ac_fn_c_try_compile "$LINENO"; then :
3498 ac_compiler_gnu=yes
3499else
3500 ac_compiler_gnu=no
3501fi
3502rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3503ac_cv_c_compiler_gnu=$ac_compiler_gnu
3504
3505fi
3506{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3507$as_echo "$ac_cv_c_compiler_gnu" >&6; }
3508if test $ac_compiler_gnu = yes; then
3509 GCC=yes
3510else
3511 GCC=
3512fi
3513ac_test_CFLAGS=${CFLAGS+set}
3514ac_save_CFLAGS=$CFLAGS
3515{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3516$as_echo_n "checking whether $CC accepts -g... " >&6; }
3517if ${ac_cv_prog_cc_g+:} false; then :
3518 $as_echo_n "(cached) " >&6
3519else
3520 ac_save_c_werror_flag=$ac_c_werror_flag
3521 ac_c_werror_flag=yes
3522 ac_cv_prog_cc_g=no
3523 CFLAGS="-g"
3524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3525/* end confdefs.h. */
3526
3527int
3528main ()
3529{
3530
3531 ;
3532 return 0;
3533}
3534_ACEOF
3535if ac_fn_c_try_compile "$LINENO"; then :
3536 ac_cv_prog_cc_g=yes
3537else
3538 CFLAGS=""
3539 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3540/* end confdefs.h. */
3541
3542int
3543main ()
3544{
3545
3546 ;
3547 return 0;
3548}
3549_ACEOF
3550if ac_fn_c_try_compile "$LINENO"; then :
3551
3552else
3553 ac_c_werror_flag=$ac_save_c_werror_flag
3554 CFLAGS="-g"
3555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3556/* end confdefs.h. */
3557
3558int
3559main ()
3560{
3561
3562 ;
3563 return 0;
3564}
3565_ACEOF
3566if ac_fn_c_try_compile "$LINENO"; then :
3567 ac_cv_prog_cc_g=yes
3568fi
3569rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3570fi
3571rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3572fi
3573rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3574 ac_c_werror_flag=$ac_save_c_werror_flag
3575fi
3576{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3577$as_echo "$ac_cv_prog_cc_g" >&6; }
3578if test "$ac_test_CFLAGS" = set; then
3579 CFLAGS=$ac_save_CFLAGS
3580elif test $ac_cv_prog_cc_g = yes; then
3581 if test "$GCC" = yes; then
3582 CFLAGS="-g -O2"
3583 else
3584 CFLAGS="-g"
3585 fi
3586else
3587 if test "$GCC" = yes; then
3588 CFLAGS="-O2"
3589 else
3590 CFLAGS=
3591 fi
3592fi
3593{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3594$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3595if ${ac_cv_prog_cc_c89+:} false; then :
3596 $as_echo_n "(cached) " >&6
3597else
3598 ac_cv_prog_cc_c89=no
3599ac_save_CC=$CC
3600cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3601/* end confdefs.h. */
3602#include <stdarg.h>
3603#include <stdio.h>
3604struct stat;
3605/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
3606struct buf { int x; };
3607FILE * (*rcsopen) (struct buf *, struct stat *, int);
3608static char *e (p, i)
3609 char **p;
3610 int i;
3611{
3612 return p[i];
3613}
3614static char *f (char * (*g) (char **, int), char **p, ...)
3615{
3616 char *s;
3617 va_list v;
3618 va_start (v,p);
3619 s = g (p, va_arg (v,int));
3620 va_end (v);
3621 return s;
3622}
3623
3624/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
3625 function prototypes and stuff, but not '\xHH' hex character constants.
3626 These don't provoke an error unfortunately, instead are silently treated
3627 as 'x'. The following induces an error, until -std is added to get
3628 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
3629 array size at least. It's necessary to write '\x00'==0 to get something
3630 that's true only with -std. */
3631int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3632
3633/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3634 inside strings and character constants. */
3635#define FOO(x) 'x'
3636int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3637
3638int test (int i, double x);
3639struct s1 {int (*f) (int a);};
3640struct s2 {int (*f) (double a);};
3641int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3642int argc;
3643char **argv;
3644int
3645main ()
3646{
3647return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
3648 ;
3649 return 0;
3650}
3651_ACEOF
3652for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3653 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3654do
3655 CC="$ac_save_CC $ac_arg"
3656 if ac_fn_c_try_compile "$LINENO"; then :
3657 ac_cv_prog_cc_c89=$ac_arg
3658fi
3659rm -f core conftest.err conftest.$ac_objext
3660 test "x$ac_cv_prog_cc_c89" != "xno" && break
3661done
3662rm -f conftest.$ac_ext
3663CC=$ac_save_CC
3664
3665fi
3666# AC_CACHE_VAL
3667case "x$ac_cv_prog_cc_c89" in
3668 x)
3669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3670$as_echo "none needed" >&6; } ;;
3671 xno)
3672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3673$as_echo "unsupported" >&6; } ;;
3674 *)
3675 CC="$CC $ac_cv_prog_cc_c89"
3676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3677$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3678esac
3679if test "x$ac_cv_prog_cc_c89" != xno; then :
3680
3681fi
3682
3683ac_ext=c
3684ac_cpp='$CPP $CPPFLAGS'
3685ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3686ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3687ac_compiler_gnu=$ac_cv_c_compiler_gnu
3688DEPDIR="${am__leading_dot}deps"
3689
3690ac_config_commands="$ac_config_commands depfiles"
3691
3692
3693am_make=${MAKE-make}
3694cat > confinc << 'END'
3695am__doit:
3696 @echo this is the am__doit target
3697.PHONY: am__doit
3698END
3699# If we don't find an include directive, just comment out the code.
3700{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
3701$as_echo_n "checking for style of include used by $am_make... " >&6; }
3702am__include="#"
3703am__quote=
3704_am_result=none
3705# First try GNU make style include.
3706echo "include confinc" > confmf
3707# Ignore all kinds of additional output from 'make'.
3708case `$am_make -s -f confmf 2> /dev/null` in #(
3709*the\ am__doit\ target*)
3710 am__include=include
3711 am__quote=
3712 _am_result=GNU
3713 ;;
3714esac
3715# Now try BSD make style include.
3716if test "$am__include" = "#"; then
3717 echo '.include "confinc"' > confmf
3718 case `$am_make -s -f confmf 2> /dev/null` in #(
3719 *the\ am__doit\ target*)
3720 am__include=.include
3721 am__quote="\""
3722 _am_result=BSD
3723 ;;
3724 esac
3725fi
3726
3727
3728{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
3729$as_echo "$_am_result" >&6; }
3730rm -f confinc confmf
3731
3732# Check whether --enable-dependency-tracking was given.
3733if test "${enable_dependency_tracking+set}" = set; then :
3734 enableval=$enable_dependency_tracking;
3735fi
3736
3737if test "x$enable_dependency_tracking" != xno; then
3738 am_depcomp="$ac_aux_dir/depcomp"
3739 AMDEPBACKSLASH='\'
3740 am__nodep='_no'
3741fi
3742 if test "x$enable_dependency_tracking" != xno; then
3743 AMDEP_TRUE=
3744 AMDEP_FALSE='#'
3745else
3746 AMDEP_TRUE='#'
3747 AMDEP_FALSE=
3748fi
3749
3750
3751
3752depcc="$CC" am_compiler_list=
3753
3754{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
3755$as_echo_n "checking dependency style of $depcc... " >&6; }
3756if ${am_cv_CC_dependencies_compiler_type+:} false; then :
3757 $as_echo_n "(cached) " >&6
3758else
3759 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
3760 # We make a subdir and do the tests there. Otherwise we can end up
3761 # making bogus files that we don't know about and never remove. For
3762 # instance it was reported that on HP-UX the gcc test will end up
3763 # making a dummy file named 'D' -- because '-MD' means "put the output
3764 # in D".
3765 rm -rf conftest.dir
3766 mkdir conftest.dir
3767 # Copy depcomp to subdir because otherwise we won't find it if we're
3768 # using a relative directory.
3769 cp "$am_depcomp" conftest.dir
3770 cd conftest.dir
3771 # We will build objects and dependencies in a subdirectory because
3772 # it helps to detect inapplicable dependency modes. For instance
3773 # both Tru64's cc and ICC support -MD to output dependencies as a
3774 # side effect of compilation, but ICC will put the dependencies in
3775 # the current directory while Tru64 will put them in the object
3776 # directory.
3777 mkdir sub
3778
3779 am_cv_CC_dependencies_compiler_type=none
3780 if test "$am_compiler_list" = ""; then
3781 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
3782 fi
3783 am__universal=false
3784 case " $depcc " in #(
3785 *\ -arch\ *\ -arch\ *) am__universal=true ;;
3786 esac
3787
3788 for depmode in $am_compiler_list; do
3789 # Setup a source with many dependencies, because some compilers
3790 # like to wrap large dependency lists on column 80 (with \), and
3791 # we should not choose a depcomp mode which is confused by this.
3792 #
3793 # We need to recreate these files for each test, as the compiler may
3794 # overwrite some of them when testing with obscure command lines.
3795 # This happens at least with the AIX C compiler.
3796 : > sub/conftest.c
3797 for i in 1 2 3 4 5 6; do
3798 echo '#include "conftst'$i'.h"' >> sub/conftest.c
3799 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
3800 # Solaris 10 /bin/sh.
3801 echo '/* dummy */' > sub/conftst$i.h
3802 done
3803 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
3804
3805 # We check with '-c' and '-o' for the sake of the "dashmstdout"
3806 # mode. It turns out that the SunPro C++ compiler does not properly
3807 # handle '-M -o', and we need to detect this. Also, some Intel
3808 # versions had trouble with output in subdirs.
3809 am__obj=sub/conftest.${OBJEXT-o}
3810 am__minus_obj="-o $am__obj"
3811 case $depmode in
3812 gcc)
3813 # This depmode causes a compiler race in universal mode.
3814 test "$am__universal" = false || continue
3815 ;;
3816 nosideeffect)
3817 # After this tag, mechanisms are not by side-effect, so they'll
3818 # only be used when explicitly requested.
3819 if test "x$enable_dependency_tracking" = xyes; then
3820 continue
3821 else
3822 break
3823 fi
3824 ;;
3825 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
3826 # This compiler won't grok '-c -o', but also, the minuso test has
3827 # not run yet. These depmodes are late enough in the game, and
3828 # so weak that their functioning should not be impacted.
3829 am__obj=conftest.${OBJEXT-o}
3830 am__minus_obj=
3831 ;;
3832 none) break ;;
3833 esac
3834 if depmode=$depmode \
3835 source=sub/conftest.c object=$am__obj \
3836 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
3837 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
3838 >/dev/null 2>conftest.err &&
3839 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
3840 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
3841 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
3842 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
3843 # icc doesn't choke on unknown options, it will just issue warnings
3844 # or remarks (even with -Werror). So we grep stderr for any message
3845 # that says an option was ignored or not supported.
3846 # When given -MP, icc 7.0 and 7.1 complain thusly:
3847 # icc: Command line warning: ignoring option '-M'; no argument required
3848 # The diagnosis changed in icc 8.0:
3849 # icc: Command line remark: option '-MP' not supported
3850 if (grep 'ignoring option' conftest.err ||
3851 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
3852 am_cv_CC_dependencies_compiler_type=$depmode
3853 break
3854 fi
3855 fi
3856 done
3857
3858 cd ..
3859 rm -rf conftest.dir
3860else
3861 am_cv_CC_dependencies_compiler_type=none
3862fi
3863
3864fi
3865{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
3866$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
3867CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
3868
3869 if
3870 test "x$enable_dependency_tracking" != xno \
3871 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
3872 am__fastdepCC_TRUE=
3873 am__fastdepCC_FALSE='#'
3874else
3875 am__fastdepCC_TRUE='#'
3876 am__fastdepCC_FALSE=
3877fi
3878
3879
3880ac_ext=cpp
3881ac_cpp='$CXXCPP $CPPFLAGS'
3882ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3883ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3884ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
3885if test -z "$CXX"; then
3886 if test -n "$CCC"; then
3887 CXX=$CCC
3888 else
3889 if test -n "$ac_tool_prefix"; then
3890 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3891 do
3892 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3893set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3894{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3895$as_echo_n "checking for $ac_word... " >&6; }
3896if ${ac_cv_prog_CXX+:} false; then :
3897 $as_echo_n "(cached) " >&6
3898else
3899 if test -n "$CXX"; then
3900 ac_cv_prog_CXX="$CXX" # Let the user override the test.
3901else
3902as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3903for as_dir in $PATH
3904do
3905 IFS=$as_save_IFS
3906 test -z "$as_dir" && as_dir=.
3907 for ac_exec_ext in '' $ac_executable_extensions; do
3908 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3909 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
3910 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3911 break 2
3912 fi
3913done
3914 done
3915IFS=$as_save_IFS
3916
3917fi
3918fi
3919CXX=$ac_cv_prog_CXX
3920if test -n "$CXX"; then
3921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
3922$as_echo "$CXX" >&6; }
3923else
3924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3925$as_echo "no" >&6; }
3926fi
3927
3928
3929 test -n "$CXX" && break
3930 done
3931fi
3932if test -z "$CXX"; then
3933 ac_ct_CXX=$CXX
3934 for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
3935do
3936 # Extract the first word of "$ac_prog", so it can be a program name with args.
3937set dummy $ac_prog; ac_word=$2
3938{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3939$as_echo_n "checking for $ac_word... " >&6; }
3940if ${ac_cv_prog_ac_ct_CXX+:} false; then :
3941 $as_echo_n "(cached) " >&6
3942else
3943 if test -n "$ac_ct_CXX"; then
3944 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
3945else
3946as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3947for as_dir in $PATH
3948do
3949 IFS=$as_save_IFS
3950 test -z "$as_dir" && as_dir=.
3951 for ac_exec_ext in '' $ac_executable_extensions; do
3952 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3953 ac_cv_prog_ac_ct_CXX="$ac_prog"
3954 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3955 break 2
3956 fi
3957done
3958 done
3959IFS=$as_save_IFS
3960
3961fi
3962fi
3963ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
3964if test -n "$ac_ct_CXX"; then
3965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
3966$as_echo "$ac_ct_CXX" >&6; }
3967else
3968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3969$as_echo "no" >&6; }
3970fi
3971
3972
3973 test -n "$ac_ct_CXX" && break
3974done
3975
3976 if test "x$ac_ct_CXX" = x; then
3977 CXX="g++"
3978 else
3979 case $cross_compiling:$ac_tool_warned in
3980yes:)
3981{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3982$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3983ac_tool_warned=yes ;;
3984esac
3985 CXX=$ac_ct_CXX
3986 fi
3987fi
3988
3989 fi
3990fi
3991# Provide some information about the compiler.
3992$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
3993set X $ac_compile
3994ac_compiler=$2
3995for ac_option in --version -v -V -qversion; do
3996 { { ac_try="$ac_compiler $ac_option >&5"
3997case "(($ac_try" in
3998 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3999 *) ac_try_echo=$ac_try;;
4000esac
4001eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4002$as_echo "$ac_try_echo"; } >&5
4003 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4004 ac_status=$?
4005 if test -s conftest.err; then
4006 sed '10a\
4007... rest of stderr output deleted ...
4008 10q' conftest.err >conftest.er1
4009 cat conftest.er1 >&5
4010 fi
4011 rm -f conftest.er1 conftest.err
4012 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4013 test $ac_status = 0; }
4014done
4015
4016{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
4017$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
4018if ${ac_cv_cxx_compiler_gnu+:} false; then :
4019 $as_echo_n "(cached) " >&6
4020else
4021 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4022/* end confdefs.h. */
4023
4024int
4025main ()
4026{
4027#ifndef __GNUC__
4028 choke me
4029#endif
4030
4031 ;
4032 return 0;
4033}
4034_ACEOF
4035if ac_fn_cxx_try_compile "$LINENO"; then :
4036 ac_compiler_gnu=yes
4037else
4038 ac_compiler_gnu=no
4039fi
4040rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4041ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
4042
4043fi
4044{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
4045$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
4046if test $ac_compiler_gnu = yes; then
4047 GXX=yes
4048else
4049 GXX=
4050fi
4051ac_test_CXXFLAGS=${CXXFLAGS+set}
4052ac_save_CXXFLAGS=$CXXFLAGS
4053{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
4054$as_echo_n "checking whether $CXX accepts -g... " >&6; }
4055if ${ac_cv_prog_cxx_g+:} false; then :
4056 $as_echo_n "(cached) " >&6
4057else
4058 ac_save_cxx_werror_flag=$ac_cxx_werror_flag
4059 ac_cxx_werror_flag=yes
4060 ac_cv_prog_cxx_g=no
4061 CXXFLAGS="-g"
4062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4063/* end confdefs.h. */
4064
4065int
4066main ()
4067{
4068
4069 ;
4070 return 0;
4071}
4072_ACEOF
4073if ac_fn_cxx_try_compile "$LINENO"; then :
4074 ac_cv_prog_cxx_g=yes
4075else
4076 CXXFLAGS=""
4077 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4078/* end confdefs.h. */
4079
4080int
4081main ()
4082{
4083
4084 ;
4085 return 0;
4086}
4087_ACEOF
4088if ac_fn_cxx_try_compile "$LINENO"; then :
4089
4090else
4091 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4092 CXXFLAGS="-g"
4093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4094/* end confdefs.h. */
4095
4096int
4097main ()
4098{
4099
4100 ;
4101 return 0;
4102}
4103_ACEOF
4104if ac_fn_cxx_try_compile "$LINENO"; then :
4105 ac_cv_prog_cxx_g=yes
4106fi
4107rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4108fi
4109rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4110fi
4111rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4112 ac_cxx_werror_flag=$ac_save_cxx_werror_flag
4113fi
4114{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
4115$as_echo "$ac_cv_prog_cxx_g" >&6; }
4116if test "$ac_test_CXXFLAGS" = set; then
4117 CXXFLAGS=$ac_save_CXXFLAGS
4118elif test $ac_cv_prog_cxx_g = yes; then
4119 if test "$GXX" = yes; then
4120 CXXFLAGS="-g -O2"
4121 else
4122 CXXFLAGS="-g"
4123 fi
4124else
4125 if test "$GXX" = yes; then
4126 CXXFLAGS="-O2"
4127 else
4128 CXXFLAGS=
4129 fi
4130fi
4131ac_ext=c
4132ac_cpp='$CPP $CPPFLAGS'
4133ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4134ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4135ac_compiler_gnu=$ac_cv_c_compiler_gnu
4136
4137depcc="$CXX" am_compiler_list=
4138
4139{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
4140$as_echo_n "checking dependency style of $depcc... " >&6; }
4141if ${am_cv_CXX_dependencies_compiler_type+:} false; then :
4142 $as_echo_n "(cached) " >&6
4143else
4144 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
4145 # We make a subdir and do the tests there. Otherwise we can end up
4146 # making bogus files that we don't know about and never remove. For
4147 # instance it was reported that on HP-UX the gcc test will end up
4148 # making a dummy file named 'D' -- because '-MD' means "put the output
4149 # in D".
4150 rm -rf conftest.dir
4151 mkdir conftest.dir
4152 # Copy depcomp to subdir because otherwise we won't find it if we're
4153 # using a relative directory.
4154 cp "$am_depcomp" conftest.dir
4155 cd conftest.dir
4156 # We will build objects and dependencies in a subdirectory because
4157 # it helps to detect inapplicable dependency modes. For instance
4158 # both Tru64's cc and ICC support -MD to output dependencies as a
4159 # side effect of compilation, but ICC will put the dependencies in
4160 # the current directory while Tru64 will put them in the object
4161 # directory.
4162 mkdir sub
4163
4164 am_cv_CXX_dependencies_compiler_type=none
4165 if test "$am_compiler_list" = ""; then
4166 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
4167 fi
4168 am__universal=false
4169 case " $depcc " in #(
4170 *\ -arch\ *\ -arch\ *) am__universal=true ;;
4171 esac
4172
4173 for depmode in $am_compiler_list; do
4174 # Setup a source with many dependencies, because some compilers
4175 # like to wrap large dependency lists on column 80 (with \), and
4176 # we should not choose a depcomp mode which is confused by this.
4177 #
4178 # We need to recreate these files for each test, as the compiler may
4179 # overwrite some of them when testing with obscure command lines.
4180 # This happens at least with the AIX C compiler.
4181 : > sub/conftest.c
4182 for i in 1 2 3 4 5 6; do
4183 echo '#include "conftst'$i'.h"' >> sub/conftest.c
4184 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
4185 # Solaris 10 /bin/sh.
4186 echo '/* dummy */' > sub/conftst$i.h
4187 done
4188 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
4189
4190 # We check with '-c' and '-o' for the sake of the "dashmstdout"
4191 # mode. It turns out that the SunPro C++ compiler does not properly
4192 # handle '-M -o', and we need to detect this. Also, some Intel
4193 # versions had trouble with output in subdirs.
4194 am__obj=sub/conftest.${OBJEXT-o}
4195 am__minus_obj="-o $am__obj"
4196 case $depmode in
4197 gcc)
4198 # This depmode causes a compiler race in universal mode.
4199 test "$am__universal" = false || continue
4200 ;;
4201 nosideeffect)
4202 # After this tag, mechanisms are not by side-effect, so they'll
4203 # only be used when explicitly requested.
4204 if test "x$enable_dependency_tracking" = xyes; then
4205 continue
4206 else
4207 break
4208 fi
4209 ;;
4210 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
4211 # This compiler won't grok '-c -o', but also, the minuso test has
4212 # not run yet. These depmodes are late enough in the game, and
4213 # so weak that their functioning should not be impacted.
4214 am__obj=conftest.${OBJEXT-o}
4215 am__minus_obj=
4216 ;;
4217 none) break ;;
4218 esac
4219 if depmode=$depmode \
4220 source=sub/conftest.c object=$am__obj \
4221 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
4222 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
4223 >/dev/null 2>conftest.err &&
4224 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
4225 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
4226 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
4227 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
4228 # icc doesn't choke on unknown options, it will just issue warnings
4229 # or remarks (even with -Werror). So we grep stderr for any message
4230 # that says an option was ignored or not supported.
4231 # When given -MP, icc 7.0 and 7.1 complain thusly:
4232 # icc: Command line warning: ignoring option '-M'; no argument required
4233 # The diagnosis changed in icc 8.0:
4234 # icc: Command line remark: option '-MP' not supported
4235 if (grep 'ignoring option' conftest.err ||
4236 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
4237 am_cv_CXX_dependencies_compiler_type=$depmode
4238 break
4239 fi
4240 fi
4241 done
4242
4243 cd ..
4244 rm -rf conftest.dir
4245else
4246 am_cv_CXX_dependencies_compiler_type=none
4247fi
4248
4249fi
4250{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5
4251$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; }
4252CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type
4253
4254 if
4255 test "x$enable_dependency_tracking" != xno \
4256 && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then
4257 am__fastdepCXX_TRUE=
4258 am__fastdepCXX_FALSE='#'
4259else
4260 am__fastdepCXX_TRUE='#'
4261 am__fastdepCXX_FALSE=
4262fi
4263
4264
4265if test "x$CC" != xcc; then
4266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
4267$as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
4268else
4269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
4270$as_echo_n "checking whether cc understands -c and -o together... " >&6; }
4271fi
4272set dummy $CC; ac_cc=`$as_echo "$2" |
4273 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
4274if eval \${ac_cv_prog_cc_${ac_cc}_c_o+:} false; then :
4275 $as_echo_n "(cached) " >&6
4276else
4277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4278/* end confdefs.h. */
4279
4280int
4281main ()
4282{
4283
4284 ;
4285 return 0;
4286}
4287_ACEOF
4288# Make sure it works both with $CC and with simple cc.
4289# We do the test twice because some compilers refuse to overwrite an
4290# existing .o file with -o, though they will create one.
4291ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
4292rm -f conftest2.*
4293if { { case "(($ac_try" in
4294 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4295 *) ac_try_echo=$ac_try;;
4296esac
4297eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4298$as_echo "$ac_try_echo"; } >&5
4299 (eval "$ac_try") 2>&5
4300 ac_status=$?
4301 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4302 test $ac_status = 0; } &&
4303 test -f conftest2.$ac_objext && { { case "(($ac_try" in
4304 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4305 *) ac_try_echo=$ac_try;;
4306esac
4307eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4308$as_echo "$ac_try_echo"; } >&5
4309 (eval "$ac_try") 2>&5
4310 ac_status=$?
4311 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4312 test $ac_status = 0; };
4313then
4314 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
4315 if test "x$CC" != xcc; then
4316 # Test first that cc exists at all.
4317 if { ac_try='cc -c conftest.$ac_ext >&5'
4318 { { case "(($ac_try" in
4319 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4320 *) ac_try_echo=$ac_try;;
4321esac
4322eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4323$as_echo "$ac_try_echo"; } >&5
4324 (eval "$ac_try") 2>&5
4325 ac_status=$?
4326 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4327 test $ac_status = 0; }; }; then
4328 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
4329 rm -f conftest2.*
4330 if { { case "(($ac_try" in
4331 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4332 *) ac_try_echo=$ac_try;;
4333esac
4334eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4335$as_echo "$ac_try_echo"; } >&5
4336 (eval "$ac_try") 2>&5
4337 ac_status=$?
4338 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4339 test $ac_status = 0; } &&
4340 test -f conftest2.$ac_objext && { { case "(($ac_try" in
4341 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4342 *) ac_try_echo=$ac_try;;
4343esac
4344eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4345$as_echo "$ac_try_echo"; } >&5
4346 (eval "$ac_try") 2>&5
4347 ac_status=$?
4348 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4349 test $ac_status = 0; };
4350 then
4351 # cc works too.
4352 :
4353 else
4354 # cc exists but doesn't like -o.
4355 eval ac_cv_prog_cc_${ac_cc}_c_o=no
4356 fi
4357 fi
4358 fi
4359else
4360 eval ac_cv_prog_cc_${ac_cc}_c_o=no
4361fi
4362rm -f core conftest*
4363
4364fi
4365if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
4366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4367$as_echo "yes" >&6; }
4368else
4369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4370$as_echo "no" >&6; }
4371
4372$as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
4373
4374fi
4375
4376# FIXME: we rely on the cache variable name because
4377# there is no other way.
4378set dummy $CC
4379am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
4380eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
4381if test "$am_t" != yes; then
4382 # Losing compiler, so override with the script.
4383 # FIXME: It is wrong to rewrite CC.
4384 # But if we don't then we get into trouble of one sort or another.
4385 # A longer-term fix would be to have automake use am__CC in this case,
4386 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
4387 CC="$am_aux_dir/compile $CC"
4388fi
4389
4390
4391
4392{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
4393$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
4394set x ${MAKE-make}
4395ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
4396if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
4397 $as_echo_n "(cached) " >&6
4398else
4399 cat >conftest.make <<\_ACEOF
4400SHELL = /bin/sh
4401all:
4402 @echo '@@@%%%=$(MAKE)=@@@%%%'
4403_ACEOF
4404# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
4405case `${MAKE-make} -f conftest.make 2>/dev/null` in
4406 *@@@%%%=?*=@@@%%%*)
4407 eval ac_cv_prog_make_${ac_make}_set=yes;;
4408 *)
4409 eval ac_cv_prog_make_${ac_make}_set=no;;
4410esac
4411rm -f conftest.make
4412fi
4413if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
4414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4415$as_echo "yes" >&6; }
4416 SET_MAKE=
4417else
4418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4419$as_echo "no" >&6; }
4420 SET_MAKE="MAKE=${MAKE-make}"
4421fi
4422
4423case `pwd` in
4424 *\ * | *\ *)
4425 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
4426$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
4427esac
4428
4429
4430
4431macro_version='2.4.2'
4432macro_revision='1.3337'
4433
4434
4435
4436
4437
4438
4439
4440
4441
4442
4443
4444
4445
4446ltmain="$ac_aux_dir/ltmain.sh"
4447
4448# Make sure we can run config.sub.
4449$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4450 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4451
4452{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4453$as_echo_n "checking build system type... " >&6; }
4454if ${ac_cv_build+:} false; then :
4455 $as_echo_n "(cached) " >&6
4456else
4457 ac_build_alias=$build_alias
4458test "x$ac_build_alias" = x &&
4459 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4460test "x$ac_build_alias" = x &&
4461 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
4462ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4463 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4464
4465fi
4466{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4467$as_echo "$ac_cv_build" >&6; }
4468case $ac_cv_build in
4469*-*-*) ;;
4470*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
4471esac
4472build=$ac_cv_build
4473ac_save_IFS=$IFS; IFS='-'
4474set x $ac_cv_build
4475shift
4476build_cpu=$1
4477build_vendor=$2
4478shift; shift
4479# Remember, the first character of IFS is used to create $*,
4480# except with old shells:
4481build_os=$*
4482IFS=$ac_save_IFS
4483case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4484
4485
4486{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4487$as_echo_n "checking host system type... " >&6; }
4488if ${ac_cv_host+:} false; then :
4489 $as_echo_n "(cached) " >&6
4490else
4491 if test "x$host_alias" = x; then
4492 ac_cv_host=$ac_cv_build
4493else
4494 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4495 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4496fi
4497
4498fi
4499{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4500$as_echo "$ac_cv_host" >&6; }
4501case $ac_cv_host in
4502*-*-*) ;;
4503*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
4504esac
4505host=$ac_cv_host
4506ac_save_IFS=$IFS; IFS='-'
4507set x $ac_cv_host
4508shift
4509host_cpu=$1
4510host_vendor=$2
4511shift; shift
4512# Remember, the first character of IFS is used to create $*,
4513# except with old shells:
4514host_os=$*
4515IFS=$ac_save_IFS
4516case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4517
4518
4519# Backslashify metacharacters that are still active within
4520# double-quoted strings.
4521sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
4522
4523# Same as above, but do not quote variable references.
4524double_quote_subst='s/\(["`\\]\)/\\\1/g'
4525
4526# Sed substitution to delay expansion of an escaped shell variable in a
4527# double_quote_subst'ed string.
4528delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
4529
4530# Sed substitution to delay expansion of an escaped single quote.
4531delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
4532
4533# Sed substitution to avoid accidental globbing in evaled expressions
4534no_glob_subst='s/\*/\\\*/g'
4535
4536ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
4537ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
4538ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
4539
4540{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
4541$as_echo_n "checking how to print strings... " >&6; }
4542# Test print first, because it will be a builtin if present.
4543if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
4544 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
4545 ECHO='print -r --'
4546elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
4547 ECHO='printf %s\n'
4548else
4549 # Use this function as a fallback that always works.
4550 func_fallback_echo ()
4551 {
4552 eval 'cat <<_LTECHO_EOF
4553$1
4554_LTECHO_EOF'
4555 }
4556 ECHO='func_fallback_echo'
4557fi
4558
4559# func_echo_all arg...
4560# Invoke $ECHO with all args, space-separated.
4561func_echo_all ()
4562{
4563 $ECHO ""
4564}
4565
4566case "$ECHO" in
4567 printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
4568$as_echo "printf" >&6; } ;;
4569 print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
4570$as_echo "print -r" >&6; } ;;
4571 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
4572$as_echo "cat" >&6; } ;;
4573esac
4574
4575
4576
4577
4578
4579
4580
4581
4582
4583
4584
4585
4586
4587
4588{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
4589$as_echo_n "checking for a sed that does not truncate output... " >&6; }
4590if ${ac_cv_path_SED+:} false; then :
4591 $as_echo_n "(cached) " >&6
4592else
4593 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
4594 for ac_i in 1 2 3 4 5 6 7; do
4595 ac_script="$ac_script$as_nl$ac_script"
4596 done
4597 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
4598 { ac_script=; unset ac_script;}
4599 if test -z "$SED"; then
4600 ac_path_SED_found=false
4601 # Loop through the user's path and test for each of PROGNAME-LIST
4602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4603for as_dir in $PATH
4604do
4605 IFS=$as_save_IFS
4606 test -z "$as_dir" && as_dir=.
4607 for ac_prog in sed gsed; do
4608 for ac_exec_ext in '' $ac_executable_extensions; do
4609 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
4610 as_fn_executable_p "$ac_path_SED" || continue
4611# Check for GNU ac_path_SED and select it if it is found.
4612 # Check for GNU $ac_path_SED
4613case `"$ac_path_SED" --version 2>&1` in
4614*GNU*)
4615 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
4616*)
4617 ac_count=0
4618 $as_echo_n 0123456789 >"conftest.in"
4619 while :
4620 do
4621 cat "conftest.in" "conftest.in" >"conftest.tmp"
4622 mv "conftest.tmp" "conftest.in"
4623 cp "conftest.in" "conftest.nl"
4624 $as_echo '' >> "conftest.nl"
4625 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
4626 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4627 as_fn_arith $ac_count + 1 && ac_count=$as_val
4628 if test $ac_count -gt ${ac_path_SED_max-0}; then
4629 # Best one so far, save it but keep looking for a better one
4630 ac_cv_path_SED="$ac_path_SED"
4631 ac_path_SED_max=$ac_count
4632 fi
4633 # 10*(2^10) chars as input seems more than enough
4634 test $ac_count -gt 10 && break
4635 done
4636 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4637esac
4638
4639 $ac_path_SED_found && break 3
4640 done
4641 done
4642 done
4643IFS=$as_save_IFS
4644 if test -z "$ac_cv_path_SED"; then
4645 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
4646 fi
4647else
4648 ac_cv_path_SED=$SED
4649fi
4650
4651fi
4652{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
4653$as_echo "$ac_cv_path_SED" >&6; }
4654 SED="$ac_cv_path_SED"
4655 rm -f conftest.sed
4656
4657test -z "$SED" && SED=sed
4658Xsed="$SED -e 1s/^X//"
4659
4660
4661
4662
4663
4664
4665
4666
4667
4668
4669
4670{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4671$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4672if ${ac_cv_path_GREP+:} false; then :
4673 $as_echo_n "(cached) " >&6
4674else
4675 if test -z "$GREP"; then
4676 ac_path_GREP_found=false
4677 # Loop through the user's path and test for each of PROGNAME-LIST
4678 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4679for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4680do
4681 IFS=$as_save_IFS
4682 test -z "$as_dir" && as_dir=.
4683 for ac_prog in grep ggrep; do
4684 for ac_exec_ext in '' $ac_executable_extensions; do
4685 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4686 as_fn_executable_p "$ac_path_GREP" || continue
4687# Check for GNU ac_path_GREP and select it if it is found.
4688 # Check for GNU $ac_path_GREP
4689case `"$ac_path_GREP" --version 2>&1` in
4690*GNU*)
4691 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4692*)
4693 ac_count=0
4694 $as_echo_n 0123456789 >"conftest.in"
4695 while :
4696 do
4697 cat "conftest.in" "conftest.in" >"conftest.tmp"
4698 mv "conftest.tmp" "conftest.in"
4699 cp "conftest.in" "conftest.nl"
4700 $as_echo 'GREP' >> "conftest.nl"
4701 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4702 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4703 as_fn_arith $ac_count + 1 && ac_count=$as_val
4704 if test $ac_count -gt ${ac_path_GREP_max-0}; then
4705 # Best one so far, save it but keep looking for a better one
4706 ac_cv_path_GREP="$ac_path_GREP"
4707 ac_path_GREP_max=$ac_count
4708 fi
4709 # 10*(2^10) chars as input seems more than enough
4710 test $ac_count -gt 10 && break
4711 done
4712 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4713esac
4714
4715 $ac_path_GREP_found && break 3
4716 done
4717 done
4718 done
4719IFS=$as_save_IFS
4720 if test -z "$ac_cv_path_GREP"; then
4721 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4722 fi
4723else
4724 ac_cv_path_GREP=$GREP
4725fi
4726
4727fi
4728{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4729$as_echo "$ac_cv_path_GREP" >&6; }
4730 GREP="$ac_cv_path_GREP"
4731
4732
4733{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4734$as_echo_n "checking for egrep... " >&6; }
4735if ${ac_cv_path_EGREP+:} false; then :
4736 $as_echo_n "(cached) " >&6
4737else
4738 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4739 then ac_cv_path_EGREP="$GREP -E"
4740 else
4741 if test -z "$EGREP"; then
4742 ac_path_EGREP_found=false
4743 # Loop through the user's path and test for each of PROGNAME-LIST
4744 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4745for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4746do
4747 IFS=$as_save_IFS
4748 test -z "$as_dir" && as_dir=.
4749 for ac_prog in egrep; do
4750 for ac_exec_ext in '' $ac_executable_extensions; do
4751 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4752 as_fn_executable_p "$ac_path_EGREP" || continue
4753# Check for GNU ac_path_EGREP and select it if it is found.
4754 # Check for GNU $ac_path_EGREP
4755case `"$ac_path_EGREP" --version 2>&1` in
4756*GNU*)
4757 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4758*)
4759 ac_count=0
4760 $as_echo_n 0123456789 >"conftest.in"
4761 while :
4762 do
4763 cat "conftest.in" "conftest.in" >"conftest.tmp"
4764 mv "conftest.tmp" "conftest.in"
4765 cp "conftest.in" "conftest.nl"
4766 $as_echo 'EGREP' >> "conftest.nl"
4767 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4768 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4769 as_fn_arith $ac_count + 1 && ac_count=$as_val
4770 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4771 # Best one so far, save it but keep looking for a better one
4772 ac_cv_path_EGREP="$ac_path_EGREP"
4773 ac_path_EGREP_max=$ac_count
4774 fi
4775 # 10*(2^10) chars as input seems more than enough
4776 test $ac_count -gt 10 && break
4777 done
4778 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4779esac
4780
4781 $ac_path_EGREP_found && break 3
4782 done
4783 done
4784 done
4785IFS=$as_save_IFS
4786 if test -z "$ac_cv_path_EGREP"; then
4787 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4788 fi
4789else
4790 ac_cv_path_EGREP=$EGREP
4791fi
4792
4793 fi
4794fi
4795{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4796$as_echo "$ac_cv_path_EGREP" >&6; }
4797 EGREP="$ac_cv_path_EGREP"
4798
4799
4800{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
4801$as_echo_n "checking for fgrep... " >&6; }
4802if ${ac_cv_path_FGREP+:} false; then :
4803 $as_echo_n "(cached) " >&6
4804else
4805 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
4806 then ac_cv_path_FGREP="$GREP -F"
4807 else
4808 if test -z "$FGREP"; then
4809 ac_path_FGREP_found=false
4810 # Loop through the user's path and test for each of PROGNAME-LIST
4811 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4812for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4813do
4814 IFS=$as_save_IFS
4815 test -z "$as_dir" && as_dir=.
4816 for ac_prog in fgrep; do
4817 for ac_exec_ext in '' $ac_executable_extensions; do
4818 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
4819 as_fn_executable_p "$ac_path_FGREP" || continue
4820# Check for GNU ac_path_FGREP and select it if it is found.
4821 # Check for GNU $ac_path_FGREP
4822case `"$ac_path_FGREP" --version 2>&1` in
4823*GNU*)
4824 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
4825*)
4826 ac_count=0
4827 $as_echo_n 0123456789 >"conftest.in"
4828 while :
4829 do
4830 cat "conftest.in" "conftest.in" >"conftest.tmp"
4831 mv "conftest.tmp" "conftest.in"
4832 cp "conftest.in" "conftest.nl"
4833 $as_echo 'FGREP' >> "conftest.nl"
4834 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
4835 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4836 as_fn_arith $ac_count + 1 && ac_count=$as_val
4837 if test $ac_count -gt ${ac_path_FGREP_max-0}; then
4838 # Best one so far, save it but keep looking for a better one
4839 ac_cv_path_FGREP="$ac_path_FGREP"
4840 ac_path_FGREP_max=$ac_count
4841 fi
4842 # 10*(2^10) chars as input seems more than enough
4843 test $ac_count -gt 10 && break
4844 done
4845 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4846esac
4847
4848 $ac_path_FGREP_found && break 3
4849 done
4850 done
4851 done
4852IFS=$as_save_IFS
4853 if test -z "$ac_cv_path_FGREP"; then
4854 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4855 fi
4856else
4857 ac_cv_path_FGREP=$FGREP
4858fi
4859
4860 fi
4861fi
4862{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
4863$as_echo "$ac_cv_path_FGREP" >&6; }
4864 FGREP="$ac_cv_path_FGREP"
4865
4866
4867test -z "$GREP" && GREP=grep
4868
4869
4870
4871
4872
4873
4874
4875
4876
4877
4878
4879
4880
4881
4882
4883
4884
4885
4886
4887# Check whether --with-gnu-ld was given.
4888if test "${with_gnu_ld+set}" = set; then :
4889 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
4890else
4891 with_gnu_ld=no
4892fi
4893
4894ac_prog=ld
4895if test "$GCC" = yes; then
4896 # Check if gcc -print-prog-name=ld gives a path.
4897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
4898$as_echo_n "checking for ld used by $CC... " >&6; }
4899 case $host in
4900 *-*-mingw*)
4901 # gcc leaves a trailing carriage return which upsets mingw
4902 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4903 *)
4904 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4905 esac
4906 case $ac_prog in
4907 # Accept absolute paths.
4908 [\\/]* | ?:[\\/]*)
4909 re_direlt='/[^/][^/]*/\.\./'
4910 # Canonicalize the pathname of ld
4911 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
4912 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
4913 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
4914 done
4915 test -z "$LD" && LD="$ac_prog"
4916 ;;
4917 "")
4918 # If it fails, then pretend we aren't using GCC.
4919 ac_prog=ld
4920 ;;
4921 *)
4922 # If it is relative, then search for the first ld in PATH.
4923 with_gnu_ld=unknown
4924 ;;
4925 esac
4926elif test "$with_gnu_ld" = yes; then
4927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
4928$as_echo_n "checking for GNU ld... " >&6; }
4929else
4930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
4931$as_echo_n "checking for non-GNU ld... " >&6; }
4932fi
4933if ${lt_cv_path_LD+:} false; then :
4934 $as_echo_n "(cached) " >&6
4935else
4936 if test -z "$LD"; then
4937 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4938 for ac_dir in $PATH; do
4939 IFS="$lt_save_ifs"
4940 test -z "$ac_dir" && ac_dir=.
4941 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4942 lt_cv_path_LD="$ac_dir/$ac_prog"
4943 # Check to see if the program is GNU ld. I'd rather use --version,
4944 # but apparently some variants of GNU ld only accept -v.
4945 # Break only if it was the GNU/non-GNU ld that we prefer.
4946 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
4947 *GNU* | *'with BFD'*)
4948 test "$with_gnu_ld" != no && break
4949 ;;
4950 *)
4951 test "$with_gnu_ld" != yes && break
4952 ;;
4953 esac
4954 fi
4955 done
4956 IFS="$lt_save_ifs"
4957else
4958 lt_cv_path_LD="$LD" # Let the user override the test with a path.
4959fi
4960fi
4961
4962LD="$lt_cv_path_LD"
4963if test -n "$LD"; then
4964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
4965$as_echo "$LD" >&6; }
4966else
4967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4968$as_echo "no" >&6; }
4969fi
4970test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
4971{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
4972$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
4973if ${lt_cv_prog_gnu_ld+:} false; then :
4974 $as_echo_n "(cached) " >&6
4975else
4976 # I'd rather use --version here, but apparently some GNU lds only accept -v.
4977case `$LD -v 2>&1 </dev/null` in
4978*GNU* | *'with BFD'*)
4979 lt_cv_prog_gnu_ld=yes
4980 ;;
4981*)
4982 lt_cv_prog_gnu_ld=no
4983 ;;
4984esac
4985fi
4986{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
4987$as_echo "$lt_cv_prog_gnu_ld" >&6; }
4988with_gnu_ld=$lt_cv_prog_gnu_ld
4989
4990
4991
4992
4993
4994
4995
4996
4997
4998{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
4999$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
5000if ${lt_cv_path_NM+:} false; then :
5001 $as_echo_n "(cached) " >&6
5002else
5003 if test -n "$NM"; then
5004 # Let the user override the test.
5005 lt_cv_path_NM="$NM"
5006else
5007 lt_nm_to_check="${ac_tool_prefix}nm"
5008 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
5009 lt_nm_to_check="$lt_nm_to_check nm"
5010 fi
5011 for lt_tmp_nm in $lt_nm_to_check; do
5012 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
5013 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
5014 IFS="$lt_save_ifs"
5015 test -z "$ac_dir" && ac_dir=.
5016 tmp_nm="$ac_dir/$lt_tmp_nm"
5017 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
5018 # Check to see if the nm accepts a BSD-compat flag.
5019 # Adding the `sed 1q' prevents false positives on HP-UX, which says:
5020 # nm: unknown option "B" ignored
5021 # Tru64's nm complains that /dev/null is an invalid object file
5022 case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
5023 */dev/null* | *'Invalid file or object type'*)
5024 lt_cv_path_NM="$tmp_nm -B"
5025 break
5026 ;;
5027 *)
5028 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
5029 */dev/null*)
5030 lt_cv_path_NM="$tmp_nm -p"
5031 break
5032 ;;
5033 *)
5034 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
5035 continue # so that we can try to find one that supports BSD flags
5036 ;;
5037 esac
5038 ;;
5039 esac
5040 fi
5041 done
5042 IFS="$lt_save_ifs"
5043 done
5044 : ${lt_cv_path_NM=no}
5045fi
5046fi
5047{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
5048$as_echo "$lt_cv_path_NM" >&6; }
5049if test "$lt_cv_path_NM" != "no"; then
5050 NM="$lt_cv_path_NM"
5051else
5052 # Didn't find any BSD compatible name lister, look for dumpbin.
5053 if test -n "$DUMPBIN"; then :
5054 # Let the user override the test.
5055 else
5056 if test -n "$ac_tool_prefix"; then
5057 for ac_prog in dumpbin "link -dump"
5058 do
5059 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5060set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5061{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5062$as_echo_n "checking for $ac_word... " >&6; }
5063if ${ac_cv_prog_DUMPBIN+:} false; then :
5064 $as_echo_n "(cached) " >&6
5065else
5066 if test -n "$DUMPBIN"; then
5067 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
5068else
5069as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5070for as_dir in $PATH
5071do
5072 IFS=$as_save_IFS
5073 test -z "$as_dir" && as_dir=.
5074 for ac_exec_ext in '' $ac_executable_extensions; do
5075 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5076 ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
5077 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5078 break 2
5079 fi
5080done
5081 done
5082IFS=$as_save_IFS
5083
5084fi
5085fi
5086DUMPBIN=$ac_cv_prog_DUMPBIN
5087if test -n "$DUMPBIN"; then
5088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
5089$as_echo "$DUMPBIN" >&6; }
5090else
5091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5092$as_echo "no" >&6; }
5093fi
5094
5095
5096 test -n "$DUMPBIN" && break
5097 done
5098fi
5099if test -z "$DUMPBIN"; then
5100 ac_ct_DUMPBIN=$DUMPBIN
5101 for ac_prog in dumpbin "link -dump"
5102do
5103 # Extract the first word of "$ac_prog", so it can be a program name with args.
5104set dummy $ac_prog; ac_word=$2
5105{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5106$as_echo_n "checking for $ac_word... " >&6; }
5107if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
5108 $as_echo_n "(cached) " >&6
5109else
5110 if test -n "$ac_ct_DUMPBIN"; then
5111 ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
5112else
5113as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5114for as_dir in $PATH
5115do
5116 IFS=$as_save_IFS
5117 test -z "$as_dir" && as_dir=.
5118 for ac_exec_ext in '' $ac_executable_extensions; do
5119 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5120 ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
5121 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5122 break 2
5123 fi
5124done
5125 done
5126IFS=$as_save_IFS
5127
5128fi
5129fi
5130ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
5131if test -n "$ac_ct_DUMPBIN"; then
5132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
5133$as_echo "$ac_ct_DUMPBIN" >&6; }
5134else
5135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5136$as_echo "no" >&6; }
5137fi
5138
5139
5140 test -n "$ac_ct_DUMPBIN" && break
5141done
5142
5143 if test "x$ac_ct_DUMPBIN" = x; then
5144 DUMPBIN=":"
5145 else
5146 case $cross_compiling:$ac_tool_warned in
5147yes:)
5148{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5149$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5150ac_tool_warned=yes ;;
5151esac
5152 DUMPBIN=$ac_ct_DUMPBIN
5153 fi
5154fi
5155
5156 case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
5157 *COFF*)
5158 DUMPBIN="$DUMPBIN -symbols"
5159 ;;
5160 *)
5161 DUMPBIN=:
5162 ;;
5163 esac
5164 fi
5165
5166 if test "$DUMPBIN" != ":"; then
5167 NM="$DUMPBIN"
5168 fi
5169fi
5170test -z "$NM" && NM=nm
5171
5172
5173
5174
5175
5176
5177{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
5178$as_echo_n "checking the name lister ($NM) interface... " >&6; }
5179if ${lt_cv_nm_interface+:} false; then :
5180 $as_echo_n "(cached) " >&6
5181else
5182 lt_cv_nm_interface="BSD nm"
5183 echo "int some_variable = 0;" > conftest.$ac_ext
5184 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
5185 (eval "$ac_compile" 2>conftest.err)
5186 cat conftest.err >&5
5187 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
5188 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
5189 cat conftest.err >&5
5190 (eval echo "\"\$as_me:$LINENO: output\"" >&5)
5191 cat conftest.out >&5
5192 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
5193 lt_cv_nm_interface="MS dumpbin"
5194 fi
5195 rm -f conftest*
5196fi
5197{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
5198$as_echo "$lt_cv_nm_interface" >&6; }
5199
5200{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
5201$as_echo_n "checking whether ln -s works... " >&6; }
5202LN_S=$as_ln_s
5203if test "$LN_S" = "ln -s"; then
5204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5205$as_echo "yes" >&6; }
5206else
5207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
5208$as_echo "no, using $LN_S" >&6; }
5209fi
5210
5211# find the maximum length of command line arguments
5212{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
5213$as_echo_n "checking the maximum length of command line arguments... " >&6; }
5214if ${lt_cv_sys_max_cmd_len+:} false; then :
5215 $as_echo_n "(cached) " >&6
5216else
5217 i=0
5218 teststring="ABCD"
5219
5220 case $build_os in
5221 msdosdjgpp*)
5222 # On DJGPP, this test can blow up pretty badly due to problems in libc
5223 # (any single argument exceeding 2000 bytes causes a buffer overrun
5224 # during glob expansion). Even if it were fixed, the result of this
5225 # check would be larger than it should be.
5226 lt_cv_sys_max_cmd_len=12288; # 12K is about right
5227 ;;
5228
5229 gnu*)
5230 # Under GNU Hurd, this test is not required because there is
5231 # no limit to the length of command line arguments.
5232 # Libtool will interpret -1 as no limit whatsoever
5233 lt_cv_sys_max_cmd_len=-1;
5234 ;;
5235
5236 cygwin* | mingw* | cegcc*)
5237 # On Win9x/ME, this test blows up -- it succeeds, but takes
5238 # about 5 minutes as the teststring grows exponentially.
5239 # Worse, since 9x/ME are not pre-emptively multitasking,
5240 # you end up with a "frozen" computer, even though with patience
5241 # the test eventually succeeds (with a max line length of 256k).
5242 # Instead, let's just punt: use the minimum linelength reported by
5243 # all of the supported platforms: 8192 (on NT/2K/XP).
5244 lt_cv_sys_max_cmd_len=8192;
5245 ;;
5246
5247 mint*)
5248 # On MiNT this can take a long time and run out of memory.
5249 lt_cv_sys_max_cmd_len=8192;
5250 ;;
5251
5252 amigaos*)
5253 # On AmigaOS with pdksh, this test takes hours, literally.
5254 # So we just punt and use a minimum line length of 8192.
5255 lt_cv_sys_max_cmd_len=8192;
5256 ;;
5257
5258 netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
5259 # This has been around since 386BSD, at least. Likely further.
5260 if test -x /sbin/sysctl; then
5261 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
5262 elif test -x /usr/sbin/sysctl; then
5263 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
5264 else
5265 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
5266 fi
5267 # And add a safety zone
5268 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
5269 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
5270 ;;
5271
5272 interix*)
5273 # We know the value 262144 and hardcode it with a safety zone (like BSD)
5274 lt_cv_sys_max_cmd_len=196608
5275 ;;
5276
5277 os2*)
5278 # The test takes a long time on OS/2.
5279 lt_cv_sys_max_cmd_len=8192
5280 ;;
5281
5282 osf*)
5283 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
5284 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
5285 # nice to cause kernel panics so lets avoid the loop below.
5286 # First set a reasonable default.
5287 lt_cv_sys_max_cmd_len=16384
5288 #
5289 if test -x /sbin/sysconfig; then
5290 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
5291 *1*) lt_cv_sys_max_cmd_len=-1 ;;
5292 esac
5293 fi
5294 ;;
5295 sco3.2v5*)
5296 lt_cv_sys_max_cmd_len=102400
5297 ;;
5298 sysv5* | sco5v6* | sysv4.2uw2*)
5299 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
5300 if test -n "$kargmax"; then
5301 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
5302 else
5303 lt_cv_sys_max_cmd_len=32768
5304 fi
5305 ;;
5306 *)
5307 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
5308 if test -n "$lt_cv_sys_max_cmd_len"; then
5309 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
5310 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
5311 else
5312 # Make teststring a little bigger before we do anything with it.
5313 # a 1K string should be a reasonable start.
5314 for i in 1 2 3 4 5 6 7 8 ; do
5315 teststring=$teststring$teststring
5316 done
5317 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
5318 # If test is not a shell built-in, we'll probably end up computing a
5319 # maximum length that is only half of the actual maximum length, but
5320 # we can't tell.
5321 while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
5322 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
5323 test $i != 17 # 1/2 MB should be enough
5324 do
5325 i=`expr $i + 1`
5326 teststring=$teststring$teststring
5327 done
5328 # Only check the string length outside the loop.
5329 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
5330 teststring=
5331 # Add a significant safety factor because C++ compilers can tack on
5332 # massive amounts of additional arguments before passing them to the
5333 # linker. It appears as though 1/2 is a usable value.
5334 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
5335 fi
5336 ;;
5337 esac
5338
5339fi
5340
5341if test -n $lt_cv_sys_max_cmd_len ; then
5342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
5343$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
5344else
5345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
5346$as_echo "none" >&6; }
5347fi
5348max_cmd_len=$lt_cv_sys_max_cmd_len
5349
5350
5351
5352
5353
5354
5355: ${CP="cp -f"}
5356: ${MV="mv -f"}
5357: ${RM="rm -f"}
5358
5359{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
5360$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
5361# Try some XSI features
5362xsi_shell=no
5363( _lt_dummy="a/b/c"
5364 test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
5365 = c,a/b,b/c, \
5366 && eval 'test $(( 1 + 1 )) -eq 2 \
5367 && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
5368 && xsi_shell=yes
5369{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
5370$as_echo "$xsi_shell" >&6; }
5371
5372
5373{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
5374$as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
5375lt_shell_append=no
5376( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
5377 >/dev/null 2>&1 \
5378 && lt_shell_append=yes
5379{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
5380$as_echo "$lt_shell_append" >&6; }
5381
5382
5383if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
5384 lt_unset=unset
5385else
5386 lt_unset=false
5387fi
5388
5389
5390
5391
5392
5393# test EBCDIC or ASCII
5394case `echo X|tr X '\101'` in
5395 A) # ASCII based system
5396 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
5397 lt_SP2NL='tr \040 \012'
5398 lt_NL2SP='tr \015\012 \040\040'
5399 ;;
5400 *) # EBCDIC based system
5401 lt_SP2NL='tr \100 \n'
5402 lt_NL2SP='tr \r\n \100\100'
5403 ;;
5404esac
5405
5406
5407
5408
5409
5410
5411
5412
5413
5414{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
5415$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
5416if ${lt_cv_to_host_file_cmd+:} false; then :
5417 $as_echo_n "(cached) " >&6
5418else
5419 case $host in
5420 *-*-mingw* )
5421 case $build in
5422 *-*-mingw* ) # actually msys
5423 lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
5424 ;;
5425 *-*-cygwin* )
5426 lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
5427 ;;
5428 * ) # otherwise, assume *nix
5429 lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
5430 ;;
5431 esac
5432 ;;
5433 *-*-cygwin* )
5434 case $build in
5435 *-*-mingw* ) # actually msys
5436 lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
5437 ;;
5438 *-*-cygwin* )
5439 lt_cv_to_host_file_cmd=func_convert_file_noop
5440 ;;
5441 * ) # otherwise, assume *nix
5442 lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
5443 ;;
5444 esac
5445 ;;
5446 * ) # unhandled hosts (and "normal" native builds)
5447 lt_cv_to_host_file_cmd=func_convert_file_noop
5448 ;;
5449esac
5450
5451fi
5452
5453to_host_file_cmd=$lt_cv_to_host_file_cmd
5454{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
5455$as_echo "$lt_cv_to_host_file_cmd" >&6; }
5456
5457
5458
5459
5460
5461{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
5462$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
5463if ${lt_cv_to_tool_file_cmd+:} false; then :
5464 $as_echo_n "(cached) " >&6
5465else
5466 #assume ordinary cross tools, or native build.
5467lt_cv_to_tool_file_cmd=func_convert_file_noop
5468case $host in
5469 *-*-mingw* )
5470 case $build in
5471 *-*-mingw* ) # actually msys
5472 lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
5473 ;;
5474 esac
5475 ;;
5476esac
5477
5478fi
5479
5480to_tool_file_cmd=$lt_cv_to_tool_file_cmd
5481{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
5482$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
5483
5484
5485
5486
5487
5488{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
5489$as_echo_n "checking for $LD option to reload object files... " >&6; }
5490if ${lt_cv_ld_reload_flag+:} false; then :
5491 $as_echo_n "(cached) " >&6
5492else
5493 lt_cv_ld_reload_flag='-r'
5494fi
5495{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
5496$as_echo "$lt_cv_ld_reload_flag" >&6; }
5497reload_flag=$lt_cv_ld_reload_flag
5498case $reload_flag in
5499"" | " "*) ;;
5500*) reload_flag=" $reload_flag" ;;
5501esac
5502reload_cmds='$LD$reload_flag -o $output$reload_objs'
5503case $host_os in
5504 cygwin* | mingw* | pw32* | cegcc*)
5505 if test "$GCC" != yes; then
5506 reload_cmds=false
5507 fi
5508 ;;
5509 darwin*)
5510 if test "$GCC" = yes; then
5511 reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
5512 else
5513 reload_cmds='$LD$reload_flag -o $output$reload_objs'
5514 fi
5515 ;;
5516esac
5517
5518
5519
5520
5521
5522
5523
5524
5525
5526if test -n "$ac_tool_prefix"; then
5527 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
5528set dummy ${ac_tool_prefix}objdump; ac_word=$2
5529{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5530$as_echo_n "checking for $ac_word... " >&6; }
5531if ${ac_cv_prog_OBJDUMP+:} false; then :
5532 $as_echo_n "(cached) " >&6
5533else
5534 if test -n "$OBJDUMP"; then
5535 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
5536else
5537as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5538for as_dir in $PATH
5539do
5540 IFS=$as_save_IFS
5541 test -z "$as_dir" && as_dir=.
5542 for ac_exec_ext in '' $ac_executable_extensions; do
5543 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5544 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
5545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5546 break 2
5547 fi
5548done
5549 done
5550IFS=$as_save_IFS
5551
5552fi
5553fi
5554OBJDUMP=$ac_cv_prog_OBJDUMP
5555if test -n "$OBJDUMP"; then
5556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
5557$as_echo "$OBJDUMP" >&6; }
5558else
5559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5560$as_echo "no" >&6; }
5561fi
5562
5563
5564fi
5565if test -z "$ac_cv_prog_OBJDUMP"; then
5566 ac_ct_OBJDUMP=$OBJDUMP
5567 # Extract the first word of "objdump", so it can be a program name with args.
5568set dummy objdump; ac_word=$2
5569{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5570$as_echo_n "checking for $ac_word... " >&6; }
5571if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
5572 $as_echo_n "(cached) " >&6
5573else
5574 if test -n "$ac_ct_OBJDUMP"; then
5575 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
5576else
5577as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5578for as_dir in $PATH
5579do
5580 IFS=$as_save_IFS
5581 test -z "$as_dir" && as_dir=.
5582 for ac_exec_ext in '' $ac_executable_extensions; do
5583 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5584 ac_cv_prog_ac_ct_OBJDUMP="objdump"
5585 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5586 break 2
5587 fi
5588done
5589 done
5590IFS=$as_save_IFS
5591
5592fi
5593fi
5594ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
5595if test -n "$ac_ct_OBJDUMP"; then
5596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
5597$as_echo "$ac_ct_OBJDUMP" >&6; }
5598else
5599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5600$as_echo "no" >&6; }
5601fi
5602
5603 if test "x$ac_ct_OBJDUMP" = x; then
5604 OBJDUMP="false"
5605 else
5606 case $cross_compiling:$ac_tool_warned in
5607yes:)
5608{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5609$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5610ac_tool_warned=yes ;;
5611esac
5612 OBJDUMP=$ac_ct_OBJDUMP
5613 fi
5614else
5615 OBJDUMP="$ac_cv_prog_OBJDUMP"
5616fi
5617
5618test -z "$OBJDUMP" && OBJDUMP=objdump
5619
5620
5621
5622
5623
5624
5625
5626
5627
5628{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
5629$as_echo_n "checking how to recognize dependent libraries... " >&6; }
5630if ${lt_cv_deplibs_check_method+:} false; then :
5631 $as_echo_n "(cached) " >&6
5632else
5633 lt_cv_file_magic_cmd='$MAGIC_CMD'
5634lt_cv_file_magic_test_file=
5635lt_cv_deplibs_check_method='unknown'
5636# Need to set the preceding variable on all platforms that support
5637# interlibrary dependencies.
5638# 'none' -- dependencies not supported.
5639# `unknown' -- same as none, but documents that we really don't know.
5640# 'pass_all' -- all dependencies passed with no checks.
5641# 'test_compile' -- check by making test program.
5642# 'file_magic [[regex]]' -- check by looking for files in library path
5643# which responds to the $file_magic_cmd with a given extended regex.
5644# If you have `file' or equivalent on your system and you're not sure
5645# whether `pass_all' will *always* work, you probably want this one.
5646
5647case $host_os in
5648aix[4-9]*)
5649 lt_cv_deplibs_check_method=pass_all
5650 ;;
5651
5652beos*)
5653 lt_cv_deplibs_check_method=pass_all
5654 ;;
5655
5656bsdi[45]*)
5657 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
5658 lt_cv_file_magic_cmd='/usr/bin/file -L'
5659 lt_cv_file_magic_test_file=/shlib/libc.so
5660 ;;
5661
5662cygwin*)
5663 # func_win32_libid is a shell function defined in ltmain.sh
5664 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5665 lt_cv_file_magic_cmd='func_win32_libid'
5666 ;;
5667
5668mingw* | pw32*)
5669 # Base MSYS/MinGW do not provide the 'file' command needed by
5670 # func_win32_libid shell function, so use a weaker test based on 'objdump',
5671 # unless we find 'file', for example because we are cross-compiling.
5672 # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
5673 if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
5674 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5675 lt_cv_file_magic_cmd='func_win32_libid'
5676 else
5677 # Keep this pattern in sync with the one in func_win32_libid.
5678 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
5679 lt_cv_file_magic_cmd='$OBJDUMP -f'
5680 fi
5681 ;;
5682
5683cegcc*)
5684 # use the weaker test based on 'objdump'. See mingw*.
5685 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
5686 lt_cv_file_magic_cmd='$OBJDUMP -f'
5687 ;;
5688
5689darwin* | rhapsody*)
5690 lt_cv_deplibs_check_method=pass_all
5691 ;;
5692
5693freebsd* | dragonfly*)
5694 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
5695 case $host_cpu in
5696 i*86 )
5697 # Not sure whether the presence of OpenBSD here was a mistake.
5698 # Let's accept both of them until this is cleared up.
5699 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
5700 lt_cv_file_magic_cmd=/usr/bin/file
5701 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
5702 ;;
5703 esac
5704 else
5705 lt_cv_deplibs_check_method=pass_all
5706 fi
5707 ;;
5708
5709gnu*)
5710 lt_cv_deplibs_check_method=pass_all
5711 ;;
5712
5713haiku*)
5714 lt_cv_deplibs_check_method=pass_all
5715 ;;
5716
5717hpux10.20* | hpux11*)
5718 lt_cv_file_magic_cmd=/usr/bin/file
5719 case $host_cpu in
5720 ia64*)
5721 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
5722 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
5723 ;;
5724 hppa*64*)
5725 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
5726 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
5727 ;;
5728 *)
5729 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
5730 lt_cv_file_magic_test_file=/usr/lib/libc.sl
5731 ;;
5732 esac
5733 ;;
5734
5735interix[3-9]*)
5736 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
5737 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
5738 ;;
5739
5740irix5* | irix6* | nonstopux*)
5741 case $LD in
5742 *-32|*"-32 ") libmagic=32-bit;;
5743 *-n32|*"-n32 ") libmagic=N32;;
5744 *-64|*"-64 ") libmagic=64-bit;;
5745 *) libmagic=never-match;;
5746 esac
5747 lt_cv_deplibs_check_method=pass_all
5748 ;;
5749
5750# This must be glibc/ELF.
5751linux* | k*bsd*-gnu | kopensolaris*-gnu)
5752 lt_cv_deplibs_check_method=pass_all
5753 ;;
5754
5755netbsd*)
5756 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
5757 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5758 else
5759 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
5760 fi
5761 ;;
5762
5763newos6*)
5764 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
5765 lt_cv_file_magic_cmd=/usr/bin/file
5766 lt_cv_file_magic_test_file=/usr/lib/libnls.so
5767 ;;
5768
5769*nto* | *qnx*)
5770 lt_cv_deplibs_check_method=pass_all
5771 ;;
5772
5773openbsd*)
5774 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5775 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
5776 else
5777 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5778 fi
5779 ;;
5780
5781osf3* | osf4* | osf5*)
5782 lt_cv_deplibs_check_method=pass_all
5783 ;;
5784
5785rdos*)
5786 lt_cv_deplibs_check_method=pass_all
5787 ;;
5788
5789solaris*)
5790 lt_cv_deplibs_check_method=pass_all
5791 ;;
5792
5793sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
5794 lt_cv_deplibs_check_method=pass_all
5795 ;;
5796
5797sysv4 | sysv4.3*)
5798 case $host_vendor in
5799 motorola)
5800 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
5801 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
5802 ;;
5803 ncr)
5804 lt_cv_deplibs_check_method=pass_all
5805 ;;
5806 sequent)
5807 lt_cv_file_magic_cmd='/bin/file'
5808 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
5809 ;;
5810 sni)
5811 lt_cv_file_magic_cmd='/bin/file'
5812 lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
5813 lt_cv_file_magic_test_file=/lib/libc.so
5814 ;;
5815 siemens)
5816 lt_cv_deplibs_check_method=pass_all
5817 ;;
5818 pc)
5819 lt_cv_deplibs_check_method=pass_all
5820 ;;
5821 esac
5822 ;;
5823
5824tpf*)
5825 lt_cv_deplibs_check_method=pass_all
5826 ;;
5827esac
5828
5829fi
5830{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
5831$as_echo "$lt_cv_deplibs_check_method" >&6; }
5832
5833file_magic_glob=
5834want_nocaseglob=no
5835if test "$build" = "$host"; then
5836 case $host_os in
5837 mingw* | pw32*)
5838 if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
5839 want_nocaseglob=yes
5840 else
5841 file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
5842 fi
5843 ;;
5844 esac
5845fi
5846
5847file_magic_cmd=$lt_cv_file_magic_cmd
5848deplibs_check_method=$lt_cv_deplibs_check_method
5849test -z "$deplibs_check_method" && deplibs_check_method=unknown
5850
5851
5852
5853
5854
5855
5856
5857
5858
5859
5860
5861
5862
5863
5864
5865
5866
5867
5868
5869
5870
5871
5872if test -n "$ac_tool_prefix"; then
5873 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
5874set dummy ${ac_tool_prefix}dlltool; ac_word=$2
5875{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5876$as_echo_n "checking for $ac_word... " >&6; }
5877if ${ac_cv_prog_DLLTOOL+:} false; then :
5878 $as_echo_n "(cached) " >&6
5879else
5880 if test -n "$DLLTOOL"; then
5881 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
5882else
5883as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5884for as_dir in $PATH
5885do
5886 IFS=$as_save_IFS
5887 test -z "$as_dir" && as_dir=.
5888 for ac_exec_ext in '' $ac_executable_extensions; do
5889 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5890 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
5891 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5892 break 2
5893 fi
5894done
5895 done
5896IFS=$as_save_IFS
5897
5898fi
5899fi
5900DLLTOOL=$ac_cv_prog_DLLTOOL
5901if test -n "$DLLTOOL"; then
5902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
5903$as_echo "$DLLTOOL" >&6; }
5904else
5905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5906$as_echo "no" >&6; }
5907fi
5908
5909
5910fi
5911if test -z "$ac_cv_prog_DLLTOOL"; then
5912 ac_ct_DLLTOOL=$DLLTOOL
5913 # Extract the first word of "dlltool", so it can be a program name with args.
5914set dummy dlltool; ac_word=$2
5915{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5916$as_echo_n "checking for $ac_word... " >&6; }
5917if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
5918 $as_echo_n "(cached) " >&6
5919else
5920 if test -n "$ac_ct_DLLTOOL"; then
5921 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
5922else
5923as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5924for as_dir in $PATH
5925do
5926 IFS=$as_save_IFS
5927 test -z "$as_dir" && as_dir=.
5928 for ac_exec_ext in '' $ac_executable_extensions; do
5929 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5930 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
5931 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5932 break 2
5933 fi
5934done
5935 done
5936IFS=$as_save_IFS
5937
5938fi
5939fi
5940ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
5941if test -n "$ac_ct_DLLTOOL"; then
5942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
5943$as_echo "$ac_ct_DLLTOOL" >&6; }
5944else
5945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5946$as_echo "no" >&6; }
5947fi
5948
5949 if test "x$ac_ct_DLLTOOL" = x; then
5950 DLLTOOL="false"
5951 else
5952 case $cross_compiling:$ac_tool_warned in
5953yes:)
5954{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5955$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5956ac_tool_warned=yes ;;
5957esac
5958 DLLTOOL=$ac_ct_DLLTOOL
5959 fi
5960else
5961 DLLTOOL="$ac_cv_prog_DLLTOOL"
5962fi
5963
5964test -z "$DLLTOOL" && DLLTOOL=dlltool
5965
5966
5967
5968
5969
5970
5971
5972
5973
5974
5975{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
5976$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
5977if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
5978 $as_echo_n "(cached) " >&6
5979else
5980 lt_cv_sharedlib_from_linklib_cmd='unknown'
5981
5982case $host_os in
5983cygwin* | mingw* | pw32* | cegcc*)
5984 # two different shell functions defined in ltmain.sh
5985 # decide which to use based on capabilities of $DLLTOOL
5986 case `$DLLTOOL --help 2>&1` in
5987 *--identify-strict*)
5988 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
5989 ;;
5990 *)
5991 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
5992 ;;
5993 esac
5994 ;;
5995*)
5996 # fallback: assume linklib IS sharedlib
5997 lt_cv_sharedlib_from_linklib_cmd="$ECHO"
5998 ;;
5999esac
6000
6001fi
6002{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
6003$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
6004sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
6005test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
6006
6007
6008
6009
6010
6011
6012
6013
6014if test -n "$ac_tool_prefix"; then
6015 for ac_prog in ar
6016 do
6017 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
6018set dummy $ac_tool_prefix$ac_prog; ac_word=$2
6019{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6020$as_echo_n "checking for $ac_word... " >&6; }
6021if ${ac_cv_prog_AR+:} false; then :
6022 $as_echo_n "(cached) " >&6
6023else
6024 if test -n "$AR"; then
6025 ac_cv_prog_AR="$AR" # Let the user override the test.
6026else
6027as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6028for as_dir in $PATH
6029do
6030 IFS=$as_save_IFS
6031 test -z "$as_dir" && as_dir=.
6032 for ac_exec_ext in '' $ac_executable_extensions; do
6033 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6034 ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
6035 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6036 break 2
6037 fi
6038done
6039 done
6040IFS=$as_save_IFS
6041
6042fi
6043fi
6044AR=$ac_cv_prog_AR
6045if test -n "$AR"; then
6046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6047$as_echo "$AR" >&6; }
6048else
6049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6050$as_echo "no" >&6; }
6051fi
6052
6053
6054 test -n "$AR" && break
6055 done
6056fi
6057if test -z "$AR"; then
6058 ac_ct_AR=$AR
6059 for ac_prog in ar
6060do
6061 # Extract the first word of "$ac_prog", so it can be a program name with args.
6062set dummy $ac_prog; ac_word=$2
6063{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6064$as_echo_n "checking for $ac_word... " >&6; }
6065if ${ac_cv_prog_ac_ct_AR+:} false; then :
6066 $as_echo_n "(cached) " >&6
6067else
6068 if test -n "$ac_ct_AR"; then
6069 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6070else
6071as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6072for as_dir in $PATH
6073do
6074 IFS=$as_save_IFS
6075 test -z "$as_dir" && as_dir=.
6076 for ac_exec_ext in '' $ac_executable_extensions; do
6077 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6078 ac_cv_prog_ac_ct_AR="$ac_prog"
6079 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6080 break 2
6081 fi
6082done
6083 done
6084IFS=$as_save_IFS
6085
6086fi
6087fi
6088ac_ct_AR=$ac_cv_prog_ac_ct_AR
6089if test -n "$ac_ct_AR"; then
6090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6091$as_echo "$ac_ct_AR" >&6; }
6092else
6093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6094$as_echo "no" >&6; }
6095fi
6096
6097
6098 test -n "$ac_ct_AR" && break
6099done
6100
6101 if test "x$ac_ct_AR" = x; then
6102 AR="false"
6103 else
6104 case $cross_compiling:$ac_tool_warned in
6105yes:)
6106{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6107$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6108ac_tool_warned=yes ;;
6109esac
6110 AR=$ac_ct_AR
6111 fi
6112fi
6113
6114: ${AR=ar}
6115: ${AR_FLAGS=cru}
6116
6117
6118
6119
6120
6121
6122
6123
6124
6125
6126
6127{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
6128$as_echo_n "checking for archiver @FILE support... " >&6; }
6129if ${lt_cv_ar_at_file+:} false; then :
6130 $as_echo_n "(cached) " >&6
6131else
6132 lt_cv_ar_at_file=no
6133 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6134/* end confdefs.h. */
6135
6136int
6137main ()
6138{
6139
6140 ;
6141 return 0;
6142}
6143_ACEOF
6144if ac_fn_c_try_compile "$LINENO"; then :
6145 echo conftest.$ac_objext > conftest.lst
6146 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
6147 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
6148 (eval $lt_ar_try) 2>&5
6149 ac_status=$?
6150 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6151 test $ac_status = 0; }
6152 if test "$ac_status" -eq 0; then
6153 # Ensure the archiver fails upon bogus file names.
6154 rm -f conftest.$ac_objext libconftest.a
6155 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
6156 (eval $lt_ar_try) 2>&5
6157 ac_status=$?
6158 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6159 test $ac_status = 0; }
6160 if test "$ac_status" -ne 0; then
6161 lt_cv_ar_at_file=@
6162 fi
6163 fi
6164 rm -f conftest.* libconftest.a
6165
6166fi
6167rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6168
6169fi
6170{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
6171$as_echo "$lt_cv_ar_at_file" >&6; }
6172
6173if test "x$lt_cv_ar_at_file" = xno; then
6174 archiver_list_spec=
6175else
6176 archiver_list_spec=$lt_cv_ar_at_file
6177fi
6178
6179
6180
6181
6182
6183
6184
6185if test -n "$ac_tool_prefix"; then
6186 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6187set dummy ${ac_tool_prefix}strip; ac_word=$2
6188{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6189$as_echo_n "checking for $ac_word... " >&6; }
6190if ${ac_cv_prog_STRIP+:} false; then :
6191 $as_echo_n "(cached) " >&6
6192else
6193 if test -n "$STRIP"; then
6194 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6195else
6196as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6197for as_dir in $PATH
6198do
6199 IFS=$as_save_IFS
6200 test -z "$as_dir" && as_dir=.
6201 for ac_exec_ext in '' $ac_executable_extensions; do
6202 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6203 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6204 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6205 break 2
6206 fi
6207done
6208 done
6209IFS=$as_save_IFS
6210
6211fi
6212fi
6213STRIP=$ac_cv_prog_STRIP
6214if test -n "$STRIP"; then
6215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
6216$as_echo "$STRIP" >&6; }
6217else
6218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6219$as_echo "no" >&6; }
6220fi
6221
6222
6223fi
6224if test -z "$ac_cv_prog_STRIP"; then
6225 ac_ct_STRIP=$STRIP
6226 # Extract the first word of "strip", so it can be a program name with args.
6227set dummy strip; ac_word=$2
6228{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6229$as_echo_n "checking for $ac_word... " >&6; }
6230if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
6231 $as_echo_n "(cached) " >&6
6232else
6233 if test -n "$ac_ct_STRIP"; then
6234 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6235else
6236as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6237for as_dir in $PATH
6238do
6239 IFS=$as_save_IFS
6240 test -z "$as_dir" && as_dir=.
6241 for ac_exec_ext in '' $ac_executable_extensions; do
6242 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6243 ac_cv_prog_ac_ct_STRIP="strip"
6244 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6245 break 2
6246 fi
6247done
6248 done
6249IFS=$as_save_IFS
6250
6251fi
6252fi
6253ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6254if test -n "$ac_ct_STRIP"; then
6255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
6256$as_echo "$ac_ct_STRIP" >&6; }
6257else
6258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6259$as_echo "no" >&6; }
6260fi
6261
6262 if test "x$ac_ct_STRIP" = x; then
6263 STRIP=":"
6264 else
6265 case $cross_compiling:$ac_tool_warned in
6266yes:)
6267{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6268$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6269ac_tool_warned=yes ;;
6270esac
6271 STRIP=$ac_ct_STRIP
6272 fi
6273else
6274 STRIP="$ac_cv_prog_STRIP"
6275fi
6276
6277test -z "$STRIP" && STRIP=:
6278
6279
6280
6281
6282
6283
6284if test -n "$ac_tool_prefix"; then
6285 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6286set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6287{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6288$as_echo_n "checking for $ac_word... " >&6; }
6289if ${ac_cv_prog_RANLIB+:} false; then :
6290 $as_echo_n "(cached) " >&6
6291else
6292 if test -n "$RANLIB"; then
6293 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6294else
6295as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6296for as_dir in $PATH
6297do
6298 IFS=$as_save_IFS
6299 test -z "$as_dir" && as_dir=.
6300 for ac_exec_ext in '' $ac_executable_extensions; do
6301 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6302 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6303 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6304 break 2
6305 fi
6306done
6307 done
6308IFS=$as_save_IFS
6309
6310fi
6311fi
6312RANLIB=$ac_cv_prog_RANLIB
6313if test -n "$RANLIB"; then
6314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6315$as_echo "$RANLIB" >&6; }
6316else
6317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6318$as_echo "no" >&6; }
6319fi
6320
6321
6322fi
6323if test -z "$ac_cv_prog_RANLIB"; then
6324 ac_ct_RANLIB=$RANLIB
6325 # Extract the first word of "ranlib", so it can be a program name with args.
6326set dummy ranlib; ac_word=$2
6327{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6328$as_echo_n "checking for $ac_word... " >&6; }
6329if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
6330 $as_echo_n "(cached) " >&6
6331else
6332 if test -n "$ac_ct_RANLIB"; then
6333 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6334else
6335as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6336for as_dir in $PATH
6337do
6338 IFS=$as_save_IFS
6339 test -z "$as_dir" && as_dir=.
6340 for ac_exec_ext in '' $ac_executable_extensions; do
6341 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6342 ac_cv_prog_ac_ct_RANLIB="ranlib"
6343 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6344 break 2
6345 fi
6346done
6347 done
6348IFS=$as_save_IFS
6349
6350fi
6351fi
6352ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6353if test -n "$ac_ct_RANLIB"; then
6354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6355$as_echo "$ac_ct_RANLIB" >&6; }
6356else
6357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6358$as_echo "no" >&6; }
6359fi
6360
6361 if test "x$ac_ct_RANLIB" = x; then
6362 RANLIB=":"
6363 else
6364 case $cross_compiling:$ac_tool_warned in
6365yes:)
6366{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6367$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6368ac_tool_warned=yes ;;
6369esac
6370 RANLIB=$ac_ct_RANLIB
6371 fi
6372else
6373 RANLIB="$ac_cv_prog_RANLIB"
6374fi
6375
6376test -z "$RANLIB" && RANLIB=:
6377
6378
6379
6380
6381
6382
6383# Determine commands to create old-style static archives.
6384old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
6385old_postinstall_cmds='chmod 644 $oldlib'
6386old_postuninstall_cmds=
6387
6388if test -n "$RANLIB"; then
6389 case $host_os in
6390 openbsd*)
6391 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
6392 ;;
6393 *)
6394 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
6395 ;;
6396 esac
6397 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
6398fi
6399
6400case $host_os in
6401 darwin*)
6402 lock_old_archive_extraction=yes ;;
6403 *)
6404 lock_old_archive_extraction=no ;;
6405esac
6406
6407
6408
6409
6410
6411
6412
6413
6414
6415
6416
6417
6418
6419
6420
6421
6422
6423
6424
6425
6426
6427
6428
6429
6430
6431
6432
6433
6434
6435
6436
6437
6438
6439
6440
6441
6442
6443
6444
6445# If no C compiler was specified, use CC.
6446LTCC=${LTCC-"$CC"}
6447
6448# If no C compiler flags were specified, use CFLAGS.
6449LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
6450
6451# Allow CC to be a program name with arguments.
6452compiler=$CC
6453
6454
6455# Check for command to grab the raw symbol name followed by C symbol from nm.
6456{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
6457$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
6458if ${lt_cv_sys_global_symbol_pipe+:} false; then :
6459 $as_echo_n "(cached) " >&6
6460else
6461
6462# These are sane defaults that work on at least a few old systems.
6463# [They come from Ultrix. What could be older than Ultrix?!! ;)]
6464
6465# Character class describing NM global symbol codes.
6466symcode='[BCDEGRST]'
6467
6468# Regexp to match symbols that can be accessed directly from C.
6469sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
6470
6471# Define system-specific variables.
6472case $host_os in
6473aix*)
6474 symcode='[BCDT]'
6475 ;;
6476cygwin* | mingw* | pw32* | cegcc*)
6477 symcode='[ABCDGISTW]'
6478 ;;
6479hpux*)
6480 if test "$host_cpu" = ia64; then
6481 symcode='[ABCDEGRST]'
6482 fi
6483 ;;
6484irix* | nonstopux*)
6485 symcode='[BCDEGRST]'
6486 ;;
6487osf*)
6488 symcode='[BCDEGQRST]'
6489 ;;
6490solaris*)
6491 symcode='[BDRT]'
6492 ;;
6493sco3.2v5*)
6494 symcode='[DT]'
6495 ;;
6496sysv4.2uw2*)
6497 symcode='[DT]'
6498 ;;
6499sysv5* | sco5v6* | unixware* | OpenUNIX*)
6500 symcode='[ABDT]'
6501 ;;
6502sysv4)
6503 symcode='[DFNSTU]'
6504 ;;
6505esac
6506
6507# If we're using GNU nm, then use its standard symbol codes.
6508case `$NM -V 2>&1` in
6509*GNU* | *'with BFD'*)
6510 symcode='[ABCDGIRSTW]' ;;
6511esac
6512
6513# Transform an extracted symbol line into a proper C declaration.
6514# Some systems (esp. on ia64) link data and code symbols differently,
6515# so use this general approach.
6516lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
6517
6518# Transform an extracted symbol line into symbol name and symbol address
6519lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
6520lt_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'"
6521
6522# Handle CRLF in mingw tool chain
6523opt_cr=
6524case $build_os in
6525mingw*)
6526 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
6527 ;;
6528esac
6529
6530# Try without a prefix underscore, then with it.
6531for ac_symprfx in "" "_"; do
6532
6533 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
6534 symxfrm="\\1 $ac_symprfx\\2 \\2"
6535
6536 # Write the raw and C identifiers.
6537 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
6538 # Fake it for dumpbin and say T for any non-static function
6539 # and D for any global variable.
6540 # Also find C++ and __fastcall symbols from MSVC++,
6541 # which start with @ or ?.
6542 lt_cv_sys_global_symbol_pipe="$AWK '"\
6543" {last_section=section; section=\$ 3};"\
6544" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
6545" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
6546" \$ 0!~/External *\|/{next};"\
6547" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
6548" {if(hide[section]) next};"\
6549" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
6550" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
6551" s[1]~/^[@?]/{print s[1], s[1]; next};"\
6552" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
6553" ' prfx=^$ac_symprfx"
6554 else
6555 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
6556 fi
6557 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
6558
6559 # Check to see that the pipe works correctly.
6560 pipe_works=no
6561
6562 rm -f conftest*
6563 cat > conftest.$ac_ext <<_LT_EOF
6564#ifdef __cplusplus
6565extern "C" {
6566#endif
6567char nm_test_var;
6568void nm_test_func(void);
6569void nm_test_func(void){}
6570#ifdef __cplusplus
6571}
6572#endif
6573int main(){nm_test_var='a';nm_test_func();return(0);}
6574_LT_EOF
6575
6576 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
6577 (eval $ac_compile) 2>&5
6578 ac_status=$?
6579 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6580 test $ac_status = 0; }; then
6581 # Now try to grab the symbols.
6582 nlist=conftest.nm
6583 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
6584 (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
6585 ac_status=$?
6586 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6587 test $ac_status = 0; } && test -s "$nlist"; then
6588 # Try sorting and uniquifying the output.
6589 if sort "$nlist" | uniq > "$nlist"T; then
6590 mv -f "$nlist"T "$nlist"
6591 else
6592 rm -f "$nlist"T
6593 fi
6594
6595 # Make sure that we snagged all the symbols we need.
6596 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
6597 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
6598 cat <<_LT_EOF > conftest.$ac_ext
6599/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
6600#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
6601/* DATA imports from DLLs on WIN32 con't be const, because runtime
6602 relocations are performed -- see ld's documentation on pseudo-relocs. */
6603# define LT_DLSYM_CONST
6604#elif defined(__osf__)
6605/* This system does not cope well with relocations in const data. */
6606# define LT_DLSYM_CONST
6607#else
6608# define LT_DLSYM_CONST const
6609#endif
6610
6611#ifdef __cplusplus
6612extern "C" {
6613#endif
6614
6615_LT_EOF
6616 # Now generate the symbol file.
6617 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
6618
6619 cat <<_LT_EOF >> conftest.$ac_ext
6620
6621/* The mapping between symbol names and symbols. */
6622LT_DLSYM_CONST struct {
6623 const char *name;
6624 void *address;
6625}
6626lt__PROGRAM__LTX_preloaded_symbols[] =
6627{
6628 { "@PROGRAM@", (void *) 0 },
6629_LT_EOF
6630 $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
6631 cat <<\_LT_EOF >> conftest.$ac_ext
6632 {0, (void *) 0}
6633};
6634
6635/* This works around a problem in FreeBSD linker */
6636#ifdef FREEBSD_WORKAROUND
6637static const void *lt_preloaded_setup() {
6638 return lt__PROGRAM__LTX_preloaded_symbols;
6639}
6640#endif
6641
6642#ifdef __cplusplus
6643}
6644#endif
6645_LT_EOF
6646 # Now try linking the two files.
6647 mv conftest.$ac_objext conftstm.$ac_objext
6648 lt_globsym_save_LIBS=$LIBS
6649 lt_globsym_save_CFLAGS=$CFLAGS
6650 LIBS="conftstm.$ac_objext"
6651 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
6652 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
6653 (eval $ac_link) 2>&5
6654 ac_status=$?
6655 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6656 test $ac_status = 0; } && test -s conftest${ac_exeext}; then
6657 pipe_works=yes
6658 fi
6659 LIBS=$lt_globsym_save_LIBS
6660 CFLAGS=$lt_globsym_save_CFLAGS
6661 else
6662 echo "cannot find nm_test_func in $nlist" >&5
6663 fi
6664 else
6665 echo "cannot find nm_test_var in $nlist" >&5
6666 fi
6667 else
6668 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
6669 fi
6670 else
6671 echo "$progname: failed program was:" >&5
6672 cat conftest.$ac_ext >&5
6673 fi
6674 rm -rf conftest* conftst*
6675
6676 # Do not use the global_symbol_pipe unless it works.
6677 if test "$pipe_works" = yes; then
6678 break
6679 else
6680 lt_cv_sys_global_symbol_pipe=
6681 fi
6682done
6683
6684fi
6685
6686if test -z "$lt_cv_sys_global_symbol_pipe"; then
6687 lt_cv_sys_global_symbol_to_cdecl=
6688fi
6689if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
6690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
6691$as_echo "failed" >&6; }
6692else
6693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
6694$as_echo "ok" >&6; }
6695fi
6696
6697# Response file support.
6698if test "$lt_cv_nm_interface" = "MS dumpbin"; then
6699 nm_file_list_spec='@'
6700elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
6701 nm_file_list_spec='@'
6702fi
6703
6704
6705
6706
6707
6708
6709
6710
6711
6712
6713
6714
6715
6716
6717
6718
6719
6720
6721
6722
6723
6724
6725
6726
6727
6728
6729
6730{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
6731$as_echo_n "checking for sysroot... " >&6; }
6732
6733# Check whether --with-sysroot was given.
6734if test "${with_sysroot+set}" = set; then :
6735 withval=$with_sysroot;
6736else
6737 with_sysroot=no
6738fi
6739
6740
6741lt_sysroot=
6742case ${with_sysroot} in #(
6743 yes)
6744 if test "$GCC" = yes; then
6745 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
6746 fi
6747 ;; #(
6748 /*)
6749 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
6750 ;; #(
6751 no|'')
6752 ;; #(
6753 *)
6754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5
6755$as_echo "${with_sysroot}" >&6; }
6756 as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
6757 ;;
6758esac
6759
6760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
6761$as_echo "${lt_sysroot:-no}" >&6; }
6762
6763
6764
6765
6766
6767# Check whether --enable-libtool-lock was given.
6768if test "${enable_libtool_lock+set}" = set; then :
6769 enableval=$enable_libtool_lock;
6770fi
6771
6772test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
6773
6774# Some flags need to be propagated to the compiler or linker for good
6775# libtool support.
6776case $host in
6777ia64-*-hpux*)
6778 # Find out which ABI we are using.
6779 echo 'int i;' > conftest.$ac_ext
6780 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
6781 (eval $ac_compile) 2>&5
6782 ac_status=$?
6783 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6784 test $ac_status = 0; }; then
6785 case `/usr/bin/file conftest.$ac_objext` in
6786 *ELF-32*)
6787 HPUX_IA64_MODE="32"
6788 ;;
6789 *ELF-64*)
6790 HPUX_IA64_MODE="64"
6791 ;;
6792 esac
6793 fi
6794 rm -rf conftest*
6795 ;;
6796*-*-irix6*)
6797 # Find out which ABI we are using.
6798 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
6799 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
6800 (eval $ac_compile) 2>&5
6801 ac_status=$?
6802 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6803 test $ac_status = 0; }; then
6804 if test "$lt_cv_prog_gnu_ld" = yes; then
6805 case `/usr/bin/file conftest.$ac_objext` in
6806 *32-bit*)
6807 LD="${LD-ld} -melf32bsmip"
6808 ;;
6809 *N32*)
6810 LD="${LD-ld} -melf32bmipn32"
6811 ;;
6812 *64-bit*)
6813 LD="${LD-ld} -melf64bmip"
6814 ;;
6815 esac
6816 else
6817 case `/usr/bin/file conftest.$ac_objext` in
6818 *32-bit*)
6819 LD="${LD-ld} -32"
6820 ;;
6821 *N32*)
6822 LD="${LD-ld} -n32"
6823 ;;
6824 *64-bit*)
6825 LD="${LD-ld} -64"
6826 ;;
6827 esac
6828 fi
6829 fi
6830 rm -rf conftest*
6831 ;;
6832
6833x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
6834s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
6835 # Find out which ABI we are using.
6836 echo 'int i;' > conftest.$ac_ext
6837 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
6838 (eval $ac_compile) 2>&5
6839 ac_status=$?
6840 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6841 test $ac_status = 0; }; then
6842 case `/usr/bin/file conftest.o` in
6843 *32-bit*)
6844 case $host in
6845 x86_64-*kfreebsd*-gnu)
6846 LD="${LD-ld} -m elf_i386_fbsd"
6847 ;;
6848 x86_64-*linux*)
6849 LD="${LD-ld} -m elf_i386"
6850 ;;
6851 ppc64-*linux*|powerpc64-*linux*)
6852 LD="${LD-ld} -m elf32ppclinux"
6853 ;;
6854 s390x-*linux*)
6855 LD="${LD-ld} -m elf_s390"
6856 ;;
6857 sparc64-*linux*)
6858 LD="${LD-ld} -m elf32_sparc"
6859 ;;
6860 esac
6861 ;;
6862 *64-bit*)
6863 case $host in
6864 x86_64-*kfreebsd*-gnu)
6865 LD="${LD-ld} -m elf_x86_64_fbsd"
6866 ;;
6867 x86_64-*linux*)
6868 LD="${LD-ld} -m elf_x86_64"
6869 ;;
6870 ppc*-*linux*|powerpc*-*linux*)
6871 LD="${LD-ld} -m elf64ppc"
6872 ;;
6873 s390*-*linux*|s390*-*tpf*)
6874 LD="${LD-ld} -m elf64_s390"
6875 ;;
6876 sparc*-*linux*)
6877 LD="${LD-ld} -m elf64_sparc"
6878 ;;
6879 esac
6880 ;;
6881 esac
6882 fi
6883 rm -rf conftest*
6884 ;;
6885
6886*-*-sco3.2v5*)
6887 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
6888 SAVE_CFLAGS="$CFLAGS"
6889 CFLAGS="$CFLAGS -belf"
6890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
6891$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
6892if ${lt_cv_cc_needs_belf+:} false; then :
6893 $as_echo_n "(cached) " >&6
6894else
6895 ac_ext=c
6896ac_cpp='$CPP $CPPFLAGS'
6897ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6898ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6899ac_compiler_gnu=$ac_cv_c_compiler_gnu
6900
6901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6902/* end confdefs.h. */
6903
6904int
6905main ()
6906{
6907
6908 ;
6909 return 0;
6910}
6911_ACEOF
6912if ac_fn_c_try_link "$LINENO"; then :
6913 lt_cv_cc_needs_belf=yes
6914else
6915 lt_cv_cc_needs_belf=no
6916fi
6917rm -f core conftest.err conftest.$ac_objext \
6918 conftest$ac_exeext conftest.$ac_ext
6919 ac_ext=c
6920ac_cpp='$CPP $CPPFLAGS'
6921ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6922ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6923ac_compiler_gnu=$ac_cv_c_compiler_gnu
6924
6925fi
6926{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
6927$as_echo "$lt_cv_cc_needs_belf" >&6; }
6928 if test x"$lt_cv_cc_needs_belf" != x"yes"; then
6929 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
6930 CFLAGS="$SAVE_CFLAGS"
6931 fi
6932 ;;
6933*-*solaris*)
6934 # Find out which ABI we are using.
6935 echo 'int i;' > conftest.$ac_ext
6936 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
6937 (eval $ac_compile) 2>&5
6938 ac_status=$?
6939 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6940 test $ac_status = 0; }; then
6941 case `/usr/bin/file conftest.o` in
6942 *64-bit*)
6943 case $lt_cv_prog_gnu_ld in
6944 yes*)
6945 case $host in
6946 i?86-*-solaris*)
6947 LD="${LD-ld} -m elf_x86_64"
6948 ;;
6949 sparc*-*-solaris*)
6950 LD="${LD-ld} -m elf64_sparc"
6951 ;;
6952 esac
6953 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
6954 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
6955 LD="${LD-ld}_sol2"
6956 fi
6957 ;;
6958 *)
6959 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
6960 LD="${LD-ld} -64"
6961 fi
6962 ;;
6963 esac
6964 ;;
6965 esac
6966 fi
6967 rm -rf conftest*
6968 ;;
6969esac
6970
6971need_locks="$enable_libtool_lock"
6972
6973if test -n "$ac_tool_prefix"; then
6974 # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
6975set dummy ${ac_tool_prefix}mt; ac_word=$2
6976{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6977$as_echo_n "checking for $ac_word... " >&6; }
6978if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
6979 $as_echo_n "(cached) " >&6
6980else
6981 if test -n "$MANIFEST_TOOL"; then
6982 ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
6983else
6984as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6985for as_dir in $PATH
6986do
6987 IFS=$as_save_IFS
6988 test -z "$as_dir" && as_dir=.
6989 for ac_exec_ext in '' $ac_executable_extensions; do
6990 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6991 ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
6992 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6993 break 2
6994 fi
6995done
6996 done
6997IFS=$as_save_IFS
6998
6999fi
7000fi
7001MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
7002if test -n "$MANIFEST_TOOL"; then
7003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
7004$as_echo "$MANIFEST_TOOL" >&6; }
7005else
7006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7007$as_echo "no" >&6; }
7008fi
7009
7010
7011fi
7012if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
7013 ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
7014 # Extract the first word of "mt", so it can be a program name with args.
7015set dummy mt; ac_word=$2
7016{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7017$as_echo_n "checking for $ac_word... " >&6; }
7018if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
7019 $as_echo_n "(cached) " >&6
7020else
7021 if test -n "$ac_ct_MANIFEST_TOOL"; then
7022 ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
7023else
7024as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7025for as_dir in $PATH
7026do
7027 IFS=$as_save_IFS
7028 test -z "$as_dir" && as_dir=.
7029 for ac_exec_ext in '' $ac_executable_extensions; do
7030 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7031 ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
7032 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7033 break 2
7034 fi
7035done
7036 done
7037IFS=$as_save_IFS
7038
7039fi
7040fi
7041ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
7042if test -n "$ac_ct_MANIFEST_TOOL"; then
7043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
7044$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
7045else
7046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7047$as_echo "no" >&6; }
7048fi
7049
7050 if test "x$ac_ct_MANIFEST_TOOL" = x; then
7051 MANIFEST_TOOL=":"
7052 else
7053 case $cross_compiling:$ac_tool_warned in
7054yes:)
7055{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7056$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7057ac_tool_warned=yes ;;
7058esac
7059 MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
7060 fi
7061else
7062 MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
7063fi
7064
7065test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
7066{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
7067$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
7068if ${lt_cv_path_mainfest_tool+:} false; then :
7069 $as_echo_n "(cached) " >&6
7070else
7071 lt_cv_path_mainfest_tool=no
7072 echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
7073 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
7074 cat conftest.err >&5
7075 if $GREP 'Manifest Tool' conftest.out > /dev/null; then
7076 lt_cv_path_mainfest_tool=yes
7077 fi
7078 rm -f conftest*
7079fi
7080{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
7081$as_echo "$lt_cv_path_mainfest_tool" >&6; }
7082if test "x$lt_cv_path_mainfest_tool" != xyes; then
7083 MANIFEST_TOOL=:
7084fi
7085
7086
7087
7088
7089
7090
7091 case $host_os in
7092 rhapsody* | darwin*)
7093 if test -n "$ac_tool_prefix"; then
7094 # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
7095set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
7096{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7097$as_echo_n "checking for $ac_word... " >&6; }
7098if ${ac_cv_prog_DSYMUTIL+:} false; then :
7099 $as_echo_n "(cached) " >&6
7100else
7101 if test -n "$DSYMUTIL"; then
7102 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
7103else
7104as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7105for as_dir in $PATH
7106do
7107 IFS=$as_save_IFS
7108 test -z "$as_dir" && as_dir=.
7109 for ac_exec_ext in '' $ac_executable_extensions; do
7110 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7111 ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
7112 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7113 break 2
7114 fi
7115done
7116 done
7117IFS=$as_save_IFS
7118
7119fi
7120fi
7121DSYMUTIL=$ac_cv_prog_DSYMUTIL
7122if test -n "$DSYMUTIL"; then
7123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
7124$as_echo "$DSYMUTIL" >&6; }
7125else
7126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7127$as_echo "no" >&6; }
7128fi
7129
7130
7131fi
7132if test -z "$ac_cv_prog_DSYMUTIL"; then
7133 ac_ct_DSYMUTIL=$DSYMUTIL
7134 # Extract the first word of "dsymutil", so it can be a program name with args.
7135set dummy dsymutil; ac_word=$2
7136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7137$as_echo_n "checking for $ac_word... " >&6; }
7138if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
7139 $as_echo_n "(cached) " >&6
7140else
7141 if test -n "$ac_ct_DSYMUTIL"; then
7142 ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
7143else
7144as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7145for as_dir in $PATH
7146do
7147 IFS=$as_save_IFS
7148 test -z "$as_dir" && as_dir=.
7149 for ac_exec_ext in '' $ac_executable_extensions; do
7150 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7151 ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
7152 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7153 break 2
7154 fi
7155done
7156 done
7157IFS=$as_save_IFS
7158
7159fi
7160fi
7161ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
7162if test -n "$ac_ct_DSYMUTIL"; then
7163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
7164$as_echo "$ac_ct_DSYMUTIL" >&6; }
7165else
7166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7167$as_echo "no" >&6; }
7168fi
7169
7170 if test "x$ac_ct_DSYMUTIL" = x; then
7171 DSYMUTIL=":"
7172 else
7173 case $cross_compiling:$ac_tool_warned in
7174yes:)
7175{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7176$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7177ac_tool_warned=yes ;;
7178esac
7179 DSYMUTIL=$ac_ct_DSYMUTIL
7180 fi
7181else
7182 DSYMUTIL="$ac_cv_prog_DSYMUTIL"
7183fi
7184
7185 if test -n "$ac_tool_prefix"; then
7186 # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
7187set dummy ${ac_tool_prefix}nmedit; ac_word=$2
7188{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7189$as_echo_n "checking for $ac_word... " >&6; }
7190if ${ac_cv_prog_NMEDIT+:} false; then :
7191 $as_echo_n "(cached) " >&6
7192else
7193 if test -n "$NMEDIT"; then
7194 ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
7195else
7196as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7197for as_dir in $PATH
7198do
7199 IFS=$as_save_IFS
7200 test -z "$as_dir" && as_dir=.
7201 for ac_exec_ext in '' $ac_executable_extensions; do
7202 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7203 ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
7204 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7205 break 2
7206 fi
7207done
7208 done
7209IFS=$as_save_IFS
7210
7211fi
7212fi
7213NMEDIT=$ac_cv_prog_NMEDIT
7214if test -n "$NMEDIT"; then
7215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
7216$as_echo "$NMEDIT" >&6; }
7217else
7218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7219$as_echo "no" >&6; }
7220fi
7221
7222
7223fi
7224if test -z "$ac_cv_prog_NMEDIT"; then
7225 ac_ct_NMEDIT=$NMEDIT
7226 # Extract the first word of "nmedit", so it can be a program name with args.
7227set dummy nmedit; ac_word=$2
7228{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7229$as_echo_n "checking for $ac_word... " >&6; }
7230if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
7231 $as_echo_n "(cached) " >&6
7232else
7233 if test -n "$ac_ct_NMEDIT"; then
7234 ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
7235else
7236as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7237for as_dir in $PATH
7238do
7239 IFS=$as_save_IFS
7240 test -z "$as_dir" && as_dir=.
7241 for ac_exec_ext in '' $ac_executable_extensions; do
7242 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7243 ac_cv_prog_ac_ct_NMEDIT="nmedit"
7244 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7245 break 2
7246 fi
7247done
7248 done
7249IFS=$as_save_IFS
7250
7251fi
7252fi
7253ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
7254if test -n "$ac_ct_NMEDIT"; then
7255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
7256$as_echo "$ac_ct_NMEDIT" >&6; }
7257else
7258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7259$as_echo "no" >&6; }
7260fi
7261
7262 if test "x$ac_ct_NMEDIT" = x; then
7263 NMEDIT=":"
7264 else
7265 case $cross_compiling:$ac_tool_warned in
7266yes:)
7267{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7268$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7269ac_tool_warned=yes ;;
7270esac
7271 NMEDIT=$ac_ct_NMEDIT
7272 fi
7273else
7274 NMEDIT="$ac_cv_prog_NMEDIT"
7275fi
7276
7277 if test -n "$ac_tool_prefix"; then
7278 # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
7279set dummy ${ac_tool_prefix}lipo; ac_word=$2
7280{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7281$as_echo_n "checking for $ac_word... " >&6; }
7282if ${ac_cv_prog_LIPO+:} false; then :
7283 $as_echo_n "(cached) " >&6
7284else
7285 if test -n "$LIPO"; then
7286 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
7287else
7288as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7289for as_dir in $PATH
7290do
7291 IFS=$as_save_IFS
7292 test -z "$as_dir" && as_dir=.
7293 for ac_exec_ext in '' $ac_executable_extensions; do
7294 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7295 ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
7296 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7297 break 2
7298 fi
7299done
7300 done
7301IFS=$as_save_IFS
7302
7303fi
7304fi
7305LIPO=$ac_cv_prog_LIPO
7306if test -n "$LIPO"; then
7307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
7308$as_echo "$LIPO" >&6; }
7309else
7310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7311$as_echo "no" >&6; }
7312fi
7313
7314
7315fi
7316if test -z "$ac_cv_prog_LIPO"; then
7317 ac_ct_LIPO=$LIPO
7318 # Extract the first word of "lipo", so it can be a program name with args.
7319set dummy lipo; ac_word=$2
7320{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7321$as_echo_n "checking for $ac_word... " >&6; }
7322if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
7323 $as_echo_n "(cached) " >&6
7324else
7325 if test -n "$ac_ct_LIPO"; then
7326 ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
7327else
7328as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7329for as_dir in $PATH
7330do
7331 IFS=$as_save_IFS
7332 test -z "$as_dir" && as_dir=.
7333 for ac_exec_ext in '' $ac_executable_extensions; do
7334 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7335 ac_cv_prog_ac_ct_LIPO="lipo"
7336 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7337 break 2
7338 fi
7339done
7340 done
7341IFS=$as_save_IFS
7342
7343fi
7344fi
7345ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
7346if test -n "$ac_ct_LIPO"; then
7347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
7348$as_echo "$ac_ct_LIPO" >&6; }
7349else
7350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7351$as_echo "no" >&6; }
7352fi
7353
7354 if test "x$ac_ct_LIPO" = x; then
7355 LIPO=":"
7356 else
7357 case $cross_compiling:$ac_tool_warned in
7358yes:)
7359{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7360$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7361ac_tool_warned=yes ;;
7362esac
7363 LIPO=$ac_ct_LIPO
7364 fi
7365else
7366 LIPO="$ac_cv_prog_LIPO"
7367fi
7368
7369 if test -n "$ac_tool_prefix"; then
7370 # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
7371set dummy ${ac_tool_prefix}otool; ac_word=$2
7372{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7373$as_echo_n "checking for $ac_word... " >&6; }
7374if ${ac_cv_prog_OTOOL+:} false; then :
7375 $as_echo_n "(cached) " >&6
7376else
7377 if test -n "$OTOOL"; then
7378 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
7379else
7380as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7381for as_dir in $PATH
7382do
7383 IFS=$as_save_IFS
7384 test -z "$as_dir" && as_dir=.
7385 for ac_exec_ext in '' $ac_executable_extensions; do
7386 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7387 ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
7388 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7389 break 2
7390 fi
7391done
7392 done
7393IFS=$as_save_IFS
7394
7395fi
7396fi
7397OTOOL=$ac_cv_prog_OTOOL
7398if test -n "$OTOOL"; then
7399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
7400$as_echo "$OTOOL" >&6; }
7401else
7402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7403$as_echo "no" >&6; }
7404fi
7405
7406
7407fi
7408if test -z "$ac_cv_prog_OTOOL"; then
7409 ac_ct_OTOOL=$OTOOL
7410 # Extract the first word of "otool", so it can be a program name with args.
7411set dummy otool; ac_word=$2
7412{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7413$as_echo_n "checking for $ac_word... " >&6; }
7414if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
7415 $as_echo_n "(cached) " >&6
7416else
7417 if test -n "$ac_ct_OTOOL"; then
7418 ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
7419else
7420as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7421for as_dir in $PATH
7422do
7423 IFS=$as_save_IFS
7424 test -z "$as_dir" && as_dir=.
7425 for ac_exec_ext in '' $ac_executable_extensions; do
7426 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7427 ac_cv_prog_ac_ct_OTOOL="otool"
7428 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7429 break 2
7430 fi
7431done
7432 done
7433IFS=$as_save_IFS
7434
7435fi
7436fi
7437ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
7438if test -n "$ac_ct_OTOOL"; then
7439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
7440$as_echo "$ac_ct_OTOOL" >&6; }
7441else
7442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7443$as_echo "no" >&6; }
7444fi
7445
7446 if test "x$ac_ct_OTOOL" = x; then
7447 OTOOL=":"
7448 else
7449 case $cross_compiling:$ac_tool_warned in
7450yes:)
7451{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7452$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7453ac_tool_warned=yes ;;
7454esac
7455 OTOOL=$ac_ct_OTOOL
7456 fi
7457else
7458 OTOOL="$ac_cv_prog_OTOOL"
7459fi
7460
7461 if test -n "$ac_tool_prefix"; then
7462 # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
7463set dummy ${ac_tool_prefix}otool64; ac_word=$2
7464{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7465$as_echo_n "checking for $ac_word... " >&6; }
7466if ${ac_cv_prog_OTOOL64+:} false; then :
7467 $as_echo_n "(cached) " >&6
7468else
7469 if test -n "$OTOOL64"; then
7470 ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
7471else
7472as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7473for as_dir in $PATH
7474do
7475 IFS=$as_save_IFS
7476 test -z "$as_dir" && as_dir=.
7477 for ac_exec_ext in '' $ac_executable_extensions; do
7478 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7479 ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
7480 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7481 break 2
7482 fi
7483done
7484 done
7485IFS=$as_save_IFS
7486
7487fi
7488fi
7489OTOOL64=$ac_cv_prog_OTOOL64
7490if test -n "$OTOOL64"; then
7491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
7492$as_echo "$OTOOL64" >&6; }
7493else
7494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7495$as_echo "no" >&6; }
7496fi
7497
7498
7499fi
7500if test -z "$ac_cv_prog_OTOOL64"; then
7501 ac_ct_OTOOL64=$OTOOL64
7502 # Extract the first word of "otool64", so it can be a program name with args.
7503set dummy otool64; ac_word=$2
7504{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7505$as_echo_n "checking for $ac_word... " >&6; }
7506if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
7507 $as_echo_n "(cached) " >&6
7508else
7509 if test -n "$ac_ct_OTOOL64"; then
7510 ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
7511else
7512as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7513for as_dir in $PATH
7514do
7515 IFS=$as_save_IFS
7516 test -z "$as_dir" && as_dir=.
7517 for ac_exec_ext in '' $ac_executable_extensions; do
7518 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7519 ac_cv_prog_ac_ct_OTOOL64="otool64"
7520 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7521 break 2
7522 fi
7523done
7524 done
7525IFS=$as_save_IFS
7526
7527fi
7528fi
7529ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
7530if test -n "$ac_ct_OTOOL64"; then
7531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
7532$as_echo "$ac_ct_OTOOL64" >&6; }
7533else
7534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7535$as_echo "no" >&6; }
7536fi
7537
7538 if test "x$ac_ct_OTOOL64" = x; then
7539 OTOOL64=":"
7540 else
7541 case $cross_compiling:$ac_tool_warned in
7542yes:)
7543{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7544$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7545ac_tool_warned=yes ;;
7546esac
7547 OTOOL64=$ac_ct_OTOOL64
7548 fi
7549else
7550 OTOOL64="$ac_cv_prog_OTOOL64"
7551fi
7552
7553
7554
7555
7556
7557
7558
7559
7560
7561
7562
7563
7564
7565
7566
7567
7568
7569
7570
7571
7572
7573
7574
7575
7576
7577
7578
7579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
7580$as_echo_n "checking for -single_module linker flag... " >&6; }
7581if ${lt_cv_apple_cc_single_mod+:} false; then :
7582 $as_echo_n "(cached) " >&6
7583else
7584 lt_cv_apple_cc_single_mod=no
7585 if test -z "${LT_MULTI_MODULE}"; then
7586 # By default we will add the -single_module flag. You can override
7587 # by either setting the environment variable LT_MULTI_MODULE
7588 # non-empty at configure time, or by adding -multi_module to the
7589 # link flags.
7590 rm -rf libconftest.dylib*
7591 echo "int foo(void){return 1;}" > conftest.c
7592 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
7593-dynamiclib -Wl,-single_module conftest.c" >&5
7594 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
7595 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
7596 _lt_result=$?
7597 # If there is a non-empty error log, and "single_module"
7598 # appears in it, assume the flag caused a linker warning
7599 if test -s conftest.err && $GREP single_module conftest.err; then
7600 cat conftest.err >&5
7601 # Otherwise, if the output was created with a 0 exit code from
7602 # the compiler, it worked.
7603 elif test -f libconftest.dylib && test $_lt_result -eq 0; then
7604 lt_cv_apple_cc_single_mod=yes
7605 else
7606 cat conftest.err >&5
7607 fi
7608 rm -rf libconftest.dylib*
7609 rm -f conftest.*
7610 fi
7611fi
7612{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
7613$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
7614
7615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
7616$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
7617if ${lt_cv_ld_exported_symbols_list+:} false; then :
7618 $as_echo_n "(cached) " >&6
7619else
7620 lt_cv_ld_exported_symbols_list=no
7621 save_LDFLAGS=$LDFLAGS
7622 echo "_main" > conftest.sym
7623 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
7624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7625/* end confdefs.h. */
7626
7627int
7628main ()
7629{
7630
7631 ;
7632 return 0;
7633}
7634_ACEOF
7635if ac_fn_c_try_link "$LINENO"; then :
7636 lt_cv_ld_exported_symbols_list=yes
7637else
7638 lt_cv_ld_exported_symbols_list=no
7639fi
7640rm -f core conftest.err conftest.$ac_objext \
7641 conftest$ac_exeext conftest.$ac_ext
7642 LDFLAGS="$save_LDFLAGS"
7643
7644fi
7645{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
7646$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
7647
7648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
7649$as_echo_n "checking for -force_load linker flag... " >&6; }
7650if ${lt_cv_ld_force_load+:} false; then :
7651 $as_echo_n "(cached) " >&6
7652else
7653 lt_cv_ld_force_load=no
7654 cat > conftest.c << _LT_EOF
7655int forced_loaded() { return 2;}
7656_LT_EOF
7657 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
7658 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
7659 echo "$AR cru libconftest.a conftest.o" >&5
7660 $AR cru libconftest.a conftest.o 2>&5
7661 echo "$RANLIB libconftest.a" >&5
7662 $RANLIB libconftest.a 2>&5
7663 cat > conftest.c << _LT_EOF
7664int main() { return 0;}
7665_LT_EOF
7666 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
7667 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
7668 _lt_result=$?
7669 if test -s conftest.err && $GREP force_load conftest.err; then
7670 cat conftest.err >&5
7671 elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
7672 lt_cv_ld_force_load=yes
7673 else
7674 cat conftest.err >&5
7675 fi
7676 rm -f conftest.err libconftest.a conftest conftest.c
7677 rm -rf conftest.dSYM
7678
7679fi
7680{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
7681$as_echo "$lt_cv_ld_force_load" >&6; }
7682 case $host_os in
7683 rhapsody* | darwin1.[012])
7684 _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
7685 darwin1.*)
7686 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
7687 darwin*) # darwin 5.x on
7688 # if running on 10.5 or later, the deployment target defaults
7689 # to the OS version, if on x86, and 10.4, the deployment
7690 # target defaults to 10.4. Don't you love it?
7691 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
7692 10.0,*86*-darwin8*|10.0,*-darwin[91]*)
7693 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
7694 10.[012]*)
7695 _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
7696 10.*)
7697 _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
7698 esac
7699 ;;
7700 esac
7701 if test "$lt_cv_apple_cc_single_mod" = "yes"; then
7702 _lt_dar_single_mod='$single_module'
7703 fi
7704 if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
7705 _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
7706 else
7707 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
7708 fi
7709 if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
7710 _lt_dsymutil='~$DSYMUTIL $lib || :'
7711 else
7712 _lt_dsymutil=
7713 fi
7714 ;;
7715 esac
7716
7717ac_ext=c
7718ac_cpp='$CPP $CPPFLAGS'
7719ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7720ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7721ac_compiler_gnu=$ac_cv_c_compiler_gnu
7722{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
7723$as_echo_n "checking how to run the C preprocessor... " >&6; }
7724# On Suns, sometimes $CPP names a directory.
7725if test -n "$CPP" && test -d "$CPP"; then
7726 CPP=
7727fi
7728if test -z "$CPP"; then
7729 if ${ac_cv_prog_CPP+:} false; then :
7730 $as_echo_n "(cached) " >&6
7731else
7732 # Double quotes because CPP needs to be expanded
7733 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
7734 do
7735 ac_preproc_ok=false
7736for ac_c_preproc_warn_flag in '' yes
7737do
7738 # Use a header file that comes with gcc, so configuring glibc
7739 # with a fresh cross-compiler works.
7740 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7741 # <limits.h> exists even on freestanding compilers.
7742 # On the NeXT, cc -E runs the code through the compiler's parser,
7743 # not just through cpp. "Syntax error" is here to catch this case.
7744 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7745/* end confdefs.h. */
7746#ifdef __STDC__
7747# include <limits.h>
7748#else
7749# include <assert.h>
7750#endif
7751 Syntax error
7752_ACEOF
7753if ac_fn_c_try_cpp "$LINENO"; then :
7754
7755else
7756 # Broken: fails on valid input.
7757continue
7758fi
7759rm -f conftest.err conftest.i conftest.$ac_ext
7760
7761 # OK, works on sane cases. Now check whether nonexistent headers
7762 # can be detected and how.
7763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7764/* end confdefs.h. */
7765#include <ac_nonexistent.h>
7766_ACEOF
7767if ac_fn_c_try_cpp "$LINENO"; then :
7768 # Broken: success on invalid input.
7769continue
7770else
7771 # Passes both tests.
7772ac_preproc_ok=:
7773break
7774fi
7775rm -f conftest.err conftest.i conftest.$ac_ext
7776
7777done
7778# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7779rm -f conftest.i conftest.err conftest.$ac_ext
7780if $ac_preproc_ok; then :
7781 break
7782fi
7783
7784 done
7785 ac_cv_prog_CPP=$CPP
7786
7787fi
7788 CPP=$ac_cv_prog_CPP
7789else
7790 ac_cv_prog_CPP=$CPP
7791fi
7792{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
7793$as_echo "$CPP" >&6; }
7794ac_preproc_ok=false
7795for ac_c_preproc_warn_flag in '' yes
7796do
7797 # Use a header file that comes with gcc, so configuring glibc
7798 # with a fresh cross-compiler works.
7799 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7800 # <limits.h> exists even on freestanding compilers.
7801 # On the NeXT, cc -E runs the code through the compiler's parser,
7802 # not just through cpp. "Syntax error" is here to catch this case.
7803 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7804/* end confdefs.h. */
7805#ifdef __STDC__
7806# include <limits.h>
7807#else
7808# include <assert.h>
7809#endif
7810 Syntax error
7811_ACEOF
7812if ac_fn_c_try_cpp "$LINENO"; then :
7813
7814else
7815 # Broken: fails on valid input.
7816continue
7817fi
7818rm -f conftest.err conftest.i conftest.$ac_ext
7819
7820 # OK, works on sane cases. Now check whether nonexistent headers
7821 # can be detected and how.
7822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7823/* end confdefs.h. */
7824#include <ac_nonexistent.h>
7825_ACEOF
7826if ac_fn_c_try_cpp "$LINENO"; then :
7827 # Broken: success on invalid input.
7828continue
7829else
7830 # Passes both tests.
7831ac_preproc_ok=:
7832break
7833fi
7834rm -f conftest.err conftest.i conftest.$ac_ext
7835
7836done
7837# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7838rm -f conftest.i conftest.err conftest.$ac_ext
7839if $ac_preproc_ok; then :
7840
7841else
7842 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7843$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7844as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
7845See \`config.log' for more details" "$LINENO" 5; }
7846fi
7847
7848ac_ext=c
7849ac_cpp='$CPP $CPPFLAGS'
7850ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7851ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7852ac_compiler_gnu=$ac_cv_c_compiler_gnu
7853
7854
7855{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7856$as_echo_n "checking for ANSI C header files... " >&6; }
7857if ${ac_cv_header_stdc+:} false; then :
7858 $as_echo_n "(cached) " >&6
7859else
7860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7861/* end confdefs.h. */
7862#include <stdlib.h>
7863#include <stdarg.h>
7864#include <string.h>
7865#include <float.h>
7866
7867int
7868main ()
7869{
7870
7871 ;
7872 return 0;
7873}
7874_ACEOF
7875if ac_fn_c_try_compile "$LINENO"; then :
7876 ac_cv_header_stdc=yes
7877else
7878 ac_cv_header_stdc=no
7879fi
7880rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7881
7882if test $ac_cv_header_stdc = yes; then
7883 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7885/* end confdefs.h. */
7886#include <string.h>
7887
7888_ACEOF
7889if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7890 $EGREP "memchr" >/dev/null 2>&1; then :
7891
7892else
7893 ac_cv_header_stdc=no
7894fi
7895rm -f conftest*
7896
7897fi
7898
7899if test $ac_cv_header_stdc = yes; then
7900 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7902/* end confdefs.h. */
7903#include <stdlib.h>
7904
7905_ACEOF
7906if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7907 $EGREP "free" >/dev/null 2>&1; then :
7908
7909else
7910 ac_cv_header_stdc=no
7911fi
7912rm -f conftest*
7913
7914fi
7915
7916if test $ac_cv_header_stdc = yes; then
7917 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7918 if test "$cross_compiling" = yes; then :
7919 :
7920else
7921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7922/* end confdefs.h. */
7923#include <ctype.h>
7924#include <stdlib.h>
7925#if ((' ' & 0x0FF) == 0x020)
7926# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7927# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7928#else
7929# define ISLOWER(c) \
7930 (('a' <= (c) && (c) <= 'i') \
7931 || ('j' <= (c) && (c) <= 'r') \
7932 || ('s' <= (c) && (c) <= 'z'))
7933# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7934#endif
7935
7936#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7937int
7938main ()
7939{
7940 int i;
7941 for (i = 0; i < 256; i++)
7942 if (XOR (islower (i), ISLOWER (i))
7943 || toupper (i) != TOUPPER (i))
7944 return 2;
7945 return 0;
7946}
7947_ACEOF
7948if ac_fn_c_try_run "$LINENO"; then :
7949
7950else
7951 ac_cv_header_stdc=no
7952fi
7953rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7954 conftest.$ac_objext conftest.beam conftest.$ac_ext
7955fi
7956
7957fi
7958fi
7959{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
7960$as_echo "$ac_cv_header_stdc" >&6; }
7961if test $ac_cv_header_stdc = yes; then
7962
7963$as_echo "#define STDC_HEADERS 1" >>confdefs.h
7964
7965fi
7966
7967# On IRIX 5.3, sys/types and inttypes.h are conflicting.
7968for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7969 inttypes.h stdint.h unistd.h
7970do :
7971 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7972ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
7973"
7974if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7975 cat >>confdefs.h <<_ACEOF
7976#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7977_ACEOF
7978
7979fi
7980
7981done
7982
7983
7984for ac_header in dlfcn.h
7985do :
7986 ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
7987"
7988if test "x$ac_cv_header_dlfcn_h" = xyes; then :
7989 cat >>confdefs.h <<_ACEOF
7990#define HAVE_DLFCN_H 1
7991_ACEOF
7992
7993fi
7994
7995done
7996
7997
7998
7999
8000func_stripname_cnf ()
8001{
8002 case ${2} in
8003 .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
8004 *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
8005 esac
8006} # func_stripname_cnf
8007
8008
8009
8010
8011
8012# Set options
8013
8014
8015
8016 enable_dlopen=no
8017
8018
8019 enable_win32_dll=no
8020
8021
8022 # Check whether --enable-shared was given.
8023if test "${enable_shared+set}" = set; then :
8024 enableval=$enable_shared; p=${PACKAGE-default}
8025 case $enableval in
8026 yes) enable_shared=yes ;;
8027 no) enable_shared=no ;;
8028 *)
8029 enable_shared=no
8030 # Look at the argument we got. We use all the common list separators.
8031 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
8032 for pkg in $enableval; do
8033 IFS="$lt_save_ifs"
8034 if test "X$pkg" = "X$p"; then
8035 enable_shared=yes
8036 fi
8037 done
8038 IFS="$lt_save_ifs"
8039 ;;
8040 esac
8041else
8042 enable_shared=yes
8043fi
8044
8045
8046
8047
8048
8049
8050
8051
8052
8053 # Check whether --enable-static was given.
8054if test "${enable_static+set}" = set; then :
8055 enableval=$enable_static; p=${PACKAGE-default}
8056 case $enableval in
8057 yes) enable_static=yes ;;
8058 no) enable_static=no ;;
8059 *)
8060 enable_static=no
8061 # Look at the argument we got. We use all the common list separators.
8062 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
8063 for pkg in $enableval; do
8064 IFS="$lt_save_ifs"
8065 if test "X$pkg" = "X$p"; then
8066 enable_static=yes
8067 fi
8068 done
8069 IFS="$lt_save_ifs"
8070 ;;
8071 esac
8072else
8073 enable_static=yes
8074fi
8075
8076
8077
8078
8079
8080
8081
8082
8083
8084
8085# Check whether --with-pic was given.
8086if test "${with_pic+set}" = set; then :
8087 withval=$with_pic; lt_p=${PACKAGE-default}
8088 case $withval in
8089 yes|no) pic_mode=$withval ;;
8090 *)
8091 pic_mode=default
8092 # Look at the argument we got. We use all the common list separators.
8093 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
8094 for lt_pkg in $withval; do
8095 IFS="$lt_save_ifs"
8096 if test "X$lt_pkg" = "X$lt_p"; then
8097 pic_mode=yes
8098 fi
8099 done
8100 IFS="$lt_save_ifs"
8101 ;;
8102 esac
8103else
8104 pic_mode=default
8105fi
8106
8107
8108test -z "$pic_mode" && pic_mode=default
8109
8110
8111
8112
8113
8114
8115
8116 # Check whether --enable-fast-install was given.
8117if test "${enable_fast_install+set}" = set; then :
8118 enableval=$enable_fast_install; p=${PACKAGE-default}
8119 case $enableval in
8120 yes) enable_fast_install=yes ;;
8121 no) enable_fast_install=no ;;
8122 *)
8123 enable_fast_install=no
8124 # Look at the argument we got. We use all the common list separators.
8125 lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
8126 for pkg in $enableval; do
8127 IFS="$lt_save_ifs"
8128 if test "X$pkg" = "X$p"; then
8129 enable_fast_install=yes
8130 fi
8131 done
8132 IFS="$lt_save_ifs"
8133 ;;
8134 esac
8135else
8136 enable_fast_install=yes
8137fi
8138
8139
8140
8141
8142
8143
8144
8145
8146
8147
8148
8149# This can be used to rebuild libtool when needed
8150LIBTOOL_DEPS="$ltmain"
8151
8152# Always use our own libtool.
8153LIBTOOL='$(SHELL) $(top_builddir)/libtool'
8154
8155
8156
8157
8158
8159
8160
8161
8162
8163
8164
8165
8166
8167
8168
8169
8170
8171
8172
8173
8174
8175
8176
8177
8178
8179
8180
8181
8182
8183
8184test -z "$LN_S" && LN_S="ln -s"
8185
8186
8187
8188
8189
8190
8191
8192
8193
8194
8195
8196
8197
8198
8199if test -n "${ZSH_VERSION+set}" ; then
8200 setopt NO_GLOB_SUBST
8201fi
8202
8203{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
8204$as_echo_n "checking for objdir... " >&6; }
8205if ${lt_cv_objdir+:} false; then :
8206 $as_echo_n "(cached) " >&6
8207else
8208 rm -f .libs 2>/dev/null
8209mkdir .libs 2>/dev/null
8210if test -d .libs; then
8211 lt_cv_objdir=.libs
8212else
8213 # MS-DOS does not allow filenames that begin with a dot.
8214 lt_cv_objdir=_libs
8215fi
8216rmdir .libs 2>/dev/null
8217fi
8218{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
8219$as_echo "$lt_cv_objdir" >&6; }
8220objdir=$lt_cv_objdir
8221
8222
8223
8224
8225
8226cat >>confdefs.h <<_ACEOF
8227#define LT_OBJDIR "$lt_cv_objdir/"
8228_ACEOF
8229
8230
8231
8232
8233case $host_os in
8234aix3*)
8235 # AIX sometimes has problems with the GCC collect2 program. For some
8236 # reason, if we set the COLLECT_NAMES environment variable, the problems
8237 # vanish in a puff of smoke.
8238 if test "X${COLLECT_NAMES+set}" != Xset; then
8239 COLLECT_NAMES=
8240 export COLLECT_NAMES
8241 fi
8242 ;;
8243esac
8244
8245# Global variables:
8246ofile=libtool
8247can_build_shared=yes
8248
8249# All known linkers require a `.a' archive for static linking (except MSVC,
8250# which needs '.lib').
8251libext=a
8252
8253with_gnu_ld="$lt_cv_prog_gnu_ld"
8254
8255old_CC="$CC"
8256old_CFLAGS="$CFLAGS"
8257
8258# Set sane defaults for various variables
8259test -z "$CC" && CC=cc
8260test -z "$LTCC" && LTCC=$CC
8261test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
8262test -z "$LD" && LD=ld
8263test -z "$ac_objext" && ac_objext=o
8264
8265for cc_temp in $compiler""; do
8266 case $cc_temp in
8267 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
8268 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
8269 \-*) ;;
8270 *) break;;
8271 esac
8272done
8273cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
8274
8275
8276# Only perform the check for file, if the check method requires it
8277test -z "$MAGIC_CMD" && MAGIC_CMD=file
8278case $deplibs_check_method in
8279file_magic*)
8280 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
8281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
8282$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
8283if ${lt_cv_path_MAGIC_CMD+:} false; then :
8284 $as_echo_n "(cached) " >&6
8285else
8286 case $MAGIC_CMD in
8287[\\/*] | ?:[\\/]*)
8288 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
8289 ;;
8290*)
8291 lt_save_MAGIC_CMD="$MAGIC_CMD"
8292 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
8293 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
8294 for ac_dir in $ac_dummy; do
8295 IFS="$lt_save_ifs"
8296 test -z "$ac_dir" && ac_dir=.
8297 if test -f $ac_dir/${ac_tool_prefix}file; then
8298 lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
8299 if test -n "$file_magic_test_file"; then
8300 case $deplibs_check_method in
8301 "file_magic "*)
8302 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
8303 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
8304 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
8305 $EGREP "$file_magic_regex" > /dev/null; then
8306 :
8307 else
8308 cat <<_LT_EOF 1>&2
8309
8310*** Warning: the command libtool uses to detect shared libraries,
8311*** $file_magic_cmd, produces output that libtool cannot recognize.
8312*** The result is that libtool may fail to recognize shared libraries
8313*** as such. This will affect the creation of libtool libraries that
8314*** depend on shared libraries, but programs linked with such libtool
8315*** libraries will work regardless of this problem. Nevertheless, you
8316*** may want to report the problem to your system manager and/or to
8317*** bug-libtool@gnu.org
8318
8319_LT_EOF
8320 fi ;;
8321 esac
8322 fi
8323 break
8324 fi
8325 done
8326 IFS="$lt_save_ifs"
8327 MAGIC_CMD="$lt_save_MAGIC_CMD"
8328 ;;
8329esac
8330fi
8331
8332MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
8333if test -n "$MAGIC_CMD"; then
8334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
8335$as_echo "$MAGIC_CMD" >&6; }
8336else
8337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8338$as_echo "no" >&6; }
8339fi
8340
8341
8342
8343
8344
8345if test -z "$lt_cv_path_MAGIC_CMD"; then
8346 if test -n "$ac_tool_prefix"; then
8347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
8348$as_echo_n "checking for file... " >&6; }
8349if ${lt_cv_path_MAGIC_CMD+:} false; then :
8350 $as_echo_n "(cached) " >&6
8351else
8352 case $MAGIC_CMD in
8353[\\/*] | ?:[\\/]*)
8354 lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
8355 ;;
8356*)
8357 lt_save_MAGIC_CMD="$MAGIC_CMD"
8358 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
8359 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
8360 for ac_dir in $ac_dummy; do
8361 IFS="$lt_save_ifs"
8362 test -z "$ac_dir" && ac_dir=.
8363 if test -f $ac_dir/file; then
8364 lt_cv_path_MAGIC_CMD="$ac_dir/file"
8365 if test -n "$file_magic_test_file"; then
8366 case $deplibs_check_method in
8367 "file_magic "*)
8368 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
8369 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
8370 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
8371 $EGREP "$file_magic_regex" > /dev/null; then
8372 :
8373 else
8374 cat <<_LT_EOF 1>&2
8375
8376*** Warning: the command libtool uses to detect shared libraries,
8377*** $file_magic_cmd, produces output that libtool cannot recognize.
8378*** The result is that libtool may fail to recognize shared libraries
8379*** as such. This will affect the creation of libtool libraries that
8380*** depend on shared libraries, but programs linked with such libtool
8381*** libraries will work regardless of this problem. Nevertheless, you
8382*** may want to report the problem to your system manager and/or to
8383*** bug-libtool@gnu.org
8384
8385_LT_EOF
8386 fi ;;
8387 esac
8388 fi
8389 break
8390 fi
8391 done
8392 IFS="$lt_save_ifs"
8393 MAGIC_CMD="$lt_save_MAGIC_CMD"
8394 ;;
8395esac
8396fi
8397
8398MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
8399if test -n "$MAGIC_CMD"; then
8400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
8401$as_echo "$MAGIC_CMD" >&6; }
8402else
8403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8404$as_echo "no" >&6; }
8405fi
8406
8407
8408 else
8409 MAGIC_CMD=:
8410 fi
8411fi
8412
8413 fi
8414 ;;
8415esac
8416
8417# Use C for the default configuration in the libtool script
8418
8419lt_save_CC="$CC"
8420ac_ext=c
8421ac_cpp='$CPP $CPPFLAGS'
8422ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8423ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8424ac_compiler_gnu=$ac_cv_c_compiler_gnu
8425
8426
8427# Source file extension for C test sources.
8428ac_ext=c
8429
8430# Object file extension for compiled C test sources.
8431objext=o
8432objext=$objext
8433
8434# Code to be used in simple compile tests
8435lt_simple_compile_test_code="int some_variable = 0;"
8436
8437# Code to be used in simple link tests
8438lt_simple_link_test_code='int main(){return(0);}'
8439
8440
8441
8442
8443
8444
8445
8446# If no C compiler was specified, use CC.
8447LTCC=${LTCC-"$CC"}
8448
8449# If no C compiler flags were specified, use CFLAGS.
8450LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
8451
8452# Allow CC to be a program name with arguments.
8453compiler=$CC
8454
8455# Save the default compiler, since it gets overwritten when the other
8456# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
8457compiler_DEFAULT=$CC
8458
8459# save warnings/boilerplate of simple test code
8460ac_outfile=conftest.$ac_objext
8461echo "$lt_simple_compile_test_code" >conftest.$ac_ext
8462eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
8463_lt_compiler_boilerplate=`cat conftest.err`
8464$RM conftest*
8465
8466ac_outfile=conftest.$ac_objext
8467echo "$lt_simple_link_test_code" >conftest.$ac_ext
8468eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
8469_lt_linker_boilerplate=`cat conftest.err`
8470$RM -r conftest*
8471
8472
8473## CAVEAT EMPTOR:
8474## There is no encapsulation within the following macros, do not change
8475## the running order or otherwise move them around unless you know exactly
8476## what you are doing...
8477if test -n "$compiler"; then
8478
8479lt_prog_compiler_no_builtin_flag=
8480
8481if test "$GCC" = yes; then
8482 case $cc_basename in
8483 nvcc*)
8484 lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
8485 *)
8486 lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
8487 esac
8488
8489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
8490$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
8491if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
8492 $as_echo_n "(cached) " >&6
8493else
8494 lt_cv_prog_compiler_rtti_exceptions=no
8495 ac_outfile=conftest.$ac_objext
8496 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8497 lt_compiler_flag="-fno-rtti -fno-exceptions"
8498 # Insert the option either (1) after the last *FLAGS variable, or
8499 # (2) before a word containing "conftest.", or (3) at the end.
8500 # Note that $ac_compile itself does not contain backslashes and begins
8501 # with a dollar sign (not a hyphen), so the echo should work correctly.
8502 # The option is referenced via a variable to avoid confusing sed.
8503 lt_compile=`echo "$ac_compile" | $SED \
8504 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8505 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8506 -e 's:$: $lt_compiler_flag:'`
8507 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
8508 (eval "$lt_compile" 2>conftest.err)
8509 ac_status=$?
8510 cat conftest.err >&5
8511 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8512 if (exit $ac_status) && test -s "$ac_outfile"; then
8513 # The compiler can only warn and ignore the option if not recognized
8514 # So say no if there are warnings other than the usual output.
8515 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
8516 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
8517 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
8518 lt_cv_prog_compiler_rtti_exceptions=yes
8519 fi
8520 fi
8521 $RM conftest*
8522
8523fi
8524{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
8525$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
8526
8527if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
8528 lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
8529else
8530 :
8531fi
8532
8533fi
8534
8535
8536
8537
8538
8539
8540 lt_prog_compiler_wl=
8541lt_prog_compiler_pic=
8542lt_prog_compiler_static=
8543
8544
8545 if test "$GCC" = yes; then
8546 lt_prog_compiler_wl='-Wl,'
8547 lt_prog_compiler_static='-static'
8548
8549 case $host_os in
8550 aix*)
8551 # All AIX code is PIC.
8552 if test "$host_cpu" = ia64; then
8553 # AIX 5 now supports IA64 processor
8554 lt_prog_compiler_static='-Bstatic'
8555 fi
8556 ;;
8557
8558 amigaos*)
8559 case $host_cpu in
8560 powerpc)
8561 # see comment about AmigaOS4 .so support
8562 lt_prog_compiler_pic='-fPIC'
8563 ;;
8564 m68k)
8565 # FIXME: we need at least 68020 code to build shared libraries, but
8566 # adding the `-m68020' flag to GCC prevents building anything better,
8567 # like `-m68040'.
8568 lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
8569 ;;
8570 esac
8571 ;;
8572
8573 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
8574 # PIC is the default for these OSes.
8575 ;;
8576
8577 mingw* | cygwin* | pw32* | os2* | cegcc*)
8578 # This hack is so that the source file can tell whether it is being
8579 # built for inclusion in a dll (and should export symbols for example).
8580 # Although the cygwin gcc ignores -fPIC, still need this for old-style
8581 # (--disable-auto-import) libraries
8582 lt_prog_compiler_pic='-DDLL_EXPORT'
8583 ;;
8584
8585 darwin* | rhapsody*)
8586 # PIC is the default on this platform
8587 # Common symbols not allowed in MH_DYLIB files
8588 lt_prog_compiler_pic='-fno-common'
8589 ;;
8590
8591 haiku*)
8592 # PIC is the default for Haiku.
8593 # The "-static" flag exists, but is broken.
8594 lt_prog_compiler_static=
8595 ;;
8596
8597 hpux*)
8598 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
8599 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
8600 # sets the default TLS model and affects inlining.
8601 case $host_cpu in
8602 hppa*64*)
8603 # +Z the default
8604 ;;
8605 *)
8606 lt_prog_compiler_pic='-fPIC'
8607 ;;
8608 esac
8609 ;;
8610
8611 interix[3-9]*)
8612 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
8613 # Instead, we relocate shared libraries at runtime.
8614 ;;
8615
8616 msdosdjgpp*)
8617 # Just because we use GCC doesn't mean we suddenly get shared libraries
8618 # on systems that don't support them.
8619 lt_prog_compiler_can_build_shared=no
8620 enable_shared=no
8621 ;;
8622
8623 *nto* | *qnx*)
8624 # QNX uses GNU C++, but need to define -shared option too, otherwise
8625 # it will coredump.
8626 lt_prog_compiler_pic='-fPIC -shared'
8627 ;;
8628
8629 sysv4*MP*)
8630 if test -d /usr/nec; then
8631 lt_prog_compiler_pic=-Kconform_pic
8632 fi
8633 ;;
8634
8635 *)
8636 lt_prog_compiler_pic='-fPIC'
8637 ;;
8638 esac
8639
8640 case $cc_basename in
8641 nvcc*) # Cuda Compiler Driver 2.2
8642 lt_prog_compiler_wl='-Xlinker '
8643 if test -n "$lt_prog_compiler_pic"; then
8644 lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
8645 fi
8646 ;;
8647 esac
8648 else
8649 # PORTME Check for flag to pass linker flags through the system compiler.
8650 case $host_os in
8651 aix*)
8652 lt_prog_compiler_wl='-Wl,'
8653 if test "$host_cpu" = ia64; then
8654 # AIX 5 now supports IA64 processor
8655 lt_prog_compiler_static='-Bstatic'
8656 else
8657 lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
8658 fi
8659 ;;
8660
8661 mingw* | cygwin* | pw32* | os2* | cegcc*)
8662 # This hack is so that the source file can tell whether it is being
8663 # built for inclusion in a dll (and should export symbols for example).
8664 lt_prog_compiler_pic='-DDLL_EXPORT'
8665 ;;
8666
8667 hpux9* | hpux10* | hpux11*)
8668 lt_prog_compiler_wl='-Wl,'
8669 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
8670 # not for PA HP-UX.
8671 case $host_cpu in
8672 hppa*64*|ia64*)
8673 # +Z the default
8674 ;;
8675 *)
8676 lt_prog_compiler_pic='+Z'
8677 ;;
8678 esac
8679 # Is there a better lt_prog_compiler_static that works with the bundled CC?
8680 lt_prog_compiler_static='${wl}-a ${wl}archive'
8681 ;;
8682
8683 irix5* | irix6* | nonstopux*)
8684 lt_prog_compiler_wl='-Wl,'
8685 # PIC (with -KPIC) is the default.
8686 lt_prog_compiler_static='-non_shared'
8687 ;;
8688
8689 linux* | k*bsd*-gnu | kopensolaris*-gnu)
8690 case $cc_basename in
8691 # old Intel for x86_64 which still supported -KPIC.
8692 ecc*)
8693 lt_prog_compiler_wl='-Wl,'
8694 lt_prog_compiler_pic='-KPIC'
8695 lt_prog_compiler_static='-static'
8696 ;;
8697 # icc used to be incompatible with GCC.
8698 # ICC 10 doesn't accept -KPIC any more.
8699 icc* | ifort*)
8700 lt_prog_compiler_wl='-Wl,'
8701 lt_prog_compiler_pic='-fPIC'
8702 lt_prog_compiler_static='-static'
8703 ;;
8704 # Lahey Fortran 8.1.
8705 lf95*)
8706 lt_prog_compiler_wl='-Wl,'
8707 lt_prog_compiler_pic='--shared'
8708 lt_prog_compiler_static='--static'
8709 ;;
8710 nagfor*)
8711 # NAG Fortran compiler
8712 lt_prog_compiler_wl='-Wl,-Wl,,'
8713 lt_prog_compiler_pic='-PIC'
8714 lt_prog_compiler_static='-Bstatic'
8715 ;;
8716 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
8717 # Portland Group compilers (*not* the Pentium gcc compiler,
8718 # which looks to be a dead project)
8719 lt_prog_compiler_wl='-Wl,'
8720 lt_prog_compiler_pic='-fpic'
8721 lt_prog_compiler_static='-Bstatic'
8722 ;;
8723 ccc*)
8724 lt_prog_compiler_wl='-Wl,'
8725 # All Alpha code is PIC.
8726 lt_prog_compiler_static='-non_shared'
8727 ;;
8728 xl* | bgxl* | bgf* | mpixl*)
8729 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
8730 lt_prog_compiler_wl='-Wl,'
8731 lt_prog_compiler_pic='-qpic'
8732 lt_prog_compiler_static='-qstaticlink'
8733 ;;
8734 *)
8735 case `$CC -V 2>&1 | sed 5q` in
8736 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
8737 # Sun Fortran 8.3 passes all unrecognized flags to the linker
8738 lt_prog_compiler_pic='-KPIC'
8739 lt_prog_compiler_static='-Bstatic'
8740 lt_prog_compiler_wl=''
8741 ;;
8742 *Sun\ F* | *Sun*Fortran*)
8743 lt_prog_compiler_pic='-KPIC'
8744 lt_prog_compiler_static='-Bstatic'
8745 lt_prog_compiler_wl='-Qoption ld '
8746 ;;
8747 *Sun\ C*)
8748 # Sun C 5.9
8749 lt_prog_compiler_pic='-KPIC'
8750 lt_prog_compiler_static='-Bstatic'
8751 lt_prog_compiler_wl='-Wl,'
8752 ;;
8753 *Intel*\ [CF]*Compiler*)
8754 lt_prog_compiler_wl='-Wl,'
8755 lt_prog_compiler_pic='-fPIC'
8756 lt_prog_compiler_static='-static'
8757 ;;
8758 *Portland\ Group*)
8759 lt_prog_compiler_wl='-Wl,'
8760 lt_prog_compiler_pic='-fpic'
8761 lt_prog_compiler_static='-Bstatic'
8762 ;;
8763 esac
8764 ;;
8765 esac
8766 ;;
8767
8768 newsos6)
8769 lt_prog_compiler_pic='-KPIC'
8770 lt_prog_compiler_static='-Bstatic'
8771 ;;
8772
8773 *nto* | *qnx*)
8774 # QNX uses GNU C++, but need to define -shared option too, otherwise
8775 # it will coredump.
8776 lt_prog_compiler_pic='-fPIC -shared'
8777 ;;
8778
8779 osf3* | osf4* | osf5*)
8780 lt_prog_compiler_wl='-Wl,'
8781 # All OSF/1 code is PIC.
8782 lt_prog_compiler_static='-non_shared'
8783 ;;
8784
8785 rdos*)
8786 lt_prog_compiler_static='-non_shared'
8787 ;;
8788
8789 solaris*)
8790 lt_prog_compiler_pic='-KPIC'
8791 lt_prog_compiler_static='-Bstatic'
8792 case $cc_basename in
8793 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
8794 lt_prog_compiler_wl='-Qoption ld ';;
8795 *)
8796 lt_prog_compiler_wl='-Wl,';;
8797 esac
8798 ;;
8799
8800 sunos4*)
8801 lt_prog_compiler_wl='-Qoption ld '
8802 lt_prog_compiler_pic='-PIC'
8803 lt_prog_compiler_static='-Bstatic'
8804 ;;
8805
8806 sysv4 | sysv4.2uw2* | sysv4.3*)
8807 lt_prog_compiler_wl='-Wl,'
8808 lt_prog_compiler_pic='-KPIC'
8809 lt_prog_compiler_static='-Bstatic'
8810 ;;
8811
8812 sysv4*MP*)
8813 if test -d /usr/nec ;then
8814 lt_prog_compiler_pic='-Kconform_pic'
8815 lt_prog_compiler_static='-Bstatic'
8816 fi
8817 ;;
8818
8819 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
8820 lt_prog_compiler_wl='-Wl,'
8821 lt_prog_compiler_pic='-KPIC'
8822 lt_prog_compiler_static='-Bstatic'
8823 ;;
8824
8825 unicos*)
8826 lt_prog_compiler_wl='-Wl,'
8827 lt_prog_compiler_can_build_shared=no
8828 ;;
8829
8830 uts4*)
8831 lt_prog_compiler_pic='-pic'
8832 lt_prog_compiler_static='-Bstatic'
8833 ;;
8834
8835 *)
8836 lt_prog_compiler_can_build_shared=no
8837 ;;
8838 esac
8839 fi
8840
8841case $host_os in
8842 # For platforms which do not support PIC, -DPIC is meaningless:
8843 *djgpp*)
8844 lt_prog_compiler_pic=
8845 ;;
8846 *)
8847 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
8848 ;;
8849esac
8850
8851{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
8852$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
8853if ${lt_cv_prog_compiler_pic+:} false; then :
8854 $as_echo_n "(cached) " >&6
8855else
8856 lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
8857fi
8858{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
8859$as_echo "$lt_cv_prog_compiler_pic" >&6; }
8860lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
8861
8862#
8863# Check to make sure the PIC flag actually works.
8864#
8865if test -n "$lt_prog_compiler_pic"; then
8866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
8867$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
8868if ${lt_cv_prog_compiler_pic_works+:} false; then :
8869 $as_echo_n "(cached) " >&6
8870else
8871 lt_cv_prog_compiler_pic_works=no
8872 ac_outfile=conftest.$ac_objext
8873 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8874 lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
8875 # Insert the option either (1) after the last *FLAGS variable, or
8876 # (2) before a word containing "conftest.", or (3) at the end.
8877 # Note that $ac_compile itself does not contain backslashes and begins
8878 # with a dollar sign (not a hyphen), so the echo should work correctly.
8879 # The option is referenced via a variable to avoid confusing sed.
8880 lt_compile=`echo "$ac_compile" | $SED \
8881 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8882 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8883 -e 's:$: $lt_compiler_flag:'`
8884 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
8885 (eval "$lt_compile" 2>conftest.err)
8886 ac_status=$?
8887 cat conftest.err >&5
8888 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8889 if (exit $ac_status) && test -s "$ac_outfile"; then
8890 # The compiler can only warn and ignore the option if not recognized
8891 # So say no if there are warnings other than the usual output.
8892 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
8893 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
8894 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
8895 lt_cv_prog_compiler_pic_works=yes
8896 fi
8897 fi
8898 $RM conftest*
8899
8900fi
8901{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
8902$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
8903
8904if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
8905 case $lt_prog_compiler_pic in
8906 "" | " "*) ;;
8907 *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
8908 esac
8909else
8910 lt_prog_compiler_pic=
8911 lt_prog_compiler_can_build_shared=no
8912fi
8913
8914fi
8915
8916
8917
8918
8919
8920
8921
8922
8923
8924
8925
8926#
8927# Check to make sure the static flag actually works.
8928#
8929wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
8930{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
8931$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
8932if ${lt_cv_prog_compiler_static_works+:} false; then :
8933 $as_echo_n "(cached) " >&6
8934else
8935 lt_cv_prog_compiler_static_works=no
8936 save_LDFLAGS="$LDFLAGS"
8937 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
8938 echo "$lt_simple_link_test_code" > conftest.$ac_ext
8939 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
8940 # The linker can only warn and ignore the option if not recognized
8941 # So say no if there are warnings
8942 if test -s conftest.err; then
8943 # Append any errors to the config.log.
8944 cat conftest.err 1>&5
8945 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
8946 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
8947 if diff conftest.exp conftest.er2 >/dev/null; then
8948 lt_cv_prog_compiler_static_works=yes
8949 fi
8950 else
8951 lt_cv_prog_compiler_static_works=yes
8952 fi
8953 fi
8954 $RM -r conftest*
8955 LDFLAGS="$save_LDFLAGS"
8956
8957fi
8958{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
8959$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
8960
8961if test x"$lt_cv_prog_compiler_static_works" = xyes; then
8962 :
8963else
8964 lt_prog_compiler_static=
8965fi
8966
8967
8968
8969
8970
8971
8972
8973 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
8974$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
8975if ${lt_cv_prog_compiler_c_o+:} false; then :
8976 $as_echo_n "(cached) " >&6
8977else
8978 lt_cv_prog_compiler_c_o=no
8979 $RM -r conftest 2>/dev/null
8980 mkdir conftest
8981 cd conftest
8982 mkdir out
8983 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8984
8985 lt_compiler_flag="-o out/conftest2.$ac_objext"
8986 # Insert the option either (1) after the last *FLAGS variable, or
8987 # (2) before a word containing "conftest.", or (3) at the end.
8988 # Note that $ac_compile itself does not contain backslashes and begins
8989 # with a dollar sign (not a hyphen), so the echo should work correctly.
8990 lt_compile=`echo "$ac_compile" | $SED \
8991 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8992 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8993 -e 's:$: $lt_compiler_flag:'`
8994 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
8995 (eval "$lt_compile" 2>out/conftest.err)
8996 ac_status=$?
8997 cat out/conftest.err >&5
8998 echo "$as_me:$LINENO: \$? = $ac_status" >&5
8999 if (exit $ac_status) && test -s out/conftest2.$ac_objext
9000 then
9001 # The compiler can only warn and ignore the option if not recognized
9002 # So say no if there are warnings
9003 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
9004 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
9005 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
9006 lt_cv_prog_compiler_c_o=yes
9007 fi
9008 fi
9009 chmod u+w . 2>&5
9010 $RM conftest*
9011 # SGI C++ compiler will create directory out/ii_files/ for
9012 # template instantiation
9013 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
9014 $RM out/* && rmdir out
9015 cd ..
9016 $RM -r conftest
9017 $RM conftest*
9018
9019fi
9020{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
9021$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
9022
9023
9024
9025
9026
9027
9028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
9029$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
9030if ${lt_cv_prog_compiler_c_o+:} false; then :
9031 $as_echo_n "(cached) " >&6
9032else
9033 lt_cv_prog_compiler_c_o=no
9034 $RM -r conftest 2>/dev/null
9035 mkdir conftest
9036 cd conftest
9037 mkdir out
9038 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
9039
9040 lt_compiler_flag="-o out/conftest2.$ac_objext"
9041 # Insert the option either (1) after the last *FLAGS variable, or
9042 # (2) before a word containing "conftest.", or (3) at the end.
9043 # Note that $ac_compile itself does not contain backslashes and begins
9044 # with a dollar sign (not a hyphen), so the echo should work correctly.
9045 lt_compile=`echo "$ac_compile" | $SED \
9046 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
9047 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
9048 -e 's:$: $lt_compiler_flag:'`
9049 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
9050 (eval "$lt_compile" 2>out/conftest.err)
9051 ac_status=$?
9052 cat out/conftest.err >&5
9053 echo "$as_me:$LINENO: \$? = $ac_status" >&5
9054 if (exit $ac_status) && test -s out/conftest2.$ac_objext
9055 then
9056 # The compiler can only warn and ignore the option if not recognized
9057 # So say no if there are warnings
9058 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
9059 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
9060 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
9061 lt_cv_prog_compiler_c_o=yes
9062 fi
9063 fi
9064 chmod u+w . 2>&5
9065 $RM conftest*
9066 # SGI C++ compiler will create directory out/ii_files/ for
9067 # template instantiation
9068 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
9069 $RM out/* && rmdir out
9070 cd ..
9071 $RM -r conftest
9072 $RM conftest*
9073
9074fi
9075{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
9076$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
9077
9078
9079
9080
9081hard_links="nottested"
9082if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
9083 # do not overwrite the value of need_locks provided by the user
9084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
9085$as_echo_n "checking if we can lock with hard links... " >&6; }
9086 hard_links=yes
9087 $RM conftest*
9088 ln conftest.a conftest.b 2>/dev/null && hard_links=no
9089 touch conftest.a
9090 ln conftest.a conftest.b 2>&5 || hard_links=no
9091 ln conftest.a conftest.b 2>/dev/null && hard_links=no
9092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
9093$as_echo "$hard_links" >&6; }
9094 if test "$hard_links" = no; then
9095 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
9096$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
9097 need_locks=warn
9098 fi
9099else
9100 need_locks=no
9101fi
9102
9103
9104
9105
9106
9107
9108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
9109$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
9110
9111 runpath_var=
9112 allow_undefined_flag=
9113 always_export_symbols=no
9114 archive_cmds=
9115 archive_expsym_cmds=
9116 compiler_needs_object=no
9117 enable_shared_with_static_runtimes=no
9118 export_dynamic_flag_spec=
9119 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
9120 hardcode_automatic=no
9121 hardcode_direct=no
9122 hardcode_direct_absolute=no
9123 hardcode_libdir_flag_spec=
9124 hardcode_libdir_separator=
9125 hardcode_minus_L=no
9126 hardcode_shlibpath_var=unsupported
9127 inherit_rpath=no
9128 link_all_deplibs=unknown
9129 module_cmds=
9130 module_expsym_cmds=
9131 old_archive_from_new_cmds=
9132 old_archive_from_expsyms_cmds=
9133 thread_safe_flag_spec=
9134 whole_archive_flag_spec=
9135 # include_expsyms should be a list of space-separated symbols to be *always*
9136 # included in the symbol list
9137 include_expsyms=
9138 # exclude_expsyms can be an extended regexp of symbols to exclude
9139 # it will be wrapped by ` (' and `)$', so one must not match beginning or
9140 # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
9141 # as well as any symbol that contains `d'.
9142 exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
9143 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
9144 # platforms (ab)use it in PIC code, but their linkers get confused if
9145 # the symbol is explicitly referenced. Since portable code cannot
9146 # rely on this symbol name, it's probably fine to never include it in
9147 # preloaded symbol tables.
9148 # Exclude shared library initialization/finalization symbols.
9149 extract_expsyms_cmds=
9150
9151 case $host_os in
9152 cygwin* | mingw* | pw32* | cegcc*)
9153 # FIXME: the MSVC++ port hasn't been tested in a loooong time
9154 # When not using gcc, we currently assume that we are using
9155 # Microsoft Visual C++.
9156 if test "$GCC" != yes; then
9157 with_gnu_ld=no
9158 fi
9159 ;;
9160 interix*)
9161 # we just hope/assume this is gcc and not c89 (= MSVC++)
9162 with_gnu_ld=yes
9163 ;;
9164 openbsd*)
9165 with_gnu_ld=no
9166 ;;
9167 esac
9168
9169 ld_shlibs=yes
9170
9171 # On some targets, GNU ld is compatible enough with the native linker
9172 # that we're better off using the native interface for both.
9173 lt_use_gnu_ld_interface=no
9174 if test "$with_gnu_ld" = yes; then
9175 case $host_os in
9176 aix*)
9177 # The AIX port of GNU ld has always aspired to compatibility
9178 # with the native linker. However, as the warning in the GNU ld
9179 # block says, versions before 2.19.5* couldn't really create working
9180 # shared libraries, regardless of the interface used.
9181 case `$LD -v 2>&1` in
9182 *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
9183 *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
9184 *\ \(GNU\ Binutils\)\ [3-9]*) ;;
9185 *)
9186 lt_use_gnu_ld_interface=yes
9187 ;;
9188 esac
9189 ;;
9190 *)
9191 lt_use_gnu_ld_interface=yes
9192 ;;
9193 esac
9194 fi
9195
9196 if test "$lt_use_gnu_ld_interface" = yes; then
9197 # If archive_cmds runs LD, not CC, wlarc should be empty
9198 wlarc='${wl}'
9199
9200 # Set some defaults for GNU ld with shared library support. These
9201 # are reset later if shared libraries are not supported. Putting them
9202 # here allows them to be overridden if necessary.
9203 runpath_var=LD_RUN_PATH
9204 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9205 export_dynamic_flag_spec='${wl}--export-dynamic'
9206 # ancient GNU ld didn't support --whole-archive et. al.
9207 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
9208 whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
9209 else
9210 whole_archive_flag_spec=
9211 fi
9212 supports_anon_versioning=no
9213 case `$LD -v 2>&1` in
9214 *GNU\ gold*) supports_anon_versioning=yes ;;
9215 *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
9216 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
9217 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
9218 *\ 2.11.*) ;; # other 2.11 versions
9219 *) supports_anon_versioning=yes ;;
9220 esac
9221
9222 # See if GNU ld supports shared libraries.
9223 case $host_os in
9224 aix[3-9]*)
9225 # On AIX/PPC, the GNU linker is very broken
9226 if test "$host_cpu" != ia64; then
9227 ld_shlibs=no
9228 cat <<_LT_EOF 1>&2
9229
9230*** Warning: the GNU linker, at least up to release 2.19, is reported
9231*** to be unable to reliably create shared libraries on AIX.
9232*** Therefore, libtool is disabling shared libraries support. If you
9233*** really care for shared libraries, you may want to install binutils
9234*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
9235*** You will then need to restart the configuration process.
9236
9237_LT_EOF
9238 fi
9239 ;;
9240
9241 amigaos*)
9242 case $host_cpu in
9243 powerpc)
9244 # see comment about AmigaOS4 .so support
9245 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9246 archive_expsym_cmds=''
9247 ;;
9248 m68k)
9249 archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
9250 hardcode_libdir_flag_spec='-L$libdir'
9251 hardcode_minus_L=yes
9252 ;;
9253 esac
9254 ;;
9255
9256 beos*)
9257 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
9258 allow_undefined_flag=unsupported
9259 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
9260 # support --undefined. This deserves some investigation. FIXME
9261 archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9262 else
9263 ld_shlibs=no
9264 fi
9265 ;;
9266
9267 cygwin* | mingw* | pw32* | cegcc*)
9268 # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
9269 # as there is no search path for DLLs.
9270 hardcode_libdir_flag_spec='-L$libdir'
9271 export_dynamic_flag_spec='${wl}--export-all-symbols'
9272 allow_undefined_flag=unsupported
9273 always_export_symbols=no
9274 enable_shared_with_static_runtimes=yes
9275 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
9276 exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
9277
9278 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
9279 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
9280 # If the export-symbols file already is a .def file (1st line
9281 # is EXPORTS), use it as is; otherwise, prepend...
9282 archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
9283 cp $export_symbols $output_objdir/$soname.def;
9284 else
9285 echo EXPORTS > $output_objdir/$soname.def;
9286 cat $export_symbols >> $output_objdir/$soname.def;
9287 fi~
9288 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
9289 else
9290 ld_shlibs=no
9291 fi
9292 ;;
9293
9294 haiku*)
9295 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9296 link_all_deplibs=yes
9297 ;;
9298
9299 interix[3-9]*)
9300 hardcode_direct=no
9301 hardcode_shlibpath_var=no
9302 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
9303 export_dynamic_flag_spec='${wl}-E'
9304 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
9305 # Instead, shared libraries are loaded at an image base (0x10000000 by
9306 # default) and relocated if they conflict, which is a slow very memory
9307 # consuming and fragmenting process. To avoid this, we pick a random,
9308 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
9309 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
9310 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
9311 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'
9312 ;;
9313
9314 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
9315 tmp_diet=no
9316 if test "$host_os" = linux-dietlibc; then
9317 case $cc_basename in
9318 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
9319 esac
9320 fi
9321 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
9322 && test "$tmp_diet" = no
9323 then
9324 tmp_addflag=' $pic_flag'
9325 tmp_sharedflag='-shared'
9326 case $cc_basename,$host_cpu in
9327 pgcc*) # Portland Group C compiler
9328 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'
9329 tmp_addflag=' $pic_flag'
9330 ;;
9331 pgf77* | pgf90* | pgf95* | pgfortran*)
9332 # Portland Group f77 and f90 compilers
9333 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'
9334 tmp_addflag=' $pic_flag -Mnomain' ;;
9335 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
9336 tmp_addflag=' -i_dynamic' ;;
9337 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
9338 tmp_addflag=' -i_dynamic -nofor_main' ;;
9339 ifc* | ifort*) # Intel Fortran compiler
9340 tmp_addflag=' -nofor_main' ;;
9341 lf95*) # Lahey Fortran 8.1
9342 whole_archive_flag_spec=
9343 tmp_sharedflag='--shared' ;;
9344 xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
9345 tmp_sharedflag='-qmkshrobj'
9346 tmp_addflag= ;;
9347 nvcc*) # Cuda Compiler Driver 2.2
9348 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'
9349 compiler_needs_object=yes
9350 ;;
9351 esac
9352 case `$CC -V 2>&1 | sed 5q` in
9353 *Sun\ C*) # Sun C 5.9
9354 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'
9355 compiler_needs_object=yes
9356 tmp_sharedflag='-G' ;;
9357 *Sun\ F*) # Sun Fortran 8.3
9358 tmp_sharedflag='-G' ;;
9359 esac
9360 archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9361
9362 if test "x$supports_anon_versioning" = xyes; then
9363 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
9364 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
9365 echo "local: *; };" >> $output_objdir/$libname.ver~
9366 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
9367 fi
9368
9369 case $cc_basename in
9370 xlf* | bgf* | bgxlf* | mpixlf*)
9371 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
9372 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
9373 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9374 archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
9375 if test "x$supports_anon_versioning" = xyes; then
9376 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
9377 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
9378 echo "local: *; };" >> $output_objdir/$libname.ver~
9379 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
9380 fi
9381 ;;
9382 esac
9383 else
9384 ld_shlibs=no
9385 fi
9386 ;;
9387
9388 netbsd*)
9389 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
9390 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
9391 wlarc=
9392 else
9393 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9394 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9395 fi
9396 ;;
9397
9398 solaris*)
9399 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
9400 ld_shlibs=no
9401 cat <<_LT_EOF 1>&2
9402
9403*** Warning: The releases 2.8.* of the GNU linker cannot reliably
9404*** create shared libraries on Solaris systems. Therefore, libtool
9405*** is disabling shared libraries support. We urge you to upgrade GNU
9406*** binutils to release 2.9.1 or newer. Another option is to modify
9407*** your PATH or compiler configuration so that the native linker is
9408*** used, and then restart.
9409
9410_LT_EOF
9411 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
9412 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9413 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9414 else
9415 ld_shlibs=no
9416 fi
9417 ;;
9418
9419 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
9420 case `$LD -v 2>&1` in
9421 *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
9422 ld_shlibs=no
9423 cat <<_LT_EOF 1>&2
9424
9425*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
9426*** reliably create shared libraries on SCO systems. Therefore, libtool
9427*** is disabling shared libraries support. We urge you to upgrade GNU
9428*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
9429*** your PATH or compiler configuration so that the native linker is
9430*** used, and then restart.
9431
9432_LT_EOF
9433 ;;
9434 *)
9435 # For security reasons, it is highly recommended that you always
9436 # use absolute paths for naming shared libraries, and exclude the
9437 # DT_RUNPATH tag from executables and libraries. But doing so
9438 # requires that you compile everything twice, which is a pain.
9439 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
9440 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9441 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9442 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9443 else
9444 ld_shlibs=no
9445 fi
9446 ;;
9447 esac
9448 ;;
9449
9450 sunos4*)
9451 archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
9452 wlarc=
9453 hardcode_direct=yes
9454 hardcode_shlibpath_var=no
9455 ;;
9456
9457 *)
9458 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
9459 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9460 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
9461 else
9462 ld_shlibs=no
9463 fi
9464 ;;
9465 esac
9466
9467 if test "$ld_shlibs" = no; then
9468 runpath_var=
9469 hardcode_libdir_flag_spec=
9470 export_dynamic_flag_spec=
9471 whole_archive_flag_spec=
9472 fi
9473 else
9474 # PORTME fill in a description of your system's linker (not GNU ld)
9475 case $host_os in
9476 aix3*)
9477 allow_undefined_flag=unsupported
9478 always_export_symbols=yes
9479 archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
9480 # Note: this linker hardcodes the directories in LIBPATH if there
9481 # are no directories specified by -L.
9482 hardcode_minus_L=yes
9483 if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
9484 # Neither direct hardcoding nor static linking is supported with a
9485 # broken collect2.
9486 hardcode_direct=unsupported
9487 fi
9488 ;;
9489
9490 aix[4-9]*)
9491 if test "$host_cpu" = ia64; then
9492 # On IA64, the linker does run time linking by default, so we don't
9493 # have to do anything special.
9494 aix_use_runtimelinking=no
9495 exp_sym_flag='-Bexport'
9496 no_entry_flag=""
9497 else
9498 # If we're using GNU nm, then we don't want the "-C" option.
9499 # -C means demangle to AIX nm, but means don't demangle with GNU nm
9500 # Also, AIX nm treats weak defined symbols like other global
9501 # defined symbols, whereas GNU nm marks them as "W".
9502 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
9503 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'
9504 else
9505 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'
9506 fi
9507 aix_use_runtimelinking=no
9508
9509 # Test if we are trying to use run time linking or normal
9510 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
9511 # need to do runtime linking.
9512 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
9513 for ld_flag in $LDFLAGS; do
9514 if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
9515 aix_use_runtimelinking=yes
9516 break
9517 fi
9518 done
9519 ;;
9520 esac
9521
9522 exp_sym_flag='-bexport'
9523 no_entry_flag='-bnoentry'
9524 fi
9525
9526 # When large executables or shared objects are built, AIX ld can
9527 # have problems creating the table of contents. If linking a library
9528 # or program results in "error TOC overflow" add -mminimal-toc to
9529 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
9530 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
9531
9532 archive_cmds=''
9533 hardcode_direct=yes
9534 hardcode_direct_absolute=yes
9535 hardcode_libdir_separator=':'
9536 link_all_deplibs=yes
9537 file_list_spec='${wl}-f,'
9538
9539 if test "$GCC" = yes; then
9540 case $host_os in aix4.[012]|aix4.[012].*)
9541 # We only want to do this on AIX 4.2 and lower, the check
9542 # below for broken collect2 doesn't work under 4.3+
9543 collect2name=`${CC} -print-prog-name=collect2`
9544 if test -f "$collect2name" &&
9545 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
9546 then
9547 # We have reworked collect2
9548 :
9549 else
9550 # We have old collect2
9551 hardcode_direct=unsupported
9552 # It fails to find uninstalled libraries when the uninstalled
9553 # path is not listed in the libpath. Setting hardcode_minus_L
9554 # to unsupported forces relinking
9555 hardcode_minus_L=yes
9556 hardcode_libdir_flag_spec='-L$libdir'
9557 hardcode_libdir_separator=
9558 fi
9559 ;;
9560 esac
9561 shared_flag='-shared'
9562 if test "$aix_use_runtimelinking" = yes; then
9563 shared_flag="$shared_flag "'${wl}-G'
9564 fi
9565 else
9566 # not using gcc
9567 if test "$host_cpu" = ia64; then
9568 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
9569 # chokes on -Wl,-G. The following line is correct:
9570 shared_flag='-G'
9571 else
9572 if test "$aix_use_runtimelinking" = yes; then
9573 shared_flag='${wl}-G'
9574 else
9575 shared_flag='${wl}-bM:SRE'
9576 fi
9577 fi
9578 fi
9579
9580 export_dynamic_flag_spec='${wl}-bexpall'
9581 # It seems that -bexpall does not export symbols beginning with
9582 # underscore (_), so it is better to generate a list of symbols to export.
9583 always_export_symbols=yes
9584 if test "$aix_use_runtimelinking" = yes; then
9585 # Warning - without using the other runtime loading flags (-brtl),
9586 # -berok will link without error, but may produce a broken library.
9587 allow_undefined_flag='-berok'
9588 # Determine the default libpath from the value encoded in an
9589 # empty executable.
9590 if test "${lt_cv_aix_libpath+set}" = set; then
9591 aix_libpath=$lt_cv_aix_libpath
9592else
9593 if ${lt_cv_aix_libpath_+:} false; then :
9594 $as_echo_n "(cached) " >&6
9595else
9596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9597/* end confdefs.h. */
9598
9599int
9600main ()
9601{
9602
9603 ;
9604 return 0;
9605}
9606_ACEOF
9607if ac_fn_c_try_link "$LINENO"; then :
9608
9609 lt_aix_libpath_sed='
9610 /Import File Strings/,/^$/ {
9611 /^0/ {
9612 s/^0 *\([^ ]*\) *$/\1/
9613 p
9614 }
9615 }'
9616 lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9617 # Check for a 64-bit object if we didn't find anything.
9618 if test -z "$lt_cv_aix_libpath_"; then
9619 lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9620 fi
9621fi
9622rm -f core conftest.err conftest.$ac_objext \
9623 conftest$ac_exeext conftest.$ac_ext
9624 if test -z "$lt_cv_aix_libpath_"; then
9625 lt_cv_aix_libpath_="/usr/lib:/lib"
9626 fi
9627
9628fi
9629
9630 aix_libpath=$lt_cv_aix_libpath_
9631fi
9632
9633 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
9634 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"
9635 else
9636 if test "$host_cpu" = ia64; then
9637 hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
9638 allow_undefined_flag="-z nodefs"
9639 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"
9640 else
9641 # Determine the default libpath from the value encoded in an
9642 # empty executable.
9643 if test "${lt_cv_aix_libpath+set}" = set; then
9644 aix_libpath=$lt_cv_aix_libpath
9645else
9646 if ${lt_cv_aix_libpath_+:} false; then :
9647 $as_echo_n "(cached) " >&6
9648else
9649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9650/* end confdefs.h. */
9651
9652int
9653main ()
9654{
9655
9656 ;
9657 return 0;
9658}
9659_ACEOF
9660if ac_fn_c_try_link "$LINENO"; then :
9661
9662 lt_aix_libpath_sed='
9663 /Import File Strings/,/^$/ {
9664 /^0/ {
9665 s/^0 *\([^ ]*\) *$/\1/
9666 p
9667 }
9668 }'
9669 lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9670 # Check for a 64-bit object if we didn't find anything.
9671 if test -z "$lt_cv_aix_libpath_"; then
9672 lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9673 fi
9674fi
9675rm -f core conftest.err conftest.$ac_objext \
9676 conftest$ac_exeext conftest.$ac_ext
9677 if test -z "$lt_cv_aix_libpath_"; then
9678 lt_cv_aix_libpath_="/usr/lib:/lib"
9679 fi
9680
9681fi
9682
9683 aix_libpath=$lt_cv_aix_libpath_
9684fi
9685
9686 hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
9687 # Warning - without using the other run time loading flags,
9688 # -berok will link without error, but may produce a broken library.
9689 no_undefined_flag=' ${wl}-bernotok'
9690 allow_undefined_flag=' ${wl}-berok'
9691 if test "$with_gnu_ld" = yes; then
9692 # We only use this code for GNU lds that support --whole-archive.
9693 whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
9694 else
9695 # Exported symbols can be pulled into shared objects from archives
9696 whole_archive_flag_spec='$convenience'
9697 fi
9698 archive_cmds_need_lc=yes
9699 # This is similar to how AIX traditionally builds its shared libraries.
9700 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'
9701 fi
9702 fi
9703 ;;
9704
9705 amigaos*)
9706 case $host_cpu in
9707 powerpc)
9708 # see comment about AmigaOS4 .so support
9709 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9710 archive_expsym_cmds=''
9711 ;;
9712 m68k)
9713 archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
9714 hardcode_libdir_flag_spec='-L$libdir'
9715 hardcode_minus_L=yes
9716 ;;
9717 esac
9718 ;;
9719
9720 bsdi[45]*)
9721 export_dynamic_flag_spec=-rdynamic
9722 ;;
9723
9724 cygwin* | mingw* | pw32* | cegcc*)
9725 # When not using gcc, we currently assume that we are using
9726 # Microsoft Visual C++.
9727 # hardcode_libdir_flag_spec is actually meaningless, as there is
9728 # no search path for DLLs.
9729 case $cc_basename in
9730 cl*)
9731 # Native MSVC
9732 hardcode_libdir_flag_spec=' '
9733 allow_undefined_flag=unsupported
9734 always_export_symbols=yes
9735 file_list_spec='@'
9736 # Tell ltmain to make .lib files, not .a files.
9737 libext=lib
9738 # Tell ltmain to make .dll files, not .so files.
9739 shrext_cmds=".dll"
9740 # FIXME: Setting linknames here is a bad hack.
9741 archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
9742 archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
9743 sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
9744 else
9745 sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
9746 fi~
9747 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
9748 linknames='
9749 # The linker will not automatically build a static lib if we build a DLL.
9750 # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
9751 enable_shared_with_static_runtimes=yes
9752 exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
9753 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
9754 # Don't use ranlib
9755 old_postinstall_cmds='chmod 644 $oldlib'
9756 postlink_cmds='lt_outputfile="@OUTPUT@"~
9757 lt_tool_outputfile="@TOOL_OUTPUT@"~
9758 case $lt_outputfile in
9759 *.exe|*.EXE) ;;
9760 *)
9761 lt_outputfile="$lt_outputfile.exe"
9762 lt_tool_outputfile="$lt_tool_outputfile.exe"
9763 ;;
9764 esac~
9765 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
9766 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
9767 $RM "$lt_outputfile.manifest";
9768 fi'
9769 ;;
9770 *)
9771 # Assume MSVC wrapper
9772 hardcode_libdir_flag_spec=' '
9773 allow_undefined_flag=unsupported
9774 # Tell ltmain to make .lib files, not .a files.
9775 libext=lib
9776 # Tell ltmain to make .dll files, not .so files.
9777 shrext_cmds=".dll"
9778 # FIXME: Setting linknames here is a bad hack.
9779 archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
9780 # The linker will automatically build a .lib file if we build a DLL.
9781 old_archive_from_new_cmds='true'
9782 # FIXME: Should let the user specify the lib program.
9783 old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
9784 enable_shared_with_static_runtimes=yes
9785 ;;
9786 esac
9787 ;;
9788
9789 darwin* | rhapsody*)
9790
9791
9792 archive_cmds_need_lc=no
9793 hardcode_direct=no
9794 hardcode_automatic=yes
9795 hardcode_shlibpath_var=unsupported
9796 if test "$lt_cv_ld_force_load" = "yes"; then
9797 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\"`'
9798
9799 else
9800 whole_archive_flag_spec=''
9801 fi
9802 link_all_deplibs=yes
9803 allow_undefined_flag="$_lt_dar_allow_undefined"
9804 case $cc_basename in
9805 ifort*) _lt_dar_can_shared=yes ;;
9806 *) _lt_dar_can_shared=$GCC ;;
9807 esac
9808 if test "$_lt_dar_can_shared" = "yes"; then
9809 output_verbose_link_cmd=func_echo_all
9810 archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
9811 module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
9812 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}"
9813 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}"
9814
9815 else
9816 ld_shlibs=no
9817 fi
9818
9819 ;;
9820
9821 dgux*)
9822 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9823 hardcode_libdir_flag_spec='-L$libdir'
9824 hardcode_shlibpath_var=no
9825 ;;
9826
9827 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
9828 # support. Future versions do this automatically, but an explicit c++rt0.o
9829 # does not break anything, and helps significantly (at the cost of a little
9830 # extra space).
9831 freebsd2.2*)
9832 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
9833 hardcode_libdir_flag_spec='-R$libdir'
9834 hardcode_direct=yes
9835 hardcode_shlibpath_var=no
9836 ;;
9837
9838 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
9839 freebsd2.*)
9840 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
9841 hardcode_direct=yes
9842 hardcode_minus_L=yes
9843 hardcode_shlibpath_var=no
9844 ;;
9845
9846 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
9847 freebsd* | dragonfly*)
9848 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
9849 hardcode_libdir_flag_spec='-R$libdir'
9850 hardcode_direct=yes
9851 hardcode_shlibpath_var=no
9852 ;;
9853
9854 hpux9*)
9855 if test "$GCC" = yes; then
9856 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'
9857 else
9858 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'
9859 fi
9860 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
9861 hardcode_libdir_separator=:
9862 hardcode_direct=yes
9863
9864 # hardcode_minus_L: Not really in the search PATH,
9865 # but as the default location of the library.
9866 hardcode_minus_L=yes
9867 export_dynamic_flag_spec='${wl}-E'
9868 ;;
9869
9870 hpux10*)
9871 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
9872 archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
9873 else
9874 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
9875 fi
9876 if test "$with_gnu_ld" = no; then
9877 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
9878 hardcode_libdir_separator=:
9879 hardcode_direct=yes
9880 hardcode_direct_absolute=yes
9881 export_dynamic_flag_spec='${wl}-E'
9882 # hardcode_minus_L: Not really in the search PATH,
9883 # but as the default location of the library.
9884 hardcode_minus_L=yes
9885 fi
9886 ;;
9887
9888 hpux11*)
9889 if test "$GCC" = yes && test "$with_gnu_ld" = no; then
9890 case $host_cpu in
9891 hppa*64*)
9892 archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9893 ;;
9894 ia64*)
9895 archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
9896 ;;
9897 *)
9898 archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
9899 ;;
9900 esac
9901 else
9902 case $host_cpu in
9903 hppa*64*)
9904 archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9905 ;;
9906 ia64*)
9907 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
9908 ;;
9909 *)
9910
9911 # Older versions of the 11.00 compiler do not understand -b yet
9912 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
9913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
9914$as_echo_n "checking if $CC understands -b... " >&6; }
9915if ${lt_cv_prog_compiler__b+:} false; then :
9916 $as_echo_n "(cached) " >&6
9917else
9918 lt_cv_prog_compiler__b=no
9919 save_LDFLAGS="$LDFLAGS"
9920 LDFLAGS="$LDFLAGS -b"
9921 echo "$lt_simple_link_test_code" > conftest.$ac_ext
9922 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
9923 # The linker can only warn and ignore the option if not recognized
9924 # So say no if there are warnings
9925 if test -s conftest.err; then
9926 # Append any errors to the config.log.
9927 cat conftest.err 1>&5
9928 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
9929 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
9930 if diff conftest.exp conftest.er2 >/dev/null; then
9931 lt_cv_prog_compiler__b=yes
9932 fi
9933 else
9934 lt_cv_prog_compiler__b=yes
9935 fi
9936 fi
9937 $RM -r conftest*
9938 LDFLAGS="$save_LDFLAGS"
9939
9940fi
9941{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
9942$as_echo "$lt_cv_prog_compiler__b" >&6; }
9943
9944if test x"$lt_cv_prog_compiler__b" = xyes; then
9945 archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
9946else
9947 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
9948fi
9949
9950 ;;
9951 esac
9952 fi
9953 if test "$with_gnu_ld" = no; then
9954 hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
9955 hardcode_libdir_separator=:
9956
9957 case $host_cpu in
9958 hppa*64*|ia64*)
9959 hardcode_direct=no
9960 hardcode_shlibpath_var=no
9961 ;;
9962 *)
9963 hardcode_direct=yes
9964 hardcode_direct_absolute=yes
9965 export_dynamic_flag_spec='${wl}-E'
9966
9967 # hardcode_minus_L: Not really in the search PATH,
9968 # but as the default location of the library.
9969 hardcode_minus_L=yes
9970 ;;
9971 esac
9972 fi
9973 ;;
9974
9975 irix5* | irix6* | nonstopux*)
9976 if test "$GCC" = yes; then
9977 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'
9978 # Try to use the -exported_symbol ld option, if it does not
9979 # work, assume that -exports_file does not work either and
9980 # implicitly export all symbols.
9981 # This should be the same for all languages, so no per-tag cache variable.
9982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
9983$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
9984if ${lt_cv_irix_exported_symbol+:} false; then :
9985 $as_echo_n "(cached) " >&6
9986else
9987 save_LDFLAGS="$LDFLAGS"
9988 LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
9989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9990/* end confdefs.h. */
9991int foo (void) { return 0; }
9992_ACEOF
9993if ac_fn_c_try_link "$LINENO"; then :
9994 lt_cv_irix_exported_symbol=yes
9995else
9996 lt_cv_irix_exported_symbol=no
9997fi
9998rm -f core conftest.err conftest.$ac_objext \
9999 conftest$ac_exeext conftest.$ac_ext
10000 LDFLAGS="$save_LDFLAGS"
10001fi
10002{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
10003$as_echo "$lt_cv_irix_exported_symbol" >&6; }
10004 if test "$lt_cv_irix_exported_symbol" = yes; then
10005 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'
10006 fi
10007 else
10008 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'
10009 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'
10010 fi
10011 archive_cmds_need_lc='no'
10012 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
10013 hardcode_libdir_separator=:
10014 inherit_rpath=yes
10015 link_all_deplibs=yes
10016 ;;
10017
10018 netbsd*)
10019 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
10020 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
10021 else
10022 archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
10023 fi
10024 hardcode_libdir_flag_spec='-R$libdir'
10025 hardcode_direct=yes
10026 hardcode_shlibpath_var=no
10027 ;;
10028
10029 newsos6)
10030 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10031 hardcode_direct=yes
10032 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
10033 hardcode_libdir_separator=:
10034 hardcode_shlibpath_var=no
10035 ;;
10036
10037 *nto* | *qnx*)
10038 ;;
10039
10040 openbsd*)
10041 if test -f /usr/libexec/ld.so; then
10042 hardcode_direct=yes
10043 hardcode_shlibpath_var=no
10044 hardcode_direct_absolute=yes
10045 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
10046 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
10047 archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
10048 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
10049 export_dynamic_flag_spec='${wl}-E'
10050 else
10051 case $host_os in
10052 openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
10053 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
10054 hardcode_libdir_flag_spec='-R$libdir'
10055 ;;
10056 *)
10057 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
10058 hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
10059 ;;
10060 esac
10061 fi
10062 else
10063 ld_shlibs=no
10064 fi
10065 ;;
10066
10067 os2*)
10068 hardcode_libdir_flag_spec='-L$libdir'
10069 hardcode_minus_L=yes
10070 allow_undefined_flag=unsupported
10071 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'
10072 old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
10073 ;;
10074
10075 osf3*)
10076 if test "$GCC" = yes; then
10077 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
10078 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'
10079 else
10080 allow_undefined_flag=' -expect_unresolved \*'
10081 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'
10082 fi
10083 archive_cmds_need_lc='no'
10084 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
10085 hardcode_libdir_separator=:
10086 ;;
10087
10088 osf4* | osf5*) # as osf3* with the addition of -msym flag
10089 if test "$GCC" = yes; then
10090 allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
10091 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'
10092 hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
10093 else
10094 allow_undefined_flag=' -expect_unresolved \*'
10095 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'
10096 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~
10097 $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'
10098
10099 # Both c and cxx compiler support -rpath directly
10100 hardcode_libdir_flag_spec='-rpath $libdir'
10101 fi
10102 archive_cmds_need_lc='no'
10103 hardcode_libdir_separator=:
10104 ;;
10105
10106 solaris*)
10107 no_undefined_flag=' -z defs'
10108 if test "$GCC" = yes; then
10109 wlarc='${wl}'
10110 archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
10111 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
10112 $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'
10113 else
10114 case `$CC -V 2>&1` in
10115 *"Compilers 5.0"*)
10116 wlarc=''
10117 archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
10118 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
10119 $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
10120 ;;
10121 *)
10122 wlarc='${wl}'
10123 archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
10124 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
10125 $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
10126 ;;
10127 esac
10128 fi
10129 hardcode_libdir_flag_spec='-R$libdir'
10130 hardcode_shlibpath_var=no
10131 case $host_os in
10132 solaris2.[0-5] | solaris2.[0-5].*) ;;
10133 *)
10134 # The compiler driver will combine and reorder linker options,
10135 # but understands `-z linker_flag'. GCC discards it without `$wl',
10136 # but is careful enough not to reorder.
10137 # Supported since Solaris 2.6 (maybe 2.5.1?)
10138 if test "$GCC" = yes; then
10139 whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
10140 else
10141 whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
10142 fi
10143 ;;
10144 esac
10145 link_all_deplibs=yes
10146 ;;
10147
10148 sunos4*)
10149 if test "x$host_vendor" = xsequent; then
10150 # Use $CC to link under sequent, because it throws in some extra .o
10151 # files that make .init and .fini sections work.
10152 archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
10153 else
10154 archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
10155 fi
10156 hardcode_libdir_flag_spec='-L$libdir'
10157 hardcode_direct=yes
10158 hardcode_minus_L=yes
10159 hardcode_shlibpath_var=no
10160 ;;
10161
10162 sysv4)
10163 case $host_vendor in
10164 sni)
10165 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10166 hardcode_direct=yes # is this really true???
10167 ;;
10168 siemens)
10169 ## LD is ld it makes a PLAMLIB
10170 ## CC just makes a GrossModule.
10171 archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
10172 reload_cmds='$CC -r -o $output$reload_objs'
10173 hardcode_direct=no
10174 ;;
10175 motorola)
10176 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10177 hardcode_direct=no #Motorola manual says yes, but my tests say they lie
10178 ;;
10179 esac
10180 runpath_var='LD_RUN_PATH'
10181 hardcode_shlibpath_var=no
10182 ;;
10183
10184 sysv4.3*)
10185 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10186 hardcode_shlibpath_var=no
10187 export_dynamic_flag_spec='-Bexport'
10188 ;;
10189
10190 sysv4*MP*)
10191 if test -d /usr/nec; then
10192 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10193 hardcode_shlibpath_var=no
10194 runpath_var=LD_RUN_PATH
10195 hardcode_runpath_var=yes
10196 ld_shlibs=yes
10197 fi
10198 ;;
10199
10200 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
10201 no_undefined_flag='${wl}-z,text'
10202 archive_cmds_need_lc=no
10203 hardcode_shlibpath_var=no
10204 runpath_var='LD_RUN_PATH'
10205
10206 if test "$GCC" = yes; then
10207 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10208 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10209 else
10210 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10211 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10212 fi
10213 ;;
10214
10215 sysv5* | sco3.2v5* | sco5v6*)
10216 # Note: We can NOT use -z defs as we might desire, because we do not
10217 # link with -lc, and that would cause any symbols used from libc to
10218 # always be unresolved, which means just about no library would
10219 # ever link correctly. If we're not using GNU ld we use -z text
10220 # though, which does catch some bad symbols but isn't as heavy-handed
10221 # as -z defs.
10222 no_undefined_flag='${wl}-z,text'
10223 allow_undefined_flag='${wl}-z,nodefs'
10224 archive_cmds_need_lc=no
10225 hardcode_shlibpath_var=no
10226 hardcode_libdir_flag_spec='${wl}-R,$libdir'
10227 hardcode_libdir_separator=':'
10228 link_all_deplibs=yes
10229 export_dynamic_flag_spec='${wl}-Bexport'
10230 runpath_var='LD_RUN_PATH'
10231
10232 if test "$GCC" = yes; then
10233 archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10234 archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10235 else
10236 archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10237 archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
10238 fi
10239 ;;
10240
10241 uts4*)
10242 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
10243 hardcode_libdir_flag_spec='-L$libdir'
10244 hardcode_shlibpath_var=no
10245 ;;
10246
10247 *)
10248 ld_shlibs=no
10249 ;;
10250 esac
10251
10252 if test x$host_vendor = xsni; then
10253 case $host in
10254 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
10255 export_dynamic_flag_spec='${wl}-Blargedynsym'
10256 ;;
10257 esac
10258 fi
10259 fi
10260
10261{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
10262$as_echo "$ld_shlibs" >&6; }
10263test "$ld_shlibs" = no && can_build_shared=no
10264
10265with_gnu_ld=$with_gnu_ld
10266
10267
10268
10269
10270
10271
10272
10273
10274
10275
10276
10277
10278
10279
10280
10281#
10282# Do we need to explicitly link libc?
10283#
10284case "x$archive_cmds_need_lc" in
10285x|xyes)
10286 # Assume -lc should be added
10287 archive_cmds_need_lc=yes
10288
10289 if test "$enable_shared" = yes && test "$GCC" = yes; then
10290 case $archive_cmds in
10291 *'~'*)
10292 # FIXME: we may have to deal with multi-command sequences.
10293 ;;
10294 '$CC '*)
10295 # Test whether the compiler implicitly links with -lc since on some
10296 # systems, -lgcc has to come before -lc. If gcc already passes -lc
10297 # to ld, don't add -lc before -lgcc.
10298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
10299$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
10300if ${lt_cv_archive_cmds_need_lc+:} false; then :
10301 $as_echo_n "(cached) " >&6
10302else
10303 $RM conftest*
10304 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
10305
10306 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
10307 (eval $ac_compile) 2>&5
10308 ac_status=$?
10309 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
10310 test $ac_status = 0; } 2>conftest.err; then
10311 soname=conftest
10312 lib=conftest
10313 libobjs=conftest.$ac_objext
10314 deplibs=
10315 wl=$lt_prog_compiler_wl
10316 pic_flag=$lt_prog_compiler_pic
10317 compiler_flags=-v
10318 linker_flags=-v
10319 verstring=
10320 output_objdir=.
10321 libname=conftest
10322 lt_save_allow_undefined_flag=$allow_undefined_flag
10323 allow_undefined_flag=
10324 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
10325 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
10326 ac_status=$?
10327 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
10328 test $ac_status = 0; }
10329 then
10330 lt_cv_archive_cmds_need_lc=no
10331 else
10332 lt_cv_archive_cmds_need_lc=yes
10333 fi
10334 allow_undefined_flag=$lt_save_allow_undefined_flag
10335 else
10336 cat conftest.err 1>&5
10337 fi
10338 $RM conftest*
10339
10340fi
10341{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
10342$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
10343 archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
10344 ;;
10345 esac
10346 fi
10347 ;;
10348esac
10349
10350
10351
10352
10353
10354
10355
10356
10357
10358
10359
10360
10361
10362
10363
10364
10365
10366
10367
10368
10369
10370
10371
10372
10373
10374
10375
10376
10377
10378
10379
10380
10381
10382
10383
10384
10385
10386
10387
10388
10389
10390
10391
10392
10393
10394
10395
10396
10397
10398
10399
10400
10401
10402
10403
10404
10405
10406
10407
10408
10409
10410
10411
10412
10413
10414
10415
10416
10417
10418
10419
10420
10421
10422
10423
10424
10425
10426
10427
10428
10429
10430
10431
10432
10433
10434
10435
10436
10437
10438
10439
10440
10441
10442
10443
10444
10445
10446
10447
10448
10449
10450
10451
10452
10453
10454
10455
10456
10457
10458
10459
10460
10461
10462
10463
10464
10465
10466
10467
10468
10469
10470
10471
10472
10473
10474
10475
10476
10477
10478
10479
10480
10481
10482
10483
10484
10485
10486
10487
10488
10489
10490
10491
10492
10493
10494
10495
10496
10497
10498
10499
10500
10501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
10502$as_echo_n "checking dynamic linker characteristics... " >&6; }
10503
10504if test "$GCC" = yes; then
10505 case $host_os in
10506 darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
10507 *) lt_awk_arg="/^libraries:/" ;;
10508 esac
10509 case $host_os in
10510 mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
10511 *) lt_sed_strip_eq="s,=/,/,g" ;;
10512 esac
10513 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
10514 case $lt_search_path_spec in
10515 *\;*)
10516 # if the path contains ";" then we assume it to be the separator
10517 # otherwise default to the standard path separator (i.e. ":") - it is
10518 # assumed that no part of a normal pathname contains ";" but that should
10519 # okay in the real world where ";" in dirpaths is itself problematic.
10520 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
10521 ;;
10522 *)
10523 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
10524 ;;
10525 esac
10526 # Ok, now we have the path, separated by spaces, we can step through it
10527 # and add multilib dir if necessary.
10528 lt_tmp_lt_search_path_spec=
10529 lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
10530 for lt_sys_path in $lt_search_path_spec; do
10531 if test -d "$lt_sys_path/$lt_multi_os_dir"; then
10532 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
10533 else
10534 test -d "$lt_sys_path" && \
10535 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
10536 fi
10537 done
10538 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
10539BEGIN {RS=" "; FS="/|\n";} {
10540 lt_foo="";
10541 lt_count=0;
10542 for (lt_i = NF; lt_i > 0; lt_i--) {
10543 if ($lt_i != "" && $lt_i != ".") {
10544 if ($lt_i == "..") {
10545 lt_count++;
10546 } else {
10547 if (lt_count == 0) {
10548 lt_foo="/" $lt_i lt_foo;
10549 } else {
10550 lt_count--;
10551 }
10552 }
10553 }
10554 }
10555 if (lt_foo != "") { lt_freq[lt_foo]++; }
10556 if (lt_freq[lt_foo] == 1) { print lt_foo; }
10557}'`
10558 # AWK program above erroneously prepends '/' to C:/dos/paths
10559 # for these hosts.
10560 case $host_os in
10561 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
10562 $SED 's,/\([A-Za-z]:\),\1,g'` ;;
10563 esac
10564 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
10565else
10566 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
10567fi
10568library_names_spec=
10569libname_spec='lib$name'
10570soname_spec=
10571shrext_cmds=".so"
10572postinstall_cmds=
10573postuninstall_cmds=
10574finish_cmds=
10575finish_eval=
10576shlibpath_var=
10577shlibpath_overrides_runpath=unknown
10578version_type=none
10579dynamic_linker="$host_os ld.so"
10580sys_lib_dlsearch_path_spec="/lib /usr/lib"
10581need_lib_prefix=unknown
10582hardcode_into_libs=no
10583
10584# when you set need_version to no, make sure it does not cause -set_version
10585# flags to be left without arguments
10586need_version=unknown
10587
10588case $host_os in
10589aix3*)
10590 version_type=linux # correct to gnu/linux during the next big refactor
10591 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
10592 shlibpath_var=LIBPATH
10593
10594 # AIX 3 has no versioning support, so we append a major version to the name.
10595 soname_spec='${libname}${release}${shared_ext}$major'
10596 ;;
10597
10598aix[4-9]*)
10599 version_type=linux # correct to gnu/linux during the next big refactor
10600 need_lib_prefix=no
10601 need_version=no
10602 hardcode_into_libs=yes
10603 if test "$host_cpu" = ia64; then
10604 # AIX 5 supports IA64
10605 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
10606 shlibpath_var=LD_LIBRARY_PATH
10607 else
10608 # With GCC up to 2.95.x, collect2 would create an import file
10609 # for dependence libraries. The import file would start with
10610 # the line `#! .'. This would cause the generated library to
10611 # depend on `.', always an invalid library. This was fixed in
10612 # development snapshots of GCC prior to 3.0.
10613 case $host_os in
10614 aix4 | aix4.[01] | aix4.[01].*)
10615 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
10616 echo ' yes '
10617 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
10618 :
10619 else
10620 can_build_shared=no
10621 fi
10622 ;;
10623 esac
10624 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
10625 # soname into executable. Probably we can add versioning support to
10626 # collect2, so additional links can be useful in future.
10627 if test "$aix_use_runtimelinking" = yes; then
10628 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
10629 # instead of lib<name>.a to let people know that these are not
10630 # typical AIX shared libraries.
10631 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10632 else
10633 # We preserve .a as extension for shared libraries through AIX4.2
10634 # and later when we are not doing run time linking.
10635 library_names_spec='${libname}${release}.a $libname.a'
10636 soname_spec='${libname}${release}${shared_ext}$major'
10637 fi
10638 shlibpath_var=LIBPATH
10639 fi
10640 ;;
10641
10642amigaos*)
10643 case $host_cpu in
10644 powerpc)
10645 # Since July 2007 AmigaOS4 officially supports .so libraries.
10646 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
10647 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10648 ;;
10649 m68k)
10650 library_names_spec='$libname.ixlibrary $libname.a'
10651 # Create ${libname}_ixlibrary.a entries in /sys/libs.
10652 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'
10653 ;;
10654 esac
10655 ;;
10656
10657beos*)
10658 library_names_spec='${libname}${shared_ext}'
10659 dynamic_linker="$host_os ld.so"
10660 shlibpath_var=LIBRARY_PATH
10661 ;;
10662
10663bsdi[45]*)
10664 version_type=linux # correct to gnu/linux during the next big refactor
10665 need_version=no
10666 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10667 soname_spec='${libname}${release}${shared_ext}$major'
10668 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
10669 shlibpath_var=LD_LIBRARY_PATH
10670 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
10671 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
10672 # the default ld.so.conf also contains /usr/contrib/lib and
10673 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
10674 # libtool to hard-code these into programs
10675 ;;
10676
10677cygwin* | mingw* | pw32* | cegcc*)
10678 version_type=windows
10679 shrext_cmds=".dll"
10680 need_version=no
10681 need_lib_prefix=no
10682
10683 case $GCC,$cc_basename in
10684 yes,*)
10685 # gcc
10686 library_names_spec='$libname.dll.a'
10687 # DLL is installed to $(libdir)/../bin by postinstall_cmds
10688 postinstall_cmds='base_file=`basename \${file}`~
10689 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
10690 dldir=$destdir/`dirname \$dlpath`~
10691 test -d \$dldir || mkdir -p \$dldir~
10692 $install_prog $dir/$dlname \$dldir/$dlname~
10693 chmod a+x \$dldir/$dlname~
10694 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
10695 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
10696 fi'
10697 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
10698 dlpath=$dir/\$dldll~
10699 $RM \$dlpath'
10700 shlibpath_overrides_runpath=yes
10701
10702 case $host_os in
10703 cygwin*)
10704 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
10705 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
10706
10707 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
10708 ;;
10709 mingw* | cegcc*)
10710 # MinGW DLLs use traditional 'lib' prefix
10711 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
10712 ;;
10713 pw32*)
10714 # pw32 DLLs use 'pw' prefix rather than 'lib'
10715 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
10716 ;;
10717 esac
10718 dynamic_linker='Win32 ld.exe'
10719 ;;
10720
10721 *,cl*)
10722 # Native MSVC
10723 libname_spec='$name'
10724 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
10725 library_names_spec='${libname}.dll.lib'
10726
10727 case $build_os in
10728 mingw*)
10729 sys_lib_search_path_spec=
10730 lt_save_ifs=$IFS
10731 IFS=';'
10732 for lt_path in $LIB
10733 do
10734 IFS=$lt_save_ifs
10735 # Let DOS variable expansion print the short 8.3 style file name.
10736 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
10737 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
10738 done
10739 IFS=$lt_save_ifs
10740 # Convert to MSYS style.
10741 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
10742 ;;
10743 cygwin*)
10744 # Convert to unix form, then to dos form, then back to unix form
10745 # but this time dos style (no spaces!) so that the unix form looks
10746 # like /cygdrive/c/PROGRA~1:/cygdr...
10747 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
10748 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
10749 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
10750 ;;
10751 *)
10752 sys_lib_search_path_spec="$LIB"
10753 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
10754 # It is most probably a Windows format PATH.
10755 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
10756 else
10757 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
10758 fi
10759 # FIXME: find the short name or the path components, as spaces are
10760 # common. (e.g. "Program Files" -> "PROGRA~1")
10761 ;;
10762 esac
10763
10764 # DLL is installed to $(libdir)/../bin by postinstall_cmds
10765 postinstall_cmds='base_file=`basename \${file}`~
10766 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
10767 dldir=$destdir/`dirname \$dlpath`~
10768 test -d \$dldir || mkdir -p \$dldir~
10769 $install_prog $dir/$dlname \$dldir/$dlname'
10770 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
10771 dlpath=$dir/\$dldll~
10772 $RM \$dlpath'
10773 shlibpath_overrides_runpath=yes
10774 dynamic_linker='Win32 link.exe'
10775 ;;
10776
10777 *)
10778 # Assume MSVC wrapper
10779 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
10780 dynamic_linker='Win32 ld.exe'
10781 ;;
10782 esac
10783 # FIXME: first we should search . and the directory the executable is in
10784 shlibpath_var=PATH
10785 ;;
10786
10787darwin* | rhapsody*)
10788 dynamic_linker="$host_os dyld"
10789 version_type=darwin
10790 need_lib_prefix=no
10791 need_version=no
10792 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
10793 soname_spec='${libname}${release}${major}$shared_ext'
10794 shlibpath_overrides_runpath=yes
10795 shlibpath_var=DYLD_LIBRARY_PATH
10796 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
10797
10798 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
10799 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
10800 ;;
10801
10802dgux*)
10803 version_type=linux # correct to gnu/linux during the next big refactor
10804 need_lib_prefix=no
10805 need_version=no
10806 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
10807 soname_spec='${libname}${release}${shared_ext}$major'
10808 shlibpath_var=LD_LIBRARY_PATH
10809 ;;
10810
10811freebsd* | dragonfly*)
10812 # DragonFly does not have aout. When/if they implement a new
10813 # versioning mechanism, adjust this.
10814 if test -x /usr/bin/objformat; then
10815 objformat=`/usr/bin/objformat`
10816 else
10817 case $host_os in
10818 freebsd[23].*) objformat=aout ;;
10819 *) objformat=elf ;;
10820 esac
10821 fi
10822 version_type=freebsd-$objformat
10823 case $version_type in
10824 freebsd-elf*)
10825 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
10826 need_version=no
10827 need_lib_prefix=no
10828 ;;
10829 freebsd-*)
10830 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
10831 need_version=yes
10832 ;;
10833 esac
10834 shlibpath_var=LD_LIBRARY_PATH
10835 case $host_os in
10836 freebsd2.*)
10837 shlibpath_overrides_runpath=yes
10838 ;;
10839 freebsd3.[01]* | freebsdelf3.[01]*)
10840 shlibpath_overrides_runpath=yes
10841 hardcode_into_libs=yes
10842 ;;
10843 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
10844 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
10845 shlibpath_overrides_runpath=no
10846 hardcode_into_libs=yes
10847 ;;
10848 *) # from 4.6 on, and DragonFly
10849 shlibpath_overrides_runpath=yes
10850 hardcode_into_libs=yes
10851 ;;
10852 esac
10853 ;;
10854
10855gnu*)
10856 version_type=linux # correct to gnu/linux during the next big refactor
10857 need_lib_prefix=no
10858 need_version=no
10859 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
10860 soname_spec='${libname}${release}${shared_ext}$major'
10861 shlibpath_var=LD_LIBRARY_PATH
10862 shlibpath_overrides_runpath=no
10863 hardcode_into_libs=yes
10864 ;;
10865
10866haiku*)
10867 version_type=linux # correct to gnu/linux during the next big refactor
10868 need_lib_prefix=no
10869 need_version=no
10870 dynamic_linker="$host_os runtime_loader"
10871 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
10872 soname_spec='${libname}${release}${shared_ext}$major'
10873 shlibpath_var=LIBRARY_PATH
10874 shlibpath_overrides_runpath=yes
10875 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
10876 hardcode_into_libs=yes
10877 ;;
10878
10879hpux9* | hpux10* | hpux11*)
10880 # Give a soname corresponding to the major version so that dld.sl refuses to
10881 # link against other versions.
10882 version_type=sunos
10883 need_lib_prefix=no
10884 need_version=no
10885 case $host_cpu in
10886 ia64*)
10887 shrext_cmds='.so'
10888 hardcode_into_libs=yes
10889 dynamic_linker="$host_os dld.so"
10890 shlibpath_var=LD_LIBRARY_PATH
10891 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
10892 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10893 soname_spec='${libname}${release}${shared_ext}$major'
10894 if test "X$HPUX_IA64_MODE" = X32; then
10895 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
10896 else
10897 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
10898 fi
10899 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
10900 ;;
10901 hppa*64*)
10902 shrext_cmds='.sl'
10903 hardcode_into_libs=yes
10904 dynamic_linker="$host_os dld.sl"
10905 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
10906 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
10907 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10908 soname_spec='${libname}${release}${shared_ext}$major'
10909 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
10910 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
10911 ;;
10912 *)
10913 shrext_cmds='.sl'
10914 dynamic_linker="$host_os dld.sl"
10915 shlibpath_var=SHLIB_PATH
10916 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
10917 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10918 soname_spec='${libname}${release}${shared_ext}$major'
10919 ;;
10920 esac
10921 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
10922 postinstall_cmds='chmod 555 $lib'
10923 # or fails outright, so override atomically:
10924 install_override_mode=555
10925 ;;
10926
10927interix[3-9]*)
10928 version_type=linux # correct to gnu/linux during the next big refactor
10929 need_lib_prefix=no
10930 need_version=no
10931 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
10932 soname_spec='${libname}${release}${shared_ext}$major'
10933 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
10934 shlibpath_var=LD_LIBRARY_PATH
10935 shlibpath_overrides_runpath=no
10936 hardcode_into_libs=yes
10937 ;;
10938
10939irix5* | irix6* | nonstopux*)
10940 case $host_os in
10941 nonstopux*) version_type=nonstopux ;;
10942 *)
10943 if test "$lt_cv_prog_gnu_ld" = yes; then
10944 version_type=linux # correct to gnu/linux during the next big refactor
10945 else
10946 version_type=irix
10947 fi ;;
10948 esac
10949 need_lib_prefix=no
10950 need_version=no
10951 soname_spec='${libname}${release}${shared_ext}$major'
10952 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
10953 case $host_os in
10954 irix5* | nonstopux*)
10955 libsuff= shlibsuff=
10956 ;;
10957 *)
10958 case $LD in # libtool.m4 will add one of these switches to LD
10959 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
10960 libsuff= shlibsuff= libmagic=32-bit;;
10961 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
10962 libsuff=32 shlibsuff=N32 libmagic=N32;;
10963 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
10964 libsuff=64 shlibsuff=64 libmagic=64-bit;;
10965 *) libsuff= shlibsuff= libmagic=never-match;;
10966 esac
10967 ;;
10968 esac
10969 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
10970 shlibpath_overrides_runpath=no
10971 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
10972 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
10973 hardcode_into_libs=yes
10974 ;;
10975
10976# No shared lib support for Linux oldld, aout, or coff.
10977linux*oldld* | linux*aout* | linux*coff*)
10978 dynamic_linker=no
10979 ;;
10980
10981# This must be glibc/ELF.
10982linux* | k*bsd*-gnu | kopensolaris*-gnu)
10983 version_type=linux # correct to gnu/linux during the next big refactor
10984 need_lib_prefix=no
10985 need_version=no
10986 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10987 soname_spec='${libname}${release}${shared_ext}$major'
10988 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
10989 shlibpath_var=LD_LIBRARY_PATH
10990 shlibpath_overrides_runpath=no
10991
10992 # Some binutils ld are patched to set DT_RUNPATH
10993 if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
10994 $as_echo_n "(cached) " >&6
10995else
10996 lt_cv_shlibpath_overrides_runpath=no
10997 save_LDFLAGS=$LDFLAGS
10998 save_libdir=$libdir
10999 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
11000 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
11001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11002/* end confdefs.h. */
11003
11004int
11005main ()
11006{
11007
11008 ;
11009 return 0;
11010}
11011_ACEOF
11012if ac_fn_c_try_link "$LINENO"; then :
11013 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
11014 lt_cv_shlibpath_overrides_runpath=yes
11015fi
11016fi
11017rm -f core conftest.err conftest.$ac_objext \
11018 conftest$ac_exeext conftest.$ac_ext
11019 LDFLAGS=$save_LDFLAGS
11020 libdir=$save_libdir
11021
11022fi
11023
11024 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
11025
11026 # This implies no fast_install, which is unacceptable.
11027 # Some rework will be needed to allow for fast_install
11028 # before this can be enabled.
11029 hardcode_into_libs=yes
11030
11031 # Append ld.so.conf contents to the search path
11032 if test -f /etc/ld.so.conf; then
11033 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' ' '`
11034 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
11035 fi
11036
11037 # We used to test for /lib/ld.so.1 and disable shared libraries on
11038 # powerpc, because MkLinux only supported shared libraries with the
11039 # GNU dynamic linker. Since this was broken with cross compilers,
11040 # most powerpc-linux boxes support dynamic linking these days and
11041 # people can always --disable-shared, the test was removed, and we
11042 # assume the GNU/Linux dynamic linker is in use.
11043 dynamic_linker='GNU/Linux ld.so'
11044 ;;
11045
11046netbsd*)
11047 version_type=sunos
11048 need_lib_prefix=no
11049 need_version=no
11050 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
11051 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
11052 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
11053 dynamic_linker='NetBSD (a.out) ld.so'
11054 else
11055 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
11056 soname_spec='${libname}${release}${shared_ext}$major'
11057 dynamic_linker='NetBSD ld.elf_so'
11058 fi
11059 shlibpath_var=LD_LIBRARY_PATH
11060 shlibpath_overrides_runpath=yes
11061 hardcode_into_libs=yes
11062 ;;
11063
11064newsos6)
11065 version_type=linux # correct to gnu/linux during the next big refactor
11066 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
11067 shlibpath_var=LD_LIBRARY_PATH
11068 shlibpath_overrides_runpath=yes
11069 ;;
11070
11071*nto* | *qnx*)
11072 version_type=qnx
11073 need_lib_prefix=no
11074 need_version=no
11075 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
11076 soname_spec='${libname}${release}${shared_ext}$major'
11077 shlibpath_var=LD_LIBRARY_PATH
11078 shlibpath_overrides_runpath=no
11079 hardcode_into_libs=yes
11080 dynamic_linker='ldqnx.so'
11081 ;;
11082
11083openbsd*)
11084 version_type=sunos
11085 sys_lib_dlsearch_path_spec="/usr/lib"
11086 need_lib_prefix=no
11087 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
11088 case $host_os in
11089 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
11090 *) need_version=no ;;
11091 esac
11092 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
11093 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
11094 shlibpath_var=LD_LIBRARY_PATH
11095 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
11096 case $host_os in
11097 openbsd2.[89] | openbsd2.[89].*)
11098 shlibpath_overrides_runpath=no
11099 ;;
11100 *)
11101 shlibpath_overrides_runpath=yes
11102 ;;
11103 esac
11104 else
11105 shlibpath_overrides_runpath=yes
11106 fi
11107 ;;
11108
11109os2*)
11110 libname_spec='$name'
11111 shrext_cmds=".dll"
11112 need_lib_prefix=no
11113 library_names_spec='$libname${shared_ext} $libname.a'
11114 dynamic_linker='OS/2 ld.exe'
11115 shlibpath_var=LIBPATH
11116 ;;
11117
11118osf3* | osf4* | osf5*)
11119 version_type=osf
11120 need_lib_prefix=no
11121 need_version=no
11122 soname_spec='${libname}${release}${shared_ext}$major'
11123 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
11124 shlibpath_var=LD_LIBRARY_PATH
11125 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
11126 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
11127 ;;
11128
11129rdos*)
11130 dynamic_linker=no
11131 ;;
11132
11133solaris*)
11134 version_type=linux # correct to gnu/linux during the next big refactor
11135 need_lib_prefix=no
11136 need_version=no
11137 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
11138 soname_spec='${libname}${release}${shared_ext}$major'
11139 shlibpath_var=LD_LIBRARY_PATH
11140 shlibpath_overrides_runpath=yes
11141 hardcode_into_libs=yes
11142 # ldd complains unless libraries are executable
11143 postinstall_cmds='chmod +x $lib'
11144 ;;
11145
11146sunos4*)
11147 version_type=sunos
11148 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
11149 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
11150 shlibpath_var=LD_LIBRARY_PATH
11151 shlibpath_overrides_runpath=yes
11152 if test "$with_gnu_ld" = yes; then
11153 need_lib_prefix=no
11154 fi
11155 need_version=yes
11156 ;;
11157
11158sysv4 | sysv4.3*)
11159 version_type=linux # correct to gnu/linux during the next big refactor
11160 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
11161 soname_spec='${libname}${release}${shared_ext}$major'
11162 shlibpath_var=LD_LIBRARY_PATH
11163 case $host_vendor in
11164 sni)
11165 shlibpath_overrides_runpath=no
11166 need_lib_prefix=no
11167 runpath_var=LD_RUN_PATH
11168 ;;
11169 siemens)
11170 need_lib_prefix=no
11171 ;;
11172 motorola)
11173 need_lib_prefix=no
11174 need_version=no
11175 shlibpath_overrides_runpath=no
11176 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
11177 ;;
11178 esac
11179 ;;
11180
11181sysv4*MP*)
11182 if test -d /usr/nec ;then
11183 version_type=linux # correct to gnu/linux during the next big refactor
11184 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
11185 soname_spec='$libname${shared_ext}.$major'
11186 shlibpath_var=LD_LIBRARY_PATH
11187 fi
11188 ;;
11189
11190sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
11191 version_type=freebsd-elf
11192 need_lib_prefix=no
11193 need_version=no
11194 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
11195 soname_spec='${libname}${release}${shared_ext}$major'
11196 shlibpath_var=LD_LIBRARY_PATH
11197 shlibpath_overrides_runpath=yes
11198 hardcode_into_libs=yes
11199 if test "$with_gnu_ld" = yes; then
11200 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
11201 else
11202 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
11203 case $host_os in
11204 sco3.2v5*)
11205 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
11206 ;;
11207 esac
11208 fi
11209 sys_lib_dlsearch_path_spec='/usr/lib'
11210 ;;
11211
11212tpf*)
11213 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
11214 version_type=linux # correct to gnu/linux during the next big refactor
11215 need_lib_prefix=no
11216 need_version=no
11217 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
11218 shlibpath_var=LD_LIBRARY_PATH
11219 shlibpath_overrides_runpath=no
11220 hardcode_into_libs=yes
11221 ;;
11222
11223uts4*)
11224 version_type=linux # correct to gnu/linux during the next big refactor
11225 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
11226 soname_spec='${libname}${release}${shared_ext}$major'
11227 shlibpath_var=LD_LIBRARY_PATH
11228 ;;
11229
11230*)
11231 dynamic_linker=no
11232 ;;
11233esac
11234{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
11235$as_echo "$dynamic_linker" >&6; }
11236test "$dynamic_linker" = no && can_build_shared=no
11237
11238variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
11239if test "$GCC" = yes; then
11240 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
11241fi
11242
11243if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
11244 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
11245fi
11246if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
11247 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
11248fi
11249
11250
11251
11252
11253
11254
11255
11256
11257
11258
11259
11260
11261
11262
11263
11264
11265
11266
11267
11268
11269
11270
11271
11272
11273
11274
11275
11276
11277
11278
11279
11280
11281
11282
11283
11284
11285
11286
11287
11288
11289
11290
11291
11292
11293
11294
11295
11296
11297
11298
11299
11300
11301
11302
11303
11304
11305
11306
11307
11308
11309
11310
11311
11312
11313
11314
11315
11316
11317
11318
11319
11320
11321
11322
11323
11324
11325
11326
11327
11328
11329
11330
11331
11332
11333
11334
11335
11336
11337
11338
11339
11340
11341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
11342$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
11343hardcode_action=
11344if test -n "$hardcode_libdir_flag_spec" ||
11345 test -n "$runpath_var" ||
11346 test "X$hardcode_automatic" = "Xyes" ; then
11347
11348 # We can hardcode non-existent directories.
11349 if test "$hardcode_direct" != no &&
11350 # If the only mechanism to avoid hardcoding is shlibpath_var, we
11351 # have to relink, otherwise we might link with an installed library
11352 # when we should be linking with a yet-to-be-installed one
11353 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
11354 test "$hardcode_minus_L" != no; then
11355 # Linking always hardcodes the temporary library directory.
11356 hardcode_action=relink
11357 else
11358 # We can link without hardcoding, and we can hardcode nonexisting dirs.
11359 hardcode_action=immediate
11360 fi
11361else
11362 # We cannot hardcode anything, or else we can only hardcode existing
11363 # directories.
11364 hardcode_action=unsupported
11365fi
11366{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
11367$as_echo "$hardcode_action" >&6; }
11368
11369if test "$hardcode_action" = relink ||
11370 test "$inherit_rpath" = yes; then
11371 # Fast installation is not supported
11372 enable_fast_install=no
11373elif test "$shlibpath_overrides_runpath" = yes ||
11374 test "$enable_shared" = no; then
11375 # Fast installation is not necessary
11376 enable_fast_install=needless
11377fi
11378
11379
11380
11381
11382
11383
11384 if test "x$enable_dlopen" != xyes; then
11385 enable_dlopen=unknown
11386 enable_dlopen_self=unknown
11387 enable_dlopen_self_static=unknown
11388else
11389 lt_cv_dlopen=no
11390 lt_cv_dlopen_libs=
11391
11392 case $host_os in
11393 beos*)
11394 lt_cv_dlopen="load_add_on"
11395 lt_cv_dlopen_libs=
11396 lt_cv_dlopen_self=yes
11397 ;;
11398
11399 mingw* | pw32* | cegcc*)
11400 lt_cv_dlopen="LoadLibrary"
11401 lt_cv_dlopen_libs=
11402 ;;
11403
11404 cygwin*)
11405 lt_cv_dlopen="dlopen"
11406 lt_cv_dlopen_libs=
11407 ;;
11408
11409 darwin*)
11410 # if libdl is installed we need to link against it
11411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
11412$as_echo_n "checking for dlopen in -ldl... " >&6; }
11413if ${ac_cv_lib_dl_dlopen+:} false; then :
11414 $as_echo_n "(cached) " >&6
11415else
11416 ac_check_lib_save_LIBS=$LIBS
11417LIBS="-ldl $LIBS"
11418cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11419/* end confdefs.h. */
11420
11421/* Override any GCC internal prototype to avoid an error.
11422 Use char because int might match the return type of a GCC
11423 builtin and then its argument prototype would still apply. */
11424#ifdef __cplusplus
11425extern "C"
11426#endif
11427char dlopen ();
11428int
11429main ()
11430{
11431return dlopen ();
11432 ;
11433 return 0;
11434}
11435_ACEOF
11436if ac_fn_c_try_link "$LINENO"; then :
11437 ac_cv_lib_dl_dlopen=yes
11438else
11439 ac_cv_lib_dl_dlopen=no
11440fi
11441rm -f core conftest.err conftest.$ac_objext \
11442 conftest$ac_exeext conftest.$ac_ext
11443LIBS=$ac_check_lib_save_LIBS
11444fi
11445{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
11446$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
11447if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
11448 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
11449else
11450
11451 lt_cv_dlopen="dyld"
11452 lt_cv_dlopen_libs=
11453 lt_cv_dlopen_self=yes
11454
11455fi
11456
11457 ;;
11458
11459 *)
11460 ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
11461if test "x$ac_cv_func_shl_load" = xyes; then :
11462 lt_cv_dlopen="shl_load"
11463else
11464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
11465$as_echo_n "checking for shl_load in -ldld... " >&6; }
11466if ${ac_cv_lib_dld_shl_load+:} false; then :
11467 $as_echo_n "(cached) " >&6
11468else
11469 ac_check_lib_save_LIBS=$LIBS
11470LIBS="-ldld $LIBS"
11471cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11472/* end confdefs.h. */
11473
11474/* Override any GCC internal prototype to avoid an error.
11475 Use char because int might match the return type of a GCC
11476 builtin and then its argument prototype would still apply. */
11477#ifdef __cplusplus
11478extern "C"
11479#endif
11480char shl_load ();
11481int
11482main ()
11483{
11484return shl_load ();
11485 ;
11486 return 0;
11487}
11488_ACEOF
11489if ac_fn_c_try_link "$LINENO"; then :
11490 ac_cv_lib_dld_shl_load=yes
11491else
11492 ac_cv_lib_dld_shl_load=no
11493fi
11494rm -f core conftest.err conftest.$ac_objext \
11495 conftest$ac_exeext conftest.$ac_ext
11496LIBS=$ac_check_lib_save_LIBS
11497fi
11498{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
11499$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
11500if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
11501 lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
11502else
11503 ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
11504if test "x$ac_cv_func_dlopen" = xyes; then :
11505 lt_cv_dlopen="dlopen"
11506else
11507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
11508$as_echo_n "checking for dlopen in -ldl... " >&6; }
11509if ${ac_cv_lib_dl_dlopen+:} false; then :
11510 $as_echo_n "(cached) " >&6
11511else
11512 ac_check_lib_save_LIBS=$LIBS
11513LIBS="-ldl $LIBS"
11514cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11515/* end confdefs.h. */
11516
11517/* Override any GCC internal prototype to avoid an error.
11518 Use char because int might match the return type of a GCC
11519 builtin and then its argument prototype would still apply. */
11520#ifdef __cplusplus
11521extern "C"
11522#endif
11523char dlopen ();
11524int
11525main ()
11526{
11527return dlopen ();
11528 ;
11529 return 0;
11530}
11531_ACEOF
11532if ac_fn_c_try_link "$LINENO"; then :
11533 ac_cv_lib_dl_dlopen=yes
11534else
11535 ac_cv_lib_dl_dlopen=no
11536fi
11537rm -f core conftest.err conftest.$ac_objext \
11538 conftest$ac_exeext conftest.$ac_ext
11539LIBS=$ac_check_lib_save_LIBS
11540fi
11541{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
11542$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
11543if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
11544 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
11545else
11546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
11547$as_echo_n "checking for dlopen in -lsvld... " >&6; }
11548if ${ac_cv_lib_svld_dlopen+:} false; then :
11549 $as_echo_n "(cached) " >&6
11550else
11551 ac_check_lib_save_LIBS=$LIBS
11552LIBS="-lsvld $LIBS"
11553cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11554/* end confdefs.h. */
11555
11556/* Override any GCC internal prototype to avoid an error.
11557 Use char because int might match the return type of a GCC
11558 builtin and then its argument prototype would still apply. */
11559#ifdef __cplusplus
11560extern "C"
11561#endif
11562char dlopen ();
11563int
11564main ()
11565{
11566return dlopen ();
11567 ;
11568 return 0;
11569}
11570_ACEOF
11571if ac_fn_c_try_link "$LINENO"; then :
11572 ac_cv_lib_svld_dlopen=yes
11573else
11574 ac_cv_lib_svld_dlopen=no
11575fi
11576rm -f core conftest.err conftest.$ac_objext \
11577 conftest$ac_exeext conftest.$ac_ext
11578LIBS=$ac_check_lib_save_LIBS
11579fi
11580{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
11581$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
11582if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
11583 lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
11584else
11585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
11586$as_echo_n "checking for dld_link in -ldld... " >&6; }
11587if ${ac_cv_lib_dld_dld_link+:} false; then :
11588 $as_echo_n "(cached) " >&6
11589else
11590 ac_check_lib_save_LIBS=$LIBS
11591LIBS="-ldld $LIBS"
11592cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11593/* end confdefs.h. */
11594
11595/* Override any GCC internal prototype to avoid an error.
11596 Use char because int might match the return type of a GCC
11597 builtin and then its argument prototype would still apply. */
11598#ifdef __cplusplus
11599extern "C"
11600#endif
11601char dld_link ();
11602int
11603main ()
11604{
11605return dld_link ();
11606 ;
11607 return 0;
11608}
11609_ACEOF
11610if ac_fn_c_try_link "$LINENO"; then :
11611 ac_cv_lib_dld_dld_link=yes
11612else
11613 ac_cv_lib_dld_dld_link=no
11614fi
11615rm -f core conftest.err conftest.$ac_objext \
11616 conftest$ac_exeext conftest.$ac_ext
11617LIBS=$ac_check_lib_save_LIBS
11618fi
11619{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
11620$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
11621if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
11622 lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
11623fi
11624
11625
11626fi
11627
11628
11629fi
11630
11631
11632fi
11633
11634
11635fi
11636
11637
11638fi
11639
11640 ;;
11641 esac
11642
11643 if test "x$lt_cv_dlopen" != xno; then
11644 enable_dlopen=yes
11645 else
11646 enable_dlopen=no
11647 fi
11648
11649 case $lt_cv_dlopen in
11650 dlopen)
11651 save_CPPFLAGS="$CPPFLAGS"
11652 test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
11653
11654 save_LDFLAGS="$LDFLAGS"
11655 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
11656
11657 save_LIBS="$LIBS"
11658 LIBS="$lt_cv_dlopen_libs $LIBS"
11659
11660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
11661$as_echo_n "checking whether a program can dlopen itself... " >&6; }
11662if ${lt_cv_dlopen_self+:} false; then :
11663 $as_echo_n "(cached) " >&6
11664else
11665 if test "$cross_compiling" = yes; then :
11666 lt_cv_dlopen_self=cross
11667else
11668 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
11669 lt_status=$lt_dlunknown
11670 cat > conftest.$ac_ext <<_LT_EOF
11671#line $LINENO "configure"
11672#include "confdefs.h"
11673
11674#if HAVE_DLFCN_H
11675#include <dlfcn.h>
11676#endif
11677
11678#include <stdio.h>
11679
11680#ifdef RTLD_GLOBAL
11681# define LT_DLGLOBAL RTLD_GLOBAL
11682#else
11683# ifdef DL_GLOBAL
11684# define LT_DLGLOBAL DL_GLOBAL
11685# else
11686# define LT_DLGLOBAL 0
11687# endif
11688#endif
11689
11690/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
11691 find out it does not work in some platform. */
11692#ifndef LT_DLLAZY_OR_NOW
11693# ifdef RTLD_LAZY
11694# define LT_DLLAZY_OR_NOW RTLD_LAZY
11695# else
11696# ifdef DL_LAZY
11697# define LT_DLLAZY_OR_NOW DL_LAZY
11698# else
11699# ifdef RTLD_NOW
11700# define LT_DLLAZY_OR_NOW RTLD_NOW
11701# else
11702# ifdef DL_NOW
11703# define LT_DLLAZY_OR_NOW DL_NOW
11704# else
11705# define LT_DLLAZY_OR_NOW 0
11706# endif
11707# endif
11708# endif
11709# endif
11710#endif
11711
11712/* When -fvisbility=hidden is used, assume the code has been annotated
11713 correspondingly for the symbols needed. */
11714#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
11715int fnord () __attribute__((visibility("default")));
11716#endif
11717
11718int fnord () { return 42; }
11719int main ()
11720{
11721 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
11722 int status = $lt_dlunknown;
11723
11724 if (self)
11725 {
11726 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
11727 else
11728 {
11729 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
11730 else puts (dlerror ());
11731 }
11732 /* dlclose (self); */
11733 }
11734 else
11735 puts (dlerror ());
11736
11737 return status;
11738}
11739_LT_EOF
11740 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11741 (eval $ac_link) 2>&5
11742 ac_status=$?
11743 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11744 test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
11745 (./conftest; exit; ) >&5 2>/dev/null
11746 lt_status=$?
11747 case x$lt_status in
11748 x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
11749 x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
11750 x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
11751 esac
11752 else :
11753 # compilation failed
11754 lt_cv_dlopen_self=no
11755 fi
11756fi
11757rm -fr conftest*
11758
11759
11760fi
11761{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
11762$as_echo "$lt_cv_dlopen_self" >&6; }
11763
11764 if test "x$lt_cv_dlopen_self" = xyes; then
11765 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
11766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
11767$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
11768if ${lt_cv_dlopen_self_static+:} false; then :
11769 $as_echo_n "(cached) " >&6
11770else
11771 if test "$cross_compiling" = yes; then :
11772 lt_cv_dlopen_self_static=cross
11773else
11774 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
11775 lt_status=$lt_dlunknown
11776 cat > conftest.$ac_ext <<_LT_EOF
11777#line $LINENO "configure"
11778#include "confdefs.h"
11779
11780#if HAVE_DLFCN_H
11781#include <dlfcn.h>
11782#endif
11783
11784#include <stdio.h>
11785
11786#ifdef RTLD_GLOBAL
11787# define LT_DLGLOBAL RTLD_GLOBAL
11788#else
11789# ifdef DL_GLOBAL
11790# define LT_DLGLOBAL DL_GLOBAL
11791# else
11792# define LT_DLGLOBAL 0
11793# endif
11794#endif
11795
11796/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
11797 find out it does not work in some platform. */
11798#ifndef LT_DLLAZY_OR_NOW
11799# ifdef RTLD_LAZY
11800# define LT_DLLAZY_OR_NOW RTLD_LAZY
11801# else
11802# ifdef DL_LAZY
11803# define LT_DLLAZY_OR_NOW DL_LAZY
11804# else
11805# ifdef RTLD_NOW
11806# define LT_DLLAZY_OR_NOW RTLD_NOW
11807# else
11808# ifdef DL_NOW
11809# define LT_DLLAZY_OR_NOW DL_NOW
11810# else
11811# define LT_DLLAZY_OR_NOW 0
11812# endif
11813# endif
11814# endif
11815# endif
11816#endif
11817
11818/* When -fvisbility=hidden is used, assume the code has been annotated
11819 correspondingly for the symbols needed. */
11820#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
11821int fnord () __attribute__((visibility("default")));
11822#endif
11823
11824int fnord () { return 42; }
11825int main ()
11826{
11827 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
11828 int status = $lt_dlunknown;
11829
11830 if (self)
11831 {
11832 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
11833 else
11834 {
11835 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
11836 else puts (dlerror ());
11837 }
11838 /* dlclose (self); */
11839 }
11840 else
11841 puts (dlerror ());
11842
11843 return status;
11844}
11845_LT_EOF
11846 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
11847 (eval $ac_link) 2>&5
11848 ac_status=$?
11849 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
11850 test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
11851 (./conftest; exit; ) >&5 2>/dev/null
11852 lt_status=$?
11853 case x$lt_status in
11854 x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
11855 x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
11856 x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
11857 esac
11858 else :
11859 # compilation failed
11860 lt_cv_dlopen_self_static=no
11861 fi
11862fi
11863rm -fr conftest*
11864
11865
11866fi
11867{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
11868$as_echo "$lt_cv_dlopen_self_static" >&6; }
11869 fi
11870
11871 CPPFLAGS="$save_CPPFLAGS"
11872 LDFLAGS="$save_LDFLAGS"
11873 LIBS="$save_LIBS"
11874 ;;
11875 esac
11876
11877 case $lt_cv_dlopen_self in
11878 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
11879 *) enable_dlopen_self=unknown ;;
11880 esac
11881
11882 case $lt_cv_dlopen_self_static in
11883 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
11884 *) enable_dlopen_self_static=unknown ;;
11885 esac
11886fi
11887
11888
11889
11890
11891
11892
11893
11894
11895
11896
11897
11898
11899
11900
11901
11902
11903
11904striplib=
11905old_striplib=
11906{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
11907$as_echo_n "checking whether stripping libraries is possible... " >&6; }
11908if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
11909 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
11910 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
11911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11912$as_echo "yes" >&6; }
11913else
11914# FIXME - insert some real tests, host_os isn't really good enough
11915 case $host_os in
11916 darwin*)
11917 if test -n "$STRIP" ; then
11918 striplib="$STRIP -x"
11919 old_striplib="$STRIP -S"
11920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11921$as_echo "yes" >&6; }
11922 else
11923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11924$as_echo "no" >&6; }
11925 fi
11926 ;;
11927 *)
11928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11929$as_echo "no" >&6; }
11930 ;;
11931 esac
11932fi
11933
11934
11935
11936
11937
11938
11939
11940
11941
11942
11943
11944
11945 # Report which library types will actually be built
11946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
11947$as_echo_n "checking if libtool supports shared libraries... " >&6; }
11948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
11949$as_echo "$can_build_shared" >&6; }
11950
11951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
11952$as_echo_n "checking whether to build shared libraries... " >&6; }
11953 test "$can_build_shared" = "no" && enable_shared=no
11954
11955 # On AIX, shared libraries and static libraries use the same namespace, and
11956 # are all built from PIC.
11957 case $host_os in
11958 aix3*)
11959 test "$enable_shared" = yes && enable_static=no
11960 if test -n "$RANLIB"; then
11961 archive_cmds="$archive_cmds~\$RANLIB \$lib"
11962 postinstall_cmds='$RANLIB $lib'
11963 fi
11964 ;;
11965
11966 aix[4-9]*)
11967 if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
11968 test "$enable_shared" = yes && enable_static=no
11969 fi
11970 ;;
11971 esac
11972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
11973$as_echo "$enable_shared" >&6; }
11974
11975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
11976$as_echo_n "checking whether to build static libraries... " >&6; }
11977 # Make sure either enable_shared or enable_static is yes.
11978 test "$enable_shared" = yes || enable_static=yes
11979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
11980$as_echo "$enable_static" >&6; }
11981
11982
11983
11984
11985fi
11986ac_ext=c
11987ac_cpp='$CPP $CPPFLAGS'
11988ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11989ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11990ac_compiler_gnu=$ac_cv_c_compiler_gnu
11991
11992CC="$lt_save_CC"
11993
11994 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
11995 ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
11996 (test "X$CXX" != "Xg++"))) ; then
11997 ac_ext=cpp
11998ac_cpp='$CXXCPP $CPPFLAGS'
11999ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
12000ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
12001ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
12002{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
12003$as_echo_n "checking how to run the C++ preprocessor... " >&6; }
12004if test -z "$CXXCPP"; then
12005 if ${ac_cv_prog_CXXCPP+:} false; then :
12006 $as_echo_n "(cached) " >&6
12007else
12008 # Double quotes because CXXCPP needs to be expanded
12009 for CXXCPP in "$CXX -E" "/lib/cpp"
12010 do
12011 ac_preproc_ok=false
12012for ac_cxx_preproc_warn_flag in '' yes
12013do
12014 # Use a header file that comes with gcc, so configuring glibc
12015 # with a fresh cross-compiler works.
12016 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12017 # <limits.h> exists even on freestanding compilers.
12018 # On the NeXT, cc -E runs the code through the compiler's parser,
12019 # not just through cpp. "Syntax error" is here to catch this case.
12020 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12021/* end confdefs.h. */
12022#ifdef __STDC__
12023# include <limits.h>
12024#else
12025# include <assert.h>
12026#endif
12027 Syntax error
12028_ACEOF
12029if ac_fn_cxx_try_cpp "$LINENO"; then :
12030
12031else
12032 # Broken: fails on valid input.
12033continue
12034fi
12035rm -f conftest.err conftest.i conftest.$ac_ext
12036
12037 # OK, works on sane cases. Now check whether nonexistent headers
12038 # can be detected and how.
12039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12040/* end confdefs.h. */
12041#include <ac_nonexistent.h>
12042_ACEOF
12043if ac_fn_cxx_try_cpp "$LINENO"; then :
12044 # Broken: success on invalid input.
12045continue
12046else
12047 # Passes both tests.
12048ac_preproc_ok=:
12049break
12050fi
12051rm -f conftest.err conftest.i conftest.$ac_ext
12052
12053done
12054# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
12055rm -f conftest.i conftest.err conftest.$ac_ext
12056if $ac_preproc_ok; then :
12057 break
12058fi
12059
12060 done
12061 ac_cv_prog_CXXCPP=$CXXCPP
12062
12063fi
12064 CXXCPP=$ac_cv_prog_CXXCPP
12065else
12066 ac_cv_prog_CXXCPP=$CXXCPP
12067fi
12068{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
12069$as_echo "$CXXCPP" >&6; }
12070ac_preproc_ok=false
12071for ac_cxx_preproc_warn_flag in '' yes
12072do
12073 # Use a header file that comes with gcc, so configuring glibc
12074 # with a fresh cross-compiler works.
12075 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12076 # <limits.h> exists even on freestanding compilers.
12077 # On the NeXT, cc -E runs the code through the compiler's parser,
12078 # not just through cpp. "Syntax error" is here to catch this case.
12079 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12080/* end confdefs.h. */
12081#ifdef __STDC__
12082# include <limits.h>
12083#else
12084# include <assert.h>
12085#endif
12086 Syntax error
12087_ACEOF
12088if ac_fn_cxx_try_cpp "$LINENO"; then :
12089
12090else
12091 # Broken: fails on valid input.
12092continue
12093fi
12094rm -f conftest.err conftest.i conftest.$ac_ext
12095
12096 # OK, works on sane cases. Now check whether nonexistent headers
12097 # can be detected and how.
12098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12099/* end confdefs.h. */
12100#include <ac_nonexistent.h>
12101_ACEOF
12102if ac_fn_cxx_try_cpp "$LINENO"; then :
12103 # Broken: success on invalid input.
12104continue
12105else
12106 # Passes both tests.
12107ac_preproc_ok=:
12108break
12109fi
12110rm -f conftest.err conftest.i conftest.$ac_ext
12111
12112done
12113# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
12114rm -f conftest.i conftest.err conftest.$ac_ext
12115if $ac_preproc_ok; then :
12116
12117else
12118 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
12119$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
12120as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
12121See \`config.log' for more details" "$LINENO" 5; }
12122fi
12123
12124ac_ext=c
12125ac_cpp='$CPP $CPPFLAGS'
12126ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
12127ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
12128ac_compiler_gnu=$ac_cv_c_compiler_gnu
12129
12130else
12131 _lt_caught_CXX_error=yes
12132fi
12133
12134ac_ext=cpp
12135ac_cpp='$CXXCPP $CPPFLAGS'
12136ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
12137ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
12138ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
12139
12140archive_cmds_need_lc_CXX=no
12141allow_undefined_flag_CXX=
12142always_export_symbols_CXX=no
12143archive_expsym_cmds_CXX=
12144compiler_needs_object_CXX=no
12145export_dynamic_flag_spec_CXX=
12146hardcode_direct_CXX=no
12147hardcode_direct_absolute_CXX=no
12148hardcode_libdir_flag_spec_CXX=
12149hardcode_libdir_separator_CXX=
12150hardcode_minus_L_CXX=no
12151hardcode_shlibpath_var_CXX=unsupported
12152hardcode_automatic_CXX=no
12153inherit_rpath_CXX=no
12154module_cmds_CXX=
12155module_expsym_cmds_CXX=
12156link_all_deplibs_CXX=unknown
12157old_archive_cmds_CXX=$old_archive_cmds
12158reload_flag_CXX=$reload_flag
12159reload_cmds_CXX=$reload_cmds
12160no_undefined_flag_CXX=
12161whole_archive_flag_spec_CXX=
12162enable_shared_with_static_runtimes_CXX=no
12163
12164# Source file extension for C++ test sources.
12165ac_ext=cpp
12166
12167# Object file extension for compiled C++ test sources.
12168objext=o
12169objext_CXX=$objext
12170
12171# No sense in running all these tests if we already determined that
12172# the CXX compiler isn't working. Some variables (like enable_shared)
12173# are currently assumed to apply to all compilers on this platform,
12174# and will be corrupted by setting them based on a non-working compiler.
12175if test "$_lt_caught_CXX_error" != yes; then
12176 # Code to be used in simple compile tests
12177 lt_simple_compile_test_code="int some_variable = 0;"
12178
12179 # Code to be used in simple link tests
12180 lt_simple_link_test_code='int main(int, char *[]) { return(0); }'
12181
12182 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
12183
12184
12185
12186
12187
12188
12189# If no C compiler was specified, use CC.
12190LTCC=${LTCC-"$CC"}
12191
12192# If no C compiler flags were specified, use CFLAGS.
12193LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
12194
12195# Allow CC to be a program name with arguments.
12196compiler=$CC
12197
12198
12199 # save warnings/boilerplate of simple test code
12200 ac_outfile=conftest.$ac_objext
12201echo "$lt_simple_compile_test_code" >conftest.$ac_ext
12202eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
12203_lt_compiler_boilerplate=`cat conftest.err`
12204$RM conftest*
12205
12206 ac_outfile=conftest.$ac_objext
12207echo "$lt_simple_link_test_code" >conftest.$ac_ext
12208eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
12209_lt_linker_boilerplate=`cat conftest.err`
12210$RM -r conftest*
12211
12212
12213 # Allow CC to be a program name with arguments.
12214 lt_save_CC=$CC
12215 lt_save_CFLAGS=$CFLAGS
12216 lt_save_LD=$LD
12217 lt_save_GCC=$GCC
12218 GCC=$GXX
12219 lt_save_with_gnu_ld=$with_gnu_ld
12220 lt_save_path_LD=$lt_cv_path_LD
12221 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
12222 lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
12223 else
12224 $as_unset lt_cv_prog_gnu_ld
12225 fi
12226 if test -n "${lt_cv_path_LDCXX+set}"; then
12227 lt_cv_path_LD=$lt_cv_path_LDCXX
12228 else
12229 $as_unset lt_cv_path_LD
12230 fi
12231 test -z "${LDCXX+set}" || LD=$LDCXX
12232 CC=${CXX-"c++"}
12233 CFLAGS=$CXXFLAGS
12234 compiler=$CC
12235 compiler_CXX=$CC
12236 for cc_temp in $compiler""; do
12237 case $cc_temp in
12238 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
12239 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
12240 \-*) ;;
12241 *) break;;
12242 esac
12243done
12244cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
12245
12246
12247 if test -n "$compiler"; then
12248 # We don't want -fno-exception when compiling C++ code, so set the
12249 # no_builtin_flag separately
12250 if test "$GXX" = yes; then
12251 lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin'
12252 else
12253 lt_prog_compiler_no_builtin_flag_CXX=
12254 fi
12255
12256 if test "$GXX" = yes; then
12257 # Set up default GNU C++ configuration
12258
12259
12260
12261# Check whether --with-gnu-ld was given.
12262if test "${with_gnu_ld+set}" = set; then :
12263 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
12264else
12265 with_gnu_ld=no
12266fi
12267
12268ac_prog=ld
12269if test "$GCC" = yes; then
12270 # Check if gcc -print-prog-name=ld gives a path.
12271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
12272$as_echo_n "checking for ld used by $CC... " >&6; }
12273 case $host in
12274 *-*-mingw*)
12275 # gcc leaves a trailing carriage return which upsets mingw
12276 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
12277 *)
12278 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
12279 esac
12280 case $ac_prog in
12281 # Accept absolute paths.
12282 [\\/]* | ?:[\\/]*)
12283 re_direlt='/[^/][^/]*/\.\./'
12284 # Canonicalize the pathname of ld
12285 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
12286 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
12287 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
12288 done
12289 test -z "$LD" && LD="$ac_prog"
12290 ;;
12291 "")
12292 # If it fails, then pretend we aren't using GCC.
12293 ac_prog=ld
12294 ;;
12295 *)
12296 # If it is relative, then search for the first ld in PATH.
12297 with_gnu_ld=unknown
12298 ;;
12299 esac
12300elif test "$with_gnu_ld" = yes; then
12301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
12302$as_echo_n "checking for GNU ld... " >&6; }
12303else
12304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
12305$as_echo_n "checking for non-GNU ld... " >&6; }
12306fi
12307if ${lt_cv_path_LD+:} false; then :
12308 $as_echo_n "(cached) " >&6
12309else
12310 if test -z "$LD"; then
12311 lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
12312 for ac_dir in $PATH; do
12313 IFS="$lt_save_ifs"
12314 test -z "$ac_dir" && ac_dir=.
12315 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
12316 lt_cv_path_LD="$ac_dir/$ac_prog"
12317 # Check to see if the program is GNU ld. I'd rather use --version,
12318 # but apparently some variants of GNU ld only accept -v.
12319 # Break only if it was the GNU/non-GNU ld that we prefer.
12320 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
12321 *GNU* | *'with BFD'*)
12322 test "$with_gnu_ld" != no && break
12323 ;;
12324 *)
12325 test "$with_gnu_ld" != yes && break
12326 ;;
12327 esac
12328 fi
12329 done
12330 IFS="$lt_save_ifs"
12331else
12332 lt_cv_path_LD="$LD" # Let the user override the test with a path.
12333fi
12334fi
12335
12336LD="$lt_cv_path_LD"
12337if test -n "$LD"; then
12338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
12339$as_echo "$LD" >&6; }
12340else
12341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12342$as_echo "no" >&6; }
12343fi
12344test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
12345{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
12346$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
12347if ${lt_cv_prog_gnu_ld+:} false; then :
12348 $as_echo_n "(cached) " >&6
12349else
12350 # I'd rather use --version here, but apparently some GNU lds only accept -v.
12351case `$LD -v 2>&1 </dev/null` in
12352*GNU* | *'with BFD'*)
12353 lt_cv_prog_gnu_ld=yes
12354 ;;
12355*)
12356 lt_cv_prog_gnu_ld=no
12357 ;;
12358esac
12359fi
12360{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
12361$as_echo "$lt_cv_prog_gnu_ld" >&6; }
12362with_gnu_ld=$lt_cv_prog_gnu_ld
12363
12364
12365
12366
12367
12368
12369
12370 # Check if GNU C++ uses GNU ld as the underlying linker, since the
12371 # archiving commands below assume that GNU ld is being used.
12372 if test "$with_gnu_ld" = yes; then
12373 archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
12374 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'
12375
12376 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
12377 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
12378
12379 # If archive_cmds runs LD, not CC, wlarc should be empty
12380 # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
12381 # investigate it a little bit more. (MM)
12382 wlarc='${wl}'
12383
12384 # ancient GNU ld didn't support --whole-archive et. al.
12385 if eval "`$CC -print-prog-name=ld` --help 2>&1" |
12386 $GREP 'no-whole-archive' > /dev/null; then
12387 whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
12388 else
12389 whole_archive_flag_spec_CXX=
12390 fi
12391 else
12392 with_gnu_ld=no
12393 wlarc=
12394
12395 # A generic and very simple default shared library creation
12396 # command for GNU C++ for the case where it uses the native
12397 # linker, instead of GNU ld. If possible, this setting should
12398 # overridden to take advantage of the native linker features on
12399 # the platform it is being used on.
12400 archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
12401 fi
12402
12403 # Commands to make compiler produce verbose output that lists
12404 # what "hidden" libraries, object files and flags are used when
12405 # linking a shared library.
12406 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
12407
12408 else
12409 GXX=no
12410 with_gnu_ld=no
12411 wlarc=
12412 fi
12413
12414 # PORTME: fill in a description of your system's C++ link characteristics
12415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
12416$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
12417 ld_shlibs_CXX=yes
12418 case $host_os in
12419 aix3*)
12420 # FIXME: insert proper C++ library support
12421 ld_shlibs_CXX=no
12422 ;;
12423 aix[4-9]*)
12424 if test "$host_cpu" = ia64; then
12425 # On IA64, the linker does run time linking by default, so we don't
12426 # have to do anything special.
12427 aix_use_runtimelinking=no
12428 exp_sym_flag='-Bexport'
12429 no_entry_flag=""
12430 else
12431 aix_use_runtimelinking=no
12432
12433 # Test if we are trying to use run time linking or normal
12434 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
12435 # need to do runtime linking.
12436 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
12437 for ld_flag in $LDFLAGS; do
12438 case $ld_flag in
12439 *-brtl*)
12440 aix_use_runtimelinking=yes
12441 break
12442 ;;
12443 esac
12444 done
12445 ;;
12446 esac
12447
12448 exp_sym_flag='-bexport'
12449 no_entry_flag='-bnoentry'
12450 fi
12451
12452 # When large executables or shared objects are built, AIX ld can
12453 # have problems creating the table of contents. If linking a library
12454 # or program results in "error TOC overflow" add -mminimal-toc to
12455 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
12456 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
12457
12458 archive_cmds_CXX=''
12459 hardcode_direct_CXX=yes
12460 hardcode_direct_absolute_CXX=yes
12461 hardcode_libdir_separator_CXX=':'
12462 link_all_deplibs_CXX=yes
12463 file_list_spec_CXX='${wl}-f,'
12464
12465 if test "$GXX" = yes; then
12466 case $host_os in aix4.[012]|aix4.[012].*)
12467 # We only want to do this on AIX 4.2 and lower, the check
12468 # below for broken collect2 doesn't work under 4.3+
12469 collect2name=`${CC} -print-prog-name=collect2`
12470 if test -f "$collect2name" &&
12471 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
12472 then
12473 # We have reworked collect2
12474 :
12475 else
12476 # We have old collect2
12477 hardcode_direct_CXX=unsupported
12478 # It fails to find uninstalled libraries when the uninstalled
12479 # path is not listed in the libpath. Setting hardcode_minus_L
12480 # to unsupported forces relinking
12481 hardcode_minus_L_CXX=yes
12482 hardcode_libdir_flag_spec_CXX='-L$libdir'
12483 hardcode_libdir_separator_CXX=
12484 fi
12485 esac
12486 shared_flag='-shared'
12487 if test "$aix_use_runtimelinking" = yes; then
12488 shared_flag="$shared_flag "'${wl}-G'
12489 fi
12490 else
12491 # not using gcc
12492 if test "$host_cpu" = ia64; then
12493 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
12494 # chokes on -Wl,-G. The following line is correct:
12495 shared_flag='-G'
12496 else
12497 if test "$aix_use_runtimelinking" = yes; then
12498 shared_flag='${wl}-G'
12499 else
12500 shared_flag='${wl}-bM:SRE'
12501 fi
12502 fi
12503 fi
12504
12505 export_dynamic_flag_spec_CXX='${wl}-bexpall'
12506 # It seems that -bexpall does not export symbols beginning with
12507 # underscore (_), so it is better to generate a list of symbols to
12508 # export.
12509 always_export_symbols_CXX=yes
12510 if test "$aix_use_runtimelinking" = yes; then
12511 # Warning - without using the other runtime loading flags (-brtl),
12512 # -berok will link without error, but may produce a broken library.
12513 allow_undefined_flag_CXX='-berok'
12514 # Determine the default libpath from the value encoded in an empty
12515 # executable.
12516 if test "${lt_cv_aix_libpath+set}" = set; then
12517 aix_libpath=$lt_cv_aix_libpath
12518else
12519 if ${lt_cv_aix_libpath__CXX+:} false; then :
12520 $as_echo_n "(cached) " >&6
12521else
12522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12523/* end confdefs.h. */
12524
12525int
12526main ()
12527{
12528
12529 ;
12530 return 0;
12531}
12532_ACEOF
12533if ac_fn_cxx_try_link "$LINENO"; then :
12534
12535 lt_aix_libpath_sed='
12536 /Import File Strings/,/^$/ {
12537 /^0/ {
12538 s/^0 *\([^ ]*\) *$/\1/
12539 p
12540 }
12541 }'
12542 lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12543 # Check for a 64-bit object if we didn't find anything.
12544 if test -z "$lt_cv_aix_libpath__CXX"; then
12545 lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12546 fi
12547fi
12548rm -f core conftest.err conftest.$ac_objext \
12549 conftest$ac_exeext conftest.$ac_ext
12550 if test -z "$lt_cv_aix_libpath__CXX"; then
12551 lt_cv_aix_libpath__CXX="/usr/lib:/lib"
12552 fi
12553
12554fi
12555
12556 aix_libpath=$lt_cv_aix_libpath__CXX
12557fi
12558
12559 hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
12560
12561 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"
12562 else
12563 if test "$host_cpu" = ia64; then
12564 hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib'
12565 allow_undefined_flag_CXX="-z nodefs"
12566 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"
12567 else
12568 # Determine the default libpath from the value encoded in an
12569 # empty executable.
12570 if test "${lt_cv_aix_libpath+set}" = set; then
12571 aix_libpath=$lt_cv_aix_libpath
12572else
12573 if ${lt_cv_aix_libpath__CXX+:} false; then :
12574 $as_echo_n "(cached) " >&6
12575else
12576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12577/* end confdefs.h. */
12578
12579int
12580main ()
12581{
12582
12583 ;
12584 return 0;
12585}
12586_ACEOF
12587if ac_fn_cxx_try_link "$LINENO"; then :
12588
12589 lt_aix_libpath_sed='
12590 /Import File Strings/,/^$/ {
12591 /^0/ {
12592 s/^0 *\([^ ]*\) *$/\1/
12593 p
12594 }
12595 }'
12596 lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12597 # Check for a 64-bit object if we didn't find anything.
12598 if test -z "$lt_cv_aix_libpath__CXX"; then
12599 lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12600 fi
12601fi
12602rm -f core conftest.err conftest.$ac_objext \
12603 conftest$ac_exeext conftest.$ac_ext
12604 if test -z "$lt_cv_aix_libpath__CXX"; then
12605 lt_cv_aix_libpath__CXX="/usr/lib:/lib"
12606 fi
12607
12608fi
12609
12610 aix_libpath=$lt_cv_aix_libpath__CXX
12611fi
12612
12613 hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
12614 # Warning - without using the other run time loading flags,
12615 # -berok will link without error, but may produce a broken library.
12616 no_undefined_flag_CXX=' ${wl}-bernotok'
12617 allow_undefined_flag_CXX=' ${wl}-berok'
12618 if test "$with_gnu_ld" = yes; then
12619 # We only use this code for GNU lds that support --whole-archive.
12620 whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
12621 else
12622 # Exported symbols can be pulled into shared objects from archives
12623 whole_archive_flag_spec_CXX='$convenience'
12624 fi
12625 archive_cmds_need_lc_CXX=yes
12626 # This is similar to how AIX traditionally builds its shared
12627 # libraries.
12628 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'
12629 fi
12630 fi
12631 ;;
12632
12633 beos*)
12634 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
12635 allow_undefined_flag_CXX=unsupported
12636 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
12637 # support --undefined. This deserves some investigation. FIXME
12638 archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
12639 else
12640 ld_shlibs_CXX=no
12641 fi
12642 ;;
12643
12644 chorus*)
12645 case $cc_basename in
12646 *)
12647 # FIXME: insert proper C++ library support
12648 ld_shlibs_CXX=no
12649 ;;
12650 esac
12651 ;;
12652
12653 cygwin* | mingw* | pw32* | cegcc*)
12654 case $GXX,$cc_basename in
12655 ,cl* | no,cl*)
12656 # Native MSVC
12657 # hardcode_libdir_flag_spec is actually meaningless, as there is
12658 # no search path for DLLs.
12659 hardcode_libdir_flag_spec_CXX=' '
12660 allow_undefined_flag_CXX=unsupported
12661 always_export_symbols_CXX=yes
12662 file_list_spec_CXX='@'
12663 # Tell ltmain to make .lib files, not .a files.
12664 libext=lib
12665 # Tell ltmain to make .dll files, not .so files.
12666 shrext_cmds=".dll"
12667 # FIXME: Setting linknames here is a bad hack.
12668 archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
12669 archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
12670 $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
12671 else
12672 $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
12673 fi~
12674 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
12675 linknames='
12676 # The linker will not automatically build a static lib if we build a DLL.
12677 # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true'
12678 enable_shared_with_static_runtimes_CXX=yes
12679 # Don't use ranlib
12680 old_postinstall_cmds_CXX='chmod 644 $oldlib'
12681 postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~
12682 lt_tool_outputfile="@TOOL_OUTPUT@"~
12683 case $lt_outputfile in
12684 *.exe|*.EXE) ;;
12685 *)
12686 lt_outputfile="$lt_outputfile.exe"
12687 lt_tool_outputfile="$lt_tool_outputfile.exe"
12688 ;;
12689 esac~
12690 func_to_tool_file "$lt_outputfile"~
12691 if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
12692 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
12693 $RM "$lt_outputfile.manifest";
12694 fi'
12695 ;;
12696 *)
12697 # g++
12698 # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless,
12699 # as there is no search path for DLLs.
12700 hardcode_libdir_flag_spec_CXX='-L$libdir'
12701 export_dynamic_flag_spec_CXX='${wl}--export-all-symbols'
12702 allow_undefined_flag_CXX=unsupported
12703 always_export_symbols_CXX=no
12704 enable_shared_with_static_runtimes_CXX=yes
12705
12706 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
12707 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'
12708 # If the export-symbols file already is a .def file (1st line
12709 # is EXPORTS), use it as is; otherwise, prepend...
12710 archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
12711 cp $export_symbols $output_objdir/$soname.def;
12712 else
12713 echo EXPORTS > $output_objdir/$soname.def;
12714 cat $export_symbols >> $output_objdir/$soname.def;
12715 fi~
12716 $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'
12717 else
12718 ld_shlibs_CXX=no
12719 fi
12720 ;;
12721 esac
12722 ;;
12723 darwin* | rhapsody*)
12724
12725
12726 archive_cmds_need_lc_CXX=no
12727 hardcode_direct_CXX=no
12728 hardcode_automatic_CXX=yes
12729 hardcode_shlibpath_var_CXX=unsupported
12730 if test "$lt_cv_ld_force_load" = "yes"; then
12731 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\"`'
12732
12733 else
12734 whole_archive_flag_spec_CXX=''
12735 fi
12736 link_all_deplibs_CXX=yes
12737 allow_undefined_flag_CXX="$_lt_dar_allow_undefined"
12738 case $cc_basename in
12739 ifort*) _lt_dar_can_shared=yes ;;
12740 *) _lt_dar_can_shared=$GCC ;;
12741 esac
12742 if test "$_lt_dar_can_shared" = "yes"; then
12743 output_verbose_link_cmd=func_echo_all
12744 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}"
12745 module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
12746 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}"
12747 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}"
12748 if test "$lt_cv_apple_cc_single_mod" != "yes"; then
12749 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}"
12750 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}"
12751 fi
12752
12753 else
12754 ld_shlibs_CXX=no
12755 fi
12756
12757 ;;
12758
12759 dgux*)
12760 case $cc_basename in
12761 ec++*)
12762 # FIXME: insert proper C++ library support
12763 ld_shlibs_CXX=no
12764 ;;
12765 ghcx*)
12766 # Green Hills C++ Compiler
12767 # FIXME: insert proper C++ library support
12768 ld_shlibs_CXX=no
12769 ;;
12770 *)
12771 # FIXME: insert proper C++ library support
12772 ld_shlibs_CXX=no
12773 ;;
12774 esac
12775 ;;
12776
12777 freebsd2.*)
12778 # C++ shared libraries reported to be fairly broken before
12779 # switch to ELF
12780 ld_shlibs_CXX=no
12781 ;;
12782
12783 freebsd-elf*)
12784 archive_cmds_need_lc_CXX=no
12785 ;;
12786
12787 freebsd* | dragonfly*)
12788 # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
12789 # conventions
12790 ld_shlibs_CXX=yes
12791 ;;
12792
12793 gnu*)
12794 ;;
12795
12796 haiku*)
12797 archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
12798 link_all_deplibs_CXX=yes
12799 ;;
12800
12801 hpux9*)
12802 hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
12803 hardcode_libdir_separator_CXX=:
12804 export_dynamic_flag_spec_CXX='${wl}-E'
12805 hardcode_direct_CXX=yes
12806 hardcode_minus_L_CXX=yes # Not in the search PATH,
12807 # but as the default
12808 # location of the library.
12809
12810 case $cc_basename in
12811 CC*)
12812 # FIXME: insert proper C++ library support
12813 ld_shlibs_CXX=no
12814 ;;
12815 aCC*)
12816 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'
12817 # Commands to make compiler produce verbose output that lists
12818 # what "hidden" libraries, object files and flags are used when
12819 # linking a shared library.
12820 #
12821 # There doesn't appear to be a way to prevent this compiler from
12822 # explicitly linking system object files so we need to strip them
12823 # from the output so that they don't get included in the library
12824 # dependencies.
12825 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"'
12826 ;;
12827 *)
12828 if test "$GXX" = yes; then
12829 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'
12830 else
12831 # FIXME: insert proper C++ library support
12832 ld_shlibs_CXX=no
12833 fi
12834 ;;
12835 esac
12836 ;;
12837
12838 hpux10*|hpux11*)
12839 if test $with_gnu_ld = no; then
12840 hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
12841 hardcode_libdir_separator_CXX=:
12842
12843 case $host_cpu in
12844 hppa*64*|ia64*)
12845 ;;
12846 *)
12847 export_dynamic_flag_spec_CXX='${wl}-E'
12848 ;;
12849 esac
12850 fi
12851 case $host_cpu in
12852 hppa*64*|ia64*)
12853 hardcode_direct_CXX=no
12854 hardcode_shlibpath_var_CXX=no
12855 ;;
12856 *)
12857 hardcode_direct_CXX=yes
12858 hardcode_direct_absolute_CXX=yes
12859 hardcode_minus_L_CXX=yes # Not in the search PATH,
12860 # but as the default
12861 # location of the library.
12862 ;;
12863 esac
12864
12865 case $cc_basename in
12866 CC*)
12867 # FIXME: insert proper C++ library support
12868 ld_shlibs_CXX=no
12869 ;;
12870 aCC*)
12871 case $host_cpu in
12872 hppa*64*)
12873 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12874 ;;
12875 ia64*)
12876 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12877 ;;
12878 *)
12879 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12880 ;;
12881 esac
12882 # Commands to make compiler produce verbose output that lists
12883 # what "hidden" libraries, object files and flags are used when
12884 # linking a shared library.
12885 #
12886 # There doesn't appear to be a way to prevent this compiler from
12887 # explicitly linking system object files so we need to strip them
12888 # from the output so that they don't get included in the library
12889 # dependencies.
12890 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"'
12891 ;;
12892 *)
12893 if test "$GXX" = yes; then
12894 if test $with_gnu_ld = no; then
12895 case $host_cpu in
12896 hppa*64*)
12897 archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12898 ;;
12899 ia64*)
12900 archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
12901 ;;
12902 *)
12903 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'
12904 ;;
12905 esac
12906 fi
12907 else
12908 # FIXME: insert proper C++ library support
12909 ld_shlibs_CXX=no
12910 fi
12911 ;;
12912 esac
12913 ;;
12914
12915 interix[3-9]*)
12916 hardcode_direct_CXX=no
12917 hardcode_shlibpath_var_CXX=no
12918 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
12919 export_dynamic_flag_spec_CXX='${wl}-E'
12920 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
12921 # Instead, shared libraries are loaded at an image base (0x10000000 by
12922 # default) and relocated if they conflict, which is a slow very memory
12923 # consuming and fragmenting process. To avoid this, we pick a random,
12924 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
12925 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
12926 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'
12927 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'
12928 ;;
12929 irix5* | irix6*)
12930 case $cc_basename in
12931 CC*)
12932 # SGI C++
12933 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'
12934
12935 # Archives containing C++ object files must be created using
12936 # "CC -ar", where "CC" is the IRIX C++ compiler. This is
12937 # necessary to make sure instantiated templates are included
12938 # in the archive.
12939 old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs'
12940 ;;
12941 *)
12942 if test "$GXX" = yes; then
12943 if test "$with_gnu_ld" = no; then
12944 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'
12945 else
12946 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'
12947 fi
12948 fi
12949 link_all_deplibs_CXX=yes
12950 ;;
12951 esac
12952 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
12953 hardcode_libdir_separator_CXX=:
12954 inherit_rpath_CXX=yes
12955 ;;
12956
12957 linux* | k*bsd*-gnu | kopensolaris*-gnu)
12958 case $cc_basename in
12959 KCC*)
12960 # Kuck and Associates, Inc. (KAI) C++ Compiler
12961
12962 # KCC will only create a shared library if the output file
12963 # ends with ".so" (or ".sl" for HP-UX), so rename the library
12964 # to its proper name (with version) after linking.
12965 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'
12966 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'
12967 # Commands to make compiler produce verbose output that lists
12968 # what "hidden" libraries, object files and flags are used when
12969 # linking a shared library.
12970 #
12971 # There doesn't appear to be a way to prevent this compiler from
12972 # explicitly linking system object files so we need to strip them
12973 # from the output so that they don't get included in the library
12974 # dependencies.
12975 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"'
12976
12977 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
12978 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
12979
12980 # Archives containing C++ object files must be created using
12981 # "CC -Bstatic", where "CC" is the KAI C++ compiler.
12982 old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs'
12983 ;;
12984 icpc* | ecpc* )
12985 # Intel C++
12986 with_gnu_ld=yes
12987 # version 8.0 and above of icpc choke on multiply defined symbols
12988 # if we add $predep_objects and $postdep_objects, however 7.1 and
12989 # earlier do not add the objects themselves.
12990 case `$CC -V 2>&1` in
12991 *"Version 7."*)
12992 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
12993 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'
12994 ;;
12995 *) # Version 8.0 or newer
12996 tmp_idyn=
12997 case $host_cpu in
12998 ia64*) tmp_idyn=' -i_dynamic';;
12999 esac
13000 archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13001 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'
13002 ;;
13003 esac
13004 archive_cmds_need_lc_CXX=no
13005 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
13006 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
13007 whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
13008 ;;
13009 pgCC* | pgcpp*)
13010 # Portland Group C++ compiler
13011 case `$CC -V` in
13012 *pgCC\ [1-5].* | *pgcpp\ [1-5].*)
13013 prelink_cmds_CXX='tpldir=Template.dir~
13014 rm -rf $tpldir~
13015 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
13016 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
13017 old_archive_cmds_CXX='tpldir=Template.dir~
13018 rm -rf $tpldir~
13019 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
13020 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
13021 $RANLIB $oldlib'
13022 archive_cmds_CXX='tpldir=Template.dir~
13023 rm -rf $tpldir~
13024 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
13025 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
13026 archive_expsym_cmds_CXX='tpldir=Template.dir~
13027 rm -rf $tpldir~
13028 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
13029 $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'
13030 ;;
13031 *) # Version 6 and above use weak symbols
13032 archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
13033 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'
13034 ;;
13035 esac
13036
13037 hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir'
13038 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
13039 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'
13040 ;;
13041 cxx*)
13042 # Compaq C++
13043 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
13044 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'
13045
13046 runpath_var=LD_RUN_PATH
13047 hardcode_libdir_flag_spec_CXX='-rpath $libdir'
13048 hardcode_libdir_separator_CXX=:
13049
13050 # Commands to make compiler produce verbose output that lists
13051 # what "hidden" libraries, object files and flags are used when
13052 # linking a shared library.
13053 #
13054 # There doesn't appear to be a way to prevent this compiler from
13055 # explicitly linking system object files so we need to strip them
13056 # from the output so that they don't get included in the library
13057 # dependencies.
13058 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'
13059 ;;
13060 xl* | mpixl* | bgxl*)
13061 # IBM XL 8.0 on PPC, with GNU ld
13062 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
13063 export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
13064 archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13065 if test "x$supports_anon_versioning" = xyes; then
13066 archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~
13067 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
13068 echo "local: *; };" >> $output_objdir/$libname.ver~
13069 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
13070 fi
13071 ;;
13072 *)
13073 case `$CC -V 2>&1 | sed 5q` in
13074 *Sun\ C*)
13075 # Sun C++ 5.9
13076 no_undefined_flag_CXX=' -zdefs'
13077 archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
13078 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'
13079 hardcode_libdir_flag_spec_CXX='-R$libdir'
13080 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'
13081 compiler_needs_object_CXX=yes
13082
13083 # Not sure whether something based on
13084 # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
13085 # would be better.
13086 output_verbose_link_cmd='func_echo_all'
13087
13088 # Archives containing C++ object files must be created using
13089 # "CC -xar", where "CC" is the Sun C++ compiler. This is
13090 # necessary to make sure instantiated templates are included
13091 # in the archive.
13092 old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
13093 ;;
13094 esac
13095 ;;
13096 esac
13097 ;;
13098
13099 lynxos*)
13100 # FIXME: insert proper C++ library support
13101 ld_shlibs_CXX=no
13102 ;;
13103
13104 m88k*)
13105 # FIXME: insert proper C++ library support
13106 ld_shlibs_CXX=no
13107 ;;
13108
13109 mvs*)
13110 case $cc_basename in
13111 cxx*)
13112 # FIXME: insert proper C++ library support
13113 ld_shlibs_CXX=no
13114 ;;
13115 *)
13116 # FIXME: insert proper C++ library support
13117 ld_shlibs_CXX=no
13118 ;;
13119 esac
13120 ;;
13121
13122 netbsd*)
13123 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
13124 archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
13125 wlarc=
13126 hardcode_libdir_flag_spec_CXX='-R$libdir'
13127 hardcode_direct_CXX=yes
13128 hardcode_shlibpath_var_CXX=no
13129 fi
13130 # Workaround some broken pre-1.5 toolchains
13131 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
13132 ;;
13133
13134 *nto* | *qnx*)
13135 ld_shlibs_CXX=yes
13136 ;;
13137
13138 openbsd2*)
13139 # C++ shared libraries are fairly broken
13140 ld_shlibs_CXX=no
13141 ;;
13142
13143 openbsd*)
13144 if test -f /usr/libexec/ld.so; then
13145 hardcode_direct_CXX=yes
13146 hardcode_shlibpath_var_CXX=no
13147 hardcode_direct_absolute_CXX=yes
13148 archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
13149 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
13150 if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
13151 archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
13152 export_dynamic_flag_spec_CXX='${wl}-E'
13153 whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
13154 fi
13155 output_verbose_link_cmd=func_echo_all
13156 else
13157 ld_shlibs_CXX=no
13158 fi
13159 ;;
13160
13161 osf3* | osf4* | osf5*)
13162 case $cc_basename in
13163 KCC*)
13164 # Kuck and Associates, Inc. (KAI) C++ Compiler
13165
13166 # KCC will only create a shared library if the output file
13167 # ends with ".so" (or ".sl" for HP-UX), so rename the library
13168 # to its proper name (with version) after linking.
13169 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'
13170
13171 hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
13172 hardcode_libdir_separator_CXX=:
13173
13174 # Archives containing C++ object files must be created using
13175 # the KAI C++ compiler.
13176 case $host in
13177 osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;;
13178 *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;;
13179 esac
13180 ;;
13181 RCC*)
13182 # Rational C++ 2.4.1
13183 # FIXME: insert proper C++ library support
13184 ld_shlibs_CXX=no
13185 ;;
13186 cxx*)
13187 case $host in
13188 osf3*)
13189 allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
13190 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'
13191 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
13192 ;;
13193 *)
13194 allow_undefined_flag_CXX=' -expect_unresolved \*'
13195 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'
13196 archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
13197 echo "-hidden">> $lib.exp~
13198 $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~
13199 $RM $lib.exp'
13200 hardcode_libdir_flag_spec_CXX='-rpath $libdir'
13201 ;;
13202 esac
13203
13204 hardcode_libdir_separator_CXX=:
13205
13206 # Commands to make compiler produce verbose output that lists
13207 # what "hidden" libraries, object files and flags are used when
13208 # linking a shared library.
13209 #
13210 # There doesn't appear to be a way to prevent this compiler from
13211 # explicitly linking system object files so we need to strip them
13212 # from the output so that they don't get included in the library
13213 # dependencies.
13214 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"'
13215 ;;
13216 *)
13217 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
13218 allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
13219 case $host in
13220 osf3*)
13221 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'
13222 ;;
13223 *)
13224 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'
13225 ;;
13226 esac
13227
13228 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
13229 hardcode_libdir_separator_CXX=:
13230
13231 # Commands to make compiler produce verbose output that lists
13232 # what "hidden" libraries, object files and flags are used when
13233 # linking a shared library.
13234 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
13235
13236 else
13237 # FIXME: insert proper C++ library support
13238 ld_shlibs_CXX=no
13239 fi
13240 ;;
13241 esac
13242 ;;
13243
13244 psos*)
13245 # FIXME: insert proper C++ library support
13246 ld_shlibs_CXX=no
13247 ;;
13248
13249 sunos4*)
13250 case $cc_basename in
13251 CC*)
13252 # Sun C++ 4.x
13253 # FIXME: insert proper C++ library support
13254 ld_shlibs_CXX=no
13255 ;;
13256 lcc*)
13257 # Lucid
13258 # FIXME: insert proper C++ library support
13259 ld_shlibs_CXX=no
13260 ;;
13261 *)
13262 # FIXME: insert proper C++ library support
13263 ld_shlibs_CXX=no
13264 ;;
13265 esac
13266 ;;
13267
13268 solaris*)
13269 case $cc_basename in
13270 CC* | sunCC*)
13271 # Sun C++ 4.2, 5.x and Centerline C++
13272 archive_cmds_need_lc_CXX=yes
13273 no_undefined_flag_CXX=' -zdefs'
13274 archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
13275 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13276 $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'
13277
13278 hardcode_libdir_flag_spec_CXX='-R$libdir'
13279 hardcode_shlibpath_var_CXX=no
13280 case $host_os in
13281 solaris2.[0-5] | solaris2.[0-5].*) ;;
13282 *)
13283 # The compiler driver will combine and reorder linker options,
13284 # but understands `-z linker_flag'.
13285 # Supported since Solaris 2.6 (maybe 2.5.1?)
13286 whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract'
13287 ;;
13288 esac
13289 link_all_deplibs_CXX=yes
13290
13291 output_verbose_link_cmd='func_echo_all'
13292
13293 # Archives containing C++ object files must be created using
13294 # "CC -xar", where "CC" is the Sun C++ compiler. This is
13295 # necessary to make sure instantiated templates are included
13296 # in the archive.
13297 old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
13298 ;;
13299 gcx*)
13300 # Green Hills C++ Compiler
13301 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
13302
13303 # The C++ compiler must be used to create the archive.
13304 old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
13305 ;;
13306 *)
13307 # GNU C++ compiler with Solaris linker
13308 if test "$GXX" = yes && test "$with_gnu_ld" = no; then
13309 no_undefined_flag_CXX=' ${wl}-z ${wl}defs'
13310 if $CC --version | $GREP -v '^2\.7' > /dev/null; then
13311 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
13312 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13313 $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
13314
13315 # Commands to make compiler produce verbose output that lists
13316 # what "hidden" libraries, object files and flags are used when
13317 # linking a shared library.
13318 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
13319 else
13320 # g++ 2.7 appears to require `-G' NOT `-shared' on this
13321 # platform.
13322 archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
13323 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13324 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
13325
13326 # Commands to make compiler produce verbose output that lists
13327 # what "hidden" libraries, object files and flags are used when
13328 # linking a shared library.
13329 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
13330 fi
13331
13332 hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir'
13333 case $host_os in
13334 solaris2.[0-5] | solaris2.[0-5].*) ;;
13335 *)
13336 whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
13337 ;;
13338 esac
13339 fi
13340 ;;
13341 esac
13342 ;;
13343
13344 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
13345 no_undefined_flag_CXX='${wl}-z,text'
13346 archive_cmds_need_lc_CXX=no
13347 hardcode_shlibpath_var_CXX=no
13348 runpath_var='LD_RUN_PATH'
13349
13350 case $cc_basename in
13351 CC*)
13352 archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13353 archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13354 ;;
13355 *)
13356 archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13357 archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13358 ;;
13359 esac
13360 ;;
13361
13362 sysv5* | sco3.2v5* | sco5v6*)
13363 # Note: We can NOT use -z defs as we might desire, because we do not
13364 # link with -lc, and that would cause any symbols used from libc to
13365 # always be unresolved, which means just about no library would
13366 # ever link correctly. If we're not using GNU ld we use -z text
13367 # though, which does catch some bad symbols but isn't as heavy-handed
13368 # as -z defs.
13369 no_undefined_flag_CXX='${wl}-z,text'
13370 allow_undefined_flag_CXX='${wl}-z,nodefs'
13371 archive_cmds_need_lc_CXX=no
13372 hardcode_shlibpath_var_CXX=no
13373 hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir'
13374 hardcode_libdir_separator_CXX=':'
13375 link_all_deplibs_CXX=yes
13376 export_dynamic_flag_spec_CXX='${wl}-Bexport'
13377 runpath_var='LD_RUN_PATH'
13378
13379 case $cc_basename in
13380 CC*)
13381 archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13382 archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13383 old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~
13384 '"$old_archive_cmds_CXX"
13385 reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~
13386 '"$reload_cmds_CXX"
13387 ;;
13388 *)
13389 archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13390 archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13391 ;;
13392 esac
13393 ;;
13394
13395 tandem*)
13396 case $cc_basename in
13397 NCC*)
13398 # NonStop-UX NCC 3.20
13399 # FIXME: insert proper C++ library support
13400 ld_shlibs_CXX=no
13401 ;;
13402 *)
13403 # FIXME: insert proper C++ library support
13404 ld_shlibs_CXX=no
13405 ;;
13406 esac
13407 ;;
13408
13409 vxworks*)
13410 # FIXME: insert proper C++ library support
13411 ld_shlibs_CXX=no
13412 ;;
13413
13414 *)
13415 # FIXME: insert proper C++ library support
13416 ld_shlibs_CXX=no
13417 ;;
13418 esac
13419
13420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
13421$as_echo "$ld_shlibs_CXX" >&6; }
13422 test "$ld_shlibs_CXX" = no && can_build_shared=no
13423
13424 GCC_CXX="$GXX"
13425 LD_CXX="$LD"
13426
13427 ## CAVEAT EMPTOR:
13428 ## There is no encapsulation within the following macros, do not change
13429 ## the running order or otherwise move them around unless you know exactly
13430 ## what you are doing...
13431 # Dependencies to place before and after the object being linked:
13432predep_objects_CXX=
13433postdep_objects_CXX=
13434predeps_CXX=
13435postdeps_CXX=
13436compiler_lib_search_path_CXX=
13437
13438cat > conftest.$ac_ext <<_LT_EOF
13439class Foo
13440{
13441public:
13442 Foo (void) { a = 0; }
13443private:
13444 int a;
13445};
13446_LT_EOF
13447
13448
13449_lt_libdeps_save_CFLAGS=$CFLAGS
13450case "$CC $CFLAGS " in #(
13451*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
13452*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
13453*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
13454esac
13455
13456if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
13457 (eval $ac_compile) 2>&5
13458 ac_status=$?
13459 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13460 test $ac_status = 0; }; then
13461 # Parse the compiler output and extract the necessary
13462 # objects, libraries and library flags.
13463
13464 # Sentinel used to keep track of whether or not we are before
13465 # the conftest object file.
13466 pre_test_object_deps_done=no
13467
13468 for p in `eval "$output_verbose_link_cmd"`; do
13469 case ${prev}${p} in
13470
13471 -L* | -R* | -l*)
13472 # Some compilers place space between "-{L,R}" and the path.
13473 # Remove the space.
13474 if test $p = "-L" ||
13475 test $p = "-R"; then
13476 prev=$p
13477 continue
13478 fi
13479
13480 # Expand the sysroot to ease extracting the directories later.
13481 if test -z "$prev"; then
13482 case $p in
13483 -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
13484 -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
13485 -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
13486 esac
13487 fi
13488 case $p in
13489 =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
13490 esac
13491 if test "$pre_test_object_deps_done" = no; then
13492 case ${prev} in
13493 -L | -R)
13494 # Internal compiler library paths should come after those
13495 # provided the user. The postdeps already come after the
13496 # user supplied libs so there is no need to process them.
13497 if test -z "$compiler_lib_search_path_CXX"; then
13498 compiler_lib_search_path_CXX="${prev}${p}"
13499 else
13500 compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}"
13501 fi
13502 ;;
13503 # The "-l" case would never come before the object being
13504 # linked, so don't bother handling this case.
13505 esac
13506 else
13507 if test -z "$postdeps_CXX"; then
13508 postdeps_CXX="${prev}${p}"
13509 else
13510 postdeps_CXX="${postdeps_CXX} ${prev}${p}"
13511 fi
13512 fi
13513 prev=
13514 ;;
13515
13516 *.lto.$objext) ;; # Ignore GCC LTO objects
13517 *.$objext)
13518 # This assumes that the test object file only shows up
13519 # once in the compiler output.
13520 if test "$p" = "conftest.$objext"; then
13521 pre_test_object_deps_done=yes
13522 continue
13523 fi
13524
13525 if test "$pre_test_object_deps_done" = no; then
13526 if test -z "$predep_objects_CXX"; then
13527 predep_objects_CXX="$p"
13528 else
13529 predep_objects_CXX="$predep_objects_CXX $p"
13530 fi
13531 else
13532 if test -z "$postdep_objects_CXX"; then
13533 postdep_objects_CXX="$p"
13534 else
13535 postdep_objects_CXX="$postdep_objects_CXX $p"
13536 fi
13537 fi
13538 ;;
13539
13540 *) ;; # Ignore the rest.
13541
13542 esac
13543 done
13544
13545 # Clean up.
13546 rm -f a.out a.exe
13547else
13548 echo "libtool.m4: error: problem compiling CXX test program"
13549fi
13550
13551$RM -f confest.$objext
13552CFLAGS=$_lt_libdeps_save_CFLAGS
13553
13554# PORTME: override above test on systems where it is broken
13555case $host_os in
13556interix[3-9]*)
13557 # Interix 3.5 installs completely hosed .la files for C++, so rather than
13558 # hack all around it, let's just trust "g++" to DTRT.
13559 predep_objects_CXX=
13560 postdep_objects_CXX=
13561 postdeps_CXX=
13562 ;;
13563
13564linux*)
13565 case `$CC -V 2>&1 | sed 5q` in
13566 *Sun\ C*)
13567 # Sun C++ 5.9
13568
13569 # The more standards-conforming stlport4 library is
13570 # incompatible with the Cstd library. Avoid specifying
13571 # it if it's in CXXFLAGS. Ignore libCrun as
13572 # -library=stlport4 depends on it.
13573 case " $CXX $CXXFLAGS " in
13574 *" -library=stlport4 "*)
13575 solaris_use_stlport4=yes
13576 ;;
13577 esac
13578
13579 if test "$solaris_use_stlport4" != yes; then
13580 postdeps_CXX='-library=Cstd -library=Crun'
13581 fi
13582 ;;
13583 esac
13584 ;;
13585
13586solaris*)
13587 case $cc_basename in
13588 CC* | sunCC*)
13589 # The more standards-conforming stlport4 library is
13590 # incompatible with the Cstd library. Avoid specifying
13591 # it if it's in CXXFLAGS. Ignore libCrun as
13592 # -library=stlport4 depends on it.
13593 case " $CXX $CXXFLAGS " in
13594 *" -library=stlport4 "*)
13595 solaris_use_stlport4=yes
13596 ;;
13597 esac
13598
13599 # Adding this requires a known-good setup of shared libraries for
13600 # Sun compiler versions before 5.6, else PIC objects from an old
13601 # archive will be linked into the output, leading to subtle bugs.
13602 if test "$solaris_use_stlport4" != yes; then
13603 postdeps_CXX='-library=Cstd -library=Crun'
13604 fi
13605 ;;
13606 esac
13607 ;;
13608esac
13609
13610
13611case " $postdeps_CXX " in
13612*" -lc "*) archive_cmds_need_lc_CXX=no ;;
13613esac
13614 compiler_lib_search_dirs_CXX=
13615if test -n "${compiler_lib_search_path_CXX}"; then
13616 compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
13617fi
13618
13619
13620
13621
13622
13623
13624
13625
13626
13627
13628
13629
13630
13631
13632
13633
13634
13635
13636
13637
13638
13639
13640
13641
13642
13643
13644
13645
13646
13647
13648
13649 lt_prog_compiler_wl_CXX=
13650lt_prog_compiler_pic_CXX=
13651lt_prog_compiler_static_CXX=
13652
13653
13654 # C++ specific cases for pic, static, wl, etc.
13655 if test "$GXX" = yes; then
13656 lt_prog_compiler_wl_CXX='-Wl,'
13657 lt_prog_compiler_static_CXX='-static'
13658
13659 case $host_os in
13660 aix*)
13661 # All AIX code is PIC.
13662 if test "$host_cpu" = ia64; then
13663 # AIX 5 now supports IA64 processor
13664 lt_prog_compiler_static_CXX='-Bstatic'
13665 fi
13666 ;;
13667
13668 amigaos*)
13669 case $host_cpu in
13670 powerpc)
13671 # see comment about AmigaOS4 .so support
13672 lt_prog_compiler_pic_CXX='-fPIC'
13673 ;;
13674 m68k)
13675 # FIXME: we need at least 68020 code to build shared libraries, but
13676 # adding the `-m68020' flag to GCC prevents building anything better,
13677 # like `-m68040'.
13678 lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4'
13679 ;;
13680 esac
13681 ;;
13682
13683 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
13684 # PIC is the default for these OSes.
13685 ;;
13686 mingw* | cygwin* | os2* | pw32* | cegcc*)
13687 # This hack is so that the source file can tell whether it is being
13688 # built for inclusion in a dll (and should export symbols for example).
13689 # Although the cygwin gcc ignores -fPIC, still need this for old-style
13690 # (--disable-auto-import) libraries
13691 lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
13692 ;;
13693 darwin* | rhapsody*)
13694 # PIC is the default on this platform
13695 # Common symbols not allowed in MH_DYLIB files
13696 lt_prog_compiler_pic_CXX='-fno-common'
13697 ;;
13698 *djgpp*)
13699 # DJGPP does not support shared libraries at all
13700 lt_prog_compiler_pic_CXX=
13701 ;;
13702 haiku*)
13703 # PIC is the default for Haiku.
13704 # The "-static" flag exists, but is broken.
13705 lt_prog_compiler_static_CXX=
13706 ;;
13707 interix[3-9]*)
13708 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
13709 # Instead, we relocate shared libraries at runtime.
13710 ;;
13711 sysv4*MP*)
13712 if test -d /usr/nec; then
13713 lt_prog_compiler_pic_CXX=-Kconform_pic
13714 fi
13715 ;;
13716 hpux*)
13717 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
13718 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
13719 # sets the default TLS model and affects inlining.
13720 case $host_cpu in
13721 hppa*64*)
13722 ;;
13723 *)
13724 lt_prog_compiler_pic_CXX='-fPIC'
13725 ;;
13726 esac
13727 ;;
13728 *qnx* | *nto*)
13729 # QNX uses GNU C++, but need to define -shared option too, otherwise
13730 # it will coredump.
13731 lt_prog_compiler_pic_CXX='-fPIC -shared'
13732 ;;
13733 *)
13734 lt_prog_compiler_pic_CXX='-fPIC'
13735 ;;
13736 esac
13737 else
13738 case $host_os in
13739 aix[4-9]*)
13740 # All AIX code is PIC.
13741 if test "$host_cpu" = ia64; then
13742 # AIX 5 now supports IA64 processor
13743 lt_prog_compiler_static_CXX='-Bstatic'
13744 else
13745 lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp'
13746 fi
13747 ;;
13748 chorus*)
13749 case $cc_basename in
13750 cxch68*)
13751 # Green Hills C++ Compiler
13752 # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
13753 ;;
13754 esac
13755 ;;
13756 mingw* | cygwin* | os2* | pw32* | cegcc*)
13757 # This hack is so that the source file can tell whether it is being
13758 # built for inclusion in a dll (and should export symbols for example).
13759 lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
13760 ;;
13761 dgux*)
13762 case $cc_basename in
13763 ec++*)
13764 lt_prog_compiler_pic_CXX='-KPIC'
13765 ;;
13766 ghcx*)
13767 # Green Hills C++ Compiler
13768 lt_prog_compiler_pic_CXX='-pic'
13769 ;;
13770 *)
13771 ;;
13772 esac
13773 ;;
13774 freebsd* | dragonfly*)
13775 # FreeBSD uses GNU C++
13776 ;;
13777 hpux9* | hpux10* | hpux11*)
13778 case $cc_basename in
13779 CC*)
13780 lt_prog_compiler_wl_CXX='-Wl,'
13781 lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
13782 if test "$host_cpu" != ia64; then
13783 lt_prog_compiler_pic_CXX='+Z'
13784 fi
13785 ;;
13786 aCC*)
13787 lt_prog_compiler_wl_CXX='-Wl,'
13788 lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
13789 case $host_cpu in
13790 hppa*64*|ia64*)
13791 # +Z the default
13792 ;;
13793 *)
13794 lt_prog_compiler_pic_CXX='+Z'
13795 ;;
13796 esac
13797 ;;
13798 *)
13799 ;;
13800 esac
13801 ;;
13802 interix*)
13803 # This is c89, which is MS Visual C++ (no shared libs)
13804 # Anyone wants to do a port?
13805 ;;
13806 irix5* | irix6* | nonstopux*)
13807 case $cc_basename in
13808 CC*)
13809 lt_prog_compiler_wl_CXX='-Wl,'
13810 lt_prog_compiler_static_CXX='-non_shared'
13811 # CC pic flag -KPIC is the default.
13812 ;;
13813 *)
13814 ;;
13815 esac
13816 ;;
13817 linux* | k*bsd*-gnu | kopensolaris*-gnu)
13818 case $cc_basename in
13819 KCC*)
13820 # KAI C++ Compiler
13821 lt_prog_compiler_wl_CXX='--backend -Wl,'
13822 lt_prog_compiler_pic_CXX='-fPIC'
13823 ;;
13824 ecpc* )
13825 # old Intel C++ for x86_64 which still supported -KPIC.
13826 lt_prog_compiler_wl_CXX='-Wl,'
13827 lt_prog_compiler_pic_CXX='-KPIC'
13828 lt_prog_compiler_static_CXX='-static'
13829 ;;
13830 icpc* )
13831 # Intel C++, used to be incompatible with GCC.
13832 # ICC 10 doesn't accept -KPIC any more.
13833 lt_prog_compiler_wl_CXX='-Wl,'
13834 lt_prog_compiler_pic_CXX='-fPIC'
13835 lt_prog_compiler_static_CXX='-static'
13836 ;;
13837 pgCC* | pgcpp*)
13838 # Portland Group C++ compiler
13839 lt_prog_compiler_wl_CXX='-Wl,'
13840 lt_prog_compiler_pic_CXX='-fpic'
13841 lt_prog_compiler_static_CXX='-Bstatic'
13842 ;;
13843 cxx*)
13844 # Compaq C++
13845 # Make sure the PIC flag is empty. It appears that all Alpha
13846 # Linux and Compaq Tru64 Unix objects are PIC.
13847 lt_prog_compiler_pic_CXX=
13848 lt_prog_compiler_static_CXX='-non_shared'
13849 ;;
13850 xlc* | xlC* | bgxl[cC]* | mpixl[cC]*)
13851 # IBM XL 8.0, 9.0 on PPC and BlueGene
13852 lt_prog_compiler_wl_CXX='-Wl,'
13853 lt_prog_compiler_pic_CXX='-qpic'
13854 lt_prog_compiler_static_CXX='-qstaticlink'
13855 ;;
13856 *)
13857 case `$CC -V 2>&1 | sed 5q` in
13858 *Sun\ C*)
13859 # Sun C++ 5.9
13860 lt_prog_compiler_pic_CXX='-KPIC'
13861 lt_prog_compiler_static_CXX='-Bstatic'
13862 lt_prog_compiler_wl_CXX='-Qoption ld '
13863 ;;
13864 esac
13865 ;;
13866 esac
13867 ;;
13868 lynxos*)
13869 ;;
13870 m88k*)
13871 ;;
13872 mvs*)
13873 case $cc_basename in
13874 cxx*)
13875 lt_prog_compiler_pic_CXX='-W c,exportall'
13876 ;;
13877 *)
13878 ;;
13879 esac
13880 ;;
13881 netbsd*)
13882 ;;
13883 *qnx* | *nto*)
13884 # QNX uses GNU C++, but need to define -shared option too, otherwise
13885 # it will coredump.
13886 lt_prog_compiler_pic_CXX='-fPIC -shared'
13887 ;;
13888 osf3* | osf4* | osf5*)
13889 case $cc_basename in
13890 KCC*)
13891 lt_prog_compiler_wl_CXX='--backend -Wl,'
13892 ;;
13893 RCC*)
13894 # Rational C++ 2.4.1
13895 lt_prog_compiler_pic_CXX='-pic'
13896 ;;
13897 cxx*)
13898 # Digital/Compaq C++
13899 lt_prog_compiler_wl_CXX='-Wl,'
13900 # Make sure the PIC flag is empty. It appears that all Alpha
13901 # Linux and Compaq Tru64 Unix objects are PIC.
13902 lt_prog_compiler_pic_CXX=
13903 lt_prog_compiler_static_CXX='-non_shared'
13904 ;;
13905 *)
13906 ;;
13907 esac
13908 ;;
13909 psos*)
13910 ;;
13911 solaris*)
13912 case $cc_basename in
13913 CC* | sunCC*)
13914 # Sun C++ 4.2, 5.x and Centerline C++
13915 lt_prog_compiler_pic_CXX='-KPIC'
13916 lt_prog_compiler_static_CXX='-Bstatic'
13917 lt_prog_compiler_wl_CXX='-Qoption ld '
13918 ;;
13919 gcx*)
13920 # Green Hills C++ Compiler
13921 lt_prog_compiler_pic_CXX='-PIC'
13922 ;;
13923 *)
13924 ;;
13925 esac
13926 ;;
13927 sunos4*)
13928 case $cc_basename in
13929 CC*)
13930 # Sun C++ 4.x
13931 lt_prog_compiler_pic_CXX='-pic'
13932 lt_prog_compiler_static_CXX='-Bstatic'
13933 ;;
13934 lcc*)
13935 # Lucid
13936 lt_prog_compiler_pic_CXX='-pic'
13937 ;;
13938 *)
13939 ;;
13940 esac
13941 ;;
13942 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
13943 case $cc_basename in
13944 CC*)
13945 lt_prog_compiler_wl_CXX='-Wl,'
13946 lt_prog_compiler_pic_CXX='-KPIC'
13947 lt_prog_compiler_static_CXX='-Bstatic'
13948 ;;
13949 esac
13950 ;;
13951 tandem*)
13952 case $cc_basename in
13953 NCC*)
13954 # NonStop-UX NCC 3.20
13955 lt_prog_compiler_pic_CXX='-KPIC'
13956 ;;
13957 *)
13958 ;;
13959 esac
13960 ;;
13961 vxworks*)
13962 ;;
13963 *)
13964 lt_prog_compiler_can_build_shared_CXX=no
13965 ;;
13966 esac
13967 fi
13968
13969case $host_os in
13970 # For platforms which do not support PIC, -DPIC is meaningless:
13971 *djgpp*)
13972 lt_prog_compiler_pic_CXX=
13973 ;;
13974 *)
13975 lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC"
13976 ;;
13977esac
13978
13979{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
13980$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
13981if ${lt_cv_prog_compiler_pic_CXX+:} false; then :
13982 $as_echo_n "(cached) " >&6
13983else
13984 lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX
13985fi
13986{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5
13987$as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; }
13988lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX
13989
13990#
13991# Check to make sure the PIC flag actually works.
13992#
13993if test -n "$lt_prog_compiler_pic_CXX"; then
13994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
13995$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; }
13996if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then :
13997 $as_echo_n "(cached) " >&6
13998else
13999 lt_cv_prog_compiler_pic_works_CXX=no
14000 ac_outfile=conftest.$ac_objext
14001 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
14002 lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC"
14003 # Insert the option either (1) after the last *FLAGS variable, or
14004 # (2) before a word containing "conftest.", or (3) at the end.
14005 # Note that $ac_compile itself does not contain backslashes and begins
14006 # with a dollar sign (not a hyphen), so the echo should work correctly.
14007 # The option is referenced via a variable to avoid confusing sed.
14008 lt_compile=`echo "$ac_compile" | $SED \
14009 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
14010 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
14011 -e 's:$: $lt_compiler_flag:'`
14012 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
14013 (eval "$lt_compile" 2>conftest.err)
14014 ac_status=$?
14015 cat conftest.err >&5
14016 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14017 if (exit $ac_status) && test -s "$ac_outfile"; then
14018 # The compiler can only warn and ignore the option if not recognized
14019 # So say no if there are warnings other than the usual output.
14020 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
14021 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
14022 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
14023 lt_cv_prog_compiler_pic_works_CXX=yes
14024 fi
14025 fi
14026 $RM conftest*
14027
14028fi
14029{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5
14030$as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; }
14031
14032if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then
14033 case $lt_prog_compiler_pic_CXX in
14034 "" | " "*) ;;
14035 *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;;
14036 esac
14037else
14038 lt_prog_compiler_pic_CXX=
14039 lt_prog_compiler_can_build_shared_CXX=no
14040fi
14041
14042fi
14043
14044
14045
14046
14047
14048#
14049# Check to make sure the static flag actually works.
14050#
14051wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\"
14052{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
14053$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
14054if ${lt_cv_prog_compiler_static_works_CXX+:} false; then :
14055 $as_echo_n "(cached) " >&6
14056else
14057 lt_cv_prog_compiler_static_works_CXX=no
14058 save_LDFLAGS="$LDFLAGS"
14059 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
14060 echo "$lt_simple_link_test_code" > conftest.$ac_ext
14061 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
14062 # The linker can only warn and ignore the option if not recognized
14063 # So say no if there are warnings
14064 if test -s conftest.err; then
14065 # Append any errors to the config.log.
14066 cat conftest.err 1>&5
14067 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
14068 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
14069 if diff conftest.exp conftest.er2 >/dev/null; then
14070 lt_cv_prog_compiler_static_works_CXX=yes
14071 fi
14072 else
14073 lt_cv_prog_compiler_static_works_CXX=yes
14074 fi
14075 fi
14076 $RM -r conftest*
14077 LDFLAGS="$save_LDFLAGS"
14078
14079fi
14080{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5
14081$as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; }
14082
14083if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then
14084 :
14085else
14086 lt_prog_compiler_static_CXX=
14087fi
14088
14089
14090
14091
14092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
14093$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
14094if ${lt_cv_prog_compiler_c_o_CXX+:} false; then :
14095 $as_echo_n "(cached) " >&6
14096else
14097 lt_cv_prog_compiler_c_o_CXX=no
14098 $RM -r conftest 2>/dev/null
14099 mkdir conftest
14100 cd conftest
14101 mkdir out
14102 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
14103
14104 lt_compiler_flag="-o out/conftest2.$ac_objext"
14105 # Insert the option either (1) after the last *FLAGS variable, or
14106 # (2) before a word containing "conftest.", or (3) at the end.
14107 # Note that $ac_compile itself does not contain backslashes and begins
14108 # with a dollar sign (not a hyphen), so the echo should work correctly.
14109 lt_compile=`echo "$ac_compile" | $SED \
14110 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
14111 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
14112 -e 's:$: $lt_compiler_flag:'`
14113 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
14114 (eval "$lt_compile" 2>out/conftest.err)
14115 ac_status=$?
14116 cat out/conftest.err >&5
14117 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14118 if (exit $ac_status) && test -s out/conftest2.$ac_objext
14119 then
14120 # The compiler can only warn and ignore the option if not recognized
14121 # So say no if there are warnings
14122 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
14123 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
14124 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
14125 lt_cv_prog_compiler_c_o_CXX=yes
14126 fi
14127 fi
14128 chmod u+w . 2>&5
14129 $RM conftest*
14130 # SGI C++ compiler will create directory out/ii_files/ for
14131 # template instantiation
14132 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
14133 $RM out/* && rmdir out
14134 cd ..
14135 $RM -r conftest
14136 $RM conftest*
14137
14138fi
14139{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
14140$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; }
14141
14142
14143
14144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
14145$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
14146if ${lt_cv_prog_compiler_c_o_CXX+:} false; then :
14147 $as_echo_n "(cached) " >&6
14148else
14149 lt_cv_prog_compiler_c_o_CXX=no
14150 $RM -r conftest 2>/dev/null
14151 mkdir conftest
14152 cd conftest
14153 mkdir out
14154 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
14155
14156 lt_compiler_flag="-o out/conftest2.$ac_objext"
14157 # Insert the option either (1) after the last *FLAGS variable, or
14158 # (2) before a word containing "conftest.", or (3) at the end.
14159 # Note that $ac_compile itself does not contain backslashes and begins
14160 # with a dollar sign (not a hyphen), so the echo should work correctly.
14161 lt_compile=`echo "$ac_compile" | $SED \
14162 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
14163 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
14164 -e 's:$: $lt_compiler_flag:'`
14165 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
14166 (eval "$lt_compile" 2>out/conftest.err)
14167 ac_status=$?
14168 cat out/conftest.err >&5
14169 echo "$as_me:$LINENO: \$? = $ac_status" >&5
14170 if (exit $ac_status) && test -s out/conftest2.$ac_objext
14171 then
14172 # The compiler can only warn and ignore the option if not recognized
14173 # So say no if there are warnings
14174 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
14175 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
14176 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
14177 lt_cv_prog_compiler_c_o_CXX=yes
14178 fi
14179 fi
14180 chmod u+w . 2>&5
14181 $RM conftest*
14182 # SGI C++ compiler will create directory out/ii_files/ for
14183 # template instantiation
14184 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
14185 $RM out/* && rmdir out
14186 cd ..
14187 $RM -r conftest
14188 $RM conftest*
14189
14190fi
14191{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
14192$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; }
14193
14194
14195
14196
14197hard_links="nottested"
14198if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then
14199 # do not overwrite the value of need_locks provided by the user
14200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
14201$as_echo_n "checking if we can lock with hard links... " >&6; }
14202 hard_links=yes
14203 $RM conftest*
14204 ln conftest.a conftest.b 2>/dev/null && hard_links=no
14205 touch conftest.a
14206 ln conftest.a conftest.b 2>&5 || hard_links=no
14207 ln conftest.a conftest.b 2>/dev/null && hard_links=no
14208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
14209$as_echo "$hard_links" >&6; }
14210 if test "$hard_links" = no; then
14211 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
14212$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
14213 need_locks=warn
14214 fi
14215else
14216 need_locks=no
14217fi
14218
14219
14220
14221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
14222$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
14223
14224 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
14225 exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
14226 case $host_os in
14227 aix[4-9]*)
14228 # If we're using GNU nm, then we don't want the "-C" option.
14229 # -C means demangle to AIX nm, but means don't demangle with GNU nm
14230 # Also, AIX nm treats weak defined symbols like other global defined
14231 # symbols, whereas GNU nm marks them as "W".
14232 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
14233 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'
14234 else
14235 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'
14236 fi
14237 ;;
14238 pw32*)
14239 export_symbols_cmds_CXX="$ltdll_cmds"
14240 ;;
14241 cygwin* | mingw* | cegcc*)
14242 case $cc_basename in
14243 cl*)
14244 exclude_expsyms_CXX='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
14245 ;;
14246 *)
14247 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
14248 exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
14249 ;;
14250 esac
14251 ;;
14252 *)
14253 export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
14254 ;;
14255 esac
14256
14257{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
14258$as_echo "$ld_shlibs_CXX" >&6; }
14259test "$ld_shlibs_CXX" = no && can_build_shared=no
14260
14261with_gnu_ld_CXX=$with_gnu_ld
14262
14263
14264
14265
14266
14267
14268#
14269# Do we need to explicitly link libc?
14270#
14271case "x$archive_cmds_need_lc_CXX" in
14272x|xyes)
14273 # Assume -lc should be added
14274 archive_cmds_need_lc_CXX=yes
14275
14276 if test "$enable_shared" = yes && test "$GCC" = yes; then
14277 case $archive_cmds_CXX in
14278 *'~'*)
14279 # FIXME: we may have to deal with multi-command sequences.
14280 ;;
14281 '$CC '*)
14282 # Test whether the compiler implicitly links with -lc since on some
14283 # systems, -lgcc has to come before -lc. If gcc already passes -lc
14284 # to ld, don't add -lc before -lgcc.
14285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
14286$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
14287if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then :
14288 $as_echo_n "(cached) " >&6
14289else
14290 $RM conftest*
14291 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
14292
14293 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
14294 (eval $ac_compile) 2>&5
14295 ac_status=$?
14296 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14297 test $ac_status = 0; } 2>conftest.err; then
14298 soname=conftest
14299 lib=conftest
14300 libobjs=conftest.$ac_objext
14301 deplibs=
14302 wl=$lt_prog_compiler_wl_CXX
14303 pic_flag=$lt_prog_compiler_pic_CXX
14304 compiler_flags=-v
14305 linker_flags=-v
14306 verstring=
14307 output_objdir=.
14308 libname=conftest
14309 lt_save_allow_undefined_flag=$allow_undefined_flag_CXX
14310 allow_undefined_flag_CXX=
14311 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
14312 (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
14313 ac_status=$?
14314 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
14315 test $ac_status = 0; }
14316 then
14317 lt_cv_archive_cmds_need_lc_CXX=no
14318 else
14319 lt_cv_archive_cmds_need_lc_CXX=yes
14320 fi
14321 allow_undefined_flag_CXX=$lt_save_allow_undefined_flag
14322 else
14323 cat conftest.err 1>&5
14324 fi
14325 $RM conftest*
14326
14327fi
14328{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5
14329$as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; }
14330 archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX
14331 ;;
14332 esac
14333 fi
14334 ;;
14335esac
14336
14337
14338
14339
14340
14341
14342
14343
14344
14345
14346
14347
14348
14349
14350
14351
14352
14353
14354
14355
14356
14357
14358
14359
14360
14361
14362
14363
14364
14365
14366
14367
14368
14369
14370
14371
14372
14373
14374
14375
14376
14377
14378
14379
14380
14381
14382
14383
14384
14385
14386
14387
14388
14389
14390
14391
14392
14393
14394
14395
14396
14397
14398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
14399$as_echo_n "checking dynamic linker characteristics... " >&6; }
14400
14401library_names_spec=
14402libname_spec='lib$name'
14403soname_spec=
14404shrext_cmds=".so"
14405postinstall_cmds=
14406postuninstall_cmds=
14407finish_cmds=
14408finish_eval=
14409shlibpath_var=
14410shlibpath_overrides_runpath=unknown
14411version_type=none
14412dynamic_linker="$host_os ld.so"
14413sys_lib_dlsearch_path_spec="/lib /usr/lib"
14414need_lib_prefix=unknown
14415hardcode_into_libs=no
14416
14417# when you set need_version to no, make sure it does not cause -set_version
14418# flags to be left without arguments
14419need_version=unknown
14420
14421case $host_os in
14422aix3*)
14423 version_type=linux # correct to gnu/linux during the next big refactor
14424 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
14425 shlibpath_var=LIBPATH
14426
14427 # AIX 3 has no versioning support, so we append a major version to the name.
14428 soname_spec='${libname}${release}${shared_ext}$major'
14429 ;;
14430
14431aix[4-9]*)
14432 version_type=linux # correct to gnu/linux during the next big refactor
14433 need_lib_prefix=no
14434 need_version=no
14435 hardcode_into_libs=yes
14436 if test "$host_cpu" = ia64; then
14437 # AIX 5 supports IA64
14438 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
14439 shlibpath_var=LD_LIBRARY_PATH
14440 else
14441 # With GCC up to 2.95.x, collect2 would create an import file
14442 # for dependence libraries. The import file would start with
14443 # the line `#! .'. This would cause the generated library to
14444 # depend on `.', always an invalid library. This was fixed in
14445 # development snapshots of GCC prior to 3.0.
14446 case $host_os in
14447 aix4 | aix4.[01] | aix4.[01].*)
14448 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
14449 echo ' yes '
14450 echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
14451 :
14452 else
14453 can_build_shared=no
14454 fi
14455 ;;
14456 esac
14457 # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
14458 # soname into executable. Probably we can add versioning support to
14459 # collect2, so additional links can be useful in future.
14460 if test "$aix_use_runtimelinking" = yes; then
14461 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
14462 # instead of lib<name>.a to let people know that these are not
14463 # typical AIX shared libraries.
14464 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14465 else
14466 # We preserve .a as extension for shared libraries through AIX4.2
14467 # and later when we are not doing run time linking.
14468 library_names_spec='${libname}${release}.a $libname.a'
14469 soname_spec='${libname}${release}${shared_ext}$major'
14470 fi
14471 shlibpath_var=LIBPATH
14472 fi
14473 ;;
14474
14475amigaos*)
14476 case $host_cpu in
14477 powerpc)
14478 # Since July 2007 AmigaOS4 officially supports .so libraries.
14479 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
14480 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14481 ;;
14482 m68k)
14483 library_names_spec='$libname.ixlibrary $libname.a'
14484 # Create ${libname}_ixlibrary.a entries in /sys/libs.
14485 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'
14486 ;;
14487 esac
14488 ;;
14489
14490beos*)
14491 library_names_spec='${libname}${shared_ext}'
14492 dynamic_linker="$host_os ld.so"
14493 shlibpath_var=LIBRARY_PATH
14494 ;;
14495
14496bsdi[45]*)
14497 version_type=linux # correct to gnu/linux during the next big refactor
14498 need_version=no
14499 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14500 soname_spec='${libname}${release}${shared_ext}$major'
14501 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
14502 shlibpath_var=LD_LIBRARY_PATH
14503 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
14504 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
14505 # the default ld.so.conf also contains /usr/contrib/lib and
14506 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
14507 # libtool to hard-code these into programs
14508 ;;
14509
14510cygwin* | mingw* | pw32* | cegcc*)
14511 version_type=windows
14512 shrext_cmds=".dll"
14513 need_version=no
14514 need_lib_prefix=no
14515
14516 case $GCC,$cc_basename in
14517 yes,*)
14518 # gcc
14519 library_names_spec='$libname.dll.a'
14520 # DLL is installed to $(libdir)/../bin by postinstall_cmds
14521 postinstall_cmds='base_file=`basename \${file}`~
14522 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
14523 dldir=$destdir/`dirname \$dlpath`~
14524 test -d \$dldir || mkdir -p \$dldir~
14525 $install_prog $dir/$dlname \$dldir/$dlname~
14526 chmod a+x \$dldir/$dlname~
14527 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
14528 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
14529 fi'
14530 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
14531 dlpath=$dir/\$dldll~
14532 $RM \$dlpath'
14533 shlibpath_overrides_runpath=yes
14534
14535 case $host_os in
14536 cygwin*)
14537 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
14538 soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14539
14540 ;;
14541 mingw* | cegcc*)
14542 # MinGW DLLs use traditional 'lib' prefix
14543 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14544 ;;
14545 pw32*)
14546 # pw32 DLLs use 'pw' prefix rather than 'lib'
14547 library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14548 ;;
14549 esac
14550 dynamic_linker='Win32 ld.exe'
14551 ;;
14552
14553 *,cl*)
14554 # Native MSVC
14555 libname_spec='$name'
14556 soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14557 library_names_spec='${libname}.dll.lib'
14558
14559 case $build_os in
14560 mingw*)
14561 sys_lib_search_path_spec=
14562 lt_save_ifs=$IFS
14563 IFS=';'
14564 for lt_path in $LIB
14565 do
14566 IFS=$lt_save_ifs
14567 # Let DOS variable expansion print the short 8.3 style file name.
14568 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
14569 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
14570 done
14571 IFS=$lt_save_ifs
14572 # Convert to MSYS style.
14573 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
14574 ;;
14575 cygwin*)
14576 # Convert to unix form, then to dos form, then back to unix form
14577 # but this time dos style (no spaces!) so that the unix form looks
14578 # like /cygdrive/c/PROGRA~1:/cygdr...
14579 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
14580 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
14581 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
14582 ;;
14583 *)
14584 sys_lib_search_path_spec="$LIB"
14585 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
14586 # It is most probably a Windows format PATH.
14587 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
14588 else
14589 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
14590 fi
14591 # FIXME: find the short name or the path components, as spaces are
14592 # common. (e.g. "Program Files" -> "PROGRA~1")
14593 ;;
14594 esac
14595
14596 # DLL is installed to $(libdir)/../bin by postinstall_cmds
14597 postinstall_cmds='base_file=`basename \${file}`~
14598 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
14599 dldir=$destdir/`dirname \$dlpath`~
14600 test -d \$dldir || mkdir -p \$dldir~
14601 $install_prog $dir/$dlname \$dldir/$dlname'
14602 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
14603 dlpath=$dir/\$dldll~
14604 $RM \$dlpath'
14605 shlibpath_overrides_runpath=yes
14606 dynamic_linker='Win32 link.exe'
14607 ;;
14608
14609 *)
14610 # Assume MSVC wrapper
14611 library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
14612 dynamic_linker='Win32 ld.exe'
14613 ;;
14614 esac
14615 # FIXME: first we should search . and the directory the executable is in
14616 shlibpath_var=PATH
14617 ;;
14618
14619darwin* | rhapsody*)
14620 dynamic_linker="$host_os dyld"
14621 version_type=darwin
14622 need_lib_prefix=no
14623 need_version=no
14624 library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
14625 soname_spec='${libname}${release}${major}$shared_ext'
14626 shlibpath_overrides_runpath=yes
14627 shlibpath_var=DYLD_LIBRARY_PATH
14628 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
14629
14630 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
14631 ;;
14632
14633dgux*)
14634 version_type=linux # correct to gnu/linux during the next big refactor
14635 need_lib_prefix=no
14636 need_version=no
14637 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
14638 soname_spec='${libname}${release}${shared_ext}$major'
14639 shlibpath_var=LD_LIBRARY_PATH
14640 ;;
14641
14642freebsd* | dragonfly*)
14643 # DragonFly does not have aout. When/if they implement a new
14644 # versioning mechanism, adjust this.
14645 if test -x /usr/bin/objformat; then
14646 objformat=`/usr/bin/objformat`
14647 else
14648 case $host_os in
14649 freebsd[23].*) objformat=aout ;;
14650 *) objformat=elf ;;
14651 esac
14652 fi
14653 version_type=freebsd-$objformat
14654 case $version_type in
14655 freebsd-elf*)
14656 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
14657 need_version=no
14658 need_lib_prefix=no
14659 ;;
14660 freebsd-*)
14661 library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
14662 need_version=yes
14663 ;;
14664 esac
14665 shlibpath_var=LD_LIBRARY_PATH
14666 case $host_os in
14667 freebsd2.*)
14668 shlibpath_overrides_runpath=yes
14669 ;;
14670 freebsd3.[01]* | freebsdelf3.[01]*)
14671 shlibpath_overrides_runpath=yes
14672 hardcode_into_libs=yes
14673 ;;
14674 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
14675 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
14676 shlibpath_overrides_runpath=no
14677 hardcode_into_libs=yes
14678 ;;
14679 *) # from 4.6 on, and DragonFly
14680 shlibpath_overrides_runpath=yes
14681 hardcode_into_libs=yes
14682 ;;
14683 esac
14684 ;;
14685
14686gnu*)
14687 version_type=linux # correct to gnu/linux during the next big refactor
14688 need_lib_prefix=no
14689 need_version=no
14690 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
14691 soname_spec='${libname}${release}${shared_ext}$major'
14692 shlibpath_var=LD_LIBRARY_PATH
14693 shlibpath_overrides_runpath=no
14694 hardcode_into_libs=yes
14695 ;;
14696
14697haiku*)
14698 version_type=linux # correct to gnu/linux during the next big refactor
14699 need_lib_prefix=no
14700 need_version=no
14701 dynamic_linker="$host_os runtime_loader"
14702 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
14703 soname_spec='${libname}${release}${shared_ext}$major'
14704 shlibpath_var=LIBRARY_PATH
14705 shlibpath_overrides_runpath=yes
14706 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
14707 hardcode_into_libs=yes
14708 ;;
14709
14710hpux9* | hpux10* | hpux11*)
14711 # Give a soname corresponding to the major version so that dld.sl refuses to
14712 # link against other versions.
14713 version_type=sunos
14714 need_lib_prefix=no
14715 need_version=no
14716 case $host_cpu in
14717 ia64*)
14718 shrext_cmds='.so'
14719 hardcode_into_libs=yes
14720 dynamic_linker="$host_os dld.so"
14721 shlibpath_var=LD_LIBRARY_PATH
14722 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
14723 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14724 soname_spec='${libname}${release}${shared_ext}$major'
14725 if test "X$HPUX_IA64_MODE" = X32; then
14726 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
14727 else
14728 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
14729 fi
14730 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
14731 ;;
14732 hppa*64*)
14733 shrext_cmds='.sl'
14734 hardcode_into_libs=yes
14735 dynamic_linker="$host_os dld.sl"
14736 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
14737 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
14738 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14739 soname_spec='${libname}${release}${shared_ext}$major'
14740 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
14741 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
14742 ;;
14743 *)
14744 shrext_cmds='.sl'
14745 dynamic_linker="$host_os dld.sl"
14746 shlibpath_var=SHLIB_PATH
14747 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
14748 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14749 soname_spec='${libname}${release}${shared_ext}$major'
14750 ;;
14751 esac
14752 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
14753 postinstall_cmds='chmod 555 $lib'
14754 # or fails outright, so override atomically:
14755 install_override_mode=555
14756 ;;
14757
14758interix[3-9]*)
14759 version_type=linux # correct to gnu/linux during the next big refactor
14760 need_lib_prefix=no
14761 need_version=no
14762 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
14763 soname_spec='${libname}${release}${shared_ext}$major'
14764 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
14765 shlibpath_var=LD_LIBRARY_PATH
14766 shlibpath_overrides_runpath=no
14767 hardcode_into_libs=yes
14768 ;;
14769
14770irix5* | irix6* | nonstopux*)
14771 case $host_os in
14772 nonstopux*) version_type=nonstopux ;;
14773 *)
14774 if test "$lt_cv_prog_gnu_ld" = yes; then
14775 version_type=linux # correct to gnu/linux during the next big refactor
14776 else
14777 version_type=irix
14778 fi ;;
14779 esac
14780 need_lib_prefix=no
14781 need_version=no
14782 soname_spec='${libname}${release}${shared_ext}$major'
14783 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
14784 case $host_os in
14785 irix5* | nonstopux*)
14786 libsuff= shlibsuff=
14787 ;;
14788 *)
14789 case $LD in # libtool.m4 will add one of these switches to LD
14790 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
14791 libsuff= shlibsuff= libmagic=32-bit;;
14792 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
14793 libsuff=32 shlibsuff=N32 libmagic=N32;;
14794 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
14795 libsuff=64 shlibsuff=64 libmagic=64-bit;;
14796 *) libsuff= shlibsuff= libmagic=never-match;;
14797 esac
14798 ;;
14799 esac
14800 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
14801 shlibpath_overrides_runpath=no
14802 sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
14803 sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
14804 hardcode_into_libs=yes
14805 ;;
14806
14807# No shared lib support for Linux oldld, aout, or coff.
14808linux*oldld* | linux*aout* | linux*coff*)
14809 dynamic_linker=no
14810 ;;
14811
14812# This must be glibc/ELF.
14813linux* | k*bsd*-gnu | kopensolaris*-gnu)
14814 version_type=linux # correct to gnu/linux during the next big refactor
14815 need_lib_prefix=no
14816 need_version=no
14817 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14818 soname_spec='${libname}${release}${shared_ext}$major'
14819 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
14820 shlibpath_var=LD_LIBRARY_PATH
14821 shlibpath_overrides_runpath=no
14822
14823 # Some binutils ld are patched to set DT_RUNPATH
14824 if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
14825 $as_echo_n "(cached) " >&6
14826else
14827 lt_cv_shlibpath_overrides_runpath=no
14828 save_LDFLAGS=$LDFLAGS
14829 save_libdir=$libdir
14830 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \
14831 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\""
14832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14833/* end confdefs.h. */
14834
14835int
14836main ()
14837{
14838
14839 ;
14840 return 0;
14841}
14842_ACEOF
14843if ac_fn_cxx_try_link "$LINENO"; then :
14844 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
14845 lt_cv_shlibpath_overrides_runpath=yes
14846fi
14847fi
14848rm -f core conftest.err conftest.$ac_objext \
14849 conftest$ac_exeext conftest.$ac_ext
14850 LDFLAGS=$save_LDFLAGS
14851 libdir=$save_libdir
14852
14853fi
14854
14855 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
14856
14857 # This implies no fast_install, which is unacceptable.
14858 # Some rework will be needed to allow for fast_install
14859 # before this can be enabled.
14860 hardcode_into_libs=yes
14861
14862 # Append ld.so.conf contents to the search path
14863 if test -f /etc/ld.so.conf; then
14864 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' ' '`
14865 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
14866 fi
14867
14868 # We used to test for /lib/ld.so.1 and disable shared libraries on
14869 # powerpc, because MkLinux only supported shared libraries with the
14870 # GNU dynamic linker. Since this was broken with cross compilers,
14871 # most powerpc-linux boxes support dynamic linking these days and
14872 # people can always --disable-shared, the test was removed, and we
14873 # assume the GNU/Linux dynamic linker is in use.
14874 dynamic_linker='GNU/Linux ld.so'
14875 ;;
14876
14877netbsd*)
14878 version_type=sunos
14879 need_lib_prefix=no
14880 need_version=no
14881 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
14882 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
14883 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
14884 dynamic_linker='NetBSD (a.out) ld.so'
14885 else
14886 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
14887 soname_spec='${libname}${release}${shared_ext}$major'
14888 dynamic_linker='NetBSD ld.elf_so'
14889 fi
14890 shlibpath_var=LD_LIBRARY_PATH
14891 shlibpath_overrides_runpath=yes
14892 hardcode_into_libs=yes
14893 ;;
14894
14895newsos6)
14896 version_type=linux # correct to gnu/linux during the next big refactor
14897 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14898 shlibpath_var=LD_LIBRARY_PATH
14899 shlibpath_overrides_runpath=yes
14900 ;;
14901
14902*nto* | *qnx*)
14903 version_type=qnx
14904 need_lib_prefix=no
14905 need_version=no
14906 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14907 soname_spec='${libname}${release}${shared_ext}$major'
14908 shlibpath_var=LD_LIBRARY_PATH
14909 shlibpath_overrides_runpath=no
14910 hardcode_into_libs=yes
14911 dynamic_linker='ldqnx.so'
14912 ;;
14913
14914openbsd*)
14915 version_type=sunos
14916 sys_lib_dlsearch_path_spec="/usr/lib"
14917 need_lib_prefix=no
14918 # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
14919 case $host_os in
14920 openbsd3.3 | openbsd3.3.*) need_version=yes ;;
14921 *) need_version=no ;;
14922 esac
14923 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
14924 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
14925 shlibpath_var=LD_LIBRARY_PATH
14926 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
14927 case $host_os in
14928 openbsd2.[89] | openbsd2.[89].*)
14929 shlibpath_overrides_runpath=no
14930 ;;
14931 *)
14932 shlibpath_overrides_runpath=yes
14933 ;;
14934 esac
14935 else
14936 shlibpath_overrides_runpath=yes
14937 fi
14938 ;;
14939
14940os2*)
14941 libname_spec='$name'
14942 shrext_cmds=".dll"
14943 need_lib_prefix=no
14944 library_names_spec='$libname${shared_ext} $libname.a'
14945 dynamic_linker='OS/2 ld.exe'
14946 shlibpath_var=LIBPATH
14947 ;;
14948
14949osf3* | osf4* | osf5*)
14950 version_type=osf
14951 need_lib_prefix=no
14952 need_version=no
14953 soname_spec='${libname}${release}${shared_ext}$major'
14954 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14955 shlibpath_var=LD_LIBRARY_PATH
14956 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
14957 sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
14958 ;;
14959
14960rdos*)
14961 dynamic_linker=no
14962 ;;
14963
14964solaris*)
14965 version_type=linux # correct to gnu/linux during the next big refactor
14966 need_lib_prefix=no
14967 need_version=no
14968 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14969 soname_spec='${libname}${release}${shared_ext}$major'
14970 shlibpath_var=LD_LIBRARY_PATH
14971 shlibpath_overrides_runpath=yes
14972 hardcode_into_libs=yes
14973 # ldd complains unless libraries are executable
14974 postinstall_cmds='chmod +x $lib'
14975 ;;
14976
14977sunos4*)
14978 version_type=sunos
14979 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
14980 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
14981 shlibpath_var=LD_LIBRARY_PATH
14982 shlibpath_overrides_runpath=yes
14983 if test "$with_gnu_ld" = yes; then
14984 need_lib_prefix=no
14985 fi
14986 need_version=yes
14987 ;;
14988
14989sysv4 | sysv4.3*)
14990 version_type=linux # correct to gnu/linux during the next big refactor
14991 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14992 soname_spec='${libname}${release}${shared_ext}$major'
14993 shlibpath_var=LD_LIBRARY_PATH
14994 case $host_vendor in
14995 sni)
14996 shlibpath_overrides_runpath=no
14997 need_lib_prefix=no
14998 runpath_var=LD_RUN_PATH
14999 ;;
15000 siemens)
15001 need_lib_prefix=no
15002 ;;
15003 motorola)
15004 need_lib_prefix=no
15005 need_version=no
15006 shlibpath_overrides_runpath=no
15007 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
15008 ;;
15009 esac
15010 ;;
15011
15012sysv4*MP*)
15013 if test -d /usr/nec ;then
15014 version_type=linux # correct to gnu/linux during the next big refactor
15015 library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
15016 soname_spec='$libname${shared_ext}.$major'
15017 shlibpath_var=LD_LIBRARY_PATH
15018 fi
15019 ;;
15020
15021sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
15022 version_type=freebsd-elf
15023 need_lib_prefix=no
15024 need_version=no
15025 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
15026 soname_spec='${libname}${release}${shared_ext}$major'
15027 shlibpath_var=LD_LIBRARY_PATH
15028 shlibpath_overrides_runpath=yes
15029 hardcode_into_libs=yes
15030 if test "$with_gnu_ld" = yes; then
15031 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
15032 else
15033 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
15034 case $host_os in
15035 sco3.2v5*)
15036 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
15037 ;;
15038 esac
15039 fi
15040 sys_lib_dlsearch_path_spec='/usr/lib'
15041 ;;
15042
15043tpf*)
15044 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
15045 version_type=linux # correct to gnu/linux during the next big refactor
15046 need_lib_prefix=no
15047 need_version=no
15048 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15049 shlibpath_var=LD_LIBRARY_PATH
15050 shlibpath_overrides_runpath=no
15051 hardcode_into_libs=yes
15052 ;;
15053
15054uts4*)
15055 version_type=linux # correct to gnu/linux during the next big refactor
15056 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15057 soname_spec='${libname}${release}${shared_ext}$major'
15058 shlibpath_var=LD_LIBRARY_PATH
15059 ;;
15060
15061*)
15062 dynamic_linker=no
15063 ;;
15064esac
15065{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
15066$as_echo "$dynamic_linker" >&6; }
15067test "$dynamic_linker" = no && can_build_shared=no
15068
15069variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
15070if test "$GCC" = yes; then
15071 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
15072fi
15073
15074if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
15075 sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
15076fi
15077if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
15078 sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
15079fi
15080
15081
15082
15083
15084
15085
15086
15087
15088
15089
15090
15091
15092
15093
15094
15095
15096
15097
15098
15099
15100
15101
15102
15103
15104
15105
15106
15107
15108
15109
15110
15111
15112
15113
15114
15115
15116
15117
15118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
15119$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
15120hardcode_action_CXX=
15121if test -n "$hardcode_libdir_flag_spec_CXX" ||
15122 test -n "$runpath_var_CXX" ||
15123 test "X$hardcode_automatic_CXX" = "Xyes" ; then
15124
15125 # We can hardcode non-existent directories.
15126 if test "$hardcode_direct_CXX" != no &&
15127 # If the only mechanism to avoid hardcoding is shlibpath_var, we
15128 # have to relink, otherwise we might link with an installed library
15129 # when we should be linking with a yet-to-be-installed one
15130 ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no &&
15131 test "$hardcode_minus_L_CXX" != no; then
15132 # Linking always hardcodes the temporary library directory.
15133 hardcode_action_CXX=relink
15134 else
15135 # We can link without hardcoding, and we can hardcode nonexisting dirs.
15136 hardcode_action_CXX=immediate
15137 fi
15138else
15139 # We cannot hardcode anything, or else we can only hardcode existing
15140 # directories.
15141 hardcode_action_CXX=unsupported
15142fi
15143{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5
15144$as_echo "$hardcode_action_CXX" >&6; }
15145
15146if test "$hardcode_action_CXX" = relink ||
15147 test "$inherit_rpath_CXX" = yes; then
15148 # Fast installation is not supported
15149 enable_fast_install=no
15150elif test "$shlibpath_overrides_runpath" = yes ||
15151 test "$enable_shared" = no; then
15152 # Fast installation is not necessary
15153 enable_fast_install=needless
15154fi
15155
15156
15157
15158
15159
15160
15161
15162 fi # test -n "$compiler"
15163
15164 CC=$lt_save_CC
15165 CFLAGS=$lt_save_CFLAGS
15166 LDCXX=$LD
15167 LD=$lt_save_LD
15168 GCC=$lt_save_GCC
15169 with_gnu_ld=$lt_save_with_gnu_ld
15170 lt_cv_path_LDCXX=$lt_cv_path_LD
15171 lt_cv_path_LD=$lt_save_path_LD
15172 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
15173 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
15174fi # test "$_lt_caught_CXX_error" != yes
15175
15176ac_ext=c
15177ac_cpp='$CPP $CPPFLAGS'
15178ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15179ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15180ac_compiler_gnu=$ac_cv_c_compiler_gnu
15181
15182
15183
15184
15185
15186
15187
15188
15189
15190
15191
15192
15193
15194
15195
15196 ac_config_commands="$ac_config_commands libtool"
15197
15198
15199
15200
15201# Only expand once:
15202
15203
15204
15205
15206
15207INDENT="indent"
15208CPREPROCESSOR="cpp -P"
15209
15210# Extract the first word of "addr2line", so it can be a program name with args.
15211set dummy addr2line; ac_word=$2
15212{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15213$as_echo_n "checking for $ac_word... " >&6; }
15214if ${ac_cv_prog_HAVE_ADDR2LINE+:} false; then :
15215 $as_echo_n "(cached) " >&6
15216else
15217 if test -n "$HAVE_ADDR2LINE"; then
15218 ac_cv_prog_HAVE_ADDR2LINE="$HAVE_ADDR2LINE" # Let the user override the test.
15219else
15220as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15221for as_dir in $PATH
15222do
15223 IFS=$as_save_IFS
15224 test -z "$as_dir" && as_dir=.
15225 for ac_exec_ext in '' $ac_executable_extensions; do
15226 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15227 ac_cv_prog_HAVE_ADDR2LINE="yes"
15228 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15229 break 2
15230 fi
15231done
15232 done
15233IFS=$as_save_IFS
15234
15235fi
15236fi
15237HAVE_ADDR2LINE=$ac_cv_prog_HAVE_ADDR2LINE
15238if test -n "$HAVE_ADDR2LINE"; then
15239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_ADDR2LINE" >&5
15240$as_echo "$HAVE_ADDR2LINE" >&6; }
15241else
15242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15243$as_echo "no" >&6; }
15244fi
15245
15246
15247if test "x$HAVE_ADDR2LINE" == "xyes"; then
15248
15249$as_echo "#define HAVE_ADDR2LINE 1" >>confdefs.h
15250
15251fi
15252
15253# Checks for header files
15254{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
15255$as_echo_n "checking for ANSI C header files... " >&6; }
15256if ${ac_cv_header_stdc+:} false; then :
15257 $as_echo_n "(cached) " >&6
15258else
15259 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15260/* end confdefs.h. */
15261#include <stdlib.h>
15262#include <stdarg.h>
15263#include <string.h>
15264#include <float.h>
15265
15266int
15267main ()
15268{
15269
15270 ;
15271 return 0;
15272}
15273_ACEOF
15274if ac_fn_c_try_compile "$LINENO"; then :
15275 ac_cv_header_stdc=yes
15276else
15277 ac_cv_header_stdc=no
15278fi
15279rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15280
15281if test $ac_cv_header_stdc = yes; then
15282 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
15283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15284/* end confdefs.h. */
15285#include <string.h>
15286
15287_ACEOF
15288if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15289 $EGREP "memchr" >/dev/null 2>&1; then :
15290
15291else
15292 ac_cv_header_stdc=no
15293fi
15294rm -f conftest*
15295
15296fi
15297
15298if test $ac_cv_header_stdc = yes; then
15299 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
15300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15301/* end confdefs.h. */
15302#include <stdlib.h>
15303
15304_ACEOF
15305if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15306 $EGREP "free" >/dev/null 2>&1; then :
15307
15308else
15309 ac_cv_header_stdc=no
15310fi
15311rm -f conftest*
15312
15313fi
15314
15315if test $ac_cv_header_stdc = yes; then
15316 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
15317 if test "$cross_compiling" = yes; then :
15318 :
15319else
15320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15321/* end confdefs.h. */
15322#include <ctype.h>
15323#include <stdlib.h>
15324#if ((' ' & 0x0FF) == 0x020)
15325# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
15326# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
15327#else
15328# define ISLOWER(c) \
15329 (('a' <= (c) && (c) <= 'i') \
15330 || ('j' <= (c) && (c) <= 'r') \
15331 || ('s' <= (c) && (c) <= 'z'))
15332# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
15333#endif
15334
15335#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
15336int
15337main ()
15338{
15339 int i;
15340 for (i = 0; i < 256; i++)
15341 if (XOR (islower (i), ISLOWER (i))
15342 || toupper (i) != TOUPPER (i))
15343 return 2;
15344 return 0;
15345}
15346_ACEOF
15347if ac_fn_c_try_run "$LINENO"; then :
15348
15349else
15350 ac_cv_header_stdc=no
15351fi
15352rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15353 conftest.$ac_objext conftest.beam conftest.$ac_ext
15354fi
15355
15356fi
15357fi
15358{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
15359$as_echo "$ac_cv_header_stdc" >&6; }
15360if test $ac_cv_header_stdc = yes; then
15361
15362$as_echo "#define STDC_HEADERS 1" >>confdefs.h
15363
15364fi
15365
15366
15367# Checks for typedefs, structures, and compiler characteristics
15368# Check whether --enable-largefile was given.
15369if test "${enable_largefile+set}" = set; then :
15370 enableval=$enable_largefile;
15371fi
15372
15373if test "$enable_largefile" != no; then
15374
15375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
15376$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
15377if ${ac_cv_sys_largefile_CC+:} false; then :
15378 $as_echo_n "(cached) " >&6
15379else
15380 ac_cv_sys_largefile_CC=no
15381 if test "$GCC" != yes; then
15382 ac_save_CC=$CC
15383 while :; do
15384 # IRIX 6.2 and later do not support large files by default,
15385 # so use the C compiler's -n32 option if that helps.
15386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15387/* end confdefs.h. */
15388#include <sys/types.h>
15389 /* Check that off_t can represent 2**63 - 1 correctly.
15390 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15391 since some C++ compilers masquerading as C compilers
15392 incorrectly reject 9223372036854775807. */
15393#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15394 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15395 && LARGE_OFF_T % 2147483647 == 1)
15396 ? 1 : -1];
15397int
15398main ()
15399{
15400
15401 ;
15402 return 0;
15403}
15404_ACEOF
15405 if ac_fn_c_try_compile "$LINENO"; then :
15406 break
15407fi
15408rm -f core conftest.err conftest.$ac_objext
15409 CC="$CC -n32"
15410 if ac_fn_c_try_compile "$LINENO"; then :
15411 ac_cv_sys_largefile_CC=' -n32'; break
15412fi
15413rm -f core conftest.err conftest.$ac_objext
15414 break
15415 done
15416 CC=$ac_save_CC
15417 rm -f conftest.$ac_ext
15418 fi
15419fi
15420{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
15421$as_echo "$ac_cv_sys_largefile_CC" >&6; }
15422 if test "$ac_cv_sys_largefile_CC" != no; then
15423 CC=$CC$ac_cv_sys_largefile_CC
15424 fi
15425
15426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
15427$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
15428if ${ac_cv_sys_file_offset_bits+:} false; then :
15429 $as_echo_n "(cached) " >&6
15430else
15431 while :; do
15432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15433/* end confdefs.h. */
15434#include <sys/types.h>
15435 /* Check that off_t can represent 2**63 - 1 correctly.
15436 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15437 since some C++ compilers masquerading as C compilers
15438 incorrectly reject 9223372036854775807. */
15439#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15440 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15441 && LARGE_OFF_T % 2147483647 == 1)
15442 ? 1 : -1];
15443int
15444main ()
15445{
15446
15447 ;
15448 return 0;
15449}
15450_ACEOF
15451if ac_fn_c_try_compile "$LINENO"; then :
15452 ac_cv_sys_file_offset_bits=no; break
15453fi
15454rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15455 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15456/* end confdefs.h. */
15457#define _FILE_OFFSET_BITS 64
15458#include <sys/types.h>
15459 /* Check that off_t can represent 2**63 - 1 correctly.
15460 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15461 since some C++ compilers masquerading as C compilers
15462 incorrectly reject 9223372036854775807. */
15463#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15464 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15465 && LARGE_OFF_T % 2147483647 == 1)
15466 ? 1 : -1];
15467int
15468main ()
15469{
15470
15471 ;
15472 return 0;
15473}
15474_ACEOF
15475if ac_fn_c_try_compile "$LINENO"; then :
15476 ac_cv_sys_file_offset_bits=64; break
15477fi
15478rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15479 ac_cv_sys_file_offset_bits=unknown
15480 break
15481done
15482fi
15483{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
15484$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
15485case $ac_cv_sys_file_offset_bits in #(
15486 no | unknown) ;;
15487 *)
15488cat >>confdefs.h <<_ACEOF
15489#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
15490_ACEOF
15491;;
15492esac
15493rm -rf conftest*
15494 if test $ac_cv_sys_file_offset_bits = unknown; then
15495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
15496$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
15497if ${ac_cv_sys_large_files+:} false; then :
15498 $as_echo_n "(cached) " >&6
15499else
15500 while :; do
15501 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15502/* end confdefs.h. */
15503#include <sys/types.h>
15504 /* Check that off_t can represent 2**63 - 1 correctly.
15505 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15506 since some C++ compilers masquerading as C compilers
15507 incorrectly reject 9223372036854775807. */
15508#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15509 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15510 && LARGE_OFF_T % 2147483647 == 1)
15511 ? 1 : -1];
15512int
15513main ()
15514{
15515
15516 ;
15517 return 0;
15518}
15519_ACEOF
15520if ac_fn_c_try_compile "$LINENO"; then :
15521 ac_cv_sys_large_files=no; break
15522fi
15523rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15525/* end confdefs.h. */
15526#define _LARGE_FILES 1
15527#include <sys/types.h>
15528 /* Check that off_t can represent 2**63 - 1 correctly.
15529 We can't simply define LARGE_OFF_T to be 9223372036854775807,
15530 since some C++ compilers masquerading as C compilers
15531 incorrectly reject 9223372036854775807. */
15532#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
15533 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
15534 && LARGE_OFF_T % 2147483647 == 1)
15535 ? 1 : -1];
15536int
15537main ()
15538{
15539
15540 ;
15541 return 0;
15542}
15543_ACEOF
15544if ac_fn_c_try_compile "$LINENO"; then :
15545 ac_cv_sys_large_files=1; break
15546fi
15547rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15548 ac_cv_sys_large_files=unknown
15549 break
15550done
15551fi
15552{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
15553$as_echo "$ac_cv_sys_large_files" >&6; }
15554case $ac_cv_sys_large_files in #(
15555 no | unknown) ;;
15556 *)
15557cat >>confdefs.h <<_ACEOF
15558#define _LARGE_FILES $ac_cv_sys_large_files
15559_ACEOF
15560;;
15561esac
15562rm -rf conftest*
15563 fi
15564
15565
15566fi
15567
15568
15569# Checks for library functions
15570
15571
15572case "$host" in
15573 *linux*)
15574 CFLAGS="-std=gnu99 -static"
15575 if test "${enable_debug}" = "yes"; then
15576 CFLAGS="-g -DDEBUG=1 ${CFLAGS}"
15577 else
15578 CFLAGS="-g -O3 ${CFLAGS}"
15579 fi
15580 if test "${enable_prof}" = "yes"; then
15581 CFLAGS="-pg ${CFLAGS}"
15582 LFLAGS="-pg ${LFLAGS}"
15583 fi
15584
15585 if test "${enable_bounds_check}" = "yes"; then
15586 CFLAGS="-fbounds-check ${CFLAGS}"
15587 fi
15588
15589 RPATH_PREFIX="-Wl,"
15590
15591 ;;
15592 *darwin*)
15593 CFLAGS="-std=gnu99 -pedantic -Wno-overlength-strings"
15594 INDENT="gindent"
15595 CPREPROCESSOR="gcc -E -P -U__APPLE_CC__"
15596 if test "${enable_debug}" = "yes"; then
15597 CFLAGS="-g -DDEBUG=1 ${CFLAGS}"
15598 else
15599 CFLAGS="-g -O3 ${CFLAGS}"
15600 fi
15601
15602 if test "${enable_bounds_check}" = "yes"; then
15603 CFLAGS="-fbounds-check ${CFLAGS}"
15604 fi
15605
15606 RPATH_PREFIX="-Wl,"
15607
15608 ;;
15609 *)
15610 echo "Unknown machine"
15611 exit 1
15612 ;;
15613esac
15614
15615if test "${enable_detailed_timing}" = "yes"; then
15616 CFLAGS="-DDETAILED_TIMING=1 ${CFLAGS}"
15617fi
15618
15619if test "${enable_write_mem_usage}" = "no"; then
15620 CFLAGS="-DWRITE_MEM_USAGE=0 ${CFLAGS}"
15621fi
15622
15623if test "${enable_opencl}" != "no"; then
15624 case "$host" in
15625 *linux*)
15626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking OPENCL_INCLUDE environment variable to set OpenCL includes" >&5
15627$as_echo_n "checking OPENCL_INCLUDE environment variable to set OpenCL includes... " >&6; }
15628 opencl_inc_found="no"
15629 if test ! -z "${OPENCL_INCLUDE}" ; then
15630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: -I${OPENCL_INCLUDE}" >&5
15631$as_echo "-I${OPENCL_INCLUDE}" >&6; }
15632 opencl_inc_found="yes"
15633 AM_CPPFLAGS="${AM_CPPFLAGS} -I${OPENCL_INCLUDE}"
15634 else
15635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15636$as_echo "no" >&6; }
15637 fi
15638
15639 opencl_lib_found="no"
15640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking OPENCL_LIBS environment variable to set OpenCL libs" >&5
15641$as_echo_n "checking OPENCL_LIBS environment variable to set OpenCL libs... " >&6; }
15642 if test ! -z "${OPENCL_LIBS}" ; then
15643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: -L${OPENCL_LIBS} -lOpenCL" >&5
15644$as_echo "-L${OPENCL_LIBS} -lOpenCL" >&6; }
15645 opencl_lib_found="yes"
15646 LIBS="${LIBS} -L${OPENCL_LIBS} -lOpenCL"
15647 if test "${RPATH_LIBS}x" = "x"; then
15648 RPATH_LIBS="${OPENCL_LIBS}"
15649 else
15650 RPATH_LIBS="${RPATH_LIBS}:${OPENCL_LIBS}"
15651 fi
15652 else
15653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15654$as_echo "no" >&6; }
15655 fi
15656
15657 if test "$opencl_inc_found" = "no"; then
15658 # Extract the first word of "lspci", so it can be a program name with args.
15659set dummy lspci; ac_word=$2
15660{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15661$as_echo_n "checking for $ac_word... " >&6; }
15662if ${ac_cv_prog_lspci_found+:} false; then :
15663 $as_echo_n "(cached) " >&6
15664else
15665 if test -n "$lspci_found"; then
15666 ac_cv_prog_lspci_found="$lspci_found" # Let the user override the test.
15667else
15668as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15669for as_dir in $PATH
15670do
15671 IFS=$as_save_IFS
15672 test -z "$as_dir" && as_dir=.
15673 for ac_exec_ext in '' $ac_executable_extensions; do
15674 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15675 ac_cv_prog_lspci_found="yes"
15676 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15677 break 2
15678 fi
15679done
15680 done
15681IFS=$as_save_IFS
15682
15683 test -z "$ac_cv_prog_lspci_found" && ac_cv_prog_lspci_found="no"
15684fi
15685fi
15686lspci_found=$ac_cv_prog_lspci_found
15687if test -n "$lspci_found"; then
15688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lspci_found" >&5
15689$as_echo "$lspci_found" >&6; }
15690else
15691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15692$as_echo "no" >&6; }
15693fi
15694
15695
15696 if test "$lspci_found" = "no"; then
15697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /projects/opt/cuda/cuda-5.5/include/CL/cl.h" >&5
15698$as_echo_n "checking for /projects/opt/cuda/cuda-5.5/include/CL/cl.h... " >&6; }
15699if ${ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h+:} false; then :
15700 $as_echo_n "(cached) " >&6
15701else
15702 test "$cross_compiling" = yes &&
15703 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15704if test -r "/projects/opt/cuda/cuda-5.5/include/CL/cl.h"; then
15705 ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h=yes
15706else
15707 ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h=no
15708fi
15709fi
15710{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h" >&5
15711$as_echo "$ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h" >&6; }
15712if test "x$ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h" = xyes; then :
15713 AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/cuda/cuda-5.5/include" && opencl_inc_found="yes"
15714fi
15715
15716 if test "$opencl_inc_found" = "no"; then
15717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /opt/cudatoolkit-6.0/include/CL/cl.h" >&5
15718$as_echo_n "checking for /opt/cudatoolkit-6.0/include/CL/cl.h... " >&6; }
15719if ${ac_cv_file__opt_cudatoolkit_6_0_include_CL_cl_h+:} false; then :
15720 $as_echo_n "(cached) " >&6
15721else
15722 test "$cross_compiling" = yes &&
15723 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15724if test -r "/opt/cudatoolkit-6.0/include/CL/cl.h"; then
15725 ac_cv_file__opt_cudatoolkit_6_0_include_CL_cl_h=yes
15726else
15727 ac_cv_file__opt_cudatoolkit_6_0_include_CL_cl_h=no
15728fi
15729fi
15730{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_cudatoolkit_6_0_include_CL_cl_h" >&5
15731$as_echo "$ac_cv_file__opt_cudatoolkit_6_0_include_CL_cl_h" >&6; }
15732if test "x$ac_cv_file__opt_cudatoolkit_6_0_include_CL_cl_h" = xyes; then :
15733 AM_CPPFLAGS="${AM_CPPFLAGS} -I/opt/cudatoolkit-6.0/include" && opencl_inc_found="yes"
15734fi
15735
15736 fi
15737 if test "$opencl_inc_found" = "no"; then
15738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /projects/opt/opencl1d2_additional_files/include/CL/cl.h" >&5
15739$as_echo_n "checking for /projects/opt/opencl1d2_additional_files/include/CL/cl.h... " >&6; }
15740if ${ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h+:} false; then :
15741 $as_echo_n "(cached) " >&6
15742else
15743 test "$cross_compiling" = yes &&
15744 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15745if test -r "/projects/opt/opencl1d2_additional_files/include/CL/cl.h"; then
15746 ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h=yes
15747else
15748 ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h=no
15749fi
15750fi
15751{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h" >&5
15752$as_echo "$ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h" >&6; }
15753if test "x$ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h" = xyes; then :
15754 AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/opencl1d2_additional_files/include" && opencl_inc_found="yes"
15755fi
15756
15757 fi
15758 if test "$opencl_inc_found" = "no"; then
15759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /projects/opt/AMD_APP_SDK/AMDAPP-2.8/include/CL/cl.h" >&5
15760$as_echo_n "checking for /projects/opt/AMD_APP_SDK/AMDAPP-2.8/include/CL/cl.h... " >&6; }
15761if ${ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_include_CL_cl_h+:} false; then :
15762 $as_echo_n "(cached) " >&6
15763else
15764 test "$cross_compiling" = yes &&
15765 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15766if test -r "/projects/opt/AMD_APP_SDK/AMDAPP-2.8/include/CL/cl.h"; then
15767 ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_include_CL_cl_h=yes
15768else
15769 ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_include_CL_cl_h=no
15770fi
15771fi
15772{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_include_CL_cl_h" >&5
15773$as_echo "$ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_include_CL_cl_h" >&6; }
15774if test "x$ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_include_CL_cl_h" = xyes; then :
15775 AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/AMD_APP_SDK/AMDAPP-2.8/include" && opencl_inc_found="yes"
15776fi
15777
15778 fi
15779 if test "$opencl_inc_found" = "no"; then
15780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /opt/intel/opencl-1.2-3.0.67279/include/CL/cl.h" >&5
15781$as_echo_n "checking for /opt/intel/opencl-1.2-3.0.67279/include/CL/cl.h... " >&6; }
15782if ${ac_cv_file__opt_intel_opencl_1_2_3_0_67279_include_CL_cl_h+:} false; then :
15783 $as_echo_n "(cached) " >&6
15784else
15785 test "$cross_compiling" = yes &&
15786 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15787if test -r "/opt/intel/opencl-1.2-3.0.67279/include/CL/cl.h"; then
15788 ac_cv_file__opt_intel_opencl_1_2_3_0_67279_include_CL_cl_h=yes
15789else
15790 ac_cv_file__opt_intel_opencl_1_2_3_0_67279_include_CL_cl_h=no
15791fi
15792fi
15793{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_intel_opencl_1_2_3_0_67279_include_CL_cl_h" >&5
15794$as_echo "$ac_cv_file__opt_intel_opencl_1_2_3_0_67279_include_CL_cl_h" >&6; }
15795if test "x$ac_cv_file__opt_intel_opencl_1_2_3_0_67279_include_CL_cl_h" = xyes; then :
15796 AM_CPPFLAGS="${AM_CPPFLAGS} -I/opt/intel/opencl-1.2-3.0.67279/include" && opencl_inc_found="yes"
15797fi
15798
15799 fi
15800
15801 if test "$opencl_lib_found" = "no"; then
15802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /opt/cudatoolkit-6.0/lib64/libOpenCL.so" >&5
15803$as_echo_n "checking for /opt/cudatoolkit-6.0/lib64/libOpenCL.so... " >&6; }
15804if ${ac_cv_file__opt_cudatoolkit_6_0_lib64_libOpenCL_so+:} false; then :
15805 $as_echo_n "(cached) " >&6
15806else
15807 test "$cross_compiling" = yes &&
15808 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15809if test -r "/opt/cudatoolkit-6.0/lib64/libOpenCL.so"; then
15810 ac_cv_file__opt_cudatoolkit_6_0_lib64_libOpenCL_so=yes
15811else
15812 ac_cv_file__opt_cudatoolkit_6_0_lib64_libOpenCL_so=no
15813fi
15814fi
15815{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_cudatoolkit_6_0_lib64_libOpenCL_so" >&5
15816$as_echo "$ac_cv_file__opt_cudatoolkit_6_0_lib64_libOpenCL_so" >&6; }
15817if test "x$ac_cv_file__opt_cudatoolkit_6_0_lib64_libOpenCL_so" = xyes; then :
15818 LIBS="${LIBS} -L/opt/cudatoolkit-6.0/lib64 -lOpenCL" && opencl_lib_found="yes"
15819fi
15820
15821 if test "${opencl_lib_found}" = "yes"; then
15822 if test "${RPATH_LIBS}x" = "x"; then
15823 RPATH_LIBS="/opt/cudatoolkit-6.0/lib64"
15824 else
15825 RPATH_LIBS="${RPATH_LIBS}:/opt/cudatoolkit-6.0/lib64"
15826 fi
15827 fi
15828 fi
15829 if test "$opencl_lib_found" = "no"; then
15830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /usr/lib/libOpenCL.so" >&5
15831$as_echo_n "checking for /usr/lib/libOpenCL.so... " >&6; }
15832if ${ac_cv_file__usr_lib_libOpenCL_so+:} false; then :
15833 $as_echo_n "(cached) " >&6
15834else
15835 test "$cross_compiling" = yes &&
15836 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15837if test -r "/usr/lib/libOpenCL.so"; then
15838 ac_cv_file__usr_lib_libOpenCL_so=yes
15839else
15840 ac_cv_file__usr_lib_libOpenCL_so=no
15841fi
15842fi
15843{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__usr_lib_libOpenCL_so" >&5
15844$as_echo "$ac_cv_file__usr_lib_libOpenCL_so" >&6; }
15845if test "x$ac_cv_file__usr_lib_libOpenCL_so" = xyes; then :
15846 LIBS="${LIBS} -lOpenCL" && opencl_lib_found="yes"
15847fi
15848
15849 if test "${opencl_lib_found}" = "yes"; then
15850 if test "${RPATH_LIBS}x" = "x"; then
15851 RPATH_LIBS="/usr/lib"
15852 else
15853 RPATH_LIBS="${RPATH_LIBS}:/usr/lib"
15854 fi
15855 fi
15856 fi
15857 if test "$opencl_lib_found" = "no"; then
15858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /usr/lib64/libOpenCL.so" >&5
15859$as_echo_n "checking for /usr/lib64/libOpenCL.so... " >&6; }
15860if ${ac_cv_file__usr_lib64_libOpenCL_so+:} false; then :
15861 $as_echo_n "(cached) " >&6
15862else
15863 test "$cross_compiling" = yes &&
15864 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15865if test -r "/usr/lib64/libOpenCL.so"; then
15866 ac_cv_file__usr_lib64_libOpenCL_so=yes
15867else
15868 ac_cv_file__usr_lib64_libOpenCL_so=no
15869fi
15870fi
15871{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__usr_lib64_libOpenCL_so" >&5
15872$as_echo "$ac_cv_file__usr_lib64_libOpenCL_so" >&6; }
15873if test "x$ac_cv_file__usr_lib64_libOpenCL_so" = xyes; then :
15874 LIBS="${LIBS} -lOpenCL" && opencl_lib_found="yes"
15875fi
15876
15877 if test "${opencl_lib_found}" = "yes"; then
15878 if test "${RPATH_LIBS}x" = "x"; then
15879 RPATH_LIBS="/usr/lib64"
15880 else
15881 RPATH_LIBS="${RPATH_LIBS}:/usr/lib64"
15882 fi
15883 fi
15884 fi
15885 if test "$opencl_lib_found" = "no"; then
15886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /projects/opt/AMD_APP_SDK/AMDAPP-2.8/lib/x86_64/libOpenCL.so" >&5
15887$as_echo_n "checking for /projects/opt/AMD_APP_SDK/AMDAPP-2.8/lib/x86_64/libOpenCL.so... " >&6; }
15888if ${ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_lib_x86_64_libOpenCL_so+:} false; then :
15889 $as_echo_n "(cached) " >&6
15890else
15891 test "$cross_compiling" = yes &&
15892 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15893if test -r "/projects/opt/AMD_APP_SDK/AMDAPP-2.8/lib/x86_64/libOpenCL.so"; then
15894 ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_lib_x86_64_libOpenCL_so=yes
15895else
15896 ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_lib_x86_64_libOpenCL_so=no
15897fi
15898fi
15899{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_lib_x86_64_libOpenCL_so" >&5
15900$as_echo "$ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_lib_x86_64_libOpenCL_so" >&6; }
15901if test "x$ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_2_8_lib_x86_64_libOpenCL_so" = xyes; then :
15902 LIBS="${LIBS} -L/projects/opt/AMD_APP_SDK/AMDAPP-2.8/lib/x86_64 -lOpenCL" && opencl_lib_found="yes"
15903fi
15904
15905 if test "${opencl_lib_found}" = "yes"; then
15906 if test "${RPATH_LIBS}x" = "x"; then
15907 RPATH_LIBS="/projects/opt/AMD_APP_SDK/AMDAPP-2.8/lib/x86_64"
15908 else
15909 RPATH_LIBS="${RPATH_LIBS}:/projects/opt/AMD_APP_SDK/AMDAPP-2.8/lib/x86_64"
15910 fi
15911 fi
15912 fi
15913 if test "$opencl_lib_found" = "no"; then
15914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /opt/intel/opencl-1.2-3.0.67279/lib64/libOpenCL.so" >&5
15915$as_echo_n "checking for /opt/intel/opencl-1.2-3.0.67279/lib64/libOpenCL.so... " >&6; }
15916if ${ac_cv_file__opt_intel_opencl_1_2_3_0_67279_lib64_libOpenCL_so+:} false; then :
15917 $as_echo_n "(cached) " >&6
15918else
15919 test "$cross_compiling" = yes &&
15920 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15921if test -r "/opt/intel/opencl-1.2-3.0.67279/lib64/libOpenCL.so"; then
15922 ac_cv_file__opt_intel_opencl_1_2_3_0_67279_lib64_libOpenCL_so=yes
15923else
15924 ac_cv_file__opt_intel_opencl_1_2_3_0_67279_lib64_libOpenCL_so=no
15925fi
15926fi
15927{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__opt_intel_opencl_1_2_3_0_67279_lib64_libOpenCL_so" >&5
15928$as_echo "$ac_cv_file__opt_intel_opencl_1_2_3_0_67279_lib64_libOpenCL_so" >&6; }
15929if test "x$ac_cv_file__opt_intel_opencl_1_2_3_0_67279_lib64_libOpenCL_so" = xyes; then :
15930 LIBS="${LIBS} -L/opt/intel/opencl-1.2-3.0.67279/lib64 -L/opt/intel/opencl-1.2-3.0.67279/libmic" && opencl_lib_found="yes"
15931fi
15932
15933 if test "${opencl_lib_found}" = "yes"; then
15934 if test "${RPATH_LIBS}x" = "x"; then
15935 RPATH_LIBS="/opt/intel/opencl-1.2-3.0.67279/lib64"
15936 else
15937 RPATH_LIBS="${RPATH_LIBS}:/opt/intel/opencl-1.2-3.0.67279/lib64"
15938 fi
15939 fi
15940 fi
15941 elif test "`lspci | grep "VGA compatible controller" | grep -i nVidia | wc -l`" != "0"; then
15942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /usr/local/NVIDIA_GPU_Computing_SDK/OpenCL/common/inc/CL/cl.h" >&5
15943$as_echo_n "checking for /usr/local/NVIDIA_GPU_Computing_SDK/OpenCL/common/inc/CL/cl.h... " >&6; }
15944if ${ac_cv_file__usr_local_NVIDIA_GPU_Computing_SDK_OpenCL_common_inc_CL_cl_h+:} false; then :
15945 $as_echo_n "(cached) " >&6
15946else
15947 test "$cross_compiling" = yes &&
15948 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15949if test -r "/usr/local/NVIDIA_GPU_Computing_SDK/OpenCL/common/inc/CL/cl.h"; then
15950 ac_cv_file__usr_local_NVIDIA_GPU_Computing_SDK_OpenCL_common_inc_CL_cl_h=yes
15951else
15952 ac_cv_file__usr_local_NVIDIA_GPU_Computing_SDK_OpenCL_common_inc_CL_cl_h=no
15953fi
15954fi
15955{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__usr_local_NVIDIA_GPU_Computing_SDK_OpenCL_common_inc_CL_cl_h" >&5
15956$as_echo "$ac_cv_file__usr_local_NVIDIA_GPU_Computing_SDK_OpenCL_common_inc_CL_cl_h" >&6; }
15957if test "x$ac_cv_file__usr_local_NVIDIA_GPU_Computing_SDK_OpenCL_common_inc_CL_cl_h" = xyes; then :
15958 AM_CPPFLAGS="${AM_CPPFLAGS} -I/usr/local/NVIDIA_GPU_Computing_SDK/OpenCL/common/inc" && opencl_inc_found="yes"
15959fi
15960
15961 if test "$opencl_inc_found" = "no"; then
15962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /usr/local/cuda/include/CL/cl.h" >&5
15963$as_echo_n "checking for /usr/local/cuda/include/CL/cl.h... " >&6; }
15964if ${ac_cv_file__usr_local_cuda_include_CL_cl_h+:} false; then :
15965 $as_echo_n "(cached) " >&6
15966else
15967 test "$cross_compiling" = yes &&
15968 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15969if test -r "/usr/local/cuda/include/CL/cl.h"; then
15970 ac_cv_file__usr_local_cuda_include_CL_cl_h=yes
15971else
15972 ac_cv_file__usr_local_cuda_include_CL_cl_h=no
15973fi
15974fi
15975{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__usr_local_cuda_include_CL_cl_h" >&5
15976$as_echo "$ac_cv_file__usr_local_cuda_include_CL_cl_h" >&6; }
15977if test "x$ac_cv_file__usr_local_cuda_include_CL_cl_h" = xyes; then :
15978 AM_CPPFLAGS="${AM_CPPFLAGS} -I/usr/local/cuda/include" && opencl_inc_found="yes"
15979fi
15980
15981 fi
15982 if test "$opencl_inc_found" = "no"; then
15983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /projects/opt/cuda/cuda-5.5/include/CL/cl.h" >&5
15984$as_echo_n "checking for /projects/opt/cuda/cuda-5.5/include/CL/cl.h... " >&6; }
15985if ${ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h+:} false; then :
15986 $as_echo_n "(cached) " >&6
15987else
15988 test "$cross_compiling" = yes &&
15989 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15990if test -r "/projects/opt/cuda/cuda-5.5/include/CL/cl.h"; then
15991 ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h=yes
15992else
15993 ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h=no
15994fi
15995fi
15996{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h" >&5
15997$as_echo "$ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h" >&6; }
15998if test "x$ac_cv_file__projects_opt_cuda_cuda_5_5_include_CL_cl_h" = xyes; then :
15999 AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/cuda/cuda-5.5/include" && opencl_inc_found="yes"
16000fi
16001
16002 fi
16003 if test "$opencl_inc_found" = "no"; then
16004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /projects/opt/opencl1d2_additional_files/include/CL/cl.h" >&5
16005$as_echo_n "checking for /projects/opt/opencl1d2_additional_files/include/CL/cl.h... " >&6; }
16006if ${ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h+:} false; then :
16007 $as_echo_n "(cached) " >&6
16008else
16009 test "$cross_compiling" = yes &&
16010 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
16011if test -r "/projects/opt/opencl1d2_additional_files/include/CL/cl.h"; then
16012 ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h=yes
16013else
16014 ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h=no
16015fi
16016fi
16017{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h" >&5
16018$as_echo "$ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h" >&6; }
16019if test "x$ac_cv_file__projects_opt_opencl1d2_additional_files_include_CL_cl_h" = xyes; then :
16020 AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/opencl1d2_additional_files/include" && opencl_inc_found="yes"
16021fi
16022
16023 fi
16024 if test "$opencl_inc_found" = "no"; then
16025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /home/cuda/sdk4.0.13/OpenCL/common/inc/CL/cl.h" >&5
16026$as_echo_n "checking for /home/cuda/sdk4.0.13/OpenCL/common/inc/CL/cl.h... " >&6; }
16027if ${ac_cv_file__home_cuda_sdk4_0_13_OpenCL_common_inc_CL_cl_h+:} false; then :
16028 $as_echo_n "(cached) " >&6
16029else
16030 test "$cross_compiling" = yes &&
16031 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
16032if test -r "/home/cuda/sdk4.0.13/OpenCL/common/inc/CL/cl.h"; then
16033 ac_cv_file__home_cuda_sdk4_0_13_OpenCL_common_inc_CL_cl_h=yes
16034else
16035 ac_cv_file__home_cuda_sdk4_0_13_OpenCL_common_inc_CL_cl_h=no
16036fi
16037fi
16038{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__home_cuda_sdk4_0_13_OpenCL_common_inc_CL_cl_h" >&5
16039$as_echo "$ac_cv_file__home_cuda_sdk4_0_13_OpenCL_common_inc_CL_cl_h" >&6; }
16040if test "x$ac_cv_file__home_cuda_sdk4_0_13_OpenCL_common_inc_CL_cl_h" = xyes; then :
16041 AM_CPPFLAGS="${AM_CPPFLAGS} -I/home/cuda/sdk4.0.13/OpenCL/common/inc" && opencl_inc_found="yes"
16042fi
16043
16044 fi
16045
16046 if test "$opencl_lib_found" = "no"; then
16047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /usr/lib/libOpenCL.so" >&5
16048$as_echo_n "checking for /usr/lib/libOpenCL.so... " >&6; }
16049if ${ac_cv_file__usr_lib_libOpenCL_so+:} false; then :
16050 $as_echo_n "(cached) " >&6
16051else
16052 test "$cross_compiling" = yes &&
16053 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
16054if test -r "/usr/lib/libOpenCL.so"; then
16055 ac_cv_file__usr_lib_libOpenCL_so=yes
16056else
16057 ac_cv_file__usr_lib_libOpenCL_so=no
16058fi
16059fi
16060{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__usr_lib_libOpenCL_so" >&5
16061$as_echo "$ac_cv_file__usr_lib_libOpenCL_so" >&6; }
16062if test "x$ac_cv_file__usr_lib_libOpenCL_so" = xyes; then :
16063 LIBS="${LIBS} -lOpenCL" && opencl_lib_found="yes"
16064fi
16065
16066 if test "${opencl_lib_found}" = "yes"; then
16067 if test "${RPATH_LIBS}x" = "x"; then
16068 RPATH_LIBS="/usr/lib"
16069 else
16070 RPATH_LIBS="${RPATH_LIBS}:/usr/lib"
16071 fi
16072 fi
16073 fi
16074 if test "$opencl_lib_found" = "no"; then
16075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /usr/lib64/libOpenCL.so" >&5
16076$as_echo_n "checking for /usr/lib64/libOpenCL.so... " >&6; }
16077if ${ac_cv_file__usr_lib64_libOpenCL_so+:} false; then :
16078 $as_echo_n "(cached) " >&6
16079else
16080 test "$cross_compiling" = yes &&
16081 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
16082if test -r "/usr/lib64/libOpenCL.so"; then
16083 ac_cv_file__usr_lib64_libOpenCL_so=yes
16084else
16085 ac_cv_file__usr_lib64_libOpenCL_so=no
16086fi
16087fi
16088{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__usr_lib64_libOpenCL_so" >&5
16089$as_echo "$ac_cv_file__usr_lib64_libOpenCL_so" >&6; }
16090if test "x$ac_cv_file__usr_lib64_libOpenCL_so" = xyes; then :
16091 LIBS="${LIBS} -lOpenCL" && opencl_lib_found="yes"
16092fi
16093
16094 if test "${opencl_lib_found}" = "yes"; then
16095 if test "${RPATH_LIBS}x" = "x"; then
16096 RPATH_LIBS="/usr/lib64"
16097 else
16098 RPATH_LIBS="${RPATH_LIBS}:/usr/lib64"
16099 fi
16100 fi
16101 fi
16102 elif test "`lspci | grep "VGA compatible controller" | grep ATI | wc -l`" != "0"; then
16103 if test "$opencl_inc_found" = "no"; then
16104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /home/opt/AMDAPP_v2.6/include/CL/cl.h" >&5
16105$as_echo_n "checking for /home/opt/AMDAPP_v2.6/include/CL/cl.h... " >&6; }
16106if ${ac_cv_file__home_opt_AMDAPP_v2_6_include_CL_cl_h+:} false; then :
16107 $as_echo_n "(cached) " >&6
16108else
16109 test "$cross_compiling" = yes &&
16110 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
16111if test -r "/home/opt/AMDAPP_v2.6/include/CL/cl.h"; then
16112 ac_cv_file__home_opt_AMDAPP_v2_6_include_CL_cl_h=yes
16113else
16114 ac_cv_file__home_opt_AMDAPP_v2_6_include_CL_cl_h=no
16115fi
16116fi
16117{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__home_opt_AMDAPP_v2_6_include_CL_cl_h" >&5
16118$as_echo "$ac_cv_file__home_opt_AMDAPP_v2_6_include_CL_cl_h" >&6; }
16119if test "x$ac_cv_file__home_opt_AMDAPP_v2_6_include_CL_cl_h" = xyes; then :
16120 AM_CPPFLAGS="${AM_CPPFLAGS} -I/home/opt/AMDAPP_v2.6/include" && opencl_inc_found="yes"
16121fi
16122
16123 fi
16124 if test "$opencl_inc_found" = "no"; then
16125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /projects/opt/AMD_APP_SDK/AMDAPP_v2.6/include/CL/cl.h" >&5
16126$as_echo_n "checking for /projects/opt/AMD_APP_SDK/AMDAPP_v2.6/include/CL/cl.h... " >&6; }
16127if ${ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_include_CL_cl_h+:} false; then :
16128 $as_echo_n "(cached) " >&6
16129else
16130 test "$cross_compiling" = yes &&
16131 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
16132if test -r "/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/include/CL/cl.h"; then
16133 ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_include_CL_cl_h=yes
16134else
16135 ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_include_CL_cl_h=no
16136fi
16137fi
16138{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_include_CL_cl_h" >&5
16139$as_echo "$ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_include_CL_cl_h" >&6; }
16140if test "x$ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_include_CL_cl_h" = xyes; then :
16141 AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/include" && opencl_inc_found="yes"
16142fi
16143
16144 fi
16145
16146 if test "$opencl_lib_found" = "no"; then
16147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /home/opt/AMDAPP_v2.6/lib/x86_64/libOpenCL.so" >&5
16148$as_echo_n "checking for /home/opt/AMDAPP_v2.6/lib/x86_64/libOpenCL.so... " >&6; }
16149if ${ac_cv_file__home_opt_AMDAPP_v2_6_lib_x86_64_libOpenCL_so+:} false; then :
16150 $as_echo_n "(cached) " >&6
16151else
16152 test "$cross_compiling" = yes &&
16153 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
16154if test -r "/home/opt/AMDAPP_v2.6/lib/x86_64/libOpenCL.so"; then
16155 ac_cv_file__home_opt_AMDAPP_v2_6_lib_x86_64_libOpenCL_so=yes
16156else
16157 ac_cv_file__home_opt_AMDAPP_v2_6_lib_x86_64_libOpenCL_so=no
16158fi
16159fi
16160{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__home_opt_AMDAPP_v2_6_lib_x86_64_libOpenCL_so" >&5
16161$as_echo "$ac_cv_file__home_opt_AMDAPP_v2_6_lib_x86_64_libOpenCL_so" >&6; }
16162if test "x$ac_cv_file__home_opt_AMDAPP_v2_6_lib_x86_64_libOpenCL_so" = xyes; then :
16163 LIBS="${LIBS} -L/home/opt/AMDAPP_v2.6/lib/x86_64 -lOpenCL" && opencl_lib_found="yes"
16164fi
16165
16166 if test "${opencl_lib_found}" = "yes"; then
16167 if test "${RPATH_LIBS}x" = "x"; then
16168 RPATH_LIBS="/home/opt/AMDAPP_v2.6/lib/x86_64"
16169 else
16170 RPATH_LIBS="${RPATH_LIBS}:/home/opt/AMDAPP_v2.6/lib/x86_64"
16171 fi
16172 fi
16173 fi
16174 if test "$opencl_lib_found" = "no"; then
16175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /projects/opt/AMD_APP_SDK/AMDAPP_v2.6/lib/x86_64/libOpenCL.so" >&5
16176$as_echo_n "checking for /projects/opt/AMD_APP_SDK/AMDAPP_v2.6/lib/x86_64/libOpenCL.so... " >&6; }
16177if ${ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_lib_x86_64_libOpenCL_so+:} false; then :
16178 $as_echo_n "(cached) " >&6
16179else
16180 test "$cross_compiling" = yes &&
16181 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
16182if test -r "/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/lib/x86_64/libOpenCL.so"; then
16183 ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_lib_x86_64_libOpenCL_so=yes
16184else
16185 ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_lib_x86_64_libOpenCL_so=no
16186fi
16187fi
16188{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_lib_x86_64_libOpenCL_so" >&5
16189$as_echo "$ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_lib_x86_64_libOpenCL_so" >&6; }
16190if test "x$ac_cv_file__projects_opt_AMD_APP_SDK_AMDAPP_v2_6_lib_x86_64_libOpenCL_so" = xyes; then :
16191 LIBS="${LIBS} -L/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/lib/x86_64 -lOpenCL" && opencl_lib_found="yes"
16192fi
16193
16194 if test "${opencl_lib_found}" = "yes"; then
16195 if test "${RPATH_LIBS}x" = "x"; then
16196 RPATH_LIBS="/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/lib/x86_64"
16197 else
16198 RPATH_LIBS="${RPATH_LIBS}:/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/lib/x86_64"
16199 fi
16200 fi
16201 fi
16202 fi
16203 fi
16204 if test "$opencl_inc_found" = "yes"; then
16205
16206$as_echo "#define HAVE_OPENCL 1" >>confdefs.h
16207
16208 else
16209 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: =================================================================" >&5
16210$as_echo "$as_me: WARNING: =================================================================" >&2;}
16211 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: OpenCL was not found" >&5
16212$as_echo "$as_me: WARNING: OpenCL was not found" >&2;}
16213 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: If it fails" >&5
16214$as_echo "$as_me: WARNING: If it fails" >&2;}
16215 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: to location of include directory and the OpenCL library" >&5
16216$as_echo "$as_me: WARNING: to location of include directory and the OpenCL library" >&2;}
16217 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: or build without OpenCL with \"./configure --disable-opencl\"." >&5
16218$as_echo "$as_me: WARNING: or build without OpenCL with \"./configure --disable-opencl\"." >&2;}
16219 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: If you disable opencl" >&5
16220$as_echo "$as_me: WARNING: If you disable opencl" >&2;}
16221 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: and force the rebuild of HashFactory.c and HashFactory.h \"make HashFactory.c HashFactory.h\"." >&5
16222$as_echo "$as_me: WARNING: and force the rebuild of HashFactory.c and HashFactory.h \"make HashFactory.c HashFactory.h\"." >&2;}
16223 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: You may need to remove the HashFactory.c and HashFactory.h files if make gets" >&5
16224$as_echo "$as_me: WARNING: You may need to remove the HashFactory.c and HashFactory.h files if make gets" >&2;}
16225 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: confused by timestamps" >&5
16226$as_echo "$as_me: WARNING: confused by timestamps" >&2;}
16227 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: =================================================================" >&5
16228$as_echo "$as_me: WARNING: =================================================================" >&2;}
16229 fi
16230 ;;
16231 *darwin*)
16232 { $as_echo "$as_me:${as_lineno-$LINENO}: Adding OpenCL framework" >&5
16233$as_echo "$as_me: Adding OpenCL framework" >&6;}
16234
16235$as_echo "#define HAVE_OPENCL 1" >>confdefs.h
16236
16237 LIBS="${LIBS} -framework OpenCL"
16238 ;;
16239 esac
16240
16241
16242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OpenCL double type" >&5
16243$as_echo_n "checking for OpenCL double type... " >&6; }
16244
16245 SAVE_C_FLAGS=$CFLAGS
16246 CFLAGS="$CFLAGS $AM_CPPFLAGS"
16247
16248 ac_ext=c
16249ac_cpp='$CPP $CPPFLAGS'
16250ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16251ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16252ac_compiler_gnu=$ac_cv_c_compiler_gnu
16253
16254
16255 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16256/* end confdefs.h. */
16257
16258 #ifdef __APPLE_CC__
16259 #include <OpenCL/OpenCL.h>
16260 #else
16261 #include <CL/cl.h>
16262 #endif
16263
16264int
16265main ()
16266{
16267cl_double x;
16268 ;
16269 return 0;
16270}
16271_ACEOF
16272if ac_fn_c_try_compile "$LINENO"; then :
16273 ac_cv_opencl_double=yes
16274else
16275 ac_cv_opencl_double=no
16276
16277fi
16278rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16279 if test "x$ac_cv_opencl_double" = "xyes"; then
16280
16281$as_echo "#define HAVE_CL_DOUBLE 1" >>confdefs.h
16282
16283 else
16284
16285$as_echo "#define NO_CL_DOUBLE 1" >>confdefs.h
16286
16287 fi
16288
16289 CFLAGS=$SAVE_C_FLAGS
16290
16291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_opencl_double" >&5
16292$as_echo "$ac_cv_opencl_double" >&6; }
16293fi
16294
16295if test ! -z "${RPATH_LIBS}"; then
16296 LIBS="${LIBS} ${RPATH_PREFIX}-rpath ${RPATH_PREFIX}${RPATH_LIBS}"
16297fi
16298
16299LIBS="${LIBS} -lm"
16300
16301
16302
16303
16304
16305
16306
16307
16308ac_config_files="$ac_config_files Makefile"
16309
16310ac_config_files="$ac_config_files kdtree/Makefile"
16311
16312ac_config_files="$ac_config_files HashFactory/Makefile"
16313
16314ac_config_files="$ac_config_files simplehash/Makefile"
16315
16316ac_config_files="$ac_config_files timer/Makefile"
16317
16318
16319
16320
16321test "x$prefix" = xNONE && prefix=$ac_default_prefix
16322# Let make expand exec_prefix.
16323test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
16324
16325# Transform confdefs.h into DEFS.
16326# Protect against shell expansion while executing Makefile rules.
16327# Protect against Makefile macro expansion.
16328#
16329# If the first sed substitution is executed (which looks for macros that
16330# take arguments), then branch to the quote section. Otherwise,
16331# look for a macro that doesn't take arguments.
16332ac_script='
16333:mline
16334/\\$/{
16335 N
16336 s,\\\n,,
16337 b mline
16338}
16339t clear
16340:clear
16341s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g
16342t quote
16343s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g
16344t quote
16345b any
16346:quote
16347s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g
16348s/\[/\\&/g
16349s/\]/\\&/g
16350s/\$/$$/g
16351H
16352:any
16353${
16354 g
16355 s/^\n//
16356 s/\n/ /g
16357 p
16358}
16359'
16360DEFS=`sed -n "$ac_script" confdefs.h`
16361
16362
16363ac_libobjs=
16364ac_ltlibobjs=
16365U=
16366for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
16367 # 1. Remove the extension, and $U if already installed.
16368 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
16369 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
16370 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
16371 # will be set to the directory where LIBOBJS objects are built.
16372 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
16373 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
16374done
16375LIBOBJS=$ac_libobjs
16376
16377LTLIBOBJS=$ac_ltlibobjs
16378
16379
16380{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
16381$as_echo_n "checking that generated files are newer than configure... " >&6; }
16382 if test -n "$am_sleep_pid"; then
16383 # Hide warnings about reused PIDs.
16384 wait $am_sleep_pid 2>/dev/null
16385 fi
16386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
16387$as_echo "done" >&6; }
16388 if test -n "$EXEEXT"; then
16389 am__EXEEXT_TRUE=
16390 am__EXEEXT_FALSE='#'
16391else
16392 am__EXEEXT_TRUE='#'
16393 am__EXEEXT_FALSE=
16394fi
16395
16396if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
16397 as_fn_error $? "conditional \"AMDEP\" was never defined.
16398Usually this means the macro was only invoked conditionally." "$LINENO" 5
16399fi
16400if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
16401 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
16402Usually this means the macro was only invoked conditionally." "$LINENO" 5
16403fi
16404if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then
16405 as_fn_error $? "conditional \"am__fastdepCXX\" was never defined.
16406Usually this means the macro was only invoked conditionally." "$LINENO" 5
16407fi
16408
16409: "${CONFIG_STATUS=./config.status}"
16410ac_write_fail=0
16411ac_clean_files_save=$ac_clean_files
16412ac_clean_files="$ac_clean_files $CONFIG_STATUS"
16413{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
16414$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
16415as_write_fail=0
16416cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
16417#! $SHELL
16418# Generated by $as_me.
16419# Run this file to recreate the current configuration.
16420# Compiler output produced by configure, useful for debugging
16421# configure, is in config.log if it exists.
16422
16423debug=false
16424ac_cs_recheck=false
16425ac_cs_silent=false
16426
16427SHELL=\${CONFIG_SHELL-$SHELL}
16428export SHELL
16429_ASEOF
16430cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
16431## -------------------- ##
16432## M4sh Initialization. ##
16433## -------------------- ##
16434
16435# Be more Bourne compatible
16436DUALCASE=1; export DUALCASE # for MKS sh
16437if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
16438 emulate sh
16439 NULLCMD=:
16440 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
16441 # is contrary to our usage. Disable this feature.
16442 alias -g '${1+"$@"}'='"$@"'
16443 setopt NO_GLOB_SUBST
16444else
16445 case `(set -o) 2>/dev/null` in #(
16446 *posix*) :
16447 set -o posix ;; #(
16448 *) :
16449 ;;
16450esac
16451fi
16452
16453
16454as_nl='
16455'
16456export as_nl
16457# Printing a long string crashes Solaris 7 /usr/bin/printf.
16458as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
16459as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
16460as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
16461# Prefer a ksh shell builtin over an external printf program on Solaris,
16462# but without wasting forks for bash or zsh.
16463if test -z "$BASH_VERSION$ZSH_VERSION" \
16464 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
16465 as_echo='print -r --'
16466 as_echo_n='print -rn --'
16467elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
16468 as_echo='printf %s\n'
16469 as_echo_n='printf %s'
16470else
16471 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
16472 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
16473 as_echo_n='/usr/ucb/echo -n'
16474 else
16475 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
16476 as_echo_n_body='eval
16477 arg=$1;
16478 case $arg in #(
16479 *"$as_nl"*)
16480 expr "X$arg" : "X\\(.*\\)$as_nl";
16481 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
16482 esac;
16483 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
16484 '
16485 export as_echo_n_body
16486 as_echo_n='sh -c $as_echo_n_body as_echo'
16487 fi
16488 export as_echo_body
16489 as_echo='sh -c $as_echo_body as_echo'
16490fi
16491
16492# The user is always right.
16493if test "${PATH_SEPARATOR+set}" != set; then
16494 PATH_SEPARATOR=:
16495 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
16496 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
16497 PATH_SEPARATOR=';'
16498 }
16499fi
16500
16501
16502# IFS
16503# We need space, tab and new line, in precisely that order. Quoting is
16504# there to prevent editors from complaining about space-tab.
16505# (If _AS_PATH_WALK were called with IFS unset, it would disable word
16506# splitting by setting IFS to empty value.)
16507IFS=" "" $as_nl"
16508
16509# Find who we are. Look in the path if we contain no directory separator.
16510as_myself=
16511case $0 in #((
16512 *[\\/]* ) as_myself=$0 ;;
16513 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16514for as_dir in $PATH
16515do
16516 IFS=$as_save_IFS
16517 test -z "$as_dir" && as_dir=.
16518 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
16519 done
16520IFS=$as_save_IFS
16521
16522 ;;
16523esac
16524# We did not find ourselves, most probably we were run as `sh COMMAND'
16525# in which case we are not to be found in the path.
16526if test "x$as_myself" = x; then
16527 as_myself=$0
16528fi
16529if test ! -f "$as_myself"; then
16530 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
16531 exit 1
16532fi
16533
16534# Unset variables that we do not need and which cause bugs (e.g. in
16535# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
16536# suppresses any "Segmentation fault" message there. '((' could
16537# trigger a bug in pdksh 5.2.14.
16538for as_var in BASH_ENV ENV MAIL MAILPATH
16539do eval test x\${$as_var+set} = xset \
16540 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
16541done
16542PS1='$ '
16543PS2='> '
16544PS4='+ '
16545
16546# NLS nuisances.
16547LC_ALL=C
16548export LC_ALL
16549LANGUAGE=C
16550export LANGUAGE
16551
16552# CDPATH.
16553(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
16554
16555
16556# as_fn_error STATUS ERROR [LINENO LOG_FD]
16557# ----------------------------------------
16558# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
16559# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
16560# script with STATUS, using 1 if that was 0.
16561as_fn_error ()
16562{
16563 as_status=$1; test $as_status -eq 0 && as_status=1
16564 if test "$4"; then
16565 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
16566 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
16567 fi
16568 $as_echo "$as_me: error: $2" >&2
16569 as_fn_exit $as_status
16570} # as_fn_error
16571
16572
16573# as_fn_set_status STATUS
16574# -----------------------
16575# Set $? to STATUS, without forking.
16576as_fn_set_status ()
16577{
16578 return $1
16579} # as_fn_set_status
16580
16581# as_fn_exit STATUS
16582# -----------------
16583# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
16584as_fn_exit ()
16585{
16586 set +e
16587 as_fn_set_status $1
16588 exit $1
16589} # as_fn_exit
16590
16591# as_fn_unset VAR
16592# ---------------
16593# Portably unset VAR.
16594as_fn_unset ()
16595{
16596 { eval $1=; unset $1;}
16597}
16598as_unset=as_fn_unset
16599# as_fn_append VAR VALUE
16600# ----------------------
16601# Append the text in VALUE to the end of the definition contained in VAR. Take
16602# advantage of any shell optimizations that allow amortized linear growth over
16603# repeated appends, instead of the typical quadratic growth present in naive
16604# implementations.
16605if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
16606 eval 'as_fn_append ()
16607 {
16608 eval $1+=\$2
16609 }'
16610else
16611 as_fn_append ()
16612 {
16613 eval $1=\$$1\$2
16614 }
16615fi # as_fn_append
16616
16617# as_fn_arith ARG...
16618# ------------------
16619# Perform arithmetic evaluation on the ARGs, and store the result in the
16620# global $as_val. Take advantage of shells that can avoid forks. The arguments
16621# must be portable across $(()) and expr.
16622if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
16623 eval 'as_fn_arith ()
16624 {
16625 as_val=$(( $* ))
16626 }'
16627else
16628 as_fn_arith ()
16629 {
16630 as_val=`expr "$@" || test $? -eq 1`
16631 }
16632fi # as_fn_arith
16633
16634
16635if expr a : '\(a\)' >/dev/null 2>&1 &&
16636 test "X`expr 00001 : '.*\(...\)'`" = X001; then
16637 as_expr=expr
16638else
16639 as_expr=false
16640fi
16641
16642if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
16643 as_basename=basename
16644else
16645 as_basename=false
16646fi
16647
16648if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
16649 as_dirname=dirname
16650else
16651 as_dirname=false
16652fi
16653
16654as_me=`$as_basename -- "$0" ||
16655$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
16656 X"$0" : 'X\(//\)$' \| \
16657 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
16658$as_echo X/"$0" |
16659 sed '/^.*\/\([^/][^/]*\)\/*$/{
16660 s//\1/
16661 q
16662 }
16663 /^X\/\(\/\/\)$/{
16664 s//\1/
16665 q
16666 }
16667 /^X\/\(\/\).*/{
16668 s//\1/
16669 q
16670 }
16671 s/.*/./; q'`
16672
16673# Avoid depending upon Character Ranges.
16674as_cr_letters='abcdefghijklmnopqrstuvwxyz'
16675as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
16676as_cr_Letters=$as_cr_letters$as_cr_LETTERS
16677as_cr_digits='0123456789'
16678as_cr_alnum=$as_cr_Letters$as_cr_digits
16679
16680ECHO_C= ECHO_N= ECHO_T=
16681case `echo -n x` in #(((((
16682-n*)
16683 case `echo 'xy\c'` in
16684 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
16685 xy) ECHO_C='\c';;
16686 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
16687 ECHO_T=' ';;
16688 esac;;
16689*)
16690 ECHO_N='-n';;
16691esac
16692
16693rm -f conf$$ conf$$.exe conf$$.file
16694if test -d conf$$.dir; then
16695 rm -f conf$$.dir/conf$$.file
16696else
16697 rm -f conf$$.dir
16698 mkdir conf$$.dir 2>/dev/null
16699fi
16700if (echo >conf$$.file) 2>/dev/null; then
16701 if ln -s conf$$.file conf$$ 2>/dev/null; then
16702 as_ln_s='ln -s'
16703 # ... but there are two gotchas:
16704 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
16705 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
16706 # In both cases, we have to default to `cp -pR'.
16707 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
16708 as_ln_s='cp -pR'
16709 elif ln conf$$.file conf$$ 2>/dev/null; then
16710 as_ln_s=ln
16711 else
16712 as_ln_s='cp -pR'
16713 fi
16714else
16715 as_ln_s='cp -pR'
16716fi
16717rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
16718rmdir conf$$.dir 2>/dev/null
16719
16720
16721# as_fn_mkdir_p
16722# -------------
16723# Create "$as_dir" as a directory, including parents if necessary.
16724as_fn_mkdir_p ()
16725{
16726
16727 case $as_dir in #(
16728 -*) as_dir=./$as_dir;;
16729 esac
16730 test -d "$as_dir" || eval $as_mkdir_p || {
16731 as_dirs=
16732 while :; do
16733 case $as_dir in #(
16734 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
16735 *) as_qdir=$as_dir;;
16736 esac
16737 as_dirs="'$as_qdir' $as_dirs"
16738 as_dir=`$as_dirname -- "$as_dir" ||
16739$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16740 X"$as_dir" : 'X\(//\)[^/]' \| \
16741 X"$as_dir" : 'X\(//\)$' \| \
16742 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
16743$as_echo X"$as_dir" |
16744 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
16745 s//\1/
16746 q
16747 }
16748 /^X\(\/\/\)[^/].*/{
16749 s//\1/
16750 q
16751 }
16752 /^X\(\/\/\)$/{
16753 s//\1/
16754 q
16755 }
16756 /^X\(\/\).*/{
16757 s//\1/
16758 q
16759 }
16760 s/.*/./; q'`
16761 test -d "$as_dir" && break
16762 done
16763 test -z "$as_dirs" || eval "mkdir $as_dirs"
16764 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
16765
16766
16767} # as_fn_mkdir_p
16768if mkdir -p . 2>/dev/null; then
16769 as_mkdir_p='mkdir -p "$as_dir"'
16770else
16771 test -d ./-p && rmdir ./-p
16772 as_mkdir_p=false
16773fi
16774
16775
16776# as_fn_executable_p FILE
16777# -----------------------
16778# Test if FILE is an executable regular file.
16779as_fn_executable_p ()
16780{
16781 test -f "$1" && test -x "$1"
16782} # as_fn_executable_p
16783as_test_x='test -x'
16784as_executable_p=as_fn_executable_p
16785
16786# Sed expression to map a string onto a valid CPP name.
16787as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
16788
16789# Sed expression to map a string onto a valid variable name.
16790as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
16791
16792
16793exec 6>&1
16794## ----------------------------------- ##
16795## Main body of $CONFIG_STATUS script. ##
16796## ----------------------------------- ##
16797_ASEOF
16798test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
16799
16800cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16801# Save the log message, to keep $0 and so on meaningful, and to
16802# report actual input values of CONFIG_FILES etc. instead of their
16803# values after options handling.
16804ac_log="
16805This file was extended by CompactHash $as_me v1.2, which was
16806generated by GNU Autoconf 2.69. Invocation command line was
16807
16808 CONFIG_FILES = $CONFIG_FILES
16809 CONFIG_HEADERS = $CONFIG_HEADERS
16810 CONFIG_LINKS = $CONFIG_LINKS
16811 CONFIG_COMMANDS = $CONFIG_COMMANDS
16812 $ $0 $@
16813
16814on `(hostname || uname -n) 2>/dev/null | sed 1q`
16815"
16816
16817_ACEOF
16818
16819case $ac_config_files in *"
16820"*) set x $ac_config_files; shift; ac_config_files=$*;;
16821esac
16822
16823
16824
16825cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16826# Files that config.status was made for.
16827config_files="$ac_config_files"
16828config_commands="$ac_config_commands"
16829
16830_ACEOF
16831
16832cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16833ac_cs_usage="\
16834\`$as_me' instantiates files and other configuration actions
16835from templates according to the current configuration. Unless the files
16836and actions are specified as TAGs, all are instantiated by default.
16837
16838Usage: $0 [OPTION]... [TAG]...
16839
16840 -h, --help print this help, then exit
16841 -V, --version print version number and configuration settings, then exit
16842 --config print configuration, then exit
16843 -q, --quiet, --silent
16844 do not print progress messages
16845 -d, --debug don't remove temporary files
16846 --recheck update $as_me by reconfiguring in the same conditions
16847 --file=FILE[:TEMPLATE]
16848 instantiate the configuration file FILE
16849
16850Configuration files:
16851$config_files
16852
16853Configuration commands:
16854$config_commands
16855
16856Report bugs to the package provider."
16857
16858_ACEOF
16859cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16860ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
16861ac_cs_version="\\
16862CompactHash config.status v1.2
16863configured by $0, generated by GNU Autoconf 2.69,
16864 with options \\"\$ac_cs_config\\"
16865
16866Copyright (C) 2012 Free Software Foundation, Inc.
16867This config.status script is free software; the Free Software Foundation
16868gives unlimited permission to copy, distribute and modify it."
16869
16870ac_pwd='$ac_pwd'
16871srcdir='$srcdir'
16872INSTALL='$INSTALL'
16873MKDIR_P='$MKDIR_P'
16874AWK='$AWK'
16875test -n "\$AWK" || AWK=awk
16876_ACEOF
16877
16878cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16879# The default lists apply if the user does not specify any file.
16880ac_need_defaults=:
16881while test $# != 0
16882do
16883 case $1 in
16884 --*=?*)
16885 ac_option=`expr "X$1" : 'X\([^=]*\)='`
16886 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
16887 ac_shift=:
16888 ;;
16889 --*=)
16890 ac_option=`expr "X$1" : 'X\([^=]*\)='`
16891 ac_optarg=
16892 ac_shift=:
16893 ;;
16894 *)
16895 ac_option=$1
16896 ac_optarg=$2
16897 ac_shift=shift
16898 ;;
16899 esac
16900
16901 case $ac_option in
16902 # Handling of the options.
16903 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
16904 ac_cs_recheck=: ;;
16905 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
16906 $as_echo "$ac_cs_version"; exit ;;
16907 --config | --confi | --conf | --con | --co | --c )
16908 $as_echo "$ac_cs_config"; exit ;;
16909 --debug | --debu | --deb | --de | --d | -d )
16910 debug=: ;;
16911 --file | --fil | --fi | --f )
16912 $ac_shift
16913 case $ac_optarg in
16914 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
16915 '') as_fn_error $? "missing file argument" ;;
16916 esac
16917 as_fn_append CONFIG_FILES " '$ac_optarg'"
16918 ac_need_defaults=false;;
16919 --he | --h | --help | --hel | -h )
16920 $as_echo "$ac_cs_usage"; exit ;;
16921 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
16922 | -silent | --silent | --silen | --sile | --sil | --si | --s)
16923 ac_cs_silent=: ;;
16924
16925 # This is an error.
16926 -*) as_fn_error $? "unrecognized option: \`$1'
16927Try \`$0 --help' for more information." ;;
16928
16929 *) as_fn_append ac_config_targets " $1"
16930 ac_need_defaults=false ;;
16931
16932 esac
16933 shift
16934done
16935
16936ac_configure_extra_args=
16937
16938if $ac_cs_silent; then
16939 exec 6>/dev/null
16940 ac_configure_extra_args="$ac_configure_extra_args --silent"
16941fi
16942
16943_ACEOF
16944cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16945if \$ac_cs_recheck; then
16946 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
16947 shift
16948 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
16949 CONFIG_SHELL='$SHELL'
16950 export CONFIG_SHELL
16951 exec "\$@"
16952fi
16953
16954_ACEOF
16955cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16956exec 5>>config.log
16957{
16958 echo
16959 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
16960## Running $as_me. ##
16961_ASBOX
16962 $as_echo "$ac_log"
16963} >&5
16964
16965_ACEOF
16966cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16967#
16968# INIT-COMMANDS
16969#
16970AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
16971
16972
16973# The HP-UX ksh and POSIX shell print the target directory to stdout
16974# if CDPATH is set.
16975(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
16976
16977sed_quote_subst='$sed_quote_subst'
16978double_quote_subst='$double_quote_subst'
16979delay_variable_subst='$delay_variable_subst'
16980macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
16981macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
16982enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
16983enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
16984pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
16985enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
16986SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
16987ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
16988PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
16989host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
16990host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
16991host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
16992build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
16993build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
16994build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
16995SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
16996Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
16997GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
16998EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
16999FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
17000LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
17001NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
17002LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
17003max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
17004ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
17005exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
17006lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
17007lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
17008lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
17009lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
17010lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
17011reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
17012reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
17013OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
17014deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
17015file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
17016file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
17017want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
17018DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
17019sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
17020AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
17021AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
17022archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
17023STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
17024RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
17025old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
17026old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
17027old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
17028lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
17029CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
17030CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
17031compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
17032GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
17033lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
17034lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
17035lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
17036lt_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"`'
17037nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
17038lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
17039objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
17040MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
17041lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
17042lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
17043lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
17044lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
17045lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
17046need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
17047MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
17048DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
17049NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
17050LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
17051OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
17052OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
17053libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
17054shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
17055extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
17056archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
17057enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
17058export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
17059whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
17060compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
17061old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
17062old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
17063archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
17064archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
17065module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
17066module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
17067with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
17068allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
17069no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
17070hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
17071hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
17072hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
17073hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
17074hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
17075hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
17076hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
17077inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
17078link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
17079always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
17080export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
17081exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
17082include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
17083prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
17084postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
17085file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
17086variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
17087need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
17088need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
17089version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
17090runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
17091shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
17092shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
17093libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
17094library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
17095soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
17096install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
17097postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
17098postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
17099finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
17100finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
17101hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
17102sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
17103sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
17104hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
17105enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
17106enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
17107enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
17108old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
17109striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
17110compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`'
17111predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`'
17112postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`'
17113predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`'
17114postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`'
17115compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`'
17116LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`'
17117reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`'
17118reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17119old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17120compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`'
17121GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`'
17122lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`'
17123lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`'
17124lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`'
17125lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`'
17126lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`'
17127archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`'
17128enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`'
17129export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
17130whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
17131compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`'
17132old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17133old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17134archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17135archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17136module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17137module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17138with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`'
17139allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
17140no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
17141hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
17142hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`'
17143hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`'
17144hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`'
17145hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`'
17146hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`'
17147hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`'
17148inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`'
17149link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`'
17150always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`'
17151export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17152exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
17153include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
17154prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17155postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`'
17156file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`'
17157hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`'
17158compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`'
17159predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`'
17160postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`'
17161predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`'
17162postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`'
17163compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`'
17164
17165LTCC='$LTCC'
17166LTCFLAGS='$LTCFLAGS'
17167compiler='$compiler_DEFAULT'
17168
17169# A function that is used when there is no print builtin or printf.
17170func_fallback_echo ()
17171{
17172 eval 'cat <<_LTECHO_EOF
17173\$1
17174_LTECHO_EOF'
17175}
17176
17177# Quote evaled strings.
17178for var in SHELL \
17179ECHO \
17180PATH_SEPARATOR \
17181SED \
17182GREP \
17183EGREP \
17184FGREP \
17185LD \
17186NM \
17187LN_S \
17188lt_SP2NL \
17189lt_NL2SP \
17190reload_flag \
17191OBJDUMP \
17192deplibs_check_method \
17193file_magic_cmd \
17194file_magic_glob \
17195want_nocaseglob \
17196DLLTOOL \
17197sharedlib_from_linklib_cmd \
17198AR \
17199AR_FLAGS \
17200archiver_list_spec \
17201STRIP \
17202RANLIB \
17203CC \
17204CFLAGS \
17205compiler \
17206lt_cv_sys_global_symbol_pipe \
17207lt_cv_sys_global_symbol_to_cdecl \
17208lt_cv_sys_global_symbol_to_c_name_address \
17209lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
17210nm_file_list_spec \
17211lt_prog_compiler_no_builtin_flag \
17212lt_prog_compiler_pic \
17213lt_prog_compiler_wl \
17214lt_prog_compiler_static \
17215lt_cv_prog_compiler_c_o \
17216need_locks \
17217MANIFEST_TOOL \
17218DSYMUTIL \
17219NMEDIT \
17220LIPO \
17221OTOOL \
17222OTOOL64 \
17223shrext_cmds \
17224export_dynamic_flag_spec \
17225whole_archive_flag_spec \
17226compiler_needs_object \
17227with_gnu_ld \
17228allow_undefined_flag \
17229no_undefined_flag \
17230hardcode_libdir_flag_spec \
17231hardcode_libdir_separator \
17232exclude_expsyms \
17233include_expsyms \
17234file_list_spec \
17235variables_saved_for_relink \
17236libname_spec \
17237library_names_spec \
17238soname_spec \
17239install_override_mode \
17240finish_eval \
17241old_striplib \
17242striplib \
17243compiler_lib_search_dirs \
17244predep_objects \
17245postdep_objects \
17246predeps \
17247postdeps \
17248compiler_lib_search_path \
17249LD_CXX \
17250reload_flag_CXX \
17251compiler_CXX \
17252lt_prog_compiler_no_builtin_flag_CXX \
17253lt_prog_compiler_pic_CXX \
17254lt_prog_compiler_wl_CXX \
17255lt_prog_compiler_static_CXX \
17256lt_cv_prog_compiler_c_o_CXX \
17257export_dynamic_flag_spec_CXX \
17258whole_archive_flag_spec_CXX \
17259compiler_needs_object_CXX \
17260with_gnu_ld_CXX \
17261allow_undefined_flag_CXX \
17262no_undefined_flag_CXX \
17263hardcode_libdir_flag_spec_CXX \
17264hardcode_libdir_separator_CXX \
17265exclude_expsyms_CXX \
17266include_expsyms_CXX \
17267file_list_spec_CXX \
17268compiler_lib_search_dirs_CXX \
17269predep_objects_CXX \
17270postdep_objects_CXX \
17271predeps_CXX \
17272postdeps_CXX \
17273compiler_lib_search_path_CXX; do
17274 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
17275 *[\\\\\\\`\\"\\\$]*)
17276 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
17277 ;;
17278 *)
17279 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
17280 ;;
17281 esac
17282done
17283
17284# Double-quote double-evaled strings.
17285for var in reload_cmds \
17286old_postinstall_cmds \
17287old_postuninstall_cmds \
17288old_archive_cmds \
17289extract_expsyms_cmds \
17290old_archive_from_new_cmds \
17291old_archive_from_expsyms_cmds \
17292archive_cmds \
17293archive_expsym_cmds \
17294module_cmds \
17295module_expsym_cmds \
17296export_symbols_cmds \
17297prelink_cmds \
17298postlink_cmds \
17299postinstall_cmds \
17300postuninstall_cmds \
17301finish_cmds \
17302sys_lib_search_path_spec \
17303sys_lib_dlsearch_path_spec \
17304reload_cmds_CXX \
17305old_archive_cmds_CXX \
17306old_archive_from_new_cmds_CXX \
17307old_archive_from_expsyms_cmds_CXX \
17308archive_cmds_CXX \
17309archive_expsym_cmds_CXX \
17310module_cmds_CXX \
17311module_expsym_cmds_CXX \
17312export_symbols_cmds_CXX \
17313prelink_cmds_CXX \
17314postlink_cmds_CXX; do
17315 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
17316 *[\\\\\\\`\\"\\\$]*)
17317 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
17318 ;;
17319 *)
17320 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
17321 ;;
17322 esac
17323done
17324
17325ac_aux_dir='$ac_aux_dir'
17326xsi_shell='$xsi_shell'
17327lt_shell_append='$lt_shell_append'
17328
17329# See if we are running on zsh, and set the options which allow our
17330# commands through without removal of \ escapes INIT.
17331if test -n "\${ZSH_VERSION+set}" ; then
17332 setopt NO_GLOB_SUBST
17333fi
17334
17335
17336 PACKAGE='$PACKAGE'
17337 VERSION='$VERSION'
17338 TIMESTAMP='$TIMESTAMP'
17339 RM='$RM'
17340 ofile='$ofile'
17341
17342
17343
17344
17345
17346
17347_ACEOF
17348
17349cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17350
17351# Handling of arguments.
17352for ac_config_target in $ac_config_targets
17353do
17354 case $ac_config_target in
17355 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
17356 "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
17357 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
17358 "kdtree/Makefile") CONFIG_FILES="$CONFIG_FILES kdtree/Makefile" ;;
17359 "HashFactory/Makefile") CONFIG_FILES="$CONFIG_FILES HashFactory/Makefile" ;;
17360 "simplehash/Makefile") CONFIG_FILES="$CONFIG_FILES simplehash/Makefile" ;;
17361 "timer/Makefile") CONFIG_FILES="$CONFIG_FILES timer/Makefile" ;;
17362
17363 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
17364 esac
17365done
17366
17367
17368# If the user did not use the arguments to specify the items to instantiate,
17369# then the envvar interface is used. Set only those that are not.
17370# We use the long form for the default assignment because of an extremely
17371# bizarre bug on SunOS 4.1.3.
17372if $ac_need_defaults; then
17373 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
17374 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
17375fi
17376
17377# Have a temporary directory for convenience. Make it in the build tree
17378# simply because there is no reason against having it here, and in addition,
17379# creating and moving files from /tmp can sometimes cause problems.
17380# Hook for its removal unless debugging.
17381# Note that there is a small window in which the directory will not be cleaned:
17382# after its creation but before its name has been assigned to `$tmp'.
17383$debug ||
17384{
17385 tmp= ac_tmp=
17386 trap 'exit_status=$?
17387 : "${ac_tmp:=$tmp}"
17388 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
17389' 0
17390 trap 'as_fn_exit 1' 1 2 13 15
17391}
17392# Create a (secure) tmp directory for tmp files.
17393
17394{
17395 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
17396 test -d "$tmp"
17397} ||
17398{
17399 tmp=./conf$$-$RANDOM
17400 (umask 077 && mkdir "$tmp")
17401} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
17402ac_tmp=$tmp
17403
17404# Set up the scripts for CONFIG_FILES section.
17405# No need to generate them if there are no CONFIG_FILES.
17406# This happens for instance with `./config.status config.h'.
17407if test -n "$CONFIG_FILES"; then
17408
17409
17410ac_cr=`echo X | tr X '\015'`
17411# On cygwin, bash can eat \r inside `` if the user requested igncr.
17412# But we know of no other shell where ac_cr would be empty at this
17413# point, so we can use a bashism as a fallback.
17414if test "x$ac_cr" = x; then
17415 eval ac_cr=\$\'\\r\'
17416fi
17417ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
17418if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
17419 ac_cs_awk_cr='\\r'
17420else
17421 ac_cs_awk_cr=$ac_cr
17422fi
17423
17424echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
17425_ACEOF
17426
17427
17428{
17429 echo "cat >conf$$subs.awk <<_ACEOF" &&
17430 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
17431 echo "_ACEOF"
17432} >conf$$subs.sh ||
17433 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
17434ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
17435ac_delim='%!_!# '
17436for ac_last_try in false false false false false :; do
17437 . ./conf$$subs.sh ||
17438 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
17439
17440 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
17441 if test $ac_delim_n = $ac_delim_num; then
17442 break
17443 elif $ac_last_try; then
17444 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
17445 else
17446 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
17447 fi
17448done
17449rm -f conf$$subs.sh
17450
17451cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17452cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
17453_ACEOF
17454sed -n '
17455h
17456s/^/S["/; s/!.*/"]=/
17457p
17458g
17459s/^[^!]*!//
17460:repl
17461t repl
17462s/'"$ac_delim"'$//
17463t delim
17464:nl
17465h
17466s/\(.\{148\}\)..*/\1/
17467t more1
17468s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
17469p
17470n
17471b repl
17472:more1
17473s/["\\]/\\&/g; s/^/"/; s/$/"\\/
17474p
17475g
17476s/.\{148\}//
17477t nl
17478:delim
17479h
17480s/\(.\{148\}\)..*/\1/
17481t more2
17482s/["\\]/\\&/g; s/^/"/; s/$/"/
17483p
17484b
17485:more2
17486s/["\\]/\\&/g; s/^/"/; s/$/"\\/
17487p
17488g
17489s/.\{148\}//
17490t delim
17491' <conf$$subs.awk | sed '
17492/^[^""]/{
17493 N
17494 s/\n//
17495}
17496' >>$CONFIG_STATUS || ac_write_fail=1
17497rm -f conf$$subs.awk
17498cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17499_ACAWK
17500cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
17501 for (key in S) S_is_set[key] = 1
17502 FS = ""
17503
17504}
17505{
17506 line = $ 0
17507 nfields = split(line, field, "@")
17508 substed = 0
17509 len = length(field[1])
17510 for (i = 2; i < nfields; i++) {
17511 key = field[i]
17512 keylen = length(key)
17513 if (S_is_set[key]) {
17514 value = S[key]
17515 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
17516 len += length(value) + length(field[++i])
17517 substed = 1
17518 } else
17519 len += 1 + keylen
17520 }
17521
17522 print line
17523}
17524
17525_ACAWK
17526_ACEOF
17527cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17528if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
17529 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
17530else
17531 cat
17532fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
17533 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
17534_ACEOF
17535
17536# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
17537# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
17538# trailing colons and then remove the whole line if VPATH becomes empty
17539# (actually we leave an empty line to preserve line numbers).
17540if test "x$srcdir" = x.; then
17541 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
17542h
17543s///
17544s/^/:/
17545s/[ ]*$/:/
17546s/:\$(srcdir):/:/g
17547s/:\${srcdir}:/:/g
17548s/:@srcdir@:/:/g
17549s/^:*//
17550s/:*$//
17551x
17552s/\(=[ ]*\).*/\1/
17553G
17554s/\n//
17555s/^[^=]*=[ ]*$//
17556}'
17557fi
17558
17559cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17560fi # test -n "$CONFIG_FILES"
17561
17562
17563eval set X " :F $CONFIG_FILES :C $CONFIG_COMMANDS"
17564shift
17565for ac_tag
17566do
17567 case $ac_tag in
17568 :[FHLC]) ac_mode=$ac_tag; continue;;
17569 esac
17570 case $ac_mode$ac_tag in
17571 :[FHL]*:*);;
17572 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
17573 :[FH]-) ac_tag=-:-;;
17574 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
17575 esac
17576 ac_save_IFS=$IFS
17577 IFS=:
17578 set x $ac_tag
17579 IFS=$ac_save_IFS
17580 shift
17581 ac_file=$1
17582 shift
17583
17584 case $ac_mode in
17585 :L) ac_source=$1;;
17586 :[FH])
17587 ac_file_inputs=
17588 for ac_f
17589 do
17590 case $ac_f in
17591 -) ac_f="$ac_tmp/stdin";;
17592 *) # Look for the file first in the build tree, then in the source tree
17593 # (if the path is not absolute). The absolute path cannot be DOS-style,
17594 # because $ac_f cannot contain `:'.
17595 test -f "$ac_f" ||
17596 case $ac_f in
17597 [\\/$]*) false;;
17598 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
17599 esac ||
17600 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
17601 esac
17602 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
17603 as_fn_append ac_file_inputs " '$ac_f'"
17604 done
17605
17606 # Let's still pretend it is `configure' which instantiates (i.e., don't
17607 # use $as_me), people would be surprised to read:
17608 # /* config.h. Generated by config.status. */
17609 configure_input='Generated from '`
17610 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
17611 `' by configure.'
17612 if test x"$ac_file" != x-; then
17613 configure_input="$ac_file. $configure_input"
17614 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
17615$as_echo "$as_me: creating $ac_file" >&6;}
17616 fi
17617 # Neutralize special characters interpreted by sed in replacement strings.
17618 case $configure_input in #(
17619 *\&* | *\|* | *\\* )
17620 ac_sed_conf_input=`$as_echo "$configure_input" |
17621 sed 's/[\\\\&|]/\\\\&/g'`;; #(
17622 *) ac_sed_conf_input=$configure_input;;
17623 esac
17624
17625 case $ac_tag in
17626 *:-:* | *:-) cat >"$ac_tmp/stdin" \
17627 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
17628 esac
17629 ;;
17630 esac
17631
17632 ac_dir=`$as_dirname -- "$ac_file" ||
17633$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17634 X"$ac_file" : 'X\(//\)[^/]' \| \
17635 X"$ac_file" : 'X\(//\)$' \| \
17636 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
17637$as_echo X"$ac_file" |
17638 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
17639 s//\1/
17640 q
17641 }
17642 /^X\(\/\/\)[^/].*/{
17643 s//\1/
17644 q
17645 }
17646 /^X\(\/\/\)$/{
17647 s//\1/
17648 q
17649 }
17650 /^X\(\/\).*/{
17651 s//\1/
17652 q
17653 }
17654 s/.*/./; q'`
17655 as_dir="$ac_dir"; as_fn_mkdir_p
17656 ac_builddir=.
17657
17658case "$ac_dir" in
17659.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
17660*)
17661 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
17662 # A ".." for each directory in $ac_dir_suffix.
17663 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
17664 case $ac_top_builddir_sub in
17665 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
17666 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
17667 esac ;;
17668esac
17669ac_abs_top_builddir=$ac_pwd
17670ac_abs_builddir=$ac_pwd$ac_dir_suffix
17671# for backward compatibility:
17672ac_top_builddir=$ac_top_build_prefix
17673
17674case $srcdir in
17675 .) # We are building in place.
17676 ac_srcdir=.
17677 ac_top_srcdir=$ac_top_builddir_sub
17678 ac_abs_top_srcdir=$ac_pwd ;;
17679 [\\/]* | ?:[\\/]* ) # Absolute name.
17680 ac_srcdir=$srcdir$ac_dir_suffix;
17681 ac_top_srcdir=$srcdir
17682 ac_abs_top_srcdir=$srcdir ;;
17683 *) # Relative name.
17684 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
17685 ac_top_srcdir=$ac_top_build_prefix$srcdir
17686 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
17687esac
17688ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
17689
17690
17691 case $ac_mode in
17692 :F)
17693 #
17694 # CONFIG_FILE
17695 #
17696
17697 case $INSTALL in
17698 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
17699 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
17700 esac
17701 ac_MKDIR_P=$MKDIR_P
17702 case $MKDIR_P in
17703 [\\/$]* | ?:[\\/]* ) ;;
17704 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
17705 esac
17706_ACEOF
17707
17708cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17709# If the template does not know about datarootdir, expand it.
17710# FIXME: This hack should be removed a few years after 2.60.
17711ac_datarootdir_hack=; ac_datarootdir_seen=
17712ac_sed_dataroot='
17713/datarootdir/ {
17714 p
17715 q
17716}
17717/@datadir@/p
17718/@docdir@/p
17719/@infodir@/p
17720/@localedir@/p
17721/@mandir@/p'
17722case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
17723*datarootdir*) ac_datarootdir_seen=yes;;
17724*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
17725 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
17726$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
17727_ACEOF
17728cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17729 ac_datarootdir_hack='
17730 s&@datadir@&$datadir&g
17731 s&@docdir@&$docdir&g
17732 s&@infodir@&$infodir&g
17733 s&@localedir@&$localedir&g
17734 s&@mandir@&$mandir&g
17735 s&\\\${datarootdir}&$datarootdir&g' ;;
17736esac
17737_ACEOF
17738
17739# Neutralize VPATH when `$srcdir' = `.'.
17740# Shell code in configure.ac might set extrasub.
17741# FIXME: do we really want to maintain this feature?
17742cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17743ac_sed_extra="$ac_vpsub
17744$extrasub
17745_ACEOF
17746cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17747:t
17748/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
17749s|@configure_input@|$ac_sed_conf_input|;t t
17750s&@top_builddir@&$ac_top_builddir_sub&;t t
17751s&@top_build_prefix@&$ac_top_build_prefix&;t t
17752s&@srcdir@&$ac_srcdir&;t t
17753s&@abs_srcdir@&$ac_abs_srcdir&;t t
17754s&@top_srcdir@&$ac_top_srcdir&;t t
17755s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
17756s&@builddir@&$ac_builddir&;t t
17757s&@abs_builddir@&$ac_abs_builddir&;t t
17758s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
17759s&@INSTALL@&$ac_INSTALL&;t t
17760s&@MKDIR_P@&$ac_MKDIR_P&;t t
17761$ac_datarootdir_hack
17762"
17763eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
17764 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
17765
17766test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
17767 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
17768 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
17769 "$ac_tmp/out"`; test -z "$ac_out"; } &&
17770 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
17771which seems to be undefined. Please make sure it is defined" >&5
17772$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
17773which seems to be undefined. Please make sure it is defined" >&2;}
17774
17775 rm -f "$ac_tmp/stdin"
17776 case $ac_file in
17777 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
17778 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
17779 esac \
17780 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
17781 ;;
17782
17783
17784 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
17785$as_echo "$as_me: executing $ac_file commands" >&6;}
17786 ;;
17787 esac
17788
17789
17790 case $ac_file$ac_mode in
17791 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
17792 # Older Autoconf quotes --file arguments for eval, but not when files
17793 # are listed without --file. Let's play safe and only enable the eval
17794 # if we detect the quoting.
17795 case $CONFIG_FILES in
17796 *\'*) eval set x "$CONFIG_FILES" ;;
17797 *) set x $CONFIG_FILES ;;
17798 esac
17799 shift
17800 for mf
17801 do
17802 # Strip MF so we end up with the name of the file.
17803 mf=`echo "$mf" | sed -e 's/:.*$//'`
17804 # Check whether this is an Automake generated Makefile or not.
17805 # We used to match only the files named 'Makefile.in', but
17806 # some people rename them; so instead we look at the file content.
17807 # Grep'ing the first line is not enough: some people post-process
17808 # each Makefile.in and add a new line on top of each file to say so.
17809 # Grep'ing the whole file is not good either: AIX grep has a line
17810 # limit of 2048, but all sed's we know have understand at least 4000.
17811 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
17812 dirpart=`$as_dirname -- "$mf" ||
17813$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17814 X"$mf" : 'X\(//\)[^/]' \| \
17815 X"$mf" : 'X\(//\)$' \| \
17816 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
17817$as_echo X"$mf" |
17818 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
17819 s//\1/
17820 q
17821 }
17822 /^X\(\/\/\)[^/].*/{
17823 s//\1/
17824 q
17825 }
17826 /^X\(\/\/\)$/{
17827 s//\1/
17828 q
17829 }
17830 /^X\(\/\).*/{
17831 s//\1/
17832 q
17833 }
17834 s/.*/./; q'`
17835 else
17836 continue
17837 fi
17838 # Extract the definition of DEPDIR, am__include, and am__quote
17839 # from the Makefile without running 'make'.
17840 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
17841 test -z "$DEPDIR" && continue
17842 am__include=`sed -n 's/^am__include = //p' < "$mf"`
17843 test -z "$am__include" && continue
17844 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
17845 # Find all dependency output files, they are included files with
17846 # $(DEPDIR) in their names. We invoke sed twice because it is the
17847 # simplest approach to changing $(DEPDIR) to its actual value in the
17848 # expansion.
17849 for file in `sed -n "
17850 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
17851 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
17852 # Make sure the directory exists.
17853 test -f "$dirpart/$file" && continue
17854 fdir=`$as_dirname -- "$file" ||
17855$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17856 X"$file" : 'X\(//\)[^/]' \| \
17857 X"$file" : 'X\(//\)$' \| \
17858 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
17859$as_echo X"$file" |
17860 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
17861 s//\1/
17862 q
17863 }
17864 /^X\(\/\/\)[^/].*/{
17865 s//\1/
17866 q
17867 }
17868 /^X\(\/\/\)$/{
17869 s//\1/
17870 q
17871 }
17872 /^X\(\/\).*/{
17873 s//\1/
17874 q
17875 }
17876 s/.*/./; q'`
17877 as_dir=$dirpart/$fdir; as_fn_mkdir_p
17878 # echo "creating $dirpart/$file"
17879 echo '# dummy' > "$dirpart/$file"
17880 done
17881 done
17882}
17883 ;;
17884 "libtool":C)
17885
17886 # See if we are running on zsh, and set the options which allow our
17887 # commands through without removal of \ escapes.
17888 if test -n "${ZSH_VERSION+set}" ; then
17889 setopt NO_GLOB_SUBST
17890 fi
17891
17892 cfgfile="${ofile}T"
17893 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
17894 $RM "$cfgfile"
17895
17896 cat <<_LT_EOF >> "$cfgfile"
17897#! $SHELL
17898
17899# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
17900# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
17901# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
17902# NOTE: Changes made to this file will be lost: look at ltmain.sh.
17903#
17904# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
17905# 2006, 2007, 2008, 2009, 2010, 2011 Free Software
17906# Foundation, Inc.
17907# Written by Gordon Matzigkeit, 1996
17908#
17909# This file is part of GNU Libtool.
17910#
17911# GNU Libtool is free software; you can redistribute it and/or
17912# modify it under the terms of the GNU General Public License as
17913# published by the Free Software Foundation; either version 2 of
17914# the License, or (at your option) any later version.
17915#
17916# As a special exception to the GNU General Public License,
17917# if you distribute this file as part of a program or library that
17918# is built using GNU Libtool, you may include this file under the
17919# same distribution terms that you use for the rest of that program.
17920#
17921# GNU Libtool is distributed in the hope that it will be useful,
17922# but WITHOUT ANY WARRANTY; without even the implied warranty of
17923# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17924# GNU General Public License for more details.
17925#
17926# You should have received a copy of the GNU General Public License
17927# along with GNU Libtool; see the file COPYING. If not, a copy
17928# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
17929# obtained by writing to the Free Software Foundation, Inc.,
17930# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
17931
17932
17933# The names of the tagged configurations supported by this script.
17934available_tags="CXX "
17935
17936# ### BEGIN LIBTOOL CONFIG
17937
17938# Which release of libtool.m4 was used?
17939macro_version=$macro_version
17940macro_revision=$macro_revision
17941
17942# Whether or not to build shared libraries.
17943build_libtool_libs=$enable_shared
17944
17945# Whether or not to build static libraries.
17946build_old_libs=$enable_static
17947
17948# What type of objects to build.
17949pic_mode=$pic_mode
17950
17951# Whether or not to optimize for fast installation.
17952fast_install=$enable_fast_install
17953
17954# Shell to use when invoking shell scripts.
17955SHELL=$lt_SHELL
17956
17957# An echo program that protects backslashes.
17958ECHO=$lt_ECHO
17959
17960# The PATH separator for the build system.
17961PATH_SEPARATOR=$lt_PATH_SEPARATOR
17962
17963# The host system.
17964host_alias=$host_alias
17965host=$host
17966host_os=$host_os
17967
17968# The build system.
17969build_alias=$build_alias
17970build=$build
17971build_os=$build_os
17972
17973# A sed program that does not truncate output.
17974SED=$lt_SED
17975
17976# Sed that helps us avoid accidentally triggering echo(1) options like -n.
17977Xsed="\$SED -e 1s/^X//"
17978
17979# A grep program that handles long lines.
17980GREP=$lt_GREP
17981
17982# An ERE matcher.
17983EGREP=$lt_EGREP
17984
17985# A literal string matcher.
17986FGREP=$lt_FGREP
17987
17988# A BSD- or MS-compatible name lister.
17989NM=$lt_NM
17990
17991# Whether we need soft or hard links.
17992LN_S=$lt_LN_S
17993
17994# What is the maximum length of a command?
17995max_cmd_len=$max_cmd_len
17996
17997# Object file suffix (normally "o").
17998objext=$ac_objext
17999
18000# Executable file suffix (normally "").
18001exeext=$exeext
18002
18003# whether the shell understands "unset".
18004lt_unset=$lt_unset
18005
18006# turn spaces into newlines.
18007SP2NL=$lt_lt_SP2NL
18008
18009# turn newlines into spaces.
18010NL2SP=$lt_lt_NL2SP
18011
18012# convert \$build file names to \$host format.
18013to_host_file_cmd=$lt_cv_to_host_file_cmd
18014
18015# convert \$build files to toolchain format.
18016to_tool_file_cmd=$lt_cv_to_tool_file_cmd
18017
18018# An object symbol dumper.
18019OBJDUMP=$lt_OBJDUMP
18020
18021# Method to check whether dependent libraries are shared objects.
18022deplibs_check_method=$lt_deplibs_check_method
18023
18024# Command to use when deplibs_check_method = "file_magic".
18025file_magic_cmd=$lt_file_magic_cmd
18026
18027# How to find potential files when deplibs_check_method = "file_magic".
18028file_magic_glob=$lt_file_magic_glob
18029
18030# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
18031want_nocaseglob=$lt_want_nocaseglob
18032
18033# DLL creation program.
18034DLLTOOL=$lt_DLLTOOL
18035
18036# Command to associate shared and link libraries.
18037sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
18038
18039# The archiver.
18040AR=$lt_AR
18041
18042# Flags to create an archive.
18043AR_FLAGS=$lt_AR_FLAGS
18044
18045# How to feed a file listing to the archiver.
18046archiver_list_spec=$lt_archiver_list_spec
18047
18048# A symbol stripping program.
18049STRIP=$lt_STRIP
18050
18051# Commands used to install an old-style archive.
18052RANLIB=$lt_RANLIB
18053old_postinstall_cmds=$lt_old_postinstall_cmds
18054old_postuninstall_cmds=$lt_old_postuninstall_cmds
18055
18056# Whether to use a lock for old archive extraction.
18057lock_old_archive_extraction=$lock_old_archive_extraction
18058
18059# A C compiler.
18060LTCC=$lt_CC
18061
18062# LTCC compiler flags.
18063LTCFLAGS=$lt_CFLAGS
18064
18065# Take the output of nm and produce a listing of raw symbols and C names.
18066global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
18067
18068# Transform the output of nm in a proper C declaration.
18069global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
18070
18071# Transform the output of nm in a C name address pair.
18072global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
18073
18074# Transform the output of nm in a C name address pair when lib prefix is needed.
18075global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
18076
18077# Specify filename containing input files for \$NM.
18078nm_file_list_spec=$lt_nm_file_list_spec
18079
18080# The root where to search for dependent libraries,and in which our libraries should be installed.
18081lt_sysroot=$lt_sysroot
18082
18083# The name of the directory that contains temporary libtool files.
18084objdir=$objdir
18085
18086# Used to examine libraries when file_magic_cmd begins with "file".
18087MAGIC_CMD=$MAGIC_CMD
18088
18089# Must we lock files when doing compilation?
18090need_locks=$lt_need_locks
18091
18092# Manifest tool.
18093MANIFEST_TOOL=$lt_MANIFEST_TOOL
18094
18095# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
18096DSYMUTIL=$lt_DSYMUTIL
18097
18098# Tool to change global to local symbols on Mac OS X.
18099NMEDIT=$lt_NMEDIT
18100
18101# Tool to manipulate fat objects and archives on Mac OS X.
18102LIPO=$lt_LIPO
18103
18104# ldd/readelf like tool for Mach-O binaries on Mac OS X.
18105OTOOL=$lt_OTOOL
18106
18107# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
18108OTOOL64=$lt_OTOOL64
18109
18110# Old archive suffix (normally "a").
18111libext=$libext
18112
18113# Shared library suffix (normally ".so").
18114shrext_cmds=$lt_shrext_cmds
18115
18116# The commands to extract the exported symbol list from a shared archive.
18117extract_expsyms_cmds=$lt_extract_expsyms_cmds
18118
18119# Variables whose values should be saved in libtool wrapper scripts and
18120# restored at link time.
18121variables_saved_for_relink=$lt_variables_saved_for_relink
18122
18123# Do we need the "lib" prefix for modules?
18124need_lib_prefix=$need_lib_prefix
18125
18126# Do we need a version for libraries?
18127need_version=$need_version
18128
18129# Library versioning type.
18130version_type=$version_type
18131
18132# Shared library runtime path variable.
18133runpath_var=$runpath_var
18134
18135# Shared library path variable.
18136shlibpath_var=$shlibpath_var
18137
18138# Is shlibpath searched before the hard-coded library search path?
18139shlibpath_overrides_runpath=$shlibpath_overrides_runpath
18140
18141# Format of library name prefix.
18142libname_spec=$lt_libname_spec
18143
18144# List of archive names. First name is the real one, the rest are links.
18145# The last name is the one that the linker finds with -lNAME
18146library_names_spec=$lt_library_names_spec
18147
18148# The coded name of the library, if different from the real name.
18149soname_spec=$lt_soname_spec
18150
18151# Permission mode override for installation of shared libraries.
18152install_override_mode=$lt_install_override_mode
18153
18154# Command to use after installation of a shared archive.
18155postinstall_cmds=$lt_postinstall_cmds
18156
18157# Command to use after uninstallation of a shared archive.
18158postuninstall_cmds=$lt_postuninstall_cmds
18159
18160# Commands used to finish a libtool library installation in a directory.
18161finish_cmds=$lt_finish_cmds
18162
18163# As "finish_cmds", except a single script fragment to be evaled but
18164# not shown.
18165finish_eval=$lt_finish_eval
18166
18167# Whether we should hardcode library paths into libraries.
18168hardcode_into_libs=$hardcode_into_libs
18169
18170# Compile-time system search path for libraries.
18171sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
18172
18173# Run-time system search path for libraries.
18174sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
18175
18176# Whether dlopen is supported.
18177dlopen_support=$enable_dlopen
18178
18179# Whether dlopen of programs is supported.
18180dlopen_self=$enable_dlopen_self
18181
18182# Whether dlopen of statically linked programs is supported.
18183dlopen_self_static=$enable_dlopen_self_static
18184
18185# Commands to strip libraries.
18186old_striplib=$lt_old_striplib
18187striplib=$lt_striplib
18188
18189
18190# The linker used to build libraries.
18191LD=$lt_LD
18192
18193# How to create reloadable object files.
18194reload_flag=$lt_reload_flag
18195reload_cmds=$lt_reload_cmds
18196
18197# Commands used to build an old-style archive.
18198old_archive_cmds=$lt_old_archive_cmds
18199
18200# A language specific compiler.
18201CC=$lt_compiler
18202
18203# Is the compiler the GNU compiler?
18204with_gcc=$GCC
18205
18206# Compiler flag to turn off builtin functions.
18207no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
18208
18209# Additional compiler flags for building library objects.
18210pic_flag=$lt_lt_prog_compiler_pic
18211
18212# How to pass a linker flag through the compiler.
18213wl=$lt_lt_prog_compiler_wl
18214
18215# Compiler flag to prevent dynamic linking.
18216link_static_flag=$lt_lt_prog_compiler_static
18217
18218# Does compiler simultaneously support -c and -o options?
18219compiler_c_o=$lt_lt_cv_prog_compiler_c_o
18220
18221# Whether or not to add -lc for building shared libraries.
18222build_libtool_need_lc=$archive_cmds_need_lc
18223
18224# Whether or not to disallow shared libs when runtime libs are static.
18225allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
18226
18227# Compiler flag to allow reflexive dlopens.
18228export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
18229
18230# Compiler flag to generate shared objects directly from archives.
18231whole_archive_flag_spec=$lt_whole_archive_flag_spec
18232
18233# Whether the compiler copes with passing no objects directly.
18234compiler_needs_object=$lt_compiler_needs_object
18235
18236# Create an old-style archive from a shared archive.
18237old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
18238
18239# Create a temporary old-style archive to link instead of a shared archive.
18240old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
18241
18242# Commands used to build a shared archive.
18243archive_cmds=$lt_archive_cmds
18244archive_expsym_cmds=$lt_archive_expsym_cmds
18245
18246# Commands used to build a loadable module if different from building
18247# a shared archive.
18248module_cmds=$lt_module_cmds
18249module_expsym_cmds=$lt_module_expsym_cmds
18250
18251# Whether we are building with GNU ld or not.
18252with_gnu_ld=$lt_with_gnu_ld
18253
18254# Flag that allows shared libraries with undefined symbols to be built.
18255allow_undefined_flag=$lt_allow_undefined_flag
18256
18257# Flag that enforces no undefined symbols.
18258no_undefined_flag=$lt_no_undefined_flag
18259
18260# Flag to hardcode \$libdir into a binary during linking.
18261# This must work even if \$libdir does not exist
18262hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
18263
18264# Whether we need a single "-rpath" flag with a separated argument.
18265hardcode_libdir_separator=$lt_hardcode_libdir_separator
18266
18267# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
18268# DIR into the resulting binary.
18269hardcode_direct=$hardcode_direct
18270
18271# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
18272# DIR into the resulting binary and the resulting library dependency is
18273# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
18274# library is relocated.
18275hardcode_direct_absolute=$hardcode_direct_absolute
18276
18277# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
18278# into the resulting binary.
18279hardcode_minus_L=$hardcode_minus_L
18280
18281# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
18282# into the resulting binary.
18283hardcode_shlibpath_var=$hardcode_shlibpath_var
18284
18285# Set to "yes" if building a shared library automatically hardcodes DIR
18286# into the library and all subsequent libraries and executables linked
18287# against it.
18288hardcode_automatic=$hardcode_automatic
18289
18290# Set to yes if linker adds runtime paths of dependent libraries
18291# to runtime path list.
18292inherit_rpath=$inherit_rpath
18293
18294# Whether libtool must link a program against all its dependency libraries.
18295link_all_deplibs=$link_all_deplibs
18296
18297# Set to "yes" if exported symbols are required.
18298always_export_symbols=$always_export_symbols
18299
18300# The commands to list exported symbols.
18301export_symbols_cmds=$lt_export_symbols_cmds
18302
18303# Symbols that should not be listed in the preloaded symbols.
18304exclude_expsyms=$lt_exclude_expsyms
18305
18306# Symbols that must always be exported.
18307include_expsyms=$lt_include_expsyms
18308
18309# Commands necessary for linking programs (against libraries) with templates.
18310prelink_cmds=$lt_prelink_cmds
18311
18312# Commands necessary for finishing linking programs.
18313postlink_cmds=$lt_postlink_cmds
18314
18315# Specify filename containing input files.
18316file_list_spec=$lt_file_list_spec
18317
18318# How to hardcode a shared library path into an executable.
18319hardcode_action=$hardcode_action
18320
18321# The directories searched by this compiler when creating a shared library.
18322compiler_lib_search_dirs=$lt_compiler_lib_search_dirs
18323
18324# Dependencies to place before and after the objects being linked to
18325# create a shared library.
18326predep_objects=$lt_predep_objects
18327postdep_objects=$lt_postdep_objects
18328predeps=$lt_predeps
18329postdeps=$lt_postdeps
18330
18331# The library search path used internally by the compiler when linking
18332# a shared library.
18333compiler_lib_search_path=$lt_compiler_lib_search_path
18334
18335# ### END LIBTOOL CONFIG
18336
18337_LT_EOF
18338
18339 case $host_os in
18340 aix3*)
18341 cat <<\_LT_EOF >> "$cfgfile"
18342# AIX sometimes has problems with the GCC collect2 program. For some
18343# reason, if we set the COLLECT_NAMES environment variable, the problems
18344# vanish in a puff of smoke.
18345if test "X${COLLECT_NAMES+set}" != Xset; then
18346 COLLECT_NAMES=
18347 export COLLECT_NAMES
18348fi
18349_LT_EOF
18350 ;;
18351 esac
18352
18353
18354ltmain="$ac_aux_dir/ltmain.sh"
18355
18356
18357 # We use sed instead of cat because bash on DJGPP gets confused if
18358 # if finds mixed CR/LF and LF-only lines. Since sed operates in
18359 # text mode, it properly converts lines to CR/LF. This bash problem
18360 # is reportedly fixed, but why not run on old versions too?
18361 sed '$q' "$ltmain" >> "$cfgfile" \
18362 || (rm -f "$cfgfile"; exit 1)
18363
18364 if test x"$xsi_shell" = xyes; then
18365 sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
18366func_dirname ()\
18367{\
18368\ case ${1} in\
18369\ */*) func_dirname_result="${1%/*}${2}" ;;\
18370\ * ) func_dirname_result="${3}" ;;\
18371\ esac\
18372} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
18373 && mv -f "$cfgfile.tmp" "$cfgfile" \
18374 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18375test 0 -eq $? || _lt_function_replace_fail=:
18376
18377
18378 sed -e '/^func_basename ()$/,/^} # func_basename /c\
18379func_basename ()\
18380{\
18381\ func_basename_result="${1##*/}"\
18382} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
18383 && mv -f "$cfgfile.tmp" "$cfgfile" \
18384 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18385test 0 -eq $? || _lt_function_replace_fail=:
18386
18387
18388 sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
18389func_dirname_and_basename ()\
18390{\
18391\ case ${1} in\
18392\ */*) func_dirname_result="${1%/*}${2}" ;;\
18393\ * ) func_dirname_result="${3}" ;;\
18394\ esac\
18395\ func_basename_result="${1##*/}"\
18396} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
18397 && mv -f "$cfgfile.tmp" "$cfgfile" \
18398 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18399test 0 -eq $? || _lt_function_replace_fail=:
18400
18401
18402 sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
18403func_stripname ()\
18404{\
18405\ # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
18406\ # positional parameters, so assign one to ordinary parameter first.\
18407\ func_stripname_result=${3}\
18408\ func_stripname_result=${func_stripname_result#"${1}"}\
18409\ func_stripname_result=${func_stripname_result%"${2}"}\
18410} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
18411 && mv -f "$cfgfile.tmp" "$cfgfile" \
18412 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18413test 0 -eq $? || _lt_function_replace_fail=:
18414
18415
18416 sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
18417func_split_long_opt ()\
18418{\
18419\ func_split_long_opt_name=${1%%=*}\
18420\ func_split_long_opt_arg=${1#*=}\
18421} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
18422 && mv -f "$cfgfile.tmp" "$cfgfile" \
18423 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18424test 0 -eq $? || _lt_function_replace_fail=:
18425
18426
18427 sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
18428func_split_short_opt ()\
18429{\
18430\ func_split_short_opt_arg=${1#??}\
18431\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
18432} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
18433 && mv -f "$cfgfile.tmp" "$cfgfile" \
18434 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18435test 0 -eq $? || _lt_function_replace_fail=:
18436
18437
18438 sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
18439func_lo2o ()\
18440{\
18441\ case ${1} in\
18442\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
18443\ *) func_lo2o_result=${1} ;;\
18444\ esac\
18445} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
18446 && mv -f "$cfgfile.tmp" "$cfgfile" \
18447 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18448test 0 -eq $? || _lt_function_replace_fail=:
18449
18450
18451 sed -e '/^func_xform ()$/,/^} # func_xform /c\
18452func_xform ()\
18453{\
18454 func_xform_result=${1%.*}.lo\
18455} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
18456 && mv -f "$cfgfile.tmp" "$cfgfile" \
18457 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18458test 0 -eq $? || _lt_function_replace_fail=:
18459
18460
18461 sed -e '/^func_arith ()$/,/^} # func_arith /c\
18462func_arith ()\
18463{\
18464 func_arith_result=$(( $* ))\
18465} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
18466 && mv -f "$cfgfile.tmp" "$cfgfile" \
18467 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18468test 0 -eq $? || _lt_function_replace_fail=:
18469
18470
18471 sed -e '/^func_len ()$/,/^} # func_len /c\
18472func_len ()\
18473{\
18474 func_len_result=${#1}\
18475} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
18476 && mv -f "$cfgfile.tmp" "$cfgfile" \
18477 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18478test 0 -eq $? || _lt_function_replace_fail=:
18479
18480fi
18481
18482if test x"$lt_shell_append" = xyes; then
18483 sed -e '/^func_append ()$/,/^} # func_append /c\
18484func_append ()\
18485{\
18486 eval "${1}+=\\${2}"\
18487} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
18488 && mv -f "$cfgfile.tmp" "$cfgfile" \
18489 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18490test 0 -eq $? || _lt_function_replace_fail=:
18491
18492
18493 sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
18494func_append_quoted ()\
18495{\
18496\ func_quote_for_eval "${2}"\
18497\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
18498} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
18499 && mv -f "$cfgfile.tmp" "$cfgfile" \
18500 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18501test 0 -eq $? || _lt_function_replace_fail=:
18502
18503
18504 # Save a `func_append' function call where possible by direct use of '+='
18505 sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
18506 && mv -f "$cfgfile.tmp" "$cfgfile" \
18507 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18508 test 0 -eq $? || _lt_function_replace_fail=:
18509else
18510 # Save a `func_append' function call even when '+=' is not available
18511 sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
18512 && mv -f "$cfgfile.tmp" "$cfgfile" \
18513 || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
18514 test 0 -eq $? || _lt_function_replace_fail=:
18515fi
18516
18517if test x"$_lt_function_replace_fail" = x":"; then
18518 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
18519$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
18520fi
18521
18522
18523 mv -f "$cfgfile" "$ofile" ||
18524 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
18525 chmod +x "$ofile"
18526
18527
18528 cat <<_LT_EOF >> "$ofile"
18529
18530# ### BEGIN LIBTOOL TAG CONFIG: CXX
18531
18532# The linker used to build libraries.
18533LD=$lt_LD_CXX
18534
18535# How to create reloadable object files.
18536reload_flag=$lt_reload_flag_CXX
18537reload_cmds=$lt_reload_cmds_CXX
18538
18539# Commands used to build an old-style archive.
18540old_archive_cmds=$lt_old_archive_cmds_CXX
18541
18542# A language specific compiler.
18543CC=$lt_compiler_CXX
18544
18545# Is the compiler the GNU compiler?
18546with_gcc=$GCC_CXX
18547
18548# Compiler flag to turn off builtin functions.
18549no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX
18550
18551# Additional compiler flags for building library objects.
18552pic_flag=$lt_lt_prog_compiler_pic_CXX
18553
18554# How to pass a linker flag through the compiler.
18555wl=$lt_lt_prog_compiler_wl_CXX
18556
18557# Compiler flag to prevent dynamic linking.
18558link_static_flag=$lt_lt_prog_compiler_static_CXX
18559
18560# Does compiler simultaneously support -c and -o options?
18561compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX
18562
18563# Whether or not to add -lc for building shared libraries.
18564build_libtool_need_lc=$archive_cmds_need_lc_CXX
18565
18566# Whether or not to disallow shared libs when runtime libs are static.
18567allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX
18568
18569# Compiler flag to allow reflexive dlopens.
18570export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX
18571
18572# Compiler flag to generate shared objects directly from archives.
18573whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX
18574
18575# Whether the compiler copes with passing no objects directly.
18576compiler_needs_object=$lt_compiler_needs_object_CXX
18577
18578# Create an old-style archive from a shared archive.
18579old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX
18580
18581# Create a temporary old-style archive to link instead of a shared archive.
18582old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX
18583
18584# Commands used to build a shared archive.
18585archive_cmds=$lt_archive_cmds_CXX
18586archive_expsym_cmds=$lt_archive_expsym_cmds_CXX
18587
18588# Commands used to build a loadable module if different from building
18589# a shared archive.
18590module_cmds=$lt_module_cmds_CXX
18591module_expsym_cmds=$lt_module_expsym_cmds_CXX
18592
18593# Whether we are building with GNU ld or not.
18594with_gnu_ld=$lt_with_gnu_ld_CXX
18595
18596# Flag that allows shared libraries with undefined symbols to be built.
18597allow_undefined_flag=$lt_allow_undefined_flag_CXX
18598
18599# Flag that enforces no undefined symbols.
18600no_undefined_flag=$lt_no_undefined_flag_CXX
18601
18602# Flag to hardcode \$libdir into a binary during linking.
18603# This must work even if \$libdir does not exist
18604hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX
18605
18606# Whether we need a single "-rpath" flag with a separated argument.
18607hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
18608
18609# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
18610# DIR into the resulting binary.
18611hardcode_direct=$hardcode_direct_CXX
18612
18613# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
18614# DIR into the resulting binary and the resulting library dependency is
18615# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
18616# library is relocated.
18617hardcode_direct_absolute=$hardcode_direct_absolute_CXX
18618
18619# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
18620# into the resulting binary.
18621hardcode_minus_L=$hardcode_minus_L_CXX
18622
18623# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
18624# into the resulting binary.
18625hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX
18626
18627# Set to "yes" if building a shared library automatically hardcodes DIR
18628# into the library and all subsequent libraries and executables linked
18629# against it.
18630hardcode_automatic=$hardcode_automatic_CXX
18631
18632# Set to yes if linker adds runtime paths of dependent libraries
18633# to runtime path list.
18634inherit_rpath=$inherit_rpath_CXX
18635
18636# Whether libtool must link a program against all its dependency libraries.
18637link_all_deplibs=$link_all_deplibs_CXX
18638
18639# Set to "yes" if exported symbols are required.
18640always_export_symbols=$always_export_symbols_CXX
18641
18642# The commands to list exported symbols.
18643export_symbols_cmds=$lt_export_symbols_cmds_CXX
18644
18645# Symbols that should not be listed in the preloaded symbols.
18646exclude_expsyms=$lt_exclude_expsyms_CXX
18647
18648# Symbols that must always be exported.
18649include_expsyms=$lt_include_expsyms_CXX
18650
18651# Commands necessary for linking programs (against libraries) with templates.
18652prelink_cmds=$lt_prelink_cmds_CXX
18653
18654# Commands necessary for finishing linking programs.
18655postlink_cmds=$lt_postlink_cmds_CXX
18656
18657# Specify filename containing input files.
18658file_list_spec=$lt_file_list_spec_CXX
18659
18660# How to hardcode a shared library path into an executable.
18661hardcode_action=$hardcode_action_CXX
18662
18663# The directories searched by this compiler when creating a shared library.
18664compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX
18665
18666# Dependencies to place before and after the objects being linked to
18667# create a shared library.
18668predep_objects=$lt_predep_objects_CXX
18669postdep_objects=$lt_postdep_objects_CXX
18670predeps=$lt_predeps_CXX
18671postdeps=$lt_postdeps_CXX
18672
18673# The library search path used internally by the compiler when linking
18674# a shared library.
18675compiler_lib_search_path=$lt_compiler_lib_search_path_CXX
18676
18677# ### END LIBTOOL TAG CONFIG: CXX
18678_LT_EOF
18679
18680 ;;
18681
18682 esac
18683done # for ac_tag
18684
18685
18686as_fn_exit 0
18687_ACEOF
18688ac_clean_files=$ac_clean_files_save
18689
18690test $ac_write_fail = 0 ||
18691 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
18692
18693
18694# configure is writing to config.log, and then calls config.status.
18695# config.status does its own redirection, appending to config.log.
18696# Unfortunately, on DOS this fails, as config.log is still kept open
18697# by configure, so config.status won't be able to write to it; its
18698# output is simply discarded. So we exec the FD to /dev/null,
18699# effectively closing config.log, so it can be properly (re)opened and
18700# appended to by config.status. When coming back to configure, we
18701# need to make the FD available again.
18702if test "$no_create" != yes; then
18703 ac_cs_success=:
18704 ac_config_status_args=
18705 test "$silent" = yes &&
18706 ac_config_status_args="$ac_config_status_args --quiet"
18707 exec 5>/dev/null
18708 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
18709 exec 5>>config.log
18710 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
18711 # would make configure fail if this is the last instruction.
18712 $ac_cs_success || as_fn_exit 1
18713fi
18714if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
18715 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
18716$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
18717fi
18718
18719
configure.ac +0 -383
……@@ -1,383 +0,0 @@
1AC_INIT(CompactHash, v1.2)
2
3AC_CONFIG_AUX_DIR(./config)
4
5AM_INIT_AUTOMAKE([foreign])
6
7dnl AC_CONFIG_HEADERS([config.h])
8dnl AC_CONFIG_HEADERS([HashFactory/config.h])
9
10dnl
11dnl Caching is usually WRONG for systems with cross-mounted file systems
12dnl the cache file may correspond to a different system.
13dnl
14define([AC_CACHE_LOAD], )dnl
15define([AC_CACHE_SAVE], )dnl
16dnl
17
18#
19echo "Configuring hash with $ac_configure_args"
20#
21
22AC_ARG_ENABLE( [debug],
23 [ AS_HELP_STRING([--enable-debug],
24 [compiles code with debug flags @<:@default=no@:>@])],
25 [],
26 [enable_debug=no]
27)
28
29AC_ARG_ENABLE( [bounds-check],
30 [ AS_HELP_STRING([--enable-bounds-check],
31 [compiles code with bounds check flags @<:@default=no@:>@])],
32 [],
33 [enable_bounds_check=no]
34)
35
36AC_ARG_ENABLE( [prof],
37 [ AS_HELP_STRING([--enable-prof],
38 [compiles code with profiling flags @<:@default=no@:>@])],
39 [],
40 [enable_prof=no]
41)
42
43AC_ARG_ENABLE( [opencl],
44 [ AS_HELP_STRING([--enable-opencl],
45 [compiles code with opencl library @<:@default=yes@:>@])],
46 [],
47 [enable_opencl=yes]
48)
49
50AC_ARG_ENABLE( [detailed-timing],
51 [ AS_HELP_STRING([--enable-detailed-timing],
52 [compiles code with detailed timing on @<:@default=no@:>@])],
53 [],
54 [enable_detailed_timing=no]
55)
56
57AC_ARG_ENABLE( [write-mem-usage],
58 [ AS_HELP_STRING([--enable-write-mem-usage],
59 [compiles code with write memory usage on @<:@default=no@:>@])],
60 [],
61 [enable_write_mem_usage=no]
62)
63
64#AM_WITH_DMALLOC
65
66dnl so we don't have shared libraries
67dnl AC_ENABLE_STATIC(yes)
68
69# Checks for programs
70AC_PROG_CC
71AC_PROG_CXX
72AM_PROG_CC_C_O
73AC_PROG_INSTALL
74AC_PROG_MAKE_SET
75AC_PROG_LIBTOOL
76
77AC_CONFIG_MACRO_DIR([m4])
78
79INDENT="indent"
80CPREPROCESSOR="cpp -P"
81
82AC_CHECK_PROG([HAVE_ADDR2LINE], [addr2line], [yes])
83if test "x$HAVE_ADDR2LINE" == "xyes"; then
84 AC_DEFINE([HAVE_ADDR2LINE],[1],[Has addr2line program])
85fi
86
87# Checks for header files
88AC_HEADER_STDC
89
90# Checks for typedefs, structures, and compiler characteristics
91AC_SYS_LARGEFILE
92
93# Checks for library functions
94
95AC_CANONICAL_HOST
96case "$host" in
97 *linux*)
98 CFLAGS="-std=gnu99 -static"
99 if test "${enable_debug}" = "yes"; then
100 CFLAGS="-g -DDEBUG=1 ${CFLAGS}"
101 else
102 CFLAGS="-g -O3 ${CFLAGS}"
103 fi
104 if test "${enable_prof}" = "yes"; then
105 CFLAGS="-pg ${CFLAGS}"
106 LFLAGS="-pg ${LFLAGS}"
107 fi
108
109 if test "${enable_bounds_check}" = "yes"; then
110 CFLAGS="-fbounds-check ${CFLAGS}"
111 fi
112
113 RPATH_PREFIX="-Wl,"
114
115 ;;
116 *darwin*)
117 CFLAGS="-std=gnu99 -pedantic -Wno-overlength-strings"
118 INDENT="gindent"
119 CPREPROCESSOR="gcc -E -P -U__APPLE_CC__"
120 if test "${enable_debug}" = "yes"; then
121 CFLAGS="-g -DDEBUG=1 ${CFLAGS}"
122 else
123 CFLAGS="-g -O3 ${CFLAGS}"
124 fi
125
126 if test "${enable_bounds_check}" = "yes"; then
127 CFLAGS="-fbounds-check ${CFLAGS}"
128 fi
129
130 RPATH_PREFIX="-Wl,"
131
132 ;;
133 *)
134 echo "Unknown machine"
135 exit 1
136 ;;
137esac
138
139if test "${enable_detailed_timing}" = "yes"; then
140 CFLAGS="-DDETAILED_TIMING=1 ${CFLAGS}"
141fi
142
143if test "${enable_write_mem_usage}" = "no"; then
144 CFLAGS="-DWRITE_MEM_USAGE=0 ${CFLAGS}"
145fi
146
147if test "${enable_opencl}" != "no"; then
148 case "$host" in
149 *linux*)
150 AC_MSG_CHECKING([OPENCL_INCLUDE environment variable to set OpenCL includes])
151 opencl_inc_found="no"
152 if test ! -z "${OPENCL_INCLUDE}" ; then
153 AC_MSG_RESULT(-I${OPENCL_INCLUDE})
154 opencl_inc_found="yes"
155 AM_CPPFLAGS="${AM_CPPFLAGS} -I${OPENCL_INCLUDE}"
156 else
157 AC_MSG_RESULT(no)
158 fi
159
160 opencl_lib_found="no"
161 AC_MSG_CHECKING([OPENCL_LIBS environment variable to set OpenCL libs])
162 if test ! -z "${OPENCL_LIBS}" ; then
163 AC_MSG_RESULT(-L${OPENCL_LIBS} -lOpenCL)
164 opencl_lib_found="yes"
165 LIBS="${LIBS} -L${OPENCL_LIBS} -lOpenCL"
166 if test "${RPATH_LIBS}x" = "x"; then
167 RPATH_LIBS="${OPENCL_LIBS}"
168 else
169 RPATH_LIBS="${RPATH_LIBS}:${OPENCL_LIBS}"
170 fi
171 else
172 AC_MSG_RESULT(no)
173 fi
174
175 if test "$opencl_inc_found" = "no"; then
176 AC_CHECK_PROG(lspci_found, lspci, yes, no)
177 if test "$lspci_found" = "no"; then
178 AC_CHECK_FILE(/projects/opt/cuda/cuda-5.5/include/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/cuda/cuda-5.5/include" && opencl_inc_found="yes")
179 if test "$opencl_inc_found" = "no"; then
180 AC_CHECK_FILE(/opt/cudatoolkit-6.0/include/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/opt/cudatoolkit-6.0/include" && opencl_inc_found="yes")
181 fi
182 if test "$opencl_inc_found" = "no"; then
183 AC_CHECK_FILE( /projects/opt/opencl1d2_additional_files/include/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/opencl1d2_additional_files/include" && opencl_inc_found="yes")
184 fi
185 if test "$opencl_inc_found" = "no"; then
186 AC_CHECK_FILE( /projects/opt/AMD_APP_SDK/AMDAPP-2.8/include/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/AMD_APP_SDK/AMDAPP-2.8/include" && opencl_inc_found="yes")
187 fi
188 if test "$opencl_inc_found" = "no"; then
189 AC_CHECK_FILE( /opt/intel/opencl-1.2-3.0.67279/include/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/opt/intel/opencl-1.2-3.0.67279/include" && opencl_inc_found="yes")
190 fi
191
192 if test "$opencl_lib_found" = "no"; then
193 AC_CHECK_FILE(/opt/cudatoolkit-6.0/lib64/libOpenCL.so, LIBS="${LIBS} -L/opt/cudatoolkit-6.0/lib64 -lOpenCL" && opencl_lib_found="yes")
194 if test "${opencl_lib_found}" = "yes"; then
195 if test "${RPATH_LIBS}x" = "x"; then
196 RPATH_LIBS="/opt/cudatoolkit-6.0/lib64"
197 else
198 RPATH_LIBS="${RPATH_LIBS}:/opt/cudatoolkit-6.0/lib64"
199 fi
200 fi
201 fi
202 if test "$opencl_lib_found" = "no"; then
203 AC_CHECK_FILE(/usr/lib/libOpenCL.so, LIBS="${LIBS} -lOpenCL" && opencl_lib_found="yes")
204 if test "${opencl_lib_found}" = "yes"; then
205 if test "${RPATH_LIBS}x" = "x"; then
206 RPATH_LIBS="/usr/lib"
207 else
208 RPATH_LIBS="${RPATH_LIBS}:/usr/lib"
209 fi
210 fi
211 fi
212 if test "$opencl_lib_found" = "no"; then
213 AC_CHECK_FILE(/usr/lib64/libOpenCL.so, LIBS="${LIBS} -lOpenCL" && opencl_lib_found="yes")
214 if test "${opencl_lib_found}" = "yes"; then
215 if test "${RPATH_LIBS}x" = "x"; then
216 RPATH_LIBS="/usr/lib64"
217 else
218 RPATH_LIBS="${RPATH_LIBS}:/usr/lib64"
219 fi
220 fi
221 fi
222 if test "$opencl_lib_found" = "no"; then
223 AC_CHECK_FILE(/projects/opt/AMD_APP_SDK/AMDAPP-2.8/lib/x86_64/libOpenCL.so, LIBS="${LIBS} -L/projects/opt/AMD_APP_SDK/AMDAPP-2.8/lib/x86_64 -lOpenCL" && opencl_lib_found="yes")
224 if test "${opencl_lib_found}" = "yes"; then
225 if test "${RPATH_LIBS}x" = "x"; then
226 RPATH_LIBS="/projects/opt/AMD_APP_SDK/AMDAPP-2.8/lib/x86_64"
227 else
228 RPATH_LIBS="${RPATH_LIBS}:/projects/opt/AMD_APP_SDK/AMDAPP-2.8/lib/x86_64"
229 fi
230 fi
231 fi
232 if test "$opencl_lib_found" = "no"; then
233 AC_CHECK_FILE(/opt/intel/opencl-1.2-3.0.67279/lib64/libOpenCL.so, LIBS="${LIBS} -L/opt/intel/opencl-1.2-3.0.67279/lib64 -L/opt/intel/opencl-1.2-3.0.67279/libmic" && opencl_lib_found="yes")
234 if test "${opencl_lib_found}" = "yes"; then
235 if test "${RPATH_LIBS}x" = "x"; then
236 RPATH_LIBS="/opt/intel/opencl-1.2-3.0.67279/lib64"
237 else
238 RPATH_LIBS="${RPATH_LIBS}:/opt/intel/opencl-1.2-3.0.67279/lib64"
239 fi
240 fi
241 fi
242 elif test "`lspci | grep "VGA compatible controller" | grep -i nVidia | wc -l`" != "0"; then
243 AC_CHECK_FILE(/usr/local/NVIDIA_GPU_Computing_SDK/OpenCL/common/inc/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/usr/local/NVIDIA_GPU_Computing_SDK/OpenCL/common/inc" && opencl_inc_found="yes")
244 if test "$opencl_inc_found" = "no"; then
245 AC_CHECK_FILE(/usr/local/cuda/include/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/usr/local/cuda/include" && opencl_inc_found="yes")
246 fi
247 if test "$opencl_inc_found" = "no"; then
248 AC_CHECK_FILE(/projects/opt/cuda/cuda-5.5/include/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/cuda/cuda-5.5/include" && opencl_inc_found="yes")
249 fi
250 if test "$opencl_inc_found" = "no"; then
251 AC_CHECK_FILE( /projects/opt/opencl1d2_additional_files/include/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/opencl1d2_additional_files/include" && opencl_inc_found="yes")
252 fi
253 if test "$opencl_inc_found" = "no"; then
254 AC_CHECK_FILE(/home/cuda/sdk4.0.13/OpenCL/common/inc/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/home/cuda/sdk4.0.13/OpenCL/common/inc" && opencl_inc_found="yes")
255 fi
256
257 if test "$opencl_lib_found" = "no"; then
258 AC_CHECK_FILE(/usr/lib/libOpenCL.so, LIBS="${LIBS} -lOpenCL" && opencl_lib_found="yes")
259 if test "${opencl_lib_found}" = "yes"; then
260 if test "${RPATH_LIBS}x" = "x"; then
261 RPATH_LIBS="/usr/lib"
262 else
263 RPATH_LIBS="${RPATH_LIBS}:/usr/lib"
264 fi
265 fi
266 fi
267 if test "$opencl_lib_found" = "no"; then
268 AC_CHECK_FILE(/usr/lib64/libOpenCL.so, LIBS="${LIBS} -lOpenCL" && opencl_lib_found="yes")
269 if test "${opencl_lib_found}" = "yes"; then
270 if test "${RPATH_LIBS}x" = "x"; then
271 RPATH_LIBS="/usr/lib64"
272 else
273 RPATH_LIBS="${RPATH_LIBS}:/usr/lib64"
274 fi
275 fi
276 fi
277 elif test "`lspci | grep "VGA compatible controller" | grep ATI | wc -l`" != "0"; then
278 if test "$opencl_inc_found" = "no"; then
279 AC_CHECK_FILE(/home/opt/AMDAPP_v2.6/include/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/home/opt/AMDAPP_v2.6/include" && opencl_inc_found="yes")
280 fi
281 if test "$opencl_inc_found" = "no"; then
282 AC_CHECK_FILE(/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/include/CL/cl.h, AM_CPPFLAGS="${AM_CPPFLAGS} -I/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/include" && opencl_inc_found="yes")
283 fi
284
285 if test "$opencl_lib_found" = "no"; then
286 AC_CHECK_FILE(/home/opt/AMDAPP_v2.6/lib/x86_64/libOpenCL.so, LIBS="${LIBS} -L/home/opt/AMDAPP_v2.6/lib/x86_64 -lOpenCL" && opencl_lib_found="yes")
287 if test "${opencl_lib_found}" = "yes"; then
288 if test "${RPATH_LIBS}x" = "x"; then
289 RPATH_LIBS="/home/opt/AMDAPP_v2.6/lib/x86_64"
290 else
291 RPATH_LIBS="${RPATH_LIBS}:/home/opt/AMDAPP_v2.6/lib/x86_64"
292 fi
293 fi
294 fi
295 if test "$opencl_lib_found" = "no"; then
296 AC_CHECK_FILE(/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/lib/x86_64/libOpenCL.so, LIBS="${LIBS} -L/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/lib/x86_64 -lOpenCL" && opencl_lib_found="yes")
297 if test "${opencl_lib_found}" = "yes"; then
298 if test "${RPATH_LIBS}x" = "x"; then
299 RPATH_LIBS="/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/lib/x86_64"
300 else
301 RPATH_LIBS="${RPATH_LIBS}:/projects/opt/AMD_APP_SDK/AMDAPP_v2.6/lib/x86_64"
302 fi
303 fi
304 fi
305 fi
306 fi
307 dnl For debugging fail
308 dnl opencl_inc_found=no
309 if test "$opencl_inc_found" = "yes"; then
310 AC_DEFINE(HAVE_OPENCL,1,[Has OpenCL])
311 else
312 AC_MSG_WARN(=================================================================)
313 AC_MSG_WARN(OpenCL was not found, but will try to build without it)
314 AC_MSG_WARN(If it fails, try setting OPENCL_INCLUDE and OPENCL_LIBS)
315 AC_MSG_WARN(to location of include directory and the OpenCL library)
316 AC_MSG_WARN(or build without OpenCL with "./configure --disable-opencl".)
317 AC_MSG_WARN(If you disable opencl, you may need to go into the HashFactory directory)
318 AC_MSG_WARN(and force the rebuild of HashFactory.c and HashFactory.h "make HashFactory.c HashFactory.h".)
319 AC_MSG_WARN(You may need to remove the HashFactory.c and HashFactory.h files if make gets)
320 AC_MSG_WARN(confused by timestamps)
321 AC_MSG_WARN(=================================================================)
322 fi
323 ;;
324 *darwin*)
325 AC_MSG_NOTICE([Adding OpenCL framework])
326 AC_DEFINE(HAVE_OPENCL,1,[Has OpenCL])
327 LIBS="${LIBS} -framework OpenCL"
328 ;;
329 esac
330
331
332dnl ---------------------------------------------------------------
333 AC_MSG_CHECKING(for OpenCL double type)
334
335 SAVE_C_FLAGS=$CFLAGS
336 CFLAGS="$CFLAGS $AM_CPPFLAGS"
337
338 AC_LANG([C])
339
340 AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
341 [
342 [#ifdef __APPLE_CC__]
343 [#include <OpenCL/OpenCL.h>]
344 [#else]
345 [#include <CL/cl.h>]
346 [#endif]
347 ],
348 [[cl_double x;]])],
349 ac_cv_opencl_double=yes, ac_cv_opencl_double=no
350 )
351 if test "x$ac_cv_opencl_double" = "xyes"; then
352 AC_DEFINE(HAVE_CL_DOUBLE,1,[Has OpenCL double type])
353 else
354 AC_DEFINE(NO_CL_DOUBLE,1,[Does not have OpenCL double type])
355 fi
356
357 CFLAGS=$SAVE_C_FLAGS
358
359 AC_MSG_RESULT($ac_cv_opencl_double)
360dnl ---------------------------------------------------------------
361fi
362
363if test ! -z "${RPATH_LIBS}"; then
364 LIBS="${LIBS} ${RPATH_PREFIX}-rpath ${RPATH_PREFIX}${RPATH_LIBS}"
365fi
366
367LIBS="${LIBS} -lm"
368
369AC_SUBST(CC)
370AC_SUBST(CFLAGS)
371AC_SUBST(AM_CPPFLAGS)
372AC_SUBST(LIBS)
373AC_SUBST(INDENT)
374AC_SUBST(CPREPROCESSOR)
375
376AC_CONFIG_FILES([Makefile])
377AC_CONFIG_FILES([kdtree/Makefile])
378AC_CONFIG_FILES([HashFactory/Makefile])
379AC_CONFIG_FILES([simplehash/Makefile])
380AC_CONFIG_FILES([timer/Makefile])
381
382AC_OUTPUT
383
embed_source.pl +37 -0
……@@ -0,0 +1,37 @@
1eval 'exec perl -w $0 ${1+"$@"}'
2 if 0;
3
4use File::Basename;
5
6$ARGV_LAST = "";
7
8($file,,) = fileparse($ARGV[0], qr/\..*/);
9print "const char *",$file,"_source =\n";
10
11while(<>) {
12 if ($ARGV ne $ARGV_LAST){
13# $comment = 0;
14 $ARGV_LAST=$ARGV;
15 }
16 chop $_;
17
18 s/"/""/g;
19
20# if (/^\/\*/){
21# #print "Setting comment to 1\n";
22# $comment = 1;
23# }
24# if (/\*\/$/){
25# #print "Setting comment to 0\n";
26# $comment = 0;
27# next;
28# }
29# if ($comment eq 1) {
30# #print "Skip line and goto next\n";
31## next;
32# }
33
34 print '"',$_,'\n','"',"\n";
35}
36
37print ";"
kdtree/CMakeLists.txt +34 -0
……@@ -0,0 +1,34 @@
1########### global settings ###############
2set(H_SRCS Bounds1d.h Bounds2d.h Globals1d.h Globals2d.h KDTree1d.h KDTree2d.h)
3
4set(C_SRCS Bounds1d.c Bounds2d.c KDTree1d.c KDTree2d.c)
5
6set(kdtree_LIB_SRCS ${C_SRCS} ${H_SRCS})
7
8########### kdtree target ###############
9
10add_library(kdtree SHARED ${kdtree_LIB_SRCS})
11
12set_target_properties(kdtree PROPERTIES VERSION 1.0.0 SOVERSION 2)
13install(TARGETS kdtree DESTINATION lib)
14
15########### install files ###############
16
17#install(FILES KDTree.h DESTINATION include)
18
19#========== original Makefile.am contents follow ===========
20
21#original Makefile.am contents follow:
22
23#default: libkdtree.la
24#all: libkdtree.la
25#
26#AM_MAKEFLAGS = -j 4
27#
28#DEFAULT_INCLUDES=-I. -I..
29#
30#lib_LTLIBRARIES = libkdtree.la
31#include_HEADERS = KDTree.h
32#
33#libkdtree_la_SOURCES = ${C_SRCS} ${H_SRCS}
34#
simplehash/CMakeLists.txt +42 -0
……@@ -0,0 +1,42 @@
1set(libsimplehash_LIB_SRCS simplehash.c simplehash.h)
2
3########### embed source target ###############
4add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/simplehashlib_kern.inc
5 COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/embed_source.pl
6 ${CMAKE_CURRENT_SOURCE_DIR}/simplehashlib_kern.cl > simplehashlib_kern.inc
7 DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/simplehashlib_kern.cl
8 ${CMAKE_CURRENT_SOURCE_DIR}/embed_source.pl)
9add_custom_target(simplehashlib_kernel_source ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/simplehashlib_kern.inc)
10
11add_custom_command(OUTPUT
12${CMAKE_CURRENT_BINARY_DIR}/simplehash_kern.inc
13 COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/embed_source.pl
14 ${CMAKE_CURRENT_SOURCE_DIR}/simplehash_kern.cl > simplehash_kern.inc
15 DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/simplehash_kern.cl
16 ${CMAKE_CURRENT_SOURCE_DIR}/embed_source.pl)
17add_custom_target(simplehash_kernel_source ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/simplehash_kern.inc)
18
19add_library(simplehash STATIC ${libsimplehash_LIB_SRCS})
20set_target_properties(simplehash PROPERTIES COMPILE_FLAGS "-I..")
21if (OPENCL_FOUND)
22 target_link_libraries(simplehash)
23 set_target_properties(simplehash PROPERTIES COMPILE_DEFINITIONS "HAVE_OPENCL")
24endif (OPENCL_FOUND)
25add_dependencies(simplehash simplehash_kernel_source)
26add_dependencies(simplehash simplehashlib_kernel_source)
27
28if (OPENMP_FOUND)
29 add_library(simplehash_openmp STATIC ${libsimplehash_LIB_SRCS})
30 set_target_properties(simplehash_openmp PROPERTIES COMPILE_FLAGS "-I.. ${OpenMP_C_FLAGS}")
31# set_target_properties(simplehash_openmp PROPERTIES COMPILE_FLAGS "${OpenMP_C_FLAGS}")
32# set_target_properties(simplehash_openmp PROPERTIES LINK_FLAGS "${OpenMP_C_FLAGS}")
33
34 if (OPENCL_FOUND)
35 target_link_libraries(simplehash_openmp)
36 set_target_properties(simplehash_openmp PROPERTIES COMPILE_DEFINITIONS "HAVE_OPENCL")
37 endif (OPENCL_FOUND)
38 add_dependencies(simplehash_openmp simplehash_kernel_source)
39 add_dependencies(simplehash_openmp simplehashlib_kernel_source)
40endif (OPENMP_FOUND)
41
42
simplehash/Makefile.am +0 -28
……@@ -1,28 +0,0 @@
1default: simplehash.c libsimplehash.la
2all: simplehash.c libsimplehash.la
3
4AM_MAKEFLAGS = -j 4
5
6DEFAULT_INCLUDES=-I. -I..
7
8lib_LTLIBRARIES = libsimplehash.la
9include_HEADERS = simplehash.h
10
11H_SRCS = simplehash.h
12
13C_SRCS = simplehash.c
14
15libsimplehash_la_SOURCES = ${C_SRCS} ${H_SRCS}
16
17simplehash.c: simplehashlib_kern.inc simplehash_kern.inc
18
19simplehashlib_kern.inc:
20 ./embed_source.pl simplehashlib_kern.cl > simplehashlib_kern.inc
21
22simplehash_kern.inc:
23 ./embed_source.pl simplehash_kern.cl > simplehash_kern.inc
24
25EXTRA_DIST = simplehash_kern.cl simplehashlib_kern.cl embed_source.pl
26
27clean-local:
28 rm -f *.inc
simplehash/Makefile.in +0 -679
……@@ -1,679 +0,0 @@
1# Makefile.in generated by automake 1.13.4 from Makefile.am.
2# @configure_input@
3
4# Copyright (C) 1994-2013 Free Software Foundation, Inc.
5
6# This Makefile.in is free software; the Free Software Foundation
7# gives unlimited permission to copy and/or distribute it,
8# with or without modifications, as long as this notice is preserved.
9
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
12# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
13# PARTICULAR PURPOSE.
14
15@SET_MAKE@
16
17
18VPATH = @srcdir@
19am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
20am__make_running_with_option = \
21 case $${target_option-} in \
22 ?) ;; \
23 *) echo "am__make_running_with_option: internal error: invalid" \
24 "target option '$${target_option-}' specified" >&2; \
25 exit 1;; \
26 esac; \
27 has_opt=no; \
28 sane_makeflags=$$MAKEFLAGS; \
29 if $(am__is_gnu_make); then \
30 sane_makeflags=$$MFLAGS; \
31 else \
32 case $$MAKEFLAGS in \
33 *\\[\ \ ]*) \
34 bs=\\; \
35 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
36 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
37 esac; \
38 fi; \
39 skip_next=no; \
40 strip_trailopt () \
41 { \
42 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
43 }; \
44 for flg in $$sane_makeflags; do \
45 test $$skip_next = yes && { skip_next=no; continue; }; \
46 case $$flg in \
47 *=*|--*) continue;; \
48 -*I) strip_trailopt 'I'; skip_next=yes;; \
49 -*I?*) strip_trailopt 'I';; \
50 -*O) strip_trailopt 'O'; skip_next=yes;; \
51 -*O?*) strip_trailopt 'O';; \
52 -*l) strip_trailopt 'l'; skip_next=yes;; \
53 -*l?*) strip_trailopt 'l';; \
54 -[dEDm]) skip_next=yes;; \
55 -[JT]) skip_next=yes;; \
56 esac; \
57 case $$flg in \
58 *$$target_option*) has_opt=yes; break;; \
59 esac; \
60 done; \
61 test $$has_opt = yes
62am__make_dryrun = (target_option=n; $(am__make_running_with_option))
63am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
64pkgdatadir = $(datadir)/@PACKAGE@
65pkgincludedir = $(includedir)/@PACKAGE@
66pkglibdir = $(libdir)/@PACKAGE@
67pkglibexecdir = $(libexecdir)/@PACKAGE@
68am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
69install_sh_DATA = $(install_sh) -c -m 644
70install_sh_PROGRAM = $(install_sh) -c
71install_sh_SCRIPT = $(install_sh) -c
72INSTALL_HEADER = $(INSTALL_DATA)
73transform = $(program_transform_name)
74NORMAL_INSTALL = :
75PRE_INSTALL = :
76POST_INSTALL = :
77NORMAL_UNINSTALL = :
78PRE_UNINSTALL = :
79POST_UNINSTALL = :
80build_triplet = @build@
81host_triplet = @host@
82subdir = simplehash
83DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
84 $(top_srcdir)/./config/depcomp $(include_HEADERS)
85ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
86am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
87 $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
88 $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
89 $(top_srcdir)/configure.ac
90am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
91 $(ACLOCAL_M4)
92mkinstalldirs = $(install_sh) -d
93CONFIG_CLEAN_FILES =
94CONFIG_CLEAN_VPATH_FILES =
95am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
96am__vpath_adj = case $$p in \
97 $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
98 *) f=$$p;; \
99 esac;
100am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
101am__install_max = 40
102am__nobase_strip_setup = \
103 srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
104am__nobase_strip = \
105 for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
106am__nobase_list = $(am__nobase_strip_setup); \
107 for p in $$list; do echo "$$p $$p"; done | \
108 sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
109 $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
110 if (++n[$$2] == $(am__install_max)) \
111 { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
112 END { for (dir in files) print dir, files[dir] }'
113am__base_list = \
114 sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
115 sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
116am__uninstall_files_from_dir = { \
117 test -z "$$files" \
118 || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
119 || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
120 $(am__cd) "$$dir" && rm -f $$files; }; \
121 }
122am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)"
123LTLIBRARIES = $(lib_LTLIBRARIES)
124libsimplehash_la_LIBADD =
125am__objects_1 = simplehash.lo
126am__objects_2 =
127am_libsimplehash_la_OBJECTS = $(am__objects_1) $(am__objects_2)
128libsimplehash_la_OBJECTS = $(am_libsimplehash_la_OBJECTS)
129AM_V_lt = $(am__v_lt_@AM_V@)
130am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
131am__v_lt_0 = --silent
132am__v_lt_1 =
133AM_V_P = $(am__v_P_@AM_V@)
134am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
135am__v_P_0 = false
136am__v_P_1 = :
137AM_V_GEN = $(am__v_GEN_@AM_V@)
138am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
139am__v_GEN_0 = @echo " GEN " $@;
140am__v_GEN_1 =
141AM_V_at = $(am__v_at_@AM_V@)
142am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
143am__v_at_0 = @
144am__v_at_1 =
145depcomp = $(SHELL) $(top_srcdir)/./config/depcomp
146am__depfiles_maybe = depfiles
147am__mv = mv -f
148COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
149 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
150LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
151 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
152 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
153 $(AM_CFLAGS) $(CFLAGS)
154AM_V_CC = $(am__v_CC_@AM_V@)
155am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
156am__v_CC_0 = @echo " CC " $@;
157am__v_CC_1 =
158CCLD = $(CC)
159LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
160 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
161 $(AM_LDFLAGS) $(LDFLAGS) -o $@
162AM_V_CCLD = $(am__v_CCLD_@AM_V@)
163am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
164am__v_CCLD_0 = @echo " CCLD " $@;
165am__v_CCLD_1 =
166SOURCES = $(libsimplehash_la_SOURCES)
167DIST_SOURCES = $(libsimplehash_la_SOURCES)
168am__can_run_installinfo = \
169 case $$AM_UPDATE_INFO_DIR in \
170 n|no|NO) false;; \
171 *) (install-info --version) >/dev/null 2>&1;; \
172 esac
173HEADERS = $(include_HEADERS)
174am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
175# Read a list of newline-separated strings from the standard input,
176# and print each of them once, without duplicates. Input order is
177# *not* preserved.
178am__uniquify_input = $(AWK) '\
179 BEGIN { nonempty = 0; } \
180 { items[$$0] = 1; nonempty = 1; } \
181 END { if (nonempty) { for (i in items) print i; }; } \
182'
183# Make sure the list of sources is unique. This is necessary because,
184# e.g., the same source file might be shared among _SOURCES variables
185# for different programs/libraries.
186am__define_uniq_tagged_files = \
187 list='$(am__tagged_files)'; \
188 unique=`for i in $$list; do \
189 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
190 done | $(am__uniquify_input)`
191ETAGS = etags
192CTAGS = ctags
193DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
194ACLOCAL = @ACLOCAL@
195AMTAR = @AMTAR@
196AM_CPPFLAGS = @AM_CPPFLAGS@
197AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
198AR = @AR@
199AUTOCONF = @AUTOCONF@
200AUTOHEADER = @AUTOHEADER@
201AUTOMAKE = @AUTOMAKE@
202AWK = @AWK@
203CC = @CC@
204CCDEPMODE = @CCDEPMODE@
205CFLAGS = @CFLAGS@
206CPP = @CPP@
207CPPFLAGS = @CPPFLAGS@
208CPREPROCESSOR = @CPREPROCESSOR@
209CXX = @CXX@
210CXXCPP = @CXXCPP@
211CXXDEPMODE = @CXXDEPMODE@
212CXXFLAGS = @CXXFLAGS@
213CYGPATH_W = @CYGPATH_W@
214DEFS = @DEFS@
215DEPDIR = @DEPDIR@
216DLLTOOL = @DLLTOOL@
217DSYMUTIL = @DSYMUTIL@
218DUMPBIN = @DUMPBIN@
219ECHO_C = @ECHO_C@
220ECHO_N = @ECHO_N@
221ECHO_T = @ECHO_T@
222EGREP = @EGREP@
223EXEEXT = @EXEEXT@
224FGREP = @FGREP@
225GREP = @GREP@
226HAVE_ADDR2LINE = @HAVE_ADDR2LINE@
227INDENT = @INDENT@
228INSTALL = @INSTALL@
229INSTALL_DATA = @INSTALL_DATA@
230INSTALL_PROGRAM = @INSTALL_PROGRAM@
231INSTALL_SCRIPT = @INSTALL_SCRIPT@
232INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
233LD = @LD@
234LDFLAGS = @LDFLAGS@
235LIBOBJS = @LIBOBJS@
236LIBS = @LIBS@
237LIBTOOL = @LIBTOOL@
238LIPO = @LIPO@
239LN_S = @LN_S@
240LTLIBOBJS = @LTLIBOBJS@
241MAKEINFO = @MAKEINFO@
242MANIFEST_TOOL = @MANIFEST_TOOL@
243MKDIR_P = @MKDIR_P@
244NM = @NM@
245NMEDIT = @NMEDIT@
246OBJDUMP = @OBJDUMP@
247OBJEXT = @OBJEXT@
248OTOOL = @OTOOL@
249OTOOL64 = @OTOOL64@
250PACKAGE = @PACKAGE@
251PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
252PACKAGE_NAME = @PACKAGE_NAME@
253PACKAGE_STRING = @PACKAGE_STRING@
254PACKAGE_TARNAME = @PACKAGE_TARNAME@
255PACKAGE_URL = @PACKAGE_URL@
256PACKAGE_VERSION = @PACKAGE_VERSION@
257PATH_SEPARATOR = @PATH_SEPARATOR@
258RANLIB = @RANLIB@
259SED = @SED@
260SET_MAKE = @SET_MAKE@
261SHELL = @SHELL@
262STRIP = @STRIP@
263VERSION = @VERSION@
264abs_builddir = @abs_builddir@
265abs_srcdir = @abs_srcdir@
266abs_top_builddir = @abs_top_builddir@
267abs_top_srcdir = @abs_top_srcdir@
268ac_ct_AR = @ac_ct_AR@
269ac_ct_CC = @ac_ct_CC@
270ac_ct_CXX = @ac_ct_CXX@
271ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
272am__include = @am__include@
273am__leading_dot = @am__leading_dot@
274am__quote = @am__quote@
275am__tar = @am__tar@
276am__untar = @am__untar@
277bindir = @bindir@
278build = @build@
279build_alias = @build_alias@
280build_cpu = @build_cpu@
281build_os = @build_os@
282build_vendor = @build_vendor@
283builddir = @builddir@
284datadir = @datadir@
285datarootdir = @datarootdir@
286docdir = @docdir@
287dvidir = @dvidir@
288exec_prefix = @exec_prefix@
289host = @host@
290host_alias = @host_alias@
291host_cpu = @host_cpu@
292host_os = @host_os@
293host_vendor = @host_vendor@
294htmldir = @htmldir@
295includedir = @includedir@
296infodir = @infodir@
297install_sh = @install_sh@
298libdir = @libdir@
299libexecdir = @libexecdir@
300localedir = @localedir@
301localstatedir = @localstatedir@
302lspci_found = @lspci_found@
303mandir = @mandir@
304mkdir_p = @mkdir_p@
305oldincludedir = @oldincludedir@
306pdfdir = @pdfdir@
307prefix = @prefix@
308program_transform_name = @program_transform_name@
309psdir = @psdir@
310sbindir = @sbindir@
311sharedstatedir = @sharedstatedir@
312srcdir = @srcdir@
313sysconfdir = @sysconfdir@
314target_alias = @target_alias@
315top_build_prefix = @top_build_prefix@
316top_builddir = @top_builddir@
317top_srcdir = @top_srcdir@
318AM_MAKEFLAGS = -j 4
319DEFAULT_INCLUDES = -I. -I..
320lib_LTLIBRARIES = libsimplehash.la
321include_HEADERS = simplehash.h
322H_SRCS = simplehash.h
323C_SRCS = simplehash.c
324libsimplehash_la_SOURCES = ${C_SRCS} ${H_SRCS}
325EXTRA_DIST = simplehash_kern.cl simplehashlib_kern.cl embed_source.pl
326all: all-am
327
328.SUFFIXES:
329.SUFFIXES: .c .lo .o .obj
330$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
331 @for dep in $?; do \
332 case '$(am__configure_deps)' in \
333 *$$dep*) \
334 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
335 && { if test -f $@; then exit 0; else break; fi; }; \
336 exit 1;; \
337 esac; \
338 done; \
339 echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign simplehash/Makefile'; \
340 $(am__cd) $(top_srcdir) && \
341 $(AUTOMAKE) --foreign simplehash/Makefile
342.PRECIOUS: Makefile
343Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
344 @case '$?' in \
345 *config.status*) \
346 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
347 *) \
348 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
349 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
350 esac;
351
352$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
353 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
354
355$(top_srcdir)/configure: $(am__configure_deps)
356 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
357$(ACLOCAL_M4): $(am__aclocal_m4_deps)
358 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
359$(am__aclocal_m4_deps):
360
361install-libLTLIBRARIES: $(lib_LTLIBRARIES)
362 @$(NORMAL_INSTALL)
363 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
364 list2=; for p in $$list; do \
365 if test -f $$p; then \
366 list2="$$list2 $$p"; \
367 else :; fi; \
368 done; \
369 test -z "$$list2" || { \
370 echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \
371 $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \
372 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \
373 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \
374 }
375
376uninstall-libLTLIBRARIES:
377 @$(NORMAL_UNINSTALL)
378 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
379 for p in $$list; do \
380 $(am__strip_dir) \
381 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \
382 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \
383 done
384
385clean-libLTLIBRARIES:
386 -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES)
387 @list='$(lib_LTLIBRARIES)'; \
388 locs=`for p in $$list; do echo $$p; done | \
389 sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
390 sort -u`; \
391 test -z "$$locs" || { \
392 echo rm -f $${locs}; \
393 rm -f $${locs}; \
394 }
395
396libsimplehash.la: $(libsimplehash_la_OBJECTS) $(libsimplehash_la_DEPENDENCIES) $(EXTRA_libsimplehash_la_DEPENDENCIES)
397 $(AM_V_CCLD)$(LINK) -rpath $(libdir) $(libsimplehash_la_OBJECTS) $(libsimplehash_la_LIBADD) $(LIBS)
398
399mostlyclean-compile:
400 -rm -f *.$(OBJEXT)
401
402distclean-compile:
403 -rm -f *.tab.c
404
405@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simplehash.Plo@am__quote@
406
407.c.o:
408@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
409@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
410@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
411@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
412@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c $<
413
414.c.obj:
415@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
416@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
417@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
418@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
419@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c `$(CYGPATH_W) '$<'`
420
421.c.lo:
422@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
423@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
424@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
425@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
426@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
427
428mostlyclean-libtool:
429 -rm -f *.lo
430
431clean-libtool:
432 -rm -rf .libs _libs
433install-includeHEADERS: $(include_HEADERS)
434 @$(NORMAL_INSTALL)
435 @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \
436 if test -n "$$list"; then \
437 echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \
438 $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \
439 fi; \
440 for p in $$list; do \
441 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
442 echo "$$d$$p"; \
443 done | $(am__base_list) | \
444 while read files; do \
445 echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \
446 $(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \
447 done
448
449uninstall-includeHEADERS:
450 @$(NORMAL_UNINSTALL)
451 @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \
452 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
453 dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir)
454
455ID: $(am__tagged_files)
456 $(am__define_uniq_tagged_files); mkid -fID $$unique
457tags: tags-am
458TAGS: tags
459
460tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
461 set x; \
462 here=`pwd`; \
463 $(am__define_uniq_tagged_files); \
464 shift; \
465 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
466 test -n "$$unique" || unique=$$empty_fix; \
467 if test $$# -gt 0; then \
468 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
469 "$$@" $$unique; \
470 else \
471 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
472 $$unique; \
473 fi; \
474 fi
475ctags: ctags-am
476
477CTAGS: ctags
478ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
479 $(am__define_uniq_tagged_files); \
480 test -z "$(CTAGS_ARGS)$$unique" \
481 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
482 $$unique
483
484GTAGS:
485 here=`$(am__cd) $(top_builddir) && pwd` \
486 && $(am__cd) $(top_srcdir) \
487 && gtags -i $(GTAGS_ARGS) "$$here"
488cscopelist: cscopelist-am
489
490cscopelist-am: $(am__tagged_files)
491 list='$(am__tagged_files)'; \
492 case "$(srcdir)" in \
493 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
494 *) sdir=$(subdir)/$(srcdir) ;; \
495 esac; \
496 for i in $$list; do \
497 if test -f "$$i"; then \
498 echo "$(subdir)/$$i"; \
499 else \
500 echo "$$sdir/$$i"; \
501 fi; \
502 done >> $(top_builddir)/cscope.files
503
504distclean-tags:
505 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
506
507distdir: $(DISTFILES)
508 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
509 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
510 list='$(DISTFILES)'; \
511 dist_files=`for file in $$list; do echo $$file; done | \
512 sed -e "s|^$$srcdirstrip/||;t" \
513 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
514 case $$dist_files in \
515 */*) $(MKDIR_P) `echo "$$dist_files" | \
516 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
517 sort -u` ;; \
518 esac; \
519 for file in $$dist_files; do \
520 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
521 if test -d $$d/$$file; then \
522 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
523 if test -d "$(distdir)/$$file"; then \
524 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
525 fi; \
526 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
527 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
528 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
529 fi; \
530 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
531 else \
532 test -f "$(distdir)/$$file" \
533 || cp -p $$d/$$file "$(distdir)/$$file" \
534 || exit 1; \
535 fi; \
536 done
537check-am: all-am
538check: check-am
539all-am: Makefile $(LTLIBRARIES) $(HEADERS)
540installdirs:
541 for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)"; do \
542 test -z "$$dir" || $(MKDIR_P) "$$dir"; \
543 done
544install: install-am
545install-exec: install-exec-am
546install-data: install-data-am
547uninstall: uninstall-am
548
549install-am: all-am
550 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
551
552installcheck: installcheck-am
553install-strip:
554 if test -z '$(STRIP)'; then \
555 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
556 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
557 install; \
558 else \
559 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
560 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
561 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
562 fi
563mostlyclean-generic:
564
565clean-generic:
566
567distclean-generic:
568 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
569 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
570
571maintainer-clean-generic:
572 @echo "This command is intended for maintainers to use"
573 @echo "it deletes files that may require special tools to rebuild."
574clean: clean-am
575
576clean-am: clean-generic clean-libLTLIBRARIES clean-libtool clean-local \
577 mostlyclean-am
578
579distclean: distclean-am
580 -rm -rf ./$(DEPDIR)
581 -rm -f Makefile
582distclean-am: clean-am distclean-compile distclean-generic \
583 distclean-tags
584
585dvi: dvi-am
586
587dvi-am:
588
589html: html-am
590
591html-am:
592
593info: info-am
594
595info-am:
596
597install-data-am: install-includeHEADERS
598
599install-dvi: install-dvi-am
600
601install-dvi-am:
602
603install-exec-am: install-libLTLIBRARIES
604
605install-html: install-html-am
606
607install-html-am:
608
609install-info: install-info-am
610
611install-info-am:
612
613install-man:
614
615install-pdf: install-pdf-am
616
617install-pdf-am:
618
619install-ps: install-ps-am
620
621install-ps-am:
622
623installcheck-am:
624
625maintainer-clean: maintainer-clean-am
626 -rm -rf ./$(DEPDIR)
627 -rm -f Makefile
628maintainer-clean-am: distclean-am maintainer-clean-generic
629
630mostlyclean: mostlyclean-am
631
632mostlyclean-am: mostlyclean-compile mostlyclean-generic \
633 mostlyclean-libtool
634
635pdf: pdf-am
636
637pdf-am:
638
639ps: ps-am
640
641ps-am:
642
643uninstall-am: uninstall-includeHEADERS uninstall-libLTLIBRARIES
644
645.MAKE: install-am install-strip
646
647.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
648 clean-libLTLIBRARIES clean-libtool clean-local cscopelist-am \
649 ctags ctags-am distclean distclean-compile distclean-generic \
650 distclean-libtool distclean-tags distdir dvi dvi-am html \
651 html-am info info-am install install-am install-data \
652 install-data-am install-dvi install-dvi-am install-exec \
653 install-exec-am install-html install-html-am \
654 install-includeHEADERS install-info install-info-am \
655 install-libLTLIBRARIES install-man install-pdf install-pdf-am \
656 install-ps install-ps-am install-strip installcheck \
657 installcheck-am installdirs maintainer-clean \
658 maintainer-clean-generic mostlyclean mostlyclean-compile \
659 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
660 tags tags-am uninstall uninstall-am uninstall-includeHEADERS \
661 uninstall-libLTLIBRARIES
662
663default: simplehash.c libsimplehash.la
664all: simplehash.c libsimplehash.la
665
666simplehash.c: simplehashlib_kern.inc simplehash_kern.inc
667
668simplehashlib_kern.inc:
669 ./embed_source.pl simplehashlib_kern.cl > simplehashlib_kern.inc
670
671simplehash_kern.inc:
672 ./embed_source.pl simplehash_kern.cl > simplehash_kern.inc
673
674clean-local:
675 rm -f *.inc
676
677# Tell versions [3.59,3.63) of GNU make to not export all variables.
678# Otherwise a system limit (for SysV at least) may be exceeded.
679.NOEXPORT:
timer/CMakeLists.txt +50 -0
……@@ -0,0 +1,50 @@
1cmake_minimum_required(VERSION 2.6)
2
3set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
4# --- custom targets: ---
5if (NOT TARGET distclean)
6 INCLUDE( cmake/Modules/TargetDistclean.cmake OPTIONAL)
7endif (NOT TARGET distclean)
8
9# enable @rpath in the install name for any shared library being built
10set(CMAKE_MACOSX_RPATH 1)
11
12project (TIMER)
13# The version number.
14set (TIMER_VERSION_MAJOR 1)
15set (TIMER_VERSION_MINOR 2.0)
16set (TIMER_VERSION "${TIMER_VERSION_MAJOR}.${TIMER_VERSION_MINOR}")
17
18if (NOT CMAKE_BUILD_TYPE)
19 set(CMAKE_BUILD_TYPE RelWithDebInfo)
20endif(NOT CMAKE_BUILD_TYPE)
21
22# uncomment to build debug
23#set(CMAKE_BUILD_TYPE Debug)
24
25set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
26
27if (MIC_NATIVE)
28 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -static-intel -mmic")
29 link_directories("/projects/opt/intel/compilers/parallel_studio_xe_2013/composer_xe_2013_sp1.2.144/compiler/lib/mic")
30endif (MIC_NATIVE)
31
32set(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -Wall -g -O0 -Wextra")
33set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -g -O3")
34
35########### global settings ###############
36set(H_SRCS timer.h)
37set(C_SRCS timer.c)
38
39set(timer_LIB_SRCS ${C_SRCS} ${H_SRCS})
40
41########### timer target ###############
42add_library(timer SHARED ${timer_LIB_SRCS})
43
44set_target_properties(timer PROPERTIES VERSION ${TIMER_VERSION} SOVERSION ${TIMER_VERSION_MAJOR})
45install(TARGETS timer DESTINATION lib)
46
47########### install files ###############
48
49install(FILES timer.h DESTINATION include/timer)
50
timer/Makefile.am +0 -14
……@@ -1,14 +0,0 @@
1default: libtimer.la
2all: libtimer.la
3
4DEFAULT_INCLUDES=-I. -I..
5
6lib_LTLIBRARIES = libtimer.la
7include_HEADERS = timer.h
8
9H_SRCS = timer.h
10
11C_SRCS = timer.c
12
13libtimer_la_SOURCES = ${C_SRCS} ${H_SRCS}
14
timer/Makefile.in +0 -666
……@@ -1,666 +0,0 @@
1# Makefile.in generated by automake 1.13.4 from Makefile.am.
2# @configure_input@
3
4# Copyright (C) 1994-2013 Free Software Foundation, Inc.
5
6# This Makefile.in is free software; the Free Software Foundation
7# gives unlimited permission to copy and/or distribute it,
8# with or without modifications, as long as this notice is preserved.
9
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
12# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
13# PARTICULAR PURPOSE.
14
15@SET_MAKE@
16
17
18VPATH = @srcdir@
19am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
20am__make_running_with_option = \
21 case $${target_option-} in \
22 ?) ;; \
23 *) echo "am__make_running_with_option: internal error: invalid" \
24 "target option '$${target_option-}' specified" >&2; \
25 exit 1;; \
26 esac; \
27 has_opt=no; \
28 sane_makeflags=$$MAKEFLAGS; \
29 if $(am__is_gnu_make); then \
30 sane_makeflags=$$MFLAGS; \
31 else \
32 case $$MAKEFLAGS in \
33 *\\[\ \ ]*) \
34 bs=\\; \
35 sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
36 | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
37 esac; \
38 fi; \
39 skip_next=no; \
40 strip_trailopt () \
41 { \
42 flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
43 }; \
44 for flg in $$sane_makeflags; do \
45 test $$skip_next = yes && { skip_next=no; continue; }; \
46 case $$flg in \
47 *=*|--*) continue;; \
48 -*I) strip_trailopt 'I'; skip_next=yes;; \
49 -*I?*) strip_trailopt 'I';; \
50 -*O) strip_trailopt 'O'; skip_next=yes;; \
51 -*O?*) strip_trailopt 'O';; \
52 -*l) strip_trailopt 'l'; skip_next=yes;; \
53 -*l?*) strip_trailopt 'l';; \
54 -[dEDm]) skip_next=yes;; \
55 -[JT]) skip_next=yes;; \
56 esac; \
57 case $$flg in \
58 *$$target_option*) has_opt=yes; break;; \
59 esac; \
60 done; \
61 test $$has_opt = yes
62am__make_dryrun = (target_option=n; $(am__make_running_with_option))
63am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
64pkgdatadir = $(datadir)/@PACKAGE@
65pkgincludedir = $(includedir)/@PACKAGE@
66pkglibdir = $(libdir)/@PACKAGE@
67pkglibexecdir = $(libexecdir)/@PACKAGE@
68am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
69install_sh_DATA = $(install_sh) -c -m 644
70install_sh_PROGRAM = $(install_sh) -c
71install_sh_SCRIPT = $(install_sh) -c
72INSTALL_HEADER = $(INSTALL_DATA)
73transform = $(program_transform_name)
74NORMAL_INSTALL = :
75PRE_INSTALL = :
76POST_INSTALL = :
77NORMAL_UNINSTALL = :
78PRE_UNINSTALL = :
79POST_UNINSTALL = :
80build_triplet = @build@
81host_triplet = @host@
82subdir = timer
83DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
84 $(top_srcdir)/./config/depcomp $(include_HEADERS)
85ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
86am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
87 $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
88 $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
89 $(top_srcdir)/configure.ac
90am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
91 $(ACLOCAL_M4)
92mkinstalldirs = $(install_sh) -d
93CONFIG_CLEAN_FILES =
94CONFIG_CLEAN_VPATH_FILES =
95am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
96am__vpath_adj = case $$p in \
97 $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
98 *) f=$$p;; \
99 esac;
100am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
101am__install_max = 40
102am__nobase_strip_setup = \
103 srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
104am__nobase_strip = \
105 for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
106am__nobase_list = $(am__nobase_strip_setup); \
107 for p in $$list; do echo "$$p $$p"; done | \
108 sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
109 $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
110 if (++n[$$2] == $(am__install_max)) \
111 { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
112 END { for (dir in files) print dir, files[dir] }'
113am__base_list = \
114 sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
115 sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
116am__uninstall_files_from_dir = { \
117 test -z "$$files" \
118 || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
119 || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
120 $(am__cd) "$$dir" && rm -f $$files; }; \
121 }
122am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)"
123LTLIBRARIES = $(lib_LTLIBRARIES)
124libtimer_la_LIBADD =
125am__objects_1 = timer.lo
126am__objects_2 =
127am_libtimer_la_OBJECTS = $(am__objects_1) $(am__objects_2)
128libtimer_la_OBJECTS = $(am_libtimer_la_OBJECTS)
129AM_V_lt = $(am__v_lt_@AM_V@)
130am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
131am__v_lt_0 = --silent
132am__v_lt_1 =
133AM_V_P = $(am__v_P_@AM_V@)
134am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
135am__v_P_0 = false
136am__v_P_1 = :
137AM_V_GEN = $(am__v_GEN_@AM_V@)
138am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
139am__v_GEN_0 = @echo " GEN " $@;
140am__v_GEN_1 =
141AM_V_at = $(am__v_at_@AM_V@)
142am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
143am__v_at_0 = @
144am__v_at_1 =
145depcomp = $(SHELL) $(top_srcdir)/./config/depcomp
146am__depfiles_maybe = depfiles
147am__mv = mv -f
148COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
149 $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
150LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
151 $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
152 $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
153 $(AM_CFLAGS) $(CFLAGS)
154AM_V_CC = $(am__v_CC_@AM_V@)
155am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
156am__v_CC_0 = @echo " CC " $@;
157am__v_CC_1 =
158CCLD = $(CC)
159LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
160 $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
161 $(AM_LDFLAGS) $(LDFLAGS) -o $@
162AM_V_CCLD = $(am__v_CCLD_@AM_V@)
163am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
164am__v_CCLD_0 = @echo " CCLD " $@;
165am__v_CCLD_1 =
166SOURCES = $(libtimer_la_SOURCES)
167DIST_SOURCES = $(libtimer_la_SOURCES)
168am__can_run_installinfo = \
169 case $$AM_UPDATE_INFO_DIR in \
170 n|no|NO) false;; \
171 *) (install-info --version) >/dev/null 2>&1;; \
172 esac
173HEADERS = $(include_HEADERS)
174am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
175# Read a list of newline-separated strings from the standard input,
176# and print each of them once, without duplicates. Input order is
177# *not* preserved.
178am__uniquify_input = $(AWK) '\
179 BEGIN { nonempty = 0; } \
180 { items[$$0] = 1; nonempty = 1; } \
181 END { if (nonempty) { for (i in items) print i; }; } \
182'
183# Make sure the list of sources is unique. This is necessary because,
184# e.g., the same source file might be shared among _SOURCES variables
185# for different programs/libraries.
186am__define_uniq_tagged_files = \
187 list='$(am__tagged_files)'; \
188 unique=`for i in $$list; do \
189 if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
190 done | $(am__uniquify_input)`
191ETAGS = etags
192CTAGS = ctags
193DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
194ACLOCAL = @ACLOCAL@
195AMTAR = @AMTAR@
196AM_CPPFLAGS = @AM_CPPFLAGS@
197AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
198AR = @AR@
199AUTOCONF = @AUTOCONF@
200AUTOHEADER = @AUTOHEADER@
201AUTOMAKE = @AUTOMAKE@
202AWK = @AWK@
203CC = @CC@
204CCDEPMODE = @CCDEPMODE@
205CFLAGS = @CFLAGS@
206CPP = @CPP@
207CPPFLAGS = @CPPFLAGS@
208CPREPROCESSOR = @CPREPROCESSOR@
209CXX = @CXX@
210CXXCPP = @CXXCPP@
211CXXDEPMODE = @CXXDEPMODE@
212CXXFLAGS = @CXXFLAGS@
213CYGPATH_W = @CYGPATH_W@
214DEFS = @DEFS@
215DEPDIR = @DEPDIR@
216DLLTOOL = @DLLTOOL@
217DSYMUTIL = @DSYMUTIL@
218DUMPBIN = @DUMPBIN@
219ECHO_C = @ECHO_C@
220ECHO_N = @ECHO_N@
221ECHO_T = @ECHO_T@
222EGREP = @EGREP@
223EXEEXT = @EXEEXT@
224FGREP = @FGREP@
225GREP = @GREP@
226HAVE_ADDR2LINE = @HAVE_ADDR2LINE@
227INDENT = @INDENT@
228INSTALL = @INSTALL@
229INSTALL_DATA = @INSTALL_DATA@
230INSTALL_PROGRAM = @INSTALL_PROGRAM@
231INSTALL_SCRIPT = @INSTALL_SCRIPT@
232INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
233LD = @LD@
234LDFLAGS = @LDFLAGS@
235LIBOBJS = @LIBOBJS@
236LIBS = @LIBS@
237LIBTOOL = @LIBTOOL@
238LIPO = @LIPO@
239LN_S = @LN_S@
240LTLIBOBJS = @LTLIBOBJS@
241MAKEINFO = @MAKEINFO@
242MANIFEST_TOOL = @MANIFEST_TOOL@
243MKDIR_P = @MKDIR_P@
244NM = @NM@
245NMEDIT = @NMEDIT@
246OBJDUMP = @OBJDUMP@
247OBJEXT = @OBJEXT@
248OTOOL = @OTOOL@
249OTOOL64 = @OTOOL64@
250PACKAGE = @PACKAGE@
251PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
252PACKAGE_NAME = @PACKAGE_NAME@
253PACKAGE_STRING = @PACKAGE_STRING@
254PACKAGE_TARNAME = @PACKAGE_TARNAME@
255PACKAGE_URL = @PACKAGE_URL@
256PACKAGE_VERSION = @PACKAGE_VERSION@
257PATH_SEPARATOR = @PATH_SEPARATOR@
258RANLIB = @RANLIB@
259SED = @SED@
260SET_MAKE = @SET_MAKE@
261SHELL = @SHELL@
262STRIP = @STRIP@
263VERSION = @VERSION@
264abs_builddir = @abs_builddir@
265abs_srcdir = @abs_srcdir@
266abs_top_builddir = @abs_top_builddir@
267abs_top_srcdir = @abs_top_srcdir@
268ac_ct_AR = @ac_ct_AR@
269ac_ct_CC = @ac_ct_CC@
270ac_ct_CXX = @ac_ct_CXX@
271ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
272am__include = @am__include@
273am__leading_dot = @am__leading_dot@
274am__quote = @am__quote@
275am__tar = @am__tar@
276am__untar = @am__untar@
277bindir = @bindir@
278build = @build@
279build_alias = @build_alias@
280build_cpu = @build_cpu@
281build_os = @build_os@
282build_vendor = @build_vendor@
283builddir = @builddir@
284datadir = @datadir@
285datarootdir = @datarootdir@
286docdir = @docdir@
287dvidir = @dvidir@
288exec_prefix = @exec_prefix@
289host = @host@
290host_alias = @host_alias@
291host_cpu = @host_cpu@
292host_os = @host_os@
293host_vendor = @host_vendor@
294htmldir = @htmldir@
295includedir = @includedir@
296infodir = @infodir@
297install_sh = @install_sh@
298libdir = @libdir@
299libexecdir = @libexecdir@
300localedir = @localedir@
301localstatedir = @localstatedir@
302lspci_found = @lspci_found@
303mandir = @mandir@
304mkdir_p = @mkdir_p@
305oldincludedir = @oldincludedir@
306pdfdir = @pdfdir@
307prefix = @prefix@
308program_transform_name = @program_transform_name@
309psdir = @psdir@
310sbindir = @sbindir@
311sharedstatedir = @sharedstatedir@
312srcdir = @srcdir@
313sysconfdir = @sysconfdir@
314target_alias = @target_alias@
315top_build_prefix = @top_build_prefix@
316top_builddir = @top_builddir@
317top_srcdir = @top_srcdir@
318DEFAULT_INCLUDES = -I. -I..
319lib_LTLIBRARIES = libtimer.la
320include_HEADERS = timer.h
321H_SRCS = timer.h
322C_SRCS = timer.c
323libtimer_la_SOURCES = ${C_SRCS} ${H_SRCS}
324all: all-am
325
326.SUFFIXES:
327.SUFFIXES: .c .lo .o .obj
328$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
329 @for dep in $?; do \
330 case '$(am__configure_deps)' in \
331 *$$dep*) \
332 ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
333 && { if test -f $@; then exit 0; else break; fi; }; \
334 exit 1;; \
335 esac; \
336 done; \
337 echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign timer/Makefile'; \
338 $(am__cd) $(top_srcdir) && \
339 $(AUTOMAKE) --foreign timer/Makefile
340.PRECIOUS: Makefile
341Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
342 @case '$?' in \
343 *config.status*) \
344 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
345 *) \
346 echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
347 cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
348 esac;
349
350$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
351 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
352
353$(top_srcdir)/configure: $(am__configure_deps)
354 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
355$(ACLOCAL_M4): $(am__aclocal_m4_deps)
356 cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
357$(am__aclocal_m4_deps):
358
359install-libLTLIBRARIES: $(lib_LTLIBRARIES)
360 @$(NORMAL_INSTALL)
361 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
362 list2=; for p in $$list; do \
363 if test -f $$p; then \
364 list2="$$list2 $$p"; \
365 else :; fi; \
366 done; \
367 test -z "$$list2" || { \
368 echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \
369 $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \
370 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \
371 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \
372 }
373
374uninstall-libLTLIBRARIES:
375 @$(NORMAL_UNINSTALL)
376 @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
377 for p in $$list; do \
378 $(am__strip_dir) \
379 echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \
380 $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \
381 done
382
383clean-libLTLIBRARIES:
384 -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES)
385 @list='$(lib_LTLIBRARIES)'; \
386 locs=`for p in $$list; do echo $$p; done | \
387 sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
388 sort -u`; \
389 test -z "$$locs" || { \
390 echo rm -f $${locs}; \
391 rm -f $${locs}; \
392 }
393
394libtimer.la: $(libtimer_la_OBJECTS) $(libtimer_la_DEPENDENCIES) $(EXTRA_libtimer_la_DEPENDENCIES)
395 $(AM_V_CCLD)$(LINK) -rpath $(libdir) $(libtimer_la_OBJECTS) $(libtimer_la_LIBADD) $(LIBS)
396
397mostlyclean-compile:
398 -rm -f *.$(OBJEXT)
399
400distclean-compile:
401 -rm -f *.tab.c
402
403@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/timer.Plo@am__quote@
404
405.c.o:
406@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
407@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
408@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
409@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
410@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c $<
411
412.c.obj:
413@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
414@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
415@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
416@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
417@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c `$(CYGPATH_W) '$<'`
418
419.c.lo:
420@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
421@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
422@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
423@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
424@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
425
426mostlyclean-libtool:
427 -rm -f *.lo
428
429clean-libtool:
430 -rm -rf .libs _libs
431install-includeHEADERS: $(include_HEADERS)
432 @$(NORMAL_INSTALL)
433 @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \
434 if test -n "$$list"; then \
435 echo " $(MKDIR_P) '$(DESTDIR)$(includedir)'"; \
436 $(MKDIR_P) "$(DESTDIR)$(includedir)" || exit 1; \
437 fi; \
438 for p in $$list; do \
439 if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
440 echo "$$d$$p"; \
441 done | $(am__base_list) | \
442 while read files; do \
443 echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(includedir)'"; \
444 $(INSTALL_HEADER) $$files "$(DESTDIR)$(includedir)" || exit $$?; \
445 done
446
447uninstall-includeHEADERS:
448 @$(NORMAL_UNINSTALL)
449 @list='$(include_HEADERS)'; test -n "$(includedir)" || list=; \
450 files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
451 dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir)
452
453ID: $(am__tagged_files)
454 $(am__define_uniq_tagged_files); mkid -fID $$unique
455tags: tags-am
456TAGS: tags
457
458tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
459 set x; \
460 here=`pwd`; \
461 $(am__define_uniq_tagged_files); \
462 shift; \
463 if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
464 test -n "$$unique" || unique=$$empty_fix; \
465 if test $$# -gt 0; then \
466 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
467 "$$@" $$unique; \
468 else \
469 $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
470 $$unique; \
471 fi; \
472 fi
473ctags: ctags-am
474
475CTAGS: ctags
476ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
477 $(am__define_uniq_tagged_files); \
478 test -z "$(CTAGS_ARGS)$$unique" \
479 || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
480 $$unique
481
482GTAGS:
483 here=`$(am__cd) $(top_builddir) && pwd` \
484 && $(am__cd) $(top_srcdir) \
485 && gtags -i $(GTAGS_ARGS) "$$here"
486cscopelist: cscopelist-am
487
488cscopelist-am: $(am__tagged_files)
489 list='$(am__tagged_files)'; \
490 case "$(srcdir)" in \
491 [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
492 *) sdir=$(subdir)/$(srcdir) ;; \
493 esac; \
494 for i in $$list; do \
495 if test -f "$$i"; then \
496 echo "$(subdir)/$$i"; \
497 else \
498 echo "$$sdir/$$i"; \
499 fi; \
500 done >> $(top_builddir)/cscope.files
501
502distclean-tags:
503 -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
504
505distdir: $(DISTFILES)
506 @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
507 topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
508 list='$(DISTFILES)'; \
509 dist_files=`for file in $$list; do echo $$file; done | \
510 sed -e "s|^$$srcdirstrip/||;t" \
511 -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
512 case $$dist_files in \
513 */*) $(MKDIR_P) `echo "$$dist_files" | \
514 sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
515 sort -u` ;; \
516 esac; \
517 for file in $$dist_files; do \
518 if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
519 if test -d $$d/$$file; then \
520 dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
521 if test -d "$(distdir)/$$file"; then \
522 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
523 fi; \
524 if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
525 cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
526 find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
527 fi; \
528 cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
529 else \
530 test -f "$(distdir)/$$file" \
531 || cp -p $$d/$$file "$(distdir)/$$file" \
532 || exit 1; \
533 fi; \
534 done
535check-am: all-am
536check: check-am
537all-am: Makefile $(LTLIBRARIES) $(HEADERS)
538installdirs:
539 for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)"; do \
540 test -z "$$dir" || $(MKDIR_P) "$$dir"; \
541 done
542install: install-am
543install-exec: install-exec-am
544install-data: install-data-am
545uninstall: uninstall-am
546
547install-am: all-am
548 @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
549
550installcheck: installcheck-am
551install-strip:
552 if test -z '$(STRIP)'; then \
553 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
554 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
555 install; \
556 else \
557 $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
558 install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
559 "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
560 fi
561mostlyclean-generic:
562
563clean-generic:
564
565distclean-generic:
566 -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
567 -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
568
569maintainer-clean-generic:
570 @echo "This command is intended for maintainers to use"
571 @echo "it deletes files that may require special tools to rebuild."
572clean: clean-am
573
574clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \
575 mostlyclean-am
576
577distclean: distclean-am
578 -rm -rf ./$(DEPDIR)
579 -rm -f Makefile
580distclean-am: clean-am distclean-compile distclean-generic \
581 distclean-tags
582
583dvi: dvi-am
584
585dvi-am:
586
587html: html-am
588
589html-am:
590
591info: info-am
592
593info-am:
594
595install-data-am: install-includeHEADERS
596
597install-dvi: install-dvi-am
598
599install-dvi-am:
600
601install-exec-am: install-libLTLIBRARIES
602
603install-html: install-html-am
604
605install-html-am:
606
607install-info: install-info-am
608
609install-info-am:
610
611install-man:
612
613install-pdf: install-pdf-am
614
615install-pdf-am:
616
617install-ps: install-ps-am
618
619install-ps-am:
620
621installcheck-am:
622
623maintainer-clean: maintainer-clean-am
624 -rm -rf ./$(DEPDIR)
625 -rm -f Makefile
626maintainer-clean-am: distclean-am maintainer-clean-generic
627
628mostlyclean: mostlyclean-am
629
630mostlyclean-am: mostlyclean-compile mostlyclean-generic \
631 mostlyclean-libtool
632
633pdf: pdf-am
634
635pdf-am:
636
637ps: ps-am
638
639ps-am:
640
641uninstall-am: uninstall-includeHEADERS uninstall-libLTLIBRARIES
642
643.MAKE: install-am install-strip
644
645.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
646 clean-libLTLIBRARIES clean-libtool cscopelist-am ctags \
647 ctags-am distclean distclean-compile distclean-generic \
648 distclean-libtool distclean-tags distdir dvi dvi-am html \
649 html-am info info-am install install-am install-data \
650 install-data-am install-dvi install-dvi-am install-exec \
651 install-exec-am install-html install-html-am \
652 install-includeHEADERS install-info install-info-am \
653 install-libLTLIBRARIES install-man install-pdf install-pdf-am \
654 install-ps install-ps-am install-strip installcheck \
655 installcheck-am installdirs maintainer-clean \
656 maintainer-clean-generic mostlyclean mostlyclean-compile \
657 mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
658 tags tags-am uninstall uninstall-am uninstall-includeHEADERS \
659 uninstall-libLTLIBRARIES
660
661default: libtimer.la
662all: libtimer.la
663
664# Tell versions [3.59,3.63) of GNU make to not export all variables.
665# Otherwise a system limit (for SysV at least) may be exceeded.
666.NOEXPORT: