[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
linking against libraries which a not in the local directory
From: |
gromeck |
Subject: |
linking against libraries which a not in the local directory |
Date: |
Mon, 12 Jan 2009 12:05:44 +0100 |
User-agent: |
RoundCube Webmail/0.1 |
Hi to all,
I have a problem building with automake in the following
directory layout:
src/
src/dirA/ holds lib A and program A
src/dirB/ holds lib B and program B
Both, program A and B have to linked against lib A and B!
Yes, I know that this is not a good layout but I have
currently no other chance to rearrange it (the real project
is somewhat larger).
In src/dirA/Makefile.am I've set
progA_LDADD=libA.a ../dirB/libB.a
but the build of libB.a is not triggered automatically.
A workaround is to add the following target to
src/dirA/Makefile.am:
../dirB/libB.a:
make -C ../dirB/ libB.a
But I think, this is a hack.
So,
1. is there a way to setup the dependencies in a way which
triggers build of the lib which is not in the local
directory?
2. is there a way to trigger building all libs in a source
tree ("make libs")?
Any ideas or comments would be appreciated.
Schönen Gruss -- gromeck
- linking against libraries which a not in the local directory,
gromeck <=