annotate autogen.sh @ 594:132642e44799

2004-10-09 Laszlo Dvornik <dvornik@gnome.hu> * hu.po: Updated Hungarian translation.
author ldvornik
date Sat, 09 Oct 2004 17:36:48 +0000
parents b2b4f5fa8fc7
children 2d3ea4db3106
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
1 #!/bin/sh
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
2 # Run this to generate all the initial makefiles, etc.
545
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
3 # This was derived from Glib's autogen.sh
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
4
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
5 srcdir=`dirname $0`
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
6 test -z "$srcdir" && srcdir=.
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
7
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
8 ORIGDIR=`pwd`
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
9 cd $srcdir
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
10 PROJECT=gFTP
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
11 TEST_TYPE=-f
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
12 FILE=lib/gftp.h
195
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
13 GETTEXTIZE=gettextize
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
14
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
15 DIE=0
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
16
545
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
17 AUTOMAKE=automake
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
18 ACLOCAL=aclocal
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
19 AUTOCONF=autoconf
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
20 AUTOHEADER=autoheader
195
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
21
545
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
22 autoconf_version=`$AUTOCONF --version 2>/dev/null`
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
23 if [ "x$autoconf_version" = "x" ] ; then
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
24 echo
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
25 echo "GNU autoconf must be installed to build gFTP"
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
26 echo "GNU autoconf is available from http://www.gnu.org/software/autoconf/"
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
27 DIE=1
195
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
28 fi
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
29
545
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
30 automake_version=`$AUTOMAKE --version 2>/dev/null`
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
31 if [ "x$automake_version" = "x" ] ; then
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
32 echo
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
33 echo "GNU automake must be installed to build gFTP"
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
34 echo "GNU automake is available from http://www.gnu.org/software/automake/"
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
35 DIE=1
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
36 fi
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
37
195
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
38 gettext_version=`$GETTEXTIZE --version 2>/dev/null | grep 'GNU'`
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
39 if [ "x$gettext_version" = "x" ] ; then
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
40 echo
545
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
41 echo "GNU gettext must be installed to build gFTP"
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
42 echo "GNU gettext is available from http://www.gnu.org/software/gettext/"
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
43 DIE=1
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
44 fi
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
45
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
46 if test "$DIE" -eq 1; then
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
47 exit 1
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
48 fi
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
49
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
50 test $TEST_TYPE $FILE || {
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
51 echo "You must run this script in the top-level $PROJECT directory"
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
52 exit 1
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
53 }
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
54
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
55 if test -z "$AUTOGEN_SUBDIR_MODE"; then
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
56 if test -z "$*"; then
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
57 echo "I am going to run ./configure with no arguments - if you wish "
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
58 echo "to pass any to it, please specify them on the $0 command line."
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
59 fi
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
60 fi
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
61
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
62 case $CC in
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
63 *xlc | *xlc\ * | *lcc | *lcc\ *) am_opt=--include-deps;;
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
64 esac
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
65
195
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
66 intl=`$GETTEXTIZE --help 2>/dev/null | grep -- '--intl'`
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
67 if test -z "$intl"; then
545
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
68 GETTEXTIZE_FLAGS="-c"
195
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
69 else
545
e850102b64be 2004-9-6 Brian Masney <masneyb@gftp.org>
masneyb
parents: 387
diff changeset
70 GETTEXTIZE_FLAGS="-c --intl"
195
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
71 fi
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
72
195
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
73 echo "$GETTEXTIZE $GETTEXTIZE_FLAGS"
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
74 $GETTEXTIZE $GETTEXTIZE_FLAGS
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
75
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
76 echo "$ACLOCAL $ACLOCAL_FLAGS"
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
77 $ACLOCAL $ACLOCAL_FLAGS
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
78
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
79 # optionally feature autoheader
195
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
80 ($AUTOHEADER --version) < /dev/null > /dev/null 2>&1 && $AUTOHEADER
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
81
195
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
82 AUTOMAKE_FLAGS="-a -c $am_opt"
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
83 echo "$AUTOMAKE $AUTOMAKE_FLAGS"
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
84 $AUTOMAKE $AUTOMAKE_FLAGS
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
85
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
86 echo $AUTOCONF
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
87 $AUTOCONF
3fa7b4f4ab78 2003-6-19 Brian Masney <masneyb@gftp.org>
masneyb
parents: 171
diff changeset
88
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
89 cd $ORIGDIR
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
90
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
91 if test -z "$AUTOGEN_SUBDIR_MODE"; then
553
b2b4f5fa8fc7 2004-9-14 Brian Masney <masneyb@gftp.org>
masneyb
parents: 545
diff changeset
92 CFLAGS="-Wall -W -Wno-long-long -Wno-unused-parameter -ansi -D_GNU_SOURCE -O -g" $srcdir/configure "$@"
26
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
93
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
94 echo
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
95 echo "Now type 'make' to compile $PROJECT."
d74bfa342116 2002-09-24 gettextize <bug-gnu-gettext@gnu.org>
masneyb
parents:
diff changeset
96 fi