Check-in [408c12ee83]

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:use compact test syntax wrap long lines return by default returns 0 ECHO_CMD defined as sh builtin and always return 0, therefore change && to ;

Submitted by: Alex Kozlov (ak@)

Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 408c12ee830ae0ca73288a859e50be6d30638595
User & Date: bapt 2012-06-18 05:43:43
Context
2012-06-19
04:24
Fix error when no pkg-{install,message} exists check-in: 511d3ad7a2 user: bdrewery tags: trunk
2012-06-18
05:43
use compact test syntax wrap long lines return by default returns 0 ECHO_CMD defined as sh builtin and always return 0, therefore change && to ;

Submitted by: Alex Kozlov (ak@) check-in: 408c12ee83 user: bapt tags: trunk

2012-06-16
15:22
Sync with latest version check-in: ee2ba26bcd user: bapt tags: trunk
Changes

Changes to ports/Mk/bsd.stage.mk.

20
21
22
23
24
25
26
27
28
29

30
31
32
33
34
35
36
37
38

39
40
41
42
43
44
45
46
..
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64

.if !target(sync-from-stage)
sync-from-stage: stage
.if defined(WITH_PKGNG)
	@${DO_NADA}
.else
	@${ECHO_MSG} "===> Syncing from stagedir"
	@${SH} ${PORTSDIR}/Tools/scripts/sync_from_stage.sh -f ${STAGEDIR} -p ${TMPPLIST} -P ${PREFIX} -w ${WRKDIR}

	@if [ -f ${PKGINSTALL} ]; then \

		${SH} ${PKGINSTALL} POST-INSTALL; \
	fi
	@[ -f ${PKGMESSAGE} ] && ${CAT} ${PKGMESSAGE} || return 0
.endif
.endif

.if !target(genplist)
genplist: stage
	@(${ECHO_CMD} "#mtree" && ${CAT} ${MTREE_FILE}) | ${TAR} tf - | \

		awk '{ sub(/^\.$$/, "", $$1); if ($$1 == "") print "${PREFIX}"; else print "${PREFIX}/"$$1; }' \
		> ${WRKDIR}/.mtree
	@a=${PREFIX}; \
		while :; do \
			a=$${a%/*} ; \
			[ -z "$${a}" ] && break ; \
			${ECHO_CMD} $${a} >> ${WRKDIR}/.mtree ; \
		done
................................................................................
		-e "s,${DOCSDIR},%%PORTDOCS%%%%DOCSDIR%%,g" \
		-e "s,${EXAMPLESDIR},%%PORTEXAMPLES%%%%EXAMPLESDIR%%,g" \
		-e "s,${DATADIR},%%DATADIR%%,g" \
		-e "s,${PREFIX}/,,g" | sort
	@${FIND} ${STAGEDIR} -type d | sed -e "s,${STAGEDIR},,g" \
		| while read line; do \
		${GREP} -qw "^$${line}$$" ${WRKDIR}/.mtree || { \
			if [ -n "$${line}" ]; then \
				${ECHO_CMD} "@dirrm $${line}"; \
			fi ; \
		}; \
		done | ${SORT} -r | ${SED} \
		-e "s,\(.*\)${DOCSDIR},%%PORTDOCS%%\1%%DOCSDIR%%,g" \
		-e "s,\(.*\)${EXAMPLESDIR},%%PORTEXAMPLES%%\1%%EXAMPLESDIR%%,g" \
		-e "s,${DATADIR},%%DATADIR%%,g" \
		-e "s,${PREFIX},,g"
.endif







|
<
<
>
|
<
|





|
>
|







 







<
|
<







20
21
22
23
24
25
26
27


28
29

30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
..
47
48
49
50
51
52
53

54

55
56
57
58
59
60
61

.if !target(sync-from-stage)
sync-from-stage: stage
.if defined(WITH_PKGNG)
	@${DO_NADA}
.else
	@${ECHO_MSG} "===> Syncing from stagedir"
	@${SH} ${PORTSDIR}/Tools/scripts/sync_from_stage.sh -f ${STAGEDIR} \


		-p ${TMPPLIST} -P ${PREFIX} -w ${WRKDIR}
	@[ -f ${PKGINSTALL} ] && ${SH} ${PKGINSTALL} POST-INSTALL

	@[ -f ${PKGMESSAGE} ] && ${CAT} ${PKGMESSAGE} || return
.endif
.endif

.if !target(genplist)
genplist: stage
	@(${ECHO_CMD} "#mtree"; ${CAT} ${MTREE_FILE}) | ${TAR} tf - | \
		awk '{ sub(/^\.$$/, "", $$1); \
		if ($$1 == "") print "${PREFIX}"; else print "${PREFIX}/"$$1; }' \
		> ${WRKDIR}/.mtree
	@a=${PREFIX}; \
		while :; do \
			a=$${a%/*} ; \
			[ -z "$${a}" ] && break ; \
			${ECHO_CMD} $${a} >> ${WRKDIR}/.mtree ; \
		done
................................................................................
		-e "s,${DOCSDIR},%%PORTDOCS%%%%DOCSDIR%%,g" \
		-e "s,${EXAMPLESDIR},%%PORTEXAMPLES%%%%EXAMPLESDIR%%,g" \
		-e "s,${DATADIR},%%DATADIR%%,g" \
		-e "s,${PREFIX}/,,g" | sort
	@${FIND} ${STAGEDIR} -type d | sed -e "s,${STAGEDIR},,g" \
		| while read line; do \
		${GREP} -qw "^$${line}$$" ${WRKDIR}/.mtree || { \

			[ -n "$${line}" ] && ${ECHO_CMD} "@dirrm $${line}"; \

		}; \
		done | ${SORT} -r | ${SED} \
		-e "s,\(.*\)${DOCSDIR},%%PORTDOCS%%\1%%DOCSDIR%%,g" \
		-e "s,\(.*\)${EXAMPLESDIR},%%PORTEXAMPLES%%\1%%EXAMPLESDIR%%,g" \
		-e "s,${DATADIR},%%DATADIR%%,g" \
		-e "s,${PREFIX},,g"
.endif