Skip to content

LOCAL_CFLAGS do not disable warnings in Clang #307

@alexcohn

Description

@alexcohn

Description

Switching to Clang from GCC in r14, we have a problem with compilation of some 3rd party libraries, e.g. gumbo-query. See google/gumbo-parser#377 for details.

The problem specific to NDK is that when we switch to Clang, we cannot silence the warnings by tuning LOCAL_CFLAGS for the specific library the way we used to, with GCC. The reason is that when I turn on the warnings with APP_CFLAGS+=-Wall, this goes after the LOCAL_CFLAGS, and with Clang, -Wall overrides -Wno-unused-variable.

Environment Details

  • NDK Version: 14.0.3675639-beta2
  • Build sytem: ndk-build
  • Host OS: Mac
  • Compiler: Clang
  • ABI: checked with x86, but is probably relevant to the others.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions