I'm having trouble with the cygwin auto*tool package and the wrappers it puts around the different tool versions. I've looked in the following places
/usr/doc /usr/doc/Cygwin /usr/share/doc /usr/share/doc/Cygwin man automake man autoconf info automake info autoconf and autoconf-wrapper-2.59.README is the only one with cygwin-specific usage info. It says "Port Notes: Be sure to read the documentation in /usr/doc/autoconf-2.59/" which doesn't exist, but /usr/share/doc/autoconf-wrapper-2.59/ does, and it has a README that says that autoconf is a wrapper, that it will generally execute the newer auto* tool versions unless it finds an old generated configure script or is overridden by the WANT_AUTOCONF_2_1 or FORCE_AUTOCONF_2_5 environment vars. If there's any more cygwin-specific docs than that, I just didn't find it. Anyway, I can't figure out any way to get it to work. Back in the Good Old Days (TM), I just used to cd into the relevant dir and execute autoconf/automake according to whether I wanted to rebuild a configure script or makefile from a .in/.am or whatever. (As you can tell, I didn't understand the process in great detail, because I never needed to.) That was easy, but the new side-by-side install system has me stumped. I've got an old (2.13/2.14-ish timeframe) binutils. I edit ld/Makefile.am. Now I want to rebuild the thing, regenerating Makefile.in from Makefile.am. I work on the assumption that an old binutils will need old auto*tools, so I try the WANT_AUTOCONF_2_1 flag. But it fails: running 'autoconf' silently exits without doing anything at all, running 'automake' emits an error message. ----------------------------------snip---------------------------------- [EMAIL PROTECTED] /tools/external_source/gnu/binutils-x.xx> cvs up [EMAIL PROTECTED]'s password: ? diffs.txt M ld/Makefile.am [EMAIL PROTECTED] /tools/external_source/gnu/binutils-x.xx> export WANT_AUTOCONF_2_1=1 [EMAIL PROTECTED] /tools/external_source/gnu/binutils-x.xx> autoconf [EMAIL PROTECTED] /tools/external_source/gnu/binutils-x.xx> automake Usage: autoconf [-h] [--help] [-m dir] [--macrodir=dir] [-l dir] [--localdir=dir] [--version] [template-file] automake: autoconf failed with exit status: 1 [EMAIL PROTECTED] /tools/external_source/gnu/binutils-x.xx> cvs up [EMAIL PROTECTED]'s password: ? diffs.txt M ld/Makefile.am ----------------------------------snip---------------------------------- If I just cd into the ld subdir and try running automake there, it also fails, with the same error message as above. Trying it with the new autotools just seems to confirm my theory that the source is too old to be compatible: ----------------------------------snip---------------------------------- [EMAIL PROTECTED] /dlxtools/external_source/gnu/binutils-x.xx> unset WANT_AUTOCONF_2_1 [EMAIL PROTECTED] /dlxtools/external_source/gnu/binutils-x.xx> export FORCE_AUTOCONF_2_5=1 [EMAIL PROTECTED] /dlxtools/external_source/gnu/binutils-x.xx> autoconf configure.in:2053: error: possibly undefined macro: AS_FOR_TARGET If this token and others are legitimate, please use m4_pattern_allow. See the Autoconf documentation. [EMAIL PROTECTED] /dlxtools/external_source/gnu/binutils-x.xx> automake configure.in: no proper invocation of AM_INIT_AUTOMAKE was found. configure.in: You should verify that configure.in invokes AM_INIT_AUTOMAKE, configure.in: that aclocal.m4 is present in the top-level directory, configure.in: and that aclocal.m4 was recently regenerated (using aclocal). automake: no `Makefile.am' found for any configure output [EMAIL PROTECTED] /dlxtools/external_source/gnu/binutils-x.xx> ----------------------------------snip---------------------------------- I tried setting WANT_AUTOCONF_2_1 and then enabling maintainer mode at configure time, in an attempt to have maintainer mode regen the makefile for me, and although the configure went fine, the build fails when it comes to recurse into the binutils subdir to configure and build down there, with the following error: ----------------------------------snip---------------------------------- else true; fi touch stamp-lib make[3]: Leaving directory `/repository/gcc-build/binutils/opcodes' make[2]: Leaving directory `/repository/gcc-build/binutils/opcodes' make[1]: Leaving directory `/repository/gcc-build/binutils/opcodes' Configuring in binutils loading cache .././config.cache checking for Cygwin environment... (cached) yes checking for mingw32 environment... (cached) no checking host system type... i686-pc-cygwin ... omit much normal looking config test output here ... checking whether getenv must be declared... (cached) no checking whether environ must be declared... no updating cache .././config.cache creating ./config.status creating Makefile creating doc/Makefile creating po/Makefile.in creating config.h make[1]: Entering directory `/repository/gcc-build/binutils/binutils' cd /dlxtools/external_source/gnu/binutils-x.xx/binutils && automake --cygnus Makefile Usage: autoconf [-h] [--help] [-m dir] [--macrodir=dir] [-l dir] [--localdir=dir] [--version] [template-file] automake: autoconf failed with exit status: 1 make[1]: *** [/dlxtools/external_source/gnu/binutils-x.xx/binutils/Makefile.in] Error 1 make[1]: Leaving directory `/repository/gcc-build/binutils/binutils' make: *** [all-binutils] Error 2 [EMAIL PROTECTED] /repository/gcc-build/binutils> ----------------------------------snip---------------------------------- I know that there's been a lot of effort put into the autoconf wrappers just for the purpose of maintaining backward-compatibility, but I'm *really* stumped here. I have to support a legacy toolchain for a custom cpu and so just upgrading to newer binutils and using the newer auto* versions isn't an option; I really need to regenerate this makefile. Does anyone do this (work with old tools and sources) regularly and can tell me how to make it work? cheers, DaveK -- Can't think of a witty .sigline today.... -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/