1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76
|
AC_INIT(gudev-sharp, 0.1)
AC_CANONICAL_SYSTEM
AM_INIT_AUTOMAKE(gudev-sharp-1.0, 0.1)
AM_MAINTAINER_MODE
API_VERSION=1.0.0.0
AC_SUBST(API_VERSION)
MONO_REQUIRED_VERSION=2.0
AC_MSG_CHECKING([whether we're compiling from bzr])
if test -f "$srcdir/.bzr" ; then
from_bzr=yes
else
from_bzr=no
fi
AC_MSG_RESULT($from_bzr)
AC_SUBST(PATH)
AC_SUBST(LD_LIBRARY_PATH)
dnl Find pkg-config
AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
if test "x$PKG_CONFIG" = "xno"; then
AC_MSG_ERROR([You need to install pkg-config])
fi
dnl Find GTK
BUILD_GTK_CFLAGS=`$PKG_CONFIG --cflags gtk+-2.0`
BUILD_GTK_LIBS=`$PKG_CONFIG --libs gtk+-2.0`
AC_SUBST(BUILD_GTK_CFLAGS)
AC_SUBST(BUILD_GTK_LIBS)
GTK_REQUIRED_VERSION=2.0.0
MONO_REQUIRED_VERSION=2.0
UDEV_REQUIRED_VERSION=146
PKG_CHECK_MODULES(BASE_DEPENDENCIES, gtk+-2.0 >= $GTK_REQUIRED_VERSION gmodule-2.0 >= $GTK_REQUIRED_VERSION gudev-1.0 >= $UDEV_REQUIRED_VERSION)
PKG_CHECK_MODULES(MONO_DEPENDENCY, mono >= $MONO_REQUIRED_VERSION, has_mono=true, has_mono=false)
GENERATED_SOURCES=generated/*.cs
AC_PATH_PROG(RUNTIME, mono, no)
AC_PATH_PROG(CSC, gmcs, no)
LIB_PREFIX=.so
LIB_SUFFIX=
AC_SUBST(GENERATED_SOURCES)
AC_SUBST(LIB_PREFIX)
AC_SUBST(LIB_SUFFIX)
AC_SUBST(BASE_DEPENDENCIES_CFLAGS)
AC_SUBST(BASE_DEPENDENCIES_LIBS)
dnl Find Gtk#
PKG_CHECK_MODULES(GTK_SHARP, gtk-sharp-2.0 >= 1.9.0)
AC_SUBST(GTK_SHARP_CFLAGS)
AC_SUBST(GTK_SHARP_LIBS)
dnl Find GAPI
PKG_CHECK_MODULES(GAPI, gapi-2.0 >= 1.9.0)
AC_PATH_PROG(GACUTIL, gacutil, no)
if test "x$GACUTIL" = "xno" ; then
AC_MSG_ERROR([No gacutil tool found])
fi
AC_SUBST(GACUTIL)
AC_OUTPUT([
Makefile
gudev/gudev-sharp.dll.config
gudev/Makefile
gudev/AssemblyInfo.cs
gudev-sharp-1.0.pc
])
|