diff options
Diffstat (limited to 'nixpkgs/pkgs/development/interpreters')
43 files changed, 1072 insertions, 217 deletions
diff --git a/nixpkgs/pkgs/development/interpreters/anko/default.nix b/nixpkgs/pkgs/development/interpreters/anko/default.nix new file mode 100644 index 000000000000..f88534e9ecf8 --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/anko/default.nix @@ -0,0 +1,29 @@ +{ lib +, buildGoModule +, fetchFromGitHub +}: + +buildGoModule rec { + pname = "anko"; + version = "0.1.9"; + + src = fetchFromGitHub { + owner = "mattn"; + repo = "anko"; + rev = "v${version}"; + hash = "sha256-ZVNkQu5IxBx3f+FkUWc36EOEcY176wQJ2ravLPQAHAA="; + }; + + vendorHash = null; + + ldflags = [ "-s" "-w" ]; + + __darwinAllowLocalNetworking = true; + + meta = with lib; { + description = "Scriptable interpreter written in golang"; + homepage = "https://github.com/mattn/anko"; + license = licenses.mit; + maintainers = with maintainers; [ figsoda ]; + }; +} diff --git a/nixpkgs/pkgs/development/interpreters/babashka/wrapped.nix b/nixpkgs/pkgs/development/interpreters/babashka/wrapped.nix index 64c4acff066c..4b77eddab03c 100644 --- a/nixpkgs/pkgs/development/interpreters/babashka/wrapped.nix +++ b/nixpkgs/pkgs/development/interpreters/babashka/wrapped.nix @@ -1,12 +1,22 @@ -{ stdenv +{ stdenvNoCC +, lib , babashka-unwrapped , clojure , makeWrapper , rlwrap , jdkBabashka ? clojure.jdk + + # rlwrap is a small utility to allow the editing of keyboard input, see + # https://book.babashka.org/#_repl + # + # NOTE In some cases, rlwrap prints some extra empty lines. That behavior can + # break some babashka scripts. For this reason, it is disabled by default. See: + # https://github.com/NixOS/nixpkgs/issues/246839 + # https://github.com/NixOS/nixpkgs/pull/248207 +, withRlwrap ? false }: -stdenv.mkDerivation (finalAttrs: { +stdenvNoCC.mkDerivation (finalAttrs: { pname = "babashka"; inherit (babashka-unwrapped) version meta doInstallCheck installCheckPhase; @@ -27,6 +37,8 @@ stdenv.mkDerivation (finalAttrs: { --set-default DEPS_CLJ_TOOLS_DIR $out/clojure_tools \ --set-default JAVA_HOME ${jdkBabashka} + '' + + lib.optionalString withRlwrap '' substituteInPlace $out/bin/bb \ --replace '"${unwrapped-bin}"' '"${rlwrap}/bin/rlwrap" "${unwrapped-bin}"' ''; diff --git a/nixpkgs/pkgs/development/interpreters/cel-go/default.nix b/nixpkgs/pkgs/development/interpreters/cel-go/default.nix new file mode 100644 index 000000000000..613f332ed623 --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/cel-go/default.nix @@ -0,0 +1,38 @@ +{ lib +, buildGoModule +, fetchFromGitHub +}: + +buildGoModule rec { + pname = "cel-go"; + version = "0.17.1"; + + src = fetchFromGitHub { + owner = "google"; + repo = "cel-go"; + rev = "v${version}"; + hash = "sha256-qk7jopOr/woWCi5j509K4bdlIybuZZ+UFTmTHEEw9/Y="; + }; + + sourceRoot = "${src.name}/repl"; + + vendorHash = "sha256-OypSL91/2FVCF3ADNSJH33JxH0+3HxIziwmXHb/vZM4="; + + subPackages = [ + "main" + ]; + + ldflags = [ "-s" "-w" ]; + + postInstall = '' + mv $out/bin/{main,cel-go} + ''; + + meta = with lib; { + description = "Fast, portable, non-Turing complete expression evaluation with gradual typing"; + homepage = "https://github.com/google/cel-go"; + changelog = "https://github.com/google/cel-go/releases/tag/${src.rev}"; + license = licenses.asl20; + maintainers = with maintainers; [ figsoda ]; + }; +} diff --git a/nixpkgs/pkgs/development/interpreters/cling/default.nix b/nixpkgs/pkgs/development/interpreters/cling/default.nix index 6a2fa5ea50da..f59c1910a6ff 100644 --- a/nixpkgs/pkgs/development/interpreters/cling/default.nix +++ b/nixpkgs/pkgs/development/interpreters/cling/default.nix @@ -1,20 +1,39 @@ -{ lib -, stdenv -, python3 -, libffi -, git -, cmake -, zlib -, fetchgit +{ cmake , fetchFromGitHub -, makeWrapper -, runCommand +, fetchgit +, git +, lib +, libffi , llvmPackages_9 -, glibc +, makeWrapper , ncurses +, python3 +, runCommand +, zlib + +# *NOT* from LLVM 9! +# The compiler used to compile Cling may affect the runtime include and lib +# directories it expects to be run with. Cling builds against (a fork of) Clang, +# so we prefer to use Clang as the compiler as well for consistency. +# It would be cleanest to use LLVM 9's clang, but it errors. So, we use a later +# version of Clang to compile, but we check out the Cling fork of Clang 9 to +# build Cling against. +, clangStdenv + +# For runtime C++ standard library +, gcc-unwrapped + +# Build with debug symbols +, debug ? false + +# Build with libc++ (LLVM) rather than stdlibc++ (GCC). +# This is experimental and not all features work. +, useLLVMLibcxx ? false }: let + stdenv = clangStdenv; + # The LLVM 9 headers have a couple bugs we need to patch fixedLlvmDev = runCommand "llvm-dev-${llvmPackages_9.llvm.version}" { buildInputs = [git]; } '' mkdir $out @@ -58,7 +77,7 @@ let ]; nativeBuildInputs = [ python3 git cmake ]; - buildInputs = [ libffi zlib ncurses ]; + buildInputs = [ libffi ncurses zlib ]; strictDeps = true; @@ -69,6 +88,7 @@ let "-DLLVM_MAIN_INCLUDE_DIR=${fixedLlvmDev}/include" "-DLLVM_TABLEGEN_EXE=${llvmPackages_9.llvm.out}/bin/llvm-tblgen" "-DLLVM_TOOLS_BINARY_DIR=${llvmPackages_9.llvm.out}/bin" + "-DLLVM_BUILD_TOOLS=Off" "-DLLVM_TOOL_CLING_BUILD=ON" "-DLLVM_TARGETS_TO_BUILD=host;NVPTX" @@ -78,14 +98,22 @@ let # see cling/tools/CMakeLists.txt "-DCLING_INCLUDE_TESTS=ON" "-DCLANG-TOOLS=OFF" - # "--trace-expand" + ] ++ lib.optionals debug [ + "-DCMAKE_BUILD_TYPE=Debug" + ] ++ lib.optionals useLLVMLibcxx [ + "-DLLVM_ENABLE_LIBCXX=ON" + "-DLLVM_ENABLE_LIBCXXABI=ON" ]; + CPPFLAGS = if useLLVMLibcxx then [ "-stdlib=libc++" ] else []; + postInstall = lib.optionalString (!stdenv.isDarwin) '' mkdir -p $out/share/Jupyter cp -r /build/clang/tools/cling/tools/Jupyter/kernel $out/share/Jupyter ''; + dontStrip = debug; + meta = with lib; { description = "The Interactive C++ Interpreter"; homepage = "https://root.cern/cling/"; @@ -95,44 +123,49 @@ let }; }; + # Runtime flags for the C++ standard library + cxxFlags = if useLLVMLibcxx then [ + "-I" "${lib.getDev llvmPackages_9.libcxx}/include/c++/v1" + "-L" "${llvmPackages_9.libcxx}/lib" + "-l" "${llvmPackages_9.libcxx}/lib/libc++.so" + ] else [ + "-I" "${gcc-unwrapped}/include/c++/${gcc-unwrapped.version}" + "-I" "${gcc-unwrapped}/include/c++/${gcc-unwrapped.version}/x86_64-unknown-linux-gnu" + ]; + # The flags passed to the wrapped cling should # a) prevent it from searching for system include files and libs, and - # b) provide it with the include files and libs it needs (C and C++ standard library) + # b) provide it with the include files and libs it needs (C and C++ standard library plus + # its own stuff) - # These are also exposed as cling.flags/cling.compilerIncludeFlags because it's handy to be - # able to pass them to tools that wrap Cling, particularly Jupyter kernels such as xeus-cling - # and the built-in jupyter-cling-kernel. Both of these use Cling as a library by linking against - # libclingJupyter.so, so the makeWrapper approach to wrapping the binary doesn't work. + # These are also exposed as cling.flags because it's handy to be able to pass them to tools + # that wrap Cling, particularly Jupyter kernels such as xeus-cling and the built-in + # jupyter-cling-kernel, which use Cling as a library. # Thus, if you're packaging a Jupyter kernel, you either need to pass these flags as extra # args to xcpp (for xeus-cling) or put them in the environment variable CLING_OPTS - # (for jupyter-cling-kernel) + # (for jupyter-cling-kernel). flags = [ "-nostdinc" "-nostdinc++" + + "-isystem" "${lib.getLib unwrapped}/lib/clang/9.0.1/include" + ] + ++ cxxFlags + ++ [ + # System libc "-isystem" "${lib.getDev stdenv.cc.libc}/include" - "-I" "${lib.getDev unwrapped}/include" - "-I" "${lib.getLib unwrapped}/lib/clang/9.0.1/include" - ]; - # Autodetect the include paths for the compiler used to build Cling, in the same way Cling does at - # https://github.com/root-project/cling/blob/v0.7/lib/Interpreter/CIFactory.cpp#L107:L111 - # Note: it would be nice to just put the compiler in Cling's PATH and let it do this by itself, but - # unfortunately passing -nostdinc/-nostdinc++ disables Cling's autodetection logic. - compilerIncludeFlags = runCommand "compiler-include-flags.txt" {} '' - export LC_ALL=C - ${stdenv.cc}/bin/c++ -xc++ -E -v /dev/null 2>&1 | sed -n -e '/^.include/,''${' -e '/^ \/.*++/p' -e '}' > tmp - sed -e 's/^/-isystem /' -i tmp - tr '\n' ' ' < tmp > $out - ''; + # cling includes + "-isystem" "${lib.getDev unwrapped}/include" + ]; in runCommand "cling-${unwrapped.version}" { nativeBuildInputs = [ makeWrapper ]; - inherit unwrapped flags compilerIncludeFlags; + inherit unwrapped flags; inherit (unwrapped) meta; } '' makeWrapper $unwrapped/bin/cling $out/bin/cling \ - --add-flags "$(cat "$compilerIncludeFlags")" \ --add-flags "$flags" '' diff --git a/nixpkgs/pkgs/development/interpreters/clojure/default.nix b/nixpkgs/pkgs/development/interpreters/clojure/default.nix index 18984e2b774c..2aaefaed7a43 100644 --- a/nixpkgs/pkgs/development/interpreters/clojure/default.nix +++ b/nixpkgs/pkgs/development/interpreters/clojure/default.nix @@ -2,12 +2,12 @@ stdenv.mkDerivation (finalAttrs: { pname = "clojure"; - version = "1.11.1.1347"; + version = "1.11.1.1386"; src = fetchurl { - # https://clojure.org/releases/tools - url = "https://download.clojure.org/install/clojure-tools-${finalAttrs.version}.tar.gz"; - hash = "sha256-1ebAPk64tJt/Cpt3pKfMTN50YABKPflqG055f4Quv+M="; + # https://github.com/clojure/brew-install/releases + url = "https://github.com/clojure/brew-install/releases/download/${finalAttrs.version}/clojure-tools-${finalAttrs.version}.tar.gz"; + hash = "sha256-e5RLnsydCZKRv6P/yC8FxK5AgK0Gj6YJw7E41neGYsM="; }; nativeBuildInputs = [ diff --git a/nixpkgs/pkgs/development/interpreters/cyber/default.nix b/nixpkgs/pkgs/development/interpreters/cyber/default.nix new file mode 100644 index 000000000000..9c1d94b0c7f8 --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/cyber/default.nix @@ -0,0 +1,38 @@ +{ lib +, stdenv +, fetchFromGitHub +, zig_0_11 +}: + +stdenv.mkDerivation rec { + pname = "cyber"; + version = "unstable-2023-08-11"; + + src = fetchFromGitHub { + owner = "fubark"; + repo = "cyber"; + rev = "242ba2573cbac2acecc8c06878a8d754dd7a8716"; + hash = "sha256-jArkFdvWnHNouNGsTn8O2lbU7eZdLbPD0xEfkrFH5Aw="; + }; + + nativeBuildInputs = [ + zig_0_11.hook + ]; + + zigBuildFlags = [ + "cli" + ]; + + env = { + COMMIT = lib.substring 0 7 src.rev; + }; + + meta = with lib; { + description = "A fast, efficient, and concurrent scripting language"; + homepage = "https://github.com/fubark/cyber"; + license = licenses.mit; + maintainers = with maintainers; [ figsoda ]; + inherit (zig_0_11.meta) platforms; + broken = stdenv.isDarwin; + }; +} diff --git a/nixpkgs/pkgs/development/interpreters/expr/default.nix b/nixpkgs/pkgs/development/interpreters/expr/default.nix new file mode 100644 index 000000000000..6db01f41eff1 --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/expr/default.nix @@ -0,0 +1,35 @@ +{ lib +, buildGoModule +, fetchFromGitHub +}: + +buildGoModule rec { + pname = "expr"; + version = "1.14.1"; + + src = fetchFromGitHub { + owner = "antonmedv"; + repo = "expr"; + rev = "v${version}"; + hash = "sha256-X55l2pSlwrcxM4JFcd25yfc5AQJPzNrZRHEHPWPevHw="; + }; + + sourceRoot = "${src.name}/repl"; + + vendorHash = "sha256-pX8Yk/md6I27PPmdwoixSMMbopDjXOOnXyUxq0D97YA="; + + ldflags = [ "-s" "-w" ]; + + postInstall = '' + mv $out/bin/{repl,expr} + ''; + + meta = with lib; { + description = "Expression language and expression evaluation for Go"; + homepage = "https://github.com/antonmedv/expr"; + changelog = "https://github.com/antonmedv/expr/releases/tag/${src.rev}"; + license = licenses.mit; + maintainers = with maintainers; [ figsoda ]; + mainProgram = "expr"; + }; +} diff --git a/nixpkgs/pkgs/development/interpreters/gpython/default.nix b/nixpkgs/pkgs/development/interpreters/gpython/default.nix new file mode 100644 index 000000000000..8bb432e839ea --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/gpython/default.nix @@ -0,0 +1,47 @@ +{ lib +, buildGoModule +, fetchFromGitHub +, testers +, gpython +}: + +buildGoModule rec { + pname = "gpython"; + version = "0.2.0"; + + src = fetchFromGitHub { + owner = "go-python"; + repo = "gpython"; + rev = "v${version}"; + hash = "sha256-xqwq27u41Jgoh7t9UDyatuBQswr+h3xio5AV/npncHc="; + }; + + vendorHash = "sha256-NXPllEhootdB8m5Wvfy8MW899oQnjWAQj7yCC2oDvqE="; + + subPackages = [ + "." + ]; + + ldflags = [ + "-s" + "-w" + "-X=main.version=${version}" + "-X=main.commit=${src.rev}" + "-X=main.date=1970-01-01" + ]; + + passthru.tests = { + version = testers.testVersion { + package = gpython; + command = "gpython < /dev/null"; + }; + }; + + meta = with lib; { + description = "A Python interpreter written in Go"; + homepage = "https://github.com/go-python/gpython"; + changelog = "https://github.com/go-python/gpython/releases/tag/${src.rev}"; + license = licenses.bsd3; + maintainers = with maintainers; [ figsoda ]; + }; +} diff --git a/nixpkgs/pkgs/development/interpreters/guile/setup-hook-1.8.sh b/nixpkgs/pkgs/development/interpreters/guile/setup-hook-1.8.sh index 946e595ac0bf..9a6ffb793a78 100644 --- a/nixpkgs/pkgs/development/interpreters/guile/setup-hook-1.8.sh +++ b/nixpkgs/pkgs/development/interpreters/guile/setup-hook-1.8.sh @@ -1,6 +1,6 @@ addGuileLibPath () { if test -d "$1/share/guile/site"; then - export GUILE_LOAD_PATH="${GUILE_LOAD_PATH-}${GUILE_LOAD_PATH:+:}$1/share/guile/site" + addToSearchPath GUILE_LOAD_PATH "$1/share/guile/site" fi } diff --git a/nixpkgs/pkgs/development/interpreters/guile/setup-hook-2.0.sh b/nixpkgs/pkgs/development/interpreters/guile/setup-hook-2.0.sh index d83f9c647057..9ef0fae011b5 100644 --- a/nixpkgs/pkgs/development/interpreters/guile/setup-hook-2.0.sh +++ b/nixpkgs/pkgs/development/interpreters/guile/setup-hook-2.0.sh @@ -1,18 +1,18 @@ addGuileLibPath () { if test -d "$1/share/guile/site/2.0"; then - export GUILE_LOAD_PATH="${GUILE_LOAD_PATH-}${GUILE_LOAD_PATH:+:}$1/share/guile/site/2.0" - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/share/guile/site/2.0" + addToSearchPath GUILE_LOAD_PATH "$1/share/guile/site/2.0" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/share/guile/site/2.0" elif test -d "$1/share/guile/site"; then - export GUILE_LOAD_PATH="${GUILE_LOAD_PATH-}${GUILE_LOAD_PATH:+:}$1/share/guile/site" - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/share/guile/site" + addToSearchPath GUILE_LOAD_PATH "$1/share/guile/site" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/share/guile/site" fi if test -d "$1/lib/guile/2.0/ccache"; then - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/lib/guile/2.0/ccache" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/lib/guile/2.0/ccache" fi if test -d "$1/lib/guile/2.0/site-ccache"; then - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/lib/guile/2.0/site-ccache" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/lib/guile/2.0/site-ccache" fi } diff --git a/nixpkgs/pkgs/development/interpreters/guile/setup-hook-2.2.sh b/nixpkgs/pkgs/development/interpreters/guile/setup-hook-2.2.sh index d6bb23e7949a..932a5b6c41e6 100644 --- a/nixpkgs/pkgs/development/interpreters/guile/setup-hook-2.2.sh +++ b/nixpkgs/pkgs/development/interpreters/guile/setup-hook-2.2.sh @@ -1,18 +1,18 @@ addGuileLibPath () { if test -d "$1/share/guile/site/2.2"; then - export GUILE_LOAD_PATH="${GUILE_LOAD_PATH-}${GUILE_LOAD_PATH:+:}$1/share/guile/site/2.2" - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/share/guile/site/2.2" + addToSearchPath GUILE_LOAD_PATH "$1/share/guile/site/2.2" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/share/guile/site/2.2" elif test -d "$1/share/guile/site"; then - export GUILE_LOAD_PATH="${GUILE_LOAD_PATH-}${GUILE_LOAD_PATH:+:}$1/share/guile/site" - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/share/guile/site" + addToSearchPath GUILE_LOAD_PATH "$1/share/guile/site" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/share/guile/site" fi if test -d "$1/lib/guile/2.2/ccache"; then - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/lib/guile/2.2/ccache" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/lib/guile/2.2/ccache" fi if test -d "$1/lib/guile/2.2/site-ccache"; then - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/lib/guile/2.2/site-ccache" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/lib/guile/2.2/site-ccache" fi } diff --git a/nixpkgs/pkgs/development/interpreters/guile/setup-hook-3.0.sh b/nixpkgs/pkgs/development/interpreters/guile/setup-hook-3.0.sh index 903a1ebfb235..1a71e82d13a2 100644 --- a/nixpkgs/pkgs/development/interpreters/guile/setup-hook-3.0.sh +++ b/nixpkgs/pkgs/development/interpreters/guile/setup-hook-3.0.sh @@ -1,24 +1,24 @@ addGuileLibPath () { if test -d "$1/share/guile/site/3.0"; then - export GUILE_LOAD_PATH="${GUILE_LOAD_PATH-}${GUILE_LOAD_PATH:+:}$1/share/guile/site/3.0" - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/share/guile/site/3.0" - export GUILE_EXTENSIONS_PATH="${GUILE_EXTENSIONS_PATH-}${GUILE_EXTENSIONS_PATH:+:}$1/share/guile/site/3.0" + addToSearchPath GUILE_LOAD_PATH "$1/share/guile/site/3.0" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/share/guile/site/3.0" + addToSearchPath GUILE_EXTENSIONS_PATH "$1/share/guile/site/3.0" elif test -d "$1/share/guile/site"; then - export GUILE_LOAD_PATH="${GUILE_LOAD_PATH-}${GUILE_LOAD_PATH:+:}$1/share/guile/site" - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/share/guile/site" - export GUILE_EXTENSIONS_PATH="${GUILE_EXTENSIONS_PATH-}${GUILE_EXTENSIONS_PATH:+:}$1/share/guile/site" + addToSearchPath GUILE_LOAD_PATH "$1/share/guile/site" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/share/guile/site" + addToSearchPath GUILE_EXTENSIONS_PATH "$1/share/guile/site" fi if test -d "$1/lib/guile/3.0/ccache"; then - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/lib/guile/3.0/ccache" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/lib/guile/3.0/ccache" fi if test -d "$1/lib/guile/3.0/site-ccache"; then - export GUILE_LOAD_COMPILED_PATH="${GUILE_LOAD_COMPILED_PATH-}${GUILE_LOAD_COMPILED_PATH:+:}$1/lib/guile/3.0/site-ccache" + addToSearchPath GUILE_LOAD_COMPILED_PATH "$1/lib/guile/3.0/site-ccache" fi if test -d "$1/lib/guile/3.0/extensions"; then - export GUILE_EXTENSIONS_PATH="${GUILE_EXTENSIONS_PATH-}${GUILE_EXTENSIONS_PATH:+:}$1/lib/guile/3.0/extensions" + addToSearchPath GUILE_EXTENSIONS_PATH "$1/lib/guile/3.0/extensions" fi } diff --git a/nixpkgs/pkgs/development/interpreters/janet/default.nix b/nixpkgs/pkgs/development/interpreters/janet/default.nix index 545f7de95b1c..bb711129ff95 100644 --- a/nixpkgs/pkgs/development/interpreters/janet/default.nix +++ b/nixpkgs/pkgs/development/interpreters/janet/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { pname = "janet"; - version = "1.29.1"; + version = "1.30.0"; src = fetchFromGitHub { owner = "janet-lang"; repo = pname; rev = "v${version}"; - sha256 = "sha256-waBOPrcZ1mNsvb2PrivYUmbUKv1mxD/rMFOCZXslyKA="; + hash = "sha256-tkXEi8m7eroie/yP1kW0V6Ld5SCLA0/KmtHHI0fIsRI="; }; postPatch = '' @@ -18,6 +18,7 @@ stdenv.mkDerivation rec { nativeBuildInputs = [ meson ninja ]; + mesonBuildType = "release"; mesonFlags = [ "-Dgit_hash=release" ]; doCheck = true; diff --git a/nixpkgs/pkgs/development/interpreters/kamilalisp/default.nix b/nixpkgs/pkgs/development/interpreters/kamilalisp/default.nix index 9b990afaa57f..e0554e10b421 100644 --- a/nixpkgs/pkgs/development/interpreters/kamilalisp/default.nix +++ b/nixpkgs/pkgs/development/interpreters/kamilalisp/default.nix @@ -7,11 +7,11 @@ stdenv.mkDerivation rec { name = "kamilalisp"; - version = "0.2p"; + version = "0.3.0.1"; src = fetchurl { - url = "https://github.com/kspalaiologos/kamilalisp/releases/download/v${version}/kamilalisp-${lib.versions.majorMinor version}.jar"; - hash = "sha256-6asl9zRTidDxWsgIRxUA1ygYug/aqiQ5XAEwWYNOfKE="; + url = "https://github.com/kspalaiologos/kamilalisp/releases/download/v${version}/kamilalisp-${version}.jar"; + hash = "sha256-SW0U483eHptkYw+yJV/2cImfK3uEjkl8ma54yeagF6s="; }; dontUnpack = true; diff --git a/nixpkgs/pkgs/development/interpreters/lua-5/default.nix b/nixpkgs/pkgs/development/interpreters/lua-5/default.nix index f4c622515d7d..51d44e7f1e0f 100644 --- a/nixpkgs/pkgs/development/interpreters/lua-5/default.nix +++ b/nixpkgs/pkgs/development/interpreters/lua-5/default.nix @@ -23,7 +23,7 @@ let # - imports lua-packages.nix # - adds spliced package sets to the package set # - applies overrides from `packageOverrides` - ({ lua, overrides, callPackage, makeScopeWithSplicing }: let + ({ lua, overrides, callPackage, makeScopeWithSplicing' }: let luaPackagesFun = callPackage ../../../top-level/lua-packages.nix { lua = self; }; @@ -39,18 +39,15 @@ let selfHostHost = luaOnHostForHost.pkgs; selfTargetTarget = luaOnTargetForTarget.pkgs or {}; }; - keep = self: { }; - extra = spliced0: {}; extensions = lib.composeManyExtensions [ generatedPackages overriddenPackages overrides ]; - in makeScopeWithSplicing - otherSplices - keep - extra - (lib.extends extensions luaPackagesFun)) + in makeScopeWithSplicing' { + inherit otherSplices; + f = lib.extends extensions luaPackagesFun; + }) { overrides = packageOverrides; lua = self; diff --git a/nixpkgs/pkgs/development/interpreters/luau/default.nix b/nixpkgs/pkgs/development/interpreters/luau/default.nix index 8fe357820396..4bacb15a79d9 100644 --- a/nixpkgs/pkgs/development/interpreters/luau/default.nix +++ b/nixpkgs/pkgs/development/interpreters/luau/default.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { pname = "luau"; - version = "0.588"; + version = "0.591"; src = fetchFromGitHub { owner = "Roblox"; repo = "luau"; rev = version; - hash = "sha256-iRYVmRnEpLBtBJ5EjN88EmWM88FNU4CyFvgnBaqDSz4="; + hash = "sha256-eCYB+B5bglUcF+xAAHBWwwgDrvY9NatmcwL/GUnIhOk="; }; nativeBuildInputs = [ cmake ]; diff --git a/nixpkgs/pkgs/development/interpreters/nickel/default.nix b/nixpkgs/pkgs/development/interpreters/nickel/default.nix index ea69852b7ab5..8ab3ec532fdb 100644 --- a/nixpkgs/pkgs/development/interpreters/nickel/default.nix +++ b/nixpkgs/pkgs/development/interpreters/nickel/default.nix @@ -43,6 +43,6 @@ rustPlatform.buildRustPackage rec { ''; changelog = "https://github.com/tweag/nickel/blob/${version}/RELEASES.md"; license = licenses.mit; - maintainers = with maintainers; [ AndersonTorres felschr ]; + maintainers = with maintainers; [ AndersonTorres felschr matthiasbeyer ]; }; } diff --git a/nixpkgs/pkgs/development/interpreters/perl/MakeMaker-cross.patch b/nixpkgs/pkgs/development/interpreters/perl/MakeMaker-cross.patch deleted file mode 100644 index 40626c51f9bd..000000000000 --- a/nixpkgs/pkgs/development/interpreters/perl/MakeMaker-cross.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff -Naur a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm ---- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm 2017-06-30 17:03:20.000000000 -0400 -+++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MakeMaker.pm 2018-02-28 10:06:37.031237946 -0500 -@@ -1267,7 +1267,12 @@ - my $value = shift; - return $value if $UNDER_CORE; - my $tvalue = ''; -- require B; -+ eval { -+ require B; -+ }; -+ if ($@) { -+ return $tvalue; -+ } - my $sv = B::svref_2object(\$value); - my $magic = ref($sv) eq 'B::PVMG' ? $sv->MAGIC : undef; - while ( $magic ) { diff --git a/nixpkgs/pkgs/development/interpreters/perl/cross.patch b/nixpkgs/pkgs/development/interpreters/perl/cross.patch new file mode 100644 index 000000000000..e0f05ede90d0 --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/perl/cross.patch @@ -0,0 +1,250 @@ +From: =?UTF-8?q?Christian=20K=C3=B6gler?= <ck3d@gmx.de> +Date: Mon, 10 Apr 2023 22:12:24 +0200 +Subject: [PATCH] miniperl compatible modules + +CPAN::Meta +ExtUtils::MakeMaker +JSON::PP +Data::Dumper + +Updated for perl v5.38.0 by stig@stig.io + +--- + +diff --git a/cpan/CPAN-Meta-Requirements/lib/CPAN/Meta/Requirements.pm b/cpan/CPAN-Meta-Requirements/lib/CPAN/Meta/Requirements.pm +index b0e83b0d2d..dab4907704 100644 +--- a/cpan/CPAN-Meta-Requirements/lib/CPAN/Meta/Requirements.pm ++++ b/cpan/CPAN-Meta-Requirements/lib/CPAN/Meta/Requirements.pm +@@ -86,21 +86,7 @@ sub new { + # from version::vpp + sub _find_magic_vstring { + my $value = shift; +- my $tvalue = ''; +- require B; +- my $sv = B::svref_2object(\$value); +- my $magic = ref($sv) eq 'B::PVMG' ? $sv->MAGIC : undef; +- while ( $magic ) { +- if ( $magic->TYPE eq 'V' ) { +- $tvalue = $magic->PTR; +- $tvalue =~ s/^v?(.+)$/v$1/; +- last; +- } +- else { +- $magic = $magic->MOREMAGIC; +- } +- } +- return $tvalue; ++ return version::->parse($value)->stringify; + } + + # safe if given an unblessed reference +diff --git a/cpan/CPAN-Meta-YAML/lib/CPAN/Meta/YAML.pm b/cpan/CPAN-Meta-YAML/lib/CPAN/Meta/YAML.pm +index 746abd63bc..c55d7cd2d0 100644 +--- a/cpan/CPAN-Meta-YAML/lib/CPAN/Meta/YAML.pm ++++ b/cpan/CPAN-Meta-YAML/lib/CPAN/Meta/YAML.pm +@@ -1,6 +1,7 @@ + use 5.008001; # sane UTF-8 support + use strict; + use warnings; ++no warnings 'experimental::builtin'; + package CPAN::Meta::YAML; # git description: v1.68-2-gcc5324e + # XXX-INGY is 5.8.1 too old/broken for utf8? + # XXX-XDG Lancaster consensus was that it was sufficient until +@@ -650,27 +651,29 @@ sub _dump_string { + join '', map { "$_\n" } @lines; + } + +-sub _has_internal_string_value { ++# taken from cpan/JSON-PP/lib/JSON/PP.pm ++sub _looks_like_number { + my $value = shift; +- my $b_obj = B::svref_2object(\$value); # for round trip problem +- return $b_obj->FLAGS & B::SVf_POK(); ++ no warnings 'numeric'; ++ # if the utf8 flag is on, it almost certainly started as a string ++ return if utf8::is_utf8($value); ++ # detect numbers ++ # string & "" -> "" ++ # number & "" -> 0 (with warning) ++ # nan and inf can detect as numbers, so check with * 0 ++ return unless length((my $dummy = "") & $value); ++ return unless 0 + $value eq $value; ++ return 1 if $value * 0 == 0; ++ return -1; # inf/nan + } + + sub _dump_scalar { + my $string = $_[1]; + my $is_key = $_[2]; +- # Check this before checking length or it winds up looking like a string! +- my $has_string_flag = _has_internal_string_value($string); + return '~' unless defined $string; + return "''" unless length $string; +- if (Scalar::Util::looks_like_number($string)) { +- # keys and values that have been used as strings get quoted +- if ( $is_key || $has_string_flag ) { +- return qq['$string']; +- } +- else { +- return $string; +- } ++ if (_looks_like_number($string)) { ++ return qq['$string']; + } + if ( $string =~ /[\x00-\x09\x0b-\x0d\x0e-\x1f\x7f-\x9f\'\n]/ ) { + $string =~ s/\\/\\\\/g; +@@ -800,9 +803,6 @@ sub errstr { + # Helper functions. Possibly not needed. + + +-# Use to detect nv or iv +-use B; +- + # XXX-INGY Is flock CPAN::Meta::YAML's responsibility? + # Some platforms can't flock :-( + # XXX-XDG I think it is. When reading and writing files, we ought +@@ -822,35 +822,8 @@ sub _can_flock { + } + } + +- +-# XXX-INGY Is this core in 5.8.1? Can we remove this? +-# XXX-XDG Scalar::Util 1.18 didn't land until 5.8.8, so we need this +-##################################################################### +-# Use Scalar::Util if possible, otherwise emulate it +- +-use Scalar::Util (); + BEGIN { +- local $@; +- if ( eval { Scalar::Util->VERSION(1.18); } ) { +- *refaddr = *Scalar::Util::refaddr; +- } +- else { +- eval <<'END_PERL'; +-# Scalar::Util failed to load or too old +-sub refaddr { +- my $pkg = ref($_[0]) or return undef; +- if ( !! UNIVERSAL::can($_[0], 'can') ) { +- bless $_[0], 'Scalar::Util::Fake'; +- } else { +- $pkg = undef; +- } +- "$_[0]" =~ /0x(\w+)/; +- my $i = do { no warnings 'portable'; hex $1 }; +- bless $_[0], $pkg if defined $pkg; +- $i; +-} +-END_PERL +- } ++ *refaddr = *builtin::refaddr; + } + + delete $CPAN::Meta::YAML::{refaddr}; +diff --git a/cpan/CPAN-Meta/lib/CPAN/Meta/Merge.pm b/cpan/CPAN-Meta/lib/CPAN/Meta/Merge.pm +index 3604eae402..991f69d275 100644 +--- a/cpan/CPAN-Meta/lib/CPAN/Meta/Merge.pm ++++ b/cpan/CPAN-Meta/lib/CPAN/Meta/Merge.pm +@@ -1,12 +1,13 @@ + use strict; + use warnings; ++no warnings 'experimental::builtin'; + + package CPAN::Meta::Merge; + + our $VERSION = '2.150010'; + + use Carp qw/croak/; +-use Scalar::Util qw/blessed/; ++use builtin qw/blessed/; + use CPAN::Meta::Converter 2.141170; + + sub _is_identical { +diff --git a/cpan/CPAN-Meta/lib/CPAN/Meta/Prereqs.pm b/cpan/CPAN-Meta/lib/CPAN/Meta/Prereqs.pm +index d4e93fd8a5..809da68d02 100644 +--- a/cpan/CPAN-Meta/lib/CPAN/Meta/Prereqs.pm ++++ b/cpan/CPAN-Meta/lib/CPAN/Meta/Prereqs.pm +@@ -1,6 +1,7 @@ + use 5.006; + use strict; + use warnings; ++no warnings 'experimental::builtin'; + package CPAN::Meta::Prereqs; + + our $VERSION = '2.150010'; +@@ -14,7 +15,6 @@ our $VERSION = '2.150010'; + #pod =cut + + use Carp qw(confess); +-use Scalar::Util qw(blessed); + use CPAN::Meta::Requirements 2.121; + + #pod =method new +@@ -168,7 +168,12 @@ sub types_in { + sub with_merged_prereqs { + my ($self, $other) = @_; + +- my @other = blessed($other) ? $other : @$other; ++ eval 'require Scalar::Util'; ++ my @other = unless($@){ ++ Scalar::Util::blessed($other) ? $other : @$other; ++ }else{ ++ builtin::blessed($other) ? $other : @$other; ++ } + + my @prereq_objs = ($self, @other); + +diff --git a/cpan/JSON-PP/lib/JSON/PP.pm b/cpan/JSON-PP/lib/JSON/PP.pm +index fc8fcbc8f0..cda7b90c65 100644 +--- a/cpan/JSON-PP/lib/JSON/PP.pm ++++ b/cpan/JSON-PP/lib/JSON/PP.pm +@@ -4,6 +4,7 @@ package JSON::PP; + + use 5.008; + use strict; ++no warnings 'experimental::builtin'; + + use Exporter (); + BEGIN { our @ISA = ('Exporter') } +diff --git a/dist/Data-Dumper/Dumper.pm b/dist/Data-Dumper/Dumper.pm +index bb6d3caedb..0c2fde4743 100644 +--- a/dist/Data-Dumper/Dumper.pm ++++ b/dist/Data-Dumper/Dumper.pm +@@ -11,6 +11,7 @@ package Data::Dumper; + + use strict; + use warnings; ++no warnings 'experimental::builtin'; + + #$| = 1; + +@@ -125,8 +126,7 @@ sub new { + # Packed numeric addresses take less memory. Plus pack is faster than sprintf + + sub format_refaddr { +- require Scalar::Util; +- pack "J", Scalar::Util::refaddr(shift); ++ pack "J", builtin::refaddr(shift); + }; + + # +@@ -282,9 +282,8 @@ sub _dump { + warn "WARNING(Freezer method call failed): $@" if $@; + } + +- require Scalar::Util; +- my $realpack = Scalar::Util::blessed($val); +- my $realtype = $realpack ? Scalar::Util::reftype($val) : ref $val; ++ my $realpack = builtin::blessed($val); ++ my $realtype = $realpack ? builtin::reftype($val) : ref $val; + $id = format_refaddr($val); + + # Note: By this point $name is always defined and of non-zero length. +@@ -576,7 +575,7 @@ sub _dump { + # here generates a different result. So there are actually "three" different + # implementations of Data::Dumper (kind of sort of) but we only test two. + elsif (!defined &_vstring +- and ref $ref eq 'VSTRING' || eval{Scalar::Util::isvstring($val)}) { ++ and ref $ref eq 'VSTRING') { + $out .= sprintf "v%vd", $val; + } + # \d here would treat "1\x{660}" as a safe decimal number diff --git a/nixpkgs/pkgs/development/interpreters/perl/default.nix b/nixpkgs/pkgs/development/interpreters/perl/default.nix index 3c57d8a2b690..201a080309d7 100644 --- a/nixpkgs/pkgs/development/interpreters/perl/default.nix +++ b/nixpkgs/pkgs/development/interpreters/perl/default.nix @@ -17,7 +17,7 @@ let # Function that when called # - imports perl-packages.nix # - adds spliced package sets to the package set - ({ stdenv, pkgs, perl, callPackage, makeScopeWithSplicing }: let + ({ stdenv, pkgs, perl, callPackage, makeScopeWithSplicing' }: let perlPackagesFun = callPackage ../../../top-level/perl-packages.nix { # allow 'perlPackages.override { pkgs = pkgs // { imagemagick = imagemagickBig; }; }' like in python3Packages # most perl packages aren't called with callPackage so it's not possible to override their arguments individually @@ -34,13 +34,10 @@ let selfHostHost = perlOnHostForHost.pkgs; selfTargetTarget = perlOnTargetForTarget.pkgs or {}; }; - keep = self: { }; - extra = spliced0: {}; - in makeScopeWithSplicing - otherSplices - keep - extra - perlPackagesFun) + in makeScopeWithSplicing' { + inherit otherSplices; + f = perlPackagesFun; + }) { perl = self; }; @@ -58,18 +55,18 @@ let in rec { # Maint version - perl534 = callPackage ./intepreter.nix { - self = perl534; - version = "5.34.1"; - sha256 = "sha256-NXlRpJGwuhzjYRJjki/ux4zNWB3dwkpEawM+JazyQqE="; + perl536 = callPackage ./intepreter.nix { + self = perl536; + version = "5.36.1"; + sha256 = "sha256-aCA2Zdjs4CmI/HfckvzLspeoOku0uNB1WEQvl42lTME="; inherit passthruFun; }; # Maint version - perl536 = callPackage ./intepreter.nix { - self = perl536; - version = "5.36.0"; - sha256 = "sha256-4mCFr4rDlvYq3YpTPDoOqMhJfYNvBok0esWr17ek4Ao="; + perl538 = callPackage ./intepreter.nix { + self = perl538; + version = "5.38.0"; + sha256 = "sha256-IT71gInS8sly6jU1F9xg7DZW8FDcwCdmbhGLUIQj5Rc="; inherit passthruFun; }; @@ -77,8 +74,8 @@ in rec { perldevel = callPackage ./intepreter.nix { self = perldevel; perlAttr = "perldevel"; - version = "5.37.0"; - sha256 = "sha256-8RQO6gtH+WmghqzRafbqAH1MhKv/vJCcvysi7/+T9XI="; + version = "5.38.0"; + sha256 = "sha256-IT71gInS8sly6jU1F9xg7DZW8FDcwCdmbhGLUIQj5Rc="; inherit passthruFun; }; } diff --git a/nixpkgs/pkgs/development/interpreters/perl/intepreter.nix b/nixpkgs/pkgs/development/interpreters/perl/intepreter.nix index 96d6430c14e2..c16dffe3db69 100644 --- a/nixpkgs/pkgs/development/interpreters/perl/intepreter.nix +++ b/nixpkgs/pkgs/development/interpreters/perl/intepreter.nix @@ -63,16 +63,16 @@ stdenv.mkDerivation (rec { disallowedReferences = [ stdenv.cc ]; patches = - [ - # Do not look in /usr etc. for dependencies. - ./no-sys-dirs-5.31.patch + # Enable TLS/SSL verification in HTTP::Tiny by default + lib.optional (lib.versionOlder version "5.38.0") ./http-tiny-verify-ssl-by-default.patch + + # Do not look in /usr etc. for dependencies. + ++ lib.optional (lib.versionOlder version "5.38.0") ./no-sys-dirs-5.31.patch + ++ lib.optional (lib.versionAtLeast version "5.38.0") ./no-sys-dirs-5.38.0.patch - # Enable TLS/SSL verification in HTTP::Tiny by default - ./http-tiny-verify-ssl-by-default.patch - ] ++ lib.optional stdenv.isSunOS ./ld-shared.patch ++ lib.optionals stdenv.isDarwin [ ./cpp-precomp.patch ./sw_vers.patch ] - ++ lib.optional crossCompiling ./MakeMaker-cross.patch; + ++ lib.optional crossCompiling ./cross.patch; # This is not done for native builds because pwd may need to come from # bootstrap tools when building bootstrap perl. @@ -123,7 +123,7 @@ stdenv.mkDerivation (rec { dontAddPrefix = !crossCompiling; - enableParallelBuilding = !crossCompiling; + enableParallelBuilding = false; # perl includes the build date, the uname of the build system and the # username of the build user in some files. @@ -150,6 +150,7 @@ stdenv.mkDerivation (rec { LIB = ${zlib.out}/lib OLD_ZLIB = False GZIP_OS_CODE = AUTO_DETECT + USE_ZLIB_NG = False EOF '' + lib.optionalString stdenv.isDarwin '' substituteInPlace hints/darwin.sh --replace "env MACOSX_DEPLOYMENT_TARGET=10.3" "" @@ -235,14 +236,14 @@ stdenv.mkDerivation (rec { mainProgram = "perl"; }; } // lib.optionalAttrs (stdenv.buildPlatform != stdenv.hostPlatform) rec { - crossVersion = "c876045741f5159318085d2737b0090f35a842ca"; # June 5, 2022 + crossVersion = "1.5"; # Jul 03, 2023 perl-cross-src = fetchFromGitHub { - name = "perl-cross-unstable-${crossVersion}"; + name = "perl-cross-${crossVersion}"; owner = "arsv"; repo = "perl-cross"; rev = crossVersion; - sha256 = "sha256-m9UCoTQgXBxSgk9Q1Zv6wl3Qnd0aZm/jEPXkcMKti8U="; + sha256 = "sha256-9nRFJinZUWUSpXXyyIVmhRLQ1B5LB3UmN2iAckmem58="; }; depsBuildBuild = [ buildPackages.stdenv.cc makeWrapper ]; diff --git a/nixpkgs/pkgs/development/interpreters/perl/no-sys-dirs-5.38.0.patch b/nixpkgs/pkgs/development/interpreters/perl/no-sys-dirs-5.38.0.patch new file mode 100644 index 000000000000..c959730d1420 --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/perl/no-sys-dirs-5.38.0.patch @@ -0,0 +1,256 @@ +diff --git a/Configure b/Configure +index e261cb9548..3bbbc4b9df 100755 +--- a/Configure ++++ b/Configure +@@ -108,15 +108,7 @@ if test -d c:/. || ( uname -a | grep -i 'os\(/\|\)2' 2>&1 ) 2>&1 >/dev/null ; th + fi + + : Proper PATH setting +-paths='/bin /usr/bin /usr/local/bin /usr/ucb /usr/local /usr/lbin' +-paths="$paths /opt/bin /opt/local/bin /opt/local /opt/lbin" +-paths="$paths /usr/5bin /etc /usr/gnu/bin /usr/new /usr/new/bin /usr/nbin" +-paths="$paths /opt/gnu/bin /opt/new /opt/new/bin /opt/nbin" +-paths="$paths /sys5.3/bin /sys5.3/usr/bin /bsd4.3/bin /bsd4.3/usr/ucb" +-paths="$paths /bsd4.3/usr/bin /usr/bsd /bsd43/bin /opt/ansic/bin /usr/ccs/bin" +-paths="$paths /etc /usr/lib /usr/ucblib /lib /usr/ccs/lib" +-paths="$paths /sbin /usr/sbin /usr/libexec" +-paths="$paths /system/gnu_library/bin" ++paths='' + + for p in $paths + do +@@ -1455,8 +1447,7 @@ groupstype='' + i_whoami='' + : Possible local include directories to search. + : Set locincpth to "" in a hint file to defeat local include searches. +-locincpth="/usr/local/include /opt/local/include /usr/gnu/include" +-locincpth="$locincpth /opt/gnu/include /usr/GNU/include /opt/GNU/include" ++locincpth="" + : + : no include file wanted by default + inclwanted='' +@@ -1470,17 +1461,12 @@ DEBUGGING='' + archobjs='' + libnames='' + : change the next line if compiling for Xenix/286 on Xenix/386 +-xlibpth='/usr/lib/386 /lib/386' ++xlibpth='' + : Possible local library directories to search. +-loclibpth="/usr/local/lib /opt/local/lib /usr/gnu/lib" +-loclibpth="$loclibpth /opt/gnu/lib /usr/GNU/lib /opt/GNU/lib" ++loclibpth="" + + : general looking path for locating libraries +-glibpth="/lib /usr/lib $xlibpth" +-glibpth="$glibpth /usr/ccs/lib /usr/ucblib /usr/local/lib" +-test -f /usr/shlib/libc.so && glibpth="/usr/shlib $glibpth" +-test -f /shlib/libc.so && glibpth="/shlib $glibpth" +-test -d /usr/lib64 && glibpth="$glibpth /lib64 /usr/lib64 /usr/local/lib64" ++glibpth="" + + : Private path used by Configure to find libraries. Its value + : is prepended to libpth. This variable takes care of special +@@ -1515,8 +1501,6 @@ libswanted="cl pthread socket bind inet ndbm gdbm dbm db malloc dl ld" + libswanted="$libswanted sun m crypt sec util c cposix posix ucb bsd BSD" + : We probably want to search /usr/shlib before most other libraries. + : This is only used by the lib/ExtUtils/MakeMaker.pm routine extliblist. +-glibpth=`echo " $glibpth " | sed -e 's! /usr/shlib ! !'` +-glibpth="/usr/shlib $glibpth" + : Do not use vfork unless overridden by a hint file. + usevfork=false + +@@ -2581,7 +2565,6 @@ uname + zip + " + pth=`echo $PATH | sed -e "s/$p_/ /g"` +-pth="$pth $sysroot/lib $sysroot/usr/lib" + for file in $loclist; do + eval xxx=\$$file + case "$xxx" in +@@ -5023,7 +5006,7 @@ esac + : Set private lib path + case "$plibpth" in + '') if ./mips; then +- plibpth="$incpath/usr/lib $sysroot/usr/local/lib $sysroot/usr/ccs/lib" ++ plibpth="$incpath/usr/lib" + fi;; + esac + case "$libpth" in +@@ -8860,13 +8843,8 @@ esac + echo " " + case "$sysman" in + '') +- syspath='/usr/share/man/man1 /usr/man/man1' +- syspath="$syspath /usr/man/mann /usr/man/manl /usr/man/local/man1" +- syspath="$syspath /usr/man/u_man/man1" +- syspath="$syspath /usr/catman/u_man/man1 /usr/man/l_man/man1" +- syspath="$syspath /usr/local/man/u_man/man1 /usr/local/man/l_man/man1" +- syspath="$syspath /usr/man/man.L /local/man/man1 /usr/local/man/man1" +- sysman=`./loc . /usr/man/man1 $syspath` ++ syspath='' ++ sysman='' + ;; + esac + if $test -d "$sysman"; then +@@ -21500,9 +21478,10 @@ $rm_try tryp + case "$full_ar" in + '') full_ar=$ar ;; + esac ++full_ar=ar + + : Store the full pathname to the sed program for use in the C program +-full_sed=$sed ++full_sed=sed + + : see what type gids are declared as in the kernel + echo " " +diff --git a/ext/Errno/Errno_pm.PL b/ext/Errno/Errno_pm.PL +index ae647d5f06..9a05d66592 100644 +--- a/ext/Errno/Errno_pm.PL ++++ b/ext/Errno/Errno_pm.PL +@@ -135,12 +135,7 @@ sub get_files { + if ($dep =~ /(\S+errno\.h)/) { + push(@file, $1); + } +- } elsif ($^O eq 'linux' && +- $Config{gccversion} ne '' && +- $Config{gccversion} !~ /intel/i && +- # might be using, say, Intel's icc +- $linux_errno_h +- ) { ++ } elsif (0) { + push(@file, $linux_errno_h); + } elsif ($^O eq 'haiku') { + # hidden in a special place +diff --git a/hints/freebsd.sh b/hints/freebsd.sh +index 4d26835e99..c6d365d84d 100644 +--- a/hints/freebsd.sh ++++ b/hints/freebsd.sh +@@ -127,21 +127,21 @@ case "$osvers" in + objformat=`/usr/bin/objformat` + if [ x$objformat = xaout ]; then + if [ -e /usr/lib/aout ]; then +- libpth="/usr/lib/aout /usr/local/lib /usr/lib" +- glibpth="/usr/lib/aout /usr/local/lib /usr/lib" ++ libpth="" ++ glibpth="" + fi + lddlflags='-Bshareable' + else +- libpth="/usr/lib /usr/local/lib" +- glibpth="/usr/lib /usr/local/lib" ++ libpth="" ++ glibpth="" + ldflags="-Wl,-E " + lddlflags="-shared " + fi + cccdlflags='-DPIC -fPIC' + ;; + *) +- libpth="/usr/lib /usr/local/lib" +- glibpth="/usr/lib /usr/local/lib" ++ libpth="" ++ glibpth="" + ldflags="-Wl,-E " + lddlflags="-shared " + cccdlflags='-DPIC -fPIC' +diff --git a/hints/linux.sh b/hints/linux.sh +index e1508c7509..5a187c583a 100644 +--- a/hints/linux.sh ++++ b/hints/linux.sh +@@ -150,28 +150,6 @@ case "$optimize" in + ;; + esac + +-# Ubuntu 11.04 (and later, presumably) doesn't keep most libraries +-# (such as -lm) in /lib or /usr/lib. So we have to ask gcc to tell us +-# where to look. We don't want gcc's own libraries, however, so we +-# filter those out. +-# This could be conditional on Ubuntu, but other distributions may +-# follow suit, and this scheme seems to work even on rather old gcc's. +-# This unconditionally uses gcc because even if the user is using another +-# compiler, we still need to find the math library and friends, and I don't +-# know how other compilers will cope with that situation. +-# Morever, if the user has their own gcc earlier in $PATH than the system gcc, +-# we don't want its libraries. So we try to prefer the system gcc +-# Still, as an escape hatch, allow Configure command line overrides to +-# plibpth to bypass this check. +-if [ -x /usr/bin/gcc ] ; then +- gcc=/usr/bin/gcc +-# clang also provides -print-search-dirs +-elif ${cc:-cc} --version 2>/dev/null | grep -q '^clang ' ; then +- gcc=${cc:-cc} +-else +- gcc=gcc +-fi +- + case "$plibpth" in + '') plibpth=`LANG=C LC_ALL=C $gcc $ccflags $ldflags -print-search-dirs | grep libraries | + cut -f2- -d= | tr ':' $trnl | grep -v 'gcc' | sed -e 's:/$::'` +@@ -208,32 +186,6 @@ case "$usequadmath" in + ;; + esac + +-case "$libc" in +-'') +-# If you have glibc, then report the version for ./myconfig bug reporting. +-# (Configure doesn't need to know the specific version since it just uses +-# gcc to load the library for all tests.) +-# We don't use __GLIBC__ and __GLIBC_MINOR__ because they +-# are insufficiently precise to distinguish things like +-# libc-2.0.6 and libc-2.0.7. +- for p in $plibpth +- do +- for trylib in libc.so.6 libc.so +- do +- if $test -e $p/$trylib; then +- libc=`ls -l $p/$trylib | awk '{print $NF}'` +- if $test "X$libc" != X; then +- break +- fi +- fi +- done +- if $test "X$libc" != X; then +- break +- fi +- done +- ;; +-esac +- + if ${sh:-/bin/sh} -c exit; then + echo '' + echo 'You appear to have a working bash. Good.' +@@ -311,33 +263,6 @@ sparc*) + ;; + esac + +-# SuSE8.2 has /usr/lib/libndbm* which are ld scripts rather than +-# true libraries. The scripts cause binding against static +-# version of -lgdbm which is a bad idea. So if we have 'nm' +-# make sure it can read the file +-# NI-S 2003/08/07 +-case "$nm" in +- '') ;; +- *) +- for p in $plibpth +- do +- if $test -r $p/libndbm.so; then +- if $nm $p/libndbm.so >/dev/null 2>&1 ; then +- echo 'Your shared -lndbm seems to be a real library.' +- _libndbm_real=1 +- break +- fi +- fi +- done +- if $test "X$_libndbm_real" = X; then +- echo 'Your shared -lndbm is not a real library.' +- set `echo X "$libswanted "| sed -e 's/ ndbm / /'` +- shift +- libswanted="$*" +- fi +- ;; +-esac +- + # Linux on Synology. + if [ -f /etc/synoinfo.conf -a -d /usr/syno ]; then + # Tested on Synology DS213 and DS413 diff --git a/nixpkgs/pkgs/development/interpreters/php/8.2.nix b/nixpkgs/pkgs/development/interpreters/php/8.2.nix index b27d3539e653..d80269d4ae7d 100644 --- a/nixpkgs/pkgs/development/interpreters/php/8.2.nix +++ b/nixpkgs/pkgs/development/interpreters/php/8.2.nix @@ -2,8 +2,8 @@ let base = callPackage ./generic.nix (_args // { - version = "8.2.8"; - hash = "sha256-mV7UAJx5F8li0xg3oaNljzbUr081e2c8l//b5kA/hRc="; + version = "8.2.9"; + hash = "sha256-SEYLmUrn61CWoxD0TRPoZd4XcRBNSlUNUwcr5YpvF2w="; }); in diff --git a/nixpkgs/pkgs/development/interpreters/php/generic.nix b/nixpkgs/pkgs/development/interpreters/php/generic.nix index 4a563d4fd70e..d60d0cdf1fd1 100644 --- a/nixpkgs/pkgs/development/interpreters/php/generic.nix +++ b/nixpkgs/pkgs/development/interpreters/php/generic.nix @@ -85,7 +85,7 @@ let php-packages = (callPackage ../../../top-level/php-packages.nix { phpPackage = phpWithExtensions; - }).overrideScope' packageOverrides; + }).overrideScope packageOverrides; allExtensionFunctions = prevExtensionFunctions ++ [ extensions ]; enabledExtensions = diff --git a/nixpkgs/pkgs/development/interpreters/python/cpython/default.nix b/nixpkgs/pkgs/development/interpreters/python/cpython/default.nix index f84cca760f86..a491c6c1d619 100644 --- a/nixpkgs/pkgs/development/interpreters/python/cpython/default.nix +++ b/nixpkgs/pkgs/development/interpreters/python/cpython/default.nix @@ -184,6 +184,8 @@ let if parsed.cpu.significantByte.name == "littleEndian" then "arm" else "armeb" else if isx86_32 then "i386" else parsed.cpu.name; + # Python doesn't distinguish musl and glibc and always prefixes with "gnu" + gnuAbiName = replaceStrings [ "musl" ] [ "gnu" ] parsed.abi.name; pythonAbiName = # python's build doesn't support every gnu<extension>, and doesn't # differentiate between musl and glibc, so we list those supported in @@ -191,7 +193,7 @@ let # https://github.com/python/cpython/blob/e488e300f5c01289c10906c2e53a8e43d6de32d8/configure.ac#L724 # Note: this is an approximation, as it doesn't take into account the CPU # family, or the nixpkgs abi naming conventions. - if elem parsed.abi.name [ + if elem gnuAbiName [ "gnux32" "gnueabihf" "gnueabi" @@ -199,7 +201,7 @@ let "gnuabi64" "gnuspe" ] - then parsed.abi.name + then gnuAbiName else "gnu"; multiarch = if isDarwin then "darwin" @@ -439,6 +441,7 @@ in with passthru; stdenv.mkDerivation { ln -s "$out/bin/python3" "$out/bin/python" ln -s "$out/bin/python3-config" "$out/bin/python-config" ln -s "$out/lib/pkgconfig/python3.pc" "$out/lib/pkgconfig/python.pc" + ln -sL "$out/share/man/man1/python3.1.gz" "$out/share/man/man1/python.1.gz" # Get rid of retained dependencies on -dev packages, and remove # some $TMPDIR references to improve binary reproducibility. @@ -572,6 +575,6 @@ in with passthru; stdenv.mkDerivation { license = licenses.psfl; platforms = platforms.linux ++ platforms.darwin; maintainers = with maintainers; [ fridh ]; - mainProgram = "python3"; + mainProgram = executable; }; } diff --git a/nixpkgs/pkgs/development/interpreters/python/default.nix b/nixpkgs/pkgs/development/interpreters/python/default.nix index 8ea1c14c7111..fb504c5043c8 100644 --- a/nixpkgs/pkgs/development/interpreters/python/default.nix +++ b/nixpkgs/pkgs/development/interpreters/python/default.nix @@ -5,7 +5,7 @@ , db , lib , libffiBoot -, makeScopeWithSplicing +, makeScopeWithSplicing' , pythonPackagesExtensions , stdenv }@args: diff --git a/nixpkgs/pkgs/development/interpreters/python/hooks/default.nix b/nixpkgs/pkgs/development/interpreters/python/hooks/default.nix index 001e477b9185..46b01999f96c 100644 --- a/nixpkgs/pkgs/development/interpreters/python/hooks/default.nix +++ b/nixpkgs/pkgs/development/interpreters/python/hooks/default.nix @@ -1,9 +1,9 @@ -self: super: with self; +self: dontUse: with self; let - pythonInterpreter = super.python.pythonForBuild.interpreter; - pythonSitePackages = super.python.sitePackages; - pythonCheckInterpreter = super.python.interpreter; + pythonInterpreter = python.pythonForBuild.interpreter; + pythonSitePackages = python.sitePackages; + pythonCheckInterpreter = python.interpreter; setuppy = ../run_setup.py; in { makePythonHook = args: pkgs.makeSetupHook ({passthru.provides.setupHook = true; } // args); @@ -62,6 +62,16 @@ in { }; } ./pip-build-hook.sh) {}; + pypaBuildHook = callPackage ({ makePythonHook, build, wheel }: + makePythonHook { + name = "pypa-build-hook.sh"; + propagatedBuildInputs = [ build wheel ]; + substitutions = { + inherit pythonInterpreter; + }; + } ./pypa-build-hook.sh) {}; + + pipInstallHook = callPackage ({ makePythonHook, pip }: makePythonHook { name = "pip-install-hook"; @@ -97,11 +107,12 @@ in { }; } ./python-imports-check-hook.sh) {}; - pythonNamespacesHook = callPackage ({ makePythonHook, findutils }: + pythonNamespacesHook = callPackage ({ makePythonHook, buildPackages }: makePythonHook { name = "python-namespaces-hook.sh"; substitutions = { - inherit pythonSitePackages findutils; + inherit pythonSitePackages; + inherit (buildPackages) findutils; }; } ./python-namespaces-hook.sh) {}; @@ -160,6 +171,20 @@ in { }; } ./setuptools-check-hook.sh) {}; + setuptoolsRustBuildHook = callPackage ({ makePythonHook, setuptools-rust, rust }: + makePythonHook { + name = "setuptools-rust-setup-hook"; + propagatedBuildInputs = [ setuptools-rust ]; + substitutions = { + pyLibDir = "${python}/lib/${python.libPrefix}"; + cargoBuildTarget = rust.toRustTargetSpec stdenv.hostPlatform; + cargoLinkerVar = lib.toUpper ( + builtins.replaceStrings ["-"] ["_"] ( + rust.toRustTarget stdenv.hostPlatform)); + targetLinker = "${stdenv.cc}/bin/${stdenv.cc.targetPrefix}cc"; + }; + } ./setuptools-rust-hook.sh) {}; + unittestCheckHook = callPackage ({ makePythonHook }: makePythonHook { name = "unittest-check-hook"; diff --git a/nixpkgs/pkgs/development/interpreters/python/hooks/pip-build-hook.sh b/nixpkgs/pkgs/development/interpreters/python/hooks/pip-build-hook.sh index 745f02e8c9bc..9de4c7d1dd0d 100644 --- a/nixpkgs/pkgs/development/interpreters/python/hooks/pip-build-hook.sh +++ b/nixpkgs/pkgs/development/interpreters/python/hooks/pip-build-hook.sh @@ -1,13 +1,22 @@ # Setup hook to use for pip projects echo "Sourcing pip-build-hook" +declare -a pipBuildFlags + pipBuildPhase() { echo "Executing pipBuildPhase" runHook preBuild mkdir -p dist echo "Creating a wheel..." - @pythonInterpreter@ -m pip wheel --verbose --no-index --no-deps --no-clean --no-build-isolation --wheel-dir dist . + @pythonInterpreter@ -m pip wheel \ + --verbose \ + --no-index \ + --no-deps \ + --no-clean \ + --no-build-isolation \ + --wheel-dir dist \ + $pipBuildFlags . echo "Finished creating a wheel..." runHook postBuild diff --git a/nixpkgs/pkgs/development/interpreters/python/hooks/pypa-build-hook.sh b/nixpkgs/pkgs/development/interpreters/python/hooks/pypa-build-hook.sh new file mode 100644 index 000000000000..3b7130049769 --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/python/hooks/pypa-build-hook.sh @@ -0,0 +1,19 @@ +# Setup hook to use for pypa/build projects +echo "Sourcing pypa-build-hook" + +pypaBuildPhase() { + echo "Executing pypaBuildPhase" + runHook preBuild + + echo "Creating a wheel..." + @pythonInterpreter@ -m build --no-isolation --outdir dist/ --wheel $pypaBuildFlags + echo "Finished creating a wheel..." + + runHook postBuild + echo "Finished executing pypaBuildPhase" +} + +if [ -z "${dontUsePypaBuild-}" ] && [ -z "${buildPhase-}" ]; then + echo "Using pypaBuildPhase" + buildPhase=pypaBuildPhase +fi diff --git a/nixpkgs/pkgs/development/interpreters/python/hooks/setuptools-rust-hook.sh b/nixpkgs/pkgs/development/interpreters/python/hooks/setuptools-rust-hook.sh new file mode 100644 index 000000000000..917c19ef9b31 --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/python/hooks/setuptools-rust-hook.sh @@ -0,0 +1,18 @@ +echo "Sourcing setuptools-rust-hook" + +setuptoolsRustSetup() { + # This can work only if rustPlatform.cargoSetupHook is also included + if ! command -v cargoSetupPostPatchHook >/dev/null; then + echo "ERROR: setuptools-rust has to be used alongside with rustPlatform.cargoSetupHook!" + exit 1 + fi + + export PYO3_CROSS_LIB_DIR="@pyLibDir@" + export CARGO_BUILD_TARGET=@cargoBuildTarget@ + # TODO theoretically setting linker should not be required because it is + # already set in pkgs/build-support/rust/hooks/default.nix but build fails + # on missing linker without this. + export CARGO_TARGET_@cargoLinkerVar@_LINKER=@targetLinker@ +} + +preConfigureHooks+=(setuptoolsRustSetup) diff --git a/nixpkgs/pkgs/development/interpreters/python/passthrufun.nix b/nixpkgs/pkgs/development/interpreters/python/passthrufun.nix index d4b5428c3184..7a38308800a0 100644 --- a/nixpkgs/pkgs/development/interpreters/python/passthrufun.nix +++ b/nixpkgs/pkgs/development/interpreters/python/passthrufun.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, callPackage, pythonPackagesExtensions, config, makeScopeWithSplicing, ... }: +{ lib, stdenv, callPackage, pythonPackagesExtensions, config, makeScopeWithSplicing', ... }: { implementation , libPrefix @@ -47,12 +47,12 @@ selfTargetTarget = pythonOnTargetForTarget.pkgs or {}; # There is no Python TargetTarget. }; hooks = import ./hooks/default.nix; - keep = lib.extends hooks pythonPackagesFun; - extra = _: {}; + keep = self: hooks self {}; optionalExtensions = cond: as: lib.optionals cond as; pythonExtension = import ../../../top-level/python-packages.nix; python2Extension = import ../../../top-level/python2-packages.nix; extensions = lib.composeManyExtensions ([ + hooks pythonExtension ] ++ (optionalExtensions (!self.isPy3k) [ python2Extension @@ -60,12 +60,10 @@ overrides ]); aliases = self: super: lib.optionalAttrs config.allowAliases (import ../../../top-level/python-aliases.nix lib self super); - in makeScopeWithSplicing - otherSplices - keep - extra - (lib.extends (lib.composeExtensions aliases extensions) keep)) - { + in makeScopeWithSplicing' { + inherit otherSplices keep; + f = lib.extends (lib.composeExtensions aliases extensions) pythonPackagesFun; + }) { overrides = packageOverrides; python = self; }); diff --git a/nixpkgs/pkgs/development/interpreters/python/tests.nix b/nixpkgs/pkgs/development/interpreters/python/tests.nix index 4ba1b757c3f6..d2bab1b0c8d3 100644 --- a/nixpkgs/pkgs/development/interpreters/python/tests.nix +++ b/nixpkgs/pkgs/development/interpreters/python/tests.nix @@ -114,6 +114,10 @@ let nix-pythonprefix-mypy = callPackage ./tests/test_nix_pythonprefix { interpreter = python; }; + # Make sure tkinter is importable. See https://github.com/NixOS/nixpkgs/issues/238990 + tkinter = callPackage ./tests/test_tkinter { + interpreter = python; + }; } ); diff --git a/nixpkgs/pkgs/development/interpreters/python/tests/test_tkinter/default.nix b/nixpkgs/pkgs/development/interpreters/python/tests/test_tkinter/default.nix new file mode 100644 index 000000000000..67e67d2d1e97 --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/python/tests/test_tkinter/default.nix @@ -0,0 +1,17 @@ +{ interpreter, writeText, runCommand }: + +let + + pythonEnv = interpreter.withPackages(ps: [ + ps.tkinter + ]); + + pythonScript = writeText "myscript.py" '' + import tkinter + print(tkinter) + ''; + +in runCommand "${interpreter.name}-tkinter-test" {} '' + ${pythonEnv}/bin/python ${pythonScript} + touch $out +'' diff --git a/nixpkgs/pkgs/development/interpreters/racket/default.nix b/nixpkgs/pkgs/development/interpreters/racket/default.nix index eac454d39005..9b0bb014e1ef 100644 --- a/nixpkgs/pkgs/development/interpreters/racket/default.nix +++ b/nixpkgs/pkgs/development/interpreters/racket/default.nix @@ -50,7 +50,7 @@ in stdenv.mkDerivation rec { pname = "racket"; - version = "8.9"; # always change at once with ./minimal.nix + version = "8.10"; # always change at once with ./minimal.nix src = (lib.makeOverridable ({ name, sha256 }: fetchurl { @@ -59,7 +59,7 @@ stdenv.mkDerivation rec { } )) { name = "${pname}-${version}"; - sha256 = "sha256-OuIl6E4Rn0zRpH8bFhM1aPx9NcKQxQVJVWbZ3M78UiQ="; + sha256 = "sha256-Dklj2iwX5/bVdCi9odz2Ttp0N+Lya7bMSLR/QXo9k6M="; }; FONTCONFIG_FILE = fontsConf; @@ -149,6 +149,7 @@ stdenv.mkDerivation rec { GUIs and charts. ''; homepage = "https://racket-lang.org/"; + changelog = "https://github.com/racket/racket/releases/tag/v${version}"; license = with licenses; [ asl20 /* or */ mit ]; maintainers = with maintainers; [ henrytill vrthra ]; platforms = [ "x86_64-darwin" "x86_64-linux" "aarch64-linux" "aarch64-darwin" ]; diff --git a/nixpkgs/pkgs/development/interpreters/racket/minimal.nix b/nixpkgs/pkgs/development/interpreters/racket/minimal.nix index 29baef2087f1..ce58aec92108 100644 --- a/nixpkgs/pkgs/development/interpreters/racket/minimal.nix +++ b/nixpkgs/pkgs/development/interpreters/racket/minimal.nix @@ -6,7 +6,7 @@ racket.overrideAttrs (oldAttrs: rec { version = oldAttrs.version; src = oldAttrs.src.override { name = "${pname}-${version}"; - sha256 = "sha256-mAvwer///Oz2w/Sf4tIo+DyS6wib8P85G+q9waDri3Q="; + sha256 = "sha256-k1NzmkiYgPkP42U+08Ljjb3FEU7OM3lEaXsLH29hveA="; }; meta = oldAttrs.meta // { diff --git a/nixpkgs/pkgs/development/interpreters/rakudo/zef.nix b/nixpkgs/pkgs/development/interpreters/rakudo/zef.nix index 37132f17c016..103f5c5afa8e 100644 --- a/nixpkgs/pkgs/development/interpreters/rakudo/zef.nix +++ b/nixpkgs/pkgs/development/interpreters/rakudo/zef.nix @@ -2,13 +2,13 @@ stdenv.mkDerivation rec { pname = "zef"; - version = "0.18.2"; + version = "0.18.3"; src = fetchFromGitHub { owner = "ugexe"; repo = "zef"; rev = "v${version}"; - sha256 = "sha256-0EWajziWoxWLGaj54FfvEMNPPTc2Wb6O050o2qWGJ9c="; + sha256 = "sha256-/H8wHDMl2lJElsjNcNmTrijIeL1ohOkDzrO7LuOPhi4="; }; nativeBuildInputs = [ makeWrapper ]; diff --git a/nixpkgs/pkgs/development/interpreters/renpy/default.nix b/nixpkgs/pkgs/development/interpreters/renpy/default.nix index 3d4ee70e7a04..4bbeb224ce3d 100644 --- a/nixpkgs/pkgs/development/interpreters/renpy/default.nix +++ b/nixpkgs/pkgs/development/interpreters/renpy/default.nix @@ -8,8 +8,8 @@ let # base_version is of the form major.minor.patch # vc_version is of the form YYMMDDCC # version corresponds to the tag on GitHub - base_version = "8.1.0"; - vc_version = "23051307"; + base_version = "8.1.1"; + vc_version = "23060707"; in stdenv.mkDerivation rec { pname = "renpy"; @@ -19,7 +19,7 @@ in stdenv.mkDerivation rec { owner = "renpy"; repo = "renpy"; rev = version; - sha256 = "sha256-5EU4jaBTU+a9UNHRs7xrKQ7ZivhDEqisO3l4W2E6F+c="; + sha256 = "sha256-aJ/MobZ6SNBYRC/EpUxAMLJ3pwK6PC92DV0YL/LF5Ew="; }; nativeBuildInputs = [ @@ -49,9 +49,11 @@ in stdenv.mkDerivation rec { cp tutorial/game/tutorial_director.rpy{m,} cat > renpy/vc_version.py << EOF - vc_version = ${vc_version} + version = '${version}' official = False nightly = False + # Look at https://renpy.org/latest.html for what to put. + version_name = 'Where No One Has Gone Before' EOF ''; diff --git a/nixpkgs/pkgs/development/interpreters/renpy/renpy-system-fribidi.diff b/nixpkgs/pkgs/development/interpreters/renpy/renpy-system-fribidi.diff deleted file mode 100644 index 8c93b75a7b0f..000000000000 --- a/nixpkgs/pkgs/development/interpreters/renpy/renpy-system-fribidi.diff +++ /dev/null @@ -1,51 +0,0 @@ -diff --git a/module/renpybidicore.c b/module/renpybidicore.c -index 849430d..d883a52 100644 ---- a/module/renpybidicore.c -+++ b/module/renpybidicore.c -@@ -1,10 +1,6 @@ - #include <Python.h> - --#ifdef RENPY_BUILD - #include <fribidi.h> --#else --#include <fribidi-src/lib/fribidi.h> --#endif - - #include <stdlib.h> - -diff --git a/module/setup.py b/module/setup.py -index bd16816..f6b8794 100755 ---- a/module/setup.py -+++ b/module/setup.py -@@ -118,29 +118,17 @@ cython( - sdl + [ png, 'z', 'm' ]) - - FRIBIDI_SOURCES = """ --fribidi-src/lib/fribidi.c --fribidi-src/lib/fribidi-arabic.c --fribidi-src/lib/fribidi-bidi.c --fribidi-src/lib/fribidi-bidi-types.c --fribidi-src/lib/fribidi-deprecated.c --fribidi-src/lib/fribidi-joining.c --fribidi-src/lib/fribidi-joining-types.c --fribidi-src/lib/fribidi-mem.c --fribidi-src/lib/fribidi-mirroring.c --fribidi-src/lib/fribidi-run.c --fribidi-src/lib/fribidi-shape.c - renpybidicore.c - """.split() - cython( - "_renpybidi", - FRIBIDI_SOURCES, -+ ["fribidi"], - includes=[ -- BASE + "/fribidi-src/", -- BASE + "/fribidi-src/lib/", -+ "@fribidi@/include/fribidi/", - ], - define_macros=[ - ("FRIBIDI_ENTRY", ""), -- ("HAVE_CONFIG_H", "1"), - ]) - - if not (android or ios or emscripten): diff --git a/nixpkgs/pkgs/development/interpreters/risor/default.nix b/nixpkgs/pkgs/development/interpreters/risor/default.nix new file mode 100644 index 000000000000..61753ba2b99e --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/risor/default.nix @@ -0,0 +1,45 @@ +{ lib +, buildGoModule +, fetchFromGitHub +, testers +, risor +}: + +buildGoModule rec { + pname = "risor"; + version = "0.14.0"; + + src = fetchFromGitHub { + owner = "risor-io"; + repo = "risor"; + rev = "v${version}"; + hash = "sha256-QhXIwFrApSkWY2YYYGlojKsByNA2xpyVTm0SpYWB/Ds="; + }; + + vendorHash = "sha256-diAbQwnlhMm43ZlLKq3llMl9mO3sIkc80aCI5UDn7F4="; + + subPackages = [ + "cmd/..." + ]; + + ldflags = [ + "-s" + "-w" + "-X=main.version=${version}" + ]; + + passthru.tests = { + version = testers.testVersion { + package = risor; + command = "risor version"; + }; + }; + + meta = with lib; { + description = "Fast and flexible scripting for Go developers and DevOps"; + homepage = "https://github.com/risor-io/risor"; + changelog = "https://github.com/risor-io/risor/releases/tag/${src.rev}"; + license = licenses.asl20; + maintainers = with maintainers; [ figsoda ]; + }; +} diff --git a/nixpkgs/pkgs/development/interpreters/ruby/rubygems/default.nix b/nixpkgs/pkgs/development/interpreters/ruby/rubygems/default.nix index e99155f0f3a7..11119b768825 100644 --- a/nixpkgs/pkgs/development/interpreters/ruby/rubygems/default.nix +++ b/nixpkgs/pkgs/development/interpreters/ruby/rubygems/default.nix @@ -2,11 +2,11 @@ stdenv.mkDerivation rec { pname = "rubygems"; - version = "3.4.17"; + version = "3.4.18"; src = fetchurl { url = "https://rubygems.org/rubygems/rubygems-${version}.tgz"; - hash = "sha256-SvqqlGPiqHeZQ0Mvulbgc5bM7E1O3HK7BtnbiscG0vE="; + hash = "sha256-+yHTJWedZNCkkRMIRT103QMTFJODlbJ2PwVbTghEo0M="; }; patches = [ diff --git a/nixpkgs/pkgs/development/interpreters/trealla/default.nix b/nixpkgs/pkgs/development/interpreters/trealla/default.nix index 2fc3da05786b..4c04940470e0 100644 --- a/nixpkgs/pkgs/development/interpreters/trealla/default.nix +++ b/nixpkgs/pkgs/development/interpreters/trealla/default.nix @@ -6,23 +6,24 @@ , readline , valgrind , xxd +, gitUpdater , checkLeaks ? false , enableFFI ? true , enableSSL ? true , enableThreads ? true -, lineEditingLibrary ? "readline" +, lineEditingLibrary ? "isocline" }: assert lib.elem lineEditingLibrary [ "isocline" "readline" ]; stdenv.mkDerivation (finalAttrs: { pname = "trealla"; - version = "2.23.35"; + version = "2.24.21"; src = fetchFromGitHub { owner = "trealla-prolog"; repo = "trealla"; rev = "v${finalAttrs.version}"; - hash = "sha256-yCVBjxO9tEKlyWo6RlK4EdyUxCkxp0z2EzJ2np0xOUU="; + hash = "sha256-zpHdZiDtNcQko+gn92fiGWSvYT4aQ4t6nYFwf6zu0cA="; }; postPatch = '' @@ -41,9 +42,9 @@ stdenv.mkDerivation (finalAttrs: { ++ lib.optional enableSSL openssl ++ lib.optional (lineEditingLibrary == "readline") readline; - checkInputs = lib.optionals finalAttrs.doCheck [ valgrind ]; + nativeCheckInputs = lib.optionals finalAttrs.doCheck [ valgrind ]; - dontConfigure = true; + strictDeps = true; makeFlags = [ "GIT_VERSION=\"v${finalAttrs.version}\"" @@ -67,7 +68,9 @@ stdenv.mkDerivation (finalAttrs: { "test" ] ++ lib.optional checkLeaks "leaks"; - meta = { + passthru.updateScript = gitUpdater { }; + + meta = { homepage = "https://trealla-prolog.github.io/trealla/"; description = "A compact, efficient Prolog interpreter written in ANSI C"; longDescription = '' diff --git a/nixpkgs/pkgs/development/interpreters/wazero/default.nix b/nixpkgs/pkgs/development/interpreters/wazero/default.nix index f72f4be1fc50..880dbf321f82 100644 --- a/nixpkgs/pkgs/development/interpreters/wazero/default.nix +++ b/nixpkgs/pkgs/development/interpreters/wazero/default.nix @@ -7,13 +7,13 @@ buildGoModule rec { pname = "wazero"; - version = "1.3.1"; + version = "1.4.0"; src = fetchFromGitHub { owner = "tetratelabs"; repo = "wazero"; rev = "v${version}"; - hash = "sha256-gLiUEJdO/2btZb5D9O1r+uF3ZVBN4Oy3dFwqUNQRoW8="; + hash = "sha256-Yn5mg/K+RT6CoW1vMrpvRFOao83IAZE1mP+DGp4SmKk="; }; vendorHash = null; diff --git a/nixpkgs/pkgs/development/interpreters/yaegi/default.nix b/nixpkgs/pkgs/development/interpreters/yaegi/default.nix new file mode 100644 index 000000000000..dcde678338f0 --- /dev/null +++ b/nixpkgs/pkgs/development/interpreters/yaegi/default.nix @@ -0,0 +1,45 @@ +{ lib +, buildGoModule +, fetchFromGitHub +, testers +, yaegi +}: + +buildGoModule rec { + pname = "yaegi"; + version = "0.15.1"; + + src = fetchFromGitHub { + owner = "traefik"; + repo = "yaegi"; + rev = "v${version}"; + hash = "sha256-ZV1HidHJvwum18QIIwQiCcRcitZdHk5+FxkPs6YgDac="; + }; + + vendorHash = null; + + subPackages = [ + "cmd/yaegi" + ]; + + ldflags = [ + "-s" + "-w" + "-X=main.version=${version}" + ]; + + passthru.tests = { + version = testers.testVersion { + package = yaegi; + command = "yaegi version"; + }; + }; + + meta = with lib; { + description = "A Go interpreter"; + homepage = "https://github.com/traefik/yaegi"; + changelog = "https://github.com/traefik/yaegi/releases/tag/${src.rev}"; + license = licenses.asl20; + maintainers = with maintainers; [ figsoda ]; + }; +} |