Skip to content

Commit

Permalink
Add flag to toggle building executable (#81)
Browse files Browse the repository at this point in the history
Some distributors need to use the old Cabal-v1 build systems, which
will build the 'extensions' executable even if it isn't needed (for
instance when this package is only needed as a dependency for stan).

This adds a new 'executable' flag (enabled by default) which will allow
for disabling the 'extensions' executable if it isn't needed.

Signed-off-by: hololeap <[email protected]>

Signed-off-by: hololeap <[email protected]>
  • Loading branch information
hololeap authored Oct 7, 2022
1 parent ab02b7b commit be93e91
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions extensions.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@ tested-with: GHC == 8.8.4
GHC == 8.10.7
GHC == 9.0.2

flag executable
description: Build the extensions executable
default: True
manual: True

source-repository head
type: git
location: https://github.com/kowainik/extensions.git
Expand Down Expand Up @@ -79,6 +84,8 @@ library

executable extensions
import: common-options
if !flag(executable)
buildable: False
hs-source-dirs: app
main-is: Main.hs
other-modules: Cli
Expand Down

0 comments on commit be93e91

Please sign in to comment.