diff options
Diffstat (limited to '')
-rw-r--r-- | Game/Code/configure.ac | 143 |
1 files changed, 126 insertions, 17 deletions
diff --git a/Game/Code/configure.ac b/Game/Code/configure.ac index 2c4e37f1..ef0516d5 100644 --- a/Game/Code/configure.ac +++ b/Game/Code/configure.ac @@ -11,8 +11,22 @@ AC_PREREQ(2.61) # Init autoconf -AC_INIT([UltraStar Deluxe], [1.1], [TODO: send bugreport BUG-REPORT-ADDRESS]) +AC_INIT([UltraStar Deluxe], + [1.1 alpha], + [http://sourceforge.net/tracker/?group_id=191560&atid=937872]) +# specify the website here +PACKAGE_WEBSITE="http://www.ultrastardeluxe.org/" +# specify the IRC-channel here +PACKAGE_IRC="#ultrastardx at quakenet.org" + +AUTOCONF_INFO=[generated automatically by -*- Autoconf -*- +Do NOT edit this file. Edit ... instead.] + +# Specify a source-file so autoconf can check if the source-dir exists AC_CONFIG_SRCDIR(UltraStar.lpr) + +# This one is not used by autoconf at the moment. +# When it is used maybe we don't need aclocal's -I parameter anymore. AC_CONFIG_MACRO_DIR(m4) # show features and packages in one list @@ -22,17 +36,26 @@ AC_PRESERVE_HELP_ORDER # define switches # ----------------------------------------- -# print library option header +# print library options header AC_ARG_WITH([cfg-dummy1], [ External Libraries:]) # add lazarus option AC_ARG_WITH([lazarus], [AS_HELP_STRING([--with-lazarus=DIR], - [Directory of lazarus directory @<:@LAZARUSDIR@:>@])], + [Directory of lazarus @<:@LAZARUSDIR@:>@])], [with_lazarus=$withval], [with_lazarus="yes"]) -if [[ $with_lazarus = "no" ]] ; then - AC_MSG_ERROR("Lazarus is required. It is impossible to build without it."); +if [[ x$with_lazarus = xno ]] ; then + AC_MSG_ERROR([Lazarus is required. It is impossible to build without it.]); +fi + +# add jedi-sdl option +AC_ARG_WITH([jedi-sdl], + [AS_HELP_STRING([--with-jedi-sdl=DIR], + [Directory of JEDI-SDL @<:@lib/JEDI-SDLv1.0@:>@])], + [with_jedi_sdl=$withval], [with_jedi_sdl="lib/JEDI-SDLv1.0"]) +if [[ x$with_jedi_sdl = xno -o x$with_jedi_sdl = xyes ]]; then + AC_MSG_ERROR([JEDI-SDL is required. Specify its directory.]); fi # add portaudio option @@ -53,9 +76,35 @@ AC_ARG_WITH([projectM], [Enable projectM visualization support @<:@default=check@:>@])], [with_projectM=$withval], [with_projectM="check"]) -# AC_ARG_ENABLE(foobar, -# [ --enable-foobar Dummy option], -# enable_foobar=$enableval, enable_foobar="no") +# print path options header +AC_ARG_WITH([cfg-dummy2], [ +Additional directories:]) + +# add suffix option +AC_ARG_WITH([suffix], + [AS_HELP_STRING([--with-suffix=SUFFIX], + [path suffix @<:@default=UltraStarDeluxe@:>@])], + [suffix=$withval], [suffix="UltraStarDeluxe"]) +if [[ x$suffix = xno -o x$suffix = xyes ]] ; then + AC_MSG_ERROR([Invalid suffix.]); +fi + +# add logdir option +AC_ARG_WITH([logrootdir], + [AS_HELP_STRING([--with-logrootdir=DIR], + [logging root directory @<:@default=/var/log@:>@])], + [with_logrootdir=$withval], [with_logrootdir="/var/log"]) + +# print misc options header +AC_ARG_WITH([cfg-dummy3], [ +Development options:]) + +# add dev_layout option +# Note: now handled by the Makefile +AC_ARG_ENABLE(dev_install, + [AS_HELP_STRING([--enable-dev-install], + [local installation for testing])], + [enable_dev_install="yes"], [enable_dev_install="no"]) # ----------------------------------------- @@ -149,7 +198,7 @@ AC_DEFUN([AC_PKG_CHECK_VERSION], AC_SPLIT_VERSION([$1], [0.0.0]) AC_MSG_RESULT(no) if test x$3 = xyes -o x$4 = xyes; then - AC_MSG_ERROR(["Could not find required library $2. Please install $2 and try again."]); + AC_MSG_ERROR([Could not find required library $2. Please install $2 and try again.]); fi fi ]) @@ -161,7 +210,9 @@ AC_DEFUN([AC_PKG_CHECK_VERSION], # find and test the freepascal compiler # sets PFLAGS, FPC_VERSION, FPC_DEBUG, etc. AC_PROG_FPC -AC_SPLIT_VERSION(FPC, $FPC_VERSION) +# FPC_VERSION is already defined by FPC, use +# PPC as prefix instead. +AC_SPLIT_VERSION(PPC, $FPC_VERSION) # find and test the C compiler (for C-libs and wrappers) AC_PROG_CC @@ -206,14 +257,14 @@ else if [[ -d $with_lazarus ]] ; then LAZARUS_CHECK_DIRS=$with_lazarus else - AC_MSG_ERROR(["LAZARUSDIR is not a directory."]); + AC_MSG_ERROR([LAZARUSDIR is not a directory.]); fi fi # find lazarus AC_PATH_PROG(LAZARUS, lazarus, no, [$LAZARUS_CHECK_DIRS]) if [[ $LAZARUS = "no" ]] ; then - AC_MSG_ERROR(["Could not find lazarus. Please install lazarus and try again."]); + AC_MSG_ERROR([Could not find lazarus. Please install lazarus and try again.]); fi LAZARUS_DIR=`dirname "$LAZARUS"` @@ -228,6 +279,27 @@ AC_MSG_RESULT(@<:@$LAZARUS_VERSION@:>@) # find sdl AC_PKG_CHECK_VERSION(SDL, [sdl], yes) +# check if JEDI-SDL pascal headers exist +AC_MSG_CHECKING(for JEDI-SDL pascal headers) + +JEDISDL_DIR="$with_jedi_sdl" +if [[ ! -d "$JEDISDL_DIR" ]]; then + AC_MSG_RESULT(no) + AC_MSG_ERROR([Path specified for JEDI-SDL is not a directory.]); +fi +#http://delphi-jedi.org +# -d "$JEDISDL_DIR/SDL_ttf" -a +# -d "$JEDISDL_DIR/SDL_Image" -a +# -d "$JEDISDL_DIR/OpenGL" -a +# TODO: add further tests and check the version +if [[ -d "$JEDISDL_DIR/sdl" ]]; then + AC_MSG_RESULT(yes) +else + AC_MSG_RESULT(no) +# AC_MSG_ERROR([JEDI-SDL is not available. +#Download it and extract it to "$JEDISDL_DIR".]); +fi + # find sqlite3 AC_PKG_CHECK_VERSION(SQLITE3, [sqlite3], yes) @@ -254,7 +326,7 @@ AC_PKG_CHECK_VERSION(PORTAUDIO, [portaudio-2.0], yes, $with_portaudio) AC_PKG_CHECK_VERSION(PORTMIXER, [portmixer], no, $with_portmixer) # ----------------------------------------- -# defines for config.inc +# defines for config.inc/versions.pas # ----------------------------------------- # AC_SUBST_DEFINE(DEFINE_SUFFIX, IS_DEFINED) @@ -279,7 +351,8 @@ AC_SUBST(SWSCALE_LIB) AC_SUBST_DEFINE(HAVE_SWSCALE, $SWSCALE_HAVE) AC_SUBST(PROJECTM_LIB) -AC_SUBST_DEFINE(HAVE_PROJECTM, $PROJECTM_HAVE) +AC_SUBST_DEFINE(HAVE_PROJECTM_0_9, $PROJECTM_HAVE) +AC_SUBST_DEFINE(HAVE_PROJECTM_1_0_PLUS, $PROJECTM_HAVE) AC_SUBST(PORTAUDIO_LIB) AC_SUBST_DEFINE(HAVE_PORTAUDIO, $PORTAUDIO_HAVE) @@ -289,11 +362,17 @@ AC_SUBST_DEFINE(HAVE_PORTMIXER, $PORTMIXER_HAVE) AC_SUBST(LAZARUS_DIR) +logrootdir=$with_logrootdir +AC_SUBST(logrootdir) + +AC_SUBST(PACKAGE_WEBSITE) + # ----------------------------------------- # create output files # ----------------------------------------- -AC_CONFIG_FILES([config.inc Makefile]) +AC_CONFIG_FILES([config-linux.inc:config.inc.in]) +AC_CONFIG_FILES([Makefile]) AC_OUTPUT # ----------------------------------------- @@ -302,6 +381,36 @@ AC_OUTPUT AC_MSG_NOTICE([ -!!! Configuration done! -!!! Type "make" to compile the program. +!!! +!!! Configuration of $PACKAGE_NAME $PACKAGE_VERSION done! +!!! +!!! Type "make" to compile and +!!! "make install" to install it afterwards. +!!! +!!! For further information on $PACKAGE_NAME visit: +!!! $PACKAGE_WEBSITE +!!! +!!! IMPORTANT: +!!! This is an UNSUPPORTED ALPHA release for developers only. +!!! +!!! DO NOT EXPECT THE MAKEFILE OR THE PROGRAM ITSELF TO WORK +!!! +!!! and do not waste your time with bugfixing this version. +!!! Bugs might already be fixed in the developers' working copies. +!!! If you want to contribute, visit the IRC-Channel instead: +!!! $PACKAGE_IRC +!!! +!!! Known issues: +!!! - "make" might not work correctly +!!! - Audio-output and -input are not working yet +!!! - The editor is broken +!!! +!!! PLEASE DO NOT SEND BUGREPORTS FOR THIS VERSION. +!!! ]) + +# TODO: insert this in the public beta release +#!!! In case you find a bug send a bugreport to: +#!!! $PACKAGE_BUGREPORT +#!!! You might as well ask for help at the IRC-Channel +#!!! $PACKAGE_IRC |