Skip to content
Snippets Groups Projects
This project is mirrored from https://github.com/haskell/Cabal. Pull mirroring updated .
  1. Mar 16, 2024
  2. Feb 28, 2024
    • Matthew Pickering's avatar
      testsuite: Run tests in temporary system directories · 0ef4f441
      Matthew Pickering authored
      1. Working directory is not contaminated with results of the testsuite.
         Tests can be written in a more liberal way (creating/writing files
         etc).
      2. The tests are more hermetic.. for example it was basically impossible
         to write a test which run outside of a project context.
      3. The overall path lengths will be much shorter, which has been a
         consistent issue on windows. We can remove hacks like
         `withShorterPathForNewBuildStore`.
      
      Fixes #9711
      0ef4f441
  3. Feb 22, 2024
  4. Feb 08, 2024
  5. Jan 29, 2024
    • Andrea Bedini's avatar
      Drop sub-component targets (#8966) · 3f4c81fd
      Andrea Bedini authored
      This change removes support for building sub-component targets in
      cabal-install, since no versions of Cabal support this feature.
      
      The test RunMainBad is also dropped because without the concept of a
      file target, RunMainBad is the same test as ScriptBad.
  6. Jan 19, 2024
  7. Dec 18, 2023
  8. Oct 19, 2023
  9. Oct 07, 2023
  10. Jul 18, 2023
    • Matthew Pickering's avatar
      Add support for using GHC's -jsem option · 0a1c167a
      Matthew Pickering authored and Ben Gamari's avatar Ben Gamari committed
      * The top-level user interface to enable the use of the semaphore is the
        `--semaphore` flag. If you pass `-j4 --semaphore` then cabal will
        create a semaphore with 4 slots which is passed to ghc using the
        `-jsem` option so that all GHC processes coordinate to use 4
        capabilities.
      
        - The semaphore logic is provided by a new package `semaphore-compat`
          which provides a cross-platform abstraction for semaphores.
      
      * The low level `./Setup.hs build` interface accepts the `--semaphore
        <SEMAPHORE>` option, which can be used to directly pass the semaphore
        you require to the Setup script.
      0a1c167a
  11. Jun 02, 2023
  12. May 28, 2023
    • Matthew Pickering's avatar
      Add support for loading multiple components into one repl session · e61b658d
      Matthew Pickering authored and Francesco Gazzetta's avatar Francesco Gazzetta committed
      There are several parts to this patch which are logically distinct but
      work together to support the overal goal of starting a GHCi session with
      multiple packages loaded at once.
      
      1. When a user writes "cabal repl <target>" then if the user is using a
         compiler > ghc-9.4.* then we will attempt to start a multi-session
         which loads the selected targets into one multi-package session of
         GHC.
      1a. The closure property states that in order to load components `p` and `q` into
          the same session that if `p` depends on `z` and `z` depends on `q`
          then `z` must also be loaded into the session.
      1b. Only inplace packages are able to be loaded into a multi session (if a component
          `z` exists then it is already made into an inplace package by
          cabal). Therefore cabal has already engineered that there is source
          code locally available for all packages which we will want to load
          into a session.
      
      2. The solver is unmodified, the solver is given the repl targets and
         creates a build plan as before. After the solver is completed then in
         `setRootTargets` and `pruneInstallPlan` we modify the install plan to
         enforce the closure property and mark which dependencies need to be
         promised.
      
         * Mark the current components as `BuildInPlaceOnly InMemory`, which
           indicates to the compiler that it is to be built in a GHC
           multi-session.
         * Augment the component repl targets to indicate that components
           required by the closure property (in addition to normal targets)
           will be loaded into the repl.
         * Modify the dependency edges in `compLibDependencies` to indicate
           which dependencies are the promised ones (which is precisely
           components which are `BuildInPlaceOnly InMemory` build styles).
           This is the field which is eventually used to populate the
           `--dependency` argument to `./Setup configure`.
      
      Fixes #8491
      e61b658d
  13. May 24, 2023
    • Mel Zuser's avatar
      Shorten script-builds paths (#8898) · a482a63c
      Mel Zuser authored
      * Use shorter hash for script-builds directories
      
      Using a Base64 hash and truncating it to 26 characters, saves 38 chars,
      which helps avoid long paths issues on Windows, while still providing
      130 bits of hash in order to avoid collisions.
      
      Bug #8841
      
      * Use the script cache dir as the dist dir
      
      Putting script build products under dist-newstyle within the cache
      directory is unnecessary because we already control the cache directory
      and can ensure there are no conflicts.
      
      * Use the actual script name in the executable name
      
      Previously, the script name was sanitized in final executable name,
      because the executable name had to match the component name, which only
      allowed for a limited character set. Now we can use the actual script
      name in the executable name. This only lets us shorten the component
      name without losing clarity.
      
      * Add changelog entry
      
      * Reenable script tests for Windows/ghc-9.4.*
  14. Apr 03, 2023
  15. Feb 13, 2023
  16. Dec 31, 2022
  17. Nov 10, 2022
  18. Oct 07, 2022
  19. Sep 24, 2022
  20. Aug 24, 2022
  21. Aug 07, 2022
  22. Aug 04, 2022
  23. Jul 28, 2022
  24. Jul 12, 2022
  25. May 16, 2022
  26. Apr 29, 2022
  27. Apr 04, 2022
    • Robert's avatar
      Fix race condition in PackageTests/NewBuild/CmdRun/Terminate · 2521ee9d
      Robert authored
      The "up and running" file was written before the signal handler
      was installed, so it was possible for the test to kill the
      subprocess before, leading to a missed "exiting" line in the
      output.
      
      I hope this fixes the sporadic failures we're seeing (#8080).
      2521ee9d
  28. Mar 25, 2022
  29. Mar 18, 2022
  30. Mar 15, 2022
Loading