堆栈生成错误:体系结构x86_64的未定义符号

时间:2018-11-10 22:10:20

标签: haskell ghc haskell-stack

我正在尝试运行routes: [ { path: '/article/:id', component: require('../components/articlePage.vue').default, name: 'article', meta: {title: "article"} }, ] 并出现以下错误:

stack build

这是bartosz $ stack setup The GHC located at /Users/evanzamir/.stack/programs/x86_64-osx/ghc-8.4.4/bin/ghc failed to compile a sanity check. Please see: http://docs.haskellstack.org/en/stable/install_and_upgrade/ for more information. Exception was: Received ExitFailure 1 when running Raw command: /Users/evanzamir/.stack/programs/x86_64-osx/ghc-8.4.4/bin/ghc /private/var/folders/rj/vrrtj8094qb8gf4ky_r_mxq80000gn/T/stack-sanity-check4255/Main.hs -no-user-package-db Run from: /private/var/folders/rj/vrrtj8094qb8gf4ky_r_mxq80000gn/T/stack-sanity-check4255/ Standard output: [1 of 1] Compiling Main ( /private/var/folders/rj/vrrtj8094qb8gf4ky_r_mxq80000gn/T/stack-sanity-check4255/Main.hs, /private/var/folders/rj/vrrtj8094qb8gf4ky_r_mxq80000gn/T/stack-sanity-check4255/Main.o ) Linking /private/var/folders/rj/vrrtj8094qb8gf4ky_r_mxq80000gn/T/stack-sanity-check4255/Main ... Standard error: clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument] clang: warning: argument unused during compilation: '-nopie' [-Wunused-command-line-argument] Undefined symbols for architecture x86_64: "_iconv", referenced from: _hs_iconv in libHSbase-4.11.1.0.a(iconv.o) (maybe you meant: _base_GHCziIOziEncodingziIconv_iconvEncoding1_closure, _base_GHCziIOziEncodingziIconv_iconvEncoding1_info , _base_GHCziIOziEncodingziIconv_iconvEncoding4_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding15_info , _base_GHCziIOziEncodingziIconv_iconvEncoding4_info , _base_GHCziIOziEncodingziIconv_iconvEncoding7_info , _base_GHCziIOziEncodingziIconv_iconvEncoding6_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding6_info , _base_GHCziIOziEncodingziIconv_iconvEncoding8_info , _hs_iconv_open , _base_GHCziIOziEncodingziIconv_iconvEncoding12_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding9_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding9_info , _base_GHCziIOziEncodingziIconv_iconvEncoding12_info , _base_GHCziIOziEncodingziIconv_iconvEncoding13_info , _base_GHCziIOziEncodingziIconv_iconvEncoding11_info , _base_GHCziIOziEncodingziIconv_iconvEncoding_info , _base_GHCziIOziEncodingziIconv_iconvEncoding7_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding13_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding2_info , _base_GHCziIOziEncodingziIconv_iconvEncoding11_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding14_bytes , _base_GHCziIOziEncodingziIconv_iconvEncoding15_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding2_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding3_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding8_closure , _base_GHCziIOziEncodingziIconv_iconvEncoding10_bytes , _hs_iconv_close , _hs_iconv , _base_GHCziIOziEncodingziIconv_iconvEncoding5_closure ) "_iconv_open", referenced from: _hs_iconv_open in libHSbase-4.11.1.0.a(iconv.o) (maybe you meant: _hs_iconv_open) "_iconv_close", referenced from: _hs_iconv_close in libHSbase-4.11.1.0.a(iconv.o) (maybe you meant: _hs_iconv_close) "_locale_charset", referenced from: _localeEncoding in libHSbase-4.11.1.0.a(PrelIOUtils.o) ld: symbol(s) not found for architecture x86_64 clang: error: linker command failed with exit code 1 (use -v to see invocation) `gcc' failed in phase `Linker'. (Exit code: 1) 的输出:

stack path

一整天都想弄清楚这一点。我在OS X Mojave 14.1上。我尝试使用脚本Brew直接从二进制文件甚至是Haskell Platform安装程序安装堆栈,所有这些都给我错误。

0 个答案:

没有答案