Opened 11 years ago

Closed 10 years ago

#43566 closed enhancement (fixed)

netpbm @10.66.02_1 Requesting a no_x11 variant

Reported by: mthomas+macports@… Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version:
Keywords: haspatch Cc: su-v, Mathias.Laurin+macports.org@…
Port: netpbm

Description

changeset:119542 makes netpbm require X11.

The only tool in the netpbm suite that requires X11 is pamx, the image viewer. Would you create a no_x11 variant for netpbm that does not build the viewer?

Sample patch file for the netpbm Porfile attached.

Attachments (3)

Portfile.diff (393 bytes) - added by mthomas+macports@… 11 years ago.
Portfile.2.diff (1.4 KB) - added by mthomas+macports@… 11 years ago.
Portfile patch version 2 that uses +x11 instead of no_x11
patch-other-pamx-Makefile.diff (410 bytes) - added by mthomas+macports@… 11 years ago.

Download all attachments as: .zip

Change History (10)

Changed 11 years ago by mthomas+macports@…

Attachment: Portfile.diff added

comment:1 Changed 11 years ago by su-v

Cc: suv-sf@… added

Cc Me!

comment:2 Changed 11 years ago by mf2k (Frank Schima)

Keywords: haspatch removed
Owner: changed from macports-tickets@… to ryandesign@…
Version: 2.2.1

In the future, please Cc the port maintainers (port info --maintainers netpbm).

We are not creating no_{foo} variants anymore. Rename the variant to x11 and make it do the reverse. See #39383. Furthermore, what if the user has the xorg-libX11 installed? The port must make sure it does not use it in that case.

comment:3 Changed 11 years ago by mthomas+macports@…

Sorry, I was not aware that no_{foo} is no longer supported.

I have attached a second version of the Portfile patch that I hope addresses the issues. Getting netpbm not to build pamx when X11 is installed involves patching other/pamx/Makefile to check for a configuration variable that I have named MACPORTS_X11. The patch for the Makefile is patch-other-pamx-Makefile.diff, which is also attached.

Changed 11 years ago by mthomas+macports@…

Attachment: Portfile.2.diff added

Portfile patch version 2 that uses +x11 instead of no_x11

Changed 11 years ago by mthomas+macports@…

comment:4 in reply to:  3 ; Changed 10 years ago by Mathias.Laurin+macports.org@…

Replying to mthomas+macports@…:

I have attached a second version of the Portfile patch that I hope addresses the issues. Getting netpbm not to build pamx when X11 is installed involves patching other/pamx/Makefile to check for a configuration variable that I have named MACPORTS_X11. The patch for the Makefile is patch-other-pamx-Makefile.diff, which is also attached.

Is it not enough to set X11LIB = NONE in ${configmk}?—That works for me but I do not have x11 installed. In any case, I believe that it should be set in any case. i.e.

@@ -84,6 +89,11 @@ TIFFLIB = -ltiff
 WANT_SSE = ${want_sse}
 ZLIB = -lz
 "
+    if {![variant_isset x11]} {
+        puts ${configmk} "
+X11LIB = NONE
+"
+    }
     close ${configmk}
 }

I would also like see your patch accepted by the way.

comment:5 Changed 10 years ago by Mathias.Laurin+macports.org@…

Cc: Mathias.Laurin+macports.org@… added

Cc Me!

comment:6 in reply to:  4 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Replying to Mathias.Laurin+macports.org@…:

Is it not enough to set X11LIB = NONE in ${configmk}?—That works for me but I do not have x11 installed.

Have a look in config.mk.in. X11LIB = NONE is already in there, and no, that does not prevent X11 from being used if it is found by pkg-config.

Last edited 10 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:7 in reply to:  3 Changed 10 years ago by ryandesign (Ryan Carsten Schmidt)

Keywords: haspatch added
Resolution: fixed
Status: newclosed

Replying to mthomas+macports@…:

I have attached a second version of the Portfile patch that I hope addresses the issues. Getting netpbm not to build pamx when X11 is installed involves patching other/pamx/Makefile to check for a configuration variable that I have named MACPORTS_X11. The patch for the Makefile is patch-other-pamx-Makefile.diff, which is also attached.

Thank you for the patch and sorry for the delay. I've committed it in r131363 with a few changes, including renaming the option to WANT_X11 (mirroring the existing option WANT_SSE).

Note: See TracTickets for help on using tickets.