From 4d22c060dd698a154b7716b42b47744d5f4030218b828500ef5d1b902f567e94 Mon Sep 17 00:00:00 2001 From: Johannes Segitz Date: Sat, 1 Dec 2018 07:36:52 +0000 Subject: [PATCH] Accepting request 652674 from home:jengelh:branches:security:SELinux - Replace old $RPM_* shell vars. OBS-URL: https://build.opensuse.org/request/show/652674 OBS-URL: https://build.opensuse.org/package/show/security:SELinux/libselinux?expand=0&rev=99 --- libselinux.changes | 5 ++++ libselinux.spec | 62 +++++++++++++++++++++++----------------------- 2 files changed, 36 insertions(+), 31 deletions(-) diff --git a/libselinux.changes b/libselinux.changes index 3f877ff..0b650f5 100644 --- a/libselinux.changes +++ b/libselinux.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Nov 29 19:10:14 UTC 2018 - Jan Engelhardt + +- Replace old $RPM_* shell vars. + ------------------------------------------------------------------- Wed Nov 21 10:38:23 UTC 2018 - jsegitz@suse.com diff --git a/libselinux.spec b/libselinux.spec index 4a5c4ad..9a964f3 100644 --- a/libselinux.spec +++ b/libselinux.spec @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -112,42 +112,42 @@ necessary to develop your own software using libselinux. %patch4 -p1 %build -make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="$RPM_OPT_FLAGS" CC="%{__cc}" -make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="$RPM_OPT_FLAGS" -C src V=1 -make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="$RPM_OPT_FLAGS" -C src swigify V=1 -make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="$RPM_OPT_FLAGS" -C src pywrap V=1 -make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="$RPM_OPT_FLAGS" -C src rubywrap V=1 +make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags}" CC="%{__cc}" +make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags}" -C src V=1 +make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags}" -C src swigify V=1 +make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags}" -C src pywrap V=1 +make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags}" -C src rubywrap V=1 %install -mkdir -p $RPM_BUILD_ROOT/%{_lib} -mkdir -p $RPM_BUILD_ROOT%{_libdir} -mkdir -p $RPM_BUILD_ROOT%{_includedir} -mkdir -p $RPM_BUILD_ROOT%{_sbindir} -make DESTDIR="$RPM_BUILD_ROOT" LIBDIR="%{_libdir}" SHLIBDIR="/%{_lib}" BINDIR="%{_sbindir}" install -rm -f $RPM_BUILD_ROOT%{_sbindir}/compute_* -rm -f $RPM_BUILD_ROOT%{_sbindir}/deftype -rm -f $RPM_BUILD_ROOT%{_sbindir}/execcon -rm -f $RPM_BUILD_ROOT%{_sbindir}/getenforcemode -rm -f $RPM_BUILD_ROOT%{_sbindir}/getfilecon -rm -f $RPM_BUILD_ROOT%{_sbindir}/getpidcon -rm -f $RPM_BUILD_ROOT%{_sbindir}/mkdircon -rm -f $RPM_BUILD_ROOT%{_sbindir}/policyvers -rm -f $RPM_BUILD_ROOT%{_sbindir}/setfilecon -rm -f $RPM_BUILD_ROOT%{_sbindir}/selinuxconfig -rm -f $RPM_BUILD_ROOT%{_sbindir}/selinuxdisable -rm -f $RPM_BUILD_ROOT%{_sbindir}/getseuser -rm -f $RPM_BUILD_ROOT%{_sbindir}/selinux_check_securetty_context -mv $RPM_BUILD_ROOT%{_sbindir}/getdefaultcon $RPM_BUILD_ROOT%{_sbindir}/selinuxdefcon -mv $RPM_BUILD_ROOT%{_sbindir}/getconlist $RPM_BUILD_ROOT%{_sbindir}/selinuxconlist -install -m 0755 %{SOURCE1} $RPM_BUILD_ROOT%{_sbindir}/selinux-ready +mkdir -p %{buildroot}/%{_lib} +mkdir -p %{buildroot}/%{_libdir} +mkdir -p %{buildroot}/%{_includedir} +mkdir -p %{buildroot}/%{_sbindir} +%make_install LIBDIR="%{_libdir}" SHLIBDIR="/%{_lib}" BINDIR="%{_sbindir}" +rm -f %{buildroot}/%{_sbindir}/compute_* +rm -f %{buildroot}/%{_sbindir}/deftype +rm -f %{buildroot}/%{_sbindir}/execcon +rm -f %{buildroot}/%{_sbindir}/getenforcemode +rm -f %{buildroot}/%{_sbindir}/getfilecon +rm -f %{buildroot}/%{_sbindir}/getpidcon +rm -f %{buildroot}/%{_sbindir}/mkdircon +rm -f %{buildroot}/%{_sbindir}/policyvers +rm -f %{buildroot}/%{_sbindir}/setfilecon +rm -f %{buildroot}/%{_sbindir}/selinuxconfig +rm -f %{buildroot}/%{_sbindir}/selinuxdisable +rm -f %{buildroot}/%{_sbindir}/getseuser +rm -f %{buildroot}/%{_sbindir}/selinux_check_securetty_context +mv %{buildroot}/%{_sbindir}/getdefaultcon %{buildroot}/%{_sbindir}/selinuxdefcon +mv %{buildroot}/%{_sbindir}/getconlist %{buildroot}/%{_sbindir}/selinuxconlist +install -m 0755 %{SOURCE1} %{buildroot}/%{_sbindir}/selinux-ready -make DESTDIR="$RPM_BUILD_ROOT" LIBDIR="%{_libdir}" \ +%make_install LIBDIR="%{_libdir}" \ SHLIBDIR="/%{_lib}" LIBSEPOLA=%{_libdir}/libsepol.a \ - -C src install V=1 -make DESTDIR="$RPM_BUILD_ROOT" LIBDIR="%{_libdir}" \ + -C src V=1 +make DESTDIR="%{buildroot}" LIBDIR="%{_libdir}" \ SHLIBDIR="/%{_lib}" LIBSEPOLA=%{_libdir}/libsepol.a \ -C src install-pywrap V=1 -make DESTDIR="$RPM_BUILD_ROOT" LIBDIR="%{_libdir}" \ +make DESTDIR="%{buildroot}" LIBDIR="%{_libdir}" \ SHLIBDIR="/%{_lib}" LIBSEPOLA=%{_libdir}/libsepol.a \ -C src install-rubywrap V=1 # Remove duplicate files