3 # Discover what version of autoconf we are using.
4 autoversion=`autoconf --version | head -n 1`
10 cp config/configure.in .
11 cp config/relyx_configure.in lib/reLyX/configure.in
15 cp config/configure.ac .
16 cp config/relyx_configure.ac lib/reLyX/configure.ac
19 echo "You are running a version of autoconf that"
20 echo "we do not support."
21 echo "LyX only supports autoconf 2.13 and 2.53."
28 AUTOHEADER="autoheader -W none -W obsolete"
29 AUTOMAKE="automake -a -c --foreign"
30 AUTOCONF="autoconf -W none -W obsolete"
33 ACINCLUDE_FILES="lyxinclude.m4 libtool.m4 codeset.m4 gettext.m4 glibc21.m4 iconv.m4 isc-posix.m4 lcmessage.m4 progtest.m4 xforms.m4 qt2.m4 gtk--.m4 gnome--.m4 gnome.m4 pspell.m4 pkg.m4"
34 SIGCPP_ACINCLUDE_FILES="libtool.m4"
36 echo -n "Locating GNU m4... "
37 for prog in $M4 gm4 gnum4 m4 ; do
38 case `$prog --version 2>&1` in
46 if test x$ok = xno ; then
50 # Generate acinclude.m4
51 echo -n "Generate acinclude.m4... "
53 (cd config ; cat ${ACINCLUDE_FILES} >../acinclude.m4)
56 # Generate the Makefiles and configure files
57 if ( $ACLOCAL --version ) </dev/null > /dev/null 2>&1; then
58 echo "Building macros..."
59 for dir in . lib/reLyX ; do
61 ( cd $dir ; $ACLOCAL )
65 echo "aclocal not found -- aborting"
69 if ( $AUTOHEADER --version ) </dev/null > /dev/null 2>&1; then
70 echo "Building config header template..."
73 ( cd $dir ; $AUTOHEADER )
77 echo "autoheader not found -- aborting"
81 if ( $AUTOMAKE --version ) </dev/null > /dev/null 2>&1; then
82 echo "Building Makefile templates..."
83 for dir in . lib/reLyX ; do
85 ( cd $dir ; $AUTOMAKE )
89 echo "automake not found -- aborting"
93 if ( $AUTOCONF --version ) </dev/null > /dev/null 2>&1; then
94 echo "Building configure..."
95 for dir in . lib/reLyX ; do
97 ( cd $dir ; $AUTOCONF )
101 echo "autoconf not found -- aborting"
105 # Autogenerate lib/configure.m4.
106 if test x$GNUM4 != x ; then
107 echo -n "Building lib/configure ... "
109 $GNUM4 lib/configure.m4 > lib/configure
110 chmod a+x lib/configure
113 echo "No GNU m4. Impossible to build lib/configure -- aborting"
118 echo 'run "./configure ; make"'