Re: UPDATE: textproc/ripgrep-0.10.0 (with request for help)

2018-11-28 Thread Sebastien Marie
On Tue, Nov 27, 2018 at 06:03:13PM -0600, Edward Lopez-Acosta wrote:
> WANTLIB fixed, it did add an extra entry (c++abi), I am fairly certain I
> sorted out the tabs vs spaces in the list. Is there a way to preserve this
> when I make the crate list and import it into the Makefile?

copy/paste could replace tab by spaces.

usually, I am doing something like:

$ make modcargo-gen-crates-licenses > foo

and use ":read foo" from vim.

> Thank you for the patience and hopefully this diff is clean. First time ever
> even looking at anything in Rust on my end.

the diff is OK semarie@ . if someone want to take a look and commit it,
it is possible. else I will commit it tomorrow.

Thanks.
-- 
Sebastien Marie

> diff --git Makefile Makefile
> index 16d2c678d98..2f06334c405 100644
> --- Makefile
> +++ Makefile
> @@ -4,16 +4,14 @@ COMMENT =   line oriented search tool using Rust's 
> regex library #'
>  
>  GH_ACCOUNT = BurntSushi
>  GH_PROJECT = ripgrep
> -GH_TAGNAME = 0.8.1
> -REVISION =   2
> +GH_TAGNAME = 0.10.0
>  
>  CATEGORIES = textproc sysutils
>  
>  # Unlicense/MIT
>  PERMIT_PACKAGE_CDROM =   Yes
>  
> -# uses pledge()
> -WANTLIB += c pthread
> +WANTLIB += c c++abi pthread
>  
>  # as devel/cargo MODULES adds DISTFILES, GH_* didn't
>  DISTFILES += ${DISTNAME}${EXTRACT_SUFX}
> @@ -22,52 +20,83 @@ MODULES = devel/cargo
>  BUILD_DEPENDS =  lang/rust>=1.20 \
>   textproc/asciidoc
>  
> -MODCARGO_CRATES +=   aho-corasick-0.6.4  # Unlicense/MIT
> -MODCARGO_CRATES +=   ansi_term-0.10.2# MIT
> -MODCARGO_CRATES +=   atty-0.2.6  # MIT
> -MODCARGO_CRATES +=   bitflags-1.0.1  # MIT/Apache-2.0
> -MODCARGO_CRATES +=   bytecount-0.3.1 # Apache-2.0/MIT
> -MODCARGO_CRATES +=   cfg-if-0.1.2# MIT/Apache-2.0
> -MODCARGO_CRATES +=   clap-2.30.0 # MIT
> -MODCARGO_CRATES +=   crossbeam-0.3.2 # Apache-2.0/MIT
> -MODCARGO_CRATES +=   encoding_rs-0.7.2   # MIT/Apache-2.0
> +MODCARGO_CRATES +=   aho-corasick-0.6.8  # Unlicense/MIT
> +MODCARGO_CRATES +=   arrayvec-0.4.7  # MIT/Apache-2.0
> +MODCARGO_CRATES +=   atty-0.2.11 # MIT
> +MODCARGO_CRATES +=   base64-0.9.2# MIT/Apache-2.0
> +MODCARGO_CRATES +=   bitflags-1.0.4  # MIT/Apache-2.0
> +MODCARGO_CRATES +=   bytecount-0.3.2 # Apache-2.0/MIT
> +MODCARGO_CRATES +=   byteorder-1.2.6 # Unlicense/MIT
> +MODCARGO_CRATES +=   cc-1.0.24   # MIT/Apache-2.0
> +MODCARGO_CRATES +=   cfg-if-0.1.5# MIT/Apache-2.0
> +MODCARGO_CRATES +=   clap-2.32.0 # MIT
> +MODCARGO_CRATES +=   cloudabi-0.0.3  # BSD-2-Clause
> +MODCARGO_CRATES +=   crossbeam-channel-0.2.4 # MIT/Apache-2.0
> +MODCARGO_CRATES +=   crossbeam-epoch-0.5.2   # MIT/Apache-2.0
> +MODCARGO_CRATES +=   crossbeam-utils-0.5.0   # MIT/Apache-2.0
> +MODCARGO_CRATES +=   encoding_rs-0.8.6   # MIT/Apache-2.0
> +MODCARGO_CRATES +=   encoding_rs_io-0.1.2# MIT OR Apache-2.0
>  MODCARGO_CRATES +=   fnv-1.0.6   # Apache-2.0 / MIT
>  MODCARGO_CRATES +=   fuchsia-zircon-0.3.3# BSD-3-Clause
> -MODCARGO_CRATES +=   fuchsia-zircon-sys-0.3.3# BSD-3-Clause
>  MODCARGO_CRATES +=   glob-0.2.11 # MIT/Apache-2.0
> -MODCARGO_CRATES +=   globset-0.3.0   # Unlicense/MIT
> -MODCARGO_CRATES +=   grep-0.1.8  # Unlicense/MIT
> -MODCARGO_CRATES +=   ignore-0.4.0# Unlicense/MIT
> -MODCARGO_CRATES +=   lazy_static-1.0.0   # MIT/Apache-2.0
> -MODCARGO_CRATES +=   libc-0.2.36 # MIT/Apache-2.0
> -MODCARGO_CRATES +=   log-0.4.1   # MIT/Apache-2.0
> -MODCARGO_CRATES +=   memchr-2.0.1# Unlicense/MIT
> +MODCARGO_CRATES +=   fuchsia-zircon-sys-0.3.3# BSD-3-Clause
> +MODCARGO_CRATES +=   itoa-0.4.2  # MIT/Apache-2.0
> +MODCARGO_CRATES +=   lazy_static-1.1.0   # MIT/Apache-2.0
> +MODCARGO_CRATES +=   libc-0.2.43 # MIT/Apache-2.0
> +MODCARGO_CRATES +=   lock_api-0.1.3  # Apache-2.0/MIT
> +MODCARGO_CRATES +=   log-0.4.5   # MIT/Apache-2.0
> +MODCARGO_CRATES +=   memchr-2.0.2# Unlicense/MIT
>  MODCARGO_CRATES +=   memmap-0.6.2# MIT/Apache-2.0
> +MODCARGO_CRATES +=   memoffset-0.2.1 # MIT
> +MODCARGO_CRATES +=   nodrop-0.1.12   # MIT/Apache-2.0
>  MODCARGO_CRATES +=   num_cpus-1.8.0  # MIT/Apache-2.0
> -MODCARGO_CRATES +=   rand-0.3.22 # MIT/Apache-2.0
> -MODCARGO_CRATES +=   rand-0.4.2  # MIT/Apache-2.0
> -MODCARGO_CRATES +=   redox_syscall-0.1.37# MIT
> +MODCARGO_CRATES +=   owning_ref-0.3.3# MIT
> +MODCARGO_CRATES +=   parking_lot-0.6.4   # Apache-2.0/MIT
> +MODCARGO_CRATES +=   parking_lot_core-0.3.0  # Apache-2.0/MIT
> +MODCARGO_CRATES +=   pcre2-0.1.0 # Unlicense/MIT
> +MODCARGO_CRATES +=   pcre2-sys-0.1.1 # Unlicense/MIT
> +MODCARGO_CRATES +=   pkg-config-0.3.14   # MIT/Apache-2.0
> +MODCARGO_CRATES +=   proc-macro2-0.4.18  # MIT/Apache-2.0
> +MODCARGO_CRATES +=   quote-0.6.8 # MIT/Apache-2.0
> +MODCARGO_CRATES +=   rand-0.4.3  # MIT/Apache-2.0
> +MODCARGO_CRATES +=   rand-0.5.5  

