stack build --resolver nightly --haddock --test --bench --no-run-benchmarks Selected resolver: nightly-2018-11-21 Downloaded nightly-2018-11-21 build plan. Preparing to install GHC to an isolated location. This will not interfere with any system-level installation. Already downloaded. Installed GHC. [1 of 2] Compiling Main ( /Users/etorreborre/.stack/setup-exe-src/setup-mPHDZzAJ.hs, /Users/etorreborre/.stack/setup-exe-src/setup-mPHDZzAJ.o ) [2 of 2] Compiling StackSetupShim ( /Users/etorreborre/.stack/setup-exe-src/setup-shim-mPHDZzAJ.hs, /Users/etorreborre/.stack/setup-exe-src/setup-shim-mPHDZzAJ.o ) Linking /Users/etorreborre/.stack/setup-exe-cache/x86_64-osx/tmp-Cabal-simple_mPHDZzAJ_184.108.40.206_ghc-8.6.2 ... ld: library not found for -lgmp clang: error: linker command failed with exit code 1 (use -v to see invocation) `gcc' failed in phase `Linker'. (Exit code: 1)
Hi Stackagers, I see a few bugs in latest
json-autotype that appear in Stack builds only:
Heisenbug when executing
stack runghc on CI:
Test suite failure for package json-autotype-3.0.0 json-autotype-examples: exited with: ExitFailure 1 Full log available at /builds/migamake/json-autotype/.stack-work/logs/json-autotype-3.0.0-test.log stack: WARNING! Expecting stack options comment at line 1, column 1 stack: WARNING! Missing or unusable stack options specification stack: WARNING! Using runghc without any additional stack options Invalid argument `run' Error executing interpreter command: stack run -- runghc -- examples/json-schema/fstab.json --outputFilename output/Fstab.hs
Here is the code that implements nested call to Stack:
runHaskellModule :: [String] -> IO ExitCode runHaskellModule arguments = do maybeStack <- System.Environment.lookupEnv "STACK_EXEC" maybeCabal <- System.Environment.lookupEnv "CABAL_SANDBOX_CONFIG" let execPrefix | Just stackExec <- maybeStack = [stackExec, "runghc"] | Just _ <- maybeCabal = ["cabal", "exec", "runghc"] | otherwise = ["runghc"] putStrLn $ "Running Haskell module: " ++ show execPrefix ++ show arguments system $ Prelude.unwords $ execPrefix ++ arguments
Can you please lend me a hand?
@mihaimaruseac Thanks in advance. It may be a bug in the way I detect
stack environment or bug in the way
stack runs nested. Either way, I would need your guidance as to how to improve it, since detection of nested
stack environment is a bit of a riddle to me.
Can you tell anything about whether
/tmp is available on Stackage CI?
to clarify, the stackage build server builds with cabal-install,
To further clarify, the stackage build server builds with
runghc Setup configure,
runghc Setup build, etc. 100% of the time, Setup.hs is cabal's defaultMain or some other use of Cabal, but in theory, it could be anything.
stack build cabal-installshould work correctly for people that are sticking to stackage defaults.
resolvand other missing deps back into the build plans anyways. Assuming it is compatible and all. Not sure how difficult it would be to detect which conditional dependencies we could harmlessly include automatically, but we can for sure include them on a case-by-case basis as needs arise, such as this.
Hi, I can't install the package unix with with the following command:
stack build --copy-compiler-tool unix.
When I tried this, nothing happened.
I have Mac Sierra and I would expect the unix-220.127.116.11 version to be installed. My GHC version is 8.6.4.
Thanks in advance.