Bug 225196 - irc/irssi: Update to 1.1.0
Summary: irc/irssi: Update to 1.1.0
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: Brad Davis
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-01-15 22:04 UTC by David O'Rourke
Modified: 2018-02-19 20:46 UTC (History)
5 users (show)

See Also:
dor.bsd: maintainer-feedback+


Attachments
irc/irssi: 1.1.0 diff (3.12 KB, patch)
2018-01-15 22:04 UTC, David O'Rourke
dor.bsd: maintainer-approval-
Details | Diff
irc/irssi: 1.1.0 diff (6.21 KB, patch)
2018-01-17 21:26 UTC, David O'Rourke
dor.bsd: maintainer-approval+
Details | Diff
irc/irssi: 1.1.0 diff (6.41 KB, patch)
2018-01-22 22:39 UTC, David O'Rourke
dor.bsd: maintainer-approval+
Details | Diff
irc/irssi: 1.1.0 diff (6.41 KB, patch)
2018-01-23 12:29 UTC, David O'Rourke
dor.bsd: maintainer-approval+
Details | Diff
irc/irssi: 1.1.0 diff (6.38 KB, patch)
2018-01-23 19:05 UTC, David O'Rourke
dor.bsd: maintainer-approval+
Details | Diff
updated patch (5.77 KB, patch)
2018-01-31 23:34 UTC, Brad Davis
dor.bsd: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David O'Rourke 2018-01-15 22:04:34 UTC
Created attachment 189770 [details]
irc/irssi: 1.1.0 diff

This updates the irssi port to 1.1.0.

This version includes many changes as detailed in https://github.com/irssi/irssi/blob/1.1.0/NEWS.

The main feature of interest to FreeBSD users is likely the Capsicum support for which a toggle was added to the Makefile. This new option is enabled by default.
Comment 1 David O'Rourke 2018-01-17 21:06:45 UTC
Comment on attachment 189770 [details]
irc/irssi: 1.1.0 diff

Approval removed. Needs an update to pkg-plist.
Comment 2 David O'Rourke 2018-01-17 21:26:19 UTC
Created attachment 189866 [details]
irc/irssi: 1.1.0 diff

