[Rpm-maint] [draft] spec file unification: autotools based projects

Stanislav Brabec sbrabec at suse.cz
Fri Jul 18 11:26:57 UTC 2008


Marc Haisenko wrote:

> What about passing autoconf cache variables ? I regularly need to do things 
> like:
> 
> ac_cv_foo=yes \
> ac_cv_bar=no \
> ./configure ...

It should not appear in the spec files, as it is not packages specific,
but platform specific.

Hopefully autotools provide a support for system-wide caches and
settings.

You could create a global cache of these variables (for example
OpenEmbedded does). You can modify definition of %configure or define
extra variables in your global RPM macros to build it with this cache,
or do some config.site magic.

Regarding the cross compilation, autotools have much more problems than
rpmbuild, so we are still very far from the situation, when unpatched
standard spec files could be usable for cross compilation.

- There is no standard for discrimination between native CFLAGS and
target CFLAGS.

- There are no standards for discrimination between native helpers and
target programs. It becomes even worse, when you need to build such
helper twice and native and target environments are very different.

- Autotools have no support for target sysroot or target staging
repositories (e. g. AC_CHECK_FILE does not work).

- And finally gcc itself has no support for explicit -I and -L
redirection into sysroot.

Yes, particular programs provide a solution, but as it is program
specific, it cannot be used for general packaging rules.

-- 
Best Regards / S pozdravem,

Stanislav Brabec
software developer
---------------------------------------------------------------------
SUSE LINUX, s. r. o.                          e-mail: sbrabec at suse.cz
Lihovarská 1060/12           tel: +420 284 028 966, +49 911 740538747
190 00 Praha 9                                  fax: +420 284 028 951
Czech Republic                                    http://www.suse.cz/




More information about the Rpm-maint mailing list