[PATCH] D22415: Enable cross-compilation across architectures on android

Francis Ricci via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 18 09:40:27 PDT 2016


fjricci added a comment.

It looks to me like `CMAKE_CXX_FLAGS` is applied explicitly in `add_compiler_rt_object_libraries`, which makes me think that we do need to add them explicitly:

  foreach(libname ${libnames})
    add_library(${libname} OBJECT ${LIB_SOURCES})
    set_target_compile_flags(${libname}
        ${CMAKE_CXX_FLAGS} ${extra_cflags_${libname}} ${LIB_CFLAGS})

This is not true for `add_compiler_rt_runtime`. If I set CMAKE_CXX_FLAGS and CMAKE_C_FLAGS without this patch, the flags passed do not end up in the compile commands when building the builtins.


https://reviews.llvm.org/D22415





More information about the llvm-commits mailing list