Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Build on Debian failing #150

Open
ituri opened this issue Nov 11, 2024 · 1 comment
Open

[Bug]: Build on Debian failing #150

ituri opened this issue Nov 11, 2024 · 1 comment

Comments

@ituri
Copy link

ituri commented Nov 11, 2024

I hope it's okay that I'm flooding the repo with issues. ;) See it as an appreciation of catnap; I just like to get it running on all of my systems.

Right now, I have trouble getting catnap to compile on Debian bookworm:

➜  catnap git:(main) nim install
Cleaning existing build
Building in release mode
/usr/lib/nim/lib/pure/times.nim(2135, 39) Hint: 'parse' cannot raise 'Defect' [XCannotRaiseY]
stack trace: (most recent call last)
sugar.nim(234, 11)       capture
/home/phil/catnap/src/catnaplib/platform/fetch.nim(38, 25) template/generic instantiation of `capture` from here
/usr/lib/nim/lib/pure/sugar.nim(234, 11) Error: node lacks field: strVal
stack trace: (most recent call last)
/usr/lib/nim/lib/system/nimscript.nim(429, 18)
/home/phil/catnap/config.nims(120, 16) installTask
/home/phil/catnap/config.nims(60, 12) releaseTask
/home/phil/catnap/config.nims(22, 9) compile
/usr/lib/nim/lib/system/nimscript.nim(273, 7) exec
/usr/lib/nim/lib/system/nimscript.nim(273, 7) Error: unhandled exception: FAILED: nim c  --cincludes:/home/phil/catnap/src/extern/headers --path:/home/phil/catnap/src/extern/libraries --passC:-f --mm:arc --threads:on --panics:on --checks:off --verbosity:0 -d:danger --opt:speed -d:strip --outdir:/home/phil/catnap/bin /home/phil/catnap/src/catnap.nim [OSError]
➜  catnap git:(main)

Is there anything I can do to fix this error?

@ruiiiijiiiiang
Copy link
Contributor

ruiiiijiiiiang commented Nov 13, 2024

Hi @ituri any feedback is greatly appreciated! The error you're seeing appears to be specific to how your drives are mounted. While we look for a more permanent fix, here's a quick hack you can do to make sure the code compiles.
Comment out the if condition here and un-indent line 46 and 47, so it looks like this:

CodeSnap_2024-11-13_at_16:42:01
(notice the indentation on line 46 and 47)
This essentially skips checking for any additional mounted drives besides the root / and you should be able to build and run it after this modification.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants