diff options
author | Ryan Steinmetz <zi@FreeBSD.org> | 2011-08-16 14:34:58 +0000 |
---|---|---|
committer | Ryan Steinmetz <zi@FreeBSD.org> | 2011-08-16 14:34:58 +0000 |
commit | 92cec64c8a9c9c57c67bac09a6e85c9afc010c5b (patch) | |
tree | b871926b608c97d4c3c08124360becfd69134124 /sysutils/cpulimit | |
parent | 12667965f5eeb5ec99fb9ac30486c9e63aa7077d (diff) | |
download | ports-92cec64c8a9c9c57c67bac09a6e85c9afc010c5b.tar.gz ports-92cec64c8a9c9c57c67bac09a6e85c9afc010c5b.zip |
Update to 1.4 [1]
Add LICENSE
Fix build under CLANG
PR: ports/159732
Submitted by: Jesse <jessefrgsmith@yahoo.ca> (maintainer) [1]
Approved by: wxs (mentor)
Notes
Notes:
svn path=/head/; revision=279810
Diffstat (limited to 'sysutils/cpulimit')
-rw-r--r-- | sysutils/cpulimit/Makefile | 15 | ||||
-rw-r--r-- | sysutils/cpulimit/distinfo | 4 | ||||
-rw-r--r-- | sysutils/cpulimit/files/patch-cpulimit.c | 18 | ||||
-rw-r--r-- | sysutils/cpulimit/files/patch-makefile | 19 |
4 files changed, 22 insertions, 34 deletions
diff --git a/sysutils/cpulimit/Makefile b/sysutils/cpulimit/Makefile index 284d99cde32c..61bbd350c3ac 100644 --- a/sysutils/cpulimit/Makefile +++ b/sysutils/cpulimit/Makefile @@ -6,16 +6,23 @@ # PORTNAME= cpulimit -PORTVERSION= 1.1 +PORTVERSION= 1.4 CATEGORIES= sysutils -MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTNAME}/ +MASTER_SITES= SF/limitcpu/limitcpu/ MAINTAINER= jessefrgsmith@yahoo.ca COMMENT= A program to limit the CPU usage of a process +LICENSE= GPLv2 + +CFLAGS+= -lkvm -Wall -O2 +MANCOMPRESSED= yes + PLIST_FILES= bin/${PORTNAME} +MAN1= ${PORTNAME}.1 -do-install: - ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin +post-patch: + @${REINPLACE_CMD} -e 's|share/||g' ${WRKSRC}/Makefile + @${REINPLACE_CMD} -e 's|gcc|${CC}|g' ${WRKSRC}/Makefile .include <bsd.port.mk> diff --git a/sysutils/cpulimit/distinfo b/sysutils/cpulimit/distinfo index 848e0a69fb05..c1da1b765b5b 100644 --- a/sysutils/cpulimit/distinfo +++ b/sysutils/cpulimit/distinfo @@ -1,2 +1,2 @@ -SHA256 (cpulimit-1.1.tar.gz) = ee734e82692dc496a083c003340b326bd779567f5de99fcae99e451606c85c00 -SIZE (cpulimit-1.1.tar.gz) = 5130 +SHA256 (cpulimit-1.4.tar.gz) = 48bb37801c83c926bf891ca66927c4c51ed1f2186bb3d61a70b19168d3c576df +SIZE (cpulimit-1.4.tar.gz) = 15950 diff --git a/sysutils/cpulimit/files/patch-cpulimit.c b/sysutils/cpulimit/files/patch-cpulimit.c index c6d1b5c47658..d7bbe4e0748f 100644 --- a/sysutils/cpulimit/files/patch-cpulimit.c +++ b/sysutils/cpulimit/files/patch-cpulimit.c @@ -1,8 +1,8 @@ ---- cpulimit.c.orig 2010-08-20 19:35:15.000000000 -0300 -+++ cpulimit.c 2010-08-21 14:17:52.000000000 -0300 -@@ -43,6 +43,15 @@ - #include <errno.h> - #include <string.h> +--- ./cpulimit.c.orig 2011-08-12 19:35:36.000000000 -0300 ++++ ./cpulimit.c 2011-08-12 21:31:58.000000000 -0300 +@@ -35,6 +35,15 @@ + #include <limits.h> // for compatibility + +#include <limits.h> +#include <fcntl.h> @@ -16,7 +16,7 @@ //kernel time resolution (inverse of one jiffy interval) in Hertz //i don't know how to detect it, then define to the default (not very clean!) #define HZ 100 -@@ -235,6 +244,31 @@ +@@ -245,6 +254,31 @@ } //get jiffies count from /proc filesystem @@ -48,9 +48,9 @@ int getjiffies(int pid) { static char stat[20]; static char buffer[1024]; -@@ -255,6 +289,8 @@ - int ktime=atoi(p+1); - return utime+ktime; +@@ -271,6 +305,8 @@ + // could not read info + return -1; } +*/ + diff --git a/sysutils/cpulimit/files/patch-makefile b/sysutils/cpulimit/files/patch-makefile deleted file mode 100644 index 426bf3a20fd0..000000000000 --- a/sysutils/cpulimit/files/patch-makefile +++ /dev/null @@ -1,19 +0,0 @@ ---- Makefile.old 2005-06-24 07:53:43.000000000 -0300 -+++ Makefile 2010-08-21 15:10:45.000000000 -0300 -@@ -1,7 +1,15 @@ -+PREFIX=/usr/local -+ - all:: cpulimit - - cpulimit: cpulimit.c -- gcc -o cpulimit cpulimit.c -lrt -Wall -O2 -+ gcc -o cpulimit cpulimit.c -lrt -Wall -O2 -lkvm -+ -+install: cpulimit -+ cp cpulimit ${PREFIX}/bin -+ -+deinstall: -+ rm -f ${PREFIX}/bin/cpulimit - - clean: - rm -f *~ cpulimit |