python312Packages.gurobipy: 11.0.3 -> 12.0.0 (#357427)
This commit is contained in:
commit
b013efdaa8
@ -1,24 +1,52 @@
|
||||
{ stdenv, lib, fetchurl, autoPatchelfHook, python3 }:
|
||||
{
|
||||
stdenv,
|
||||
lib,
|
||||
fetchurl,
|
||||
autoPatchelfHook,
|
||||
python3,
|
||||
}:
|
||||
|
||||
let
|
||||
platform =
|
||||
{
|
||||
aarch64-linux = "armlinux64";
|
||||
x86_64-linux = "linux64";
|
||||
}
|
||||
.${stdenv.hostPlatform.system} or (throw "Unsupported system: ${stdenv.hostPlatform.system}");
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "gurobi";
|
||||
version = "11.0.3";
|
||||
version = "12.0.0";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://packages.gurobi.com/${lib.versions.majorMinor version}/gurobi${version}_linux64.tar.gz";
|
||||
hash = "sha256-gqLIZxwjS7qp3GTaIrGVGr9BxiBH/fdwBOZfJKkd/RM=";
|
||||
url = "https://packages.gurobi.com/${lib.versions.majorMinor version}/gurobi${version}_${platform}.tar.gz";
|
||||
hash =
|
||||
{
|
||||
aarch64-linux = "sha256-jhICy/CGahb6eMPkvg+jKIjskS+N3zM8KVYdBXlk74Y=";
|
||||
x86_64-linux = "sha256-or3Jwda/jrTlUaGErxzo17BDXqjn0ZoBfMfVP9Xv2hI=";
|
||||
}
|
||||
.${stdenv.hostPlatform.system} or (throw "Unsupported system: ${stdenv.hostPlatform.system}");
|
||||
};
|
||||
|
||||
sourceRoot = "gurobi${builtins.replaceStrings ["."] [""] version}/linux64";
|
||||
sourceRoot = "gurobi${builtins.replaceStrings [ "." ] [ "" ] version}/${platform}";
|
||||
|
||||
nativeBuildInputs = [ autoPatchelfHook ];
|
||||
buildInputs = [ (python3.withPackages (ps: [ ps.gurobipy ])) ];
|
||||
nativeBuildInputs = [
|
||||
autoPatchelfHook
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
(python3.withPackages (ps: [
|
||||
ps.gurobipy
|
||||
]))
|
||||
];
|
||||
|
||||
strictDeps = true;
|
||||
|
||||
makeFlags = [ "--directory=src/build" ];
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p $out/bin
|
||||
cp bin/* $out/bin/
|
||||
rm $out/bin/gurobi.sh
|
||||
@ -39,19 +67,24 @@ stdenv.mkDerivation rec {
|
||||
mkdir -p $out/share/java
|
||||
ln -s $out/lib/gurobi.jar $out/share/java/
|
||||
ln -s $out/lib/gurobi-javadoc.jar $out/share/java/
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
passthru.libSuffix = lib.replaceStrings [ "." ] [ "" ] (lib.versions.majorMinor version);
|
||||
|
||||
meta = with lib; {
|
||||
meta = {
|
||||
description = "Optimization solver for mathematical programming";
|
||||
homepage = "https://www.gurobi.com";
|
||||
sourceProvenance = with sourceTypes; [
|
||||
sourceProvenance = with lib.sourceTypes; [
|
||||
binaryBytecode
|
||||
binaryNativeCode
|
||||
];
|
||||
license = licenses.unfree;
|
||||
platforms = [ "x86_64-linux" ];
|
||||
maintainers = with maintainers; [ wegank ];
|
||||
license = lib.licenses.unfree;
|
||||
platforms = [
|
||||
"aarch64-linux"
|
||||
"x86_64-linux"
|
||||
];
|
||||
maintainers = with lib.maintainers; [ wegank ];
|
||||
};
|
||||
}
|
||||
|
@ -17,14 +17,14 @@ let
|
||||
};
|
||||
platform = platforms.${stdenv.system} or (throw "Unsupported system: ${stdenv.system}");
|
||||
hashes = rec {
|
||||
cp311-aarch64-darwin = "sha256-E4tL6PtC1JS4SEvUz6meoeUR6IYM2xFxNJ9PzgbZqgE=";
|
||||
cp311-aarch64-linux = "sha256-hMWOFkyQ/B3ovAqsitJagrSp0webUGRzWCLOz1UrGyY=";
|
||||
cp311-aarch64-darwin = "sha256-KRC3fY7KUVCfI4u+TQQjgqLLIEunkzgIZxiuTol2/50=";
|
||||
cp311-aarch64-linux = "sha256-/DiS49iND4oB2nXxL3QCPTmO9Zmp4a3WbtdjE3M+MPs=";
|
||||
cp311-x86_64-darwin = cp311-aarch64-darwin;
|
||||
cp311-x86_64-linux = "sha256-2O7Vykgx0fELCM1wH3VIOyeBBzR1DUFKWzy25LpMF/M=";
|
||||
cp312-aarch64-darwin = "sha256-BXAJeUaVEa7fy00BNsFhB30IU5O2pEnJjp/3gYdHJ5w=";
|
||||
cp312-aarch64-linux = "sha256-t1KopNiYo8xZsGcKpEne6OIVnU9CDzADO6+W8Uo2UW0=";
|
||||
cp311-x86_64-linux = "sha256-oI+0Kl58sCzbmTwTgci4xaO67tyt1W5yiNhFile4FEI=";
|
||||
cp312-aarch64-darwin = "sha256-tcNcuYGmFScBaFUyTgVMrkc0lnhdtX8Ggr1W1YSpbu4=";
|
||||
cp312-aarch64-linux = "sha256-+Ch951NcO5yX9KqHFpadcDAqlyvQnp07b71yZsoOq3I=";
|
||||
cp312-x86_64-darwin = cp312-aarch64-darwin;
|
||||
cp312-x86_64-linux = "sha256-0IppqYhLLHq4Q8mWe0R3DBfHOsVybbeoeUroXXwfxEY=";
|
||||
cp312-x86_64-linux = "sha256-kLukle+yXP9aOCYViv974pY30ugKzMOompjLhjCFYQY=";
|
||||
};
|
||||
hash =
|
||||
hashes."${pyShortVersion}-${stdenv.system}"
|
||||
@ -32,7 +32,7 @@ let
|
||||
in
|
||||
buildPythonPackage rec {
|
||||
pname = "gurobipy";
|
||||
version = "11.0.3";
|
||||
version = "12.0.0";
|
||||
inherit format;
|
||||
|
||||
src = fetchPypi {
|
||||
|
Loading…
Reference in New Issue
Block a user