You are not logged in.
I am very new to Haskell, but I though it would be an interesting project to start playing around with hakyll. It turns out to already exist in the Arch "regular" repos (i.e. not arch-haskell or similar), which is nice. I installed that version (as well as stack, also from the repos), and proceeded to follow the instructions given here.
And it went fine, until the `$ stack build`, which promptly failed thusly:
$ stack build
[1 of 2] Compiling Main ( /home/me/.stack/setup-exe-src/setup-mPHDZzAJ.hs, /home/me/.stack/setup-exe-src/setup-mPHDZzAJ.o )
[2 of 2] Compiling StackSetupShim ( /home/me/.stack/setup-exe-src/setup-shim-mPHDZzAJ.hs, /home/me/.stack/setup-exe-src/setup-shim-mPHDZzAJ.o )
Linking /home/me/.stack/setup-exe-cache/x86_64-linux/tmp-Cabal-simple_mPHDZzAJ_1.24.2.0_ghc-8.0.2 ...
/usr/bin/ld: cannot find -lHSCabal-1.24.2.0
/usr/bin/ld: cannot find -lHSprocess-1.4.3.0
/usr/bin/ld: cannot find -lHSpretty-1.1.3.3
/usr/bin/ld: cannot find -lHSdirectory-1.3.0.0
/usr/bin/ld: cannot find -lHSunix-2.7.2.1
/usr/bin/ld: cannot find -lHStime-1.6.0.1
/usr/bin/ld: cannot find -lHSfilepath-1.4.1.1
/usr/bin/ld: cannot find -lHSbinary-0.8.3.0
/usr/bin/ld: cannot find -lHScontainers-0.5.7.1
/usr/bin/ld: cannot find -lHSbytestring-0.10.8.1
/usr/bin/ld: cannot find -lHSdeepseq-1.4.2.0
/usr/bin/ld: cannot find -lHSarray-0.5.1.1
/usr/bin/ld: cannot find -lHSbase-4.9.1.0
/usr/bin/ld: cannot find -lHSinteger-gmp-1.0.0.1
/usr/bin/ld: cannot find -lHSghc-prim-0.5.0.0
/usr/bin/ld: cannot find -lHSrts_thr
collect2: error: ld returned 1 exit status
`gcc' failed in phase `Linker'. (Exit code: 1)
Exit code ExitFailure 1 while running ["ghc","-rtsopts","-threaded","-clear-package-db","-global-package-db","-hide-all-packages","-package","base",
"-main-is","StackSetupShim.mainOverride","-package","Cabal-1.24.2.0","/home/me/.stack/setup-exe-src/setup-mPHDZzAJ.hs",
"/home/me/.stack/setup-exe-src/setup-shim-mPHDZzAJ.hs","-o",
"/home/me/.stack/setup-exe-cache/x86_64-linux/tmp-Cabal-simple_mPHDZzAJ_1.24.2.0_ghc-8.0.2"] in /tmp/stack19147/Searched I have, but the only way I found to solve (or more accurately work around) this issue was to do a `stack setup`, and then the `$ stack build` functioned properly (and so did the rest of the tutorial). The problem, of course, is that I now have `~/.stack` occupying a whopping 3.2Gb, with local versions of the dependencies of hakyll, that supposedly are also installed in the main system...
So, if someone could enlighten me on how to avoid that stack setup phase, it would be nice :-)
Last edited by gauthma (2017-08-09 22:55:19)
Offline
Offline
Thanks for pointing that out; I had actually read that before posting here, but did not make the connection. In any event, that did help, somewhat: `stack build` now takes a while longer to fail, but it does do so again, and again with ld pains:
/tmp/stack1377/aeson-pretty-0.8.5/Data/Aeson/Encode/Pretty.hs:205:20: warning: [-Wdeprecations]
In the use of ‘encodeToTextBuilder’
(imported from Data.Aeson.Encode):
Deprecated: "Use Data.Aeson or Data.Aeson.Text instead"
Preprocessing executable 'aeson-pretty' for aeson-pretty-0.8.5...
[1 of 2] Compiling Paths_aeson_pretty ( .stack-work/dist/x86_64-linux/Cabal-1.24.2.0/build/autogen/Paths_aeson_pretty.hs, .stack-work/dist/x86_64-linux/Cabal-1.24.2.0/build/aeson-pretty/aeson-pretty-tmp/Paths_aeson_pretty.o )
[2 of 2] Compiling Main ( cli-tool/Main.hs, .stack-work/dist/x86_64-linux/Cabal-1.24.2.0/build/aeson-pretty/aeson-pretty-tmp/Main.o )
Linking .stack-work/dist/x86_64-linux/Cabal-1.24.2.0/build/aeson-pretty/aeson-pretty ...
/usr/bin/ld: cannot find -lHScmdargs-0.10.17-gTr0lzwrHbBcQQ47pfTGo
/usr/bin/ld: cannot find -lHSvector-0.12.0.1-692PQMDMB6pIQ1uGwefDcQ
/usr/bin/ld: cannot find -lHSuuid-types-1.0.3-I7xNINqiSgy8XiSgWjW585
/usr/bin/ld: cannot find -lHSrandom-1.1-9tceXaeYIMZ4JrKq20Egog
/usr/bin/ld: cannot find -lHSunordered-containers-0.2.8.0-1tqMF698WJE3INvmpuzQZc
/usr/bin/ld: cannot find -lHStime-locale-compat-0.1.1.3-KZ1jqNx8uhlHjmuPPj6V1Y
/usr/bin/ld: cannot find -lHStagged-0.8.5-DG0qxw3gXxx4NfDcDx4Iai
/usr/bin/ld: cannot find -lHStransformers-compat-0.5.1.4-IuFogs8HAVUJBWVNMhtssu
/usr/bin/ld: cannot find -lHSdlist-0.8.0.3-BHFBNaw8k6n9WiaUNzoXpk
/usr/bin/ld: cannot find -lHSbase-compat-0.9.3-KeJp8zYMpcS9WibvTcxU22
/usr/bin/ld: cannot find -lHSscientific-0.3.5.1-3aJEdQvcyho88FhIoGrzGS
/usr/bin/ld: cannot find -lHSprimitive-0.6.2.0-4578caNkWQ54Gt1mxLF2Yh
/usr/bin/ld: cannot find -lHSinteger-logarithms-1.0.2-IDuUvOgHWcrIzD9yrr4lsA
/usr/bin/ld: cannot find -lHShashable-1.2.6.1-2nPqxcHq7mUGgurrYaLtXr
/usr/bin/ld: cannot find -lHStext-1.2.2.2-3ENqlljngKa6xj1Go2fVWq
collect2: error: ld returned 1 exit status
`gcc' failed in phase `Linker'. (Exit code: 1)Got some more wisdom to offer? :-)
Of course, ~/.stack has so far grown up to ~1Gb, so I am left wondering whether there is any soundness to installing Haskell packages system-wide (almost everywhere I read the suggestion is local install with cabal and/or stack...)
Offline
lHScmdargs is from the haskell-cmdargs package and there seems to be no static variant for that ... (probably similar condition for the rest)
You'll likely have to build that package locally, enabling the static lib build ...
I've actually never compiled any haskell, just laterally noticed the hazzle about the static/dynamic split because of forum complaints that it skyrocketet dependencies for pandoc - sorry.
Offline