Date: Tue, 28 Feb 2012 13:14:10 +0100 From: Alberto Villa <avilla@freebsd.org> To: freebsd-desktop@freebsd.org Cc: rflynn@acsalaska.net, desktop@freebsd.org Subject: Re: What about improving the desktop ports consistency: task 1, the fonts Message-ID: <201202281314.13503.avilla@freebsd.org> In-Reply-To: <201202280357.05198.avilla@freebsd.org> References: <20120120065141.GM4729@azathoth.lan> <201201201004.36979.avilla@freebsd.org> <201202280357.05198.avilla@freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--nextPart4146270.DkoGryWCUQ Content-Type: Text/Plain; charset="iso-8859-15" Content-Transfer-Encoding: quoted-printable On Tuesday 28 February 2012 03:57:02 Alberto Villa wrote: > When not using XORG_CAT=3Dfont and INSTALLS_TTF=3Dyes, ports just=20 mimic > that behaviour, with some deviations (like installing fonts.scale and > fonts.dirs files) which appear not to be optimal. I will try converting > some ports to bsd.xorg.mk magic and see what changes. I had a closer look at the process, and read some documentation as well. fontconfig is *required* to be run after installation to update fontconfig= =20 system fonts cache. Some ports which run it explicitly don't pass option -s= =20 (while bsd.xorg.mk does), thus updating also user's (in that case, root's!)= =20 cache, which is not what we want. fc-cache @exec line in bsd.xorg.mk is=20 thus correct and *required*. I'm not sure about @unexec line, though. It doesn't remove the font from=20 the cache, so the only reason for its existence I can think of is if a port= =20 overwrites a font installed by another port, and on deinstallation it resto= res=20 it. But this sounds like something which should not happen by design.=20 melflynn: ideas on why that line could be there? Meanwhile, I'll see if I c= an=20 ask to the author of that code. If it's useless, it should be removed, as i= t=20 also slows down a bit the port deinstallation. A @unexec line should also be added by bsd.xorg.mk to remove=20 font.cache-1 files. According to melflynn, they're backup files created by= =20 (old?) fc-cache, so let's do some garbage cleaning. mkfontscale and mkfontdir are *required* to update X fonts cache (i.e.,=20 font.scale and font.dir files). We could package font.* files, but this wou= ld=20 break horribly if we end up installing two ports in the same directory. So,= =20 since we already have to put fc-cache in post installation scripts, there's= no=20 reason in not adding those too. Plus, if we want to package those files, we= =20 need to keep them in sync with the fonts on every update, which is sub- optimal. Both @exec and @unexec lines are *required* here, still for the "n= =20 ports, 1 directory" reason above. > > > (do we still need that FontPath thing?, if no then the > > > pkg-message asking people to fill it should be dropped) > >=20 > > I think we do, but will try and report. >=20 > I'm currently running KDE with stock FontPath's, and I can use my port- > installed fonts. Seems like fontconfig takes care of this. Thus, there's = no > pkg-message in my port. > I wonder, though, if there's still software not using fontconfig: I guess > that, in that case, FontPath might be required. Apparently there is some, so the pkg-message is still required (without the= =20 line about loading FreeType). I'd like to fill it via bsd.xorg.mk, but that= =20 wouldn't let maintainers write their custom pkg-message. Maybe we could=20 make it conditional, i.e., if maintainer didn't set any pkg-message, write = it=20 automatically. About the packaging issue: I know I've talked about @exec's and=20 @unexec's above, but I think we can convert them to standard post-*=20 scripts. Can't we? This would conflict with maintainers custom scripts, of= =20 course, just like pkg-message, but the solution might be the same. =2D-=20 Alberto Villa, FreeBSD committer <avilla@FreeBSD.org> http://people.FreeBSD.org/~avilla Der Horizont vieler Menschen ist ein Kreis mit Radius Null - und das nennen sie ihren Standpunkt. --nextPart4146270.DkoGryWCUQ Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part. -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.18 (FreeBSD) iJwEAAECAAYFAk9MxRUACgkQ3xiC6kQ1Cot63wQAqwsCcv9W5G+9RX5ACs5y4jfF ImtmyVUpU1rHnhoyuV2NExAWrwi6V5haEuum9q3vA7KRqFcoONZ+++BjzAtvCKlp FgLA+5AhuL80ct9zRPNzoiI1UDU2Yfw42h+654u/IAU1a2mlTpgnqyEwZoREXMto L9jt2/wRSP3xPmjlfDc= =GRIh -----END PGP SIGNATURE----- --nextPart4146270.DkoGryWCUQ--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201202281314.13503.avilla>