diff --git a/.devtoolset-3.metadata b/.devtoolset-3.metadata index e69de29..428a27f 100644 --- a/.devtoolset-3.metadata +++ b/.devtoolset-3.metadata @@ -0,0 +1 @@ +7483812d597a7faae9ad2b48c0a8840d8502541e SOURCES/rhscl-dockerfiles-062c3b8.tar.gz diff --git a/.gitignore b/.gitignore index e69de29..263c5c2 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +SOURCES/rhscl-dockerfiles-062c3b8.tar.gz diff --git a/SPECS/devtoolset-3.spec b/SPECS/devtoolset-3.spec index f231c45..22cf516 100644 --- a/SPECS/devtoolset-3.spec +++ b/SPECS/devtoolset-3.spec @@ -1,21 +1,28 @@ %global scl devtoolset-3 %scl_package %scl +%global dfcommit 062c3b833c8cc030204fdaf45d359dfafae63002 +%global dfshortcommit %(c=%{dfcommit}; echo ${c:0:7}) +%global dockerfiledir %{_datadir}/%{scl_prefix}dockerfiles Summary: Package that installs %scl Name: %scl_name -Version: 3.0 -Release: 15%{?dist} -BuildArch: noarch +Version: 3.1 +Release: 9%{?dist} License: GPLv2+ Group: Applications/File BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) +Source0: https://github.com/sclorg/rhscl-dockerfiles/archive/%{dfcommit}/rhscl-dockerfiles-%{dfshortcommit}.tar.gz # The base package must require everything in the collection Requires: %{scl_prefix}toolchain %{scl_prefix}ide %{scl_prefix}perftools +Obsoletes: %{name} < %{version}-%{release} BuildRequires: scl-utils-build >= 20120927-11 BuildRequires: iso-codes +# This is needed for java directory macros +BuildRequires: javapackages-tools + %description This is the main package for %scl Software Collection. @@ -23,6 +30,7 @@ This is the main package for %scl Software Collection. Summary: Package that handles %scl Software Collection. Group: Applications/File Requires: scl-utils >= 20120927-11 +Obsoletes: %{name}-runtime < %{version}-%{release} Requires(post): libselinux policycoreutils-python Requires(postun): libselinux policycoreutils-python Requires(preun): libselinux policycoreutils-python @@ -35,6 +43,13 @@ Summary: Package shipping basic build configuration Group: Applications/File Requires: %{scl_prefix}runtime Requires: scl-utils-build >= 20120927-11 +Obsoletes: %{name}-build < %{version}-%{release} +# Java stuff has build-time requirements on these SCLs, +# which are only available for x86_64 arch +%ifarch x86_64 +Requires: rh-java-common-scldevel >= 1.1-12 +Requires: maven30-scldevel >= 1.1-7 +%endif %description build Package shipping essential configuration macros to build %scl Software Collection. @@ -47,6 +62,7 @@ Requires: %{scl_prefix}gcc %{scl_prefix}gcc-c++ %{scl_prefix}gcc-gfortran Requires: %{scl_prefix}binutils %{scl_prefix}gdb %{scl_prefix}strace Requires: %{scl_prefix}dwz %{scl_prefix}elfutils %{scl_prefix}memstomp Requires: %{scl_prefix}ltrace +Obsoletes: %{name}-toolchain < %{version}-%{release} %description toolchain Package shipping basic toolchain applications (compiler, debugger, ...) @@ -103,6 +119,7 @@ Requires: %{scl_prefix}eclipse-mylyn-tasks-web Requires: %{scl_prefix}eclipse-mylyn-versions Requires: %{scl_prefix}eclipse-mylyn-versions-cvs Requires: %{scl_prefix}eclipse-mylyn-versions-git +Obsoletes: %{name}-ide < %{version}-%{release} %description ide Package shipping Eclipse IDE @@ -113,17 +130,33 @@ Group: Applications/File Requires: %{scl_prefix}runtime Requires: %{scl_prefix}oprofile %{scl_prefix}systemtap %{scl_prefix}valgrind Requires: %{scl_prefix}dyninst +Obsoletes: %{name}-perftools < %{version}-%{release} %description perftools Package shipping performance tools (systemtap, oprofile) +%package dockerfiles +Summary: Package shipping Dockerfiles for Developer Toolset +Group: Applications/File + +%description dockerfiles +This package provides a set of example Dockerfiles that can be used +with Red Hat Developer Toolset. Use these examples to stand up +test environments using the Docker container engine. + %prep -%setup -c -T +%setup -c %build # Enable collection script # ======================== cat <enable +# The IDE part of this collection has a runtime dependency on +# the java-common collection, so enable it if present +if test -e /opt/rh/rh-java-common/enable ; then + . scl_source enable rh-java-common +fi + # General environment variables export PATH=%{_bindir}\${PATH:+:\${PATH}} export MANPATH=%{_mandir}:\${MANPATH} @@ -134,7 +167,7 @@ export JAVACONFDIRS="%{_sysconfdir}/java:\${JAVACONFDIRS:-/etc/java}" # Required by XMvn to locate its configuration files export XDG_CONFIG_DIRS="%{_sysconfdir}/xdg:\${XDG_CONFIG_DIRS:-/etc/xdg}" -export XDG_DATA_DIRS="%{_datadir}:\${XDG_DATA_DIRS:-/usr/local/share:/usr/share}" +export XDG_DATA_DIRS="%{_datadir}:\${XDG_DATA_DIRS:+\${XDG_DATADIRS}:}/usr/local/share:/usr/share" export PCP_DIR=%{_scl_root} # Some perl Ext::MakeMaker versions install things under /usr/lib/perl5 @@ -172,6 +205,8 @@ done exec /usr/bin/sudo \$sudo_options LD_LIBRARY_PATH=\$LD_LIBRARY_PATH PATH=\$PATH scl enable %{scl} "\$cmd_options" EOF +# " (Fix vim syntax coloring.) + # Java configuration # ================== cat <java.conf @@ -186,7 +221,9 @@ cat <ivysettings.xml @@ -195,12 +232,22 @@ cat <ivysettings.xml + + + + + + + + + + @@ -212,26 +259,33 @@ EOF # XMvn configuration # ================= cat <configuration.xml + - + - /opt/rh/%{scl}/root + %{_scl_root} + / + + %{_scl_root}/usr/share/maven-metadata + - opt/rh/%{scl}/root/usr/share/maven-fragments + opt/rh/%{scl}/root/usr/share/maven-metadata - %{scl}-resolve + resolve-%{scl} compound - opt/rh/%{scl}/root + %{_scl_root} %{scl} @@ -241,14 +295,21 @@ cat <configuration.xml - resolve-system + resolve compound / - %{scl}-resolve + + resolve-local + resolve-%{scl} + resolve-java-common + resolve-maven30 base-resolve @@ -266,36 +327,22 @@ cat <configuration.xml - - install-raw-pom - compound - - opt/rh/%{scl}/root - %{scl} - - - - base-raw-pom - - - - - install-effective-pom - compound - - opt/rh/%{scl}/root - %{scl} - - - - base-effective-pom - - - EOF +%if 0%{?rhel} < 7 +# OSGi auto-{provides,requires} macros +# ==================================== +cat <macros.%{scl}-osgi-config +%%osgi_find_provides_and_requires %%{expand: \\ +%%global _use_internal_dependency_generator 0 +%%global __find_provides %{_rpmconfigdir}/osgi.prov +%%global __find_requires %{_rpmconfigdir}/osgi.req +} +EOF +%endif + %install (%{scl_install}) @@ -316,6 +363,21 @@ install -p -m 644 ivysettings.xml %{buildroot}%{_sysconfdir}/ivy/ install -d -m 755 %{buildroot}%{_sysconfdir}/xdg/xmvn install -p -m 644 configuration.xml %{buildroot}%{_sysconfdir}/xdg/xmvn/ +install -d %{buildroot}%{dockerfiledir} + +collections="devtoolset-3 devtoolset-3-toolchain devtoolset-3-dyninst \ + devtoolset-3-elfutils devtoolset-3-oprofile devtoolset-3-systemtap \ + devtoolset-3-valgrind" +install -d -p -m 755 %{buildroot}%{dockerfiledir}/rhel{6,7} +for d in $collections; do + install -d -p -m 755 %{buildroot}%{dockerfiledir}/rhel{6,7}/$d + install -p -m 644 rhscl-dockerfiles-%{dfcommit}/rhel6.$d/* %{buildroot}%{dockerfiledir}/rhel6/$d + install -p -m 644 rhscl-dockerfiles-%{dfcommit}/rhel7.$d/* %{buildroot}%{dockerfiledir}/rhel7/$d +done + +# BZ#1194557: Don't ship systemtap container for RHEL6. +rm -rf %{buildroot}%{dockerfiledir}/rhel6/devtoolset-3-systemtap + %files %files runtime @@ -323,7 +385,6 @@ install -p -m 644 configuration.xml %{buildroot}%{_sysconfdir}/xdg/xmvn/ %attr(0644,root,root) %verify(not md5 size mtime) %ghost %config(missingok,noreplace) %{_sysconfdir}/selinux-equiv.created %{_sysconfdir}/ivy %{_sysconfdir}/java -%{_sysconfdir}/xdg/xmvn %dir %{_scl_root}/etc/alternatives %files build @@ -335,6 +396,11 @@ install -p -m 644 configuration.xml %{buildroot}%{_sysconfdir}/xdg/xmvn/ %files perftools +%if 0%{?rhel} >= 7 +%files dockerfiles +%{dockerfiledir} +%endif + %post runtime if [ ! -f %{_sysconfdir}/selinux-equiv.created ]; then /usr/sbin/semanage fcontext -a -e / %{_scl_root} @@ -352,6 +418,45 @@ if [ $1 = 0 ]; then fi %changelog +* Wed Apr 8 2015 Marek Polacek - 3.1-9 +- Add Obsoletes (#1208867) + +* Mon Feb 23 2015 Marek Polacek - 3.1-8 +- Don't ship devtoolset-3-dockerfiles subpackage on RHEL6 (#1194558) + +* Fri Feb 20 2015 Marek Polacek - 3.1-7 +- Don't ship systemtap container for RHEL6 (#1194557) + +* Wed Feb 11 2015 Marek Polacek - 3.1-6 +- Add devtoolset-3-{dyninst,elfutils,valgrind,oprofile,systemtap} + dockerfiles (#1180659) + +* Tue Feb 10 2015 Marek Polacek - 3.1-5 +- Add devtoolset-3-dockerfiles (#1180657) + +* Fri Jan 23 2015 Alexander Kurtakov 3.1-4 +- Include root /usr/share and /usr/local/share to prevent gsettings crash. + +* Tue Jan 13 2015 Mat Booth - 3.1-3 +- Resolves: rhbz#1178915 - Rebuild to get correct disttag +- Add BR to Fix unexpanded java dir macros in java.conf +- Don't enable maven30 SCL, as recommended by maven30 maintainer + +* Wed Jan 07 2015 Mat Booth - 3.1-2 +- Resolves: rhbz#1178915 +- Add missing xmvn resolver setting for metadata repo. +- Make package archful to make sure lib64 dirs are owned. +- Only require java-common and maven30 SCLs when on x86_64. + +* Thu Dec 18 2014 Mat Booth - 3.1-1 +- Resolves: rhbz#1178915 - Initial build for DTS 3.1 +- Add build-time deps on java-common and mvn30 SCLs +- Update xmvn and ivy config for latest javapackages/xmvn +- Fix file listed twice warning for xmvn/config.xml + +* Fri Jun 20 2014 Roland Grunberg - 3.0-16 +- Add macro for enablement of osgi auto-{provides,requires}. + * Wed Jun 04 2014 Marek Polacek 3.0-15 - Drop the -vc subpackage (#1104342)