From a2ec07f1d11c1279cc9f05e010518d0b481ba4d7 Mon Sep 17 00:00:00 2001 From: usa Date: Sun, 2 Dec 2001 18:33:10 +0000 Subject: [PATCH] * configure.in: apply patch from NetBSD's pkgsrc (patch-aa). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1874 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 4 ++++ configure.in | 26 ++++++++++++-------------- 2 files changed, 16 insertions(+), 14 deletions(-) diff --git a/ChangeLog b/ChangeLog index 8de6cba944..abed3f0078 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Mon Dec 3 03:32:22 2001 Usaku Nakamura + + * configure.in: apply patch from NetBSD's pkgsrc (patch-aa). + Sun Dec 2 22:01:52 2001 WATANABE Hirofumi * configure.in: use GCC, not without_gcc. remove without_gcc. diff --git a/configure.in b/configure.in index 57aee10315..955720a5e5 100644 --- a/configure.in +++ b/configure.in @@ -559,12 +559,7 @@ if test "$with_dln_a_out" != yes; then beos*) ;; cygwin*) ;; mingw*) ;; - netbsd*) CCDLFLAGS=-fpic - case "$target_cpu" in - mips*) CCDLFLAGS=-fPIC ;; - sparc) CCDLFLAGS=-fPIC ;; - *) ;; - esac ;; + netbsd*) CCDLFLAGS=-fPIC;; *) CCDLFLAGS=-fPIC;; esac else @@ -611,10 +606,8 @@ if test "$with_dln_a_out" != yes; then test "$GCC" = yes && `$CC --print-prog-name=ld` -v 2>&1 | grep "GNU ld" > /dev/null || LDSHARED="ld -Bshareable" fi rb_cv_dlopen=yes ;; - netbsd*) LDSHARED="ld -shared" - if test "$rb_cv_binary_elf" = yes; then - LDFLAGS="-export-dynamic" - fi + netbsd*) LDSHARED='${CC} -shared' + LDFLAGS="" rb_cv_dlopen=yes ;; openbsd*) LDSHARED="ld -Bforcearchive -Bshareable" rb_cv_dlopen=yes ;; @@ -885,11 +878,13 @@ if test "$enable_shared" = 'yes'; then ;; netbsd*) SOLIBS='$(LIBS)' - LIBRUBY_SO='lib$(RUBY_INSTALL_NAME).so.$(MAJOR).$(MINOR)' + LIBRUBY_SO='lib$(RUBY_INSTALL_NAME).so.$(MAJOR)$(MINOR).$(TEENY)' + LIBRUBY_DLDFLAGS='-Wl,-soname,lib$(RUBY_INSTALL_NAME).so.$(MAJOR)$(MINOR)' + LIBRUBYARG='-Wl,-R -Wl,${prefix}/lib -L${prefix}/lib -L. -l$(RUBY_INSTALL_NAME) -Wl,-R -Wl,${X11BASE}/lib -L${X11BASE}/lib' if test "$rb_cv_binary_elf" = yes; then # ELF platforms - LIBRUBY_ALIASES='lib$(RUBY_INSTALL_NAME).so.$(MAJOR) lib$(RUBY_INSTALL_NAME).so' - else - LIBRUBY_ALIASES= # a.out platforms + LIBRUBY_ALIASES='lib$(RUBY_INSTALL_NAME).so.$(MAJOR)$(MINOR) lib$(RUBY_INSTALL_NAME).so' + else # a.out platforms + LIBRUBY_ALIASES="" fi ;; openbsd*) @@ -933,6 +928,9 @@ if test "$enable_shared" = 'yes'; then fi case "$target_os" in + netbsd*) + CFLAGS="$CFLAGS -pipe" + ;; nextstep*) CFLAGS="$CFLAGS -pipe" ;;