Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: af6cc8e70465
Choose a base ref
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: ba2a04f656d1
Choose a head ref
  • 1 commit
  • 1 file changed
  • 1 contributor

Commits on Mar 23, 2018

  1. glslviewer: 1.2 -> 2018-01-31, fixes build

    (cherry picked from commit a8eb2c9)
    dezgeg committed Mar 23, 2018
    Copy the full SHA
    ba2a04f View commit details
Showing with 21 additions and 11 deletions.
  1. +21 −11 pkgs/development/tools/glslviewer/default.nix
32 changes: 21 additions & 11 deletions pkgs/development/tools/glslviewer/default.nix
Original file line number Diff line number Diff line change
@@ -1,36 +1,46 @@
{ stdenv, fetchFromGitHub, glfw, pkgconfig, libXrandr, libXdamage
, libXext, libXrender, libXinerama, libXcursor, libXxf86vm, libXi
, libX11, libGLU, Cocoa
, libX11, libGLU, python2Packages, ensureNewerSourcesForZipFilesHook
, Cocoa
}:

stdenv.mkDerivation rec {
name = "glslviewer-${version}";
version = "1.2";
version = "2018-01-31";

src = fetchFromGitHub {
owner = "patriciogonzalezvivo";
repo = "glslViewer";
rev = version;
sha256 = "05ya821l2pd58anyx21mgmlm2bv78rz8cnbvqw4d9pfhq40z9psw";
rev = "cac40f6984dbeb638950744c9508aa88591fea6c";
sha256 = "1bykpp68hdxjlxvi1xicyb6822mz69q0adz24faaac372pls4bk0";
};

nativeBuildInputs = [ pkgconfig ensureNewerSourcesForZipFilesHook ];
buildInputs = [
glfw libGLU glfw libXrandr libXdamage
libXext libXrender libXinerama libXcursor libXxf86vm
libXi libX11
] ++ (with python2Packages; [ python setuptools wrapPython ])
++ stdenv.lib.optional stdenv.isDarwin Cocoa;
pythonPath = with python2Packages; [ requests.dev ];

# Makefile has /usr/local/bin hard-coded for 'make install'
preConfigure = ''
substituteInPlace Makefile \
--replace '/usr/local' "$out" \
--replace '/usr/bin/clang++' 'clang++'
substituteInPlace Makefile \
--replace 'python setup.py install' "python setup.py install --prefix=$out"
'';

preInstall = ''
mkdir -p $out/bin
mkdir -p $out/bin $(toPythonPath "$out")
export PYTHONPATH=$PYTHONPATH:$(toPythonPath "$out")
'';

nativeBuildInputs = [ pkgconfig ];
buildInputs = [
glfw libGLU glfw libXrandr libXdamage
libXext libXrender libXinerama libXcursor libXxf86vm
libXi libX11
] ++ stdenv.lib.optional stdenv.isDarwin Cocoa;
postInstall = ''
wrapPythonPrograms
'';

meta = with stdenv.lib; {
description = "Live GLSL coding renderer";