1 m4_define([adg_lua_version],[0.0.1])
3 m4_define([cpml_prereq],[0.6.3])
4 m4_define([cpml_api_version],1.0)
5 m4_define([adg_prereq],cpml_prereq)
6 m4_define([adg_api_version],1.0)
7 m4_define([lua_prereq],5.1.0)
12 dnl autoconf and automake versions here should be the same
13 dnl as the ones required by the adg package (just for laziness)
15 AC_INIT([adg-lua],adg_lua_version,[http://dev.entidi.com/p/adg/],[adg-lua],[http://adg.entidi.com/])
16 AC_CONFIG_SRCDIR([configure.ac])
17 AC_CONFIG_AUX_DIR([build])
18 AC_CONFIG_MACRO_DIR([build])
19 AM_INIT_AUTOMAKE([1.11 gnits no-dist-gzip dist-bzip2 -Wall -Wno-portability])
20 AM_SILENT_RULES([yes])
28 AC_PATH_PROG([LGOB_PARSER],[lgob-gir-parser],[/usr/bin/lgob-gir-parser])
29 AC_PATH_PROG([LGOB_GENERATOR],[lgob-generator],[/usr/bin/lgob-generator])
31 # Libtool initialization
33 AC_MSG_CHECKING([which libtool initialization strategy to adopt])
34 AC_MSG_RESULT([m4_ifset([LT_INIT],[LT-INIT],[AC-PROG-LIBTOOL])])
36 [LT_INIT([disable-static win32-dll])],
42 # Check for required packages
44 PKG_CHECK_MODULES([CPML],[cpml-1 >= ]cpml_prereq)
45 PKG_CHECK_MODULES([ADG],[adg-1 >= ]adg_prereq)
46 PKG_CHECK_MODULES([LUA],[lua >= ]lua_prereq)
49 # Check for Lua/lgob dirs
51 AC_ARG_WITH(lua-includedir,
52 [AS_HELP_STRING([--with-lua-includedir],
53 [prefix where Lua headers are installed @<:@INSTALL_INC@:>@])],
54 lua_includedir="$withval", lua_includedir="$(${PKG_CONFIG} --variable=INSTALL_INC --define-variable=prefix='${prefix}' lua)")
55 AC_SUBST([LUA_INCLUDEDIR],"$lua_includedir")
56 AC_ARG_WITH(lua-cmoduledir,
57 [AS_HELP_STRING([--with-lua-cmoduledir],
58 [prefix where Lua C modules are installed @<:@INSTALL_CMOD@:>@])],
59 lua_cmoduledir="$withval", lua_cmoduledir="$(${PKG_CONFIG} --variable=INSTALL_CMOD --define-variable=prefix='${prefix}' lua)")
60 AC_SUBST([LUA_CMODULEDIR],"$lua_cmoduledir")
65 AC_SUBST([CPML_API_VERSION],cpml_api_version)
66 AC_SUBST([ADG_API_VERSION],adg_api_version)
71 AC_CONFIG_FILES([Makefile
80 AC_MSG_NOTICE([generating report
82 AC_PACKAGE_NAME adg_lua_version will be built with the following options:
83 ----------------------------------------------------------
84 CPML bindings version: cpml_api_version
85 ADG bindings version: adg_api_version
86 Path to Lua headers: ${lua_includedir}
87 Path to Lua C modules: ${lua_cmoduledir}