Bug 194283 - [PATCH] print/muttprint: fix build with OPTIONS_UNSET=X11
Summary: [PATCH] print/muttprint: fix build with OPTIONS_UNSET=X11
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Only Me
Assignee: John Marino
Keywords: patch-ready
Depends on:
Reported: 2014-10-10 13:36 UTC by Frank Wall
Modified: 2014-11-28 11:21 UTC (History)
2 users (show)

See Also:

patch print/muttprint (706 bytes, patch)
2014-10-10 13:36 UTC, Frank Wall
no flags Details | Diff
updated patch (982 bytes, patch)
2014-11-23 21:44 UTC, Frank Wall
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Frank Wall 2014-10-10 13:36:55 UTC
Created attachment 148162 [details]
patch print/muttprint

Attached patch adds a check to use the -nox11 version of ImageMagick if OPTIONS_UNSET=X11 is set.

Without this patch the port would not build with poudriere:

====>> Computing deps for print/muttprint
====>> DEBUG: print/muttprint depends on converters/p5-Text-Iconv
====>> DEBUG: print/muttprint depends on devel/gmake
====>> DEBUG: print/muttprint depends on devel/p5-TimeDate
====>> DEBUG: print/muttprint depends on graphics/ImageMagick
====>> Error: Duplicated origin for ImageMagick-nox11-,1: graphics/ImageMagick AND graphics/ImageMagick-nox11. Rerun with -vv to see which ports are depending on these.
Comment 1 John Marino freebsd_committer 2014-10-31 19:28:14 UTC
maintainer did not get auto-CC'd, doing that now.

is OPTIONS_UNSET=X11 still supported officially?
Comment 2 John Marino freebsd_committer 2014-11-14 10:48:38 UTC
Due to lack of feedback, maintainer approval is no longer required.   I'm promoting the PR now.
Comment 3 John Marino freebsd_committer 2014-11-14 11:37:53 UTC
This diff refers to PORTS_OPTIONS:MX11 but there's not option X11 in the port.  If there was, the patch is okay. 

So I think the patch needs to add the X11 option as well.  Moving back to triage.
Comment 4 Frank Wall 2014-11-15 13:54:09 UTC
John, I didn't add an X11 option to the *port* because it's just a matter of handling the *dependencies*, not the port itself.

My patch makes it possible to build print/muttprint in an environment, where OPTIONS_UNSET=X11 is set globally (i.e. a poudriere build).

Please let me know if you think I should add a X11 option to the port regardlessly.
Comment 5 John Marino freebsd_committer 2014-11-15 21:01:06 UTC
your code only works if X11 option is defined.  As it stands now, 

RUN_DEPENDS+=	convert:${PORTSDIR}/graphics/ImageMagick-nox11

is what is executed in *ALL* cases.
Comment 6 Frank Wall 2014-11-23 21:44:06 UTC
Created attachment 149756 [details]
updated patch
Comment 7 Frank Wall 2014-11-23 21:44:42 UTC
I've updated the patch to address the issue.
Comment 8 John Marino freebsd_committer 2014-11-24 14:23:29 UTC
This looks ok, I'll promote it.  However, it needs to have the PORTREVISION incremented (note to committer).
Comment 9 John Marino freebsd_committer 2014-11-28 10:39:58 UTC
Actually, this is not ok.
It was assuming x11 before.  this turns x11 into an option (fine), but has it off by default (not fine).

So it's missing OPTIONS_DEFAULT=x11, which I'll add.
Comment 10 commit-hook freebsd_committer 2014-11-28 11:20:28 UTC
A commit references this bug:

Author: marino
Date: Fri Nov 28 11:19:54 UTC 2014
New revision: 373545
URL: https://svnweb.freebsd.org/changeset/ports/373545

  print/muttprint: provide option to build it without X11 support

  PR:		194283
  Submitted by:	Frank Wall
  Approved by:	maintainer timeout

Comment 11 John Marino freebsd_committer 2014-11-28 11:21:14 UTC
With my modification, this passed poudriere testing, thanks!