libtool
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: windres on mingw32 and cygwin


From: Jason Curl
Subject: Re: windres on mingw32 and cygwin
Date: Sat, 13 Dec 2008 18:33:58 +0100
User-agent: Thunderbird 2.0.0.18 (Windows/20081105)

Bob Friesenhahn wrote:
On Sat, 13 Dec 2008, Jason Curl wrote:

My next woe when porting over to libtool-2.x. It looks like the compilation phase of libtool has changed for resources. The shared library works, but the static library build on mingw32/cygwin no longer works.

If this is supposedly a static build then why is the -shared option being passed to GCC?
Just to make sure I didn't screw up, I rebuilt the package. The "configure" script wasn't told anything different so it builds both static and shared. So the first line is the shared library build (which works, it finds .libs/rsrc.o) but the static build fails.

Before I migrated over to libtool-2.2.x, I used the tag=CC to compile resources (without telling libtool at all anything about windres). Now I use RC and it breaks (after LT_LANG([Windows Resource])). Just checking and the tag=CC doesn't work with libtool 2.2.x (it almost the right thing when compiling, but linking later fails with lt-version.c)
/bin/sh ../../libtool   --tag=CC --mode=compile windres  rsrc.rc -o rsrc.lo
libtool: compile:  windres rsrc.rc  -DDLL_EXPORT -DPIC -o .libs/rsrc.o
libtool: compile:  windres rsrc.rc -o rsrc.o >/dev/null 2>&1

Here's the complete output:
$ ./configure --host=i686-pc-mingw32 && make
configure: WARNING: If you wanted to set the --build type, don't use --host.
   If a cross compiler is detected then cross compile mode will be used.
checking build system type... i686-pc-cygwin
checking host system type... i686-pc-mingw32
checking target system type... i686-pc-mingw32
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for i686-pc-mingw32-strip... no
checking for strip... strip
checking whether to enable maintainer-specific portions of Makefiles... no
checking for style of include used by make... GNU
checking for i686-pc-mingw32-gcc... no
checking for gcc... gcc
checking for C compiler default output file name... a.exe
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... .exe
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define __EXTENSIONS__... yes
checking for i686-pc-mingw32-gcc... gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking dependency style of gcc... (cached) gcc3
checking for a BSD-compatible install... /usr/bin/install -c
checking whether make sets $(MAKE)... (cached) yes
checking for ANSI C header files... (cached) yes
checking for a sed that does not truncate output... /usr/bin/sed
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc... /usr/i686-pc-cygwin/bin/ld.exe
checking if the linker (/usr/i686-pc-cygwin/bin/ld.exe) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... no
checking for i686-pc-mingw32-dumpbin... no
checking for i686-pc-mingw32-link... no
checking for dumpbin... no
checking for link... link -dump -symbols
checking the name lister (link -dump -symbols) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 8192
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking for /usr/i686-pc-cygwin/bin/ld.exe option to reload object files... -r
checking for i686-pc-mingw32-objdump... no
checking for objdump... objdump
checking how to recognize dependent libraries... file_magic ^x86 archive import|^x86 DLL
checking for i686-pc-mingw32-ar... no
checking for ar... ar
checking for i686-pc-mingw32-strip... strip
checking for i686-pc-mingw32-ranlib... no
checking for ranlib... ranlib
checking command to parse link -dump -symbols output from gcc object... failed
checking for dlfcn.h... yes
checking for i686-pc-mingw32-as... no
checking for as... as
checking for i686-pc-mingw32-dlltool... no
checking for dlltool... dlltool
checking for i686-pc-mingw32-objdump... objdump
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -DDLL_EXPORT -DPIC
checking if gcc PIC flag -DDLL_EXPORT -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/i686-pc-cygwin/bin/ld.exe) supports shared libraries... yes
checking whether -lc should be explicitly linked in... yes
checking dynamic linker characteristics... Win32 ld.exe
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for i686-pc-mingw32-windres... no
checking for windres... windres
checking Library version WINLIB... libwin-1.dll (1.0.0.119)
checking for rman... no
checking for id... id -un
checking windows.h usability... yes
checking windows.h presence... yes
checking for windows.h... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating libtestfw/Makefile
config.status: creating libwin/Makefile
config.status: creating libwin/src/Makefile
config.status: creating libwin/src/rsrc.rc
config.status: creating libwin/src/winlib/version.h
config.status: creating libwin/test/Makefile
config.status: creating libwin/src/config.h
config.status: executing depfiles commands
config.status: executing libtool commands
Making all in libwin
make[1]: Entering directory `/home/jcurl/winlib/code/libwin'
Making all in src
make[2]: Entering directory `/home/jcurl/winlib/code/libwin/src'
make  all-am
make[3]: Entering directory `/home/jcurl/winlib/code/libwin/src'
/bin/sh ../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -DBUILD_DLL -g -O2 -MT version.lo -MD -MP -MF .deps/version.Tpo -c -o version.lo version.c libtool: compile: gcc -DHAVE_CONFIG_H -I. -DBUILD_DLL -g -O2 -MT version.lo -MD -MP -MF .deps/version.Tpo -c version.c -DDLL_EXPORT -DPIC -o .libs/version.o libtool: compile: gcc -DHAVE_CONFIG_H -I. -DBUILD_DLL -g -O2 -MT version.lo -MD -MP -MF .deps/version.Tpo -c version.c -o version.o >/dev/null 2>&1
mv -f .deps/version.Tpo .deps/version.Plo
/bin/sh ../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -DBUILD_DLL -g -O2 -MT libmain.lo -MD -MP -MF .deps/libmain.Tpo -c -o libmain.lo libmain.c libtool: compile: gcc -DHAVE_CONFIG_H -I. -DBUILD_DLL -g -O2 -MT libmain.lo -MD -MP -MF .deps/libmain.Tpo -c libmain.c -DDLL_EXPORT -DPIC -o .libs/libmain.o libtool: compile: gcc -DHAVE_CONFIG_H -I. -DBUILD_DLL -g -O2 -MT libmain.lo -MD -MP -MF .deps/libmain.Tpo -c libmain.c -o libmain.o >/dev/null 2>&1
mv -f .deps/libmain.Tpo .deps/libmain.Plo
/bin/sh ../../libtool   --tag=RC --mode=compile windres  rsrc.rc -o rsrc.lo
libtool: compile:  windres rsrc.rc  -o .libs/rsrc.o
libtool: compile:  windres rsrc.rc >/dev/null 2>&1
/bin/sh ../../libtool --tag=CC --mode=link gcc -DBUILD_DLL -g -O2 -no-undefined -version-info 1:0:0 -Wl,--add-stdcall-alias -o libwin.la -rpath /usr/local/lib version.lo libmain.lo rsrc.lo libtool: link: gcc -shared .libs/version.o .libs/libmain.o .libs/rsrc.o -Wl,--add-stdcall-alias -o .libs/libwin-1.dll -Wl,--enable-auto-image-base -Xlinker --out-implib -Xlinker .libs/libwin.dll.a
Creating library file: .libs/libwin.dll.a
libtool: link: ar cru .libs/libwin.a  version.o libmain.o rsrc.o
ar: rsrc.o: No such file or directory
make[3]: *** [libwin.la] Error 1
make[3]: Leaving directory `/home/jcurl/winlib/code/libwin/src'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/jcurl/winlib/code/libwin/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/jcurl/winlib/code/libwin'
make: *** [all-recursive] Error 1





reply via email to

[Prev in Thread] Current Thread [Next in Thread]