Sven Tennie pushed to branch wip/supersven/libDir-setting at Glasgow Haskell Compiler / GHC Commits: 2d61f92b by Sven Tennie at 2026-04-25T12:55:32+02:00 WIP: Move pkg recaching to end - - - - - 1 changed file: - hadrian/src/Rules/BinaryDist.hs Changes: ===================================== hadrian/src/Rules/BinaryDist.hs ===================================== @@ -232,17 +232,6 @@ bindistRules = do copyDirectory (rtsIncludeDir) bindistFilesDir when windowsHost $ createGhcii (bindistFilesDir -/- "bin") - -- Call ghc-pkg recache, after copying so the package.cache is - -- accurate, then it's on the distributor to use `cp -a` to install - -- a relocatable bindist. - -- - -- N.B. the ghc-pkg executable may be prefixed with a target triple - -- (c.f. #20267). - ghcPkgName <- programName (vanillaContext Stage1 ghcPkg) - cmd_ (bindistFilesDir -/- "bin" -/- ghcPkgName) ["recache"] - - - -- TODO: we should only embed the docs that have been generated -- depending on the current settings (flavours' "ghcDocs" field and -- "--docs=.." command-line flag) @@ -280,6 +269,15 @@ bindistRules = do whenM (liftIO (IO.doesDirectoryExist (root -/- "manpage"))) $ do copyDirectory (root -/- "manpage") bindistFilesDir + -- Call ghc-pkg recache at the very end, after all file operations. + -- This ensures package.cache has the most recent timestamp, which is + -- important on Windows where 'cp -a' preserves timestamps. + -- + -- N.B. the ghc-pkg executable may be prefixed with a target triple + -- (c.f. #20267). + ghcPkgName <- programName (vanillaContext Stage1 ghcPkg) + cmd_ (bindistFilesDir -/- "bin" -/- ghcPkgName) ["recache"] + -- We then 'need' all the files necessary to configure and install -- (as in, './configure [...] && make install') this build on some -- other machine. View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/2d61f92b1007b6a6a2d7c9529a40f1d9... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/2d61f92b1007b6a6a2d7c9529a40f1d9... You're receiving this email because of your account on gitlab.haskell.org.
participants (1)
-
Sven Tennie (@supersven)