Bug 210885 - dns/dnscrypt-wrapper: Update to 0.2.1
Summary: dns/dnscrypt-wrapper: Update to 0.2.1
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: Dmitry Marakasov
URL:
Keywords: easy, needs-qa, patch
Depends on:
Blocks:
 
Reported: 2016-07-07 08:34 UTC by Will
Modified: 2016-07-14 12:57 UTC (History)
1 user (show)

See Also:
koobs: maintainer-feedback? (freebsd)


Attachments
patch to install new version 0.2.1 (1.64 KB, patch)
2016-07-07 08:34 UTC, Will
no flags Details | Diff
2nd attempt at patch to install new version 0.2.1 (3.35 KB, patch)
2016-07-09 02:13 UTC, Will
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Will 2016-07-07 08:34:51 UTC
Created attachment 172188 [details]
patch to install new version 0.2.1

Version 0.2.1 of dnscrypt-wrapper was released, so I've created a patch to upgrade the port accordingly.
Comment 1 Kubilay Kocak freebsd_committer freebsd_triage 2016-07-07 08:40:31 UTC
Thank you Will

Can you explain the removal of DESTDIR from Makefile and also confirm this passes QA (poudriere, portlint) please
Comment 2 Dmitry Marakasov freebsd_committer freebsd_triage 2016-07-08 13:55:12 UTC
Yes, you can leave out both Makefile patching and passing PREFIX through MAKE_ARGS. Rest of MAKE_ARGS may be replaced with USES=localbase. STRIP and MKDIR are better to be silenced (@${MKDIR}). Also build in argparse subdirectory does not respect CFLAGS.

See also https://github.com/cofyc/dnscrypt-wrapper/pull/76
Comment 3 Will 2016-07-09 02:13:34 UTC
Created attachment 172271 [details]
2nd attempt at patch to install new version 0.2.1
Comment 4 Will 2016-07-09 02:50:48 UTC
Dmitry, thanks so much for your feedback, it was very helpful. When I was working on the first release of this port I suspected that my solutions to the problems I had were not as graceful as they could be, but I didn't know a better way to solve them. I'm glad to have some of those rough corners more polished, now.

I've attached a new patch that obsoletes the old one. To summarize it:

- Includes 2 patch files for the changes that you submitted a pull request to the author for.
- Adds "localbase" to USES.
- Removes the MAKE_ARGS line since the two above changes make it unnecessary.
- Silences STRIP_CMD and MKDIR with @ like you suggested.
- Changes version numbers, file hashes, and file sizes to fetch the new release of the source.

Kubilay, regarding QA:

$ portlint -C
WARN: Consider to set DEVELOPER=yes in /etc/make.conf
0 fatal errors and 1 warning found.
$

Is that make.conf warning significant? I did some cursory searching and wasn't able to find a ready explanation of what that flag does. It've not used poudriere before but am looking into it now. It seems to need to download some not-small files and I'm stuck on a very limited cellular connection for a few more days, but when I get back to civilization and wifi I'll give it a go and see if I can figure out what to do with that. Beyond that, it compiles, executes, and passes my manual functionality testing (I can get dnscrypt-proxy to connect to it and pass DNS queries through it).
Comment 5 Will 2016-07-13 07:08:27 UTC
I spent some time working with poudriere testport last night and set up 4 jails: the amd64 and i386 versions of FreeBSD 9.3 and 10.3. It seems that the newly-patched version of the port builds and installs fine in 10.3, but while it builds in 9.3, installation fails with the following error:

[00:08:29] ====>> Installing from package
[9-3_amd64-default] Installing dnscrypt-wrapper-0.2.1...
===> Creating users
Creating user '_dnscrypt-wrapper' with uid '718'.
pw: name too long `_dnscrypt-wrapper' (max is 16)
pkg-static: PRE-INSTALL script failed

Failed to install the following 1 package(s): /tmp/pkgs/dnscrypt-wrapper-0.2.1.txz

I assume that while 10.3 allows user names longer than 16 characters, 9.3 doesn't. This must be something that's already broken in the current port tree and unrelated to this patch, but it'd be nice to roll in a fix for this issue. Patching the UIDs file to change the name in place seems like it would cause discrepancies with existing installations of the port. Alternately, is there a Makefile option to mark it as requiring FreeBSD 10 or higher? That seems less desirable, but am unsure if there's a precedent for how to deal with this problem. Thanks in advance for your advice!
Comment 6 commit-hook freebsd_committer freebsd_triage 2016-07-14 12:52:31 UTC
A commit references this bug:

Author: amdmi3
Date: Thu Jul 14 12:52:07 UTC 2016
New revision: 418533
URL: https://svnweb.freebsd.org/changeset/ports/418533

Log:
  - Update to 0.2.1
  - Properly respect ${CC}
  - Cosmetic fixes
  - Mark broken on 9.x due to too long username

  PR:		210885
  Submitted by:	freebsd@toyingwithfate.com (maintainer)

Changes:
  head/dns/dnscrypt-wrapper/Makefile
  head/dns/dnscrypt-wrapper/distinfo
  head/dns/dnscrypt-wrapper/files/patch-Makefile
  head/dns/dnscrypt-wrapper/files/patch-argparse_Makefile
Comment 7 Dmitry Marakasov freebsd_committer freebsd_triage 2016-07-14 12:57:36 UTC
> Is that make.conf warning significant? I did some cursory searching and
> wasn't able to find a ready explanation of what that flag does.

It enables some additional checks and warnings. It's useful to have if you maintain any ports.

> It've not used poudriere before but am looking into it now.

Please do. The port has more problems: the patch is incorrect (still contains DESTDIR removal bits) and it doesn't build on 9.x (username too long). Removed bad patch fragment and marked broken on 9.x for now.

PS. Sorry, I've missed the last comment

> I assume that while 10.3 allows user names longer than 16 characters, 9.3 doesn't. This must be something that's already broken in the current port tree and unrelated to this patch, but it'd be nice to roll in a fix for this issue. Patching the UIDs file to change the name in place seems like it would cause discrepancies with existing installations of the port. Alternately, is there a Makefile option to mark it as requiring FreeBSD 10 or higher? That seems less desirable, but am unsure if there's a precedent for how to deal with this problem. Thanks in advance for your advice!

I think we can just leave it with BROKEN_FreeBSD_9.