Signed-off-by: Florian Bäuerle <[email protected]>
---
 rules/xorg-font-bh-ttf.make       | 55 ++++++++++++++++++++-----------
 rules/xorg-font-ttf-vlgothic.make |  2 +-
 2 files changed, 37 insertions(+), 20 deletions(-)

diff --git a/rules/xorg-font-bh-ttf.make b/rules/xorg-font-bh-ttf.make
index 59a290094..ed10b5844 100644
--- a/rules/xorg-font-bh-ttf.make
+++ b/rules/xorg-font-bh-ttf.make
@@ -2,6 +2,7 @@
 #
 # Copyright (C) 2006 by Erwin Rol
 #           (C) 2010 by Michael Olbrich <[email protected]>
+#           (C) 2018 by Florian Bäuerle <[email protected]>
 #
 # See CREDITS for details about who has contributed to this project.
 #
@@ -26,23 +27,16 @@ XORG_FONT_BH_TTF_SOURCE             := 
$(SRCDIR)/$(XORG_FONT_BH_TTF).$(XORG_FONT_BH_TTF_SUF
 XORG_FONT_BH_TTF_DIR           := $(BUILDDIR)/$(XORG_FONT_BH_TTF)
 XORG_FONT_BH_TTF_LICENSE       := Luxi
 
-ifdef PTXCONF_XORG_FONT_BH_TTF
-$(STATEDIR)/xorg-fonts.targetinstall.post: 
$(STATEDIR)/xorg-font-bh-ttf.targetinstall
-endif
+XORG_FONT_BH_TTF_FONTDIR       := $(XORG_FONTDIR)/truetype/bh
+XORG_FONT_BH_TTF_FONTPKGDIR    := 
$(XORG_FONT_BH_TTF_PKGDIR)$(XORG_FONT_BH_TTF_FONTDIR)
 
 # ----------------------------------------------------------------------------
-# Prepare
+# Compile
 # ----------------------------------------------------------------------------
 
-XORG_FONT_BH_TTF_PATH  := PATH=$(CROSS_PATH)
-XORG_FONT_BH_TTF_ENV   := $(CROSS_ENV)
-
-#
-# autoconf
-#
-XORG_FONT_BH_TTF_AUTOCONF := \
-       $(CROSS_AUTOCONF_USR) \
-       --with-fontdir=$(XORG_FONTDIR)/truetype
+$(STATEDIR)/xorg-font-bh-ttf.compile:
+       @$(call targetinfo)
+       @$(call touch)
 
 # ----------------------------------------------------------------------------
 # Install
@@ -50,6 +44,18 @@ XORG_FONT_BH_TTF_AUTOCONF := \
 
 $(STATEDIR)/xorg-font-bh-ttf.install:
        @$(call targetinfo)
+
+       @rm -rf $(XORG_FONT_BH_TTF_PKGDIR)
+       @mkdir -p $(XORG_FONT_BH_TTF_FONTPKGDIR)
+       @find $(XORG_FONT_BH_TTF_DIR) \
+               -name "*.ttf" \
+               | \
+               while read file; do \
+               install -m 644 $${file} $(XORG_FONT_BH_TTF_FONTPKGDIR); \
+       done
+       @mkfontscale $(XORG_FONT_BH_TTF_FONTPKGDIR)
+       @mkfontdir $(XORG_FONT_BH_TTF_FONTPKGDIR)
+
        @$(call touch)
 
 # ----------------------------------------------------------------------------
@@ -59,14 +65,25 @@ $(STATEDIR)/xorg-font-bh-ttf.install:
 $(STATEDIR)/xorg-font-bh-ttf.targetinstall:
        @$(call targetinfo)
 
-       @mkdir -p $(XORG_FONTS_DIR_INSTALL)/truetype
+       @$(call install_init, xorg-font-bh-ttf)
+       @$(call install_fixup, xorg-font-bh-ttf,PRIORITY,optional)
+       @$(call install_fixup, xorg-font-bh-ttf,SECTION,base)
+       @$(call install_fixup, xorg-font-bh-ttf,AUTHOR,"Florian Bäuerle 
<[email protected]>")
+       @$(call install_fixup, xorg-font-bh-ttf,DESCRIPTION,missing)
 
-       @find $(XORG_FONT_BH_TTF_DIR) \
-               -name "*.ttf" \
-               | \
-               while read file; do \
-               install -m 644 $${file} $(XORG_FONTS_DIR_INSTALL)/truetype; \
+       @$(call install_tree, xorg-font-bh-ttf, 0, 0, -, 
$(XORG_FONT_BH_TTF_FONTDIR))
+
+ifdef PTXCONF_XORG_FONTS_QT4_LINKS
+       @cd $(XORG_FONT_BH_TTF_PKGDIR) && \
+       find . -type f -name "*.ttf" | while read file; do \
+               name=$$(basename $$file); \
+               $(call install_link, xorg-font-bh-ttf, \
+                       ../../..$(XORG_FONT_BH_TTF_FONTDIR)/$$name, \
+                       /usr/lib/fonts/$$name); \
        done
+endif
+
+       @$(call install_finish, xorg-font-bh-ttf)
 
        @$(call touch)
 
diff --git a/rules/xorg-font-ttf-vlgothic.make 
b/rules/xorg-font-ttf-vlgothic.make
index 41ac1f713..e463d5c74 100644
--- a/rules/xorg-font-ttf-vlgothic.make
+++ b/rules/xorg-font-ttf-vlgothic.make
@@ -1,7 +1,7 @@
 # -*-makefile-*-
 #
 # Copyright (C) 2015 by Michael Olbrich <[email protected]>
-#              2018 by Florian Bäuerle <[email protected]>
+#           (C) 2018 by Florian Bäuerle <[email protected]>
 #
 # See CREDITS for details about who has contributed to this project.
 #
-- 
2.18.0


_______________________________________________
ptxdist mailing list
[email protected]

Reply via email to