compiles deb, fails at distcheck; refs #110

This commit is contained in:
Marc Wäckerlin
2011-12-13 09:35:41 +00:00
parent 2914b984e5
commit 29dcafa065
9 changed files with 1066 additions and 664 deletions

View File

@@ -1,4 +1,20 @@
# init
# $Id: configure.in 2654 2011-06-20 10:00:54Z marc $
AC_ALIAS([AC_DEFINE_DIR], [AX_DEFINE_DIR])
AC_DEFUN([AX_DEFINE_DIR], [
prefix_NONE=
exec_prefix_NONE=
test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix
test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix
dnl In Autoconf 2.60, ${datadir} refers to ${datarootdir}, which in turn
dnl refers to ${prefix}. Thus we have to use `eval' twice.
eval ax_define_dir="\"[$]$2\""
eval ax_define_dir="\"$ax_define_dir\""
AC_SUBST($1, "$ax_define_dir")
AC_DEFINE_UNQUOTED($1, "$ax_define_dir", [$3])
test "$prefix_NONE" && prefix=NONE
test "$exec_prefix_NONE" && exec_prefix=NONE
])
AC_INIT([README])
SRC_DIR=src
TST_DIR=
@@ -6,27 +22,31 @@ DOC_DIR=doc
m4_define(x_packagename, swisssurfer)
m4_define(x_major, 1)
m4_define(x_minor, 1)
m4_define(x_minor, 2)
PACKAGENAME=x_packagename
MAJOR=x_major
MINOR=x_minor
BUILDDATE=$(date "+%d.%m.%Y/%H.%M")
LEAST="ERROR-UNDEFINED-REVISION-to-be-built-in-subdirectory-of-svn-checkout"
for path in . .. ../..; do
if svn info $path 2>&1 > /dev/null; then
if svn info . 2>&1 > /dev/null; then
LEAST=$(LANG= svn info $path | sed -n 's/Revision: //p')
break;
fi
done
else
LEAST=[$(pwd | sed -n 's,^.*/'${PACKAGENAME}'-'${MAJOR}'\.'${MINOR}'\.\([0-9]*\).*$,\1,p')]
if test -z "${LEAST}"; then
LEAST="ERROR CANNOT DETERMINE REVISION NUMBER from $(pwd)"
fi
fi
AM_INIT_AUTOMAKE($PACKAGENAME, $MAJOR.$MINOR.$LEAST, [marc@waeckerlin.org])
AM_INIT_AUTOMAKE($PACKAGENAME, $MAJOR.$MINOR.$LEAST, [marc.waeckerlin@tech.swisssign.com])
# files to create
AC_CONFIG_FILES(makefile
src/makefile src/qmake.pro src/languages.qrc
doc/doxyfile doc/makefile)
AC_CONFIG_FILES([makefile ${PACKAGENAME}.spec src/version.cxx
src/makefile
src/qmake.pro src/languages.qrc
doc/doxyfile doc/makefile
debian/changelog])
# copy M4 to shell
AC_SUBST(MAJOR)
@@ -44,12 +64,18 @@ AC_SUBST(LIB_VERSION)
# home
AC_SUBST(HOME)
# datadir for languages
AX_DEFINE_DIR([DATADIR], [datadir])
#AC_SUBST(DATADIR)
# macros
README=README
AC_SUBST_FILE(README)
CHANGE_LOG=ChangeLog
AC_SUBST_FILE(CHANGE_LOG)
AM_CPPFLAGS="-DPACKAGEVERSION='\"${VERSION}\"' -DPACKAGENAME='\"${PACKAGENAME}\"'"
# Get rid of that stupid -O2 -g opions!
CXXFLAGS="${CXXFLAGS:-}"
@@ -81,6 +107,15 @@ AC_ARG_ENABLE(dot,
test "$enableval" = "yes" && HAVE_DOT="YES" || HAVE_DOT="NO";
AM_PATH_CPPUNIT([1.0.0], [have_cppunit="yes"], [have_cppunit="no"])
MINGW32=no
MAC=no
case $host_os in
*mingw32*) MINGW32=yes;;
*darwin* | *rhapsody* | *macosx*) MAC=yes;;
esac
AM_CONDITIONAL(MINGW32, test "$MINGW32" = "yes")
AM_CONDITIONAL(MAC, test "$MAC" = "yes")
# Special Options
AC_CHECK_PROGS([LRELEASE], [lrelease-qt4 lrelease-mac lrelease])
test -n "$LRELEASE" || AC_MSG_ERROR([lrelease for Qt 4 not found!])
@@ -91,10 +126,6 @@ AC_SUBST(LUPDATE)
# Environment Variables
AC_ARG_VAR(LUPDATE_ARGS, [arguments for qt lupdate command, e.g. -no-obsolete])
AC_ARG_VAR(EDITION, [name of the edition, e.g. comol])
AC_ARG_VAR(EDITION_USERFRIENDLY, [userfriendly name of the edition, e.g. CoMoL])
AC_ARG_VAR(BUILDVERSION, [version of this build, e.g. v1.0])
AC_ARG_VAR(BUILD, [build number of this build, e.g. 213])
AC_PATH_PROG(QMAKE, [qmake qmake-qt4], [])
AC_ARG_VAR(QMAKE, [path to qmake program])
@@ -114,12 +145,6 @@ AC_SUBST(LIBS)
# create output
AC_OUTPUT
# infos and warnings
AC_MSG_NOTICE([Build Information from Environment:
- EDITION=$EDITION
- EDITION_USERFRIENDLY=$EDITION_USERFRIENDLY
- BUILDVERSION=$BUILDVERSION
- BUILD=$BUILD
])
if test "$have_doxygen" = "no"; then
AC_MSG_WARN([Missing program doxygen!
- you cannot rebuild the documentation with make doc