Ticket 1141

Summary: Allow overriding autotools binaries with autogen.sh
Product: Slurm Reporter: Nicolas Joly <njoly>
Component: OtherAssignee: David Bigagli <david>
Status: RESOLVED FIXED QA Contact:
Severity: 6 - No support contract    
Priority: --- CC: brian, da
Version: 14.11.x   
Hardware: Other   
OS: Other   
Site: -Other- Alineos Sites: ---
Atos/Eviden Sites: --- Confidential Site: ---
Coreweave sites: --- Cray Sites: ---
DS9 clusters: --- HPCnow Sites: ---
HPE Sites: --- IBM Sites: ---
NOAA SIte: --- OCF Sites: ---
Recursion Pharma Sites: --- SFW Sites: ---
SNIC sites: --- Linux Distro: ---
Machine Name: CLE Version:
Version Fixed: 14.11.0rc3 Target Release: ---
DevPrio: --- Emory-Cloud Sites: ---
Attachments: Allow envs to override autotools binaries in autogen.sh

Description Nicolas Joly 2014-10-02 19:35:31 MDT
Created attachment 1285 [details]
Allow envs to override autotools binaries in autogen.sh

Hi,

On my main deleveloppement machine, i have multiple autotools versions. A vanilla one for my own projects which does not has definitions for AM_PATH_GLIB_2_0 and AM_PATH_GTK_2_0, and a system packaged one which has them.

It would be great if autotools binaries could be selected on the command line without altering the PATH.

The provided patch follow the autoreconf(1) mecanism by allowing tools override with specific environment variables (ACLOCAL, AUTOCONF, AUTOMAKE, ...).

njoly@raya [temp/slurm]> sh autogen.sh  
+ rm -fr 'autom4te.cache'
+ aclocal -I auxdir
configure.ac:263: warning: macro 'AM_PATH_GLIB_2_0' not found in library
configure.ac:269: warning: macro 'AM_PATH_GTK_2_0' not found in library
+ libtoolize --automake --copy --force
+ autoheader
+ automake --add-missing --copy --force-missing
+ autoconf --force --warnings=no-obsolete
configure.ac:263: error: possibly undefined macro: AM_PATH_GLIB_2_0
      If this token and others are legitimate, please use m4_pattern_allow.
      See the Autoconf documentation.
configure.ac:269: error: possibly undefined macro: AM_PATH_GTK_2_0
+ exit 1

njoly@raya [temp/slurm]> ACLOCAL=/usr/pkg/bin/aclocal sh autogen.sh
+ rm -fr 'autom4te.cache'
+ /usr/pkg/bin/aclocal -I auxdir
+ libtoolize --automake --copy --force
+ autoheader
+ automake --add-missing --copy --force-missing
+ autoconf --force --warnings=no-obsolete
+ set '+x'
now run ./configure to configure slurm for your environment.

NOTE: This script has most likely just modified files that are under
      version control.  Make sure that you really want these changes
      applied to the repository before you run "git commit".

Thanks.
Comment 1 Danny Auble 2014-10-17 10:55:45 MDT
Thanks Nicolas, keep in mind you should only ever need to run autogen.sh when adding new files or changing the Makefile.am files, which should be a very rare occasion.
Comment 2 Nicolas Joly 2014-10-17 11:52:39 MDT
(In reply to Danny Auble from comment #1)
> Thanks Nicolas, keep in mind you should only ever need to run autogen.sh
> when adding new files or changing the Makefile.am files, which should be a
> very rare occasion.

Do not forget cases were configure has to be regenerated too ... I needed it when adding a few function checks for the NetBSD port. I always wants to test my proposed changes before submitting patches.

Thanks.