-
Notifications
You must be signed in to change notification settings - Fork 29
/
Copy pathcompile-mono.sh
executable file
·47 lines (42 loc) · 1.16 KB
/
compile-mono.sh
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
#!/bin/sh
if [ -z "$STAGE" ]; then
echo "Set the STAGE environment variable to the directory to install the mono build to"
exit 1
fi
plat=`uname -s`
if [ "$plat" = "Darwin" ]; then
if [ -z "$1" ]; then
echo "Pass either 32 or 64 to specify the architecture of the build for OS X"
exit 1
fi
arch="$1"
shift 1
if [ "$arch" = "32" ]; then
EXTRA_FLAGS="--build=i686-apple-darwin10"
else
EXTRA_FLAGS="--build=x86_64-apple-darwin10"
fi
export CFLAGS="-mmacosx-version-min=10.6"
export CXXFLAGS=${CFLAGS}
export LDFLAGS=${CFLAGS}
EXTRA_FLAGS="${EXTRA_FLAGS} --without-x"
fi
if [ ! -x ./configure ]; then
echo "Could not find configure"
exit 2
fi
./configure --prefix="$STAGE" \
--with-ikvm-native=yes --with-jit=yes \
--with-moonlight=no --with-monotouch=no \
--enable-minimal=debug,portability,profiler \
--disable-mono-debugger \
--with-sgen=yes \
--with-jit=yes \
--with-mcs-docs=no \
--with-profile2=no \
--with-profile4=yes \
${EXTRA_FLAGS} \
"$@"
exit
make -j6
make install