1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* Makefile.in (EXTLDFLAGS): export it.

* configure.in: add --no-undefined if --enable-shared is specified.
  Gentoo enabled this option long time. Also, export EXTLDFALGS.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33838 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
kosaki 2011-11-25 01:41:59 +00:00
parent 98975ba9dc
commit 0996ae361a
3 changed files with 13 additions and 1 deletions

View file

@ -1,3 +1,9 @@
Fri Nov 25 10:39:14 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com>
* Makefile.in (EXTLDFLAGS): export it.
* configure.in: add --no-undefined if --enable-shared is specified.
Gentoo enabled this option long time. Also, export EXTLDFALGS.
Fri Nov 25 08:48:35 2011 KOSAKI Motohiro <kosaki.motohiro@gmail.com>
* configure.in: turn on PIE if --enable-shared is not specified.

View file

@ -57,7 +57,7 @@ INCFLAGS = -I. -I$(arch_hdrdir) -I$(hdrdir) -I$(srcdir)
XCFLAGS = @XCFLAGS@
CPPFLAGS = @CPPFLAGS@ $(INCFLAGS)
LDFLAGS = @STATIC@ $(CFLAGS) @LDFLAGS@
EXTLDFLAGS =
EXTLDFLAGS = @EXTLDFLAGS@
XLDFLAGS = @XLDFLAGS@ $(EXTLDFLAGS)
EXTLIBS =
LIBS = @LIBS@ $(EXTLIBS)

View file

@ -2266,6 +2266,11 @@ AS_CASE("$enable_shared", [yes], [
if test "$rb_cv_binary_elf" = yes; then
SOLIBS='$(LIBS)'
fi
if test "$GCC" = yes; then
RUBY_TRY_CFLAGS(-Xlinker --no-undefined, RUBY_APPEND_OPTION(EXTLDFLAGS, -Xlinker --no-undefined))
fi
AS_CASE(["$target_os"],
[sunos4*], [
LIBRUBY_ALIASES='lib$(RUBY_SO_NAME).so.$(MAJOR).$(MINOR) lib$(RUBY_SO_NAME).so'
@ -2613,6 +2618,7 @@ AC_SUBST(debugflags)dnl
AC_SUBST(warnflags)dnl
AC_SUBST(XCFLAGS)dnl
AC_SUBST(XLDFLAGS)dnl
AC_SUBST(EXTLDFLAGS)dnl
AC_SUBST(LIBRUBY_LDSHARED)
AC_SUBST(LIBRUBY_DLDFLAGS)
AC_SUBST(RUBY_INSTALL_NAME)