Date: Sat, 25 Feb 2017 13:51:00 +0000 (UTC) From: Dmitry Marakasov <amdmi3@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r434808 - in head/sysutils/swapd: . files Message-ID: <201702251351.v1PDp0DW065500@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: amdmi3 Date: Sat Feb 25 13:50:59 2017 New Revision: 434808 URL: https://svnweb.freebsd.org/changeset/ports/434808 Log: - Add LICENSE - Strip binary - Regenerate patches Modified: head/sysutils/swapd/Makefile head/sysutils/swapd/files/patch-Makefile.in head/sysutils/swapd/files/patch-configure head/sysutils/swapd/files/patch-swapd.c head/sysutils/swapd/files/patch-swapd.conf.5.in Modified: head/sysutils/swapd/Makefile ============================================================================== --- head/sysutils/swapd/Makefile Sat Feb 25 13:50:19 2017 (r434807) +++ head/sysutils/swapd/Makefile Sat Feb 25 13:50:59 2017 (r434808) @@ -3,13 +3,16 @@ PORTNAME= swapd PORTVERSION= 1.0.5 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= sysutils MASTER_SITES= http://www.rkeene.org/files/oss/swapd/ MAINTAINER= ports@FreeBSD.org COMMENT= Daemon that watches free memory and manages swap files +LICENSE= GPLv2 +LICENSE_FILE= ${WRKSRC}/LICENSE + LIB_DEPENDS= libstatgrab.so:devel/libstatgrab USES= gmake pkgconfig @@ -21,6 +24,7 @@ post-patch: @${REINPLACE_CMD} -e "s,%%PREFIX%%,${PREFIX},g" ${WRKSRC}/${CONFIGURE_SCRIPT} post-install: + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/sbin/${PORTNAME} .for f in swapd_swapon swapd_swapoff ${INSTALL_SCRIPT} ${FILESDIR}/${f} ${STAGEDIR}${PREFIX}/sbin .endfor Modified: head/sysutils/swapd/files/patch-Makefile.in ============================================================================== --- head/sysutils/swapd/files/patch-Makefile.in Sat Feb 25 13:50:19 2017 (r434807) +++ head/sysutils/swapd/files/patch-Makefile.in Sat Feb 25 13:50:59 2017 (r434808) @@ -1,6 +1,6 @@ ---- ./Makefile.in.orig 2004-10-18 06:05:24.000000000 +0100 -+++ ./Makefile.in 2013-11-22 22:33:19.141103774 +0000 -@@ -30,11 +30,11 @@ +--- Makefile.in.orig 2004-10-18 05:05:24 UTC ++++ Makefile.in +@@ -30,11 +30,11 @@ distclean: clean rm -f Makefile config.h config.status config.log swapd.8 swapd.conf.5 install: all Modified: head/sysutils/swapd/files/patch-configure ============================================================================== --- head/sysutils/swapd/files/patch-configure Sat Feb 25 13:50:19 2017 (r434807) +++ head/sysutils/swapd/files/patch-configure Sat Feb 25 13:50:59 2017 (r434808) @@ -1,6 +1,6 @@ ---- ./configure.orig 2013-10-06 17:11:43.000000000 +0100 -+++ ./configure 2013-11-22 21:48:41.875104078 +0000 -@@ -4850,6 +4850,7 @@ +--- configure.orig 2013-10-06 16:11:43 UTC ++++ configure +@@ -4850,6 +4850,7 @@ fi for ac_func in swapoff do : ac_fn_c_check_func "$LINENO" "swapoff" "ac_cv_func_swapoff" @@ -8,7 +8,7 @@ if test "x$ac_cv_func_swapoff" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_SWAPOFF 1 -@@ -4861,6 +4862,7 @@ +@@ -4861,6 +4862,7 @@ done ac_fn_c_check_func "$LINENO" "swapon" "ac_cv_func_swapon" @@ -16,7 +16,7 @@ if test "x$ac_cv_func_swapon" = xyes; then : -@@ -5114,6 +5116,17 @@ +@@ -5114,6 +5116,17 @@ $as_echo "#define SWAPD_SWAP_PERMS 01600 $as_echo "#define SWAPD_SWAPOFF_CMDLINE \"/sbin/swapctl -d \\\"%s\\\"\"" >>confdefs.h ;; Modified: head/sysutils/swapd/files/patch-swapd.c ============================================================================== --- head/sysutils/swapd/files/patch-swapd.c Sat Feb 25 13:50:19 2017 (r434807) +++ head/sysutils/swapd/files/patch-swapd.c Sat Feb 25 13:50:59 2017 (r434808) @@ -1,5 +1,5 @@ ---- swapd.c.orig 2005-02-18 20:32:30.000000000 -0800 -+++ swapd.c 2010-06-25 12:16:07.000000000 -0700 +--- swapd.c.orig 2013-10-06 16:09:13 UTC ++++ swapd.c @@ -1,3 +1,6 @@ +#include <syslog.h> +#include <stdarg.h> @@ -7,7 +7,7 @@ #include "compat.h" #ifdef HAVE_STDIO_H -@@ -187,15 +190,18 @@ +@@ -188,15 +191,18 @@ int swapd_swapon(const char *swapfile) { # ifdef SWAPON_TAKES_2_ARGS /* Linux */ swaponret = swapon(swapfile, 0); @@ -26,7 +26,7 @@ # else # error Dont know how to swapon() on this platform! # endif -@@ -286,7 +292,9 @@ +@@ -287,7 +293,9 @@ swap_t *swapd_mkswap(const char *swapdir int swapd_swapoff(swap_t *swapfile) { int swapoffret = -1; @@ -36,7 +36,7 @@ if (swapfile == NULL) { return(-1); -@@ -299,11 +307,13 @@ +@@ -300,11 +308,13 @@ int swapd_swapoff(swap_t *swapfile) { /* Prefer the swapoff() system call ... */ #ifdef HAVE_SWAPOFF swapoffret = swapoff(swapfile->pathname); @@ -50,7 +50,7 @@ # else /* ... otherwise, issue a warning since we don't know what to do. */ # warning Dont know how to swapoff on this platform -@@ -444,6 +454,8 @@ +@@ -445,6 +455,8 @@ int main(int argc, char **argv) { int chdirret = 0, statret = 0; int gfm_errorcount = 0; @@ -59,7 +59,7 @@ if (!swapd_init_stats()) { return(EXIT_FAILURE); } -@@ -518,7 +530,7 @@ +@@ -519,7 +531,7 @@ int main(int argc, char **argv) { daemonize(); @@ -68,7 +68,7 @@ if (dh != NULL) { inactive_swaps = 0; -@@ -587,7 +599,7 @@ +@@ -588,7 +600,7 @@ int main(int argc, char **argv) { } } @@ -77,7 +77,7 @@ if (swapfile != NULL) { free(swapfile); -@@ -637,6 +649,7 @@ +@@ -638,6 +650,7 @@ int main(int argc, char **argv) { if (swaps[i]->active == 0 && swaps[i]->pathname != NULL) { inactive_swaps++; if (inactive_swaps > max_inactive_swaps) { @@ -85,7 +85,7 @@ unlink(swaps[i]->pathname); free(swaps[i]->pathname); free(swaps[i]); -@@ -658,5 +671,6 @@ +@@ -659,5 +672,6 @@ int main(int argc, char **argv) { } Modified: head/sysutils/swapd/files/patch-swapd.conf.5.in ============================================================================== --- head/sysutils/swapd/files/patch-swapd.conf.5.in Sat Feb 25 13:50:19 2017 (r434807) +++ head/sysutils/swapd/files/patch-swapd.conf.5.in Sat Feb 25 13:50:59 2017 (r434808) @@ -1,6 +1,6 @@ ---- swapd.conf.5.in.orig 2010-06-24 16:22:44.000000000 -0700 -+++ swapd.conf.5.in 2010-06-24 16:22:57.000000000 -0700 -@@ -14,7 +14,7 @@ +--- swapd.conf.5.in.orig 2005-02-19 04:22:44 UTC ++++ swapd.conf.5.in +@@ -14,7 +14,7 @@ at startup. The configuration file is i maxfree 0 swapsize 32m swapdir /var/tmp
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201702251351.v1PDp0DW065500>