%{?scl:%scl_package eclipse-linuxtools}
%{!?scl:%global pkg_name %{name}}
%global eclipse_dropin %{_datadir}/eclipse/dropins
%global git_version d2973ee6552477424a4cd58d3e452541db3dd44c
Name: %{?scl_prefix}eclipse-linuxtools
Version: 2.2.0
Release: 0.1.gitd2973ee%{?dist}
Summary: Linux specific Eclipse plugins
License: EPL
URL: http://eclipse.org/linuxtools/
#Main directory changed to not be git sha but version as tycho fails with path too long otherwise
Source0: http://git.eclipse.org/c/linuxtools/org.eclipse.linuxtools.git/snapshot/org.eclipse.linuxtools-%{git_version}.tar.bz2
Patch0: disable-libhover-lttng.patch
BuildRequires: tycho
BuildRequires: tycho-extras
BuildRequires: %{?scl_prefix}eclipse-cdt
BuildRequires: %{?scl_prefix}eclipse-jdt
BuildRequires: %{?scl_prefix}swt-chart
BuildRequires: maven-clean-plugin
BuildRequires: eclipse-swtbot
BuildRequires: %{?scl_prefix}eclipse-gef
BuildRequires: osgi(org.eclipse.ptp.remote.core)
BuildRequires: exec-maven-plugin
BuildArch: noarch
Obsoletes: %{?scl_prefix}eclipse-linuxprofilingframework < 2.0.0
Provides: %{?scl_prefix}eclipse-linuxprofilingframework = %{version}-%{release}
%description
The Linux Tools project is a two-faceted project. Firstly, it develops tools
and frameworks for writing tools for Linux developers. Secondly, it provides
a place for Linux distributions to collaboratively overcome issues surrounding
distribution packaging of Eclipse technology. The project will produce both
best practices and tools related to packaging.
%package -n %{?scl_prefix}eclipse-changelog
Version: 2.8.2
Summary: Eclipse ChangeLog plug-in
Epoch: 2
%description -n %{?scl_prefix}eclipse-changelog
The Eclipse ChangeLog package contains Eclipse features and plugins that are
useful for ChangeLog maintenance within the Eclipse IDE. It includes
fragments for parsing C, C++, and Java source files to create more detailed
entries containing function or method names.
%package -n %{?scl_prefix}eclipse-rpmstubby
Summary: Rpm spec file generator
%description -n %{?scl_prefix}eclipse-rpmstubby
RPM Stubby Plug-in is a plugin aiming to auto-generate RPM spec files.
%package -n %{?scl_prefix}eclipse-rpm-editor
Summary: RPM Spec file editor for Eclipse
Requires: rpmlint >= 0.81
Requires: rpmdevtools
%description -n %{?scl_prefix}eclipse-rpm-editor
The Eclipse Spec file Editor package contains Eclipse plugins that are
useful for maintenance of RPM spec files within the Eclipse IDE.
%package -n %{?scl_prefix}eclipse-manpage
Summary: Man page viewer
%description -n %{?scl_prefix}eclipse-manpage
Plugin providing common interface for displaying a man page in a view or
fetching its content for embedded display purposes (e.g hover help).
%package -n %{?scl_prefix}eclipse-gcov
Summary: GCov Integration
%description -n %{?scl_prefix}eclipse-gcov
Functionality to integrate GCov with the Eclipse workbench.
%package -n %{?scl_prefix}eclipse-gprof
Summary: GProf Integration
%description -n %{?scl_prefix}eclipse-gprof
Functionality to integrate GProf with the Eclipse workbench.
%package -n %{?scl_prefix}eclipse-oprofile
Summary: Eclipse plugin for OProfile integration
Requires: oprofile >= 0.9.3
Requires: usermode >= 1.98
%description -n %{?scl_prefix}eclipse-oprofile
Eclipse plugins to integrate OProfile's profiling capabilities with the CDT.
%package -n %{?scl_prefix}eclipse-perf
Summary: Eclipse plugin for Perf integration
Requires: perf
%description -n %{?scl_prefix}eclipse-perf
Eclipse plugins to integrate Perf's profiling capabilities with the CDT.
%package -n %{?scl_prefix}eclipse-valgrind
Summary: Valgrind Tools Integration for Eclipse
Requires: valgrind
%description -n %{?scl_prefix}eclipse-valgrind
This package for Eclipse allows users to launch their C/C++ Development Tools
projects using the Valgrind tool suite and presents the results in the IDE.
%package -n %{?scl_prefix}eclipse-systemtap
Summary: Systemtap Tools Integration for Eclipse
Requires: systemtap
Obsoletes: %{?scl_prefix}eclipse-callgraph < 2.0.0
Obsoletes: %{?scl_prefix}eclipse-systemtapgui < 1.2
Provides: %{?scl_prefix}eclipse-callgraph = %{version}-%{release}
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.2.0
%patch0
%pom_remove_plugin org.jacoco:jacoco-maven-plugin
%pom_disable_module lttng
%pom_disable_module libhover
# Do not package swt-chart
sed -i '/org.swtchart/,/<\/iu>/ d' releng/org.eclipse.linuxtools.releng-site/category.xml
%build
%{?scl:%scl_maven_opts}
export MAVEN_OPTS="-XX:CompileCommand=exclude,org/eclipse/tycho/core/osgitools/EquinoxResolver,newState ${MAVEN_OPTS}"
mvn-rpmbuild clean verify -Dmaven.test.skip=true -DskipTychoVersionCheck=true
pushd releng/org.eclipse.linuxtools.releng-site/target/repository/features
for f in `ls -1 . | grep jar$`; do
unzip $f -d ${f/.jar//};
rm -fr $f
done
popd
%install
install -d -m 755 %{buildroot}%{eclipse_dropin}
for s in changelog rpmstubby perf valgrind oprofile man rpm gcov gprof systemtap linuxtools; do
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
mv ./features/*changelog* %{buildroot}%{eclipse_dropin}/changelog/features
#rpmstubby
mv ./plugins/*rpmstubby* %{buildroot}%{eclipse_dropin}/rpmstubby/plugins
mv ./features/*rpmstubby* %{buildroot}%{eclipse_dropin}/rpmstubby/features
#rpm
mv ./plugins/*rpm* %{buildroot}%{eclipse_dropin}/rpm/plugins
mv ./features/*rpm* %{buildroot}%{eclipse_dropin}/rpm/features
#man
mv ./plugins/*man* %{buildroot}%{eclipse_dropin}/man/plugins
mv ./features/*man* %{buildroot}%{eclipse_dropin}/man/features
#gcov
mv ./plugins/*gcov* %{buildroot}%{eclipse_dropin}/gcov/plugins
mv ./features/*gcov* %{buildroot}%{eclipse_dropin}/gcov/features
#gprof
mv ./plugins/*gprof* %{buildroot}%{eclipse_dropin}/gprof/plugins
mv ./features/*gprof* %{buildroot}%{eclipse_dropin}/gprof/features
#perf
mv ./plugins/*perf* %{buildroot}%{eclipse_dropin}/perf/plugins
mv ./features/*perf* %{buildroot}%{eclipse_dropin}/perf/features
#valgrind
mv ./plugins/*valgrind* %{buildroot}%{eclipse_dropin}/valgrind/plugins
mv ./features/*valgrind* %{buildroot}%{eclipse_dropin}/valgrind/features
#oprofile
mv ./plugins/*oprofile* %{buildroot}%{eclipse_dropin}/oprofile/plugins
mv ./features/*oprofile* %{buildroot}%{eclipse_dropin}/oprofile/features
#systemtap
mv ./plugins/*systemtap* %{buildroot}%{eclipse_dropin}/systemtap/plugins
mv ./features/*systemtap* %{buildroot}%{eclipse_dropin}/systemtap/features
mv ./plugins/*callgraph* %{buildroot}%{eclipse_dropin}/systemtap/plugins
mv ./features/*callgraph* %{buildroot}%{eclipse_dropin}/systemtap/features
#linuxtools
mv ./plugins/* %{buildroot}%{eclipse_dropin}/linuxtools/plugins
mv ./features/* %{buildroot}%{eclipse_dropin}/linuxtools/features
# Use system swt-chart
ln -s %{_javadir}/swt-chart.jar %{buildroot}%{eclipse_dropin}/linuxtools/plugins
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//')
unzip org.eclipse.linuxtools.oprofile.core_$OPROFILECOREVERSION.jar -d ./org.eclipse.linuxtools.oprofile.core_$OPROFILECOREVERSION
rm -fr org.eclipse.linuxtools.oprofile.core_$OPROFILECOREVERSION.jar
%global corepath %{buildroot}%{eclipse_dropin}/oprofile/plugins/org.eclipse.linuxtools.oprofile.core_$OPROFILECOREVERSION
#create opcontrol wrapper
pushd %{corepath}/natives/linux/scripts
rm -f *.sh
echo '#!/bin/sh' > opcontrol
echo 'exec pkexec /usr/bin/opcontrol ${1+"$@"}' >> opcontrol
popd
#install opcontrol wrapper permission files
install -d -m 755 %{buildroot}%{_datadir}/polkit-1/actions
install -D -m 644 \
org.eclipse.linuxtools.oprofile.core_$OPROFILECOREVERSION/natives/linux/scripts/org.eclipse.linuxtools.oprofile.policy \
%{buildroot}%{_datadir}/polkit-1/actions/org.eclipse.linuxtools.oprofile.policy
#remove installed files
rm -f org.eclipse.linuxtools.oprofile.core_$OPROFILECOREVERSION/natives/linux/scripts/org.eclipse.linuxtools.oprofile.policy
popd
%files
%{eclipse_dropin}/linuxtools
%doc releng/org.eclipse.linuxtools.license-feature/license.html
%doc releng/org.eclipse.linuxtools.license-feature/epl-v10.html
%files -n %{?scl_prefix}eclipse-changelog
%{eclipse_dropin}/changelog
%files -n %{?scl_prefix}eclipse-rpmstubby
%{eclipse_dropin}/rpmstubby
%files -n %{?scl_prefix}eclipse-rpm-editor
%{eclipse_dropin}/rpm
%files -n %{?scl_prefix}eclipse-manpage
%{eclipse_dropin}/man
%files -n %{?scl_prefix}eclipse-gcov
%{eclipse_dropin}/gcov
%files -n %{?scl_prefix}eclipse-gprof
%{eclipse_dropin}/gprof
%files -n %{?scl_prefix}eclipse-oprofile
%{eclipse_dropin}/oprofile
%attr(755, root, root) %{eclipse_dropin}/oprofile/plugins/org.eclipse.linuxtools.oprofile.core_*/natives/linux/scripts/opcontrol
%{_datadir}/polkit-1/actions/org.eclipse.linuxtools.oprofile.policy
%files -n %{?scl_prefix}eclipse-perf
%{eclipse_dropin}/perf
%files -n %{?scl_prefix}eclipse-valgrind
%{eclipse_dropin}/valgrind
%files -n %{?scl_prefix}eclipse-systemtap
%{eclipse_dropin}/systemtap
%files -n %{?scl_prefix}eclipse-linuxtools-tests
%{_javadir}/linuxtools-tests
%changelog
* Mon Nov 18 2013 Alexander Kurtakov <akurtako@redhat.com> 2.2.0-0.1.gitd2973ee
- Update to Linux Tools 2.2.0 snapshot.
* Tue Oct 8 2013 Krzysztof Daniel <kdaniel@redhat.com> 2.1.0-3
- Include fix for save not working in a spec compare editor.
* Mon Sep 30 2013 Alexander Kurtakov <akurtako@redhat.com> 2.1.0-2
- Bump changelog version too.
* Mon Sep 30 2013 Alexander Kurtakov <akurtako@redhat.com> 2.1.0-1
- Update to latest upstream release.
* Thu Sep 19 2013 Roland Grunberg <rgrunber@redhat.com> - 2.0.0-4
- Fix Bug 1009448.
* Tue Aug 13 2013 Roland Grunberg <rgrunber@redhat.com> - 2.0.0-3
- Add eclipse-linuxtools-tests subpackage.
* Tue Aug 06 2013 Roland Grunberg <rgrunber@redhat.com> - 2.0.0-2
- Fix Bug 992171.
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
* Thu Jun 27 2013 Alexander Kurtakov <akurtako@redhat.com> 2:2.0.0-1
- Final 2.0.0 release.
* Fri Jun 07 2013 Sami Wagiaalla <swagiaal@redhat.com> 2:2.0.0-0.7.git6428ae8
- Update to RC3.
* Mon May 13 2013 Roland Grunberg <rgrunber@redhat.com> 2:2.0.0-0.6.git294c1bf
- Update to a newer snapshot.
* Mon May 13 2013 Alexander Kurtakov <akurtako@redhat.com> 2:2.0.0-0.5.gitd67d6da
- Make callgraph and linuxtoolsframework obsoletes be fixed.
* Tue Apr 23 2013 Sami Wagiaalla <swagiaal@redhat.com> 2.0.0-0.4.gitd67d6da
- Update to a new snapshot.
* Thu Apr 11 2013 Alexander Kurtakov <akurtako@redhat.com> 2.0.0-0.3.gita645f32
- New snapshot containing fix for building with Ant 1.9.
* Wed Apr 10 2013 Alexander Kurtakov <akurtako@redhat.com> 2.0.0-0.2.gitaa6d235
- SCL-ize.
- Update to newer snapshot.
* Wed Mar 27 2013 Alexander Kurtakov <akurtako@redhat.com> 2.0.0-0.1.git95aacfe
- Update to 2.0.0 prerelease for Kepler compatibility.
- Changelog no longer has it's own release as the version bumped.
* Mon Feb 4 2013 <swagiaal@redhat.com> 1.2.0-5
- Actually remove 'Requires: kernel-debuginfo' from systemtap.
* Wed Jan 30 2013 <swagiaal@redhat.com> 1.2.0-4
- Remove 'Requires: kernel-debuginfo' from systemtap.
* Thu Jan 24 2013 <rgrunber@redhat.com> 1.2.0-3
- Properly package PolicyKit for Eclipse OProfile.
* Mon Jan 7 2013 <swagiaal@redhat.com> 1.2.0-2
- Add 'Requires' to systemtap on kernel-debuginfo.
* Fri Nov 23 2012 Roland Grunberg <rgrunber@redhat.com> 1.2.0-1
- Update to 1.2.0 upstream release.
- Disable jacoco-maven-plugin.
* Fri Oct 5 2012 Roland Grunberg <rgrunber@redhat.com> 1.1.1-3
- Synchronize release number for subpackages and rebuild.
* Fri Oct 5 2012 Roland Grunberg <rgrunber@redhat.com> 1.1.1-2
- Bump release to avoid conflicting with previous build.
* Tue Oct 2 2012 Roland Grunberg <rgrunber@redhat.com> 1.1.1-1
- Update to 1.1.1 upstream release.
* Wed Aug 8 2012 Alexander Kurtakov <akurtako@redhat.com> 1.1.0-1
- Initial packaging.