Bug 256800 - graphics/cairo: update/revise pkg-plist
Summary: graphics/cairo: update/revise pkg-plist
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-desktop (Team)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-06-24 03:31 UTC by tigersharke
Modified: 2021-07-10 08:33 UTC (History)
4 users (show)

See Also:
tcberner: maintainer-feedback+


Attachments
diff of pkg-plist for proposed changes (653 bytes, patch)
2021-06-24 03:31 UTC, tigersharke
no flags Details | Diff
v2 (528 bytes, patch)
2021-06-24 08:16 UTC, Evgeniy Khramtsov
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description tigersharke 2021-06-24 03:31:15 UTC
Created attachment 226023 [details]
diff of pkg-plist for proposed changes

It seems that cairo no longer provides libdata/pkgconfig/cairo-glx.pc and so the pkg-plist line for it might need to be removed to permit build and install.
%%OPENGL%%%%X11%%libdata/pkgconfig/cairo-glx.pc

I would also recommend that the plist used match the order of the plist generated as it makes parsing easier, but that is not essential to build/install success. 

The very small unified diff which includes all changes is attached.
Comment 1 Tobias C. Berner freebsd_committer 2021-06-24 04:37:30 UTC
(In reply to tigersharke from comment #0)
Moin moin

> pkg which /usr/local/libdata/pkgconfig/cairo-glx.pc
/usr/local/libdata/pkgconfig/cairo-glx.pc was installed by package cairo-1.17.4,3

It's there on my machine.

Could you provide the output of 
> make showconfig 


mfg Tobias
Comment 2 tigersharke 2021-06-24 05:47:58 UTC
Sorry for the noise however, we have discovered a combination which causes the issue I described.  I cannot say how it will be resolved.

When I build graphics/libglvnd with X11=off (unticked) then cairo does not include the libdata/pkgconfig/cairo-glx.pc and gives the error about it.

There were some issues with mesa-libs and libglvnd recently which caused me to attempt a fix by adjusting the libglvnd config, this I overlooked and after enough repeated builds of cairo, I noticed it pulled libglvnd.

my cairo config itself does not affect it:

root@ichigo:/usr/ports/graphics/cairo # make showconfig
===> The following configuration options are available for cairo-1.17.4,3:
     DOCS=on: Build and/or install documentation
     GLIB=on: Enable GObject Functions Feature
     X11=on: X11 (graphics) support
     XCB=on: Enable XCB (X C-language Binding) Support
====> Options available for the radio GL: you can only select none or one of them
     OPENGL=on: 2D/3D rendering support via OpenGL
     GLESV2=off: Enable GLESv2 rendering
===> Use 'make config' to modify these settings
root@ichigo:/usr/ports/graphics/cairo #
Comment 3 Evgeniy Khramtsov 2021-06-24 07:59:53 UTC
(In reply to tigersharke from comment #2)

Ports framework does not enforce option dependencies unlike Gentoo Portage.

libglvnd built without X11 excludes GLX support, and cairo with X11=on needs GLX from $GL_DEFAULT (libglvnd) to build, which you disabled.

If you want a X11-less setup, then consider {X11,XCB}=off cairo, and maybe OPENGL=off if it is headless.
Comment 4 Evgeniy Khramtsov 2021-06-24 08:05:27 UTC
(In reply to tigersharke from comment #0)

> It seems that cairo no longer provides libdata/pkgconfig/cairo-glx.pc

Ah. So it just built without GLX.

Maybe there should be a GLX option for cairo, so the OPENGL=on {X11,XCB}=on works through EGL.
Comment 5 Evgeniy Khramtsov 2021-06-24 08:06:49 UTC
(In reply to Evgeniy Khramtsov from comment #4)

> OPENGL=on {X11,XCB}=on

and libglvnd X11=off

Sorry for forgetting.
Comment 6 tigersharke 2021-06-24 08:15:54 UTC
The graphics/libglvnd X11=off was in error, a response in hopes of understanding the libglvnd and mesa-libs issues I was having.

Thank you all for your time.
Comment 7 Evgeniy Khramtsov 2021-06-24 08:16:10 UTC
Created attachment 226027 [details]
v2

Does the attached diff help in your case?

I guess selecting GLX pkgconfig in plist based on OPENGL is not useful, as GLX is not going to be built with X11=off.
Comment 8 Evgeniy Khramtsov 2021-06-24 08:20:02 UTC
(In reply to Evgeniy Khramtsov from comment #7)

Nevermind, forgot that this is with X11=on...