diff options
author | Sebastian Dröge <sebastian.droege@collabora.co.uk> | 2013-04-18 13:12:11 +0200 |
---|---|---|
committer | Sebastian Dröge <sebastian.droege@collabora.co.uk> | 2013-04-22 08:35:08 +0200 |
commit | 1cc18c6336cb01ac4d3482725073592a6be23468 (patch) | |
tree | af034cacc6bf15ea2a2869eb26d8b1c71db8e6b5 | |
parent | 168949eb504c99c3307eabb68d2776f44cf7e949 (diff) |
fontconfig: Create relative links to the configuration files
-rw-r--r-- | recipes/fontconfig.recipe | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/recipes/fontconfig.recipe b/recipes/fontconfig.recipe index ddb6b24..d8920db 100644 --- a/recipes/fontconfig.recipe +++ b/recipes/fontconfig.recipe @@ -1,5 +1,6 @@ # -*- Mode: Python -*- vi:si:et:sw=4:sts=4:ts=4:syntax=python +import os class Recipe(recipe.Recipe): name = 'fontconfig' @@ -23,3 +24,15 @@ class Recipe(recipe.Recipe): self.configure_options = '--with-arch=x86_64' else: self.configure_options = '--with-arch=i686' + + def post_install(self): + # Create relative symlinks to prevent breakage during packaging + if self.config.target_platform != Platform.WINDOWS: + confddir = os.path.join(self.config.prefix, 'etc', 'fonts', 'conf.d') + linksrc = os.path.join('..', '..', '..', 'share', 'fontconfig', 'conf.avail') + for f in os.listdir(confddir): + if not f.endswith('.conf'): + continue + os.remove(os.path.join(confddir, f)) + os.symlink(os.path.join(linksrc, f), os.path.join(confddir, f)) + |