Skip to content

[BUG] Master does not compile on Linux #957

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

Closed
schoedon opened this issue Oct 16, 2024 · 4 comments
Closed

[BUG] Master does not compile on Linux #957

schoedon opened this issue Oct 16, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@schoedon
Copy link

Describe the bug
Cannot build codex from source.

To Reproduce
Steps to reproduce the behavior:

  1. Go to build#linux
  2. Clone repository
  3. Run make udate
  4. Run make
  5. See error: passing argument 1 of ‘br_prng_seeder_system’ from incompatible pointer type [-Wincompatible-pointer-types]

Expected behavior
This section should be removed from the BUG template.

Screenshots

[...]
/home/user/.src/codex-storage/nim-codex/vendor/nim-presto/presto/server.nim(41, 28) Warning: Callback could raise only CancelledError, annotate with {.async: (raises: [CancelledError]).}; new is deprecated [Deprecated]
/home/user/.src/codex-storage/nim-codex/codex.nim(31, 13) Warning: imported and not used: 'sequtils' [UnusedImport]
/home/user/.src/codex-storage/nim-codex/vendor/nim-bearssl/bearssl/rand.nim: In function ‘_ZN4rand3newE8typeDescIN12bearssl_rand15HmacDrbgContextEE’:
/home/user/.src/codex-storage/nim-codex/vendor/nim-bearssl/bearssl/rand.nim:35:34: error: passing argument 1 of ‘br_prng_seeder_system’ from incompatible pointer type [-Wincompatible-pointer-types]
   35 |   let seeder = prngSeederSystem(nil)
      |                                 ~^~~                 
      |                                  |
      |                                  char **
In file included from /home/user/.src/codex-storage/nim-codex/nimcache/release/codex/@mvendor@snim-bearssl@[email protected]:8:
/home/user/.src/codex-storage/nim-codex/vendor/nim-bearssl/bearssl/abi/../csources/inc/bearssl_rand.h:318:51: note: expected ‘const char **’ but argument is of type ‘char **’
  318 | br_prng_seeder br_prng_seeder_system(const char **name);
      |                                      ~~~~~~~~~~~~~^~~~
Error: execution of an external compiler program 'gcc -c  -w -fmax-errors=3 -pthread -I/home/user/.src/codex-storage/nim-codex/vendor/nim-libbacktrace -I/home/user/.src/codex-storage/nim-codex/vendor/nim-libbacktrace/install/usr/include -I/home/user/.src/codex-storage/nim-codex/vendor/nim-bearssl/bearssl/abi/../csources/src/ -I/home/user/.src/codex-storage/nim-codex/vendor/nim-bearssl/bearssl/abi/../csources/inc/ -I/home/user/.src/codex-storage/nim-codex/vendor/nim-bearssl/bearssl/abi/../csources/tools/ -DBR_USE_UNIX_TIME=1 -DBR_USE_URANDOM=1 -DBR_LE_UNALIGNED=1 -DBR_64=1  -DBR_amd64=1 -DBR_INT128=1 -I/home/user/.src/codex-storage/nim-codex/vendor/nim-zlib/zlib/csources -DHAVE_UNISTD_H -DSQLITE_ENABLE_COLUMN_METADATA -DLEVELDB_PLATFORM_POSIX -I/home/user/.src/codex-storage/nim-codex/vendor/nim-leveldbstatic/vendor -I/home/user/.src/codex-storage/nim-codex/vendor/nim-leveldbstatic/vendor/helpers -I/home/user/.src/codex-storage/nim-codex/vendor/nim-leveldbstatic/vendor/helpers/memenv -I/home/user/.src/codex-storage/nim-codex/vendor/nim-leveldbstatic/vendor/port -I/home/user/.src/codex-storage/nim-codex/vendor/nim-leveldbstatic/vendor/include -I/home/user/.src/codex-storage/nim-codex/vendor/nim-leopard/vendor/leopard -fopenmp -march=native -g3 -Og -O3 -fno-strict-aliasing -fno-ident   -I/home/user/.src/codex-storage/nim-codex/vendor/nimbus-build-system/vendor/Nim/lib -I/home/user/.src/codex-storage/nim-codex -o /home/user/.src/codex-storage/nim-codex/nimcache/release/codex/@mvendor@snim-bearssl@[email protected] /home/user/.src/codex-storage/nim-codex/nimcache/release/codex/@mvendor@snim-bearssl@[email protected]' failed with exit code: 1


