- rebased to 1.29.0
- dropped daemon hardening patch as hardening is enabled globally - added hmcdrvfs and cpacfstatsd subpackages - install systemd units where available
This commit is contained in:
parent
d7aa0839fa
commit
056c251a8d
1
.gitignore
vendored
1
.gitignore
vendored
@ -10,3 +10,4 @@ src_vipa-2.0.4.tar.gz
|
||||
/s390-tools-1.20.0.tar.bz2
|
||||
/s390-tools-1.23.0.tar.bz2
|
||||
/src_vipa-2.1.0.tar.gz
|
||||
/s390-tools-1.29.0.tar.bz2
|
||||
|
@ -6,7 +6,7 @@ diff -urN cmsfs-1.1.8/cmsfssed.sh cmsfs-1.1.8_/cmsfssed.sh
|
||||
MODULES_DIRECTORY="/lib/modules/`uname -r`/fs"
|
||||
;;
|
||||
- 2.4*|2.5*)
|
||||
+ 2.4*|2.5*|2.6*|3.*)
|
||||
+ 2.4*|2.5*|2.6*|3.*|4.*)
|
||||
LINUX_RELEASE="2.4"
|
||||
# ln -s cmsfs24x.c cmsfsvfs.c
|
||||
INCLUDES="-I/lib/modules/`uname -r`/build/include"
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,57 +0,0 @@
|
||||
diff -up s390-tools-1.23.0/tape390/tape390_display.c.format s390-tools-1.23.0/tape390/tape390_display.c
|
||||
--- s390-tools-1.23.0/tape390/tape390_display.c.format 2014-02-10 04:59:30.430126870 -0500
|
||||
+++ s390-tools-1.23.0/tape390/tape390_display.c 2014-02-10 05:00:08.960127361 -0500
|
||||
@@ -175,7 +175,7 @@ int main(int argc, char *argv[]) {
|
||||
) {
|
||||
switch(c) {
|
||||
case 'h':
|
||||
- fprintf(stderr, help_text);
|
||||
+ fprintf(stderr, "%s", help_text);
|
||||
exit(0);
|
||||
case 'b':
|
||||
ds.cntrl.blink = 1;
|
||||
@@ -266,7 +266,7 @@ int main(int argc, char *argv[]) {
|
||||
strchkcpy(ds.message1, argv[optind]);
|
||||
pathname = argv[optind+1];
|
||||
} else {
|
||||
- fprintf(stderr, help_text);
|
||||
+ fprintf(stderr, "%s", help_text);
|
||||
exit(1);
|
||||
}
|
||||
|
||||
diff -up s390-tools-1.23.0/vmur/vmur.cpp.format s390-tools-1.23.0/vmur/vmur.cpp
|
||||
--- s390-tools-1.23.0/vmur/vmur.cpp.format 2014-02-10 05:00:32.430127965 -0500
|
||||
+++ s390-tools-1.23.0/vmur/vmur.cpp 2014-02-10 05:00:47.900128212 -0500
|
||||
@@ -201,7 +201,7 @@ static char HELP_TEXT[] =
|
||||
|
||||
static void usage(void)
|
||||
{
|
||||
- printf(HELP_TEXT);
|
||||
+ printf("%s", HELP_TEXT);
|
||||
}
|
||||
|
||||
/*
|
||||
diff -up s390-tools-1.23.0/zdump/opts.c.format s390-tools-1.23.0/zdump/opts.c
|
||||
--- s390-tools-1.23.0/zdump/opts.c.format 2014-02-10 04:58:26.760125680 -0500
|
||||
+++ s390-tools-1.23.0/zdump/opts.c 2014-02-10 04:58:45.510125937 -0500
|
||||
@@ -72,7 +72,7 @@ static void print_usage_exit(void)
|
||||
*/
|
||||
static void print_help_exit(void)
|
||||
{
|
||||
- STDOUT(help_text);
|
||||
+ STDOUT("%s", help_text);
|
||||
zg_exit(0);
|
||||
}
|
||||
|
||||
diff -up s390-tools-1.23.0/zdump/zgetdump.c.format s390-tools-1.23.0/zdump/zgetdump.c
|
||||
--- s390-tools-1.23.0/zdump/zgetdump.c.format 2014-02-10 04:57:23.100124931 -0500
|
||||
+++ s390-tools-1.23.0/zdump/zgetdump.c 2014-02-10 04:56:57.640124530 -0500
|
||||
@@ -95,7 +95,7 @@ static void kdump_select_check(void)
|
||||
return;
|
||||
if (!dfi_kdump_base())
|
||||
return;
|
||||
- ERR_EXIT(msg);
|
||||
+ ERR_EXIT("%s", msg);
|
||||
}
|
||||
|
||||
/*
|
@ -1,75 +0,0 @@
|
||||
From a1d489d42248acd0b5f2e3348df5f2ece22dc9e0 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Dan=20Hor=C3=A1k?= <dan@danny.cz>
|
||||
Date: Tue, 5 Nov 2013 15:34:11 +0100
|
||||
Subject: [PATCH] build daemons hardened
|
||||
|
||||
---
|
||||
common.mak | 3 +++
|
||||
cpuplugd/Makefile | 4 ++--
|
||||
mon_tools/Makefile | 2 ++
|
||||
osasnmpd/Makefile.rules | 3 +++
|
||||
4 files changed, 10 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/common.mak b/common.mak
|
||||
index 4373da5..7b992b4 100644
|
||||
--- a/common.mak
|
||||
+++ b/common.mak
|
||||
@@ -76,6 +76,9 @@ CXXFLAGS = $(WARNFLAGS) -O3 -DS390_TOOLS_RELEASE=$(S390_TOOLS_RELEASE) \
|
||||
-DS390_TOOLS_SYSCONFDIR=$(SYSCONFDIR) \
|
||||
-g $(OPT_FLAGS)
|
||||
|
||||
+DAEMON_CFLAGS = -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
|
||||
+DAEMON_LDFLAGS = -specs=/usr/lib/rpm/redhat/redhat-hardened-ld
|
||||
+
|
||||
# make G=1
|
||||
# Compile tools so that gcov can be used to collect code coverage data.
|
||||
# See the gcov man page for details.
|
||||
diff --git a/cpuplugd/Makefile b/cpuplugd/Makefile
|
||||
index 4a72075..28480f5 100644
|
||||
--- a/cpuplugd/Makefile
|
||||
+++ b/cpuplugd/Makefile
|
||||
@@ -1,6 +1,6 @@
|
||||
include ../common.mak
|
||||
|
||||
-CFLAGS += -I../include
|
||||
+CFLAGS += $(DAEMON_CFLAGS) -I../include
|
||||
|
||||
all: cpuplugd
|
||||
|
||||
@@ -10,7 +10,7 @@ OBJECTS = daemon.o cpu.o info.o terms.o config.o main.o getopt.o mem.o
|
||||
$(OBJECTS): cpuplugd.h
|
||||
|
||||
cpuplugd: $(OBJECTS)
|
||||
- $(LINK) $(LDFLAGS) $^ $(LOADLIBES) $(LDLIBS) -o $@
|
||||
+ $(LINK) $(DAEMON_LDFLAGS) $(LDFLAGS) $^ $(LOADLIBES) $(LDLIBS) -o $@
|
||||
|
||||
clean:
|
||||
rm -f cpuplugd $(OBJECTS)
|
||||
diff --git a/mon_tools/Makefile b/mon_tools/Makefile
|
||||
index c8c58fc..b025f65 100644
|
||||
--- a/mon_tools/Makefile
|
||||
+++ b/mon_tools/Makefile
|
||||
@@ -1,6 +1,8 @@
|
||||
include ../common.mak
|
||||
|
||||
CPPFLAGS += -I../include
|
||||
+CFLAGS += $(DAEMON_CFLAGS)
|
||||
+LDFLAGS += $(DAEMON_LDFLAGS)
|
||||
|
||||
all: mon_fsstatd mon_procd
|
||||
|
||||
diff --git a/osasnmpd/Makefile.rules b/osasnmpd/Makefile.rules
|
||||
index 6668ed6..11ee8eb 100644
|
||||
--- a/osasnmpd/Makefile.rules
|
||||
+++ b/osasnmpd/Makefile.rules
|
||||
@@ -10,4 +10,7 @@ CPPFLAGS += -DNETSNMP5
|
||||
endif
|
||||
CPPFLAGS += -I../include
|
||||
|
||||
+CFLAGS += $(DAEMON_CFLAGS)
|
||||
+LDFLAGS += $(DAEMON_LDFLAGS)
|
||||
+
|
||||
OBJS = ibmOSAMib.o ibmOSAMibUtil.o osasnmpd.o
|
||||
--
|
||||
1.8.1.4
|
||||
|
33
s390-tools-1.29.0-format.patch
Normal file
33
s390-tools-1.29.0-format.patch
Normal file
@ -0,0 +1,33 @@
|
||||
diff -up s390-tools-1.29.0/cpacfstats/cpacfstatsd.c.format s390-tools-1.29.0/cpacfstats/cpacfstatsd.c
|
||||
--- s390-tools-1.29.0/cpacfstats/cpacfstatsd.c.format 2015-06-23 04:52:38.141420401 -0400
|
||||
+++ s390-tools-1.29.0/cpacfstats/cpacfstatsd.c 2015-06-23 04:53:01.271420401 -0400
|
||||
@@ -348,7 +348,7 @@ int eprint(const char *format, ...)
|
||||
|
||||
if (n > 0) {
|
||||
if (daemonized)
|
||||
- syslog(LOG_WARNING, buf);
|
||||
+ syslog(LOG_WARNING, "%s", buf);
|
||||
else
|
||||
fputs(buf, stderr);
|
||||
}
|
||||
diff -up s390-tools-1.29.0/tape390/tape390_display.c.format s390-tools-1.29.0/tape390/tape390_display.c
|
||||
--- s390-tools-1.29.0/tape390/tape390_display.c.format 2015-05-13 05:17:55.000000000 -0400
|
||||
+++ s390-tools-1.29.0/tape390/tape390_display.c 2015-06-23 04:50:24.061420401 -0400
|
||||
@@ -175,7 +175,7 @@ int main(int argc, char *argv[]) {
|
||||
) {
|
||||
switch(c) {
|
||||
case 'h':
|
||||
- fprintf(stderr, help_text);
|
||||
+ fprintf(stderr, "%s", help_text);
|
||||
exit(0);
|
||||
case 'b':
|
||||
ds.cntrl.blink = 1;
|
||||
@@ -266,7 +266,7 @@ int main(int argc, char *argv[]) {
|
||||
strchkcpy(ds.message1, argv[optind]);
|
||||
pathname = argv[optind+1];
|
||||
} else {
|
||||
- fprintf(stderr, help_text);
|
||||
+ fprintf(stderr, "%s", help_text);
|
||||
exit(1);
|
||||
}
|
||||
|
@ -4,8 +4,8 @@
|
||||
Name: s390utils
|
||||
Summary: Utilities and daemons for IBM System/z
|
||||
Group: System Environment/Base
|
||||
Version: 1.23.0
|
||||
Release: 16%{?dist}
|
||||
Version: 1.29.0
|
||||
Release: 1%{?dist}
|
||||
Epoch: 2
|
||||
License: GPLv2 and GPLv2+ and CPL
|
||||
ExclusiveArch: s390 s390x
|
||||
@ -33,9 +33,7 @@ Source18: cpuplugd.initd
|
||||
Source19: mon_statd.initd
|
||||
Source21: normalize_dasd_arg
|
||||
|
||||
Patch1: s390-tools-1.23.0-fedora.patch
|
||||
Patch2: s390-tools-1.23.0-hardening.patch
|
||||
Patch3: s390-tools-1.23.0-format.patch
|
||||
Patch1: s390-tools-1.29.0-format.patch
|
||||
|
||||
Patch1000: cmsfs-1.1.8-warnings.patch
|
||||
Patch1001: cmsfs-1.1.8-kernel26.patch
|
||||
@ -62,9 +60,7 @@ be used together with the zSeries (s390) Linux kernel and device drivers.
|
||||
%setup -q -n s390-tools-%{version} -a 4 -a 6
|
||||
|
||||
# Fedora/RHEL changes
|
||||
%patch1 -p1 -b .fedora
|
||||
%patch2 -p1 -b .hardening
|
||||
%patch3 -p1 -b .format
|
||||
%patch1 -p1 -b .format
|
||||
|
||||
#
|
||||
# cmsfs
|
||||
@ -119,6 +115,7 @@ make install \
|
||||
MANDIR=$RPM_BUILD_ROOT%{_mandir} \
|
||||
LIBDIR=${RPM_BUILD_ROOT}/%{_lib} \
|
||||
DISTRELEASE=%{release} \
|
||||
SYSTEMDSYSTEMUNITDIR=$RPM_BUILD_ROOT%{_unitdir} \
|
||||
V=1
|
||||
|
||||
install -p -m 644 zipl/boot/tape0.bin $RPM_BUILD_ROOT/boot/tape0
|
||||
@ -210,6 +207,8 @@ Requires(pre): chkconfig
|
||||
Requires(preun): chkconfig
|
||||
Requires(preun): initscripts
|
||||
BuildRequires: ncurses-devel
|
||||
BuildRequires: libpfm-devel
|
||||
BuildRequires: glibc-static
|
||||
|
||||
|
||||
%description base
|
||||
@ -389,10 +388,12 @@ fi
|
||||
/sbin/zgetdump
|
||||
/sbin/znetconf
|
||||
/sbin/dbginfo.sh
|
||||
%{_bindir}/lscpumf
|
||||
%{_sbindir}/lsluns
|
||||
%{_sbindir}/lsmem
|
||||
%{_sbindir}/lsreipl
|
||||
%{_sbindir}/lsshut
|
||||
%{_sbindir}/chcpumf
|
||||
%{_sbindir}/chmem
|
||||
%{_sbindir}/chreipl
|
||||
%{_sbindir}/chshut
|
||||
@ -408,10 +409,12 @@ fi
|
||||
/lib/s390-tools
|
||||
%{_mandir}/man1/dbginfo.sh.1*
|
||||
%{_mandir}/man1/zfcpdbf.1*
|
||||
%{_mandir}/man1/lscpumf.1*
|
||||
%{_mandir}/man4/prandom.4*
|
||||
%{_mandir}/man5/zipl.conf.5*
|
||||
%{_mandir}/man8/chccwdev.8*
|
||||
%{_mandir}/man8/chchp.8*
|
||||
%{_mandir}/man8/chcpumf.8*
|
||||
%{_mandir}/man8/chmem.8*
|
||||
%{_mandir}/man8/chreipl.8*
|
||||
%{_mandir}/man8/chshut.8*
|
||||
@ -449,6 +452,8 @@ fi
|
||||
%{_mandir}/man8/zgetdump.8*
|
||||
%{_mandir}/man8/znetconf.8*
|
||||
%{_mandir}/man8/zipl.8*
|
||||
%dir %{_datadir}/s390-tools/
|
||||
%{_datadir}/s390-tools/cpumf/
|
||||
|
||||
# Additional Redhat specific stuff
|
||||
/boot/tape0
|
||||
@ -627,6 +632,7 @@ Requires(pre): shadow-utils
|
||||
Requires(post): grep
|
||||
Requires(postun): grep
|
||||
BuildRequires: gettext
|
||||
BuildRequires: systemd
|
||||
|
||||
%description iucvterm
|
||||
A set of applications to provide terminal access via the z/VM Inter-User
|
||||
@ -675,6 +681,8 @@ fi
|
||||
%{_mandir}/man7/af_iucv.7*
|
||||
%{_mandir}/man8/chiucvallow.8*
|
||||
%{_mandir}/man9/hvc_iucv.9*
|
||||
%{_unitdir}/iucvtty-login@.service
|
||||
%{_unitdir}/ttyrun-getty@.service
|
||||
|
||||
#
|
||||
# *********************** cmsfs package ***********************
|
||||
@ -737,6 +745,58 @@ This package contains the z/OS data set access based on FUSE.
|
||||
%{_bindir}/zdsfs
|
||||
%{_mandir}/man1/zdsfs.1*
|
||||
|
||||
#
|
||||
# *********************** hmcdrvfs package ***********************
|
||||
#
|
||||
%package hmcdrvfs
|
||||
License: GPLv2
|
||||
Summary: HMC drive file system based on FUSE
|
||||
Group: System Environment/Base
|
||||
BuildRequires: fuse-devel
|
||||
Requires: fuse
|
||||
|
||||
%description hmcdrvfs
|
||||
This package contains a HMC drive file system based on FUSE and a tool
|
||||
to list files and directories.
|
||||
|
||||
%files hmcdrvfs
|
||||
%{_bindir}/hmcdrvfs
|
||||
%{_sbindir}/lshmc
|
||||
%{_mandir}/man1/hmcdrvfs.1*
|
||||
%{_mandir}/man8/lshmc.8*
|
||||
|
||||
#
|
||||
# *********************** cpacfstatsd package ***********************
|
||||
#
|
||||
%package cpacfstatsd
|
||||
License: GPLv2
|
||||
Summary: Monitor and maintain CPACF activity counters
|
||||
Group: System Environment/Base
|
||||
Requires(post): systemd
|
||||
Requires(preun): systemd
|
||||
Requires(postun): systemd
|
||||
BuildRequires: systemd
|
||||
|
||||
%description cpacfstatsd
|
||||
The cpacfstats tools provide a client/server application set to monitor
|
||||
and maintain CPACF activity counters.
|
||||
|
||||
%post cpacfstatsd
|
||||
%systemd_post cpacfstatsd.service
|
||||
|
||||
%preun cpacfstatsd
|
||||
%systemd_preun cpacfstatsd.service
|
||||
|
||||
%postun cpacfstatsd
|
||||
%systemd_postun_with_restart cpacfstatsd.service
|
||||
|
||||
%files cpacfstatsd
|
||||
%{_bindir}/cpacfstats
|
||||
%{_sbindir}/cpacfstatsd
|
||||
%{_mandir}/man1/cpacfstats.1*
|
||||
%{_mandir}/man8/cpacfstatsd.8*
|
||||
%{_unitdir}/cpacfstatsd.service
|
||||
|
||||
#
|
||||
# *********************** devel package ***********************
|
||||
#
|
||||
@ -753,6 +813,12 @@ User-space development files for the s390/s390x architecture.
|
||||
|
||||
|
||||
%changelog
|
||||
* Tue Jun 23 2015 Dan Horák <dan[at]danny.cz> - 2:1.29.0-1
|
||||
- rebased to 1.29.0
|
||||
- dropped daemon hardening patch as hardening is enabled globally
|
||||
- added hmcdrvfs and cpacfstatsd subpackages
|
||||
- install systemd units where available
|
||||
|
||||
* Fri Jun 19 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2:1.23.0-16
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user