Ainsi parlait Guillaume Rousse :
> Ainsi parlait Oden Eriksson :
> [..]
>
> > Use this "magic" in your ".rpmrc" file?
> >
> > macrofiles:
> > /usr/lib/rpm/macros:/usr/lib/rpm/%{_target}/macros:/etc/rpm/macros.specsp
> >o:
> > /etc/rpm/macros.db1:/etc/rpm/macros.cdb:/etc/rpm/macros:/etc/rpm/%{_targe
> >t}/ macros:~/.my_rpmmacros
>
> Too bad i can't concatenate values to current macrofiles value, only
> override it. But thanks for the magic :-)
Arghh, there is still a problem :-(
error: No compatible architectures found for build

Comparing configuration using rpm and rpm --rcfile .rpmrc.plf gives:
[guillaume@silbermann guillaume]$ diff -Naur test testp
--- test        Fri Dec  7 18:11:20 2001
+++ testp       Fri Dec  7 18:11:16 2001
@@ -1,17 +1,16 @@
 ARCHITECTURE AND OS:
 build arch            : athlon
-compatible build archs: athlon i686 i586 i486 i386 noarch
+compatible build archs: athlon
 build os              : Linux
 compatible build os's : Linux
 install arch          : athlon
 install os            : Linux
-compatible archs      : athlon i686 i586 i486 i386 noarch
+compatible archs      : athlon
 compatible os's       : Linux

 RPMRC VALUES:
-macrofiles            : 
/usr/lib/rpm/macros:/usr/lib/rpm/athlon-linux/macros:/etc/rpm/macros.specspo:/etc/rpm/macros.db1:/etc/rpm/macros.cdb:/etc/rpm/macros:/etc/rpm/athlon-linux/macros:~/.rpmmacros
-optflags              : -O2 -march=athlon
-provides              :  alsa module-info kernel = 2.4.6 kernel = 2.4.6-3mdk
+macrofiles            : 
/usr/lib/rpm/macros:/usr/lib/rpm/athlon-linux/macros:/etc/rpm/macros.specspo:/etc/rpm/macros.db1:/etc/rpm/macros.cdb:/etc/rpm/macros:/etc/rpm/athlon-linux/macros:~/.rpmmacros.plf
+optflags              : -O2

 Features supported by rpmlib:
     rpmlib(VersionedDependencies) = 3.0.3-1[guillaume@silbermann guillaume]$ 
diff -Naur test testp
--- test        Fri Dec  7 18:11:20 2001
+++ testp       Fri Dec  7 18:11:16 2001
@@ -1,17 +1,16 @@
 ARCHITECTURE AND OS:
 build arch            : athlon
-compatible build archs: athlon i686 i586 i486 i386 noarch
+compatible build archs: athlon
 build os              : Linux
 compatible build os's : Linux
 install arch          : athlon
 install os            : Linux
-compatible archs      : athlon i686 i586 i486 i386 noarch
+compatible archs      : athlon
 compatible os's       : Linux

 RPMRC VALUES:
-macrofiles            : 
/usr/lib/rpm/macros:/usr/lib/rpm/athlon-linux/macros:/etc/rpm/macros.specspo:/etc/rpm/macros.db1:/etc/rpm/macros.cdb:/etc/rpm/macros:/etc/rpm/athlon-linux/macros:~/.rpmmacros
-optflags              : -O2 -march=athlon
-provides              :  alsa module-info kernel = 2.4.6 kernel = 2.4.6-3mdk
+macrofiles            : 
/usr/lib/rpm/macros:/usr/lib/rpm/athlon-linux/macros:/etc/rpm/macros.specspo:/etc/rpm/macros.db1:/etc/rpm/macros.cdb:/etc/rpm/macros:/etc/rpm/athlon-linux/macros:~/.rpmmacros.plf
+optflags              : -O2

 Features supported by rpmlib:
     rpmlib(VersionedDependencies) = 3.0.3-1
@@ -262,6 +261,8 @@
 -14: _gamesdatadir     %{_datadir}/%{_gamesdir}
 -14: _gamesdir games
 -14: _gnu      -gnu
+-14: _gpg_name Guillaume Rousse <[EMAIL PROTECTED]>
+-14: _gpg_path ~/.gnupg
 -14: _gzipbin  %{__gzip}
 -14: _host     i586-mandrake-linux-gnu
 -14: _host_alias       i586-mandrake-linux-gnu
@@ -318,7 +319,7 @@
 -14: _rpmfilename      %{_build_name_fmt}
 -14: _sbindir  %{_exec_prefix}/sbin
 -14: _sharedstatedir   %{_prefix}/com
--14: _signature        none
+-14: _signature        gpg
 -14: _smp_mflags       %([ -z "$RPM_BUILD_NCPUS" ] \
        && RPM_BUILD_NCPUS="`/usr/bin/getconf _NPROCESSORS_ONLN`"; \
        [ "$RPM_BUILD_NCPUS" -gt 1 ] && echo "-j$RPM_BUILD_NCPUS")
@@ -332,8 +333,8 @@
 -11= _target_os        linux
 -14: _target_platform  %{_target_cpu}-%{_real_vendor}-%{_target_os}%{?_gnu}
 -14: _target_vendor    %{_host_vendor}
--14: _tmppath  %{_var}/tmp
--14: _topdir   %{_usrsrc}/RPM
+-14: _tmppath  /home/guillaume/rpm/tmp
+-14: _topdir   /home/guillaume/rpm
 -14: _unzipbin %{__unzip}
 -14: _update_menus_bin %{_bindir}/update-menus
 -14: _usr      /usr
@@ -386,6 +387,7 @@
   chmod %{4} %{1}
 fi
 %{nil}
+-14: distribution      Mandrake Linux
 -14: find_lang /usr/lib/rpm/find-lang.sh %{buildroot}
 -14: ix86      i386 i486 i586 i686 i786 i886 i986
 -14: make      %{_make_bin} %_smp_mflags
@@ -424,11 +426,13 @@
        mandir=%{?buildroot:%{buildroot}}%{_mandir} \
        infodir=%{?buildroot:%{buildroot}}%{_infodir} \
     install
--11: optflags  -O2 -march=athlon
+-11: optflags  -O2
+-14: packager  Guillaume Rousse <[EMAIL PROTECTED]>
 -14: perl_archlib      %(eval "`perl -V:installarchlib`"; echo 
$installarchlib)
 -14: perl_sitearch     %(eval "`perl -V:installsitearch`"; echo 
$installsitearch)
 -14: requires_eq       %(LC_ALL="C" rpm -q --queryformat 'Requires:%%{NAME} 
= %%{VERSION}' %1| grep -v "is not")
 -14: serverbuild       export CFLAGS="%optflags -fno-omit-frame-pointer"; 
export CXXFLAGS="%optflags -fno-omit-frame-pointer"; export 
RPM_OPT_FLAGS="%optflags -fno-omit-frame-pointer"
 -15: sigtype   none
 -14: update_menus      if [ -x %{_update_menus_bin} ]; then 
%{_update_menus_bin} || true ; fi
-======================== active 219 empty 0
+-14: vendor    Penguin Liberation Front
+======================== active 224 empty 0
@@ -262,6 +261,8 @@
 -14: _gamesdatadir     %{_datadir}/%{_gamesdir}
 -14: _gamesdir games
 -14: _gnu      -gnu
+-14: _gpg_name Guillaume Rousse <[EMAIL PROTECTED]>
+-14: _gpg_path ~/.gnupg
 -14: _gzipbin  %{__gzip}
 -14: _host     i586-mandrake-linux-gnu
 -14: _host_alias       i586-mandrake-linux-gnu
@@ -318,7 +319,7 @@
 -14: _rpmfilename      %{_build_name_fmt}
 -14: _sbindir  %{_exec_prefix}/sbin
 -14: _sharedstatedir   %{_prefix}/com
--14: _signature        none
+-14: _signature        gpg
 -14: _smp_mflags       %([ -z "$RPM_BUILD_NCPUS" ] \
        && RPM_BUILD_NCPUS="`/usr/bin/getconf _NPROCESSORS_ONLN`"; \
        [ "$RPM_BUILD_NCPUS" -gt 1 ] && echo "-j$RPM_BUILD_NCPUS")
@@ -332,8 +333,8 @@
 -11= _target_os        linux
 -14: _target_platform  %{_target_cpu}-%{_real_vendor}-%{_target_os}%{?_gnu}
 -14: _target_vendor    %{_host_vendor}
--14: _tmppath  %{_var}/tmp
--14: _topdir   %{_usrsrc}/RPM
+-14: _tmppath  /home/guillaume/rpm/tmp
+-14: _topdir   /home/guillaume/rpm
 -14: _unzipbin %{__unzip}
 -14: _update_menus_bin %{_bindir}/update-menus
 -14: _usr      /usr
@@ -386,6 +387,7 @@
   chmod %{4} %{1}
 fi
 %{nil}
+-14: distribution      Mandrake Linux
 -14: find_lang /usr/lib/rpm/find-lang.sh %{buildroot}
 -14: ix86      i386 i486 i586 i686 i786 i886 i986
 -14: make      %{_make_bin} %_smp_mflags
@@ -424,11 +426,13 @@
        mandir=%{?buildroot:%{buildroot}}%{_mandir} \
        infodir=%{?buildroot:%{buildroot}}%{_infodir} \
     install
--11: optflags  -O2 -march=athlon
+-11: optflags  -O2
+-14: packager  Guillaume Rousse <[EMAIL PROTECTED]>
 -14: perl_archlib      %(eval "`perl -V:installarchlib`"; echo 
$installarchlib)
 -14: perl_sitearch     %(eval "`perl -V:installsitearch`"; echo 
$installsitearch)
 -14: requires_eq       %(LC_ALL="C" rpm -q --queryformat 'Requires:%%{NAME} 
= %%{VERSION}' %1| grep -v "is not")
 -14: serverbuild       export CFLAGS="%optflags -fno-omit-frame-pointer"; 
export CXXFLAGS="%optflags -fno-omit-frame-pointer"; export 
RPM_OPT_FLAGS="%optflags -fno-omit-frame-pointer"
 -15: sigtype   none
 -14: update_menus      if [ -x %{_update_menus_bin} ]; then 
%{_update_menus_bin} || true ; fi
-======================== active 219 empty 0
+-14: vendor    Penguin Liberation Front
+======================== active 224 empty 0

Official doc says rpm commands source /usr/lib/rpmrc, /etc/rpmrc and ~/.rpmrc 
when used directly, and only /usr/lib/rpmrc and given file when using 
--rcfile flag. This is clearly wrong here :-(
-- 
Guillaume Rousse <[EMAIL PROTECTED]>
GPG key http://lis.snv.jussieu.fr/~rousse/gpgkey.html

Reply via email to