1 { lib, stdenv, fetchFromGitHub, cmake, fetchpatch }:
3 stdenv.mkDerivation rec {
4 pname = "nvidia-texture-tools";
5 version = "unstable-2019-10-27";
7 src = fetchFromGitHub {
9 repo = "nvidia-texture-tools";
10 rev = "a131e4c6b0b7c9c73ccc3c9e6f1c7e165be86bcc";
11 sha256 = "1qzyr3ib5dpxyq1y33lq02qv4cww075sm9bm4f651d34q5x38sk3";
16 url = "https://github.com/castano/nvidia-texture-tools/commit/6474f2593428d89ec152da2502aa136ababe66ca.patch";
17 sha256 = "0akbkvm55hiv58jx71h9hj173rbnqlb5a430y9azjiix7zga42vd";
21 nativeBuildInputs = [ cmake ];
23 outputs = [ "out" "dev" "lib" ];
26 # Make a recently added pure virtual function just virtual,
27 # to keep compatibility.
28 sed -i 's/virtual void endImage() = 0;/virtual void endImage() {}/' src/nvtt/nvtt.h
36 moveToOutput include "$dev"
37 moveToOutput lib "$lib"
41 description = "A set of cuda-enabled texture tools and compressors";
42 homepage = "https://github.com/castano/nvidia-texture-tools";
43 license = licenses.mit;
44 platforms = platforms.unix;
45 broken = stdenv.isAarch64;