Merge staging-next into staging

This commit is contained in:
github-actions[bot] 2024-06-15 06:01:20 +00:00 committed by GitHub
commit 520c7e2ee8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
41 changed files with 1420 additions and 155 deletions

View File

@ -7154,6 +7154,13 @@
githubId = 77672306;
name = "Florian Agbuya";
};
fsnkty = {
name = "fsnkty";
github = "fsnkty";
githubId = 153512689;
email = "fsnkty@shimeji.cafe";
matrix = "@nuko:shimeji.cafe";
};
fstamour = {
email = "fr.st-amour@gmail.com";
github = "fstamour";
@ -15239,13 +15246,6 @@
github = "numkem";
githubId = 332423;
};
nu-nu-ko = {
email = "nuko@shimeji.cafe";
matrix = "@nuko:shimeji.cafe";
github = "nu-nu-ko";
githubId = 153512689;
name = "nuko";
};
nviets = {
email = "nathan.g.viets@gmail.com";
github = "nviets";

View File

@ -157,5 +157,5 @@ in
networking.firewall.allowedTCPPorts = mkIf cfg.openFirewall [ cfg.settings.Port ];
};
meta.maintainers = with maintainers; [ nu-nu-ko ];
meta.maintainers = with maintainers; [ fsnkty ];
}

View File

@ -160,5 +160,5 @@ in
};
meta.maintainers = with maintainers; [ minijackson nu-nu-ko ];
meta.maintainers = with maintainers; [ minijackson fsnkty ];
}

View File

@ -101,7 +101,7 @@ in
config = {
# Note: this is set here rather than up there so that changing
# nixos.label would not rebuild manual pages
services.getty.greetingLine = mkDefault ''<<< Welcome to NixOS ${config.system.nixos.label} (\m) - \l >>>'';
services.getty.greetingLine = mkDefault ''<<< Welcome to ${config.system.nixos.distroName} ${config.system.nixos.label} (\m) - \l >>>'';
services.getty.helpLine = mkIf (config.documentation.nixos.enable && config.documentation.doc.enable) "\nRun 'nixos-help' for the NixOS manual.";
systemd.services."getty@" =
@ -158,4 +158,5 @@ in
};
meta.maintainers = with maintainers; [ RossComputerGuy ];
}

View File

