2020-02-16 12:44:16 +00:00
|
|
|
{ stdenv, fetchFromGitHub, python3, bdftopcf, mkfontscale }:
|
2015-06-04 22:09:32 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2020-02-16 12:44:16 +00:00
|
|
|
pname = "tewi-font";
|
|
|
|
version = "2.0.2";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "lucy";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
|
|
|
sha256 = "1axv9bv10xlcmgfyjh3z5kn5fkg3m6n1kskcs5hvlmyb6m1zk91j";
|
2015-06-04 22:09:32 +01:00
|
|
|
};
|
|
|
|
|
2020-02-16 12:44:16 +00:00
|
|
|
nativeBuildInputs = [ python3 bdftopcf mkfontscale ];
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
# do not update fontconfig cache
|
|
|
|
sed '32,33d' -i Makefile
|
|
|
|
|
|
|
|
# make gzip deterministic
|
|
|
|
sed 's/gzip -9/gzip -9 -n/g' -i Makefile
|
2015-06-04 22:09:32 +01:00
|
|
|
|
2020-02-16 12:44:16 +00:00
|
|
|
# fix python not found
|
|
|
|
patchShebangs scripts/merge
|
2015-06-04 22:09:32 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
fontDir="$out/share/fonts/misc"
|
2020-02-16 12:44:16 +00:00
|
|
|
install -m 644 -D out/* -t "$fontDir"
|
|
|
|
mkfontdir "$fontDir"
|
2015-06-04 22:09:32 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "A nice bitmap font, readable even at small sizes";
|
|
|
|
longDescription = ''
|
|
|
|
Tewi is a bitmap font, readable even at very small font sizes. This is
|
|
|
|
particularily useful while programming, to fit a lot of code on your
|
|
|
|
screen.
|
|
|
|
'';
|
2017-08-01 21:03:30 +01:00
|
|
|
homepage = https://github.com/lucy/tewi-font;
|
2015-06-04 22:09:32 +01:00
|
|
|
license = {
|
|
|
|
fullName = "GNU General Public License with a font exception";
|
|
|
|
url = "https://www.gnu.org/licenses/gpl-faq.html#FontException";
|
|
|
|
};
|
|
|
|
maintainers = [ maintainers.fro_ozen ];
|
|
|
|
};
|
|
|
|
}
|