2007-12-25 13:29:02 +01:00
|
|
|
args : with args;
|
2008-11-04 22:24:10 +01:00
|
|
|
let localDefs = builderDefs.passthru.function {
|
2007-12-25 13:29:02 +01:00
|
|
|
src =""; /* put a fetchurl here */
|
2008-03-02 20:19:34 +01:00
|
|
|
buildInputs = [mkfontdir mkfontscale ttmkfdir];
|
2007-12-25 13:29:02 +01:00
|
|
|
configureFlags = [];
|
2008-08-19 07:54:09 +02:00
|
|
|
};
|
2008-01-18 13:36:56 +01:00
|
|
|
in with localDefs;
|
2007-12-25 13:29:02 +01:00
|
|
|
let
|
2009-05-20 01:25:58 +02:00
|
|
|
doInstall = fullDepEntry ("
|
2007-12-25 13:29:02 +01:00
|
|
|
ensureDir \$out/share/fonts/
|
|
|
|
cd \$out/share/fonts
|
|
|
|
for i in ${toString paths}; do
|
|
|
|
find \$i -type f -exec ln -s '{}' . ';' ;
|
|
|
|
done
|
|
|
|
mkfontdir
|
|
|
|
mkfontscale
|
2008-03-02 20:19:34 +01:00
|
|
|
mv fonts.scale fonts.scale.old
|
|
|
|
mv fonts.dir fonts.dir.old
|
|
|
|
ttmkfdir
|
|
|
|
cat fonts.dir.old >> fonts.dir
|
|
|
|
cat fonts.scale.old >> fonts.scale
|
|
|
|
rm fonts.dir.old fonts.scale.old
|
2007-12-25 13:29:02 +01:00
|
|
|
") [minInit addInputs defEnsureDir] ;
|
|
|
|
in
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "wrapped-font-dir";
|
|
|
|
builder = writeScript (name + "-builder")
|
2008-01-18 13:36:56 +01:00
|
|
|
(textClosure localDefs [ doInstall doForceShare doPropagate]);
|
2007-12-25 13:29:02 +01:00
|
|
|
meta = {
|
|
|
|
description = "
|
2008-01-18 13:36:56 +01:00
|
|
|
Just a wrapper to create fonts.dir and fonts.scale .
|
2007-12-25 13:29:02 +01:00
|
|
|
";
|
2008-03-02 19:49:31 +01:00
|
|
|
inherit src;
|
2007-12-25 13:29:02 +01:00
|
|
|
};
|
|
|
|
}
|