summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJacques Garrigue <garrigue at math.nagoya-u.ac.jp>2003-01-09 12:01:51 +0000
committerJacques Garrigue <garrigue at math.nagoya-u.ac.jp>2003-01-09 12:01:51 +0000
commitc86d5f231d656e6fb52f195d9de95041f6b546d5 (patch)
tree3aa0bd738713a8b8cce94bdc9c50fe72da7637fd
parent71409b5604f45f5afadb03be82d257bb112965cb (diff)
macosx and shared libraries
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@5379 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
-rwxr-xr-xconfigure31
1 files changed, 15 insertions, 16 deletions
diff --git a/configure b/configure
index e565a8761..f455d58f7 100755
--- a/configure
+++ b/configure
@@ -492,25 +492,14 @@ if test $withsharedlibs = "yes"; then
mksharedlibrpath="-rpath "
shared_libraries_supported=true;;
powerpc-apple-darwin*)
- if sh ./hasgot $dl_defs -i dlfcn.h; then
- mksharedlib="cc -bundle -flat_namespace -undefined suppress -o"
- bytecccompopts="$dl_defs $bytecccompopts"
- #sharedcccompopts="-fnocommon"
- dl_needs_underscore=true
- shared_libraries_supported=true;
- fi
- ;;
+ mksharedlib="cc -bundle -flat_namespace -undefined suppress -o"
+ bytecccompopts="$dl_defs $bytecccompopts"
+ #sharedcccompopts="-fnocommon"
+ dl_needs_underscore=true
+ shared_libraries_supported=true;;
esac
fi
-if $shared_libraries_supported; then
- echo "Dynamic loading of shared libraries is supported."
- echo "#define SUPPORT_DYNAMIC_LINKING" >> s.h
- if $dl_needs_underscore; then
- echo '#define DL_NEEDS_UNDERSCORE' >>s.h
- fi
-fi
-
# Further machine-specific hacks
case "$host" in
@@ -950,6 +939,16 @@ elif sh ./hasgot $dllib dlopen; then
elif sh ./hasgot $dllib -ldl dlopen; then
echo "dlopen() found in -ldl."
dllib="$dllib -ldl"
+else
+ shared_libraries_supported=no
+fi
+
+if $shared_libraries_supported; then
+ echo "Dynamic loading of shared libraries is supported."
+ echo "#define SUPPORT_DYNAMIC_LINKING" >> s.h
+ if $dl_needs_underscore; then
+ echo '#define DL_NEEDS_UNDERSCORE' >>s.h
+ fi
fi
if sh ./hasgot -i sys/types.h -i sys/mman.h && sh ./hasgot mmap munmap; then