2002-04-25 11:17:54 +02:00
|
|
|
|
2012-10-14 16:08:52 +02:00
|
|
|
AC_INIT(gtk-sharp, 2.99.0)
|
|
|
|
|
|
|
|
AM_INIT_AUTOMAKE([1.10 no-dist-gzip dist-bzip2 tar-ustar foreign])
|
|
|
|
AC_CANONICAL_HOST
|
2002-04-25 11:17:54 +02:00
|
|
|
AM_CONFIG_HEADER(config.h)
|
|
|
|
AM_MAINTAINER_MODE
|
|
|
|
|
2010-11-22 04:18:06 +01:00
|
|
|
API_VERSION=3.0.0.0
|
2004-04-30 20:24:16 +02:00
|
|
|
AC_SUBST(API_VERSION)
|
2012-07-02 19:56:06 +02:00
|
|
|
CAIRO_API_VERSION=1.10.0.0
|
|
|
|
AC_SUBST(CAIRO_API_VERSION)
|
2010-11-22 04:18:06 +01:00
|
|
|
POLICY_VERSIONS=""
|
2005-09-22 06:26:52 +02:00
|
|
|
AC_SUBST(POLICY_VERSIONS)
|
2004-04-30 20:24:16 +02:00
|
|
|
|
2009-08-30 22:06:33 +02:00
|
|
|
PACKAGE_VERSION=gtk-sharp-3.0
|
2004-10-29 22:33:07 +02:00
|
|
|
AC_SUBST(PACKAGE_VERSION)
|
|
|
|
|
2007-10-22 19:34:02 +02:00
|
|
|
WIN64DEFINES=
|
|
|
|
|
2005-08-25 22:59:21 +02:00
|
|
|
case "$host" in
|
2007-10-22 19:34:02 +02:00
|
|
|
x86_64-*-mingw*|x86_64-*-cygwin*)
|
|
|
|
WIN64DEFINES="-define:WIN64LONGS"
|
|
|
|
platform_win32=yes
|
2009-11-30 21:40:34 +01:00
|
|
|
AC_MSG_RESULT([yes, 64-bit])
|
2007-10-22 19:34:02 +02:00
|
|
|
AC_DEFINE(PLATFORM_WIN32,1,[Platform is Win32])
|
2009-01-12 23:14:25 +01:00
|
|
|
if test "x$cross_compiling" = "xno"; then
|
|
|
|
CC="gcc -mno-cygwin -g"
|
|
|
|
HOST_CC="gcc"
|
|
|
|
fi
|
2007-10-22 19:34:02 +02:00
|
|
|
;;
|
2005-08-25 22:59:21 +02:00
|
|
|
*-*-mingw*|*-*-cygwin*)
|
|
|
|
platform_win32=yes
|
2009-11-30 21:40:34 +01:00
|
|
|
AC_MSG_RESULT([yes, 32-bit])
|
2005-08-25 22:59:21 +02:00
|
|
|
AC_DEFINE(PLATFORM_WIN32,1,[Platform is Win32])
|
2009-01-12 23:14:25 +01:00
|
|
|
if test "x$cross_compiling" = "xno"; then
|
|
|
|
CC="gcc -mno-cygwin -g"
|
|
|
|
HOST_CC="gcc"
|
|
|
|
fi
|
2005-08-25 22:59:21 +02:00
|
|
|
;;
|
|
|
|
*)
|
|
|
|
platform_win32=no
|
2009-11-30 21:40:34 +01:00
|
|
|
AC_MSG_RESULT([no])
|
2005-08-25 22:59:21 +02:00
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
|
|
|
AM_CONDITIONAL(PLATFORM_WIN32, test x$platform_win32 = xyes)
|
|
|
|
|
2002-04-25 11:17:54 +02:00
|
|
|
AC_CHECK_TOOL(CC, gcc, gcc)
|
|
|
|
AC_PROG_CC
|
|
|
|
AM_PROG_CC_STDC
|
|
|
|
AC_PROG_INSTALL
|
|
|
|
|
|
|
|
dnl may require a specific autoconf version
|
|
|
|
dnl AC_PROG_CC_FOR_BUILD
|
|
|
|
dnl CC_FOR_BUILD not automatically detected
|
|
|
|
CC_FOR_BUILD=$CC
|
|
|
|
BUILD_EXEEXT=
|
|
|
|
if test "x$cross_compiling" = "xyes"; then
|
|
|
|
CC_FOR_BUILD=cc
|
|
|
|
BUILD_EXEEXT=""
|
|
|
|
fi
|
|
|
|
AC_SUBST(CC_FOR_BUILD)
|
|
|
|
AC_SUBST(HOST_CC)
|
|
|
|
AC_SUBST(BUILD_EXEEXT)
|
|
|
|
|
|
|
|
# Set STDC_HEADERS
|
|
|
|
AC_HEADER_STDC
|
2004-06-11 20:19:41 +02:00
|
|
|
AC_LIBTOOL_WIN32_DLL
|
2002-04-25 11:17:54 +02:00
|
|
|
AM_PROG_LIBTOOL
|
|
|
|
|
|
|
|
# not 64 bit clean in cross-compile
|
|
|
|
AC_CHECK_SIZEOF(void *, 4)
|
|
|
|
|
2008-11-26 18:41:12 +01:00
|
|
|
CFLAGS="${CFLAGS} -g -Wall -Wunused -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Wshadow -Wpointer-arith -Wno-cast-qual -Wcast-align -Wwrite-strings"
|
2002-04-25 11:17:54 +02:00
|
|
|
|
2005-05-06 22:36:21 +02:00
|
|
|
if test "x$enable_maintainer_mode" = "xyes"; then
|
2005-05-12 02:02:21 +02:00
|
|
|
DEBUG_FLAGS='-debug'
|
2011-01-09 18:24:16 +01:00
|
|
|
RUNTIME_DEBUG_FLAGS=' --debug'
|
2005-05-06 22:36:21 +02:00
|
|
|
else
|
2005-05-04 22:53:02 +02:00
|
|
|
DEBUG_FLAGS=
|
2011-01-09 18:24:16 +01:00
|
|
|
RUNTIME_DEBUG_FLAGS=
|
2005-04-11 16:56:29 +02:00
|
|
|
AC_ARG_ENABLE(debug, [ --enable-debug Build debugger (.mdb) files for dlls],
|
2005-05-12 02:02:21 +02:00
|
|
|
DEBUG_FLAGS='-debug'
|
2005-04-11 16:56:29 +02:00
|
|
|
)
|
2005-05-06 22:36:21 +02:00
|
|
|
fi
|
2005-05-04 22:53:02 +02:00
|
|
|
|
2002-04-25 11:17:54 +02:00
|
|
|
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
|
|
|
|
|
2007-12-05 00:52:08 +01:00
|
|
|
AC_CHECK_SIZEOF(off_t)
|
|
|
|
OFF_T_FLAGS="-define:OFF_T_$ac_cv_sizeof_off_t"
|
|
|
|
AC_SUBST(OFF_T_FLAGS)
|
|
|
|
|
2010-11-22 04:18:06 +01:00
|
|
|
MONO_REQUIRED_VERSION=2.8
|
2004-05-04 00:59:30 +02:00
|
|
|
PKG_CHECK_MODULES(MONO_DEPENDENCY, mono >= $MONO_REQUIRED_VERSION, has_mono=true, has_mono=false)
|
2003-11-07 19:14:35 +01:00
|
|
|
|
2005-08-26 00:32:18 +02:00
|
|
|
AC_PATH_PROG(GACUTIL, gacutil, no)
|
|
|
|
if test "x$GACUTIL" = "xno" ; then
|
|
|
|
AC_MSG_ERROR([No gacutil tool found. You need to install either the mono or .Net SDK.])
|
|
|
|
fi
|
|
|
|
|
2005-09-22 06:26:52 +02:00
|
|
|
AC_PATH_PROG(AL, al, no)
|
|
|
|
if test "x$AL" = "xno" ; then
|
|
|
|
AC_MSG_ERROR([No al tool found. You need to install either the mono or .Net SDK.])
|
|
|
|
fi
|
|
|
|
|
2004-03-12 22:18:11 +01:00
|
|
|
if test "x$has_mono" = "xtrue"; then
|
2005-04-28 00:05:12 +02:00
|
|
|
GACUTIL_FLAGS='/package $(PACKAGE_VERSION) /gacdir $(DESTDIR)$(prefix)/lib'
|
2004-06-11 20:19:41 +02:00
|
|
|
GENERATED_SOURCES=generated/*.cs
|
2004-06-11 21:54:52 +02:00
|
|
|
AC_PATH_PROG(RUNTIME, mono, no)
|
2005-11-01 06:12:12 +01:00
|
|
|
|
|
|
|
# If mono is found, it's in the path. Require it to be in the path at runtime as well
|
|
|
|
if test "x$RUNTIME" != "no" ; then
|
2011-01-09 18:24:16 +01:00
|
|
|
RUNTIME="mono$RUNTIME_DEBUG_FLAGS"
|
2005-11-01 06:12:12 +01:00
|
|
|
fi
|
|
|
|
|
2009-07-02 22:18:10 +02:00
|
|
|
AC_PATH_PROG(CSC, gmcs, no)
|
2004-03-10 16:57:33 +01:00
|
|
|
if test `uname -s` = "Darwin"; then
|
2004-04-29 17:00:24 +02:00
|
|
|
LIB_PREFIX=
|
|
|
|
LIB_SUFFIX=.dylib
|
2004-03-10 16:57:33 +01:00
|
|
|
else
|
2004-04-29 17:00:24 +02:00
|
|
|
LIB_PREFIX=.so
|
|
|
|
LIB_SUFFIX=
|
2004-03-10 16:57:33 +01:00
|
|
|
fi
|
2005-08-25 22:59:21 +02:00
|
|
|
SDCHECK="`$GACUTIL /l |grep ^System.Drawing, | head -n1 |cut -f1 -d','`"
|
|
|
|
if test "x$SDCHECK" = "xSystem.Drawing"; then
|
|
|
|
enable_dotnet=yes
|
|
|
|
else
|
|
|
|
enable_dotnet=no
|
|
|
|
fi
|
2004-03-12 22:18:11 +01:00
|
|
|
else
|
2004-03-22 07:23:07 +01:00
|
|
|
AC_PATH_PROG(CSC, csc.exe, no)
|
2004-06-10 21:45:20 +02:00
|
|
|
GACUTIL_FLAGS=
|
2004-06-11 20:19:41 +02:00
|
|
|
GENERATED_SOURCES=generated\\\\*.cs
|
2005-08-25 22:59:21 +02:00
|
|
|
enable_dotnet=yes
|
2004-06-10 21:45:20 +02:00
|
|
|
|
2004-03-22 07:23:07 +01:00
|
|
|
if test x$CSC = "xno"; then
|
2009-05-18 20:15:22 +02:00
|
|
|
AC_MSG_ERROR([You need to install either mono (>=$MONO_REQUIRED_VERSION) or .Net])
|
2004-03-12 22:18:11 +01:00
|
|
|
else
|
|
|
|
RUNTIME=
|
2004-04-29 17:00:24 +02:00
|
|
|
LIB_PREFIX=
|
|
|
|
LIB_SUFFIX=.dylib
|
2004-03-12 22:18:11 +01:00
|
|
|
fi
|
|
|
|
fi
|
2004-03-22 07:23:07 +01:00
|
|
|
|
|
|
|
CS="C#"
|
|
|
|
if test "x$CSC" = "xno" ; then
|
|
|
|
AC_MSG_ERROR([No $CS compiler found])
|
|
|
|
fi
|
|
|
|
|
2004-03-12 22:18:11 +01:00
|
|
|
AC_SUBST(RUNTIME)
|
|
|
|
AC_SUBST(CSC)
|
2004-05-01 05:38:54 +02:00
|
|
|
AC_SUBST(GACUTIL)
|
2004-06-10 21:45:20 +02:00
|
|
|
AC_SUBST(GACUTIL_FLAGS)
|
2004-04-29 17:00:24 +02:00
|
|
|
AC_SUBST(LIB_PREFIX)
|
|
|
|
AC_SUBST(LIB_SUFFIX)
|
2004-06-11 20:19:41 +02:00
|
|
|
AC_SUBST(GENERATED_SOURCES)
|
2004-03-12 22:18:11 +01:00
|
|
|
|
2011-02-12 22:30:20 +01:00
|
|
|
GTK_REQUIRED_VERSION=3.0.0
|
|
|
|
GLIB_REQUIRED_VERSION=2.28.0
|
2005-05-04 22:53:02 +02:00
|
|
|
|
2009-01-05 17:30:59 +01:00
|
|
|
PKG_CHECK_MODULES(GLIB, gobject-2.0 >= $GLIB_REQUIRED_VERSION)
|
2004-03-12 22:18:11 +01:00
|
|
|
AC_SUBST(GLIB_CFLAGS)
|
|
|
|
AC_SUBST(GLIB_LIBS)
|
|
|
|
|
2009-01-05 17:30:59 +01:00
|
|
|
PKG_CHECK_MODULES(GIO, gio-2.0 >= $GLIB_REQUIRED_VERSION)
|
2009-01-04 23:29:56 +01:00
|
|
|
AC_SUBST(GIO_CFLAGS)
|
|
|
|
AC_SUBST(GIO_LIBS)
|
|
|
|
|
2012-05-04 23:20:14 +02:00
|
|
|
CSFLAGS="$DEBUG_FLAGS $WIN64DEFINES"
|
2012-05-04 00:45:07 +02:00
|
|
|
PKG_CHECK_MODULES(GLIB_2_31,
|
|
|
|
glib-2.0 >= 2.31,
|
|
|
|
HAVE_GLIB_2_31_OR_HIGHER=yes, HAVE_GLIB_2_31_OR_HIGHER=no)
|
2012-05-04 23:20:14 +02:00
|
|
|
if test "x$HAVE_GLIB_2_31_OR_HIGHER" = "xyes" ; then
|
|
|
|
CSFLAGS="$CSFLAGS -define:DISABLE_GTHREAD_CHECK"
|
|
|
|
fi
|
|
|
|
AC_SUBST(CSFLAGS)
|
2012-05-04 00:45:07 +02:00
|
|
|
|
2005-05-04 22:53:02 +02:00
|
|
|
PKG_CHECK_MODULES(PANGO, pango)
|
2004-06-07 20:59:16 +02:00
|
|
|
AC_SUBST(PANGO_CFLAGS)
|
|
|
|
AC_SUBST(PANGO_LIBS)
|
|
|
|
|
2008-02-29 17:30:21 +01:00
|
|
|
PKG_CHECK_MODULES(ATK, atk)
|
|
|
|
AC_SUBST(ATK_CFLAGS)
|
|
|
|
AC_SUBST(ATK_LIBS)
|
|
|
|
|
2011-01-08 15:48:10 +01:00
|
|
|
PKG_CHECK_MODULES(GTK, gtk+-3.0 >= $GTK_REQUIRED_VERSION)
|
2004-04-30 21:08:16 +02:00
|
|
|
AC_SUBST(GTK_CFLAGS)
|
|
|
|
AC_SUBST(GTK_LIBS)
|
|
|
|
|
2011-01-08 15:48:10 +01:00
|
|
|
GDK_BACKEND=`pkg-config --variable=target gtk+-3.0`
|
2009-08-12 10:24:32 +02:00
|
|
|
AC_SUBST(GDK_BACKEND)
|
|
|
|
|
2009-01-06 18:38:06 +01:00
|
|
|
AC_PATH_PROG(MDOC, mdoc, no)
|
|
|
|
if test "x$MDOC" = "xno"; then
|
2005-05-23 22:41:51 +02:00
|
|
|
enable_monodoc=no
|
2005-09-07 18:54:16 +02:00
|
|
|
doc_sources_dir=
|
2005-08-29 02:02:37 +02:00
|
|
|
else
|
|
|
|
enable_monodoc=yes
|
2005-09-07 18:54:16 +02:00
|
|
|
doc_sources_dir="`pkg-config --variable=sourcesdir monodoc`"
|
2005-05-23 22:41:51 +02:00
|
|
|
fi
|
2009-01-06 18:38:06 +01:00
|
|
|
AC_SUBST(MDOC)
|
2005-05-23 22:41:51 +02:00
|
|
|
|
2005-01-12 01:11:08 +01:00
|
|
|
AM_CONDITIONAL(ENABLE_DOTNET, test "x$enable_dotnet" = "xyes")
|
2005-05-23 22:41:51 +02:00
|
|
|
AM_CONDITIONAL(ENABLE_MONODOC, test "x$enable_monodoc" = "xyes")
|
2002-04-25 11:17:54 +02:00
|
|
|
|
|
|
|
AC_SUBST(CFLAGS)
|
|
|
|
|
|
|
|
AC_OUTPUT([
|
2005-01-09 01:26:45 +01:00
|
|
|
AssemblyInfo.cs
|
|
|
|
Makefile
|
2005-09-22 06:26:52 +02:00
|
|
|
policy.config
|
2004-03-12 22:18:11 +01:00
|
|
|
sources/Makefile
|
2002-08-20 22:46:14 +02:00
|
|
|
parser/Makefile
|
2009-07-23 19:18:03 +02:00
|
|
|
parser/gapi-3.0.pc
|
|
|
|
parser/gapi3-fixup
|
|
|
|
parser/gapi3-parser
|
2002-08-20 22:54:28 +02:00
|
|
|
generator/Makefile
|
2009-07-23 19:18:03 +02:00
|
|
|
generator/gapi3-codegen
|
2002-05-02 23:57:41 +02:00
|
|
|
glib/Makefile
|
2009-08-30 22:06:33 +02:00
|
|
|
glib/glib-sharp-3.0.pc
|
2004-04-29 17:00:24 +02:00
|
|
|
glib/glib-sharp.dll.config
|
2009-01-04 23:29:56 +01:00
|
|
|
gio/Makefile
|
2009-08-30 22:06:33 +02:00
|
|
|
gio/gio-sharp-3.0.pc
|
2009-01-04 23:29:56 +01:00
|
|
|
gio/gio-sharp.dll.config
|
|
|
|
gio/glue/Makefile
|
2012-07-02 19:56:06 +02:00
|
|
|
cairo/AssemblyInfo.cs
|
2008-10-10 00:35:02 +02:00
|
|
|
cairo/Makefile
|
2002-05-02 23:57:41 +02:00
|
|
|
pango/Makefile
|
2004-04-29 17:00:24 +02:00
|
|
|
pango/pango-sharp.dll.config
|
2004-06-07 20:59:16 +02:00
|
|
|
pango/glue/Makefile
|
2002-05-02 23:57:41 +02:00
|
|
|
atk/Makefile
|
2004-04-29 17:00:24 +02:00
|
|
|
atk/atk-sharp.dll.config
|
2008-02-29 17:30:21 +01:00
|
|
|
atk/glue/Makefile
|
2002-05-02 23:57:41 +02:00
|
|
|
gdk/Makefile
|
2004-04-29 17:00:24 +02:00
|
|
|
gdk/gdk-sharp.dll.config
|
2002-05-02 23:57:41 +02:00
|
|
|
gtk/Makefile
|
2009-08-30 22:06:33 +02:00
|
|
|
gtk/gtk-sharp-3.0.pc
|
2004-04-29 17:00:24 +02:00
|
|
|
gtk/gtk-sharp.dll.config
|
2004-03-12 22:18:11 +01:00
|
|
|
gtk/glue/Makefile
|
2005-01-12 01:11:08 +01:00
|
|
|
gtkdotnet/Makefile
|
|
|
|
gtkdotnet/gtk-dotnet.dll.config
|
2009-08-30 22:06:33 +02:00
|
|
|
gtkdotnet/gtk-dotnet-3.0.pc
|
2004-03-31 00:32:46 +02:00
|
|
|
doc/Makefile
|
2004-03-12 22:18:11 +01:00
|
|
|
sample/GtkDemo/Makefile
|
2002-05-02 23:57:41 +02:00
|
|
|
sample/Makefile
|
2004-03-12 22:18:11 +01:00
|
|
|
sample/pixmaps/Makefile
|
|
|
|
sample/test/Makefile
|
2005-07-22 20:36:50 +02:00
|
|
|
sample/valtest/Makefile
|
|
|
|
sample/valtest/valtest.exe.config
|
2005-08-09 16:44:32 +02:00
|
|
|
sample/opaquetest/Makefile
|
|
|
|
sample/opaquetest/opaquetest.exe.config
|
2009-02-11 13:34:08 +01:00
|
|
|
sample/gio/Makefile
|
2009-02-11 14:05:59 +01:00
|
|
|
sample/gtk-gio/Makefile
|
2002-04-25 11:17:54 +02:00
|
|
|
])
|
|
|
|
|
2009-05-02 18:21:07 +02:00
|
|
|
if test x$platform_win32 = xyes; then
|
|
|
|
# Get rid of 'cyg' prefixes in library names
|
|
|
|
sed -e "s/\/cyg\//\/\//" libtool > libtool.new; mv libtool.new libtool; chmod 755 libtool
|
|
|
|
fi
|
|
|
|
|
2009-01-02 23:03:06 +01:00
|
|
|
if test "x$enable_mono_cairo" = "xyes"; then
|
|
|
|
cairo_comment="building local copy"
|
|
|
|
else
|
|
|
|
cairo_comment="using system assembly"
|
|
|
|
fi
|
|
|
|
|
2002-11-06 04:53:24 +01:00
|
|
|
echo "---"
|
|
|
|
echo "Configuration summary"
|
|
|
|
echo ""
|
|
|
|
echo " * Installation prefix = $prefix"
|
2005-04-11 16:56:29 +02:00
|
|
|
echo " * $CS compiler: $CSC $CSFLAGS"
|
2002-11-06 04:53:24 +01:00
|
|
|
echo ""
|
|
|
|
echo " Optional assemblies included in the build:"
|
|
|
|
echo ""
|
2009-01-02 23:03:06 +01:00
|
|
|
echo " * gtk-dotnet.dll: $enable_dotnet"
|
2002-11-06 04:53:24 +01:00
|
|
|
echo ""
|
|
|
|
echo " NOTE: if any of the above say 'no' you may install the"
|
|
|
|
echo " corresponding development packages for them, rerun"
|
|
|
|
echo " autogen.sh to include them in the build."
|
|
|
|
echo ""
|
2005-05-23 22:41:51 +02:00
|
|
|
echo " * Documentation build enabled: $enable_monodoc "
|
2005-09-07 18:54:16 +02:00
|
|
|
if test "x$enable_monodoc" = "xyes" -a "x$doc_sources_dir" != "x$prefix/lib/monodoc/sources"; then
|
|
|
|
echo " WARNING: The install prefix is different than the monodoc prefix."
|
|
|
|
echo " Monodoc will not be able to load the documentation."
|
|
|
|
fi
|
2002-11-06 04:53:24 +01:00
|
|
|
echo "---"
|
2002-04-25 11:17:54 +02:00
|
|
|
|