Skip to content
Snippets Groups Projects
This project is mirrored from https://github.com/haskell/Cabal. Pull mirroring updated .
  1. Nov 24, 2023
    • Matthew Pickering's avatar
      External commands: Add tests for #9402 #9403 #9404 · 7fb1ca65
      Matthew Pickering authored
      This adds 4 tests which test the new external commands feature:
      
      * ExternalCommand - Tests the expected usage of external command invoked
        via cabal-install
      * ExternalCommandSetup - Tests that the ./Setup interface does not
        support external commands (#9403)
      * ExternalCommandEnv - Tests that environment variables are set and
        preserved appropiately  (#9402)
      * ExternalCommandHelp - Test that `cabal help <cmd>` is interpreted appropiately (#9404)
      7fb1ca65
  2. Nov 23, 2023
  3. Nov 21, 2023
    • BinderDavid's avatar
      Finish improvements to the CI configuration for documentation changes (#9460) · eaa5245e
      BinderDavid authored
      * Add bootstrap postjob to CI config
      
      Add a new job to the bootstrap.yml GitHub action config.
      This job succeeds if, and only if, all the other bootstrap
      jobs succeed.
      
      * Do not run bootstrap CI jobs for documentation changes
      
      The approach was already introduced in #9355 for the validate jobs.
      This commit introduces the same change also for the bootstrap jobs.
      
      * Also ignore CONTRIBUTING.md and README.md in CI
      
      We do not run the entire CI suite for documentation changes.
      Previously, only changes which were restricted to the 'docs/'
      subdirectory were considered to be documentation changes.
      With this commit we also recognize changes to README.md and
      CONTRIBUTING.md as documentation changes.
      
      * Document improved CI for documentation in CONTRIBUTING.md
      
      The CONTRIBUTING.md file now mentions that documentation changes
      do not waste expensive CI resources.
      
      * Recognize all README.md in subdirs as documentation
      
      Expensive CI jobs should not run on changes which affect only
      README.md files.
  4. Nov 19, 2023
  5. Nov 18, 2023
  6. Nov 17, 2023
  7. Nov 16, 2023
    • mergify[bot]'s avatar
      Merge pull request #9434 from sthibaul/master · a134b265
      mergify[bot] authored
      Fix the platform string for GNU/Hurd
    • sthibaul's avatar
      Fix the platform string for GNU/Hurd · 1a89c9d6
      sthibaul authored
      Since version 9.4.7-1, ghc fails to build on the GNU/Hurd port of Debian,
      see
      
      https://buildd.debian.org/status/fetch.php?pkg=ghc&arch=hurd-i386&ver=9.4.7-1&stamp=1697717885&raw=0
      
      Error, rule finished running but did not produce file:
        _build/stage0/lib/i386-gnu-ghc-9.4.6/ghc-boot-th-9.4.7/libHSghc-boot-th-9.4.7.a
      
      and indeed, what did get produce was rather
      _build/stage0/lib/i386-hurd-ghc-9.4.6/ghc-boot-th-9.4.7/libHSghc-boot-th-9.4.7.a
      (i386-hurd instead of i386-gnu).
      
      This is due to confusion between hurd and gnu in various places.  Apparently
      previous versions of ghc were using gnu for the GNU/Hurd port, and thus
      putting libraries etc. in i386-gnu. So we have to follow the existing
      practice.
      1a89c9d6
    • mergify[bot]'s avatar
      Merge pull request #9441 from sthibaul/rpath · d0630487
      mergify[bot] authored
      hurd: Enable using $ORIGIN in RPATH
    • sthibaul's avatar
      hurd: Enable using $ORIGIN in RPATH · 1dff9d52
      sthibaul authored
      GNU/Hurd fully supports RPATH and the $ORIGIN development, and we indeed
      want to use it for relocatable installations shipped in Debian GNU/Hurd.
      1dff9d52
    • mergify[bot]'s avatar
      Merge pull request #9439 from mpickering/wip/fix-8356 · 27f4ee71
      mergify[bot] authored
      testsuite: Be explicit about runtime test dependencies
    • Matthew Pickering's avatar
      testsuite: Be explicit about runtime test dependencies · 5c2286a4
      Matthew Pickering authored
      Issue #8356 reports occasional errors from running the testsuite about
      multiple package versions available. This stems from the invokation of
      `runghc` not being explicit about all dependencies of the testsuite.
      
      The solution is provide a component in the cabal file which is explicit
      about which packages the tests can depend on. This component has a
      build-depends section which lists all the dependencies that the tests
      require.
      
      It would be better if this component was a library component but we
      can't do this with a Custom setup because of limitations to do with
      per-component builds.
      
      Then we also enable `-hide-all-packages`, so the dependency will not be
      available if it is not explicitly listed as a dependency.
      
      You could also imagine a future where the Setup.hs script found the test
      files and compiled a single executable which would run all the tests,
      rather than invoking runghc on each one individually.
      
      Fixes #8356
      5c2286a4
    • mergify[bot]'s avatar
      Merge pull request #9425 from mpickering/wip/windows-cli · 840ee994
      mergify[bot] authored
      CI: Attempt to enable tests for 9.6.3 windows
    • Matthew Pickering's avatar
      ci: Enable windows tests for 9.6.3 · 0a177f3a
      Matthew Pickering authored
      There were two failing tests:
      
      1. CCompilerOverride, was attempting to use gcc.exe rather than
         clang.exe without also overriding the C options which led to
         incorrect options being passed to gcc.exe. The fix is to override to
         clang.exe on ghc-9.4 or newer.
      2. ForeignLibs exposes a bug in GHC
         (ghc/ghc#24185) and hence is
         skipped for GHCs newer than 9.4 where it was first introduced.
      
      Towards fixing #8451, we just need to fix the shared library issue now.
      0a177f3a
  8. Nov 13, 2023
    • f-a's avatar
      Reimplement `cabal check` (#8427) · 21b858f1
      f-a authored
      * Fix Semigroup target instance
      
      When two target names are the same, `mappend`ing them should not
      error but just pick the first name.
      
      * Add `desugarBuildToolSimple`
      
      * Reimplement cabal check
      
      * Reorder test output
      
      * Fix autogen modules tests .cabal files
      
      * Add a number of tests
      
      * Add test for #7423
      
      i.e. Do not warn on -O2 if under off-by-default package configuration
      flag conditional.
      
      * Add a regression for:
      
          * Add another -WErrr test
              This is to make sure we do *not* report it if it is under
              a user, off-by-default flag.
          * Add test for non manual user flags.
          * Add “absolute path in extra-lib-dirs” test
          * Add if/else test
          * Add “dircheck on abspath” check
          * Add Package version internal test
          * Add PackageVersionsStraddle test
      
      * Add changelog for #8427
      
      * Integrate various reviews
      
      * Integrate Artem’s review
      
      (review) Clarify `combineNames` documentation
      
      By explaining the way it operates (working if the two names are equal
      or one is empty) and renaming the function from `combineName` to
      `combineNames`.
      
      (review) Use guards instead of if/then/else
      
      (review) Match inside argument list
      
      (review) Replace “white” with “allow”
      
      (review) Fix typo in comment
      
      (review) Fix typo in Check module documentation
      
      (review) Harmonise indentation for `data` decls
      
      First field goes in a new line than the data constructor, so we
      have more space.
      
      (review) Rename `Prim` module to `Types`
      
      (review) Add checkPackageFilesGPD
      
      `checkPackageFiles` — which works on PD — was used to perform IO. We
      introduce a function that does the same thing but works on GPD (which
      is more principled).
      
      `checkPackageFiles` cannot just be removed, since it is part of the
      interface of Distribution.PackageDescription.Check. Deprecation can
      be planned once “new check” is up and running.
      
      * Integrate Andreas’ review
      
      (review) Add named section to missing upper bound check
      
      “miss upper bound” checks will now list target type and name (“On
      executable 'myexe', these packages miss upper bounds”) for easier
      fixing by the user.
      
      (review) remove `cabal gen-bounds` suggestion
      
      Reasonable as `cabal gen-bounds` is stricter than `cabal check`, see
      https://github.com/haskell/cabal/pull/8427#issuecomment-1446712486
      
      
      Once `gen-bounds` behaves in line with `check` we can readd the
      suggestion.
      
      (review) Do not warn on shared bounds
      
      When a target which depends on an internal library shares some
      dependencies with the latter, do not warn on upper bounds.
      
      An example is clearer
      
          library
           build-depends: text < 5
          ⁝
           build-depends: myPackage,        ← no warning, internal
                          text,             ← no warning, shared bound
                          monadacme         ← warning!
      
      * Integrate Artem’s review /II
      
      (review) Split Check.hs
      
      Check.hs has been split in multiple file, each une sub 1000 lines:
      
      Check              857 lines
      Check.Common       147 lines
      Check.Conditional  204 lines
      Check.Monad        352 lines
      Check.Paths        387 lines
      Check.Target       765 lines
      Check.Warning      865 lines
      
      Migration guide:
      - Check              GPD/PD checks plus work-tree checks.
      - Check.Common       common types and functions that are
                           *not* part of monadic checking setup.
      - Check.Conditional  checks on CondTree and related matter
                           (variables, duplicate modules).
      - Check.Monad        Backbone of the checks, monadic inter-
                           face and related functions.
      - Check.Paths        Checks on files, directories, globs.
      - Check.Target       Checks on realised targets (libraries,
                           executables, benchmarks, testsuites).
      - Check.Warning      Datatypes and strings for warnings
                           and severities.
      
      (review) remove useless section header
      
      (review) Fix typo
      
      (review) Add warnings documentation (list)
      
      For each warning, we document constructor/brief description
      in the manual.  This might not be much useful as not but it
      will come handy when introducing `--ignore=WARN` and similar
      flags.
      
      * (review Andreas) Clarify CheckExplanation comment
      
      Whoever modifies `CheckExplanation` data constructors needs to be
      aware that the documentation in  doc/cabal-commands.rst  has to be
      updated too.
      
      * Move internal Check modules to `other-modules`
      
      No need to expose Distribution.PackageDescription.Check.*
      to the world. API for checking, for cabal-install and other
      tools, should be in Distribution.PackageDescription.Check.
      
      * Make fourmolu happy
      
      Cabal codebase has now a formatter/style standard (see #8950).
      
      “Ravioli ravioli, give me the formuoli”
      
      * Do not check for OptO in scripts
      
      See #8963 for reason and clarification requests.
      
      * Remove useless PackageId parameter
      
      It is now in the Reader part of CheckM monad.
      
      * Do not check PVP on internal targets
      
      Internal: testsuite, benchmark.
      See #8361.
      
      * Make hlint happy
      
      * Fix #9122
      
      When checking internal version ranges, we need to make sure we
      are not mistaking a libraries with the same name but from different
      packages. See #9132.
      
      * Fix grammar
      
      neither…nor, completing what done in #9162
      
      * Integrate Brandon’s review: grammar
      
      * Remove unnecessary `-fvia-C` check
      
      Brandon’s review/II.
      
      ---------
      
      Co-authored-by: default avatarmergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
    • Athas's avatar
      A 'cabal path' command. (#8879) · 1908f51a
      Athas authored
      
      * Add a 'cabal path' command.
      
      * Formatting fix.
      
      * Another formatting fix.
      
      * Categorise "cabal path" as global command.
      
      * Allow individual paths to be printed.
      
      * Less duplication.
      
      * Add config-file to "cabal path".
      
      * Use sum type instead of strings.
      
      * cabal path: support --installdir.
      
      * Add documentation.
      
      * Better text.
      
      * Formatting.
      
      * Add some tests.
      
      * Improve tests.
      
      * Add changelog entry.
      
      * Mention "cabal path" in directory documentation.
      
      ---------
      
      Co-authored-by: default avatarArtem Pelenitsyn <a.pelenitsyn@gmail.com>
  9. Nov 12, 2023
  10. Nov 11, 2023
  11. Nov 10, 2023
Loading