forked from mono/mono-basic
-
Notifications
You must be signed in to change notification settings - Fork 0
/
configure
executable file
·66 lines (61 loc) · 2.73 KB
/
configure
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
#!/bin/sh
VERSION=2.11
prefix=/usr/local
configured_profiles=
moonlight_sdk_location=
monotouch_sdk_location="`pwd`/../mono/mcs/class/lib/monotouch"
monodroid_sdk_location="`pwd`/../mono/mcs/class/lib/monodroid"
while test x$1 != x; do
case $1 in
--prefix=*)
prefix=`echo $1 | sed 's/--prefix=//'`
;;
--moonlight-sdk-location=*)
moonlight_sdk_location=`echo $1 | sed 's/--moonlight-sdk-location=//'`
configured_profiles="moonlight $configured_profiles"
;;
--prefix)
echo --prefix needs an argument: --prefix=directory >&2
;;
--with-monotouch=yes)
configured_profiles="monotouch $configured_profiles"
;;
--monotouch-sdk-location=*)
configured_profiles="monotouch $configured_profiles"
monotouch_sdk_location=`echo $1 | sed 's/--monotouch-sdk-location=//'`
;;
--with-monodroid=yes)
configured_profiles="monodroid $configured_profiles"
;;
--monodroid-sdk-location=*)
configured_profiles="monodroid $configured_profiles"
monodroid_sdk_location=`echo $1 | sed 's/--monodroid-sdk-location=//'`
;;
--with-moonlight=yes)
configured_profiles="moonlight $configured_profiles"
;;
*)
echo Unknown argument $1 >&2
esac
shift
done
if test "x$moonlight_sdk_location" = "x"; then
if test "x`echo $configured_profiles | grep moonlight`" != "x"; then
echo Configure error: --with-moonlight=yes requires --moonlight-sdk-location
exit 1
fi
fi
echo "prefix=$prefix" > build/config.make
echo "exec_prefix=\${prefix}" >> build/config.make
echo "mono_libdir=\${exec_prefix}/lib" >> build/config.make
echo "man_dir=\${exec_prefix}/share/man" >> build/config.make
echo "man1_dir=\${man_dir}/man1" >> build/config.make
echo "MCS_FLAGS=-debug+" >> build/config.make
echo "RUNTIME=mono" >> build/config.make
echo "MONO_BASIC_VERSION=$VERSION" >> build/config.make
echo "VERSION :=$VERSION" >> build/config.make
echo "CONFIGURED_PROFILES :=$configured_profiles" >> build/config.make
echo "MOONLIGHT_SDK_LOCATION :=$sdk_location" >> build/config.make
echo "MONOTOUCH_SDK_LOCATION=$monotouch_sdk_location" >> build/config.make
echo "MONODROID_SDK_LOCATION=$monodroid_sdk_location" >> build/config.make
echo "mono-basic $VERSION module configured to use prefix=$prefix"