Commit f305e717 authored by Bjørn Forsman's avatar Bjørn Forsman
Browse files

quartus-prime-lite: run tests with NIXPKGS_QUARTUS_REPRODUCIBLE_BUILD=1

To prevent the reproducible build code path from regressing. Also adapt
the buildSof test to output the hash of the build artifact, so it's easy
to verify that the build is reproducible:

  $ NIXPKGS_ALLOW_UNFREE=1 nix-build -A quartus-prime-lite.tests.buildSof
  $ NIXPKGS_ALLOW_UNFREE=1 nix-build -A quartus-prime-lite.tests.buildSof --check
parent 25ce61d6
Loading
Loading
Loading
Loading
+9 −5
Original line number Diff line number Diff line
@@ -150,6 +150,7 @@ in buildFHSEnv rec {
    tests = {
      buildSof = runCommand "quartus-prime-lite-test-build-sof"
        { nativeBuildInputs = [ quartus-prime-lite ];
          env.NIXPKGS_QUARTUS_REPRODUCIBLE_BUILD = "1";
        }
        ''
          cat >mydesign.vhd <<EOF
@@ -177,9 +178,12 @@ in buildFHSEnv rec {
              exit 1
          fi

          touch "$out"
          sha1sum mydesign.sof > "$out"
        '';
      questaEncryptedModel = runCommand "quartus-prime-lite-test-questa-encrypted-model" {} ''
        questaEncryptedModel = runCommand "quartus-prime-lite-test-questa-encrypted-model"
          { env.NIXPKGS_QUARTUS_REPRODUCIBLE_BUILD = "1";
          }
          ''
            "${quartus-prime-lite}/bin/vlog" "${quartus-prime-lite.unwrapped}/questa_fse/intel/verilog/src/arriav_atoms_ncrypt.v"
            touch "$out"
          '';