Bug 210212 - graphics/libimg: missing X11 linkage
Summary: graphics/libimg: missing X11 linkage
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: freebsd-ports-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-06-11 14:20 UTC by Edward Tomasz Napierala
Modified: 2016-06-14 19:29 UTC (History)
2 users (show)

See Also:
mi: maintainer-feedback+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Edward Tomasz Napierala freebsd_committer 2016-06-11 14:20:01 UTC
The libimg port removes X11 linkage, which makes linuxcnc fail to start, like this:

Traceback (most recent call last):
  File "bin/axis", line 123, in <module>
    nf.start(root_window)
  File "/usr/home/trasz/git/linuxcnc/lib/python/nf.py", line 119, in start
    source_lib_tcl(r, "support.tcl")
  File "/usr/home/trasz/git/linuxcnc/lib/python/nf.py", line 111, in source_lib_tcl
    r.tk.call("source", os.path.join(tcl_libdir, f))
_tkinter.TclError: couldn't load file "/usr/local/lib/Img/libtkimgxpm142.so.1": /usr/local/lib/Img/libtkimgxpm142.so.1: Undefined symbol "XParseColor"

Removing the appropriate portion of Makefile seems to fix this problem:

Index: Makefile
===================================================================
--- Makefile    (revision 416716)
+++ Makefile    (working copy)
@@ -3,7 +3,7 @@
 
 PORTNAME=      libimg
 PORTVERSION=   1.4.2
-PORTREVISION=  1
+PORTREVISION=  2
 CATEGORIES?=   graphics tk
 MASTER_SITES=  SF/tkimg/tkimg/${PORTVERSION:R}
 DISTNAME=      tkimg${PORTVERSION}
@@ -37,9 +37,6 @@
 .endfor
 
 post-configure:
-       # Do not link with X11 -- none of tkimg code uses X directly
-       ${REINPLACE_CMD} -E -e 's,-L[^[:space:]]+[[:space:]]+-lX[^[:space:]]*,,g' \
-               ${WRKSRC}/*/Makefile
 .for l in jpeg png tiff
        # Link with -l$l
        ${REINPLACE_CMD} -E \
Comment 1 Mikhail Teterin freebsd_committer 2016-06-12 04:11:35 UTC
Go ahead. I think, my goal was to allow at least some of the sub-packages to work without X11 (and without DISPLAY), but it never reached that state...

On a side-note, I got to look into upgrading the port to 1.46. Thanks!
Comment 2 commit-hook freebsd_committer 2016-06-14 19:28:14 UTC
A commit references this bug:

Author: trasz
Date: Tue Jun 14 19:27:30 UTC 2016
New revision: 416906
URL: https://svnweb.freebsd.org/changeset/ports/416906

Log:
  Don't remove X11 linkage; this breaks the upcoming LinuxCNC port.

  PR:		210212
  Approved by:	maintainer (earlier version)

Changes:
  head/graphics/libimg/Makefile
Comment 3 Edward Tomasz Napierala freebsd_committer 2016-06-14 19:29:01 UTC
Thanks, committed.  The upgrade would be great; I've just discovered that the version, as is, doesn't work quite properly with current libpng.