This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH: binutils breaks on x64-pc-mingw32


On Wed, Aug 29, 2007 at 07:53:25PM -0400, NightStrike wrote:
> H. J. Lu,
> 
> I noticed that you checked in a number of patches recently that make
> changes in i386-dis.c.  The current version of binutils from cvs no
> longer builds with the following error:
> 
> $ ../src/configure --target=x86_64-pc-mingw32 --prefix=/cygdrive/m
> --with-sysroot=/cygdrive/m --disable-nls > /dev/null
> $ make > /dev/null
> libtool: link: warning: undefined symbols not allowed in
> i686-pc-cygwin shared libraries
> ../../src/opcodes/i386-dis.c: In function `print_insn':
> ../../src/opcodes/i386-dis.c:3934: warning: implicit declaration of
> function `stpcpy'
> make[4]: *** [i386-dis.lo] Error 1
> make[3]: *** [all-recursive] Error 1
> make[2]: *** [all] Error 2
> make[1]: *** [all-opcodes] Error 2
> make: *** [all] Error 2
> 

Can you try this patch?


H.J.
---
2007-08-29  H.J. Lu  <hongjiu.lu@intel.com>

	* configure.in (AC_GNU_SOURCE): Added.
	(AC_CHECK_DECLS): Add stpcpy.
	* config.in: Regenerated.
	* configure: Likewise.

--- opcodes/config.in.str	2007-07-02 06:54:31.000000000 -0700
+++ opcodes/config.in	2007-08-29 18:24:36.000000000 -0700
@@ -8,6 +8,10 @@
    don't. */
 #undef HAVE_DECL_BASENAME
 
+/* Define to 1 if you have the declaration of `stpcpy', and to 0 if you don't.
+   */
+#undef HAVE_DECL_STPCPY
+
 /* Define to 1 if you have the <dlfcn.h> header file. */
 #undef HAVE_DLFCN_H
 
--- opcodes/configure.in.str	2007-06-30 09:28:12.000000000 -0700
+++ opcodes/configure.in	2007-08-29 19:27:42.000000000 -0700
@@ -17,6 +17,8 @@ changequote([,])dnl
 
 AM_INIT_AUTOMAKE(opcodes, ${BFD_VERSION})
 
+AC_GNU_SOURCE
+
 dnl These must be called before AM_PROG_LIBTOOL, because it may want
 dnl to call AC_CHECK_PROG.
 AC_CHECK_TOOL(AR, ar)
@@ -73,7 +75,7 @@ AC_PROG_INSTALL
 
 AC_CHECK_HEADERS(string.h strings.h stdlib.h)
 
-AC_CHECK_DECLS(basename)
+AC_CHECK_DECLS([basename, stpcpy])
 
 cgen_maint=no
 cgendir='$(srcdir)/../cgen'


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]