I have set the following structure in my project's cabal file:
library
if flag(no-tracking)
hs-source-dirs: src, no-telemetry
else
hs-source-dirs: src, telemetry
But I get "can't find source for " errors. I have verified that both hs-source-dirs: src, telemetry and hs-source-dirs: src, no-telemetry work without the conditional structure. It case it matters I am building with stack.