diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /eclass/font-ebdftopcf.eclass |
reinit the tree, so we can have metadata
Diffstat (limited to 'eclass/font-ebdftopcf.eclass')
-rw-r--r-- | eclass/font-ebdftopcf.eclass | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/eclass/font-ebdftopcf.eclass b/eclass/font-ebdftopcf.eclass new file mode 100644 index 000000000000..c36cd14256fa --- /dev/null +++ b/eclass/font-ebdftopcf.eclass @@ -0,0 +1,45 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +# Author: Robin H. Johnson <robbat2@gentoo.org> + +# font-ebdftopcf.eclass +# Eclass to make PCF font generator from BDF uniform and optimal +# The manpage for this eclass is in media-gfx/ebdftopcf. + +# inherit this eclass after font.eclass + +# if USE="-X", this eclass is basically a no-op, since bdftopcf requires Xorg. +IUSE="X" + +# Variable declarations +DEPEND="X? ( media-gfx/ebdftopcf )" +RDEPEND="" + +# +# Public functions +# +ebdftopcf() { + local bdffiles + bdffiles="$@" + [ -z "$bdffiles" ] && die "No BDF files specified." + emake -f "${EPREFIX}"/usr/share/ebdftopcf/Makefile.ebdftopcf \ + BDFFILES="${bdffiles}" \ + BDFTOPCF_PARAMS="${BDFTOPCF_PARAMS}" \ + || die "Failed to build PCF files" +} + +# +# Public inheritable functions +# +font-ebdftopcf_src_compile() { + use X && FONT_SUFFIX="pcf.gz" + use X || FONT_SUFFIX="bdf" + + if use X; then + [ -z "${BDFFILES}" ] && BDFFILES="$(find . -name '*.bdf')" + ebdftopcf ${BDFFILES} + fi +} + +EXPORT_FUNCTIONS src_compile |