|
From: <a_r...@gm...> - 2007-09-12 10:37:11
|
Hi!
Just in case, someone wants to contribute...
IIRC, the list does not like attachments, so configure.ac just inline:
==========
dnl First attempt to create a GNU auto* tools scheme for CRRC
dnl Sep 1 2007
dnl Jan Reucker <slo...@gm...>
dnl Andreas Rueckert <ma...@an...>
dnl Init the autoconf macros
AC_INIT(crrc-config, version-0.1)
dnl Init automake
AM_INIT_AUTOMAKE
dnl This project is written in C++
AC_LANG(C++)
dnl check for required libs
dnl Search for a portaudio lib
dnl Default is: no portaudio present
portaudio=0
dnl Check for Portaudio 18
AC_CHECK_LIB( portaudio, Pa_CountDevices, [portaudio=18], [])
dnl Check for Portaudio 19
AC_CHECK_LIB( portaudio, Pa_GetDeviceCount, [portaudio=19], [])
dnl Show the result
if test $portaudio == 18
then
AC_MSG_NOTICE([Portaudio 18 found])
else if test $portaudio == 19
then
AC_MSG_NOTICE([Portaudio 19 found])
else
AC_MSG_NOTICE([No Portaudio found])
fi
fi
dnl Search for SDL 1.2.x
SDL_VERSION=1.2.0
AM_PATH_SDL($SDL_VERSION,:,AC_MSG_ERROR([*** SDL version $SDL_VERSION not found!])
)
AM_CFLAGS="$AM_CFLAGS $SDL_CFLAGS"
AM_LDFLAGS="$AM_LDFLAGS $SDL_LIBS"
dnl Search for GLUT 3.7.x
AX_CHECK_GLUT
dnl Search for PLIB 1.8.4
dnl PLIB consist of several more or less independent
dnl components, so we better check each component we need.
AC_CHECK_HEADER(plib/ul.h)
AC_CHECK_HEADER(plib/sg.h)
AC_CHECK_HEADER(plib/ssg.h)
AC_CHECK_HEADER(plib/ssgaSky.h)
AC_CHECK_HEADER(plib/pu.h)
AC_CHECK_HEADER(plib/puAux.h)
if (test "x$ac_cv_header_plib_puAux_h" != "xyes") \
|| (test "x$ac_cv_header_plib_pu_h" != "xyes") \
|| (test "x$ac_cv_header_plib_ssgaSky_h" != "xyes") \
|| (test "x$ac_cv_header_plib_ssg_h" != "xyes") \
|| (test "x$ac_cv_header_plib_sg_h" != "xyes") \
|| (test "x$ac_cv_header_plib_ul_h" != "xyes"); then
echo
echo "You *must* have the plib library installed on your system to build CRRC!"
echo
echo "configure aborted."
exit
fi
dnl Thanks to the FlightGear guys for this piece of code...
AC_MSG_CHECKING([for plib 1.8.4 or newer])
AC_TRY_RUN([
#include <plib/ul.h>
#define MIN_PLIB_VERSION 184
int main() {
if ( PLIB_VERSION < MIN_PLIB_VERSION ) {
return -1;
}
return 0;
}
],
AC_MSG_RESULT(yes),
[AC_MSG_RESULT(wrong version);
AC_MSG_ERROR([Install plib 1.8.4 or later first...])],
AC_MSG_RESULT(yes)
)
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
==========
If you want to test this, drop me a note, since you a m4 dir. Jan tagged
this status in CVS and created a tarball.
The heli stuff is somewhat more complicated, so I guess a CVS branch would be
the better alternative to work on it...
Ciao,
Andreas
--
Psssst! Schon vom neuen GMX MultiMessenger gehört?
Der kanns mit allen: http://www.gmx.net/de/go/multimessenger
|