diff --git a/xorp.spec b/xorp.spec index c134a1f..4492f35 100644 --- a/xorp.spec +++ b/xorp.spec @@ -37,7 +37,7 @@ BuildRequires: chrpath # Automatically added by buildreq on Tue Apr 08 2014 # optimized out: libstdc++-devel libtinfo-devel python-base python-modules python-modules-compiler python-modules-email xz -BuildRequires: cvs flex gcc4.5-c++ libncurses-devel libpcap-devel libpcre-devel libssl-devel scons +BuildRequires: cvs flex gcc-c++ libncurses-devel libpcap-devel libpcre-devel libssl-devel scons %description @@ -53,9 +53,7 @@ functionality, including support for custom hardware and software forwarding. %build -%set_gcc_version 4.5 - -scons -j4 \ +[ -n "$NPROCS" ] || NPROCS='%__nprocs'; scons -j$NPROCS \ DESTDIR=${RPM_BUILD_ROOT} \ sbindir=%{_sbindir} \ prefix=%{prefixdir} \ @@ -63,6 +61,8 @@ scons -j4 \ sysconfdir=%{_sysconfdir} \ xorp_confdir=%{_sysconfdir} \ localstatedir=%{_localstatedir} \ + build=%_configure_platform \ + rtld_origin=false \ %if %with_shared shared=yes \ %endif @@ -92,6 +92,8 @@ scons \ sysconfdir=%{_sysconfdir} \ xorp_confdir=%{_sysconfdir} \ localstatedir=%{_localstatedir} \ + build=%_configure_platform \ + rtld_origin=false \ %if %with_shared shared=yes \ %endif @@ -106,15 +108,8 @@ scons \ %{__install} -m 0644 %{SOURCE3} ${RPM_BUILD_ROOT}%{_sysconfdir}/logrotate.d/xorp %{__install} -m 0660 %{SOURCE4} ${RPM_BUILD_ROOT}%{_sysconfdir}/xorp - -# remove rpath -find %buildroot -type f -exec file {} \; | grep ELF | sed "s/^\([^ ]*\): ELF.*/\1/" | \ - while read f; do chrpath -d $f; done - -%set_verify_elf_method unresolved=relaxed - %pre -if ! getent group xorp >/dev/null 2>&1; then +if ! getent group xorp >/dev/null 2>&1; then /usr/sbin/groupadd -r xorp # xorpsh is using group's permission for access to xorp. @@ -141,12 +136,12 @@ exit 0 %attr(660,root,xorp) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/xorp/xorp.conf %dir %_datadir/%name -%dir %_libexecdir/%name +%dir /usr/lib/%name %dir %_logdir/%name %_sbindir/* %_datadir/%name/* -%_libexecdir/%name/* +/usr/lib/%name/* %changelog * Wed Apr 09 2014 Sergey Y. Afonin 1.8.6-alt0.20130830.1