2014-06-26 20:24:44 +04:00
|
|
|
{ stdenv, fetchurl, cmake, zlib, freetype, libjpeg, libtiff, fontconfig
|
|
|
|
, openssl, libpng, lua5 }:
|
2010-01-08 01:47:30 +03:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2013-03-18 15:20:43 +04:00
|
|
|
name = "podofo-0.9.2";
|
2014-06-26 20:24:44 +04:00
|
|
|
|
2010-01-08 01:47:30 +03:00
|
|
|
src = fetchurl {
|
|
|
|
url = "mirror://sourceforge/podofo/${name}.tar.gz";
|
2013-03-18 15:20:43 +04:00
|
|
|
sha256 = "1wx3s0718rmhdzdwyi8hgpf2s92sk3hijy8f4glrmnjpiihr2la6";
|
2010-01-08 01:47:30 +03:00
|
|
|
};
|
2014-06-26 20:24:44 +04:00
|
|
|
|
2010-09-16 12:40:47 +04:00
|
|
|
propagatedBuildInputs = [ zlib freetype libjpeg libtiff fontconfig openssl libpng ];
|
2012-12-28 22:20:09 +04:00
|
|
|
nativeBuildInputs = [ cmake ];
|
2012-10-27 16:50:00 +04:00
|
|
|
buildInputs = [ lua5 stdenv.gcc.libc ];
|
2013-04-10 18:49:18 +04:00
|
|
|
|
|
|
|
crossAttrs = {
|
|
|
|
propagatedBuildInputs = [ zlib.crossDrv freetype.crossDrv libjpeg.crossDrv
|
|
|
|
libtiff.crossDrv fontconfig.crossDrv openssl.crossDrv libpng.crossDrv
|
|
|
|
lua5.crossDrv stdenv.gccCross.libc ];
|
|
|
|
};
|
|
|
|
|
2014-06-26 20:24:44 +04:00
|
|
|
# fix finding freetype-2.5
|
|
|
|
preConfigure = ''
|
|
|
|
substituteInPlace ./CMakeLists.txt \
|
|
|
|
--replace FREETYPE_INCLUDE_DIR FREETYPE_INCLUDE_DIRS \
|
|
|
|
--replace 'FIND_PACKAGE(FREETYPE' 'FIND_PACKAGE(Freetype'
|
|
|
|
|
|
|
|
rm ./cmake/modules/Find{FREETYPE,ZLIB,PkgConfig}.cmake
|
|
|
|
'';
|
|
|
|
|
2010-01-08 01:47:30 +03:00
|
|
|
cmakeFlags = "-DPODOFO_BUILD_SHARED=ON -DPODOFO_BUILD_STATIC=OFF";
|
2010-09-15 22:37:38 +04:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = http://podofo.sourceforge.net;
|
|
|
|
description = "A library to work with the PDF file format";
|
|
|
|
platforms = stdenv.lib.platforms.all;
|
|
|
|
maintainers = [ stdenv.lib.maintainers.urkud ];
|
|
|
|
};
|
2010-01-08 01:47:30 +03:00
|
|
|
}
|