Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F168284238
D2735.id5954.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D2735.id5954.diff
View Options
Index: Mk/bsd.port.mk
===================================================================
--- Mk/bsd.port.mk
+++ Mk/bsd.port.mk
@@ -540,12 +540,12 @@
# Default: ${WRKDIRPREFIX}${.CURDIR}/work
# WRKSRC - A subdirectory of ${WRKDIR} where the distribution actually
# unpacks to.
-# Default: ${WRKDIR}/${DISTNAME} unless NO_WRKSUBDIR is set,
-# in which case simply ${WRKDIR}
+# Default: ${WRKDIR}/${DISTNAME}
# WRKSRC_SUBDIR - A subdirectory of ${WRKSRC} where the distribution actually
# builds in.
# Default: not set
-# NO_WRKSUBDIR - Assume port unpacks directly into ${WRKDIR}.
+# NO_WRKSUBDIR - Assume port unpacks without a subdirectory, and extract it in
+# ${WRKSRC} instead of ${WRKDIR}.
# PATCHDIR - A directory containing any additional patches you made
# to port this software to FreeBSD.
# Default: ${MASTERDIR}/files
@@ -1558,10 +1558,13 @@
.if !defined(IGNORE_MASTER_SITE_GITHUB) && defined(USE_GITHUB)
WRKSRC?= ${WRKDIR}/${GH_PROJECT}-${GH_TAGNAME_EXTRACT}
.endif
+WRKSRC?= ${WRKDIR}/${DISTNAME}
+.if !defined(EXTRACT_WRKDIR)
.if defined(NO_WRKSUBDIR)
-WRKSRC?= ${WRKDIR}
+EXTRACT_WRKDIR:= ${WRKSRC}
.else
-WRKSRC?= ${WRKDIR}/${DISTNAME}
+EXTRACT_WRKDIR:= ${WRKDIR}
+.endif
.endif
.if defined(WRKSRC_SUBDIR)
WRKSRC:= ${WRKSRC}/${WRKSRC_SUBDIR}
@@ -3036,7 +3039,7 @@
@${ECHO_MSG} "===> Found saved configuration for ${_OPTIONS_READ}"
.endif
-${PKG_DBDIR} ${PREFIX} ${WRKDIR} ${WRKSRC}:
+${PKG_DBDIR} ${PREFIX} ${WRKDIR} ${EXTRACT_WRKDIR} ${WRKSRC}:
@${MKDIR} ${.TARGET}
# Warn user about deprecated packages. Advisory only.
@@ -3258,9 +3261,9 @@
@${RM} -rf ${WRKDIR}
.if !target(do-extract)
-do-extract:
+do-extract: ${EXTRACT_WRKDIR}
@for file in ${EXTRACT_ONLY}; do \
- if ! (cd ${WRKDIR} && ${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} ${_DISTDIR}/$$file ${EXTRACT_AFTER_ARGS});\
+ if ! (cd ${EXTRACT_WRKDIR} && ${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} ${_DISTDIR}/$$file ${EXTRACT_AFTER_ARGS});\
then \
exit 1; \
fi; \
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Aug 28, 9:52 AM (2 h, 12 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
37448181
Default Alt Text
D2735.id5954.diff (1 KB)
Attached To
Mode
D2735: Change the meaning of NO_WRKSUBDIR to force a WRKDIR != WRKSRC.
Attached
Detach File
Event Timeline
Log In to Comment