Monday, March 19, 2018

Building GNU autoconf 2.69

I start with the same considerations from the post Building GNU m4. The GNU autoconf library is sometimes used on GNU buildings so I add it to my crazy list of GNU software to manually build.

The basic building strategy and general assumptions have been detailed on a previous post: Staged Building, so I'll (hopefully) get more straight to the point:

$ pwd
/stage/build

$ ./gnu-build-preparation ../source/.../autoconf-2.69.tar.xz
...

$ cd autoconf/autoconf-2.69-64

$ source ../setenv 64

CONFIG_SHELL=/usr/bin/bash

CC=/usr/bin/gcc CFLAGS=-m64 -march=core2 -std=gnu89

CXX=/usr/bin/g++ CXXFLAGS=-m64 -march=core2 -std=gnu++03

LD=/usr/bin/ld LDFLAGS=-m64 -march=core2

PATH=/opt/gnu/bin:/usr/gnu/bin:/usr/bin:/usr/sbin

PKG_CONFIG_PATH=

Suggested build sequence:

Fine-tune/fix config.h.in, Makefile.in and others...

$ ./configure \
  --build=x86_64-pc-solaris2.11 \
  --prefix=/opt/... \
  ...

$ gmake -j4


For IPS package:


$ sudo gmake DESTDIR=/stage/prototype/autoconf/2.69/64 install

For immediate use:

$ sudo gmake install
$ sudo zfs snapshot -r .../opt/...@autoconf-2.69

$ ./configure \
    --build=x86_64-pc-solaris2.11 \
    --prefix=/opt/gnu
...

$ gmake -j4
...

$ gmake check
...
/usr/bin/bash ./testsuite
## ----------------------------- ##
## GNU Autoconf 2.69 test suite. ##
## ----------------------------- ##
...

Compatibility with other tools.

501: Libtool                          
FAILED (foreign.at:61)
502: shtool                            ok

Autoscan.

503: autoscan                          ok

## ------------- ##
## Test results. ##
## ------------- ##
 
ERROR: 495 tests were run,
15 failed (4 expected failures).
8 tests were skipped.

## -------------------------- ##
## testsuite.log was created. ##
## -------------------------- ##


Please send `tests/testsuite.log' and all information you think might help:

   To: ...
   Subject: [GNU Autoconf 2.69] testsuite: 309 310 311 312 313 314 315 316 328 339 501 failed

You may investigate any problem if you feel able to do so, in which
case the test suite provides a good starting point.  Its output may
be found below `tests/testsuite.dir'.

gmake[3]: *** [check-local] Error 1
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/tests'
gmake[2]: *** [check-am] Error 2
gmake[2]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/tests'
gmake[1]: *** [check-recursive] Error 1
gmake[1]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64'
gmake: *** [check] Error 2


NOTE
The last failure, test 501, could be concerning at first but it seems to be temporary and derived from the fact that Solaris 11.3 defaults to a 32-bits userland, i386-pc-solaris2.11 (although the kernel is 64-bits). Hence I'll postpone a double-check until I get sufficiently more 64-bits artifacts available from my manual update process.
$ sudo gmake DESTDIR=/stage/prototype/autoconf/2.69/64 install
...

$ sudo gmake install
gmake  install-recursive
gmake[1]: Entering directory `/stage/build/autoconf/autoconf-2.69-64'
Making install in bin
gmake[2]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/bin'
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/bin'
test -z "/opt/gnu/bin" || /usr/gnu/bin/mkdir -p "/opt/gnu/bin"
 /usr/gnu/bin/install -c autom4te autoconf autoheader autoreconf ifnames autoscan autoupdate '/opt/gnu/bin'
gmake[3]: Nothing to be done for `install-data-am'.
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/bin'
gmake[2]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/bin'
Making install in .
gmake[2]: Entering directory `/stage/build/autoconf/autoconf-2.69-64'
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64'
gmake[3]: Nothing to be done for `install-exec-am'.
test -z "/opt/gnu/share/autoconf" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/autoconf"
 /usr/gnu/bin/install -c -m 644 ./INSTALL '/opt/gnu/share/autoconf'
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64'
gmake[2]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64'
Making install in lib
gmake[2]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib'
Making install in Autom4te
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/Autom4te'
gmake[4]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/Autom4te'
gmake[4]: Nothing to be done for `install-exec-am'.
test -z "/opt/gnu/share/autoconf/Autom4te" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/autoconf/Autom4te"
 /usr/gnu/bin/install -c -m 644 C4che.pm ChannelDefs.pm Channels.pm Configure_ac.pm FileUtils.pm General.pm Getopt.pm Request.pm XFile.pm '/opt/gnu/share/autoconf/Autom4te'
gmake[4]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/Autom4te'
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/Autom4te'
Making install in m4sugar
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/m4sugar'
gmake[4]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/m4sugar'
gmake[4]: Nothing to be done for `install-exec-am'.
test -z "/opt/gnu/share/autoconf/m4sugar" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/autoconf/m4sugar"
 /usr/gnu/bin/install -c -m 644 m4sugar.m4 foreach.m4 m4sh.m4 '/opt/gnu/share/autoconf/m4sugar'
