libtool
[Top][All Lists]
Advanced

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

passing flags to the librarian


From: David Byron
Subject: passing flags to the librarian
Date: Tue, 11 Dec 2007 12:51:05 -0800

I'm building a libtool-based package (pcre) using Microsoft command line
tools in a cygwin shell.  I use a wrapper script for the compiler and linker
(cccl), but the librarian (lib) gets invoked directly.

I'd like to specify the /LTCG (link time code generation flag) to the
librarian.  Beats me why I need it, or what it actually does, but when I
compile source with the equivalent option (/GL), I get this warning from the
librarian if I don't have it:

/bin/sh ./libtool --tag=CC   --mode=link cccl  /W3 /Zc:wchar_t- /O2 /Ob1 /Os
/GL /GF /FD /Gy /MD -version-info 0:0:0 /LTCG -o libpcreposix.la -rpath
/home/dbyron/src/tuneup/tuneup_juce/trunk/install/lib/Release pcreposix.lo
libpcre.la /LTCG
cygpath: can't convert empty path
libtool: link: warning: undefined symbols not allowed in i686-pc-cygwin
shared libraries
lib -OUT:.libs/libpcreposix.lib  pcreposix.obj
Microsoft (R) Library Manager Version 8.00.50727.762
Copyright (C) Microsoft Corporation.  All rights reserved.

pcreposix.obj : MSIL .netmodule or module compiled with /GL found;
restarting link with /LTCG; add /LTCG to the link command line to
 improve linker performance
Microsoft (R) Library Manager Version 8.00.50727.762
Copyright (C) Microsoft Corporation.  All rights reserved.

creating libpcreposix.la
(cd .libs && rm -f libpcreposix.la && ln -s ../libpcreposix.la
libpcreposix.la)

I tried as hard as I know how to get /LTCG on the lib command line, by
invoking configure with LIB=/LTCG and LDFLAGS=/LTCG.  Here's the complete
configure invocation:

  $ ../configure CC=cccl CXX=cccl CPPFLAGS=-DPCRE_STATIC -DNDEBUG CFLAGS=/W3
/Zc:wchar_t- /O2 /Ob1 /Os /GL /GF /FD /Gy /MD CXXFLAGS=/W3 /EHsc
/Zc:wchar_t- /O2 /Ob1 /Os /GL /GF /FD /Gy /MD LDFLAGS=/LTCG LIBS=/LTCG
--enable-shared=no --enable-newline-is-anycrlf --enable-bsr-anycrlf
--enable-unicode-properties
--prefix=/home/dbyron/src/tuneup/tuneup_juce/trunk/install
--libdir=/home/dbyron/src/tuneup/tuneup_juce/trunk/install/lib/Release

The configure script was generated with autoconf 2.61.  Makefile.in was
generated with automake 1.10.  Looking into ltmain.sh, I see:

PROGRAM=ltmain.sh
PACKAGE=libtool
VERSION=1.5.23b
TIMESTAMP=" (1.1220.2.437 2007/02/17 09:08:45)"

Is this enough version info to see what tools I'm using?  Any suggestions
about how to get an option to the librarian?

Thanks much.

-DB

PS I'm also curious about the:

cygpath: can't convert empty path

warning that comes from this line in the generated libtool script:

fix_srcfile_path="`cygpath -w "$srcfile"`"

I guess this gets called with an empty $srcfile but I'm not sure why.





reply via email to

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