2

I have a question when working with autotools, specifically when working with generating configure scripts by running

autoreconf -fi

I'll get these warnings:

libtoolize: putting auxiliary files in '.'.
libtoolize: copying file './ltmain.sh'
libtoolize: Consider adding 'AC_CONFIG_MACRO_DIRS([m4])' to configure.ac,
libtoolize: and rerunning libtoolize and aclocal.
libtoolize: Consider adding '-I m4' to ACLOCAL_AMFLAGS in Makefile.am.
configure.ac:12: installing './compile'
configure.ac:15: installing './config.guess'
configure.ac:15: installing './config.sub'
configure.ac:6: installing './install-sh'
configure.ac:6: installing './missing'
Makefile.am: installing './INSTALL'
src/Makefile.am:5: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/Makefile.am: installing './depcomp'
src/filteropt/Makefile.am:3: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/memory/Makefile.am:3: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/pagemanager/Makefile.am:3: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/raster/Makefile.am:5: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/raster/blendSource/Makefile.am:3: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')

After this I can manually go through and change INCLUDES to AM_CPPFLAGS as well as adding -I m4 but shouldn't I be able to update the configure files so that I do not get these warnings?

Where would I make those edits so that I can avoid these warnings?

user1610950
  • 759
  • 2
  • 9
  • 22

2 Answers2

0

From the man page of autoreconf:

By default, it only remakes those files that are older than their sources. If you install new versions of the GNU Build System, you can make ('autoreconf' remake all of the files by giving it the '--force' option).

So it seems that just running autoreconf -fi it should automatically update those configuration files

Vicente Bolea
  • 174
  • 1
  • 8
0

As you know, libtoolize is hanging. autoreconf is sometimes blamed for the problem, but the actual problem is strictly libtoolize. autoreconf runs libtoolize and that's when the problem shows up. However, simply running libtoolize on the command line by itself also demonstrates the problem.

Various things around the net suggest a change to configure.ac.

# configure.ac  (this does not help)
AC_CONFIG_AUX_DIR([.])

That doesn't work.

Others suggest that you need to make the m4 directory first. That does not help.

The workaround is to delete the ACLOCAL_AMFLAGS line from Makefile.am and simply tolerate the nastygram from libtoolize.

# delete this from Makefile.am
ACLOCAL_AMFLAGS="-I m4"

If you truly need some ACLOCAL_AMFLAGS line in Makefile.am, then, ahhh..., you have a problem which I can't address. Good luck.