Hi Mathias, Am Sonntag, 23. September 2018, 10:29:41 CEST schrieb Mathias Homann:
I'm having a really strange packaging issue on Leap 15.0:
the %files se4ction of my spec file fails! here's the part of the spec file in question: %files
%defattr(-,root,root,0755) %doc $RPM_BUILD_DIR/%{_srcname}/build-linux-%{_arch}/newview/packaged/*.txt
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ IMHO this looks wrong. If you need to include documentation into your package, use relative paths. Depending on the structure of your archive, it could mean you use: %doc newview/packaged/*.txt Probably your archive contains more files that the above. Maybe it contains README files, Changelog, NEWS etc.? Depending on what you consider meaningful, you should add them to your %doc section too: %doc README* CHANGELOG ...
/usr/share/applications/* /usr/share/pixmaps/* /usr/games/*
For all three lines you should use the %_datadir macro instead of /usr/share: %_datadir/applications/* %_datadir/pixmaps/* %_datadir/games/* Although it means the same, you should avoid hard-coded paths.
[...] On every suse version until now this had worked just fine, but on 15.0 it almost looks as if $RPM_BUILD_DIR is not defined anymore, or as if variables are not expanded anymore at that point.
I vaguely remember that $RPM_BUILD_DIR should be replaced(?) in favor of the %buildroot macro, but I may be wrong. However, regardless of this issue, you should neither use $RPM_BUILD_DIR nor the %{buildroot} macro inside %doc. I never saw absolute paths in %doc (although it could work, as you proofed it with your previous versions). In 99% you should use the above lines. :) Hope that helps. :) -- Gruß/Regards, Thomas Schraitle ---------------------------------------------------------------------- SUSE LINUX Products GmbH (o< Maxfeldstrasse 5 /\\ Documentation Specialist 90409 Nuernberg, Germany _\_v http://www.suse.com | HRB 21284 SUSE LINUX GmbH, GF: Felix Imendörffer, Jane Smithard, Dilip Upmanyu, Graham Norton, HRB 21284 (AG Nürnberg) -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org