diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | configure.in | 10 |
2 files changed, 13 insertions, 3 deletions
@@ -1,3 +1,9 @@ +Mon Jul 30 13:11:20 2012 Nobuyoshi Nakada <nobu@ruby-lang.org> + + * configure.in (LIBRUBY_RELATIVE): libruby_so is not made when + disable-shared, so no absolute path is used for it and executable + file is runnable anywhere. + Mon Jul 30 01:30:10 2012 CHIKANAGA Tomoyuki <nagachika@ruby-lang.org> * common.mk: add a dependency. [ruby-core:46741] [Bug #6789] diff --git a/configure.in b/configure.in index 3bb58b3d39..9041b9c509 100644 --- a/configure.in +++ b/configure.in @@ -2405,10 +2405,13 @@ if test "$rb_cv_dlopen:$load_relative" = yes:yes; then AC_CHECK_FUNCS(dladdr) if test "$ac_cv_func_dladdr" = yes; then LOAD_RELATIVE=1 - else - unset load_relative fi fi +if test x"$LOAD_RELATIVE" = x1; then + load_relative=yes +else + unset load_relative +fi len=2 # .rb n=`expr "$DLEXT" : '.*'`; test "$n" -gt "$len" && len=$n @@ -2542,11 +2545,12 @@ AC_ARG_ENABLE(shared, AS_HELP_STRING([--enable-shared], [build a shared library for Ruby]), [enable_shared=$enableval]) libprefix='$(libdir)' -LIBRUBY_RELATIVE=no +LIBRUBY_RELATIVE=${load_relative-no} AS_CASE("$enable_shared", [yes], [ LIBRUBY='$(LIBRUBY_SO)' LIBRUBYARG_SHARED='-l$(RUBY_SO_NAME)' LIBRUBYARG='$(LIBRUBYARG_SHARED)' + LIBRUBY_RELATIVE=no test -z "$CCDLFLAGS" || CFLAGS="$CFLAGS $CCDLFLAGS" ENABLE_SHARED=yes if test "$rb_cv_binary_elf" = yes; then |