From 15ab37afe52a2993d1160656b811483013223170 Mon Sep 17 00:00:00 2001 From: Jung-uk Kim Date: Thu, 19 Apr 2012 22:09:36 +0000 Subject: - Install plasma_saver.ko under /boot/modules and remove pkg-message. - Execute kldxref when we install or deinstall the package. - Fix a compiler warning and remove custom CWARNFLAGS. - Replace NOMAN with NO_MAN. - Add LICENSE. --- graphics/plasma-kmod/Makefile | 14 ++++++-------- graphics/plasma-kmod/files/patch-Makefile | 12 ++++++++++++ graphics/plasma-kmod/files/patch-plasma_saver.c | 18 ++++++++++++++---- graphics/plasma-kmod/files/pkg-message.in | 3 --- graphics/plasma-kmod/pkg-plist | 4 ++++ 5 files changed, 36 insertions(+), 15 deletions(-) create mode 100644 graphics/plasma-kmod/files/patch-Makefile delete mode 100644 graphics/plasma-kmod/files/pkg-message.in create mode 100644 graphics/plasma-kmod/pkg-plist (limited to 'graphics/plasma-kmod') diff --git a/graphics/plasma-kmod/Makefile b/graphics/plasma-kmod/Makefile index 21a4f9eb7a6a..3c6c20c5d7c1 100644 --- a/graphics/plasma-kmod/Makefile +++ b/graphics/plasma-kmod/Makefile @@ -7,7 +7,7 @@ PORTNAME= plasma PORTVERSION= 0.1 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= graphics kld MASTER_SITES= SF/futurebsd/futurebsd/${PORTNAME} PKGNAMESUFFIX= -kmod @@ -15,18 +15,16 @@ PKGNAMESUFFIX= -kmod MAINTAINER= ports@FreeBSD.org COMMENT= A plasma-effect screensaver kernel module +LICENSE= BSD + .include .if !exists(${SRC_BASE}/sys/dev/syscons/syscons.h) IGNORE= requires kernel source (in ${SRC_BASE}) to build .endif -PLIST_FILES= lib/plasma_saver.ko -SUB_FILES= pkg-message - -do-install: - ${INSTALL_KLD} ${WRKSRC}/plasma_saver.ko ${PREFIX}/lib -post-install: - @${CAT} ${PKGMESSAGE} +KMODDIR= /boot/modules +PLIST_SUB+= KMODDIR=${KMODDIR:C,^/,,} +MAKE_ARGS= KMODDIR=${KMODDIR} .include diff --git a/graphics/plasma-kmod/files/patch-Makefile b/graphics/plasma-kmod/files/patch-Makefile new file mode 100644 index 000000000000..d0dc6a902dfe --- /dev/null +++ b/graphics/plasma-kmod/files/patch-Makefile @@ -0,0 +1,12 @@ +--- Makefile.orig 2001-01-24 11:57:49.000000000 -0500 ++++ Makefile 2012-04-19 17:54:27.000000000 -0400 +@@ -3,8 +3,6 @@ + KMOD= plasma_saver + SRCS= plasma_saver.c + +-NOMAN= +-CFLAGS+= -I${.CURDIR}/.. -I. +-CWARNFLAGS= -Wall ++NO_MAN= + + .include diff --git a/graphics/plasma-kmod/files/patch-plasma_saver.c b/graphics/plasma-kmod/files/patch-plasma_saver.c index df7ec0479f30..0e0975f59a2f 100644 --- a/graphics/plasma-kmod/files/patch-plasma_saver.c +++ b/graphics/plasma-kmod/files/patch-plasma_saver.c @@ -1,5 +1,5 @@ --- plasma_saver.c.orig 2001-01-24 12:03:23.000000000 -0500 -+++ plasma_saver.c 2012-04-18 17:51:10.000000000 -0400 ++++ plasma_saver.c 2012-04-19 17:56:10.000000000 -0400 @@ -52,7 +52,7 @@ #define SCR_W 320 #define SCR_H 200 @@ -58,7 +58,17 @@ log(LOG_NOTICE, "plasma_saver: the console does not support M_VGA_CG320\n"); return(ENODEV); } -@@ -123,14 +134,15 @@ +@@ -115,7 +126,8 @@ + return(0); + } + +-void draw_plasma(u_char *buffer) ++static void ++draw_plasma(u_char *buffer) + { + short i,j; + anglebak[0] = angle[0]; +@@ -123,14 +135,15 @@ anglebak[2] = angle[2]; for (i=0; i