Re: UPDATE: textproc/ripgrep-0.10.0 (with request for help)

2018-11-27 Thread Edward Lopez-Acosta
WANTLIB fixed, it did add an extra entry (c++abi), I am fairly certain I 
sorted out the tabs vs spaces in the list. Is there a way to preserve 
this when I make the crate list and import it into the Makefile?


Thank you for the patience and hopefully this diff is clean. First time 
ever even looking at anything in Rust on my end.


Edward Lopez-Acosta

On 11/26/18 1:24 AM, Sebastien Marie wrote:

On Sun, Nov 25, 2018 at 06:49:43AM -0600, Edward Lopez-Acosta wrote:

Hi Sebastien,

Thank you for the tips.


some nits


I think the CONFIGURE_STYLE removal was simply an oversight on my part.


no problem.


I regened the list of crates using the method you noted (which was
quite handy, and there were a lot of changes),


you removed tabs and inserted spaces. it is why there is still lot of changes.


  and removed WANTLIB since this
version removes pledge for the time being.


well, only the comment should be removed, not WANTLIB :)

see bsd.port.mk(5) man page, specially 'port-lib-depends-check' entry.

$ make port-lib-depends-check
...


I am still interested in where this gets applied if it gets added for
a revision.


I will look to re-add it later. Having some example code in Rust is a good
thing.


