forked from ServUO/ServUO
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
42 lines (33 loc) · 1.09 KB
/
Makefile
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
MCS=mcs
CURPATH=`pwd`
SRVPATH=${CURPATH}/Server
SDKPATH=${CURPATH}/Ultima
REFS=System.Drawing.dll
NOWARNS=0618,0219,0414,1635
# Detect whether we are on 64 bit environment or not
LBITS := $(shell getconf LONG_BIT)
ifeq ($(LBITS),64)
MONO=mono64
else
MONO=mono
endif
PHONY : default build clean run
default: run
run: build
${CURPATH}/ServUO.sh
build: ServUO.sh
clean:
rm -f ServUO.sh
rm -f ServUO.MONO.exe
rm -f ServUO.MONO.pdb
rm -f Ultima.dll
rm -f Ultima.pdb
rm -f *.bin
Ultima.dll: Ultima/*.cs
${MCS} -target:library -out:${CURPATH}/Ultima.dll -r:${REFS} -d:ServUO -d:NEWTIMERS -nowarn:${NOWARNS} -debug -nologo -optimize -unsafe -recurse:${SDKPATH}/*.cs
ServUO.MONO.exe: Ultima.dll Server/*.cs
${MCS} -win32icon:${SRVPATH}/servuo.ico -r:${CURPATH}/Ultima.dll,${REFS} -nowarn:${NOWARNS} -target:exe -out:${CURPATH}/ServUO.MONO.exe -d:ServUO -d:NEWTIMERS -d:MONO -debug -nologo -optimize -unsafe -recurse:${SRVPATH}/*.cs
ServUO.sh: ServUO.MONO.exe
echo "#!/bin/sh" > ${CURPATH}/ServUO.sh
echo "${MONO} ${CURPATH}/ServUO.MONO.exe" >> ${CURPATH}/ServUO.sh
chmod a+x ${CURPATH}/ServUO.sh