Merge pull request #318036 from herberteuler/fix/jbr-21
jetbrains-jdk: 17.0.11 -> 21.0.3
This commit is contained in:
commit
bac3e72803
@ -2,8 +2,7 @@
|
|||||||
, stdenv
|
, stdenv
|
||||||
, fetchFromGitHub
|
, fetchFromGitHub
|
||||||
, jetbrains
|
, jetbrains
|
||||||
, openjdk17
|
, jdk
|
||||||
, openjdk17-bootstrap
|
|
||||||
, git
|
, git
|
||||||
, autoconf
|
, autoconf
|
||||||
, unzip
|
, unzip
|
||||||
@ -37,28 +36,28 @@ let
|
|||||||
}.${stdenv.hostPlatform.system} or (throw "Unsupported system: ${stdenv.hostPlatform.system}");
|
}.${stdenv.hostPlatform.system} or (throw "Unsupported system: ${stdenv.hostPlatform.system}");
|
||||||
cpu = stdenv.hostPlatform.parsed.cpu.name;
|
cpu = stdenv.hostPlatform.parsed.cpu.name;
|
||||||
in
|
in
|
||||||
openjdk17.overrideAttrs (oldAttrs: rec {
|
jdk.overrideAttrs (oldAttrs: rec {
|
||||||
pname = "jetbrains-jdk" + lib.optionalString withJcef "-jcef";
|
pname = "jetbrains-jdk" + lib.optionalString withJcef "-jcef";
|
||||||
javaVersion = "17.0.11";
|
javaVersion = "21.0.3";
|
||||||
build = "1207.24";
|
build = "465.3";
|
||||||
# To get the new tag:
|
# To get the new tag:
|
||||||
# git clone https://github.com/jetbrains/jetbrainsruntime
|
# git clone https://github.com/jetbrains/jetbrainsruntime
|
||||||
# cd jetbrainsruntime
|
# cd jetbrainsruntime
|
||||||
# git reset --hard [revision]
|
# git checkout jbr-release-${javaVersion}b${build}
|
||||||
# git log --simplify-by-decoration --decorate=short --pretty=short | grep "jbr-" --color=never | cut -d "(" -f2 | cut -d ")" -f1 | awk '{print $2}' | sort -t "-" -k 2 -g | tail -n 1 | tr -d ","
|
# git log --simplify-by-decoration --decorate=short --pretty=short | grep "jbr-" --color=never | cut -d "(" -f2 | cut -d ")" -f1 | awk '{print $2}' | sort -t "-" -k 2 -g | tail -n 1 | tr -d ","
|
||||||
openjdkTag = "jbr-17.0.8+7";
|
openjdkTag = "jbr-21.0.2+3";
|
||||||
version = "${javaVersion}-b${build}";
|
version = "${javaVersion}-b${build}";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "JetBrains";
|
owner = "JetBrains";
|
||||||
repo = "JetBrainsRuntime";
|
repo = "JetBrainsRuntime";
|
||||||
rev = "jb${version}";
|
rev = "jb${version}";
|
||||||
hash = "sha256-a7cJF2iCW/1GK0/GmVbaY5pYcn3YtZy5ngFkyAGRhu0=";
|
hash = "sha256-Pup/XeHExCE6yy2o74wF7VlYU6MI9cg8gb69V3bclIo=";
|
||||||
};
|
};
|
||||||
|
|
||||||
BOOT_JDK = openjdk17-bootstrap.home;
|
BOOT_JDK = jdk.home;
|
||||||
# run `git log -1 --pretty=%ct` in jdk repo for new value on update
|
# run `git log -1 --pretty=%ct` in jdk repo for new value on update
|
||||||
SOURCE_DATE_EPOCH = 1715809405;
|
SOURCE_DATE_EPOCH = 1717225235;
|
||||||
|
|
||||||
patches = [ ];
|
patches = [ ];
|
||||||
|
|
||||||
@ -74,7 +73,8 @@ openjdk17.overrideAttrs (oldAttrs: rec {
|
|||||||
-e "s/SOURCE_DATE_EPOCH=.*//" \
|
-e "s/SOURCE_DATE_EPOCH=.*//" \
|
||||||
-e "s/export SOURCE_DATE_EPOCH//" \
|
-e "s/export SOURCE_DATE_EPOCH//" \
|
||||||
-i jb/project/tools/common/scripts/common.sh
|
-i jb/project/tools/common/scripts/common.sh
|
||||||
sed -i "s/STATIC_CONF_ARGS/STATIC_CONF_ARGS \$configureFlags/" jb/project/tools/linux/scripts/mkimages_${arch}.sh
|
configureFlags=$(echo $configureFlags | sed 's/--host=[^ ]*//')
|
||||||
|
sed -i "s|STATIC_CONF_ARGS|STATIC_CONF_ARGS \$configureFlags|" jb/project/tools/linux/scripts/mkimages_${arch}.sh
|
||||||
sed \
|
sed \
|
||||||
-e "s/create_image_bundle \"jb/#/" \
|
-e "s/create_image_bundle \"jb/#/" \
|
||||||
-e "s/echo Creating /exit 0 #/" \
|
-e "s/echo Creating /exit 0 #/" \
|
||||||
@ -144,7 +144,7 @@ openjdk17.overrideAttrs (oldAttrs: rec {
|
|||||||
your own risk.
|
your own risk.
|
||||||
'';
|
'';
|
||||||
homepage = "https://confluence.jetbrains.com/display/JBR/JetBrains+Runtime";
|
homepage = "https://confluence.jetbrains.com/display/JBR/JetBrains+Runtime";
|
||||||
inherit (openjdk17.meta) license platforms mainProgram;
|
inherit (jdk.meta) license platforms mainProgram;
|
||||||
maintainers = with maintainers; [ edwtjo ];
|
maintainers = with maintainers; [ edwtjo ];
|
||||||
|
|
||||||
broken = stdenv.isDarwin;
|
broken = stdenv.isDarwin;
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
, stdenv
|
, stdenv
|
||||||
, cmake
|
, cmake
|
||||||
, python3
|
, python3
|
||||||
, jdk17
|
, jdk
|
||||||
, git
|
, git
|
||||||
, libcef
|
, libcef
|
||||||
, rsync
|
, rsync
|
||||||
@ -101,20 +101,20 @@ let
|
|||||||
in
|
in
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
pname = "jcef-jetbrains";
|
pname = "jcef-jetbrains";
|
||||||
rev = "5e368cf6456d6319967e466e96ad5fa99f412c85";
|
rev = "34dfd656652c24da31b89c39d0885f284722eeaa";
|
||||||
# This is the commit number
|
# This is the commit number
|
||||||
# Currently from the branch: https://github.com/JetBrains/jcef/tree/232
|
# Currently from the branch: https://github.com/JetBrains/jcef/tree/242
|
||||||
# Run `git rev-list --count HEAD`
|
# Run `git rev-list --count HEAD`
|
||||||
version = "767";
|
version = "867";
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake python3 jdk17 git rsync ant ninja strip-nondeterminism stripJavaArchivesHook ];
|
nativeBuildInputs = [ cmake python3 jdk git rsync ant ninja strip-nondeterminism stripJavaArchivesHook ];
|
||||||
buildInputs = [ boost libX11 libXdamage nss nspr thrift ];
|
buildInputs = [ boost libX11 libXdamage nss nspr thrift ];
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "jetbrains";
|
owner = "jetbrains";
|
||||||
repo = "jcef";
|
repo = "jcef";
|
||||||
inherit rev;
|
inherit rev;
|
||||||
hash = "sha256-n+zwxHkyjkjaFhnYWcDNfsqRZIXzZplZiyeHNExfxKU=";
|
hash = "sha256-JlTGKqvgdBpBs2xtFMTVJ/ZksT1uME/8a2g7niH2sq8=";
|
||||||
};
|
};
|
||||||
cef-bin =
|
cef-bin =
|
||||||
let
|
let
|
||||||
@ -130,6 +130,7 @@ stdenv.mkDerivation rec {
|
|||||||
url = "https://cef-builds.spotifycdn.com/${urlName}.tar.bz2";
|
url = "https://cef-builds.spotifycdn.com/${urlName}.tar.bz2";
|
||||||
inherit name hash;
|
inherit name hash;
|
||||||
};
|
};
|
||||||
|
# Find the hash in tools/buildtools/linux64/clang-format.sha1
|
||||||
clang-fmt = fetchurl {
|
clang-fmt = fetchurl {
|
||||||
url = "https://storage.googleapis.com/chromium-clang-format/dd736afb28430c9782750fc0fd5f0ed497399263";
|
url = "https://storage.googleapis.com/chromium-clang-format/dd736afb28430c9782750fc0fd5f0ed497399263";
|
||||||
hash = "sha256-4H6FVO9jdZtxH40CSfS+4VESAHgYgYxfCBFSMHdT0hE=";
|
hash = "sha256-4H6FVO9jdZtxH40CSfS+4VESAHgYgYxfCBFSMHdT0hE=";
|
||||||
@ -180,11 +181,15 @@ stdenv.mkDerivation rec {
|
|||||||
../tools/compile.sh ${platform} Release
|
../tools/compile.sh ${platform} Release
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# Mostly taken from jb/tools/common/create_modules.sh
|
# N.B. For new versions, manually synchronize the following
|
||||||
|
# definitions with jb/tools/common/create_modules.sh to include
|
||||||
|
# newly added modules
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
runHook preInstall
|
runHook preInstall
|
||||||
|
|
||||||
export JCEF_ROOT_DIR=$(realpath ..)
|
export JCEF_ROOT_DIR=$(realpath ..)
|
||||||
|
export THRIFT_DIR="$JCEF_ROOT_DIR"/third_party/thrift
|
||||||
|
export THRIFT_JAR=libthrift-0.19.0.jar
|
||||||
export OUT_NATIVE_DIR=$JCEF_ROOT_DIR/jcef_build/native/${buildType}
|
export OUT_NATIVE_DIR=$JCEF_ROOT_DIR/jcef_build/native/${buildType}
|
||||||
export JB_TOOLS_DIR=$(realpath ../jb/tools)
|
export JB_TOOLS_DIR=$(realpath ../jb/tools)
|
||||||
export JB_TOOLS_OS_DIR=$JB_TOOLS_DIR/linux
|
export JB_TOOLS_OS_DIR=$JB_TOOLS_DIR/linux
|
||||||
@ -244,6 +249,11 @@ stdenv.mkDerivation rec {
|
|||||||
'' + ''
|
'' + ''
|
||||||
|
|
||||||
cd ../jcef
|
cd ../jcef
|
||||||
|
cp "$THRIFT_DIR"/"$THRIFT_JAR" .
|
||||||
|
cp "$JB_TOOLS_DIR"/common/thrift-module-info.java module-info.java
|
||||||
|
javac --patch-module org.apache.thrift=$THRIFT_JAR module-info.java
|
||||||
|
jar uf $THRIFT_JAR module-info.class
|
||||||
|
rm module-info.class module-info.java
|
||||||
cp "$OUT_CLS_DIR"/jcef.jar .
|
cp "$OUT_CLS_DIR"/jcef.jar .
|
||||||
mkdir lib
|
mkdir lib
|
||||||
cp -R "$OUT_NATIVE_DIR"/* lib
|
cp -R "$OUT_NATIVE_DIR"/* lib
|
||||||
@ -264,6 +274,7 @@ stdenv.mkDerivation rec {
|
|||||||
jmod create --module-path . --class-path jogl-all.jar --libs lib $out/jmods/jogl.all.jmod
|
jmod create --module-path . --class-path jogl-all.jar --libs lib $out/jmods/jogl.all.jmod
|
||||||
cd ../jcef
|
cd ../jcef
|
||||||
jmod create --module-path . --class-path jcef.jar --libs lib $out/jmods/jcef.jmod
|
jmod create --module-path . --class-path jcef.jar --libs lib $out/jmods/jcef.jmod
|
||||||
|
jmod create --module-path . --class-path $THRIFT_JAR $out/jmods/org.apache.thrift.jmod
|
||||||
|
|
||||||
# stripJavaArchivesHook gets rid of jar file timestamps, but not of jmod file timestamps
|
# stripJavaArchivesHook gets rid of jar file timestamps, but not of jmod file timestamps
|
||||||
# We have to manually call strip-nondeterminism to do this for jmod files too
|
# We have to manually call strip-nondeterminism to do this for jmod files too
|
||||||
|
@ -31183,9 +31183,16 @@ with pkgs;
|
|||||||
vmopts = config.jetbrains.vmopts or null;
|
vmopts = config.jetbrains.vmopts or null;
|
||||||
jdk = jetbrains.jdk;
|
jdk = jetbrains.jdk;
|
||||||
}) // {
|
}) // {
|
||||||
jdk-no-jcef = callPackage ../development/compilers/jetbrains-jdk { withJcef = false; };
|
jdk-no-jcef = callPackage ../development/compilers/jetbrains-jdk {
|
||||||
jdk = callPackage ../development/compilers/jetbrains-jdk { };
|
jdk = jdk21;
|
||||||
jcef = callPackage ../development/compilers/jetbrains-jdk/jcef.nix { };
|
withJcef = false;
|
||||||
|
};
|
||||||
|
jdk = callPackage ../development/compilers/jetbrains-jdk {
|
||||||
|
jdk = jdk21;
|
||||||
|
};
|
||||||
|
jcef = callPackage ../development/compilers/jetbrains-jdk/jcef.nix {
|
||||||
|
jdk = jdk21;
|
||||||
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
jmusicbot = callPackage ../applications/audio/jmusicbot { };
|
jmusicbot = callPackage ../applications/audio/jmusicbot { };
|
||||||
|
Loading…
Reference in New Issue
Block a user