summaryrefslogtreecommitdiffstats
path: root/pkgs/development/libraries/allegro
diff options
context:
space:
mode:
authorPiotr Bogdan <ppbogdan@gmail.com>2017-09-03 19:12:32 +0100
committerPiotr Bogdan <ppbogdan@gmail.com>2017-09-03 19:32:35 +0100
commite22a77217d08d6b83431a8ed230f6040881acc58 (patch)
tree010529b5be6cca2d48e500bd8285dfc73856e173 /pkgs/development/libraries/allegro
parent2c301b1b48f7443a8346301162de24bfcb30dc1d (diff)
allegro: fix sandboxed build with nixUnstable
In Nix 1.12 sandboxed builds are performed in /build/ directory which conflicts with the regex in docs/CMakeLists.txt, and generated documentation ends up in wrong directory -> https://hydra.nixos.org/build/53914969/nixlog/1 -> CTRL-F abi.txt
Diffstat (limited to 'pkgs/development/libraries/allegro')
-rw-r--r--pkgs/development/libraries/allegro/default.nix4
-rw-r--r--pkgs/development/libraries/allegro/nix-unstable-sandbox-fix.patch13
2 files changed, 17 insertions, 0 deletions
diff --git a/pkgs/development/libraries/allegro/default.nix b/pkgs/development/libraries/allegro/default.nix
index 997a8d223054..c0451486c144 100644
--- a/pkgs/development/libraries/allegro/default.nix
+++ b/pkgs/development/libraries/allegro/default.nix
@@ -12,6 +12,10 @@ stdenv.mkDerivation rec {
sha256 = "1p0ghkmpc4kwij1z9rzxfv7adnpy4ayi0ifahlns1bdzgmbyf88v";
};
+ patches = [
+ ./nix-unstable-sandbox-fix.patch
+ ];
+
buildInputs = [
texinfo libXext xextproto libX11 xproto libXpm libXt libXcursor
alsaLib cmake zlib libpng libvorbis libXxf86dga libXxf86misc
diff --git a/pkgs/development/libraries/allegro/nix-unstable-sandbox-fix.patch b/pkgs/development/libraries/allegro/nix-unstable-sandbox-fix.patch
new file mode 100644
index 000000000000..a227cea1ce7b
--- /dev/null
+++ b/pkgs/development/libraries/allegro/nix-unstable-sandbox-fix.patch
@@ -0,0 +1,13 @@
+diff --git a/docs/CMakeLists.txt b/docs/CMakeLists.txt
+index 32ed053..73ba87f 100644
+--- a/docs/CMakeLists.txt
++++ b/docs/CMakeLists.txt
+@@ -72,7 +72,7 @@ foreach(page ${DOC_SRCS})
+ string(REPLACE "._tx" "" basename ${basename})
+
+ set(page ${CMAKE_CURRENT_SOURCE_DIR}/${page})
+- if(${page} MATCHES "/build/")
++ if(${page} MATCHES ".+/build/")
+ set(txt_out ${CMAKE_CURRENT_BINARY_DIR}/build/${basename}.txt)
+ set(html_out ${CMAKE_CURRENT_BINARY_DIR}/build/${basename}.html)
+ else()