So I just switched over to Linux Mint 20 today (trying to get away from Ubuntu's apt/snap bait-and-switch fiasco) and got an error when trying to install Nim with the curl command that has worked for me on every other Linux distro... I was hoping someone could tell me if I'm missing something???
After running:
$ curl https://nim-lang.org/choosenim/init.sh -sSf | sh
I get the following error when trying to install 1.2.4:
Exception: Execution failed with exit code 1
... Command: sh build.sh
... Output: # OS: linux
... # CPU: amd64
... gcc -w -O3 -fno-strict-aliasing -fno-ident -Ic_code -c c_code/1_2/stdlib_assertions.nim.c -o c_code/1_2/stdlib_assertions.nim.o
... In file included from /usr/lib/gcc/x86_64-linux-gnu/9/include/syslimits.h:7,
... from /usr/lib/gcc/x86_64-linux-gnu/9/include/limits.h:34,
... from c_code/nimbase.h:262,
... from c_code/1_2/stdlib_assertions.nim.c:7:
... /usr/lib/gcc/x86_64-linux-gnu/9/include/limits.h:194:15: fatal error: limits.h: No such file or directory
... 194 | #include_next <limits.h> /* recurse down to the real one */
... | ^~~~~~~~~~
... compilation terminated.
Cleaning failed build
Tip: 1 messages have been suppressed, use --verbose to show them.
Error: Build failed
Could this be an issue with the newer version of GCC in Ubuntu/Linux Mint? On another computer, I also run LMDE which is using an older GCC, and Nim installed just fine using curl... Thanks in advance!
You should find which library provides "limits.h" in your distro. It's usually something like linux-libc-dev, libc-devel, glibc-headers, gcc...
If Mint is still based on Ubuntu, this command could help:
dpkg --search "limits.h"