Seagate / halon

High availability solution
Apache License 2.0
1 stars 0 forks source link

stack.yaml: add rebuild-ghc-options: true #1485

Closed 1468ca0b-2a64-4fb4-8e52-ea5806644b4c closed 6 years ago

1468ca0b-2a64-4fb4-8e52-ea5806644b4c commented 6 years ago

Created by: andriytk

Handy option to rebuild packages if some ghc-option was specified/changed via command line. (By default, stack won't rebuild anything in such a case.) It is useful for developers when they make some custom debug builds.

1468ca0b-2a64-4fb4-8e52-ea5806644b4c commented 6 years ago

Created by: andriytk

Sorry, I did find this option useful before with older stack version, but it seems useless with the stack 1.7.1 version I'm using now - all the packages are recompiled automatically as soon as some --ghc-option is changed via cmd line (including optimization options). So I'm abandoning this PR.

1468ca0b-2a64-4fb4-8e52-ea5806644b4c commented 6 years ago

Created by: vvv

https://docs.haskellstack.org/en/stable/yaml_configuration/#rebuild-ghc-options :

in most cases, the flag is used to affect optimization levels and warning behavior, for which GHC itself doesn't actually recompile the modules anyway. Therefore, the new behavior is to not recompile on an options change

@andriytk, could you provide an example of

useful for developers when they make some custom debug builds

?

1468ca0b-2a64-4fb4-8e52-ea5806644b4c commented 6 years ago

Created by: vvv

Are you sure this setting has any effect? See https://github.com/commercialhaskell/stack/issues/2855 .