From d1daaeb1280c5df7b8dc1c24e6a894f8f3411a44 Mon Sep 17 00:00:00 2001 From: TomaSajt <62384384+TomaSajt@users.noreply.github.com> Date: Mon, 1 Apr 2024 00:01:54 +0200 Subject: openjfx{11,17,19,20,21,22}: fix build when withWebKit is enabled --- pkgs/development/compilers/openjdk/openjfx/11.nix | 22 ++++++++++++++++++--- pkgs/development/compilers/openjdk/openjfx/17.nix | 22 ++++++++++----------- pkgs/development/compilers/openjdk/openjfx/19.nix | 24 ++++++++++++++++++++--- pkgs/development/compilers/openjdk/openjfx/20.nix | 24 ++++++++++++++++++++--- pkgs/development/compilers/openjdk/openjfx/21.nix | 24 ++++++++++++++++++++--- pkgs/development/compilers/openjdk/openjfx/22.nix | 18 ++++++++++++++--- 6 files changed, 107 insertions(+), 27 deletions(-) (limited to 'pkgs/development/compilers') diff --git a/pkgs/development/compilers/openjdk/openjfx/11.nix b/pkgs/development/compilers/openjdk/openjfx/11.nix index 6d550538b081a..424c41ce3c783 100644 --- a/pkgs/development/compilers/openjdk/openjfx/11.nix +++ b/pkgs/development/compilers/openjdk/openjfx/11.nix @@ -1,5 +1,5 @@ { stdenv, lib, fetchFromGitHub, writeText, gradle_7, pkg-config, perl, cmake -, gperf, gtk2, gtk3, libXtst, libXxf86vm, glib, alsa-lib, ffmpeg_4-headless, python3, ruby, icu68 +, gperf, gtk2, gtk3, libXtst, libXxf86vm, glib, alsa-lib, ffmpeg_4-headless, python3, ruby, fetchurl, runCommand , openjdk11-bootstrap , withMedia ? true , withWebKit ? false @@ -14,6 +14,16 @@ let java = openjdk11-bootstrap; }); + icuVersionWithSep = s: "71${s}1"; + icuPath = "download/release-${icuVersionWithSep "-"}/icu4c-${icuVersionWithSep "_"}-data-bin-l.zip"; + icuData = fetchurl { + url = "https://github.com/unicode-org/icu/releases/${icuPath}"; + hash = "sha256-pVWIy0BkICsthA5mxhR9SJQHleMNnaEcGl/AaLi5qZM="; + }; + icuFakeRepository = runCommand "icu-data-repository" {} '' + install -Dm644 ${icuData} $out/${icuPath} + ''; + makePackage = args: stdenv.mkDerivation ({ version = "${major}${update}-${build}"; @@ -24,7 +34,7 @@ let sha256 = "sha256-46DjIzcBHkmp5vnhYnLu78CG72bIBRM4A6mgk2OLOko="; }; - buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4-headless icu68 ]; + buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4-headless ]; nativeBuildInputs = [ gradle_ perl pkg-config cmake gperf python3 ruby ]; dontUseCmakeConfigure = true; @@ -32,6 +42,11 @@ let postPatch = '' substituteInPlace buildSrc/linux.gradle \ --replace ', "-Werror=implicit-function-declaration"' "" + + # Add missing includes for gcc-13 for webkit build: + sed -e '1i #include ' \ + -i modules/javafx.web/src/main/native/Source/bmalloc/bmalloc/Heap.cpp \ + modules/javafx.web/src/main/native/Source/bmalloc/bmalloc/IsoSharedPageInlines.h ''; config = writeText "gradle.properties" ('' @@ -46,7 +61,7 @@ let export GRADLE_USER_HOME=$(mktemp -d) ln -s $config gradle.properties export NIX_CFLAGS_COMPILE="$(pkg-config --cflags glib-2.0) $NIX_CFLAGS_COMPILE" - gradle --no-daemon $gradleFlags sdk + gradle --no-daemon --console=plain $gradleFlags sdk runHook postBuild ''; @@ -77,6 +92,7 @@ in makePackage { gradleProperties = '' COMPILE_MEDIA = ${lib.boolToString withMedia} COMPILE_WEBKIT = ${lib.boolToString withWebKit} + ${lib.optionalString withWebKit "icuRepositoryURL = file://${icuFakeRepository}"} ''; preBuild = '' diff --git a/pkgs/development/compilers/openjdk/openjfx/17.nix b/pkgs/development/compilers/openjdk/openjfx/17.nix index 58444abd3f17a..c5d6c6aaa597e 100644 --- a/pkgs/development/compilers/openjdk/openjfx/17.nix +++ b/pkgs/development/compilers/openjdk/openjfx/17.nix @@ -1,6 +1,6 @@ { stdenv, lib, fetchFromGitHub, writeText, openjdk17_headless, gradle_7 , pkg-config, perl, cmake, gperf, gtk2, gtk3, libXtst, libXxf86vm, glib, alsa-lib -, ffmpeg_4-headless, python3, ruby, icu71, fetchurl, runCommand +, ffmpeg_4-headless, python3, ruby, fetchurl, runCommand , withMedia ? true , withWebKit ? false }: @@ -14,16 +14,14 @@ let java = openjdk17_headless; }); - dashed-icu-version = lib.concatStringsSep "-" (lib.splitVersion (lib.getVersion icu71)); - underscored-icu-version = lib.concatStringsSep "_" (lib.splitVersion (lib.getVersion icu71)); - icu-data = fetchurl { - url = "https://github.com/unicode-org/icu/releases/download/release-${dashed-icu-version}/icu4c-${underscored-icu-version}-data-bin-l.zip"; + icuVersionWithSep = s: "71${s}1"; + icuPath = "download/release-${icuVersionWithSep "-"}/icu4c-${icuVersionWithSep "_"}-data-bin-l.zip"; + icuData = fetchurl { + url = "https://github.com/unicode-org/icu/releases/${icuPath}"; hash = "sha256-pVWIy0BkICsthA5mxhR9SJQHleMNnaEcGl/AaLi5qZM="; }; - - fakeRepository = runCommand "icu-data-repository" {} '' - mkdir -p $out/download/release-${dashed-icu-version} - cp ${icu-data} $out/download/release-${dashed-icu-version}/icu4c-${underscored-icu-version}-data-bin-l.zip + icuFakeRepository = runCommand "icu-data-repository" {} '' + install -Dm644 ${icuData} $out/${icuPath} ''; makePackage = args: stdenv.mkDerivation ({ @@ -36,7 +34,7 @@ let sha256 = "sha256-9VfXk2EfMebMyVKPohPRP2QXRFf8XemUtfY0JtBCHyw="; }; - buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4-headless icu71 ]; + buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4-headless ]; nativeBuildInputs = [ gradle_ perl pkg-config cmake gperf python3 ruby ]; dontUseCmakeConfigure = true; @@ -60,7 +58,7 @@ let export GRADLE_USER_HOME=$(mktemp -d) ln -s $config gradle.properties export NIX_CFLAGS_COMPILE="$(pkg-config --cflags glib-2.0) $NIX_CFLAGS_COMPILE" - gradle --no-daemon $gradleFlags sdk + gradle --no-daemon --console=plain $gradleFlags sdk runHook postBuild ''; @@ -91,7 +89,7 @@ in makePackage { gradleProperties = '' COMPILE_MEDIA = ${lib.boolToString withMedia} COMPILE_WEBKIT = ${lib.boolToString withWebKit} - ${lib.optionalString withWebKit "icuRepositoryURL = file://${fakeRepository}"} + ${lib.optionalString withWebKit "icuRepositoryURL = file://${icuFakeRepository}"} ''; preBuild = '' diff --git a/pkgs/development/compilers/openjdk/openjfx/19.nix b/pkgs/development/compilers/openjdk/openjfx/19.nix index 802a0eb9b457f..6f173db8327c1 100644 --- a/pkgs/development/compilers/openjdk/openjfx/19.nix +++ b/pkgs/development/compilers/openjdk/openjfx/19.nix @@ -1,6 +1,6 @@ { stdenv, lib, fetchFromGitHub, fetchpatch, writeText, openjdk17_headless , openjdk19_headless, gradle_7, pkg-config, perl, cmake, gperf, gtk2, gtk3, libXtst -, libXxf86vm, glib, alsa-lib, ffmpeg_4, python3, ruby, icu68 +, libXxf86vm, glib, alsa-lib, ffmpeg_4, python3, ruby, fetchurl, runCommand , withMedia ? true , withWebKit ? false }: @@ -15,6 +15,16 @@ let java = openjdk17_headless; }); + icuVersionWithSep = s: "68${s}2"; + icuPath = "download/release-${icuVersionWithSep "-"}/icu4c-${icuVersionWithSep "."}-data-bin-l.zip"; + icuData = fetchurl { + url = "https://github.com/unicode-org/icu/releases/${icuPath}"; + hash = "sha256-ieQCLBTNrskuf8j3IUQS3QLIAQzLom/O58muMP363Lw="; + }; + icuFakeRepository = runCommand "icu-data-repository" {} '' + install -Dm644 ${icuData} $out/${icuPath} + ''; + makePackage = args: stdenv.mkDerivation ({ version = "${major}${update}${build}"; @@ -38,7 +48,14 @@ let }) ]; - buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4 icu68 ]; + postPatch = '' + # Add missing includes for gcc-13 for webkit build: + sed -e '1i #include ' \ + -i modules/javafx.web/src/main/native/Source/bmalloc/bmalloc/Heap.cpp \ + modules/javafx.web/src/main/native/Source/bmalloc/bmalloc/IsoSharedPageInlines.h + ''; + + buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4 ]; nativeBuildInputs = [ gradle_ perl pkg-config cmake gperf python3 ruby ]; dontUseCmakeConfigure = true; @@ -55,7 +72,7 @@ let export GRADLE_USER_HOME=$(mktemp -d) ln -s $config gradle.properties export NIX_CFLAGS_COMPILE="$(pkg-config --cflags glib-2.0) $NIX_CFLAGS_COMPILE" - gradle --no-daemon $gradleFlags sdk + gradle --no-daemon --console=plain $gradleFlags sdk runHook postBuild ''; @@ -89,6 +106,7 @@ in makePackage { gradleProperties = '' COMPILE_MEDIA = ${lib.boolToString withMedia} COMPILE_WEBKIT = ${lib.boolToString withWebKit} + ${lib.optionalString withWebKit "icuRepositoryURL = file://${icuFakeRepository}"} ''; preBuild = '' diff --git a/pkgs/development/compilers/openjdk/openjfx/20.nix b/pkgs/development/compilers/openjdk/openjfx/20.nix index d570db3b9aee1..794590dc7e606 100644 --- a/pkgs/development/compilers/openjdk/openjfx/20.nix +++ b/pkgs/development/compilers/openjdk/openjfx/20.nix @@ -1,6 +1,6 @@ { stdenv, lib, fetchFromGitHub, fetchpatch, writeText, openjdk17_headless , openjdk19_headless, gradle_7, pkg-config, perl, cmake, gperf, gtk2, gtk3, libXtst -, libXxf86vm, glib, alsa-lib, ffmpeg_4, python3, ruby, icu68 +, libXxf86vm, glib, alsa-lib, ffmpeg_4, python3, ruby, fetchurl, runCommand , withMedia ? true , withWebKit ? false }: @@ -15,6 +15,16 @@ let java = openjdk17_headless; }); + icuVersionWithSep = s: "71${s}1"; + icuPath = "download/release-${icuVersionWithSep "-"}/icu4c-${icuVersionWithSep "_"}-data-bin-l.zip"; + icuData = fetchurl { + url = "https://github.com/unicode-org/icu/releases/${icuPath}"; + hash = "sha256-pVWIy0BkICsthA5mxhR9SJQHleMNnaEcGl/AaLi5qZM="; + }; + icuFakeRepository = runCommand "icu-data-repository" {} '' + install -Dm644 ${icuData} $out/${icuPath} + ''; + makePackage = args: stdenv.mkDerivation ({ version = "${major}${update}${build}"; @@ -25,11 +35,18 @@ let hash = "sha256-QPPJyl6+XU+m5xqYOFtQKJNNrovqy7ngNE/e7kiEJVU="; }; - buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4 icu68 ]; + buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4 ]; nativeBuildInputs = [ gradle_ perl pkg-config cmake gperf python3 ruby ]; dontUseCmakeConfigure = true; + postPatch = '' + # Add missing includes for gcc-13 for webkit build: + sed -e '1i #include ' \ + -i modules/javafx.web/src/main/native/Source/bmalloc/bmalloc/Heap.cpp \ + modules/javafx.web/src/main/native/Source/bmalloc/bmalloc/IsoSharedPageInlines.h + ''; + config = writeText "gradle.properties" ('' CONF = Release JDK_HOME = ${openjdk19_headless.home} @@ -42,7 +59,7 @@ let export GRADLE_USER_HOME=$(mktemp -d) ln -s $config gradle.properties export NIX_CFLAGS_COMPILE="$(pkg-config --cflags glib-2.0) $NIX_CFLAGS_COMPILE" - gradle --no-daemon $gradleFlags sdk + gradle --no-daemon --console=plain $gradleFlags sdk runHook postBuild ''; @@ -76,6 +93,7 @@ in makePackage { gradleProperties = '' COMPILE_MEDIA = ${lib.boolToString withMedia} COMPILE_WEBKIT = ${lib.boolToString withWebKit} + ${lib.optionalString withWebKit "icuRepositoryURL = file://${icuFakeRepository}"} ''; preBuild = '' diff --git a/pkgs/development/compilers/openjdk/openjfx/21.nix b/pkgs/development/compilers/openjdk/openjfx/21.nix index 2f0d83f9f251a..f49dbe3b0e985 100644 --- a/pkgs/development/compilers/openjdk/openjfx/21.nix +++ b/pkgs/development/compilers/openjdk/openjfx/21.nix @@ -1,6 +1,6 @@ { stdenv, lib, fetchFromGitHub, fetchpatch, writeText, openjdk17_headless , openjdk19_headless, gradle_7, pkg-config, perl, cmake, gperf, gtk2, gtk3, libXtst -, libXxf86vm, glib, alsa-lib, ffmpeg_4, python3, ruby, icu68 +, libXxf86vm, glib, alsa-lib, ffmpeg_4, python3, ruby, fetchurl, runCommand , withMedia ? true , withWebKit ? false }: @@ -15,6 +15,16 @@ let java = openjdk17_headless; }); + icuVersionWithSep = s: "73${s}1"; + icuPath = "download/release-${icuVersionWithSep "-"}/icu4c-${icuVersionWithSep "_"}-data-bin-l.zip"; + icuData = fetchurl { + url = "https://github.com/unicode-org/icu/releases/${icuPath}"; + hash = "sha256-QDgpjuAqDDiRcYXvj/Tr3pyLVSx3f9A+TfbGtLGCXiA="; + }; + icuFakeRepository = runCommand "icu-data-repository" {} '' + install -Dm644 ${icuData} $out/${icuPath} + ''; + makePackage = args: stdenv.mkDerivation ({ version = "${major}${update}${build}"; @@ -25,11 +35,18 @@ let hash = "sha256-deNAGfnA6gwcAa64l0AWdkX+vJd3ZOfIgAifSl+/m+s="; }; - buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4 icu68 ]; + buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4 ]; nativeBuildInputs = [ gradle_ perl pkg-config cmake gperf python3 ruby ]; dontUseCmakeConfigure = true; + postPatch = '' + # Add missing includes for gcc-13 for webkit build: + sed -e '1i #include ' \ + -i modules/javafx.web/src/main/native/Source/bmalloc/bmalloc/Heap.cpp \ + modules/javafx.web/src/main/native/Source/bmalloc/bmalloc/IsoSharedPageInlines.h + ''; + config = writeText "gradle.properties" ('' CONF = Release JDK_HOME = ${openjdk19_headless.home} @@ -42,7 +59,7 @@ let export GRADLE_USER_HOME=$(mktemp -d) ln -s $config gradle.properties export NIX_CFLAGS_COMPILE="$(pkg-config --cflags glib-2.0) $NIX_CFLAGS_COMPILE" - gradle --no-daemon $gradleFlags sdk + gradle --no-daemon --console=plain $gradleFlags sdk runHook postBuild ''; @@ -76,6 +93,7 @@ in makePackage { gradleProperties = '' COMPILE_MEDIA = ${lib.boolToString withMedia} COMPILE_WEBKIT = ${lib.boolToString withWebKit} + ${lib.optionalString withWebKit "icuRepositoryURL = file://${icuFakeRepository}"} ''; preBuild = '' diff --git a/pkgs/development/compilers/openjdk/openjfx/22.nix b/pkgs/development/compilers/openjdk/openjfx/22.nix index 89908779c9094..d585dbdf01413 100644 --- a/pkgs/development/compilers/openjdk/openjfx/22.nix +++ b/pkgs/development/compilers/openjdk/openjfx/22.nix @@ -2,6 +2,8 @@ , lib , fetchFromGitHub , fetchpatch +, fetchurl +, runCommand , writeText , openjdk21_headless , gradle @@ -18,7 +20,6 @@ , ffmpeg_4 , python3 , ruby -, icu68 , withMedia ? true , withWebKit ? false }: @@ -29,6 +30,16 @@ let build = "+30"; repover = "${major}${update}${build}"; + icuVersionWithSep = s: "73${s}1"; + icuPath = "download/release-${icuVersionWithSep "-"}/icu4c-${icuVersionWithSep "_"}-data-bin-l.zip"; + icuData = fetchurl { + url = "https://github.com/unicode-org/icu/releases/${icuPath}"; + hash = "sha256-QDgpjuAqDDiRcYXvj/Tr3pyLVSx3f9A+TfbGtLGCXiA="; + }; + icuFakeRepository = runCommand "icu-data-repository" {} '' + install -Dm644 ${icuData} $out/${icuPath} + ''; + makePackage = args: stdenv.mkDerivation ({ version = "${major}${update}${build}"; @@ -39,7 +50,7 @@ let hash = "sha256-sZF7ZPC0kgTTxWgtkxmGtOlfroGPGVZcMw0/wSTJUxQ="; }; - buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4 icu68 ]; + buildInputs = [ gtk2 gtk3 libXtst libXxf86vm glib alsa-lib ffmpeg_4 ]; nativeBuildInputs = [ gradle perl pkg-config cmake gperf python3 ruby ]; dontUseCmakeConfigure = true; @@ -56,7 +67,7 @@ let export GRADLE_USER_HOME=$(mktemp -d) ln -s $config gradle.properties export NIX_CFLAGS_COMPILE="$(pkg-config --cflags glib-2.0) $NIX_CFLAGS_COMPILE" - gradle --no-daemon $gradleFlags sdk + gradle --no-daemon --console=plain $gradleFlags sdk runHook postBuild ''; @@ -88,6 +99,7 @@ makePackage { gradleProperties = '' COMPILE_MEDIA = ${lib.boolToString withMedia} COMPILE_WEBKIT = ${lib.boolToString withWebKit} + ${lib.optionalString withWebKit "icuRepositoryURL = file://${icuFakeRepository}"} ''; preBuild = '' -- cgit 1.4.1 From 767d892193e5e8afd9a077efaa51ecac7a9c48ab Mon Sep 17 00:00:00 2001 From: David McFarland Date: Wed, 17 Apr 2024 09:12:07 -0300 Subject: dotnet: fix typo which was breaking the console test --- pkgs/development/compilers/dotnet/common.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pkgs/development/compilers') diff --git a/pkgs/development/compilers/dotnet/common.nix b/pkgs/development/compilers/dotnet/common.nix index a757dd36d17b2..a266171498379 100644 --- a/pkgs/development/compilers/dotnet/common.nix +++ b/pkgs/development/compilers/dotnet/common.nix @@ -63,7 +63,7 @@ '' + build); in if run == null - then build + then built else runCommand "${built.name}-run" { src = built; nativeBuildInputs = runInputs; } ( lib.optionalString (runtime != null) '' -- cgit 1.4.1 From 7150d7e203ab92fb914e08a780d30b6493e6988d Mon Sep 17 00:00:00 2001 From: David McFarland Date: Wed, 17 Apr 2024 09:12:18 -0300 Subject: dotnet: add self-contained test --- pkgs/development/compilers/dotnet/common.nix | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'pkgs/development/compilers') diff --git a/pkgs/development/compilers/dotnet/common.nix b/pkgs/development/compilers/dotnet/common.nix index a266171498379..7cd37975f9888 100644 --- a/pkgs/development/compilers/dotnet/common.nix +++ b/pkgs/development/compilers/dotnet/common.nix @@ -98,6 +98,15 @@ run = checkConsoleOutput "$src/test"; }; + self-contained = mkDotnetTest { + name = "self-contained"; + template = "console"; + usePackageSource = true; + build = "dotnet publish --use-current-runtime --sc -o $out"; + runtime = null; + run = checkConsoleOutput "$src/test"; + }; + single-file = mkDotnetTest { name = "single-file"; template = "console"; -- cgit 1.4.1 From 81693c96bab62e166a9828a76533823370def2a8 Mon Sep 17 00:00:00 2001 From: David McFarland Date: Wed, 17 Apr 2024 09:41:03 -0300 Subject: dotnet: force ICU to be loaded during tests --- pkgs/development/compilers/dotnet/common.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'pkgs/development/compilers') diff --git a/pkgs/development/compilers/dotnet/common.nix b/pkgs/development/compilers/dotnet/common.nix index 7cd37975f9888..49f3e3be4d779 100644 --- a/pkgs/development/compilers/dotnet/common.nix +++ b/pkgs/development/compilers/dotnet/common.nix @@ -71,8 +71,10 @@ export DOTNET_ROOT=${runtime} '' + run); + # Setting LANG to something other than 'C' forces the runtime to search + # for ICU, which will be required in most user environments. checkConsoleOutput = command: '' - output="$(${command})" + output="$(LANG=C.UTF-8 ${command})" # yes, older SDKs omit the comma [[ "$output" =~ Hello,?\ World! ]] && touch "$out" ''; -- cgit 1.4.1 From bd934093f4dd2528403f5ee8aa67788e8843d238 Mon Sep 17 00:00:00 2001 From: David McFarland Date: Wed, 17 Apr 2024 09:41:51 -0300 Subject: dotnet: patch apphost as well as singlefilehost This fixes library loading in self-contained builds. --- pkgs/development/compilers/dotnet/build-dotnet.nix | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'pkgs/development/compilers') diff --git a/pkgs/development/compilers/dotnet/build-dotnet.nix b/pkgs/development/compilers/dotnet/build-dotnet.nix index 8ee0bd9e7b3a3..f6802e62c70d1 100644 --- a/pkgs/development/compilers/dotnet/build-dotnet.nix +++ b/pkgs/development/compilers/dotnet/build-dotnet.nix @@ -25,6 +25,7 @@ assert if type == "sdk" then packages != null else true; , writeShellScript , mkNugetDeps , callPackage +, dotnetCorePackages }: let @@ -44,6 +45,8 @@ let mkCommon = callPackage ./common.nix {}; + targetRid = dotnetCorePackages.systemToDotnetRid stdenv.targetPlatform.system; + in mkCommon type rec { inherit pname version; @@ -88,21 +91,21 @@ mkCommon type rec { # Tell autoPatchelf about runtime dependencies. # (postFixup phase is run before autoPatchelfHook.) - postFixup = lib.optionalString stdenv.isLinux '' + postFixup = lib.optionalString stdenv.targetPlatform.isLinux '' patchelf \ --add-needed libicui18n.so \ --add-needed libicuuc.so \ $out/shared/Microsoft.NETCore.App/*/libcoreclr.so \ $out/shared/Microsoft.NETCore.App/*/*System.Globalization.Native.so \ - $out/packs/Microsoft.NETCore.App.Host.linux-x64/*/runtimes/linux-x64/native/singlefilehost + $out/packs/Microsoft.NETCore.App.Host.${targetRid}/*/runtimes/${targetRid}/native/*host patchelf \ --add-needed libgssapi_krb5.so \ $out/shared/Microsoft.NETCore.App/*/*System.Net.Security.Native.so \ - $out/packs/Microsoft.NETCore.App.Host.linux-x64/*/runtimes/linux-x64/native/singlefilehost + $out/packs/Microsoft.NETCore.App.Host.${targetRid}/*/runtimes/${targetRid}/native/*host patchelf \ --add-needed libssl.so \ $out/shared/Microsoft.NETCore.App/*/*System.Security.Cryptography.Native.OpenSsl.so \ - $out/packs/Microsoft.NETCore.App.Host.linux-x64/*/runtimes/linux-x64/native/singlefilehost + $out/packs/Microsoft.NETCore.App.Host.${targetRid}/*/runtimes/${targetRid}/native/*host ''; passthru = { -- cgit 1.4.1 From 57d6e5bda67775c68b198d0ac62efd3ecb3eb898 Mon Sep 17 00:00:00 2001 From: David McFarland Date: Wed, 17 Apr 2024 16:11:47 -0300 Subject: treewide: remove autoPatchelfHook from dotnet packages --- pkgs/applications/audio/galaxy-buds-client/default.nix | 2 -- pkgs/applications/blockchains/wasabibackend/default.nix | 2 -- pkgs/applications/misc/avalonia-ilspy/default.nix | 4 +--- pkgs/development/compilers/inklecate/default.nix | 2 -- .../tools/continuous-integration/github-runner/default.nix | 5 +---- pkgs/tools/games/opentracker/default.nix | 8 -------- pkgs/tools/networking/mqttmultimeter/default.nix | 6 ------ 7 files changed, 2 insertions(+), 27 deletions(-) (limited to 'pkgs/development/compilers') diff --git a/pkgs/applications/audio/galaxy-buds-client/default.nix b/pkgs/applications/audio/galaxy-buds-client/default.nix index 15125358e4647..6dd2256d7c8a4 100644 --- a/pkgs/applications/audio/galaxy-buds-client/default.nix +++ b/pkgs/applications/audio/galaxy-buds-client/default.nix @@ -2,7 +2,6 @@ , stdenv , buildDotnetModule , fetchFromGitHub -, autoPatchelfHook , fontconfig , xorg , libglvnd @@ -27,7 +26,6 @@ buildDotnetModule rec { dotnetFlags = [ "-p:Runtimeidentifier=linux-x64" ]; nativeBuildInputs = [ - autoPatchelfHook copyDesktopItems graphicsmagick ]; diff --git a/pkgs/applications/blockchains/wasabibackend/default.nix b/pkgs/applications/blockchains/wasabibackend/default.nix index 79355f3979dca..1371be1a97520 100644 --- a/pkgs/applications/blockchains/wasabibackend/default.nix +++ b/pkgs/applications/blockchains/wasabibackend/default.nix @@ -4,7 +4,6 @@ fetchFromGitHub, buildDotnetModule, dotnetCorePackages, - autoPatchelfHook, zlib, openssl, }: @@ -25,7 +24,6 @@ buildDotnetModule rec { dotnet-sdk = dotnetCorePackages.sdk_7_0; dotnet-runtime = dotnetCorePackages.aspnetcore_7_0; - nativeBuildInputs = [autoPatchelfHook]; buildInputs = [stdenv.cc.cc.lib zlib]; runtimeDeps = [openssl zlib]; diff --git a/pkgs/applications/misc/avalonia-ilspy/default.nix b/pkgs/applications/misc/avalonia-ilspy/default.nix index 797a8ffe5c936..d8ae98e66acd6 100644 --- a/pkgs/applications/misc/avalonia-ilspy/default.nix +++ b/pkgs/applications/misc/avalonia-ilspy/default.nix @@ -15,7 +15,6 @@ , makeDesktopItem , copyDesktopItems , icoutils -, autoPatchelfHook , bintools , fixDarwinDylibNames , autoSignDarwinBinariesHook @@ -40,8 +39,7 @@ buildDotnetModule rec { nativeBuildInputs = [ copyDesktopItems icoutils - ] ++ lib.optionals stdenv.hostPlatform.isLinux [ autoPatchelfHook ] - ++ lib.optionals stdenv.hostPlatform.isDarwin [ bintools fixDarwinDylibNames ] + ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ bintools fixDarwinDylibNames ] ++ lib.optionals (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isAarch64) [ autoSignDarwinBinariesHook ]; buildInputs = [ diff --git a/pkgs/development/compilers/inklecate/default.nix b/pkgs/development/compilers/inklecate/default.nix index fa701d8fd269e..52c278a1bd30f 100644 --- a/pkgs/development/compilers/inklecate/default.nix +++ b/pkgs/development/compilers/inklecate/default.nix @@ -1,6 +1,5 @@ { lib , stdenv -, autoPatchelfHook , buildDotnetModule , dotnetCorePackages , fetchFromGitHub @@ -17,7 +16,6 @@ buildDotnetModule rec { hash = "sha512-aUjjT5Qf64wrKRn1vkwJadMOBWMkvsXUjtZ7S3/ZWAh1CCDkQNO84mSbtbVc9ny0fKeJEqaDX2tJNwq7pYqAbA=="; }; - nativeBuildInputs = lib.optionals stdenv.isLinux [ autoPatchelfHook ]; buildInputs = [ stdenv.cc.cc.lib ]; projectFile = "inklecate/inklecate.csproj"; diff --git a/pkgs/development/tools/continuous-integration/github-runner/default.nix b/pkgs/development/tools/continuous-integration/github-runner/default.nix index e9aace248d865..34aaf68bb0ff3 100644 --- a/pkgs/development/tools/continuous-integration/github-runner/default.nix +++ b/pkgs/development/tools/continuous-integration/github-runner/default.nix @@ -1,5 +1,4 @@ -{ autoPatchelfHook -, autoSignDarwinBinariesHook +{ autoSignDarwinBinariesHook , buildDotnetModule , dotnetCorePackages , fetchFromGitHub @@ -114,8 +113,6 @@ buildDotnetModule rec { nativeBuildInputs = [ which git - ] ++ lib.optionals stdenv.isLinux [ - autoPatchelfHook ] ++ lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [ autoSignDarwinBinariesHook ]; diff --git a/pkgs/tools/games/opentracker/default.nix b/pkgs/tools/games/opentracker/default.nix index 6bb5fc8ff207d..5bab19fa2ad97 100644 --- a/pkgs/tools/games/opentracker/default.nix +++ b/pkgs/tools/games/opentracker/default.nix @@ -3,7 +3,6 @@ stdenv, buildDotnetModule, fetchFromGitHub, - autoPatchelfHook, wrapGAppsHook, dotnetCorePackages, fontconfig, @@ -40,7 +39,6 @@ buildDotnetModule rec { ]; nativeBuildInputs = [ - autoPatchelfHook wrapGAppsHook ]; @@ -64,12 +62,6 @@ buildDotnetModule rec { libXi ]); - # Attempts to patchelf unneeded SOs - autoPatchelfIgnoreMissingDeps = [ - "libc.musl-x86_64.so.1" - "libintl.so.8" - ]; - meta = with lib; { description = "A tracking application for A Link to the Past Randomizer"; homepage = "https://github.com/trippsc2/OpenTracker"; diff --git a/pkgs/tools/networking/mqttmultimeter/default.nix b/pkgs/tools/networking/mqttmultimeter/default.nix index e2d6f4e6fbd37..1c2c290bef787 100644 --- a/pkgs/tools/networking/mqttmultimeter/default.nix +++ b/pkgs/tools/networking/mqttmultimeter/default.nix @@ -4,7 +4,6 @@ , dotnet-runtime_8 , buildDotnetModule , fetchFromGitHub -, autoPatchelfHook , fontconfig , xorg , libglvnd @@ -12,9 +11,6 @@ , copyDesktopItems }: -# NOTES: -# 1. we need autoPatchelfHook for quite a number of things in $out/lib - buildDotnetModule rec { pname = "mqttmultimeter"; version = "1.8.2.272"; @@ -35,13 +31,11 @@ buildDotnetModule rec { executables = [ "mqttMultimeter" ]; nativeBuildInputs = [ - autoPatchelfHook copyDesktopItems ]; buildInputs = [ stdenv.cc.cc.lib fontconfig ]; - # don't care about musl and windows versions, as they fail autoPatchelfHook postInstall = '' rm -rf $out/lib/${lib.toLower pname}/runtimes/{*musl*,win*} ''; -- cgit 1.4.1 From 8420bae6105680deae07dc4bb634b77df011b864 Mon Sep 17 00:00:00 2001 From: Owen Lynch Date: Tue, 23 Apr 2024 01:25:37 -0700 Subject: ber_metaocaml: 111 -> 114 (#303529) --- pkgs/development/compilers/ocaml/ber-metaocaml.nix | 19 ++++--------------- 1 file changed, 4 insertions(+), 15 deletions(-) (limited to 'pkgs/development/compilers') diff --git a/pkgs/development/compilers/ocaml/ber-metaocaml.nix b/pkgs/development/compilers/ocaml/ber-metaocaml.nix index 36ea949d1ece0..230c911ef68ca 100644 --- a/pkgs/development/compilers/ocaml/ber-metaocaml.nix +++ b/pkgs/development/compilers/ocaml/ber-metaocaml.nix @@ -9,9 +9,9 @@ let x11deps = [ libX11 xorgproto ]; inherit (lib) optionals; - baseOcamlBranch = "4.11"; + baseOcamlBranch = "4.14"; baseOcamlVersion = "${baseOcamlBranch}.1"; - metaocamlPatch = "111"; + metaocamlPatch = "114"; in stdenv.mkDerivation rec { @@ -20,12 +20,12 @@ stdenv.mkDerivation rec { src = fetchurl { url = "https://caml.inria.fr/pub/distrib/ocaml-${baseOcamlBranch}/ocaml-${baseOcamlVersion}.tar.gz"; - sha256 = "sha256-3Yi2OFvZLgrZInMuKMxoyHd4QXcOoAPCC9FS9dtEFc4="; + sha256 = "sha256-GDl53JwJyw9YCiMraFMaCbAlqmKLjY1ydEnxRv1vX+4="; }; metaocaml = fetchurl { url = "http://okmij.org/ftp/ML/ber-metaocaml-${metaocamlPatch}.tar.gz"; - sha256 = "sha256-hDb0w0ZCm0hCz8jktZKmr/7gPSfBoKPT/cc7sPjt0yE="; + sha256 = "sha256-vvq3xI4jSAsrXcDk97TPbFDYgO9NcQeN/yBcUbcb/y0="; }; x11env = buildEnv { name = "x11env"; paths = x11deps; }; @@ -38,17 +38,6 @@ stdenv.mkDerivation rec { dontStrip = true; buildInputs = [ ncurses ] ++ optionals useX11 x11deps; - patches = [ - # glibc 2.34 changed SIGSTKSZ from a #define'd integer to an - # expression involving a function call. This broke all code that - # used SIGSTKSZ as the size of a statically-allocated array. This - # patch is also applied by the ocaml/4.07.nix expression. - (fetchpatch { - url = "https://github.com/ocaml/ocaml/commit/dd28ac0cf4365bd0ea1bcc374cbc5e95a6f39bea.patch"; - sha256 = "sha256-OmyovAu+8sgg3n5YD29Cytx3u/9PO2ofMsmrwiKUxks="; - }) - ]; - postConfigure = '' tar -xvzf $metaocaml cd ${pname}-${version} -- cgit 1.4.1