Bug 290983 - net/spoofdpi: Update 1.0.1 => 1.0.2
Summary: net/spoofdpi: Update 1.0.1 => 1.0.2
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Vladimir Druzenko
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-11-12 20:12 UTC by Yusuf Yaman
Modified: 2025-11-13 13:26 UTC (History)
2 users (show)

See Also:


Attachments
0001-net-spoofdpi-Update-1.0.1-1.0.2.patch (9.62 KB, patch)
2025-11-12 20:36 UTC, Yusuf Yaman
nxjoseph: maintainer-approval+
Details | Diff
0001-net-spoofdpi-Update-1.0.1-1.0.2.patch (9.55 KB, patch)
2025-11-13 12:36 UTC, Yusuf Yaman
nxjoseph: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yusuf Yaman 2025-11-12 20:12:01 UTC

    
Comment 1 Yusuf Yaman 2025-11-12 20:36:23 UTC
Created attachment 265379 [details]
0001-net-spoofdpi-Update-1.0.1-1.0.2.patch

Thanks in advance.
Comment 2 Vladimir Druzenko freebsd_committer freebsd_triage 2025-11-12 21:09:02 UTC
Are you sure LOCALBASE, not PREFIX here:
        @${REINPLACE_CMD} -e '67s#/etc#${LOCALBASE}/etc/${PORTNAME}#g' \
                -e '233s#"etc"#"${LOCALBASE}", "etc", "${PORTNAME}"#g' \
                ${WRKSRC}/internal/config/cli.go
?
Comment 3 Vladimir Druzenko freebsd_committer freebsd_triage 2025-11-12 21:18:21 UTC
        @${REINPLACE_CMD} -e '67s|/etc|${ETCDIR}|g' \
                -e '233s|"etc"|"${ETCDIR}"|g' \
                ${WRKSRC}/internal/config/cli.go
Comment 4 Yusuf Yaman 2025-11-13 09:52:11 UTC
(In reply to Vladimir Druzenko from comment #2)
I'm getting confused when I should decide localbase or prefix. I don't understand them well. This time I just went with localbase. So I guess in this case it should be prefix.

I also tried the etcdir way instead of writing the full one but it looked bad in code to me so I continued with full one.
Comment 5 Yusuf Yaman 2025-11-13 12:36:48 UTC
Created attachment 265395 [details]
0001-net-spoofdpi-Update-1.0.1-1.0.2.patch

Ok, fixed after suggestions, thanks.

I think i should note that, the pkg-message for this version. 1.0.2, didn't worked for me when i was upgrading spoofdpi from 1.0.1 to 1.0.2. I hope it works normally but don't know why I couldn't see the results. pkg info -D command doensn't show any message too.


diff --git a/net/spoofdpi/Makefile b/net/spoofdpi/Makefile
index 668c057e4..900d5f679 100644
--- a/net/spoofdpi/Makefile
+++ b/net/spoofdpi/Makefile
@@ -60,13 +60,13 @@ USERS=              ${PORTNAME}
 GROUPS=                ${PORTNAME}

 PLIST_FILES=   "@dir(${USERS},${GROUPS},0770) ${ETCDIR}" \
-               "@sample(${USERS},${GROUPS},0770) ${ETCDIR}/${PORTNAME}.toml.sample ${ETCDIR}/${PORTNAME}.toml" \
+               "@sample(${USERS},${GROUPS},0770) ${ETCDIR}/${PORTNAME}.toml.sample" \
                bin/${PORTNAME}

 post-patch:
        ${CP} ${FILESDIR}/modules.txt ${WRKSRC}/vendor
-       @${REINPLACE_CMD} -e '67s#/etc#${LOCALBASE}/etc/${PORTNAME}#g' \
-               -e '233s#"etc"#"${LOCALBASE}", "etc", "${PORTNAME}"#g' \
+       @${REINPLACE_CMD} -e '67s#/etc#${ETCDIR}#g' \
+               -e '233s#"etc"#"${ETCDIR}"#g' \
                ${WRKSRC}/internal/config/cli.go
Comment 6 Vladimir Druzenko freebsd_committer freebsd_triage 2025-11-13 12:55:17 UTC
(In reply to Yusuf Yaman from comment #4)
LOCALBASE - where the ports required by this port are installed.
PREFIX - where this port will be installed.

Mk/bsd.port.mk:
ETCDIR?=         ${PREFIX}/etc/${PORTNAME}

(In reply to Yusuf Yaman from comment #5)
I don't know how pkg-message work. :-(
Comment 7 commit-hook freebsd_committer freebsd_triage 2025-11-13 13:25:36 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=1e23df854ae8494d16a00f6d0577bc0820cb97a5

commit 1e23df854ae8494d16a00f6d0577bc0820cb97a5
Author:     Yusuf Yaman <nxjoseph@protonmail.com>
AuthorDate: 2025-11-13 13:23:29 +0000
Commit:     Vladimir Druzenko <vvd@FreeBSD.org>
CommitDate: 2025-11-13 13:23:29 +0000

    net/spoofdpi: Update 1.0.1 => 1.0.2

    This release brings toml configuration support. It will be used when no
    command-line arguments are given.

    Changelog:
    https://github.com/xvzc/SpoofDPI/releases/tag/v1.0.2

    PR:     290983

 net/spoofdpi/Makefile                   | 19 ++++++++++++++---
 net/spoofdpi/distinfo                   | 10 ++++++---
 net/spoofdpi/files/modules.txt          |  9 +++++++-
 net/spoofdpi/files/pkg-message.in (new) | 37 +++++++++++++++++++++++++++++++++
 net/spoofdpi/pkg-message (gone)         | 30 --------------------------
 5 files changed, 68 insertions(+), 37 deletions(-)
Comment 8 Vladimir Druzenko freebsd_committer freebsd_triage 2025-11-13 13:26:11 UTC
Thanks.