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
Basic information
There is a build error when building Zellij in a bare git repository with worktrees and a custom target directory in zellij.git/.cargo/config.toml. I realize this is very specific, and I could look into this, but I wanted to ask whether this is something that would be accepted, since the use case is so specific. Basically, the directory given to include_bytes!() isn't correct as it doesn't take into account the custom target directory. I don't know whether there are ways to find out the target directory at build time, but that could help.
Error
error: couldn't read /mnt/data/thomas/Documents/development/forks/zellij.git/fix-underline-bug/zellij-utils/../target/wasm32-wasi/debug/compact-bar.wasm: No such file or directory (os error 2)
--> zellij-utils/src/consts.rs:67:17
|
67 | / include_bytes!(concat!(
68 | | env!("CARGO_MANIFEST_DIR"),
69 | | "/../target/wasm32-wasi/debug/",
70 | | $plugin
71 | | ))
| |__________________^
...
81 | add_plugin!(assets, "compact-bar.wasm");
| --------------------------------------- in this macro invocation
|
= note: this error originates in the macro `include_bytes` (in Nightly builds, run with -Z macro-backtrace for more info)
To reproduce
git clone --bare <zelij-url>cd zellij.git
git worktree add main
mkdir .cargo
echo"[build]\ntarget-dir=\"target\""> .cargo/config.toml
cd main
cargo xtask build
uname -av or ver(Windows): Linux thomas-desktop 6.1.3-arch1-1 #1 SMP PREEMPT_DYNAMIC Wed, 04 Jan 2023 16:28:15 +0000 x86_64 GNU/Linux
Further information
Reproduction steps, noticeable behavior, related issues, etc
The text was updated successfully, but these errors were encountered:
@ThomasFrans Unfortunately we cannot support custom target directories due to how we include the plugins into the application code. We have to resolve the path where we take the plugins from during compile time, and cargo doesn't expose the target dir (as far as I'm aware) via env variables. If you really want/need this for your specific application, you can try the following procedure (Although I haven't tested this, but it should work):
Build the plugins in release mode: cargo x build -p -r
Ah, that's ok. I know that this was a very specific request. From the little bit I read online I also noticed cargo might not give any method to get the target dir at compile time. A normal repo works fine :)
Basic information
There is a build error when building Zellij in a bare git repository with worktrees and a custom target directory in
zellij.git/.cargo/config.toml
. I realize this is very specific, and I could look into this, but I wanted to ask whether this is something that would be accepted, since the use case is so specific. Basically, the directory given to include_bytes!() isn't correct as it doesn't take into account the custom target directory. I don't know whether there are ways to find out the target directory at build time, but that could help.Error
To reproduce
uname -av
orver
(Windows):Linux thomas-desktop 6.1.3-arch1-1 #1 SMP PREEMPT_DYNAMIC Wed, 04 Jan 2023 16:28:15 +0000 x86_64 GNU/Linux
Further information
Reproduction steps, noticeable behavior, related issues, etc
The text was updated successfully, but these errors were encountered: