Author: bdrewery
Date: Thu Sep  3 17:01:58 2015
New Revision: 287436
URL: https://svnweb.freebsd.org/changeset/base/287436

Log:
  Avoid sub-shell for realpath(1) for bmake by using its built-in :tA.
  
  MFC after:    2 weeks
  Approved by:  portmgr (implicit)

Modified:
  head/share/mk/bsd.port.mk
  head/share/mk/bsd.port.subdir.mk

Modified: head/share/mk/bsd.port.mk
==============================================================================
--- head/share/mk/bsd.port.mk   Thu Sep  3 16:43:35 2015        (r287435)
+++ head/share/mk/bsd.port.mk   Thu Sep  3 17:01:58 2015        (r287436)
@@ -10,8 +10,12 @@ _PORTSDIR=   ${.CURDIR}/${RELPATH}
 .endif
 .endfor
 _PORTSDIR?=    /usr/ports
+.if defined(.PARSEDIR)
+PORTSDIR=      ${_PORTSDIR:tA}
+.else # fmake doesn't have :tA
 PORTSDIR!=     realpath ${_PORTSDIR}
 .endif
+.endif
 
 BSDPORTMK?=    ${PORTSDIR}/Mk/bsd.port.mk
 

Modified: head/share/mk/bsd.port.subdir.mk
==============================================================================
--- head/share/mk/bsd.port.subdir.mk    Thu Sep  3 16:43:35 2015        
(r287435)
+++ head/share/mk/bsd.port.subdir.mk    Thu Sep  3 17:01:58 2015        
(r287436)
@@ -10,8 +10,12 @@ _PORTSDIR=   ${.CURDIR}/${RELPATH}
 .endif
 .endfor
 _PORTSDIR?=    /usr/ports
+.if defined(.PARSEDIR)
+PORTSDIR=      ${_PORTSDIR:tA}
+.else # fmake doesn't have :tA
 PORTSDIR!=     realpath ${_PORTSDIR}
 .endif
+.endif
 
 BSDPORTSUBDIRMK?=      ${PORTSDIR}/Mk/bsd.port.subdir.mk
 
_______________________________________________
svn-src-head@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to