On Fri, Jul 20, 2001 at 04:17:38PM -0400, Matt Zimmerman wrote:> Maybe the easy way to get around all of this is to build a plain old .a archive > for the assembler stuff, instead of a libtool .la library. This may or may not > cause problems when linking the libFLAC shared library. I'll try it.It does work, but gives a warning: *** Warning: Linking the shared library libFLAC.la against the *** static library ia32/libFLAC-asm.a is not portable! I think this is just because libtool can't determine whether the objects in libFLAC-asm.a are PIC or not. In our case, it shouldn't matter. I'll try one other approach (getting nasm to act like gas), but for now, here is a patch. -- - mdz -------------- next part -------------- Index: Makefile.am ==================================================================RCS file: /cvsroot/flac/flac/src/libFLAC/Makefile.am,v retrieving revision 1.14 diff -u -r1.14 Makefile.am --- Makefile.am 2001/07/16 18:10:19 1.14 +++ Makefile.am 2001/07/20 20:21:58 @@ -32,7 +32,7 @@ if FLaC__CPU_IA32 if FLaC__HAS_NASM SUBDIRS = ia32 . -libFLAC_la_LIBADD = ia32/libFLAC-asm.la +libFLAC_la_LIBADD = ia32/libFLAC-asm.a endif endif endif Index: ia32/Makefile.am ==================================================================RCS file: /cvsroot/flac/flac/src/libFLAC/ia32/Makefile.am,v retrieving revision 1.5 diff -u -r1.5 Makefile.am --- ia32/Makefile.am 2001/07/16 18:04:19 1.5 +++ ia32/Makefile.am 2001/07/20 20:21:58 @@ -20,14 +20,13 @@ STRIP_FPIC = sh $(top_srcdir)/strip_fPIC.sh -.nasm.lo: - $(LIBTOOL) --tag=CC --mode=compile \ - $(STRIP_FPIC) $(NASM) -f $(OBJ_FORMAT) -d OBJ_FORMAT_$(OBJ_FORMAT) $< +.nasm.o: + $(NASM) -f $(OBJ_FORMAT) -d OBJ_FORMAT_$(OBJ_FORMAT) $< #@@@OLD RULE: $(NASM) -f $(OBJ_FORMAT) -d OBJ_FORMAT_$(OBJ_FORMAT) $< -o $@ -noinst_LTLIBRARIES = libFLAC-asm.la -libFLAC_asm_la_SOURCES = \ +noinst_LIBRARIES = libFLAC-asm.a +libFLAC_asm_a_SOURCES = \ cpu_asm.nasm \ fixed_asm.nasm \ lpc_asm.nasm
On Thu, Jul 19, 2001 at 05:05:46PM -0700, Josh Coalson wrote:> --- collver@linuxfreemail.com wrote: > > On Thu, Jul 19, 2001 at 04:58:44PM -0400, Matt Zimmerman wrote: > > > On Thu, Jul 19, 2001 at 10:38:14AM -0700, Josh Coalson wrote: > > > > > > > So, last chance to checkout from CVS and break it! > > > > > > Also, my libtool doesn't seem to recognize --tag=CC. What is its > > > purpose? > > > > > > /bin/sh ../../../libtool --tag=CC --mode=compile \ > > > sh ../../../strip_fPIC.sh nasm -f elf -d OBJ_FORMAT_elf > > > cpu_asm.nasm > > > libtool: unrecognized option `--tag=CC' > > > Try `libtool --help' for more information. > > > > My libtool errored with a message instructing me to specify a tag. > > I put --tag=CC just to make it compile, I don't understand the > > actual problem. > > Ben, was there a reason to compile the .nasm files > through libtool in the first place (instead of > just using nasm directly like before)? If not I would > revert back to the old src/libFLAC/ia32/Makefile.amThe libtool on my system will not add .o files to a library. It only accepts .lo files which appear to be text files describing the .o files libtool generates. Ben
On Fri, Jul 20, 2001 at 08:12:13AM -0700, collver@linuxfreemail.com wrote:> On Thu, Jul 19, 2001 at 05:05:46PM -0700, Josh Coalson wrote: > > > > Ben, was there a reason to compile the .nasm files > > through libtool in the first place (instead of > > just using nasm directly like before)? If not I would > > revert back to the old src/libFLAC/ia32/Makefile.am > > The libtool on my system will not add .o files to a > library. It only accepts .lo files which appear to be > text files describing the .o files libtool generates.Interesting; this, too, seems to be a change from libtool 1.4. .lo files generated by libtool 1.4 are normal object files, at least on Linux/ia32: format.lo: ELF 32-bit LSB relocatable, Intel 80386, version 1, not stripped In contrast to .la files, which are text. Maybe the easy way to get around all of this is to build a plain old .a archive for the assembler stuff, instead of a libtool .la library. This may or may not cause problems when linking the libFLAC shared library. I'll try it. -- - mdz