haskellPackages.Agda: set mainProgram (#425829)

This commit is contained in:
Philip Taron 2025-07-16 10:27:48 -07:00 committed by GitHub
commit e5b7598a48
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 4 additions and 2 deletions

View File

@ -65,10 +65,10 @@ let
}
''
mkdir -p $out/bin
makeWrapper ${lib.getBin Agda}/bin/agda $out/bin/agda \
makeWrapper ${lib.getExe Agda} $out/bin/agda \
${lib.optionalString (ghc != null) ''--add-flags "--with-compiler=${ghc}/bin/ghc"''} \
--add-flags "--library-file=${library-file}"
ln -s ${lib.getBin Agda}/bin/agda-mode $out/bin/agda-mode
ln -s ${lib.getExe' Agda "agda-mode"} $out/bin/agda-mode
'';
withPackages = arg: if isAttrs arg then withPackages' arg else withPackages' { pkgs = arg; };

View File

@ -1362,6 +1362,8 @@ builtins.intersectAttrs super {
# very useful.
# Flag added in Agda 2.6.4.1, was always enabled before
(enableCabalFlag "debug")
# Set the main program
(overrideCabal { mainProgram = "agda"; })
# Split outputs to reduce closure size
enableSeparateBinOutput
];