Bug 254747

Summary: [NEW PORT] devel/rgxg: Regular expression generator
Product: Ports & Packages Reporter: alexander naumochkin <alexander.naumochkin>
Component: Individual Port(s)Assignee: Juraj Lutter <otis>
Status: Closed FIXED    
Severity: Affects Only Me CC: diizzy, otis
Priority: --- Keywords: feature
Version: LatestFlags: koobs: maintainer-feedback? (otis)
koobs: maintainer-feedback? (diizzy)
Hardware: Any   
OS: Any   
Description Flags
devel/rgxg new port
devel/rgxg new port
Patch for rgxg
devel/rgxg new port
Patch for rgxg v2
devel/rgxg new port none

Description alexander naumochkin 2021-04-03 19:56:22 UTC
Created attachment 223790 [details]
devel/rgxg new port

extended regular expression generator especially useful for ip (v4 and v6) matching regexes
Comment 1 Daniel Engberg freebsd_committer 2021-04-04 05:56:27 UTC
Hi Alexander,

A few things that can be improved. :-)

Porters Handbook - "Table 5.2. Package Naming Examples"

"If the distribution file comes from a specific commit or tag on GitHub for which there is no officially released file"
In this case upstream provides one, https://github.com/rgxg/rgxg/releases/tag/v0.1.2 --> https://github.com/rgxg/rgxg/releases/download/v0.1.2/rgxg-0.1.2.tar.gz so please use that instead.

Please define DOCS and possibly MANPAGES as port options

Thanks for your contribution!
Best regards,
Comment 2 alexander naumochkin 2021-04-04 20:50:11 UTC
Created attachment 223810 [details]
devel/rgxg new port

updated Makefile for port
Comment 3 alexander naumochkin 2021-04-04 20:57:49 UTC
Hi Daniel,

I've modified Makefile following your recomendations about *VERSION and MASTER_SITES, check it, please.

But at the moment I'm not sure what to do with DOCS/MANPAGES without patching configure.ac, because docs/man-pages installation are not options with it. Do I have to make the patch or ask author for that?

Sorry for my newbie questions, this is my first port :)
Comment 4 Daniel Engberg freebsd_committer 2021-04-05 21:33:38 UTC
Created attachment 223845 [details]
Patch for rgxg

Add pkgconf(ig) as dependency
Disable static library
Add DOCS option
Comment 5 Daniel Engberg freebsd_committer 2021-04-05 21:35:35 UTC
I initially didn't look at upstream but as you said upstream doesn't have options for it. The ports framework does however let you do create these options as it can automatically ignore file(s) if you "bind" them to an option ("knob") (OPTIONS_SUB in Porters Handbook, PORTDOCS enables it by default and adds items automatically to plist) however there's no need to overengineer so I just made a DOCS option.

I should also mention that I learned a few new things thanks to jrm@ and mat@ by hacking on this. :-)

This version also passes Poudriere on 12.2-RELEASE

Best regards,
Comment 6 alexander naumochkin 2021-04-10 07:31:39 UTC
Created attachment 223976 [details]
devel/rgxg new port

Corrected (and final I hope) version
Comment 7 alexander naumochkin 2021-04-10 07:40:33 UTC
Hi Daniel,

thanks alot for your mentoring, I've attached new edition of .shar. Hope it is good enough to adopt. If everything is Ok, should I do something else with this "bug-report"?

Best regards,
Comment 8 Daniel Engberg freebsd_committer 2021-04-18 18:00:21 UTC
Created attachment 224227 [details]
Patch for rgxg v2

Remove "Created by" and deprecated SVN entry ( $FreeBSD$ )

Poudriere testport OK 12.2-RELEASE (amd64)
Poudriere testport OK 11.4-RELEASE (amd64)
Comment 9 Daniel Engberg freebsd_committer 2021-04-18 18:02:30 UTC
Hi Alexander,

Can you please review "Patch for rgxg v2" I've done some style cleanup and COMMENT= follows ports framework style (no non standard capitals)

This should be ready to commit

Best regards,
Comment 10 alexander naumochkin 2021-04-24 01:07:07 UTC
Created attachment 224391 [details]
devel/rgxg new port

style cleanup according to daniels advisory
Comment 11 alexander naumochkin 2021-04-24 01:09:22 UTC
Hi Daniel,

hope this will become final version

Comment 12 Daniel Engberg freebsd_committer 2021-05-03 08:59:23 UTC
Hi Alex,

Sorry for the late reply but what did you change for the last patch compared to the one I submitted?
Comment 13 alexander naumochkin 2021-05-04 19:12:57 UTC
(In reply to daniel.engberg.lists from comment #12)

Hi Daniel,

just as you said in comment #9 — some style cleanup.

diff --git a/Makefile b/Makefile
index 3641e6d..b975a4e 100644
--- a/Makefile
+++ b/Makefile
@@ -1,13 +1,10 @@
-# Created by: alexander naumochkin <alexander.naumochkin@gmail.com>
-# $FreeBSD$
 PORTNAME=      rgxg
 CATEGORIES=    devel
 MASTER_SITES=  https://github.com/${PORTNAME}/${PORTNAME}/releases/download/v${DISTVERSION}/

 MAINTAINER=    alexander.naumochkin@gmail.com
-COMMENT=       ReGular eXpression Generator
+COMMENT=       Regular expression generator

Comment 14 alexander naumochkin 2021-05-24 22:58:22 UTC
Hi Daniel,

is something wrong still?

Comment 15 Daniel Engberg freebsd_committer 2021-05-31 20:20:42 UTC
Sorry for the late reply!

No, it should be fine now however you don't need to submit the patch in another format if its already attached. :-)

Comment 16 Kubilay Kocak freebsd_committer freebsd_triage 2021-08-11 00:59:29 UTC
^Triage: What needs to happen to resolve this issue?
Comment 17 commit-hook freebsd_committer 2021-09-03 06:53:36 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=4a6c4a258ae524df314a5a4cee64bfabf7275d99

commit 4a6c4a258ae524df314a5a4cee64bfabf7275d99
Author:     alexander naumochkin <alexander.naumochkin@gmail.com>
AuthorDate: 2021-09-03 06:47:52 +0000
Commit:     Juraj Lutter <otis@FreeBSD.org>
CommitDate: 2021-09-03 06:47:52 +0000

    devel/rgxg: Add port: a ReGular eXpression Generator.

    rgxg (ReGular eXpression Generator) is a C library and a command-line
    tool to generate (extended) regular expressions.


    PR:             254747

 devel/rgxg/Makefile (new)  | 28 ++++++++++++++++++++++++++++
 devel/rgxg/distinfo (new)  |  3 +++
 devel/rgxg/pkg-descr (new) |  4 ++++
 devel/rgxg/pkg-plist (new) | 17 +++++++++++++++++
 4 files changed, 52 insertions(+)
Comment 18 Juraj Lutter freebsd_committer 2021-09-03 07:01:58 UTC
It took time, but committed. Thanks!