-
Notifications
You must be signed in to change notification settings - Fork 0
/
configure.ac
82 lines (68 loc) · 2.08 KB
/
configure.ac
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
77
78
79
80
81
AC_PREREQ([2.54])
AC_INIT([Ude], [0.1])
AM_INIT_AUTOMAKE([foreign])
dnl AC_SUBST([ACLOCAL_AMFLAGS], ["-I m4 \${ACLOCAL_FLAGS}"])
dnl 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
SHAMROCK_EXPAND_LIBDIR
SHAMROCK_EXPAND_BINDIR
SHAMROCK_EXPAND_DATADIR
AC_PROG_INSTALL
AC_PATH_PROG(GMCS, gmcs, no)
if test "x$GMCS" = "xno"; then
AC_MSG_ERROR([gmcs Not found])
fi
AC_ARG_ENABLE(debug_any_cpu,
AC_HELP_STRING([--enable-debug_any_cpu],
[Use 'DEBUG_ANY_CPU' Configuration [default=NO]]),
enable_debug_any_cpu=yes, enable_debug_any_cpu=no)
AM_CONDITIONAL(ENABLE_DEBUG_ANY_CPU, test x$enable_debug_any_cpu = xyes)
if test "x$enable_debug_any_cpu" = "xyes" ; then
CONFIG_REQUESTED="yes"
fi
AC_ARG_ENABLE(release_any_cpu,
AC_HELP_STRING([--enable-release_any_cpu],
[Use 'RELEASE_ANY_CPU' Configuration [default=YES]]),
enable_release_any_cpu=yes, enable_release_any_cpu=no)
AM_CONDITIONAL(ENABLE_RELEASE_ANY_CPU, test x$enable_release_any_cpu = xyes)
if test "x$enable_release_any_cpu" = "xyes" ; then
CONFIG_REQUESTED="yes"
fi
if test -z "$CONFIG_REQUESTED" ; then
AM_CONDITIONAL(ENABLE_RELEASE_ANY_CPU, true)
enable_release_any_cpu=yes
fi
dnl package checks, common for all configs
dnl PKG_CHECK_MODULES([MONO_NUNIT], [mono-nunit])
AC_ARG_ENABLE(tests,
AC_HELP_STRING([--enable-tests],
[build unit tests [default=yes]]),
enable_tests=${enableval}, enable_tests=no)
AM_CONDITIONAL(ENABLE_TESTS, test x$enable_tests = xyes)
if test "x$enable_tests" = "xyes"; then
PKG_CHECK_MODULES([MONO_NUNIT], [mono-nunit])
fi
AC_SUBST(MONO_NUNIT_LIBS)
AM_CONDITIONAL(ENABLE_TESTS, test x$enable_tests = xyes)
AC_CONFIG_FILES([
Makefile
m4/Makefile
src/Example/Makefile
src/Example/udetect
src/Library/ude.pc
src/Library/Makefile
src/Tests/Makefile
])
AC_OUTPUT
echo "
${PACKAGE}-${VERSION}
Configuration summary
* Install Prefix: ${prefix}
* Datadir: ${expanded_datadir}
* Libdir: ${expanded_libdir}
* C# compiler: ${GMCS}
* Unit tests: ${enable_tests}
"