
Hi Marc Yes this is possible using the 'Buildable' field. executable yyyywebinterface build-depends: cgi, xhtml Main-is: web/yyyWebInterface.hs Extensions: PatternGuards ScopedTypeVariables Ghc-options: -Wall if flag(web) Buildable: True else Buildable: False regards allan Marc Weber wrote:
Hi,
Can I enable/ disable executable by flags ? eg this way:
============= ======================================================= Name: xxxxxxxxxxxxx category: web application version: 0.0.1 Cabal-Version: >=1.2 build-type: Simple LICENSE: GPL extensions: CPP cpp-options: -DSSTRING=B.ByteString -DLSTRING=L.ByteString
Flag testing Default: True Description build testing application as well
executable YYYYYYYYYYy main-is: YYYYYYYYYYy.hs hs-source-dirs: src build-depends: base , HList -- , HaXml == 1.19 , filepath , mtl , containers , template-haskell , directory , HAppS-Server , HAppS-Data , HAppS-State , type-level include-dirs: include extra-source-files: include/vxmldos.h -- strict and lazy strings beeing used
if flag(testing) executable test main-is: test.hs hs-source-dirs: test, src build-depends: base , HList -- , HaXml == 1.19 , filepath , mtl , containers , template-haskell , directory , HAppS-Server , HAppS-Data , HAppS-State , type-level include-dirs: include extra-source-files: include/vxmldos.h -- strict and lazy strings beeing used ============= =======================================================
By the way this results in
marc@mail: /pr/haskell/waskaufeichwo ]$ sConfigure bash: /home/marc/ghc69/bin/ghc-pkg: No such file or directory setup: 'parseField' called on a non-field. Consider this a bug. ^^^^^^^^^^^^^^^^^^^ Don't think its harmfull
marc@mail: /pr/haskell/waskaufeichwo ]$ ./setup --version Cabal library version 1.5.5
Do you build test tests this way as well?
Marc
_______________________________________________ cabal-devel mailing list cabal-devel@haskell.org http://www.haskell.org/mailman/listinfo/cabal-devel
-- The University of Edinburgh is a charitable body, registered in Scotland, with registration number SC005336.