Bug 265619 - sysutils/pstree: Update to 2.40
Summary: sysutils/pstree: Update to 2.40
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Jason Helfman
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-08-04 07:23 UTC by Daniel Engberg
Modified: 2022-10-02 20:06 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (jgh)


Attachments
Patch for pstree (1.40 KB, patch)
2022-08-04 07:23 UTC, Daniel Engberg
no flags Details | Diff
patch to use tag (1.32 KB, patch)
2022-09-30 00:10 UTC, Jason Helfman
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Engberg freebsd_committer freebsd_triage 2022-08-04 07:23:28 UTC
Created attachment 235670 [details]
Patch for pstree

Update MASTER_SITES to unbreak port
Add LICENSE definitions
Remove USES alias definition as DragonflyBSD is defined in source

Poudriere testport OK 12.3-RELEASE (amd64)
Poudriere testport OK 13.0-RELEASE (i386)

References:
https://github.com/FredHucht/pstree/blob/main/pstree.c#L69
Comment 1 Jason Helfman freebsd_committer freebsd_triage 2022-08-12 18:54:51 UTC
I've just seen this patch and can work on validation, however can you please address mastersite change? Are you originator of code and project? If so, can you please validate this information in some way?

Thanks!
-jgh
Comment 2 Daniel Engberg freebsd_committer freebsd_triage 2022-08-12 21:14:46 UTC
Hi,

Not more than same person is listed as author

https://fossies.org/dox/pstree-2.39/pstree_8c_source.html

And that Alpine, MacPorts and OpenIndiana uses the same repo

https://pkgs.alpinelinux.org/package/edge/main/x86/pstree
https://ports.macports.org/port/pstree/details/
https://github.com/OpenIndiana/oi-userland/search?q=pstree+filename%3AMakefile&type=Code

Best regards,
Daniel
Comment 3 Daniel Engberg freebsd_committer freebsd_triage 2022-09-11 08:56:26 UTC
Friendly ping
Comment 4 Daniel Engberg freebsd_committer freebsd_triage 2022-09-27 09:52:31 UTC
Good to go?
Comment 5 Jason Helfman freebsd_committer freebsd_triage 2022-09-29 15:59:35 UTC
I didn't see these updates, sorry... I'll take a look at this soon.
Comment 6 Jason Helfman freebsd_committer freebsd_triage 2022-09-29 17:44:35 UTC
Why is this pointing to a specific file? Is this a commit?

https://github.com/FredHucht/${PORTNAME}/files/9119465/


Thanks!
-jgh
Comment 7 Daniel Engberg freebsd_committer freebsd_triage 2022-09-29 19:30:05 UTC
"If the distribution file comes from a specific commit or tag on GitHub for which there is no officially released file, there is..."
https://docs.freebsd.org/en/books/porters-handbook/book/#makefile-master_sites-github

https://github.com/FredHucht/pstree/releases/tag/v2.40 --> https://github.com/FredHucht/pstree/files/9119465/pstree-v2.40.zip ("Source code" archives are generated on the fly so not suitable). Not sure how upstream ended up with that path but that's the link.

Best regards,
Daniel
Comment 8 Jason Helfman freebsd_committer freebsd_triage 2022-09-29 19:49:03 UTC
Ok, thanks. I haven't run into this specific situation, yet, as I've always at least pulled on content hash when release hasn't been made, and use a patchfile tied to a commit, if appropriate, over pulling a specific file.

I will work this out, but encourage you open up an issue to have owner properly tag release if these changes aren't in release, yet it was updated. It does become more difficult to follow updates going forward, and I've found maintainer of software does become more aware of release-based actions. 

Thanks!
-jgh
Comment 9 Jason Helfman freebsd_committer freebsd_triage 2022-09-30 00:09:45 UTC
Ok, thanks. I haven't run into this specific situation, yet, as I've always at least pulled on content hash when release hasn't been made, and use a patchfile tied to a commit, if appropriate, over pulling a specific file.

I will work this out, but encourage you open up an issue to have owner properly tag release if these changes aren't in release, yet it was updated. It does become more difficult to follow updates going forward, and I've found maintainer of software does become more aware of release-based actions. 

