Page MenuHomeFreeBSD

New port: sysutils/sockaddr
ClosedPublic

Authored by seanc on Mar 3 2018, 12:33 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Mar 9, 2:29 PM
Unknown Object (File)
Feb 8 2024, 7:38 PM
Unknown Object (File)
Feb 8 2024, 4:42 AM
Unknown Object (File)
Feb 6 2024, 9:00 AM
Unknown Object (File)
Feb 6 2024, 12:36 AM
Unknown Object (File)
Feb 4 2024, 2:25 PM
Unknown Object (File)
Feb 4 2024, 10:59 AM
Unknown Object (File)
Feb 4 2024, 1:28 AM
Subscribers

Details

Summary

Add a new port: sysutils/sockaddr

Sockaddr is a command-line utility that makes it easy to query network
address information from the local server. With sockaddr it is possible
to create a list of the RFC 1918 addresses on a server, obtain the
default gateway, or public IP addresses and use this information in other
shell scripts. See the website for additional templating and IP math
functions.

Test Plan

poudriere testport

Diff Detail

Repository
rP FreeBSD ports repository
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

sysutils/sockaddr/Makefile
4

Should be named go-sockaddr.

6

Where is ths v0.1.0 coming from? I could not find any reference to it on the github page.

15

Do not USES=go if you overwrite everything it does later. Simply add a dependency on go itself.

20

Remove this line and set GH_TAGNAME= 7165ee1

36

@mat Updated with a few residual Q's.

sysutils/sockaddr/Makefile
4

Ignorant question: there is no runtime dependency on Go. Why does the language that the tool was written in need to be part of the port name's prefix? Go is used as the compiler to install a static binary, this isn't a library. As a library name, go-sockaddr is correct, however as a standalone binary sockaddr is correct. Because this port is installing the binary, not the Go library, I believe this is correct. ?

6

I arbitrarily designated this 0.1.0 since the port is not tagged upstream.

20

There is a nuance in the port build infrastructure that I don't fully understand yet. I used GH_TAGNAME to begin with, but this doesn't work as expected:

GH_TAGNAME=	7165ee1

I am unable to fetch the tarball:

% make makesum
=> hashicorp-sockaddr-v0.1.0-7165ee1_GH0.tar.gz doesn't seem to exist in /usr/ports/distfiles/.
=> Attempting to fetch https://codeload.github.com/hashicorp/sockaddr/tar.gz/7165ee1?dummy=/hashicorp-sockaddr-v0.1.0-7165ee1_GH0.tar.gz
fetch: https://codeload.github.com/hashicorp/sockaddr/tar.gz/7165ee1?dummy=/hashicorp-sockaddr-v0.1.0-7165ee1_GH0.tar.gz: Not Found

But if I use a GH_TUPLE instead, everything works as expected:

 % make makesum
=> hashicorp-go-sockaddr-v0.1.0-7165ee1_GH0.tar.gz doesn't seem to exist in /usr/ports/distfiles/.
=> Attempting to fetch https://codeload.github.com/hashicorp/go-sockaddr/tar.gz/7165ee1?dummy=/hashicorp-go-sockaddr-v0.1.0-7165ee1_GH0.tar.gz
fetch: https://codeload.github.com/hashicorp/go-sockaddr/tar.gz/7165ee1?dummy=/hashicorp-go-sockaddr-v0.1.0-7165ee1_GH0.tar.gz: size of remote file is not known
hashicorp-go-sockaddr-v0.1.0-7165ee1_GH0.tar.g         645 kB 2344 kBps 00m01s
seanc added a reviewer: mat.

Additional tweak found via portlint -A

sysutils/sockaddr/Makefile
4

This seems correct to me, I think sockaddr is fine as a name.

6

Might want to use a gYYYYMMDD timestamp type version instead in that case.

seanc marked 6 inline comments as done.
seanc edited the summary of this revision. (Show Details)

Updated to use a date for DISTVERSION.

seanc added inline comments.
sysutils/sockaddr/Makefile
6

Curio: where's the g prefix come from?

seanc requested review of this revision.Apr 26 2018, 7:23 PM
seanc edited the test plan for this revision. (Show Details)

Staged diff via svn diff

sockaddr/Makefile
18 ↗(On Diff #42176)

Replace by

GH_TAGNAME=7165ee1

Updated and addresses all known feedback from @mat .

seanc added inline comments.
sockaddr/Makefile
18 ↗(On Diff #42176)

Done/fixed.

seanc requested review of this revision.
seanc marked an inline comment as done.
This revision is now accepted and ready to land.May 11 2018, 8:00 PM
This revision was automatically updated to reflect the committed changes.