# SPDX-FileCopyrightText: Emery Hemingway # # SPDX-License-Identifier: LicenseRef-Hippocratic-1.1 { stdenvNoCC, fetchurl }: let stdenv = stdenvNoCC; unpack = baseUrl: { name, value }: { inherit name; value = stdenv.mkDerivation { pname = name; inherit (value) version; preferLocalBuild = true; src = fetchurl { url = "${baseUrl}${name}/${value.version}.tar.xz"; inherit (value) sha256; }; phases = [ "unpackPhase" "installPhase" "fixupPhase" "distPhase" ]; installPhase = '' find . -type f | while read FILE; do case $FILE in *.a | *.o) install -Dm444 -t $out/lib $FILE;; *.so) install -Dm555 -t $out/lib $FILE;; *.tar) install -Dm444 -t $out/tar $FILE;; *) install -Dm555 -t $out/bin $FILE;; esac done ''; meta = { license = [ "LicenseRef-Genode" ]; downloadPage = "${baseUrl}${name}/"; }; }; }; expand = baseUrl: listing: builtins.listToAttrs (map (unpack baseUrl) listing); base = expand "http://depot.hq.c3d2.de/user/bin/x86_64/" (import ./base-list.nix); genodelabs = expand "http://depot.genode.org/genodelabs/bin/x86_64/" (import ./genodelabs-list.nix); in (base // genodelabs)