-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathbootstrap
executable file
·56 lines (41 loc) · 1.51 KB
/
bootstrap
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
#!/bin/sh
#set -e
echo "Initial preparation...this can take awhile, so sit tight..."
aclocalincludes=""
if test -d "/usr/local/share/aclocal"; then
if test "/usr/local/share/aclocal" != `aclocal --print-ac-dir`; then
aclocalincludes="$aclocalincludes -I /usr/local/share/aclocal"
fi
fi
#if test -d "$HOME/share/aclocal"; then
# if test "$HOME/share/aclocal" != `aclocal --print-ac-dir`; then
# aclocalincludes="$aclocalincludes -I $HOME/share/aclocal"
# fi
#fi
aclocal $aclocalincludes || exit
# Create config.h
autoheader || exit
# Create configure script
autoconf || exit
echo "Writing Makefiles:"
# Note: do _NOT_ include '.' here
MODULES="tools tools/disasm tools/compile tools/shapeconv tools/fold tools/flexpack tools/gimp-plugin tools/data2c misc convert convert/u8 convert/crusader filesys filesys/zip kernel games graphics graphics/fonts graphics/scalers audio audio/midi audio/midi/timidity world world/actors usecode gumps gumps/widgets conf system system/macosx"
for subdir in $MODULES; do
rm -f $subdir/Makefile
echo "# This file is generated automatically by bootstrap. Do not edit!" > $subdir/Makefile
echo "" >> $subdir/Makefile
echo "" >> $subdir/Makefile
echo "LPATH := $subdir" >> $subdir/Makefile
echo "" >> $subdir/Makefile
cat >> $subdir/Makefile <<'EOF'
all: all-$(LPATH) ;
clean: clean-$(LPATH) ;
# Catch all rule - call Makefile in parent dir
%::
cd .. && $(MAKE) $@
.PHONY: all clean
EOF
echo " $subdir/Makefile"
done
echo ""
echo "You are now ready to run ./configure ..."