New diff attached using a tip (on another port) from Stuart Henderson. It
should hopefully be easier to apply now. I used `git diff --relative .` in
the port directory rather than from /usr/ports and specifying the port.

All tests pass and builds/runs fine on amd64.

Thank you.

Edward Lopez-Acosta



Thanks.

diff --git Makefile Makefile
index 16d2c678d98..2f06334c405 100644
--- Makefile
+++ Makefile
@@ -4,16 +4,14 @@ COMMENT =		line oriented search tool using Rust's regex library #'
 
 GH_ACCOUNT =		BurntSushi
 GH_PROJECT =		ripgrep
-GH_TAGNAME =		0.8.1
-REVISION =		2
+GH_TAGNAME =		0.10.0
 
 CATEGORIES =		textproc sysutils
 
 # Unlicense/MIT
 PERMIT_PACKAGE_CDROM =	Yes
 
-# uses pledge()
-WANTLIB += c pthread
+WANTLIB += c c++abi pthread
 
 # as devel/cargo MODULES adds DISTFILES, GH_* didn't
 DISTFILES +=		${DISTNAME}${EXTRACT_SUFX}
@@ -22,52 +20,83 @@ MODULES =		devel/cargo
 BUILD_DEPENDS =		lang/rust>=1.20 \
 			textproc/asciidoc
 
-MODCARGO_CRATES +=	aho-corasick-0.6.4	# Unlicense/MIT
-MODCARGO_CRATES +=	ansi_term-0.10.2	# MIT
-MODCARGO_CRATES +=	atty-0.2.6	# MIT
-MODCARGO_CRATES +=	bitflags-1.0.1	# MIT/Apache-2.0
-MODCARGO_CRATES +=	bytecount-0.3.1	# Apache-2.0/MIT
-MODCARGO_CRATES +=	cfg-if-0.1.2	# MIT/Apache-2.0
-MODCARGO_CRATES +=	clap-2.30.0	# MIT
-MODCARGO_CRATES +=	crossbeam-0.3.2	# Apache-2.0/MIT
-MODCARGO_CRATES +=	encoding_rs-0.7.2	# MIT/Apache-2.0
+MODCARGO_CRATES +=	aho-corasick-0.6.8	# Unlicense/MIT
+MODCARGO_CRATES +=	arrayvec-0.4.7 	# MIT/Apache-2.0
+MODCARGO_CRATES +=	atty-0.2.11	# MIT
+MODCARGO_CRATES +=	base64-0.9.2	# MIT/Apache-2.0
+MODCARGO_CRATES +=	bitflags-1.0.4	# MIT/Apache-2.0
+MODCARGO_CRATES +=	bytecount-0.3.2 # Apache-2.0/MIT
+MODCARGO_CRATES +=	byteorder-1.2.6 # Unlicense/MIT
+MODCARGO_CRATES +=	cc-1.0.24	# MIT/Apache-2.0
+MODCARGO_CRATES +=	cfg-if-0.1.5	# MIT/Apache-2.0
+MODCARGO_CRATES +=	clap-2.32.0	# MIT
+MODCARGO_CRATES +=	cloudabi-0.0.3	# BSD-2-Clause
+MODCARGO_CRATES +=	crossbeam-channel-0.2.4 # MIT/Apache-2.0
+MODCARGO_CRATES +=	crossbeam-epoch-0.5.2	# MIT/Apache-2.0
+MODCARGO_CRATES +=	crossbeam-utils-0.5.0	# MIT/Apache-2.0
+MODCARGO_CRATES +=	encoding_rs-0.8.6	# MIT/Apache-2.0
+MODCARGO_CRATES +=	encoding_rs_io-0.1.2	# MIT OR Apache-2.0
 MODCARGO_CRATES +=	fnv-1.0.6	# Apache-2.0 / MIT
 MODCARGO_CRATES +=	fuchsia-zircon-0.3.3	# BSD-3-Clause
