on iko/ghcjs-patch-master help sign in
Check that the library component package.conf.d/*.conf file is created (#956)

Had a strange issue where eval of #955 and it might have been caused by a the nix-tools library seeming to have no `.conf` files. Since it seemed to go away by itself I think this was a nix GC issue or something. Here is some code we could add to the builders to double check the files are created if it turns out that is not the case. Co-authored-by: Rodney Lorrimar <rodney.lorrimar@iohk.io>

commit062a0317b6f1ec231864df49cb9c0fcc838e9c8a authorHamish Mackenzie <Hamish.Mackenzie@iohk.io> dateTue 6 Jul 2021, 13:24 (5 years ago) parentd8f6361
1 file changed+10
builder/comp-builder.nix+10
builder/comp-builder.nix+10
@@ -515,6 +515,16 @@ let
515515 echo The test ${package.identifier.name}.components.tests.${componentId.cname} was built. To run the test build ${package.identifier.name}.checks.${componentId.cname}.
516516 '');
517517
518+ doInstallCheck = true;
519+ installCheckPhase = lib.optionalString (haskellLib.isLibrary componentId) ''
520+ if test -n "$(shopt -s nullglob; echo $out/package.conf.d/${name}-*.conf)"; then
521+ echo $out/package.conf.d/${name}-*.conf " is present"
522+ else
523+ echo "ERROR: $out/package.conf.d/${name}-*.conf was not created"
524+ exit 1
525+ fi
526+ '';
527+
518528 shellHook = ''
519529 export PATH="${shellWrappers}/bin:$PATH"
520530 ${shellHookApplied}