stack trace: (most recent call last)
nimscript.nim(429, 18)
build.nims(30, 15)       codexTask
build.nims(23, 7)        buildBinary
nimscript.nim(273, 7)    exec
/home/user/.src/codex-storage/nim-codex/vendor/nimbus-build-system/vendor/Nim/lib/system/nimscript.nim(273, 7) Error: unhandled exception: FAILED: nim c --out:build/codex -d:chronicles_runtime_filtering -d:chronicles_log_level=TRACE --verbosity:0 --hints:off -d:release ./codex.nim [OSError]
make: *** [Makefile:74: all] Error 1

/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim: In function ‘_ZN18addcarry_subborrow4subBE3varI2CtI5uInt8EE3varI2CtI6uInt64EE2CtI6uInt64E2CtI6uInt64E2CtI5uInt8E’:
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim:153:38: error: passing argument 4 of ‘_subborrow_u64’ from incompatible pointer type [-Wincompatible-pointer-types]
  153 |     bOut = subborrow_u64(bIn, a, b, diff)
      |                                      ^~~~
      |                                      |
      |                                      NU64 * {aka long unsigned int *}
In file included from /usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/x86gprintrin.h:39,
                 from /usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/x86intrin.h:27,
                 from /home/user/.src/codex-storage/nim-codex/nimcache/release/codex/@mvendor@sconstantine@sconstantine@smath@sarithmetic@slimbs_montgomery.nim.c:9:
/usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/adxintrin.h:59:61: note: expected ‘long long unsigned int *’ but argument is of type ‘NU64 *’ {aka ‘long unsigned int *’}
   59 |                 unsigned long long __Y, unsigned long long *__P)
      |                                         ~~~~~~~~~~~~~~~~~~~~^~~
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim: In function ‘_ZN18addcarry_subborrow4addCE3varI2CtI5uInt8EE3varI2CtI6uInt64EE2CtI6uInt64E2CtI6uInt64E2CtI5uInt8E’:
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim:131:37: error: passing argument 4 of ‘_addcarry_u64’ from incompatible pointer type [-Wincompatible-pointer-types]
  131 |     cOut = addcarry_u64(cIn, a, b, sum)
      |                                     ^~~
      |                                     |
      |                                     NU64 * {aka long unsigned int *}
/usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/adxintrin.h:67:60: note: expected ‘long long unsigned int *’ but argument is of type ‘NU64 *’ {aka ‘long unsigned int *’}
   67 |                unsigned long long __Y, unsigned long long *__P)
      |                                        ~~~~~~~~~~~~~~~~~~~~^~~
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim: In function ‘_ZN18addcarry_subborrow4subBE3varI2CtI5uInt8EE3varI2CtI6uInt64EE2CtI6uInt64E2CtI6uInt64E2CtI5uInt8E’:
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim:153:38: error: passing argument 4 of ‘_subborrow_u64’ from incompatible pointer type [-Wincompatible-pointer-types]
  153 |     bOut = subborrow_u64(bIn, a, b, diff)
      |                                      ^~~~
      |                                      |
      |                                      NU64 * {aka long unsigned int *}
In file included from /usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/x86gprintrin.h:39,
                 from /usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/x86intrin.h:27,
                 from /home/user/.src/codex-storage/nim-codex/nimcache/release/codex/@mvendor@snim-poseidon2@[email protected]:9:
/usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/adxintrin.h:59:61: note: expected ‘long long unsigned int *’ but argument is of type ‘NU64 *’ {aka ‘long unsigned int *’}
   59 |                 unsigned long long __Y, unsigned long long *__P)
      |                                         ~~~~~~~~~~~~~~~~~~~~^~~
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim: In function ‘_ZN18addcarry_subborrow4addCE3varI2CtI5uInt8EE3varI2CtI6uInt64EE2CtI6uInt64E2CtI6uInt64E2CtI5uInt8E’:
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim:131:37: error: passing argument 4 of ‘_addcarry_u64’ from incompatible pointer type [-Wincompatible-pointer-types]
  131 |     cOut = addcarry_u64(cIn, a, b, sum)
      |                                     ^~~
      |                                     |
      |                                     NU64 * {aka long unsigned int *}
