summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPacho Ramos <pacho@gentoo.org>2018-10-14 21:42:48 +0200
committerPacho Ramos <pacho@gentoo.org>2018-10-14 21:43:54 +0200
commit268be533088b3305127faa9bf4dcb048d3b4934a (patch)
tree28e06309da00ad8a0ea9c1cb7237747fe29feaaa /media-fonts/noto-emoji
parentdev-python/nototools: New package needed for noto-emoji (diff)
downloadgentoo-268be533088b3305127faa9bf4dcb048d3b4934a.tar.gz
gentoo-268be533088b3305127faa9bf4dcb048d3b4934a.tar.bz2
gentoo-268be533088b3305127faa9bf4dcb048d3b4934a.zip
media-fonts/noto-emoji: New noto-emoji fonts (splitted from noto)
Signed-off-by: Pacho Ramos <pacho@gentoo.org> Package-Manager: Portage-2.3.51, Repoman-2.3.11
Diffstat (limited to 'media-fonts/noto-emoji')
-rw-r--r--media-fonts/noto-emoji/Manifest1
-rw-r--r--media-fonts/noto-emoji/files/noto-emoji-build-all-flags.patch11
-rw-r--r--media-fonts/noto-emoji/files/noto-emoji-use-system-pngquant.patch59
-rw-r--r--media-fonts/noto-emoji/metadata.xml8
-rw-r--r--media-fonts/noto-emoji/noto-emoji-20180814.ebuild46
5 files changed, 125 insertions, 0 deletions
diff --git a/media-fonts/noto-emoji/Manifest b/media-fonts/noto-emoji/Manifest
new file mode 100644
index 000000000000..79d84c3fc5b3
--- /dev/null
+++ b/media-fonts/noto-emoji/Manifest
@@ -0,0 +1 @@
+DIST noto-emoji-20180814.tar.gz 51709109 BLAKE2B 9678861973b231de48b11dc9267840e4a4a6689c7c26281dfc1d6b0d4c1c1c627b503226d7eeac2f568dc19162c669b54c8dd34f5aa449850797437cf3a2e8cb SHA512 bca0fb73d3897c4ec1ba94173fda17804cdf2dfa365aa4a19bf1d24e9a94806bcdd5e6eb6304eb3e2312b37f37fa917905be6fe11c84510214f0eba70f426ea8
diff --git a/media-fonts/noto-emoji/files/noto-emoji-build-all-flags.patch b/media-fonts/noto-emoji/files/noto-emoji-build-all-flags.patch
new file mode 100644
index 000000000000..564b08a59078
--- /dev/null
+++ b/media-fonts/noto-emoji/files/noto-emoji-build-all-flags.patch
@@ -0,0 +1,11 @@
+--- old/Makefile 2018-05-03 20:32:14.000000000 +0200
++++ new/Makefile 2018-05-08 11:48:20.811073447 +0200
+@@ -78,7 +78,7 @@
+
+ ALL_FLAGS = $(basename $(notdir $(wildcard $(FLAGS_SRC_DIR)/*.png)))
+
+-FLAGS = $(SELECTED_FLAGS)
++FLAGS = $(ALL_FLAGS)
+
+ FLAG_NAMES = $(FLAGS:%=%.png)
+ FLAG_FILES = $(addprefix $(FLAGS_DIR)/, $(FLAG_NAMES))
diff --git a/media-fonts/noto-emoji/files/noto-emoji-use-system-pngquant.patch b/media-fonts/noto-emoji/files/noto-emoji-use-system-pngquant.patch
new file mode 100644
index 000000000000..ddc6ff881ce1
--- /dev/null
+++ b/media-fonts/noto-emoji/files/noto-emoji-use-system-pngquant.patch
@@ -0,0 +1,59 @@
+diff -ru noto-emoji-153e1d4c026c124fbac6ee93e559b5df375f24f5.orig/Makefile noto-emoji-153e1d4c026c124fbac6ee93e559b5df375f24f5/Makefile
+--- noto-emoji-153e1d4c026c124fbac6ee93e559b5df375f24f5.orig/Makefile 2018-03-07 09:22:49.670696985 +0100
++++ noto-emoji-153e1d4c026c124fbac6ee93e559b5df375f24f5/Makefile 2018-03-07 09:23:06.824506178 +0100
+@@ -15,10 +15,9 @@
+ EMOJI = NotoColorEmoji
+ font: $(EMOJI).ttf
+
+-CFLAGS = -std=c99 -Wall -Wextra `pkg-config --cflags --libs cairo`
++CFLAGS = $(OPT_CFLAGS) `pkg-config --cflags --libs cairo`
+ LDFLAGS = -lm `pkg-config --libs cairo`
+-PNGQUANTDIR := third_party/pngquant
+-PNGQUANT := $(PNGQUANTDIR)/pngquant
++PNGQUANT = pngquant
+ PNGQUANTFLAGS = --speed 1 --skip-if-larger --quality 85-95 --force
+ BODY_DIMENSIONS = 136x128
+ IMOPS := -size $(BODY_DIMENSIONS) canvas:none -compose copy -gravity center
+@@ -97,6 +96,12 @@
+ ALL_COMPRESSED_FILES = $(addprefix $(COMPRESSED_DIR)/, $(ALL_NAMES))
+
+ # tool checks
++ifeq (,$(shell which $(PNGQUANT)))
++ ifeq (,$(wildcard $(PNGQUANT)))
++ MISSING_PNGQUANT = fail
++ endif
++endif
++
+ ifeq (,$(shell which $(ZOPFLIPNG)))
+ ifeq (,$(wildcard $(ZOPFLIPNG)))
+ MISSING_ZOPFLI = fail
+@@ -126,6 +131,11 @@
+
+ compressed: $(ALL_COMPRESSED_FILES)
+
++check_quantization_tool:
++ifdef MISSING_PNGQUANT
++ $(error "$(PNGQUANT) is not available")
++endif
++
+ check_compress_tool:
+ ifdef MISSING_ZOPFLI
+ ifdef MISSING_OPTIPNG
+@@ -146,8 +156,7 @@
+ $(EMOJI_DIR) $(FLAGS_DIR) $(RESIZED_FLAGS_DIR) $(RENAMED_FLAGS_DIR) $(QUANTIZED_DIR) $(COMPRESSED_DIR):
+ mkdir -p "$@"
+
+-$(PNGQUANT):
+- $(MAKE) -C $(PNGQUANTDIR)
++$(PNGQUANT): check_quantization_tool
+
+ waveflag: waveflag.c
+ $(CC) $< -o $@ $(CFLAGS) $(LDFLAGS)
+@@ -227,5 +236,5 @@
+ .SECONDARY: $(EMOJI_FILES) $(FLAG_FILES) $(RESIZED_FLAG_FILES) $(RENAMED_FLAG_FILES) \
+ $(ALL_QUANTIZED_FILES) $(ALL_COMPRESSED_FILES)
+
+-.PHONY: clean flags emoji renamed_flags quantized compressed check_compress_tool
++.PHONY: clean flags emoji renamed_flags quantized compressed check_compress_tool check_quantization_tool
+
+noto-emoji-153e1d4c026c124fbac6ee93e559b5df375f24f5/ のみに存在: Makefile.orig
diff --git a/media-fonts/noto-emoji/metadata.xml b/media-fonts/noto-emoji/metadata.xml
new file mode 100644
index 000000000000..3da97a9953cc
--- /dev/null
+++ b/media-fonts/noto-emoji/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>pacho@gentoo.org</email>
+ <name>Pacho Ramos</name>
+ </maintainer>
+</pkgmetadata>
diff --git a/media-fonts/noto-emoji/noto-emoji-20180814.ebuild b/media-fonts/noto-emoji/noto-emoji-20180814.ebuild
new file mode 100644
index 000000000000..55a94f7b5777
--- /dev/null
+++ b/media-fonts/noto-emoji/noto-emoji-20180814.ebuild
@@ -0,0 +1,46 @@
+# Copyright 1999-2018 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+PYTHON_COMPAT=( python2_7 )
+
+inherit font python-any-r1
+
+DESCRIPTION="Google Noto Emoji fonts"
+HOMEPAGE="https://www.google.com/get/noto/ https://github.com/googlei18n/noto-emoji"
+
+COMMIT="3ffd20ec7504657aa17c84f9aa475ad09b20c362"
+SRC_URI="https://github.com/googlei18n/noto-emoji/archive/${COMMIT}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND="${PYTHON_DEPS}
+ app-arch/zopfli
+ dev-python/fonttools
+ dev-python/nototools
+ media-gfx/pngquant
+ x11-libs/cairo
+"
+RDEPEND=""
+
+RESTRICT="binchecks strip"
+
+S="${WORKDIR}/${PN}-${COMMIT}"
+
+FONT_S="${S}"
+FONT_SUFFIX="ttf"
+
+PATCHES=(
+ # From Fedora
+ "${FILESDIR}/${PN}-use-system-pngquant.patch"
+ "${FILESDIR}/${PN}-build-all-flags.patch"
+)
+
+src_prepare() {
+ default
+ # Use system pngquant
+ rm -rf third_party/pngquant
+}