@@ -2052,58 +2052,7 @@ in {
20522052
20532053 canmatrix = callPackage ../development/python-modules/canmatrix {};
20542054
2055− cairocffi = buildPythonPackage rec {
2056− name = "cairocffi-0.7.2";
2057−
2058− src = pkgs.fetchurl {
2059− url = "mirror://pypi/c/cairocffi/${name}.tar.gz";
2060− sha256 = "e42b4256d27bd960cbf3b91a6c55d602defcdbc2a73f7317849c80279feeb975";
2061− };
2062−
2063− LC_ALL = "en_US.UTF-8";
2064−
2065− # checkPhase require at least one 'normal' font and one 'monospace',
2066− # otherwise glyph tests fails
2067− FONTCONFIG_FILE = pkgs.makeFontsConf {
2068− fontDirectories = [ pkgs.freefont_ttf ];
2069− };
2070−
2071− buildInputs = with self; [ pytest pkgs.glibcLocales ];
2072− propagatedBuildInputs = with self; [ pkgs.cairo cffi ];
2073−
2074− checkPhase = ''
2075− py.test $out/${python.sitePackages}
2076− '';
2077−
2078− # FIXME: make gdk_pixbuf dependency optional (as wel as xcfffi)
2079− # Happens with 0.7.1 and 0.7.2
2080− # OSError: dlopen() failed to load a library: gdk_pixbuf-2.0 / gdk_pixbuf-2.0-0
2081−
2082− patches = [
2083− # This patch from PR substituted upstream
2084− (pkgs.fetchpatch {
2085− url = "https://github.com/avnik/cairocffi/commit/2266882e263c5efc87350cf016d117b2ec6a1d59.patch";
2086− sha256 = "0gb570z3ivf1b0ixsk526n3h29m8c5rhjsiyam7rr3x80dp65cdl";
2087− })
2088−
2089− ../development/python-modules/cairocffi/dlopen-paths.patch
2090− ../development/python-modules/cairocffi/fix_test_scaled_font.patch
2091− ];
2092−
2093− postPatch = ''
2094− # Hardcode cairo library path
2095− substituteInPlace cairocffi/__init__.py --subst-var-by cairo ${pkgs.cairo.out}
2096− substituteInPlace cairocffi/__init__.py --subst-var-by glib ${pkgs.glib.out}
2097− substituteInPlace cairocffi/__init__.py --subst-var-by gdk_pixbuf ${pkgs.gdk_pixbuf.out}
2098− '';
2099−
2100− meta = {
2101− homepage = https://github.com/SimonSapin/cairocffi;
2102− license = "bsd";
2103− description = "cffi-based cairo bindings for Python";
2104− };
2105− };
2106−
2055+ cairocffi = callPackage ../development/python-modules/cairocffi {};
21072056
21082057 cairosvg = buildPythonPackage rec {
21092058 version = "1.0.18";