Fixed diff with pkg-plist update.
Comment 3 Danilo G. Baio freebsd_committer freebsd_triage 2018-01-18 00:25:28 UTC
(In reply to David O'Rourke from comment #2)

CCing trasz@ who implemented Capsicum support on irssi.

Edward, do you mind in take a look on this?

I did a small change on pkg-plist:
  +%%CAPSICUM%%include/irssi/src/core/capsicum.h
  +%%CAPSICUM%%include/irssi/src/core/iregex.h
  +%%CAPSICUM%%include/irssi/src/core/network-openssl.h
  +%%CAPSICUM%%include/irssi/src/fe-common/core/fe-capsicum.h
  +%%CAPSICUM%%include/irssi/src/fe-common/core/fe-settings.h
  +%%CAPSICUM%%%%PORTDOCS%%%%DOCSDIR%%/capsicum.txt
  +%%CAPSICUM%%%%PORTDOCS%%%%DOCSDIR%%/startup-HOWTO.txt

It is building fine on 11.1-RELEASE and 12.0-CURRENT 1200056 but not on 10.3-RELEASE.

Regards.
Comment 4 David O'Rourke 2018-01-20 20:46:43 UTC
Thanks for catching the Capsicum files. I managed to miss those when updating the rest of the pkg-plist.

Do we want to wait for a 10.3 fix here, or is there a way to disable the Capsicum option on FreeBSD < 11 for the time being?
Comment 5 David O'Rourke 2018-01-22 22:39:41 UTC
Created attachment 189983 [details]
irc/irssi: 1.1.0 diff

A new diff which hides the Capsicum option and forces `--without-capsicum` on FreeBSD < 1100121 (releng/11.0).
Someone might want to check the technique I've used there. It appears to work, but I'm unsure if that's the usual way of doing something like this.

I've also tweaked the `pkg-plist` a little more and limited the `%%CAPSICUM%%` items to the files related to Capsicum.
Comment 6 David O'Rourke 2018-01-22 22:42:45 UTC
I did have a look at adding support for Capsicum on FreeBSD < 11.0 to irssi, however, it got tricky when `pdfork(2)` didn't support `PD_CLOEXEC`, which is when I went for this option instead.
Comment 7 Tobias Kortkamp freebsd_committer freebsd_triage 2018-01-22 23:30:57 UTC
(In reply to David O'Rourke from comment #5)
${OPVERSION} should be ${OSVERSION}, but you can use

OPTIONS_EXCLUDE_FreeBSD_10= CAPSICUM

instead to hide and deselect the option on FreeBSD 10.x.

It's arguably nicer :)
Comment 8 David O'Rourke 2018-01-23 12:29:42 UTC
Created attachment 189998 [details]
irc/irssi: 1.1.0 diff

New diff fixing the typo in ${OSVERSION}.
Comment 9 David O'Rourke 2018-01-23 12:32:51 UTC
If I exclude the CAPSICUM option using OPTIONS_EXCLUDE, I still need to add --without-capsicum to the CONFIGURE_ARGS as irssi attempts to use Capsicum by default if it finds it.

So, I could do something to avoid the OPTIONS_DEFINE+=, etc, but I think I'll still require the OPSYS and OSVERSION checks to do the OPTIONS_EXCLUDE and set the CONFIGURE_ARGS appropriately.
Comment 10 David O'Rourke 2018-01-23 13:03:31 UTC
Actually, I see what you're getting at, in that if it's deselected the correct argument will be added to CONFIGURE_ARGS by the rest of the Makefile.

I'll give that a try in a while. Thanks.
Comment 11 David O'Rourke 2018-01-23 19:05:59 UTC
Created attachment 190007 [details]
irc/irssi: 1.1.0 diff

New patch making use of the OPTIONS_EXCLUDE_opsys_osrel setting to exclude Capsicum from FreeBSD 10.
Comment 12 Edward Tomasz Napierala freebsd_committer freebsd_triage 2018-01-23 20:23:59 UTC
Thanks for the heads up.  Yeah, it all looks good to me.  And yes, disabling Capsicum support on 10.x seems like the right thing to do.  Thanks :-)
Comment 13 Brad Davis freebsd_committer freebsd_triage 2018-01-31 23:34:13 UTC
Created attachment 190236 [details]
updated patch

It does not seem like this port was tested with `poudriere testport' and fails a few different checks, including linking against Perl when it should not due to a misplaced `include <bsd.port.options.mk>'.

See this link for more info:
https://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/book.html#makefile-options

I have attached an updated patch.
Comment 14 David O'Rourke 2018-01-31 23:42:41 UTC
Comment on attachment 190236 [details]
updated patch

Thanks for the patch. The bsd.port.options.mk managed to hang around after switching to OPTIONS_EXCLUDE_FreeBSD_10.
Comment 15 commit-hook freebsd_committer freebsd_triage 2018-01-31 23:54:15 UTC
A commit references this bug:

Author: brd
Date: Wed Jan 31 23:53:53 UTC 2018
New revision: 460549
URL: https://svnweb.freebsd.org/changeset/ports/460549

Log:
  Update irc/irssi to 1.1.0

  PR:		225196
  Submitted by:	David O'Rourke <dor.bsd@xm0.uk>

Changes:
  head/irc/irssi/Makefile
  head/irc/irssi/distinfo
  head/irc/irssi/files/patch-Makefile.in
  head/irc/irssi/pkg-plist
Comment 16 Brad Davis freebsd_committer freebsd_triage 2018-01-31 23:54:45 UTC
Committed, thanks!
Comment 17 commit-hook freebsd_committer freebsd_triage 2018-02-19 20:46:50 UTC
A commit references this bug:

Author: dbaio
Date: Mon Feb 19 20:45:57 UTC 2018
New revision: 462348
URL: https://svnweb.freebsd.org/changeset/ports/462348

Log:
  MFH: r460549 r462311

  Update irc/irssi to 1.1.0

  PR:		225196
  Submitted by:	David O'Rourke <dor.bsd@xm0.uk>

  irc/irssi: Update to 1.1.1, Fixes multiple vulnerabilities

  Changes:	https://irssi.org/NEWS/#v1-1-1

  PR:		226001
  Submitted by:	David O'Rourke <dor.bsd@xm0.uk> (maintainer)
  Reported by:	tj@mrsk.me (email)
  Security:	7afc5e56-156d-11e8-95f2-005056925db4

  Approved by:	ports-secteam (swills)

Changes:
_U  branches/2018Q1/
  branches/2018Q1/irc/irssi/Makefile
  branches/2018Q1/irc/irssi/distinfo
  branches/2018Q1/irc/irssi/files/patch-Makefile.in
  branches/2018Q1/irc/irssi/pkg-plist