From 24c2d0e20f520a58ed8795c16588d63013c4cef23b55634b55dbd69ac39505f9 Mon Sep 17 00:00:00 2001 From: David Disseldorp Date: Tue, 28 Mar 2017 22:11:53 +0000 Subject: [PATCH] Accepting request 483206 from home:dmdiss:pcp-311 - Update to 3.11.8 See http://git.pcp.io/cgi-bin/gitweb.cgi?p=pcp/pcp.git;a=blob_plain;f=CHANGELOG;hb=3.11.8 for details. - Remove 0010-build-do-not-include-.gitignore-in-installed-file-se.patch + Upstream - Drop pcp-webjs.src.tar.gz + https://github.com/performancecopilot/pcp-webjs/issues/3 + Vector will be pulled in from the upstream source in future - Enable pmda-systemd package + libsystemd pkg-config detection fixed upstream - New packages + pcp-devel: Upstream split of non-essential devel packages from libpcp-devel + pcp-pmda-bind2 + pcp-pmda-docker + pcp-pmda-lio + pcp-pmda-nutcracker + pcp-pmda-oracle + pcp-pmda-redis + pcp-pmda-libvirt + pcp-export-pcp2influxdb - Update to 3.10.9 See http://git.pcp.io/cgi-bin/gitweb.cgi?p=pcp/pcp.git;a=blob_plain;f=CHANGELOG;hb=3.10.9 for details. - Drop obsolete 0001-Fix-XEN-build.patch + PCP_PS_ALL_FLAGS now used explicitly - Add 0010-build-do-not-include-.gitignore-in-installed-file-se.patch - Split out a number of agents from the base package into separate rpms - Disable sheet2pcp OBS-URL: https://build.opensuse.org/request/show/483206 OBS-URL: https://build.opensuse.org/package/show/Base:System/pcp?expand=0&rev=49 --- 0001-Fix-XEN-build.patch | 21 - ...ll-libraries-without-exec-permission.patch | 207 +- 0003-pcp-legacy-init-lsb.patch | 15 +- ...gger-and-pmie-logdirs-during-install.patch | 33 +- 0007-Honor-CFLAGS-in-qmake.patch | 75 +- _service | 17 + ...vice:recompress:tar_scm:pcp-3.11.8.tar.bz2 | 3 + _service:set_version:pcp.spec | 2989 +++++++++++++++++ pcp-3.10.4.src.tar.gz | 3 - pcp-webjs.src.tar.gz | 3 - pcp.changes | 49 + pcp.spec | 2050 +++++++++-- 12 files changed, 5007 insertions(+), 458 deletions(-) delete mode 100644 0001-Fix-XEN-build.patch create mode 100644 _service create mode 100644 _service:recompress:tar_scm:pcp-3.11.8.tar.bz2 create mode 100644 _service:set_version:pcp.spec delete mode 100644 pcp-3.10.4.src.tar.gz delete mode 100644 pcp-webjs.src.tar.gz diff --git a/0001-Fix-XEN-build.patch b/0001-Fix-XEN-build.patch deleted file mode 100644 index 32c8a0e..0000000 --- a/0001-Fix-XEN-build.patch +++ /dev/null @@ -1,21 +0,0 @@ -From 58127dca98f11270491383946d2714fd9d983d76 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Klaus=20K=C3=A4mpf?= -Date: Fri, 12 Dec 2014 15:42:25 +0100 -Subject: [PATCH 1/6] Fix XEN build - ---- - configure.ac | 1 + - 1 file changed, 1 insertion(+) - -Index: pcp-3.10.4/configure.ac -=================================================================== ---- pcp-3.10.4.orig/configure.ac -+++ pcp-3.10.4/configure.ac -@@ -1105,6 +1105,7 @@ NR == 1 { if ($1 != "UID" && $1 != "US - # Unix variants - $2 == 1 && / init/ { print "OK"; exit } - $2 == 1 && / \/etc\/init/ { print "OK"; exit } -+$2 == 1 && / \/bin\/bash/ { print "OK"; exit } - # Fedora 9 - $2 == 1 && / \/sbin\/init/ { print "OK"; exit } - # Fedora 15 diff --git a/0002-Install-libraries-without-exec-permission.patch b/0002-Install-libraries-without-exec-permission.patch index 6d02f7d..bad8e08 100644 --- a/0002-Install-libraries-without-exec-permission.patch +++ b/0002-Install-libraries-without-exec-permission.patch @@ -22,10 +22,10 @@ Subject: [PATCH 2/6] Install libraries without exec permission src/pmdas/solaris/GNUmakefile | 3 ++- 16 files changed, 29 insertions(+), 23 deletions(-) -Index: pcp-3.10.4/src/genpmda/genpmda +Index: pcp-3.11.8/src/genpmda/genpmda =================================================================== ---- pcp-3.10.4.orig/src/genpmda/genpmda -+++ pcp-3.10.4/src/genpmda/genpmda +--- pcp-3.11.8.orig/src/genpmda/genpmda ++++ pcp-3.11.8/src/genpmda/genpmda @@ -909,7 +909,7 @@ install: default \$(INSTALL) -m 755 -d \$(PCP_VAR_DIR)/pmdas \$(INSTALL) -m 755 -d \$(PMDADIR) @@ -44,11 +44,11 @@ Index: pcp-3.10.4/src/genpmda/genpmda \$(INSTALL) -m 755 -f $oflag/Install \$(PMDADIR)/Install \$(INSTALL) -m 755 -f $oflag/Remove \$(PMDADIR)/Remove \$(INSTALL) -m 644 -f $oflag/Makefile.install \$(PMDADIR)/Makefile -Index: pcp-3.10.4/src/libpcp/src/GNUmakefile +Index: pcp-3.11.8/src/libpcp/src/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/libpcp/src/GNUmakefile -+++ pcp-3.10.4/src/libpcp/src/GNUmakefile -@@ -125,7 +125,7 @@ endif +--- pcp-3.11.8.orig/src/libpcp/src/GNUmakefile ++++ pcp-3.11.8/src/libpcp/src/GNUmakefile +@@ -103,7 +103,7 @@ endif install : default ifneq ($(LIBTARGET),) @@ -57,7 +57,7 @@ Index: pcp-3.10.4/src/libpcp/src/GNUmakefile endif ifneq ($(SYMTARGET),) for tt in $(SYMTARGET); do \ -@@ -133,7 +133,7 @@ ifneq ($(SYMTARGET),) +@@ -111,7 +111,7 @@ ifneq ($(SYMTARGET),) done endif ifneq ($(STATICLIBTARGET),) @@ -66,10 +66,10 @@ Index: pcp-3.10.4/src/libpcp/src/GNUmakefile endif default_pcp : default -Index: pcp-3.10.4/src/libpcp_gui/src/GNUmakefile +Index: pcp-3.11.8/src/libpcp_gui/src/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/libpcp_gui/src/GNUmakefile -+++ pcp-3.10.4/src/libpcp_gui/src/GNUmakefile +--- pcp-3.11.8.orig/src/libpcp_gui/src/GNUmakefile ++++ pcp-3.11.8/src/libpcp_gui/src/GNUmakefile @@ -54,7 +54,7 @@ include $(BUILDRULES) install: default @@ -88,10 +88,10 @@ Index: pcp-3.10.4/src/libpcp_gui/src/GNUmakefile endif default_pcp: default -Index: pcp-3.10.4/src/libpcp_import/src/GNUmakefile +Index: pcp-3.11.8/src/libpcp_import/src/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/libpcp_import/src/GNUmakefile -+++ pcp-3.10.4/src/libpcp_import/src/GNUmakefile +--- pcp-3.11.8.orig/src/libpcp_import/src/GNUmakefile ++++ pcp-3.11.8/src/libpcp_import/src/GNUmakefile @@ -53,7 +53,7 @@ include $(BUILDRULES) install: default @@ -110,11 +110,11 @@ Index: pcp-3.10.4/src/libpcp_import/src/GNUmakefile endif default_pcp: default -Index: pcp-3.10.4/src/libpcp_mmv/src/GNUmakefile +Index: pcp-3.11.8/src/libpcp_mmv/src/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/libpcp_mmv/src/GNUmakefile -+++ pcp-3.10.4/src/libpcp_mmv/src/GNUmakefile -@@ -48,7 +48,7 @@ include $(BUILDRULES) +--- pcp-3.11.8.orig/src/libpcp_mmv/src/GNUmakefile ++++ pcp-3.11.8/src/libpcp_mmv/src/GNUmakefile +@@ -47,7 +47,7 @@ include $(BUILDRULES) install: default ifneq ($(LIBTARGET),) @@ -123,7 +123,7 @@ Index: pcp-3.10.4/src/libpcp_mmv/src/GNUmakefile endif ifneq ($(SYMTARGET),) for tt in $(SYMTARGET); do \ -@@ -56,7 +56,7 @@ ifneq ($(SYMTARGET),) +@@ -55,7 +55,7 @@ ifneq ($(SYMTARGET),) done endif ifneq ($(STATICLIBTARGET),) @@ -132,11 +132,11 @@ Index: pcp-3.10.4/src/libpcp_mmv/src/GNUmakefile endif default_pcp: default -Index: pcp-3.10.4/src/libpcp_pmda/src/GNUmakefile +Index: pcp-3.11.8/src/libpcp_pmda/src/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/libpcp_pmda/src/GNUmakefile -+++ pcp-3.10.4/src/libpcp_pmda/src/GNUmakefile -@@ -60,7 +60,7 @@ include $(BUILDRULES) +--- pcp-3.11.8.orig/src/libpcp_pmda/src/GNUmakefile ++++ pcp-3.11.8/src/libpcp_pmda/src/GNUmakefile +@@ -61,7 +61,7 @@ include $(BUILDRULES) install: default ifneq ($(LIBTARGET),) @@ -145,7 +145,7 @@ Index: pcp-3.10.4/src/libpcp_pmda/src/GNUmakefile endif ifneq ($(SYMTARGET),) for tt in $(SYMTARGET); do \ -@@ -68,7 +68,7 @@ ifneq ($(SYMTARGET),) +@@ -69,7 +69,7 @@ ifneq ($(SYMTARGET),) done endif ifneq ($(STATICLIBTARGET),) @@ -154,10 +154,10 @@ Index: pcp-3.10.4/src/libpcp_pmda/src/GNUmakefile endif default_pcp: default -Index: pcp-3.10.4/src/libpcp_trace/src/GNUmakefile +Index: pcp-3.11.8/src/libpcp_trace/src/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/libpcp_trace/src/GNUmakefile -+++ pcp-3.10.4/src/libpcp_trace/src/GNUmakefile +--- pcp-3.11.8.orig/src/libpcp_trace/src/GNUmakefile ++++ pcp-3.11.8/src/libpcp_trace/src/GNUmakefile @@ -56,13 +56,13 @@ include $(BUILDRULES) install : default @@ -174,11 +174,11 @@ Index: pcp-3.10.4/src/libpcp_trace/src/GNUmakefile endif default_pcp : default -Index: pcp-3.10.4/src/pmdas/aix/GNUmakefile +Index: pcp-3.11.8/src/pmdas/aix/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/pmdas/aix/GNUmakefile -+++ pcp-3.10.4/src/pmdas/aix/GNUmakefile -@@ -43,7 +43,8 @@ build-me: common.h root_aix domain.h $(C +--- pcp-3.11.8.orig/src/pmdas/aix/GNUmakefile ++++ pcp-3.11.8/src/pmdas/aix/GNUmakefile +@@ -44,7 +44,8 @@ build-me: common.h root_aix $(CMDTARGET) install: build-me $(INSTALL) -m 755 -d $(PMDADIR) $(INSTALL) -m 644 domain.h help.dir help.pag $(PMDADIR) @@ -188,11 +188,11 @@ Index: pcp-3.10.4/src/pmdas/aix/GNUmakefile $(INSTALL) -m 644 root_aix $(PCP_VAR_DIR)/pmns/root_aix else build-me: -Index: pcp-3.10.4/src/pmdas/darwin/GNUmakefile +Index: pcp-3.11.8/src/pmdas/darwin/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/pmdas/darwin/GNUmakefile -+++ pcp-3.10.4/src/pmdas/darwin/GNUmakefile -@@ -47,7 +47,8 @@ build-me: root_darwin domain.h $(LIBTARG +--- pcp-3.11.8.orig/src/pmdas/darwin/GNUmakefile ++++ pcp-3.11.8/src/pmdas/darwin/GNUmakefile +@@ -48,7 +48,8 @@ build-me: root_darwin $(LIBTARGET) $(CMD install: build-me $(INSTALL) -m 755 -d $(PMDADIR) $(INSTALL) -m 644 domain.h help.dir help.pag $(PMDADIR) @@ -202,11 +202,11 @@ Index: pcp-3.10.4/src/pmdas/darwin/GNUmakefile $(INSTALL) -m 644 root_darwin $(PCP_VAR_DIR)/pmns/root_darwin else build-me: -Index: pcp-3.10.4/src/pmdas/freebsd/GNUmakefile +Index: pcp-3.11.8/src/pmdas/freebsd/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/pmdas/freebsd/GNUmakefile -+++ pcp-3.10.4/src/pmdas/freebsd/GNUmakefile -@@ -48,7 +48,8 @@ build-me: domain.h $(LIBTARGET) $(CMDTAR +--- pcp-3.11.8.orig/src/pmdas/freebsd/GNUmakefile ++++ pcp-3.11.8/src/pmdas/freebsd/GNUmakefile +@@ -48,7 +48,8 @@ build-me: $(LIBTARGET) $(CMDTARGET) help install: default $(INSTALL) -m 755 -d $(PMDADIR) $(INSTALL) -m 644 domain.h help help.dir help.pag $(PMDADIR) @@ -216,25 +216,25 @@ Index: pcp-3.10.4/src/pmdas/freebsd/GNUmakefile $(INSTALL) -m 644 root_freebsd $(PCP_VAR_DIR)/pmns/root_freebsd else build-me: -Index: pcp-3.10.4/src/pmdas/linux/GNUmakefile +Index: pcp-3.11.8/src/pmdas/linux/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/pmdas/linux/GNUmakefile -+++ pcp-3.10.4/src/pmdas/linux/GNUmakefile -@@ -75,7 +75,8 @@ build-me: domain.h $(LIBTARGET) $(CMDTAR - install: default +--- pcp-3.11.8.orig/src/pmdas/linux/GNUmakefile ++++ pcp-3.11.8/src/pmdas/linux/GNUmakefile +@@ -78,7 +78,8 @@ install: default $(INSTALL) -m 755 -d $(PMDADIR) $(INSTALL) -m 644 domain.h help $(HELPTARGETS) $(PMDADIR) + $(INSTALL) -m 644 bandwidth.conf $(PMDADIR)/samplebandwidth.conf - $(INSTALL) -m 755 $(LIBTARGET) $(CMDTARGET) $(PMDADIR) + $(INSTALL) -m 644 $(LIBTARGET) $(PMDADIR)/$(LIBTARGET) + $(INSTALL) -m 755 $(CMDTARGET) $(PMDADIR)/$(CMDTARGET) $(INSTALL) -m 644 root_linux $(PCP_VAR_DIR)/pmns/root_linux $(INSTALL) -m 644 proc_net_snmp_migrate.conf $(LOGREWRITEDIR)/linux_proc_net_snmp_migrate.conf - else -Index: pcp-3.10.4/src/pmdas/linux_proc/GNUmakefile + $(INSTALL) -m 644 proc_net_tcp_migrate.conf $(LOGREWRITEDIR)/linux_proc_net_tcp_migrate.conf +Index: pcp-3.11.8/src/pmdas/linux_proc/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/pmdas/linux_proc/GNUmakefile -+++ pcp-3.10.4/src/pmdas/linux_proc/GNUmakefile -@@ -66,7 +66,8 @@ build-me: domain.h root_proc $(LIBTARGET +--- pcp-3.11.8.orig/src/pmdas/linux_proc/GNUmakefile ++++ pcp-3.11.8/src/pmdas/linux_proc/GNUmakefile +@@ -68,7 +68,8 @@ build-me: root_proc $(LIBTARGET) $(CMDTA install: default $(INSTALL) -m 755 -d $(PMDADIR) $(INSTALL) -m 644 domain.h help help.dir help.pag root root_proc samplehotproc.conf $(PMDADIR) @@ -244,11 +244,11 @@ Index: pcp-3.10.4/src/pmdas/linux_proc/GNUmakefile $(INSTALL) -m 644 root_proc $(PCP_VAR_DIR)/pmns/root_proc $(INSTALL) -m 644 $(LOGREWRITERS) $(PCP_VAR_DIR)/config/pmlogrewrite @$(INSTALL_MAN) -Index: pcp-3.10.4/src/pmdas/lustrecomm/GNUmakefile +Index: pcp-3.11.8/src/pmdas/lustrecomm/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/pmdas/lustrecomm/GNUmakefile -+++ pcp-3.10.4/src/pmdas/lustrecomm/GNUmakefile -@@ -50,7 +50,7 @@ build-me: domain.h $(TARGETS) +--- pcp-3.11.8.orig/src/pmdas/lustrecomm/GNUmakefile ++++ pcp-3.11.8/src/pmdas/lustrecomm/GNUmakefile +@@ -51,7 +51,7 @@ build-me: $(TARGETS) install: default $(INSTALL) -m 755 -d $(PMDADIR) $(INSTALL) -m 755 $(CMDTARGET) $(PMDADIR)/$(CMDTARGET) @@ -257,11 +257,11 @@ Index: pcp-3.10.4/src/pmdas/lustrecomm/GNUmakefile $(INSTALL) -m 755 Install Remove $(PMDADIR) $(INSTALL) -m 644 $(DFILES) root pmns domain.h help $(PMDADIR) @$(INSTALL_MAN) -Index: pcp-3.10.4/src/pmdas/pmcd/src/GNUmakefile +Index: pcp-3.11.8/src/pmdas/pmcd/src/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/pmdas/pmcd/src/GNUmakefile -+++ pcp-3.10.4/src/pmdas/pmcd/src/GNUmakefile -@@ -54,7 +54,7 @@ default: $(LIBTARGET) domain.h +--- pcp-3.11.8.orig/src/pmdas/pmcd/src/GNUmakefile ++++ pcp-3.11.8/src/pmdas/pmcd/src/GNUmakefile +@@ -55,7 +55,7 @@ default: $(LIBTARGET) install: default $(INSTALL) -m 755 -d $(PCP_PMDAS_DIR)/pmcd @@ -270,11 +270,11 @@ Index: pcp-3.10.4/src/pmdas/pmcd/src/GNUmakefile include $(BUILDRULES) -Index: pcp-3.10.4/src/pmdas/sendmail/GNUmakefile +Index: pcp-3.11.8/src/pmdas/sendmail/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/pmdas/sendmail/GNUmakefile -+++ pcp-3.10.4/src/pmdas/sendmail/GNUmakefile -@@ -39,7 +39,7 @@ include $(BUILDRULES) +--- pcp-3.11.8.orig/src/pmdas/sendmail/GNUmakefile ++++ pcp-3.11.8/src/pmdas/sendmail/GNUmakefile +@@ -40,7 +40,7 @@ include $(BUILDRULES) install install_pcp: default $(INSTALL) -m 755 -d $(PMDADIR) @@ -283,11 +283,11 @@ Index: pcp-3.10.4/src/pmdas/sendmail/GNUmakefile $(INSTALL) -m 755 $(CMDTARGET) $(PMDADIR)/pmda$(IAM)$(EXECSUFFIX) $(INSTALL) -m 755 $(SCRIPTS) $(PMDADIR) $(INSTALL) -m 644 $(DFILES) pmns help root domain.h $(PMDADIR) -Index: pcp-3.10.4/src/pmdas/solaris/GNUmakefile +Index: pcp-3.11.8/src/pmdas/solaris/GNUmakefile =================================================================== ---- pcp-3.10.4.orig/src/pmdas/solaris/GNUmakefile -+++ pcp-3.10.4/src/pmdas/solaris/GNUmakefile -@@ -53,7 +53,8 @@ build-me: root_solaris domain.h $(LIBTAR +--- pcp-3.11.8.orig/src/pmdas/solaris/GNUmakefile ++++ pcp-3.11.8/src/pmdas/solaris/GNUmakefile +@@ -53,7 +53,8 @@ build-me: root_solaris $(LIBTARGET) $(CM install: build-me $(INSTALL) -m 755 -d $(PMDADIR) $(INSTALL) -m 644 domain.h $(HELPTARGETS) $(PMDADIR) @@ -297,3 +297,80 @@ Index: pcp-3.10.4/src/pmdas/solaris/GNUmakefile $(INSTALL) -m 644 root_solaris $(PCP_VAR_DIR)/pmns/root_solaris else build-me: +Index: pcp-3.11.8/src/libpcp_fault/src/GNUmakefile +=================================================================== +--- pcp-3.11.8.orig/src/libpcp_fault/src/GNUmakefile ++++ pcp-3.11.8/src/libpcp_fault/src/GNUmakefile +@@ -132,7 +132,7 @@ endif + + install : default + ifneq ($(LIBTARGET),) +- $(INSTALL) -m 755 $(LIBTARGET) $(PCP_LIB_DIR)/$(LIBTARGET) ++ $(INSTALL) -m 644 $(LIBTARGET) $(PCP_LIB_DIR)/$(LIBTARGET) + endif + ifneq ($(SYMTARGET),) + for tt in $(SYMTARGET); do \ +@@ -140,7 +140,7 @@ ifneq ($(SYMTARGET),) + done + endif + ifneq ($(STATICLIBTARGET),) +- $(INSTALL) -m 755 $(STATICLIBTARGET) $(PCP_LIB_DIR)/$(STATICLIBTARGET) ++ $(INSTALL) -m 644 $(STATICLIBTARGET) $(PCP_LIB_DIR)/$(STATICLIBTARGET) + endif + $(INSTALL) -m 644 $(TOPDIR)/src/include/pcp/fault.h $(PCP_INC_DIR)/fault.h + +Index: pcp-3.11.8/src/pmdas/jbd2/GNUmakefile +=================================================================== +--- pcp-3.11.8.orig/src/pmdas/jbd2/GNUmakefile ++++ pcp-3.11.8/src/pmdas/jbd2/GNUmakefile +@@ -54,7 +54,8 @@ build-me: $(LIBTARGET) $(CMDTARGET) $(HE + install: default + $(INSTALL) -m 755 -d $(PMDADIR) + $(INSTALL) -m 644 domain.h help $(HELPTARGETS) root root_jbd2 $(PMDADIR) +- $(INSTALL) -m 755 $(LIBTARGET) $(CMDTARGET) $(SCRIPTS) $(PMDADIR) ++ $(INSTALL) -m 755 $(CMDTARGET) $(SCRIPTS) $(PMDADIR) ++ $(INSTALL) -m 644 $(LIBTARGET) $(PMDADIR)/$(LIBTARGET) + $(INSTALL) -m 644 root_jbd2 $(PCP_VAR_DIR)/pmns/root_jbd2 + $(INSTALL) -m 644 jbd2_kernel_ulong.conf $(LOGREWRITEDIR)/jbd2_kernel_ulong.conf + @$(INSTALL_MAN) +Index: pcp-3.11.8/src/pmdas/linux_xfs/GNUmakefile +=================================================================== +--- pcp-3.11.8.orig/src/pmdas/linux_xfs/GNUmakefile ++++ pcp-3.11.8/src/pmdas/linux_xfs/GNUmakefile +@@ -55,7 +55,8 @@ build-me: $(LIBTARGET) $(CMDTARGET) $(HE + install: default + $(INSTALL) -m 755 -d $(PMDADIR) + $(INSTALL) -m 644 domain.h help help.dir help.pag root root_xfs $(PMDADIR) +- $(INSTALL) -m 755 $(LIBTARGET) $(CMDTARGET) $(SCRIPTS) $(PMDADIR) ++ $(INSTALL) -m 755 $(CMDTARGET) $(SCRIPTS) $(PMDADIR) ++ $(INSTALL) -m 644 $(LIBTARGET) $(PMDADIR)/$(LIBTARGET) + $(INSTALL) -m 644 root_xfs $(PCP_VAR_DIR)/pmns/root_xfs + $(INSTALL) -m 644 linux_xfs_migrate.conf $(PCP_VAR_DIR)/config/pmlogrewrite/linux_xfs_migrate.conf + @$(INSTALL_MAN) +Index: pcp-3.11.8/src/pmdas/nvidia/GNUmakefile +=================================================================== +--- pcp-3.11.8.orig/src/pmdas/nvidia/GNUmakefile ++++ pcp-3.11.8/src/pmdas/nvidia/GNUmakefile +@@ -37,7 +37,8 @@ include $(BUILDRULES) + install: default + $(INSTALL) -m 755 -d $(PMDADIR) + $(INSTALL) -m 755 Install Remove $(PMDADIR) +- $(INSTALL) -m 755 $(LIBTARGET) $(CMDTARGET) $(PMDADIR) ++ $(INSTALL) -m 755 $(CMDTARGET) $(PMDADIR)/$(CMDTARGET) ++ $(INSTALL) -m 644 $(LIBTARGET) $(PMDADIR)/$(LIBTARGET) + $(INSTALL) -m 644 $(DFILES) root help pmns domain.h $(PMDADIR) + + $(OBJECTS): domain.h +Index: pcp-3.11.8/src/zabbix-agent/src/GNUmakefile +=================================================================== +--- pcp-3.11.8.orig/src/zabbix-agent/src/GNUmakefile ++++ pcp-3.11.8/src/zabbix-agent/src/GNUmakefile +@@ -37,7 +37,7 @@ include $(BUILDRULES) + install: default + $(INSTALL) -m 755 -d $(ZABBIX_DIR) + $(INSTALL) -m 755 -d $(MODULE_DIR) +- $(INSTALL) -m 755 $(LIBTARGET) $(MODULE_DIR)/$(LIBTARGET) ++ $(INSTALL) -m 644 $(LIBTARGET) $(MODULE_DIR)/$(LIBTARGET) + @$(INSTALL_MAN) + + default_pcp: default diff --git a/0003-pcp-legacy-init-lsb.patch b/0003-pcp-legacy-init-lsb.patch index 1d467e8..96c2811 100644 --- a/0003-pcp-legacy-init-lsb.patch +++ b/0003-pcp-legacy-init-lsb.patch @@ -7,10 +7,10 @@ Subject: [PATCH 3/6] pcp legacy init lsb src/pmcd/rc_pcp | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) -diff --git a/src/pmcd/rc_pcp b/src/pmcd/rc_pcp -index 974ca06c2f4a..8d6872cfad9c 100644 ---- a/src/pmcd/rc_pcp -+++ b/src/pmcd/rc_pcp +Index: pcp-3.11.8/src/pmcd/rc_pcp +=================================================================== +--- pcp-3.11.8.orig/src/pmcd/rc_pcp ++++ pcp-3.11.8/src/pmcd/rc_pcp @@ -31,12 +31,12 @@ # e.g. SuSE, where chkconfig is a perl script. ### BEGIN INIT INFO @@ -30,8 +30,8 @@ index 974ca06c2f4a..8d6872cfad9c 100644 # Short-Description: Legacy control for PCP daemons # Description: Legacy init script wrapper for the Performance Co-Pilot (PCP) daemons ### END INIT INFO -@@ -53,6 +53,8 @@ _usage() - echo "Usage: $pmprog [-v] {start|restart|condrestart|stop|status|reload|force-reload}" +@@ -79,6 +79,8 @@ _service() + fi } +echo "The pcp init script is depricated, pmcd and pmlogger should be used instead" @@ -39,6 +39,3 @@ index 974ca06c2f4a..8d6872cfad9c 100644 case "$1" in 'start'|'restart'|'condrestart'|'reload'|'force-reload') --- -2.1.2 - diff --git a/0006-create-pmlogger-and-pmie-logdirs-during-install.patch b/0006-create-pmlogger-and-pmie-logdirs-during-install.patch index 1519d55..5b2119f 100644 --- a/0006-create-pmlogger-and-pmie-logdirs-during-install.patch +++ b/0006-create-pmlogger-and-pmie-logdirs-during-install.patch @@ -8,32 +8,29 @@ Subject: [PATCH 6/6] create pmlogger and pmie logdirs during install src/pmlogger/GNUmakefile | 2 ++ 2 files changed, 4 insertions(+) -diff --git a/src/pmie/GNUmakefile b/src/pmie/GNUmakefile -index 4c8e971d519b..9c6d09445dbd 100644 ---- a/src/pmie/GNUmakefile -+++ b/src/pmie/GNUmakefile -@@ -55,6 +55,8 @@ endif - $(INSTALL) -m 775 -o $(PCP_USER) -g $(PCP_GROUP) -d $(PCP_TMP_DIR)/pmie - ifeq ($(TARGET_OS),linux) +Index: pcp-3.10.9/src/pmie/GNUmakefile +=================================================================== +--- pcp-3.10.9.orig/src/pmie/GNUmakefile ++++ pcp-3.10.9/src/pmie/GNUmakefile +@@ -58,6 +58,8 @@ ifeq ($(TARGET_OS),linux) + # Docker version of the crontab into the hosts /etc/cron.d directory. + $(INSTALL) -m 644 crontab.docker $(PCP_VAR_DIR)/config/pmie/crontab.docker $(INSTALL) -m 755 -d `dirname $(CRONTAB_PATH)` + $(INSTALL) -m 755 -d $(PCP_LOG_DIR)/pmie + $(INSTALL) -m 1777 -d $(PCP_TMP_DIR)/pmie endif $(INSTALL) -m 644 crontab $(CRONTAB_PATH) -diff --git a/src/pmlogger/GNUmakefile b/src/pmlogger/GNUmakefile -index ae728faff2af..483087dbd39f 100644 ---- a/src/pmlogger/GNUmakefile -+++ b/src/pmlogger/GNUmakefile -@@ -56,6 +56,8 @@ endif - $(INSTALL) -m 775 -o $(PCP_USER) -g $(PCP_GROUP) -d $(PCP_TMP_DIR)/pmlogger - ifeq ($(TARGET_OS),linux) +Index: pcp-3.10.9/src/pmlogger/GNUmakefile +=================================================================== +--- pcp-3.10.9.orig/src/pmlogger/GNUmakefile ++++ pcp-3.10.9/src/pmlogger/GNUmakefile +@@ -62,6 +62,8 @@ ifeq ($(TARGET_OS),linux) + # Docker version of the crontab into the hosts cron.d directory. + $(INSTALL) -m 644 crontab.docker $(PCP_VAR_DIR)/config/pmlogger/crontab.docker $(INSTALL) -m 755 -d `dirname $(CRONTAB_PATH)` + $(INSTALL) -m 755 -d $(PCP_LOG_DIR)/pmlogger + $(INSTALL) -m 1777 -d $(PCP_TMP_DIR)/pmlogger endif $(INSTALL) -m 644 crontab $(CRONTAB_PATH) - --- -2.1.2 - + $(INSTALL) -m 644 utilproc.sh $(PCP_SHARE_DIR)/lib/utilproc.sh diff --git a/0007-Honor-CFLAGS-in-qmake.patch b/0007-Honor-CFLAGS-in-qmake.patch index d21f686..68f924e 100644 --- a/0007-Honor-CFLAGS-in-qmake.patch +++ b/0007-Honor-CFLAGS-in-qmake.patch @@ -15,22 +15,22 @@ http://stackoverflow.com/questions/17578150/add-cflags-to-qmake-project-without- src/pmtime/pmtime.pro | 1 + 6 files changed, 6 insertions(+) -diff --git a/src/libpcp_qed/src/libpcp_qed.pro b/src/libpcp_qed/src/libpcp_qed.pro -index 6a3c872a4b87..c67f1d63290d 100644 ---- a/src/libpcp_qed/src/libpcp_qed.pro -+++ b/src/libpcp_qed/src/libpcp_qed.pro -@@ -6,6 +6,7 @@ INCLUDEPATH += ../../include ../../libpcp_qmc/src +Index: pcp-3.11.8/src/libpcp_qed/src/libpcp_qed.pro +=================================================================== +--- pcp-3.11.8.orig/src/libpcp_qed/src/libpcp_qed.pro ++++ pcp-3.11.8/src/libpcp_qed/src/libpcp_qed.pro +@@ -6,6 +6,7 @@ INCLUDEPATH += ../../include ../../libpc release:DESTDIR = build/debug debug:DESTDIR = build/release - QT = core gui network svg + QT = core gui network printsupport svg widgets +QMAKE_CXXFLAGS += $$(PCP_CFLAGS) HEADERS = qed.h \ qed_actionlist.h \ -diff --git a/src/libpcp_qmc/src/libpcp_qmc.pro b/src/libpcp_qmc/src/libpcp_qmc.pro -index 39671ab2dceb..b59ffa4e6bb9 100644 ---- a/src/libpcp_qmc/src/libpcp_qmc.pro -+++ b/src/libpcp_qmc/src/libpcp_qmc.pro +Index: pcp-3.11.8/src/libpcp_qmc/src/libpcp_qmc.pro +=================================================================== +--- pcp-3.11.8.orig/src/libpcp_qmc/src/libpcp_qmc.pro ++++ pcp-3.11.8/src/libpcp_qmc/src/libpcp_qmc.pro @@ -5,6 +5,7 @@ CONFIG += qt staticlib warn_on INCLUDEPATH += ../../include release:DESTDIR = build/debug @@ -39,45 +39,42 @@ index 39671ab2dceb..b59ffa4e6bb9 100644 HEADERS = qmc_context.h qmc_desc.h qmc_group.h \ qmc_indom.h qmc_metric.h qmc_source.h \ -diff --git a/src/libpcp_qwt/src/libpcp_qwt.pro b/src/libpcp_qwt/src/libpcp_qwt.pro -index 1a7b1d8b736c..6badfc328605 100644 ---- a/src/libpcp_qwt/src/libpcp_qwt.pro -+++ b/src/libpcp_qwt/src/libpcp_qwt.pro -@@ -5,6 +5,7 @@ CONFIG += qt staticlib warn_on - release:DESTDIR = build/debug - debug:DESTDIR = build/release - QT = core gui network svg +Index: pcp-3.11.8/src/libpcp_qwt/src/libpcp_qwt.pro +=================================================================== +--- pcp-3.11.8.orig/src/libpcp_qwt/src/libpcp_qwt.pro ++++ pcp-3.11.8/src/libpcp_qwt/src/libpcp_qwt.pro +@@ -8,6 +8,7 @@ QT = core gui network svg + greaterThan(QT_MAJOR_VERSION, 4) { + QT += concurrent printsupport + } +QMAKE_CXXFLAGS += $$(PCP_CFLAGS) HEADERS += \ qwt.h \ -diff --git a/src/pmdumptext/pmdumptext.pro b/src/pmdumptext/pmdumptext.pro -index d521e2f40cb7..f9048bb1a037 100644 ---- a/src/pmdumptext/pmdumptext.pro -+++ b/src/pmdumptext/pmdumptext.pro -@@ -9,3 +9,4 @@ LIBS += -L../libpcp/src - LIBS += -L../libpcp_qmc/src -L../libpcp_qmc/src/$$DESTDIR +Index: pcp-3.11.8/src/pmdumptext/pmdumptext.pro +=================================================================== +--- pcp-3.11.8.orig/src/pmdumptext/pmdumptext.pro ++++ pcp-3.11.8/src/pmdumptext/pmdumptext.pro +@@ -10,3 +10,4 @@ LIBS += -L../libpcp_qmc/src -L../libpcp LIBS += -lpcp_qmc -lpcp + win32:LIBS += -lwsock32 -liphlpapi QT -= gui +QMAKE_CXXFLAGS += $$(PCP_CFLAGS) -diff --git a/src/pmquery/pmquery.pro b/src/pmquery/pmquery.pro -index 6a4293fb7a23..d9392931888c 100644 ---- a/src/pmquery/pmquery.pro -+++ b/src/pmquery/pmquery.pro -@@ -7,3 +7,4 @@ RESOURCES = pmquery.qrc - CONFIG += qt warn_on +Index: pcp-3.11.8/src/pmquery/pmquery.pro +=================================================================== +--- pcp-3.11.8.orig/src/pmquery/pmquery.pro ++++ pcp-3.11.8/src/pmquery/pmquery.pro +@@ -8,3 +8,4 @@ CONFIG += qt warn_on + QT += widgets release:DESTDIR = build/debug debug:DESTDIR = build/release +QMAKE_CXXFLAGS += $$(PCP_CFLAGS) -diff --git a/src/pmtime/pmtime.pro b/src/pmtime/pmtime.pro -index ad3e1932e7b1..4605765cab79 100644 ---- a/src/pmtime/pmtime.pro -+++ b/src/pmtime/pmtime.pro +Index: pcp-3.11.8/src/pmtime/pmtime.pro +=================================================================== +--- pcp-3.11.8.orig/src/pmtime/pmtime.pro ++++ pcp-3.11.8/src/pmtime/pmtime.pro @@ -22,3 +22,4 @@ LIBS += -lpcp_qwt -lpcp_qmc -lpcp - win32:LIBS += -lwsock32 - QT += network + win32:LIBS += -lwsock32 -liphlpapi + QT += network widgets QMAKE_INFO_PLIST = pmtime.info +QMAKE_CXXFLAGS += $$(PCP_CFLAGS) --- -2.1.2 - diff --git a/_service b/_service new file mode 100644 index 0000000..381aba7 --- /dev/null +++ b/_service @@ -0,0 +1,17 @@ + + + git + https://github.com/performancecopilot/pcp.git + pcp + 3d9cb4fad25d7d0406a571157645a028d5d3a5c2 + @PARENT_TAG@ + disable + + + *.tar + bz2 + + + pcp + + diff --git a/_service:recompress:tar_scm:pcp-3.11.8.tar.bz2 b/_service:recompress:tar_scm:pcp-3.11.8.tar.bz2 new file mode 100644 index 0000000..bcc5872 --- /dev/null +++ b/_service:recompress:tar_scm:pcp-3.11.8.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:597bad2126c5d0f8fd9ee75349ae443ac5e834a072e4f847906171ea4643e72d +size 14639274 diff --git a/_service:set_version:pcp.spec b/_service:set_version:pcp.spec new file mode 100644 index 0000000..7d95e37 --- /dev/null +++ b/_service:set_version:pcp.spec @@ -0,0 +1,2989 @@ +# +# spec file for package pcp +# +# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# + + +BuildRequires: -post-build-checks + +%if 0%{?suse_version} > 1140 || 0%{?fedora_version} > 14 +%global has_systemd 1 +%else +%global has_systemd 0 +%endif + +%if 0%{?suse_version} +%global pcp_gr System/Monitoring +%global lib_pkg libpcp3 +%global lib_pkg_conflict pcp-libs +%global lib_gr System/Libraries +%global lib_devel_pkg libpcp-devel +%global lib_devel_pkg_conflict pcp-libs-devel +%global lib_devel_gr Development/Libraries/Other +%global license_apache2 Apache-2.0 +%global license_cc_by CC-BY-SA-3.0 +%global license_gplv2 GPL-2.0 +%global license_gplv2plus GPL-2.0+ +%global license_lgplv2 LGPL-2.0 +%global license_lgplv2plus LGPL-2.0+ +%global license_lgplv21plus LGPL-2.1+ +%global license_mit MIT +%global _libexecdir %{_libdir} +%else +%global pcp_gr Applications/System +%global lib_pkg pcp-libs +%global lib_pkg_conflict libpcp3 +%global lib_gr System Environment/Libraries +%global lib_devel_pkg pcp-libs-devel +%global lib_devel_pkg_conflict libpcp-devel +%global lib_devel_gr Development/Libraries +%global license_apache2 ASL2.0 +%global license_cc_by CC-BY +%global license_gplv2 GPLv2 +%global license_gplv2plus GPLv2+ +%global license_lgplv2 LGPLv2 +%global license_lgplv2plus LGPLv2+ +%global license_lgplv21plus LGPLv2.1+ +%global license_mit MIT +%endif + +Summary: System-level performance monitoring and performance management +License: %{license_gplv2plus} and %{license_lgplv2plus} and %{license_cc_by} +Group: %{pcp_gr} +Name: pcp +Version: 3.11.8 +Release: 0 +%global buildversion 1 + +Url: http://www.pcp.io +Source0: pcp-%{version}.tar.bz2 +%if 0%{?suse_version} +Source2: pcp-rpmlintrc +%endif + +# PATCH-FIX-OPENSUSE, kkaempf@suse.de +Patch2: 0002-Install-libraries-without-exec-permission.patch +# PATCH-FIX-OPENSUSE, kkaempf@suse.de +Patch3: 0003-pcp-legacy-init-lsb.patch +# PATCH-FIX-OPENSUSE, kkaempf@suse.de +Patch5: 0005-Remove-runlevel-4-from-init-scripts.patch +# PATCH-FIX-OPENSUSE, kkaempf@suse.de +Patch6: 0006-create-pmlogger-and-pmie-logdirs-during-install.patch +# PATCH-FIX-OPENSUSE, kkaempf@suse.de +Patch7: 0007-Honor-CFLAGS-in-qmake.patch +# PATCH-FIX-OPENSUSE, kkaempf@suse.de +Patch8: 0008-SUSE-fy-pmsnap-control-path.patch +# PATCH-FIX-OPENSUSE, kkaempf@suse.de +Patch9: 0009-pmsnap-control-var-www-srv-www.patch + +%if 0%{?fedora} || 0%{?rhel} +%global disable_selinux 0 +%else +%global disable_selinux 1 +%endif + +%global disable_snmp 0 + +# There are no papi/libpfm devel packages for s390 nor for some rhels, disable +%ifarch s390 s390x +%global disable_papi 1 +%global disable_perfevent 1 +%else +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 || 0%{?suse_version} +%global disable_papi 0 +%else +%global disable_papi 1 +%endif +%if 0%{?fedora} >= 20 || 0%{?rhel} > 6 || 0%{?suse_version} +%global disable_perfevent 0 +%else +%global disable_perfevent 1 +%endif +%endif + +%global disable_sheet2pcp 1 +%global disable_microhttpd 0 +%global disable_cairo 0 + +%global disable_python2 0 +# Default for epel5 is python24, so use the (optional) python26 packages +%if 0%{?rhel} == 5 +%global default_python 26 +%endif +# No python3 development environment before el8 +%if 0%{?rhel} == 0 || 0%{?rhel} > 7 +%global disable_python3 0 +# Do we wish to mandate python3 use in pcp? (f22+ and el8+) +%if 0%{?fedora} >= 22 || 0%{?rhel} > 7 +%global default_python 3 +%endif +%else +%global disable_python3 1 +%endif + +# some Python3 deps missing for SLE <= 12SP2 +%if 0%{?sle_version} && 0%{?sle_version} <= 120200 +%global disable_python3 1 +%endif + +# support for pmdajson +%if 0%{?rhel} == 0 || 0%{?rhel} > 6 +%if !%{disable_python2} || !%{disable_python3} +%global disable_json 0 +%else +%global disable_json 1 +%endif +%else +%global disable_json 1 +%endif + +# support for pmdarpm +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 +%global disable_rpm 0 +%else +%global disable_rpm 1 +%endif + +# Qt development and runtime environment missing components before el6 +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 +%global disable_qt 0 +%else +%global disable_qt 1 +%endif + +# systemd services and pmdasystemd +%if 0%{?fedora} >= 19 || 0%{?rhel} >= 7 || 0%{?suse_version} +%global disable_systemd 0 +%else +%global disable_systemd 1 +%endif + +# systemtap static probing, missing before el6 and on some architectures +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 +%global disable_sdt 0 +%else +%ifnarch ppc ppc64 +%global disable_sdt 0 +%else +%global disable_sdt 1 +%endif +%endif + +%if 0%{?suse_version} && !%{disable_python3} +# SUSE doesn't currently ship the libvirt-python3 dependency +%global disable_libvirt 1 +%else +%global disable_libvirt 0 +%endif + +%if 0%{?sle_version} && 0%{?sle_version} <= 120200 +# SUSE doesn't currently ship the perl-DBD-Pg dependency +%global disable_postgresql 1 +%else +%global disable_postgresql 0 +%endif + +# rpm producing "noarch" packages +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 || 0%{?suse_version} >= 1315 +%global disable_noarch 0 +%else +%global disable_noarch 1 +%endif + +%if 0%{?suse_version} +BuildRoot: %{_tmppath}/%{name}-%{version}-build +%else +BuildRoot: %{_tmppath}/%{name}-%{version}-build +%endif +BuildRequires: autoconf +BuildRequires: avahi-devel +BuildRequires: bison +BuildRequires: zlib-devel +%if 0%{?suse_version} > 1010 +BuildRequires: fdupes +%endif +BuildRequires: flex +BuildRequires: gcc-c++ +%if 0%{?suse_version} +BuildRequires: mozilla-nss-devel +%else +BuildRequires: nss-devel +%endif +BuildRequires: perl +BuildRequires: procps +BuildRequires: python-devel +BuildRequires: rpm-devel +%if !%{disable_python3} +BuildRequires: python3-devel +%endif +BuildRequires: cyrus-sasl-devel +BuildRequires: ncurses-devel +BuildRequires: readline-devel +%if !%{disable_papi} +BuildRequires: papi-devel +%endif +%if !%{disable_perfevent} +BuildRequires: libpfm-devel >= 4.4 +%endif +%if !%{disable_microhttpd} +BuildRequires: libmicrohttpd-devel +%endif +%if !%{disable_cairo} +BuildRequires: cairo-devel +%endif +%if !%{disable_sdt} +BuildRequires: systemtap-sdt-devel +%endif +BuildRequires: perl-ExtUtils-MakeMaker +%if 0%{?suse_version} +BuildRequires: update-desktop-files +%else +BuildRequires: initscripts +%endif +BuildRequires: man +%if !%{disable_systemd} +BuildRequires: systemd-devel +%{?systemd_requires} +%endif +%if !%{disable_qt} +BuildRequires: desktop-file-utils +%if 0%{?suse_version} +BuildRequires: libqt4-devel >= 4.4 +%else +BuildRequires: qt4-devel >= 4.4 +%endif +%endif +%if !%{disable_selinux} +Requires: pcp-selinux = %{version}-%{release} +%endif + +# for set_permissions +%if 0%{?suse_version} >= 1131 +PreReq: permissions +%endif +Requires: bash +Requires: cron +Requires: fileutils +Requires: findutils +Requires: gawk +Requires: grep +Requires: perl +Requires: sed +Requires: which +%if 0%{?suse_version} +Requires: cpp +Requires: cyrus-sasl +Requires: sysconfig +# pmatop needs curses.py +Requires: python-curses +%else +Requires: initscripts +%endif + +Requires: %{lib_pkg} = %{version}-%{release} +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: python +Requires: python-pcp = %{version}-%{release} +Obsoletes: pcp-pmda-nvidia < %{version} + +%global tapsetdir %{_datadir}/systemtap/tapset + +%global _confdir %{_sysconfdir}/pcp +%global _logsdir %{_localstatedir}/log/pcp +%global _pmnsdir %{_localstatedir}/lib/pcp/pmns +%global _tempsdir %{_localstatedir}/lib/pcp/tmp +%global _pmdasdir %{_localstatedir}/lib/pcp/pmdas +%global _testsdir %{_localstatedir}/lib/pcp/testsuite +%global _selinuxdir %{_localstatedir}/lib/pcp/selinux +%if 0%{?suse_version} +%global _pixmapdir %{_datadir}/pixmaps +%global _booksdir %{_docdir}/pcp-doc +%else +%global _pixmapdir %{_datadir}/pcp-gui/pixmaps +%global _booksdir %{_datadir}/doc/pcp-doc +%endif + +%if 0%{?fedora} >= 20 || 0%{?rhel} >= 8 || 0%{?suse_version} +# FIXME: PCP defaults to using %{_datadir}/doc/pcp-doc +%global _with_doc --with-docdir=%{_docdir}/%{name} +%endif +%if !%{disable_systemd} +%global _initddir %{_datadir}/pcp/lib +%else +%if 0%{?suse_version} +%global _initddir %{_sysconfdir}/init.d +%else +%global _initddir %{_sysconfdir}/rc.d/init.d +%endif +%global _with_initd --with-rcdir=%{_initddir} +%endif + +# we never want Infiniband on s390 platforms +%ifarch s390 s390x +%global disable_infiniband 1 +%else + +# we never want Infiniband on RHEL5 or earlier +%if 0%{?rhel} != 0 && 0%{?rhel} < 6 +%global disable_infiniband 1 +%else +%global disable_infiniband 0 +%endif + +%endif + +%if %{disable_infiniband} +%global _with_ib --with-infiniband=no +%endif + +%if !%{disable_papi} +%global _with_papi --with-papi=yes +%endif + +%if !%{disable_perfevent} +%global _with_perfevent --with-perfevent=yes +%endif + +%if %{disable_json} +%global _with_json --with-pmdajson=no +%else +%global _with_json --with-pmdajson=yes +%endif + +%if %{disable_snmp} +%global _with_snmp --with-pmdasnmp=no +%else +%global _with_snmp --with-pmdasnmp=yes +%endif + +%description +Performance Co-Pilot (PCP) provides a framework and services to support +system-level performance monitoring and performance management. + +The PCP open source release provides a unifying abstraction for all of +the interesting performance data in a system, and allows client +applications to easily retrieve and process any subset of that data. + +# +# pcp-conf +# +%package conf +Summary: Performance Co-Pilot run-time configuration +License: %{license_lgplv21plus} +Group: %{lib_gr} +Url: http://www.pcp.io +# http://fedoraproject.org/wiki/Packaging:Conflicts "Splitting Packages" +Conflicts: pcp-libs < 3.9 + +%description conf +Performance Co-Pilot (PCP) run-time configuration + +# +# pcp-libs +# + +%package -n %{lib_pkg} +Summary: Performance Co-Pilot run-time libraries +License: %{license_lgplv21plus} +Group: %{lib_gr} +Url: http://www.pcp.io +Conflicts: %{lib_pkg_conflict} +Requires: pcp-conf >= %{version}-%{release} + +%description -n %{lib_pkg} +Performance Co-Pilot (PCP) run-time libraries + +# +# pcp-libs-devel +# SLE uses the legacy libpcp-devel package name. +# +%package -n %{lib_devel_pkg} +Summary: Performance Co-Pilot (PCP) development headers +License: %{license_gplv2plus} and %{license_lgplv21plus} +Group: %{lib_devel_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Conflicts: %{lib_devel_pkg_conflict} +%if (0%{?suse_version} > 0) +Provides: pcp-devel = %{version} +Obsoletes: pcp-devel < %{version} +%endif + +%description -n %{lib_devel_pkg} +Performance Co-Pilot (PCP) headers for development. + +# +# pcp-devel +# +%package devel +Summary: Performance Co-Pilot (PCP) development tools and documentation +License: %{license_gplv2plus} and %{license_lgplv21plus} +Group: %{lib_devel_gr} +Url: http://www.pcp.io +Requires: %{lib_devel_pkg} = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description devel +Performance Co-Pilot (PCP) documentation and tools for development. + +# +# pcp-testsuite +# +%package testsuite +Summary: Performance Co-Pilot (PCP) test suite +License: %{license_gplv2plus} and %{license_mit} +Group: %{lib_devel_gr} +Url: http://www.pcp.io +Requires: %{lib_devel_pkg} = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} +Requires: pcp-devel = %{version}-%{release} +Obsoletes: pcp-gui-testsuite + +%description testsuite +Quality assurance test suite for Performance Co-Pilot (PCP). + +# +# pcp-manager +# +%package manager +Summary: Performance Co-Pilot (PCP) manager daemon +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description manager +An optional daemon (pmmgr) that manages a collection of pmlogger and +pmie daemons, for a set of discovered local and remote hosts running +the performance metrics collection daemon (pmcd). It ensures these +daemons are running when appropriate, and manages their log rotation +needs. It is an alternative to the cron-based pmlogger/pmie service +scripts. + +%if !%{disable_microhttpd} +# +# pcp-webapi +# +%package webapi +Summary: Performance Co-Pilot (PCP) web API service +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description webapi +Provides a daemon (pmwebd) that binds a large subset of the Performance +Co-Pilot (PCP) client API (PMAPI) to RESTful web applications using the +HTTP (PMWEBAPI) protocol. +%endif + +# +# perl-PCP-PMDA. This is the PCP agent perl binding. +# +%package -n perl-PCP-PMDA +Summary: Performance Co-Pilot (PCP) Perl bindings and documentation +License: %{license_gplv2plus} +Group: %{lib_devel_gr} +Url: http://www.pcp.io +%if 0%{?suse_version} +%perl_requires +%endif +Requires: %{lib_pkg} = %{version}-%{release} + +%description -n perl-PCP-PMDA +The PCP::PMDA Perl module contains the language bindings for +building Performance Metric Domain Agents (PMDAs) using Perl. +Each PMDA exports performance data for one specific domain, for +example the operating system kernel, Cisco routers, a database, +an application, etc. + +# +# perl-PCP-MMV +# +%package -n perl-PCP-MMV +Summary: Performance Co-Pilot (PCP) Perl bindings for PCP Memory Mapped Values +License: %{license_gplv2plus} +Group: %{lib_devel_gr} +Url: http://www.pcp.io +%if 0%{?suse_version} +%perl_requires +%endif +Requires: %{lib_pkg} = %{version}-%{release} + +%description -n perl-PCP-MMV +The PCP::MMV module contains the Perl language bindings for +building scripts instrumented with the Performance Co-Pilot +(PCP) Memory Mapped Value (MMV) mechanism. +This mechanism allows arbitrary values to be exported from an +instrumented script into the PCP infrastructure for monitoring +and analysis with pmchart, pmie, pmlogger and other PCP tools. + +# +# perl-PCP-LogImport +# +%package -n perl-PCP-LogImport +Summary: Performance Co-Pilot Perl bindings for importing external archive data +License: %{license_gplv2plus} +Group: %{lib_devel_gr} +Url: http://www.pcp.io +%if 0%{?suse_version} +%perl_requires +%endif +Requires: %{lib_pkg} = %{version}-%{release} + +%description -n perl-PCP-LogImport +The PCP::LogImport module contains the Perl language bindings for +importing data in various 3rd party formats into PCP archives so +they can be replayed with standard PCP monitoring tools. + + # +# perl-PCP-LogSummary +# +%package -n perl-PCP-LogSummary +Summary: Performance Co-Pilot Perl bindings for processing pmlogsummary output +License: %{license_gplv2plus} +Group: %{lib_devel_gr} +Url: http://www.pcp.io +%if 0%{?suse_version} +%perl_requires +%endif +Requires: %{lib_pkg} = %{version}-%{release} + +%description -n perl-PCP-LogSummary +The PCP::LogSummary module provides a Perl module for using the +statistical summary data produced by the Performance Co-Pilot +pmlogsummary utility. This utility produces various averages, +minima, maxima, and other calculations based on the performance +data stored in a PCP archive. The Perl interface is ideal for +exporting this data into third-party tools (e.g. spreadsheets). + +# +# pcp-import-sar2pcp +# +%package import-sar2pcp +Summary: Performance Co-Pilot archive tools for importing sar data +License: %{license_lgplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +%endif +Requires: perl-PCP-LogImport = %{version}-%{release} +Requires: sysstat + +%description import-sar2pcp +Performance Co-Pilot (PCP) front-end tools for importing sar data +into standard PCP archive logs for replay with any PCP monitoring tool. + +# +# pcp-import-iostat2pcp +# +%package import-iostat2pcp +Summary: Performance Co-Pilot archive tools for importing iostat data +License: %{license_lgplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +%endif +Requires: perl-PCP-LogImport = %{version}-%{release} +Requires: sysstat + +%description import-iostat2pcp +Performance Co-Pilot (PCP) front-end tools for importing iostat data +into standard PCP archive logs for replay with any PCP monitoring tool. + +%if !%{disable_sheet2pcp} +# +# pcp-import-sheet2pcp +# +%package import-sheet2pcp +Summary: Performance Co-Pilot archive tools for importing spreadsheet data +License: %{license_lgplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +%endif +Requires: perl-PCP-LogImport = %{version}-%{release} +Requires: sysstat + +%description import-sheet2pcp +Performance Co-Pilot (PCP) front-end tools for importing spreadsheet data +into standard PCP archive logs for replay with any PCP monitoring tool. + +%endif + +# +# pcp-import-mrtg2pcp +# +%package import-mrtg2pcp +Summary: Performance Co-Pilot archive tools for importing MTRG data +License: %{license_lgplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +%endif +Requires: perl-PCP-LogImport = %{version}-%{release} + +%description import-mrtg2pcp +Performance Co-Pilot (PCP) front-end tools for importing MTRG data +into standard PCP archive logs for replay with any PCP monitoring tool. + +# +# pcp-import-ganglia2pcp +# +%package import-ganglia2pcp +Summary: Performance Co-Pilot archive tools for importing ganglia data +License: %{license_lgplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +%endif +Requires: perl-PCP-LogImport = %{version}-%{release} + +%description import-ganglia2pcp +Performance Co-Pilot (PCP) front-end tools for importing ganglia data +into standard PCP archive logs for replay with any PCP monitoring tool. + +# +# pcp-import-collectl2pcp +# +%package import-collectl2pcp +Summary: Performance Co-Pilot archive tools for importing collectl data +License: %{license_lgplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description import-collectl2pcp +Performance Co-Pilot (PCP) front-end tools for importing collectl data +into standard PCP archive logs for replay with any PCP monitoring tool. + +# +# pcp-export-zabbix-agent +# +%package export-zabbix-agent +Summary: Module for exporting from PCP into a Zabbix agent daemon +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} >= %{version}-%{release} + +%description export-zabbix-agent +Performance Co-Pilot (PCP) module for exporting metrics from PCP to +Zabbix via the Zabbix agent - see zbxpcp(3) for further details. + +%if !%{disable_python2} || !%{disable_python3} +# +# pcp-export-pcp2graphite +# +%package export-pcp2graphite +Summary: Performance Co-Pilot tools for exporting PCP metrics to Graphite +License: %{license_lgplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +%endif +%if !%{disable_python3} +Requires: python3-pcp = %{version}-%{release} +%else +Requires: python-pcp = %{version}-%{release} +%endif + +%description export-pcp2graphite +Performance Co-Pilot (PCP) front-end tools for exporting metric values +to graphite (http://graphite.readthedocs.org). + +# pcp-export-pcp2influxdb +# +%package export-pcp2influxdb +Summary: Performance Co-Pilot tools for exporting PCP metrics to InfluxDB +License: %{license_lgplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} >= %{version}-%{release} +%if !%{disable_python3} +Requires: python3-pcp = %{version}-%{release} +Requires: python3-requests +%else +Requires: python-pcp = %{version}-%{release} +Requires: python-requests +%endif + +%description export-pcp2influxdb +Performance Co-Pilot (PCP) front-end tools for exporting metric values +to InfluxDB (https://influxdata.com/time-series-platform/influxdb). +%endif + +%if !%{disable_papi} +# +# pcp-pmda-papi +# +%package pmda-papi +Summary: Performance Co-Pilot (PCP) metrics for Performance API and hardware counters +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +%endif +BuildRequires: papi-devel + +%description pmda-papi +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting hardware counters statistics through PAPI (Performance API). +%endif + +%if !%{disable_perfevent} +# +# pcp-pmda-perfevent +# +%package pmda-perfevent +Summary: Performance Co-Pilot (PCP) metrics for hardware counters +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +Requires: libpfm >= 4.4 +%endif +BuildRequires: libpfm-devel >= 4.4 + +%description pmda-perfevent +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting hardware counters statistics through libpfm. +%endif + +%if !%{disable_infiniband} +# +# pcp-pmda-infiniband +# +%package pmda-infiniband +Summary: Performance Co-Pilot (PCP) metrics for Infiniband HCAs and switches +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +Requires: libibmad >= 1.3.7 +Requires: libibumad >= 1.3.7 +%endif +BuildRequires: libibmad-devel >= 1.3.7 +BuildRequires: libibumad-devel >= 1.3.7 + +%description pmda-infiniband +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting Infiniband statistics. By default, it monitors the local HCAs +but can also be configured to monitor remote GUIDs such as IB switches. +%endif + +# +# pcp-pmda-activemq +# +%package pmda-activemq +Summary: Performance Co-Pilot (PCP) metrics for ActiveMQ +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(LWP::UserAgent) + +%description pmda-activemq +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the ActiveMQ message broker. +#end pcp-pmda-activemq + +# +# pcp-pmda-bind2 +# +%package pmda-bind2 +Summary: Performance Co-Pilot (PCP) metrics for BIND servers +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(File::Slurp) +Requires: perl(LWP::UserAgent) +Requires: perl(XML::LibXML) + +%description pmda-bind2 +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from BIND (Berkeley Internet Name Domain). +#end pcp-pmda-bind2 + +# +# pcp-pmda-redis +# +%package pmda-redis +Summary: Performance Co-Pilot (PCP) metrics for Redis +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-redis +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from Redis servers (redis.io). +#end pcp-pmda-redis + +# +# pcp-pmda-nutcracker +# +%package pmda-nutcracker +Summary: Performance Co-Pilot (PCP) metrics for NutCracker (TwemCache) +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(JSON) +Requires: perl(YAML::XS::LibYAML) + +%description pmda-nutcracker +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from NutCracker (TwemCache). +#end pcp-pmda-nutcracker + +# +# pcp-pmda-bonding +# +%package pmda-bonding +Summary: Performance Co-Pilot (PCP) metrics for Bonded network interfaces +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-bonding +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about bonded network interfaces. +#end pcp-pmda-bonding + +# +# pcp-pmda-dbping +# +%package pmda-dbping +Summary: Performance Co-Pilot (PCP) metrics for Database response times and Availablility +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-dbping +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Database response times and Availablility. +#end pcp-pmda-dbping + +# +# pcp-pmda-ds389 +# +%package pmda-ds389 +Summary: Performance Co-Pilot (PCP) metrics for 389 Directory Servers +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-LDAP +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-ds389 +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about a 389 Directory Server. +#end pcp-pmda-ds389 + +# +# pcp-pmda-ds389log +# +%package pmda-ds389log +Summary: Performance Co-Pilot (PCP) metrics for 389 Directory Server Loggers +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-Date-Manip +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-ds389log +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from a 389 Directory Server log. +#end pcp-pmda-ds389log + +# +# pcp-pmda-elasticsearch +# +%package pmda-elasticsearch +Summary: Performance Co-Pilot (PCP) metrics for Elasticsearch +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(LWP::UserAgent) +BuildRequires: perl(LWP::UserAgent) + +%description pmda-elasticsearch +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Elasticsearch. +#end pcp-pmda-elasticsearch + +# +# pcp-pmda-gpfs +# +%package pmda-gpfs +Summary: Performance Co-Pilot (PCP) metrics for GPFS Filesystem +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-gpfs +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the GPFS filesystem. +#end pcp-pmda-gpfs + +# +# pcp-pmda-gpsd +# +%package pmda-gpsd +Summary: Performance Co-Pilot (PCP) metrics for a GPS Daemon +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-gpsd +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about a GPS Daemon. +#end pcp-pmda-gpsd + +# +# pcp-pmda-kvm +# +%package pmda-kvm +Summary: Performance Co-Pilot (PCP) metrics for KVM +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-kvm +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Kernel based Virtual Machine. +#end pcp-pmda-kvm + +# +# pcp-pmda-docker +# +%package pmda-docker +Summary: Performance Co-Pilot (PCP) metrics from the Docker daemon +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io + +%description pmda-docker +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics using the Docker daemon REST API. +#end pcp-pmda-docker + +# +# pcp-pmda-lustre +# +%package pmda-lustre +Summary: Performance Co-Pilot (PCP) metrics for the Lustre Filesytem +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-lustre +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Lustre Filesystem. +#end pcp-pmda-lustre + +# +# pcp-pmda-lustrecomm +# +%package pmda-lustrecomm +Summary: Performance Co-Pilot (PCP) metrics for the Lustre Filesytem Comms +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-lustrecomm +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Lustre Filesystem Comms. +#end pcp-pmda-lustrecomm + +# +# pcp-pmda-memcache +# +%package pmda-memcache +Summary: Performance Co-Pilot (PCP) metrics for Memcached +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-memcache +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Memcached. +#end pcp-pmda-memcache + +# +# pcp-pmda-mysql +# +%package pmda-mysql +Summary: Performance Co-Pilot (PCP) metrics for MySQL +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(DBD::mysql) +Requires: perl(DBI) +BuildRequires: perl(DBD::mysql) +BuildRequires: perl(DBI) + +%description pmda-mysql +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the MySQL database. +#end pcp-pmda-mysql + +# +# pcp-pmda-named +# +%package pmda-named +Summary: Performance Co-Pilot (PCP) metrics for Named +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-named +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Named nameserver. +#end pcp-pmda-named + +# pcp-pmda-netfilter +# +%package pmda-netfilter +Summary: Performance Co-Pilot (PCP) metrics for Netfilter framework +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-netfilter +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Netfilter packet filtering framework. +#end pcp-pmda-netfilter + +# +# pcp-pmda-news +# +%package pmda-news +Summary: Performance Co-Pilot (PCP) metrics for Usenet News +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-news +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Usenet News. +#end pcp-pmda-news + +# +# pcp-pmda-nginx +# +%package pmda-nginx +Summary: Performance Co-Pilot (PCP) metrics for the Nginx Webserver +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(LWP::UserAgent) +BuildRequires: perl(LWP::UserAgent) + +%description pmda-nginx +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Nginx Webserver. +#end pcp-pmda-nginx + +# +# pcp-pmda-nfsclient +# +%package pmda-nfsclient +Summary: Performance Co-Pilot (PCP) metrics for NFS Clients +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-nfsclient +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics for NFS Clients. +#end pcp-pmda-nfsclient + +# +# pcp-pmda-oracle +# +%package pmda-oracle +Summary: Performance Co-Pilot (PCP) metrics for the Oracle database +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(DBI) +BuildRequires: perl(DBI) + +%description pmda-oracle +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Oracle database. +#end pcp-pmda-oracle + +# +# pcp-pmda-pdns +# +%package pmda-pdns +Summary: Performance Co-Pilot (PCP) metrics for PowerDNS +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-pdns +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the PowerDNS. +#end pcp-pmda-pdns + +# +# pcp-pmda-postfix +# +%package pmda-postfix +Summary: Performance Co-Pilot (PCP) metrics for the Postfix (MTA) +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +%if 0%{?fedora} > 16 || 0%{?rhel} > 5 +Requires: postfix-perl-scripts +BuildRequires: postfix-perl-scripts +%endif +%if 0%{?rhel} <= 5 +Requires: postfix +BuildRequires: postfix +%endif +%if "%{_vendor}" == "suse" +Requires: postfix-doc +BuildRequires: postfix-doc +%endif + +%description pmda-postfix +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Postfix (MTA). +#end pcp-pmda-postfix + +%if !%{disable_postgresql} +# +# pcp-pmda-postgresql +# +%package pmda-postgresql +Summary: Performance Co-Pilot (PCP) metrics for PostgreSQL +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(DBD::Pg) +Requires: perl(DBI) +BuildRequires: perl(DBD::Pg) +BuildRequires: perl(DBI) + +%description pmda-postgresql +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the PostgreSQL database. +#end pcp-pmda-postgresql +%endif + +# +# pcp-pmda-rsyslog +# +%package pmda-rsyslog +Summary: Performance Co-Pilot (PCP) metrics for Rsyslog +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-rsyslog +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Rsyslog. +#end pcp-pmda-rsyslog + +# +# pcp-pmda-samba +# +%package pmda-samba +Summary: Performance Co-Pilot (PCP) metrics for Samba +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-samba +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Samba. +#end pcp-pmda-samba + +# +# pcp-pmda-slurm +# +%package pmda-slurm +Summary: Performance Co-Pilot (PCP) metrics for NFS Clients +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-slurm +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from the SLURM Workload Manager. +#end pcp-pmda-slurm + +%if !%{disable_snmp} +# +# pcp-pmda-snmp +# +%package pmda-snmp +Summary: Performance Co-Pilot (PCP) metrics for Simple Network Management Protocol +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +# There are no perl-Net-SNMP packages in rhel, disable unless non-rhel or epel5 +%if 0%{?rhel} == 0 || 0%{?rhel} < 6 +Requires: perl(Net::SNMP) +%endif + +%description pmda-snmp +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about SNMP. +#end pcp-pmda-snmp +%endif + +# +# pcp-pmda-vmware +# +%package pmda-vmware +Summary: Performance Co-Pilot (PCP) metrics for VMware +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-vmware +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics for VMware. +#end pcp-pmda-vmware + +# +# pcp-pmda-zimbra +# +%package pmda-zimbra +Summary: Performance Co-Pilot (PCP) metrics for Zimbra +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-zimbra +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Zimbra. +#end pcp-pmda-zimbra + +# +# pcp-pmda-dm +# +%package pmda-dm +Summary: Performance Co-Pilot (PCP) metrics for the Device Mapper Cache and Thin Client +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-dm +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Device Mapper Cache and Thin Client. +# end pcp-pmda-dm + + +%if !%{disable_python2} || !%{disable_python3} +# +# pcp-pmda-gluster +# +%package pmda-gluster +Summary: Performance Co-Pilot (PCP) metrics for the Gluster filesystem +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +%else +Requires: python-pcp +%endif +%description pmda-gluster +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the gluster filesystem. +# end pcp-pmda-gluster + +# +# pcp-pmda-zswap +# +%package pmda-zswap +Summary: Performance Co-Pilot (PCP) metrics for compressed swap +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +%else +Requires: python-pcp +%endif +%description pmda-zswap +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about compressed swap. +# end pcp-pmda-zswap + +# +# pcp-pmda-unbound +# +%package pmda-unbound +Summary: Performance Co-Pilot (PCP) metrics for the Unbound DNS Resolver +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +%else +Requires: python-pcp +%endif +%description pmda-unbound +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Unbound DNS Resolver. +# end pcp-pmda-unbound + +# +# pcp-pmda-mic +# +%package pmda-mic +Summary: Performance Co-Pilot (PCP) metrics for Intel MIC cards +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +%else +Requires: python-pcp +%endif +%description pmda-mic +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Intel MIC cards. +# end pcp-pmda-mic + +%if !%{disable_libvirt} +# +# pcp-pmda-libvirt +# +%package pmda-libvirt +Summary: Performance Co-Pilot (PCP) metrics for virtual machines +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: libvirt-python3 +Requires: python3-lxml +Requires: python3-pcp +BuildRequires: libvirt-python3 +%else +Requires: libvirt-python +Requires: python-lxml +Requires: python-pcp +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 +BuildRequires: libvirt-python +%endif +%endif +%description pmda-libvirt +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +extracting virtualisation statistics from libvirt about behaviour of guest +and hypervisor machines. +# end pcp-pmda-libvirt +%endif + +# +# pcp-pmda-lio +# +%package pmda-lio +Summary: Performance Co-Pilot (PCP) metrics for the LIO subsystem +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +Requires: python3-rtslib +%else +Requires: python-pcp +Requires: python-rtslib +%endif +%description pmda-lio +This package provides a PMDA to gather performance metrics from the kernels +iSCSI target interface (LIO). The metrics are stored by LIO within the Linux +kernels configfs filesystem. The PMDA provides per LUN level stats, and a +summary instance per iSCSI target, which aggregates all LUN metrics within the +target. +#end pcp-pmda-lio + +%endif # !%{disable_python2} || !%{disable_python3} + +%if !%{disable_json} +# +# pcp-pmda-json +# +%package pmda-json +Summary: Performance Co-Pilot (PCP) metrics for JSON data +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +Requires: python3-six +BuildRequires: python3-six +%if 0%{?suse_version} +Requires: python-jsonpointer +BuildRequires: python-jsonpointer +%else +Requires: python3-jsonpointer +BuildRequires: python3-jsonpointer +%endif +%else +Requires: python-jsonpointer +Requires: python-pcp +Requires: python-six +BuildRequires: python-jsonpointer +BuildRequires: python-six +%endif +%description pmda-json +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics output in JSON. +# end pcp-pmda-json +%endif # !%{disable_json} + +# +# C pmdas +# pcp-pmda-apache +# +%package pmda-apache +Summary: Performance Co-Pilot (PCP) metrics for the Apache webserver +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-apache +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Apache webserver. +# end pcp-pmda-apache + +# +# pcp-pmda-bash +# +%package pmda-bash +Summary: Performance Co-Pilot (PCP) metrics for the Bash shell +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-bash +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Bash shell. +# end pcp-pmda-bash + +# +# pcp-pmda-cifs +# +%package pmda-cifs +Summary: Performance Co-Pilot (PCP) metrics for the CIFS protocol +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-cifs +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Common Internet Filesytem. +# end pcp-pmda-cifs + +# +# pcp-pmda-cisco +# +%package pmda-cisco +Summary: Performance Co-Pilot (PCP) metrics for Cisco routers +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-cisco +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Cisco routers. +# end pcp-pmda-cisco + +# +# pcp-pmda-gfs2 +# +%package pmda-gfs2 +Summary: Performance Co-Pilot (PCP) metrics for the GFS2 filesystem +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-gfs2 +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Global Filesystem v2. +# end pcp-pmda-gfs2 + +# +# pcp-pmda-lmsensors +# +%package pmda-lmsensors +Summary: Performance Co-Pilot (PCP) metrics for hardware sensors +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-lmsensors +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Linux hardware monitoring sensors. +# end pcp-pmda-lmsensors + +# +# pcp-pmda-logger +# +%package pmda-logger +Summary: Performance Co-Pilot (PCP) metrics from arbitrary log files +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-logger +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from a specified set of log files (or pipes). The PMDA +supports both sampled and event-style metrics. +# end pcp-pmda-logger + +# +# pcp-pmda-mailq +# +%package pmda-mailq +Summary: Performance Co-Pilot (PCP) metrics for the sendmail queue +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-mailq +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about email queues managed by sendmail. +# end pcp-pmda-mailq + +# +# pcp-pmda-mounts +# +%package pmda-mounts +Summary: Performance Co-Pilot (PCP) metrics for filesystem mounts +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-mounts +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about filesystem mounts. +# end pcp-pmda-mounts + +# +# pcp-pmda-nvidia-gpu +# +%package pmda-nvidia-gpu +Summary: Performance Co-Pilot (PCP) metrics for the Nvidia GPU +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-nvidia-gpu +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Nvidia GPUs. +# end pcp-pmda-nvidia-gpu + +# +# pcp-pmda-roomtemp +# +%package pmda-roomtemp +Summary: Performance Co-Pilot (PCP) metrics for the room temperature +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-roomtemp +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the room temperature. +# end pcp-pmda-roomtemp + +%if !%{disable_rpm} +# +# pcp-pmda-rpm +# +%package pmda-rpm +Summary: Performance Co-Pilot (PCP) metrics for the RPM package manager +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-rpm +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the installed RPM packages. +%endif +# end pcp-pmda-rpm + +# +# pcp-pmda-sendmail +# +%package pmda-sendmail +Summary: Performance Co-Pilot (PCP) metrics for Sendmail +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-sendmail +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Sendmail traffic. +# end pcp-pmda-sendmail + +# +# pcp-pmda-shping +# +%package pmda-shping +Summary: Performance Co-Pilot (PCP) metrics for shell command responses +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-shping +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about quality of service and response time measurements of +arbitrary shell commands. +# end pcp-pmda-shping + +# +# pcp-pmda-summary +# +%package pmda-summary +Summary: Performance Co-Pilot (PCP) summary metrics from pmie +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-summary +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about other installed pmdas. +# end pcp-pmda-summary + +%if !%{disable_systemd} +# +# pcp-pmda-systemd +# +%package pmda-systemd +Summary: Performance Co-Pilot (PCP) metrics from the Systemd journal +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-systemd +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from the Systemd journal. +# end pcp-pmda-systemd +%endif + +# +# pcp-pmda-trace +# +%package pmda-trace +Summary: Performance Co-Pilot (PCP) metrics for application tracing +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-trace +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about trace performance data in applications. +# end pcp-pmda-trace + +# +# pcp-pmda-weblog +# +%package pmda-weblog +Summary: Performance Co-Pilot (PCP) metrics from web server logs +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-weblog +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about web server logs. +# end pcp-pmda-weblog +# end C pmdas + +# +# python-pcp. This is the PCP library bindings for python. +# +%package -n python-pcp +Summary: Performance Co-Pilot (PCP) Python bindings and documentation +License: %{license_gplv2plus} +Group: Development/Libraries +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} +%if 0%{?rhel} == 5 +Requires: python%{default_python} +%else +Requires: python +%endif + +%description -n python-pcp +This python PCP module contains the language bindings for +Performance Metric API (PMAPI) monitor tools and Performance +Metric Domain Agent (PMDA) collector tools written in Python. + +%if !%{disable_python3} +# +# python3-pcp. This is the PCP library bindings for python3. +# +%package -n python3-pcp +Summary: Performance Co-Pilot (PCP) Python3 bindings and documentation +License: %{license_gplv2plus} +Group: Development/Libraries +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +%endif +Requires: python3 + +%description -n python3-pcp +This python PCP module contains the language bindings for +Performance Metric API (PMAPI) monitor tools and Performance +Metric Domain Agent (PMDA) collector tools written in Python3. +%endif + +%if !%{disable_python2} || !%{disable_python3} +# +# pcp-system-tools +# +%package system-tools +Summary: Performance Co-Pilot (PCP) System and Monitoring Tools +License: %{license_gplv2plus} +Group: Development/Libraries +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp = %{version}-%{release} +%endif +%if !%{disable_python2} +Requires: python-pcp = %{version}-%{release} +%endif +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp-libs = %{version}-%{release} + +%description system-tools +This PCP module contains additional system monitoring tools written +in python. +%endif #end pcp-system-tools +%if !%{disable_qt} +# +# pcp-gui package for Qt tools +# +%package gui +Summary: Visualization tools for the Performance Co-Pilot toolkit +License: %{license_gplv2plus} and %{license_lgplv2plus} +Group: Applications/System +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +%endif + +%description gui +Visualization tools for the Performance Co-Pilot toolkit. +The pcp-gui package primarily includes visualization tools for +monitoring systems using live and archived Performance Co-Pilot +(PCP) sources. +%endif + +# +# pcp-doc package +# +%package doc +%if !%{disable_noarch} +BuildArch: noarch +%endif +Summary: Documentation and tutorial for the Performance Co-Pilot +License: %{license_gplv2plus} and %{license_cc_by} +Group: Documentation +Url: http://www.pcp.io +# http://fedoraproject.org/wiki/Packaging:Conflicts "Splitting Packages" +# (all man pages migrated to pcp-doc during great package split of '15) +Conflicts: pcp-pmda-pmda < 3.10.5 +Conflicts: pcp-pmda-infiniband < 3.10.5 + +%description doc +Documentation and tutorial for the Performance Co-Pilot +Performance Co-Pilot (PCP) provides a framework and services to support +system-level performance monitoring and performance management. + +The pcp-doc package provides useful information on using and +configuring the Performance Co-Pilot (PCP) toolkit for system +level performance management. It includes tutorials, HOWTOs, +and other detailed documentation about the internals of core +PCP utilities and daemons, and the PCP graphical tools. + +# +# pcp-selinux package +# +%if !%{disable_selinux} +%package selinux +Summary: Selinux policy package +License: %{license_gplv2plus} and %{license_cc_by} +Group: Applications/System +Url: http://www.pcp.io +BuildRequires: selinux-policy-devel +Requires: pcp = %{version}-%{release} +Requires: policycoreutils + +%description selinux +This package contains SELinux support for PCP. The package contains +interface rules, type enforcement and file context adjustments for an +updated policy package. +%endif + +%prep +%setup -q +%patch2 -p1 +%patch3 -p1 +%patch5 -p1 +%patch6 -p1 +%patch7 -p1 +%patch8 -p1 +%patch9 -p1 + +autoconf + +%clean +rm -Rf $RPM_BUILD_ROOT + +%build +PCP_CFLAGS="$RPM_OPT_FLAGS" CFLAGS="$RPM_OPT_FLAGS" CCFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" %configure \ + --with-tmpdir=%{_tempsdir} \ + --datarootdir=%{_datadir} \ + --docdir=%{_docdir} \ + %{?_with_initd} \ + %{?_with_doc} \ + %{?_with_ib} \ + %{?_with_papi} \ + %{?_with_perfevent} \ + %{?_with_json} \ + %{?_with_snmp} +PCP_CFLAGS="$RPM_OPT_FLAGS" CFLAGS="$RPM_OPT_FLAGS" CCFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" make default_pcp + +############################################################################### + +%install +export NO_CHOWN=true DIST_ROOT=$RPM_BUILD_ROOT +make install_pcp + +PCP_GUI='pmchart|pmconfirm|pmdumptext|pmmessage|pmquery|pmsnap|pmtime' + +# Fix stuff we do/don't want to ship +rm -f $RPM_BUILD_ROOT/%{_libdir}/*.a + +%if %{disable_sheet2pcp} +# remove sheet2pcp until BZ 830923 and BZ 754678 are resolved. +rm -f $RPM_BUILD_ROOT/%{_bindir}/sheet2pcp $RPM_BUILD_ROOT/%{_mandir}/man1/sheet2pcp.1* +%endif + +%if %{disable_libvirt} +rm -fr $RPM_BUILD_ROOT/%{_pmdasdir}/libvirt +%endif + +%if %{disable_postgresql} +rm -fr $RPM_BUILD_ROOT/%{_pmdasdir}/postgresql +%endif + +# remove {config,platform}sz.h as these are not multilib friendly. +rm -f $RPM_BUILD_ROOT/%{_includedir}/pcp/configsz.h +rm -f $RPM_BUILD_ROOT/%{_includedir}/pcp/platformsz.h + +%if %{disable_microhttpd} +rm -f $RPM_BUILD_ROOT/%{_mandir}/man1/pmwebd.* +rm -f $RPM_BUILD_ROOT/%{_mandir}/man3/PMWEBAPI.* +rm -fr $RPM_BUILD_ROOT/%{_confdir}/pmwebd +rm -fr $RPM_BUILD_ROOT/%{_initddir}/pmwebd +rm -fr $RPM_BUILD_ROOT/%{_unitdir}/pmwebd.service +rm -f $RPM_BUILD_ROOT/%{_libexecdir}/pcp/bin/pmwebd +%endif + +%if %{disable_infiniband} +# remove pmdainfiniband on platforms lacking IB devel packages. +rm -f $RPM_BUILD_ROOT/%{_pmdasdir}/ib +rm -fr $RPM_BUILD_ROOT/%{_pmdasdir}/infiniband +%endif + +%if %{disable_selinux} +rm -fr $RPM_BUILD_ROOT/%{_selinuxdir} +%endif + +%if %{disable_qt} +%if !0%{?suse_version} +rm -fr $RPM_BUILD_ROOT/%{_pixmapdir} +%endif +rm -fr $RPM_BUILD_ROOT/%{_confdir}/pmsnap +rm -fr $RPM_BUILD_ROOT/%{_localstatedir}/lib/pcp/config/pmsnap +rm -fr $RPM_BUILD_ROOT/%{_localstatedir}/lib/pcp/config/pmchart +rm -f $RPM_BUILD_ROOT/%{_localstatedir}/lib/pcp/config/pmafm/pcp-gui +rm -f $RPM_BUILD_ROOT/%{_datadir}/applications/pmchart.desktop +rm -f `find $RPM_BUILD_ROOT/%{_mandir}/man1 | grep -E "$PCP_GUI"` +%else +rm -rf $RPM_BUILD_ROOT/usr/share/doc/pcp-gui +%if 0%{?suse_version} +mkdir -p $RPM_BUILD_ROOT/%{_pixmapdir} +mv $RPM_BUILD_ROOT/%{_datadir}/pcp-gui/pixmaps/*.png $RPM_BUILD_ROOT/%{_pixmapdir} +rm -rf $RPM_BUILD_ROOT/%{_datadir}/pcp-gui/pixmaps +%suse_update_desktop_file -r -G 'Performance Copilot Chart' $RPM_BUILD_ROOT/%{_datadir}/applications/pmchart.desktop System Monitor +%else +desktop-file-validate $RPM_BUILD_ROOT/%{_datadir}/applications/pmchart.desktop +%endif +%endif + +%if 0%{?suse_version} +mkdir -p $RPM_BUILD_ROOT/%{_tempsdir} + +%__install -d -m 0755 ${RPM_BUILD_ROOT}/%{_sbindir} + +%if !0%{?has_systemd} +# add /etc/init.d/X symlinks at /usr/sbin/rcX +for script in pcp pmie pmproxy pmlogger pmcd; do + ln -s "%{_sysconfdir}/init.d/${script}" \ + "${RPM_BUILD_ROOT}/%{_sbindir}/rc${script}" +done +%else +ln -sf /sbin/service $RPM_BUILD_ROOT/%{_sbindir}/rcpmcd +ln -sf /sbin/service $RPM_BUILD_ROOT/%{_sbindir}/rcpmie +ln -sf /sbin/service $RPM_BUILD_ROOT/%{_sbindir}/rcpmlogger +ln -sf /sbin/service $RPM_BUILD_ROOT/%{_sbindir}/rcpmproxy +ln -sf /sbin/service $RPM_BUILD_ROOT/%{_sbindir}/rcpmmgr +ln -sf /sbin/service $RPM_BUILD_ROOT/%{_sbindir}/rcpmwebd +%endif + +# SUSE requires use of %fillup_and_insserv +mkdir -p $RPM_BUILD_ROOT/%{_localstatedir}/adm/fillup-templates +mv $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/pmlogger \ + $RPM_BUILD_ROOT/%{_localstatedir}/adm/fillup-templates/sysconfig.pmlogger +mv $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/pmproxy \ + $RPM_BUILD_ROOT/%{_localstatedir}/adm/fillup-templates/sysconfig.pmproxy +mv $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/pmcd \ + $RPM_BUILD_ROOT/%{_localstatedir}/adm/fillup-templates/sysconfig.pmcd + +%else +# default chkconfig off for Fedora and RHEL +for f in $RPM_BUILD_ROOT/%{_initddir}/{pcp,pmcd,pmlogger,pmie,pmwebd,pmmgr,pmproxy}; do + test -f "$f" || continue + sed -i -e '/^# chkconfig/s/:.*$/: - 95 05/' -e '/^# Default-Start:/s/:.*$/:/' $f +done +%endif + +# list of PMDAs in the base pkg +ls -1 $RPM_BUILD_ROOT/%{_pmdasdir} |\ + grep -E -v '^simple|sample|trivial|txmon' |\ + grep -E -v '^perfevent|perfalloc.1' |\ + grep -E -v '^ib$|^infiniband' |\ + grep -E -v '^activemq' |\ + grep -E -v '^bonding' |\ + grep -E -v '^bind2' |\ + grep -E -v '^dbping' |\ + grep -E -v '^docker' |\ + grep -E -v '^ds389log'|\ + grep -E -v '^ds389' |\ + grep -E -v '^elasticsearch' |\ + grep -E -v '^gpfs' |\ + grep -E -v '^gpsd' |\ + grep -E -v '^kvm' |\ + grep -E -v '^lio' |\ + grep -E -v '^lustre' |\ + grep -E -v '^lustrecomm' |\ + grep -E -v '^memcache' |\ + grep -E -v '^mysql' |\ + grep -E -v '^named' |\ + grep -E -v '^netfilter' |\ + grep -E -v '^news' |\ + grep -E -v '^nfsclient' |\ + grep -E -v '^nginx' |\ + grep -E -v '^nutcracker' |\ + grep -E -v '^oracle' |\ + grep -E -v '^papi' |\ + grep -E -v '^pdns' |\ + grep -E -v '^postfix' |\ + grep -E -v '^postgresql' |\ + grep -E -v '^redis' |\ + grep -E -v '^rsyslog' |\ + grep -E -v '^samba' |\ + grep -E -v '^slurm' |\ + grep -E -v '^snmp' |\ + grep -E -v '^vmware' |\ + grep -E -v '^zimbra' |\ + grep -E -v '^dm' |\ + grep -E -v '^apache' |\ + grep -E -v '^bash' |\ + grep -E -v '^cifs' |\ + grep -E -v '^cisco' |\ + grep -E -v '^gfs2' |\ + grep -E -v '^libvirt' |\ + grep -E -v '^lmsensors' |\ + grep -E -v '^logger' |\ + grep -E -v '^mailq' |\ + grep -E -v '^mounts' |\ + grep -E -v '^nvidia' |\ + grep -E -v '^roomtemp' |\ + grep -E -v '^sendmail' |\ + grep -E -v '^shping' |\ + grep -E -v '^summary' |\ + grep -E -v '^trace' |\ + grep -E -v '^weblog' |\ + grep -E -v '^rpm' |\ + grep -E -v '^json' |\ + grep -E -v '^mic' |\ + grep -E -v '^gluster' |\ + grep -E -v '^zswap' |\ + grep -E -v '^unbound' |\ + sed -e 's#^#'%{_pmdasdir}'\/#' >base_pmdas.list + +# all base pcp package files except those split out into sub packages +ls -1 $RPM_BUILD_ROOT/%{_bindir} |\ + grep -E -v 'pmiostat|pmcollectl|pmatop|zabbix|zbxpcp' |\ + grep -E -v 'pmrep|pcp2graphite|pcp2influxdb' |\ + grep -E -v 'pmdbg|pmclient|pmerr|genpmda' |\ +sed -e 's#^#'%{_bindir}'\/#' >base_bin.list +# +# Separate the pcp-system-tools package files. +# +# pmatop, pmcollectl and pmiostat are back-compat symlinks to their +# pcp(1) sub-command variants so must also be in pcp-system-tools. +%if !%{disable_python2} || !%{disable_python3} +ls -1 $RPM_BUILD_ROOT/%{_bindir} |\ + grep -E 'pmiostat|pmcollectl|pmatop|pmrep' |\ + sed -e 's#^#'%{_bindir}'\/#' >pcp_system_tools.list +ls -1 $RPM_BUILD_ROOT/%{_libexecdir}/pcp/bin |\ + grep -E 'atop|collectl|dmcache|free|iostat|mpstat|numastat|pidstat|verify|uptime|shping' |\ + sed -e 's#^#'%{_libexecdir}/pcp/bin'\/#' >>pcp_system_tools.list +%endif + +ls -1 $RPM_BUILD_ROOT/%{_libexecdir}/pcp/bin |\ +%if !%{disable_python2} || !%{disable_python3} + grep -E -v 'atop|collectl|dmcache|free|iostat|mpstat|numastat|pidstat|verify|uptime|shping' |\ +%endif + sed -e 's#^#'%{_libexecdir}/pcp/bin'\/#' >base_exec.list +ls -1 $RPM_BUILD_ROOT/%{_booksdir} |\ + sed -e 's#^#'%{_booksdir}'\/#' > pcp-doc.list +ls -1 $RPM_BUILD_ROOT/%{_mandir}/man1 |\ + sed -e 's#^#'%{_mandir}'\/man1\/#' >>pcp-doc.list +ls -1 $RPM_BUILD_ROOT/%{_mandir}/man5 |\ + sed -e 's#^#'%{_mandir}'\/man5\/#' >>pcp-doc.list +%if 0%{?suse_version} +mv $RPM_BUILD_ROOT/%{_datadir}/pcp/demos $RPM_BUILD_ROOT/%{_docdir}/pcp +ls -1 $RPM_BUILD_ROOT/%{_docdir}/pcp/demos/tutorials |\ + sed -e 's#^#'%{_docdir}/pcp/demos/tutorials'\/#' >>pcp-doc.list +find $RPM_BUILD_ROOT/%{_datadir}/doc/pcp-doc |\ + sed -e "s#^$RPM_BUILD_ROOT#/#" >>pcp-doc.list +%else +ls -1 $RPM_BUILD_ROOT/%{_datadir}/pcp/demos/tutorials |\ + sed -e 's#^#'%{_datadir}/pcp/demos/tutorials'\/#' >>pcp-doc.list +%endif +%if !%{disable_selinux} +ls -1 $RPM_BUILD_ROOT/%{_selinuxdir} |\ + sed -e 's#^#'%{_selinuxdir}'\/#' > pcp-selinux.list +%endif +%if !%{disable_qt} +ls -1 $RPM_BUILD_ROOT/%{_pixmapdir} |\ + sed -e 's#^#'%{_pixmapdir}'\/#' > pcp-gui.list +cat base_bin.list base_exec.list |\ + grep -E "$PCP_GUI" >> pcp-gui.list +%endif +cat base_pmdas.list base_bin.list base_exec.list |\ + grep -E -v 'pmdaib|pmmgr|pmweb|pmsnap|2pcp|pmdas/systemd' |\ + grep -E -v "$PCP_GUI|pixmaps|pcp-doc|tutorials|selinux" |\ + grep -E -v %{_confdir} | grep -E -v %{_logsdir} > base.list + +# all devel pcp package files except those split out into sub packages +ls -1 $RPM_BUILD_ROOT/%{_mandir}/man3 |\ +sed -e 's#^#'%{_mandir}'\/man3\/#' | grep -v '3pm' >>pcp-doc.list +%if 0%{?suse_version} +ls -1 $RPM_BUILD_ROOT/%{_docdir}/pcp/demos |\ +sed -e 's#^#'%{_docdir}'\/pcp\/demos\/#' | grep -E -v tutorials >> devel.list +%else +ls -1 $RPM_BUILD_ROOT/%{_datadir}/pcp/demos |\ +sed -e 's#^#'%{_datadir}'\/pcp\/demos\/#' | grep -E -v tutorials >> devel.list +%endif +ls -1 $RPM_BUILD_ROOT/%{_bindir} |\ +grep -E 'pmdbg|pmclient|pmerr|genpmda' |\ +sed -e 's#^#'%{_bindir}'\/#' >>devel.list + +%pre testsuite +test -d %{_testsdir} || mkdir -p -m 755 %{_testsdir} +getent group pcpqa >/dev/null || groupadd -r pcpqa +getent passwd pcpqa >/dev/null || \ + useradd -c "PCP Quality Assurance" -g pcpqa -d %{_testsdir} -M -r -s /bin/bash pcpqa 2>/dev/null +chown -R pcpqa:pcpqa %{_testsdir} 2>/dev/null +exit 0 + +%post testsuite +chown -R pcpqa:pcpqa %{_testsdir} 2>/dev/null +exit 0 + +%pre +getent group pcp >/dev/null || groupadd -r pcp +getent passwd pcp >/dev/null || \ + useradd -c "Performance Co-Pilot" -g pcp -d %{_localstatedir}/lib/pcp -M -r -s /sbin/nologin pcp +%if !0%{?suse_version} +PCP_CONFIG_DIR=%{_localstatedir}/lib/pcp/config +PCP_SYSCONF_DIR=%{_confdir} +PCP_LOG_DIR=%{_logsdir} +PCP_ETC_DIR=%{_sysconfdir} +# rename crontab files to align with current Fedora packaging guidelines +for crontab in pmlogger pmie +do + test -f "$PCP_ETC_DIR/cron.d/$crontab" || continue + mv -f "$PCP_ETC_DIR/cron.d/$crontab" "$PCP_ETC_DIR/cron.d/pcp-$crontab" +done +# produce a script to run post-install to move configs to their new homes +save_configs_script() +{ + _new="$1" + shift + for _dir + do + [ "$_dir" = "$_new" ] && continue + if [ -d "$_dir" ] + then + ( cd "$_dir" ; find . -maxdepth 1 -type f ) | sed -e 's/^\.\///' \ + | while read _file + do + [ "$_file" = "control" ] && continue + _want=true + if [ -f "$_new/$_file" ] + then + # file exists in both directories, pick the more + # recently modified one + _try=`find "$_dir/$_file" -newer "$_new/$_file" -print` + [ -n "$_try" ] || _want=false + fi + $_want && echo cp -p "$_dir/$_file" "$_new/$_file" + done + fi + done +} +# migrate and clean configs if we have had a previous in-use installation +[ -d "$PCP_LOG_DIR" ] || exit 0 # no configuration file upgrades required +rm -f "$PCP_LOG_DIR/configs.sh" +for daemon in pmie pmlogger +do + save_configs_script >> "$PCP_LOG_DIR/configs.sh" "$PCP_CONFIG_DIR/$daemon" \ + "$PCP_SYSCONF_DIR/$daemon" +done +for daemon in pmcd pmproxy +do + save_configs_script >> "$PCP_LOG_DIR/configs.sh" "$PCP_SYSCONF_DIR/$daemon"\ + "$PCP_CONFIG_DIR/$daemon" /etc/$daemon +done +%endif +exit 0 + +%if !%{disable_microhttpd} +%preun webapi +%if 0%{?suse_version} +%if !%{disable_systemd} +%service_del_preun pmwebd +%else +%{stop_on_removal pmwebd} +%endif +%else +if [ "$1" -eq 0 ] +then +%if !%{disable_systemd} + systemctl --no-reload disable pmwebd.service >/dev/null 2>&1 + systemctl stop pmwebd.service >/dev/null 2>&1 +%else + /sbin/service pmwebd stop >/dev/null 2>&1 + /sbin/chkconfig --del pmwebd >/dev/null 2>&1 +%endif +fi +%endif +%endif + +%preun manager +%if 0%{?suse_version} +%if !%{disable_systemd} +%service_del_preun pmmgr +%else +%{stop_on_removal pmmgr} +%endif +%else +if [ "$1" -eq 0 ] +then +%if !%{disable_systemd} + systemctl --no-reload disable pmmgr.service >/dev/null 2>&1 + systemctl stop pmmgr.service >/dev/null 2>&1 +%else + /sbin/service pmmgr stop >/dev/null 2>&1 + /sbin/chkconfig --del pmmgr >/dev/null 2>&1 +%endif +fi +%endif + +%preun +%if 0%{?suse_version} +%if !%{disable_systemd} +%service_del_preun pmlogger pmie pmproxy pmcd +%else +%{?stop_on_removal:%{stop_on_removal pmlogger pmie pmproxy pmcd}} +%endif +%else +if [ "$1" -eq 0 ] +then + # stop daemons before erasing the package + %if !%{disable_systemd} + systemctl --no-reload disable pmlogger.service >/dev/null 2>&1 + systemctl --no-reload disable pmie.service >/dev/null 2>&1 + systemctl --no-reload disable pmproxy.service >/dev/null 2>&1 + systemctl --no-reload disable pmcd.service >/dev/null 2>&1 + + systemctl stop pmlogger.service >/dev/null 2>&1 + systemctl stop pmie.service >/dev/null 2>&1 + systemctl stop pmproxy.service >/dev/null 2>&1 + systemctl stop pmcd.service >/dev/null 2>&1 + %else + /sbin/service pmlogger stop >/dev/null 2>&1 + /sbin/service pmie stop >/dev/null 2>&1 + /sbin/service pmproxy stop >/dev/null 2>&1 + /sbin/service pmcd stop >/dev/null 2>&1 + + /sbin/chkconfig --del pcp >/dev/null 2>&1 + /sbin/chkconfig --del pmcd >/dev/null 2>&1 + /sbin/chkconfig --del pmlogger >/dev/null 2>&1 + /sbin/chkconfig --del pmie >/dev/null 2>&1 + /sbin/chkconfig --del pmproxy >/dev/null 2>&1 + %endif + # cleanup namespace state/flag, may still exist + PCP_PMNS_DIR=%{_pmnsdir} + rm -f "$PCP_PMNS_DIR/.NeedRebuild" >/dev/null 2>&1 +fi +%endif + +%if !%{disable_microhttpd} +%post webapi +chown -R pcp:pcp %{_logsdir}/pmwebd 2>/dev/null +%if 0%{?suse_version} +%if !%{disable_systemd} +%service_add_post pmwebd +%else +%{fillup_and_insserv pmwebd} +%endif +%else +%if !%{disable_systemd} + systemctl condrestart pmwebd.service >/dev/null 2>&1 +%else + /sbin/chkconfig --add pmwebd >/dev/null 2>&1 + /sbin/service pmwebd condrestart +%endif +%endif +%endif + +%post manager +chown -R pcp:pcp %{_logsdir}/pmmgr 2>/dev/null +%if 0%{?suse_version} +%if !%{disable_systemd} +%service_add_post pmmgr +%else +%{fillup_and_insserv pmmgr} +%endif +%else +%if !%{disable_systemd} + systemctl condrestart pmmgr.service >/dev/null 2>&1 +%else + /sbin/chkconfig --add pmmgr >/dev/null 2>&1 + /sbin/service pmmgr condrestart +%endif +%endif + +%if !%{disable_selinux} +%post selinux +%if 0%{?fedora} >= 24 || 0%{?rhel} > 6 + semodule -X 400 -i %{localstatedir}/lib/pcp/selinux/pcpupstream.pp +%else + semodule -i %{localstatedir}/lib/pcp/selinux/pcpupstream.pp +%endif #distro version check +%endif + +%post +PCP_LOG_DIR=%{_logsdir} +PCP_PMNS_DIR=%{_pmnsdir} +# restore saved configs, if any +test -s "$PCP_LOG_DIR/configs.sh" && source "$PCP_LOG_DIR/configs.sh" +rm -f $PCP_LOG_DIR/configs.sh + +# migrate old to new temp dir locations (within the same filesystem) +migrate_tempdirs() +{ + _sub="$1" + _new_tmp_dir=%{_tempsdir} + _old_tmp_dir=%{_localstatedir}/tmp + + for d in "$_old_tmp_dir/$_sub" ; do + test -d "$d" -a -k "$d" || continue + cd "$d" || continue + for f in * ; do + [ "$f" != "*" ] || continue + source="$d/$f" + target="$_new_tmp_dir/$_sub/$f" + [ "$source" != "$target" ] || continue + [ -f "$target" ] || mv -fu "$source" "$target" + done + cd && rmdir "$d" 2>/dev/null + done +} +for daemon in mmv pmdabash pmie pmlogger +do + migrate_tempdirs $daemon +done +chown -R pcp:pcp %{_logsdir}/pmcd 2>/dev/null +chown -R pcp:pcp %{_logsdir}/pmlogger 2>/dev/null +chown -R pcp:pcp %{_logsdir}/pmie 2>/dev/null +chown -R pcp:pcp %{_logsdir}/pmproxy 2>/dev/null +touch "$PCP_PMNS_DIR/.NeedRebuild" +chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" +%if 0%{?suse_version} +%if !%{disable_systemd} +%service_add_post pmcd +%service_add_post pmlogger +%service_add_post pmie +%service_add_post pmproxy +%else +%{fillup_and_insserv pmcd} +%{fillup_and_insserv pmlogger} +%{fillup_and_insserv pmie} +%{fillup_and_insserv pmproxy} +%endif +%else +%if !%{disable_systemd} + systemctl condrestart pmcd.service >/dev/null 2>&1 + systemctl condrestart pmlogger.service >/dev/null 2>&1 + systemctl condrestart pmie.service >/dev/null 2>&1 + systemctl condrestart pmproxy.service >/dev/null 2>&1 +%else + /sbin/chkconfig --add pmcd >/dev/null 2>&1 + /sbin/service pmcd condrestart + /sbin/chkconfig --add pmlogger >/dev/null 2>&1 + /sbin/service pmlogger condrestart + /sbin/chkconfig --add pmie >/dev/null 2>&1 + /sbin/service pmie condrestart + /sbin/chkconfig --add pmproxy >/dev/null 2>&1 + /sbin/service pmproxy condrestart +%endif +%endif + +cd $PCP_PMNS_DIR && ./Rebuild -s && rm -f .NeedRebuild +cd + +%post -n %{lib_pkg} -p /sbin/ldconfig +%postun -n %{lib_pkg} -p /sbin/ldconfig + +%if !%{disable_selinux} +%postun selinux +%if 0%{?fedora} >= 24 || 0%{?rhel} > 6 + semodule -X 400 -r pcpupstream >/dev/null +%else + semodule -r pcpupstream >/dev/null +%endif +%endif + +%if 0%{?suse_version} +%postun +/sbin/ldconfig +%if !%{disable_systemd} +%service_del_postun pcp pmproxy pmie +%else +%{?restart_on_update:%{restart_on_update pcp pmproxy pmie}} +%{?insserv_cleanup:%{insserv_cleanup}} +%endif +%endif + +%files -f base.list +# +# Note: there are some headers (e.g. domain.h) and in a few cases some +# C source files that rpmlint complains about. These are not devel files, +# but rather they are (slightly obscure) PMDA config files. +# +%defattr(-,root,root) +%doc CHANGELOG COPYING INSTALL.md README.md VERSION.pcp pcp.lsm +%if 0%{?suse_version} +%exclude %{_docdir}/pcp/demos +%exclude %{_docdir}/pcp/examples +%exclude %{_docdir}/pcp/trivial +%exclude %{_docdir}/pcp/txmon +%exclude %{_testsdir} +# -> pcp-pmda-infiniband +%exclude %{_pmdasdir}/infiniband +%endif + +%dir %{_confdir} +%dir %{_pmdasdir} +%dir %{_datadir}/pcp +%dir %{_localstatedir}/lib/pcp +%if 0%{?suse_version} +%dir %{_libdir}/pcp +%dir %{_libdir}/pcp/bin +%endif +%{_localstatedir}/lib/pcp +%dir %{_localstatedir}/lib/pcp/config +%if 0%{?suse_version} +# part of pcp-gui +%exclude %{_localstatedir}/lib/pcp/config/pmsnap +%exclude %{_localstatedir}/lib/pcp/config/pmchart +%exclude %{_localstatedir}/lib/pcp/config/pmafm/pcp-gui +%{_initddir}/pcp +%{_initddir}/pmcd +%{_initddir}/pmlogger +%{_initddir}/pmie +%{_initddir}/pmproxy +%endif +%dir %attr(0775,pcp,pcp) %{_tempsdir} +%dir %attr(0775,pcp,pcp) %{_tempsdir}/pmie +%dir %attr(0775,pcp,pcp) %{_tempsdir}/pmlogger +%dir %attr(0700,root,root) %{_tempsdir}/pmcd + +%dir %{_datadir}/pcp/lib +%{_datadir}/pcp/lib/ReplacePmnsSubtree +%{_datadir}/pcp/lib/bashproc.sh +%{_datadir}/pcp/lib/lockpmns +%{_datadir}/pcp/lib/pmdaproc.sh +%{_datadir}/pcp/lib/utilproc.sh +%{_datadir}/pcp/lib/rc-proc.sh +%{_datadir}/pcp/lib/rc-proc.sh.minimal +%{_datadir}/pcp/lib/unlockpmns + +%dir %attr(0775,pcp,pcp) %{_logsdir} +%attr(0775,pcp,pcp) %{_logsdir}/pmcd +%attr(0775,pcp,pcp) %{_logsdir}/pmlogger +%attr(0775,pcp,pcp) %{_logsdir}/pmie +%attr(0775,pcp,pcp) %{_logsdir}/pmproxy +%{_localstatedir}/lib/pcp/pmns +%if %{disable_systemd} +%{_initrddir}/pcp +%{_initrddir}/pmcd +%{_initrddir}/pmlogger +%{_initrddir}/pmie +%{_initrddir}/pmproxy +%else +%{_unitdir}/pmcd.service +%{_unitdir}/pmlogger.service +%{_unitdir}/pmie.service +%{_unitdir}/pmproxy.service +%{_sbindir}/rcpmcd +%{_sbindir}/rcpmie +%{_sbindir}/rcpmlogger +%{_sbindir}/rcpmproxy +%endif +%dir %{_sysconfdir}/sasl2 +%config(noreplace) %{_sysconfdir}/sasl2/pmcd.conf +%config(noreplace) %{_sysconfdir}/cron.d/pcp-pmlogger +%config(noreplace) %{_sysconfdir}/cron.d/pcp-pmie +%if 0%{?suse_version} +%{_localstatedir}/adm/fillup-templates/sysconfig.pmlogger +%{_localstatedir}/adm/fillup-templates/sysconfig.pmproxy +%{_localstatedir}/adm/fillup-templates/sysconfig.pmcd +%else +%config(noreplace) %{_sysconfdir}/sysconfig/pmlogger +%config(noreplace) %{_sysconfdir}/sysconfig/pmproxy +%config(noreplace) %{_sysconfdir}/sysconfig/pmcd +%endif +%config %{_sysconfdir}/pcp.env +%dir %{_confdir}/pmcd +%config(noreplace) %{_confdir}/pmcd/pmcd.conf +%config(noreplace) %{_confdir}/pmcd/pmcd.options +%config(noreplace) %{_confdir}/pmcd/rc.local +%dir %{_confdir}/pmproxy +%config(noreplace) %{_confdir}/pmproxy/pmproxy.options +%dir %{_confdir}/pmie +%dir %{_confdir}/pmie/control.d +%config(noreplace) %{_confdir}/pmie/control +%config(noreplace) %{_confdir}/pmie/control.d/local +%dir %{_confdir}/pmlogger +%dir %{_confdir}/pmlogger/control.d +%config(noreplace) %{_confdir}/pmlogger/control +%config(noreplace) %{_confdir}/pmlogger/control.d/local +%dir %attr(0775,pcp,pcp) %{_confdir}/nssdb + +%{_localstatedir}/lib/pcp/config/pmafm +%dir %attr(0775,pcp,pcp) %{_localstatedir}/lib/pcp/config/pmie +%{_localstatedir}/lib/pcp/config/pmie +%{_localstatedir}/lib/pcp/config/pmieconf +%dir %attr(0775,pcp,pcp) %{_localstatedir}/lib/pcp/config/pmlogger +%{_localstatedir}/lib/pcp/config/pmlogger/* +%{_localstatedir}/lib/pcp/config/pmlogconf +%{_localstatedir}/lib/pcp/config/pmlogrewrite +%dir %attr(0775,pcp,pcp) %{_localstatedir}/lib/pcp/config/pmda + +%{_datadir}/bash-completion/completions/pcp +%{_datadir}/zsh/site-functions/_pcp + +%if !%{disable_sdt} +%{tapsetdir}/pmcd.stp +%endif + +%files conf +%defattr(-,root,root) + +%dir %{_includedir}/pcp +%{_includedir}/pcp/builddefs +%{_includedir}/pcp/buildrules +%config %{_sysconfdir}/pcp.conf +%dir %{_localstatedir}/lib/pcp/config/derived +%config %{_localstatedir}/lib/pcp/config/derived/* + +%files -n %{lib_pkg} +%defattr(-,root,root) + +%{_libdir}/libpcp.so.3 +%{_libdir}/libpcp_gui.so.2 +%{_libdir}/libpcp_mmv.so.1 +%{_libdir}/libpcp_pmda.so.3 +%{_libdir}/libpcp_trace.so.2 +%{_libdir}/libpcp_import.so.1 +%{_libdir}/libpcp_web.so.1 + +%files -n %{lib_devel_pkg} -f devel.list +%defattr(-,root,root) + +%{_libdir}/libpcp.so +%{_libdir}/libpcp_gui.so +%{_libdir}/libpcp_mmv.so +%{_libdir}/libpcp_pmda.so +%{_libdir}/libpcp_trace.so +%{_libdir}/libpcp_import.so +%{_libdir}/libpcp_web.so +%{_includedir}/pcp/*.h + +%files devel -f devel.list +%{_datadir}/pcp/examples + +# PMDAs that ship src and are not for production use +# straight out-of-the-box, for devel or QA use only. +%{_pmdasdir}/simple +%{_pmdasdir}/sample +%{_pmdasdir}/trivial +%{_pmdasdir}/txmon + +%files testsuite +%defattr(-,pcpqa,pcpqa) +%{_testsdir} + +%if !%{disable_microhttpd} +%files webapi +%defattr(-,root,root) +%{_initddir}/pmwebd +%if !%{disable_systemd} +%{_unitdir}/pmwebd.service +%{_sbindir}/rcpmwebd +%endif +%{_libexecdir}/pcp/bin/pmwebd +%attr(0775,pcp,pcp) %{_logsdir}/pmwebd +%dir %{_confdir}/pmwebd +%config(noreplace) %{_confdir}/pmwebd/pmwebd.options +# duplicate directories from pcp and pcp-webjs, but rpm copes with that. +%dir %{_datadir}/pcp +%endif + +%files manager +%defattr(-,root,root) +%if 0%{?suse_version} +%dir %{_confdir}/pmmgr +%{_confdir}/pmmgr +%endif +%{_initddir}/pmmgr +%if !%{disable_systemd} +%{_unitdir}/pmmgr.service +%{_sbindir}/rcpmmgr +%endif +%{_libexecdir}/pcp/bin/pmmgr +%attr(0775,pcp,pcp) %{_logsdir}/pmmgr +%dir %{_confdir}/pmmgr +%config(noreplace) %{_confdir}/pmmgr/pmmgr.options + +%files import-sar2pcp +%defattr(-,root,root) +%{_bindir}/sar2pcp + +%files import-iostat2pcp +%defattr(-,root,root) +%{_bindir}/iostat2pcp + +%if !%{disable_sheet2pcp} +%files import-sheet2pcp +%defattr(-,root,root) +%{_bindir}/sheet2pcp +%endif + +%files import-mrtg2pcp +%defattr(-,root,root) +%{_bindir}/mrtg2pcp + +%files import-ganglia2pcp +%defattr(-,root,root) +%{_bindir}/ganglia2pcp + +%files import-collectl2pcp +%defattr(-,root,root) +%{_bindir}/collectl2pcp + +%if !%{disable_papi} +%files pmda-papi +%defattr(-,root,root) +%{_pmdasdir}/papi +%endif + +%if !%{disable_perfevent} +%files pmda-perfevent +%defattr(-,root,root) +%{_pmdasdir}/perfevent +%config(noreplace) %{_pmdasdir}/perfevent/perfevent.conf +%endif + +%if !%{disable_infiniband} +%files pmda-infiniband +%defattr(-,root,root) +%{_pmdasdir}/ib +%{_pmdasdir}/infiniband +%endif + +%files pmda-activemq +%{_pmdasdir}/activemq + +%files pmda-bonding +%{_pmdasdir}/bonding + +%files pmda-bind2 +%{_pmdasdir}/bind2 + +%files pmda-dbping +%{_pmdasdir}/dbping + +%files pmda-ds389log +%{_pmdasdir}/ds389log + +%files pmda-ds389 +%{_pmdasdir}/ds389 + +%files pmda-elasticsearch +%{_pmdasdir}/elasticsearch + +%files pmda-gpfs +%{_pmdasdir}/gpfs + +%files pmda-gpsd +%{_pmdasdir}/gpsd + +%files pmda-kvm +%{_pmdasdir}/kvm + +%files pmda-docker +%{_pmdasdir}/docker + +%files pmda-lio +%{_pmdasdir}/lio + +%files pmda-lustre +%{_pmdasdir}/lustre + +%files pmda-lustrecomm +%{_pmdasdir}/lustrecomm + +%files pmda-memcache +%{_pmdasdir}/memcache + +%files pmda-mysql +%{_pmdasdir}/mysql + +%files pmda-named +%{_pmdasdir}/named + +%files pmda-netfilter +%{_pmdasdir}/netfilter + +%files pmda-news +%{_pmdasdir}/news + +%files pmda-nginx +%{_pmdasdir}/nginx + +%files pmda-nfsclient +%{_pmdasdir}/nfsclient + +%files pmda-nutcracker +%{_pmdasdir}/nutcracker + +%files pmda-oracle +%{_pmdasdir}/oracle + +%files pmda-pdns +%{_pmdasdir}/pdns + +%files pmda-postfix +%{_pmdasdir}/postfix + +%if !%{disable_postgresql} +%files pmda-postgresql +%{_pmdasdir}/postgresql +%endif + +%files pmda-redis +%{_pmdasdir}/redis + +%files pmda-rsyslog +%{_pmdasdir}/rsyslog + +%files pmda-samba +%{_pmdasdir}/samba + +%if !%{disable_snmp} +%files pmda-snmp +%{_pmdasdir}/snmp +%endif + +%files pmda-slurm +%{_pmdasdir}/slurm + +%files pmda-vmware +%{_pmdasdir}/vmware + +%files pmda-zimbra +%{_pmdasdir}/zimbra + +%files pmda-dm +%{_pmdasdir}/dm + +%if !%{disable_python2} || !%{disable_python3} +%files pmda-gluster +%{_pmdasdir}/gluster + +%files pmda-zswap +%{_pmdasdir}/zswap + +%files pmda-unbound +%{_pmdasdir}/unbound + +%files pmda-mic +%{_pmdasdir}/mic + +%if !%{disable_libvirt} +%files pmda-libvirt +%{_pmdasdir}/libvirt +%endif + +%files export-pcp2graphite +%{_bindir}/pcp2graphite + +%files export-pcp2influxdb +%{_bindir}/pcp2influxdb +%endif # !%{disable_python2} || !%{disable_python3} + +%files export-zabbix-agent +%{_libdir}/zabbix + +%if !%{disable_json} +%files pmda-json +%{_pmdasdir}/json +%endif + +%files pmda-apache +%{_pmdasdir}/apache + +%files pmda-bash +%{_pmdasdir}/bash + +%files pmda-cifs +%{_pmdasdir}/cifs + +%files pmda-cisco +%{_pmdasdir}/cisco + +%files pmda-gfs2 +%{_pmdasdir}/gfs2 + +%files pmda-lmsensors +%{_pmdasdir}/lmsensors + +%files pmda-logger +%{_pmdasdir}/logger + +%files pmda-mailq +%{_pmdasdir}/mailq + +%files pmda-mounts +%{_pmdasdir}/mounts + +%files pmda-nvidia-gpu +%{_pmdasdir}/nvidia + +%files pmda-roomtemp +%{_pmdasdir}/roomtemp + +%if !%{disable_rpm} +%files pmda-rpm +%{_pmdasdir}/rpm +%endif + +%files pmda-sendmail +%{_pmdasdir}/sendmail + +%files pmda-shping +%{_pmdasdir}/shping + +%files pmda-summary +%{_pmdasdir}/summary + +%if !%{disable_systemd} +%files pmda-systemd +%{_pmdasdir}/systemd +%endif + +%files pmda-trace +%{_pmdasdir}/trace + +%files pmda-weblog +%{_pmdasdir}/weblog + +%files -n perl-PCP-PMDA -f perl-pcp-pmda.list +%defattr(-,root,root) +%if 0%{?suse_version} +%dir %{_prefix}/lib/perl5/vendor_perl/*/*-linux-thread-multi*/PCP +%dir %{_prefix}/lib/perl5/vendor_perl/*/*-linux-thread-multi*/auto/PCP +%dir %{_prefix}/lib/perl5/vendor_perl/*/*-linux-thread-multi*/auto/PCP/PMDA +%endif + +%files -n perl-PCP-MMV -f perl-pcp-mmv.list +%defattr(-,root,root) +%if 0%{?suse_version} +%dir %{_prefix}/lib/perl5/vendor_perl/*/*-linux-thread-multi*/PCP +%dir %{_prefix}/lib/perl5/vendor_perl/*/*-linux-thread-multi*/auto/PCP +%dir %{_prefix}/lib/perl5/vendor_perl/*/*-linux-thread-multi*/auto/PCP/MMV +%endif + +%files -n perl-PCP-LogImport -f perl-pcp-logimport.list +%defattr(-,root,root) +%if 0%{?suse_version} +%dir %{_prefix}/lib/perl5/vendor_perl/*/*-linux-thread-multi*/PCP +%dir %{_prefix}/lib/perl5/vendor_perl/*/*-linux-thread-multi*/auto/PCP +%dir %{_prefix}/lib/perl5/vendor_perl/*/*-linux-thread-multi*/auto/PCP/LogImport +%endif + +%files -n perl-PCP-LogSummary -f perl-pcp-logsummary.list +%defattr(-,root,root) +%if 0%{?suse_version} +%dir %{_prefix}/lib/perl5/vendor_perl/*/PCP +%endif + +%if !%{disable_python2} +%files -n python-pcp -f python-pcp.list.rpm +%defattr(-,root,root) +%if 0%{?suse_version} +%{python_sitearch}/*.so +%dir %{python_sitearch}/pcp +%{python_sitearch}/pcp +%endif +%endif + +%if !%{disable_python3} +%files -n python3-pcp -f python3-pcp.list.rpm +%defattr(-,root,root) +%endif + +%if !%{disable_qt} +%files gui -f pcp-gui.list +%defattr(-,root,root,-) +%{_pixmapdir}/pmchart.png +%{_confdir}/pmsnap +%config(noreplace) %{_confdir}/pmsnap/control +%{_localstatedir}/lib/pcp/config/pmsnap +%{_localstatedir}/lib/pcp/config/pmchart +%{_localstatedir}/lib/pcp/config/pmafm/pcp-gui +%{_datadir}/applications/pmchart.desktop +%endif + +%files doc -f pcp-doc.list +%defattr(-,root,root,-) +%if 0%{?suse_version} +%exclude %{_docdir}/pcp/CHANGELOG +%exclude %{_docdir}/pcp/COPYING +%exclude %{_docdir}/pcp/INSTALL.md +%exclude %{_docdir}/pcp/README.md +%exclude %{_docdir}/pcp/VERSION.pcp +%exclude %{_docdir}/pcp/pcp.lsm +%dir %{_docdir}/pcp/demos +%dir %{_docdir}/pcp/demos/tutorials +%endif + +%if !%{disable_python2} || !%{disable_python3} +%files system-tools -f pcp_system_tools.list +%dir %{_confdir}/pmrep +%config(noreplace) %{_confdir}/pmrep/pmrep.conf +%endif + +%changelog diff --git a/pcp-3.10.4.src.tar.gz b/pcp-3.10.4.src.tar.gz deleted file mode 100644 index 883a4a4..0000000 --- a/pcp-3.10.4.src.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:0215380d2ddb01865f659bbf36ed06020d5865152d430a6b6fc45eda67cc22ba -size 14285544 diff --git a/pcp-webjs.src.tar.gz b/pcp-webjs.src.tar.gz deleted file mode 100644 index 3058d68..0000000 --- a/pcp-webjs.src.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:df470158fb5a075e5b4a260b8fc52dcda6f8b93baf3e3bc8cd31edd9ee846135 -size 3874320 diff --git a/pcp.changes b/pcp.changes index 16ec389..f47e560 100644 --- a/pcp.changes +++ b/pcp.changes @@ -1,3 +1,52 @@ +------------------------------------------------------------------- +Mon Mar 27 15:13:39 UTC 2017 - ddiss@suse.com + +- Update to 3.11.8 + See http://git.pcp.io/cgi-bin/gitweb.cgi?p=pcp/pcp.git;a=blob_plain;f=CHANGELOG;hb=3.11.8 + for details. + +- Remove 0010-build-do-not-include-.gitignore-in-installed-file-se.patch + + Upstream + +- Drop pcp-webjs.src.tar.gz + + https://github.com/performancecopilot/pcp-webjs/issues/3 + + Vector will be pulled in from the upstream source in future + +- Enable pmda-systemd package + + libsystemd pkg-config detection fixed upstream + +- New packages + + pcp-devel: Upstream split of non-essential devel packages from + libpcp-devel + + pcp-pmda-bind2 + + pcp-pmda-docker + + pcp-pmda-lio + + pcp-pmda-nutcracker + + pcp-pmda-oracle + + pcp-pmda-redis + + pcp-pmda-libvirt + + pcp-export-pcp2influxdb + +------------------------------------------------------------------- +Wed Mar 22 15:06:13 UTC 2017 - ddiss@suse.com + +- Update to 3.10.9 + See http://git.pcp.io/cgi-bin/gitweb.cgi?p=pcp/pcp.git;a=blob_plain;f=CHANGELOG;hb=3.10.9 + for details. + +- Drop obsolete 0001-Fix-XEN-build.patch + + PCP_PS_ALL_FLAGS now used explicitly +- Add 0010-build-do-not-include-.gitignore-in-installed-file-se.patch + +- Split out a number of agents from the base package into separate rpms +- Disable sheet2pcp + + As per upstream: "until BZ 830923 and BZ 754678 are resolved". + +------------------------------------------------------------------- +Tue Feb 28 18:09:50 UTC 2017 - ddiss@suse.com + +- Add _service file for pulling directly from the upstream Git repository. + ------------------------------------------------------------------- Thu Apr 16 09:14:35 UTC 2015 - ddiss@suse.com diff --git a/pcp.spec b/pcp.spec index 7570ad5..f040053 100644 --- a/pcp.spec +++ b/pcp.spec @@ -1,7 +1,7 @@ # # spec file for package pcp # -# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -19,67 +19,60 @@ BuildRequires: -post-build-checks %if 0%{?suse_version} > 1140 || 0%{?fedora_version} > 14 -%define has_systemd 1 +%global has_systemd 1 %else -%define has_systemd 0 +%global has_systemd 0 %endif %if 0%{?suse_version} -%define pcp_gr System/Monitoring -%define lib_pkg libpcp3 -%define lib_pkg_conflict pcp-libs -%define lib_gr System/Libraries -%define lib_devel_pkg libpcp-devel -%define lib_devel_pkg_conflict pcp-libs-devel -%define lib_devel_gr Development/Libraries/Other -%define license_apache2 Apache-2.0 -%define license_cc_by CC-BY-SA-3.0 -%define license_gplv2 GPL-2.0 -%define license_gplv2plus GPL-2.0+ -%define license_lgplv2 LGPL-2.0 -%define license_lgplv2plus LGPL-2.0+ -%define license_lgplv21plus LGPL-2.1+ -%define license_mit MIT -%define _libexecdir %{_libdir} +%global pcp_gr System/Monitoring +%global lib_pkg libpcp3 +%global lib_pkg_conflict pcp-libs +%global lib_gr System/Libraries +%global lib_devel_pkg libpcp-devel +%global lib_devel_pkg_conflict pcp-libs-devel +%global lib_devel_gr Development/Libraries/Other +%global license_apache2 Apache-2.0 +%global license_cc_by CC-BY-SA-3.0 +%global license_gplv2 GPL-2.0 +%global license_gplv2plus GPL-2.0+ +%global license_lgplv2 LGPL-2.0 +%global license_lgplv2plus LGPL-2.0+ +%global license_lgplv21plus LGPL-2.1+ +%global license_mit MIT +%global _libexecdir %{_libdir} %else -%define pcp_gr Applications/System -%define lib_pkg pcp-libs -%define lib_pkg_conflict libpcp3 -%define lib_gr Applications/System -%define lib_devel_pkg pcp-libs-devel -%define lib_devel_pkg_conflict libpcp-devel -%define lib_devel_gr Development/Libraries -%define license_apache2 ASL2.0 -%define license_cc_by CC-BY -%define license_gplv2 GPLv2 -%define license_gplv2plus GPLv2+ -%define license_lgplv2 LGPLv2 -%define license_lgplv2plus LGPLv2+ -%define license_lgplv21plus LGPLv2.1+ -%define license_mit MIT +%global pcp_gr Applications/System +%global lib_pkg pcp-libs +%global lib_pkg_conflict libpcp3 +%global lib_gr System Environment/Libraries +%global lib_devel_pkg pcp-libs-devel +%global lib_devel_pkg_conflict libpcp-devel +%global lib_devel_gr Development/Libraries +%global license_apache2 ASL2.0 +%global license_cc_by CC-BY +%global license_gplv2 GPLv2 +%global license_gplv2plus GPLv2+ +%global license_lgplv2 LGPLv2 +%global license_lgplv2plus LGPLv2+ +%global license_lgplv21plus LGPLv2.1+ +%global license_mit MIT %endif Summary: System-level performance monitoring and performance management License: %{license_gplv2plus} and %{license_lgplv2plus} and %{license_cc_by} Group: %{pcp_gr} Name: pcp -Version: 3.10.4 +Version: replaced_by_obs_set_version Release: 0 -%define buildversion 1 - -%if 0%{?suse_version} -%else -%endif +%global buildversion 1 Url: http://www.pcp.io -Source0: pcp-%{version}.src.tar.gz -Source1: pcp-webjs.src.tar.gz +Source0: pcp-%{version}.tar.bz2 %if 0%{?suse_version} Source2: pcp-rpmlintrc %endif -# PATCH-FIX-OPENSUSE, kkaempf@suse.de -Patch1: 0001-Fix-XEN-build.patch # PATCH-FIX-OPENSUSE, kkaempf@suse.de Patch2: 0002-Install-libraries-without-exec-permission.patch # PATCH-FIX-OPENSUSE, kkaempf@suse.de @@ -95,32 +88,118 @@ Patch8: 0008-SUSE-fy-pmsnap-control-path.patch # PATCH-FIX-OPENSUSE, kkaempf@suse.de Patch9: 0009-pmsnap-control-var-www-srv-www.patch +%if 0%{?fedora} || 0%{?rhel} +%global disable_selinux 0 +%else +%global disable_selinux 1 +%endif + +%global disable_snmp 0 + # There are no papi/libpfm devel packages for s390 nor for some rhels, disable %ifarch s390 s390x -%{!?disable_papi: %global disable_papi 1} -%{!?disable_perfevent: %global disable_perfevent 1} +%global disable_papi 1 +%global disable_perfevent 1 %else -%{!?disable_papi: %global disable_papi (0%{?rhel} < 6)} -%{!?disable_perfevent: %global disable_perfevent (0%{?rhel} < 7)} +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 || 0%{?suse_version} +%global disable_papi 0 +%else +%global disable_papi 1 +%endif +%if 0%{?fedora} >= 20 || 0%{?rhel} > 6 || 0%{?suse_version} +%global disable_perfevent 0 +%else +%global disable_perfevent 1 +%endif %endif -%if 0%{?suse_version} -%define disable_sheet2pcp 0 +%global disable_sheet2pcp 1 +%global disable_microhttpd 0 +%global disable_cairo 0 + +%global disable_python2 0 +# Default for epel5 is python24, so use the (optional) python26 packages +%if 0%{?rhel} == 5 +%global default_python 26 +%endif +# No python3 development environment before el8 +%if 0%{?rhel} == 0 || 0%{?rhel} > 7 +%global disable_python3 0 +# Do we wish to mandate python3 use in pcp? (f22+ and el8+) +%if 0%{?fedora} >= 22 || 0%{?rhel} > 7 +%global default_python 3 +%endif %else -%define disable_sheet2pcp 1 +%global disable_python3 1 %endif -%define disable_microhttpd 0 -%define disable_cairo 0 -%if 0%{?rhel} > 6 -%define disable_python3 0 -%else -%define disable_python3 1 +# some Python3 deps missing for SLE <= 12SP2 +%if 0%{?sle_version} && 0%{?sle_version} <= 120200 +%global disable_python3 1 %endif + +# support for pmdajson +%if 0%{?rhel} == 0 || 0%{?rhel} > 6 +%if !%{disable_python2} || !%{disable_python3} +%global disable_json 0 +%else +%global disable_json 1 +%endif +%else +%global disable_json 1 +%endif + +# support for pmdarpm %if 0%{?rhel} == 0 || 0%{?rhel} > 5 -%define disable_qt 0 +%global disable_rpm 0 %else -%define disable_qt 1 +%global disable_rpm 1 +%endif + +# Qt development and runtime environment missing components before el6 +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 +%global disable_qt 0 +%else +%global disable_qt 1 +%endif + +# systemd services and pmdasystemd +%if 0%{?fedora} >= 19 || 0%{?rhel} >= 7 || 0%{?suse_version} +%global disable_systemd 0 +%else +%global disable_systemd 1 +%endif + +# systemtap static probing, missing before el6 and on some architectures +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 +%global disable_sdt 0 +%else +%ifnarch ppc ppc64 +%global disable_sdt 0 +%else +%global disable_sdt 1 +%endif +%endif + +%if 0%{?suse_version} && !%{disable_python3} +# SUSE doesn't currently ship the libvirt-python3 dependency +%global disable_libvirt 1 +%else +%global disable_libvirt 0 +%endif + +%if 0%{?sle_version} && 0%{?sle_version} <= 120200 +# SUSE doesn't currently ship the perl-DBD-Pg dependency +%global disable_postgresql 1 +%else +%global disable_postgresql 0 +%endif + +# rpm producing "noarch" packages +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 || 0%{?suse_version} >= 1315 +%global disable_noarch 0 +%else +%global disable_noarch 1 %endif %if 0%{?suse_version} @@ -131,6 +210,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: autoconf BuildRequires: avahi-devel BuildRequires: bison +BuildRequires: zlib-devel %if 0%{?suse_version} > 1010 BuildRequires: fdupes %endif @@ -163,12 +243,8 @@ BuildRequires: libmicrohttpd-devel %if !%{disable_cairo} BuildRequires: cairo-devel %endif -%if 0%{?rhel} == 0 || 0%{?rhel} > 5 +%if !%{disable_sdt} BuildRequires: systemtap-sdt-devel -%else -%ifnarch ppc ppc64 -BuildRequires: systemtap-sdt-devel -%endif %endif BuildRequires: perl-ExtUtils-MakeMaker %if 0%{?suse_version} @@ -177,13 +253,9 @@ BuildRequires: update-desktop-files BuildRequires: initscripts %endif BuildRequires: man -%if 0%{?has_systemd} +%if !%{disable_systemd} BuildRequires: systemd-devel %{?systemd_requires} -%else -%if 0%{?fedora} >= 18 || 0%{?rhel} >= 7 -BuildRequires: systemd-devel -%endif %endif %if !%{disable_qt} BuildRequires: desktop-file-utils @@ -193,6 +265,9 @@ BuildRequires: libqt4-devel >= 4.4 BuildRequires: qt4-devel >= 4.4 %endif %endif +%if !%{disable_selinux} +Requires: pcp-selinux = %{version}-%{release} +%endif # for set_permissions %if 0%{?suse_version} >= 1131 @@ -217,107 +292,101 @@ Requires: python-curses Requires: initscripts %endif -Requires: python -%if 0%{?rhel} <= 5 -Requires: python-ctypes -%endif - Requires: %{lib_pkg} = %{version}-%{release} Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: python Requires: python-pcp = %{version}-%{release} Obsoletes: pcp-pmda-nvidia < %{version} %global tapsetdir %{_datadir}/systemtap/tapset -%define _confdir %{_sysconfdir}/pcp -%define _logsdir %{_localstatedir}/log/pcp -%define _pmnsdir %{_localstatedir}/lib/pcp/pmns -%define _tempsdir %{_localstatedir}/lib/pcp/tmp -%define _pmdasdir %{_localstatedir}/lib/pcp/pmdas -%define _testsdir %{_localstatedir}/lib/pcp/testsuite +%global _confdir %{_sysconfdir}/pcp +%global _logsdir %{_localstatedir}/log/pcp +%global _pmnsdir %{_localstatedir}/lib/pcp/pmns +%global _tempsdir %{_localstatedir}/lib/pcp/tmp +%global _pmdasdir %{_localstatedir}/lib/pcp/pmdas +%global _testsdir %{_localstatedir}/lib/pcp/testsuite +%global _selinuxdir %{_localstatedir}/lib/pcp/selinux %if 0%{?suse_version} -%define _pixmapdir %{_datadir}/pixmaps -%define _booksdir %{_docdir}/pcp +%global _pixmapdir %{_datadir}/pixmaps +%global _booksdir %{_docdir}/pcp-doc %else -%define _pixmapdir %{_datadir}/pcp-gui/pixmaps -%define _booksdir %{_datadir}/doc/pcp-doc +%global _pixmapdir %{_datadir}/pcp-gui/pixmaps +%global _booksdir %{_datadir}/doc/pcp-doc %endif -%if 0%{?fedora} >= 20 || 0%{?suse_version} -%define _with_doc --with-docdir=%{_docdir}/%{name} +%if 0%{?fedora} >= 20 || 0%{?rhel} >= 8 || 0%{?suse_version} +# FIXME: PCP defaults to using %{_datadir}/doc/pcp-doc +%global _with_doc --with-docdir=%{_docdir}/%{name} %endif -%if 0%{?fedora} >= 19 || 0%{?rhel} >= 7 || 0%{?has_systemd} -%define _initddir %{_datadir}/pcp/lib -%define disable_systemd 0 +%if !%{disable_systemd} +%global _initddir %{_datadir}/pcp/lib %else %if 0%{?suse_version} -%define _initddir %{_sysconfdir}/init.d +%global _initddir %{_sysconfdir}/init.d %else -%define _initddir %{_sysconfdir}/rc.d/init.d +%global _initddir %{_sysconfdir}/rc.d/init.d %endif -%define _with_initd --with-rcdir=%{_initddir} -%define disable_systemd 1 +%global _with_initd --with-rcdir=%{_initddir} %endif # we never want Infiniband on s390 platforms %ifarch s390 s390x -%define disable_infiniband 1 +%global disable_infiniband 1 %else # we never want Infiniband on RHEL5 or earlier %if 0%{?rhel} != 0 && 0%{?rhel} < 6 -%define disable_infiniband 1 +%global disable_infiniband 1 %else -%define disable_infiniband 0 +%global disable_infiniband 0 %endif %endif %if %{disable_infiniband} -%define _with_ib --with-infiniband=no +%global _with_ib --with-infiniband=no %endif %if !%{disable_papi} -%define _with_papi --with-papi=yes +%global _with_papi --with-papi=yes %endif %if !%{disable_perfevent} -%define _with_perfevent --with-perfevent=yes +%global _with_perfevent --with-perfevent=yes %endif -%if %{disable_qt} -%define _with_ib --with-qt=no +%if %{disable_json} +%global _with_json --with-pmdajson=no +%else +%global _with_json --with-pmdajson=yes %endif -%if ! %{defined _rundir} -%define _rundir %{_localstatedir}/run +%if %{disable_snmp} +%global _with_snmp --with-pmdasnmp=no +%else +%global _with_snmp --with-pmdasnmp=yes %endif -%define _pmdasdir %{_localstatedir}/lib/pcp/pmdas - %description Performance Co-Pilot (PCP) provides a framework and services to support system-level performance monitoring and performance management. The PCP open source release provides a unifying abstraction for all of the interesting performance data in a system, and allows client -applications to easily retrieve and process any subset of that data. +applications to easily retrieve and process any subset of that data. # # pcp-conf # %package conf -%if 0%{?suse_version} -%else -%endif Summary: Performance Co-Pilot run-time configuration -License: %{license_lgplv2plus} -Group: Development/Libraries +License: %{license_lgplv21plus} +Group: %{lib_gr} Url: http://www.pcp.io -%if !0%{?suse_version} # http://fedoraproject.org/wiki/Packaging:Conflicts "Splitting Packages" Conflicts: pcp-libs < 3.9 -%endif + %description conf Performance Co-Pilot (PCP) run-time configuration @@ -327,21 +396,21 @@ Performance Co-Pilot (PCP) run-time configuration %package -n %{lib_pkg} Summary: Performance Co-Pilot run-time libraries -License: %{license_lgplv2plus} +License: %{license_lgplv21plus} Group: %{lib_gr} Url: http://www.pcp.io Conflicts: %{lib_pkg_conflict} -Requires: pcp-conf = %{version}-%{release} +Requires: pcp-conf >= %{version}-%{release} %description -n %{lib_pkg} Performance Co-Pilot (PCP) run-time libraries # # pcp-libs-devel -# SLE uses the legacy pcp-devel package name. +# SLE uses the legacy libpcp-devel package name. # %package -n %{lib_devel_pkg} -Summary: Performance Co-Pilot (PCP) development headers and documentation +Summary: Performance Co-Pilot (PCP) development headers License: %{license_gplv2plus} and %{license_lgplv21plus} Group: %{lib_devel_gr} Url: http://www.pcp.io @@ -353,7 +422,22 @@ Obsoletes: pcp-devel < %{version} %endif %description -n %{lib_devel_pkg} -Performance Co-Pilot (PCP) headers, documentation and tools for development. +Performance Co-Pilot (PCP) headers for development. + +# +# pcp-devel +# +%package devel +Summary: Performance Co-Pilot (PCP) development tools and documentation +License: %{license_gplv2plus} and %{license_lgplv21plus} +Group: %{lib_devel_gr} +Url: http://www.pcp.io +Requires: %{lib_devel_pkg} = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description devel +Performance Co-Pilot (PCP) documentation and tools for development. # # pcp-testsuite @@ -361,13 +445,12 @@ Performance Co-Pilot (PCP) headers, documentation and tools for development. %package testsuite Summary: Performance Co-Pilot (PCP) test suite License: %{license_gplv2plus} and %{license_mit} -Group: Development/Libraries +Group: %{lib_devel_gr} Url: http://www.pcp.io -Requires: pcp = %{version}-%{release} -%if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} -%endif Requires: %{lib_devel_pkg} = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} +Requires: pcp-devel = %{version}-%{release} Obsoletes: pcp-gui-testsuite %description testsuite @@ -381,22 +464,16 @@ Summary: Performance Co-Pilot (PCP) manager daemon License: %{license_gplv2plus} Group: %{pcp_gr} Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} Requires: pcp = %{version}-%{release} -%if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} -%endif %description manager An optional daemon (pmmgr) that manages a collection of pmlogger and pmie daemons, for a set of discovered local and remote hosts running the performance metrics collection daemon (pmcd). It ensures these daemons are running when appropriate, and manages their log rotation -needs (which are particularly complex in the case of pmlogger). -The base PCP package provides comparable functionality through cron -scripts which predate this daemon but do still provide effective and -efficient log management services. -The pcp-manager package aims to aggressively enable new PCP features -and as a result may not be suited to all production environments. +needs. It is an alternative to the cron-based pmlogger/pmie service +scripts. %if !%{disable_microhttpd} # @@ -407,11 +484,8 @@ Summary: Performance Co-Pilot (PCP) web API service License: %{license_gplv2plus} Group: %{pcp_gr} Url: http://www.pcp.io -%if 0%{?suse_version} -Requires: pcp-conf = %{version}-%{release} -%else -Requires: pcp-libs = %{version}-%{release} -%endif +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} %description webapi Provides a daemon (pmwebd) that binds a large subset of the Performance @@ -419,24 +493,6 @@ Co-Pilot (PCP) client API (PMAPI) to RESTful web applications using the HTTP (PMWEBAPI) protocol. %endif -%if !%{disable_microhttpd} -# -# pcp-webjs -# -%package webjs -%if 0%{?rhel} == 0 || 0%{?rhel} > 5 -BuildArch: noarch -%endif -Summary: Performance Co-Pilot (PCP) web applications -License: %{license_apache2} and %{license_mit} and %{license_cc_by} -Group: Applications/System -Url: http://www.pcp.io - -%description webjs -Javascript web application content for the Performance Co-Pilot (PCP) -web service. -%endif - # # perl-PCP-PMDA. This is the PCP agent perl binding. # @@ -465,7 +521,6 @@ Summary: Performance Co-Pilot (PCP) Perl bindings for PCP Memory Mapped V License: %{license_gplv2plus} Group: %{lib_devel_gr} Url: http://www.pcp.io -Requires: pcp >= %{version} %if 0%{?suse_version} %perl_requires %endif @@ -487,7 +542,6 @@ Summary: Performance Co-Pilot Perl bindings for importing external archiv License: %{license_gplv2plus} Group: %{lib_devel_gr} Url: http://www.pcp.io -Requires: pcp >= %{version} %if 0%{?suse_version} %perl_requires %endif @@ -506,7 +560,6 @@ Summary: Performance Co-Pilot Perl bindings for processing pmlogsummary o License: %{license_gplv2plus} Group: %{lib_devel_gr} Url: http://www.pcp.io -Requires: pcp >= %{version} %if 0%{?suse_version} %perl_requires %endif @@ -524,12 +577,12 @@ exporting this data into third-party tools (e.g. spreadsheets). # pcp-import-sar2pcp # %package import-sar2pcp -Summary: Performance Co-Pilot tools for importing sar data into PCP archive logs +Summary: Performance Co-Pilot archive tools for importing sar data License: %{license_lgplv2plus} Group: %{pcp_gr} Url: http://www.pcp.io %if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} %endif Requires: perl-PCP-LogImport = %{version}-%{release} Requires: sysstat @@ -542,12 +595,12 @@ into standard PCP archive logs for replay with any PCP monitoring tool. # pcp-import-iostat2pcp # %package import-iostat2pcp -Summary: Performance Co-Pilot tools for importing iostat data into PCP archive logs +Summary: Performance Co-Pilot archive tools for importing iostat data License: %{license_lgplv2plus} Group: %{pcp_gr} Url: http://www.pcp.io %if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} %endif Requires: perl-PCP-LogImport = %{version}-%{release} Requires: sysstat @@ -561,12 +614,12 @@ into standard PCP archive logs for replay with any PCP monitoring tool. # pcp-import-sheet2pcp # %package import-sheet2pcp -Summary: Performance Co-Pilot tools for importing spreadsheet data into PCP archive logs +Summary: Performance Co-Pilot archive tools for importing spreadsheet data License: %{license_lgplv2plus} Group: %{pcp_gr} Url: http://www.pcp.io %if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} %endif Requires: perl-PCP-LogImport = %{version}-%{release} Requires: sysstat @@ -581,12 +634,12 @@ into standard PCP archive logs for replay with any PCP monitoring tool. # pcp-import-mrtg2pcp # %package import-mrtg2pcp -Summary: Performance Co-Pilot tools for importing MTRG data into PCP archive logs +Summary: Performance Co-Pilot archive tools for importing MTRG data License: %{license_lgplv2plus} Group: %{pcp_gr} Url: http://www.pcp.io %if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} %endif Requires: perl-PCP-LogImport = %{version}-%{release} @@ -598,12 +651,12 @@ into standard PCP archive logs for replay with any PCP monitoring tool. # pcp-import-ganglia2pcp # %package import-ganglia2pcp -Summary: Performance Co-Pilot tools for importing ganglia data into PCP archive logs +Summary: Performance Co-Pilot archive tools for importing ganglia data License: %{license_lgplv2plus} Group: %{pcp_gr} Url: http://www.pcp.io %if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} %endif Requires: perl-PCP-LogImport = %{version}-%{release} @@ -615,18 +668,73 @@ into standard PCP archive logs for replay with any PCP monitoring tool. # pcp-import-collectl2pcp # %package import-collectl2pcp -Summary: Performance Co-Pilot tools for importing collectl log files into PCP archive logs +Summary: Performance Co-Pilot archive tools for importing collectl data License: %{license_lgplv2plus} -Group: Applications/System +Group: %{pcp_gr} Url: http://www.pcp.io -%if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} -%endif +Requires: %{lib_pkg} = %{version}-%{release} %description import-collectl2pcp Performance Co-Pilot (PCP) front-end tools for importing collectl data into standard PCP archive logs for replay with any PCP monitoring tool. +# +# pcp-export-zabbix-agent +# +%package export-zabbix-agent +Summary: Module for exporting from PCP into a Zabbix agent daemon +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} >= %{version}-%{release} + +%description export-zabbix-agent +Performance Co-Pilot (PCP) module for exporting metrics from PCP to +Zabbix via the Zabbix agent - see zbxpcp(3) for further details. + +%if !%{disable_python2} || !%{disable_python3} +# +# pcp-export-pcp2graphite +# +%package export-pcp2graphite +Summary: Performance Co-Pilot tools for exporting PCP metrics to Graphite +License: %{license_lgplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} +%endif +%if !%{disable_python3} +Requires: python3-pcp = %{version}-%{release} +%else +Requires: python-pcp = %{version}-%{release} +%endif + +%description export-pcp2graphite +Performance Co-Pilot (PCP) front-end tools for exporting metric values +to graphite (http://graphite.readthedocs.org). + +# pcp-export-pcp2influxdb +# +%package export-pcp2influxdb +Summary: Performance Co-Pilot tools for exporting PCP metrics to InfluxDB +License: %{license_lgplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} >= %{version}-%{release} +%if !%{disable_python3} +Requires: python3-pcp = %{version}-%{release} +Requires: python3-requests +%else +Requires: python-pcp = %{version}-%{release} +Requires: python-requests +%endif + +%description export-pcp2influxdb +Performance Co-Pilot (PCP) front-end tools for exporting metric values +to InfluxDB (https://influxdata.com/time-series-platform/influxdb). +%endif + %if !%{disable_papi} # # pcp-pmda-papi @@ -634,10 +742,10 @@ into standard PCP archive logs for replay with any PCP monitoring tool. %package pmda-papi Summary: Performance Co-Pilot (PCP) metrics for Performance API and hardware counters License: %{license_gplv2plus} -Group: Applications/System +Group: %{pcp_gr} Url: http://www.pcp.io %if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} %endif BuildRequires: papi-devel @@ -653,11 +761,11 @@ collecting hardware counters statistics through PAPI (Performance API). %package pmda-perfevent Summary: Performance Co-Pilot (PCP) metrics for hardware counters License: %{license_gplv2plus} -Group: Applications/System +Group: %{pcp_gr} Url: http://www.pcp.io %if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} Requires: libpfm >= 4.4 -Requires: pcp-libs = %{version}-%{release} %endif BuildRequires: libpfm-devel >= 4.4 @@ -673,12 +781,12 @@ collecting hardware counters statistics through libpfm. %package pmda-infiniband Summary: Performance Co-Pilot (PCP) metrics for Infiniband HCAs and switches License: %{license_gplv2plus} -Group: Applications/System +Group: %{pcp_gr} Url: http://www.pcp.io %if !0%{?suse_version} +Requires: %{lib_pkg} = %{version}-%{release} Requires: libibmad >= 1.3.7 Requires: libibumad >= 1.3.7 -Requires: pcp-libs = %{version}-%{release} %endif BuildRequires: libibmad-devel >= 1.3.7 BuildRequires: libibumad-devel >= 1.3.7 @@ -689,6 +797,986 @@ collecting Infiniband statistics. By default, it monitors the local HCAs but can also be configured to monitor remote GUIDs such as IB switches. %endif +# +# pcp-pmda-activemq +# +%package pmda-activemq +Summary: Performance Co-Pilot (PCP) metrics for ActiveMQ +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(LWP::UserAgent) + +%description pmda-activemq +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the ActiveMQ message broker. +#end pcp-pmda-activemq + +# +# pcp-pmda-bind2 +# +%package pmda-bind2 +Summary: Performance Co-Pilot (PCP) metrics for BIND servers +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(File::Slurp) +Requires: perl(LWP::UserAgent) +Requires: perl(XML::LibXML) + +%description pmda-bind2 +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from BIND (Berkeley Internet Name Domain). +#end pcp-pmda-bind2 + +# +# pcp-pmda-redis +# +%package pmda-redis +Summary: Performance Co-Pilot (PCP) metrics for Redis +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-redis +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from Redis servers (redis.io). +#end pcp-pmda-redis + +# +# pcp-pmda-nutcracker +# +%package pmda-nutcracker +Summary: Performance Co-Pilot (PCP) metrics for NutCracker (TwemCache) +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(JSON) +Requires: perl(YAML::XS::LibYAML) + +%description pmda-nutcracker +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from NutCracker (TwemCache). +#end pcp-pmda-nutcracker + +# +# pcp-pmda-bonding +# +%package pmda-bonding +Summary: Performance Co-Pilot (PCP) metrics for Bonded network interfaces +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-bonding +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about bonded network interfaces. +#end pcp-pmda-bonding + +# +# pcp-pmda-dbping +# +%package pmda-dbping +Summary: Performance Co-Pilot (PCP) metrics for Database response times and Availablility +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-dbping +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Database response times and Availablility. +#end pcp-pmda-dbping + +# +# pcp-pmda-ds389 +# +%package pmda-ds389 +Summary: Performance Co-Pilot (PCP) metrics for 389 Directory Servers +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-LDAP +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-ds389 +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about a 389 Directory Server. +#end pcp-pmda-ds389 + +# +# pcp-pmda-ds389log +# +%package pmda-ds389log +Summary: Performance Co-Pilot (PCP) metrics for 389 Directory Server Loggers +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-Date-Manip +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-ds389log +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from a 389 Directory Server log. +#end pcp-pmda-ds389log + +# +# pcp-pmda-elasticsearch +# +%package pmda-elasticsearch +Summary: Performance Co-Pilot (PCP) metrics for Elasticsearch +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(LWP::UserAgent) +BuildRequires: perl(LWP::UserAgent) + +%description pmda-elasticsearch +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Elasticsearch. +#end pcp-pmda-elasticsearch + +# +# pcp-pmda-gpfs +# +%package pmda-gpfs +Summary: Performance Co-Pilot (PCP) metrics for GPFS Filesystem +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-gpfs +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the GPFS filesystem. +#end pcp-pmda-gpfs + +# +# pcp-pmda-gpsd +# +%package pmda-gpsd +Summary: Performance Co-Pilot (PCP) metrics for a GPS Daemon +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-gpsd +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about a GPS Daemon. +#end pcp-pmda-gpsd + +# +# pcp-pmda-kvm +# +%package pmda-kvm +Summary: Performance Co-Pilot (PCP) metrics for KVM +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-kvm +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Kernel based Virtual Machine. +#end pcp-pmda-kvm + +# +# pcp-pmda-docker +# +%package pmda-docker +Summary: Performance Co-Pilot (PCP) metrics from the Docker daemon +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io + +%description pmda-docker +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics using the Docker daemon REST API. +#end pcp-pmda-docker + +# +# pcp-pmda-lustre +# +%package pmda-lustre +Summary: Performance Co-Pilot (PCP) metrics for the Lustre Filesytem +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-lustre +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Lustre Filesystem. +#end pcp-pmda-lustre + +# +# pcp-pmda-lustrecomm +# +%package pmda-lustrecomm +Summary: Performance Co-Pilot (PCP) metrics for the Lustre Filesytem Comms +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-lustrecomm +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Lustre Filesystem Comms. +#end pcp-pmda-lustrecomm + +# +# pcp-pmda-memcache +# +%package pmda-memcache +Summary: Performance Co-Pilot (PCP) metrics for Memcached +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-memcache +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Memcached. +#end pcp-pmda-memcache + +# +# pcp-pmda-mysql +# +%package pmda-mysql +Summary: Performance Co-Pilot (PCP) metrics for MySQL +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(DBD::mysql) +Requires: perl(DBI) +BuildRequires: perl(DBD::mysql) +BuildRequires: perl(DBI) + +%description pmda-mysql +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the MySQL database. +#end pcp-pmda-mysql + +# +# pcp-pmda-named +# +%package pmda-named +Summary: Performance Co-Pilot (PCP) metrics for Named +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-named +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Named nameserver. +#end pcp-pmda-named + +# pcp-pmda-netfilter +# +%package pmda-netfilter +Summary: Performance Co-Pilot (PCP) metrics for Netfilter framework +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-netfilter +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Netfilter packet filtering framework. +#end pcp-pmda-netfilter + +# +# pcp-pmda-news +# +%package pmda-news +Summary: Performance Co-Pilot (PCP) metrics for Usenet News +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-news +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Usenet News. +#end pcp-pmda-news + +# +# pcp-pmda-nginx +# +%package pmda-nginx +Summary: Performance Co-Pilot (PCP) metrics for the Nginx Webserver +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(LWP::UserAgent) +BuildRequires: perl(LWP::UserAgent) + +%description pmda-nginx +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Nginx Webserver. +#end pcp-pmda-nginx + +# +# pcp-pmda-nfsclient +# +%package pmda-nfsclient +Summary: Performance Co-Pilot (PCP) metrics for NFS Clients +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-nfsclient +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics for NFS Clients. +#end pcp-pmda-nfsclient + +# +# pcp-pmda-oracle +# +%package pmda-oracle +Summary: Performance Co-Pilot (PCP) metrics for the Oracle database +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(DBI) +BuildRequires: perl(DBI) + +%description pmda-oracle +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Oracle database. +#end pcp-pmda-oracle + +# +# pcp-pmda-pdns +# +%package pmda-pdns +Summary: Performance Co-Pilot (PCP) metrics for PowerDNS +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-pdns +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the PowerDNS. +#end pcp-pmda-pdns + +# +# pcp-pmda-postfix +# +%package pmda-postfix +Summary: Performance Co-Pilot (PCP) metrics for the Postfix (MTA) +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +%if 0%{?fedora} > 16 || 0%{?rhel} > 5 +Requires: postfix-perl-scripts +BuildRequires: postfix-perl-scripts +%endif +%if 0%{?rhel} <= 5 +Requires: postfix +BuildRequires: postfix +%endif +%if "%{_vendor}" == "suse" +Requires: postfix-doc +BuildRequires: postfix-doc +%endif + +%description pmda-postfix +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Postfix (MTA). +#end pcp-pmda-postfix + +%if !%{disable_postgresql} +# +# pcp-pmda-postgresql +# +%package pmda-postgresql +Summary: Performance Co-Pilot (PCP) metrics for PostgreSQL +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +Requires: perl(DBD::Pg) +Requires: perl(DBI) +BuildRequires: perl(DBD::Pg) +BuildRequires: perl(DBI) + +%description pmda-postgresql +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the PostgreSQL database. +#end pcp-pmda-postgresql +%endif + +# +# pcp-pmda-rsyslog +# +%package pmda-rsyslog +Summary: Performance Co-Pilot (PCP) metrics for Rsyslog +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-rsyslog +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Rsyslog. +#end pcp-pmda-rsyslog + +# +# pcp-pmda-samba +# +%package pmda-samba +Summary: Performance Co-Pilot (PCP) metrics for Samba +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-samba +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Samba. +#end pcp-pmda-samba + +# +# pcp-pmda-slurm +# +%package pmda-slurm +Summary: Performance Co-Pilot (PCP) metrics for NFS Clients +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-slurm +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from the SLURM Workload Manager. +#end pcp-pmda-slurm + +%if !%{disable_snmp} +# +# pcp-pmda-snmp +# +%package pmda-snmp +Summary: Performance Co-Pilot (PCP) metrics for Simple Network Management Protocol +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} +# There are no perl-Net-SNMP packages in rhel, disable unless non-rhel or epel5 +%if 0%{?rhel} == 0 || 0%{?rhel} < 6 +Requires: perl(Net::SNMP) +%endif + +%description pmda-snmp +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about SNMP. +#end pcp-pmda-snmp +%endif + +# +# pcp-pmda-vmware +# +%package pmda-vmware +Summary: Performance Co-Pilot (PCP) metrics for VMware +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-vmware +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics for VMware. +#end pcp-pmda-vmware + +# +# pcp-pmda-zimbra +# +%package pmda-zimbra +Summary: Performance Co-Pilot (PCP) metrics for Zimbra +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: perl-PCP-PMDA = %{version}-%{release} + +%description pmda-zimbra +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Zimbra. +#end pcp-pmda-zimbra + +# +# pcp-pmda-dm +# +%package pmda-dm +Summary: Performance Co-Pilot (PCP) metrics for the Device Mapper Cache and Thin Client +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-dm +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Device Mapper Cache and Thin Client. +# end pcp-pmda-dm + + +%if !%{disable_python2} || !%{disable_python3} +# +# pcp-pmda-gluster +# +%package pmda-gluster +Summary: Performance Co-Pilot (PCP) metrics for the Gluster filesystem +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +%else +Requires: python-pcp +%endif +%description pmda-gluster +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the gluster filesystem. +# end pcp-pmda-gluster + +# +# pcp-pmda-zswap +# +%package pmda-zswap +Summary: Performance Co-Pilot (PCP) metrics for compressed swap +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +%else +Requires: python-pcp +%endif +%description pmda-zswap +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about compressed swap. +# end pcp-pmda-zswap + +# +# pcp-pmda-unbound +# +%package pmda-unbound +Summary: Performance Co-Pilot (PCP) metrics for the Unbound DNS Resolver +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +%else +Requires: python-pcp +%endif +%description pmda-unbound +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Unbound DNS Resolver. +# end pcp-pmda-unbound + +# +# pcp-pmda-mic +# +%package pmda-mic +Summary: Performance Co-Pilot (PCP) metrics for Intel MIC cards +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +%else +Requires: python-pcp +%endif +%description pmda-mic +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Intel MIC cards. +# end pcp-pmda-mic + +%if !%{disable_libvirt} +# +# pcp-pmda-libvirt +# +%package pmda-libvirt +Summary: Performance Co-Pilot (PCP) metrics for virtual machines +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: libvirt-python3 +Requires: python3-lxml +Requires: python3-pcp +BuildRequires: libvirt-python3 +%else +Requires: libvirt-python +Requires: python-lxml +Requires: python-pcp +%if 0%{?rhel} == 0 || 0%{?rhel} > 5 +BuildRequires: libvirt-python +%endif +%endif +%description pmda-libvirt +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +extracting virtualisation statistics from libvirt about behaviour of guest +and hypervisor machines. +# end pcp-pmda-libvirt +%endif + +# +# pcp-pmda-lio +# +%package pmda-lio +Summary: Performance Co-Pilot (PCP) metrics for the LIO subsystem +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +Requires: python3-rtslib +%else +Requires: python-pcp +Requires: python-rtslib +%endif +%description pmda-lio +This package provides a PMDA to gather performance metrics from the kernels +iSCSI target interface (LIO). The metrics are stored by LIO within the Linux +kernels configfs filesystem. The PMDA provides per LUN level stats, and a +summary instance per iSCSI target, which aggregates all LUN metrics within the +target. +#end pcp-pmda-lio + +%endif # !%{disable_python2} || !%{disable_python3} + +%if !%{disable_json} +# +# pcp-pmda-json +# +%package pmda-json +Summary: Performance Co-Pilot (PCP) metrics for JSON data +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp +Requires: python3-six +BuildRequires: python3-six +%if 0%{?suse_version} +Requires: python-jsonpointer +BuildRequires: python-jsonpointer +%else +Requires: python3-jsonpointer +BuildRequires: python3-jsonpointer +%endif +%else +Requires: python-jsonpointer +Requires: python-pcp +Requires: python-six +BuildRequires: python-jsonpointer +BuildRequires: python-six +%endif +%description pmda-json +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics output in JSON. +# end pcp-pmda-json +%endif # !%{disable_json} + +# +# C pmdas +# pcp-pmda-apache +# +%package pmda-apache +Summary: Performance Co-Pilot (PCP) metrics for the Apache webserver +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-apache +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Apache webserver. +# end pcp-pmda-apache + +# +# pcp-pmda-bash +# +%package pmda-bash +Summary: Performance Co-Pilot (PCP) metrics for the Bash shell +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-bash +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Bash shell. +# end pcp-pmda-bash + +# +# pcp-pmda-cifs +# +%package pmda-cifs +Summary: Performance Co-Pilot (PCP) metrics for the CIFS protocol +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-cifs +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Common Internet Filesytem. +# end pcp-pmda-cifs + +# +# pcp-pmda-cisco +# +%package pmda-cisco +Summary: Performance Co-Pilot (PCP) metrics for Cisco routers +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-cisco +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Cisco routers. +# end pcp-pmda-cisco + +# +# pcp-pmda-gfs2 +# +%package pmda-gfs2 +Summary: Performance Co-Pilot (PCP) metrics for the GFS2 filesystem +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-gfs2 +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Global Filesystem v2. +# end pcp-pmda-gfs2 + +# +# pcp-pmda-lmsensors +# +%package pmda-lmsensors +Summary: Performance Co-Pilot (PCP) metrics for hardware sensors +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-lmsensors +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the Linux hardware monitoring sensors. +# end pcp-pmda-lmsensors + +# +# pcp-pmda-logger +# +%package pmda-logger +Summary: Performance Co-Pilot (PCP) metrics from arbitrary log files +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-logger +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from a specified set of log files (or pipes). The PMDA +supports both sampled and event-style metrics. +# end pcp-pmda-logger + +# +# pcp-pmda-mailq +# +%package pmda-mailq +Summary: Performance Co-Pilot (PCP) metrics for the sendmail queue +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-mailq +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about email queues managed by sendmail. +# end pcp-pmda-mailq + +# +# pcp-pmda-mounts +# +%package pmda-mounts +Summary: Performance Co-Pilot (PCP) metrics for filesystem mounts +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-mounts +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about filesystem mounts. +# end pcp-pmda-mounts + +# +# pcp-pmda-nvidia-gpu +# +%package pmda-nvidia-gpu +Summary: Performance Co-Pilot (PCP) metrics for the Nvidia GPU +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-nvidia-gpu +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Nvidia GPUs. +# end pcp-pmda-nvidia-gpu + +# +# pcp-pmda-roomtemp +# +%package pmda-roomtemp +Summary: Performance Co-Pilot (PCP) metrics for the room temperature +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-roomtemp +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the room temperature. +# end pcp-pmda-roomtemp + +%if !%{disable_rpm} +# +# pcp-pmda-rpm +# +%package pmda-rpm +Summary: Performance Co-Pilot (PCP) metrics for the RPM package manager +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-rpm +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about the installed RPM packages. +%endif +# end pcp-pmda-rpm + +# +# pcp-pmda-sendmail +# +%package pmda-sendmail +Summary: Performance Co-Pilot (PCP) metrics for Sendmail +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-sendmail +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about Sendmail traffic. +# end pcp-pmda-sendmail + +# +# pcp-pmda-shping +# +%package pmda-shping +Summary: Performance Co-Pilot (PCP) metrics for shell command responses +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-shping +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about quality of service and response time measurements of +arbitrary shell commands. +# end pcp-pmda-shping + +# +# pcp-pmda-summary +# +%package pmda-summary +Summary: Performance Co-Pilot (PCP) summary metrics from pmie +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-summary +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about other installed pmdas. +# end pcp-pmda-summary + +%if !%{disable_systemd} +# +# pcp-pmda-systemd +# +%package pmda-systemd +Summary: Performance Co-Pilot (PCP) metrics from the Systemd journal +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-systemd +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics from the Systemd journal. +# end pcp-pmda-systemd +%endif + +# +# pcp-pmda-trace +# +%package pmda-trace +Summary: Performance Co-Pilot (PCP) metrics for application tracing +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} + +%description pmda-trace +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about trace performance data in applications. +# end pcp-pmda-trace + +# +# pcp-pmda-weblog +# +%package pmda-weblog +Summary: Performance Co-Pilot (PCP) metrics from web server logs +License: %{license_gplv2plus} +Group: %{pcp_gr} +Url: http://www.pcp.io +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} + +%description pmda-weblog +This package contains the PCP Performance Metrics Domain Agent (PMDA) for +collecting metrics about web server logs. +# end pcp-pmda-weblog +# end C pmdas + # # python-pcp. This is the PCP library bindings for python. # @@ -697,8 +1785,12 @@ Summary: Performance Co-Pilot (PCP) Python bindings and documentation License: %{license_gplv2plus} Group: Development/Libraries Url: http://www.pcp.io -%if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp = %{version}-%{release} +%if 0%{?rhel} == 5 +Requires: python%{default_python} +%else +Requires: python %endif %description -n python-pcp @@ -716,8 +1808,9 @@ License: %{license_gplv2plus} Group: Development/Libraries Url: http://www.pcp.io %if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} %endif +Requires: python3 %description -n python3-pcp This python PCP module contains the language bindings for @@ -725,20 +1818,42 @@ Performance Metric API (PMAPI) monitor tools and Performance Metric Domain Agent (PMDA) collector tools written in Python3. %endif +%if !%{disable_python2} || !%{disable_python3} +# +# pcp-system-tools +# +%package system-tools +Summary: Performance Co-Pilot (PCP) System and Monitoring Tools +License: %{license_gplv2plus} +Group: Development/Libraries +Url: http://www.pcp.io +%if !%{disable_python3} +Requires: python3-pcp = %{version}-%{release} +%endif +%if !%{disable_python2} +Requires: python-pcp = %{version}-%{release} +%endif +Requires: %{lib_pkg} = %{version}-%{release} +Requires: pcp-libs = %{version}-%{release} + +%description system-tools +This PCP module contains additional system monitoring tools written +in python. +%endif #end pcp-system-tools %if !%{disable_qt} # # pcp-gui package for Qt tools # -%package -n pcp-gui +%package gui Summary: Visualization tools for the Performance Co-Pilot toolkit License: %{license_gplv2plus} and %{license_lgplv2plus} Group: Applications/System Url: http://www.pcp.io %if !0%{?suse_version} -Requires: pcp-libs = %{version}-%{release} +Requires: %{lib_pkg} = %{version}-%{release} %endif -%description -n pcp-gui +%description gui Visualization tools for the Performance Co-Pilot toolkit. The pcp-gui package primarily includes visualization tools for monitoring systems using live and archived Performance Co-Pilot @@ -748,16 +1863,20 @@ monitoring systems using live and archived Performance Co-Pilot # # pcp-doc package # -%package -n pcp-doc -%if 0%{?rhel} == 0 || 0%{?rhel} > 5 +%package doc +%if !%{disable_noarch} BuildArch: noarch %endif Summary: Documentation and tutorial for the Performance Co-Pilot License: %{license_gplv2plus} and %{license_cc_by} Group: Documentation Url: http://www.pcp.io +# http://fedoraproject.org/wiki/Packaging:Conflicts "Splitting Packages" +# (all man pages migrated to pcp-doc during great package split of '15) +Conflicts: pcp-pmda-pmda < 3.10.5 +Conflicts: pcp-pmda-infiniband < 3.10.5 -%description -n pcp-doc +%description doc Documentation and tutorial for the Performance Co-Pilot Performance Co-Pilot (PCP) provides a framework and services to support system-level performance monitoring and performance management. @@ -768,12 +1887,27 @@ level performance management. It includes tutorials, HOWTOs, and other detailed documentation about the internals of core PCP utilities and daemons, and the PCP graphical tools. -############################################################################### +# +# pcp-selinux package +# +%if !%{disable_selinux} +%package selinux +Summary: Selinux policy package +License: %{license_gplv2plus} and %{license_cc_by} +Group: Applications/System +Url: http://www.pcp.io +BuildRequires: selinux-policy-devel +Requires: pcp = %{version}-%{release} +Requires: policycoreutils + +%description selinux +This package contains SELinux support for PCP. The package contains +interface rules, type enforcement and file context adjustments for an +updated policy package. +%endif %prep %setup -q -%setup -q -T -D -a 1 -%patch1 -p1 %patch2 -p1 %patch3 -p1 %patch5 -p1 @@ -797,7 +1931,8 @@ PCP_CFLAGS="$RPM_OPT_FLAGS" CFLAGS="$RPM_OPT_FLAGS" CCFLAGS="$RPM_OPT_FLAGS" CXX %{?_with_ib} \ %{?_with_papi} \ %{?_with_perfevent} \ - %{?_with_qt} + %{?_with_json} \ + %{?_with_snmp} PCP_CFLAGS="$RPM_OPT_FLAGS" CFLAGS="$RPM_OPT_FLAGS" CCFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" make default_pcp ############################################################################### @@ -813,11 +1948,20 @@ rm -f $RPM_BUILD_ROOT/%{_libdir}/*.a %if %{disable_sheet2pcp} # remove sheet2pcp until BZ 830923 and BZ 754678 are resolved. -rm -f $RPM_BUILD_ROOT/%{_bindir}/sheet2pcp $RPM_BUILD_ROOT/%{_mandir}/man1/sheet2pcp.1.gz +rm -f $RPM_BUILD_ROOT/%{_bindir}/sheet2pcp $RPM_BUILD_ROOT/%{_mandir}/man1/sheet2pcp.1* %endif -# remove configsz.h as this is not multilib friendly. +%if %{disable_libvirt} +rm -fr $RPM_BUILD_ROOT/%{_pmdasdir}/libvirt +%endif + +%if %{disable_postgresql} +rm -fr $RPM_BUILD_ROOT/%{_pmdasdir}/postgresql +%endif + +# remove {config,platform}sz.h as these are not multilib friendly. rm -f $RPM_BUILD_ROOT/%{_includedir}/pcp/configsz.h +rm -f $RPM_BUILD_ROOT/%{_includedir}/pcp/platformsz.h %if %{disable_microhttpd} rm -f $RPM_BUILD_ROOT/%{_mandir}/man1/pmwebd.* @@ -826,24 +1970,27 @@ rm -fr $RPM_BUILD_ROOT/%{_confdir}/pmwebd rm -fr $RPM_BUILD_ROOT/%{_initddir}/pmwebd rm -fr $RPM_BUILD_ROOT/%{_unitdir}/pmwebd.service rm -f $RPM_BUILD_ROOT/%{_libexecdir}/pcp/bin/pmwebd -%else -mkdir -p $RPM_BUILD_ROOT/%{_datadir}/pcp/webapps -mv pcp-webjs/* $RPM_BUILD_ROOT/%{_datadir}/pcp/webapps -rmdir pcp-webjs %endif %if %{disable_infiniband} # remove pmdainfiniband on platforms lacking IB devel packages. rm -f $RPM_BUILD_ROOT/%{_pmdasdir}/ib -rm -f $RPM_BUILD_ROOT/%{_mandir}/man1/pmdaib.1.gz rm -fr $RPM_BUILD_ROOT/%{_pmdasdir}/infiniband %endif +%if %{disable_selinux} +rm -fr $RPM_BUILD_ROOT/%{_selinuxdir} +%endif + %if %{disable_qt} %if !0%{?suse_version} rm -fr $RPM_BUILD_ROOT/%{_pixmapdir} %endif rm -fr $RPM_BUILD_ROOT/%{_confdir}/pmsnap +rm -fr $RPM_BUILD_ROOT/%{_localstatedir}/lib/pcp/config/pmsnap +rm -fr $RPM_BUILD_ROOT/%{_localstatedir}/lib/pcp/config/pmchart +rm -f $RPM_BUILD_ROOT/%{_localstatedir}/lib/pcp/config/pmafm/pcp-gui +rm -f $RPM_BUILD_ROOT/%{_datadir}/applications/pmchart.desktop rm -f `find $RPM_BUILD_ROOT/%{_mandir}/man1 | grep -E "$PCP_GUI"` %else rm -rf $RPM_BUILD_ROOT/usr/share/doc/pcp-gui @@ -858,16 +2005,8 @@ desktop-file-validate $RPM_BUILD_ROOT/%{_datadir}/applications/pmchart.desktop %endif %if 0%{?suse_version} -mkdir -p $RPM_BUILD_ROOT/%{_rundir}/pcp mkdir -p $RPM_BUILD_ROOT/%{_tempsdir} -# move sample code to doc dir -mv $RPM_BUILD_ROOT/%{_pmdasdir}/sample $RPM_BUILD_ROOT/%{_docdir}/%{name} -mv $RPM_BUILD_ROOT/%{_pmdasdir}/simple $RPM_BUILD_ROOT/%{_docdir}/%{name} -mv $RPM_BUILD_ROOT/%{_pmdasdir}/trivial $RPM_BUILD_ROOT/%{_docdir}/%{name} -mv $RPM_BUILD_ROOT/%{_pmdasdir}/txmon $RPM_BUILD_ROOT/%{_docdir}/%{name} -mv $RPM_BUILD_ROOT/%{_datadir}/%{name}/examples $RPM_BUILD_ROOT/%{_docdir}/%{name} - %__install -d -m 0755 ${RPM_BUILD_ROOT}/%{_sbindir} %if !0%{?has_systemd} @@ -885,52 +2024,147 @@ ln -sf /sbin/service $RPM_BUILD_ROOT/%{_sbindir}/rcpmmgr ln -sf /sbin/service $RPM_BUILD_ROOT/%{_sbindir}/rcpmwebd %endif +# SUSE requires use of %fillup_and_insserv +mkdir -p $RPM_BUILD_ROOT/%{_localstatedir}/adm/fillup-templates +mv $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/pmlogger \ + $RPM_BUILD_ROOT/%{_localstatedir}/adm/fillup-templates/sysconfig.pmlogger +mv $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/pmproxy \ + $RPM_BUILD_ROOT/%{_localstatedir}/adm/fillup-templates/sysconfig.pmproxy +mv $RPM_BUILD_ROOT/%{_sysconfdir}/sysconfig/pmcd \ + $RPM_BUILD_ROOT/%{_localstatedir}/adm/fillup-templates/sysconfig.pmcd + %else # default chkconfig off for Fedora and RHEL -for f in $RPM_BUILD_ROOT/%{_sysconfdir}/rc.d/init.d/{pcp,pmie,pmproxy}; do +for f in $RPM_BUILD_ROOT/%{_initddir}/{pcp,pmcd,pmlogger,pmie,pmwebd,pmmgr,pmproxy}; do + test -f "$f" || continue sed -i -e '/^# chkconfig/s/:.*$/: - 95 05/' -e '/^# Default-Start:/s/:.*$/:/' $f done %endif # list of PMDAs in the base pkg ls -1 $RPM_BUILD_ROOT/%{_pmdasdir} |\ - grep -E -v 'simple|sample|trivial|txmon' |\ - grep -E -v 'perfevent|perfalloc.1' |\ - grep -E -v '^ib$|infiniband' |\ - grep -E -v 'papi' |\ + grep -E -v '^simple|sample|trivial|txmon' |\ + grep -E -v '^perfevent|perfalloc.1' |\ + grep -E -v '^ib$|^infiniband' |\ + grep -E -v '^activemq' |\ + grep -E -v '^bonding' |\ + grep -E -v '^bind2' |\ + grep -E -v '^dbping' |\ + grep -E -v '^docker' |\ + grep -E -v '^ds389log'|\ + grep -E -v '^ds389' |\ + grep -E -v '^elasticsearch' |\ + grep -E -v '^gpfs' |\ + grep -E -v '^gpsd' |\ + grep -E -v '^kvm' |\ + grep -E -v '^lio' |\ + grep -E -v '^lustre' |\ + grep -E -v '^lustrecomm' |\ + grep -E -v '^memcache' |\ + grep -E -v '^mysql' |\ + grep -E -v '^named' |\ + grep -E -v '^netfilter' |\ + grep -E -v '^news' |\ + grep -E -v '^nfsclient' |\ + grep -E -v '^nginx' |\ + grep -E -v '^nutcracker' |\ + grep -E -v '^oracle' |\ + grep -E -v '^papi' |\ + grep -E -v '^pdns' |\ + grep -E -v '^postfix' |\ + grep -E -v '^postgresql' |\ + grep -E -v '^redis' |\ + grep -E -v '^rsyslog' |\ + grep -E -v '^samba' |\ + grep -E -v '^slurm' |\ + grep -E -v '^snmp' |\ + grep -E -v '^vmware' |\ + grep -E -v '^zimbra' |\ + grep -E -v '^dm' |\ + grep -E -v '^apache' |\ + grep -E -v '^bash' |\ + grep -E -v '^cifs' |\ + grep -E -v '^cisco' |\ + grep -E -v '^gfs2' |\ + grep -E -v '^libvirt' |\ + grep -E -v '^lmsensors' |\ + grep -E -v '^logger' |\ + grep -E -v '^mailq' |\ + grep -E -v '^mounts' |\ + grep -E -v '^nvidia' |\ + grep -E -v '^roomtemp' |\ + grep -E -v '^sendmail' |\ + grep -E -v '^shping' |\ + grep -E -v '^summary' |\ + grep -E -v '^trace' |\ + grep -E -v '^weblog' |\ + grep -E -v '^rpm' |\ + grep -E -v '^json' |\ + grep -E -v '^mic' |\ + grep -E -v '^gluster' |\ + grep -E -v '^zswap' |\ + grep -E -v '^unbound' |\ sed -e 's#^#'%{_pmdasdir}'\/#' >base_pmdas.list # all base pcp package files except those split out into sub packages ls -1 $RPM_BUILD_ROOT/%{_bindir} |\ - sed -e 's#^#'%{_bindir}'\/#' >base_bin.list + grep -E -v 'pmiostat|pmcollectl|pmatop|zabbix|zbxpcp' |\ + grep -E -v 'pmrep|pcp2graphite|pcp2influxdb' |\ + grep -E -v 'pmdbg|pmclient|pmerr|genpmda' |\ +sed -e 's#^#'%{_bindir}'\/#' >base_bin.list +# +# Separate the pcp-system-tools package files. +# +# pmatop, pmcollectl and pmiostat are back-compat symlinks to their +# pcp(1) sub-command variants so must also be in pcp-system-tools. +%if !%{disable_python2} || !%{disable_python3} +ls -1 $RPM_BUILD_ROOT/%{_bindir} |\ + grep -E 'pmiostat|pmcollectl|pmatop|pmrep' |\ + sed -e 's#^#'%{_bindir}'\/#' >pcp_system_tools.list ls -1 $RPM_BUILD_ROOT/%{_libexecdir}/pcp/bin |\ + grep -E 'atop|collectl|dmcache|free|iostat|mpstat|numastat|pidstat|verify|uptime|shping' |\ + sed -e 's#^#'%{_libexecdir}/pcp/bin'\/#' >>pcp_system_tools.list +%endif + +ls -1 $RPM_BUILD_ROOT/%{_libexecdir}/pcp/bin |\ +%if !%{disable_python2} || !%{disable_python3} + grep -E -v 'atop|collectl|dmcache|free|iostat|mpstat|numastat|pidstat|verify|uptime|shping' |\ +%endif sed -e 's#^#'%{_libexecdir}/pcp/bin'\/#' >base_exec.list -ls -1 $RPM_BUILD_ROOT/%{_mandir}/man1 |\ - sed -e 's#^#'%{_mandir}'\/man1\/#' >base_man.list ls -1 $RPM_BUILD_ROOT/%{_booksdir} |\ sed -e 's#^#'%{_booksdir}'\/#' > pcp-doc.list +ls -1 $RPM_BUILD_ROOT/%{_mandir}/man1 |\ + sed -e 's#^#'%{_mandir}'\/man1\/#' >>pcp-doc.list +ls -1 $RPM_BUILD_ROOT/%{_mandir}/man5 |\ + sed -e 's#^#'%{_mandir}'\/man5\/#' >>pcp-doc.list %if 0%{?suse_version} mv $RPM_BUILD_ROOT/%{_datadir}/pcp/demos $RPM_BUILD_ROOT/%{_docdir}/pcp ls -1 $RPM_BUILD_ROOT/%{_docdir}/pcp/demos/tutorials |\ sed -e 's#^#'%{_docdir}/pcp/demos/tutorials'\/#' >>pcp-doc.list +find $RPM_BUILD_ROOT/%{_datadir}/doc/pcp-doc |\ + sed -e "s#^$RPM_BUILD_ROOT#/#" >>pcp-doc.list %else ls -1 $RPM_BUILD_ROOT/%{_datadir}/pcp/demos/tutorials |\ sed -e 's#^#'%{_datadir}/pcp/demos/tutorials'\/#' >>pcp-doc.list %endif +%if !%{disable_selinux} +ls -1 $RPM_BUILD_ROOT/%{_selinuxdir} |\ + sed -e 's#^#'%{_selinuxdir}'\/#' > pcp-selinux.list +%endif %if !%{disable_qt} ls -1 $RPM_BUILD_ROOT/%{_pixmapdir} |\ sed -e 's#^#'%{_pixmapdir}'\/#' > pcp-gui.list -cat base_bin.list base_exec.list base_man.list |\ +cat base_bin.list base_exec.list |\ grep -E "$PCP_GUI" >> pcp-gui.list %endif -cat base_pmdas.list base_bin.list base_exec.list base_man.list |\ - grep -E -v 'pmdaib|pmmgr|pmweb|pmsnap|2pcp' |\ - grep -E -v "$PCP_GUI|pixmaps|doc|tutorials" |\ +cat base_pmdas.list base_bin.list base_exec.list |\ + grep -E -v 'pmdaib|pmmgr|pmweb|pmsnap|2pcp|pmdas/systemd' |\ + grep -E -v "$PCP_GUI|pixmaps|pcp-doc|tutorials|selinux" |\ grep -E -v %{_confdir} | grep -E -v %{_logsdir} > base.list # all devel pcp package files except those split out into sub packages ls -1 $RPM_BUILD_ROOT/%{_mandir}/man3 |\ -sed -e 's#^#'%{_mandir}'\/man3\/#' | grep -E -v '3pm|PMWEBAPI' >devel.list +sed -e 's#^#'%{_mandir}'\/man3\/#' | grep -v '3pm' >>pcp-doc.list %if 0%{?suse_version} ls -1 $RPM_BUILD_ROOT/%{_docdir}/pcp/demos |\ sed -e 's#^#'%{_docdir}'\/pcp\/demos\/#' | grep -E -v tutorials >> devel.list @@ -938,16 +2172,9 @@ sed -e 's#^#'%{_docdir}'\/pcp\/demos\/#' | grep -E -v tutorials >> devel.list ls -1 $RPM_BUILD_ROOT/%{_datadir}/pcp/demos |\ sed -e 's#^#'%{_datadir}'\/pcp\/demos\/#' | grep -E -v tutorials >> devel.list %endif - -%if 0%{?suse_version} -mv $RPM_BUILD_ROOT/%{_datadir}/doc/pcp-doc/* $RPM_BUILD_ROOT/%{_booksdir} -rm -rf $RPM_BUILD_ROOT/%{_datadir}/doc/pcp-doc -%if 0%{?suse_version} > 1010 -%fdupes %{buildroot} -%endif -%endif - -############################################################################### +ls -1 $RPM_BUILD_ROOT/%{_bindir} |\ +grep -E 'pmdbg|pmclient|pmerr|genpmda' |\ +sed -e 's#^#'%{_bindir}'\/#' >>devel.list %pre testsuite test -d %{_testsdir} || mkdir -p -m 755 %{_testsdir} @@ -966,6 +2193,7 @@ getent group pcp >/dev/null || groupadd -r pcp getent passwd pcp >/dev/null || \ useradd -c "Performance Co-Pilot" -g pcp -d %{_localstatedir}/lib/pcp -M -r -s /sbin/nologin pcp %if !0%{?suse_version} +PCP_CONFIG_DIR=%{_localstatedir}/lib/pcp/config PCP_SYSCONF_DIR=%{_confdir} PCP_LOG_DIR=%{_logsdir} PCP_ETC_DIR=%{_sysconfdir} @@ -985,9 +2213,10 @@ save_configs_script() [ "$_dir" = "$_new" ] && continue if [ -d "$_dir" ] then - ( cd "$_dir" ; find . -type f -print ) | sed -e 's/^\.\///' \ + ( cd "$_dir" ; find . -maxdepth 1 -type f ) | sed -e 's/^\.\///' \ | while read _file do + [ "$_file" = "control" ] && continue _want=true if [ -f "$_new/$_file" ] then @@ -1004,10 +2233,15 @@ save_configs_script() # migrate and clean configs if we have had a previous in-use installation [ -d "$PCP_LOG_DIR" ] || exit 0 # no configuration file upgrades required rm -f "$PCP_LOG_DIR/configs.sh" -for daemon in pmcd pmie pmlogger pmproxy +for daemon in pmie pmlogger do - save_configs_script >> "$PCP_LOG_DIR/configs.sh" "$PCP_SYSCONF_DIR/$daemon" \ - /var/lib/pcp/config/$daemon /etc/$daemon /etc/pcp/$daemon /etc/sysconfig/$daemon + save_configs_script >> "$PCP_LOG_DIR/configs.sh" "$PCP_CONFIG_DIR/$daemon" \ + "$PCP_SYSCONF_DIR/$daemon" +done +for daemon in pmcd pmproxy +do + save_configs_script >> "$PCP_LOG_DIR/configs.sh" "$PCP_SYSCONF_DIR/$daemon"\ + "$PCP_CONFIG_DIR/$daemon" /etc/$daemon done %endif exit 0 @@ -1015,7 +2249,7 @@ exit 0 %if !%{disable_microhttpd} %preun webapi %if 0%{?suse_version} -%if 0%{?has_systemd} +%if !%{disable_systemd} %service_del_preun pmwebd %else %{stop_on_removal pmwebd} @@ -1036,7 +2270,7 @@ fi %preun manager %if 0%{?suse_version} -%if 0%{?has_systemd} +%if !%{disable_systemd} %service_del_preun pmmgr %else %{stop_on_removal pmmgr} @@ -1056,7 +2290,7 @@ fi %preun %if 0%{?suse_version} -%if 0%{?has_systemd} +%if !%{disable_systemd} %service_del_preun pmlogger pmie pmproxy pmcd %else %{?stop_on_removal:%{stop_on_removal pmlogger pmie pmproxy pmcd}} @@ -1097,7 +2331,7 @@ fi %post webapi chown -R pcp:pcp %{_logsdir}/pmwebd 2>/dev/null %if 0%{?suse_version} -%if 0%{?has_systemd} +%if !%{disable_systemd} %service_add_post pmwebd %else %{fillup_and_insserv pmwebd} @@ -1115,7 +2349,7 @@ chown -R pcp:pcp %{_logsdir}/pmwebd 2>/dev/null %post manager chown -R pcp:pcp %{_logsdir}/pmmgr 2>/dev/null %if 0%{?suse_version} -%if 0%{?has_systemd} +%if !%{disable_systemd} %service_add_post pmmgr %else %{fillup_and_insserv pmmgr} @@ -1129,13 +2363,16 @@ chown -R pcp:pcp %{_logsdir}/pmmgr 2>/dev/null %endif %endif -%post -/sbin/ldconfig -%if 0%{?has_systemd} -%service_add_post pmmgr +%if !%{disable_selinux} +%post selinux +%if 0%{?fedora} >= 24 || 0%{?rhel} > 6 + semodule -X 400 -i %{localstatedir}/lib/pcp/selinux/pcpupstream.pp %else -%{fillup_and_insserv pmmgr} + semodule -i %{localstatedir}/lib/pcp/selinux/pcpupstream.pp +%endif #distro version check %endif + +%post PCP_LOG_DIR=%{_logsdir} PCP_PMNS_DIR=%{_pmnsdir} # restore saved configs, if any @@ -1172,6 +2409,19 @@ chown -R pcp:pcp %{_logsdir}/pmie 2>/dev/null chown -R pcp:pcp %{_logsdir}/pmproxy 2>/dev/null touch "$PCP_PMNS_DIR/.NeedRebuild" chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" +%if 0%{?suse_version} +%if !%{disable_systemd} +%service_add_post pmcd +%service_add_post pmlogger +%service_add_post pmie +%service_add_post pmproxy +%else +%{fillup_and_insserv pmcd} +%{fillup_and_insserv pmlogger} +%{fillup_and_insserv pmie} +%{fillup_and_insserv pmproxy} +%endif +%else %if !%{disable_systemd} systemctl condrestart pmcd.service >/dev/null 2>&1 systemctl condrestart pmlogger.service >/dev/null 2>&1 @@ -1187,14 +2437,27 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" /sbin/chkconfig --add pmproxy >/dev/null 2>&1 /sbin/service pmproxy condrestart %endif +%endif + +cd $PCP_PMNS_DIR && ./Rebuild -s && rm -f .NeedRebuild +cd %post -n %{lib_pkg} -p /sbin/ldconfig %postun -n %{lib_pkg} -p /sbin/ldconfig +%if !%{disable_selinux} +%postun selinux +%if 0%{?fedora} >= 24 || 0%{?rhel} > 6 + semodule -X 400 -r pcpupstream >/dev/null +%else + semodule -r pcpupstream >/dev/null +%endif +%endif + %if 0%{?suse_version} %postun /sbin/ldconfig -%if 0%{?has_systemd} +%if !%{disable_systemd} %service_del_postun pcp pmproxy pmie %else %{?restart_on_update:%{restart_on_update pcp pmproxy pmie}} @@ -1202,8 +2465,6 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %endif %endif -############################################################################### - %files -f base.list # # Note: there are some headers (e.g. domain.h) and in a few cases some @@ -1211,14 +2472,10 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" # but rather they are (slightly obscure) PMDA config files. # %defattr(-,root,root) -%doc CHANGELOG COPYING README VERSION.pcp pcp.lsm +%doc CHANGELOG COPYING INSTALL.md README.md VERSION.pcp pcp.lsm %if 0%{?suse_version} -%exclude %{_booksdir}/html -%exclude %{_booksdir}/*.pdf %exclude %{_docdir}/pcp/demos %exclude %{_docdir}/pcp/examples -%exclude %{_docdir}/pcp/sample -%exclude %{_docdir}/pcp/simple %exclude %{_docdir}/pcp/trivial %exclude %{_docdir}/pcp/txmon %exclude %{_testsdir} @@ -1226,7 +2483,6 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %exclude %{_pmdasdir}/infiniband %endif -%ghost %dir %{_rundir}/pcp %dir %{_confdir} %dir %{_pmdasdir} %dir %{_datadir}/pcp @@ -1251,12 +2507,14 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %dir %attr(0775,pcp,pcp) %{_tempsdir} %dir %attr(0775,pcp,pcp) %{_tempsdir}/pmie %dir %attr(0775,pcp,pcp) %{_tempsdir}/pmlogger +%dir %attr(0700,root,root) %{_tempsdir}/pmcd %dir %{_datadir}/pcp/lib %{_datadir}/pcp/lib/ReplacePmnsSubtree %{_datadir}/pcp/lib/bashproc.sh %{_datadir}/pcp/lib/lockpmns %{_datadir}/pcp/lib/pmdaproc.sh +%{_datadir}/pcp/lib/utilproc.sh %{_datadir}/pcp/lib/rc-proc.sh %{_datadir}/pcp/lib/rc-proc.sh.minimal %{_datadir}/pcp/lib/unlockpmns @@ -1267,7 +2525,7 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %attr(0775,pcp,pcp) %{_logsdir}/pmie %attr(0775,pcp,pcp) %{_logsdir}/pmproxy %{_localstatedir}/lib/pcp/pmns -%if !0%{?has_systemd} +%if %{disable_systemd} %{_initrddir}/pcp %{_initrddir}/pmcd %{_initrddir}/pmlogger @@ -1283,14 +2541,20 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %{_sbindir}/rcpmlogger %{_sbindir}/rcpmproxy %endif -%{_mandir}/man5/* %dir %{_sysconfdir}/sasl2 %config(noreplace) %{_sysconfdir}/sasl2/pmcd.conf %config(noreplace) %{_sysconfdir}/cron.d/pcp-pmlogger %config(noreplace) %{_sysconfdir}/cron.d/pcp-pmie -%config %{_sysconfdir}/bash_completion.d/pcp +%if 0%{?suse_version} +%{_localstatedir}/adm/fillup-templates/sysconfig.pmlogger +%{_localstatedir}/adm/fillup-templates/sysconfig.pmproxy +%{_localstatedir}/adm/fillup-templates/sysconfig.pmcd +%else +%config(noreplace) %{_sysconfdir}/sysconfig/pmlogger +%config(noreplace) %{_sysconfdir}/sysconfig/pmproxy +%config(noreplace) %{_sysconfdir}/sysconfig/pmcd +%endif %config %{_sysconfdir}/pcp.env -%config %{_sysconfdir}/pcp.sh %dir %{_confdir}/pmcd %config(noreplace) %{_confdir}/pmcd/pmcd.conf %config(noreplace) %{_confdir}/pmcd/pmcd.options @@ -1298,12 +2562,18 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %dir %{_confdir}/pmproxy %config(noreplace) %{_confdir}/pmproxy/pmproxy.options %dir %{_confdir}/pmie +%dir %{_confdir}/pmie/control.d %config(noreplace) %{_confdir}/pmie/control +%config(noreplace) %{_confdir}/pmie/control.d/local %dir %{_confdir}/pmlogger +%dir %{_confdir}/pmlogger/control.d %config(noreplace) %{_confdir}/pmlogger/control +%config(noreplace) %{_confdir}/pmlogger/control.d/local +%dir %attr(0775,pcp,pcp) %{_confdir}/nssdb %{_localstatedir}/lib/pcp/config/pmafm %dir %attr(0775,pcp,pcp) %{_localstatedir}/lib/pcp/config/pmie +%{_localstatedir}/lib/pcp/config/pmie %{_localstatedir}/lib/pcp/config/pmieconf %dir %attr(0775,pcp,pcp) %{_localstatedir}/lib/pcp/config/pmlogger %{_localstatedir}/lib/pcp/config/pmlogger/* @@ -1311,14 +2581,11 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %{_localstatedir}/lib/pcp/config/pmlogrewrite %dir %attr(0775,pcp,pcp) %{_localstatedir}/lib/pcp/config/pmda -%if 0%{?rhel} == 0 || 0%{?rhel} > 5 +%{_datadir}/bash-completion/completions/pcp +%{_datadir}/zsh/site-functions/_pcp + +%if !%{disable_sdt} %{tapsetdir}/pmcd.stp -%else # rhel5 -%ifarch ppc ppc64 -# no systemtap-sdt-devel -%else # ! ppc -%{tapsetdir}/pmcd.stp -%endif # ppc %endif %files conf @@ -1328,6 +2595,8 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %{_includedir}/pcp/builddefs %{_includedir}/pcp/buildrules %config %{_sysconfdir}/pcp.conf +%dir %{_localstatedir}/lib/pcp/config/derived +%config %{_localstatedir}/lib/pcp/config/derived/* %files -n %{lib_pkg} %defattr(-,root,root) @@ -1338,6 +2607,7 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %{_libdir}/libpcp_pmda.so.3 %{_libdir}/libpcp_trace.so.2 %{_libdir}/libpcp_import.so.1 +%{_libdir}/libpcp_web.so.1 %files -n %{lib_devel_pkg} -f devel.list %defattr(-,root,root) @@ -1348,20 +2618,18 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %{_libdir}/libpcp_pmda.so %{_libdir}/libpcp_trace.so %{_libdir}/libpcp_import.so +%{_libdir}/libpcp_web.so %{_includedir}/pcp/*.h + +%files devel -f devel.list +%{_datadir}/pcp/examples + # PMDAs that ship src and are not for production use # straight out-of-the-box, for devel or QA use only. -%if 0%{?suse_version} -%{_docdir}/pcp/sample -%{_docdir}/pcp/simple -%{_docdir}/pcp/trivial -%{_docdir}/pcp/txmon -%else %{_pmdasdir}/simple %{_pmdasdir}/sample %{_pmdasdir}/trivial %{_pmdasdir}/txmon -%endif %files testsuite %defattr(-,pcpqa,pcpqa) @@ -1379,15 +2647,8 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %attr(0775,pcp,pcp) %{_logsdir}/pmwebd %dir %{_confdir}/pmwebd %config(noreplace) %{_confdir}/pmwebd/pmwebd.options -%dir %{_datadir}/pcp/webapps -%{_mandir}/man1/pmwebd.1.gz -%{_mandir}/man3/PMWEBAPI.3.gz -%endif - -%if !%{disable_microhttpd} -%files webjs -%defattr(-,root,root) -%{_datadir}/pcp/webapps/* +# duplicate directories from pcp and pcp-webjs, but rpm copes with that. +%dir %{_datadir}/pcp %endif %files manager @@ -1405,45 +2666,37 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %attr(0775,pcp,pcp) %{_logsdir}/pmmgr %dir %{_confdir}/pmmgr %config(noreplace) %{_confdir}/pmmgr/pmmgr.options -%{_mandir}/man1/pmmgr.1.gz %files import-sar2pcp %defattr(-,root,root) %{_bindir}/sar2pcp -%{_mandir}/man1/sar2pcp.1.gz %files import-iostat2pcp %defattr(-,root,root) %{_bindir}/iostat2pcp -%{_mandir}/man1/iostat2pcp.1.gz %if !%{disable_sheet2pcp} %files import-sheet2pcp %defattr(-,root,root) %{_bindir}/sheet2pcp -%{_mandir}/man1/sheet2pcp.1.gz %endif %files import-mrtg2pcp %defattr(-,root,root) %{_bindir}/mrtg2pcp -%{_mandir}/man1/mrtg2pcp.1.gz %files import-ganglia2pcp %defattr(-,root,root) %{_bindir}/ganglia2pcp -%{_mandir}/man1/ganglia2pcp.1.gz %files import-collectl2pcp %defattr(-,root,root) %{_bindir}/collectl2pcp -%{_mandir}/man1/collectl2pcp.1.gz %if !%{disable_papi} %files pmda-papi %defattr(-,root,root) %{_pmdasdir}/papi -%{_mandir}/man1/pmdapapi.1.gz %endif %if !%{disable_perfevent} @@ -1451,9 +2704,6 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %defattr(-,root,root) %{_pmdasdir}/perfevent %config(noreplace) %{_pmdasdir}/perfevent/perfevent.conf -%{_mandir}/man1/perfalloc.1.gz -%{_mandir}/man1/pmdaperfevent.1.gz -%{_mandir}/man5/perfevent.conf.5.gz %endif %if !%{disable_infiniband} @@ -1461,9 +2711,205 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %defattr(-,root,root) %{_pmdasdir}/ib %{_pmdasdir}/infiniband -%{_mandir}/man1/pmdaib.1.gz %endif +%files pmda-activemq +%{_pmdasdir}/activemq + +%files pmda-bonding +%{_pmdasdir}/bonding + +%files pmda-bind2 +%{_pmdasdir}/bind2 + +%files pmda-dbping +%{_pmdasdir}/dbping + +%files pmda-ds389log +%{_pmdasdir}/ds389log + +%files pmda-ds389 +%{_pmdasdir}/ds389 + +%files pmda-elasticsearch +%{_pmdasdir}/elasticsearch + +%files pmda-gpfs +%{_pmdasdir}/gpfs + +%files pmda-gpsd +%{_pmdasdir}/gpsd + +%files pmda-kvm +%{_pmdasdir}/kvm + +%files pmda-docker +%{_pmdasdir}/docker + +%files pmda-lio +%{_pmdasdir}/lio + +%files pmda-lustre +%{_pmdasdir}/lustre + +%files pmda-lustrecomm +%{_pmdasdir}/lustrecomm + +%files pmda-memcache +%{_pmdasdir}/memcache + +%files pmda-mysql +%{_pmdasdir}/mysql + +%files pmda-named +%{_pmdasdir}/named + +%files pmda-netfilter +%{_pmdasdir}/netfilter + +%files pmda-news +%{_pmdasdir}/news + +%files pmda-nginx +%{_pmdasdir}/nginx + +%files pmda-nfsclient +%{_pmdasdir}/nfsclient + +%files pmda-nutcracker +%{_pmdasdir}/nutcracker + +%files pmda-oracle +%{_pmdasdir}/oracle + +%files pmda-pdns +%{_pmdasdir}/pdns + +%files pmda-postfix +%{_pmdasdir}/postfix + +%if !%{disable_postgresql} +%files pmda-postgresql +%{_pmdasdir}/postgresql +%endif + +%files pmda-redis +%{_pmdasdir}/redis + +%files pmda-rsyslog +%{_pmdasdir}/rsyslog + +%files pmda-samba +%{_pmdasdir}/samba + +%if !%{disable_snmp} +%files pmda-snmp +%{_pmdasdir}/snmp +%endif + +%files pmda-slurm +%{_pmdasdir}/slurm + +%files pmda-vmware +%{_pmdasdir}/vmware + +%files pmda-zimbra +%{_pmdasdir}/zimbra + +%files pmda-dm +%{_pmdasdir}/dm + +%if !%{disable_python2} || !%{disable_python3} +%files pmda-gluster +%{_pmdasdir}/gluster + +%files pmda-zswap +%{_pmdasdir}/zswap + +%files pmda-unbound +%{_pmdasdir}/unbound + +%files pmda-mic +%{_pmdasdir}/mic + +%if !%{disable_libvirt} +%files pmda-libvirt +%{_pmdasdir}/libvirt +%endif + +%files export-pcp2graphite +%{_bindir}/pcp2graphite + +%files export-pcp2influxdb +%{_bindir}/pcp2influxdb +%endif # !%{disable_python2} || !%{disable_python3} + +%files export-zabbix-agent +%{_libdir}/zabbix + +%if !%{disable_json} +%files pmda-json +%{_pmdasdir}/json +%endif + +%files pmda-apache +%{_pmdasdir}/apache + +%files pmda-bash +%{_pmdasdir}/bash + +%files pmda-cifs +%{_pmdasdir}/cifs + +%files pmda-cisco +%{_pmdasdir}/cisco + +%files pmda-gfs2 +%{_pmdasdir}/gfs2 + +%files pmda-lmsensors +%{_pmdasdir}/lmsensors + +%files pmda-logger +%{_pmdasdir}/logger + +%files pmda-mailq +%{_pmdasdir}/mailq + +%files pmda-mounts +%{_pmdasdir}/mounts + +%files pmda-nvidia-gpu +%{_pmdasdir}/nvidia + +%files pmda-roomtemp +%{_pmdasdir}/roomtemp + +%if !%{disable_rpm} +%files pmda-rpm +%{_pmdasdir}/rpm +%endif + +%files pmda-sendmail +%{_pmdasdir}/sendmail + +%files pmda-shping +%{_pmdasdir}/shping + +%files pmda-summary +%{_pmdasdir}/summary + +%if !%{disable_systemd} +%files pmda-systemd +%{_pmdasdir}/systemd +%endif + +%files pmda-trace +%{_pmdasdir}/trace + +%files pmda-weblog +%{_pmdasdir}/weblog + %files -n perl-PCP-PMDA -f perl-pcp-pmda.list %defattr(-,root,root) %if 0%{?suse_version} @@ -1494,6 +2940,7 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %dir %{_prefix}/lib/perl5/vendor_perl/*/PCP %endif +%if !%{disable_python2} %files -n python-pcp -f python-pcp.list.rpm %defattr(-,root,root) %if 0%{?suse_version} @@ -1501,6 +2948,7 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %dir %{python_sitearch}/pcp %{python_sitearch}/pcp %endif +%endif %if !%{disable_python3} %files -n python3-pcp -f python3-pcp.list.rpm @@ -1508,7 +2956,7 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %endif %if !%{disable_qt} -%files -n pcp-gui -f pcp-gui.list +%files gui -f pcp-gui.list %defattr(-,root,root,-) %{_pixmapdir}/pmchart.png %{_confdir}/pmsnap @@ -1519,21 +2967,23 @@ chmod 644 "$PCP_PMNS_DIR/.NeedRebuild" %{_datadir}/applications/pmchart.desktop %endif -%files -n pcp-doc -f pcp-doc.list +%files doc -f pcp-doc.list %defattr(-,root,root,-) %if 0%{?suse_version} %exclude %{_docdir}/pcp/CHANGELOG %exclude %{_docdir}/pcp/COPYING -%exclude %{_docdir}/pcp/INSTALL -%exclude %{_docdir}/pcp/README +%exclude %{_docdir}/pcp/INSTALL.md +%exclude %{_docdir}/pcp/README.md %exclude %{_docdir}/pcp/VERSION.pcp %exclude %{_docdir}/pcp/pcp.lsm -%exclude %{_docdir}/pcp/sample -%exclude %{_docdir}/pcp/simple -%exclude %{_docdir}/pcp/trivial -%exclude %{_docdir}/pcp/txmon %dir %{_docdir}/pcp/demos %dir %{_docdir}/pcp/demos/tutorials %endif +%if !%{disable_python2} || !%{disable_python3} +%files system-tools -f pcp_system_tools.list +%dir %{_confdir}/pmrep +%config(noreplace) %{_confdir}/pmrep/pmrep.conf +%endif + %changelog