[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Primaries in Conditionals
From: |
Ralf Corsepius |
Subject: |
Re: Primaries in Conditionals |
Date: |
22 Feb 2002 08:41:04 +0100 |
Am Fre, 2002-02-22 um 03.23 schrieb Fausto Sanchez:
> Hi,
>
> Can anyone tell me how to suppress these warning from automake. I just
> upgraded
> to automake 1.5, and now these warnings are being displayed when running
> automake.
This kind of questions is going to be an FAQ ;)
> diag_LDADD = @LDFLAGS@ -L../common_objects -ldiagcommonobj -ldiageng -ltcl8.3
>
> #
> # Depending on the platform we will include either the linecard or
> supervisor objects.
> #
> if HWPLATFORM_LC1
> diag_LDADD += -L../lcp_objects -ldiaglcpobj
> endif
>
> if HWPLATFORM_SUP1
> diag_LDADD += -L../smp_objects -ldiagsmpobj
> endif
Makefile.am:
..
if HWPLATFORM_LC1
MORE = -L../lcp_objects -ldiaglcpobj
endif
if HWPLATFORM_SUP1
MORE = -L../smp_objects -ldiagsmpobj
endif
diag_LDADD = ... $(MORE)
..
Alternatively you could compose these flags from inside of your
configure.ac and let it be passed to the Makefile by AC_SUBST:
configure.ac:
[..]
if test ..; then
# LC1
MORE= ...
else
# SUP1
MORE= ...
fi
AC_SUBST(MORE)
[..]
Makefile.am:
diag_LDADD = ... @MORE@
> What would be the correct way to doing something like the above without
> getting automake to complain.
I'd use the second alternative, because it is more in the spirit of
autoconf (setup anything based upon conclusions from feature-checks).
Ralf