View | Details | Raw Unified | Return to bug 239881
Collapse All | Expand All

(-)textproc/fzf/Makefile (-26 / +6 lines)
Lines 11-22 Link Here
11
LICENSE=	MIT
11
LICENSE=	MIT
12
LICENSE_FILE=	${WRKSRC}/LICENSE
12
LICENSE_FILE=	${WRKSRC}/LICENSE
13
13
14
USES=		compiler go
14
USES=		compiler go:modules
15
15
16
USE_GITHUB=	yes
16
USE_GITHUB=	yes
17
GH_ACCOUNT=	junegunn
17
GH_ACCOUNT=	junegunn
18
GH_SUBDIR:=	src/github.com/${GH_ACCOUNT}/${PORTNAME}
19
20
GH_TUPLE=	\
18
GH_TUPLE=	\
21
		gdamore:encoding:b23993cbb635:gdamore_encoding/vendor/github.com/gdamore/encoding \
19
		gdamore:encoding:b23993cbb635:gdamore_encoding/vendor/github.com/gdamore/encoding \
22
		gdamore:tcell:0a0db94084df:gdamore_tcell/vendor/github.com/gdamore/tcell \
20
		gdamore:tcell:0a0db94084df:gdamore_tcell/vendor/github.com/gdamore/tcell \
Lines 33-38 Link Here
33
		smartystreets:assertions:b2de0cb4f26d:smartystreets_assertions/vendor/github.com/smartystreets/assertions \
31
		smartystreets:assertions:b2de0cb4f26d:smartystreets_assertions/vendor/github.com/smartystreets/assertions \
34
		smartystreets:goconvey:044398e4856c:smartystreets_goconvey/vendor/github.com/smartystreets/goconvey
32
		smartystreets:goconvey:044398e4856c:smartystreets_goconvey/vendor/github.com/smartystreets/goconvey
35
33
34
GO_BUILDFLAGS=	-ldflags="-X main.revision=0b33dc6 -w"
35
36
SUB_FILES=	pkg-message
36
SUB_FILES=	pkg-message
37
PLIST_FILES=	bin/fzf man/man1/fzf.1.gz
37
PLIST_FILES=	bin/fzf man/man1/fzf.1.gz
38
PORTEXAMPLES=	shell/completion.bash shell/completion.zsh \
38
PORTEXAMPLES=	shell/completion.bash shell/completion.zsh \
Lines 47-80 Link Here
47
TMUX_RUN_DEPENDS=	bash:shells/bash
47
TMUX_RUN_DEPENDS=	bash:shells/bash
48
TMUX_PLIST_FILES=	bin/fzf-tmux man/man1/fzf-tmux.1.gz
48
TMUX_PLIST_FILES=	bin/fzf-tmux man/man1/fzf-tmux.1.gz
49
49
50
GOENV=		GOPATH=${WRKSRC} CGO_CFLAGS="${CGO_CFLAGS}" \
50
post-install:
51
		CGO_LDFLAGS="${CGO_LDFLAGS}" GOBIN=""
51
	${INSTALL_MAN} ${WRKSRC}/man/man1/fzf.1 ${STAGEDIR}${MANPREFIX}/man/man1
52
53
do-build:
54
	cd ${WRKSRC}/src/github.com/${GH_ACCOUNT_DEFAULT}/${PORTNAME} && \
55
	${SETENV} ${MAKE_ENV} ${GOENV} ${GO_CMD} build -a \
56
		-ldflags "-X main.revision=0b33dc6 -w" -o bin/${PORTNAME}
57
58
do-install:
59
	${INSTALL_PROGRAM} ${WRKSRC}/src/github.com/${GH_ACCOUNT_DEFAULT}/${PORTNAME}/bin/${PORTNAME} \
60
		${STAGEDIR}${PREFIX}/bin/${PORTNAME}
61
	${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
52
	${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
62
	(cd ${WRKSRC} && \
53
	(cd ${WRKSRC} && \
63
	    ${COPYTREE_SHARE} shell ${STAGEDIR}${EXAMPLESDIR})
54
	    ${COPYTREE_SHARE} shell ${STAGEDIR}${EXAMPLESDIR})
64
55
65
post-install:
66
	${INSTALL_MAN} ${WRKSRC}/man/man1/fzf.1 ${STAGEDIR}${MANPREFIX}/man/man1
67
68
post-install-TMUX-on:
56
post-install-TMUX-on:
69
	${INSTALL_SCRIPT} ${WRKSRC}/bin/${PORTNAME}-tmux ${STAGEDIR}${PREFIX}/bin
57
	${INSTALL_SCRIPT} ${WRKSRC}/bin/${PORTNAME}-tmux ${STAGEDIR}${PREFIX}/bin
70
	${INSTALL_MAN} ${WRKSRC}/man/man1/fzf-tmux.1 ${STAGEDIR}${MANPREFIX}/man/man1
58
	${INSTALL_MAN} ${WRKSRC}/man/man1/fzf-tmux.1 ${STAGEDIR}${MANPREFIX}/man/man1
71
59
72
.include <bsd.port.pre.mk>
60
.include <bsd.port.mk>
73
74
# If cc is clang, change it to clang to help Go identify the compiler,
75
# else we get -pthread warnings
76
.if ${COMPILER_TYPE} == "clang" && ${CC} == "cc"
77
CC=clang
78
.endif
79
80
.include <bsd.port.post.mk>

Return to bug 239881