@ -1229,7 +1229,7 @@ dependencies = [
[[package]]
name = "wireplumber"
version = "0.1.0"
source = "git+https://github.com/arcnmx/wireplumber.rs.git?rev=341b0c4e8d177f5f21c109cf88cca4f2dc1f853a#341b0c4e8d177f5f21c109cf88cca4f2dc1f853a"
source = "git+https://github.com/arcnmx/wireplumber.rs.git?rev=2c0ee463d029d3562ee66db90554c5af573565c1#2c0ee463d029d3562ee66db90554c5af573565c1"
dependencies = [
"bitflags 2.4.1",
"gio",
@ -1245,7 +1245,7 @@ dependencies = [
[[package]]
name = "wireplumber-sys"
version = "0.1.0"
source = "git+https://github.com/arcnmx/wireplumber.rs.git?rev=341b0c4e8d177f5f21c109cf88cca4f2dc1f853a#341b0c4e8d177f5f21c109cf88cca4f2dc1f853a"
source = "git+https://github.com/arcnmx/wireplumber.rs.git?rev=2c0ee463d029d3562ee66db90554c5af573565c1#2c0ee463d029d3562ee66db90554c5af573565c1"
dependencies = [
"gio-sys",
"glib-sys",

View File

@ -34,19 +34,19 @@ let
in
stdenv.mkDerivation rec {
pname = "pwvucontrol";
version = "0.4.1";
version = "0.4.2";
src = fetchFromGitHub {
owner = "saivert";
repo = "pwvucontrol";
rev = version;
hash = "sha256-soxB8pbbyYe1EXtopq1OjoklEDJrwK6od4nFLDwb8LY=";
hash = "sha256-cWNWdCMk9hF8Nzq2UFBEKSx1zS8JlplMG7B5gv7BaZA=";
};
cargoDeps = rustPlatform.importCargoLock {
lockFile = ./Cargo.lock;
outputHashes = {
"wireplumber-0.1.0" = "sha256-+LZ8xKok2AOegW8WvfrfZGXuQB4xHrLNshcTOHab+xQ=";
"wireplumber-0.1.0" = "sha256-r3p4OpmMgiFgjn1Fj4LeMOhx6R2UWollIdJRy/0kiNM=";
};
};
@ -77,7 +77,7 @@ stdenv.mkDerivation rec {
description = "Pipewire Volume Control";
homepage = "https://github.com/saivert/pwvucontrol";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ figsoda ];
maintainers = with maintainers; [ figsoda Guanran928 ];
mainProgram = "pwvucontrol";
platforms = platforms.linux;
};

View File

@ -21,17 +21,17 @@
ungoogled-chromium = {
deps = {
gn = {
hash = "sha256-lrVAb6La+cvuUCNI90O6M/sheOEVFTjgpfA3O/6Odp0=";
rev = "d823fd85da3fb83146f734377da454473b93a2b2";
hash = "sha256-mNoQeHSSM+rhR0UHrpbyzLJC9vFqfxK1SD0X8GiRsqw=";
rev = "df98b86690c83b81aedc909ded18857296406159";
url = "https://gn.googlesource.com/gn";
version = "2024-04-10";
version = "2024-05-13";
};
ungoogled-patches = {
hash = "sha256-ZYYizL3hFSEQUdDDZIvsEzidq5td+UoaWdertY/pqOc=";
rev = "125.0.6422.141-1";
hash = "sha256-2Yt91vWR5SYLBTO+PIEgFswkvwxJsNpKidOwxUBgLeg=";
rev = "126.0.6478.55-1";
};
};
hash = "sha256-8Qe1hgDEjvdAf2ao4CIieC7l2pTSIPLTZb+vdctUEo0=";
version = "125.0.6422.141";
hash = "sha256-nXRzISkU37TIgV8rjO0qgnhq8uM37M6IpMoGHdsOGIM=";
version = "126.0.6478.55";
};
}

View File

@ -24,13 +24,13 @@
}:
stdenv.mkDerivation (finalAttrs: {
pname = "hyprpicker" + lib.optionalString debug "-debug";
version = "0.2.0";
version = "0.3.0";
src = fetchFromGitHub {
owner = "hyprwm";
repo = finalAttrs.pname;
rev = "v${finalAttrs.version}";
hash = "sha256-bys8S7wuY9FJRLD5WriktWED5Hi7nCKSiNbs1Rvfk4s=";
hash = "sha256-BYQF1zM6bJ44ag9FJ0aTSkhOTY9U7uRdp3SmRCs5fJM=";
};
cmakeBuildType = if debug then "Debug" else "Release";
@ -60,31 +60,9 @@ stdenv.mkDerivation (finalAttrs: {
util-linux
];
configurePhase = ''
runHook preConfigure
make protocols
runHook postConfigure
'';
buildPhase = ''
runHook preBuild
make release
runHook postBuild
'';
installPhase = ''
runHook preInstall
mkdir -p $out/{bin,share/licenses}
install -Dm755 build/hyprpicker -t $out/bin
install -Dm644 LICENSE -t $out/share/licenses/hyprpicker
runHook postInstall
postInstall = ''
mkdir -p $out/share/licenses
install -Dm644 $src/LICENSE -t $out/share/licenses/hyprpicker
'';
meta = with lib; {

View File

@ -67,6 +67,20 @@ let
exit 1
fi
'';
# https://github.com/dart-lang/pub/blob/e1fbda73d1ac597474b82882ee0bf6ecea5df108/lib/src/sdk/dart.dart#L80
"dart" = name: runCommand "dart-sdk-${name}" { passthru.packageRoot = "."; } ''
for path in '${flutter.dart}/pkg/${name}'; do
if [ -d "$path" ]; then
ln -s "$path" "$out"
break
fi
done
if [ ! -e "$out" ]; then
echo 1>&2 'The Dart SDK does not contain the requested package: ${name}!'
exit 1
fi
'';
};
extraPackageConfigSetup = ''

View File

@ -7,13 +7,13 @@
stdenvNoCC.mkDerivation {
pname = "ananicy-rules-cachyos";
version = "0-unstable-2024-06-07";
version = "0-unstable-2024-06-14";
src = fetchFromGitHub {
owner = "CachyOS";
repo = "ananicy-rules";
rev = "38b3e8c12801df68ba15c2d96ee96d7d2362b576";
hash = "sha256-yVKzkASMzJDmgzS0CxEFky2Y4Bs4vlbRJgUI+uG3muY=";
rev = "e3638ebb2320202ede9facfc9657cc8af2098a2d";
hash = "sha256-lIhXeqPJKC3brxVhIK04K9AAU+RqqqOwN/gUevYmaDM=";
};
dontConfigure = true;

View File

@ -28,7 +28,7 @@ rustPlatform.buildRustPackage rec {
description = "Multi-Monitor Wallpaper Utility";
homepage = "https://github.com/0xk1f0/rwpspread";
license = lib.licenses.gpl3Only;
maintainers = with lib.maintainers; [ nu-nu-ko ];
maintainers = with lib.maintainers; [ fsnkty ];
platforms = lib.platforms.linux;
mainProgram = "rwpspread";
};

View File

@ -33,7 +33,7 @@ rustPlatform.buildRustPackage rec {
homepage = "https://github.com/danyspin97/wpaperd";
license = licenses.gpl3Plus;
platforms = platforms.linux;
maintainers = with maintainers; [ DPDmancul nu-nu-ko ];
maintainers = with maintainers; [ DPDmancul fsnkty ];
mainProgram = "wpaperd";
};
}

View File

@ -14,28 +14,29 @@ let
, patches
, pubspecLock
, artifactHashes
, channel
}:
let
args = {
inherit version engineVersion patches pubspecLock artifactHashes;
inherit version engineVersion patches pubspecLock artifactHashes channel;
dart = dart.override {
version = dartVersion;
sources = {
"${dartVersion}-x86_64-linux" = fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-linux-x64-release.zip";
url = "https://storage.googleapis.com/dart-archive/channels/${channel}/release/${dartVersion}/sdk/dartsdk-linux-x64-release.zip";
sha256 = dartHash.x86_64-linux;
};
"${dartVersion}-aarch64-linux" = fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-linux-arm64-release.zip";
url = "https://storage.googleapis.com/dart-archive/channels/${channel}/release/${dartVersion}/sdk/dartsdk-linux-arm64-release.zip";
sha256 = dartHash.aarch64-linux;
};
"${dartVersion}-x86_64-darwin" = fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-macos-x64-release.zip";
url = "https://storage.googleapis.com/dart-archive/channels/${channel}/release/${dartVersion}/sdk/dartsdk-macos-x64-release.zip";
sha256 = dartHash.x86_64-darwin;
};
"${dartVersion}-aarch64-darwin" = fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-macos-arm64-release.zip";
url = "https://storage.googleapis.com/dart-archive/channels/${channel}/release/${dartVersion}/sdk/dartsdk-macos-arm64-release.zip";
sha256 = dartHash.aarch64-darwin;
};
};
@ -65,8 +66,12 @@ let
patches = (getPatches ./patches) ++ (getPatches (versionDir + "/patches"));
} // data))))
(builtins.readDir ./versions);
stableFlutterVersions = lib.attrsets.filterAttrs (_: v: v.channel == "stable") flutterVersions;
betaFlutterVersions = lib.attrsets.filterAttrs (_: v: v.channel == "beta") flutterVersions;
in
flutterVersions // {
stable = flutterVersions.${lib.last (lib.naturalSort (builtins.attrNames flutterVersions))};
beta = flutterVersions.${lib.last (lib.naturalSort (builtins.attrNames betaFlutterVersions))};
stable = flutterVersions.${lib.last (lib.naturalSort (builtins.attrNames stableFlutterVersions))};
inherit wrapFlutter mkFlutter;
}

