We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
GCC 14 introduces a couple of changes, among them - certain warnings are now errors. One of those changes I've stumbled upon now is -Wincompatible-pointer-types (https://gcc.gnu.org/gcc-14/porting_to.html#incompatible-pointer-types).
-Wincompatible-pointer-types
Compiling chronos is impossible now because of this error. I've added the resulting error message of running V=1 nimble test on chronos git source.
V=1 nimble test
Workaround: --passC:-Wno-error=incompatible-pointer-types
--passC:-Wno-error=incompatible-pointer-types
build/nimcache/testall/@m..@schronos@sstreams@stlsstream.nim.c: In function ‘sslEngineSetX509__OOZOOZOOZOnimbleZpkgs50Zbearssl4548O50O5045d505156535452ab49e5057485655515753535449515456534853555351e52c5053ccdeZbearsslZabiZbearssl95ssl_u390’: build/nimcache/testall/@m..@schronos@sstreams@stlsstream.nim.c:1872:42: error: assignment to ‘const br_x509_class **’ {aka ‘const struct br_x509_class_ **’} from incompatible pointer type ‘br_x509_class **’ {aka ‘struct br_x509_class_ **’} [-Wincompatible-pointer-types] 1872 | nimln_(616); (*cc_p0).x509ctx = x509ctx_p1; | ^ build/nimcache/testall/@m..@schronos@sstreams@stlsstream.nim.c: In function ‘newTLSClientAsyncStream__testasyncstream_u17122’: build/nimcache/testall/@m..@schronos@sstreams@stlsstream.nim.c:4993:227: error: passing argument 2 of ‘sslEngineSetX509__OOZOOZOOZOnimbleZpkgs50Zbearssl4548O50O5045d505156535452ab49e5057485655515753535449515456534853555351e52c5053ccdeZbearsslZabiZbearssl95ssl_u390’ from incompatible pointer type [-Wincompatible-pointer-types] 4993 | nimln_(514); sslEngineSetX509__OOZOOZOOZOnimbleZpkgs50Zbearssl4548O50O5045d505156535452ab49e5057485655515753535449515456534853555351e52c5053ccdeZbearsslZabiZbearssl95ssl_u390((&(*res).ccontext.eng), &(*res).xwc.vtable); | ^~~~~~~~~~~~~~~~~~ | | | const br_x509_class ** {aka const struct br_x509_class_ **} build/nimcache/testall/@m..@schronos@sstreams@stlsstream.nim.c:1870:232: note: expected ‘br_x509_class **’ {aka ‘struct br_x509_class_ **’} but argument is of type ‘const br_x509_class **’ {aka ‘const struct br_x509_class_ **’} 1870 | static N_INLINE(void, sslEngineSetX509__OOZOOZOOZOnimbleZpkgs50Zbearssl4548O50O5045d505156535452ab49e5057485655515753535449515456534853555351e52c5053ccdeZbearsslZabiZbearssl95ssl_u390)(br_ssl_engine_context* cc_p0, br_x509_class** x509ctx_p1) { | ~~~~~~~~~~~~~~~~^~~~~~~~~~ build/nimcache/testall/@m..@schronos@sstreams@stlsstream.nim.c: In function ‘sslServerSetCache__OOZOOZOOZOnimbleZpkgs50Zbearssl4548O50O5045d505156535452ab49e5057485655515753535449515456534853555351e52c5053ccdeZbearsslZabiZbearssl95ssl_u1292’: build/nimcache/testall/@m..@schronos@sstreams@stlsstream.nim.c:5704:47: error: assignment to ‘const br_ssl_session_cache_class **’ {aka ‘const struct br_ssl_session_cache_class_ **’} from incompatible pointer type ‘br_ssl_session_cache_class **’ {aka ‘struct br_ssl_session_cache_class_ **’} [-Wincompatible-pointer-types] 5704 | nimln_(1226); (*cc_p0).cache_vtable = vtable_p1; | ^ compilation terminated due to -fmax-errors=3. Error: execution of an external compiler program 'gcc -c -w -fmax-errors=3 -pthread -I/home/konrad/.nimble/pkgs2/bearssl-0.2.2-d238564ab1e29087395561368505753e4c25ccde/bearssl/abi -I/home/konrad/.nimble/pkgs2/bearssl-0.2.2-d238564ab1e29087395561368505753e4c25ccde/bearssl/abi/../csources/src/ -I/home/konrad/.nimble/pkgs2/bearssl-0.2.2-d238564ab1e29087395561368505753e4c25ccde/bearssl/abi/../csources/inc/ -I/home/konrad/.nimble/pkgs2/bearssl-0.2.2-d238564ab1e29087395561368505753e4c25ccde/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/konrad/.choosenim/toolchains/nim-#devel/lib' -I'/home/konrad/Kody-źródłowe/nim-chronos/tests' -o build/nimcache/testall/@m..@schronos@sstreams@stlsstream.nim.c.o build/nimcache/testall/@m..@schronos@sstreams@stlsstream.nim.c' failed with exit code: 1
Nim Compiler Version 2.1.1 [Linux: amd64] Compiled at 2024-03-22 Copyright (c) 2006-2024 by Andreas Rumpf
git hash: 33902d9dbb65fbfdfbd6e3b2a34c6e19eccb762f active boot switches: -d:release
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Description
GCC 14 introduces a couple of changes, among them - certain warnings are now errors. One of those changes I've stumbled upon now is
-Wincompatible-pointer-types
(https://gcc.gnu.org/gcc-14/porting_to.html#incompatible-pointer-types).Compiling chronos is impossible now because of this error. I've added the resulting error message of running
V=1 nimble test
on chronos git source.Workaround:
--passC:-Wno-error=incompatible-pointer-types
Error message
Nim version
Nim Compiler Version 2.1.1 [Linux: amd64]
Compiled at 2024-03-22
Copyright (c) 2006-2024 by Andreas Rumpf
git hash: 33902d9dbb65fbfdfbd6e3b2a34c6e19eccb762f
active boot switches: -d:release
The text was updated successfully, but these errors were encountered: