update to newest version of cego and adding a startup script How-To-Repeat: -
Hi! Attached is a newer version which updates to 2.7.17. -- pi@opsec.eu +49 171 3101372 9 years to go !
State Changed From-To: open->feedback Startup script should be sh script, not bash script. /usr/local shouldn't be hardcoded. Can you fix this? Bapt
Hi! Attached is a newer version which updates to 2.8.1. ----------- diff -r -u -N databases/cego/Makefile /usr/home/pi/myp/databases/cego/Makefile --- databases/cego/Makefile 2010-12-04 23:04:53.000000000 +0100 +++ /usr/home/pi/myp/databases/cego/Makefile 2011-04-02 19:32:01.000000000 +0200 @@ -6,10 +6,10 @@ PORTNAME= cego -PORTVERSION= 2.6.18 +PORTVERSION= 2.8.1 CATEGORIES= databases MASTER_SITES= http://www.lemke-it.com/ @@ -22,4 +22,6 @@ USE_LDCONFIG= yes USE_AUTOTOOLS= autoconf:env +USE_RC_SUBR= cego + .include <bsd.port.mk> diff -r -u -N databases/cego/distinfo /usr/home/pi/myp/databases/cego/distinfo --- databases/cego/distinfo 2011-03-20 23:05:10.000000000 +0100 +++ /usr/home/pi/myp/databases/cego/distinfo 2011-04-03 11:07:31.000000000 +0200 @@ -1,2 +1,2 @@ -SHA256 (cego-2.6.18.tar.gz) = afd48d6c49b072cc76be30600e43a15a34d65a6382a98c46f3fcad528ab82d3b -SIZE (cego-2.6.18.tar.gz) = 642309 +SHA256 (cego-2.8.1.tar.gz) = 45ead9f2c98937e053281932af336ad7af524959eb35693a36c228b16cdb6eff +SIZE (cego-2.8.1.tar.gz) = 640678 diff -r -u -N databases/cego/files/cego.in /usr/home/pi/myp/databases/cego/files/cego.in --- databases/cego/files/cego.in 1970-01-01 01:00:00.000000000 +0100 +++ /usr/home/pi/myp/databases/cego/files/cego.in 2011-03-09 11:26:37.000000000 +0100 @@ -0,0 +1,114 @@ +#!/usr/local/bin/bash +# +# $FreeBSD$ +# + +# PROVIDE: cego +# REQUIRE: LOGIN cleanvar +# KEYWORD: shutdown + +# +# Add the following lines to /etc/rc.conf to enable cego: +# cego_enable (bool): Set to "NO" by default. +# Set it to "YES" to enable cego +# cego_profiles (str): Set to "" by default. +# Define your profiles here. +# cego_flags (str): Set to "" by default. +# Extra flags passed to start command. + +. /etc/rc.subr + +name="cego" +rcvar=`set_rcvar` + +command="/usr/local/bin/cego" +user="cego" +defcegoconf="/serv/cego" +defcegoroot="/serv/cego" +flags="--mode=daemon" + +_pidprefix="/var/run/cego" +pidfile="${_pidprefix}.pid" + +[ -z "$cego_enable" ] && cego_enable="NO" +[ -z "$cego_tablespc" ] && cego_enable="NO" + +load_rc_config $name + +if [ -n "$2" ]; then + profile="$2" + if [ "x${cego_profiles}" != "x" ]; then + pidfile="${_pidprefix}.${profile}.pid" + + echo profile is $profile + eval cginst=`echo $profile | awk -F : '{ print $1 }'` + eval cgts=`echo $profile | awk -F : '{ print $2 }'` + + if [ "x${cgts}" = "x" ]; then + echo "You must define a tableset for db instance ${profile}" + exit 1 + fi + + eval cegoconf="\${cegoconf:-${defcegoconf}}" + eval cegoroot="\${cegoroot:-${defcegoroot}}" + + required_files="${configfile}" + eval cego_enable="\${cego_${cginst}_enable:-${cego_enable}}" + # command_args="--dbxml=${cegoconf}/${cginst}.xml --tableset=${cgts} --lockfile=${cegoroot}/${cginst}.lck --logfile=${cegoroot}/${cginst}.log --pidfile=${cegoroot}/${cginst}.pid" + command_args="--dbxml=${cegoconf}/${cginst}.xml --tableset=${cgts} --lockfile=${cegoroot}/${cginst}.lck --logfile=${cegoroot}/${cginst}.log" + echo "Setting command_args $command_args" + else + echo "$0: extra argument ignored" + fi +else + if [ "x${cego_profiles}" != "x" -a "x$1" != "x" ]; then + for profile in ${cego_profiles}; do + eval _enable="\${cego_${profile}_enable}" + case "x${_enable:-${cego_enable}}" in + x|x[Nn][Oo]|x[Nn][Oo][Nn][Ee]) + continue + ;; + x[Yy][Ee][Ss]) + ;; + *) + if test -z "$_enable"; then + _var=cego_enable + else + _var=cego_"${profile}"_enable + fi + echo "Bad value" \ + "'${_enable:-${cego_enable}}'" \ + "for ${_var}. " \ + "Profile ${profile} skipped." + continue + ;; + esac + echo "===> cego profile: ${profile}" + /etc/rc.d/cego $1 ${profile} + retcode="$?" + if [ "0${retcode}" -ne 0 ]; then + failed="${profile} (${retcode}) ${failed:-}" + else + success="${profile} ${success:-}" + fi + done + exit 0 + fi +fi + +cego_requirepidfile() +{ + if [ ! "0`check_pidfile ${pidfile} ${command}`" -gt 1 ]; then + echo "${name} not running? (check $pidfile)." + exit 1 + fi +} + +cego_stop() { + cego_requirepidfile + + echo "stopping cego instance $1" + kill -1 $1 +} + +run_rc_command "$1" -------------- -- pi@opsec.eu +49 171 3101372 9 years to go !
Hi! > Attached is a newer version which updates to 2.8.1. And another one to 2.8.3. --------------- diff -r -u -N databases/cego/Makefile /usr/home/pi/myp/databases/cego/Makefile --- databases/cego/Makefile 2010-12-04 23:04:53.000000000 +0100 +++ /usr/home/pi/myp/databases/cego/Makefile 2011-04-22 21:13:53.000000000 +0200 @@ -2,10 +2,10 @@ PORTNAME= cego -PORTVERSION= 2.6.18 +PORTVERSION= 2.8.3 CATEGORIES= databases MASTER_SITES= http://www.lemke-it.com/ @@ -22,4 +22,6 @@ USE_LDCONFIG= yes USE_AUTOTOOLS= autoconf:env +USE_RC_SUBR= cego + .include <bsd.port.mk> diff -r -u -N databases/cego/distinfo /usr/home/pi/myp/databases/cego/distinfo --- databases/cego/distinfo 2011-03-20 23:05:10.000000000 +0100 +++ /usr/home/pi/myp/databases/cego/distinfo 2011-04-22 21:14:20.000000000 +0200 @@ -1,2 +1,2 @@ -SHA256 (cego-2.6.18.tar.gz) = afd48d6c49b072cc76be30600e43a15a34d65a6382a98c46f3fcad528ab82d3b -SIZE (cego-2.6.18.tar.gz) = 642309 +SHA256 (cego-2.8.3.tar.gz) = df5bf41b732637d3e7a3def0bd5403d91f4bb4230a3f5a47e62765997baecb68 +SIZE (cego-2.8.3.tar.gz) = 642171 diff -r -u -N databases/cego/files/cego.in /usr/home/pi/myp/databases/cego/files/cego.in --- databases/cego/files/cego.in 1970-01-01 01:00:00.000000000 +0100 +++ /usr/home/pi/myp/databases/cego/files/cego.in 2011-03-09 11:26:37.000000000 +0100 @@ -0,0 +1,114 @@ +#!/usr/local/bin/bash +# +# $FreeBSD$ +# + +# PROVIDE: cego +# REQUIRE: LOGIN cleanvar +# KEYWORD: shutdown + +# +# Add the following lines to /etc/rc.conf to enable cego: +# cego_enable (bool): Set to "NO" by default. +# Set it to "YES" to enable cego +# cego_profiles (str): Set to "" by default. +# Define your profiles here. +# cego_flags (str): Set to "" by default. +# Extra flags passed to start command. + +. /etc/rc.subr + +name="cego" +rcvar=`set_rcvar` + +command="/usr/local/bin/cego" +user="cego" +defcegoconf="/serv/cego" +defcegoroot="/serv/cego" +flags="--mode=daemon" + +_pidprefix="/var/run/cego" +pidfile="${_pidprefix}.pid" + +[ -z "$cego_enable" ] && cego_enable="NO" +[ -z "$cego_tablespc" ] && cego_enable="NO" + +load_rc_config $name + +if [ -n "$2" ]; then + profile="$2" + if [ "x${cego_profiles}" != "x" ]; then + pidfile="${_pidprefix}.${profile}.pid" + + echo profile is $profile + eval cginst=`echo $profile | awk -F : '{ print $1 }'` + eval cgts=`echo $profile | awk -F : '{ print $2 }'` + + if [ "x${cgts}" = "x" ]; then + echo "You must define a tableset for db instance ${profile}" + exit 1 + fi + + eval cegoconf="\${cegoconf:-${defcegoconf}}" + eval cegoroot="\${cegoroot:-${defcegoroot}}" + + required_files="${configfile}" + eval cego_enable="\${cego_${cginst}_enable:-${cego_enable}}" + # command_args="--dbxml=${cegoconf}/${cginst}.xml --tableset=${cgts} --lockfile=${cegoroot}/${cginst}.lck --logfile=${cegoroot}/${cginst}.log --pidfile=${cegoroot}/${cginst}.pid" + command_args="--dbxml=${cegoconf}/${cginst}.xml --tableset=${cgts} --lockfile=${cegoroot}/${cginst}.lck --logfile=${cegoroot}/${cginst}.log" + echo "Setting command_args $command_args" + else + echo "$0: extra argument ignored" + fi +else + if [ "x${cego_profiles}" != "x" -a "x$1" != "x" ]; then + for profile in ${cego_profiles}; do + eval _enable="\${cego_${profile}_enable}" + case "x${_enable:-${cego_enable}}" in + x|x[Nn][Oo]|x[Nn][Oo][Nn][Ee]) + continue + ;; + x[Yy][Ee][Ss]) + ;; + *) + if test -z "$_enable"; then + _var=cego_enable + else + _var=cego_"${profile}"_enable + fi + echo "Bad value" \ + "'${_enable:-${cego_enable}}'" \ + "for ${_var}. " \ + "Profile ${profile} skipped." + continue + ;; + esac + echo "===> cego profile: ${profile}" + /etc/rc.d/cego $1 ${profile} + retcode="$?" + if [ "0${retcode}" -ne 0 ]; then + failed="${profile} (${retcode}) ${failed:-}" + else + success="${profile} ${success:-}" + fi + done + exit 0 + fi +fi + +cego_requirepidfile() +{ + if [ ! "0`check_pidfile ${pidfile} ${command}`" -gt 1 ]; then + echo "${name} not running? (check $pidfile)." + exit 1 + fi +} + +cego_stop() { + cego_requirepidfile + + echo "stopping cego instance $1" + kill -1 $1 +} + +run_rc_command "$1" --------------- -- pi@opsec.eu +49 171 3101372 9 years to go !
Responsible Changed From-To: freebsd-ports-bugs->bapt I'll take it.
bapt 2011-04-24 09:54:22 UTC FreeBSD ports repository Modified files: databases/cego Makefile distinfo pkg-plist . GIDs UIDs Added files: databases/cego/files cego.in Log: - update to 2.8.3 - use of USERS/GROUPS macros - add rc script PR: ports/155405 Submitted by: Kurt Jaeger <fbsd-ports _at_ opsec.eu> (maintainer) Revision Changes Path 1.134 +2 -1 ports/GIDs 1.149 +2 -1 ports/UIDs 1.16 +12 -1 ports/databases/cego/Makefile 1.14 +2 -2 ports/databases/cego/distinfo 1.1 +111 -0 ports/databases/cego/files/cego.in (new) 1.7 +1 -0 ports/databases/cego/pkg-plist _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
State Changed From-To: feedback->closed Committed, with minor changes. Thanks!