nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at 20.09 63 lines 1.8 kB view raw
1{ stdenv, fetchurl 2# Image file formats 3, libjpeg, libtiff, giflib, libpng, libwebp 4# imlib2 can load images from ID3 tags. 5, libid3tag 6, freetype , bzip2, pkgconfig 7, x11Support ? true, xlibsWrapper ? null 8}: 9 10let 11 inherit (stdenv.lib) optional; 12in 13stdenv.mkDerivation rec { 14 pname = "imlib2"; 15 version = "1.7.0"; 16 17 src = fetchurl { 18 url = "mirror://sourceforge/enlightenment/${pname}-${version}.tar.bz2"; 19 sha256 = "0zdk4afdrrr1539f2q15zja19j4wwfmpswzws2ffgflcnhywlxhr"; 20 }; 21 22 buildInputs = [ 23 libjpeg libtiff giflib libpng libwebp 24 bzip2 freetype libid3tag 25 ] ++ optional x11Support xlibsWrapper; 26 27 nativeBuildInputs = [ pkgconfig ]; 28 29 enableParallelBuilding = true; 30 31 preConfigure = '' 32 substituteInPlace imlib2-config.in \ 33 --replace "@my_libs@" "" 34 ''; 35 36 # Do not build amd64 assembly code on Darwin, because it fails to compile 37 # with unknow directive errors 38 configureFlags = optional stdenv.isDarwin "--enable-amd64=no" 39 ++ optional (!x11Support) "--without-x"; 40 41 outputs = [ "bin" "out" "dev" ]; 42 43 postInstall = '' 44 moveToOutput bin/imlib2-config "$dev" 45 ''; 46 47 meta = with stdenv.lib; { 48 description = "Image manipulation library"; 49 50 longDescription = '' 51 This is the Imlib 2 library - a library that does image file loading and 52 saving as well as rendering, manipulation, arbitrary polygon support, etc. 53 It does ALL of these operations FAST. Imlib2 also tries to be highly 54 intelligent about doing them, so writing naive programs can be done 55 easily, without sacrificing speed. 56 ''; 57 58 homepage = "https://docs.enlightenment.org/api/imlib2/html"; 59 license = licenses.mit; 60 platforms = platforms.unix; 61 maintainers = with maintainers; [ spwhitt ]; 62 }; 63}