summaryrefslogtreecommitdiff
path: root/sysutils/powerman
diff options
context:
space:
mode:
authorMateusz Piotrowski <0mp@FreeBSD.org>2019-10-26 20:52:47 +0000
committerMateusz Piotrowski <0mp@FreeBSD.org>2019-10-26 20:52:47 +0000
commitf91d0bca7dc61aff49633036e080651919250933 (patch)
tree4cf637ff5836ae45338d90a388539b15bb0cac14 /sysutils/powerman
parent171b084d06e8cae215f11d5b6ed612e475318d41 (diff)
downloadfreebsd-ports-f91d0bca7dc61aff49633036e080651919250933.zip
Clean up
- Use USES=localbase instead of setting CPPFLAGS and LDFLAGS manually. - Pet portlint, portfmt, and portclippy. - Regenerate patches with makepatch. - Define TEST_TARGET and disable failing tests. - Set USES=fakeroot to address some errors during installation.
Diffstat (limited to 'sysutils/powerman')
-rw-r--r--sysutils/powerman/Makefile20
-rw-r--r--sysutils/powerman/files/patch-man_powerman.conf.5.in (renamed from sysutils/powerman/files/patch-man-powerman.conf.5)8
-rw-r--r--sysutils/powerman/files/patch-man_powermand.8.in (renamed from sysutils/powerman/files/patch-man-powermand.8)6
3 files changed, 19 insertions, 15 deletions
diff --git a/sysutils/powerman/Makefile b/sysutils/powerman/Makefile
index 9e91196bfdfc..dc56bef49a58 100644
--- a/sysutils/powerman/Makefile
+++ b/sysutils/powerman/Makefile
@@ -15,22 +15,26 @@ LICENSE_FILE= ${WRKSRC}/COPYING
LIB_DEPENDS= libcurl.so:ftp/curl
-USES= libtool perl5 shebangfix
-SHEBANG_FILES= heartbeat/powerman
+USES= fakeroot libtool localbase:ldflags perl5 shebangfix
+USE_LDCONFIG= yes
USE_PERL5= build
+USE_RC_SUBR= powerman
+SHEBANG_FILES= heartbeat/powerman
+
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --with-httppower --localstatedir=/var \
--with-pkgconfig-dir=${PREFIX}/libdata/pkgconfig
-USE_LDCONFIG= yes
-INSTALL_TARGET= install-strip
-USE_RC_SUBR= powerman
-
-CPPFLAGS+= -I${LOCALBASE}/include
-LDFLAGS+= -L${LOCALBASE}/lib
+INSTALL_TARGET= install-strip
+TEST_TARGET= check
post-patch:
@${REINPLACE_CMD} -e \
'/^install-data-am/s|:.*|:|' ${WRKSRC}/scripts/Makefile.in
+ # Disable failing tests.
+.for test_case in t50 t53 t56 t57 t58 t59
+ @${REINPLACE_CMD} -E -e 's/${test_case}(.conf)?//' \
+ ${WRKSRC}/test/Makefile.in
+.endfor
.include <bsd.port.mk>
diff --git a/sysutils/powerman/files/patch-man-powerman.conf.5 b/sysutils/powerman/files/patch-man_powerman.conf.5.in
index 2c757041ae10..73427ef22a3b 100644
--- a/sysutils/powerman/files/patch-man-powerman.conf.5
+++ b/sysutils/powerman/files/patch-man_powerman.conf.5.in
@@ -1,6 +1,6 @@
---- man/powerman.conf.5.in.orig 2009-02-13 18:31:28.000000000 +0100
-+++ man/powerman.conf.5.in 2009-02-13 18:34:28.000000000 +0100
-@@ -5,7 +5,7 @@
+--- man/powerman.conf.5.in.orig 2012-01-13 23:01:47 UTC
++++ man/powerman.conf.5.in
+@@ -5,7 +5,7 @@ powerman.conf \- configuration file for PowerMan
.SH DESCRIPTION
The powerman.conf file typically includes one or more of the remote power
@@ -9,7 +9,7 @@
sets a few global options;
instantiates RPC devices with unique names, hostnames, and ports;
and maps node names to RPC's and plug numbers.
-@@ -32,7 +32,7 @@
+@@ -32,7 +32,7 @@ The following example is a 16-node cluster that uses t
Baytech RPC-3 remote power controllers.
.LP
.nf
diff --git a/sysutils/powerman/files/patch-man-powermand.8 b/sysutils/powerman/files/patch-man_powermand.8.in
index 80325388d2b8..149a33736f8d 100644
--- a/sysutils/powerman/files/patch-man-powermand.8
+++ b/sysutils/powerman/files/patch-man_powermand.8.in
@@ -1,6 +1,6 @@
---- man/powermand.8.in.orig 2009-02-13 18:33:44.000000000 +0100
-+++ man/powermand.8.in 2009-02-13 18:34:09.000000000 +0100
-@@ -12,7 +12,7 @@
+--- man/powermand.8.in.orig 2012-01-13 23:01:52 UTC
++++ man/powermand.8.in
+@@ -12,7 +12,7 @@ provides power management in a data center or compute
.TP
.I "-c, --conf filename"
Override the default location of the powerman configuration file