diff --git a/hledger-ui/hledger-ui.cabal b/hledger-ui/hledger-ui.cabal index 40f78392a..5e4b225e6 100644 --- a/hledger-ui/hledger-ui.cabal +++ b/hledger-ui/hledger-ui.cabal @@ -79,6 +79,8 @@ executable hledger-ui , transformers , vector , vty >= 5.2 && < 5.8 + if os(windows) + buildable: False if flag(threaded) ghc-options: -threaded if flag(old-locale) diff --git a/hledger-ui/package.yaml b/hledger-ui/package.yaml index b94f0ad2a..f833e0ecf 100644 --- a/hledger-ui/package.yaml +++ b/hledger-ui/package.yaml @@ -48,6 +48,17 @@ flags: manual: false default: false +# curses is required to build terminfo for vty for hledger-ui. +# On POSIX systems it might be not present. +# On windows it's very likely not present, but possibly it could be. +# Ideally we'd like to +# on POSIX: give a clear error ("install your system libcurses-dev package") if not present +# on windows: quietly skip building if not present, build if it is present +# curses +# default: True +# description: +# For now, just don't build hledger-ui on windows + cpp-options: -DVERSION="0.28" executables: @@ -85,6 +96,8 @@ executables: - vector - vty >= 5.2 && < 5.8 when: + - condition: os(windows) + buildable: false - condition: flag(threaded) ghc-options: -threaded - condition: flag(old-locale)