summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorDaniel Baumann <mail@daniel-baumann.ch>2015-11-08 04:16:56 +0000
committerDaniel Baumann <mail@daniel-baumann.ch>2015-11-08 04:16:56 +0000
commit5db0b79a24c1a00b3f5a91f02170ecc9efaa004c (patch)
tree809707785164b504dc85fabab941c078098319db /configure
parentAdding upstream version 0.7. (diff)
downloadzutils-5db0b79a24c1a00b3f5a91f02170ecc9efaa004c.tar.xz
zutils-5db0b79a24c1a00b3f5a91f02170ecc9efaa004c.zip
Adding upstream version 0.8~rc1.upstream/0.8_rc1
Signed-off-by: Daniel Baumann <mail@daniel-baumann.ch>
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure41
1 files changed, 11 insertions, 30 deletions
diff --git a/configure b/configure
index c8eda48..c94a506 100755
--- a/configure
+++ b/configure
@@ -5,12 +5,12 @@
# This configure script is free software: you have unlimited permission
# to copy, distribute and modify it.
#
-# Date of this version: 2009-10-21
+# Date of this version: 2009-12-01
args=
no_create=
progname=zutils
-progversion=0.7
+progversion=0.8-rc1
srctrigger=zdiff.in
# clear some things potentially inherited from environment.
@@ -24,15 +24,15 @@ datadir='$(prefix)/share'
infodir='$(datadir)/info'
mandir='$(datadir)/man'
sysconfdir='$(prefix)/etc'
-CC=
-CXX=
-CPPFLAGS=
-CFLAGS='-Wall -W -O2'
-CXXFLAGS='-Wall -W -O2'
-LDFLAGS=
+
+if [ -n "${CXX}" ] ; then args="${args} CXX=\"${CXX}\"" ; fi
+if [ -n "${CPPFLAGS}" ] ; then args="${args} CPPFLAGS=\"${CPPFLAGS}\"" ; fi
+if [ -n "${CXXFLAGS}" ] ; then args="${args} CXXFLAGS=\"${CXXFLAGS}\""
+else CXXFLAGS='-Wall -W -O2' ; fi
+if [ -n "${LDFLAGS}" ] ; then args="${args} LDFLAGS=\"${LDFLAGS}\"" ; fi
# Loop over all args
-while [ x"$1" != x ] ; do
+while [ -n "$1" ] ; do
# Get the first arg, and shuffle
option=$1
@@ -62,10 +62,8 @@ while [ x"$1" != x ] ; do
echo " --infodir=DIR info files directory [${infodir}]"
echo " --mandir=DIR man pages directory [${mandir}]"
echo " --sysconfdir=DIR read-only single-machine data directory [${sysconfdir}]"
- echo " CC=COMPILER C compiler to use [gcc]"
echo " CXX=COMPILER C++ compiler to use [g++]"
echo " CPPFLAGS=OPTIONS command line options for the preprocessor [${CPPFLAGS}]"
- echo " CFLAGS=OPTIONS command line options for the C compiler [${CFLAGS}]"
echo " CXXFLAGS=OPTIONS command line options for the C++ compiler [${CXXFLAGS}]"
echo " LDFLAGS=OPTIONS command line options for the linker [${LDFLAGS}]"
echo
@@ -92,10 +90,8 @@ while [ x"$1" != x ] ; do
--no-create | --no-c*)
no_create=yes ;;
- CC=*) CC=${optarg} ;;
CXX=*) CXX=${optarg} ;;
CPPFLAGS=*) CPPFLAGS=${optarg} ;;
- CFLAGS=*) CFLAGS=${optarg} ;;
CXXFLAGS=*) CXXFLAGS=${optarg} ;;
LDFLAGS=*) LDFLAGS=${optarg} ;;
@@ -108,7 +104,7 @@ done
# Find the source files, if location was not specified.
srcdirtext=
-if [ x"${srcdir}" = x ] ; then
+if [ -z "${srcdir}" ] ; then
srcdirtext="or . or .." ; srcdir=.
if [ ! -r ${srcdir}/${srctrigger} ] ; then srcdir=.. ; fi
if [ ! -r ${srcdir}/${srctrigger} ] ; then
@@ -128,19 +124,8 @@ fi
# Set srcdir to . if that's what it is.
if [ "`pwd`" = "`cd ${srcdir} ; pwd`" ] ; then srcdir=. ; fi
-# checking whether we are using GNU C.
-if [ x"${CC}" = x ] ; then # Let the user override the test.
- if [ -x /bin/gcc ] ||
- [ -x /usr/bin/gcc ] ||
- [ -x /usr/local/bin/gcc ] ; then
- CC="gcc"
- else
- CC="cc"
- fi
-fi
-
# checking whether we are using GNU C++.
-if [ x"${CXX}" = x ] ; then # Let the user override the test.
+if [ -z "${CXX}" ] ; then # Let the user override the test.
if [ -x /bin/g++ ] ||
[ -x /usr/bin/g++ ] ||
[ -x /usr/local/bin/g++ ] ; then
@@ -176,10 +161,8 @@ echo "datadir = ${datadir}"
echo "infodir = ${infodir}"
echo "mandir = ${mandir}"
echo "sysconfdir = ${sysconfdir}"
-echo "CC = ${CC}"
echo "CXX = ${CXX}"
echo "CPPFLAGS = ${CPPFLAGS}"
-echo "CFLAGS = ${CFLAGS}"
echo "CXXFLAGS = ${CXXFLAGS}"
echo "LDFLAGS = ${LDFLAGS}"
rm -f Makefile
@@ -201,10 +184,8 @@ datadir = ${datadir}
infodir = ${infodir}
mandir = ${mandir}
sysconfdir = ${sysconfdir}
-CC = ${CC}
CXX = ${CXX}
CPPFLAGS = ${CPPFLAGS}
-CFLAGS = ${CFLAGS}
CXXFLAGS = ${CXXFLAGS}
LDFLAGS = ${LDFLAGS}
EOF