Subject: Re: devel/nss and Linux
To: Matthew Luckie <>
From: Jeremy C. Reed <>
List: tech-pkg
Date: 08/12/2005 12:14:25
On Thu, 7 Jul 2005, Matthew Luckie wrote:

> the patch below *should* fix this, but I'm unable to test and confirm it.
> can you review/check?  It doesn't seem to break anything on my NetBSD
> system.

I did it a little different. First my comments here and then my patch 

> +NSS_OBJ_DIR+=  ${SED} -e 's/^\([[:digit:]]\.[[:digit:]]\)\..*$/\1/'

The sed is not ran but added to this line. Also each component of this is 
separated by a space.

> +.if ${MACHINE_ARCH} == "i386"
> +NSS_OBJ_DIR+=  _x86

Also separated by a space.

> +NSS_OBJ_DIR+=  _glibc_PTH_OPT.OBJ

Missing /lib at end.

So I did it this way:

+.if ${OPSYS} == "NetBSD" || ${OPSYS} == "FreeBSD"
+.elif ${OPSYS} == "Linux"
+.if ${MACHINE_ARCH} == "i386"
+.elif ${MACHINE_ARCH} == "parisc" || ${MACHINE_ARCH} == "parisc64"
+.elif ${MACHINE_ARCH} == "sparc64"
  	${INSTALL_DATA_DIR} ${PREFIX}/include/nss
  	${INSTALL_DATA_DIR} ${PREFIX}/lib/nss
  	(cd ${DIST}/public && ${PAX} -Lrwpe . ${PREFIX}/include/nss/ )
-	(cd ${DIST}/${OPSYS}${OS_VERSION}_OPT.OBJ/lib && \
+	(cd ${DIST}/${NSS_OBJ_DIR}/lib && \
  		${PAX} -Lrwpe *.${SO_SUFFIX} ${PREFIX}/lib/nss/ )

Also I changed the build to get rid of the BSD_LDOPTS to just define 
LD_LIBS instead:


And the patch-af using BSD_LDOPTS can be removed.

I haven't tested this with DragonFly yet (for the PR #30711), but did some 
testing with NetBSD 2.0.2 and Linux 2.6.x.

  Jeremy C. Reed

  	  	 	 BSD News, BSD tutorials, BSD links