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

cross compile chip-tool failure with error ‘nullptr_t’ has not been declared based on v1.1-branch[Build] #32749

Closed
wilbur-se opened this issue Mar 27, 2024 · 1 comment · Fixed by #32751

Comments

@wilbur-se
Copy link
Contributor

Build issue(s)

I try to cross build chip-tool with latest v1.1-branch for imx6ull, but has error "error: ‘nullptr_t’ has not been declared". It is no failure for x86 platform.

I try to do bellow change, and then it pass the build. I am not sure if it is issue.

image

build error log:
[1/396] c++ obj/third_party/connectedhomeip/src/app/libCHIPDataModel.EventManagement.cpp.o FAILED: obj/third_party/connectedhomeip/src/app/libCHIPDataModel.EventManagement.cpp.o armv7l-linux-musleabihf-g++ --sysroot=/opt/matter/armv7l-linux-musleabihf-cross -I=/usr/include -Wno-error=incompatible-pointer-types -MMD -MF obj/third_party/connectedhomeip/src/app/libCHIPDataModel.EventManagement.cpp.o.d -Wconversion -O0 -g2 -fno-common -ffunction-sections -fdata-sections -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -fPIC -Wall -Werror -Wextra -Wshadow -Wunreachable-code -Wvla -Wformat -Wformat-nonliteral -Wformat-security -Wundef -Wno-deprecated-declarations -Wno-missing-field-initializers -Wno-unknown-warning-option -Wno-unused-parameter -Wno-cast-function-type -Wno-psabi -Wno-maybe-uninitialized -fdiagnostics-color -fno-strict-aliasing -fmacro-prefix-map=../third_party/connectedhomeip/= -I/usr/include/gio-unix-2.0 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -Wno-format-nonliteral -Wno-format-nonliteral -std=gnu++17 -fno-rtti -Wnon-virtual-dtor -DCHIP_HAVE_CONFIG_H=1 -DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER=\<lib/address_resolve/AddressResolve_DefaultImpl.h\> -DCHIP_MINMDNS_USE_EPHEMERAL_UNICAST_PORT=1 -DCHIP_MINMDNS_HIGH_VERBOSITY=0 -DCHIP_MINMDNS_DEFAULT_POLICY=1 -I../third_party/connectedhomeip/src/include -I../third_party/connectedhomeip/src -Igen/include -I../third_party/connectedhomeip/examples/chip-tool/include -I../third_party/connectedhomeip/config/standalone -I../third_party/connectedhomeip/zzz_generated/app-common -I../third_party/connectedhomeip/third_party/nlassert/repo/include -I../third_party/connectedhomeip/third_party/nlio/repo/include -I../third_party/connectedhomeip/third_party/inipp/repo/inipp -I../third_party/connectedhomeip/src/tracing/perfetto/include -I../third_party/connectedhomeip/third_party/perfetto/repo/sdk -c ../third_party/connectedhomeip/src/app/EventManagement.cpp -o obj/third_party/connectedhomeip/src/app/libCHIPDataModel.EventManagement.cpp.o In file included from ../third_party/connectedhomeip/src/app/ReadHandler.h:31, from ../third_party/connectedhomeip/src/app/InteractionModelEngine.h:42, from ../third_party/connectedhomeip/src/app/EventManagement.cpp:23: ../third_party/connectedhomeip/src/app/CASESessionManager.h:138:116: error: ‘nullptr_t’ has not been declared 138 | void FindOrEstablishSession(const ScopedNodeId & peerId, Callback::Callback<OnDeviceConnected> * onConnection, nullptr_t | ^~~~~~~~~ cc1plus: note: unrecognized command-line option ‘-Wno-unknown-warning-option’ may have been intended to silence earlier diagnostics [2/396] c++ obj/third_party/connectedhomeip/src/app/libCHIPDataModel.WriteHandler.cpp.o FAILED: obj/third_party/connectedhomeip/src/app/libCHIPDataModel.WriteHandler.cpp.o armv7l-linux-musleabihf-g++ --sysroot=/opt/matter/armv7l-linux-musleabihf-cross -I=/usr/include -Wno-error=incompatible-pointer-types -MMD -MF obj/third_party/connectedhomeip/src/app/libCHIPDataModel.WriteHandler.cpp.o.d -Wconversion -O0 -g2 -fno-common -ffunction-sections -fdata-sections -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -fPIC -Wall -Werror -Wextra -Wshadow -Wunreachable-code -Wvla -Wformat -Wformat-nonliteral -Wformat-security -Wundef -Wno-deprecated-declarations -Wno-missing-field-initializers -Wno-unknown-warning-option -Wno-unused-parameter -Wno-cast-function-type -Wno-psabi -Wno-maybe-uninitialized -fdiagnostics-color -fno-strict-aliasing -fmacro-prefix-map=../third_party/connectedhomeip/= -I/usr/include/gio-unix-2.0 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -Wno-format-nonliteral -Wno-format-nonliteral -std=gnu++17 -fno-rtti -Wnon-virtual-dtor -DCHIP_HAVE_CONFIG_H=1 -DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER=\<lib/address_resolve/AddressResolve_DefaultImpl.h\> -DCHIP_MINMDNS_USE_EPHEMERAL_UNICAST_PORT=1 -DCHIP_MINMDNS_HIGH_VERBOSITY=0 -DCHIP_MINMDNS_DEFAULT_POLICY=1 -I../third_party/connectedhomeip/src/include -I../third_party/connectedhomeip/src -Igen/include -I../third_party/connectedhomeip/examples/chip-tool/include -I../third_party/connectedhomeip/config/standalone -I../third_party/connectedhomeip/zzz_generated/app-common -I../third_party/connectedhomeip/third_party/nlassert/repo/include -I../third_party/connectedhomeip/third_party/nlio/repo/include -I../third_party/connectedhomeip/third_party/inipp/repo/inipp -I../third_party/connectedhomeip/src/tracing/perfetto/include -I../third_party/connectedhomeip/third_party/perfetto/repo/sdk -c ../third_party/connectedhomeip/src/app/WriteHandler.cpp -o obj/third_party/connectedhomeip/src/app/libCHIPDataModel.WriteHandler.cpp.o In file included from ../third_party/connectedhomeip/src/app/ReadHandler.h:31, from ../third_party/connectedhomeip/src/app/InteractionModelEngine.h:42, from ../third_party/connectedhomeip/src/app/WriteHandler.cpp:21: ../third_party/connectedhomeip/src/app/CASESessionManager.h:138:116: error: ‘nullptr_t’ has not been declared 138 | void FindOrEstablishSession(const ScopedNodeId & peerId, Callback::Callback<OnDeviceConnected> * onConnection, nullptr_t | ^~~~~~~~~ cc1plus: note: unrecognized command-line option ‘-Wno-unknown-warning-option’ may have been intended to silence earlier diagnostics [3/396] c++ obj/third_party/connectedhomeip/src/app/libCHIPDataModel.TimerDelegates.cpp.o FAILED: obj/third_party/connectedhomeip/src/app/libCHIPDataModel.TimerDelegates.cpp.o armv7l-linux-musleabihf-g++ --sysroot=/opt/matter/armv7l-linux-musleabihf-cross -I=/usr/include -Wno-error=incompatible-pointer-types -MMD -MF obj/third_party/connectedhomeip/src/app/libCHIPDataModel.TimerDelegates.cpp.o.d -Wconversion -O0 -g2 -fno-common -ffunction-sections -fdata-sections -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -fPIC -Wall -Werror -Wextra -Wshadow -Wunreachable-code -Wvla -Wformat -Wformat-nonliteral -Wformat-security -Wundef -Wno-deprecated-declarations -Wno-missing-field-initializers -Wno-unknown-warning-option -Wno-unused-parameter -Wno-cast-function-type -Wno-psabi -Wno-maybe-uninitialized -fdiagnostics-color -fno-strict-aliasing -fmacro-prefix-map=../third_party/connectedhomeip/= -I/usr/include/gio-unix-2.0 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -Wno-format-nonliteral -Wno-format-nonliteral -std=gnu++17 -fno-rtti -Wnon-virtual-dtor -DCHIP_HAVE_CONFIG_H=1 -DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER=\<lib/address_resolve/AddressResolve_DefaultImpl.h\> -DCHIP_MINMDNS_USE_EPHEMERAL_UNICAST_PORT=1 -DCHIP_MINMDNS_HIGH_VERBOSITY=0 -DCHIP_MINMDNS_DEFAULT_POLICY=1 -I../third_party/connectedhomeip/src/include -I../third_party/connectedhomeip/src -Igen/include -I../third_party/connectedhomeip/examples/chip-tool/include -I../third_party/connectedhomeip/config/standalone -I../third_party/connectedhomeip/zzz_generated/app-common -I../third_party/connectedhomeip/third_party/nlassert/repo/include -I../third_party/connectedhomeip/third_party/nlio/repo/include -I../third_party/connectedhomeip/third_party/inipp/repo/inipp -I../third_party/connectedhomeip/src/tracing/perfetto/include -I../third_party/connectedhomeip/third_party/perfetto/repo/sdk -c ../third_party/connectedhomeip/src/app/TimerDelegates.cpp -o obj/third_party/connectedhomeip/src/app/libCHIPDataModel.TimerDelegates.cpp.o In file included from ../third_party/connectedhomeip/src/app/ReadHandler.h:31, from ../third_party/connectedhomeip/src/app/InteractionModelEngine.h:42, from ../third_party/connectedhomeip/src/app/TimerDelegates.cpp:18: ../third_party/connectedhomeip/src/app/CASESessionManager.h:138:116: error: ‘nullptr_t’ has not been declared 138 | void FindOrEstablishSession(const ScopedNodeId & peerId, Callback::Callback<OnDeviceConnected> * onConnection, nullptr_t | ^~~~~~~~~ cc1plus: note: unrecognized command-line option ‘-Wno-unknown-warning-option’ may have been intended to silence earlier diagnostics [4/396] c++ obj/third_party/connectedhomeip/src/app/libCHIPDataModel.CommandResponseSender.cpp.o FAILED: obj/third_party/connectedhomeip/src/app/libCHIPDataModel.CommandResponseSender.cpp.o armv7l-linux-musleabihf-g++ --sysroot=/opt/matter/armv7l-linux-musleabihf-cross -I=/usr/include -Wno-error=incompatible-pointer-types -MMD -MF obj/third_party/connectedhomeip/src/app/libCHIPDataModel.CommandResponseSender.cpp.o.d -Wconversion -O0 -g2 -fno-common -ffunction-sections -fdata-sections -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -fPIC -Wall -Werror -Wextra -Wshadow -Wunreachable-code -Wvla -Wformat -Wformat-nonliteral -Wformat-security -Wundef -Wno-deprecated-declarations -Wno-missing-field-initializers -Wno-unknown-warning-option -Wno-unused-parameter -Wno-cast-function-type -Wno-psabi -Wno-maybe-uninitialized -fdiagnostics-color -fno-strict-aliasing -fmacro-prefix-map=../third_party/connectedhomeip/= -I/usr/include/gio-unix-2.0 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -Wno-format-nonliteral -Wno-format-nonliteral -std=gnu++17 -fno-rtti -Wnon-virtual-dtor -DCHIP_HAVE_CONFIG_H=1 -DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER=\<lib/address_resolve/AddressResolve_DefaultImpl.h\> -DCHIP_MINMDNS_USE_EPHEMERAL_UNICAST_PORT=1 -DCHIP_MINMDNS_HIGH_VERBOSITY=0 -DCHIP_MINMDNS_DEFAULT_POLICY=1 -I../third_party/connectedhomeip/src/include -I../third_party/connectedhomeip/src -Igen/include -I../third_party/connectedhomeip/examples/chip-tool/include -I../third_party/connectedhomeip/config/standalone -I../third_party/connectedhomeip/zzz_generated/app-common -I../third_party/connectedhomeip/third_party/nlassert/repo/include -I../third_party/connectedhomeip/third_party/nlio/repo/include -I../third_party/connectedhomeip/third_party/inipp/repo/inipp -I../third_party/connectedhomeip/src/tracing/perfetto/include -I../third_party/connectedhomeip/third_party/perfetto/repo/sdk -c ../third_party/connectedhomeip/src/app/CommandResponseSender.cpp -o obj/third_party/connectedhomeip/src/app/libCHIPDataModel.CommandResponseSender.cpp.o In file included from ../third_party/connectedhomeip/src/app/ReadHandler.h:31, from ../third_party/connectedhomeip/src/app/InteractionModelEngine.h:42, from ../third_party/connectedhomeip/src/app/CommandResponseSender.cpp:19: ../third_party/connectedhomeip/src/app/CASESessionManager.h:138:116: error: ‘nullptr_t’ has not been declared 138 | void FindOrEstablishSession(const ScopedNodeId & peerId, Callback::Callback<OnDeviceConnected> * onConnection, nullptr_t | ^~~~~~~~~ cc1plus: note: unrecognized command-line option ‘-Wno-unknown-warning-option’ may have been intended to silence earlier diagnostics [5/396] c++ obj/third_party/connectedhomeip/src/app/libCHIPDataModel.ReadHandler.cpp.o FAILED: obj/third_party/connectedhomeip/src/app/libCHIPDataModel.ReadHandler.cpp.o armv7l-linux-musleabihf-g++ --sysroot=/opt/matter/armv7l-linux-musleabihf-cross -I=/usr/include -Wno-error=incompatible-pointer-types -MMD -MF obj/third_party/connectedhomeip/src/app/libCHIPDataModel.ReadHandler.cpp.o.d -Wconversion -O0 -g2 -fno-common -ffunction-sections -fdata-sections -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -fPIC -Wall -Werror -Wextra -Wshadow -Wunreachable-code -Wvla -Wformat -Wformat-nonliteral -Wformat-security -Wundef -Wno-deprecated-declarations -Wno-missing-field-initializers -Wno-unknown-warning-option -Wno-unused-parameter -Wno-cast-function-type -Wno-psabi -Wno-maybe-uninitialized -fdiagnostics-color -fno-strict-aliasing -fmacro-prefix-map=../third_party/connectedhomeip/= -I/usr/include/gio-unix-2.0 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -Wno-format-nonliteral -Wno-format-nonliteral -std=gnu++17 -fno-rtti -Wnon-virtual-dtor -DCHIP_HAVE_CONFIG_H=1 -DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER=\<lib/address_resolve/AddressResolve_DefaultImpl.h\> -DCHIP_MINMDNS_USE_EPHEMERAL_UNICAST_PORT=1 -DCHIP_MINMDNS_HIGH_VERBOSITY=0 -DCHIP_MINMDNS_DEFAULT_POLICY=1 -I../third_party/connectedhomeip/src/include -I../third_party/connectedhomeip/src -Igen/include -I../third_party/connectedhomeip/examples/chip-tool/include -I../third_party/connectedhomeip/config/standalone -I../third_party/connectedhomeip/zzz_generated/app-common -I../third_party/connectedhomeip/third_party/nlassert/repo/include -I../third_party/connectedhomeip/third_party/nlio/repo/include -I../third_party/connectedhomeip/third_party/inipp/repo/inipp -I../third_party/connectedhomeip/src/tracing/perfetto/include -I../third_party/connectedhomeip/third_party/perfetto/repo/sdk -c ../third_party/connectedhomeip/src/app/ReadHandler.cpp -o obj/third_party/connectedhomeip/src/app/libCHIPDataModel.ReadHandler.cpp.o In file included from ../third_party/connectedhomeip/src/app/ReadHandler.h:31, from ../third_party/connectedhomeip/src/app/InteractionModelEngine.h:42, from ../third_party/connectedhomeip/src/app/ReadHandler.cpp:26: ../third_party/connectedhomeip/src/app/CASESessionManager.h:138:116: error: ‘nullptr_t’ has not been declared 138 | void FindOrEstablishSession(const ScopedNodeId & peerId, Callback::Callback<OnDeviceConnected> * onConnection, nullptr_t | ^~~~~~~~~ cc1plus: note: unrecognized command-line option ‘-Wno-unknown-warning-option’ may have been intended to silence earlier diagnostics [6/396] c++ obj/third_party/connectedhomeip/src/app/libCHIPDataModel.CommandHandler.cpp.o FAILED: obj/third_party/connectedhomeip/src/app/libCHIPDataModel.CommandHandler.cpp.o armv7l-linux-musleabihf-g++ --sysroot=/opt/matter/armv7l-linux-musleabihf-cross -I=/usr/include -Wno-error=incompatible-pointer-types -MMD -MF obj/third_party/connectedhomeip/src/app/libCHIPDataModel.CommandHandler.cpp.o.d -Wconversion -O0 -g2 -fno-common -ffunction-sections -fdata-sections -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -fPIC -Wall -Werror -Wextra -Wshadow -Wunreachable-code -Wvla -Wformat -Wformat-nonliteral -Wformat-security -Wundef -Wno-deprecated-declarations -Wno-missing-field-initializers -Wno-unknown-warning-option -Wno-unused-parameter -Wno-cast-function-type -Wno-psabi -Wno-maybe-uninitialized -fdiagnostics-color -fno-strict-aliasing -fmacro-prefix-map=../third_party/connectedhomeip/= -I/usr/include/gio-unix-2.0 -I/usr/include/libmount -I/usr/include/blkid -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -Wno-format-nonliteral -Wno-format-nonliteral -std=gnu++17 -fno-rtti -Wnon-virtual-dtor -DCHIP_HAVE_CONFIG_H=1 -DCHIP_ADDRESS_RESOLVE_IMPL_INCLUDE_HEADER=\<lib/address_resolve/AddressResolve_DefaultImpl.h\> -DCHIP_MINMDNS_USE_EPHEMERAL_UNICAST_PORT=1 -DCHIP_MINMDNS_HIGH_VERBOSITY=0 -DCHIP_MINMDNS_DEFAULT_POLICY=1 -I../third_party/connectedhomeip/src/include -I../third_party/connectedhomeip/src -Igen/include -I../third_party/connectedhomeip/examples/chip-tool/include -I../third_party/connectedhomeip/config/standalone -I../third_party/connectedhomeip/zzz_generated/app-common -I../third_party/connectedhomeip/third_party/nlassert/repo/include -I../third_party/connectedhomeip/third_party/nlio/repo/include -I../third_party/connectedhomeip/third_party/inipp/repo/inipp -I../third_party/connectedhomeip/src/tracing/perfetto/include -I../third_party/connectedhomeip/third_party/perfetto/repo/sdk -c ../third_party/connectedhomeip/src/app/CommandHandler.cpp -o obj/third_party/connectedhomeip/src/app/libCHIPDataModel.CommandHandler.cpp.o In file included from ../third_party/connectedhomeip/src/app/ReadHandler.h:31, from ../third_party/connectedhomeip/src/app/InteractionModelEngine.h:42, from ../third_party/connectedhomeip/src/app/CommandHandler.cpp:26: ../third_party/connectedhomeip/src/app/CASESessionManager.h:138:116: error: ‘nullptr_t’ has not been declared 138 | void FindOrEstablishSession(const ScopedNodeId & peerId, Callback::Callback<OnDeviceConnected> * onConnection, nullptr_t | ^~~~~~~~~ cc1plus: note: unrecognized command-line option ‘-Wno-unknown-warning-option’ may have been intended to silence earlier diagnostics

Platform

IMX8

Anything else?

No response

@github-actions github-actions bot added the linux label Mar 27, 2024
bzbarsky-apple added a commit to bzbarsky-apple/connectedhomeip that referenced this issue Mar 27, 2024
nullptr_t is in namespace std, not just at global level.  Fixes project-chip#32749
@bzbarsky-apple
Copy link
Contributor

I try to do bellow change, and then it pass the build. I am not sure if it is issue.

That is exactly the issue. Thank you for catching this!

bzbarsky-apple added a commit to bzbarsky-apple/connectedhomeip that referenced this issue Mar 27, 2024
nullptr_t is in namespace std, not just at global level.  Fixes project-chip#32749
@mergify mergify bot closed this as completed in #32751 Mar 27, 2024
mergify bot pushed a commit that referenced this issue Mar 27, 2024
nullptr_t is in namespace std, not just at global level.  Fixes #32749
@github-project-automation github-project-automation bot moved this from Todo to Done in [Build] Build Issues Mar 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants