# HG changeset patch # User james # Date 1063332127 0 # Node ID 2422c1cd1afd4c8e83b6e8a53471e6d5dbec9a0a # Parent c28d1cb3107df30ec6307c407ba7c2a5c70755a3 [xemacs-hg @ 2003-09-12 02:02:06 by james] Andrew Begel's patch to make modules build correctly on MacOS X. diff -r c28d1cb3107d -r 2422c1cd1afd ChangeLog --- a/ChangeLog Thu Sep 11 21:52:39 2003 +0000 +++ b/ChangeLog Fri Sep 12 02:02:07 2003 +0000 @@ -1,3 +1,9 @@ +2003-05-10 Andrew Begel + + * aclocal.m4 (XE_SHLIB_STUFF): Use -bundle when testing the + ability to build shared libraries, but use -bundle_loader in + ellcc. Properly handle other flags for MacOS X. + 2003-09-03 Steve Youngs * XEmacs 21.5.15 "celery" is released. diff -r c28d1cb3107d -r 2422c1cd1afd aclocal.m4 --- a/aclocal.m4 Thu Sep 11 21:52:39 2003 +0000 +++ b/aclocal.m4 Fri Sep 12 02:02:07 2003 +0000 @@ -92,6 +92,9 @@ # PIC is the default for these OSes. ;; + *darwin*) dll_cflags='-dynamic' + ;; + os2*) # We can build DLLs from non-PIC. ;; @@ -244,8 +247,16 @@ xcldf= AC_MSG_CHECKING(if C compiler can produce shared libraries) if test "$XEGCC" = yes; then - xcldf="-shared" - xldf="-shared" + case "$xehost_os" in + *darwin*) + xcldf='-bundle' + xldf='-bundle -bundle_loader ../../src/xemacs' + ;; + *) + xcldf="-shared" + xldf="-shared" + ;; + esac else # Not using GCC case "$xehost_os" in aix[[3-9]]*) @@ -393,7 +404,15 @@ if test "$cc_produces_so" = "yes"; then dll_ld=$CC - dll_ldflags=$xcldf + case "$xehost_os" in + *darwin*) + dnl On Darwin, we test with xcldf, but we use xldf + dll_ldflags=$xldf + ;; + *) + dll_ldflags=$xcldf + ;; + esac can_build_shared=yes ld_shlibs=yes else @@ -542,6 +561,10 @@ ld_dynamic_link_flags= ;; + *darwin*) + ld_dynamic_link_flags= + ;; + freebsd2.2*) ld_dynamic_link_flags= ;;