RFC on Makefile.am fixes for (non-portable) linking against libtool modules in KDE

Lubos Lunak l.lunak at suse.cz
Thu Mar 6 14:57:12 GMT 2003


On Thursday 06 of March 2003 15:45, Michael Matz wrote:
> Hi,
>
> On Thu, 6 Mar 2003, Benjamin Reed wrote:
> > > That might not be for a couple weeks though since I have tons of work
> > > and travel next week.

 Actually, yesterday I tried to write am_edit/automake support for kdeinit 
modules too.

> >
> > Yeah, I started looking into it a bit last night and I think it will
> > basically be impossible (or impractical) to implement in am_edit.
> > am_edit edit's the .in files (strangely enough), and by the time you
> > have those it's too late.
>
> What makes you think that?
>
> > I'm going to try to find some docs on adding keywords to automake (if
> > it's even possible) and then I guess we'll go from there.
>
> Ehh no.  You don't want to do this in automake.  am_edit is perfectly
> capable to do the rewriting you want.

 And how exactly should the Makefile.am look for am_edit to work?

 I first thought about simply having the app written normally without all that 
LTLIBRARIES stuff, only with some flag marking it as kdeinit module, and I 
thought am_edit could do the rest. Very simple to find out this doesn't work. 
If automake doesn't see any LTLIBRARIES stuff in Makefile.am, it won't 
generate rules for building libraries -> myapp.la building will fail.

 I also tried automake conditionals (AM_CONDITIONAL). That needed larger 
Makefile.am, but it was simply some lines from a template that only needed 
s/templateapp/myapp/. Seemed to work very well until I found out am_edit 
fails hopelessly with conditionals (and fixing this issue in am_edit looks 
like a lot of work after investigation). So this doesn't work either.

 I'm still considering one more variant: Simply writting Makefile.am for both 
kdeinit and non-kdeinit case, with the first one being myapp1_SOURCES etc., 
the latter one myapp2_SOURCES, and trying to make am_edit create some useful 
result from it. Or do you have a better idea?

-- 
Lubos Lunak
KDE developer
---------------------------------------------------------------------
SuSE CR, s.r.o.  e-mail: l.lunak at suse.cz , l.lunak at kde.org
Drahobejlova 27  tel: +420 2 9654 2373
190 00 Praha 9   fax: +420 2 9654 2374
Czech Republic   http://www.suse.cz/





More information about the kde-core-devel mailing list