libtool
[Top][All Lists]
Advanced

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

Re: How to create only executable files


From: Sergio Belkin
Subject: Re: How to create only executable files
Date: Mon, 24 Jan 2011 07:42:25 -0300


2011/1/24 Ralf Wildenhues <address@hidden>
Hello Sergio,

* Sergio Belkin wrote on Sun, Jan 23, 2011 at 11:13:16PM CET:
> I've found great the option "-no-install". But I wonder if is there a
> way to build directly the executables files, I mean that don't create
> object file "something.o" and only do something.o

You mean creating an executable directly from source file(s)?
No, Automake doesn't really support that.  You can try to write
a rule that passes foo.c to 'libtool --mode=link', but since we
don't test that I'm guessing that it won't work reliably.

What's the point of this anyway?  AFAIK the only thing you save
by omitting the object file is one fork&exec of the compiler driver,
which is often negligible compared with the actual work the compiler
and linker do.  You can 'make mostlyclean' to remove object files
you don't need again afterwards.

Cheers,
Ralf

Sorry, I was no clear enough

Let's say that you have a library libfoo.so and you have on build tree a source file fred.c. You've created a test target that creat (with -no-install flag)  the  ELF  executable fred (note that has no extension). But libtool create also fred.o "an ELF relocatable", is there a way that libtool create only the "ELF excutable"? What is the advantage of create an "intermediate file"? Please correct me if I have a wrong concept.

Thanks in advance!
--
--
Sergio Belkin  http://www.sergiobelkin.com
Watch More TV http://sebelk.blogspot.com
LPIC-2 Certified

reply via email to

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