module-build-macros: Use /etc instead of %_sysconfdir

Commit 42aef7d5d2 moved the macros installed by module-build-macros
from %_rpmconfdir (which is unaffected by %_prefix) to %_sysconfdir/rpm
(which follows %_prefix). This interacts badly with the Flatpak module
macros which change %_prefix to /app - when flatpak-rpm-macros is
in the buildroot while module-build-macros is built, module-build-macros
installs its macros to /app and they aren't found when building the
rest of the packages in the module.

Hardcoding /etc rather than using %_sysconfdir fixes this.
This commit is contained in:
Owen W. Taylor
2018-05-31 17:42:58 -04:00
parent afaaae2894
commit 827546dc9a

View File

@@ -279,13 +279,13 @@ It should NEVER be installed on any system as it will really mess up
%build
%install
mkdir -p %buildroot/%_sysconfdir/rpm 2>/dev/null |:
cp %SOURCE1 %buildroot/%_sysconfdir/rpm/macros.zz-modules
chmod 644 %buildroot/%_sysconfdir/rpm/macros.zz-modules
mkdir -p %buildroot/etc/rpm 2>/dev/null |:
cp %SOURCE1 %buildroot/etc/rpm/macros.zz-modules
chmod 644 %buildroot/etc/rpm/macros.zz-modules
%files
%_sysconfdir/rpm/macros.zz-modules
/etc/rpm/macros.zz-modules