EricssonResearch / EricssonResearch/openwebrtc
Build fails with implicit declaration of function and unrecognized command line option errors
- Dominant language
- C
- Stars
- 1.8k
- Forks
- 531
- PR merge metrics
- No merged PRs in 30d
Description
I'm trying to build openwebrtc on centos 7.
I have gcc-4.8.5, libnice-10.5.0 and other dependencies in the custom prefix.
Autotools runs successfully, but compilation stage fails with error:
```
CC owr_transport_agent.lo
owr_transport_agent.c: In function 'on_local_candidate_change':
owr_transport_agent.c:2441:5: error: implicit declaration of function 'nice_agent_set_local_credentials' [-Werror=implicit-function-declaration]
nice_agent_set_local_credentials(transport_agent->priv->nice_agent, stream_id, ufrag, password);
^
owr_transport_agent.c: At top level:
cc1: error: unrecognized command line option "-Wno-parentheses-equality" [-Werror]
cc1: all warnings being treated as errors
```
`-Wno-parentheses-equality` is clang option, but with clang it fails with other error:
`argument unused during compilation: '-L/myprefix/lib'`
Disabling -Werror entails linker error: undefined reference to `nice_agent_set_local_credentials`.
Contributor guide
Research direction
Start with owr_transport_agent.c at the nice_agent_set_local_credentials call and inspect the Autotools configuration that adds -Wno-parentheses-equality. Check how the configured libnice headers and library expose that function, then compare GCC and Clang builds on the reported CentOS 7 dependency setup. Done means the compilation and link stages complete without the reported option, declaration, or undefined-reference errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100