uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
35
pkgs/development/libraries/AntTweakBar/default.nix
Normal file
35
pkgs/development/libraries/AntTweakBar/default.nix
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
{ lib, stdenv, fetchurl, unzip, xorg, libGLU, libGL }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "AntTweakBar";
|
||||
version = "1.16";
|
||||
|
||||
nativeBuildInputs = [ unzip ];
|
||||
buildInputs = [ xorg.libX11 libGLU libGL ];
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/project/anttweakbar/AntTweakBar_${lib.replaceStrings ["."] [""] version}.zip";
|
||||
sha256 = "0z3frxpzf54cjs07m6kg09p7nljhr7140f4pznwi7srwq4cvgkpv";
|
||||
};
|
||||
|
||||
postPatch = "cd src";
|
||||
installPhase = ''
|
||||
mkdir -p $out/lib/
|
||||
cp ../lib/{libAntTweakBar.so,libAntTweakBar.so.1,libAntTweakBar.a} $out/lib/
|
||||
cp -r ../include $out/
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Add a light/intuitive GUI to OpenGL applications";
|
||||
longDescription = ''
|
||||
A small and easy-to-use C/C++ library that allows to quickly add a light
|
||||
and intuitive graphical user interface into graphic applications based on OpenGL
|
||||
(compatibility and core profiles), DirectX 9, DirectX 10 or DirectX 11
|
||||
to interactively tweak parameters on-screen
|
||||
'';
|
||||
homepage = "http://anttweakbar.sourceforge.net/";
|
||||
license = lib.licenses.zlib;
|
||||
maintainers = [ lib.maintainers.razvan ];
|
||||
platforms = lib.platforms.linux;
|
||||
};
|
||||
}
|
||||
46
pkgs/development/libraries/CGAL/4.nix
Normal file
46
pkgs/development/libraries/CGAL/4.nix
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
{ lib, stdenv, fetchFromGitHub, fetchpatch, cmake, boost, gmp, mpfr }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "4.14.2";
|
||||
pname = "cgal";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "CGAL";
|
||||
repo = "releases";
|
||||
rev = "CGAL-${version}";
|
||||
sha256 = "1p1xyws2s9h2c8hlkz1af4ix48qma160av24by6lcm8al1g44pca";
|
||||
};
|
||||
|
||||
patches = [
|
||||
|
||||
# Pull upstream fix for c++17 (gcc-12):
|
||||
# https://github.com/CGAL/cgal/pull/6109
|
||||
(fetchpatch {
|
||||
name = "gcc-12-prereq.patch";
|
||||
url = "https://github.com/CGAL/cgal/commit/4581f1b7a8e97d1a136830e64b77cdae3546c4bf.patch";
|
||||
relative = "CGAL_Core"; # Upstream slightly reordered directory structure since.
|
||||
sha256 = "sha256-4+7mzGSBwAv5RHBQPAecPPKNN/LQBgvYq5mq+fHAteo=";
|
||||
})
|
||||
(fetchpatch {
|
||||
name = "gcc-12.patch";
|
||||
url = "https://github.com/CGAL/cgal/commit/6680a6e6f994b2c5b9f068eb3014d12ee1134d53.patch";
|
||||
relative = "CGAL_Core"; # Upstream slightly reordered directory structure since.
|
||||
sha256 = "sha256-8kxJDT47jXI9kQNFI/ARWl9JBNS4AfU57/D0tYlgW0M=";
|
||||
})
|
||||
];
|
||||
|
||||
# note: optional component libCGAL_ImageIO would need zlib and opengl;
|
||||
# there are also libCGAL_Qt{3,4} omitted ATM
|
||||
buildInputs = [ boost gmp mpfr ];
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
doCheck = false;
|
||||
|
||||
meta = with lib; {
|
||||
description = "Computational Geometry Algorithms Library";
|
||||
homepage = "http://cgal.org";
|
||||
license = with licenses; [ gpl3Plus lgpl3Plus];
|
||||
platforms = platforms.all;
|
||||
maintainers = [ maintainers.raskin ];
|
||||
};
|
||||
}
|
||||
15
pkgs/development/libraries/CGAL/cgal_path.patch
Normal file
15
pkgs/development/libraries/CGAL/cgal_path.patch
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
--- Installation/cmake/modules/CGALConfig_install.cmake.in.original 2019-07-10 10:39:12.377022659 -0700
|
||||
+++ Installation/cmake/modules/CGALConfig_install.cmake.in 2019-07-10 10:47:24.310154928 -0700
|
||||
@@ -45,9 +45,9 @@
|
||||
set(CGAL_SHARED_LINKER_FLAGS_DEBUG_INIT "@CMAKE_SHARED_LINKER_FLAGS_DEBUG@" )
|
||||
set(CGAL_BUILD_TYPE_INIT "@CMAKE_BUILD_TYPE@" )
|
||||
|
||||
-set(CGAL_INCLUDE_DIRS "${CGAL_INSTALL_PREFIX}/@CGAL_INSTALL_INC_DIR@" )
|
||||
-set(CGAL_MODULES_DIR "${CGAL_INSTALL_PREFIX}/@CGAL_INSTALL_CMAKE_DIR@" )
|
||||
-set(CGAL_LIBRARIES_DIR "${CGAL_INSTALL_PREFIX}/@CGAL_INSTALL_LIB_DIR@" )
|
||||
+set(CGAL_INCLUDE_DIRS "@CGAL_INSTALL_INC_DIR@" )
|
||||
+set(CGAL_MODULES_DIR "@CGAL_INSTALL_CMAKE_DIR@" )
|
||||
+set(CGAL_LIBRARIES_DIR "@CGAL_INSTALL_LIB_DIR@" )
|
||||
|
||||
# If CGAL_ImageIO is built, tell if it was linked with Zlib.
|
||||
set(CGAL_ImageIO_USE_ZLIB "@CGAL_ImageIO_USE_ZLIB@" )
|
||||
36
pkgs/development/libraries/CGAL/default.nix
Normal file
36
pkgs/development/libraries/CGAL/default.nix
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
{ lib, stdenv
|
||||
, fetchFromGitHub
|
||||
, cmake
|
||||
, boost
|
||||
, gmp
|
||||
, mpfr
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "cgal";
|
||||
version = "5.4";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "CGAL";
|
||||
repo = "releases";
|
||||
rev = "CGAL-${version}";
|
||||
sha256 = "sha256-flrVWsvGAdGVCZ1Ygy9z30w6aU8WAzpMLv+JbP2CKjE=";
|
||||
};
|
||||
|
||||
# note: optional component libCGAL_ImageIO would need zlib and opengl;
|
||||
# there are also libCGAL_Qt{3,4} omitted ATM
|
||||
buildInputs = [ boost gmp mpfr ];
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
patches = [ ./cgal_path.patch ];
|
||||
|
||||
doCheck = false;
|
||||
|
||||
meta = with lib; {
|
||||
description = "Computational Geometry Algorithms Library";
|
||||
homepage = "http://cgal.org";
|
||||
license = with licenses; [ gpl3Plus lgpl3Plus];
|
||||
platforms = platforms.all;
|
||||
maintainers = [ maintainers.raskin ];
|
||||
};
|
||||
}
|
||||
22
pkgs/development/libraries/CoinMP/default.nix
Normal file
22
pkgs/development/libraries/CoinMP/default.nix
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
{ lib, stdenv, fetchurl }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "CoinMP";
|
||||
version = "1.8.4";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.coin-or.org/download/source/CoinMP/${pname}-${version}.tgz";
|
||||
sha256 = "13d3j1sdcjzpijp4qks3n0zibk649ac3hhv88hkk8ffxrc6gnn9l";
|
||||
};
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
hardeningDisable = [ "format" ];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://projects.coin-or.org/CoinMP/";
|
||||
description = "COIN-OR lightweight API for COIN-OR libraries CLP, CBC, and CGL";
|
||||
platforms = platforms.unix;
|
||||
license = licenses.epl10;
|
||||
};
|
||||
}
|
||||
33
pkgs/development/libraries/LAStools/default.nix
Normal file
33
pkgs/development/libraries/LAStools/default.nix
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "LAStools";
|
||||
version = "2.0.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "LAStools";
|
||||
repo = "LAStools";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-Mxic/zLk/qkB/rSlvkLZPgtNscrTrzSzrxiqXAMeDVU=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
./drop-64-suffix.patch # necessary to prevent '64' from being appended to the names of the executables
|
||||
];
|
||||
|
||||
hardeningDisable = [
|
||||
"format"
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Software for rapid LiDAR processing";
|
||||
homepage = "http://lastools.org/";
|
||||
license = licenses.unfree;
|
||||
maintainers = with maintainers; [ stephenwithph ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
13
pkgs/development/libraries/LAStools/drop-64-suffix.patch
Normal file
13
pkgs/development/libraries/LAStools/drop-64-suffix.patch
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
--- a/src/CMakeLists.txt
|
||||
+++ b/src/CMakeLists.txt
|
||||
@@ -32,6 +32,6 @@ endforeach(TARGET)
|
||||
foreach(TARGET ${ALL_TARGETS})
|
||||
target_link_libraries(${TARGET} LASlib)
|
||||
set_target_properties(${TARGET} PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/../bin64)
|
||||
- set_target_properties(${TARGET} PROPERTIES OUTPUT_NAME ${TARGET}64)
|
||||
+ set_target_properties(${TARGET} PROPERTIES OUTPUT_NAME ${TARGET})
|
||||
install(TARGETS ${TARGET} RUNTIME DESTINATION bin)
|
||||
endforeach(TARGET)
|
||||
--
|
||||
2.28.0
|
||||
|
||||
23
pkgs/development/libraries/LASzip/LASzip2.nix
Normal file
23
pkgs/development/libraries/LASzip/LASzip2.nix
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "2.2.0";
|
||||
pname = "LASzip";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "LASzip";
|
||||
repo = "LASzip";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-TXzse4oLjNX5R2xDR721iV+gW/rP5z3Zciv4OgxfeqA=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Turn quickly bulky LAS files into compact LAZ files without information loss";
|
||||
homepage = "https://laszip.org";
|
||||
license = licenses.lgpl2;
|
||||
maintainers = [ maintainers.michelk ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
25
pkgs/development/libraries/LASzip/default.nix
Normal file
25
pkgs/development/libraries/LASzip/default.nix
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "3.4.3";
|
||||
pname = "LASzip";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "LASzip";
|
||||
repo = "LASzip";
|
||||
rev = version;
|
||||
sha256 = "09lcsgxwv0jq50fhsgfhx0npbf1zcwn3hbnq6q78fshqksbxmz7m";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
];
|
||||
|
||||
meta = {
|
||||
description = "Turn quickly bulky LAS files into compact LAZ files without information loss";
|
||||
homepage = "https://laszip.org";
|
||||
license = lib.licenses.lgpl2;
|
||||
maintainers = [ lib.maintainers.michelk ];
|
||||
platforms = lib.platforms.unix;
|
||||
};
|
||||
}
|
||||
22
pkgs/development/libraries/NSPlist/default.nix
Normal file
22
pkgs/development/libraries/NSPlist/default.nix
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
pname = "NSPlist";
|
||||
version = "unstable-2017-04-11";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "matthewbauer";
|
||||
repo = "NSPlist";
|
||||
rev = "713decf06c1ef6c39a707bc99eb45ac9925f2b8a";
|
||||
sha256 = "0v4yfiwfd08hmh2ydgy6pnmlzjbd96k78dsla9pfd56ka89aw74r";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
meta = with lib; {
|
||||
maintainers = with maintainers; [ matthewbauer ];
|
||||
description = "Parses .plist files";
|
||||
license = licenses.mit;
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
23
pkgs/development/libraries/PlistCpp/default.nix
Normal file
23
pkgs/development/libraries/PlistCpp/default.nix
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake, boost, NSPlist, pugixml }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
pname = "PlistCpp";
|
||||
version = "unstable-11615d";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "matthewbauer";
|
||||
repo = "PlistCpp";
|
||||
rev = "11615deab3369356a182dabbf5bae30574967264";
|
||||
sha256 = "10jn6bvm9vn6492zix2pd724v5h4lccmkqg3lxfw8r0qg3av0yzv";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
buildInputs = [ boost NSPlist pugixml ];
|
||||
|
||||
meta = with lib; {
|
||||
maintainers = with maintainers; [ matthewbauer ];
|
||||
description = "CPP bindings for Plist";
|
||||
license = licenses.mit;
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
135
pkgs/development/libraries/SDL/default.nix
Normal file
135
pkgs/development/libraries/SDL/default.nix
Normal file
|
|
@ -0,0 +1,135 @@
|
|||
{ lib, stdenv, config, fetchurl, fetchpatch, pkg-config, audiofile, libcap, libiconv
|
||||
, libGLSupported ? lib.elem stdenv.hostPlatform.system lib.platforms.mesaPlatforms
|
||||
, openglSupport ? libGLSupported, libGL, libGLU
|
||||
, alsaSupport ? stdenv.isLinux && !stdenv.hostPlatform.isAndroid, alsa-lib
|
||||
, x11Support ? !stdenv.isCygwin && !stdenv.hostPlatform.isAndroid
|
||||
, libXext, libICE, libXrandr
|
||||
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux && !stdenv.hostPlatform.isAndroid, libpulseaudio
|
||||
, OpenGL, GLUT, CoreAudio, CoreServices, AudioUnit, Kernel, Cocoa
|
||||
}:
|
||||
|
||||
# NOTE: When editing this expression see if the same change applies to
|
||||
# SDL2 expression too
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
extraPropagatedBuildInputs = [ ]
|
||||
++ optionals x11Support [ libXext libICE libXrandr ]
|
||||
++ optionals (openglSupport && stdenv.isLinux) [ libGL libGLU ]
|
||||
++ optionals (openglSupport && stdenv.isDarwin) [ OpenGL GLUT ]
|
||||
++ optional alsaSupport alsa-lib
|
||||
++ optional pulseaudioSupport libpulseaudio
|
||||
++ optional stdenv.isDarwin Cocoa;
|
||||
rpath = makeLibraryPath extraPropagatedBuildInputs;
|
||||
in
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL";
|
||||
version = "1.2.15";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.libsdl.org/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "005d993xcac8236fpvd1iawkz4wqjybkpn8dbwaliqz5jfkidlyn";
|
||||
};
|
||||
|
||||
# make: *** No rule to make target 'build/*.lo', needed by 'build/libSDL.la'. Stop.
|
||||
postPatch = "patchShebangs ./configure";
|
||||
|
||||
outputs = [ "out" "dev" ];
|
||||
outputBin = "dev"; # sdl-config
|
||||
|
||||
nativeBuildInputs = [ pkg-config ]
|
||||
++ optional stdenv.isLinux libcap;
|
||||
|
||||
propagatedBuildInputs = [ libiconv ] ++ extraPropagatedBuildInputs;
|
||||
|
||||
buildInputs = [ ]
|
||||
++ optional (!stdenv.hostPlatform.isMinGW && alsaSupport) audiofile
|
||||
++ optionals stdenv.isDarwin [ AudioUnit CoreAudio CoreServices Kernel OpenGL ];
|
||||
|
||||
configureFlags = [
|
||||
"--disable-oss"
|
||||
"--disable-video-x11-xme"
|
||||
"--enable-rpath"
|
||||
# Building without this fails on Darwin with
|
||||
#
|
||||
# ./src/video/x11/SDL_x11sym.h:168:17: error: conflicting types for '_XData32'
|
||||
# SDL_X11_SYM(int,_XData32,(Display *dpy,register long *data,unsigned len),(dpy,data,len),return)
|
||||
#
|
||||
# Please try revert the change that introduced this comment when updating SDL.
|
||||
] ++ optional stdenv.isDarwin "--disable-x11-shared"
|
||||
++ optional (!x11Support) "--without-x"
|
||||
++ optional alsaSupport "--with-alsa-prefix=${alsa-lib.out}/lib";
|
||||
|
||||
patches = [
|
||||
./find-headers.patch
|
||||
|
||||
# Fix window resizing issues, e.g. for xmonad
|
||||
# Ticket: http://bugzilla.libsdl.org/show_bug.cgi?id=1430
|
||||
(fetchpatch {
|
||||
name = "fix_window_resizing.diff";
|
||||
url = "https://bugs.debian.org/cgi-bin/bugreport.cgi?msg=10;filename=fix_window_resizing.diff;att=2;bug=665779";
|
||||
sha256 = "1z35azc73vvi19pzi6byck31132a8w1vzrghp1x3hy4a4f9z4gc6";
|
||||
})
|
||||
# Fix drops of keyboard events for SDL_EnableUNICODE
|
||||
(fetchpatch {
|
||||
url = "https://github.com/libsdl-org/SDL-1.2/commit/0332e2bb18dc68d6892c3b653b2547afe323854b.patch";
|
||||
sha256 = "0g458iv6pp9sikdch6ms8svz60lf5ks2q5wgid8s9rydhk98lpp5";
|
||||
})
|
||||
# Ignore insane joystick axis events
|
||||
(fetchpatch {
|
||||
url = "https://github.com/libsdl-org/SDL-1.2/commit/ab99cc82b0a898ad528d46fa128b649a220a94f4.patch";
|
||||
sha256 = "1b3473sawfdbkkxaqf1hg0vn37yk8hf655jhnjwdk296z4gclazh";
|
||||
})
|
||||
# https://bugzilla.libsdl.org/show_bug.cgi?id=1769
|
||||
(fetchpatch {
|
||||
url = "https://github.com/libsdl-org/SDL-1.2/commit/5d79977ec7a6b58afa6e4817035aaaba186f7e9f.patch";
|
||||
sha256 = "1k7y57b1zy5afib1g7w3in36n8cswbcrzdbrjpn5cb105rnb9vmp";
|
||||
})
|
||||
# Workaround X11 bug to allow changing gamma
|
||||
# Ticket: https://bugs.freedesktop.org/show_bug.cgi?id=27222
|
||||
(fetchpatch {
|
||||
name = "SDL_SetGamma.patch";
|
||||
url = "https://src.fedoraproject.org/cgit/rpms/SDL.git/plain/SDL-1.2.15-x11-Bypass-SetGammaRamp-when-changing-gamma.patch?id=04a3a7b1bd88c2d5502292fad27e0e02d084698d";
|
||||
sha256 = "0x52s4328kilyq43i7psqkqg7chsfwh0aawr50j566nzd7j51dlv";
|
||||
})
|
||||
# Fix a build failure on OS X Mavericks
|
||||
# Ticket: https://bugzilla.libsdl.org/show_bug.cgi?id=2085
|
||||
(fetchpatch {
|
||||
url = "https://github.com/libsdl-org/SDL-1.2/commit/19039324be71738d8990e91b9ba341b2ea068445.patch";
|
||||
sha256 = "0ckwling2ad27c9vxgp97ndjd098d6zbrydza8b9l77k8airj98c";
|
||||
})
|
||||
(fetchpatch {
|
||||
url = "https://github.com/libsdl-org/SDL-1.2/commit/7933032ad4d57c24f2230db29f67eb7d21bb5654.patch";
|
||||
sha256 = "1by16firaxyr0hjvn35whsgcmq6bl0nwhnpjf75grjzsw9qvwyia";
|
||||
})
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
moveToOutput share/aclocal "$dev"
|
||||
'';
|
||||
|
||||
# See the same place in the expression for SDL2
|
||||
postFixup = ''
|
||||
for lib in $out/lib/*.so* ; do
|
||||
if [[ -L "$lib" ]]; then
|
||||
patchelf --set-rpath "$(patchelf --print-rpath $lib):${rpath}" "$lib"
|
||||
fi
|
||||
done
|
||||
'';
|
||||
|
||||
setupHook = ./setup-hook.sh;
|
||||
|
||||
passthru = { inherit openglSupport; };
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
meta = with lib; {
|
||||
description = "A cross-platform multimedia library";
|
||||
homepage = "http://www.libsdl.org/";
|
||||
maintainers = with maintainers; [ lovek323 ];
|
||||
platforms = platforms.unix;
|
||||
license = licenses.lgpl21;
|
||||
};
|
||||
}
|
||||
26
pkgs/development/libraries/SDL/find-headers.patch
Normal file
26
pkgs/development/libraries/SDL/find-headers.patch
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
diff --git a/sdl-config.in b/sdl-config.in
|
||||
index e0fcc0c..bf7928a 100644
|
||||
--- a/sdl-config.in
|
||||
+++ b/sdl-config.in
|
||||
@@ -42,14 +42,18 @@ while test $# -gt 0; do
|
||||
echo @SDL_VERSION@
|
||||
;;
|
||||
--cflags)
|
||||
- echo -I@includedir@/SDL @SDL_CFLAGS@
|
||||
+ SDL_CFLAGS=""
|
||||
+ for i in @includedir@/SDL $SDL_PATH; do
|
||||
+ SDL_CFLAGS="$SDL_CFLAGS -I$i"
|
||||
+ done
|
||||
+ echo $SDL_CFLAGS @SDL_CFLAGS@
|
||||
;;
|
||||
@ENABLE_SHARED_TRUE@ --libs)
|
||||
-@ENABLE_SHARED_TRUE@ echo -L@libdir@ @SDL_RLD_FLAGS@ @SDL_LIBS@
|
||||
+@ENABLE_SHARED_TRUE@ echo -L@libdir@ @SDL_RLD_FLAGS@ @SDL_LIBS@ $SDL_LIB_PATH
|
||||
@ENABLE_SHARED_TRUE@ ;;
|
||||
@ENABLE_STATIC_TRUE@@ENABLE_SHARED_TRUE@ --static-libs)
|
||||
@ENABLE_STATIC_TRUE@@ENABLE_SHARED_FALSE@ --libs|--static-libs)
|
||||
-@ENABLE_STATIC_TRUE@ echo -L@libdir@ @SDL_RLD_FLAGS@ @SDL_STATIC_LIBS@
|
||||
+@ENABLE_STATIC_TRUE@ echo -L@libdir@ @SDL_RLD_FLAGS@ @SDL_STATIC_LIBS@ $SDL_LIB_PATH
|
||||
@ENABLE_STATIC_TRUE@ ;;
|
||||
*)
|
||||
echo "${usage}" 1>&2
|
||||
10
pkgs/development/libraries/SDL/setup-hook.sh
Normal file
10
pkgs/development/libraries/SDL/setup-hook.sh
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
addSDLPath () {
|
||||
if [ -e "$1/include/SDL" ]; then
|
||||
export SDL_PATH="${SDL_PATH-}${SDL_PATH:+ }$1/include/SDL"
|
||||
fi
|
||||
if [ -e "$1/lib" ]; then
|
||||
export SDL_LIB_PATH="${SDL_LIB_PATH-}${SDL_LIB_PATH:+ }-L$1/lib"
|
||||
fi
|
||||
}
|
||||
|
||||
addEnvHooks "$hostOffset" addSDLPath
|
||||
180
pkgs/development/libraries/SDL2/default.nix
Normal file
180
pkgs/development/libraries/SDL2/default.nix
Normal file
|
|
@ -0,0 +1,180 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, config
|
||||
, fetchurl
|
||||
, pkg-config
|
||||
, libGLSupported ? lib.elem stdenv.hostPlatform.system lib.platforms.mesaPlatforms
|
||||
, openglSupport ? libGLSupported
|
||||
, libGL
|
||||
, alsaSupport ? stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
||||
, alsa-lib
|
||||
, x11Support ? !stdenv.targetPlatform.isWindows && !stdenv.hostPlatform.isAndroid
|
||||
, libX11
|
||||
, xorgproto
|
||||
, libICE
|
||||
, libXi
|
||||
, libXScrnSaver
|
||||
, libXcursor
|
||||
, libXinerama
|
||||
, libXext
|
||||
, libXxf86vm
|
||||
, libXrandr
|
||||
, waylandSupport ? stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
||||
, wayland
|
||||
, wayland-protocols
|
||||
, wayland-scanner
|
||||
, drmSupport ? stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
||||
, libdrm
|
||||
, mesa
|
||||
, libxkbcommon
|
||||
, dbusSupport ? stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
||||
, dbus
|
||||
, udevSupport ? false
|
||||
, udev
|
||||
, ibusSupport ? false
|
||||
, ibus
|
||||
, fcitxSupport ? false
|
||||
, fcitx
|
||||
, libdecorSupport ? stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
||||
, libdecor
|
||||
, pipewireSupport ? stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
||||
, pipewire # NOTE: must be built with SDL2 without pipewire support
|
||||
, pulseaudioSupport ? config.pulseaudio or stdenv.isLinux && !stdenv.hostPlatform.isAndroid
|
||||
, libpulseaudio
|
||||
, AudioUnit
|
||||
, Cocoa
|
||||
, CoreAudio
|
||||
, CoreServices
|
||||
, ForceFeedback
|
||||
, OpenGL
|
||||
, audiofile
|
||||
, libiconv
|
||||
, withStatic ? false
|
||||
}:
|
||||
|
||||
# NOTE: When editing this expression see if the same change applies to
|
||||
# SDL expression too
|
||||
|
||||
with lib;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL2";
|
||||
version = "2.0.22";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.libsdl.org/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "sha256-/ny/MSeILj/HJZp1oMtYViAnLFF0XThSq53YeWBpfy4=";
|
||||
};
|
||||
dontDisableStatic = withStatic;
|
||||
outputs = [ "out" "dev" ];
|
||||
outputBin = "dev"; # sdl-config
|
||||
|
||||
patches = [
|
||||
# `sdl2-config --cflags` from Nixpkgs returns include path to just SDL2.
|
||||
# On a normal distro this is enough for includes from all SDL2* packages to work,
|
||||
# but on NixOS they're spread across different paths.
|
||||
# This patch + the setup-hook will ensure that `sdl2-config --cflags` works correctly.
|
||||
./find-headers.patch
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
# Fix running wayland-scanner for the build platform when cross-compiling.
|
||||
# See comment here: https://github.com/libsdl-org/SDL/issues/4860#issuecomment-1119003545
|
||||
substituteInPlace configure \
|
||||
--replace '$(WAYLAND_SCANNER)' 'wayland-scanner'
|
||||
'';
|
||||
|
||||
strictDeps = true;
|
||||
|
||||
depsBuildBuild = [ pkg-config ];
|
||||
|
||||
nativeBuildInputs = [ pkg-config ] ++ optionals waylandSupport [ wayland wayland-scanner ];
|
||||
|
||||
propagatedBuildInputs = dlopenPropagatedBuildInputs;
|
||||
|
||||
dlopenPropagatedBuildInputs = [ ]
|
||||
# Propagated for #include <GLES/gl.h> in SDL_opengles.h.
|
||||
++ optional openglSupport libGL
|
||||
# Propagated for #include <X11/Xlib.h> and <X11/Xatom.h> in SDL_syswm.h.
|
||||
++ optionals x11Support [ libX11 xorgproto ];
|
||||
|
||||
dlopenBuildInputs = optionals alsaSupport [ alsa-lib audiofile ]
|
||||
++ optional dbusSupport dbus
|
||||
++ optional libdecorSupport libdecor
|
||||
++ optional pipewireSupport pipewire
|
||||
++ optional pulseaudioSupport libpulseaudio
|
||||
++ optional udevSupport udev
|
||||
++ optionals waylandSupport [ wayland wayland-protocols libxkbcommon ]
|
||||
++ optionals x11Support [ libICE libXi libXScrnSaver libXcursor libXinerama libXext libXrandr libXxf86vm ]
|
||||
++ optionals drmSupport [ libdrm mesa ];
|
||||
|
||||
buildInputs = [ libiconv ]
|
||||
++ dlopenBuildInputs
|
||||
++ optional ibusSupport ibus
|
||||
++ optional fcitxSupport fcitx
|
||||
++ optionals stdenv.isDarwin [ AudioUnit Cocoa CoreAudio CoreServices ForceFeedback OpenGL ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
configureFlags = [
|
||||
"--disable-oss"
|
||||
] ++ optional (!x11Support) "--without-x"
|
||||
++ optional alsaSupport "--with-alsa-prefix=${alsa-lib.out}/lib"
|
||||
++ optional stdenv.targetPlatform.isWindows "--disable-video-opengles"
|
||||
++ optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
# We remove libtool .la files when static libs are requested,
|
||||
# because they make the builds of downstream libs like `SDL_tff`
|
||||
# fail with `cannot find -lXext, `-lXcursor` etc. linker errors
|
||||
# because the `.la` files are not pruned if static libs exist
|
||||
# (see https://github.com/NixOS/nixpkgs/commit/fd97db43bcb05e37f6bb77f363f1e1e239d9de53)
|
||||
# and they also don't carry the necessary `-L` paths of their
|
||||
# X11 dependencies.
|
||||
# For static linking, it is better to rely on `pkg-config` `.pc`
|
||||
# files.
|
||||
postInstall = ''
|
||||
if [ "$dontDisableStatic" -eq "1" ]; then
|
||||
rm $out/lib/*.la
|
||||
else
|
||||
rm $out/lib/*.a
|
||||
fi
|
||||
moveToOutput bin/sdl2-config "$dev"
|
||||
'';
|
||||
|
||||
# SDL is weird in that instead of just dynamically linking with
|
||||
# libraries when you `--enable-*` (or when `configure` finds) them
|
||||
# it `dlopen`s them at runtime. In principle, this means it can
|
||||
# ignore any missing optional dependencies like alsa, pulseaudio,
|
||||
# some x11 libs, wayland, etc if they are missing on the system
|
||||
# and/or work with wide array of versions of said libraries. In
|
||||
# nixpkgs, however, we don't need any of that. Moreover, since we
|
||||
# don't have a global ld-cache we have to stuff all the propagated
|
||||
# libraries into rpath by hand or else some applications that use
|
||||
# SDL API that requires said libraries will fail to start.
|
||||
#
|
||||
# You can grep SDL sources with `grep -rE 'SDL_(NAME|.*_SYM)'` to
|
||||
# list the symbols used in this way.
|
||||
postFixup =
|
||||
let
|
||||
rpath = makeLibraryPath (dlopenPropagatedBuildInputs ++ dlopenBuildInputs);
|
||||
in
|
||||
optionalString (stdenv.hostPlatform.extensions.sharedLibrary == ".so") ''
|
||||
for lib in $out/lib/*.so* ; do
|
||||
if ! [[ -L "$lib" ]]; then
|
||||
patchelf --set-rpath "$(patchelf --print-rpath $lib):${rpath}" "$lib"
|
||||
fi
|
||||
done
|
||||
'';
|
||||
|
||||
setupHook = ./setup-hook.sh;
|
||||
|
||||
passthru = { inherit openglSupport; };
|
||||
|
||||
meta = with lib; {
|
||||
description = "A cross-platform multimedia library";
|
||||
homepage = "http://www.libsdl.org/";
|
||||
license = licenses.zlib;
|
||||
platforms = platforms.all;
|
||||
maintainers = with maintainers; [ cpages ];
|
||||
};
|
||||
}
|
||||
34
pkgs/development/libraries/SDL2/find-headers.patch
Normal file
34
pkgs/development/libraries/SDL2/find-headers.patch
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
diff --git a/sdl2-config.cmake.in b/sdl2-config.cmake.in
|
||||
index c570511fa..ca694f595 100644
|
||||
--- a/sdl2-config.cmake.in
|
||||
+++ b/sdl2-config.cmake.in
|
||||
@@ -7,7 +7,8 @@ set(includedir "@includedir@")
|
||||
set(SDL2_PREFIX "${prefix}")
|
||||
set(SDL2_EXEC_PREFIX "${exec_prefix}")
|
||||
set(SDL2_LIBDIR "${libdir}")
|
||||
-set(SDL2_INCLUDE_DIRS "${includedir}/SDL2")
|
||||
+set(SDL2_INCLUDE_DIRS "${includedir}/SDL2" $ENV{SDL2_PATH})
|
||||
+separate_arguments(SDL2_INCLUDE_DIRS)
|
||||
set(SDL2_LIBRARIES "-L${SDL2_LIBDIR} @SDL_RLD_FLAGS@ @SDL_LIBS@")
|
||||
string(STRIP "${SDL2_LIBRARIES}" SDL2_LIBRARIES)
|
||||
|
||||
diff --git a/sdl2-config.in b/sdl2-config.in
|
||||
index 5a2aed292..7c55f0a28 100644
|
||||
--- a/sdl2-config.in
|
||||
+++ b/sdl2-config.in
|
||||
@@ -42,7 +42,11 @@ while test $# -gt 0; do
|
||||
echo @SDL_VERSION@
|
||||
;;
|
||||
--cflags)
|
||||
- echo -I@includedir@/SDL2 @SDL_CFLAGS@
|
||||
+ SDL_CFLAGS=""
|
||||
+ for i in @includedir@/SDL2 $SDL2_PATH; do
|
||||
+ SDL_CFLAGS="$SDL_CFLAGS -I$i"
|
||||
+ done
|
||||
+ echo $SDL_CFLAGS @SDL_CFLAGS@
|
||||
;;
|
||||
@ENABLE_SHARED_TRUE@ --libs)
|
||||
@ENABLE_SHARED_TRUE@ echo -L@libdir@ @SDL_RLD_FLAGS@ @SDL_LIBS@
|
||||
--
|
||||
2.33.1
|
||||
|
||||
7
pkgs/development/libraries/SDL2/setup-hook.sh
Normal file
7
pkgs/development/libraries/SDL2/setup-hook.sh
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
addSDL2Path () {
|
||||
if [ -e "$1/include/SDL2" ]; then
|
||||
export SDL2_PATH="${SDL2_PATH-}${SDL2_PATH:+ }$1/include/SDL2"
|
||||
fi
|
||||
}
|
||||
|
||||
addEnvHooks "$hostOffset" addSDL2Path
|
||||
46
pkgs/development/libraries/SDL2_gfx/default.nix
Normal file
46
pkgs/development/libraries/SDL2_gfx/default.nix
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
{ lib, stdenv, darwin, fetchurl, pkg-config, SDL2 }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL2_gfx";
|
||||
version = "1.0.4";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://www.ferzkopp.net/Software/${pname}/${pname}-${version}.tar.gz";
|
||||
sha256 = "0qk2ax7f7grlxb13ba0ll3zlm8780s7j8fmrhlpxzjgdvldf1q33";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
|
||||
buildInputs = [ SDL2 ]
|
||||
++ lib.optional stdenv.isDarwin darwin.libobjc;
|
||||
|
||||
configureFlags = [(if stdenv.hostPlatform.isx86 then "--enable-mmx" else "--disable-mmx")]
|
||||
++ lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL graphics drawing primitives and support functions";
|
||||
|
||||
longDescription = ''
|
||||
The SDL_gfx library evolved out of the SDL_gfxPrimitives code
|
||||
which provided basic drawing routines such as lines, circles or
|
||||
polygons and SDL_rotozoom which implemented a interpolating
|
||||
rotozoomer for SDL surfaces.
|
||||
|
||||
The current components of the SDL_gfx library are:
|
||||
|
||||
* Graphic Primitives (SDL_gfxPrimitves.h)
|
||||
* Rotozoomer (SDL_rotozoom.h)
|
||||
* Framerate control (SDL_framerate.h)
|
||||
* MMX image filters (SDL_imageFilter.h)
|
||||
* Custom Blit functions (SDL_gfxBlitFunc.h)
|
||||
|
||||
The library is backwards compatible to the above mentioned
|
||||
code. Its is written in plain C and can be used in C++ code.
|
||||
'';
|
||||
|
||||
homepage = "http://www.ferzkopp.net/wordpress/2016/01/02/sdl_gfx-sdl2_gfx/";
|
||||
license = licenses.zlib;
|
||||
maintainers = with maintainers; [ cpages ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
42
pkgs/development/libraries/SDL2_image/default.nix
Normal file
42
pkgs/development/libraries/SDL2_image/default.nix
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
{ lib, stdenv, fetchurl
|
||||
, pkg-config
|
||||
, SDL2, libpng, libjpeg, libtiff, giflib, libwebp, libXpm, zlib, Foundation
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL2_image";
|
||||
version = "2.0.5";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.libsdl.org/projects/SDL_image/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "1l0864kas9cwpp2d32yxl81g98lx40dhbdp03dz7sbv84vhgdmdx";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
|
||||
buildInputs = [ SDL2 libpng libjpeg libtiff giflib libwebp libXpm zlib ]
|
||||
++ lib.optional stdenv.isDarwin Foundation;
|
||||
|
||||
configureFlags = [
|
||||
# Disable dynamically loaded dependencies
|
||||
"--disable-jpg-shared"
|
||||
"--disable-png-shared"
|
||||
"--disable-tif-shared"
|
||||
"--disable-webp-shared"
|
||||
] ++ lib.optionals stdenv.isDarwin [
|
||||
# Darwin headless will hang when trying to run the SDL test program
|
||||
"--disable-sdltest"
|
||||
# Don't use native macOS frameworks
|
||||
"--disable-imageio"
|
||||
];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL image library";
|
||||
homepage = "http://www.libsdl.org/projects/SDL_image/";
|
||||
platforms = platforms.unix;
|
||||
license = licenses.zlib;
|
||||
maintainers = with maintainers; [ cpages ];
|
||||
};
|
||||
}
|
||||
75
pkgs/development/libraries/SDL2_mixer/default.nix
Normal file
75
pkgs/development/libraries/SDL2_mixer/default.nix
Normal file
|
|
@ -0,0 +1,75 @@
|
|||
{ lib, stdenv
|
||||
, fetchurl
|
||||
, pkg-config
|
||||
, AudioToolbox
|
||||
, AudioUnit
|
||||
, CoreServices
|
||||
, SDL2
|
||||
, flac
|
||||
, fluidsynth
|
||||
, libmodplug
|
||||
, libogg
|
||||
, libvorbis
|
||||
, mpg123
|
||||
, opusfile
|
||||
, smpeg2
|
||||
, timidity
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL2_mixer";
|
||||
version = "2.0.4";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.libsdl.org/projects/SDL_mixer/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "0694vsz5bjkcdgfdra6x9fq8vpzrl8m6q96gh58df7065hw5mkxl";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
|
||||
buildInputs = lib.optionals stdenv.isDarwin [
|
||||
AudioToolbox
|
||||
AudioUnit
|
||||
CoreServices
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
SDL2
|
||||
flac
|
||||
fluidsynth
|
||||
libmodplug
|
||||
libogg
|
||||
libvorbis
|
||||
mpg123
|
||||
opusfile
|
||||
smpeg2
|
||||
# MIDI patterns
|
||||
timidity
|
||||
];
|
||||
|
||||
# fix default path to timidity.cfg so MIDI files could be played
|
||||
postPatch = ''
|
||||
substituteInPlace timidity/options.h \
|
||||
--replace "/usr/share/timidity" "${timidity}/share/timidity"
|
||||
'';
|
||||
|
||||
configureFlags = [
|
||||
"--disable-music-ogg-shared"
|
||||
"--disable-music-flac-shared"
|
||||
"--disable-music-mod-modplug-shared"
|
||||
"--disable-music-mp3-mpg123-shared"
|
||||
"--disable-music-opus-shared"
|
||||
"--disable-music-midi-fluidsynth-shared"
|
||||
] ++ lib.optionals stdenv.isDarwin [
|
||||
"--disable-sdltest"
|
||||
"--disable-smpegtest"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL multi-channel audio mixer library";
|
||||
platforms = platforms.unix;
|
||||
homepage = "https://www.libsdl.org/projects/SDL_mixer/";
|
||||
maintainers = with maintainers; [ MP2E ];
|
||||
license = licenses.zlib;
|
||||
};
|
||||
}
|
||||
27
pkgs/development/libraries/SDL2_net/default.nix
Normal file
27
pkgs/development/libraries/SDL2_net/default.nix
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
{ lib, stdenv, pkg-config, darwin, fetchurl, SDL2 }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL2_net";
|
||||
version = "2.0.1";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.libsdl.org/projects/SDL_net/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "08cxc1bicmyk89kiks7izw1rlx5ng5n6xpy8fy0zxni3b9z8mkhm";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
|
||||
buildInputs = lib.optional stdenv.isDarwin darwin.libobjc;
|
||||
|
||||
configureFlags = lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
propagatedBuildInputs = [ SDL2 ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL multiplatform networking library";
|
||||
homepage = "https://www.libsdl.org/projects/SDL_net";
|
||||
license = licenses.zlib;
|
||||
maintainers = with maintainers; [ MP2E ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
48
pkgs/development/libraries/SDL2_sound/default.nix
Normal file
48
pkgs/development/libraries/SDL2_sound/default.nix
Normal file
|
|
@ -0,0 +1,48 @@
|
|||
{ stdenv
|
||||
, lib
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
, SDL2
|
||||
, flac
|
||||
, libmikmod
|
||||
, libvorbis
|
||||
, timidity
|
||||
, AudioToolbox
|
||||
, CoreAudio
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL2_sound";
|
||||
version = "2.0.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "icculus";
|
||||
repo = "SDL_sound";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-N2znqy58tMHgYa07vEsSedWLRhoJzDoINcsUu0UYLnA=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
# https://github.com/icculus/SDL_sound/pull/32 - fix build on darwin
|
||||
# can be dropped on the next update
|
||||
url = "https://github.com/icculus/SDL_sound/commit/c15d75b7720113b28639baad284f45f943846294.patch";
|
||||
sha256 = "sha256-4GL8unsZ7eNkzjLXq9QdaxFQMzX2tdP0cBR1jTaRLc0=";
|
||||
})
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
cmakeFlags = [ "-DSDLSOUND_DECODER_MIDI=1" ];
|
||||
|
||||
buildInputs = [ SDL2 flac libmikmod libvorbis timidity ]
|
||||
++ lib.optionals stdenv.isDarwin [ AudioToolbox CoreAudio ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL2 sound library";
|
||||
platforms = platforms.unix;
|
||||
license = licenses.zlib;
|
||||
homepage = "https://www.icculus.org/SDL_sound/";
|
||||
};
|
||||
}
|
||||
25
pkgs/development/libraries/SDL2_ttf/2.0.15.nix
Normal file
25
pkgs/development/libraries/SDL2_ttf/2.0.15.nix
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
{ lib, stdenv, pkg-config, darwin, fetchurl, SDL2, freetype, libGL }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL2_ttf";
|
||||
version = "2.0.15";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.libsdl.org/projects/SDL_ttf/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "0cyd48dipc0m399qy8s03lci8b0bpiy8xlkvrm2ia7wcv0dfpv59";
|
||||
};
|
||||
|
||||
configureFlags = lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
|
||||
buildInputs = [ SDL2 freetype libGL ]
|
||||
++ lib.optional stdenv.isDarwin darwin.libobjc;
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL TrueType library";
|
||||
platforms = platforms.unix;
|
||||
license = licenses.zlib;
|
||||
homepage = "https://www.libsdl.org/projects/SDL_ttf/";
|
||||
};
|
||||
}
|
||||
25
pkgs/development/libraries/SDL2_ttf/default.nix
Normal file
25
pkgs/development/libraries/SDL2_ttf/default.nix
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
{ lib, stdenv, pkg-config, darwin, fetchurl, SDL2, freetype, libGL }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL2_ttf";
|
||||
version = "2.0.18";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.libsdl.org/projects/SDL_ttf/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "sha256-cjTriINRTgGed0fHA+SndFdbGNQ1wipKKdBoy3aKIlE=";
|
||||
};
|
||||
|
||||
configureFlags = lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
|
||||
buildInputs = [ SDL2 freetype libGL ]
|
||||
++ lib.optional stdenv.isDarwin darwin.libobjc;
|
||||
|
||||
meta = with lib; {
|
||||
description = "Support for TrueType (.ttf) font files with Simple Directmedia Layer";
|
||||
platforms = platforms.unix;
|
||||
license = licenses.zlib;
|
||||
homepage = "https://github.com/libsdl-org/SDL_ttf";
|
||||
};
|
||||
}
|
||||
33
pkgs/development/libraries/SDL_Pango/default.nix
Normal file
33
pkgs/development/libraries/SDL_Pango/default.nix
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
{ lib, stdenv, fetchpatch, fetchurl, SDL, autoreconfHook, pango, pkg-config }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL_Pango";
|
||||
version = "0.1.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/sdlpango/${pname}-${version}.tar.gz";
|
||||
sha256 = "197baw1dsg0p4pljs5k0fshbyki00r4l49m1drlpqw6ggawx6xbz";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
url = "https://sources.debian.org/data/main/s/sdlpango/0.1.2-6/debian/patches/api_additions.patch";
|
||||
sha256 = "00p5ry5gd3ixm257p9i2c4jg0qj8ipk8nf56l7c9fma8id3zxyld";
|
||||
})
|
||||
./fixes.patch
|
||||
];
|
||||
|
||||
preConfigure = "autoreconf -i -f";
|
||||
configureFlags = lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
nativeBuildInputs = [ pkg-config autoreconfHook ];
|
||||
buildInputs = [ SDL pango ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Connects the Pango rendering engine to SDL";
|
||||
license = licenses.lgpl21Plus;
|
||||
platforms = platforms.all;
|
||||
homepage = "http://sdlpango.sourceforge.net/";
|
||||
maintainers = with maintainers; [ puckipedia ];
|
||||
};
|
||||
}
|
||||
148
pkgs/development/libraries/SDL_Pango/fixes.patch
Normal file
148
pkgs/development/libraries/SDL_Pango/fixes.patch
Normal file
|
|
@ -0,0 +1,148 @@
|
|||
diff --git a/SDL_Pango.pc.in b/SDL_Pango.pc.in
|
||||
index 750d091..3af38ff 100644
|
||||
--- a/SDL_Pango.pc.in
|
||||
+++ b/SDL_Pango.pc.in
|
||||
@@ -6,6 +6,6 @@ includedir=@includedir@
|
||||
Name: SDL_Pango
|
||||
Description: SDL library for internationalized text rendering
|
||||
Version: @VERSION@
|
||||
-Requires: pango
|
||||
+Requires: pango pangoft2
|
||||
Libs: -L${libdir} -lSDL_Pango
|
||||
Cflags: -I${includedir}
|
||||
\ No newline at end of file
|
||||
diff --git a/src/SDL_Pango.c b/src/SDL_Pango.c
|
||||
index b969bc1..cc2c3f5 100644
|
||||
--- a/src/SDL_Pango.c
|
||||
+++ b/src/SDL_Pango.c
|
||||
@@ -231,6 +231,41 @@
|
||||
|
||||
#include "SDL_Pango.h"
|
||||
|
||||
+const SDLPango_Matrix _MATRIX_WHITE_BACK
|
||||
+ = {255, 0, 0, 0,
|
||||
+ 255, 0, 0, 0,
|
||||
+ 255, 0, 0, 0,
|
||||
+ 255, 255, 0, 0,};
|
||||
+const SDLPango_Matrix *MATRIX_WHITE_BACK = &_MATRIX_WHITE_BACK;
|
||||
+
|
||||
+const SDLPango_Matrix _MATRIX_BLACK_BACK
|
||||
+ = {0, 255, 0, 0,
|
||||
+ 0, 255, 0, 0,
|
||||
+ 0, 255, 0, 0,
|
||||
+ 255, 255, 0, 0,};
|
||||
+const SDLPango_Matrix *MATRIX_BLACK_BACK = &_MATRIX_BLACK_BACK;
|
||||
+
|
||||
+const SDLPango_Matrix _MATRIX_TRANSPARENT_BACK_BLACK_LETTER
|
||||
+ = {0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 0, 0, 0,
|
||||
+ 0, 255, 0, 0,};
|
||||
+const SDLPango_Matrix *MATRIX_TRANSPARENT_BACK_BLACK_LETTER = &_MATRIX_TRANSPARENT_BACK_BLACK_LETTER;
|
||||
+
|
||||
+const SDLPango_Matrix _MATRIX_TRANSPARENT_BACK_WHITE_LETTER
|
||||
+ = {255, 255, 0, 0,
|
||||
+ 255, 255, 0, 0,
|
||||
+ 255, 255, 0, 0,
|
||||
+ 0, 255, 0, 0,};
|
||||
+const SDLPango_Matrix *MATRIX_TRANSPARENT_BACK_WHITE_LETTER = &_MATRIX_TRANSPARENT_BACK_WHITE_LETTER;
|
||||
+
|
||||
+const SDLPango_Matrix _MATRIX_TRANSPARENT_BACK_TRANSPARENT_LETTER
|
||||
+ = {255, 255, 0, 0,
|
||||
+ 255, 255, 0, 0,
|
||||
+ 255, 255, 0, 0,
|
||||
+ 0, 0, 0, 0,};
|
||||
+const SDLPango_Matrix *MATRIX_TRANSPARENT_BACK_TRANSPARENT_LETTER = &_MATRIX_TRANSPARENT_BACK_TRANSPARENT_LETTER;
|
||||
+
|
||||
//! non-zero if initialized
|
||||
static int IS_INITIALIZED = 0;
|
||||
|
||||
diff --git a/src/SDL_Pango.h b/src/SDL_Pango.h
|
||||
index 6ebdf78..b7e5e58 100644
|
||||
--- a/src/SDL_Pango.h
|
||||
+++ b/src/SDL_Pango.h
|
||||
@@ -47,57 +47,32 @@ typedef struct _SDLPango_Matrix {
|
||||
Uint8 m[4][4]; /*! Matrix variables */
|
||||
} SDLPango_Matrix;
|
||||
|
||||
-const SDLPango_Matrix _MATRIX_WHITE_BACK
|
||||
- = {255, 0, 0, 0,
|
||||
- 255, 0, 0, 0,
|
||||
- 255, 0, 0, 0,
|
||||
- 255, 255, 0, 0,};
|
||||
|
||||
/*!
|
||||
Specifies white back and black letter.
|
||||
*/
|
||||
-const SDLPango_Matrix *MATRIX_WHITE_BACK = &_MATRIX_WHITE_BACK;
|
||||
+extern const SDLPango_Matrix *MATRIX_WHITE_BACK;
|
||||
|
||||
-const SDLPango_Matrix _MATRIX_BLACK_BACK
|
||||
- = {0, 255, 0, 0,
|
||||
- 0, 255, 0, 0,
|
||||
- 0, 255, 0, 0,
|
||||
- 255, 255, 0, 0,};
|
||||
/*!
|
||||
Specifies black back and white letter.
|
||||
*/
|
||||
-const SDLPango_Matrix *MATRIX_BLACK_BACK = &_MATRIX_BLACK_BACK;
|
||||
+extern const SDLPango_Matrix *MATRIX_BLACK_BACK;
|
||||
|
||||
-const SDLPango_Matrix _MATRIX_TRANSPARENT_BACK_BLACK_LETTER
|
||||
- = {0, 0, 0, 0,
|
||||
- 0, 0, 0, 0,
|
||||
- 0, 0, 0, 0,
|
||||
- 0, 255, 0, 0,};
|
||||
/*!
|
||||
Specifies transparent back and black letter.
|
||||
*/
|
||||
-const SDLPango_Matrix *MATRIX_TRANSPARENT_BACK_BLACK_LETTER = &_MATRIX_TRANSPARENT_BACK_BLACK_LETTER;
|
||||
+extern const SDLPango_Matrix *MATRIX_TRANSPARENT_BACK_BLACK_LETTER;
|
||||
|
||||
-const SDLPango_Matrix _MATRIX_TRANSPARENT_BACK_WHITE_LETTER
|
||||
- = {255, 255, 0, 0,
|
||||
- 255, 255, 0, 0,
|
||||
- 255, 255, 0, 0,
|
||||
- 0, 255, 0, 0,};
|
||||
/*!
|
||||
Specifies transparent back and white letter.
|
||||
*/
|
||||
-const SDLPango_Matrix *MATRIX_TRANSPARENT_BACK_WHITE_LETTER = &_MATRIX_TRANSPARENT_BACK_WHITE_LETTER;
|
||||
+extern const SDLPango_Matrix *MATRIX_TRANSPARENT_BACK_WHITE_LETTER;
|
||||
|
||||
-const SDLPango_Matrix _MATRIX_TRANSPARENT_BACK_TRANSPARENT_LETTER
|
||||
- = {255, 255, 0, 0,
|
||||
- 255, 255, 0, 0,
|
||||
- 255, 255, 0, 0,
|
||||
- 0, 0, 0, 0,};
|
||||
/*!
|
||||
Specifies transparent back and transparent letter.
|
||||
This is useful for KARAOKE like rendering.
|
||||
*/
|
||||
-const SDLPango_Matrix *MATRIX_TRANSPARENT_BACK_TRANSPARENT_LETTER = &_MATRIX_TRANSPARENT_BACK_TRANSPARENT_LETTER;
|
||||
+extern const SDLPango_Matrix *MATRIX_TRANSPARENT_BACK_TRANSPARENT_LETTER;
|
||||
|
||||
/*!
|
||||
Specifies direction of text. See Pango reference for detail
|
||||
@@ -186,7 +161,8 @@ extern DECLSPEC void SDLCALL SDLPango_SetBaseDirection(
|
||||
SDLPango_Direction direction);
|
||||
|
||||
|
||||
-#ifdef __FT2_BUILD_UNIX_H__
|
||||
+
|
||||
+#ifdef __PANGO_H__
|
||||
|
||||
extern DECLSPEC void SDLCALL SDLPango_CopyFTBitmapToSurface(
|
||||
const FT_Bitmap *bitmap,
|
||||
@@ -194,11 +170,8 @@ extern DECLSPEC void SDLCALL SDLPango_CopyFTBitmapToSurface(
|
||||
const SDLPango_Matrix *matrix,
|
||||
SDL_Rect *rect);
|
||||
|
||||
-#endif /* __FT2_BUILD_UNIX_H__ */
|
||||
|
||||
|
||||
-#ifdef __PANGO_H__
|
||||
-
|
||||
extern DECLSPEC PangoFontMap* SDLCALL SDLPango_GetPangoFontMap(
|
||||
SDLPango_Context *context);
|
||||
|
||||
53
pkgs/development/libraries/SDL_audiolib/default.nix
Normal file
53
pkgs/development/libraries/SDL_audiolib/default.nix
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, cmake
|
||||
, SDL2
|
||||
, pkg-config
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL_audiolib";
|
||||
version = "unstable-2022-04-17";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "realnc";
|
||||
repo = "SDL_audiolib";
|
||||
rev = "908214606387ef8e49aeacf89ce848fb36f694fc";
|
||||
sha256 = "sha256-11KkwIhG1rX7yDFSj92NJRO9L2e7XZGq2gOJ54+sN/A=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
pkg-config
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
SDL2
|
||||
];
|
||||
|
||||
cmakeFlags = [
|
||||
"-DUSE_RESAMP_SRC=OFF"
|
||||
"-DUSE_RESAMP_SOXR=OFF"
|
||||
"-DUSE_DEC_DRFLAC=OFF"
|
||||
"-DUSE_DEC_OPENMPT=OFF"
|
||||
"-DUSE_DEC_XMP=OFF"
|
||||
"-DUSE_DEC_MODPLUG=OFF"
|
||||
"-DUSE_DEC_MPG123=OFF"
|
||||
"-DUSE_DEC_SNDFILE=OFF"
|
||||
"-DUSE_DEC_LIBVORBIS=OFF"
|
||||
"-DUSE_DEC_LIBOPUSFILE=OFF"
|
||||
"-DUSE_DEC_MUSEPACK=OFF"
|
||||
"-DUSE_DEC_FLUIDSYNTH=OFF"
|
||||
"-DUSE_DEC_BASSMIDI=OFF"
|
||||
"-DUSE_DEC_WILDMIDI=OFF"
|
||||
"-DUSE_DEC_ADLMIDI=OFF"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Audio decoding, resampling and mixing library for SDL";
|
||||
homepage = "https://github.com/realnc/SDL_audiolib";
|
||||
license = licenses.lgpl3Plus;
|
||||
maintainers = with maintainers; [ SuperSandro2000 ];
|
||||
};
|
||||
}
|
||||
53
pkgs/development/libraries/SDL_compat/default.nix
Normal file
53
pkgs/development/libraries/SDL_compat/default.nix
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, cmake
|
||||
, pkg-config
|
||||
, SDL2
|
||||
, libGLSupported ? lib.elem stdenv.hostPlatform.system lib.platforms.mesaPlatforms
|
||||
, openglSupport ? libGLSupported
|
||||
, libGL
|
||||
, libGLU
|
||||
}:
|
||||
|
||||
let
|
||||
inherit (lib) optionals makeLibraryPath;
|
||||
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL_compat";
|
||||
version = "1.2.52";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "libsdl-org";
|
||||
repo = "sdl12-compat";
|
||||
rev = "release-" + version;
|
||||
hash = "sha256-PDGlMI8q74JaqMQ5oX9Zt5CEr7frFQWECbuwq5g25eg=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake pkg-config ];
|
||||
|
||||
propagatedBuildInputs = [ SDL2 ]
|
||||
++ optionals openglSupport [ libGL libGLU ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
setupHook = ../SDL/setup-hook.sh;
|
||||
|
||||
postFixup = ''
|
||||
for lib in $out/lib/*.so* ; do
|
||||
if [[ -L "$lib" ]]; then
|
||||
patchelf --set-rpath "$(patchelf --print-rpath $lib):${makeLibraryPath propagatedBuildInputs}" "$lib"
|
||||
fi
|
||||
done
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
broken = stdenv.isDarwin;
|
||||
description = "A cross-platform multimedia library - build SDL 1.2 applications against 2.0";
|
||||
homepage = "https://www.libsdl.org/";
|
||||
license = licenses.zlib;
|
||||
maintainers = with maintainers; [ peterhoeg ];
|
||||
platforms = platforms.all;
|
||||
};
|
||||
}
|
||||
44
pkgs/development/libraries/SDL_gfx/default.nix
Normal file
44
pkgs/development/libraries/SDL_gfx/default.nix
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
{ lib, stdenv, fetchurl, SDL }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL_gfx";
|
||||
version = "2.0.26";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.ferzkopp.net/Software/SDL_gfx-2.0/${pname}-${version}.tar.gz";
|
||||
sha256 = "0ijljhs0v99dj6y27hc10z6qchyp8gdp4199y6jzngy6dzxlzsvw";
|
||||
};
|
||||
|
||||
buildInputs = [ SDL ] ;
|
||||
|
||||
configureFlags = [ "--disable-mmx" ]
|
||||
++ lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL graphics drawing primitives and support functions";
|
||||
|
||||
longDescription = ''
|
||||
The SDL_gfx library evolved out of the SDL_gfxPrimitives code
|
||||
which provided basic drawing routines such as lines, circles or
|
||||
polygons and SDL_rotozoom which implemented a interpolating
|
||||
rotozoomer for SDL surfaces.
|
||||
|
||||
The current components of the SDL_gfx library are:
|
||||
|
||||
* Graphic Primitives (SDL_gfxPrimitves.h)
|
||||
* Rotozoomer (SDL_rotozoom.h)
|
||||
* Framerate control (SDL_framerate.h)
|
||||
* MMX image filters (SDL_imageFilter.h)
|
||||
* Custom Blit functions (SDL_gfxBlitFunc.h)
|
||||
|
||||
The library is backwards compatible to the above mentioned
|
||||
code. Its is written in plain C and can be used in C++ code.
|
||||
'';
|
||||
|
||||
homepage = "https://sourceforge.net/projects/sdlgfx/";
|
||||
license = licenses.zlib;
|
||||
|
||||
maintainers = with maintainers; [ bjg ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
36
pkgs/development/libraries/SDL_gpu/default.nix
Normal file
36
pkgs/development/libraries/SDL_gpu/default.nix
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake, SDL2, libGLU }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
pname = "SDL_gpu-unstable";
|
||||
version = "2019-01-24";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "grimfang4";
|
||||
repo = "sdl-gpu";
|
||||
rev = "e3d350b325a0e0d0b3007f69ede62313df46c6ef";
|
||||
sha256 = "0kibcaim01inb6xxn4mr6affn4hm50vz9kahb5k9iz8dmdsrhxy1";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
buildInputs = [ SDL2 libGLU ];
|
||||
|
||||
cmakeFlags = [
|
||||
"-DSDL_gpu_BUILD_DEMOS=OFF"
|
||||
"-DSDL_gpu_BUILD_TOOLS=OFF"
|
||||
"-DSDL_gpu_BUILD_VIDEO_TEST=OFF"
|
||||
"-DSDL_gpu_BUILD_TESTS=OFF"
|
||||
];
|
||||
|
||||
patchPhase = ''
|
||||
sed -ie '210s#''${OUTPUT_DIR}/lib#''${CMAKE_INSTALL_LIBDIR}#' src/CMakeLists.txt
|
||||
sed -ie '213s#''${OUTPUT_DIR}/lib#''${CMAKE_INSTALL_LIBDIR}#' src/CMakeLists.txt
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "A library for high-performance, modern 2D graphics with SDL written in C";
|
||||
homepage = "https://github.com/grimfang4/sdl-gpu";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ pmiddend ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
38
pkgs/development/libraries/SDL_image/default.nix
Normal file
38
pkgs/development/libraries/SDL_image/default.nix
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
{ lib, stdenv, fetchurl, fetchpatch, SDL, libpng, libjpeg, libtiff, giflib, libXpm, pkg-config }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL_image";
|
||||
version = "1.2.12";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.libsdl.org/projects/SDL_image/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "16an9slbb8ci7d89wakkmyfvp7c0cval8xw4hkg0842nhhlp540b";
|
||||
};
|
||||
|
||||
patches = [
|
||||
(fetchpatch {
|
||||
name = "CVE-2017-2887";
|
||||
url = "https://github.com/libsdl-org/SDL_image/commit/e7723676825cd2b2ffef3316ec1879d7726618f2.patch";
|
||||
includes = [ "IMG_xcf.c" ];
|
||||
sha256 = "174ka2r95i29nlshzgp6x5vc68v7pi8lhzf33and2b1ms49g4jb7";
|
||||
})
|
||||
];
|
||||
|
||||
configureFlags = [
|
||||
# Disable its dynamic loading or dlopen will fail because of no proper rpath
|
||||
"--disable-jpg-shared"
|
||||
"--disable-png-shared"
|
||||
"--disable-tif-shared"
|
||||
] ++ lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
buildInputs = [ SDL libpng libjpeg libtiff giflib libXpm ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL image library";
|
||||
homepage = "http://www.libsdl.org/projects/SDL_image/";
|
||||
maintainers = with maintainers; [ lovek323 ];
|
||||
platforms = platforms.unix;
|
||||
license = licenses.zlib;
|
||||
};
|
||||
}
|
||||
30
pkgs/development/libraries/SDL_mixer/default.nix
Normal file
30
pkgs/development/libraries/SDL_mixer/default.nix
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
{ stdenv, lib, fetchurl
|
||||
, SDL, libogg, libvorbis, smpeg, libmikmod
|
||||
, fluidsynth, pkg-config
|
||||
, enableNativeMidi ? false
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL_mixer";
|
||||
version = "1.2.12";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://www.libsdl.org/projects/${pname}/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "0alrhqgm40p4c92s26mimg9cm1y7rzr6m0p49687jxd9g6130i0n";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
buildInputs = [ SDL libogg libvorbis fluidsynth smpeg libmikmod ];
|
||||
|
||||
configureFlags = [ "--disable-music-ogg-shared" "--disable-music-mod-shared" ]
|
||||
++ lib.optional enableNativeMidi " --enable-music-native-midi-gpl"
|
||||
++ lib.optionals stdenv.isDarwin [ "--disable-sdltest" "--disable-smpegtest" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL multi-channel audio mixer library";
|
||||
homepage = "http://www.libsdl.org/projects/SDL_mixer/";
|
||||
maintainers = with maintainers; [ lovek323 ];
|
||||
platforms = platforms.unix;
|
||||
license = licenses.zlib;
|
||||
};
|
||||
}
|
||||
23
pkgs/development/libraries/SDL_net/default.nix
Normal file
23
pkgs/development/libraries/SDL_net/default.nix
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
{ lib, stdenv, fetchurl, SDL, pkg-config }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL_net";
|
||||
version = "1.2.8";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://www.libsdl.org/projects/SDL_net/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "1d5c9xqlf4s1c01gzv6cxmg0r621pq9kfgxcg3197xw4p25pljjz";
|
||||
};
|
||||
|
||||
configureFlags = lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
propagatedBuildInputs = [ SDL ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL networking library";
|
||||
platforms = platforms.unix;
|
||||
license = licenses.zlib;
|
||||
homepage = "https://www.libsdl.org/projects/SDL_net/release-1.2.html";
|
||||
};
|
||||
}
|
||||
26
pkgs/development/libraries/SDL_sixel/default.nix
Normal file
26
pkgs/development/libraries/SDL_sixel/default.nix
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
{ lib, stdenv, fetchFromGitHub, pkg-config, libsixel }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
pname = "SDL_sixel";
|
||||
version = "1.2-nightly";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "saitoha";
|
||||
repo = "SDL1.2-SIXEL";
|
||||
rev = "ab3fccac6e34260a617be511bd8c2b2beae41952";
|
||||
sha256 = "0gm2vngdac17lzw9azkhzazmfq3byjddms14gqjk18vnynfqp5wp";
|
||||
};
|
||||
|
||||
configureFlags = [ "--enable-video-sixel" ];
|
||||
|
||||
nativeBuildInputs = [ pkg-config ];
|
||||
buildInputs = [ libsixel ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A cross-platform multimedia library, that supports sixel graphics on consoles";
|
||||
homepage = "https://github.com/saitoha/SDL1.2-SIXEL";
|
||||
maintainers = with maintainers; [ vrthra ];
|
||||
platforms = platforms.linux;
|
||||
license = licenses.lgpl21;
|
||||
};
|
||||
}
|
||||
22
pkgs/development/libraries/SDL_sound/default.nix
Normal file
22
pkgs/development/libraries/SDL_sound/default.nix
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
{ stdenv, lib, fetchurl, SDL, libvorbis, flac, libmikmod }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL_sound";
|
||||
version = "1.0.3";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://icculus.org/SDL_sound/downloads/${pname}-${version}.tar.gz";
|
||||
sha256 = "1pz6g56gcy7pmmz3hhych3iq9jvinml2yjz15fjqjlj8pc5zv69r";
|
||||
};
|
||||
|
||||
buildInputs = [ SDL libvorbis flac libmikmod ];
|
||||
|
||||
configureFlags = lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL sound library";
|
||||
platforms = platforms.unix;
|
||||
license = licenses.lgpl21;
|
||||
homepage = "https://www.icculus.org/SDL_sound/";
|
||||
};
|
||||
}
|
||||
20
pkgs/development/libraries/SDL_stretch/default.nix
Normal file
20
pkgs/development/libraries/SDL_stretch/default.nix
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
{ lib, stdenv, fetchurl, SDL }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL_stretch";
|
||||
version = "0.3.1";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/sdl-stretch/${version}/${pname}-${version}.tar.bz2";
|
||||
sha256 = "1mzw68sn4yxbp8429jg2h23h8xw2qjid51z1f5pdsghcn3x0pgvw";
|
||||
};
|
||||
|
||||
buildInputs = [ SDL ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Stretch Functions For SDL";
|
||||
homepage = "http://sdl-stretch.sourceforge.net/";
|
||||
license = licenses.lgpl2;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
33
pkgs/development/libraries/SDL_ttf/default.nix
Normal file
33
pkgs/development/libraries/SDL_ttf/default.nix
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
{ lib, stdenv, fetchurl, fetchpatch, SDL, freetype }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "SDL_ttf";
|
||||
version = "2.0.11";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.libsdl.org/projects/SDL_ttf/release/${pname}-${version}.tar.gz";
|
||||
sha256 = "1dydxd4f5kb1288i5n5568kdk2q7f8mqjr7i7sd33nplxjaxhk3j";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Bug #830: TTF_RenderGlyph_Shaded is broken
|
||||
(fetchpatch {
|
||||
url = "https://bugzilla-attachments.libsdl.org/attachment.cgi?id=830";
|
||||
sha256 = "0cfznfzg1hs10wl349z9n8chw80i5adl3iwhq4y102g0xrjyb72d";
|
||||
})
|
||||
];
|
||||
|
||||
patchFlags = [ "-p0" ];
|
||||
|
||||
buildInputs = [ SDL freetype ];
|
||||
|
||||
configureFlags = lib.optional stdenv.isDarwin "--disable-sdltest";
|
||||
|
||||
meta = with lib; {
|
||||
description = "SDL TrueType library";
|
||||
license = licenses.zlib;
|
||||
platforms = platforms.all;
|
||||
homepage = "https://www.libsdl.org/projects/SDL_ttf/release-1.2.html";
|
||||
maintainers = with maintainers; [ abbradar ];
|
||||
};
|
||||
}
|
||||
29
pkgs/development/libraries/StormLib/default.nix
Normal file
29
pkgs/development/libraries/StormLib/default.nix
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake, bzip2, libtomcrypt, zlib }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "StormLib";
|
||||
version = "9.22";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "ladislav-zezula";
|
||||
repo = "StormLib";
|
||||
rev = "v${version}";
|
||||
sha256 = "1rcdl6ryrr8fss5z5qlpl4prrw8xpbcdgajg2hpp0i7fpk21ymcc";
|
||||
};
|
||||
|
||||
cmakeFlags = [
|
||||
"-DBUILD_SHARED_LIBS=ON"
|
||||
"-DWITH_LIBTOMCRYPT=ON"
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
buildInputs = [ bzip2 libtomcrypt zlib ];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/ladislav-zezula/StormLib";
|
||||
license = licenses.mit;
|
||||
description = "An open-source project that can work with Blizzard MPQ archives";
|
||||
platforms = platforms.all;
|
||||
maintainers = with maintainers; [ aanderse karolchmist ];
|
||||
};
|
||||
}
|
||||
33
pkgs/development/libraries/Xaw3d/default.nix
Normal file
33
pkgs/development/libraries/Xaw3d/default.nix
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchurl
|
||||
, imake
|
||||
, gccmakedep
|
||||
, bison
|
||||
, flex
|
||||
, pkg-config
|
||||
, xlibsWrapper
|
||||
, libXmu
|
||||
, libXpm
|
||||
, libXp
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "Xaw3d";
|
||||
version = "1.6.3";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.x.org/releases/individual/lib/libXaw3d-${version}.tar.bz2";
|
||||
sha256 = "0i653s8g25cc0mimkwid9366bqkbyhdyjhckx7bw77j20hzrkfid";
|
||||
};
|
||||
dontUseImakeConfigure = true;
|
||||
nativeBuildInputs = [ pkg-config bison flex imake gccmakedep ];
|
||||
buildInputs = [ libXpm libXp ];
|
||||
propagatedBuildInputs = [ xlibsWrapper libXmu ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "3D widget set based on the Athena Widget set";
|
||||
platforms = lib.platforms.unix;
|
||||
license = licenses.mit;
|
||||
};
|
||||
}
|
||||
32
pkgs/development/libraries/a52dec/default.nix
Normal file
32
pkgs/development/libraries/a52dec/default.nix
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
{lib, stdenv, fetchurl}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "a52dec";
|
||||
version = "0.7.4";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://liba52.sourceforge.io/files/${pname}-${version}.tar.gz";
|
||||
sha256 = "oh1ySrOzkzMwGUNTaH34LEdbXfuZdRPu9MJd5shl7DM=";
|
||||
};
|
||||
|
||||
configureFlags = [
|
||||
"--enable-shared"
|
||||
];
|
||||
|
||||
makeFlags = [
|
||||
"AR=${stdenv.cc.targetPrefix}ar"
|
||||
];
|
||||
|
||||
# fails 1 out of 1 tests with "BAD GLOBAL SYMBOLS" on i686
|
||||
# which can also be fixed with
|
||||
# hardeningDisable = lib.optional stdenv.isi686 "pic";
|
||||
# but it's better to disable tests than loose ASLR on i686
|
||||
doCheck = !stdenv.isi686;
|
||||
|
||||
meta = with lib; {
|
||||
description = "ATSC A/52 stream decoder";
|
||||
homepage = "https://liba52.sourceforge.io/";
|
||||
platforms = platforms.unix;
|
||||
license = licenses.gpl2Plus;
|
||||
};
|
||||
}
|
||||
106
pkgs/development/libraries/aalib/darwin.patch
Normal file
106
pkgs/development/libraries/aalib/darwin.patch
Normal file
|
|
@ -0,0 +1,106 @@
|
|||
diff --git a/src/aaedit.c b/src/aaedit.c
|
||||
index 09534d2..2ea52f9 100644
|
||||
--- a/src/aaedit.c
|
||||
+++ b/src/aaedit.c
|
||||
@@ -1,6 +1,6 @@
|
||||
#include <string.h>
|
||||
#include <ctype.h>
|
||||
-#include <malloc.h>
|
||||
+#include <stdlib.h>
|
||||
#include "aalib.h"
|
||||
#include "aaint.h"
|
||||
static void aa_editdisplay(struct aa_edit *e)
|
||||
|
||||
diff --git a/src/aakbdreg.c b/src/aakbdreg.c
|
||||
index def65fe..f4f8efb 100644
|
||||
--- a/src/aakbdreg.c
|
||||
+++ b/src/aakbdreg.c
|
||||
@@ -1,4 +1,4 @@
|
||||
-#include <malloc.h>
|
||||
+#include <stdlib.h>
|
||||
#include "config.h"
|
||||
#include "aalib.h"
|
||||
#include "aaint.h"
|
||||
diff --git a/src/aalib.c b/src/aalib.c
|
||||
index 11fecc8..e3063b4 100644
|
||||
--- a/src/aalib.c
|
||||
+++ b/src/aalib.c
|
||||
@@ -1,6 +1,6 @@
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
-#include <malloc.h>
|
||||
+#include <stdlib.h>
|
||||
#include "aalib.h"
|
||||
#include "aaint.h"
|
||||
|
||||
diff --git a/src/aamoureg.c b/src/aamoureg.c
|
||||
index 0380828..bb55fe3 100644
|
||||
--- a/src/aamoureg.c
|
||||
+++ b/src/aamoureg.c
|
||||
@@ -1,4 +1,4 @@
|
||||
-#include <malloc.h>
|
||||
+#include <stdlib.h>
|
||||
#include "config.h"
|
||||
#include "aalib.h"
|
||||
#include "aaint.h"
|
||||
diff --git a/src/aarec.c b/src/aarec.c
|
||||
index 70f4ebc..ee43e8a 100644
|
||||
--- a/src/aarec.c
|
||||
+++ b/src/aarec.c
|
||||
@@ -1,5 +1,5 @@
|
||||
#include <string.h>
|
||||
-#include <malloc.h>
|
||||
+#include <stdlib.h>
|
||||
#include "aalib.h"
|
||||
#include "aaint.h"
|
||||
aa_linkedlist *aa_kbdrecommended = NULL, *aa_mouserecommended = NULL,
|
||||
diff --git a/src/aaregist.c b/src/aaregist.c
|
||||
index 54abec0..765155e 100644
|
||||
--- a/src/aaregist.c
|
||||
+++ b/src/aaregist.c
|
||||
@@ -1,4 +1,4 @@
|
||||
-#include <malloc.h>
|
||||
+#include <stdlib.h>
|
||||
#include "config.h"
|
||||
#include "aalib.h"
|
||||
#include "aaint.h"
|
||||
diff --git a/src/aax.c b/src/aax.c
|
||||
index adcbd82..36e3294 100644
|
||||
--- a/src/aax.c
|
||||
+++ b/src/aax.c
|
||||
@@ -1,4 +1,3 @@
|
||||
-#include <malloc.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
diff --git a/src/aaxkbd.c b/src/aaxkbd.c
|
||||
index 30d5903..da2248d 100644
|
||||
--- a/src/aaxkbd.c
|
||||
+++ b/src/aaxkbd.c
|
||||
@@ -1,4 +1,3 @@
|
||||
-#include <malloc.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
diff --git a/src/aaxmouse.c b/src/aaxmouse.c
|
||||
index 9935b03..7e725ad 100644
|
||||
--- a/src/aaxmouse.c
|
||||
+++ b/src/aaxmouse.c
|
||||
@@ -1,4 +1,3 @@
|
||||
-#include <malloc.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
diff --git a/aalib.m4 b/aalib.m4
|
||||
index c40b8db..991fbda 100644
|
||||
--- a/aalib.m4
|
||||
+++ b/aalib.m4
|
||||
@@ -9,7 +9,7 @@
|
||||
dnl AM_PATH_AALIB([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
|
||||
dnl Test for AALIB, and define AALIB_CFLAGS and AALIB_LIBS
|
||||
dnl
|
||||
-AC_DEFUN(AM_PATH_AALIB,
|
||||
+AC_DEFUN([AM_PATH_AALIB],
|
||||
[dnl
|
||||
dnl Get the cflags and libraries from the aalib-config script
|
||||
dnl
|
||||
42
pkgs/development/libraries/aalib/default.nix
Normal file
42
pkgs/development/libraries/aalib/default.nix
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
{lib, stdenv, fetchurl, ncurses, automake}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "aalib";
|
||||
version = "1.4rc5";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/aa-project/aalib-${version}.tar.gz";
|
||||
sha256 = "1vkh19gb76agvh4h87ysbrgy82hrw88lnsvhynjf4vng629dmpgv";
|
||||
};
|
||||
|
||||
outputs = [ "bin" "dev" "out" "man" "info" ];
|
||||
setOutputFlags = false; # Doesn't support all the flags
|
||||
|
||||
patches = lib.optionals stdenv.isDarwin [ ./darwin.patch ];
|
||||
|
||||
# The fuloong2f is not supported by aalib still
|
||||
preConfigure = ''
|
||||
cp ${automake}/share/automake*/config.{sub,guess} .
|
||||
configureFlagsArray+=(
|
||||
"--bindir=$bin/bin"
|
||||
"--includedir=$dev/include"
|
||||
"--libdir=$out/lib"
|
||||
)
|
||||
'';
|
||||
|
||||
buildInputs = [ ncurses ];
|
||||
|
||||
configureFlags = [ "--without-x" "--with-ncurses=${ncurses.dev}" ];
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p $dev/bin
|
||||
mv $bin/bin/aalib-config $dev/bin/aalib-config
|
||||
substituteInPlace $out/lib/libaa.la --replace "${ncurses.dev}/lib" "${ncurses.out}/lib"
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "ASCII art graphics library";
|
||||
platforms = lib.platforms.unix;
|
||||
license = lib.licenses.lgpl2;
|
||||
};
|
||||
}
|
||||
45
pkgs/development/libraries/abseil-cpp/202103.nix
Normal file
45
pkgs/development/libraries/abseil-cpp/202103.nix
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
, static ? stdenv.hostPlatform.isStatic
|
||||
, cxxStandard ? null
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "abseil-cpp";
|
||||
version = "20210324.2";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "abseil";
|
||||
repo = "abseil-cpp";
|
||||
rev = version;
|
||||
sha256 = "sha256-fcxPhuI2eL/fnd6nT11p8DpUNwGNaXZmd03yOiZcOT0=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Use CMAKE_INSTALL_FULL_{LIBDIR,INCLUDEDIR}
|
||||
# https://github.com/abseil/abseil-cpp/pull/963
|
||||
(fetchpatch {
|
||||
url = "https://github.com/abseil/abseil-cpp/commit/5bfa70c75e621c5d5ec095c8c4c0c050dcb2957e.patch";
|
||||
sha256 = "0nhjxqfxpi2pkfinnqvd5m4npf9l1kg39mjx9l3087ajhadaywl5";
|
||||
})
|
||||
];
|
||||
|
||||
cmakeFlags = [
|
||||
"-DBUILD_SHARED_LIBS=${if static then "OFF" else "ON"}"
|
||||
] ++ lib.optionals (cxxStandard != null) [
|
||||
"-DCMAKE_CXX_STANDARD=${cxxStandard}"
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "An open-source collection of C++ code designed to augment the C++ standard library";
|
||||
homepage = "https://abseil.io/";
|
||||
license = licenses.asl20;
|
||||
platforms = platforms.all;
|
||||
maintainers = [ maintainers.andersk ];
|
||||
};
|
||||
}
|
||||
36
pkgs/development/libraries/abseil-cpp/202111.nix
Normal file
36
pkgs/development/libraries/abseil-cpp/202111.nix
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cmake
|
||||
, static ? stdenv.hostPlatform.isStatic
|
||||
, cxxStandard ? null
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "abseil-cpp";
|
||||
version = "20211102.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "abseil";
|
||||
repo = "abseil-cpp";
|
||||
rev = version;
|
||||
sha256 = "sha256-sSXT6D4JSrk3dA7kVaxfKkzOMBpqXQb0WbMYWG+nGwk=";
|
||||
};
|
||||
|
||||
cmakeFlags = [
|
||||
"-DBUILD_SHARED_LIBS=${if static then "OFF" else "ON"}"
|
||||
] ++ lib.optionals (cxxStandard != null) [
|
||||
"-DCMAKE_CXX_STANDARD=${cxxStandard}"
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "An open-source collection of C++ code designed to augment the C++ standard library";
|
||||
homepage = "https://abseil.io/";
|
||||
license = licenses.asl20;
|
||||
platforms = platforms.all;
|
||||
maintainers = [ maintainers.andersk ];
|
||||
};
|
||||
}
|
||||
15
pkgs/development/libraries/abseil-cpp/cmake-full-dirs.patch
Normal file
15
pkgs/development/libraries/abseil-cpp/cmake-full-dirs.patch
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
diff --git a/CMake/AbseilHelpers.cmake b/CMake/AbseilHelpers.cmake
|
||||
index 1a80b5b..1fa57a7 100644
|
||||
--- a/CMake/AbseilHelpers.cmake
|
||||
+++ b/CMake/AbseilHelpers.cmake
|
||||
@@ -171,8 +171,8 @@ function(absl_cc_library)
|
||||
FILE(GENERATE OUTPUT "${CMAKE_BINARY_DIR}/lib/pkgconfig/absl_${_NAME}.pc" CONTENT "\
|
||||
prefix=${CMAKE_INSTALL_PREFIX}\n\
|
||||
exec_prefix=\${prefix}\n\
|
||||
-libdir=\${prefix}/${CMAKE_INSTALL_LIBDIR}\n\
|
||||
-includedir=\${prefix}/${CMAKE_INSTALL_INCLUDEDIR}\n\
|
||||
+libdir=${CMAKE_INSTALL_FULL_LIBDIR}\n\
|
||||
+includedir=${CMAKE_INSTALL_FULL_INCLUDEDIR}\n\
|
||||
\n\
|
||||
Name: absl_${_NAME}\n\
|
||||
Description: Abseil ${_NAME} library\n\
|
||||
26
pkgs/development/libraries/accounts-qt/default.nix
Normal file
26
pkgs/development/libraries/accounts-qt/default.nix
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
{ mkDerivation, lib, fetchFromGitLab, doxygen, glib, libaccounts-glib, pkg-config, qmake }:
|
||||
|
||||
mkDerivation rec {
|
||||
pname = "accounts-qt";
|
||||
version = "1.16";
|
||||
|
||||
src = fetchFromGitLab {
|
||||
sha256 = "1vmpjvysm0ld8dqnx8msa15hlhrkny02cqycsh4k2azrnijg0xjz";
|
||||
rev = "VERSION_${version}";
|
||||
repo = "libaccounts-qt";
|
||||
owner = "accounts-sso";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [ glib libaccounts-glib ];
|
||||
nativeBuildInputs = [ doxygen pkg-config qmake ];
|
||||
|
||||
# Hack to avoid TMPDIR in RPATHs.
|
||||
preFixup = ''rm -rf "$(pwd)" '';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Qt library for accessing the online accounts database";
|
||||
homepage = "https://gitlab.com/accounts-sso";
|
||||
license = licenses.lgpl21;
|
||||
platforms = with platforms; linux;
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,130 @@
|
|||
From 6f172007452b39bfda5062fc29ea5382671ac16e Mon Sep 17 00:00:00 2001
|
||||
From: Alexander Ried <ried@mytum.de>
|
||||
Date: Thu, 26 May 2016 19:54:21 +0200
|
||||
Subject: [PATCH] Disable methods that change files in /etc
|
||||
|
||||
Only if environment variable NIXOS_USERS_PURE is set.
|
||||
---
|
||||
src/daemon.c | 10 ++++++++++
|
||||
src/user.c | 35 +++++++++++++++++++++++++++++++++++
|
||||
2 files changed, 45 insertions(+)
|
||||
|
||||
diff --git a/src/daemon.c b/src/daemon.c
|
||||
index e62e124..87459b2 100644
|
||||
--- a/src/daemon.c
|
||||
+++ b/src/daemon.c
|
||||
@@ -931,6 +931,11 @@ daemon_create_user (AccountsAccounts *accounts,
|
||||
const gchar *real_name,
|
||||
gint account_type)
|
||||
{
|
||||
+ if (getenv("NIXOS_USERS_PURE")) {
|
||||
+ throw_error (context, ERROR_NOT_SUPPORTED, "Modifying users not supported without users.mutableUsers");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
Daemon *daemon = (Daemon*)accounts;
|
||||
CreateUserData *data;
|
||||
|
||||
@@ -1138,6 +1143,11 @@ daemon_delete_user (AccountsAccounts *accounts,
|
||||
gint64 uid,
|
||||
gboolean remove_files)
|
||||
{
|
||||
+ if (getenv("NIXOS_USERS_PURE")) {
|
||||
+ throw_error (context, ERROR_NOT_SUPPORTED, "Modifying users not supported without users.mutableUsers");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
Daemon *daemon = (Daemon*)accounts;
|
||||
DeleteUserData *data;
|
||||
|
||||
diff --git a/src/user.c b/src/user.c
|
||||
index 0fb1a17..dbdebaf 100644
|
||||
--- a/src/user.c
|
||||
+++ b/src/user.c
|
||||
@@ -904,6 +904,11 @@ user_set_real_name (AccountsUser *auser,
|
||||
GDBusMethodInvocation *context,
|
||||
const gchar *real_name)
|
||||
{
|
||||
+ if (getenv("NIXOS_USERS_PURE")) {
|
||||
+ throw_error (context, ERROR_NOT_SUPPORTED, "Modifying users not supported without users.mutableUsers");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
User *user = (User*)auser;
|
||||
int uid;
|
||||
const gchar *action_id;
|
||||
@@ -981,6 +986,11 @@ user_set_user_name (AccountsUser *auser,
|
||||
GDBusMethodInvocation *context,
|
||||
const gchar *user_name)
|
||||
{
|
||||
+ if (getenv("NIXOS_USERS_PURE")) {
|
||||
+ throw_error (context, ERROR_NOT_SUPPORTED, "Modifying users not supported without users.mutableUsers");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
User *user = (User*)auser;
|
||||
daemon_local_check_auth (user->daemon,
|
||||
user,
|
||||
@@ -1263,6 +1273,11 @@ user_set_home_directory (AccountsUser *auser,
|
||||
GDBusMethodInvocation *context,
|
||||
const gchar *home_dir)
|
||||
{
|
||||
+ if (getenv("NIXOS_USERS_PURE")) {
|
||||
+ throw_error (context, ERROR_NOT_SUPPORTED, "Modifying users not supported without users.mutableUsers");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
User *user = (User*)auser;
|
||||
daemon_local_check_auth (user->daemon,
|
||||
user,
|
||||
@@ -1322,6 +1337,11 @@ user_set_shell (AccountsUser *auser,
|
||||
GDBusMethodInvocation *context,
|
||||
const gchar *shell)
|
||||
{
|
||||
+ if (getenv("NIXOS_USERS_PURE")) {
|
||||
+ throw_error (context, ERROR_NOT_SUPPORTED, "Modifying users not supported without users.mutableUsers");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
User *user = (User*)auser;
|
||||
daemon_local_check_auth (user->daemon,
|
||||
user,
|
||||
@@ -1602,6 +1622,11 @@ user_set_locked (AccountsUser *auser,
|
||||
GDBusMethodInvocation *context,
|
||||
gboolean locked)
|
||||
{
|
||||
+ if (getenv("NIXOS_USERS_PURE")) {
|
||||
+ throw_error (context, ERROR_NOT_SUPPORTED, "Modifying users not supported without users.mutableUsers");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
User *user = (User*)auser;
|
||||
daemon_local_check_auth (user->daemon,
|
||||
user,
|
||||
@@ -1814,6 +1839,11 @@ user_set_password_mode (AccountsUser *auser,
|
||||
GDBusMethodInvocation *context,
|
||||
gint mode)
|
||||
{
|
||||
+ if (getenv("NIXOS_USERS_PURE")) {
|
||||
+ throw_error (context, ERROR_NOT_SUPPORTED, "Modifying users not supported without users.mutableUsers");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
User *user = (User*)auser;
|
||||
const gchar *action_id;
|
||||
|
||||
@@ -1905,6 +1935,11 @@ user_set_password (AccountsUser *auser,
|
||||
const gchar *password,
|
||||
const gchar *hint)
|
||||
{
|
||||
+ if (getenv("NIXOS_USERS_PURE")) {
|
||||
+ throw_error (context, ERROR_NOT_SUPPORTED, "Modifying users not supported without users.mutableUsers");
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
User *user = (User*)auser;
|
||||
gchar **data;
|
||||
|
||||
--
|
||||
2.9.3
|
||||
|
||||
84
pkgs/development/libraries/accountsservice/default.nix
Normal file
84
pkgs/development/libraries/accountsservice/default.nix
Normal file
|
|
@ -0,0 +1,84 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchurl
|
||||
, substituteAll
|
||||
, pkg-config
|
||||
, glib
|
||||
, shadow
|
||||
, gobject-introspection
|
||||
, polkit
|
||||
, systemd
|
||||
, coreutils
|
||||
, meson
|
||||
, dbus
|
||||
, ninja
|
||||
, python3
|
||||
, vala
|
||||
, gettext
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "accountsservice";
|
||||
version = "22.08.8";
|
||||
|
||||
outputs = [ "out" "dev" ];
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.freedesktop.org/software/accountsservice/accountsservice-${version}.tar.xz";
|
||||
sha256 = "kJmXp2kZ/n3BOKmgHOpwvWItWpMtvJ+xMBARMCOno5E=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Hardcode dependency paths.
|
||||
(substituteAll {
|
||||
src = ./fix-paths.patch;
|
||||
inherit shadow coreutils;
|
||||
})
|
||||
|
||||
# Do not try to create directories in /var, that will not work in Nix sandbox.
|
||||
./no-create-dirs.patch
|
||||
|
||||
# Disable mutating D-Bus methods with immutable /etc.
|
||||
./Disable-methods-that-change-files-in-etc.patch
|
||||
|
||||
# Do not ignore third-party (e.g Pantheon) extensions not matching FHS path scheme.
|
||||
# Fixes https://github.com/NixOS/nixpkgs/issues/72396
|
||||
./drop-prefix-check-extensions.patch
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
dbus
|
||||
gettext
|
||||
gobject-introspection
|
||||
meson
|
||||
ninja
|
||||
pkg-config
|
||||
python3
|
||||
vala
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
glib
|
||||
polkit
|
||||
systemd
|
||||
];
|
||||
|
||||
mesonFlags = [
|
||||
"-Dadmin_group=wheel"
|
||||
"-Dlocalstatedir=/var"
|
||||
"-Dsystemdsystemunitdir=${placeholder "out"}/etc/systemd/system"
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
chmod +x meson_post_install.py
|
||||
patchShebangs meson_post_install.py
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "D-Bus interface for user account query and manipulation";
|
||||
homepage = "https://www.freedesktop.org/wiki/Software/AccountsService";
|
||||
license = licenses.gpl3Plus;
|
||||
maintainers = teams.freedesktop.members ++ (with maintainers; [ pSub ]);
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,22 @@
|
|||
diff --git a/src/extensions.c b/src/extensions.c
|
||||
index 038dcb2..830465d 100644
|
||||
--- a/src/extensions.c
|
||||
+++ b/src/extensions.c
|
||||
@@ -121,16 +121,7 @@ daemon_read_extension_directory (GHashTable *ifaces,
|
||||
continue;
|
||||
}
|
||||
|
||||
- /* Ensure it looks like "../../dbus-1/interfaces/${name}" */
|
||||
- const gchar * const prefix = "../../dbus-1/interfaces/";
|
||||
- if (g_str_has_prefix (symlink, prefix) && g_str_equal (symlink + strlen (prefix), name)) {
|
||||
- daemon_read_extension_file (ifaces, filename);
|
||||
- }
|
||||
- else {
|
||||
- g_warning ("Found accounts service vendor extension symlink %s, but it must be exactly "
|
||||
- "equal to '../../dbus-1/interfaces/%s' for forwards-compatibility reasons.",
|
||||
- filename, name);
|
||||
- }
|
||||
+ daemon_read_extension_file (ifaces, filename);
|
||||
}
|
||||
|
||||
g_dir_close (dir);
|
||||
125
pkgs/development/libraries/accountsservice/fix-paths.patch
Normal file
125
pkgs/development/libraries/accountsservice/fix-paths.patch
Normal file
|
|
@ -0,0 +1,125 @@
|
|||
diff --git a/src/daemon.c b/src/daemon.c
|
||||
index c8b6320..2b74949 100644
|
||||
--- a/src/daemon.c
|
||||
+++ b/src/daemon.c
|
||||
@@ -1102,7 +1102,7 @@ daemon_create_user_authorized_cb (Daemon *daemon,
|
||||
|
||||
sys_log (context, "create user '%s'", cd->user_name);
|
||||
|
||||
- argv[0] = "/usr/sbin/useradd";
|
||||
+ argv[0] = "@shadow@/bin/useradd";
|
||||
argv[1] = "-m";
|
||||
argv[2] = "-c";
|
||||
argv[3] = cd->real_name;
|
||||
@@ -1335,7 +1335,7 @@ daemon_delete_user_authorized_cb (Daemon *daemon,
|
||||
}
|
||||
free (resolved_homedir);
|
||||
|
||||
- argv[0] = "/usr/sbin/userdel";
|
||||
+ argv[0] = "@shadow@/bin/userdel";
|
||||
if (ud->remove_files) {
|
||||
argv[1] = "-f";
|
||||
argv[2] = "-r";
|
||||
diff --git a/src/user.c b/src/user.c
|
||||
index 189b2c5..5358c02 100644
|
||||
--- a/src/user.c
|
||||
+++ b/src/user.c
|
||||
@@ -1145,7 +1145,7 @@ user_change_real_name_authorized_cb (Daemon *daemon,
|
||||
new_gecos = g_strdup (name);
|
||||
}
|
||||
|
||||
- argv[0] = "/usr/sbin/usermod";
|
||||
+ argv[0] = "@shadow@/bin/usermod";
|
||||
argv[1] = "-c";
|
||||
argv[2] = new_gecos;
|
||||
argv[3] = "--";
|
||||
@@ -1218,7 +1218,7 @@ user_change_user_name_authorized_cb (Daemon *daemon,
|
||||
accounts_user_get_uid (ACCOUNTS_USER (user)),
|
||||
name);
|
||||
|
||||
- argv[0] = "/usr/sbin/usermod";
|
||||
+ argv[0] = "@shadow@/bin/usermod";
|
||||
argv[1] = "-l";
|
||||
argv[2] = name;
|
||||
argv[3] = "--";
|
||||
@@ -1627,7 +1627,7 @@ user_change_home_dir_authorized_cb (Daemon *daemon,
|
||||
accounts_user_get_uid (ACCOUNTS_USER (user)),
|
||||
home_dir);
|
||||
|
||||
- argv[0] = "/usr/sbin/usermod";
|
||||
+ argv[0] = "@shadow@/bin/usermod";
|
||||
argv[1] = "-m";
|
||||
argv[2] = "-d";
|
||||
argv[3] = home_dir;
|
||||
@@ -1683,7 +1683,7 @@ user_change_shell_authorized_cb (Daemon *daemon,
|
||||
accounts_user_get_uid (ACCOUNTS_USER (user)),
|
||||
shell);
|
||||
|
||||
- argv[0] = "/usr/sbin/usermod";
|
||||
+ argv[0] = "@shadow@/bin/usermod";
|
||||
argv[1] = "-s";
|
||||
argv[2] = shell;
|
||||
argv[3] = "--";
|
||||
@@ -1824,7 +1824,7 @@ user_change_icon_file_authorized_cb (Daemon *daemon,
|
||||
return;
|
||||
}
|
||||
|
||||
- argv[0] = "/bin/cat";
|
||||
+ argv[0] = "@coreutils@/bin/cat";
|
||||
argv[1] = filename;
|
||||
argv[2] = NULL;
|
||||
|
||||
@@ -1904,7 +1904,7 @@ user_change_locked_authorized_cb (Daemon *daemon,
|
||||
locked ? "locking" : "unlocking",
|
||||
accounts_user_get_user_name (ACCOUNTS_USER (user)),
|
||||
accounts_user_get_uid (ACCOUNTS_USER (user)));
|
||||
- argv[0] = "/usr/sbin/usermod";
|
||||
+ argv[0] = "@shadow@/bin/usermod";
|
||||
argv[1] = locked ? "-L" : "-U";
|
||||
argv[2] = "--";
|
||||
argv[3] = accounts_user_get_user_name (ACCOUNTS_USER (user));
|
||||
@@ -2026,7 +2026,7 @@ user_change_account_type_authorized_cb (Daemon *daemon,
|
||||
|
||||
g_free (groups);
|
||||
|
||||
- argv[0] = "/usr/sbin/usermod";
|
||||
+ argv[0] = "@shadow@/bin/usermod";
|
||||
argv[1] = "-G";
|
||||
argv[2] = str->str;
|
||||
argv[3] = "--";
|
||||
@@ -2093,7 +2093,7 @@ user_change_password_mode_authorized_cb (Daemon *daemon,
|
||||
if (mode == PASSWORD_MODE_SET_AT_LOGIN ||
|
||||
mode == PASSWORD_MODE_NONE) {
|
||||
|
||||
- argv[0] = "/usr/bin/passwd";
|
||||
+ argv[0] = "/run/wrappers/bin/passwd";
|
||||
argv[1] = "-d";
|
||||
argv[2] = "--";
|
||||
argv[3] = accounts_user_get_user_name (ACCOUNTS_USER (user));
|
||||
@@ -2105,7 +2105,7 @@ user_change_password_mode_authorized_cb (Daemon *daemon,
|
||||
}
|
||||
|
||||
if (mode == PASSWORD_MODE_SET_AT_LOGIN) {
|
||||
- argv[0] = "/usr/bin/chage";
|
||||
+ argv[0] = "@shadow@/bin/chage";
|
||||
argv[1] = "-d";
|
||||
argv[2] = "0";
|
||||
argv[3] = "--";
|
||||
@@ -2126,7 +2126,7 @@ user_change_password_mode_authorized_cb (Daemon *daemon,
|
||||
accounts_user_set_locked (ACCOUNTS_USER (user), FALSE);
|
||||
}
|
||||
else if (accounts_user_get_locked (ACCOUNTS_USER (user))) {
|
||||
- argv[0] = "/usr/sbin/usermod";
|
||||
+ argv[0] = "@shadow@/bin/usermod";
|
||||
argv[1] = "-U";
|
||||
argv[2] = "--";
|
||||
argv[3] = accounts_user_get_user_name (ACCOUNTS_USER (user));
|
||||
@@ -2203,7 +2203,7 @@ user_change_password_authorized_cb (Daemon *daemon,
|
||||
|
||||
g_object_freeze_notify (G_OBJECT (user));
|
||||
|
||||
- argv[0] = "/usr/sbin/usermod";
|
||||
+ argv[0] = "@shadow@/bin/usermod";
|
||||
argv[1] = "-p";
|
||||
argv[2] = strings[0];
|
||||
argv[3] = "--";
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
diff --git a/meson_post_install.py b/meson_post_install.py
|
||||
index d8c3dd1..620f714 100644
|
||||
--- a/meson_post_install.py
|
||||
+++ b/meson_post_install.py
|
||||
@@ -9,9 +9,9 @@ localstatedir = os.path.normpath(destdir + os.sep + sys.argv[1])
|
||||
# FIXME: meson will not track the creation of these directories
|
||||
# https://github.com/mesonbuild/meson/blob/master/mesonbuild/scripts/uninstall.py#L39
|
||||
dst_dirs = [
|
||||
- (os.path.join(localstatedir, 'lib'), 0o755),
|
||||
- (os.path.join(localstatedir, 'lib', 'AccountsService', 'icons'), 0o775),
|
||||
- (os.path.join(localstatedir, 'lib', 'AccountsService', 'users'), 0o700),
|
||||
+ # (os.path.join(localstatedir, 'lib'), 0o755),
|
||||
+ # (os.path.join(localstatedir, 'lib', 'AccountsService', 'icons'), 0o775),
|
||||
+ # (os.path.join(localstatedir, 'lib', 'AccountsService', 'users'), 0o700),
|
||||
]
|
||||
|
||||
for (dst_dir, dst_dir_mode) in dst_dirs:
|
||||
41
pkgs/development/libraries/ace/default.nix
Normal file
41
pkgs/development/libraries/ace/default.nix
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
{ lib, stdenv, fetchurl, pkg-config, libtool, perl }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "ace";
|
||||
version = "7.0.6";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://download.dre.vanderbilt.edu/previous_versions/ACE-${version}.tar.bz2";
|
||||
sha256 = "sha256-SgzX2khR92n9388z9mPrpK+tgk7+/59Z8TTEZA7oAhY=";
|
||||
};
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
nativeBuildInputs = [ pkg-config libtool ];
|
||||
buildInputs = [ perl ];
|
||||
|
||||
NIX_CFLAGS_COMPILE = [
|
||||
"-Wno-error=format-security"
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
patchShebangs ./MPC/prj_install.pl
|
||||
'';
|
||||
|
||||
preConfigure = ''
|
||||
export INSTALL_PREFIX=$out
|
||||
export ACE_ROOT=$(pwd)
|
||||
export LD_LIBRARY_PATH="$ACE_ROOT/ace:$ACE_ROOT/lib"
|
||||
echo '#include "ace/config-linux.h"' > ace/config.h
|
||||
echo 'include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU'\
|
||||
> include/makeinclude/platform_macros.GNU
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://www.dre.vanderbilt.edu/~schmidt/ACE.html";
|
||||
description = "ADAPTIVE Communication Environment";
|
||||
license = licenses.doc;
|
||||
maintainers = with maintainers; [ nico202 ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
37
pkgs/development/libraries/acl/default.nix
Normal file
37
pkgs/development/libraries/acl/default.nix
Normal file
|
|
@ -0,0 +1,37 @@
|
|||
{ lib, stdenv, fetchurl, gettext, attr }:
|
||||
|
||||
# Note: this package is used for bootstrapping fetchurl, and thus
|
||||
# cannot use fetchpatch! All mutable patches (generated by GitHub or
|
||||
# cgit) that are needed here should be included directly in Nixpkgs as
|
||||
# files.
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "acl";
|
||||
version = "2.3.1";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://savannah/acl/acl-${version}.tar.gz";
|
||||
sha256 = "sha256-dgxhxokBs3/dXu/ur0wMeia9/disdHoe3/HODiQ8Ea8=";
|
||||
};
|
||||
|
||||
outputs = [ "bin" "dev" "out" "man" "doc" ];
|
||||
|
||||
nativeBuildInputs = [ gettext ];
|
||||
buildInputs = [ attr ];
|
||||
|
||||
# Upstream use C++-style comments in C code. Remove them.
|
||||
# This comment breaks compilation if too strict gcc flags are used.
|
||||
patchPhase = ''
|
||||
echo "Removing C++-style comments from include/acl.h"
|
||||
sed -e '/^\/\//d' -i include/acl.h
|
||||
|
||||
patchShebangs .
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://savannah.nongnu.org/projects/acl";
|
||||
description = "Library and tools for manipulating access control lists";
|
||||
platforms = platforms.linux;
|
||||
license = licenses.gpl2Plus;
|
||||
};
|
||||
}
|
||||
88
pkgs/development/libraries/ada/gnatcoll/bindings.nix
Normal file
88
pkgs/development/libraries/ada/gnatcoll/bindings.nix
Normal file
|
|
@ -0,0 +1,88 @@
|
|||
{ stdenv
|
||||
, lib
|
||||
, fetchFromGitHub
|
||||
, gnat
|
||||
, gprbuild
|
||||
, gnatcoll-core
|
||||
, component
|
||||
# component dependencies
|
||||
, gmp
|
||||
, libiconv
|
||||
, xz
|
||||
, gcc-unwrapped
|
||||
, readline
|
||||
, zlib
|
||||
, python3
|
||||
, ncurses
|
||||
}:
|
||||
|
||||
let
|
||||
# omit python (2.7), no need to introduce a
|
||||
# dependency on an EOL package for no reason
|
||||
libsFor = {
|
||||
iconv = [ libiconv ];
|
||||
gmp = [ gmp ];
|
||||
lzma = [ xz ];
|
||||
readline = [ readline ];
|
||||
python3 = [ python3 ncurses ];
|
||||
syslog = [ ];
|
||||
zlib = [ zlib ];
|
||||
};
|
||||
in
|
||||
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "gnatcoll-${component}";
|
||||
version = "22.0.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "AdaCore";
|
||||
repo = "gnatcoll-bindings";
|
||||
rev = "v${version}";
|
||||
sha256 = "0wbwnd6jccwfd4jdxbnzhc0jhm8ad4phz6y9b1gk8adykkk6jcz4";
|
||||
};
|
||||
|
||||
patches = [
|
||||
./omp-setup-text-mode.patch
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
gprbuild
|
||||
gnat
|
||||
python3
|
||||
];
|
||||
|
||||
# propagate since gprbuild needs to find referenced .gpr files
|
||||
# and all dependency C libraries when statically linking a
|
||||
# downstream executable.
|
||||
propagatedBuildInputs = [
|
||||
gnatcoll-core
|
||||
] ++ libsFor."${component}" or [];
|
||||
|
||||
# explicit flag for GPL acceptance because upstreams
|
||||
# allows a gcc runtime exception for all bindings
|
||||
# except for readline (since it is GPL w/o exceptions)
|
||||
buildFlags = lib.optionals (component == "readline") [
|
||||
"--accept-gpl"
|
||||
];
|
||||
|
||||
buildPhase = ''
|
||||
runHook preBuild
|
||||
${python3.interpreter} ${component}/setup.py build --prefix $out $buildFlags
|
||||
runHook postBuild
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
${python3.interpreter} ${component}/setup.py install --prefix $out
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "GNAT Components Collection - Bindings to C libraries";
|
||||
homepage = "https://github.com/AdaCore/gnatcoll-bindings";
|
||||
license = licenses.gpl3Plus;
|
||||
platforms = platforms.all;
|
||||
maintainers = [ maintainers.sternenseemann ];
|
||||
};
|
||||
}
|
||||
47
pkgs/development/libraries/ada/gnatcoll/core.nix
Normal file
47
pkgs/development/libraries/ada/gnatcoll/core.nix
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
{ stdenv
|
||||
, lib
|
||||
, gnat
|
||||
, gprbuild
|
||||
, fetchFromGitHub
|
||||
, xmlada
|
||||
, which
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "gnatcoll-core";
|
||||
version = "22.0.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "AdaCore";
|
||||
repo = "gnatcoll-core";
|
||||
rev = "v${version}";
|
||||
sha256 = "0fn28dp6bgpp1sshr09m1x85g2gx11xqkiy410hiicfyg5hamh1l";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
gprbuild
|
||||
which
|
||||
gnat
|
||||
];
|
||||
|
||||
# propagate since gprbuild needs to find
|
||||
# referenced GPR project definitions
|
||||
propagatedBuildInputs = [
|
||||
gprbuild # libgpr
|
||||
];
|
||||
|
||||
makeFlags = [
|
||||
"prefix=${placeholder "out"}"
|
||||
"PROCESSORS=$(NIX_BUILD_CORES)"
|
||||
# confusingly, for gprbuild --target is autoconf --host
|
||||
"TARGET=${stdenv.hostPlatform.config}"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/AdaCore/gnatcoll-core";
|
||||
description = "GNAT Components Collection - Core packages";
|
||||
license = licenses.gpl3Plus;
|
||||
maintainers = [ maintainers.sternenseemann ];
|
||||
platforms = platforms.all;
|
||||
};
|
||||
}
|
||||
110
pkgs/development/libraries/ada/gnatcoll/db.nix
Normal file
110
pkgs/development/libraries/ada/gnatcoll/db.nix
Normal file
|
|
@ -0,0 +1,110 @@
|
|||
{ stdenv
|
||||
, lib
|
||||
, fetchFromGitHub
|
||||
, gnat
|
||||
, gprbuild
|
||||
, which
|
||||
, gnatcoll-core
|
||||
, xmlada
|
||||
, component
|
||||
# components built by this derivation other components depend on
|
||||
, gnatcoll-sql
|
||||
, gnatcoll-sqlite
|
||||
, gnatcoll-xref
|
||||
# component specific extra dependencies
|
||||
, gnatcoll-iconv
|
||||
, gnatcoll-readline
|
||||
, sqlite
|
||||
, postgresql
|
||||
}:
|
||||
|
||||
let
|
||||
libsFor = {
|
||||
gnatcoll_db2ada = [
|
||||
gnatcoll-sql
|
||||
];
|
||||
gnatinspect = [
|
||||
gnatcoll-sqlite
|
||||
gnatcoll-readline
|
||||
gnatcoll-xref
|
||||
];
|
||||
postgres = [
|
||||
gnatcoll-sql
|
||||
postgresql
|
||||
];
|
||||
sqlite = [
|
||||
gnatcoll-sql
|
||||
sqlite
|
||||
];
|
||||
xref = [
|
||||
gnatcoll-iconv
|
||||
gnatcoll-sqlite
|
||||
];
|
||||
};
|
||||
|
||||
# These components are just tools and don't install a library
|
||||
onlyExecutable = builtins.elem component [
|
||||
"gnatcoll_db2ada"
|
||||
"gnatinspect"
|
||||
];
|
||||
in
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "gnatcoll-${component}";
|
||||
version = "22.0.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "AdaCore";
|
||||
repo = "gnatcoll-db";
|
||||
rev = "v${version}";
|
||||
sha256 = "1c39yg13faadg5mzpq3s83rn24npmpc4yjj0cvj7kqwpqxci4m55";
|
||||
};
|
||||
|
||||
patches = lib.optionals (component == "sqlite") [
|
||||
# fixes build of the static sqlite component
|
||||
# when building against the system libsqlite3
|
||||
# See https://github.com/AdaCore/gprbuild/issues/27#issuecomment-298444608
|
||||
./gnatcoll-db-sqlite-static-external.patch
|
||||
];
|
||||
|
||||
# Link executables dynamically unless specified by the platform,
|
||||
# as we usually do in nixpkgs where possible
|
||||
postPatch = lib.optionalString (!stdenv.hostPlatform.isStatic) ''
|
||||
for f in gnatcoll_db2ada/Makefile gnatinspect/Makefile; do
|
||||
substituteInPlace "$f" --replace "=static" "=relocatable"
|
||||
done
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [
|
||||
gnat
|
||||
gprbuild
|
||||
which
|
||||
];
|
||||
|
||||
# Propagate since GPRbuild needs to find referenced .gpr files
|
||||
# and other libraries to link against when static linking is used.
|
||||
# For executables this is of course not relevant and we can reduce
|
||||
# the closure size dramatically
|
||||
${if onlyExecutable then "buildInputs" else "propagatedBuildInputs"} = [
|
||||
gnatcoll-core
|
||||
] ++ libsFor."${component}" or [];
|
||||
|
||||
makeFlags = [
|
||||
"-C" component
|
||||
"PROCESSORS=$(NIX_BUILD_CORES)"
|
||||
# confusingly, for gprbuild --target is autoconf --host
|
||||
"TARGET=${stdenv.hostPlatform.config}"
|
||||
"prefix=${placeholder "out"}"
|
||||
] ++ lib.optional (component == "sqlite") [
|
||||
# link against packaged, not vendored libsqlite3
|
||||
"GNATCOLL_SQLITE=external"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "GNAT Components Collection - Database packages";
|
||||
homepage = "https://github.com/AdaCore/gnatcoll-db";
|
||||
license = licenses.gpl3Plus;
|
||||
maintainers = [ maintainers.sternenseemann ];
|
||||
platforms = platforms.all;
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
diff --git a/sqlite/gnatcoll_sqlite.gpr b/sqlite/gnatcoll_sqlite.gpr
|
||||
index 5bd53d35..580739f8 100644
|
||||
--- a/sqlite/gnatcoll_sqlite.gpr
|
||||
+++ b/sqlite/gnatcoll_sqlite.gpr
|
||||
@@ -69,7 +69,12 @@ project GnatColl_Sqlite is
|
||||
for Source_Dirs use (".", "amalgamation");
|
||||
when "external" =>
|
||||
for Source_Dirs use (".");
|
||||
- for Library_Options use ("-lsqlite3") & Thread_Lib;
|
||||
+ case Library_Type is
|
||||
+ when "relocatable" =>
|
||||
+ for Library_Options use ("-lsqlite3") & Thread_Lib;
|
||||
+ when others =>
|
||||
+ null;
|
||||
+ end case;
|
||||
end case;
|
||||
|
||||
package Compiler is
|
||||
|
|
@ -0,0 +1,23 @@
|
|||
commit 37c815ee660d1bf37256638d23b0346ad7cc19e7
|
||||
Author: sternenseemann <0rpkxez4ksa01gb3typccl0i@systemli.org>
|
||||
Date: Wed Jul 21 00:18:30 2021 +0200
|
||||
|
||||
omp/setup.py: open version_information in text mode
|
||||
|
||||
Otherwise saving the config in setup_support.py will fail as a bytes
|
||||
object is not encodeable as JSON. Luckily, version_information is text
|
||||
anyways.
|
||||
|
||||
diff --git a/omp/setup.py b/omp/setup.py
|
||||
index 942ab1f5..5281398e 100755
|
||||
--- a/omp/setup.py
|
||||
+++ b/omp/setup.py
|
||||
@@ -25,7 +25,7 @@ class GNATCollOMP(SetupApp):
|
||||
|
||||
# Set library version
|
||||
with open(os.path.join(config.source_dir, '..',
|
||||
- 'version_information'), 'rb') as fd:
|
||||
+ 'version_information'), 'r') as fd:
|
||||
version = fd.read().strip()
|
||||
config.set_data('GNATCOLL_VERSION', version, sub='gprbuild')
|
||||
|
||||
35
pkgs/development/libraries/ada/xmlada/default.nix
Normal file
35
pkgs/development/libraries/ada/xmlada/default.nix
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
{ stdenv
|
||||
, lib
|
||||
, fetchFromGitHub
|
||||
, gnat
|
||||
# use gprbuild-boot since gprbuild proper depends
|
||||
# on this xmlada derivation.
|
||||
, gprbuild-boot
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "xmlada";
|
||||
version = "22.0.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
name = "xmlada-${version}-src";
|
||||
owner = "AdaCore";
|
||||
repo = "xmlada";
|
||||
rev = "v${version}";
|
||||
sha256 = "1pg6m0sfc1vwvd18r80jv2vwrsb2qgvyl8jmmrmpbdni0npx0kv3";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
gnat
|
||||
gprbuild-boot
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "XML/Ada: An XML parser for Ada";
|
||||
homepage = "https://github.com/AdaCore/xmlada";
|
||||
maintainers = [ maintainers.sternenseemann ];
|
||||
license = licenses.gpl3Plus;
|
||||
platforms = platforms.all;
|
||||
};
|
||||
}
|
||||
|
||||
52
pkgs/development/libraries/adns/default.nix
Normal file
52
pkgs/development/libraries/adns/default.nix
Normal file
|
|
@ -0,0 +1,52 @@
|
|||
{ stdenv, lib, fetchurl, gnum4 }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "adns";
|
||||
version = "1.6.0";
|
||||
|
||||
src = fetchurl {
|
||||
urls = [
|
||||
"https://www.chiark.greenend.org.uk/~ian/adns/ftp/adns-${version}.tar.gz"
|
||||
"ftp://ftp.chiark.greenend.org.uk/users/ian/adns/adns-${version}.tar.gz"
|
||||
"mirror://gnu/adns/adns-${version}.tar.gz"
|
||||
];
|
||||
sha256 = "1pi0xl07pav4zm2jrbrfpv43s1r1q1y12awgak8k7q41m5jp4hpv";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ gnum4 ];
|
||||
|
||||
configureFlags = lib.optional stdenv.hostPlatform.isStatic "--disable-dynamic";
|
||||
|
||||
preConfigure =
|
||||
lib.optionalString stdenv.isDarwin "sed -i -e 's|-Wl,-soname=$(SHLIBSONAME)||' configure";
|
||||
|
||||
# Autogenerated headers miss interdependencies in Makefile, fail parallel build:
|
||||
# https://debbugs.gnu.org/cgi/bugreport.cgi?bug=51329
|
||||
enableParallelBuilding = false;
|
||||
|
||||
# https://www.mail-archive.com/nix-dev@cs.uu.nl/msg01347.html for details.
|
||||
doCheck = false;
|
||||
|
||||
postInstall = let suffix = lib.versions.majorMinor version;
|
||||
in lib.optionalString stdenv.isDarwin ''
|
||||
install_name_tool -id $out/lib/libadns.so.${suffix} $out/lib/libadns.so.${suffix}
|
||||
'';
|
||||
|
||||
# darwin executables fail, but I don't want to fail the 100-500 packages depending on this lib
|
||||
doInstallCheck = !stdenv.isDarwin;
|
||||
installCheckPhase = ''
|
||||
set -eo pipefail
|
||||
|
||||
for prog in $out/bin/*; do
|
||||
$prog --help > /dev/null && echo $(basename $prog) shows usage
|
||||
done
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "http://www.chiark.greenend.org.uk/~ian/adns/";
|
||||
description = "Asynchronous DNS Resolver Library";
|
||||
license = licenses.lgpl2;
|
||||
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
25
pkgs/development/libraries/adslib/default.nix
Normal file
25
pkgs/development/libraries/adslib/default.nix
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
{ lib, stdenv, fetchFromGitHub }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "adslib";
|
||||
version = "unstable-2020-08-28";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "stlehmann";
|
||||
repo = "ADS";
|
||||
rev = "c457b60d61d73325837ca50be2cc997c4792d481";
|
||||
sha256 = "11r86xa8fr4z957hd0abn8x7182nz30a198d02y7gzpbhpi3z43k";
|
||||
};
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/lib
|
||||
cp adslib.so $out/lib/adslib.so
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Beckhoff protocol to communicate with TwinCAT devices";
|
||||
homepage = "https://github.com/stlehmann/ADS";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ jamiemagee ];
|
||||
};
|
||||
}
|
||||
29
pkgs/development/libraries/afflib/default.nix
Normal file
29
pkgs/development/libraries/afflib/default.nix
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
{ lib, stdenv, fetchFromGitHub, zlib, curl, expat, fuse, openssl
|
||||
, autoreconfHook, python3, libiconv
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
version = "3.7.19";
|
||||
pname = "afflib";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "sshock";
|
||||
repo = "AFFLIBv3";
|
||||
rev = "v${version}";
|
||||
sha256 = "1qs843yi33yqbp0scqirn753lxzg762rz6xy2h3f8f77fijqj2qb";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ autoreconfHook ];
|
||||
buildInputs = [ zlib curl expat openssl python3 ]
|
||||
++ lib.optionals (with stdenv; isLinux || isDarwin) [ fuse ]
|
||||
++ lib.optionals stdenv.isDarwin [ libiconv ];
|
||||
|
||||
meta = {
|
||||
homepage = "http://afflib.sourceforge.net/";
|
||||
description = "Advanced forensic format library";
|
||||
platforms = lib.platforms.unix;
|
||||
license = lib.licenses.bsdOriginal;
|
||||
maintainers = [ lib.maintainers.raskin ];
|
||||
downloadPage = "https://github.com/sshock/AFFLIBv3/tags";
|
||||
};
|
||||
}
|
||||
28
pkgs/development/libraries/aften/default.nix
Normal file
28
pkgs/development/libraries/aften/default.nix
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
{ lib, stdenv, fetchurl, cmake }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "aften";
|
||||
version = "0.0.8";
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/aften/${pname}-${version}.tar.bz2";
|
||||
sha256 = "02hc5x9vkgng1v9bzvza9985ifrjd7fjr7nlpvazp4mv6dr89k47";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Add fallback for missing SIMD functions on ARM
|
||||
# Source https://github.com/Homebrew/homebrew-core/blob/cad412c7fb4b64925f821fcc9ac5f16a2c40f32d/Formula/aften.rb
|
||||
./simd-fallback.patch
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
|
||||
cmakeFlags = [ "-DSHARED=ON" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "An audio encoder which generates compressed audio streams based on ATSC A/52 specification";
|
||||
homepage = "http://aften.sourceforge.net/";
|
||||
license = licenses.lgpl21Only;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ emilytrau ];
|
||||
};
|
||||
}
|
||||
25
pkgs/development/libraries/aften/simd-fallback.patch
Normal file
25
pkgs/development/libraries/aften/simd-fallback.patch
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
From dca9c03930d669233258c114e914a01f7c0aeb05 Mon Sep 17 00:00:00 2001
|
||||
From: jbr79 <jbr79@ef0d8562-5c19-0410-972e-841db63a069c>
|
||||
Date: Wed, 24 Sep 2008 22:02:59 +0000
|
||||
Subject: [PATCH] add fallback function for apply_simd_restrictions() on
|
||||
non-x86/ppc
|
||||
|
||||
git-svn-id: https://aften.svn.sourceforge.net/svnroot/aften@766 ef0d8562-5c19-0410-972e-841db63a069c
|
||||
---
|
||||
libaften/cpu_caps.h | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/libaften/cpu_caps.h b/libaften/cpu_caps.h
|
||||
index b7c6159..4db11f7 100644
|
||||
--- a/libaften/cpu_caps.h
|
||||
+++ b/libaften/cpu_caps.h
|
||||
@@ -26,6 +26,7 @@
|
||||
#include "ppc_cpu_caps.h"
|
||||
#else
|
||||
static inline void cpu_caps_detect(void){}
|
||||
+static inline void apply_simd_restrictions(AftenSimdInstructions *simd_instructions){}
|
||||
#endif
|
||||
|
||||
#endif /* CPU_CAPS_H */
|
||||
--
|
||||
2.24.3 (Apple Git-128)
|
||||
30
pkgs/development/libraries/agda/agda-categories/default.nix
Normal file
30
pkgs/development/libraries/agda/agda-categories/default.nix
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
{ lib, mkDerivation, fetchFromGitHub, standard-library }:
|
||||
|
||||
mkDerivation rec {
|
||||
version = "0.1.7.1";
|
||||
pname = "agda-categories";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "agda";
|
||||
repo = "agda-categories";
|
||||
rev = "v${version}";
|
||||
sha256 = "1acb693ad2nrmnn6jxsyrlkc0di3kk2ksj2w9wnyfxrgvfsil7rn";
|
||||
};
|
||||
|
||||
# Remove this once new version of agda-categories is released which
|
||||
# directly references standard-library-1.7.1
|
||||
postPatch = ''
|
||||
substituteInPlace agda-categories.agda-lib \
|
||||
--replace 'standard-library-1.7' 'standard-library-1.7.1'
|
||||
'';
|
||||
|
||||
buildInputs = [ standard-library ];
|
||||
|
||||
meta = with lib; {
|
||||
inherit (src.meta) homepage;
|
||||
description = "A new Categories library";
|
||||
license = licenses.bsd3;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ alexarice turion ];
|
||||
};
|
||||
}
|
||||
28
pkgs/development/libraries/agda/agda-prelude/default.nix
Normal file
28
pkgs/development/libraries/agda/agda-prelude/default.nix
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
{ lib, mkDerivation, fetchFromGitHub }:
|
||||
|
||||
mkDerivation rec {
|
||||
version = "compat-2.6.2";
|
||||
pname = "agda-prelude";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "UlfNorell";
|
||||
repo = "agda-prelude";
|
||||
rev = version;
|
||||
sha256 = "0j2nip5fbn61fpkm3qz4dlazl4mzdv7qlgw9zm15bkcvaila0h14";
|
||||
};
|
||||
|
||||
preConfigure = ''
|
||||
cd test
|
||||
make everything
|
||||
mv Everything.agda ..
|
||||
cd ..
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/UlfNorell/agda-prelude";
|
||||
description = "Programming library for Agda";
|
||||
license = lib.licenses.mit;
|
||||
platforms = lib.platforms.unix;
|
||||
maintainers = with maintainers; [ mudri alexarice turion ];
|
||||
};
|
||||
}
|
||||
28
pkgs/development/libraries/agda/agdarsec/default.nix
Normal file
28
pkgs/development/libraries/agda/agdarsec/default.nix
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
{ lib, mkDerivation, fetchFromGitHub
|
||||
, standard-library }:
|
||||
|
||||
mkDerivation rec {
|
||||
pname = "agdarsec";
|
||||
version = "0.4.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "gallais";
|
||||
repo = "agdarsec";
|
||||
rev = "v${version}";
|
||||
sha256 = "02fqkycvicw6m2xsz8p01aq8n3gj2d2gyx8sgj15l46f8434fy0x";
|
||||
};
|
||||
|
||||
everythingFile = "./index.agda";
|
||||
|
||||
includePaths = [ "src" "examples" ];
|
||||
|
||||
buildInputs = [ standard-library ];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://gallais.github.io/agdarsec/";
|
||||
description = "Total Parser Combinators in Agda";
|
||||
license = licenses.gpl3;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ turion ];
|
||||
};
|
||||
}
|
||||
33
pkgs/development/libraries/agda/cubical/default.nix
Normal file
33
pkgs/development/libraries/agda/cubical/default.nix
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
{ lib, mkDerivation, fetchFromGitHub, ghc, glibcLocales }:
|
||||
|
||||
mkDerivation rec {
|
||||
pname = "cubical";
|
||||
version = "0.4prec3e097a";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
repo = pname;
|
||||
owner = "agda";
|
||||
rev = "c3e097a98c84083550fa31101346bd42a0501add";
|
||||
sha256 = "101cni2a9xvia1mglb94z61jm8xk9r5kc1sn44cri0qsmk1zbqxs";
|
||||
};
|
||||
|
||||
LC_ALL = "en_US.UTF-8";
|
||||
|
||||
preConfigure = ''export AGDA_EXEC=agda'';
|
||||
|
||||
# The cubical library has several `Everything.agda` files, which are
|
||||
# compiled through the make file they provide.
|
||||
nativeBuildInputs = [ ghc glibcLocales ];
|
||||
buildPhase = ''
|
||||
make
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description =
|
||||
"A cubical type theory library for use with the Agda compiler";
|
||||
homepage = src.meta.homepage;
|
||||
license = licenses.mit;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ alexarice ryanorendorff ];
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
{ fetchFromGitHub, lib, mkDerivation, standard-library }:
|
||||
|
||||
mkDerivation rec {
|
||||
version = "0.4";
|
||||
pname = "functional-linear-algebra";
|
||||
|
||||
buildInputs = [ standard-library ];
|
||||
|
||||
src = fetchFromGitHub {
|
||||
repo = "functional-linear-algebra";
|
||||
owner = "ryanorendorff";
|
||||
rev = "v${version}";
|
||||
sha256 = "05jk3792k9xf8iiwzm2hwlvd25f2pqqr3gppmqjf8xb9199i8fk0";
|
||||
};
|
||||
|
||||
preConfigure = ''
|
||||
sh generate-everything.sh
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/ryanorendorff/functional-linear-algebra";
|
||||
description = ''
|
||||
Formalizing linear algebra in Agda by representing matrices as functions
|
||||
from one vector space to another.
|
||||
'';
|
||||
license = licenses.bsd3;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ ryanorendorff ];
|
||||
};
|
||||
}
|
||||
33
pkgs/development/libraries/agda/generic/default.nix
Normal file
33
pkgs/development/libraries/agda/generic/default.nix
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
{ lib, mkDerivation, fetchFromGitHub, standard-library }:
|
||||
|
||||
mkDerivation rec {
|
||||
pname = "generic";
|
||||
version = "0.1.0.2";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "effectfully";
|
||||
repo = "Generic";
|
||||
rev = "v${version}";
|
||||
sha256 = "05igsd2gaj6h9bkqwp8llhvn4qvc5gmi03x4fnz096ba8m6x8s3n";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
standard-library
|
||||
];
|
||||
|
||||
preBuild = ''
|
||||
echo "module Everything where" > Everything.agda
|
||||
find src -name '*.agda' | sed -e 's/src\///;s/\//./g;s/\.agda$//;s/^/import /' >> Everything.agda
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
# Remove if a version compatible with agda 2.6.2 is made
|
||||
broken = true;
|
||||
description =
|
||||
"A library for doing generic programming in Agda";
|
||||
homepage = src.meta.homepage;
|
||||
license = licenses.mit;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ alexarice turion ];
|
||||
};
|
||||
}
|
||||
31
pkgs/development/libraries/agda/iowa-stdlib/default.nix
Normal file
31
pkgs/development/libraries/agda/iowa-stdlib/default.nix
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
{ lib, mkDerivation, fetchFromGitHub }:
|
||||
|
||||
mkDerivation (rec {
|
||||
version = "1.5.0";
|
||||
pname = "iowa-stdlib";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "cedille";
|
||||
repo = "ial";
|
||||
rev = "v${version}";
|
||||
sha256 = "0dlis6v6nzbscf713cmwlx8h9n2gxghci8y21qak3hp18gkxdp0g";
|
||||
};
|
||||
|
||||
libraryFile = "";
|
||||
libraryName = "IAL-1.3";
|
||||
|
||||
buildPhase = ''
|
||||
patchShebangs find-deps.sh
|
||||
make
|
||||
'';
|
||||
|
||||
meta = {
|
||||
homepage = "https://github.com/cedille/ial";
|
||||
description = "Agda standard library developed at Iowa";
|
||||
license = lib.licenses.free;
|
||||
platforms = lib.platforms.unix;
|
||||
# broken since Agda 2.6.1
|
||||
broken = true;
|
||||
maintainers = with lib.maintainers; [ alexarice turion ];
|
||||
};
|
||||
})
|
||||
30
pkgs/development/libraries/agda/standard-library/default.nix
Normal file
30
pkgs/development/libraries/agda/standard-library/default.nix
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
{ lib, mkDerivation, fetchFromGitHub, ghcWithPackages, nixosTests }:
|
||||
|
||||
mkDerivation rec {
|
||||
pname = "standard-library";
|
||||
version = "1.7.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
repo = "agda-stdlib";
|
||||
owner = "agda";
|
||||
rev = "v${version}";
|
||||
sha256 = "0khl12jvknsvjsq3l5cbp2b5qlw983qbymi1dcgfz9z0b92si3r0";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ (ghcWithPackages (self : [ self.filemanip ])) ];
|
||||
preConfigure = ''
|
||||
runhaskell GenerateEverything.hs
|
||||
# We will only build/consider Everything.agda, in particular we don't want Everything*.agda
|
||||
# do be copied to the store.
|
||||
rm EverythingSafe.agda
|
||||
'';
|
||||
|
||||
passthru.tests = { inherit (nixosTests) agda; };
|
||||
meta = with lib; {
|
||||
homepage = "https://wiki.portal.chalmers.se/agda/pmwiki.php?n=Libraries.StandardLibrary";
|
||||
description = "A standard library for use with the Agda compiler";
|
||||
license = lib.licenses.mit;
|
||||
platforms = lib.platforms.unix;
|
||||
maintainers = with maintainers; [ jwiegley mudri alexarice turion ];
|
||||
};
|
||||
}
|
||||
64
pkgs/development/libraries/agg/default.nix
Normal file
64
pkgs/development/libraries/agg/default.nix
Normal file
|
|
@ -0,0 +1,64 @@
|
|||
{ lib, stdenv, fetchurl, autoconf, automake, libtool, pkg-config
|
||||
, freetype, SDL, libX11 }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "agg";
|
||||
version = "2.5";
|
||||
src = fetchurl {
|
||||
url = "https://www.antigrain.com/${pname}-${version}.tar.gz";
|
||||
sha256 = "07wii4i824vy9qsvjsgqxppgqmfdxq0xa87i5yk53fijriadq7mb";
|
||||
};
|
||||
nativeBuildInputs = [
|
||||
pkg-config
|
||||
autoconf
|
||||
automake
|
||||
libtool
|
||||
];
|
||||
buildInputs = [
|
||||
freetype
|
||||
SDL
|
||||
] ++ lib.optionals stdenv.isLinux [
|
||||
libX11
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace include/agg_renderer_outline_aa.h \
|
||||
--replace 'line_profile_aa& profile() {' 'const line_profile_aa& profile() {'
|
||||
'';
|
||||
|
||||
# fix build with new automake, from Gentoo ebuild
|
||||
preConfigure = ''
|
||||
sed -i '/^AM_C_PROTOTYPES/d' configure.in
|
||||
sh autogen.sh
|
||||
'';
|
||||
|
||||
configureFlags = [
|
||||
(lib.strings.enableFeature stdenv.isLinux "platform")
|
||||
"--enable-examples=no"
|
||||
] ++ lib.optionals stdenv.isLinux [
|
||||
"--x-includes=${lib.getDev libX11}/include"
|
||||
"--x-libraries=${lib.getLib libX11}/lib"
|
||||
];
|
||||
|
||||
# libtool --tag=CXX --mode=link g++ -g -O2 libexamples.la ../src/platform/X11/libaggplatformX11.la ../src/libagg.la -o alpha_mask2 alpha_mask2.o
|
||||
# libtool: error: cannot find the library 'libexamples.la'
|
||||
enableParallelBuilding = false;
|
||||
|
||||
meta = {
|
||||
description = "High quality rendering engine for C++";
|
||||
|
||||
longDescription = ''
|
||||
Anti-Grain Geometry (AGG) is an Open Source, free of charge
|
||||
graphic library, written in industrially standard C++. The
|
||||
terms and conditions of use AGG are described on The License
|
||||
page. AGG doesn't depend on any graphic API or technology.
|
||||
Basically, you can think of AGG as of a rendering engine that
|
||||
produces pixel images in memory from some vectorial data. But
|
||||
of course, AGG can do much more than that.
|
||||
'';
|
||||
|
||||
license = lib.licenses.gpl2Plus;
|
||||
homepage = "http://www.antigrain.com/";
|
||||
platforms = lib.platforms.unix;
|
||||
};
|
||||
}
|
||||
44
pkgs/development/libraries/alembic/default.nix
Normal file
44
pkgs/development/libraries/alembic/default.nix
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
{ lib, stdenv, fetchFromGitHub, unzip, cmake, openexr, hdf5-threadsafe }:
|
||||
|
||||
stdenv.mkDerivation rec
|
||||
{
|
||||
pname = "alembic";
|
||||
version = "1.8.3";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "alembic";
|
||||
repo = "alembic";
|
||||
rev = version;
|
||||
sha256 = "sha256-QnqUD8KmMDmEZ1REoKN70SwVICOdyGPZsB/lU9nojj4=";
|
||||
};
|
||||
|
||||
outputs = [ "bin" "dev" "out" "lib" ];
|
||||
|
||||
nativeBuildInputs = [ unzip cmake ];
|
||||
buildInputs = [ openexr hdf5-threadsafe ];
|
||||
|
||||
buildPhase = ''
|
||||
cmake -DUSE_HDF5=ON -DCMAKE_INSTALL_PREFIX=$out/ -DUSE_TESTS=OFF .
|
||||
|
||||
mkdir $out
|
||||
mkdir -p $bin/bin
|
||||
mkdir -p $dev/include
|
||||
mkdir -p $lib/lib
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
make install
|
||||
|
||||
mv $out/bin $bin/
|
||||
mv $out/lib $lib/
|
||||
mv $out/include $dev/
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "An open framework for storing and sharing scene data";
|
||||
homepage = "http://alembic.io/";
|
||||
license = licenses.bsd3;
|
||||
platforms = platforms.all;
|
||||
maintainers = [ maintainers.guibou ];
|
||||
};
|
||||
}
|
||||
36
pkgs/development/libraries/alglib/default.nix
Normal file
36
pkgs/development/libraries/alglib/default.nix
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
{ lib, stdenv, fetchurl, cmake, clang }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "alglib3";
|
||||
version = "3.18.0";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://www.alglib.net/translator/re/alglib-${version}.cpp.gpl.tgz";
|
||||
sha256 = "0ag8dvcxzzp9riqvk4lhcbwhvh0lq54lbdnsbyr107rjfi2p1vlq";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
clang
|
||||
];
|
||||
|
||||
patches = [
|
||||
./patch-alglib-CMakeLists.patch
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Numerical analysis and data processing library";
|
||||
homepage = "https://www.alglib.net/";
|
||||
license = lib.licenses.gpl2Plus;
|
||||
maintainers = [ maintainers.paperdigits ];
|
||||
longDescription = ''
|
||||
ALGLIB is a cross-platform numerical analysis and data processing library. It supports several programming languages (C++, C#, Delphi) and several operating systems (Windows and POSIX, including Linux). ALGLIB features include:
|
||||
|
||||
* Data analysis (classification/regression, statistics)
|
||||
* Optimization and nonlinear solvers
|
||||
* Interpolation and linear/nonlinear least-squares fitting
|
||||
* Linear algebra (direct algorithms, EVD/SVD), direct and iterative linear solvers
|
||||
* Fast Fourier Transform and many other algorithms
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,23 @@
|
|||
--- /dev/null
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -0,0 +1,20 @@
|
||||
+cmake_minimum_required(VERSION 2.8)
|
||||
+
|
||||
+project(alglib3 CXX)
|
||||
+
|
||||
+file(GLOB_RECURSE sources src/*.cpp)
|
||||
+file(GLOB_RECURSE headers src/*.h)
|
||||
+
|
||||
+add_library(${PROJECT_NAME} STATIC ${sources} ${headers})
|
||||
+
|
||||
+install(
|
||||
+ TARGETS ${PROJECT_NAME}
|
||||
+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
|
||||
+ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
||||
+)
|
||||
+
|
||||
+install(
|
||||
+ FILES ${headers}
|
||||
+ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/alglib
|
||||
+)
|
||||
32
pkgs/development/libraries/alkimia/default.nix
Normal file
32
pkgs/development/libraries/alkimia/default.nix
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
{ mkDerivation, fetchurl, lib
|
||||
, extra-cmake-modules, doxygen, graphviz, qtbase, qtwebkit, mpir
|
||||
, kdelibs4support, plasma-framework, knewstuff, kpackage
|
||||
}:
|
||||
|
||||
mkDerivation rec {
|
||||
pname = "alkimia";
|
||||
version = "8.1.0";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://kde/stable/alkimia/${version}/${pname}-${version}.tar.xz";
|
||||
sha256 = "sha256-kWgHNScHsEkM3ZymVoLv9zsAylIwKb2m/nonSaG8knw=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ extra-cmake-modules doxygen graphviz ];
|
||||
|
||||
buildInputs = [ qtbase qtwebkit kdelibs4support plasma-framework knewstuff kpackage ];
|
||||
propagatedBuildInputs = [ mpir ];
|
||||
|
||||
meta = {
|
||||
description = "Library used by KDE finance applications";
|
||||
longDescription = ''
|
||||
Alkimia is the infrastructure for common storage and business
|
||||
logic that will be used by all financial applications in KDE.
|
||||
|
||||
The target is to share financial related information over
|
||||
application bounderies.
|
||||
'';
|
||||
license = lib.licenses.lgpl21Plus;
|
||||
platforms = qtbase.meta.platforms;
|
||||
};
|
||||
}
|
||||
45
pkgs/development/libraries/allegro/5.nix
Normal file
45
pkgs/development/libraries/allegro/5.nix
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
{ lib, stdenv, fetchFromGitHub, fetchpatch, texinfo, libXext, xorgproto, libX11
|
||||
, libXpm, libXt, libXcursor, alsa-lib, cmake, zlib, libpng, libvorbis
|
||||
, libXxf86dga, libXxf86misc
|
||||
, libXxf86vm, openal, libGLU, libGL, libjpeg, flac
|
||||
, libXi, libXfixes, freetype, libopus, libtheora
|
||||
, physfs, enet, pkg-config, gtk3, pcre, libpulseaudio, libpthreadstubs
|
||||
, libXdmcp
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "allegro";
|
||||
version = "5.2.7.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "liballeg";
|
||||
repo = "allegro5";
|
||||
rev = version;
|
||||
sha256 = "sha256-JdnzEW+qAhAljR+WfmgE3P9xeR2HvjS64tFgCC0tNA0=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
buildInputs = [
|
||||
texinfo libXext xorgproto libX11 libXpm libXt libXcursor
|
||||
alsa-lib zlib libpng libvorbis libXxf86dga libXxf86misc
|
||||
libXxf86vm openal libGLU libGL
|
||||
libjpeg flac
|
||||
libXi libXfixes
|
||||
enet libtheora freetype physfs libopus pkg-config gtk3 pcre libXdmcp
|
||||
libpulseaudio libpthreadstubs
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
sed -e 's@/XInput2.h@/XI2.h@g' -i CMakeLists.txt "src/"*.c
|
||||
'';
|
||||
|
||||
cmakeFlags = [ "-DCMAKE_SKIP_RPATH=ON" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A game programming library";
|
||||
homepage = "https://liballeg.org/";
|
||||
license = licenses.zlib;
|
||||
maintainers = [ maintainers.raskin ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
38
pkgs/development/libraries/allegro/default.nix
Normal file
38
pkgs/development/libraries/allegro/default.nix
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
{ lib, stdenv, fetchurl, texinfo6_5, libXext, xorgproto, libX11
|
||||
, libXpm, libXt, libXcursor, alsa-lib, cmake, zlib, libpng, libvorbis
|
||||
, libXxf86dga, libXxf86misc
|
||||
, libXxf86vm, openal, libGLU, libGL }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "allegro";
|
||||
version="4.4.3.1";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/liballeg/allegro5/releases/download/${version}/${pname}-${version}.tar.gz";
|
||||
sha256 = "1m6lz35nk07dli26kkwz3wa50jsrxs1kb6w1nj14a911l34xn6gc";
|
||||
};
|
||||
|
||||
patches = [
|
||||
./nix-unstable-sandbox-fix.patch
|
||||
./encoding.patch
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
buildInputs = [
|
||||
texinfo6_5 libXext xorgproto libX11 libXpm libXt libXcursor
|
||||
alsa-lib zlib libpng libvorbis libXxf86dga libXxf86misc
|
||||
libXxf86vm openal libGLU libGL
|
||||
];
|
||||
|
||||
hardeningDisable = [ "format" ];
|
||||
|
||||
cmakeFlags = [ "-DCMAKE_SKIP_RPATH=ON" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A game programming library";
|
||||
homepage = "https://liballeg.org/";
|
||||
license = licenses.free; # giftware
|
||||
maintainers = [ maintainers.raskin ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
10
pkgs/development/libraries/allegro/encoding.patch
Normal file
10
pkgs/development/libraries/allegro/encoding.patch
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
--- allegro-4.4.3/docs/src/allegro._tx.orig 2019-02-02 20:28:46.000000000 +0100
|
||||
+++ allegro-4.4.3/docs/src/allegro._tx 2019-11-04 11:12:39.352699777 +0100
|
||||
@@ -23,6 +23,7 @@
|
||||
@man_shortdesc_force1=allegro
|
||||
@man_shortdesc_force2=Allegro game programming library.
|
||||
@$\input texinfo
|
||||
+@$@documentencoding ISO-8859-1
|
||||
@$@setfilename allegro.inf
|
||||
@$@settitle Allegro Manual
|
||||
@$@setchapternewpage odd
|
||||
|
|
@ -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()
|
||||
21
pkgs/development/libraries/alure/default.nix
Normal file
21
pkgs/development/libraries/alure/default.nix
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
{ lib, stdenv, fetchurl, cmake, openal }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "alure";
|
||||
version = "1.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://kcat.strangesoft.net/alure-releases/alure-${version}.tar.bz2";
|
||||
sha256 = "0w8gsyqki21s1qb2s5ac1kj08i6nc937c0rr08xbw9w9wvd6lpj6";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
buildInputs = [ openal ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A utility library to help manage common tasks with OpenAL applications";
|
||||
homepage = "https://github.com/kcat/alure";
|
||||
license = licenses.mit;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
24
pkgs/development/libraries/alure2/default.nix
Normal file
24
pkgs/development/libraries/alure2/default.nix
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake, openal, libvorbis, opusfile, libsndfile }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "alure2";
|
||||
version = "unstable-2020-02-06";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "kcat";
|
||||
repo = "alure";
|
||||
rev = "50f92fe528e77da82197fd947d1cf9b0a82a0c7d";
|
||||
sha256 = "1gmc1yfhwaj6lik0vn7zv8y23i05f4rw25v2jg34n856jcs02svx";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ];
|
||||
buildInputs = [ openal libvorbis opusfile libsndfile ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A utility library for OpenAL, providing a C++ API and managing common tasks that include file loading, caching, and streaming";
|
||||
homepage = "https://github.com/kcat/alure";
|
||||
license = licenses.zlib;
|
||||
platforms = platforms.linux;
|
||||
maintainers = with maintainers; [ McSinyx ];
|
||||
};
|
||||
}
|
||||
109
pkgs/development/libraries/amdvlk/default.nix
Normal file
109
pkgs/development/libraries/amdvlk/default.nix
Normal file
|
|
@ -0,0 +1,109 @@
|
|||
{ stdenv
|
||||
, lib
|
||||
, fetchRepoProject
|
||||
, writeScript
|
||||
, cmake
|
||||
, ninja
|
||||
, patchelf
|
||||
, perl
|
||||
, pkg-config
|
||||
, python3
|
||||
, expat
|
||||
, libdrm
|
||||
, ncurses
|
||||
, openssl
|
||||
, wayland
|
||||
, xorg
|
||||
, zlib
|
||||
}:
|
||||
let
|
||||
|
||||
suffix = if stdenv.system == "x86_64-linux" then "64" else "32";
|
||||
|
||||
in stdenv.mkDerivation rec {
|
||||
pname = "amdvlk";
|
||||
version = "2022.Q2.2";
|
||||
|
||||
src = fetchRepoProject {
|
||||
name = "${pname}-src";
|
||||
manifest = "https://github.com/GPUOpen-Drivers/AMDVLK.git";
|
||||
rev = "refs/tags/v-${version}";
|
||||
sha256 = "4LV6g2snT1usY+Ic9Hb/IwXAJQ97I9DigZCah6mwewA=";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
expat
|
||||
libdrm
|
||||
ncurses
|
||||
openssl
|
||||
wayland
|
||||
xorg.libX11
|
||||
xorg.libxcb
|
||||
xorg.xcbproto
|
||||
xorg.libXext
|
||||
xorg.libXrandr
|
||||
xorg.libXft
|
||||
xorg.libxshmfence
|
||||
zlib
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
ninja
|
||||
patchelf
|
||||
perl
|
||||
pkg-config
|
||||
python3
|
||||
];
|
||||
|
||||
rpath = lib.makeLibraryPath [
|
||||
libdrm
|
||||
openssl
|
||||
stdenv.cc.cc.lib
|
||||
xorg.libX11
|
||||
xorg.libxcb
|
||||
xorg.libxshmfence
|
||||
];
|
||||
|
||||
cmakeDir = "../drivers/xgl";
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
install -Dm755 -t $out/lib icd/amdvlk${suffix}.so
|
||||
install -Dm644 -t $out/share/vulkan/icd.d icd/amd_icd${suffix}.json
|
||||
install -Dm644 -t $out/share/vulkan/implicit_layer.d icd/amd_icd${suffix}.json
|
||||
|
||||
patchelf --set-rpath "$rpath" $out/lib/amdvlk${suffix}.so
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
# Keep the rpath, otherwise vulkaninfo and vkcube segfault
|
||||
dontPatchELF = true;
|
||||
|
||||
passthru.updateScript = writeScript "update.sh" ''
|
||||
#!/usr/bin/env nix-shell
|
||||
#!nix-shell -i bash -p coreutils curl gnused jq common-updater-scripts
|
||||
|
||||
function setHash() {
|
||||
sed -i "pkgs/development/libraries/amdvlk/default.nix" -e 's,sha256 = "[^'"'"'"]*",sha256 = "'"$1"'",'
|
||||
}
|
||||
|
||||
version="$(curl -sL "https://api.github.com/repos/GPUOpen-Drivers/AMDVLK/releases?per_page=1" | jq '.[0].tag_name | split("-") | .[1]' --raw-output)"
|
||||
sed -i "pkgs/development/libraries/amdvlk/default.nix" -e 's/version = "[^'"'"'"]*"/version = "'"$version"'"/'
|
||||
|
||||
setHash "$(nix-instantiate --eval -A lib.fakeSha256 | xargs echo)"
|
||||
hash="$(nix to-base64 $(nix-build -A amdvlk 2>&1 | tail -n3 | grep 'got:' | cut -d: -f2- | xargs echo || true))"
|
||||
setHash "$hash"
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "AMD Open Source Driver For Vulkan";
|
||||
homepage = "https://github.com/GPUOpen-Drivers/AMDVLK";
|
||||
changelog = "https://github.com/GPUOpen-Drivers/AMDVLK/releases/tag/v-${version}";
|
||||
license = licenses.mit;
|
||||
platforms = [ "x86_64-linux" "i686-linux" ];
|
||||
maintainers = with maintainers; [ Flakebi ];
|
||||
};
|
||||
}
|
||||
24
pkgs/development/libraries/aml/default.nix
Normal file
24
pkgs/development/libraries/aml/default.nix
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
{ lib, stdenv, fetchFromGitHub, meson, pkg-config, ninja }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "aml";
|
||||
version = "0.2.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "any1";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "1m911n3rd41ch4yk3k9k1lz29xp3h54k6jx122abq5kmngy9znqw";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ meson pkg-config ninja ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Another main loop";
|
||||
inherit (src.meta) homepage;
|
||||
license = licenses.isc;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ primeos ];
|
||||
broken = stdenv.isDarwin;
|
||||
};
|
||||
}
|
||||
32
pkgs/development/libraries/amrnb/default.nix
Normal file
32
pkgs/development/libraries/amrnb/default.nix
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
{lib, stdenv, fetchurl, unzip}:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
pname = "amrnb";
|
||||
version = "11.0.0.0";
|
||||
srcAmr = fetchurl {
|
||||
url = "https://www.3gpp.org/ftp/Specs/latest/Rel-11/26_series/26104-b00.zip";
|
||||
sha256 = "1wf8ih0hk7w20vdlnw7jb7w73v15hbxgbvmq4wq7h2ghn0j8ppr3";
|
||||
};
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://www.penguin.cz/~utx/ftp/amr/amrnb-11.0.0.0.tar.bz2";
|
||||
sha256 = "1qgiw02n2a6r32pimnd97v2jkvnw449xrqmaxiivjy2jcr5h141q";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ unzip ];
|
||||
|
||||
configureFlags = [ "--cache-file=config.cache" "--with-downloader=true" ];
|
||||
|
||||
postConfigure = ''
|
||||
cp $srcAmr 26104-b00.zip
|
||||
'';
|
||||
|
||||
meta = {
|
||||
homepage = "http://www.penguin.cz/~utx/amr";
|
||||
description = "AMR Narrow-Band Codec";
|
||||
# The wrapper code is free, but not the libraries from 3gpp.
|
||||
# It's a source code reference implementation with patents and licenses on
|
||||
# some countries, not redistributable.
|
||||
license = lib.licenses.unfree;
|
||||
};
|
||||
}
|
||||
33
pkgs/development/libraries/amrwb/default.nix
Normal file
33
pkgs/development/libraries/amrwb/default.nix
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
{ lib, stdenv, fetchurl, unzip }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "amrwb";
|
||||
version = "11.0.0.0";
|
||||
|
||||
srcAmr = fetchurl {
|
||||
url = "http://www.3gpp.org/ftp/Specs/archive/26_series/26.204/26204-b00.zip";
|
||||
sha256 = "1v4zhs6f1mf1xkrzhljh05890in0rpr5d5pcak9h4igxhd2c91f8";
|
||||
};
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://www.penguin.cz/~utx/ftp/amr/amrwb-${version}.tar.bz2";
|
||||
sha256 = "1p6m9nd08mv525w14py9qzs9zwsa5i3vxf5bgcmcvc408jqmkbsw";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ unzip ];
|
||||
|
||||
configureFlags = [ "--cache-file=config.cache" "--with-downloader=true" ];
|
||||
|
||||
postConfigure = ''
|
||||
cp $srcAmr 26204-b00.zip
|
||||
'';
|
||||
|
||||
meta = {
|
||||
homepage = "http://www.penguin.cz/~utx/amr";
|
||||
description = "AMR Wide-Band Codec";
|
||||
# The wrapper code is free, but not the libraries from 3gpp.
|
||||
# It's a source code reference implementation with patents and licenses on
|
||||
# some countries, not redistributable.
|
||||
license = lib.licenses.unfree;
|
||||
};
|
||||
}
|
||||
61
pkgs/development/libraries/amtk/default.nix
Normal file
61
pkgs/development/libraries/amtk/default.nix
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
{ stdenv
|
||||
, lib
|
||||
, fetchurl
|
||||
, gtk3
|
||||
, meson
|
||||
, ninja
|
||||
, pkg-config
|
||||
, gobject-introspection
|
||||
, gtk-doc
|
||||
, docbook-xsl-nons
|
||||
, gnome
|
||||
, dbus
|
||||
, xvfb-run
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "amtk";
|
||||
version = "5.4.0";
|
||||
|
||||
outputs = [ "out" "dev" "devdoc" ];
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://gnome/sources/${pname}/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
|
||||
sha256 = "g10IUHo96sie91NRzOu0szWv/qNhuIvQ+mZ/QM53enA=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
meson
|
||||
ninja
|
||||
pkg-config
|
||||
dbus
|
||||
gobject-introspection
|
||||
gtk-doc
|
||||
docbook-xsl-nons
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
gtk3
|
||||
];
|
||||
|
||||
doCheck = stdenv.isLinux;
|
||||
checkPhase = ''
|
||||
export NO_AT_BRIDGE=1
|
||||
${xvfb-run}/bin/xvfb-run -s '-screen 0 800x600x24' dbus-run-session \
|
||||
--config-file=${dbus.daemon}/share/dbus-1/session.conf \
|
||||
meson test --print-errorlogs
|
||||
'';
|
||||
|
||||
passthru.updateScript = gnome.updateScript {
|
||||
packageName = pname;
|
||||
versionPolicy = "none";
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://wiki.gnome.org/Projects/Amtk";
|
||||
description = "Actions, Menus and Toolbars Kit for GTK applications";
|
||||
maintainers = [ maintainers.manveru ];
|
||||
license = licenses.lgpl21Plus;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
29
pkgs/development/libraries/apache-activemq/default.nix
Normal file
29
pkgs/development/libraries/apache-activemq/default.nix
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
{ lib, stdenv, fetchurl }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "apache-activemq";
|
||||
version = "5.17.1";
|
||||
|
||||
src = fetchurl {
|
||||
sha256 = "sha256-YX7CUQLMYiUubZsGzElnZq8RbJdSUlW8jEs+de6eAMg=";
|
||||
url = "mirror://apache/activemq/${version}/${pname}-${version}-bin.tar.gz";
|
||||
};
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out
|
||||
mv * $out/
|
||||
for j in `find $out/lib -name "*.jar"`; do
|
||||
cp="''${cp:+"$cp:"}$j";
|
||||
done
|
||||
echo "CLASSPATH=$cp" > $out/lib/classpath.env
|
||||
'';
|
||||
|
||||
meta = {
|
||||
homepage = "https://activemq.apache.org/";
|
||||
description = "Messaging and Integration Patterns server written in Java";
|
||||
sourceProvenance = with lib.sourceTypes; [ binaryBytecode ];
|
||||
license = lib.licenses.asl20;
|
||||
platforms = lib.platforms.unix;
|
||||
};
|
||||
|
||||
}
|
||||
43
pkgs/development/libraries/appindicator-sharp/default.nix
Normal file
43
pkgs/development/libraries/appindicator-sharp/default.nix
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
{
|
||||
autoreconfHook,
|
||||
fetchFromGitHub,
|
||||
lib,
|
||||
libappindicator,
|
||||
mono,
|
||||
gtk-sharp-3_0,
|
||||
pkg-config,
|
||||
stdenv,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "appindicator-sharp";
|
||||
version = "5a79cde93da6d68a4b1373f1ce5796c3c5fe1b37";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "stsundermann";
|
||||
repo = "appindicator-sharp";
|
||||
rev = version;
|
||||
sha256 = "sha256:1i0vqbp05l29f5v9ygp7flm4s05pcnn5ivl578mxmhb51s7ncw6l";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
autoreconfHook
|
||||
mono
|
||||
pkg-config
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
gtk-sharp-3_0
|
||||
libappindicator
|
||||
];
|
||||
|
||||
ac_cv_path_MDOC = "no";
|
||||
installFlagsArray = ["GAPIXMLDIR=/tmp/gapixml"];
|
||||
|
||||
meta = {
|
||||
description = "Bindings for appindicator using gobject-introspection";
|
||||
homepage = "https://github.com/stsundermann/appindicator-sharp";
|
||||
license = lib.licenses.lgpl3Only;
|
||||
maintainers = with lib.maintainers; [ kevincox ];
|
||||
};
|
||||
}
|
||||
41
pkgs/development/libraries/applet-window-buttons/default.nix
Normal file
41
pkgs/development/libraries/applet-window-buttons/default.nix
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
{ lib
|
||||
, mkDerivation
|
||||
, fetchFromGitHub
|
||||
, cmake
|
||||
, extra-cmake-modules
|
||||
, kcoreaddons
|
||||
, kdeclarative
|
||||
, kdecoration
|
||||
, plasma-framework
|
||||
}:
|
||||
|
||||
mkDerivation rec {
|
||||
pname = "applet-window-buttons";
|
||||
version = "0.11.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "psifidotos";
|
||||
repo = "applet-window-buttons";
|
||||
rev = version;
|
||||
hash = "sha256-Qww/22bEmjuq+R3o0UDcS6U+34qjaeSEy+g681/hcfE=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
extra-cmake-modules
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
kcoreaddons
|
||||
kdeclarative
|
||||
kdecoration
|
||||
plasma-framework
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Plasma 5 applet in order to show window buttons in your panels";
|
||||
homepage = "https://github.com/psifidotos/applet-window-buttons";
|
||||
license = licenses.gpl2Plus;
|
||||
maintainers = with maintainers; [ dotlambda ];
|
||||
};
|
||||
}
|
||||
95
pkgs/development/libraries/appstream-glib/default.nix
Normal file
95
pkgs/development/libraries/appstream-glib/default.nix
Normal file
|
|
@ -0,0 +1,95 @@
|
|||
{ lib, stdenv
|
||||
, fetchFromGitHub
|
||||
, substituteAll
|
||||
, docbook_xml_dtd_42
|
||||
, docbook_xsl
|
||||
, fontconfig
|
||||
, freetype
|
||||
, gdk-pixbuf
|
||||
, gettext
|
||||
, glib
|
||||
, gobject-introspection
|
||||
, gperf
|
||||
, gtk-doc
|
||||
, gtk3
|
||||
, json-glib
|
||||
, libarchive
|
||||
, libsoup
|
||||
, libuuid
|
||||
, libxslt
|
||||
, meson
|
||||
, ninja
|
||||
, pkg-config
|
||||
, pngquant
|
||||
}:
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "appstream-glib";
|
||||
version = "0.7.18";
|
||||
|
||||
outputs = [ "out" "dev" "man" "installedTests" ];
|
||||
outputBin = "dev";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "hughsie";
|
||||
repo = "appstream-glib";
|
||||
rev = "${lib.replaceStrings ["-"] ["_"] pname}_${lib.replaceStrings ["."] ["_"] version}";
|
||||
sha256 = "12s7d3nqjs1fldnppbg2mkjg4280f3h8yzj3q1hiz3chh1w0vjbx";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
docbook_xml_dtd_42
|
||||
docbook_xsl
|
||||
gettext
|
||||
gobject-introspection
|
||||
gperf
|
||||
gtk-doc
|
||||
libxslt
|
||||
meson
|
||||
ninja
|
||||
pkg-config
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
fontconfig
|
||||
freetype
|
||||
gdk-pixbuf
|
||||
glib
|
||||
gtk3
|
||||
json-glib
|
||||
libarchive
|
||||
libsoup
|
||||
libuuid
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
glib
|
||||
gdk-pixbuf
|
||||
];
|
||||
|
||||
patches = [
|
||||
(substituteAll {
|
||||
src = ./paths.patch;
|
||||
pngquant = "${pngquant}/bin/pngquant";
|
||||
})
|
||||
];
|
||||
|
||||
mesonFlags = [
|
||||
"-Drpm=false"
|
||||
"-Dstemmer=false"
|
||||
"-Ddep11=false"
|
||||
];
|
||||
|
||||
doCheck = false; # fails at least 1 test
|
||||
|
||||
postInstall = ''
|
||||
moveToOutput "share/installed-tests" "$installedTests"
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Objects and helper methods to read and write AppStream metadata";
|
||||
homepage = "https://people.freedesktop.org/~hughsient/appstream-glib/";
|
||||
license = licenses.lgpl2Plus;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ matthewbauer ];
|
||||
};
|
||||
}
|
||||
11
pkgs/development/libraries/appstream-glib/paths.patch
Normal file
11
pkgs/development/libraries/appstream-glib/paths.patch
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
--- a/libappstream-builder/asb-utils.c
|
||||
+++ b/libappstream-builder/asb-utils.c
|
||||
@@ -294,7 +294,7 @@
|
||||
{
|
||||
g_autofree gchar *standard_error = NULL;
|
||||
gint exit_status = 0;
|
||||
- const gchar *argv[] = { "/usr/bin/pngquant", "--skip-if-larger",
|
||||
+ const gchar *argv[] = { "@pngquant@", "--skip-if-larger",
|
||||
"--strip", "--ext", ".png",
|
||||
"--force", "--speed", "1", filename, NULL };
|
||||
if (!g_file_test (argv[0], G_FILE_TEST_IS_EXECUTABLE))
|
||||
107
pkgs/development/libraries/appstream/default.nix
Normal file
107
pkgs/development/libraries/appstream/default.nix
Normal file
|
|
@ -0,0 +1,107 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, substituteAll
|
||||
, fetchFromGitHub
|
||||
, meson
|
||||
, ninja
|
||||
, pkg-config
|
||||
, gettext
|
||||
, xmlto
|
||||
, docbook-xsl-nons
|
||||
, docbook_xml_dtd_45
|
||||
, libxslt
|
||||
, libstemmer
|
||||
, glib
|
||||
, xapian
|
||||
, libxml2
|
||||
, libxmlb
|
||||
, libyaml
|
||||
, gobject-introspection
|
||||
, pcre
|
||||
, itstool
|
||||
, gperf
|
||||
, vala
|
||||
, curl
|
||||
, nixosTests
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "appstream";
|
||||
version = "0.15.2";
|
||||
# When bumping this package, please also check whether
|
||||
# fix-build-for-qt-olderthan-514.patch still applies by
|
||||
# building libsForQt512.appstream-qt.
|
||||
|
||||
outputs = [ "out" "dev" "installedTests" ];
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "ximion";
|
||||
repo = "appstream";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-/JZ49wjtcInbGUOVVjevVSrLCHcA60FMT165rhfb78Q=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Fix hardcoded paths
|
||||
(substituteAll {
|
||||
src = ./fix-paths.patch;
|
||||
libstemmer_includedir = "${lib.getDev libstemmer}/include";
|
||||
})
|
||||
|
||||
# Allow installing installed tests to a separate output.
|
||||
./installed-tests-path.patch
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
meson
|
||||
ninja
|
||||
pkg-config
|
||||
gettext
|
||||
libxslt
|
||||
xmlto
|
||||
docbook-xsl-nons
|
||||
docbook_xml_dtd_45
|
||||
gobject-introspection
|
||||
itstool
|
||||
vala
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
libstemmer
|
||||
pcre
|
||||
glib
|
||||
xapian
|
||||
libxml2
|
||||
libxmlb
|
||||
libyaml
|
||||
gperf
|
||||
curl
|
||||
];
|
||||
|
||||
mesonFlags = [
|
||||
"-Dapidocs=false"
|
||||
"-Ddocs=false"
|
||||
"-Dvapi=true"
|
||||
"-Dinstalled_test_prefix=${placeholder "installedTests"}"
|
||||
];
|
||||
|
||||
passthru = {
|
||||
tests = {
|
||||
installed-tests = nixosTests.installed-tests.appstream;
|
||||
};
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
description = "Software metadata handling library";
|
||||
longDescription = ''
|
||||
AppStream is a cross-distro effort for building Software-Center applications
|
||||
and enhancing metadata provided by software components. It provides
|
||||
specifications for meta-information which is shipped by upstream projects and
|
||||
can be consumed by other software.
|
||||
'';
|
||||
homepage = "https://www.freedesktop.org/wiki/Distributions/AppStream/";
|
||||
license = licenses.lgpl21Plus;
|
||||
mainProgram = "appstreamcli";
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,43 @@
|
|||
diff --git a/qt/component.h b/qt/component.h
|
||||
index 47abd1f3..74de943c 100644
|
||||
--- a/qt/component.h
|
||||
+++ b/qt/component.h
|
||||
@@ -90,7 +90,7 @@ class APPSTREAMQT_EXPORT Component {
|
||||
UrlKindContact,
|
||||
|
||||
// deprecated
|
||||
- UrlTranslate [[deprecated]] = UrlKindTranslate,
|
||||
+ UrlTranslate = UrlKindTranslate,
|
||||
};
|
||||
Q_ENUM(UrlKind)
|
||||
|
||||
diff --git a/qt/pool.h b/qt/pool.h
|
||||
index b59829b7..5237f613 100644
|
||||
--- a/qt/pool.h
|
||||
+++ b/qt/pool.h
|
||||
@@ -70,9 +70,9 @@ public:
|
||||
FlagMonitor = 1 << 7,
|
||||
|
||||
// deprecated
|
||||
- FlagReadCollection [[deprecated]] = FlagLoadOsCollection,
|
||||
- FlagReadMetainfo [[deprecated]] = FlagLoadOsMetainfo,
|
||||
- FlagReadDesktopFiles [[deprecated]] = FlagLoadOsDesktopFiles,
|
||||
+ FlagReadCollection = FlagLoadOsCollection,
|
||||
+ FlagReadMetainfo = FlagLoadOsMetainfo,
|
||||
+ FlagReadDesktopFiles = FlagLoadOsDesktopFiles,
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -84,9 +84,9 @@ public:
|
||||
* Flags on how caching should be used.
|
||||
**/
|
||||
enum CacheFlags {
|
||||
- CacheFlagNone [[deprecated]] = 0,
|
||||
- CacheFlagUseUser [[deprecated]] = 1 << 0,
|
||||
- CacheFlagUseSystem [[deprecated]] = 1 << 1,
|
||||
+ CacheFlagNone = 0,
|
||||
+ CacheFlagUseUser = 1 << 0,
|
||||
+ CacheFlagUseSystem = 1 << 1,
|
||||
};
|
||||
|
||||
/**
|
||||
32
pkgs/development/libraries/appstream/fix-paths.patch
Normal file
32
pkgs/development/libraries/appstream/fix-paths.patch
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
diff --git a/data/meson.build b/data/meson.build
|
||||
index 53f31cb4..90f40e77 100644
|
||||
--- a/data/meson.build
|
||||
+++ b/data/meson.build
|
||||
@@ -68,7 +68,7 @@ test('as-validate_metainfo.cli',
|
||||
)
|
||||
|
||||
install_data('appstream.conf',
|
||||
- install_dir: get_option('sysconfdir'))
|
||||
+ install_dir: get_option('prefix') / 'etc')
|
||||
|
||||
if get_option('compose')
|
||||
ascompose_metainfo = 'org.freedesktop.appstream.compose.metainfo.xml'
|
||||
diff --git a/meson.build b/meson.build
|
||||
index 2efe86b7..9dc79e28 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -107,12 +107,12 @@ if get_option ('gir')
|
||||
dependency('gobject-introspection-1.0', version: '>=1.56')
|
||||
endif
|
||||
|
||||
-stemmer_inc_dirs = include_directories(['/usr/include'])
|
||||
+stemmer_inc_dirs = include_directories(['@libstemmer_includedir@'])
|
||||
if get_option('stemming')
|
||||
stemmer_lib = cc.find_library('stemmer', required: true)
|
||||
if not cc.has_header('libstemmer.h')
|
||||
if cc.has_header('libstemmer/libstemmer.h')
|
||||
- stemmer_inc_dirs = include_directories('/usr/include/libstemmer')
|
||||
+ stemmer_inc_dirs = include_directories('@libstemmer_includedir@/libstemmer')
|
||||
else
|
||||
error('Unable to find Snowball header "libstemmer.h". Please ensure libstemmer/Snowball is installed properly in order to continue.')
|
||||
endif
|
||||
|
|
@ -0,0 +1,27 @@
|
|||
diff --git a/meson_options.txt b/meson_options.txt
|
||||
index 8dd8e0c7..e2a30b06 100644
|
||||
--- a/meson_options.txt
|
||||
+++ b/meson_options.txt
|
||||
@@ -44,6 +44,11 @@ option('install-docs',
|
||||
value : true,
|
||||
description : 'Install documentation for API and specification'
|
||||
)
|
||||
+option('installed_test_prefix',
|
||||
+ type : 'string',
|
||||
+ value : '',
|
||||
+ description : 'Prefix for installed tests'
|
||||
+)
|
||||
|
||||
#
|
||||
# For development
|
||||
diff --git a/tests/installed-tests/meson.build b/tests/installed-tests/meson.build
|
||||
index 405820ce..f592a753 100644
|
||||
--- a/tests/installed-tests/meson.build
|
||||
+++ b/tests/installed-tests/meson.build
|
||||
@@ -10,5 +10,5 @@ configure_file(
|
||||
output : 'metainfo-validate.test',
|
||||
configuration : itconf,
|
||||
install: true,
|
||||
- install_dir: join_paths('share', 'installed-tests', 'appstream'),
|
||||
+ install_dir: join_paths(get_option('installed_test_prefix'), 'share', 'installed-tests', 'appstream'),
|
||||
)
|
||||
40
pkgs/development/libraries/appstream/qt.nix
Normal file
40
pkgs/development/libraries/appstream/qt.nix
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
{ lib, mkDerivation, appstream, qtbase, qttools, nixosTests }:
|
||||
|
||||
# TODO: look into using the libraries from the regular appstream derivation as we keep duplicates here
|
||||
|
||||
mkDerivation {
|
||||
pname = "appstream-qt";
|
||||
inherit (appstream) version src;
|
||||
|
||||
outputs = [ "out" "dev" "installedTests" ];
|
||||
|
||||
buildInputs = appstream.buildInputs ++ [ appstream qtbase ];
|
||||
|
||||
nativeBuildInputs = appstream.nativeBuildInputs ++ [ qttools ];
|
||||
|
||||
mesonFlags = appstream.mesonFlags ++ [ "-Dqt=true" ];
|
||||
|
||||
patches = (appstream.patches or []) ++ lib.optionals (lib.versionOlder qtbase.version "5.14") [
|
||||
# Fix darwin build for libsForQt5.appstream-qt
|
||||
# Old Qt moc doesn't know about fancy C++14 features
|
||||
# ../qt/component.h:93: Parse error at "UrlTranslate"
|
||||
# Remove both this patch and related comment in default.nix
|
||||
# once Qt 5.14 or later becomes default on darwin
|
||||
./fix-build-for-qt-olderthan-514.patch
|
||||
];
|
||||
|
||||
postFixup = ''
|
||||
sed -i "$dev/lib/cmake/AppStreamQt/AppStreamQtConfig.cmake" \
|
||||
-e "/INTERFACE_INCLUDE_DIRECTORIES/ s@\''${PACKAGE_PREFIX_DIR}@$dev@"
|
||||
'';
|
||||
|
||||
passthru = appstream.passthru // {
|
||||
tests = {
|
||||
installed-tests = nixosTests.installed-tests.appstream-qt;
|
||||
};
|
||||
};
|
||||
|
||||
meta = appstream.meta // {
|
||||
description = "Software metadata handling library - Qt";
|
||||
};
|
||||
}
|
||||
81
pkgs/development/libraries/apr-util/default.nix
Normal file
81
pkgs/development/libraries/apr-util/default.nix
Normal file
|
|
@ -0,0 +1,81 @@
|
|||
{ lib, stdenv, fetchurl, makeWrapper, apr, expat, gnused
|
||||
, sslSupport ? true, openssl
|
||||
, bdbSupport ? true, db
|
||||
, ldapSupport ? !stdenv.isCygwin, openldap
|
||||
, libiconv
|
||||
, cyrus_sasl, autoreconfHook
|
||||
}:
|
||||
|
||||
assert sslSupport -> openssl != null;
|
||||
assert bdbSupport -> db != null;
|
||||
assert ldapSupport -> openldap != null;
|
||||
|
||||
with lib;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "apr-util";
|
||||
version = "1.6.1";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://apache/apr/${pname}-${version}.tar.bz2";
|
||||
sha256 = "0nq3s1yn13vplgl6qfm09f7n0wm08malff9s59bqf9nid9xjzqfk";
|
||||
};
|
||||
|
||||
patches = optional stdenv.isFreeBSD ./include-static-dependencies.patch;
|
||||
|
||||
outputs = [ "out" "dev" ];
|
||||
outputBin = "dev";
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
buildInputs = optional stdenv.isFreeBSD autoreconfHook;
|
||||
|
||||
configureFlags = [ "--with-apr=${apr.dev}" "--with-expat=${expat.dev}" ]
|
||||
++ optional (!stdenv.isCygwin) "--with-crypto"
|
||||
++ optional sslSupport "--with-openssl=${openssl.dev}"
|
||||
++ optional bdbSupport "--with-berkeley-db=${db.dev}"
|
||||
++ optional ldapSupport "--with-ldap=ldap"
|
||||
++ optionals stdenv.isCygwin
|
||||
[ "--without-pgsql" "--without-sqlite2" "--without-sqlite3"
|
||||
"--without-freetds" "--without-berkeley-db" "--without-crypto" ]
|
||||
;
|
||||
|
||||
# For some reason, db version 6.9 is selected when cross-compiling.
|
||||
# It's unclear as to why, it requires someone with more autotools / configure knowledge to go deeper into that.
|
||||
# Always replacing the link flag with a generic link flag seems to help though, so let's do that for now.
|
||||
postConfigure = lib.optionalString (stdenv.buildPlatform != stdenv.hostPlatform) ''
|
||||
substituteInPlace Makefile \
|
||||
--replace "-ldb-6.9" "-ldb"
|
||||
'';
|
||||
|
||||
propagatedBuildInputs = [ apr expat libiconv ]
|
||||
++ optional sslSupport openssl
|
||||
++ optional bdbSupport db
|
||||
++ optional ldapSupport openldap
|
||||
++ optional stdenv.isFreeBSD cyrus_sasl;
|
||||
|
||||
postInstall = ''
|
||||
for f in $out/lib/*.la $out/lib/apr-util-1/*.la $dev/bin/apu-1-config; do
|
||||
substituteInPlace $f \
|
||||
--replace "${expat.dev}/lib" "${expat.out}/lib" \
|
||||
--replace "${db.dev}/lib" "${db.out}/lib" \
|
||||
--replace "${openssl.dev}/lib" "${lib.getLib openssl}/lib"
|
||||
done
|
||||
|
||||
# Give apr1 access to sed for runtime invocations.
|
||||
wrapProgram $dev/bin/apu-1-config --prefix PATH : "${gnused}/bin"
|
||||
'';
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
passthru = {
|
||||
inherit sslSupport bdbSupport ldapSupport;
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://apr.apache.org/";
|
||||
description = "A companion library to APR, the Apache Portable Runtime";
|
||||
maintainers = [ maintainers.eelco ];
|
||||
platforms = platforms.unix;
|
||||
license = licenses.asl20;
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
diff --git a/build/apu-conf.m4 b/build/apu-conf.m4
|
||||
index 8943f10..aa44305 100644
|
||||
--- a/build/apu-conf.m4
|
||||
+++ b/build/apu-conf.m4
|
||||
@@ -279,6 +279,7 @@ AC_ARG_WITH(ldap,[ --with-ldap=library ldap library to use],
|
||||
APU_FIND_LDAPLIB("ldap", "-llber -lresolv -lsocket -lnsl")
|
||||
APU_FIND_LDAPLIB("ldap", "-ldl -lpthread")
|
||||
else
|
||||
+ APU_FIND_LDAPLIB($LIBLDAP, "-llber -lcrypto -lssl -lsasl2")
|
||||
APU_FIND_LDAPLIB($LIBLDAP)
|
||||
APU_FIND_LDAPLIB($LIBLDAP, "-lresolv")
|
||||
APU_FIND_LDAPLIB($LIBLDAP, "-lresolv -lsocket -lnsl")
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue