libtool
[Top][All Lists]
Advanced

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

Re: portland compiler, convenience libraries and templates


From: Markus Christen
Subject: Re: portland compiler, convenience libraries and templates
Date: Thu, 02 Dec 2004 19:24:23 +0100
User-agent: Mozilla Thunderbird 0.8 (X11/20040917)

Markus Christen wrote:


hi

first of all: thanks for libtool, it helped a lot in adding flexibility to the compilation of my project!


problem:
linking a program to a library (shared or static) built from a convenience library fails if the convenience library contains template functions : unresolved reference.

(of course when using the portland compiler ;-)

anyway, already some follow-up:

what needs to be done is using
--one_instantiation_per_object
for all .cc files in the libraries, then before building the final library, do a
pgCC --one_instantiation_per_object --prelink-objects $CXXFLAGS $LDFLAGS *.o
on all objects.
this will create additional object files in a directory Template.dir

then, when building the library, all the additional object files need to be added as well
ar cru normal objects, convenience libraries Template.dir/*.o

[
if i ar cru ' d the convenient library objects from Template.dir/ into the convenience library, and then only added the rest to the real library, i still get unresolved references...
]

if i do this manually, the prog compiles.

if anybody could put this into something that libtool can do (automatically) (maybe with writing some automake hooks or whatever?), i would be glad...

thank you,
markus

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature


reply via email to

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