From 08867addd7df44a8611b24a53f2a4e02e5c78b22 Mon Sep 17 00:00:00 2001 From: zhangxianting Date: Tue, 21 Nov 2023 18:51:25 +0800 Subject: [PATCH] enable fPIE and remove rpath --- libpeas.spec | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/libpeas.spec b/libpeas.spec index b56ae30..7f896bf 100644 --- a/libpeas.spec +++ b/libpeas.spec @@ -1,6 +1,8 @@ +%define chrpath_delete() (find $RPM_BUILD_ROOT/ -type f -exec file {} ';' | grep -w "ELF" | awk -F ':' '{print $1}' | xargs -i chrpath --delete {}) + Name: libpeas Version: 1.22.0 -Release: 11 +Release: 12 Summary: Gobject-based plugins engine License: LGPLv2+ URL: https://wiki.gnome.org/Projects/Libpeas @@ -36,17 +38,13 @@ applications that use libpeas. %autosetup %build -%configure --disable-silent-rules +%configure --disable-silent-rules CFLAGS="%{optflags} -fPIE -pie" %make_build %install %make_install +%chrpath_delete find $RPM_BUILD_ROOT%{_libdir} -type f -name '*.la' -print -exec rm -f {} ';' -chrpath -d $RPM_BUILD_ROOT%{_bindir}/peas-demo -chrpath -d $RPM_BUILD_ROOT%{_libdir}/libpeas-1.0/loaders/libpython3loader.so -chrpath -d $RPM_BUILD_ROOT%{_libdir}/libpeas-gtk-1.0.so -chrpath -d $RPM_BUILD_ROOT%{_libdir}/peas-demo/plugins/helloworld/libhelloworld.so -chrpath -d $RPM_BUILD_ROOT%{_libdir}/peas-demo/plugins/secondtime/libsecondtime.so %find_lang libpeas @@ -76,5 +74,11 @@ chrpath -d $RPM_BUILD_ROOT%{_libdir}/peas-demo/plugins/secondtime/libsecondtime. %{_datadir}/gir-1.0/*.gir %changelog +* Tue Nov 21 2023 zhangxianting - 1.22.0-11 +- Type:bugfix +- ID:NA +- SUG:NA +- DESC:enable fPIE and remove rpath + * Thu Nov 28 2019 openEuler Buildteam - 1.22.0-10 - Package init -- Gitee