automake
[Top][All Lists]
Advanced

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

Re: AM_LIBS / AM_LDADD


From: NightStrike
Subject: Re: AM_LIBS / AM_LDADD
Date: Tue, 6 Nov 2007 13:33:04 -0500

On 11/6/07, Ralf Wildenhues <address@hidden> wrote:
> * NightStrike wrote on Tue, Nov 06, 2007 at 07:09:21PM CET:
> > On 11/6/07, Ralf Wildenhues <address@hidden> wrote:
> > > > Can you add to that also AM_DLLTOOLFLAGS?
> > >
> > > It's been mentioned before: Automake currently does not use dlltool.
> [...]
> > The benefit of having it be part of Automake is that then I don't have
> > to specify it on each line.  The more stuff that is internal to
> > automake that I can use, the easier maintaining an automake file is.
>
> What you're really asking for here is support for some automatically
> generated rules that use dlltool, right?  How should such a rule look
> like, what should it do portably(!),

> and why would a portable project
> ever need such a rule when it could just use Libtool?

I guess I misunderstood the purpose of automake in general.  I
understand that automake itself is portable, but is automake intended
mainly for those projects which are themselves portable?

Regarding libtool, maybe I just don't understand how libtool works.  I
can't figure out how to use libtool to generate lib*.a.  It seems
intent on restricting outputs to only lib*.la.  I eventually gave up
and started manually invoking dlltool myself to build the lib*.a from
the *.def files.  Originally, I tried supplying the *.def files to the
lib_LIBRARIES primary, but I couldn't ever figure out how to get the
.def file recognized as a valid source file (even using SUFFIXES =
.def and .def.a: $(DLLTOOL) etc ).  So basically, what it comes down
to is that I think maybe my project is too limited to blend with
automake as simply as I initially envisioned, and my knowledge of
automake is too limited to make it do what I want without asking you
tons of questions (which you have been extremely kind in answering, I
might add... though it may not seem like it, I am learning a lot from
you, so thank you for that).

> If you have to write your own (unportable) rules anyway, then really
> there is nothing else that I see that could be done for you.
>
> Or do you just want
>   AM_DLLTOOLFLAGS = @AM_DLLTOOLFLAGS@
>
> put in every Makefile.in?  You can already have that, just use AC_SUBST
> in configure.ac.
>
> > Now, you state that Automake currently doesn't use dlltool.  I am
> > guessing you mean that dlltool support and usage is provided via
> > libtool, correct?  Should this request go to libtool, instead?  Would
> > the libtool project be able to add the global options variable?
>
> No.  While libtool happens to set ${DLLTOOL}, it doesn't really use it
> either.  I think it used to at some point in the past.
>
> I'm starting to be a bit puzzled.  I simply don't know what you want.

Your questions about my intentions have made my intents clearer to me.
 I now know what I want to do with DLLTOOL specifically.  Tell me what
you think of this idea:

I currently use $(COMPILE) to call gcc for manually written rules.
$(COMPILE) automatically includes $(C*FLAGS) as appropriate.  I keep
thinking that $(DLLTOOL) should do likewise, but $(DLLTOOL) is more
akin to $(CC) than $(COMPILE).  What I can do is:

AM_DLLTOOLFLAGS = -flag1
MAKEDLL = $(DLLTOOL) $(AM_DLLTOOLFLAGS)

Then I just need to use $(MAKEDLL) in the various locations it's necessary.

What do you think?




reply via email to

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