View File

@ -2,6 +2,7 @@
, stdenv
, systemPlatform
, buildDartApplication
, runCommand
, git
, which
, dart
@ -54,5 +55,22 @@ buildDartApplication.override { inherit dart; } rec {
popd
'';
sdkSourceBuilders = {
# https://github.com/dart-lang/pub/blob/e1fbda73d1ac597474b82882ee0bf6ecea5df108/lib/src/sdk/dart.dart#L80
"dart" = name: runCommand "dart-sdk-${name}" { passthru.packageRoot = "."; } ''
for path in '${dart}/pkg/${name}'; do
if [ -d "$path" ]; then
ln -s "$path" "$out"
break
fi
done
if [ ! -e "$out" ]; then
echo 1>&2 'The Dart SDK does not contain the requested package: ${name}!'
exit 1
fi
'';
};
inherit pubspecLock;
}

View File

@ -1,6 +1,7 @@
{ version
, engineVersion
, patches
, channel
, dart
, src
, pubspecLock
@ -74,7 +75,7 @@ let
"devToolsVersion": "$(cat "${dart}/bin/resources/devtools/version.json" | jq -r .version)",
"flutterVersion": "${version}",
"frameworkVersion": "${version}",
"channel": "stable",
"channel": "${channel}",
"repositoryUrl": "https://github.com/flutter/flutter.git",
"frameworkRevision": "nixpkgs000000000000000000000000000000000",
"frameworkCommitDate": "1970-01-01 00:00:00",
@ -124,7 +125,7 @@ let
'';
passthru = {
inherit dart engineVersion artifactHashes;
inherit dart engineVersion artifactHashes channel;
tools = flutterTools;
# The derivation containing the original Flutter SDK files.
# When other derivations wrap this one, any unmodified files

View File

@ -1,26 +1,27 @@
let
dartVersion = "@dart_version@";
platform = "@platform@";
channel = "@channel@";
in
{
x86_64-linux = { fetchzip }:
fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-linux-x64-release.zip";
url = "https://storage.googleapis.com/dart-archive/channels/${channel}/release/${dartVersion}/sdk/dartsdk-linux-x64-release.zip";
sha256 = "0000000000000000000000000000000000000000000000000000";
};
aarch64-linux = { fetchzip }:
fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-linux-arm64-release.zip";
url = "https://storage.googleapis.com/dart-archive/channels/${channel}/release/${dartVersion}/sdk/dartsdk-linux-arm64-release.zip";
sha256 = "0000000000000000000000000000000000000000000000000000";
};
x86_64-darwin = { fetchzip }:
fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-macos-x64-release.zip";
url = "https://storage.googleapis.com/dart-archive/channels/${channel}/release/${dartVersion}/sdk/dartsdk-macos-x64-release.zip";
sha256 = "0000000000000000000000000000000000000000000000000000";
};
aarch64-darwin = { fetchzip }:
fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-macos-arm64-release.zip";
url = "https://storage.googleapis.com/dart-archive/channels/${channel}/release/${dartVersion}/sdk/dartsdk-macos-arm64-release.zip";
sha256 = "0000000000000000000000000000000000000000000000000000";
};
}.${platform}

View File

