3
0
Fork 0
forked from mirrors/nixpkgs

rocclr: add update script

This commit is contained in:
Sebastian Neubauer 2021-09-08 19:12:32 +02:00
parent 61a2864b18
commit 6e93fa31f2

View file

@ -1,5 +1,6 @@
{ lib, stdenv
, fetchFromGitHub
, writeScript
, cmake
, rocm-cmake
, clang
@ -51,6 +52,13 @@ stdenv.mkDerivation rec {
--replace "/build/source/build" "$out"
'';
passthru.updateScript = writeScript "update.sh" ''
#!/usr/bin/env nix-shell
#!nix-shell -i bash -p curl jq common-updater-scripts
version="$(curl -sL "https://api.github.com/repos/ROCm-Developer-Tools/ROCclr/tags" | jq '.[].name | split("-") | .[1] | select( . != null )' --raw-output | sort -n | tail -1)"
update-source-version rocclr "$version"
'';
meta = with lib; {
description = "Radeon Open Compute common language runtime";
homepage = "https://github.com/ROCm-Developer-Tools/ROCclr";