You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So LLVM / clang is a dependency of the Juvix compiler for these targets. The user may not have LLVM installed or have a version that we do not support.
The proposal in this issue is to use an environment variable (e.g JUVIX_CLANG_PATH) to set the location of the clang binary that's used by Juvix. If this environment variable is not set then we'd fallback to the current behaviour of using PATH.
The reason for this is to facilitate easy installation of the Juvix and its dependencies as part of #1937 (Add one-liner installation command).
The installer command would give the user the option to install a version of LLVM / clang that's compatible with Juvix into $XDG_DATA_HOME/clang (specifically https://github.com/rsms/llvmbox for the target machine) and then set JUVIX_CLANG_PATH to this installation as part of the Juvix shell setup.
The text was updated successfully, but these errors were encountered:
…clang executable (#2152)
If set, `JUVIX_LLVM_DIST_PATH` should point to the root of a LLVM
installation, i.e clang should be present
in`$JUVIX_LLVM_DIST_PATH`/bin/clang.
If `JUVIX_LLVM_DIST_PATH` is not set, or `clang` is not available there
then the system PATH is used instead, (this is the current behaviour).
The `juvix doctor` clang checks use the same logic as `juvix compile` to
find and check the `clang` executable.
To help with debugging the clang location, this PR also adds `juvix
doctor --verbose` which prints the location of the `clang` executable
and whether it was found using the system PATH or the
JUVIX_LLVM_DIST_PATH environment variable:
```
juvix doctor --verbose
> Checking for clang...
| Found clang at "/Users/paul/.local/share/juvix/llvmbox/bin/clang" using JUVIX_LLVM_DIST_PATH environment variable
```
or
```
juvix doctor --verbose
> Checking for clang...
| Found clang at "/Users/paul/.local/bin/clang" using system PATH
```
* Closes#2133
For the native and WASM compile targets we run the
clang
executable from the PATH:juvix/app/Commands/Extra/Compile.hs
Line 216 in 121063c
So LLVM / clang is a dependency of the Juvix compiler for these targets. The user may not have LLVM installed or have a version that we do not support.
The proposal in this issue is to use an environment variable (e.g
JUVIX_CLANG_PATH
) to set the location of theclang
binary that's used by Juvix. If this environment variable is not set then we'd fallback to the current behaviour of using PATH.The reason for this is to facilitate easy installation of the Juvix and its dependencies as part of #1937 (Add one-liner installation command).
The installer command would give the user the option to install a version of LLVM / clang that's compatible with Juvix into
$XDG_DATA_HOME/clang
(specifically https://github.com/rsms/llvmbox for the target machine) and then setJUVIX_CLANG_PATH
to this installation as part of the Juvix shell setup.The text was updated successfully, but these errors were encountered: