autoconf
[Top][All Lists]
Advanced

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

Re: Autoconf building, linking across multiple source directories?


From: John Calcote
Subject: Re: Autoconf building, linking across multiple source directories?
Date: Tue, 08 Jul 2008 14:55:52 -0600
User-agent: Thunderbird 2.0.0.12 (X11/20071114)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Ralf Wildenhues wrote:
> For what little it's worth, I'd write that as
> 
> src/Makefile.am:
> noinst_LIBRARIES = libtest.a
> libtest_a_SOURCES = foo.cc bar.cc
> bin_PROGRAMS = myprog
> myprog_SOURCES = main.cc
> myprog_LDADD = libtest.a
> 
> tests/Makefile.am:
> check_PROGRAMS = testrunner
> testrunner_SOURCES = testrunner.cc foo_test.cc bar_test.cc
> testrunner_LDADD = ../src/libtest.a

Oh yes - that is better. It didn't even occur to me to use the library
in both the testrunner and the app - duh. I would have eventually seen
that, but I never work as well off the cuff.

Thanks,
John
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (GNU/Linux)
Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org

iEYEARECAAYFAkhz1FgACgkQdcgqmRY/OH+uLQCfXPLAy8u+f4x+DC7tzcRSjP69
3BkAnjEHwfOnaTzoRJjtATG9kbx/9XR9
=mwYL
-----END PGP SIGNATURE-----




reply via email to

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