nixpkgs/pkgs/development/libraries/sfml/default.nix
R. RyanTM 9f0381d497 sfml: 2.5.0 -> 2.5.1 (#48907)
* sfml: 2.5.0 -> 2.5.1

Semi-automatic update generated by
https://github.com/ryantm/nixpkgs-update tools. This update was made
based on information from
https://repology.org/metapackage/sfml/versions

* sfml: cmake is only needed at build time

Moved cmake from buildInputs to nativeBuildInputs

* sfml: use fetchzip instead of fetchurl

Don't use fetchurl for changing GitHub archive tarballs
2018-10-27 14:11:57 +02:00

42 lines
1.4 KiB
Nix

{ stdenv, fetchzip, cmake, libX11, freetype, libjpeg, openal, flac, libvorbis
, glew, libXrandr, libXrender, udev, xcbutilimage
, IOKit, Foundation, AppKit, OpenAL
}:
let
version = "2.5.1";
in
stdenv.mkDerivation rec {
name = "sfml-${version}";
src = fetchzip {
url = "https://github.com/SFML/SFML/archive/${version}.tar.gz";
sha256 = "0abr8ri2ssfy9ylpgjrr43m6rhrjy03wbj9bn509zqymifvq5pay";
};
nativeBuildInputs = [ cmake ];
buildInputs = [ libX11 freetype libjpeg openal flac libvorbis glew
libXrandr libXrender xcbutilimage
] ++ stdenv.lib.optional stdenv.isLinux udev
++ stdenv.lib.optionals stdenv.isDarwin [ IOKit Foundation AppKit OpenAL ];
cmakeFlags = [ "-DSFML_INSTALL_PKGCONFIG_FILES=yes"
"-DSFML_MISC_INSTALL_PREFIX=share/SFML"
"-DSFML_BUILD_FRAMEWORKS=no"
"-DSFML_USE_SYSTEM_DEPS=yes" ];
meta = with stdenv.lib; {
homepage = http://www.sfml-dev.org/;
description = "Simple and fast multimedia library";
longDescription = ''
SFML is a simple, fast, cross-platform and object-oriented multimedia API.
It provides access to windowing, graphics, audio and network.
It is written in C++, and has bindings for various languages such as C, .Net, Ruby, Python.
'';
license = licenses.zlib;
maintainers = [ maintainers.astsmtl ];
platforms = platforms.unix;
};
}