From owner-freebsd-ports-bugs@FreeBSD.ORG Wed Mar 1 15:11:48 2006 Return-Path: X-Original-To: freebsd-ports-bugs@hub.freebsd.org Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4739016A424 for ; Wed, 1 Mar 2006 15:11:48 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 86E4243DD3 for ; Wed, 1 Mar 2006 15:10:34 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id k21FA5Rf062764 for ; Wed, 1 Mar 2006 15:10:05 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id k21FA5h8062760; Wed, 1 Mar 2006 15:10:05 GMT (envelope-from gnats) Resent-Date: Wed, 1 Mar 2006 15:10:05 GMT Resent-Message-Id: <200603011510.k21FA5h8062760@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, "Ion-Mihai "IOnut" Tetcu" Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6149716A436 for ; Wed, 1 Mar 2006 15:07:15 +0000 (GMT) (envelope-from itetcu@people.tecnik93.com) Received: from it.buh.tecnik93.com (it.buh.tecnik93.com [81.196.204.98]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7251E43E13 for ; Wed, 1 Mar 2006 15:06:39 +0000 (GMT) (envelope-from itetcu@people.tecnik93.com) Received: from it.buh.tecnik93.com (localhost [127.0.0.1]) by it.buh.tecnik93.com (Postfix) with ESMTP id 0CCC51728D for ; Wed, 1 Mar 2006 17:06:08 +0200 (EET) Message-Id: <1141225568.8091@it.buh.tecnik93.com> Date: Wed, 1 Mar 2006 17:06:08 +0200 From: "Ion-Mihai "IOnut" Tetcu" To: "FreeBSD gnats submit" X-Send-Pr-Version: gtk-send-pr 0.4.7 Cc: Subject: ports/93985: [PATCH] sysutils/est: fix deinstall, other fixes X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 01 Mar 2006 15:11:48 -0000 >Number: 93985 >Category: ports >Synopsis: [PATCH] sysutils/est: fix deinstall, other fixes >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Wed Mar 01 15:10:05 GMT 2006 >Closed-Date: >Last-Modified: >Originator: Ion-Mihai "IOnut" Tetcu >Release: FreeBSD 6.1-PRERELEASE i386 >Organization: Tecnik'93 >Environment: System: FreeBSD 6.1-PRERELEASE #0: Fri Feb 17 08:33:28 EET 2006 root@it.buh.tecnik93.com:/usr/obj/usr/src/sys/IT6_B_P >Description: Remove PREFIX/modules directory if it doesn't contain other modules; use statical plist (new file: pkg-plist). Switch to a modern USE_RC_SUBR (moved file: files/est.sh --> files/est.in). Silence install here and there. Fix IGNORE message. IGNORE if no kernel sources installed. Bump PORTREVISION for plist change. >How-To-Repeat: >Fix: --- est.diff begins here --- Index: Makefile =================================================================== RCS file: /home/ncvs/ports/sysutils/est/Makefile,v retrieving revision 1.10 diff -u -r1.10 Makefile --- Makefile 7 Jan 2006 06:29:54 -0000 1.10 +++ Makefile 1 Mar 2006 14:59:39 -0000 @@ -7,7 +7,7 @@ PORTNAME= est PORTVERSION= 0.7.2 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= sysutils MASTER_SITES= http://www.daemonology.net/freebsd-est/ @@ -18,27 +18,22 @@ KMODDIR= ${PREFIX}/modules MAKE_ARGS= KMODDIR="${KMODDIR}" -USE_RC_SUBR= yes -RC_SCRIPTS_SUB= PREFIX=${PREFIX} RC_SUBR=${RC_SUBR} - -PLIST_FILES= modules/est.ko \ - etc/rc.d/est.sh +USE_RC_SUBR= ${PORTNAME} .include .if ${OSVERSION} > 600015 -IGNORE= est now contained in the base system (see cpufreq(4)) +IGNORE= is now contained in the base system (see cpufreq(4)) .endif -post-extract: - ${SED} ${RC_SCRIPTS_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \ - ${FILESDIR}/est.sh > ${WRKDIR}/est.sh +.if !exists(${SRC_BASE}/sys/Makefile) +IGNORE= needs kernel source files +.endif pre-install: - ${MKDIR} ${KMODDIR} + @${MKDIR} ${KMODDIR} post-install: - ${INSTALL_SCRIPT} ${WRKDIR}/est.sh ${PREFIX}/etc/rc.d/est.sh - ${CAT} ${PKGMESSAGE} + @${CAT} ${PKGMESSAGE} .include Index: pkg-message =================================================================== RCS file: /home/ncvs/ports/sysutils/est/pkg-message,v retrieving revision 1.1 diff -u -r1.1 pkg-message --- pkg-message 2 Sep 2004 04:14:21 -0000 1.1 +++ pkg-message 1 Mar 2006 14:59:39 -0000 @@ -1,5 +1,7 @@ +=============================================================================== To load the Enhanced Speedstep kernel module at boot: echo 'est_enable="YES"' >> /etc/rc.conf To log every change of CPU frequency: echo 'est_verbose="YES"' >> /etc/rc.conf +=============================================================================== Index: pkg-plist =================================================================== RCS file: pkg-plist diff -N pkg-plist --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ pkg-plist 1 Mar 2006 14:59:39 -0000 @@ -0,0 +1,3 @@ +modules/est.ko +@unexec MOD_FNR=`ls -1 %D/modules |wc -l`; MOD_L=`ls -1 %D/modules |grep linker.hints|wc -l`; if [ "${MOD_FNR}" -eq "${MOD_L}" ]; then rm -rf %D/modules; fi +@dirrmtry modules Index: files/est.in =================================================================== RCS file: files/est.in diff -N files/est.in --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ files/est.in 1 Mar 2006 14:59:39 -0000 @@ -0,0 +1,43 @@ +#!/bin/sh +# +# $FreeBSD: ports/sysutils/est/files/est.sh,v 1.4 2006/02/20 20:47:41 dougb Exp $ +# + +# PROVIDE: est +# REQUIRE: abi +# BEFORE: securelevel + +# Define est_* variables in one of these files: +# /etc/rc.conf +# /etc/rc.conf.local +# /etc/rc.conf.d/est +# +# DO NOT CHANGE THESE DEFAULT VALUES HERE +# +est_enable="${est_enable-NO}" +est_verbose="NO" + +. %%RC_SUBR%% + +name="est" +rcvar=`set_rcvar` + +start_cmd="est_start" +stop_cmd="est_stop" + +load_rc_config $name + +kmoddir="%%PREFIX%%/modules" + +est_start () { + /sbin/kldload ${kmoddir}/est.ko + if checkyesno est_verbose; then + sysctl hw.est_verbose=1 + fi +} + +est_stop () { + /sbin/kldunload $name +} + +run_rc_command "$1" Index: files/est.sh =================================================================== RCS file: files/est.sh diff -N files/est.sh --- files/est.sh 20 Feb 2006 20:47:41 -0000 1.4 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,43 +0,0 @@ -#!/bin/sh -# -# $FreeBSD: ports/sysutils/est/files/est.sh,v 1.4 2006/02/20 20:47:41 dougb Exp $ -# - -# PROVIDE: est -# REQUIRE: abi -# BEFORE: securelevel - -# Define est_* variables in one of these files: -# /etc/rc.conf -# /etc/rc.conf.local -# /etc/rc.conf.d/est -# -# DO NOT CHANGE THESE DEFAULT VALUES HERE -# -est_enable="${est_enable-NO}" -est_verbose="NO" - -. %%RC_SUBR%% - -name="est" -rcvar=`set_rcvar` - -start_cmd="est_start" -stop_cmd="est_stop" - -load_rc_config $name - -kmoddir="%%PREFIX%%/modules" - -est_start () { - /sbin/kldload ${kmoddir}/est.ko - if checkyesno est_verbose; then - sysctl hw.est_verbose=1 - fi -} - -est_stop () { - /sbin/kldunload $name -} - -run_rc_command "$1" --- est.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted: