Merge master into staging-next

This commit is contained in:
Frederik Rietdijk 2020-01-15 09:23:00 +01:00
commit 7119d07624
60 changed files with 1031 additions and 268 deletions

View File

@ -833,6 +833,7 @@ used in `buildPythonPackage`.
- `pythonRemoveBinBytecode` to remove bytecode from the `/bin` folder.
- `setuptoolsBuildHook` to build a wheel using `setuptools`.
- `setuptoolsCheckHook` to run tests with `python setup.py test`.
- `venvShellHook` to source a Python 3 `venv` at the `venvDir` location. A `venv` is created if it does not yet exist.
- `wheelUnpackHook` to move a wheel to the correct folder so it can be installed with the `pipInstallHook`.
### Development mode

View File

@ -1,9 +1,22 @@
.docbook .xref img[src^=images\/callouts\/],
.screen img,
.programlisting img {
.programlisting img,
.literallayout img,
.synopsis img {
width: 1em;
}
.calloutlist img {
width: 1.5em;
}
.prompt,
.screen img,
.programlisting img,
.literallayout img,
.synopsis img {
-moz-user-select: none;
-webkit-user-select: none;
-ms-user-select: none;
user-select: none;
}

56
lib/cli.nix Normal file
View File

@ -0,0 +1,56 @@
{ lib }:
rec {
/* Automatically convert an attribute set to command-line options.
This helps protect against malformed command lines and also to reduce
boilerplate related to command-line construction for simple use cases.
Example:
encodeGNUCommandLine
{ }
{ data = builtins.toJSON { id = 0; };
X = "PUT";
retry = 3;
retry-delay = null;
url = [ "https://example.com/foo" "https://example.com/bar" ];
silent = false;
verbose = true;
};
=> "'-X' 'PUT' '--data' '{\"id\":0}' '--retry' '3' '--url' 'https://example.com/foo' '--url' 'https://example.com/bar' '--verbose'"
*/
encodeGNUCommandLine =
options: attrs: lib.escapeShellArgs (toGNUCommandLine options attrs);
toGNUCommandLine =
{ renderKey ?
key: if builtins.stringLength key == 1 then "-${key}" else "--${key}"
, renderOption ?
key: value:
if value == null
then []
else [ (renderKey key) (builtins.toString value) ]
, renderBool ? key: value: lib.optional value (renderKey key)
, renderList ? key: value: lib.concatMap (renderOption key) value
}:
options:
let
render = key: value:
if builtins.isBool value
then renderBool key value
else if builtins.isList value
then renderList key value
else renderOption key value;
in
builtins.concatLists (lib.mapAttrsToList render options);
}

View File

@ -39,6 +39,7 @@ let
# misc
asserts = callLibs ./asserts.nix;
cli = callLibs ./cli.nix;
debug = callLibs ./debug.nix;
generators = callLibs ./generators.nix;
misc = callLibs ./deprecated.nix;
@ -120,6 +121,7 @@ let
isOptionType mkOptionType;
inherit (asserts)
assertMsg assertOneOf;
inherit (cli) encodeGNUCommandLine toGNUCommandLine;
inherit (debug) addErrorContextToAttrs traceIf traceVal traceValFn
traceXMLVal traceXMLValMarked traceSeq traceSeqN traceValSeq
traceValSeqFn traceValSeqN traceValSeqNFn traceShowVal

View File

@ -441,4 +441,25 @@ runTests {
expected = "«foo»";
};
testRenderOptions = {
expr =
encodeGNUCommandLine
{ }
{ data = builtins.toJSON { id = 0; };
X = "PUT";
retry = 3;
retry-delay = null;
url = [ "https://example.com/foo" "https://example.com/bar" ];
silent = false;
verbose = true;
};
expected = "'-X' 'PUT' '--data' '{\"id\":0}' '--retry' '3' '--url' 'https://example.com/foo' '--url' 'https://example.com/bar' '--verbose'";
};
}

View File

@ -590,7 +590,7 @@ rec {
tail' = tail ts;
in foldl' either head' tail';
# Either value of type `finalType` or `coercedType`, the latter is
# Either value of type `coercedType` or `finalType`, the former is
# converted to `finalType` using `coerceFunc`.
coercedTo = coercedType: coerceFunc: finalType:
assert lib.assertMsg (coercedType.getSubModules == null)
@ -599,12 +599,12 @@ rec {
mkOptionType rec {
name = "coercedTo";
description = "${finalType.description} or ${coercedType.description} convertible to it";
check = x: finalType.check x || (coercedType.check x && finalType.check (coerceFunc x));
check = x: (coercedType.check x && finalType.check (coerceFunc x)) || finalType.check x;
merge = loc: defs:
let
coerceVal = val:
if finalType.check val then val
else coerceFunc val;
if coercedType.check val then coerceFunc val
else val;
in finalType.merge loc (map (def: def // { value = coerceVal def.value; }) defs);
emptyValue = finalType.emptyValue;
getSubOptions = finalType.getSubOptions;

View File

@ -6,7 +6,7 @@
<author><personname><firstname>Eelco</firstname><surname>Dolstra</surname></personname>
<contrib>Author</contrib>
</author>
<copyright><year>2007-2019</year><holder>Eelco Dolstra</holder>
<copyright><year>2007-2020</year><holder>Eelco Dolstra</holder>
</copyright>
</info>
<xi:include href="man-configuration.xml" />

View File

@ -704,7 +704,8 @@ class Machine:
def process_serial_output() -> None:
for _line in self.process.stdout:
line = _line.decode("unicode_escape").replace("\r", "").rstrip()
# Ignore undecodable bytes that may occur in boot menus
line = _line.decode(errors="ignore").replace("\r", "").rstrip()
eprint("{} # {}".format(self.name, line))
self.logger.enqueue({"msg": line, "machine": self.name})

View File

@ -155,7 +155,7 @@ in rec {
--add-flags "''${vms[*]}" \
${lib.optionalString enableOCR
"--prefix PATH : '${ocrProg}/bin:${imagemagick_tiff}/bin'"} \
--run "export testScript=\"\$(cat $out/test-script)\"" \
--run "export testScript=\"\$(${coreutils}/bin/cat $out/test-script)\"" \
--set VLANS '${toString vlans}'
ln -s ${testDriver}/bin/nixos-test-driver $out/bin/nixos-run-vms
wrapProgram $out/bin/nixos-run-vms \

View File

@ -129,18 +129,22 @@ in
# It's useful to have transmission in path, e.g. for remote control
environment.systemPackages = [ pkgs.transmission ];
users.users = optionalAttrs (cfg.user == "transmission") (singleton
{ name = "transmission";
users.users = optionalAttrs (cfg.user == "transmission") ({
transmission = {
name = "transmission";
group = cfg.group;
uid = config.ids.uids.transmission;
description = "Transmission BitTorrent user";
home = homeDir;
createHome = true;
};
});
users.groups = optionalAttrs (cfg.group == "transmission") (singleton
{ name = "transmission";
users.groups = optionalAttrs (cfg.group == "transmission") ({
transmission = {
name = "transmission";
gid = config.ids.gids.transmission;
};
});
# AppArmor profile

View File

@ -18,6 +18,17 @@ let
externalRouterAddress = "80.100.100.1";
externalClient2Address = "80.100.100.2";
externalTrackerAddress = "80.100.100.3";
transmissionConfig = { ... }: {
environment.systemPackages = [ pkgs.transmission ];
services.transmission = {
enable = true;
settings = {
dht-enabled = false;
message-level = 3;
};
};
};
in
{
@ -26,33 +37,31 @@ in
maintainers = [ domenkozar eelco rob bobvanderlinden ];
};
nodes =
{ tracker =
{ pkgs, ... }:
{ environment.systemPackages = [ pkgs.transmission ];
nodes = {
tracker = { pkgs, ... }: {
imports = [ transmissionConfig ];
virtualisation.vlans = [ 1 ];
networking.firewall.enable = false;
networking.interfaces.eth1.ipv4.addresses = [
{ address = externalTrackerAddress; prefixLength = 24; }
];
# We need Apache on the tracker to serve the torrents.
services.httpd.enable = true;
services.httpd.adminAddr = "foo@example.org";
services.httpd.documentRoot = "/tmp";
networking.firewall.enable = false;
services.httpd = {
enable = true;
virtualHosts = {
"torrentserver.org" = {
adminAddr = "foo@example.org";
documentRoot = "/tmp";
};
};
};
services.opentracker.enable = true;
services.transmission.enable = true;
services.transmission.settings.dht-enabled = false;
services.transmission.settings.port-forwaring-enabled = false;
};
router =
{ pkgs, nodes, ... }:
{ virtualisation.vlans = [ 1 2 ];
router = { pkgs, nodes, ... }: {
virtualisation.vlans = [ 1 2 ];
networking.nat.enable = true;
networking.nat.internalInterfaces = [ "eth2" ];
networking.nat.externalInterface = "eth1";
@ -75,9 +84,10 @@ in
};
};
client1 =
{ pkgs, nodes, ... }:
{ environment.systemPackages = [ pkgs.transmission pkgs.miniupnpc ];
client1 = { pkgs, nodes, ... }: {
imports = [ transmissionConfig ];
environment.systemPackages = [ pkgs.miniupnpc ];
virtualisation.vlans = [ 2 ];
networking.interfaces.eth0.ipv4.addresses = [];
networking.interfaces.eth1.ipv4.addresses = [
@ -85,29 +95,21 @@ in
];
networking.defaultGateway = internalRouterAddress;
networking.firewall.enable = false;
services.transmission.enable = true;
services.transmission.settings.dht-enabled = false;
services.transmission.settings.message-level = 3;
};
client2 =
{ pkgs, ... }:
{ environment.systemPackages = [ pkgs.transmission ];
client2 = { pkgs, ... }: {
imports = [ transmissionConfig ];
virtualisation.vlans = [ 1 ];
networking.interfaces.eth0.ipv4.addresses = [];
networking.interfaces.eth1.ipv4.addresses = [
{ address = externalClient2Address; prefixLength = 24; }
];
networking.firewall.enable = false;
services.transmission.enable = true;
services.transmission.settings.dht-enabled = false;
services.transmission.settings.port-forwaring-enabled = false;
};
};
testScript =
{ nodes, ... }:
''
testScript = { nodes, ... }: ''
start_all()
# Wait for network and miniupnpd.
@ -159,5 +161,4 @@ in
"cmp /tmp/test.tar.bz2 ${file}"
)
'';
})

View File

@ -39,6 +39,5 @@ stdenv.mkDerivation rec {
license = licenses.bsd3;
maintainers = [ maintainers.goibhniu ];
platforms = platforms.unix;
badPlatforms = [ "x86_64-darwin" ];
};
}

View File

@ -0,0 +1,105 @@
diff a/build_files/cmake/platform/platform_apple.cmake b/build_files/cmake/platform/platform_apple.cmake
--- a/build_files/cmake/platform/platform_apple.cmake
+++ b/build_files/cmake/platform/platform_apple.cmake
@@ -35,7 +35,6 @@ else()
message(STATUS "Using pre-compiled LIBDIR: ${LIBDIR}")
endif()
if(NOT EXISTS "${LIBDIR}/")
- message(FATAL_ERROR "Mac OSX requires pre-compiled libs at: '${LIBDIR}'")
endif()
if(WITH_OPENAL)
@@ -79,7 +78,7 @@ endif()
if(WITH_CODEC_SNDFILE)
set(LIBSNDFILE ${LIBDIR}/sndfile)
set(LIBSNDFILE_INCLUDE_DIRS ${LIBSNDFILE}/include)
- set(LIBSNDFILE_LIBRARIES sndfile FLAC ogg vorbis vorbisenc)
+ set(LIBSNDFILE_LIBRARIES sndfile)
set(LIBSNDFILE_LIBPATH ${LIBSNDFILE}/lib ${LIBDIR}/ffmpeg/lib) # TODO, deprecate
endif()
@@ -90,7 +89,7 @@ if(WITH_PYTHON)
# normally cached but not since we include them with blender
set(PYTHON_INCLUDE_DIR "${LIBDIR}/python/include/python${PYTHON_VERSION}m")
set(PYTHON_EXECUTABLE "${LIBDIR}/python/bin/python${PYTHON_VERSION}m")
- set(PYTHON_LIBRARY ${LIBDIR}/python/lib/libpython${PYTHON_VERSION}m.a)
+ set(PYTHON_LIBRARY "${LIBDIR}/python/lib/libpython${PYTHON_VERSION}m.dylib")
set(PYTHON_LIBPATH "${LIBDIR}/python/lib/python${PYTHON_VERSION}")
# set(PYTHON_LINKFLAGS "-u _PyMac_Error") # won't build with this enabled
else()
@@ -155,10 +154,7 @@ if(WITH_CODEC_FFMPEG)
set(FFMPEG_INCLUDE_DIRS ${FFMPEG}/include)
set(FFMPEG_LIBRARIES
avcodec avdevice avformat avutil
- mp3lame swscale x264 xvidcore
- theora theoradec theoraenc
- vorbis vorbisenc vorbisfile ogg opus
- vpx swresample)
+ swscale swresample)
set(FFMPEG_LIBPATH ${FFMPEG}/lib)
endif()
@@ -199,14 +195,14 @@ if(WITH_OPENCOLLADA)
set(OPENCOLLADA ${LIBDIR}/opencollada)
set(OPENCOLLADA_INCLUDE_DIRS
- ${LIBDIR}/opencollada/include/COLLADAStreamWriter
- ${LIBDIR}/opencollada/include/COLLADABaseUtils
- ${LIBDIR}/opencollada/include/COLLADAFramework
- ${LIBDIR}/opencollada/include/COLLADASaxFrameworkLoader
- ${LIBDIR}/opencollada/include/GeneratedSaxParser
+ ${LIBDIR}/opencollada/include/opencollada/COLLADAStreamWriter
+ ${LIBDIR}/opencollada/include/opencollada/COLLADABaseUtils
+ ${LIBDIR}/opencollada/include/opencollada/COLLADAFramework
+ ${LIBDIR}/opencollada/include/opencollada/COLLADASaxFrameworkLoader
+ ${LIBDIR}/opencollada/include/opencollada/GeneratedSaxParser
)
- set(OPENCOLLADA_LIBPATH ${OPENCOLLADA}/lib)
+ set(OPENCOLLADA_LIBPATH ${OPENCOLLADA}/lib/opencollada)
set(OPENCOLLADA_LIBRARIES
OpenCOLLADASaxFrameworkLoader
-lOpenCOLLADAFramework
@@ -215,7 +211,7 @@ if(WITH_OPENCOLLADA)
-lMathMLSolver
-lGeneratedSaxParser
-lbuffer -lftoa -lUTF
- ${OPENCOLLADA_LIBPATH}/libxml2.a
+ xml2
)
# PCRE is bundled with openCollada
# set(PCRE ${LIBDIR}/pcre)
@@ -276,14 +272,13 @@ if(WITH_BOOST)
endif()
if(WITH_INTERNATIONAL OR WITH_CODEC_FFMPEG)
- set(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -liconv") # boost_locale and ffmpeg needs it !
endif()
if(WITH_OPENIMAGEIO)
set(OPENIMAGEIO ${LIBDIR}/openimageio)
set(OPENIMAGEIO_INCLUDE_DIRS ${OPENIMAGEIO}/include)
set(OPENIMAGEIO_LIBRARIES
- ${OPENIMAGEIO}/lib/libOpenImageIO.a
+ ${OPENIMAGEIO}/lib/libOpenImageIO.dylib
${PNG_LIBRARIES}
${JPEG_LIBRARIES}
${TIFF_LIBRARY}
@@ -306,7 +301,7 @@ endif()
if(WITH_OPENCOLORIO)
set(OPENCOLORIO ${LIBDIR}/opencolorio)
set(OPENCOLORIO_INCLUDE_DIRS ${OPENCOLORIO}/include)
- set(OPENCOLORIO_LIBRARIES OpenColorIO tinyxml yaml-cpp)
+ set(OPENCOLORIO_LIBRARIES OpenColorIO)
set(OPENCOLORIO_LIBPATH ${OPENCOLORIO}/lib)
endif()
@@ -443,7 +438,7 @@ else()
set(CMAKE_CXX_FLAGS_RELEASE "-mdynamic-no-pic -fno-strict-aliasing")
endif()
-if(${XCODE_VERSION} VERSION_EQUAL 5 OR ${XCODE_VERSION} VERSION_GREATER 5)
+if(FALSE)
# Xcode 5 is always using CLANG, which has too low template depth of 128 for libmv
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -ftemplate-depth=1024")
endif()

View File

@ -1,13 +1,14 @@
{ config, stdenv, lib, fetchurl, boost, cmake, ffmpeg, gettext, glew
, ilmbase, libXi, libX11, libXext, libXrender
, libjpeg, libpng, libsamplerate, libsndfile
, libtiff, libGLU, libGL, openal, opencolorio, openexr, openimageio, openjpeg_1, python3Packages
, libtiff, libGLU, libGL, openal, opencolorio, openexr, openimageio2, openjpeg, python3Packages
, openvdb, libXxf86vm, tbb
, zlib, fftw, opensubdiv, freetype, jemalloc, ocl-icd, addOpenGLRunpath
, jackaudioSupport ? false, libjack2
, cudaSupport ? config.cudaSupport or false, cudatoolkit
, colladaSupport ? true, opencollada
, enableNumpy ? false, makeWrapper
, pugixml, SDL, Cocoa, CoreGraphics, ForceFeedback, OpenAL, OpenGL
}:
with lib;
@ -23,22 +24,53 @@ stdenv.mkDerivation rec {
sha256 = "1zl0ar95qkxsrbqw9miz2hrjijlqjl06vg3clfk9rm7krr2l3b2j";
};
patches = lib.optional stdenv.isDarwin ./darwin.patch;
nativeBuildInputs = [ cmake ] ++ optional cudaSupport addOpenGLRunpath;
buildInputs =
[ boost ffmpeg gettext glew ilmbase
libXi libX11 libXext libXrender
freetype libjpeg libpng libsamplerate libsndfile libtiff libGLU libGL openal
opencolorio openexr openimageio openjpeg_1 python zlib fftw jemalloc
freetype libjpeg libpng libsamplerate libsndfile libtiff
opencolorio openexr openimageio2 openjpeg python zlib fftw jemalloc
(opensubdiv.override { inherit cudaSupport; })
openvdb libXxf86vm tbb
tbb
makeWrapper
]
++ (if (!stdenv.isDarwin) then [
libXi libX11 libXext libXrender
libGLU libGL openal
libXxf86vm
# OpenVDB currently doesn't build on darwin
openvdb
]
else [
pugixml SDL Cocoa CoreGraphics ForceFeedback OpenAL OpenGL
])
++ optional jackaudioSupport libjack2
++ optional cudaSupport cudatoolkit
++ optional colladaSupport opencollada;
postPatch =
''
if stdenv.isDarwin then ''
: > build_files/cmake/platform/platform_apple_xcode.cmake
substituteInPlace source/creator/CMakeLists.txt \
--replace '${"$"}{LIBDIR}/python' \
'${python}'
substituteInPlace build_files/cmake/platform/platform_apple.cmake \
--replace '${"$"}{LIBDIR}/python' \
'${python}' \
--replace '${"$"}{LIBDIR}/opencollada' \
'${opencollada}' \
--replace '${"$"}{PYTHON_LIBPATH}/site-packages/numpy' \
'${python3Packages.numpy}/${python.sitePackages}/numpy' \
--replace 'set(OPENJPEG_INCLUDE_DIRS ' \
'set(OPENJPEG_INCLUDE_DIRS "'$(echo ${openjpeg.dev}/include/openjpeg-*)'") #' \
--replace 'set(OPENJPEG_LIBRARIES ' \
'set(OPENJPEG_LIBRARIES "${openjpeg}/lib/libopenjp2.dylib") #' \
--replace 'set(OPENIMAGEIO ' \
'set(OPENIMAGEIO "${openimageio2.out}") #' \
--replace 'set(OPENEXR_INCLUDE_DIRS ' \
'set(OPENEXR_INCLUDE_DIRS "${openexr.dev}/include/OpenEXR") #'
'' else ''
substituteInPlace extern/clew/src/clew.c --replace '"libOpenCL.so"' '"${ocl-icd}/lib/libOpenCL.so"'
'';
@ -48,7 +80,7 @@ stdenv.mkDerivation rec {
"-DWITH_CODEC_SNDFILE=ON"
"-DWITH_INSTALL_PORTABLE=OFF"
"-DWITH_FFTW3=ON"
#"-DWITH_SDL=ON"
"-DWITH_SDL=OFF"
"-DWITH_OPENCOLORIO=ON"
"-DWITH_OPENSUBDIV=ON"
"-DPYTHON_LIBRARY=${python.libPrefix}m"
@ -61,10 +93,18 @@ stdenv.mkDerivation rec {
"-DWITH_OPENVDB=ON"
"-DWITH_TBB=ON"
"-DWITH_IMAGE_OPENJPEG=ON"
"-DWITH_OPENCOLLADA=${if colladaSupport then "ON" else "OFF"}"
]
++ optionals stdenv.isDarwin [
"-DWITH_CYCLES_OSL=OFF" # requires LLVM
"-DWITH_OPENVDB=OFF" # OpenVDB currently doesn't build on darwin
"-DLIBDIR=/does-not-exist"
]
# Clang doesn't support "-export-dynamic"
++ optional stdenv.cc.isClang "-DPYTHON_LINKFLAGS="
++ optional jackaudioSupport "-DWITH_JACK=ON"
++ optional cudaSupport "-DWITH_CYCLES_CUDA_BINARIES=ON"
++ optional colladaSupport "-DWITH_OPENCOLLADA=ON";
++ optional cudaSupport "-DWITH_CYCLES_CUDA_BINARIES=ON";
NIX_CFLAGS_COMPILE = "-I${ilmbase.dev}/include/OpenEXR -I${python}/include/${python.libPrefix}";
@ -95,7 +135,7 @@ stdenv.mkDerivation rec {
# They comment two licenses: GPLv2 and Blender License, but they
# say: "We've decided to cancel the BL offering for an indefinite period."
license = licenses.gpl2Plus;
platforms = [ "x86_64-linux" ];
platforms = [ "x86_64-linux" "x86_64-darwin" ];
maintainers = [ maintainers.goibhniu ];
};
}

View File

@ -1,46 +1,27 @@
{ stdenv, fetchurl, zlib } :
{ stdenv, fetchFromGitLab, autoreconfHook, zlib }:
let
convert_src = fetchurl {
url = http://m.m.i24.cc/osmconvert.c;
sha256 = "1mvmb171c1jqxrm80jc7qicwk4kgg7yq694n7ci65g6i284r984x";
# version = 0.8.5
};
filter_src = fetchurl {
url = http://m.m.i24.cc/osmfilter.c;
sha256 = "0vm3bls9jb2cb5b11dn82sxnc22qzkf4ghmnkivycigrwa74i6xl";
# version = 1.4.0
};
in
stdenv.mkDerivation {
stdenv.mkDerivation rec {
pname = "osmctools";
version = "0.8.5plus1.4.0";
version = "0.9";
src = fetchFromGitLab {
owner = "osm-c-tools";
repo = pname;
rev = version;
sha256 = "1m8d3r1q1v05pkr8k9czrmb4xjszw6hvgsf3kn9pf0v14gpn4r8f";
};
nativeBuildInputs = [ autoreconfHook ];
buildInputs = [ zlib ];
phases = [ "buildPhase" "installPhase" ];
buildPhase = ''
cc ${convert_src} -lz -O3 -o osmconvert
cc ${filter_src} -O3 -o osmfilter
'';
installPhase = ''
mkdir -p $out/bin
mv osmconvert $out/bin
mv osmfilter $out/bin
'';
meta = with stdenv.lib; {
description = "Command line tools for transforming Open Street Map files";
homepage = [
https://wiki.openstreetmap.org/wiki/Osmconvert
https://wiki.openstreetmap.org/wiki/Osmfilter
https://wiki.openstreetmap.org/wiki/osmconvert
https://wiki.openstreetmap.org/wiki/osmfilter
https://wiki.openstreetmap.org/wiki/osmupdate
];
maintainers = with maintainers; [ sikmir ];
platforms = platforms.unix;
license = licenses.agpl3;
};

View File

@ -2,7 +2,7 @@
let
pname = "Sylk";
version = "2.1.0";
version = "2.5.0";
in
appimageTools.wrapType2 rec {
@ -10,7 +10,7 @@ appimageTools.wrapType2 rec {
src = fetchurl {
url = "http://download.ag-projects.com/Sylk/Sylk-${version}-x86_64.AppImage";
sha256 = "1ifi8qr6f84dcssxhv5ar1s48nsqxiv2j1blc82248hmq5is24mf";
sha256 = "1jhs25zzdac3r2wz886vlpb0bz77p52mdlrbsbv28h6is79pbd69";
};
profile = ''

View File

@ -45,11 +45,11 @@ let
flash = stdenv.mkDerivation rec {
pname = "flashplayer-ppapi";
version = "32.0.0.303";
version = "32.0.0.314";
src = fetchzip {
url = "https://fpdownload.adobe.com/pub/flashplayer/pdc/${version}/flash_player_ppapi_linux.x86_64.tar.gz";
sha256 = "0b2cw8y9rif2p0lyy2ir1v5lchxlsh543b9c743a2p85c9p7q62b";
sha256 = "05xcscpzglpfpiiqc3ngs5snxli99irjk18g5vdhw91jk9808gnl";
stripRoot = false;
};

View File

@ -74,7 +74,7 @@ let
in
stdenv.mkDerivation rec {
pname = "flashplayer";
version = "32.0.0.303";
version = "32.0.0.314";
src = fetchurl {
url =
@ -85,14 +85,14 @@ stdenv.mkDerivation rec {
sha256 =
if debug then
if arch == "x86_64" then
"05hfc5ywmcvp6zf8aqmzjp3qy3byp0zdl0ssrv9gvzcskdqkhsj2"
"076l93wjcy15sic88cyq6msp87gdhcvbk4ym2vbvvjz2bav2z456"
else
"12hl8lvxz648ha70gi3v85mwf0nnayjiaslr669vjan3ww94jymv"
"0kxr8d6fh00akqgk3lwv0z6rk7xswislicsbh9b9p33f19mj7c8a"
else
if arch == "x86_64" then
"0x0mabgswly2v8z13832pkbjsv404aq61pback6sgmp2lyycdg6w"
"0a3hvp0qmqlann8k875ajf0i70cv0an1a3mr8kbgji46dxqvwjxz"
else
"16kbpf1i3aqlrfbfh5ncg1n46ncl9hp6qdp36s5j3ivbc68pj81z";
"0jyywas2z7ssgzng82qgnp01gy6nccqavkbx9529m07xrclvqbxn";
};
nativeBuildInputs = [ unzip ];

View File

@ -50,7 +50,7 @@
stdenv.mkDerivation {
pname = "flashplayer-standalone";
version = "32.0.0.303";
version = "32.0.0.314";
src = fetchurl {
url =
@ -60,9 +60,9 @@ stdenv.mkDerivation {
"https://fpdownload.macromedia.com/pub/flashplayer/updaters/32/flash_player_sa_linux.x86_64.tar.gz";
sha256 =
if debug then
"0xkzlv90lpyy54j6pllknrp1l9vjyh6dsl63l4c8cgh4i830gi14"
"0zlin94rip13rn58m7v5l6m20ylnw59l77rbg5j5qyxkr53zawdz"
else
"0mi3ggv6zhzmdd1h68cgl87n6izhp0pbkhnidd2gl2cp95f23c2d";
"0pfrm02iwa01pqx3adqj0sw27p1ddlz9knjky6x248ak8zywsqr2";
};
nativeBuildInputs = [ unzip ];

View File

@ -1,21 +0,0 @@
# This file was generated by https://github.com/kamilchm/go2nix v1.2.1
[
{
goPackagePath = "github.com/docker/machine";
fetch = {
type = "git";
url = "https://github.com/docker/machine";
rev = "5b274558ea6ca822c06dd407a4e774a0105c3f60";
sha256 = "1wdq9h4bx7awgclh969gvmcnl9jvgv7ldfklnclh5iv47mi7q22d";
};
}
{
goPackagePath = "github.com/zchee/libhyperkit";
fetch = {
type = "git";
url = "https://github.com/zchee/libhyperkit";
rev = "1a19a7693fac32b46ec6cdd22da6fbec974447fc";
sha256 = "119f5gcl24znwnmi837jk667asd3lirx32jldpd4mbyb3sm9nz24";
};
}
]

View File

@ -1,24 +1,36 @@
{ stdenv, buildGoPackage, fetchFromGitHub, pkgconfig, Hypervisor, vmnet }:
{ stdenv, buildGoPackage, fetchFromGitHub, fetchpatch, pkgconfig, cctools, Hypervisor, vmnet }:
buildGoPackage rec {
pname = "docker-machine-xhyve";
version = "0.3.3";
version = "0.4.0";
goPackagePath = "github.com/zchee/docker-machine-driver-xhyve";
goDeps = ./xhyve-deps.nix;
# https://github.com/machine-drivers/docker-machine-driver-xhyve/pull/225
patches = fetchpatch {
url = "https://github.com/machine-drivers/docker-machine-driver-xhyve/commit/546256494bf2ccc33e4125bf45f504b0e3027d5a.patch";
sha256 = "1i8wxqccqkxvqrbsyd0g9s0kdskd8xi2jv0c1bji9aj4rq0a8cgz";
};
preBuild = ''
make -C go/src/${goPackagePath} CC=${stdenv.cc}/bin/cc LIBTOOL=${cctools}/bin/libtool GIT_CMD=: lib9p
export CGO_CFLAGS=-I$(pwd)/go/src/${goPackagePath}/vendor/github.com/jceel/lib9p
export CGO_LDFLAGS=$(pwd)/go/src/${goPackagePath}/vendor/build/lib9p/lib9p.a
'';
buildFlags = "--tags lib9p";
src = fetchFromGitHub {
rev = "v${version}";
owner = "zchee";
owner = "machine-drivers";
repo = "docker-machine-driver-xhyve";
sha256 = "0rj6pyqp4yv4j28bglqjs95rip5i77vv8mrkmqv1rxrsl3i8aqqy";
sha256 = "0000v97fr8xc5b39v44hsa87wrbk4bcwyaaivxv4hxlf4vlgg863";
};
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ Hypervisor vmnet ];
meta = with stdenv.lib; {
homepage = https://github.com/zchee/docker-machine-driver-xhyve;
homepage = https://github.com/machine-drivers/docker-machine-driver-xhyve;
description = "Xhyve driver for docker-machine.";
license = licenses.bsd3;
maintainers = with maintainers; [ periklis ];

View File

@ -8,7 +8,7 @@
let
version = "0.7.1";
version = "0.7.2";
modulesVersion = with lib; versions.major version + "." + versions.minor version;
modulesPath = "lib/SoapySDR/modules" + modulesVersion;
extraPackagesSearchPath = lib.makeSearchPath modulesPath extraPackages;
@ -21,7 +21,7 @@ in stdenv.mkDerivation {
owner = "pothosware";
repo = "SoapySDR";
rev = "soapy-sdr-${version}";
sha256 = "1rbnd3w12kzsh94fiywyn4vch7h0kf75m88fi6nq992b3vnmiwvl";
sha256 = "102wnpjxrwba20pzdh1vvx0yg1h8vqd8z914idxflg9p14r6v5am";
};
nativeBuildInputs = [ cmake makeWrapper pkgconfig ];

View File

@ -0,0 +1,40 @@
{ mkDerivation, haskellPackages, fetchurl, lib }:
mkDerivation rec {
pname = "nota";
version = "1.0";
# Can't use fetchFromGitLab since codes.kary.us doesn't support https
src = fetchurl {
url = "http://codes.kary.us/nota/nota/-/archive/V${version}/nota-V${version}.tar.bz2";
sha256 = "0bbs6bm9p852hvqadmqs428ir7m65h2prwyma238iirv42pk04v8";
};
postUnpack = ''
export sourceRoot=$sourceRoot/source
'';
isLibrary = false;
isExecutable = true;
libraryHaskellDepends = with haskellPackages; [
base
bytestring
array
split
scientific
parsec
ansi-terminal
regex-compat
containers
terminal-size
numbers
text
time
];
description = "The most beautiful command line calculator";
homepage = "https://kary.us/nota";
license = lib.licenses.mpl20;
maintainers = with lib.maintainers; [ dtzWill ];
}

View File

@ -1,11 +1,11 @@
{
"version": "12.6.2",
"repo_hash": "0bchamvr3f0ph49f7xa76gsp2mjj1ajy4q0wy1hjvr9bayxx94av",
"version": "12.6.4",
"repo_hash": "0jsww785bxvjdrp1wsz6zkvx9zr69j24bway6nfyjkz8a7vbl9ls",
"owner": "gitlab-org",
"repo": "gitlab",
"rev": "v12.6.2-ee",
"rev": "v12.6.4-ee",
"passthru": {
"GITALY_SERVER_VERSION": "a4b6c71d4b7c1588587345e2dfe0c6bd7cc63a83",
"GITALY_SERVER_VERSION": "1.77.1",
"GITLAB_PAGES_VERSION": "1.12.0",
"GITLAB_SHELL_VERSION": "10.3.0",
"GITLAB_WORKHORSE_VERSION": "8.18.0"

View File

@ -17,14 +17,14 @@ let
};
};
in buildGoPackage rec {
version = "a4b6c71d4b7c1588587345e2dfe0c6bd7cc63a83";
version = "1.77.1";
pname = "gitaly";
src = fetchFromGitLab {
owner = "gitlab-org";
repo = "gitaly";
rev = version;
sha256 = "1pxmhq1nrc8q2kk83bz5afx14hshqgzqm6j4vgmyjvbmdvgl80wv";
rev = "v${version}";
sha256 = "08xc9lxlvga36yq1wdvb1h4zk70c36qspyd7azhkw84kzwfrif1c";
};
# Fix a check which assumes that hook files are writeable by their

View File

@ -327,7 +327,7 @@ group :metrics do
gem 'influxdb', '~> 0.2', require: false
# Prometheus
gem 'prometheus-client-mmap', '~> 0.9.10'
gem 'prometheus-client-mmap', '~> 0.10.0'
gem 'raindrops', '~> 0.18'
end

View File

@ -531,8 +531,8 @@ GEM
regexp_parser (~> 1.1)
regexp_property_values (~> 0.3)
json (1.8.6)
json-jwt (1.9.4)
activesupport
json-jwt (1.11.0)
activesupport (>= 4.2)
aes_key_wrap
bindata
json-schema (2.8.0)
@ -746,7 +746,7 @@ GEM
parser
unparser
procto (0.0.3)
prometheus-client-mmap (0.9.10)
prometheus-client-mmap (0.10.0)
pry (0.11.3)
coderay (~> 1.1.0)
method_source (~> 0.9.0)
@ -1283,7 +1283,7 @@ DEPENDENCIES
peek (~> 1.1)
pg (~> 1.1)
premailer-rails (~> 1.10.3)
prometheus-client-mmap (~> 0.9.10)
prometheus-client-mmap (~> 0.10.0)
pry-byebug (~> 3.5.1)
pry-rails (~> 0.3.4)
rack (~> 2.0.7)

View File

@ -2326,10 +2326,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "065k7vffdki73f4nz89lxi6wxmcw5dlf593831pgvlbralll6x3r";
sha256 = "18rf9v20i0dk5dblr7m22di959xpch2h7gsx0cl585cryr7apwp3";
type = "gem";
};
version = "1.9.4";
version = "1.11.0";
};
json-schema = {
dependencies = ["addressable"];
@ -3365,10 +3365,10 @@
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0immyg4as0isyj2dcjf44n0avg1jv5kx1qk0asrgb5ayzwmjqg1k";
sha256 = "00d2c79xhz5k3fcclarjr1ffxbrvc6236f4rrvriad9kwqr7c1mp";
type = "gem";
};
version = "0.9.10";
version = "0.10.0";
};
pry = {
dependencies = ["coderay" "method_source"];

View File

@ -1,35 +1,33 @@
{ stdenv, fetchFromGitHub, ninja, nodejs, python3 }:
let
version = "6.2.1";
ocaml-version = "4.06.1";
src = fetchFromGitHub {
owner = "BuckleScript";
repo = "bucklescript";
rev = "${version}";
sha256 = "0zx9nq7cik0c60n3rndqfqy3vdbj5lcrx6zcqcz2d60jjxi1z32y";
fetchSubmodules = true;
};
ocaml = import ./ocaml.nix {
bs-version = version;
# This file is based on https://github.com/turboMaCk/bs-platform.nix/blob/master/build-bs-platform.nix
# to make potential future updates simpler
{ stdenv, fetchFromGitHub, ninja, runCommand, nodejs, python3,
ocaml-version, version, src,
ocaml ? (import ./ocaml.nix {
version = ocaml-version;
inherit stdenv;
src = "${src}/ocaml";
};
in
}),
custom-ninja ? (ninja.overrideAttrs (attrs: {
src = runCommand "ninja-patched-source" {} ''
mkdir -p $out
tar zxvf ${src}/vendor/ninja.tar.gz -C $out
'';
patches = [];
}))
}:
stdenv.mkDerivation {
inherit src version;
pname = "bs-platform";
BS_RELEASE_BUILD = "true";
buildInputs = [ nodejs python3 ];
buildInputs = [ nodejs python3 custom-ninja ];
patchPhase = ''
sed -i 's:./configure.py --bootstrap:python3 ./configure.py --bootstrap:' ./scripts/install.js
mkdir -p ./native/${ocaml-version}/bin
ln -sf ${ocaml}/bin/* ./native/${ocaml-version}/bin
rm -f vendor/ninja/snapshot/ninja.linux
cp ${ninja}/bin/ninja vendor/ninja/snapshot/ninja.linux
cp ${custom-ninja}/bin/ninja vendor/ninja/snapshot/ninja.linux
'';
configurePhase = ''
@ -42,12 +40,9 @@ stdenv.mkDerivation {
installPhase = ''
node scripts/install.js
mkdir -p $out/bin
cp -rf jscomp lib vendor odoc_gen native $out
cp bsconfig.json package.json $out
ln -s $out/lib/bsb $out/bin/bsb
ln -s $out/lib/bsc $out/bin/bsc
ln -s $out/lib/bsrefmt $out/bin/bsrefmt

View File

@ -1,15 +1,28 @@
{ stdenv, fetchFromGitHub, ninja, nodejs, python3, ... }:
{ stdenv, runCommand, fetchFromGitHub, ninja, nodejs, python3, ... }:
let
build-bs-platform = import ./build-bs-platform.nix;
in
(build-bs-platform {
inherit stdenv runCommand fetchFromGitHub ninja nodejs python3;
version = "7.0.1";
ocaml-version = "4.06.1";
src = fetchFromGitHub {
owner = "BuckleScript";
repo = "bucklescript";
rev = "52770839e293ade2bcf187f2639000ca0a9a1d46";
sha256 = "0s7g2zfhshsilv9zyp0246bypg34d294z27alpwz03ws9608yr7k";
fetchSubmodules = true;
};
}).overrideAttrs (attrs: {
meta = with stdenv.lib; {
description = "A JavaScript backend for OCaml focused on smooth integration and clean generated code.";
homepage = https://bucklescript.github.io;
license = licenses.lgpl3;
maintainers = with maintainers; [ turbomack gamb anmonteiro ];
platforms = platforms.all;
# Currently there is an issue with aarch build in hydra
# https://github.com/BuckleScript/bucklescript/issues/4091
badPlatforms = platforms.aarch64;
};
in
{
bs-platform-621 = import ./bs-platform-62.nix {
inherit stdenv fetchFromGitHub ninja nodejs python3;
} // { inherit meta; };
}
})

View File

@ -1,7 +1,7 @@
{ stdenv, src, version, bs-version }:
{ stdenv, src, version }:
stdenv.mkDerivation rec {
inherit src version;
name = "ocaml-${version}+bs-${bs-version}";
name = "ocaml-${version}+bs";
configurePhase = ''
./configure -prefix $out
'';

View File

@ -2,6 +2,9 @@
{ python
, callPackage
, makeSetupHook
, disabledIf
, isPy3k
, ensureNewerSourcesForZipFilesHook
}:
let
@ -109,6 +112,15 @@ in rec {
};
} ./setuptools-check-hook.sh) {};
venvShellHook = disabledIf (!isPy3k) (callPackage ({ }:
makeSetupHook {
name = "venv-shell-hook";
deps = [ ensureNewerSourcesForZipFilesHook ];
substitutions = {
inherit pythonInterpreter;
};
} ./venv-shell-hook.sh) {});
wheelUnpackHook = callPackage ({ wheel }:
makeSetupHook {
name = "wheel-unpack-hook.sh";

View File

@ -0,0 +1,26 @@
venvShellHook() {
echo "Executing venvHook"
runHook preShellHook
if [ -d "${venvDir}" ]; then
echo "Skipping venv creation, '${venvDir}' already exists"
else
echo "Creating new venv environment in path: '${venvDir}'"
@pythonInterpreter@ -m venv "${venvDir}"
fi
source "${venvDir}/bin/activate"
runHook postShellHook
echo "Finished executing venvShellHook"
}
if [ -z "${dontUseVenvShellHook:-}" ] && [ -z "${shellHook-}" ]; then
echo "Using venvShellHook"
if [ -z "${venvDir-}" ]; then
echo "Error: \`venvDir\` should be set when using \`venvShellHook\`."
exit 1
else
shellHook=venvShellHook
fi
fi

View File

@ -1,4 +1,4 @@
{ stdenv, lib, fetchFromGitHub, fetchpatch, cmake, gflags, perl, static ? false }:
{ stdenv, lib, fetchFromGitHub, fetchpatch, cmake, gflags, perl }:
stdenv.mkDerivation rec {
pname = "glog";
@ -30,7 +30,7 @@ stdenv.mkDerivation rec {
propagatedBuildInputs = [ gflags ];
cmakeFlags = [ "-DBUILD_SHARED_LIBS=${if static then "OFF" else "ON"}" ];
cmakeFlags = [ "-DBUILD_SHARED_LIBS=ON" ];
checkInputs = [ perl ];
doCheck = false; # fails with "Mangled symbols (28 out of 380) found in demangle.dm"

View File

@ -6,13 +6,14 @@
stdenv.mkDerivation {
pname = "libvterm-neovim";
version = "2019-10-08";
# Releases are not tagged, look at commit history to find latest release
version = "0.1.3";
src = fetchFromGitHub {
owner = "neovim";
repo = "libvterm";
rev = "7c72294d84ce20da4c27362dbd7fa4b08cfc91da";
sha256 = "111qyxq33x74dwdnqcnzlv9j0n8hxyribd6ppwcsxmyrniyw9qrk";
rev = "65dbda3ed214f036ee799d18b2e693a833a0e591";
sha256 = "0r6yimzbkgrsi9aaxwvxahai2lzgjd1ysblr6m6by5w459853q3n";
};
buildInputs = [ perl ];

View File

@ -1,16 +1,16 @@
{ stdenv, fetchFromGitHub, glibcLocales
, cmake, python3
, cmake, python3, libpng, zlib
}:
stdenv.mkDerivation rec {
pname = "onnxruntime";
version = "1.0.0";
version = "1.1.0";
src = fetchFromGitHub {
owner = "microsoft";
repo = "onnxruntime";
rev = "v${version}";
sha256 = "1d28lzrjnq69yl8j9ncxlsxl0bniacn3hnsr9van10zgp527436v";
sha256 = "1ryf5v2h07c7b42q2p9id88i270ajyz5rlsradp00dy8in6dn2yr";
# TODO: use nix-versions of grpc, onnx, eigen, googletest, etc.
# submodules increase src size and compile times significantly
# not currently feasible due to how integrated cmake build is with git
@ -25,12 +25,19 @@ stdenv.mkDerivation rec {
python3 # for shared-lib or server
];
buildInputs = [
# technically optional, but highly recommended
libpng
zlib
];
cmakeDir = "../cmake";
cmakeFlags = [
"-Donnxruntime_USE_OPENMP=ON"
"-Donnxruntime_BUILD_SHARED_LIB=ON"
"-Donnxruntime_ENABLE_LTO=ON"
# flip back to ON next release
"-Donnxruntime_ENABLE_LTO=OFF" # https://github.com/microsoft/onnxruntime/issues/2828
];
# ContribOpTest.StringNormalizerTest sets locale to en_US.UTF-8"

View File

@ -36,7 +36,7 @@ let
outputs = [ "bin" "dev" "out" "man" ] ++ optional withDocs "doc";
setOutputFlags = false;
separateDebugInfo = stdenv.hostPlatform.isLinux;
separateDebugInfo = stdenv.cc.isGNU;
nativeBuildInputs = [ perl ];
buildInputs = stdenv.lib.optional withCryptodev cryptodev;

View File

@ -0,0 +1,37 @@
{ buildPythonPackage
, fetchFromGitHub
, isPy3k
, lib
# pythonPackages
, pylint-plugin-utils
}:
buildPythonPackage rec {
pname = "pylint-celery";
version = "0.3";
disabled = !isPy3k;
src = fetchFromGitHub {
owner = "PyCQA";
repo = pname;
rev = version;
sha256 = "05fhwraq12c2724pn4py1bjzy5rmsrb1x68zck73nlp5icba6yap";
};
propagatedBuildInputs = [
pylint-plugin-utils
];
# Testing requires a very old version of pylint, incompatible with other dependencies
doCheck = false;
meta = with lib; {
description = "A Pylint plugin to analyze Celery applications";
homepage = "https://github.com/PyCQA/pylint-celery";
license = licenses.gpl2;
maintainers = with maintainers; [
kamadorueda
];
};
}

View File

@ -0,0 +1,39 @@
{ buildPythonPackage
, fetchFromGitHub
, isPy3k
, lib
# pythonPackages
, django
, pylint-plugin-utils
}:
buildPythonPackage rec {
pname = "pylint-django";
version = "2.0.12";
disabled = !isPy3k;
src = fetchFromGitHub {
owner = "PyCQA";
repo = pname;
rev = "v${version}";
sha256 = "0ha06wpqqn5fp5dapgjhsdx3ahh3y62l7k2f3czlrdjmmivgdp9y";
};
propagatedBuildInputs = [
django
pylint-plugin-utils
];
# Testing requires checkout from other repositories
doCheck = false;
meta = with lib; {
description = "A Pylint plugin to analyze Django applications";
homepage = "https://github.com/PyCQA/pylint-django";
license = licenses.gpl2;
maintainers = with maintainers; [
kamadorueda
];
};
}

View File

@ -0,0 +1,36 @@
{ buildPythonPackage
, fetchPypi
, isPy3k
, lib
# pythonPackages
, pylint-plugin-utils
}:
buildPythonPackage rec {
pname = "pylint-flask";
version = "0.6";
disabled = !isPy3k;
src = fetchPypi {
inherit pname version;
sha256 = "05qmwgkpvaa5k05abqjxfbrfk3wpdqb8ph690z7bzxvb47i7vngl";
};
propagatedBuildInputs = [
pylint-plugin-utils
];
# Tests require a very old version of pylint
# also tests are only available at GitHub, with an old release tag
doCheck = false;
meta = with lib; {
description = "A Pylint plugin to analyze Flask applications";
homepage = "https://github.com/jschaf/pylint-flask";
license = licenses.gpl2;
maintainers = with maintainers; [
kamadorueda
];
};
}

View File

@ -0,0 +1,27 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, numpy
, pytest
}:
buildPythonPackage rec {
pname = "pynrrd";
version = "0.4.2";
src = fetchFromGitHub {
owner = "mhe";
repo = pname;
rev = "v${version}";
sha256 = "1wn3ara3i19fi1y9a5j4imyczpa6dkkzd5djggxg4kkl1ff9awrj";
};
propagatedBuildInputs = [ numpy ];
meta = with lib; {
homepage = https://github.com/mhe/pynrrd;
description = "Simple pure-Python reader for NRRD files";
license = licenses.mit;
maintainers = with maintainers; [ bcdarwin ];
};
}

View File

@ -4,6 +4,7 @@
, lib
# pythonPackages
, astroid
, pytest
}:
@ -13,12 +14,16 @@ buildPythonPackage rec {
disabled = isPy27;
src = fetchFromGitHub {
owner = "yuvadm";
owner = "landscapeio";
repo = pname;
rev = version;
sha256 = "15s0n1lhkz0zwi33waqkkjipal3f7s45rxsj1bw89xpr4dj87qx5";
sha256 = "1sfmm7daz0kpdx6pynsvi6qlfhrzxx783l1wb69c8dfzya4xssym";
};
propagatedBuildInputs = [
astroid
];
checkInputs = [
pytest
];

View File

@ -13,6 +13,7 @@
, pyramid
, rq
, sanic
, sqlalchemy
, stdenv
, tornado
, urllib3
@ -27,7 +28,7 @@ buildPythonPackage rec {
sha256 = "c6b919623e488134a728f16326c6f0bcdab7e3f59e7f4c472a90eea4d6d8fe82";
};
checkInputs = [ django flask tornado bottle rq falcon ]
checkInputs = [ django flask tornado bottle rq falcon sqlalchemy ]
++ stdenv.lib.optionals isPy3k [ celery pyramid sanic aiohttp ];
propagatedBuildInputs = [ urllib3 certifi ];

View File

@ -311,7 +311,6 @@ let
rgdal = [ pkgs.proj.dev pkgs.gdal ];
rgeos = [ pkgs.geos ];
rggobi = [ pkgs.ggobi pkgs.gtk2.dev pkgs.libxml2.dev ];
rgl = [ pkgs.libGLU pkgs.libGL pkgs.xlibsWrapper ];
Rglpk = [ pkgs.glpk ];
RGtk2 = [ pkgs.gtk2.dev ];
rhdf5 = [ pkgs.zlib ];
@ -404,6 +403,7 @@ let
RCurl = [ pkgs.curl.dev ];
R2SWF = [ pkgs.pkgconfig ];
rggobi = [ pkgs.pkgconfig ];
rgl = [ pkgs.libGLU pkgs.libGLU.dev pkgs.libGL pkgs.xlibsWrapper ];
RGtk2 = [ pkgs.pkgconfig ];
RProtoBuf = [ pkgs.pkgconfig ];
Rpoppler = [ pkgs.pkgconfig ];

View File

@ -0,0 +1,74 @@
{ lib
, pkgs
, python
}:
let
py = python.override {
packageOverrides = self: super: {
pep8-naming = super.pep8-naming.overridePythonAttrs(oldAttrs: rec {
version = "0.4.1";
src = oldAttrs.src.override {
inherit version;
sha256 = "0nhf8p37y008shd4f21bkj5pizv8q0l8cpagyyb8gr059d6gvvaf";
};
});
};
};
setoptconf = py.pkgs.callPackage ./setoptconf.nix { };
in
with py.pkgs;
buildPythonApplication rec {
pname = "prospector";
version = "1.2.0";
disabled = isPy27;
src = pkgs.fetchFromGitHub {
owner = "PyCQA";
repo = pname;
rev = version;
sha256 = "07kb37zrrsriqzcmli0ghx7qb1iwkzh83qsiikl9jy50faby2sjg";
};
checkInputs = [
pytest
];
checkPhase = ''
pytest
'';
patchPhase = ''
substituteInPlace setup.py \
--replace 'pycodestyle<=2.4.0' 'pycodestyle<=2.5.0'
'';
propagatedBuildInputs = [
astroid
django
dodgy
mccabe
pep8-naming
pycodestyle
pydocstyle
pyflakes
pylint
pylint-celery
pylint-django
pylint-flask
pyyaml
requirements-detector
setoptconf
];
meta = with lib; {
description = "Tool to analyse Python code and output information about errors, potential problems, convention violations and complexity";
homepage = "https://github.com/PyCQA/prospector";
license = licenses.gpl2;
maintainers = with maintainers; [
kamadorueda
];
};
}

View File

@ -0,0 +1,26 @@
{ buildPythonPackage
, fetchPypi
, lib
}:
buildPythonPackage rec {
pname = "setoptconf";
version = "0.2.0";
src = fetchPypi {
inherit pname version;
sha256 = "177l7j68j751i781bgk6pfhxjj7hwqxzdm2ja5fkywbp0275s2sv";
};
# Base tests provided via PyPi are broken
doCheck = false;
meta = with lib; {
homepage = "https://pypi.org/project/setoptconf";
description = "A module for retrieving program settings from various sources in a consistant method";
license = licenses.mit;
maintainers = with maintainers; [
kamadorueda
];
};
}

View File

@ -33,6 +33,8 @@ let
for gem in "$out"/lib/ruby/gems/*/gems/*; do
cp -a "$gem/" "$gem.new"
rm "$gem"
# needed on macOS, otherwise the mv yields permission denied
chmod +w "$gem.new"
mv "$gem.new" "$gem"
done
'';

View File

@ -5,11 +5,11 @@ let
in stdenv.mkDerivation rec {
name = "${pname}-${version}";
version = "5.2";
version = "5.4";
src = fetchurl {
url = "mirror://sourceforge/project/${pname}/${pname}/${name}/${name}.tar.gz";
sha256 = "0kmavljj3zwpgdib9nb14fnriiv0l9zm3hglimcyz26sxbw5jqky";
sha256 = "19fd9r233wkjk8gdxn6qsjgfijiw67a48xhgbm2kq46bx80yf3pg";
};
preConfigure = ''

View File

@ -0,0 +1,172 @@
From c9b5164c954cd0de80d971f1c4ced16bf41ea81b Mon Sep 17 00:00:00 2001
From: Eric Wong <e@80x24.org>
Date: Fri, 29 Nov 2019 12:25:07 +0000
Subject: [PATCH 2/2] msgtime: drop Date::Parse for RFC2822
Date::Parse is not optimized for RFC2822 dates and isn't
packaged on OpenBSD. It's still useful for historical
email when email clients were less conformant, but is
less relevant for new emails.
---
lib/PublicInbox/MsgTime.pm | 115 ++++++++++++++++++++++++++++++++-----
t/msgtime.t | 6 ++
2 files changed, 107 insertions(+), 14 deletions(-)
diff --git a/lib/PublicInbox/MsgTime.pm b/lib/PublicInbox/MsgTime.pm
index 58e11d72..e9b27a49 100644
--- a/lib/PublicInbox/MsgTime.pm
+++ b/lib/PublicInbox/MsgTime.pm
@@ -7,24 +7,114 @@ use strict;
use warnings;
use base qw(Exporter);
our @EXPORT_OK = qw(msg_timestamp msg_datestamp);
-use Date::Parse qw(str2time strptime);
+use Time::Local qw(timegm);
+my @MoY = qw(january february march april may june
+ july august september october november december);
+my %MoY;
+@MoY{@MoY} = (0..11);
+@MoY{map { substr($_, 0, 3) } @MoY} = (0..11);
+
+my %OBSOLETE_TZ = ( # RFC2822 4.3 (Obsolete Date and Time)
+ EST => '-0500', EDT => '-0400',
+ CST => '-0600', CDT => '-0500',
+ MST => '-0700', MDT => '-0600',
+ PST => '-0800', PDT => '-0700',
+ UT => '+0000', GMT => '+0000', Z => '+0000',
+
+ # RFC2822 states:
+ # The 1 character military time zones were defined in a non-standard
+ # way in [RFC822] and are therefore unpredictable in their meaning.
+);
+my $OBSOLETE_TZ = join('|', keys %OBSOLETE_TZ);
sub str2date_zone ($) {
my ($date) = @_;
+ my ($ts, $zone);
+
+ # RFC822 is most likely for email, but we can tolerate an extra comma
+ # or punctuation as long as all the data is there.
+ # We'll use '\s' since Unicode spaces won't affect our parsing.
+ # SpamAssassin ignores commas and redundant spaces, too.
+ if ($date =~ /(?:[A-Za-z]+,?\s+)? # day-of-week
+ ([0-9]+),?\s+ # dd
+ ([A-Za-z]+)\s+ # mon
+ ([0-9]{2,})\s+ # YYYY or YY (or YYY :P)
+ ([0-9]+)[:\.] # HH:
+ ((?:[0-9]{2})|(?:\s?[0-9])) # MM
+ (?:[:\.]((?:[0-9]{2})|(?:\s?[0-9])))? # :SS
+ \s+ # a TZ offset is required:
+ ([\+\-])? # TZ sign
+ [\+\-]* # I've seen extra "-" e.g. "--500"
+ ([0-9]+|$OBSOLETE_TZ)(?:\s|$) # TZ offset
+ /xo) {
+ my ($dd, $m, $yyyy, $hh, $mm, $ss, $sign, $tz) =
+ ($1, $2, $3, $4, $5, $6, $7, $8);
+ # don't accept non-English months
+ defined(my $mon = $MoY{lc($m)}) or return;
+
+ if (defined(my $off = $OBSOLETE_TZ{$tz})) {
+ $sign = substr($off, 0, 1);
+ $tz = substr($off, 1);
+ }
+
+ # Y2K problems: 3-digit years, follow RFC2822
+ if (length($yyyy) <= 3) {
+ $yyyy += 1900;
+
+ # and 2-digit years from '09 (2009) (0..49)
+ $yyyy += 100 if $yyyy < 1950;
+ }
+
+ $ts = timegm($ss // 0, $mm, $hh, $dd, $mon, $yyyy);
- my $ts = str2time($date);
- return undef unless(defined $ts);
+ # Compute the time offset from [+-]HHMM
+ $tz //= 0;
+ my ($tz_hh, $tz_mm);
+ if (length($tz) == 1) {
+ $tz_hh = $tz;
+ $tz_mm = 0;
+ } elsif (length($tz) == 2) {
+ $tz_hh = 0;
+ $tz_mm = $tz;
+ } else {
+ $tz_hh = $tz;
+ $tz_hh =~ s/([0-9]{2})\z//;
+ $tz_mm = $1;
+ }
+ while ($tz_mm >= 60) {
+ $tz_mm -= 60;
+ $tz_hh += 1;
+ }
+ $sign //= '+';
+ my $off = $sign . ($tz_mm * 60 + ($tz_hh * 60 * 60));
+ $ts -= $off;
+ $sign = '+' if $off == 0;
+ $zone = sprintf('%s%02d%02d', $sign, $tz_hh, $tz_mm);
- # off is the time zone offset in seconds from GMT
- my ($ss,$mm,$hh,$day,$month,$year,$off) = strptime($date);
- return undef unless(defined $off);
+ # Time::Zone and Date::Parse are part of the same distibution,
+ # and we need Time::Zone to deal with tz names like "EDT"
+ } elsif (eval { require Date::Parse }) {
+ $ts = Date::Parse::str2time($date);
+ return undef unless(defined $ts);
- # Compute the time zone from offset
- my $sign = ($off < 0) ? '-' : '+';
- my $hour = abs(int($off / 3600));
- my $min = ($off / 60) % 60;
- my $zone = sprintf('%s%02d%02d', $sign, $hour, $min);
+ # off is the time zone offset in seconds from GMT
+ my ($ss,$mm,$hh,$day,$month,$year,$off) =
+ Date::Parse::strptime($date);
+ return undef unless(defined $off);
+
+ # Compute the time zone from offset
+ my $sign = ($off < 0) ? '-' : '+';
+ my $hour = abs(int($off / 3600));
+ my $min = ($off / 60) % 60;
+
+ $zone = sprintf('%s%02d%02d', $sign, $hour, $min);
+ } else {
+ warn "Date::Parse missing for non-RFC822 date: $date\n";
+ return undef;
+ }
+ # Note: we've already applied the offset to $ts at this point,
+ # but we want to keep "git fsck" happy.
# "-1200" is the furthest westermost zone offset,
# but git fast-import is liberal so we use "-1400"
if ($zone >= 1400 || $zone <= -1400) {
@@ -59,9 +149,6 @@ sub msg_date_only ($) {
my @date = $hdr->header_raw('Date');
my ($ts);
foreach my $d (@date) {
- # Y2K problems: 3-digit years
- $d =~ s!([A-Za-z]{3}) ([0-9]{3}) ([0-9]{2}:[0-9]{2}:[0-9]{2})!
- my $yyyy = $2 + 1900; "$1 $yyyy $3"!e;
$ts = eval { str2date_zone($d) } and return $ts;
if ($@) {
my $mid = $hdr->header_raw('Message-ID');
diff --git a/t/msgtime.t b/t/msgtime.t
index 6b396602..d9643b65 100644
--- a/t/msgtime.t
+++ b/t/msgtime.t
@@ -84,4 +84,10 @@ is_deeply(datestamp('Fri, 28 Jun 2002 12:54:40 -700'), [1025294080, '-0700']);
is_deeply(datestamp('Sat, 12 Jan 2002 12:52:57 -200'), [1010847177, '-0200']);
is_deeply(datestamp('Mon, 05 Nov 2001 10:36:16 -800'), [1004985376, '-0800']);
+# obsolete formats described in RFC2822
+for (qw(UT GMT Z)) {
+ is_deeply(datestamp('Fri, 02 Oct 1993 00:00:00 '.$_), [ 749520000, '+0000']);
+}
+is_deeply(datestamp('Fri, 02 Oct 1993 00:00:00 EDT'), [ 749534400, '-0400']);
+
done_testing();
--
2.24.1

View File

@ -1,4 +1,4 @@
{ buildPerlPackage, lib, fetchurl, makeWrapper
{ buildPerlPackage, lib, fetchurl, fetchpatch, makeWrapper
, DBDSQLite, EmailMIME, IOSocketSSL, IPCRun, Plack, PlackMiddlewareReverseProxy
, SearchXapian, TimeDate, URI
, git, highlight, openssl, xapian
@ -29,6 +29,14 @@ buildPerlPackage rec {
sha256 = "0sa2m4f2x7kfg3mi4im7maxqmqvawafma8f7g92nyfgybid77g6s";
};
patches = [
(fetchpatch {
url = "https://public-inbox.org/meta/20200101032822.GA13063@dcvr/raw";
sha256 = "0ncxqqkvi5lwi8zaa7lk7l8mf8h278raxsvbvllh3z7jhfb48r3l";
})
./0002-msgtime-drop-Date-Parse-for-RFC2822.patch
];
outputs = [ "out" "devdoc" "sa_config" ];
postConfigure = ''

View File

@ -1,12 +1,12 @@
{ stdenv, lib, python, fetchFromGitHub, installShellFiles }:
let
version = "2.0.79";
version = "2.0.80";
src = fetchFromGitHub {
owner = "Azure";
repo = "azure-cli";
rev = "azure-cli-${version}";
sha256 = "0fzpq5fnqxkjghsjk4hi3jng5lgywpvj3fzb5sb7nb7ymvkvhad2";
sha256 = "05j74cfxjpi3w79w0i5av3h2m81bavbsc581vvh773ixivndds1k";
};
# put packages that needs to be overriden in the py package scope

View File

@ -207,8 +207,8 @@ let
azure-mgmt-authorization = overrideAzureMgmtPackage super.azure-mgmt-authorization "0.52.0" "zip"
"0357laxgldb7lvvws81r8xb6mrq9dwwnr1bnwdnyj4bw6p21i9hn";
azure-mgmt-storage = overrideAzureMgmtPackage super.azure-mgmt-storage "7.0.0" "zip"
"01f17fb1myskj72zarc67i1sxfvk66lid9zn12gwjrz2vqc6npkz";
azure-mgmt-storage = overrideAzureMgmtPackage super.azure-mgmt-storage "7.1.0" "zip"
"03yjvw1dwkwsadsv60i625mr9zpdryy7ywvh7p8fg60djszh1p5l";
azure-mgmt-servicefabric = overrideAzureMgmtPackage super.azure-mgmt-servicefabric "0.2.0" "zip"
"1bcq6fcgrsvmk6q7v8mxzn1180jm2qijdqkqbv1m117zp1wj5gxj";

View File

@ -2,16 +2,16 @@
buildGoModule rec {
pname = "eksctl";
version = "0.11.1";
version = "0.12.0";
src = fetchFromGitHub {
owner = "weaveworks";
repo = pname;
rev = version;
sha256 = "197lf6cb1maam1yxy29wgp4dkakaavmwqvq2d9i4qxhscalrdra5";
sha256 = "1m4hcj2bi9v3ngjj2x1fifcnb450jrij06vbi3j28slsdwn1bcc8";
};
modSha256 = "04ba3dyfwlf0m6kn7yp7qyp3h2qdwp17y1f9pa79y3c6sd2nadk2";
modSha256 = "1c8qyxzfazgw77rlv3yw2x39ymaq66jjd51im0jl4131a6hzj6fd";
subPackages = [ "cmd/eksctl" ];

View File

@ -35,11 +35,14 @@ python3Packages.buildPythonApplication rec {
#
# Still missing these tools: abootimg docx2txt dumpxsb enjarify js-beautify lipo oggDump otool procyon-decompiler Rscript wasm2wat zipnode
# Also these libraries: python3-guestfs
pythonPath = with python3Packages; [ debian libarchive-c python_magic tlsh rpm pyxattr ] ++ [
acl binutils-unwrapped bzip2 cdrkit colordiff coreutils cpio db diffutils
pythonPath = [
binutils-unwrapped bzip2 colordiff coreutils cpio db diffutils
dtc e2fsprogs file findutils fontforge-fonttools gettext gnutar gzip
libarchive libcaca lz4 pgpdump progressbar33 sng sqlite squashfsTools unzip xxd xz
] ++ lib.optionals enableBloat [
libarchive libcaca lz4 pgpdump sng sqlite squashfsTools unzip xxd xz
]
++ (with python3Packages; [ debian libarchive-c python_magic tlsh rpm progressbar33 ])
++ lib.optionals stdenv.isLinux [ python3Packages.pyxattr acl cdrkit ]
++ lib.optionals enableBloat [
apktool cbfstool colord fpc ghc ghostscriptX giflib gnupg gnumeric imagemagick
llvm jdk mono openssh pdftk poppler_utils tcpdump unoconv
python3Packages.guestfs
@ -69,6 +72,6 @@ python3Packages.buildPythonApplication rec {
homepage = https://wiki.debian.org/ReproducibleBuilds;
license = licenses.gpl3Plus;
maintainers = with maintainers; [ dezgeg ];
platforms = platforms.linux;
platforms = platforms.unix;
};
}

View File

@ -5,13 +5,13 @@
stdenv.mkDerivation rec {
pname = "snapper";
version = "0.8.7";
version = "0.8.8";
src = fetchFromGitHub {
owner = "openSUSE";
repo = "snapper";
rev = "v${version}";
sha256 = "0605j4f3plb6q8lwf82y2jhply6dwj49jgxk8j16wsbf5k7lqzfq";
sha256 = "0wpf82xf61r9r20whhb83wk3408wac1if8awqm3bb36b9j7ni5jr";
};
nativeBuildInputs = [

View File

@ -2,16 +2,16 @@
rustPlatform.buildRustPackage rec {
pname = "bandwhich";
version = "0.8.0";
version = "0.9.0";
src = fetchFromGitHub {
owner = "imsnif";
repo = pname;
rev = version;
sha256 = "1pd0hy17knalq4m5517ymbg95fa141843ir9283djlh3iqfgkm37";
sha256 = "0gjk84a4ks5107vrchwwnslpbcrprmznjy3sqn2mrwfvw5biycb3";
};
cargoSha256 = "14mb6rbjxv3r8awvy0rjc23lyhg92q1q1dik6q1za1aq9w8yipwf";
cargoSha256 = "1sa81570cvvpqgdcpnb08b0q4c6ap8a2wxfp2z336jzbv0zgv8a6";
buildInputs = stdenv.lib.optional stdenv.isDarwin Security;

View File

@ -111,6 +111,12 @@ let
'' + stdenv.lib.optionalString stdenv.isDarwin ''
# 'pass edit' uses hdid, which is not available from the sandbox.
rm -f tests/t0200-edit-tests.sh
rm -f tests/t0010-generate-tests.sh
rm -f tests/t0020-show-tests.sh
rm -f tests/t0050-mv-tests.sh
rm -f tests/t0100-insert-tests.sh
rm -f tests/t0300-reencryption.sh
rm -f tests/t0400-grep.sh
'';
doCheck = false;

View File

@ -2,26 +2,28 @@
rustPlatform.buildRustPackage rec {
pname = "mdcat";
version = "0.14.0";
version = "0.15.0";
src = fetchFromGitHub {
owner = "lunaryorn";
repo = pname;
rev = "mdcat-${version}";
sha256 = "1q8h6pc1i89j1zl4s234inl9v95vsdrry1fzlis89sl2mnbv8ywy";
sha256 = "1x9c3cj3y8wvwr74kbz6nrdh61rinr98gcp3hnjpi6c3vg3xx4wh";
};
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ openssl ] ++ stdenv.lib.optional stdenv.isDarwin Security;
cargoSha256 = "1hxsfls6fpllc9yg5ib3qz6pa62j1y1va8a6356j6812csk4ifnn";
cargoSha256 = "1kc434pa72n9xll2r4ddmd9xdwv3ls36cwsmdry392j41zmics51";
checkInputs = [ ansi2html ];
checkPhase = ''
# Skip tests that use the network and that include files.
cargo test -- --skip terminal::iterm2 --skip terminal::resources::tests::remote \
cargo test -- --skip terminal::iterm2 \
--skip magic::tests::detect_mimetype_of_svg_image \
--skip magic::tests::detect_mimetype_of_png_image
--skip magic::tests::detect_mimetype_of_png_image \
--skip resources::tests::read_url_with_http_url_fails_when_status_404 \
--skip resources::tests::read_url_with_http_url_returns_content_when_status_200
'';
meta = with stdenv.lib; {

View File

@ -1298,7 +1298,7 @@ in
burpsuite = callPackage ../tools/networking/burpsuite {};
bs-platform = (callPackage ../development/compilers/bs-platform {}).bs-platform-621;
bs-platform = callPackage ../development/compilers/bs-platform {};
c3d = callPackage ../applications/graphics/c3d {
inherit (darwin.apple_sdk.frameworks) Cocoa;
@ -13653,6 +13653,10 @@ in
buildPythonApplication click future six;
};
prospector = callPackage ../development/tools/prospector {
python = python37;
};
protobuf = protobuf3_7;
protobuf3_11 = callPackage ../development/libraries/protobuf/3.11.nix { };
@ -18211,7 +18215,9 @@ in
bleachbit = callPackage ../applications/misc/bleachbit { };
blender = callPackage ../applications/misc/blender { };
blender = callPackage ../applications/misc/blender {
inherit (darwin.apple_sdk.frameworks) Cocoa CoreGraphics ForceFeedback OpenAL OpenGL;
};
bluefish = callPackage ../applications/editors/bluefish {
gtk = gtk3;
@ -18553,6 +18559,7 @@ in
docker-machine-kvm2 = callPackage ../applications/networking/cluster/docker-machine/kvm2.nix { };
docker-machine-xhyve = callPackage ../applications/networking/cluster/docker-machine/xhyve.nix {
inherit (darwin.apple_sdk.frameworks) Hypervisor vmnet;
inherit (darwin) cctools;
};
docker-distribution = callPackage ../applications/virtualization/docker/distribution.nix { };
@ -23915,6 +23922,8 @@ in
nasc = callPackage ../applications/science/math/nasc { };
nota = haskellPackages.callPackage ../applications/science/math/nota { };
openblas = callPackage ../development/libraries/science/math/openblas { };
# A version of OpenBLAS using 32-bit integers on all platforms for compatibility with
@ -25799,5 +25808,4 @@ in
sentencepiece = callPackage ../development/libraries/sentencepiece {};
kcli = callPackage ../development/tools/kcli {};
}

View File

@ -108,7 +108,7 @@ in {
inherit buildSetupcfg;
inherit (callPackage ../development/interpreters/python/hooks { })
eggUnpackHook eggBuildHook eggInstallHook flitBuildHook pipBuildHook pipInstallHook pytestCheckHook pythonCatchConflictsHook pythonImportsCheckHook pythonRemoveBinBytecodeHook setuptoolsBuildHook setuptoolsCheckHook wheelUnpackHook;
eggUnpackHook eggBuildHook eggInstallHook flitBuildHook pipBuildHook pipInstallHook pytestCheckHook pythonCatchConflictsHook pythonImportsCheckHook pythonRemoveBinBytecodeHook setuptoolsBuildHook setuptoolsCheckHook venvShellHook wheelUnpackHook;
# helpers
@ -4831,6 +4831,12 @@ in {
pylint = if isPy3k then callPackage ../development/python-modules/pylint { }
else callPackage ../development/python-modules/pylint/1.9.nix { };
pylint-celery = callPackage ../development/python-modules/pylint-celery { };
pylint-django = callPackage ../development/python-modules/pylint-django { };
pylint-flask = callPackage ../development/python-modules/pylint-flask { };
pylint-plugin-utils = callPackage ../development/python-modules/pylint-plugin-utils { };
pyomo = callPackage ../development/python-modules/pyomo { };
@ -4941,6 +4947,8 @@ in {
pynmea2 = callPackage ../development/python-modules/pynmea2 {};
pynrrd = callPackage ../development/python-modules/pynrrd { };
pynzb = callPackage ../development/python-modules/pynzb { };
process-tests = callPackage ../development/python-modules/process-tests { };