project-chip / connectedhomeip

Matter (formerly Project CHIP) creates more connections between more objects, simplifying development for manufacturers and increasing compatibility for consumers, guided by the Connectivity Standards Alliance.
https://buildwithmatter.com
Apache License 2.0
7.38k stars 1.98k forks source link

[Build][Silabs] ../../../examples/lit-icd-app/silabs/src/AppTask.cpp:107:33: error: 'class chip::Server' has no member named 'GetICDManager' #35804

Open lboue opened 2 days ago

lboue commented 2 days ago

Build issue(s)

Hi,

I am facing an issue building Matter EFR32 Lit ICD Example example.

  1. cd ~/connectedhomeip
  2. ./scripts/examples/gn_silabs_example.sh ./examples/lit-icd-app/silabs/ ./out/lit-icd-app BRD4187C
-I../../../examples/lit-icd-app/silabs/third_party/connectedhomeip/examples/common/QRCode/repo/c -I../../../examples/lit-icd-app/silabs/third_party/connectedhomeip/examples/providers -c ../../../examples/lit-icd-app/silabs/src/AppTask.cpp -o obj/src/matter-silabs-lit-icd-example.out.AppTask.cpp.o
../../../examples/lit-icd-app/silabs/src/AppTask.cpp: In static member function 'static void AppTask::AppTaskMain(void*)':
../../../examples/lit-icd-app/silabs/src/AppTask.cpp:107:33: error: 'class chip::Server' has no member named 'GetICDManager'
  107 |     chip::Server::GetInstance().GetICDManager().RegisterObserver(&sAppTask);
      |                                 ^~~~~~~~~~~~~
At global scope:
cc1plus: note: unrecognized command-line option '-Wno-unknown-warning-option' may have been intended to silence earlier diagnostics
ninja: build stopped: subcommand failed.

Platform

efr32

Anything else?

Commit id: 5dc91f3273a55fe991624b68ada8fb50b64c913a

lit-icd-app_build.log

bzbarsky-apple commented 2 days ago

That sounds like CHIP_CONFIG_ENABLE_ICD_SERVER is not set true in your case. Why is it not set true? Are you missing a chip_enable_icd_server = true in the relevant args.gni file?

lboue commented 2 days ago

That sounds like CHIP_CONFIG_ENABLE_ICD_SERVER is not set true in your case. Why is it not set true? Are you missing a chip_enable_icd_server = true in the relevant args.gni file?

It should be enabled here:

https://github.com/project-chip/connectedhomeip/blob/7eb96cd1e862707c335f09cff826e52ec2134baf/examples/lit-icd-app/silabs/build_for_wifi_args.gni#L29

Or here:

https://github.com/project-chip/connectedhomeip/blob/7eb96cd1e862707c335f09cff826e52ec2134baf/examples/lit-icd-app/silabs/openthread.gni#L32

bzbarsky-apple commented 2 days ago

Well, are those ending up being loaded by something reachable from src/app/icd/server/BUILD.gn?