source: rtems/contrib/crossrpms/autotools/autoconf.add @ 4835eb0

4.115
Last change on this file since 4835eb0 was 4835eb0, checked in by Ralf Corsepius <ralf.corsepius@…>, on 12/12/11 at 10:51:05

Fix perl module filtering.

  • Property mode set to 100644
File size: 2.8 KB
Line 
1%define srcvers @AUTOCONF_VERS@
2%define rpmvers %{expand:%(echo "@AUTOCONF_VERS@" | tr - _ )}
3
4%if "%{_prefix}" != "/usr"
5%define name                    @rpmprefix@autoconf
6%else
7%define name                    autoconf
8%endif
9
10# --with alltests       enable all tests
11%bcond_with             alltests
12
13Name:           %{name}
14License:        GPL
15URL:            http://www.gnu.org/software/autoconf
16Group:          Development/Tools
17Version:        %{rpmvers}
18Release:        @AUTOCONF_RPMREL@
19Summary:        Tool for automatically generating GNU style Makefile.in's
20
21BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
22BuildArch:      noarch
23BuildRequires:  perl m4 gawk emacs
24%if "%{version}" >= "2.62"
25BuildRequires:  m4 >= 1.4.5
26%endif
27Requires:       m4 gawk
28Requires(post):         /sbin/install-info
29Requires(preun):        /sbin/install-info
30
31@SOURCES@
32
33# remove bogus Autoconf perl dependencies and provides
34%global __requires_exclude %{?__requires_exclude:%__requires_exclude|}^perl\\(Autom4te::
35%global __provides_exclude %{?__provides_exclude:%__provides_exclude|}^perl\\(Autom4te::
36
37%description
38GNU's Autoconf is a tool for configuring source code and Makefiles.
39Using Autoconf, programmers can create portable and configurable
40packages, since the person building the package is allowed to
41specify various configuration options.
42You should install Autoconf if you are developing software and you'd
43like to use it to create shell scripts which will configure your
44source code packages.
45Note that the Autoconf package is not required for the end user who
46may be configuring software with an Autoconf-generated script;
47Autoconf is only required for the generation of the scripts, not
48their use.
49
50%prep
51%setup -q -n autoconf-%{srcvers}
52%{?PATCH0:%patch0 -p1}
53
54%if !%{defined fedora}
55# Work around rpm inserting bogus perl-module deps
56cat << \EOF > %{name}-prov
57#!/bin/sh
58%{__perl_provides} $* |\
59    sed -e '/^perl(Autom4te/d'
60EOF
61%global __perl_provides %{_builddir}/autoconf-%{srcvers}/%{name}-prov
62chmod +x %{__perl_provides}
63
64cat << \EOF > %{name}-requ
65#!/bin/sh
66%{__perl_requires} $* |\
67    sed -e '/^perl(Autom4te/d'
68EOF
69%global __perl_requires %{_builddir}/autoconf-%{srcvers}/%{name}-requ
70chmod +x %{__perl_requires}
71%endif
72
73%build
74./configure --prefix=%{_prefix} --infodir=%{_infodir} --mandir=%{_mandir} \
75  --bindir=%{_bindir} --datadir=%{_datadir}
76make
77
78%check
79%if "%{_build}" == "%{_host}"
80%if "%{srcvers}" == "2.68"
81# test 199 fails sporadically
82# test 205 fails deterministically
83TESTSUITEFLAGS='-198 200-204 206-'
84%endif
85
86make check %{!?with_alltests:TESTSUITEFLAGS="${TESTSUITEFLAGS}"}
87%endif
88
89%install
90rm -rf "${RPM_BUILD_ROOT}"
91make DESTDIR=${RPM_BUILD_ROOT} install
92
93# Create this directory to prevent the corresponding line
94# in %%files below to fail
95mkdir -p ${RPM_BUILD_ROOT}%{_datadir}/emacs/site-lisp
96
97# RTEMS's standards.info comes from binutils
98rm -f $RPM_BUILD_ROOT%{_infodir}/standards.info*
99
100rm -f $RPM_BUILD_ROOT%{_infodir}/dir
101touch $RPM_BUILD_ROOT%{_infodir}/dir
102
Note: See TracBrowser for help on using the repository browser.