diff configure.in @ 35:3fcc147b253a

Updates towards 0.8beta0
author Matti Hamalainen <ccr@tnsp.org>
date Thu, 19 Jun 2003 20:13:00 +0000
parents 9cf8092ec7d3
children 3c609b6d5a02
line wrap: on
line diff
--- a/configure.in	Thu Jun 19 20:12:02 2003 +0000
+++ b/configure.in	Thu Jun 19 20:13:00 2003 +0000
@@ -2,20 +2,31 @@
 dnl *** Process this file with autoconf to produce a configure script.
 dnl ***
 
-dnl Require autoconf 2.54 or later
-AC_PREREQ(2.54)
+dnl Require autoconf 2.56 or later
+AC_PREREQ(2.56)
 
 dnl Initialize
 AC_INIT(XMMS-SID, 0.8.0beta1, ccr@tnsp.org)
 AC_COPYRIGHT([[(C) 2002-2003 Matti 'ccr' Hämäläinen]])
 AC_CONFIG_SRCDIR(src/xmms-sid.h)
 AM_INIT_AUTOMAKE
-AC_CONFIG_HEADERS(config.h)
+AC_CONFIG_HEADERS(src/config.h)
+
+
+dnl ***
+dnl *** Define some templates
+dnl ***
+AH_TEMPLATE([HAVE_XMMSEXTRA],[Define if you have XMMS version 1.2.5 or later])
+AH_TEMPLATE([HAVE_SIDPLAY1],[Define if you want to use libSIDPlay 1])
+AH_TEMPLATE([HAVE_SIDPLAY2],[Define if you want to use libSIDPlay 2])
+AH_TEMPLATE([HAVE_RESID_BUILDER],[Define if you have reSID with libSIDPlay 2])
+AH_TEMPLATE([HAVE_HARDSID_BUILDER],[Define if you have HardSID with libSIDPlay 2])
 
 
 dnl ***
 dnl *** Some general checks
 dnl ***
+AC_PREFIX_PROGRAM(xmms)
 AC_DISABLE_STATIC
 AC_LIBTOOL_DLOPEN
 AM_PROG_LIBTOOL
@@ -24,13 +35,11 @@
 dnl ***
 dnl *** Checks for programs
 dnl ***
+AC_PROG_CXX
 AC_PROG_CC
-AC_PROG_CXX
-dnl AC_PROG_CPP
+AC_PROG_CPP
 AC_PROG_INSTALL
-AC_HEADER_STDC
 
-AC_PREFIX_PROGRAM(xmms)
 
 dnl ***
 dnl *** Checks for generic libraries
@@ -43,8 +52,8 @@
 dnl ***
 dnl *** libSIDPlay 1 options
 dnl ***
-AC_ARG_WITH(libsidplay1,
-[  --with-libsidplay1=PREFIX   Enable SIDPlay1 with install-PREFIX is],
+AC_ARG_WITH(sidplay1,
+[  --with-sidplay1=PREFIX   Enable SIDPlay1 with install-PREFIX is],
 [
 if test "$withval" = yes; then
 xs_sidplay1=yes
@@ -77,10 +86,11 @@
 dnl ***
 dnl *** libSIDPlay 2 options
 dnl ***
-AC_ARG_WITH(libsidplay2,
-[  --with-libsidplay2=PREFIX   Enable SIDPlay1 with install-PREFIX is],
+AC_ARG_WITH(sidplay2,
+[  --with-sidplay2=PREFIX   Enable SIDPlay1 with install-PREFIX is],
 [
 if test "$withval" = yes; then
+xs_sidplay1=no
 xs_sidplay2=yes
 xs_sidplay2_library=""
 xs_sidplay2_includes=""
@@ -89,6 +99,7 @@
 	xs_sidplay2=no
 	else
 	xs_sidplay2=yes
+	xs_sidplay1=no
 	xs_sidplay2_includes="$withval/include"
 	xs_sidplay2_library="$withval/lib"
 	fi
@@ -124,6 +135,7 @@
 
 
 OPT_SIDPLAY2="no"
+if test "$OPT_SIDPLAY1" = no; then
 if test "$xs_sidplay2" = yes; then
 LIBSIDPLAY2_REQUIRED_VERSION="2.1.0"
 XS_PATH_LIBSIDPLAY2
@@ -140,6 +152,7 @@
 AC_MSG_ERROR([libSIDPlay2 library and/or headers were not found!])
 fi
 fi
+fi
 
 
 dnl ***
@@ -151,6 +164,23 @@
 fi
 fi
 
+dnl ***
+dnl *** Checks for header files, types and functions
+dnl ***
+AC_HEADER_STDC
+AC_CHECK_HEADERS([stdlib.h string.h unistd.h])
+
+AC_HEADER_STDBOOL
+AC_C_CONST
+AC_C_INLINE
+AC_TYPE_SIZE_T
+AC_C_VOLATILE
+
+AC_FUNC_MALLOC
+AC_TYPE_SIGNAL
+AC_FUNC_STAT
+AC_CHECK_FUNCS([memset strcasecmp strerror strrchr])
+
 
 dnl ***
 dnl *** Check XMMS version
@@ -169,16 +199,6 @@
 
 
 dnl ***
-dnl *** Define some templates
-dnl ***
-AC_DEFINE(HAVE_XMMSEXTRA, 0, Define to 1 if you have XMMS version 1.2.5 or later)
-AC_DEFINE(HAVE_SIDPLAY1, 0, Define to 1 if you want to use libSIDPlay 1)
-AC_DEFINE(HAVE_SIDPLAY2, 0, Define to 1 if you want to use libSIDPlay 2)
-AC_DEFINE(HAVE_RESID_BUILDER, 0, Define to 1 if you have reSID with libSIDPlay 2)
-AC_DEFINE(HAVE_HARDSID_BUILDER, 0, Define to 1 if you have HardSID with libSIDPlay 2)
-
-
-dnl ***
 dnl *** And finally, output the all generatable files!
 dnl ***
 AC_CONFIG_FILES([
@@ -199,5 +219,6 @@
 	XMMS >= v1.2.5 extra features : $OPT_XMMSEXTRA
 	libSIDPlay 1 support          : $OPT_SIDPLAY1
 	libSIDPlay 2 support          : $OPT_SIDPLAY2
+		Included builders     : $xs_builders
 
 ])