Maintainer update of mail/mutt: - Fix build on FreeBSd-8.x Committer: new file to be added to repo: files/patch-nessus-Makefile
Responsible Changed From-To: freebsd-ports-bugs->tijl Take.
On Fri, 25 Oct 2013 22:22:30 +0200 Tijl Coosemans wrote: > Please review the attached patch. Feel free to make/suggest any changes. Build logs: https://redports.org/buildarchive/20131025175701-42709/
On Fri, 25 Oct 2013 22:22:30 +0200 Tijl Coosemans wrote: > Please review the attached patch. Feel free to make/suggest any changes. > > I discovered that the real problem was that the makefiles in the packages > aren't safe for parallel building so simply adding MAKE_JOBS_UNSAFE is > enough to fix this PR. At first I tried to fix the makefiles but it's > just too much work. In one makefile there are multiple targets that call > make on the same subdirectory so when those targets are built in parallel > there are multiple jobs building that subdir at the same time. And that's > not all, that subdir does the same with its own subdir... so adding > MAKE_JOBS_UNSAFE is the easiest. > > Additional changes in the patch (mostly in order of appearance): > - Move DIST_SUBDIR up. This seems to be where portlint wants it. > - Add LICENSE. > - Use new style LIB_DEPENDS. > - Remove pkg-deinstall from SUB_FILES and move files/pkg-deinstall.in to > pkg-deinstall. In pkg-deinstall replace %%PKGNAME%% with plain "nessus" > and %%PREFIX%% with ${PKG_PREFIX}. > - Add a GTK2 user option that replaces the GNOME auto-detection. > - Add nessusd.conf to SUB_FILES and move files/nessusd.conf to > files/nessusd.conf.in. In files/nessusd.conf.in replace ${PREFIX} with > %%PREFIX%%. This allows removing the first SED in post-install. > - Also remove the second SED in post-install because nessusd.rules doesn't > contain ${PREFIX}. > - Install nessusd.conf and nessud.rules using INSTALL_DATA. This allows > removing the CHMOD in post-install. > - Support staging: > * Move manpages to pkg-plist. > * Remove "if [...] ${CP} ..." from post-install. This is handled from > pkg-plist. > * Move messages about certificate creation to pkg-message. I also > removed the cert target because it seems less useful now, but let > me know if you want to keep it. > - Remove move_nessus script. All configurations should have been moved > by now. > - Add var/nessus/tmp to pkg-plist. Have you had a chance to look into this?
On Sat, Nov 09, 2013 at 16:30:57 +0100, Tijl Coosemans wrote: > Have you had a chance to look into this? > Sorry, I thought I already had answered (which I hadn't). Anyway: this is completely OK for me and it works flawlessly. Thanks for the work on this. Udo
Author: tijl Date: Mon Nov 11 18:48:29 2013 New Revision: 333529 URL: http://svnweb.freebsd.org/changeset/ports/333529 Log: - Add LICENSE. - New LIB_DEPENDS syntax. - Staging. - Replace gtk detection with GTK2 option. - Mark MAKE_JOBS_UNSAFE for now. One Makefile has mutilple targets that each call make in the same subdirectory and the Makefile in that directory does the same with one of its subdirectories. - Move files/nessusd.conf to files/nessusd.conf.in and add it to SUB_FILES instead of calling sed from post-install. - Move files/pkg-deinstall.in to pkg-deinstall and replace %%PREFIX%% with ${PKG_PREFIX}. - Remove scripts/move_nessus. It was used to migrate configuration data to a new location. PR: ports/183221 Approved by: "Schweigert, Udo" <Udo.Schweigert@siemens.com> (maintainer) Added: head/security/nessus/files/nessusd.conf.in (contents, props changed) - copied, changed from r333526, head/security/nessus/files/nessusd.conf head/security/nessus/pkg-deinstall (contents, props changed) - copied, changed from r331559, head/security/nessus/files/pkg-deinstall.in Deleted: head/security/nessus/files/nessusd.conf head/security/nessus/files/pkg-deinstall.in head/security/nessus/scripts/ Modified: head/security/nessus/Makefile (contents, props changed) head/security/nessus/pkg-message (contents, props changed) head/security/nessus/pkg-plist (contents, props changed) Modified: head/security/nessus/Makefile ============================================================================== --- head/security/nessus/Makefile Mon Nov 11 17:54:33 2013 (r333528) +++ head/security/nessus/Makefile Mon Nov 11 18:48:29 2013 (r333529) @@ -3,7 +3,7 @@ PORTNAME= nessus PORTVERSION= 2.2.9 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= security MASTER_SITES= ftp://ftp.nessus.org/pub/nessus/nessus-${PORTVERSION}/src/ \ ftp://ftp.gwdg.de/pub/linux/misc/nessus/nessus-${PORTVERSION}/src/ \ @@ -11,71 +11,32 @@ MASTER_SITES= ftp://ftp.nessus.org/pub/n ftp://sunsite.cnlab-switch.ch/mirror/nessus/nessus-${PORTVERSION}/src/ \ ftp://ftp.ayamura.org/pub/nessus/nessus-${PORTVERSION}/src/ DISTNAME= nessus-core-${PORTVERSION} +DIST_SUBDIR= nessus MAINTAINER= udo.schweigert@siemens.com COMMENT= Security scanner: looks for vulnerabilities in a given network -LIB_DEPENDS= nasl.4:${PORTSDIR}/security/nessus-libnasl +LICENSE= GPLv2 -DIST_SUBDIR= nessus -WRKSRC= ${WRKDIR}/nessus-core -SUB_FILES= pkg-deinstall -SUB_LIST= PKGNAME=${PKGNAME} +LIB_DEPENDS= libnasl.so:${PORTSDIR}/security/nessus-libnasl + +OPTIONS_DEFINE= GTK2 +OPTIONS_DEFAULT=GTK2 + +GTK2_CONFIGURE_ENABLE= gtk +GTK2_USES= pkgconfig +GTK2_USE= GNOME=gtk20 GNU_CONFIGURE= yes +MAKE_JOBS_UNSAFE= yes +SUB_FILES= nessusd.conf USE_RC_SUBR= nessusd -WANT_GNOME= yes -.if defined(WITHOUT_NESSUS_GTK) || defined(WITHOUT_GTK) -WITHOUT_GNOME= yes -.endif - -NO_STAGE= yes -.include <bsd.port.pre.mk> - -.if ${HAVE_GNOME:Mgtk20}!="" -USE_GNOME+= gtk20 -PKGNAMESUFFIX+= -gtk2 -.elif ${HAVE_GNOME:Mgtk12}!="" -USE_GNOME+= gtk12 -PKGNAMESUFFIX+= -gtk -.else -CONFIGURE_ARGS+=--disable-gtk -.endif - -MAN1= nessus.1 nessus-mkrand.1 nessus-mkcert-client.1 nessus-fetch.1 -MAN8= nessusd.8 nessus-adduser.8 nessus-mkcert.8 nessus-rmuser.8 +WRKSRC= ${WRKDIR}/nessus-core post-install: - @${SED} -e 's;\$${PREFIX};${PREFIX};' ${FILESDIR}/nessusd.conf \ - > ${PREFIX}/etc/nessus/nessusd.conf.dist - @${SED} -e 's;\$${PREFIX};${PREFIX};' ${FILESDIR}/nessusd.rules \ - > ${PREFIX}/etc/nessus/nessusd.rules.dist - @${CHMOD} 644 ${PREFIX}/etc/nessus/nessusd.conf.dist \ - ${PREFIX}/etc/nessus/nessusd.rules.dist - @if [ ! -f ${PREFIX}/etc/nessus/nessusd.conf ]; then \ - ${CP} -p ${PREFIX}/etc/nessus/nessusd.conf.dist \ - ${PREFIX}/etc/nessus/nessusd.conf; \ - fi - @if [ ! -f ${PREFIX}/etc/nessus/nessusd.rules ]; then \ - ${CP} -p ${PREFIX}/etc/nessus/nessusd.rules.dist \ - ${PREFIX}/etc/nessus/nessusd.rules; \ - fi - @${SETENV} ${SCRIPTS_ENV} ${SH} ${SCRIPTDIR}/move_nessus -.if ! exists(${PREFIX}/var/CA/serverkey.pem) - @${ECHO} "" - @${ECHO} "**************************************************************************" - @${ECHO} "To create and install a new certificate, type \"make cert\"" - @${ECHO} "**************************************************************************" - @${ECHO} "" -.endif - @${CAT} ${PKGMESSAGE} - -cert: - @${ECHO} "" - @${ECHO} "**************************************************************************" - @${ECHO} "The new certificate will be saved into ${PREFIX}/var/CA/serverkey.pem" - @${ECHO} "**************************************************************************" - @${ECHO} "" - ${PREFIX}/sbin/nessus-mkcert + ${INSTALL_DATA} ${WRKDIR}/nessusd.conf \ + ${STAGEDIR}${ETCDIR}/nessusd.conf.dist + ${INSTALL_DATA} ${FILESDIR}/nessusd.rules \ + ${STAGEDIR}${ETCDIR}/nessusd.rules.dist -.include <bsd.port.post.mk> +.include <bsd.port.mk> Copied and modified: head/security/nessus/files/nessusd.conf.in (from r333526, head/security/nessus/files/nessusd.conf) ============================================================================== --- head/security/nessus/files/nessusd.conf Mon Nov 11 17:26:22 2013 (r333526, copy source) +++ head/security/nessus/files/nessusd.conf.in Mon Nov 11 18:48:29 2013 (r333529) @@ -5,7 +5,7 @@ # Every line starting with a '#' is a comment # Path to the security checks folder : -plugins_folder = ${PREFIX}/lib/nessus/plugins +plugins_folder = %%PREFIX%%/lib/nessus/plugins # Maximum number of simultaneous hosts tested : max_hosts = 30 @@ -17,7 +17,7 @@ max_checks = 10 be_nice = no # Log file (or 'syslog') : -logfile = ${PREFIX}/var/nessus/logs/nessusd.messages +logfile = %%PREFIX%%/var/nessus/logs/nessusd.messages # Shall we log every details of the attack ? log_whole_attack = yes @@ -26,13 +26,13 @@ log_whole_attack = yes log_plugins_name_at_load = no # Dump file for debugging output, use `-' for stdout -dumpfile = ${PREFIX}/var/nessus/logs/nessusd.dump +dumpfile = %%PREFIX%%/var/nessus/logs/nessusd.dump # Rules file : -rules = ${PREFIX}/etc/nessus/nessusd.rules +rules = %%PREFIX%%/etc/nessus/nessusd.rules # Users database : -users = ${PREFIX}/etc/nessus/nessusd.users +users = %%PREFIX%%/etc/nessus/nessusd.users # CGI paths to check for (cgi-bin:/cgi-aws:/ can do) cgi_path = /cgi-bin:/scripts @@ -110,9 +110,9 @@ nasl_no_signature_check = no # # Added by nessus-mkcert # -cert_file=${PREFIX}/com/CA/servercert.pem -key_file=${PREFIX}/var/CA/serverkey.pem -ca_file=${PREFIX}/com/CA/cacert.pem +cert_file=%%PREFIX%%/com/CA/servercert.pem +key_file=%%PREFIX%%/var/CA/serverkey.pem +ca_file=%%PREFIX%%/com/CA/cacert.pem # If you decide to protect your private key with a password, # uncomment and change next line # pem_password=password Copied and modified: head/security/nessus/pkg-deinstall (from r331559, head/security/nessus/files/pkg-deinstall.in) ============================================================================== --- head/security/nessus/files/pkg-deinstall.in Fri Oct 25 07:11:22 2013 (r331559, copy source) +++ head/security/nessus/pkg-deinstall Mon Nov 11 18:48:29 2013 (r333529) @@ -8,22 +8,22 @@ ECHO_CMD=echo case $2 in POST-DEINSTALL) ${ECHO_CMD} - ${ECHO_CMD} "The %%PKGNAME%% server package has been deleted." + ${ECHO_CMD} "The nessus server package has been deleted." ${ECHO_CMD} "If you're *not* upgrading and won't be using" ${ECHO_CMD} "it any longer, you may want to issue the" ${ECHO_CMD} "following commands:" ${ECHO_CMD} - if [ -d %%PREFIX%%/var/nessus ]; then + if [ -d ${PKG_PREFIX}/var/nessus ]; then ${ECHO_CMD} "- to delete the nessus server permanently (losing all data):" - ${ECHO_CMD} " rm -Rf %%PREFIX%%/var/nessus" + ${ECHO_CMD} " rm -Rf ${PKG_PREFIX}/var/nessus" ${ECHO_CMD} fi rm_dir="" - if [ -d %%PREFIX%%/com/CA ]; then - rm_dir=" %%PREFIX%%/com/CA" + if [ -d ${PKG_PREFIX}/com/CA ]; then + rm_dir=" ${PKG_PREFIX}/com/CA" fi - if [ -d %%PREFIX%%/var/CA ]; then - rm_dir="$rm_dir %%PREFIX%%/var/CA" + if [ -d ${PKG_PREFIX}/var/CA ]; then + rm_dir="$rm_dir ${PKG_PREFIX}/var/CA" fi if [ "x$rm_dir" != "x" ]; then ${ECHO_CMD} "- to remove the Certificate Authority associated with nessus:" Modified: head/security/nessus/pkg-message ============================================================================== --- head/security/nessus/pkg-message Mon Nov 11 17:54:33 2013 (r333528) +++ head/security/nessus/pkg-message Mon Nov 11 18:48:29 2013 (r333529) @@ -8,3 +8,7 @@ Available variables you add/set to /etc/ - nessusd_enable (bool): Set to "NO" by default. Set it to "YES" to enable nessusd. - nessusd_flags (str): Set to "-D" by default. + +************************************************************************** +To create and install a new certificate, run nessus-mkcert +************************************************************************** Modified: head/security/nessus/pkg-plist ============================================================================== --- head/security/nessus/pkg-plist Mon Nov 11 17:54:33 2013 (r333528) +++ head/security/nessus/pkg-plist Mon Nov 11 18:48:29 2013 (r333529) @@ -17,20 +17,31 @@ include/nessus/nessusraw.h include/nessus/nessustcp.h include/nessus/nessusudp.h include/nessus/ntcompat.h +man/man1/nessus.1.gz +man/man1/nessus-mkrand.1.gz +man/man1/nessus-mkcert-client.1.gz +man/man1/nessus-fetch.1.gz +man/man8/nessusd.8.gz +man/man8/nessus-adduser.8.gz +man/man8/nessus-mkcert.8.gz +man/man8/nessus-rmuser.8.gz sbin/nessus-adduser sbin/nessus-check-signature sbin/nessus-mkcert sbin/nessus-rmuser sbin/nessusd +var/nessus/nessus-services @exec mkdir -p %D/var/nessus/jobs @exec mkdir -p %D/var/nessus/logs +@exec mkdir -p %D/var/nessus/tmp @exec mkdir -p %D/var/nessus/users @unexec if [ ! -s %D/var/nessus/logs/nessusd.messages ]; then rm %D/var/nessus/logs/nessusd.messages 2> /dev/null; fi || true @dirrmtry var/nessus/jobs @dirrmtry var/nessus/logs +@dirrmtry var/nessus/tmp @dirrmtry var/nessus/users -var/nessus/nessus-services @dirrmtry var/nessus +@dirrmtry var @dirrmtry etc/nessus @exec mkdir -p %D/lib/nessus/plugins @dirrmtry lib/nessus/plugins _______________________________________________ svn-ports-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-ports-all To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
State Changed From-To: open->closed Committed in r333529.