Closed lost22git closed 1 year ago
What version of Crystal are you using?
Crystal 1.9.2 [1908c816f] (2023-07-19)
LLVM: 15.0.7
Default target: x86_64-unknown-linux-gnu
If this is happening on an existing Athena project, i.e. that has a shard.lock
, try doing a shards update
. Otherwise if it's a brand new project, I am unable to reproduce this :thinking:.
Oh, make sure you have PCRE2
installed. Athena no longer supports PCRE1.
Ref: https://crystal-lang.org/2023/03/02/crystal-is-upgrading-its-regex-engine/
Error target test-athena failed to compile:
/usr/bin/ld: cannot find -lyaml (this usually means you need to install the development package for libyaml): No such file or directory
collect2: error: ld returned 1 exit status
Error: execution of command failed with exit status 1: cc "${@}" -o /root/code/me/test-crystal/test-athena/bin/test-athena -rdynamic -L/roo
t/.local/share/rtx/installs/crystal/1.9.2/bin/../lib/crystal -lyaml -lz `command -v pkg-config > /dev/null && pkg-config --libs --silence-er
rors libssl || printf %s '-lssl -lcrypto'` `command -v pkg-config > /dev/null && pkg-config --libs --silence-errors libcrypto || printf %s '
-lcrypto'` -lpcre2-8 -lm -lgc -lpthread -levent -lrt -lpthread -ldl
It seems libyaml-dev is also required, but the docs don't seem to mention
How did you install Crystal? Normally these should be installed as dependencies automatically via your package manager.
Ref: https://crystal-lang.org/reference/1.9/man/required_libraries.html#other-stdlib-libraries
i install crystal by nix-env
version
error msg;