3 Commits

Author SHA1 Message Date
5d861077b4 Add meta to intel 2023
All checks were successful
CI / build:all (pull_request) Successful in 16s
2025-10-10 12:23:34 +02:00
391a27454b Add meta to packages 2025-10-09 18:19:05 +02:00
c4c3e54133 Add maintainers 2025-10-09 18:09:31 +02:00
4 changed files with 22 additions and 41 deletions

View File

@@ -12,9 +12,4 @@ jobs:
runs-on: native runs-on: native
steps: steps:
- uses: https://gitea.com/ScMi1/checkout@v1.4 - uses: https://gitea.com/ScMi1/checkout@v1.4
- run: nix build -L --no-link --print-out-paths .#bsc.ci.all - run: nix build -L --no-link --print-out-paths .#bsc-ci.all
build:cross:
runs-on: native
steps:
- uses: https://gitea.com/ScMi1/checkout@v1.4
- run: nix build -L --no-link --print-out-paths .#bsc.ci.cross

View File

@@ -42,7 +42,9 @@ in
# full nixpkgs with our overlay applied # full nixpkgs with our overlay applied
legacyPackages.${system} = pkgs; legacyPackages.${system} = pkgs;
hydraJobs = self.legacyPackages.${system}.bsc.hydraJobs; hydraJobs = {
inherit (self.legacyPackages.${system}.bsc-ci) tests pkgs cross;
};
# propagate nixpkgs lib, so we can do bscpkgs.lib # propagate nixpkgs lib, so we can do bscpkgs.lib
lib = nixpkgs.lib // { lib = nixpkgs.lib // {

View File

@@ -94,18 +94,12 @@ let
}; };
}; };
# For now, only build toplevel packages in CI/Hydra pkgs = filterAttrs (_: isDerivation) bscPkgs;
pkgsTopLevel = filterAttrs (_: isDerivation) bscPkgs;
# Native build in that platform doesn't imply cross build works crossTargets = [ "riscv64" ];
canCrossCompile = platform: pkg: cross = prev.lib.genAttrs crossTargets (target:
(isDerivation pkg) && final.pkgsCross.${target}.bsc-ci.pkgs
# Must be defined explicitly );
(pkg.meta.cross or false) &&
(meta.availableOn platform pkg);
# For now only RISC-V
crossSet = { riscv64 = final.pkgsCross.riscv64.bsc.pkgsTopLevel; };
buildList = name: paths: buildList = name: paths:
final.runCommandLocal name { } '' final.runCommandLocal name { } ''
@@ -119,14 +113,12 @@ let
printf '%s\n' $deps >$out printf '%s\n' $deps >$out
''; '';
pkgsList = buildList "ci-pkgs" (builtins.attrValues pkgsTopLevel); crossList = builtins.mapAttrs (t: v: buildList t (builtins.attrValues v)) cross;
testsList = buildList "ci-tests" (collect isDerivation tests);
allList = buildList' "ci-all" [ pkgsList testsList ]; pkgsList = buildList "ci-pkgs" (builtins.attrValues pkgs);
# For now only RISC-V testList = buildList "ci-tests" (collect isDerivation tests);
crossList = buildList "ci-cross"
(filter all = buildList' "ci-all" [ pkgsList testList ];
(canCrossCompile final.pkgsCross.riscv64.stdenv.hostPlatform)
(builtins.attrValues crossSet.riscv64));
in bscPkgs // { in bscPkgs // {
@@ -136,21 +128,14 @@ in bscPkgs // {
}; };
}; };
# Prevent accidental usage of bsc-ci attribute # Prevent accidental usage of bsc attribute
bsc-ci = throw "the bsc-ci attribute is deprecated, use bsc.ci"; bsc = throw "the bsc attribute is deprecated, packages are now in the root";
# Internal for our CI tests # Internal for our CI tests
bsc = { bsc-ci = {
# CI targets for nix build inherit pkgs pkgsList;
ci = { pkgs = pkgsList; tests = testsList; all = allList; cross = crossList; }; inherit tests testList;
inherit cross crossList;
# Direct access to package sets inherit all;
tests = tests;
pkgs = bscPkgs;
pkgsTopLevel = pkgsTopLevel;
cross = crossSet;
# Hydra uses attribute sets of pkgs
hydraJobs = { tests = tests; pkgs = pkgsTopLevel; cross = crossSet; };
}; };
} }

View File

@@ -62,6 +62,5 @@ in
maintainers = with lib.maintainers.bsc; [ rarias ]; maintainers = with lib.maintainers.bsc; [ rarias ];
platforms = lib.platforms.linux; platforms = lib.platforms.linux;
license = lib.licenses.gpl3Plus; license = lib.licenses.gpl3Plus;
cross = true;
}; };
} }