-MODCARGO_CRATES +=	fuchsia-zircon-sys-0.3.3	# BSD-3-Clause
 MODCARGO_CRATES +=	glob-0.2.11	# MIT/Apache-2.0
-MODCARGO_CRATES +=	globset-0.3.0	# Unlicense/MIT
-MODCARGO_CRATES +=	grep-0.1.8	# Unlicense/MIT
-MODCARGO_CRATES +=	ignore-0.4.0	# Unlicense/MIT
-MODCARGO_CRATES +=	lazy_static-1.0.0	# MIT/Apache-2.0
-MODCARGO_CRATES +=	libc-0.2.36	# MIT/Apache-2.0
-MODCARGO_CRATES +=	log-0.4.1	# MIT/Apache-2.0
-MODCARGO_CRATES +=	memchr-2.0.1	# Unlicense/MIT
+MODCARGO_CRATES +=	fuchsia-zircon-sys-0.3.3	# BSD-3-Clause
+MODCARGO_CRATES +=	itoa-0.4.2	# MIT/Apache-2.0
+MODCARGO_CRATES +=	lazy_static-1.1.0	# MIT/Apache-2.0
+MODCARGO_CRATES +=	libc-0.2.43	# MIT/Apache-2.0
+MODCARGO_CRATES +=	lock_api-0.1.3	# Apache-2.0/MIT
+MODCARGO_CRATES +=	log-0.4.5	# MIT/Apache-2.0
+MODCARGO_CRATES +=	memchr-2.0.2	# Unlicense/MIT
 MODCARGO_CRATES +=	memmap-0.6.2	# MIT/Apache-2.0
+MODCARGO_CRATES +=	memoffset-0.2.1 # MIT
+MODCARGO_CRATES +=	nodrop-0.1.12	# MIT/Apache-2.0
 MODCARGO_CRATES +=	num_cpus-1.8.0	# MIT/Apache-2.0
-MODCARGO_CRATES +=	rand-0.3.22	# MIT/Apache-2.0
-MODCARGO_CRATES +=	rand-0.4.2	# MIT/Apache-2.0
-MODCARGO_CRATES +=	redox_syscall-0.1.37	# MIT
+MODCARGO_CRATES +=	owning_ref-0.3.3	# MIT
+MODCARGO_CRATES +=	parking_lot-0.6.4	# Apache-2.0/MIT
+MODCARGO_CRATES +=	parking_lot_core-0.3.0	# Apache-2.0/MIT
+MODCARGO_CRATES +=	pcre2-0.1.0	# Unlicense/MIT
+MODCARGO_CRATES +=	pcre2-sys-0.1.1 # Unlicense/MIT
+MODCARGO_CRATES +=	pkg-config-0.3.14	

Re: UPDATE: textproc/ripgrep-0.10.0 (with request for help)

2018-11-25 Thread Sebastien Marie
On Sun, Nov 25, 2018 at 06:49:43AM -0600, Edward Lopez-Acosta wrote:
> Hi Sebastien,
> 
> Thank you for the tips.

some nits

> I think the CONFIGURE_STYLE removal was simply an oversight on my part.

no problem.

> I regened the list of crates using the method you noted (which was
> quite handy, and there were a lot of changes),

you removed tabs and inserted spaces. it is why there is still lot of changes.

>  and removed WANTLIB since this
> version removes pledge for the time being.

well, only the comment should be removed, not WANTLIB :)

see bsd.port.mk(5) man page, specially 'port-lib-depends-check' entry.

$ make port-lib-depends-check
...

> I am still interested in where this gets applied if it gets added for
> a revision.

I will look to re-add it later. Having some example code in Rust is a good
thing.

