9 stdenv.mkDerivation (finalAttrs: {
14 url = "https://github.com/sbt/sbt/releases/download/v${finalAttrs.version}/sbt-${finalAttrs.version}.tgz";
15 hash = "sha256-xXyuYMISLKG7p3GE37TQ0l/GwYgFOUqzarYgiwwPJi8=";
19 echo -java-home ${jre.home} >>conf/sbtopts
22 nativeBuildInputs = lib.optionals stdenv.isLinux [ autoPatchelfHook ];
24 buildInputs = lib.optionals stdenv.isLinux [
25 stdenv.cc.cc # libstdc++.so.6
32 mkdir -p $out/share/sbt $out/bin
33 cp -ra . $out/share/sbt
34 ln -sT ../share/sbt/bin/sbt $out/bin/sbt
35 ln -sT ../share/sbt/bin/sbtn-${
36 if (stdenv.hostPlatform.isAarch64) then "aarch64" else "x86_64"
38 if (stdenv.isDarwin) then "apple-darwin" else "pc-linux"
45 homepage = "https://www.scala-sbt.org/";
46 license = licenses.bsd3;
47 sourceProvenance = with sourceTypes; [
51 description = "A build tool for Scala, Java and more";
52 maintainers = with maintainers; [ nequissimus kashw2 ];
53 platforms = platforms.unix;