Fix build with CMake 3.15
Needs ReviewPublic

Authored by adridg on Sat, Aug 10, 7:54 PM.

Details

Reviewers
leinir
Summary
  • The build flags for the C part of the library overwrite the compile flags for C++, in particular, they add -std=c99 to the C++ compilation.
  • The C parts get auto-mocced (!) which generates a C++ file (although it's empty), which then gets compiled with the C flags (and weird -std= setting).
  • For clang, that leads to a build failure.

So switch out some things:

  • Build the C parts as an OBJECT library,
  • Don't apply the C flags to anything but that OBJECT library,
  • and don't automoc C code.
Test Plan

It now builds when CMake 3.15.2 is used.

Diff Detail

Repository
R157 Peruse
Branch
master
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 14961
Build 14979: arc lint + arc unit
adridg requested review of this revision.Sat, Aug 10, 7:54 PM
adridg created this revision.