Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 06 May 2023 01:09:29 +0000
From:      bugzilla-noreply@freebsd.org
To:        ports-bugs@FreeBSD.org
Subject:   [Bug 271272] graphics/libcaca: Hidden dependency on Xlib.h
Message-ID:  <bug-271272-7788@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D271272

            Bug ID: 271272
           Summary: graphics/libcaca: Hidden dependency on Xlib.h
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: multimedia@FreeBSD.org
          Reporter: fsbruva@yahoo.com
          Assignee: multimedia@FreeBSD.org
             Flags: maintainer-feedback?(multimedia@FreeBSD.org)

Created attachment 242008
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D242008&action=
=3Dedit
libcaca: patch to align x11 treatment with imlib2's

Note: This bug seems to be a repeat of bug #153846, but I cannot find what
about "the process" fixed or stopped this behavior with 0.99beta17, and it's
still present with 0.99beta19.

Problem: When building libcaca with IMLIB2 port option set, if imlib2 was b=
uilt
without X11 support, then this error occurs:

In file included from ../src/common-image.c:21:
/usr/local/include/Imlib2.h:26:10: fatal error: 'X11/Xlib.h' file not found
#include <X11/Xlib.h>
         ^~~~~~~~~~~~
1 error generated.
*** Error code 1

Stop.
make[3]: stopped in
/wrkdirs/usr/ports/graphics/libcaca/work/libcaca-0.99.beta19/examples
*** Error code 1

This is because imlib2 uses the AC_PATH_XTRA macro, and relies on
X_DISPLAY_MISSING getting defined when --without-x is passed to imlib2's
configure. Within Imlib2.h, There are several #includes and function protot=
ypes
that are guarded by an #ifndef X_DISPLAY_MISSING. By contrast, libcaca defi=
nes
its own --enable-x configure flag to permit X11 detection, and only uses the
AC_PATH_X macro.

Solution:
Have a conditional CFLAGS definition for libcaca based on the OPTIONS
combination of IMLIB2 set and X11 unset. I will also submit a patch upstrea=
m,
but libcaca's last commit was 18 months ago, so I am not optimistic it will=
 be
merged.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-271272-7788>