ports/132454: ca_root-nss won't build if ../share/certs directory exists

Michael Scheidell scheidell at secnap.net
Mon Mar 9 13:30:06 UTC 2009


>Number:         132454
>Category:       ports
>Synopsis:       ca_root-nss won't build if ../share/certs directory exists
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Mar 09 13:30:00 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator:     Michael Scheidell
>Release:        6.4/7.1
>Organization:
SECNAP Network Security
>Environment:
uname -a
FreeBSD mx1.bct.ionspam.net 6.4-RELEASE FreeBSD 6.4-RELEASE #1: Sat Dec 27 13:59:50 EST 2008     scheidell at scanner.secnap.net:/usr/obj/usr/src/sys/JAILER  i386
>Description:
install of port ca_root_nss will fail if directory  /usr/local/share/certs
 already exists.

 /usr/local/share/certs might already exist for other ports and programs that use shared certs, ca's or csrs.

small patch to Makefile avoids this failure.  verified that make deinstall 'does the right thing' and tries to rmdir but continues.

>How-To-Repeat:
mkdir -p /usr/local/share/certs # (to simulate directory existence)

cd /usr/ports/security/ca_root_nss
make && make install

get this:

Building for ca_root_nss-3.11.9_2
mirror# make install
===>  Installing for ca_root_nss-3.11.9_2
===>   Generating temporary packing list
===>  Checking if security/ca_root_nss already installed
/bin/mkdir -p /usr/local/share/certs
mkdir: /usr/local/share/certs: File exists
*** Error code 1

Stop in /ftp/pub/FreeBSD/ports/security/ca_root_nss.
*** Error code 1

Stop in /ftp/pub/FreeBSD/ports/security/ca_root_nss.


>Fix:
added || true to mkdir line

did NOT bump portversion since if client has successful install, they don't need to reinstall or upgrade. (note, web might (does) mung patch, so watch out for where tabs need to be below.


diff -bBru /tmp/Makefile Makefile
--- /tmp/Makefile       2008-03-17 12:00:45.000000000 -0400
+++ Makefile    2009-03-09 09:14:31.000000000 -0400
@@ -63,7 +63,7 @@
            ${WRKDIR}/ca-root-nss.crt
 
 do-install:
-       ${MKDIR} ${PREFIX}/${CERTDIR}
+       ${MKDIR} ${PREFIX}/${CERTDIR} || true
        ${INSTALL_DATA} ${WRKDIR}/ca-root-nss.crt ${PREFIX}/${CERTDIR}
 .if !defined(WITHOUT_ETCSYMLINK)
        ${LN} -s ${PREFIX}/${CERTDIR}/ca-root-nss.crt /etc/ssl/cert.pem


>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list