[eclipse-linuxtools] Add eclipse-linuxtools-tests subpackage.

Roland Grunberg rgrunber at fedoraproject.org
Tue Aug 13 20:47:19 UTC 2013


commit 52950a36eb6093d1d8588e1efaeaa908d5db61ad
Author: Roland Grunberg <rgrunber at redhat.com>
Date:   Mon Aug 12 16:07:35 2013 -0400

    Add eclipse-linuxtools-tests subpackage.

 eclipse-linuxtools.spec |   47 ++++++++++++++++++++++++++++++++++++++++++++++-
 1 files changed, 46 insertions(+), 1 deletions(-)
---
diff --git a/eclipse-linuxtools.spec b/eclipse-linuxtools.spec
index 8545d22..1e4d310 100644
--- a/eclipse-linuxtools.spec
+++ b/eclipse-linuxtools.spec
@@ -6,7 +6,7 @@
 
 Name:           %{?scl_prefix}eclipse-linuxtools
 Version:        2.0.0
-Release:        2%{?dist}
+Release:        3%{?dist}
 Summary:        Linux specific Eclipse plugins
 
 License:        EPL
@@ -127,6 +127,22 @@ Provides: %{?scl_prefix}eclipse-systemtapgui = 1.2
 %description -n %{?scl_prefix}eclipse-systemtap
 Integrate Systemtap's profiling and tracing capabilities with the CDT.
 
+%package -n %{?scl_prefix}eclipse-linuxtools-tests
+
+Summary:  Linux Tools Project Test Bundles
+Requires: %{?scl_prefix}eclipse-changelog
+Requires: %{?scl_prefix}eclipse-rpmstubby
+Requires: %{?scl_prefix}eclipse-rpm-editor
+Requires: %{?scl_prefix}eclipse-gcov
+Requires: %{?scl_prefix}eclipse-gprof
+Requires: %{?scl_prefix}eclipse-oprofile
+Requires: %{?scl_prefix}eclipse-perf
+Requires: %{?scl_prefix}eclipse-valgrind
+Requires: %{?scl_prefix}eclipse-systemtap
+
+%description -n  %{?scl_prefix}eclipse-linuxtools-tests
+All test bundles for the Linux Tools project.
+
 
 %prep
 %setup -q -n org.eclipse.linuxtools-2.0.0
@@ -157,6 +173,8 @@ for s in changelog rpmstubby perf valgrind oprofile man rpm gcov gprof systemtap
 mkdir -p %{buildroot}%{eclipse_dropin}/$s/{plugins,features}
 done
 
+mkdir -p %{buildroot}%{_javadir}/linuxtools-tests/plugins
+
 pushd releng/org.eclipse.linuxtools.releng-site/target/repository
 #changelog
 mv ./plugins/*changelog* %{buildroot}%{eclipse_dropin}/changelog/plugins
@@ -205,6 +223,27 @@ mv ./features/* %{buildroot}%{eclipse_dropin}/linuxtools/features
 
 popd
 
+#tests
+# We need grep to return non-zero status to skip all non eclipse-test-plugins
+set +e
+for pom in `find . -name pom.xml`; do
+ grep -q '<packaging>eclipse-test-plugin</packaging>' ${pom}
+ if [ $? -eq 0 ]; then
+   testjar=`ls ${pom/pom.xml/}'target/'*.jar | grep -v sources`
+   mv ${testjar} %{buildroot}%{_javadir}/linuxtools-tests/plugins
+ fi
+done
+set -e
+
+testjar=`ls profiling/org.eclipse.linuxtools.profiling.tests/target/*.jar | grep -v sources`
+mv ${testjar} %{buildroot}%{_javadir}/linuxtools-tests/plugins
+testjar=`ls oprofile/org.eclipse.linuxtools.oprofile.tests/target/*.jar | grep -v sources`
+mv ${testjar} %{buildroot}%{_javadir}/linuxtools-tests/plugins
+testjar=`ls valgrind/org.eclipse.linuxtools.valgrind.tests/target/*.jar | grep -v sources`
+mv ${testjar} %{buildroot}%{_javadir}/linuxtools-tests/plugins
+testjar=`ls systemtap/org.eclipse.linuxtools.systemtap.ui.tests/target/*.jar | grep -v sources`
+mv ${testjar} %{buildroot}%{_javadir}/linuxtools-tests/plugins
+
 ### oprofile install.sh stuff ###
 pushd %{buildroot}%{eclipse_dropin}/oprofile/plugins
 OPROFILECOREVERSION=$(ls . | grep org.eclipse.linuxtools.oprofile.core_ | sed 's/org.eclipse.linuxtools.oprofile.core_//' |sed 's/.jar//')
@@ -288,7 +327,13 @@ popd
 %doc systemtap/org.eclipse.linuxtools.systemtap-feature/license.html
 %doc systemtap/org.eclipse.linuxtools.systemtap-feature/epl-v10.html
 
+%files -n %{?scl_prefix}eclipse-linuxtools-tests
+%{_javadir}/linuxtools-tests
+
 %changelog
+* Tue Aug 13 2013 Roland Grunberg <rgrunber at redhat.com> - 2.0.0-3
+- Add eclipse-linuxtools-tests subpackage.
+
 * Tue Aug 06 2013 Roland Grunberg <rgrunber at redhat.com> - 2.0.0-2
 - Fix Bug 992171.
 


More information about the scm-commits mailing list