From a992ed442a525cbf85a4c3ecc4b7a88f07d0124e Mon Sep 17 00:00:00 2001 From: joerg Date: Fri, 30 Dec 2005 14:18:51 +0000 Subject: Add DragonFly support. Fix isnan and isinf detection. --- lang/gauche/distinfo | 7 ++- lang/gauche/patches/patch-aa | 120 +++++++++++++++++++++++++++++++++++++++++++ lang/gauche/patches/patch-ab | 13 +++++ lang/gauche/patches/patch-ac | 13 +++++ lang/gauche/patches/patch-ad | 13 +++++ lang/gauche/patches/patch-ae | 47 +++++++++++++++++ 6 files changed, 212 insertions(+), 1 deletion(-) create mode 100644 lang/gauche/patches/patch-aa create mode 100644 lang/gauche/patches/patch-ab create mode 100644 lang/gauche/patches/patch-ac create mode 100644 lang/gauche/patches/patch-ad create mode 100644 lang/gauche/patches/patch-ae (limited to 'lang') diff --git a/lang/gauche/distinfo b/lang/gauche/distinfo index 78a2e245db5..d90623db888 100644 --- a/lang/gauche/distinfo +++ b/lang/gauche/distinfo @@ -1,5 +1,10 @@ -$NetBSD: distinfo,v 1.17 2005/12/09 15:38:54 uebayasi Exp $ +$NetBSD: distinfo,v 1.18 2005/12/30 14:18:51 joerg Exp $ SHA1 (Gauche-0.8.6.tgz) = 8ce200011da2eff925c8ccf65502529df379f2b8 RMD160 (Gauche-0.8.6.tgz) = e6986c2602926b6a5c16a41838212bd041a4fbae Size (Gauche-0.8.6.tgz) = 2881800 bytes +SHA1 (patch-aa) = 6d3d5c1024fece9563294a3fbc488f757231499c +SHA1 (patch-ab) = 7c05e4e266078903871e13084c217ba6930275ce +SHA1 (patch-ac) = 7e5e0056f6e1cf685edf8dd0bd5b7ea87b05348c +SHA1 (patch-ad) = 25d6ed22d3a3d8d0360575ab8be5c5f1f0cf447e +SHA1 (patch-ae) = 0f76f4ba32b21d9c34335713e17bac70b8f8f9fd diff --git a/lang/gauche/patches/patch-aa b/lang/gauche/patches/patch-aa new file mode 100644 index 00000000000..62d67d3b9fe --- /dev/null +++ b/lang/gauche/patches/patch-aa @@ -0,0 +1,120 @@ +$NetBSD: patch-aa,v 1.5 2005/12/30 14:18:52 joerg Exp $ + +--- configure.orig 2005-11-05 01:00:47.000000000 +0000 ++++ configure +@@ -1631,7 +1631,7 @@ _ACEOF + + THREADLIBS="-lpthread -lrt" + ;; +- *-*-freebsd*) ++ *-*-freebsd*|*-*-dragonfly*) + { echo "$as_me:$LINENO: WARNING: \"FreeBSD does not yet fully support threads with Boehm GC.\"" >&5 + echo "$as_me: WARNING: \"FreeBSD does not yet fully support threads with Boehm GC.\"" >&2;} + +@@ -7238,7 +7238,72 @@ fi + + + +-for ac_func in isnan isinf trunc rint ++for ac_func in isnan isinf ++do ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++#include ++ ++double val; ++ ++int ++main () ++{ ++return $ac_func (val); ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_c_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ eval "$as_ac_var=yes" ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++eval "$as_ac_var=no" ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 ++_ACEOF ++ ++fi ++done ++ ++for ac_func in trunc rint + do + as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` + echo "$as_me:$LINENO: checking for $ac_func" >&5 +@@ -8878,7 +8943,7 @@ case $target in + SHLIB_MAIN_LDFLAGS="" + SHLIB_OK=ok + ;; +- *-linux-gnu|*freebsd*) ++ *-linux-gnu|*freebsd*|*dragonfly*) + SHLIB_SO_CFLAGS="-fPIC" + SHLIB_SO_LDFLAGS="$rpath -shared -o" + SHLIB_SO_SUFFIX="so" +@@ -10097,12 +10162,12 @@ fi + echo "$as_me:$LINENO: result: $ac_cv_lib_gdbm_gdbm_open" >&5 + echo "${ECHO_T}$ac_cv_lib_gdbm_gdbm_open" >&6 + if test $ac_cv_lib_gdbm_gdbm_open = yes; then +- GDBMLIB="-lgdbm" ++ GDBMLIB="-Wl,-R/usr/pkg/lib -lgdbm" + fi + + LIBSAVE="$LIBS" + if test "$NDBM_HEADER" = "gdbm/ndbm.h"; then +- NDBMLIB="-lgdbm" # use emulation by gdbm ++ NDBMLIB="-Wl,-R/usr/pkg/lib -lgdbm" # use emulation by gdbm + else + echo "$as_me:$LINENO: checking for library containing dbm_open" >&5 + echo $ECHO_N "checking for library containing dbm_open... $ECHO_C" >&6 +@@ -10232,7 +10297,7 @@ fi + + fi + if test "$ODBM_HEADER" = "gdbm/dbm.h"; then +- ODBMLIB="-lgdbm" # use emulation by gdbm ++ ODBMLIB="-Wl,-R/usr/pkg/lib -lgdbm" # use emulation by gdbm + else + echo "$as_me:$LINENO: checking for library containing dbminit" >&5 + echo $ECHO_N "checking for library containing dbminit... $ECHO_C" >&6 diff --git a/lang/gauche/patches/patch-ab b/lang/gauche/patches/patch-ab new file mode 100644 index 00000000000..f3e02ed8d65 --- /dev/null +++ b/lang/gauche/patches/patch-ab @@ -0,0 +1,13 @@ +$NetBSD: patch-ab,v 1.5 2005/12/30 14:18:52 joerg Exp $ + +--- gc/include/private/gcconfig.h.orig 2005-12-30 13:34:26.000000000 +0000 ++++ gc/include/private/gcconfig.h +@@ -55,7 +55,7 @@ + # endif + + /* And one for FreeBSD: */ +-# if defined(__FreeBSD__) && !defined(FREEBSD) ++# if (defined(__FreeBSD__) || defined(__DragonFly__)) && !defined(FREEBSD) + # define FREEBSD + # endif + diff --git a/lang/gauche/patches/patch-ac b/lang/gauche/patches/patch-ac new file mode 100644 index 00000000000..5643f6259c7 --- /dev/null +++ b/lang/gauche/patches/patch-ac @@ -0,0 +1,13 @@ +$NetBSD: patch-ac,v 1.6 2005/12/30 14:18:52 joerg Exp $ + +--- gc/include/gc_config_macros.h.orig 2005-12-30 13:35:00.000000000 +0000 ++++ gc/include/gc_config_macros.h +@@ -87,7 +87,7 @@ + # define GC_DARWIN_THREADS + # define GC_PTHREADS + # endif +-# if !defined(GC_PTHREADS) && defined(__FreeBSD__) ++# if !defined(GC_PTHREADS) && (defined(__FreeBSD__) || defined(__DragonFly__)) + # define GC_FREEBSD_THREADS + # define GC_PTHREADS + # endif diff --git a/lang/gauche/patches/patch-ad b/lang/gauche/patches/patch-ad new file mode 100644 index 00000000000..42122aba728 --- /dev/null +++ b/lang/gauche/patches/patch-ad @@ -0,0 +1,13 @@ +$NetBSD: patch-ad,v 1.7 2005/12/30 14:18:52 joerg Exp $ + +--- gc/include/gc.h.orig 2005-12-30 13:35:27.000000000 +0000 ++++ gc/include/gc.h +@@ -497,7 +497,7 @@ GC_API GC_PTR GC_malloc_atomic_ignore_of + /* This may also be desirable if it is possible but expensive to */ + /* retrieve the call chain. */ + #if (defined(__linux__) || defined(__NetBSD__) || defined(__OpenBSD__) \ +- || defined(__FreeBSD__)) & !defined(GC_CAN_SAVE_CALL_STACKS) ++ || defined(__FreeBSD__) || defined(__DragonFly__)) & !defined(GC_CAN_SAVE_CALL_STACKS) + # define GC_ADD_CALLER + # if __GNUC__ >= 3 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95) + /* gcc knows how to retrieve return address, but we don't know */ diff --git a/lang/gauche/patches/patch-ae b/lang/gauche/patches/patch-ae new file mode 100644 index 00000000000..87b2decde79 --- /dev/null +++ b/lang/gauche/patches/patch-ae @@ -0,0 +1,47 @@ +$NetBSD: patch-ae,v 1.10 2005/12/30 14:18:52 joerg Exp $ + +--- gc/configure.orig 2005-11-05 01:00:49.000000000 +0000 ++++ gc/configure +@@ -4030,7 +4030,7 @@ _ACEOF + fi + THREADDLLIBS="-lpthread -lrt" + ;; +- *-*-freebsd*) ++ *-*-freebsd* | *-*-dragonfly*) + { echo "$as_me:$LINENO: WARNING: \"FreeBSD does not yet fully support threads with Boehm GC.\"" >&5 + echo "$as_me: WARNING: \"FreeBSD does not yet fully support threads with Boehm GC.\"" >&2;} + cat >>confdefs.h <<\_ACEOF +@@ -4698,13 +4698,13 @@ darwin* | rhapsody*) + esac + ;; + +-freebsd*) ++freebsd* | dragonfly*) + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then + case $host_cpu in + i*86 ) + # Not sure whether the presence of OpenBSD here was a mistake. + # Let's accept both of them until this is cleared up. +- lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library' ++ lt_cv_deplibs_check_method='file_magic (DragonFly|FreeBSD|OpenBSD)/i[3-9]86 (compact )?demand paged shared library' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` + ;; +@@ -7200,7 +7200,7 @@ else + ;; + + # FreeBSD 3 and greater uses gcc -shared to do shared libraries. +- freebsd*) ++ freebsd* | dragonfly*) + archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' + hardcode_libdir_flag_spec='-R$libdir' + hardcode_direct=yes +@@ -7659,7 +7659,7 @@ freebsd1*) + dynamic_linker=no + ;; + +-freebsd*) ++freebsd* | dragonfly*) + objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` + version_type=freebsd-$objformat + case $version_type in -- cgit v1.2.3