pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: pango, cairo, and libXft

(sorry my mail got delayed, the datacenter with my mail server had an

On Tue 21 Jun 2022 at 14:00:46 -0400, Greg Troxel wrote:
> I'm really not sure what's going on.
> Two thoughts:
> * Are you really sure you have
>     - a consistent tree, all cvs up -A

I made sure to run this again; I have some local changes in some
packages that might be suitable for committing but that's for another

>     - no stale workdirs

It's a tmpfs and I rm'ed it again

>     - everything up to date?

cvs update -A completed successfully

> * Partial PREFER_PKGSRC considered harmful
>   If you are going to prefer_pkgsrc for something, you should do that
>   for everything that depends on it.  Yes, it ought to warn if you
>   don't.

I should indeed have set PREFER.libXft too, I agree. And setting that
is supposed to fix the situation, I gather. But...

pkg_comp:default.conf# pwd                
pkg_comp:default.conf# make show-var VARNAME=PREFER.libXft
pkg_comp:default.conf# make show-var VARNAME=X11_TYPE      
pkg_comp:default.conf# make
=> Bootstrap dependency digest>=20211023: found digest-20220214
WARNING: [] Every package should define a LICENSE.
ERROR: This package has set PKG_SKIP_REASON:
ERROR: Package set is using native X11 component
*** Error code 1

make: stopped in /usr/pkgsrc/x11/libXft

This should build the package, I would think.

So where does this message come from? In this directory's Makefile there is

.include "../../meta-pkgs/modular-xorg/"

which contains amongst other lines,

.include "../../mk/"

.if ${X11_TYPE} == "native"
.    if exists(${X11BASE}/lib/${X11_LIB_NAME}.so)
PKG_SKIP_REASON+=       "Package set is using native X11 component"
.    endif

and /usr/X11R7/lib/ exists.

It doesn't seem to look at PREFER.libXft at all.

One could imagine that could (for packages like these
where == pkgsrc) set X11_TYPE to something other than
"native", but it doesn't, as shown by the `make show-var` above. I'm not
sure where exactly the value is set, but it seems correct to me.

One way to make look at could be

RCS file: /cvsroot/pkgsrc/meta-pkgs/modular-xorg/,v
retrieving revision 1.4
diff -u -r1.4
---  10 Apr 2022 08:52:01 -0000      1.4
+++  23 Jun 2022 20:45:50 -0000
@@ -2,7 +2,7 @@
 .include "../../mk/"
-.if ${X11_TYPE} == "native"
+.if ${PREFER.${X11_BIN_NAME}${X11_LIB_NAME}${X11_DRV_NAME}} == "native"
 .  if !empty(X11_BIN_NAME)
 .    if exists(${X11BASE}/bin/${X11_BIN_NAME})
 PKG_SKIP_REASON+=      "Package set is using native X11 component"

I tried ${PREFER.${PKGBASE}} == "native" as the condition first, but it
seems that PKGBASE is not known yet at the right time. Hence the hack,
which is needed because the name can be in 3 different variables.
Hopefully they match the package name, too.

The condition ${X11_TYPE} == "native" isn't really needed if the is already native, and the conditions further down won't
match anyway for non-native setups.

___ "Buying carbon credits is a bit like a serial killer paying someone else to
\X/  have kids to make his activity cost neutral." -The BOFH

Attachment: signature.asc
Description: PGP signature

Home | Main Index | Thread Index | Old Index