From e48c489b56ac025c9093dfd69afb3406de58650f Mon Sep 17 00:00:00 2001 From: Maxim Ostapenko Date: Wed, 21 Sep 2016 18:40:22 +0300 Subject: [PATCH] Deliver sanitizer-sources package. Some Tizen developers may need custom sanitizer builds (with package-specific changes) in their packages. Libsanitizer doesn't support standalone build, but we can provide its sources to be reused in another packages. Change-Id: I3668c75e6fbfe8f7f723d68098f697526d038488 Signed-off-by: Maxim Ostapenko --- packaging/gcc-aarch64.spec | 19 +++++++++++++++++++ packaging/gcc-armv7l.spec | 19 +++++++++++++++++++ packaging/linaro-gcc.spec | 19 +++++++++++++++++++ 3 files changed, 57 insertions(+) diff --git a/packaging/gcc-aarch64.spec b/packaging/gcc-aarch64.spec index 2abb104..7fe6cac 100644 --- a/packaging/gcc-aarch64.spec +++ b/packaging/gcc-aarch64.spec @@ -737,6 +737,15 @@ Group: Development/Languages This package contains GCC Plugin development files needed for compiler plugins build. +%package -n sanitizer-sources +Summary: Sanitizer family tools sources +License: MIT +Group: Development/Tools +BuildArch: noarch + +%description -n sanitizer-sources +Sanitizer family tools sources for external tools. + %prep %setup -q -n gcc-%{version} @@ -915,6 +924,12 @@ chmod 644 %{buildroot}/ASAN_OPTIONS cp %{SOURCE19} %{buildroot} chmod 644 %{buildroot}/LSAN_OPTIONS %endif + +cd ../ +tar -czf libsanitizer.tar.bz libsanitizer +mkdir -p %{buildroot}/src +mv -v libsanitizer.tar.bz %{buildroot}/src + } %files @@ -1178,6 +1193,10 @@ chmod 644 %{buildroot}/LSAN_OPTIONS %defattr(-,root,root,-) %{_prefix}/bin/asan_symbolize.py +%files -n sanitizer-sources +%defattr(-,root,root,-) +/src/libsanitizer.tar.bz + } %changelog diff --git a/packaging/gcc-armv7l.spec b/packaging/gcc-armv7l.spec index d815ac9..33f9e8b 100644 --- a/packaging/gcc-armv7l.spec +++ b/packaging/gcc-armv7l.spec @@ -737,6 +737,15 @@ Group: Development/Languages This package contains GCC Plugin development files needed for compiler plugins build. +%package -n sanitizer-sources +Summary: Sanitizer family tools sources +License: MIT +Group: Development/Tools +BuildArch: noarch + +%description -n sanitizer-sources +Sanitizer family tools sources for external tools. + %prep %setup -q -n gcc-%{version} @@ -915,6 +924,12 @@ chmod 644 %{buildroot}/ASAN_OPTIONS cp %{SOURCE19} %{buildroot} chmod 644 %{buildroot}/LSAN_OPTIONS %endif + +cd ../ +tar -czf libsanitizer.tar.bz libsanitizer +mkdir -p %{buildroot}/src +mv -v libsanitizer.tar.bz %{buildroot}/src + } %files @@ -1178,6 +1193,10 @@ chmod 644 %{buildroot}/LSAN_OPTIONS %defattr(-,root,root,-) %{_prefix}/bin/asan_symbolize.py +%files -n sanitizer-sources +%defattr(-,root,root,-) +/src/libsanitizer.tar.bz + } %changelog diff --git a/packaging/linaro-gcc.spec b/packaging/linaro-gcc.spec index 930ddac..330fcca 100644 --- a/packaging/linaro-gcc.spec +++ b/packaging/linaro-gcc.spec @@ -734,6 +734,15 @@ Group: Development/Languages This package contains GCC Plugin development files needed for compiler plugins build. +%package -n sanitizer-sources +Summary: Sanitizer family tools sources +License: MIT +Group: Development/Tools +BuildArch: noarch + +%description -n sanitizer-sources +Sanitizer family tools sources for external tools. + %prep %setup -q -n gcc-%{version} @@ -912,6 +921,12 @@ chmod 644 %{buildroot}/ASAN_OPTIONS cp %{SOURCE19} %{buildroot} chmod 644 %{buildroot}/LSAN_OPTIONS %endif + +cd ../ +tar -czf libsanitizer.tar.bz libsanitizer +mkdir -p %{buildroot}/src +mv -v libsanitizer.tar.bz %{buildroot}/src + } %files @@ -1175,6 +1190,10 @@ chmod 644 %{buildroot}/LSAN_OPTIONS %defattr(-,root,root,-) %{_prefix}/bin/asan_symbolize.py +%files -n sanitizer-sources +%defattr(-,root,root,-) +/src/libsanitizer.tar.bz + } %changelog -- 2.7.4