automake
[Top][All Lists]
Advanced

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

Re: Overriding all commands in Makefile.am


From: rboehne
Subject: Re: Overriding all commands in Makefile.am
Date: Fri, 10 Aug 2007 15:37:55 +0000

How about

./configure AR=:  [other arguments etc.]

You also might be able to force this override in configure.ac, but that would
defeat all the nifty things that the autotools are good for.
Perhaps what you really want is "--disable-static" on the configure command 
line.
You can also make this the default to disable static libs with:

          # Turn off static libraries, since they aren't useful in python 
modules and
          # make the build process take too long.
          AC_DISABLE_STATIC
          AC_PROG_LIBTOOL

One of these should have the desired effect, depending on what you desire. ;)

Hope this helps,

Robert Boehne

 -------------- Original message ----------------------
From: NightStrike <address@hidden>
> Since this list is obviously not dead, here's my first of several questions:
> 
> (this is all with automake 1.10)
> 
> How do I individually override everything that takes place for a given
> target?  For example, if I have this:
> 
> lib_LIBRARIES = libmylib.a
> libmylib_a_SOURCES = source1.c source2.c
> 
> The resulting Makefile will perform:
> 
> $(CC) $(AM_CPPFLAGS) -o source1.o source1.c
> $(CC) $(AM_CPPFLAGS) -o source2.o source2.c
> $(AR) (AR_FLAGS) libmylib.a source1.o source2.o
> $(RANLIB) libmylib.a
> 
> I have the ability to override the AR command by setting libmylib_a_AR
> to any arbitrary set of commands, allowing me to have incredible
> control over step 3 above.  However, I have not found out how to do
> the same for steps 1, 2, and 4 (or at the very least prevent RANLIB
> from running).  For instance, I could, if I chose, do this:
> 
> lib_LIBRARIES = libmylib.a
> libmylib_a_SOURCES = source1.c source2.c
> libmylib_a_AR = echo \!* > /dev/null
> 
> and it would serve as a very kludgey (albeit effective) way to disable
> the AR command for that target only (this is just an example..
> obviously there are other, better ways to do it).  How do I achieve
> the same overriding capabilities for everything?
> 
> 





reply via email to

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