patch #5807
[mldonkey.git] / configure
blobbe53cbefaa43999a08b6fe76ce63e21211cfd0ad
1 #!/bin/sh
3 mkdir -p build
4 rm -f icons/big/*.ml_icon
5 rm -f icons/small/*.ml_icon
6 rm -f icons/*.ml_icon
7 rm -f *.cma *.cmxa *.a
8 rm -f mlgnut mlnap mlbt mldonkey mlslsk mldonkey_gui*
9 rm -f build/*.cma build/*.cmxa build/*.a
10 touch .depend
12 case "`uname -s`" in
13 *FreeBSD*)
14 CPPFLAGS="${CPPFLAGS} -I/usr/local/include"
15 export CPPFLAGS
16 LDFLAGS="${LDFLAGS} -L/usr/local/lib"
17 export LDFLAGS
21 esac
23 if test ! -d config; then
24 echo "Missing ./config/ directory. Re-download mldonkey"
25 else
26 cd config \
27 && if test ! -f ./configure; then
28 if which autoconf259; then
29 ac="autoconf259"
30 else if which autoconf-2.59; then
31 ac="autoconf-2.59"
32 else if which autoconf-2.5x; then
33 ac="autoconf-2.5x"
34 else
35 ac="autoconf"
36 fi; fi; fi
37 echo "Running Autoconf ($ac)..."
38 $ac
39 fi \
40 && if test ! -f ../Makefile; then
41 echo "Running m4 to generate Makefile..."
42 m4 Makefile.in > ../Makefile
43 fi \
44 && ./configure $*