test -z "/opt/gnu/share/autoconf/m4sugar" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/autoconf/m4sugar"
 /usr/gnu/bin/install -c -m 644 version.m4 m4sugar.m4f m4sh.m4f '/opt/gnu/share/autoconf/m4sugar'
gmake[4]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/m4sugar'
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/m4sugar'
Making install in autoconf
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/autoconf'
gmake[4]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/autoconf'
gmake[4]: Nothing to be done for `install-exec-am'.
test -z "/opt/gnu/share/autoconf/autoconf" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/autoconf/autoconf"
 /usr/gnu/bin/install -c -m 644 autoconf.m4 general.m4 status.m4 oldnames.m4 specific.m4 autoheader.m4 autoupdate.m4 autotest.m4 autoscan.m4 lang.m4 c.m4 erlang.m4 fortran.m4 functions.m4 go.m4 headers.m4 types.m4 libs.m4 programs.m4 '/opt/gnu/share/autoconf/autoconf'
test -z "/opt/gnu/share/autoconf/autoconf" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/autoconf/autoconf"
 /usr/gnu/bin/install -c -m 644 autoconf.m4f '/opt/gnu/share/autoconf/autoconf'
gmake[4]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/autoconf'
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/autoconf'
Making install in autotest
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/autotest'
gmake[4]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/autotest'
gmake[4]: Nothing to be done for `install-exec-am'.
test -z "/opt/gnu/share/autoconf/autotest" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/autoconf/autotest"
 /usr/gnu/bin/install -c -m 644 autotest.m4 general.m4 specific.m4 '/opt/gnu/share/autoconf/autotest'
test -z "/opt/gnu/share/autoconf/autotest" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/autoconf/autotest"
 /usr/gnu/bin/install -c -m 644 autotest.m4f '/opt/gnu/share/autoconf/autotest'
gmake[4]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/autotest'
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/autotest'
Making install in autoscan
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/autoscan'
gmake[4]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/autoscan'
gmake[4]: Nothing to be done for `install-exec-am'.
test -z "/opt/gnu/share/autoconf/autoscan" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/autoconf/autoscan"
 /usr/gnu/bin/install -c -m 644 autoscan.list '/opt/gnu/share/autoconf/autoscan'
gmake[4]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/autoscan'
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/autoscan'
Making install in emacs
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/emacs'
gmake[4]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib/emacs'
gmake[4]: Nothing to be done for `install-exec-am'.
gmake[4]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/emacs'
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib/emacs'
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib'
gmake[4]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/lib'
gmake[4]: Nothing to be done for `install-exec-am'.
test -z "/opt/gnu/share/autoconf" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/autoconf"
 /usr/gnu/bin/install -c -m 644 autom4te.cfg '/opt/gnu/share/autoconf'
gmake[4]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib'
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib'
gmake[2]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/lib'
Making install in doc
gmake[2]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/doc'
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/doc'
gmake[3]: Nothing to be done for `install-exec-am'.
test -z "/opt/gnu/share/info" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/info"
 /usr/gnu/bin/install -c -m 644 ./autoconf.info ./standards.info '/opt/gnu/share/info'
 install-info --info-dir='/opt/gnu/share/info' '/opt/gnu/share/info/autoconf.info'
 install-info --info-dir='/opt/gnu/share/info' '/opt/gnu/share/info/standards.info'
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/doc'
gmake[2]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/doc'
Making install in tests
gmake[2]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/tests'
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/tests'
gmake[3]: Nothing to be done for `install-exec-am'.
gmake[3]: Nothing to be done for `install-data-am'.
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/tests'
gmake[2]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/tests'
Making install in man
gmake[2]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/man'
gmake[3]: Entering directory `/stage/build/autoconf/autoconf-2.69-64/man'
gmake[3]: Nothing to be done for `install-exec-am'.
test -z "/opt/gnu/share/man/man1" || /usr/gnu/bin/mkdir -p "/opt/gnu/share/man/man1"
 /usr/gnu/bin/install -c -m 644 ./autoconf.1 ./autoheader.1 ./autom4te.1 ./autoreconf.1 ./autoscan.1 ./autoupdate.1 ./ifnames.1 ./config.guess.1 ./config.sub.1 '/opt/gnu/share/man/man1'
gmake[3]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/man'
gmake[2]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64/man'
gmake[1]: Leaving directory `/stage/build/autoconf/autoconf-2.69-64'


$ sudo zfs snapshot -r .../opt/gnu@autoconf-2.69

So far, here's my /opt/gnu folder:

























The building process is virtually the same for 32-bits artifacts.
But I don't perform it because I'm exclusively focusing on 64-bits artifacts.