[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Using special characters (quote / space) in compiler-related variables
From: |
Dmitry Katsubo |
Subject: |
Using special characters (quote / space) in compiler-related variables |
Date: |
Tue, 18 Oct 2011 15:57:13 +0200 |
User-agent: |
Mozilla/5.0 (Windows NT 5.1; rv:6.0.2) Gecko/20110902 Thunderbird/6.0.2 |
Dear autoconf users/developers,
I have the following question concerning the use of special characters
in variables. After reading the documentation chapter [1], I've come to
the conclusion, that I cannot define the following in configure.ac:
CXXFLAGS="-D__int64=\"long long\" ${CXXFLAGS}"
AC_CHECK_HEADER([jni.h])
The result is:
> configure:4104: checking jni.h usability
> configure:4104: 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 >&5
> g++: long": No such file or directory
> <command-line>: warning: missing terminating " character
> configure:4104: $? = 1
Even tough the variable is correctly set and can be used in Makefile,
but AC_CHECK_HEADER() fails to treat special characters properly.
I have also tried:
CXXFLAGS="-D__int64=long\ long" ${CXXFLAGS}"
with negative result. However I've seen some examples, where it looks to
work ([2], [3], [4]).
Maybe somebody can give me a hint, how to correctly set CXXFLAGS?
Thanks in advance!
Additional info:
autoconf 2.67 (Debian [squeeze])
> [1]
> http://www.gnu.org/software/autoconf/manual/html_node/Special-Chars-in-Variables.html
> [2] https://developer.brewmp.com/forum/dll-gnu-auto-tools-0
> [3] http://code.google.com/p/beagle-lib/source/browse/trunk/configure.ac?r=991
> [4] http://ptolemy.berkeley.edu/java/ptplot5.8/configure
--
With best regards,
Dmitry