> New diff attached using a tip (on another port) from Stuart Henderson. It
> should hopefully be easier to apply now. I used `git diff --relative .` in
> the port directory rather than from /usr/ports and specifying the port.
> 
> All tests pass and builds/runs fine on amd64.
> 
> Thank you.
> 
> Edward Lopez-Acosta
> 

Thanks.
-- 
Sebastien Marie



Re: UPDATE: textproc/ripgrep-0.10.0 (with request for help)

2018-11-25 Thread Daniel Jakots
On Sun, 25 Nov 2018 14:48:19 -0600, Edward Lopez-Acosta
 wrote:

> -# uses pledge()
> -WANTLIB += c pthread
> -

The comment about pledge should go away but it's not related to the
WANTLIB line which should stay (and maybe get updated as well).



Re: UPDATE: textproc/ripgrep-0.10.0 (with request for help)

2018-11-25 Thread Edward Lopez-Acosta

Same patch as before but regenerated so patch(1) applies it cleanly.

Edward Lopez-Acosta

On 11/25/18 6:49 AM, Edward Lopez-Acosta wrote:

Hi Sebastien,

Thank you for the tips.
I think the CONFIGURE_STYLE removal was simply an oversight on my part. 
I regened the list of crates using the method you noted (which was quite 
handy, and there were a lot of changes), and removed WANTLIB since this 
version removes pledge for the time being. I am still interested in 
where this gets applied if it gets added for a revision.


New diff attached using a tip (on another port) from Stuart Henderson. 
It should hopefully be easier to apply now. I used `git diff --relative 
.` in the port directory rather than from /usr/ports and specifying the 
port.


All tests pass and builds/runs fine on amd64.

Thank you.

Edward Lopez-Acosta

On 11/25/18 3:22 AM, Sebastien Marie wrote:

Hi Edward,

On Sat, Nov 24, 2018 at 05:59:15PM -0600, Edward Lopez-Acosta wrote:

Version bump.
I had to remove the pledge patch as the code was majorly changed and 
it no
longer applied. I spent a couple hours trying to figure out where to 
apply

pledge into the updated code, but got stuck. Would someone be willing to
help with this please?


I think it is fine to remove pledge() and look to re-add it later (if 
possible).

