From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47372) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d4qV7-00033Y-Ho for guix-patches@gnu.org; Sun, 30 Apr 2017 11:11:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d4qV4-00041d-A6 for guix-patches@gnu.org; Sun, 30 Apr 2017 11:11:05 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:49708) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1d4qV3-00041R-S8 for guix-patches@gnu.org; Sun, 30 Apr 2017 11:11:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1d4qV3-0001U6-My for guix-patches@gnu.org; Sun, 30 Apr 2017 11:11:01 -0400 Subject: bug#26702: [PATCH 1/2] gnu: Add font-cns11643 Resent-Message-ID: From: Marius Bakke In-Reply-To: <36cee073-4427-d584-2d9c-c0e2e22fd4ff@openmailbox.org> References: <36cee073-4427-d584-2d9c-c0e2e22fd4ff@openmailbox.org> Date: Sun, 30 Apr 2017 17:10:02 +0200 Message-ID: <87wpa2gcdx.fsf@fastmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Brendan Tildesley , 26702@debbugs.gnu.org --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hi Brendan, thanks for this! Brendan Tildesley writes: > * gnu/packages/fonts.scm (font-cns11643): New variable. [...] =20=20 > +(define-public font-cns11643 > + (package > + (name "font-cns11643") > + (version "98.1.20170405") > + (source (origin > + (method url-fetch) > + (uri "http://www.cns11643.gov.tw/AIDB/Open_Data.zip") > + (sha256 > + (base32 > + "1kyfrwamr8zpdp4qw3z9j3cimhsvr4xd05dmxmfphiknlbr6d455"))= )) I'm getting a different hash when downloading this: @ build-failed /gnu/store/b4s6pjp7pvwn5028zxm7dn7hxb7akhxn-Open_Data.zip.dr= v - 1 output path `/gnu/store/kv2291fl8p8r3ic15pp68751qncrv830-Open_Data.zi= p' should have sha256 hash `1kyfrwamr8zpdp4qw3z9j3cimhsvr4xd05dmxmfphiknlbr= 6d455', instead has `02kb3bwjrra0k2hlr2p8xswd2y0xs6j8d9vm6yrby734h02a40qf' Maybe I'm getting a newer version? If this is updated in-place upstream very frequently, it would be good to have a way to access older downloads. Any ideas? Minor nit-picks follow, but I've corrected this in my local branch: > + (outputs '("out" "tw-kai" "tw-sung")) > + (build-system trivial-build-system) > + (native-inputs > + `(("unzip" ,unzip))) > + (arguments > + `(#:modules ((guix build utils)) > + #:builder > + (begin > + (use-modules (guix build utils)) > + (let* ((font-dir "/share/fonts/truetype/cns11643") > + (out (string-append %output font-dir)) I've changes this to use (assoc-ref outputs "out") instead of the magical %output. > + (unzip (string-append > + (assoc-ref %build-inputs "unzip") "/bin/unzip")) > + (tw-kai (string-append > + (assoc-ref %outputs "tw-kai") font-dir)) > + (tw-sung (string-append > + (assoc-ref %outputs "tw-sung") font-dir))) > + (system* unzip (assoc-ref %build-inputs "source")) > + (chdir "Open_Data/Fonts/") > + (install-file "TW-Kai-98_1.ttf" tw-kai) > + (install-file "TW-Sung-98_1.ttf" tw-sung) > + (install-file "TW-Kai-98_1.ttf" out) > + (install-file "TW-Kai-Ext-B-98_1.ttf" out) > + (install-file "TW-Kai-Plus-98_1.ttf" out) > + (install-file "TW-Sung-98_1.ttf" out) > + (install-file "TW-Sung-Ext-B-98_1.ttf" out) > + (install-file "TW-Sung-Plus-98_1.ttf" out))))) And added a #t at the end here, since the return value of "install-file" is unspecified. > + (home-page "http://www.cns11643.gov.tw/AIDB/welcome.do") > + (synopsis "CJK TrueType fonts, TW-Kai and TW-Sung") > + (description > + "@code{CNS 11643} character set (Chinese National Standard, or Chin= ese > +Standard Interchange Code) is the standard character set of the Republic= of > +China (Taiwan) for Chinese Characters and other Unicode symbols. Contai= ned > +are six TrueType fonts based on two script styles, Regular Script (Kai),= and > +Sung/Ming Script, each with three variants: > + > +@itemize > +@item @code{CNS 11643} (@code{TW-Kai} and @code{TW-Sung}): Tens of thous= ands > +of CJK characters from frequency tables published by the Taiwanese > +Ministry of Education. ISO 10646 and Unicode compatible code encoding. > +@item @code{Big-5 Plus}: Several thousand frequently used CJK characters > +encoded in the user defined area of the Big-5 code. > +@item @code{Big-5 Extended}: A Big-5 character set based on the > +@code{Big-5 Plus} and @code{CNS 11643} character sets. > +@end itemize\n") > + (license (license:non-copyleft > + "http://data.gov.tw/license")))) ...and added a comment about this license being compatible with CC-BY 4.0 here. Thanks a lot for packaging these! --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAlkF/koACgkQoqBt8qM6 VPp9tQgApIrKTalZjSYtCXM7gI3hveZM+2FuZvp45gjLqMFT4/kPSbvnROxtt3zs LrrXVjp0QAxLMJuQzmHGjyoX4sJ37WBFmVXH/Fz4ffrVodesqjcGblxK/zBjbz6j tjnjxxjq+XD+dudaxQXUEO9mluzegCoZTQUvBg8BZP+xLNJuKC8XE2OPli6Gbvw9 enuMn/T8tfKeK2ceeTx6vA9Au5e24LzCXGTHIgEnkFUtdkk5Y8m2mRL/nOh3zhA+ RVcbYHhaoZQSYziDqM4Euq8VhGrMttKxz3R0R8PIaD9NhBn8FisxqpdgWx4Mtwjb dRpD2JPI8Dt5hh8atBNkaMpUfFY1Nw== =ljRS -----END PGP SIGNATURE----- --=-=-=--