Hi autoconfigurators!

I have a smallish problem using AC_SUBST together with AC_CACHE_VAL.
According to the manual, AC_CACHE_VAL may only contain code to set the
cache-var. But if I want to sent something depending on a cached-var to
AC_SUBST, I end up in concatenating the same values...Example:

AC_CACHE_CHECK([whether whatever accepts -foo],
                [sb_cv_foo],
                [sb_cv_foo=yes]
               )
AC_SUBST([SB_FOOS], ["$SB_FOOS bar"])

On first call, I get $SB_FOOS = bar. On second call I get $SB_FOOS = bar
bar. And so on. How can I prevent adding the same value several times? I
guess there is something like sb_cv_foo_set for the cahing mechanism,
but where is the difference in testing for that instead of putting the
AC_SUBST stuff into the AC_CACHE_CHECK command-to-set section?

greetings,

Stefan

-- 
Stefan Bienert
Zentrum fuer Bioinformatik
Universitaet Hamburg
Bundesstrasse 43
20146 Hamburg
Germany

Email: [email protected]
Phone:  +49 (40) 42838 7345
Fax:    +49 (40) 42838 7332


_______________________________________________
Autoconf mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/autoconf

Reply via email to