From owner-freebsd-desktop@FreeBSD.ORG Tue Feb 28 12:14:17 2012 Return-Path: Delivered-To: desktop@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6C6FB106567B; Tue, 28 Feb 2012 12:14:17 +0000 (UTC) (envelope-from villa.alberto@gmail.com) Received: from mail-bk0-f54.google.com (mail-bk0-f54.google.com [209.85.214.54]) by mx1.freebsd.org (Postfix) with ESMTP id 8A4C28FC26; Tue, 28 Feb 2012 12:14:16 +0000 (UTC) Received: by bkcjc3 with SMTP id jc3so2611366bkc.13 for ; Tue, 28 Feb 2012 04:14:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=sender:from:organization:to:subject:date:user-agent:cc:references :in-reply-to:mime-version:content-type:content-transfer-encoding :message-id; bh=nbRKtB70y1zY3iRlyOu4FRugERbh7SmEDyU4Tp0BS24=; b=uEVFsmMEJz5f4Jyu9cc4RJWVF0IKk5DqdND+7pqrhHPNUIZA50+CZw1Dizj3Lbrk/A HIU3/l7kcNt2shHWBDxY1cm7ENxb/w/eKgAR/10jqBw4HndQckcq03xnsTDzQfbr0SmM 5LpyG03Am6NzF0yCGdptTXFhcvxAmqwN1aWJw= Received: by 10.204.143.151 with SMTP id v23mr7619638bku.63.1330431255443; Tue, 28 Feb 2012 04:14:15 -0800 (PST) Received: from woodstock.peanuts (wifinat-16.polito.it. [130.192.232.16]) by mx.google.com with ESMTPS id w15sm30839415bku.0.2012.02.28.04.14.14 (version=SSLv3 cipher=OTHER); Tue, 28 Feb 2012 04:14:14 -0800 (PST) Sender: Alberto Villa From: Alberto Villa Organization: The FreeBSD Project To: freebsd-desktop@freebsd.org Date: Tue, 28 Feb 2012 13:14:10 +0100 User-Agent: KMail/1.13.7 (FreeBSD/10.0-CURRENT; KDE/4.7.4; amd64; ; ) References: <20120120065141.GM4729@azathoth.lan> <201201201004.36979.avilla@freebsd.org> <201202280357.05198.avilla@freebsd.org> In-Reply-To: <201202280357.05198.avilla@freebsd.org> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart4146270.DkoGryWCUQ"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <201202281314.13503.avilla@freebsd.org> Cc: rflynn@acsalaska.net, desktop@freebsd.org Subject: Re: What about improving the desktop ports consistency: task 1, the fonts X-BeenThere: freebsd-desktop@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Using and improving FreeBSD on the desktop List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 28 Feb 2012 12:14:17 -0000 --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 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--