Thanks!
-jgh

(In reply to Daniel Engberg from comment #7)

After re-reading this comment, I looked into it more and have attached a patch to address this issue. Please let me know what you think.
Comment 10 Jason Helfman freebsd_committer freebsd_triage 2022-09-30 00:10:26 UTC
Created attachment 236956 [details]
patch to use tag
Comment 11 Daniel Engberg freebsd_committer freebsd_triage 2022-09-30 00:25:27 UTC
I'm not sure I follow you, what changes and what isn't tagged properly?

If you are to follow Porters Handbook (which we should unless there's a very good reason not to) you should use upstream distfile if available which in this case is  the file despite where it's being hosted. Pulling individual changes from GitHub as patches is fine.

Best regards,
Daniel
Comment 12 Jason Helfman freebsd_committer freebsd_triage 2022-09-30 01:23:35 UTC
I'm pulling based off of github tag, https://github.com/FredHucht/pstree/releases/tag/v2.40 , as you noted. I am using upstream distfile from github.

From bsd.sites.mk:

# GH_TAGNAME    - name of the tag to download (2.0.1, hash, ...)
#                 Using the name of a branch here is incorrect. It is
#                 possible to do GH_TAGNAME= GIT_HASH to do a snapshot.
#                 default: ${DISTVERSIONFULL}
Comment 13 Jason Helfman freebsd_committer freebsd_triage 2022-09-30 01:41:44 UTC
This blurb is also cited in Porter's Handbook
Comment 14 Daniel Engberg freebsd_committer freebsd_triage 2022-09-30 07:54:22 UTC
GitHub tag is not a "static" distfile provided by upstream, it's generated on the fly (codeload). See https://cgit.freebsd.org/ports/tree/Mk/bsd.sites.mk#n289 for more information about that glue.

See also https://github.com/isamert/scli/issues/143 for example so it's "last resort" which Porters Handbook tells you not to use if there's a static distfile/tarball available.
Comment 15 Jason Helfman freebsd_committer freebsd_triage 2022-09-30 15:43:48 UTC
(In reply to Daniel Engberg from comment #14)

Ok, fair point. The only thing holding me and trying to understand what is going on here is that how can I say that v2.40 equals this zip, and how to do track when a new version is available?

Is there a particular commit bit to base off of? To me, this seems to be more of something that can be technically chased.

Thanks!
-jgh
Comment 16 Jason Helfman freebsd_committer freebsd_triage 2022-09-30 16:23:01 UTC
I see how this is working now.. Not my preference, but it is what it is... I'll work on getting this through, and thank you for any patience you extended to me during this back-n-forth ;)

-jgh
Comment 17 Daniel Engberg freebsd_committer freebsd_triage 2022-09-30 16:50:40 UTC
I don't think portscout works that well with GitHub in general but I can't say I've looked at it closely. Looking at commits logs many seem to rely on GitHub's own watch feature including myself.

Thanks for looking into this!

Best regards,
Daniel
Comment 18 commit-hook freebsd_committer freebsd_triage 2022-09-30 23:10:38 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=4899be1e6323086b95823cff3a486f240c73eb4a

commit 4899be1e6323086b95823cff3a486f240c73eb4a
Author:     Daniel Engberg <diizzy@FreeBSD.org>
AuthorDate: 2022-09-30 23:08:51 +0000
Commit:     Jason Helfman <jgh@FreeBSD.org>
CommitDate: 2022-09-30 23:08:51 +0000

    sysutils/pstree: update to v2.40, shift to github upstream

    PR:     265619

 sysutils/pstree/Makefile | 12 +++++++-----
 sysutils/pstree/distinfo |  5 +++--
 2 files changed, 10 insertions(+), 7 deletions(-)
Comment 19 Jason Helfman freebsd_committer freebsd_triage 2022-09-30 23:11:02 UTC
Committed! Thanks :)

-jgh
Comment 20 Jason Helfman freebsd_committer freebsd_triage 2022-10-02 20:06:22 UTC
Shift to closed.