-
Notifications
You must be signed in to change notification settings - Fork 13
/
configure.ac
85 lines (67 loc) · 1.73 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
82
83
84
85
AC_INIT([meshwork], 0.1, [[email protected]])
AC_PREREQ(2.53)
AC_CANONICAL_SYSTEM
AM_INIT_AUTOMAKE([1.9 tar-ustar])
AM_MAINTAINER_MODE
AC_PROG_INTLTOOL([0.25])
AC_PROG_INSTALL
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
dnl C# compiler
AC_PATH_PROG(CSC, csc, no)
AC_PATH_PROG(MCS, gmcs, no)
AC_PATH_PROG(MONO, mono, no)
CS="C#"
if test "x$CSC" = "xno" -a "x$MCS" = "xno" ; then
dnl AC_MSG_ERROR([You need to install a C# compiler])
AC_MSG_ERROR([No $CS compiler found])
fi
if test "x$MCS" = "xno" ; then
MCS=$CSC
fi
if test "x$MONO" = "xno"; then
AC_MSG_ERROR([No mono runtime found])
fi
dnl library dependencies
MONO_REQUIRED_VERSION=1.2.6
GTKSHARP_REQUIRED_VERSION=2.8.2
PKG_CHECK_MODULES(MONO, mono >= $MONO_REQUIRED_VERSION)
PKG_CHECK_MODULES(GTKSHARP, gtk-sharp-2.0 >= $GTKSHARP_REQUIRED_VERSION)
AC_SUBST(GTK_SHARP_LIBS)
PKG_CHECK_MODULES(GLADE_SHARP, glade-sharp-2.0 >= $GTKSHARP_REQUIRED_VERSION)
AC_SUBST(GLADE_SHARP_LIBS)
dnl Intl
ALL_LINGUAS=""
GETTEXT_PACKAGE=meshwork
AC_SUBST(GETTEXT_PACKAGE)
AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE", [Gettext package])
AM_GLIB_GNU_GETTEXT
# CSC_FLAGS="-langversion:ISO-1"
CSC_FLAGS=""
MESHWORK_DIR='$(prefix)/lib/meshwork'
AC_SUBST(MCS)
AC_SUBST(MESHWORK_DIR)
AC_SUBST(CSC_FLAGS)
AC_OUTPUT([
meshwork.pc
meshwork-gtk.pc
Makefile
src/Makefile
src/FileFind.Meshwork/Makefile
src/FileFind.Meshwork.GtkClient/Makefile
src/FileFind.Meshwork.DaemonClient/Makefile
contrib/Makefile
resources/Makefile
po/Makefile.in
plugins/Makefile
plugins/Debug/Makefile
])
echo "
meshwork-$VERSION
Install Prefix: ${prefix}
Mono C# Compiler: ${MCS}
Mono Runtime: ${MONO}
"