In file included from /usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/x86gprintrin.h:39,
                 from /usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/x86intrin.h:27,
                 from /home/user/.src/codex-storage/nim-codex/nimcache/release/codex/@mvendor@snim-poseidon2@[email protected]:9:
/usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/adxintrin.h:67:60: note: expected ‘long long unsigned int *’ but argument is of type ‘NU64 *’ {aka ‘long unsigned int *’}
   67 |                unsigned long long __Y, unsigned long long *__P)
      |                                        ~~~~~~~~~~~~~~~~~~~~^~~
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim: In function ‘_ZN18addcarry_subborrow4subBE3varI2CtI5uInt8EE3varI2CtI6uInt64EE2CtI6uInt64E2CtI6uInt64E2CtI5uInt8E’:
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim:153:38: error: passing argument 4 of ‘_subborrow_u64’ from incompatible pointer type [-Wincompatible-pointer-types]
  153 |     bOut = subborrow_u64(bIn, a, b, diff)
      |                                      ^~~~
      |                                      |
      |                                      NU64 * {aka long unsigned int *}
/usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/adxintrin.h:59:61: note: expected ‘long long unsigned int *’ but argument is of type ‘NU64 *’ {aka ‘long unsigned int *’}
   59 |                 unsigned long long __Y, unsigned long long *__P)
      |                                         ~~~~~~~~~~~~~~~~~~~~^~~
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim: In function ‘_ZN18addcarry_subborrow4addCE3varI2CtI5uInt8EE3varI2CtI6uInt64EE2CtI6uInt64E2CtI6uInt64E2CtI5uInt8E’:
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim:131:37: error: passing argument 4 of ‘_addcarry_u64’ from incompatible pointer type [-Wincompatible-pointer-types]
  131 |     cOut = addcarry_u64(cIn, a, b, sum)
      |                                     ^~~
      |                                     |
      |                                     NU64 * {aka long unsigned int *}
In file included from /usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/x86gprintrin.h:39,
                 from /usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/x86intrin.h:27,
                 from /home/user/.src/codex-storage/nim-codex/nimcache/release/codex/@mvendor@snim-poseidon2@[email protected]:9:
/usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/adxintrin.h:67:60: note: expected ‘long long unsigned int *’ but argument is of type ‘NU64 *’ {aka ‘long unsigned int *’}
   67 |                unsigned long long __Y, unsigned long long *__P)
      |                                        ~~~~~~~~~~~~~~~~~~~~^~~
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim: In function ‘_ZN18addcarry_subborrow4subBE3varI2CtI5uInt8EE3varI2CtI6uInt64EE2CtI6uInt64E2CtI6uInt64E2CtI5uInt8E’:
/home/user/.src/codex-storage/nim-codex/vendor/constantine/constantine/platforms/intrinsics/addcarry_subborrow.nim:153:38: error: passing argument 4 of ‘_subborrow_u64’ from incompatible pointer type [-Wincompatible-pointer-types]
  153 |     bOut = subborrow_u64(bIn, a, b, diff)
      |                                      ^~~~
      |                                      |
      |                                      NU64 * {aka long unsigned int *}
/usr/lib/gcc/x86_64-pc-linux-gnu/14.2.1/include/adxintrin.h:59:61: note: expected ‘long long unsigned int *’ but argument is of type ‘NU64 *’ {aka ‘long unsigned int *’}
   59 |                 unsigned long long __Y, unsigned long long *__P)
      |                                         ~~~~~~~~~~~~~~~~~~~~^~~

Environment:

  • OS: ArchLinux
  • Version: Linux intan 6.11.3-arch1-1 #1 SMP PREEMPT_DYNAMIC Thu, 10 Oct 2024 20:11:06 +0000 x86_64 GNU/Linux
  • Tag/Commit: 436baef
  • Arch: x86_64

Additional context
Add any other context about the problem here.

@schoedon schoedon added the bug Something isn't working label Oct 16, 2024
@veaceslavdoina
Copy link
Contributor

veaceslavdoina commented Oct 17, 2024

Can you please check your gcc version (#875)

gcc --version

@schoedon
Copy link
Author

Yes

gcc (GCC) 14.2.1 20240910

@veaceslavdoina
Copy link
Contributor

It is a known issue and we have a note about it in the docs as well - Known issues.

So, work is still in progress.

@schoedon
Copy link
Author

Got it. Duplicate of #875

@schoedon schoedon closed this as not planned Won't fix, can't repro, duplicate, stale Oct 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants