On 18.10.2011 17:21, Nick Bowler wrote: > A possible solution in this case is to just use AC_DEFINE: > > AC_DEFINE([__int64], [long long], [description if you use autoheader]) > AC_CHECK_HEADER([jni.h]) > > Autoconf will take care of including the definition in subsequent > configure tests. If you don't use a config header, automake will take > care of putting it on the compiler command line; otherwise, the > definition will end up in the config header. Thanks, Nick! Worked as a charm. Paul, thank you for your comments as well. > This appears to be more of a shell question than an autoconf > question. From an autoconf point of view, you probably shouldn't > be messing with CXXFLAGS -- that's a variable that the > user should be setting. > > From a shell point of view, the program: > > CXXFLAGS="-D__int64=\"long long\"" > for i in $CXXFLAGS; do echo $i; done > > outputs: > > -D__int64="long > long" > > which may help to explain the symptoms you're seeing. I agree with you, but if I copy-paste the following into shell: > g++ -c -D__int64="long long" -g -O2 -I/usr/lib/jvm/java-6-sun/include -I/usr/lib/jvm/java-6-sun/include/linux -I/usr/lib/jvm/java-6-sun/include/win32 -I/usr/local/include conftest.cpp it works very well. From this I conclude (maybe I am wrong) that autoconf does not pipe this string to shell (that will do the correct string / argument expansion), but somehow tries to execute compiler going the primitive split of arguments by spaces (as you have shown by your small example). -- With best regards, Dmitry _______________________________________________ Autoconf mailing list Autoconf@xxxxxxx https://lists.gnu.org/mailman/listinfo/autoconf