[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: libidn-1.23 bug in lib/Makefile cross-building for Windows
From: |
Simon Josefsson |
Subject: |
Re: libidn-1.23 bug in lib/Makefile cross-building for Windows |
Date: |
Mon, 19 Dec 2011 14:25:48 +0100 |
User-agent: |
Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.92 (gnu/linux) |
René Berber <address@hidden> writes:
> Hello,
>
> I'm trying to cross-build libidn version 1.23, and I seem to have run
> into a bug.
>
> In file lib/Makefile there is:
>
> am__append_5 = -Wl,--output-def,libidn-$(DLL_VERSION).def
> ...
> libidn_la_LDFLAGS = -version-info \
> $(LT_CURRENT):$(LT_REVISION):$(LT_AGE) -no-undefined \
> $(am__append_3) $(am__append_4) $(am__append_5)
> ...
> defexec_DATA = libidn-$(DLL_VERSION).def
> ...
> install-defexecDATA: $(defexec_DATA)
> ...
>
> The last rule depends on the .def file, but libidn_la_LDFLAGS is not
> used, so the .def file is not built.
>
> Where am I seeing this? Gentoo Linux, using crossdev with a
> x86_64-w64-mingw32 target.
Hello and thanks for the bug report. The above code is generated from
this Makefile.am snippet:
if HAVE_LD_OUTPUT_DEF
libidn_la_LDFLAGS += -Wl,--output-def,libidn-$(DLL_VERSION).def
defexecdir = $(bindir)
defexec_DATA = libidn-$(DLL_VERSION).def
DISTCLEANFILES += $(defexec_DATA)
endif
It appears correct in the sense that libidn-X.def will only be installed
if -Wl,--output-def,libidn-X.def was passed when building the library.
Is support for -Wl,--output-def detected properly on your platform?
There should be a message like 'checking if gcc/ld supports
-Wl,--output-def' when you run ./configure.
If you remove lib/libidn.la and type 'make -C lib V=99' how do the
commands look like? It should pass -Wl,--output-def,libidn-X.def to the
linker.
If the -Wl,--output-def,libidn-X.def parameter is passed to the linker
properly, and the file is not generated, it seems like a bug in the
compiler.
FWIW, I'm cross-compiling the Libidn binaries using MinGW-64 as well,
and I haven't seen this problem before.
Could it be a build ordering issue? Are you trying to install
libidn-X.def before the library has been built perhaps?
/Simon