|
Lines 16-21
Link Here
|
| 16 |
# GO_TARGET |
16 |
# GO_TARGET |
| 17 |
# The names of the package(s) to build |
17 |
# The names of the package(s) to build |
| 18 |
# |
18 |
# |
|
|
19 |
# GO_EXTRA_PACKAGES |
| 20 |
# Name of any additional packages that are included with the package |
| 21 |
# to be built. Creates additional directories in GOPATH/src as needed |
| 22 |
# |
| 19 |
# CGO_CFLAGS |
23 |
# CGO_CFLAGS |
| 20 |
# Addional CFLAGS variables to be passed to the C compiler by the `go` |
24 |
# Addional CFLAGS variables to be passed to the C compiler by the `go` |
| 21 |
# command |
25 |
# command |
|
Lines 62-72
Link Here
|
| 62 |
GO_SRCDIR=${GO_SRCDIR} \ |
66 |
GO_SRCDIR=${GO_SRCDIR} \ |
| 63 |
GO_PKGNAME=${GO_PKGNAME} |
67 |
GO_PKGNAME=${GO_PKGNAME} |
| 64 |
|
68 |
|
|
|
69 |
.if !empty(GO_EXTRA_PACKAGES) && empty(GO_EXTRA_PACKAGES:M${GO_PKGNAME}) |
| 70 |
GO_EXTRA_PACKAGES+= ${GO_PKGNAME} |
| 71 |
.endif |
| 72 |
|
| 65 |
.if !target(post-extract) |
73 |
.if !target(post-extract) |
| 66 |
post-extract: |
74 |
post-extract: |
|
|
75 |
.if empty(GO_EXTRA_PACKAGES) |
| 67 |
@${MKDIR} ${GO_WRKSRC:H} |
76 |
@${MKDIR} ${GO_WRKSRC:H} |
| 68 |
@${LN} -sf ${WRKSRC} ${GO_WRKSRC} |
77 |
@${LN} -sf ${WRKSRC} ${GO_WRKSRC} |
|
|
78 |
.else |
| 79 |
.for _PACKAGE in ${GO_EXTRA_PACKAGES} |
| 80 |
@if [ -e "${WRKSRC}/src/${_PACKAGE}" ]; then \ |
| 81 |
${MKDIR} ${GO_WRKDIR_SRC}/${_PACKAGE:H}; \ |
| 82 |
${LN} -sf ${WRKSRC}/src/${_PACKAGE} ${GO_WRKDIR_SRC}/${_PACKAGE}; \ |
| 83 |
fi; |
| 84 |
.endfor |
| 69 |
.endif |
85 |
.endif |
|
|
86 |
.endif |
| 70 |
|
87 |
|
| 71 |
.if !target(do-build) |
88 |
.if !target(do-build) |
| 72 |
do-build: |
89 |
do-build: |