automake
[Top][All Lists]
Advanced

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

Re: AM_CONDITIONAL not working properly, or I just don't understand :-(


From: Gary V. Vaughan
Subject: Re: AM_CONDITIONAL not working properly, or I just don't understand :-(
Date: Thu, 16 Oct 2003 10:06:37 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5) Gecko/20030925 Thunderbird/0.3

Kevin P. Fleming wrote:
Gary V. Vaughan wrote:
The only way I can think of doing this is with an install-exec-hook that removes installed libraries if INSTALL_LIBS was not set:

    if !INSTALL_LIBS
    install-exec-hook:
        $(MAKE) $(AM_MAKEFLAGS) uninstall-pkglibLTLIBRARIES
    endif

But this depends on an undocumented target. Better to put the modules in a separate dir with their own Makefile.am, and call that Makefile's uninstall rule in the same way.


Yuck... that means my users will see the libtool --mode=install messages and ldconfig runs for all 30+ modules, then they'll all get removed. For now I think I can live with the files getting installed and the users just knowing that they're not necessary for the application to be used.

Yeah, that is pretty sucky. What about installing the modules to a bogus directory (in the build tree?) and then removing that directory?

    if !INSTALL_LIBS
    pkglibdir = $(top_builddir)/_noinst
    install-exec-hook:
            @echo "pruning statically linked modules"
            rm -rf $(pkglibdir)
    endif

Or, if you give the modules their own Makefile.am, you might be able to redefine INSTALL and mkinstalldirs to neuter the install rules:

    if !INSTALL_LIBS
    INSTALL=:
    mkinstalldirs=:
    endif

Cheers,
        Gary.
--
  ())_.  Gary V. Vaughan    gary@(lilith.warpmail.net|gnu.org)
  ( '/   Research Scientist http://www.oranda.demon.co.uk       ,_())____
  / )=   GNU Hacker         http://www.gnu.org/software/libtool  \'      `&
`(_~)_   Tech' Author       http://sources.redhat.com/autobook   =`---d__/





reply via email to

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