Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 357492 Details for
Bug 347931
Recent binutils eclass change to enable plugins breaks Gentoo/FreeBSD
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
backport patch from trunk
backport-fbsd.patch (text/plain), 8.89 KB, created by
Yuta SATOH
on 2013-08-31 10:57:13 UTC
(
hide
)
Description:
backport patch from trunk
Filename:
MIME Type:
Creator:
Yuta SATOH
Created:
2013-08-31 10:57:13 UTC
Size:
8.89 KB
patch
obsolete
>Replace -ldl with @lt_cv_dlopen_libs@ > >https://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/Makefile.am.diff?r1=1.265&r2=1.266&cvsroot=src >https://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/configure.in.diff?r1=1.319&r2=1.320&cvsroot=src >https://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/Makefile.in.diff?r1=1.294&r2=1.295&cvsroot=src >https://sourceware.org/cgi-bin/cvsweb.cgi/src/bfd/configure.diff?r1=1.373&r2=1.374&cvsroot=src > >Fix mingw gold build with plugins enabled >https://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/Makefile.am.diff?r1=1.69&r2=1.70&cvsroot=src >https://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/configure.ac.diff?r1=1.83&r2=1.84&cvsroot=src >https://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/plugin.cc.diff?r1=1.55&r2=1.56&cvsroot=src >https://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/Makefile.in.diff?r1=1.97&r2=1.98&cvsroot=src >https://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/config.in.diff?r1=1.36&r2=1.37&cvsroot=src >https://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/configure.diff?r1=1.85&r2=1.86&cvsroot=src >https://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/testsuite/Makefile.in.diff?r1=1.215&r2=1.216&cvsroot=src > > >=================================================================== >RCS file: /cvs/src/src/bfd/Makefile.am,v >retrieving revision 1.265 >retrieving revision 1.266 >diff -u -r1.265 -r1.266 >--- src/bfd/Makefile.am 2012/08/13 14:52:33 1.265 >+++ src/bfd/Makefile.am 2012/10/13 14:17:10 1.266 >@@ -35,7 +35,7 @@ > AM_CPPFLAGS = -DBINDIR='"$(bindir)"' > if PLUGINS > bfdinclude_HEADERS += $(INCDIR)/plugin-api.h >-LIBDL = -ldl >+LIBDL = @lt_cv_dlopen_libs@ > endif > > # bfd.h goes here, for now >=================================================================== >RCS file: /cvs/src/src/bfd/configure.in,v >retrieving revision 1.319 >retrieving revision 1.320 >diff -u -r1.319 -r1.320 >--- src/bfd/configure.in 2012/09/13 22:24:49 1.319 >+++ src/bfd/configure.in 2012/10/13 14:17:14 1.320 >@@ -1100,6 +1100,7 @@ > supports_plugins=0 > fi > AC_SUBST(supports_plugins) >+AC_SUBST(lt_cv_dlopen_libs) > > # Determine the host dependant file_ptr a.k.a. off_t type. In order > # prefer: off64_t - if ftello64 and fseeko64, off_t - if ftello and >=================================================================== >RCS file: /cvs/src/src/bfd/Makefile.in,v >retrieving revision 1.294 >retrieving revision 1.295 >diff -u -r1.294 -r1.295 >--- src/bfd/Makefile.in 2012/08/13 14:52:34 1.294 >+++ src/bfd/Makefile.in 2012/10/13 14:17:10 1.295 >@@ -293,6 +293,7 @@ > libexecdir = @libexecdir@ > localedir = @localedir@ > localstatedir = @localstatedir@ >+lt_cv_dlopen_libs = @lt_cv_dlopen_libs@ > mandir = @mandir@ > mkdir_p = @mkdir_p@ > oldincludedir = @oldincludedir@ >@@ -336,7 +337,7 @@ > @INSTALL_LIBBFD_FALSE@noinst_LTLIBRARIES = libbfd.la > AM_CFLAGS = $(WARN_CFLAGS) > AM_CPPFLAGS = -DBINDIR='"$(bindir)"' >-@PLUGINS_TRUE@LIBDL = -ldl >+@PLUGINS_TRUE@LIBDL = @lt_cv_dlopen_libs@ > > # bfd.h goes here, for now > BFD_H = bfd.h >=================================================================== >RCS file: /cvs/src/src/bfd/configure,v >retrieving revision 1.373 >retrieving revision 1.374 >diff -u -r1.373 -r1.374 >--- src/bfd/configure 2012/09/14 23:56:47 1.373 >+++ src/bfd/configure 2012/10/13 14:17:11 1.374 >@@ -606,6 +606,7 @@ > tdefaults > bfd_ufile_ptr > bfd_file_ptr >+lt_cv_dlopen_libs > supports_plugins > bfd_default_target_size > bfd_machines >@@ -15633,6 +15634,7 @@ > fi > > >+ > # Determine the host dependant file_ptr a.k.a. off_t type. In order > # prefer: off64_t - if ftello64 and fseeko64, off_t - if ftello and > # fseeko, long. This assumes that sizeof off_t is .ge. sizeof long. >=================================================================== >RCS file: /cvs/src/src/gold/Makefile.am,v >retrieving revision 1.69 >retrieving revision 1.70 >diff -u -r1.69 -r1.70 >--- src/gold/Makefile.am 2012/12/17 16:56:02 1.69 >+++ src/gold/Makefile.am 2013/01/11 14:36:36 1.70 >@@ -37,7 +38,7 @@ > LIBIBERTY = ../libiberty/libiberty.a > > if PLUGINS >-LIBDL = -ldl >+LIBDL = @DLOPEN_LIBS@ > endif > > if THREADS >=================================================================== >RCS file: /cvs/src/src/gold/configure.ac,v >retrieving revision 1.83 >retrieving revision 1.84 >diff -u -r1.83 -r1.84 >--- src/gold/configure.ac 2013/01/07 19:55:41 1.83 >+++ src/gold/configure.ac 2013/01/11 14:36:36 1.84 >@@ -505,6 +506,13 @@ > AC_CHECK_HEADERS(tr1/unordered_set tr1/unordered_map) > AC_CHECK_HEADERS(ext/hash_map ext/hash_set) > AC_CHECK_HEADERS(byteswap.h) >+ >+dnl When plugins enabled dynamic loader interface is required. Check headers >+dnl which may provide this interface. In case of dlfcn.h add libdl to link. >+AC_CHECK_HEADERS(windows.h) >+AC_CHECK_HEADERS(dlfcn.h, [DLOPEN_LIBS="-ldl"], [DLOPEN_LIBS=""]) >+AC_SUBST(DLOPEN_LIBS) >+ > AC_CHECK_FUNCS(mallinfo posix_fallocate fallocate readv sysconf times) > AC_CHECK_DECLS([basename, ffs, asprintf, vasprintf, snprintf, vsnprintf, strverscmp, strndup, memmem]) > >=================================================================== >RCS file: /cvs/src/src/gold/plugin.cc,v >retrieving revision 1.55 >retrieving revision 1.56 >diff -u -r1.55 -r1.56 >--- src/gold/plugin.cc 2012/08/24 18:35:34 1.55 >+++ src/gold/plugin.cc 2013/01/11 14:36:36 1.56 >@@ -29,9 +29,39 @@ > #include <vector> > > #ifdef ENABLE_PLUGINS >+#ifdef HAVE_DLFCN_H > #include <dlfcn.h> >+#elif defined (HAVE_WINDOWS_H) >+#include <windows.h> >+#else >+#error Unknown how to handle dynamic-load-libraries. > #endif > >+#if !defined (HAVE_DLFCN_H) && defined (HAVE_WINDOWS_H) >+ >+#define RTLD_NOW 0 /* Dummy value. */ >+static void * >+dlopen(const char *file, int mode ATTRIBUTE_UNUSED) >+{ >+ return LoadLibrary(file); >+} >+ >+static void * >+dlsym(void *handle, const char *name) >+{ >+ return reinterpret_cast<void *>( >+ GetProcAddress(static_cast<HMODULE>(handle),name)); >+} >+ >+static const char * >+dlerror(void) >+{ >+ return "unable to load dll"; >+} >+ >+#endif /* !defined (HAVE_DLFCN_H) && defined (HAVE_WINDOWS_H) */ >+#endif /* ENABLE_PLUGINS */ >+ > #include "parameters.h" > #include "errors.h" > #include "fileread.h" >=================================================================== >RCS file: /cvs/src/src/gold/Makefile.in,v >retrieving revision 1.97 >retrieving revision 1.98 >diff -u -r1.97 -r1.98 >--- src/gold/Makefile.in 2012/12/17 16:56:02 1.97 >+++ src/gold/Makefile.in 2013/01/11 14:36:36 1.98 >@@ -272,6 +273,7 @@ > DATADIRNAME = @DATADIRNAME@ > DEFS = @DEFS@ > DEPDIR = @DEPDIR@ >+DLOPEN_LIBS = @DLOPEN_LIBS@ > ECHO_C = @ECHO_C@ > ECHO_N = @ECHO_N@ > ECHO_T = @ECHO_T@ >@@ -398,7 +400,7 @@ > -DTOOLLIBDIR="\"$(tooldir)/lib\"" @INCINTL@ > > LIBIBERTY = ../libiberty/libiberty.a >-@PLUGINS_TRUE@LIBDL = -ldl >+@PLUGINS_TRUE@LIBDL = @DLOPEN_LIBS@ > @THREADS_TRUE@THREADSLIB = -lpthread > AM_YFLAGS = -d >=================================================================== >RCS file: /cvs/src/src/gold/config.in,v >retrieving revision 1.36 >retrieving revision 1.37 >diff -u -r1.36 -r1.37 >--- src/gold/config.in 2012/09/10 22:30:56 1.36 >+++ src/gold/config.in 2013/01/11 14:36:36 1.37 >@@ -73,6 +73,9 @@ > don't. */ > #undef HAVE_DECL_VSNPRINTF > >+/* Define to 1 if you have the <dlfcn.h> header file. */ >+#undef HAVE_DLFCN_H >+ > /* Define to 1 if you have the <ext/hash_map> header file. */ > #undef HAVE_EXT_HASH_MAP > >@@ -184,6 +187,9 @@ > /* Define to 1 if you have the <unistd.h> header file. */ > #undef HAVE_UNISTD_H > >+/* Define to 1 if you have the <windows.h> header file. */ >+#undef HAVE_WINDOWS_H >+ > /* Define to 1 if you have the <zlib.h> header file. */ > #undef HAVE_ZLIB_H > >=================================================================== >RCS file: /cvs/src/src/gold/configure,v >retrieving revision 1.85 >retrieving revision 1.86 >diff -u -r1.85 -r1.86 >--- src/gold/configure 2013/01/07 19:55:41 1.85 >+++ src/gold/configure 2013/01/11 14:36:36 1.86 >@@ -596,6 +596,7 @@ > MAINTAINER_MODE_TRUE > HAVE_PUBNAMES_FALSE > HAVE_PUBNAMES_TRUE >+DLOPEN_LIBS > CXXCPP > HAVE_ZLIB_FALSE > HAVE_ZLIB_TRUE >@@ -7139,6 +7140,35 @@ > > done > >+ >+for ac_header in windows.h >+do : >+ ac_fn_cxx_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default" >+if test "x$ac_cv_header_windows_h" = x""yes; then : >+ cat >>confdefs.h <<_ACEOF >+#define HAVE_WINDOWS_H 1 >+_ACEOF >+ >+fi >+ >+done >+ >+for ac_header in dlfcn.h >+do : >+ ac_fn_cxx_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default" >+if test "x$ac_cv_header_dlfcn_h" = x""yes; then : >+ cat >>confdefs.h <<_ACEOF >+#define HAVE_DLFCN_H 1 >+_ACEOF >+ DLOPEN_LIBS="-ldl" >+else >+ DLOPEN_LIBS="" >+fi >+ >+done >+ >+ >+ > for ac_func in mallinfo posix_fallocate fallocate readv sysconf times > do : > as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` >=================================================================== >RCS file: /cvs/src/src/gold/testsuite/Makefile.in,v >retrieving revision 1.215 >retrieving revision 1.216 >diff -u -r1.215 -r1.216 >--- src/gold/testsuite/Makefile.in 2013/01/10 00:18:15 1.215 >+++ src/gold/testsuite/Makefile.in 2013/01/11 14:36:36 1.216 >@@ -1878,6 +1878,7 @@ > DATADIRNAME = @DATADIRNAME@ > DEFS = @DEFS@ > DEPDIR = @DEPDIR@ >+DLOPEN_LIBS = @DLOPEN_LIBS@ > ECHO_C = @ECHO_C@ > ECHO_N = @ECHO_N@ > ECHO_T = @ECHO_T@ >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 347931
:
271799
|
295153
|
295155
|
357492
|
357496
|
363812
|
363814
|
363816