For now, I will focus on the port update without pledge (so the "uses
pledge()" comment could be removed for now).


Otherwise:

Builds and runs successfully on amd64.
No maintainer listed in Makefile.
Nothing depends on this [1]
All tests pass [2]


it is on the right road.


Required crate versions match Cargo.lock [3]
https://github.com/BurntSushi/ripgrep/blob/master/Cargo.lock


how do you update the list of MODCARGO_CRATES in Makefile ?

port infrastructure has tools for helping regenerating MODCARGO_CRATES
lines.

on port-modules(5) man-page, see modcargo-gen-crates and
modcargo-gen-crates-licenses targets.

note the usage could be a bit tricky...

$ edit Makefile #remove all MODCARGO_CRATES lines
$ make clean && make patch
$ make modcargo-gen-crates > list
$ edit Makefile #include the list
$ make makesum
$ make clean && make patch
$ make modcargo-gen-crates-licenses > list
$ edit Makefile #replace all MODCARGO_CRATES by list


Ok?


Just a detail: if you are not a commiter, avoid asking for "ok". It is
usually used by an openbsd developer to ask review from another commiter,
in order to commit the change.


Regarding the diff itself, some questions.


diff --git a/textproc/ripgrep/Makefile b/textproc/ripgrep/Makefile
index 16d2c678d98..c8f3ea47967 100644
--- a/textproc/ripgrep/Makefile
+++ b/textproc/ripgrep/Makefile
@@ -22,53 +21,6 @@ MODULES =    devel/cargo
  BUILD_DEPENDS =    lang/rust>=1.20 \
  textproc/asciidoc
-MODCARGO_CRATES +=    aho-corasick-0.6.4    # Unlicense/MIT
[...]
-MODCARGO_CRATES +=    wincolor-0.1.6    # Unlicense/MIT
-CONFIGURE_STYLE =    cargo


does the remove of CONFIGURE_STYLE is intented ?

without, the build will use network for retrieving dependencies.

$ make
[...]
===>  Building for ripgrep-0.10.0
    Updating crates.io index
warning: spurious network error (2 tries remaining): curl error: 
Could not resolve host: github.com

; class=Net (12)
warning: spurious network error (1 tries remaining): curl error: 
Could not resolve host: github.com

; class=Net (12)
error: failed to fetch `https://github.com/rust-lang/crates.io-index`

Caused by:
  curl error: Could not resolve host: github.com
; class=Net (12)


  PATCHORIG =    .openbsd.orig
  SEPARATE_BUILD =    Yes
@@ -78,6 +30,92 @@ MODCARGO_RUSTFLAGS =    -C debuginfo=0
  RELEASE_DIR =    ${MODCARGO_TARGET_DIR}/release
  OUT_DIR =    ${RELEASE_DIR}/build/ripgrep-*/out
+MODCARGO_CRATES += aho-corasick-0.6.8    # Unilicense/MIT
+MODCARGO_CRATES += arrayvec-0.4.7    # MIT/Apache2.0
[...]


and why moving MODCARGO_CRATES to the end ?
it doesn't help to review what changed and what is the same.

please avoid it if not necessary.

Thanks.

diff --git Makefile Makefile
index 16d2c678d98..70c845f69e6 100644
--- Makefile
+++ Makefile
@@ -4,17 +4,13 @@ COMMENT =		line oriented search tool using Rust's regex library #'
 
 GH_ACCOUNT =		BurntSushi
 GH_PROJECT =		ripgrep
-GH_TAGNAME =		0.8.1
-REVISION =		2
+GH_TAGNAME =		0.10.0
 
 CATEGORIES =		textproc sysutils
 
 # Unlicense/MIT
 PERMIT_PACKAGE_CDROM =	Yes
 
-# uses pledge()
-WANTLIB += c pthread
-
 # as devel/cargo MODULES adds DISTFILES, GH_* didn't
 DISTFILES +=		${DISTNAME}${EXTRACT_SUFX}
 
@@ -22,52 +18,83 @@ MODULES =		devel/cargo
 BUILD_DEPENDS =		lang/rust>=1.20 \
 			textproc/asciidoc
 
-MODCARGO_CRATES +=	aho-corasick-0.6.4	# Unlicense/MIT
-MODCARGO_CRATES +=	ansi_term-0.10.2	# MIT
-MODCARGO_CRATES +=	atty-0.2.6	# MIT
-MODCARGO_CRATES +=	bitflags-1.0.1	# MIT/Apache-2.0
-MODCARGO_CRATES +=	bytecount-0.3.1	# Apache-2.0/MIT
-MODCARGO_CRATES +=	cfg-if-0.1.2	# 

Re: UPDATE: textproc/ripgrep-0.10.0 (with request for help)

2018-11-25 Thread Edward Lopez-Acosta

Hi Sebastien,

Thank you for the tips.
I think the CONFIGURE_STYLE removal was simply an oversight on my part. 
I regened the list of crates using the method you noted (which was quite 
handy, and there were a lot of changes), and removed WANTLIB since this 
version removes pledge for the time being. I am still interested in 
where this gets applied if it gets added for a revision.


New diff attached using a tip (on another port) from Stuart Henderson. 
It should hopefully be easier to apply now. I used `git diff --relative 
.` in the port directory rather than from /usr/ports and specifying the 
port.


All tests pass and builds/runs fine on amd64.

Thank you.

Edward Lopez-Acosta

On 11/25/18 3:22 AM, Sebastien Marie wrote:

Hi Edward,

On Sat, Nov 24, 2018 at 05:59:15PM -0600, Edward Lopez-Acosta wrote:

Version bump.
  
I had to remove the pledge patch as the code was majorly changed and it no

longer applied. I spent a couple hours trying to figure out where to apply
pledge into the updated code, but got stuck. Would someone be willing to
help with this please?


I think it is fine to remove pledge() and look to re-add it later (if possible).
For now, I will focus on the port update without pledge (so the "uses
pledge()" comment could be removed for now).


Otherwise:

Builds and runs successfully on amd64.
No maintainer listed in Makefile.
Nothing depends on this [1]
All tests pass [2]


it is on the right road.


Required crate versions match Cargo.lock [3]
https://github.com/BurntSushi/ripgrep/blob/master/Cargo.lock


how do you update the list of MODCARGO_CRATES in Makefile ?

port infrastructure has tools for helping regenerating MODCARGO_CRATES
lines.

on port-modules(5) man-page, see modcargo-gen-crates and
modcargo-gen-crates-licenses targets.

note the usage could be a bit tricky...

$ edit Makefile #remove all MODCARGO_CRATES lines
$ make clean && make patch
$ make modcargo-gen-crates > list
$ edit Makefile #include the list
$ make makesum
$ make clean && make patch
$ make modcargo-gen-crates-licenses > list
$ edit Makefile #replace all MODCARGO_CRATES by list


Ok?


Just a detail: if you are not a commiter, avoid asking for "ok". It is
usually used by an openbsd developer to ask review from another commiter,
in order to commit the change.


Regarding the diff itself, some questions.


diff --git a/textproc/ripgrep/Makefile b/textproc/ripgrep/Makefile
index 16d2c678d98..c8f3ea47967 100644
--- a/textproc/ripgrep/Makefile
+++ b/textproc/ripgrep/Makefile
@@ -22,53 +21,6 @@ MODULES =devel/cargo
  BUILD_DEPENDS =   lang/rust>=1.20 \
textproc/asciidoc
  
-MODCARGO_CRATES +=	aho-corasick-0.6.4	# Unlicense/MIT

[...]
-MODCARGO_CRATES += wincolor-0.1.6  # Unlicense/MIT
-CONFIGURE_STYLE =  cargo


does the remove of CONFIGURE_STYLE is intented ?

without, the build will use network for retrieving dependencies.

$ make
[...]
===>  Building for ripgrep-0.10.0
Updating crates.io index
warning: spurious network error (2 tries remaining): curl error: Could 
not resolve host: github.com
; class=Net (12)
warning: spurious network error (1 tries remaining): curl error: Could 
not resolve host: github.com
; class=Net (12)
error: failed to fetch `https://github.com/rust-lang/crates.io-index`

Caused by:
  curl error: Could not resolve host: github.com
; class=Net (12)

   

  PATCHORIG =   .openbsd.orig
  SEPARATE_BUILD =  Yes
@@ -78,6 +30,92 @@ MODCARGO_RUSTFLAGS = -C debuginfo=0
  RELEASE_DIR = ${MODCARGO_TARGET_DIR}/release
  OUT_DIR = ${RELEASE_DIR}/build/ripgrep-*/out
  
+MODCARGO_CRATES += aho-corasick-0.6.8	# Unilicense/MIT

+MODCARGO_CRATES += arrayvec-0.4.7  # MIT/Apache2.0
[...]


and why moving MODCARGO_CRATES to the end ?
it doesn't help to review what changed and what is the same.

please avoid it if not necessary.

Thanks.

diff --git a/Makefile b/Makefile
index 16d2c678d98..70c845f69e6 100644
--- a/Makefile
+++ b/Makefile
@@ -4,17 +4,13 @@ COMMENT =		line oriented search tool using Rust's regex library #'
 
 GH_ACCOUNT =		BurntSushi
 GH_PROJECT =		ripgrep
-GH_TAGNAME =		0.8.1
-REVISION =		2
+GH_TAGNAME =		0.10.0
 
 CATEGORIES =		textproc sysutils
 
 # Unlicense/MIT
 PERMIT_PACKAGE_CDROM =	Yes
 
-# uses pledge()
-WANTLIB += c pthread
-
 # as devel/cargo MODULES adds DISTFILES, GH_* didn't
 DISTFILES +=		${DISTNAME}${EXTRACT_SUFX}
 
@@ -22,52 +18,83 @@ MODULES =		devel/cargo
 BUILD_DEPENDS =		lang/rust>=1.20 \
 			textproc/asciidoc
 
-MODCARGO_CRATES +=	aho-corasick-0.6.4	# Unlicense/MIT
-MODCARGO_CRATES +=	ansi_term-0.10.2	# MIT
-MODCARGO_CRATES +=	atty-0.2.6	# MIT
-MODCARGO_CRATES +=	bitflags-1.0.1	# MIT/Apache-2.0
-MODCARGO_CRATES +=	bytecount-0.3.1	# Apache-2.0/MIT
-MODCARGO_CRATES +=	cfg-if-0.1.2	# MIT/Apache-2.0
-MODCARGO_CRATES +=	

Re: UPDATE: textproc/ripgrep-0.10.0 (with request for help)

2018-11-25 Thread Sebastien Marie
Hi Edward,

On Sat, Nov 24, 2018 at 05:59:15PM -0600, Edward Lopez-Acosta wrote:
> Version bump.
>  
> I had to remove the pledge patch as the code was majorly changed and it no
> longer applied. I spent a couple hours trying to figure out where to apply
> pledge into the updated code, but got stuck. Would someone be willing to
> help with this please?

I think it is fine to remove pledge() and look to re-add it later (if possible).
For now, I will focus on the port update without pledge (so the "uses
pledge()" comment could be removed for now).

> Otherwise:
> 
> Builds and runs successfully on amd64.
> No maintainer listed in Makefile.
> Nothing depends on this [1]
> All tests pass [2]

it is on the right road.

> Required crate versions match Cargo.lock [3]
> https://github.com/BurntSushi/ripgrep/blob/master/Cargo.lock

how do you update the list of MODCARGO_CRATES in Makefile ?

port infrastructure has tools for helping regenerating MODCARGO_CRATES
lines.

on port-modules(5) man-page, see modcargo-gen-crates and
modcargo-gen-crates-licenses targets.

note the usage could be a bit tricky...

$ edit Makefile #remove all MODCARGO_CRATES lines
$ make clean && make patch
$ make modcargo-gen-crates > list
$ edit Makefile #include the list
$ make makesum
$ make clean && make patch
$ make modcargo-gen-crates-licenses > list
$ edit Makefile #replace all MODCARGO_CRATES by list

> Ok?

Just a detail: if you are not a commiter, avoid asking for "ok". It is
usually used by an openbsd developer to ask review from another commiter,
in order to commit the change.


Regarding the diff itself, some questions.

> diff --git a/textproc/ripgrep/Makefile b/textproc/ripgrep/Makefile
> index 16d2c678d98..c8f3ea47967 100644
> --- a/textproc/ripgrep/Makefile
> +++ b/textproc/ripgrep/Makefile
> @@ -22,53 +21,6 @@ MODULES =  devel/cargo
>  BUILD_DEPENDS =  lang/rust>=1.20 \
>   textproc/asciidoc
>  
> -MODCARGO_CRATES +=   aho-corasick-0.6.4  # Unlicense/MIT
> [...]
> -MODCARGO_CRATES +=   wincolor-0.1.6  # Unlicense/MIT
> -CONFIGURE_STYLE =cargo

does the remove of CONFIGURE_STYLE is intented ?

without, the build will use network for retrieving dependencies.

$ make
[...]
===>  Building for ripgrep-0.10.0
Updating crates.io index
warning: spurious network error (2 tries remaining): curl error: Could 
not resolve host: github.com
; class=Net (12)
warning: spurious network error (1 tries remaining): curl error: Could 
not resolve host: github.com
; class=Net (12)
error: failed to fetch `https://github.com/rust-lang/crates.io-index`

Caused by:
  curl error: Could not resolve host: github.com
; class=Net (12)

  
>  PATCHORIG =  .openbsd.orig
>  SEPARATE_BUILD = Yes
> @@ -78,6 +30,92 @@ MODCARGO_RUSTFLAGS =   -C debuginfo=0
>  RELEASE_DIR =${MODCARGO_TARGET_DIR}/release
>  OUT_DIR =${RELEASE_DIR}/build/ripgrep-*/out
>  
> +MODCARGO_CRATES += aho-corasick-0.6.8# Unilicense/MIT
> +MODCARGO_CRATES += arrayvec-0.4.7# MIT/Apache2.0
> [...]

and why moving MODCARGO_CRATES to the end ?
it doesn't help to review what changed and what is the same.

please avoid it if not necessary.

Thanks.
-- 
Sebastien Marie