View | Details | Raw Unified | Return to bug 220361 | Differences between
and this patch

Collapse All | Expand All

(-)ripgrep/Makefile (+31 lines)
Lines 5-10 Link Here
5
5
6
PORTNAME=	ripgrep
6
PORTNAME=	ripgrep
7
PORTVERSION=	0.5.2
7
PORTVERSION=	0.5.2
8
PORTREVISION=	1
8
CATEGORIES=	textproc
9
CATEGORIES=	textproc
9
10
10
MAINTAINER=	petteri.valkonen@iki.fi
11
MAINTAINER=	petteri.valkonen@iki.fi
Lines 13-26 Link Here
13
LICENSE=	MIT UNLICENSE
14
LICENSE=	MIT UNLICENSE
14
LICENSE_COMB=	dual
15
LICENSE_COMB=	dual
15
LICENSE_FILE=	${WRKSRC}/COPYING
16
LICENSE_FILE=	${WRKSRC}/COPYING
17
LICENSE_FILE_MIT=	${WRKSRC}/LICENSE-MIT
16
LICENSE_FILE_UNLICENSE=	${WRKSRC}/UNLICENSE
18
LICENSE_FILE_UNLICENSE=	${WRKSRC}/UNLICENSE
17
19
18
USES=		cargo
20
USES=		cargo
19
USE_GITHUB=	yes
21
USE_GITHUB=	yes
20
GH_ACCOUNT=	BurntSushi
22
GH_ACCOUNT=	BurntSushi
21
23
24
OPTIONS_DEFINE=	BASH FISH ZSH
25
OPTIONS_DEFAULT=BASH FISH ZSH
26
FISH_DESC=	Install programmable completions for Fish
27
22
PLIST_FILES=	bin/rg \
28
PLIST_FILES=	bin/rg \
23
		man/man1/rg.1.gz
29
		man/man1/rg.1.gz
30
BASH_PLIST_FILES=	etc/bash_completion.d/rg.bash-completion
31
FISH_PLIST_FILES=	share/fish/completions/rg.fish
32
ZSH_PLIST_FILES=	share/zsh/site-functions/_rg
24
33
25
CARGO_CRATES=	aho-corasick-0.6.3 \
34
CARGO_CRATES=	aho-corasick-0.6.3 \
26
		ansi_term-0.9.0 \
35
		ansi_term-0.9.0 \
Lines 59-65 Link Here
59
		winapi-0.2.8 \
68
		winapi-0.2.8 \
60
		winapi-build-0.1.1
69
		winapi-build-0.1.1
61
70
71
CARGO_OUTDIR=${WRKDIR}/cargo-out
72
73
post-patch:
74
	@${REINPLACE_CMD} -e 's|%%CARGO_OUTDIR%%|${CARGO_OUTDIR}|' \
75
		${WRKSRC}/build.rs
76
62
post-install:
77
post-install:
78
	${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/rg
63
	${INSTALL_MAN} ${WRKSRC}/doc/rg.1 ${STAGEDIR}${MAN1PREFIX}/man/man1
79
	${INSTALL_MAN} ${WRKSRC}/doc/rg.1 ${STAGEDIR}${MAN1PREFIX}/man/man1
64
80
81
post-install-BASH-on:
82
	@${MKDIR} ${STAGEDIR}${PREFIX}/etc/bash_completion.d/
83
	${INSTALL_DATA} ${CARGO_OUTDIR}/rg.bash-completion \
84
		${STAGEDIR}${PREFIX}/etc/bash_completion.d/
85
86
post-install-FISH-on:
87
	@${MKDIR} ${STAGEDIR}${PREFIX}/share/fish/completions/
88
	${INSTALL_DATA} ${CARGO_OUTDIR}/rg.fish \
89
		${STAGEDIR}${PREFIX}/share/fish/completions/
90
91
post-install-ZSH-on:
92
	@${MKDIR} ${STAGEDIR}${PREFIX}/share/zsh/site-functions/
93
	${INSTALL_DATA} ${CARGO_OUTDIR}/_rg \
94
		${STAGEDIR}${PREFIX}/share/zsh/site-functions/
95
65
.include <bsd.port.mk>
96
.include <bsd.port.mk>
(-)ripgrep/files/patch-build.rs (+22 lines)
Line 0 Link Here
1
--- build.rs.orig	2017-05-11 23:12:20 UTC
2
+++ build.rs
3
@@ -3,7 +3,6 @@ extern crate clap;
4
 #[macro_use]
5
 extern crate lazy_static;
6
 
7
-use std::env;
8
 use std::fs;
9
 
10
 use clap::Shell;
11
@@ -13,10 +12,7 @@ use clap::Shell;
12
 mod app;
13
 
14
 fn main() {
15
-    let outdir = match env::var_os("OUT_DIR") {
16
-        None => return,
17
-        Some(outdir) => outdir,
18
-    };
19
+    let outdir = "%%CARGO_OUTDIR%%";
20
     fs::create_dir_all(&outdir).unwrap();
21
 
22
     let mut app = app::app();

Return to bug 220361