FS#77730 - ARM64 Cross-compilation error (likely others too)
Attached to Project:
Community Packages
Opened by Carlo Capocasa (capocasa) - Sunday, 05 March 2023, 01:40 GMT
Last edited by Toolybird (Toolybird) - Sunday, 05 March 2023, 21:32 GMT
Opened by Carlo Capocasa (capocasa) - Sunday, 05 March 2023, 01:40 GMT
Last edited by Toolybird (Toolybird) - Sunday, 05 March 2023, 21:32 GMT
|
Details
Description:
Cross-compiler flags do not work properly with this packaged version of Nim. Works fine when installing from choosenim script. Additional info: * package version(s) 1.6.10 * link to upstream bug report, if any https://github.com/nim-lang/Nim/issues/16204#issuecomment-756647592 Steps to reproduce: 1. Install Nim on Arch linux 2. Install ARM cross-compilation toolchain $ pacman -S aarch64-linux-gnu-gcc aarch64-linux-gnu-glibc aarch64-linux-gnu-binutils aarch64-linux-gnu-gdb aarch64-linux-gnu-glibc aarch64-linux-gnu-linux-api-headers 3. Compile a hello world file invoking that toolchain # hello.nim echo "Hello, World" $ nim c --cpu:arm64 --os:linux --arm64.linux.gcc.exe:aarch64-linux-gnu-gcc --arm64.linux.gcc.linkerexe:aarch64-linux-gnu-gcc hello.nim Error: unknown architecture `x86-64' 4. Remove packaged Nim, install choosenim pacman -R nim curl https://nim-lang.org/choosenim/init.sh -sSf | sh 5. Compile again $ nim c --cpu:arm64 --os:linux --arm64.linux.gcc.exe:aarch64-linux-gnu-gcc --arm64.linux.gcc.linkerexe:aarch64-linux-gnu-gcc hello.nim # works |
This task depends upon
Closed by Toolybird (Toolybird)
Sunday, 05 March 2023, 21:32 GMT
Reason for closing: Duplicate
Additional comments about closing: FS#67092
Sunday, 05 March 2023, 21:32 GMT
Reason for closing: Duplicate
Additional comments about closing: