summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemi Collet <fedora@famillecollet.com>2015-09-18 14:22:43 +0200
committerRemi Collet <fedora@famillecollet.com>2015-09-18 14:22:43 +0200
commitd9a493b0b171b645d280d5d481d416be41673d8f (patch)
tree70a9be813d313065a5421bc92fd7f012abf414c8
parent5cc0f6388ee49b67f5c7f2ce94243b42fe423ecf (diff)
scl-utils: f23 (re)build
-rw-r--r--0001-Honor-CFLAGS-passed-to-cmake.patch25
-rw-r--r--0002-Fix-core-dumps-with-large-input-on-stdin-rhbz-125727.patch26
-rw-r--r--scl-utils-layout.patch4
-rw-r--r--scl-utils.spec45
4 files changed, 88 insertions, 12 deletions
diff --git a/0001-Honor-CFLAGS-passed-to-cmake.patch b/0001-Honor-CFLAGS-passed-to-cmake.patch
new file mode 100644
index 0000000..dc6a1e3
--- /dev/null
+++ b/0001-Honor-CFLAGS-passed-to-cmake.patch
@@ -0,0 +1,25 @@
+From 0100e1a89bc7ba3f7e94960437f69294638322a6 Mon Sep 17 00:00:00 2001
+From: Lubos Kardos <lkardos@redhat.com>
+Date: Tue, 7 Jul 2015 10:25:40 +0200
+Subject: [PATCH] Honor CFLAGS passed to cmake resovles: #1239997
+
+---
+ src/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
+index 4cfeef3..d0f96fe 100644
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -4,7 +4,7 @@ SET(MODULE_CMD "/usr/bin/modulecmd" )
+ SET(CONF_DIR "/etc/scl/conf/" )
+ CONFIGURE_FILE( config.h.cmake config.h )
+
+-SET( CMAKE_C_FLAGS "-Wall -pedantic --std=gnu99 -D_GNU_SOURCE -g" )
++SET( CMAKE_C_FLAGS "-Wall -pedantic --std=gnu99 -D_GNU_SOURCE -g ${CMAKE_C_FLAGS}" )
+ INCLUDE_DIRECTORIES ("${PROJECT_BINARY_DIR}/src")
+ list(APPEND SOURCES scl.c debug.c scllib.c lib_common.c args.c sclmalloc.c fallback.c)
+ ADD_EXECUTABLE (scl ${SOURCES})
+--
+1.9.3
+
diff --git a/0002-Fix-core-dumps-with-large-input-on-stdin-rhbz-125727.patch b/0002-Fix-core-dumps-with-large-input-on-stdin-rhbz-125727.patch
new file mode 100644
index 0000000..56e71fa
--- /dev/null
+++ b/0002-Fix-core-dumps-with-large-input-on-stdin-rhbz-125727.patch
@@ -0,0 +1,26 @@
+From c041733a012ec179950c5113a8875a6d4b8c2867 Mon Sep 17 00:00:00 2001
+From: Lubos Kardos <lkardos@redhat.com>
+Date: Thu, 27 Aug 2015 13:46:06 +0200
+Subject: [PATCH] Fix core dumps with large input on stdin (rhbz:1257274)
+
+---
+ src/args.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/args.c b/src/args.c
+index c524dbc..dda57cd 100644
+--- a/src/args.c
++++ b/src/args.c
+@@ -139,8 +139,8 @@ static int extract_command_stdin(struct scl_args *args)
+
+ len = 0;
+ while ((r = fread(command+len, 1, BUFSIZ, stdin)) == BUFSIZ) {
+- command = xrealloc(command, len+BUFSIZ+1);
+ len += r;
++ command = xrealloc(command, len+BUFSIZ+1);
+ }
+
+ if (feof(stdin)) {
+--
+1.9.3
+
diff --git a/scl-utils-layout.patch b/scl-utils-layout.patch
index c164f98..8069019 100644
--- a/scl-utils-layout.patch
+++ b/scl-utils-layout.patch
@@ -1,6 +1,6 @@
diff -up rpm/macros.scl.orig rpm/macros.scl
---- rpm/macros.scl.orig 2015-06-24 07:26:39.838044392 +0200
-+++ rpm/macros.scl 2015-06-24 07:34:13.762968582 +0200
+--- a/rpm/macros.scl.orig 2015-06-24 07:26:39.838044392 +0200
++++ a/rpm/macros.scl 2015-06-24 07:34:13.762968582 +0200
@@ -69,10 +69,13 @@ package or when debugging this package.
%global _datadir %{_prefix}/share
%global _sysconfdir %{_scl_root}/etc
diff --git a/scl-utils.spec b/scl-utils.spec
index dd5a04c..f5997b9 100644
--- a/scl-utils.spec
+++ b/scl-utils.spec
@@ -1,7 +1,9 @@
+%global macrosdir %(d=%{_rpmconfigdir}/macros.d; [ -d $d ] || d=%{_sysconfdir}/rpm; echo $d)
+
Name: scl-utils
Epoch: 1
Version: 2.0.1
-Release: 3%{dist}
+Release: 7%{dist}
Summary: Utilities for alternative packaging
License: GPLv2+
@@ -9,13 +11,14 @@ Group: Applications/File
URL: https://fedorahosted.org/SoftwareCollections/
Source0: https://fedorahosted.org/released/scl-utils/%{name}-%{version}.tar.bz2
Source1: macros.scl-filesystem
-
-Patch0: %{name}-layout.patch
-
Buildrequires: cmake
Buildrequires: rpm-devel
Requires: environment-modules
+Patch0: %{name}-layout.patch
+Patch1: 0001-Honor-CFLAGS-passed-to-cmake.patch
+Patch2: 0002-Fix-core-dumps-with-large-input-on-stdin-rhbz-125727.patch
+
%description
Run-time utility for alternative packaging.
@@ -29,10 +32,7 @@ Requires: redhat-rpm-config
Essential RPM build macros for alternative packaging.
%prep
-%setup -q
-
-%patch0 -p0
-
+%autosetup -p1
%build
%cmake
@@ -42,7 +42,12 @@ make %{?_smp_mflags} CFLAGS="$RPM_OPT_FLAGS" LDFLAGS="$RPM_LD_FLAGS"
%install
rm -rf %{buildroot}
make install DESTDIR=%{buildroot}
-cat %SOURCE1 >> %{buildroot}%{_sysconfdir}/rpm/macros.scl
+if [ %{macrosdir} != %{_sysconfdir}/rpm ]; then
+ mkdir -p %{buildroot}%{macrosdir}
+ mv %{buildroot}%{_sysconfdir}/rpm/macros.scl %{buildroot}%{macrosdir}
+ rmdir %{buildroot}%{_sysconfdir}/rpm
+fi
+cat %SOURCE1 >> %{buildroot}%{macrosdir}/macros.scl
mkdir -p %{buildroot}%{_sysconfdir}/scl
cd %{buildroot}%{_sysconfdir}/scl
mkdir modulefiles
@@ -67,7 +72,7 @@ rm -rf %buildroot
%files build
%defattr(-,root,root,-)
-%{_sysconfdir}/rpm/macros.scl
+%{macrosdir}/macros.scl
%{_rpmconfigdir}/scldeps.sh
%{_rpmconfigdir}/fileattrs/scl.attr
%{_rpmconfigdir}/fileattrs/sclbuild.attr
@@ -75,11 +80,31 @@ rm -rf %buildroot
%{_rpmconfigdir}/brp-scl-python-bytecompile
%changelog
+* Fri Sep 18 2015 Remi Collet <remi@remirepo.net> - 1:2.0.1-7
+- add "rh_layout" to remove /scls/ from _sysconfdir,
+ _sharedstatedir and _localstatedir, in sync with RHEL version
+ see #1198693
+
+* Thu Aug 27 2015 Lubos Kardos <lkardos@redhat.com> - 1:2.0.1-7
+- Fix core dumps with large input on stdin (#1257274)
+
+* Mon Jul 27 2015 Lubos Kardos <lkardos@redhat.com> - 1:2.0.1-6
+- Rebuild with the newest rpm.
+
+* Tue Jul 07 2015 Lubos Kardos <lkardos@redhat.com> - 1:2.0.1-5
+- Honor CFLAGS passed to cmake (#1239997)
+
* Wed Jun 24 2015 Remi Collet <remi@remirepo.net> - 1:2.0.1-3
- add "rh_layout" to remove /scls/ from _sysconfdir,
_sharedstatedir and _localstatedir, in sync with RHEL version
see #1198693
+* Fri Jun 19 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:2.0.1-4
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
+
+* Wed Mar 4 2015 Ville Skyttä <ville.skytta@iki.fi> - 1:2.0.1-3
+- Install macros in %%{_rpmconfigdir}/macros.d where available (#1074284)
+
* Wed Jan 21 2015 Lubos Kardos <lkardos@redhat.com> - 1:2.0.1-2
- added owning of module file