@ -111,7 +111,7 @@ def get_artifact_hashes(flutter_compact_version):
return result_dict
def get_dart_hashes(dart_version):
def get_dart_hashes(dart_version, channel):
platforms = [
"x86_64-linux",
"aarch64-linux",
@ -122,6 +122,7 @@ def get_dart_hashes(dart_version):
code = load_code(
"get-dart-hashes.nix",
dart_version=dart_version,
channel=channel,
platform=platform)
stderr = nix_build_to_fail(code)
@ -177,6 +178,7 @@ def get_pubspec_lock(flutter_compact_version, flutter_src):
def write_data(
nixpkgs_flutter_version_directory,
flutter_version,
channel,
engine_hash,
dart_version,
dart_hash,
@ -187,6 +189,7 @@ def write_data(
f.write(json.dumps({
"version": flutter_version,
"engineVersion": engine_hash,
"channel": channel,
"dartVersion": dart_version,
"dartHash": dart_hash,
"flutterHash": flutter_hash,
@ -229,18 +232,21 @@ def update_all_packages():
# Finds Flutter version, Dart version, and Engine hash.
# If the Flutter version is given, it uses that. Otherwise finds the
# latest stable Flutter version.
def find_versions(flutter_version=None):
def find_versions(flutter_version=None, channel=None):
engine_hash = None
dart_version = None
releases = json.load(urllib.request.urlopen(
"https://storage.googleapis.com/flutter_infra_release/releases/releases_linux.json"))
if not channel:
channel = 'stable'
if not flutter_version:
stable_hash = releases['current_release']['stable']
hash = releases['current_release'][channel]
release = next(
filter(
lambda release: release['hash'] == stable_hash,
lambda release: release['hash'] == hash,
releases['releases']))
flutter_version = release['version']
@ -265,21 +271,25 @@ def find_versions(flutter_version=None):
filter(
lambda release: release['version'] == flutter_version,
releases['releases']))['dart_sdk_version']
if " " in dart_version:
dart_version = dart_version.split(' ')[2][:-1]
except StopIteration:
exit(
f"Couldn't find Dart version for Flutter version: {flutter_version}")
return (flutter_version, engine_hash, dart_version)
return (flutter_version, engine_hash, dart_version, channel)
def main():
parser = argparse.ArgumentParser(description='Update Flutter in Nixpkgs')
parser.add_argument('--version', type=str, help='Specify Flutter version')
parser.add_argument('--channel', type=str, help='Specify Flutter release channel')
parser.add_argument('--artifact-hashes', action='store_true',
help='Whether to get artifact hashes')
args = parser.parse_args()
(flutter_version, engine_hash, dart_version) = find_versions(args.version)
(flutter_version, engine_hash, dart_version, channel) = find_versions(args.version, args.channel)
flutter_compact_version = '_'.join(flutter_version.split('.')[:2])
@ -291,11 +301,11 @@ def main():
"\n")
return
print(f"Flutter version: {flutter_version} ({flutter_compact_version})")
print(f"Flutter version: {flutter_version} ({flutter_compact_version}) on ({channel})")
print(f"Engine hash: {engine_hash}")
print(f"Dart version: {dart_version}")
dart_hash = get_dart_hashes(dart_version)
dart_hash = get_dart_hashes(dart_version, channel)
(flutter_hash, flutter_src) = get_flutter_hash_and_src(flutter_version)
nixpkgs_flutter_version_directory = f"{NIXPKGS_ROOT}/pkgs/development/compilers/flutter/versions/{flutter_compact_version}"
@ -309,6 +319,7 @@ def main():
common_data_args = {
"nixpkgs_flutter_version_directory": nixpkgs_flutter_version_directory,
"flutter_version": flutter_version,
"channel": channel,
"dart_version": dart_version,
"engine_hash": engine_hash,
"flutter_hash": flutter_hash,

View File

@ -1,6 +1,7 @@
{
"version": "3.13.8",
"engineVersion": "767d8c75e898091b925519803830fc2721658d07",
"channel": "stable",
"dartVersion": "3.1.4",
"dartHash": {
"x86_64-linux": "sha256-42wrqzjRcFDWw2aEY6+/faX+QE9PA8FmRWP4M/NkgBE=",

View File

@ -1,6 +1,7 @@
{
"version": "3.16.7",
"engineVersion": "4a585b79294e830fa89c24924d58a27cc8fbf406",
"channel": "stable",
"dartVersion": "3.2.4",
"dartHash": {
"x86_64-linux": "sha256-qslf+wgmNz9r+e45o3Bg9/vDj75GkM9gQE2tb5rbIvw=",

View File

@ -1,6 +1,7 @@
{
"version": "3.19.4",
"engineVersion": "a5c24f538d05aaf66f7972fb23959d8cafb9f95a",
"channel": "stable",
"dartVersion": "3.3.2",
"dartHash": {
"x86_64-linux": "sha256-eO8qcSQNWGEz/5oVaJ5tjRMnGy2aq3PbcF15z/Pi3xQ=",

View File

@ -1,6 +1,7 @@
{
"version": "3.22.2",
"engineVersion": "edd8546116457bdf1c5bdfb13ecb9463d2bb5ed4",
"channel": "stable",
"dartVersion": "3.4.3",
"dartHash": {
"x86_64-linux": "sha256-wDIdoWoKlutP8kixd12Lppzv2aYeiTJ1A1Sy6lguXgg=",

File diff suppressed because it is too large Load Diff

View File

@ -93,6 +93,8 @@ let
mkdir -p $lib/lib/clang
mv $lib/lib/17 $lib/lib/clang/17
'') + (lib.optionalString (lib.versionAtLeast release_version "19") ''
mv $out/lib/clang $lib/lib/clang
'') + ''
# Move libclang to 'lib' output

View File

@ -210,7 +210,7 @@ stdenv.mkDerivation (rec {
'') +
# This test fails with a `dysmutil` crash; have not yet dug into what's
# going on here (TODO(@rrbutani)).
''
lib.optionalString (lib.versionOlder release_version "19") ''
rm test/tools/dsymutil/ARM/obfuscated.test
'')) +
# FileSystem permissions tests fail with various special bits

View File

@ -1,5 +1,5 @@
diff --git a/cmake/modules/AddClang.cmake b/cmake/modules/AddClang.cmake
index 75b0080f6715..c895b884cd27 100644
index 75b0080f6..c895b884c 100644
--- a/cmake/modules/AddClang.cmake
+++ b/cmake/modules/AddClang.cmake
@@ -119,8 +119,8 @@ macro(add_clang_library name)
@ -14,22 +14,22 @@ index 75b0080f6715..c895b884cd27 100644
if (NOT LLVM_ENABLE_IDE)
diff --git a/lib/Headers/CMakeLists.txt b/lib/Headers/CMakeLists.txt
index f2b0c5cddcbb..52f37fc368ce 100644
index e6ae4e19e..5ef01aea2 100644
--- a/lib/Headers/CMakeLists.txt
+++ b/lib/Headers/CMakeLists.txt
@@ -473,6 +473,7 @@ add_header_target("windows-resource-headers" ${windows_only_files})
add_header_target("utility-resource-headers" ${utility_files})
@@ -337,6 +337,7 @@ set(llvm_libc_wrapper_files
get_clang_resource_dir(header_install_dir SUBDIR include)
include(GetClangResourceDir)
get_clang_resource_dir(output_dir PREFIX ${LLVM_LIBRARY_OUTPUT_INTDIR}/.. SUBDIR include)
+set(header_install_dir ${CMAKE_INSTALL_LIBDIR}${LLVM_LIBDIR_SUFFIX}/clang/${CLANG_VERSION_MAJOR}/include)
set(out_files)
set(generated_files)
#############################################################
# Install rules for the catch-all clang-resource-headers target
diff --git a/tools/libclang/CMakeLists.txt b/tools/libclang/CMakeLists.txt
index 4f23065a2472..6a0f55991e24 100644
index b5b6d2807..6b592d255 100644
--- a/tools/libclang/CMakeLists.txt
+++ b/tools/libclang/CMakeLists.txt
@@ -234,7 +234,7 @@ foreach(PythonVersion ${CLANG_PYTHON_BINDINGS_VERSIONS})
@@ -246,7 +246,7 @@ foreach(PythonVersion ${CLANG_PYTHON_BINDINGS_VERSIONS})
COMPONENT
libclang-python-bindings
DESTINATION
@ -39,7 +39,7 @@ index 4f23065a2472..6a0f55991e24 100644
if(NOT LLVM_ENABLE_IDE)
add_custom_target(libclang-python-bindings)
diff --git a/tools/scan-build-py/CMakeLists.txt b/tools/scan-build-py/CMakeLists.txt
index 3aca22c0b0a8..3115353e3fe3 100644
index 3aca22c0b..3115353e3 100644
--- a/tools/scan-build-py/CMakeLists.txt
+++ b/tools/scan-build-py/CMakeLists.txt
@@ -88,7 +88,7 @@ foreach(lib ${LibScanbuild})

View File

@ -19,9 +19,9 @@
# LLVM release information; specify one of these but not both:
, gitRelease ? {
version = "19.0.0-git";
rev = "cebf77fb936a7270c7e3fa5c4a7e76216321d385";
rev-version = "19.0.0-unstable-2024-04-07";
sha256 = "sha256-616tscgsiFgHQcXW4KzK5srrudYizQFnJVM6K0qRf+I=";
rev = "78ee473784e5ef6f0b19ce4cb111fb6e4d23c6b2";
rev-version = "19.0.0-unstable-2024-06-12";
sha256 = "sha256-oLVMwWjo6Nt8ZsTnDTfoiM5U0+1lVIc1NO+4qBNYlzs=";
}
# i.e.:
# {

View File

@ -0,0 +1,105 @@
{
lib,
callPackage,
cmake,
coreutils,
fetchFromGitHub,
libxml2,
llvmPackages,
stdenv,
testers,
zlib,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "zig";
version = "0.13.0";
src = fetchFromGitHub {
owner = "ziglang";
repo = "zig";
rev = finalAttrs.version;
hash = "sha256-5qSiTq+UWGOwjDVZMIrAt2cDKHkyNPBSAEjpRQUByFM=";
};
nativeBuildInputs = [
cmake
(lib.getDev llvmPackages.llvm)
];
buildInputs =
[
libxml2
zlib
]
++ (with llvmPackages; [
libclang
lld
llvm
]);
outputs = [
"out"
"doc"
];
cmakeFlags = [
# file RPATH_CHANGE could not write new RPATH
(lib.cmakeBool "CMAKE_SKIP_BUILD_RPATH" true)
# ensure determinism in the compiler build
(lib.cmakeFeature "ZIG_TARGET_MCPU" "baseline")
# always link against static build of LLVM
(lib.cmakeBool "ZIG_STATIC_LLVM" true)
];
env.ZIG_GLOBAL_CACHE_DIR = "$TMPDIR/zig-cache";
doInstallCheck = true;
# strictDeps breaks zig when clang is being used.
# https://github.com/NixOS/nixpkgs/issues/317055#issuecomment-2148438395
strictDeps = !stdenv.cc.isClang;
# Zig's build looks at /usr/bin/env to find dynamic linking info. This doesn't
# work in Nix's sandbox. Use env from our coreutils instead.
postPatch = ''
substituteInPlace lib/std/zig/system.zig \
--replace "/usr/bin/env" "${lib.getExe' coreutils "env"}"
'';
postBuild = ''
stage3/bin/zig build langref
'';
postInstall = ''
install -Dm444 ../zig-out/doc/langref.html -t $doc/share/doc/zig-${finalAttrs.version}/html
'';
installCheckPhase = ''
runHook preInstallCheck
$out/bin/zig test --cache-dir "$TMPDIR/zig-test-cache" -I $src/test $src/test/behavior.zig
runHook postInstallCheck
'';
passthru = {
hook = callPackage ./hook.nix { zig = finalAttrs.finalPackage; };
tests = {
version = testers.testVersion {
package = finalAttrs.finalPackage;
command = "zig version";
};
};
};
meta = {
description = "General-purpose programming language and toolchain for maintaining robust, optimal, and reusable software";
changelog = "https://ziglang.org/download/${finalAttrs.version}/release-notes.html";
homepage = "https://ziglang.org/";
license = lib.licenses.mit;
mainProgram = "zig";
maintainers = with lib.maintainers; [ andrewrk ] ++ lib.teams.zig.members;
platforms = lib.platforms.unix;
};
})

View File

@ -0,0 +1,32 @@
{
lib,
makeSetupHook,
zig,
}:
makeSetupHook {
name = "zig-hook";
propagatedBuildInputs = [ zig ];
substitutions = {
# This zig_default_flags below is meant to avoid CPU feature impurity in
# Nixpkgs. However, this flagset is "unstable": it is specifically meant to
# be controlled by the upstream development team - being up to that team
# exposing or not that flags to the outside (especially the package manager
# teams).
zig_default_flags = [
"-Dcpu=baseline"
"--release=safe"
];
};
passthru = {
inherit zig;
};
meta = {
description = "A setup hook for using the Zig compiler in Nixpkgs";
inherit (zig.meta) maintainers platforms broken;
};
} ./setup-hook.sh

View File

@ -0,0 +1,70 @@
# shellcheck shell=bash disable=SC2154,SC2086
readonly zigDefaultFlagsArray=(@zig_default_flags@)
function zigSetGlobalCacheDir {
ZIG_GLOBAL_CACHE_DIR=$(mktemp -d)
export ZIG_GLOBAL_CACHE_DIR
}
function zigBuildPhase {
runHook preBuild
local flagsArray=(
"${zigDefaultFlagsArray[@]}"
$zigBuildFlags "${zigBuildFlagsArray[@]}"
)
echoCmd 'zig build flags' "${flagsArray[@]}"
zig build "${flagsArray[@]}"
runHook postBuild
}
function zigCheckPhase {
runHook preCheck
local flagsArray=(
"${zigDefaultFlagsArray[@]}"
$zigCheckFlags "${zigCheckFlagsArray[@]}"
)
echoCmd 'zig check flags' "${flagsArray[@]}"
zig build test "${flagsArray[@]}"
runHook postCheck
}
function zigInstallPhase {
runHook preInstall
local flagsArray=(
"${zigDefaultFlagsArray[@]}"
$zigBuildFlags "${zigBuildFlagsArray[@]}"
$zigInstallFlags "${zigInstallFlagsArray[@]}"
)
if [ -z "${dontAddPrefix-}" ]; then
# Zig does not recognize `--prefix=/dir/`, only `--prefix /dir/`
flagsArray+=("${prefixKey:---prefix}" "$prefix")
fi
echoCmd 'zig install flags' "${flagsArray[@]}"
zig build install "${flagsArray[@]}"
runHook postInstall
}
addEnvHooks "$targetOffset" zigSetGlobalCacheDir
if [ -z "${dontUseZigBuild-}" ] && [ -z "${buildPhase-}" ]; then
buildPhase=zigBuildPhase
fi
if [ -z "${dontUseZigCheck-}" ] && [ -z "${checkPhase-}" ]; then
checkPhase=zigCheckPhase
fi
if [ -z "${dontUseZigInstall-}" ] && [ -z "${installPhase-}" ]; then
installPhase=zigInstallPhase
fi

View File

@ -1,4 +1,4 @@
{ buildPythonPackage, pythonOlder }:
{ lib, buildPythonPackage, pythonOlder }:
buildPythonPackage {
@ -6,7 +6,13 @@ buildPythonPackage {
pname = "typeddep";
version = "1.3.3.7";
src = ./.;
src = lib.fileset.toSource {
root = ./.;
fileset = lib.fileset.unions [
./setup.py
./typeddep
];
};
disabled = pythonOlder "3.7";

View File

@ -58,12 +58,26 @@ let
else if stdenv.hostPlatform.osxMinVersion == "10.5" then "9"
else "8";
cpu =
/**/ if stdenv.hostPlatform.isArmv7 then "armv7"
else if stdenv.hostPlatform.isAarch64 then "arm64"
else if stdenv.hostPlatform.isx86_32 then "x86"
else stdenv.hostPlatform.parsed.cpu.name;
kernel =
# Build system doesn't understand BSD, so pretend to be Linux.
/**/ if stdenv.isBSD then "linux"
else if stdenv.isDarwin then "darwin${darwinVersion}"
else stdenv.hostPlatform.parsed.kernel.name;
isGeneric =
/**/ (stdenv.hostPlatform.isPower && stdenv.hostPlatform.isLittleEndian)
|| stdenv.hostPlatform.parsed.cpu.name == "armv6l";
target =
/**/ if (stdenv.isBSD || stdenv.hostPlatform != stdenv.buildPlatform) then
(if isGeneric then "generic-gnu" else "${cpu}-${kernel}-gcc")
else null;
in
assert vp8DecoderSupport || vp8EncoderSupport || vp9DecoderSupport || vp9EncoderSupport;
@ -167,8 +181,8 @@ stdenv.mkDerivation rec {
(enableFeature (experimentalSpatialSvcSupport ||
experimentalFpMbStatsSupport ||
experimentalEmulateHardwareSupport) "experimental")
] ++ optionals (stdenv.isBSD || stdenv.hostPlatform != stdenv.buildPlatform) [
"--force-target=${stdenv.hostPlatform.parsed.cpu.name}-${kernel}-gcc"
] ++ optionals (target != null) [
"--target=${target}"
(lib.optionalString stdenv.hostPlatform.isCygwin "--enable-static-msvcrt")
] # Experimental features
++ optional experimentalSpatialSvcSupport "--enable-spatial-svc"

View File

@ -60,6 +60,9 @@ stdenv.mkDerivation rec {
else if stdenv.hostPlatform.isi686 then "arch=ia32"
else throw "Unsupported cross architecture"));
# Fix undefined reference errors with version script under LLVM.
NIX_LDFLAGS = lib.optionalString (stdenv.cc.bintools.isLLVM && lib.versionAtLeast stdenv.cc.bintools.version "17") "--undefined-version";
enableParallelBuilding = true;
installPhase = ''

View File

@ -39,6 +39,9 @@ stdenv.mkDerivation rec {
# https://gcc.gnu.org/PR108854
lib.optionals (stdenv.cc.isGNU && stdenv.isx86_32) [ "-O2" ];
# Fix undefined reference errors with version script under LLVM.
NIX_LDFLAGS = lib.optionalString (stdenv.cc.bintools.isLLVM && lib.versionAtLeast stdenv.cc.bintools.version "17") "--undefined-version";
# Disable failing test on musl
# test/conformance/conformance_resumable_tasks.cpp:37:24: error: suspend is not a member of tbb::v1::task; did you mean tbb::detail::r1::suspend?
postPatch = lib.optionalString stdenv.hostPlatform.isMusl ''

View File

@ -23,14 +23,14 @@
buildPythonPackage rec {
pname = "molecule";
version = "24.2.1";
version = "24.6.0";
pyproject = true;
disabled = pythonOlder "3.10";
src = fetchPypi {
inherit pname version;
hash = "sha256-g1IrqpuRVg6phic8qxScORVpdunWEkVxciYyCTWtVuQ=";
hash = "sha256-jey0xoT8r7hae08DjaEl7UJb3RDbdr8M20E/m4TkG1g=";
};
nativeBuildInputs = [

View File

@ -16,7 +16,7 @@
buildPythonPackage rec {
pname = "ubelt";
version = "1.3.5";
version = "1.3.6";
pyproject = true;
disabled = pythonOlder "3.6";
@ -25,7 +25,7 @@ buildPythonPackage rec {
owner = "Erotemic";
repo = "ubelt";
rev = "refs/tags/v${version}";
hash = "sha256-pwqqt5Syag4cO6a93+7ZE3eI61yTZGc+NEu/Y0i1U0k=";
hash = "sha256-ygoJqyTscfuZVDGVbrZobZFvlcuF4HavTU65tmhyU+w=";
};
nativeBuildInputs = [

View File

@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
url = "https://github.com/horms/kexec-tools/commit/328de8e00e298f00d7ba6b25dc3950147e9642e6.patch";
hash = "sha256-wVQI4oV+hBLq3kGIp2+F5J3f6s/TypDu3Xq583KYc3U=";
})
];
] ++ lib.optional (stdenv.hostPlatform.useLLVM or false) ./fix-purgatory-llvm-libunwind.patch;
hardeningDisable = [ "format" "pic" "relro" "pie" ];

View File

@ -0,0 +1,11 @@
--- a/purgatory/Makefile 2024-06-06 23:59:33.089005832 -0700
+++ b/purgatory/Makefile 2024-06-06 23:59:56.761169892 -0700
@@ -62,7 +62,7 @@
$(PURGATORY): LDFLAGS=$($(ARCH)_PURGATORY_EXTRA_CFLAGS)\
-Wl,--no-undefined -nostartfiles -nostdlib \
-nodefaultlibs -e purgatory_start -r \
- -Wl,-Map=$(PURGATORY_MAP)
+ -Wl,-Map=$(PURGATORY_MAP) -static
$(PURGATORY): $(PURGATORY_OBJS)
$(MKDIR) -p $(@D)

View File

@ -25,13 +25,13 @@ let
in
stdenv.mkDerivation (finalAttrs: {
pname = "7zz";
version = "24.05";
version = "24.06";
src = fetchurl {
url = "https://7-zip.org/a/7z${lib.replaceStrings [ "." ] [ "" ] finalAttrs.version}-src.tar.xz";
hash = {
free = "sha256-yYq3IEV2GeDWwW6KrdpgK2/QOsmDcBpIZvbk6VKZETY=";
unfree = "sha256-Y/NBz4C40ofG6UVRmz2g+nVVPIVXKkcbf6bmj5qQt5A=";
free = "sha256-X3uqGnJGQpW5MOaTtgWYwwrhS84e+piX7Gc+e8Pll00=";
unfree = "sha256-KqFmDHc1JbLthNbNf/BoDHhuwIk7h+TbRGVNy39ayLU=";
}.${if enableUnfree then "unfree" else "free"};
downloadToTemp = (!enableUnfree);
# remove the unRAR related code from the src drv

View File

@ -1,11 +1,8 @@
#! /usr/bin/env nix-shell
#! nix-shell -i bash -p curl xq-xml nix-prefetch
#! nix-shell -I nixpkgs=./. -i bash -p curl xq-xml common-updater-scripts
set -euo pipefail
cd "$(dirname "${BASH_SOURCE[0]}")"
DRV_DIR="$PWD"
OLD_VERSION="$(sed -nE 's/\s*version = "(.*)".*/\1/p' ./default.nix)"
OLD_VERSION="$(nix-instantiate --eval --json --expr 'let pkgs = import ./. {}; in pkgs._7zz.version' | sed 's/"//g')"
NEW_VERSION="$(curl -H 'Accept: application/rss+xml' 'https://sourceforge.net/projects/sevenzip/rss?path=/7-Zip' | xq -x "substring((/rss/channel/item[link[contains(., 'src.tar.xz')]])[1]/title, 8, 5)")"
echo "comparing versions $OLD_VERSION => $NEW_VERSION"
@ -14,37 +11,5 @@ if [[ "$OLD_VERSION" == "$NEW_VERSION" ]]; then
exit 0
fi
NIXPKGS_ROOT="$(realpath "$DRV_DIR/../../../..")"
echo "getting free source hash"
OLD_FREE_HASH="$(nix-instantiate --eval --strict -E "with import $NIXPKGS_ROOT {}; _7zz.src.drvAttrs.outputHash" | tr -d '"')"
echo "getting unfree source hash"
OLD_UNFREE_HASH="$(nix-instantiate --eval --strict -E "with import $NIXPKGS_ROOT {}; (_7zz.override { enableUnfree = true; }).src.drvAttrs.outputHash" | tr -d '"')"
NEW_VERSION_FORMATTED="$(echo "$NEW_VERSION" | tr -d '.')"
URL="https://7-zip.org/a/7z${NEW_VERSION_FORMATTED}-src.tar.xz"
# `nix-prefetch` is broken without flakes
# see https://github.com/msteen/nix-prefetch/issues/51
NEW_FREE_HASH=$(nix-prefetch -f "$NIXPKGS_ROOT" -E "_7zz.src" --url "$URL" --option extra-experimental-features flakes)
NEW_UNFREE_OUT=$(nix-prefetch -f "$NIXPKGS_ROOT" -E "(_7zz.override { enableUnfree = true; }).src" --url "$URL" --output raw --print-path --option extra-experimental-features flakes)
# first line of raw output is the hash
NEW_UNFREE_HASH="$(echo "$NEW_UNFREE_OUT" | sed -n 1p)"
# second line of raw output is the src path
NEW_UNFREE_SRC="$(echo "$NEW_UNFREE_OUT" | sed -n 2p)"
# make sure to nuke the unfree src from the updater's machine
# > the license requires that you agree to these use restrictions, or you must remove the software (source and binary) from your hard disks
# https://fedoraproject.org/wiki/Licensing:Unrar
nix-store --delete "$NEW_UNFREE_SRC"
echo "updating version"
sed -i "s/version = \"$OLD_VERSION\";/version = \"$NEW_VERSION\";/" "$DRV_DIR/default.nix"
echo "updating free hash"
sed -i "s@free = \"$OLD_FREE_HASH\";@free = \"$NEW_FREE_HASH\";@" "$DRV_DIR/default.nix"
echo "updating unfree hash"
sed -i "s@unfree = \"$OLD_UNFREE_HASH\";@unfree = \"$NEW_UNFREE_HASH\";@" "$DRV_DIR/default.nix"
echo "done"
update-source-version _7zz "$NEW_VERSION"
update-source-version _7zz-rar "$NEW_VERSION" --ignore-same-version

View File

@ -13,7 +13,7 @@
let
pname = "ockam";
version = "0.125.0";
version = "0.126.0";
in
rustPlatform.buildRustPackage {
inherit pname version;
@ -22,10 +22,10 @@ rustPlatform.buildRustPackage {
owner = "build-trust";
repo = pname;
rev = "ockam_v${version}";
hash = "sha256-CFJ2Z/PI7du9wlvh3/Ew8AejcU//xPuUXJweQ4phYc8=";
hash = "sha256-LkjMxUKTlj3fkSlm1NNOQKVUEz6baqaxMXcI6myaT24=";
};
cargoHash = "sha256-j9c1m6beT70E0+czXMVOqY36wAHR1uqL5zKHkrlIAQk=";
cargoHash = "sha256-wOBr1U9lekDwG8MntrvR7QtMItJ41kLcyt70N2Uz1M8=";
nativeBuildInputs = [ git pkg-config ];
buildInputs = [ openssl dbus ]
++ lib.optionals stdenv.isDarwin [ AppKit Security ];

View File

@ -1473,6 +1473,7 @@ with pkgs;
_6tunnel = callPackage ../tools/networking/6tunnel { };
_7zz = darwin.apple_sdk_11_0.callPackage ../tools/archivers/7zz { };
_7zz-rar = _7zz.override { enableUnfree = true; };
_9pfs = callPackage ../tools/filesystems/9pfs { };
@ -9473,17 +9474,7 @@ with pkgs;
kestrel = callPackage ../tools/security/kestrel { };
kexec-tools = callPackage ../os-specific/linux/kexec-tools {
# clangStdenv fails with
# purgatory/arch/i386/entry32-16.S:23:2: error: unknown directive
# .arch i386
# ^
# purgatory/arch/i386/entry32-16.S:115:11: error: unknown token in expression
# ljmp %cs:*(realdest - entry16)
# ^
# make: *** [Makefile:128: purgatory/arch/i386/entry32-16.o] Error 1
stdenv = gccStdenv;
};
kexec-tools = callPackage ../os-specific/linux/kexec-tools { };
keepkey-agent = with python3Packages; toPythonApplication keepkey-agent;
@ -11492,6 +11483,7 @@ with pkgs;
};
p7zip = callPackage ../tools/archivers/p7zip { };
p7zip-rar = p7zip.override { enableUnfree = true; };
packagekit = callPackage ../tools/package-management/packagekit { };
@ -15380,6 +15372,7 @@ with pkgs;
flutterPackages = recurseIntoAttrs (callPackage ../development/compilers/flutter { });
flutter = flutterPackages.stable;
flutter323 = flutterPackages.v3_23;
flutter322 = flutterPackages.v3_22;
flutter319 = flutterPackages.v3_19;
flutter316 = flutterPackages.v3_16;
@ -25027,7 +25020,11 @@ with pkgs;
zig_0_12 = darwin.apple_sdk_11_0.callPackage ../development/compilers/zig/0.12 {
llvmPackages = llvmPackages_17;
};
zig = zig_0_12;
# requires a newer Apple SDK
zig_0_13 = darwin.apple_sdk_11_0.callPackage ../development/compilers/zig/0.13 {
llvmPackages = llvmPackages_18;
};
zig = zig_0_13;
zimlib = callPackage ../development/libraries/zimlib { };