summaryrefslogtreecommitdiffstats
path: root/crawl-ref/domake.sh
blob: 9db99e2732fbf9a46a1d52142647c95ed9f0c12d (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/usr/bin/env bash
#jmf: automate making normal & wizard binaries, until they merge
#jmf: N.B.: requires symlink directories; run ./dolinks.sh to make

MAKE=make
make --version &> /dev/null
if [ $? != 0 ]; then
	# BSD make returns an error code if you try '--version'. GNU make doesn't.
	MAKE=gmake
fi

pushd NORMAL/source ; $MAKE ; popd
pushd WIZARD/source ; $MAKE wizard ; popd

if [ -f NORMAL/source/crawl ]; then
	ln -sf NORMAL/source/crawl ncrawl
fi

if [ -f WIZARD/source/crawl ]; then
	ln -sf WIZARD/source/crawl wcrawl
fi