azzimzied / android-cmake

Automatically exported from code.google.com/p/android-cmake
0 stars 0 forks source link

Compiler flags not passed to assembler #20

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Make a project with both C sources and assembler sources, where some 
assembler code is conditionally compiled out (e.g. NEON code if not compiling 
for ARM-v7+), and the C code calls this code
2. Try to compile this project with ANDROID_ABI set to ARMEABI_V7A or greater

What is the expected output? What do you see instead?

Expected: no errors
Actual: The assembler object file has NEON code compiled out even though the 
ANDROID_ABI was set correctly

What version of the product are you using? On what operating system?

Latest version grabbed from Github: https://github.com/taka-no-me/android-cmake

Please provide any additional information below.

Attached a patch that fixed the problem for me. It simply adds 
ANDROID_CXX_FLAGS to CMAKE_ASM_FLAGS. Not sure if this will work for all 
toolchains. It should since CMAKE_ASM_COMPILER is only ever set to gcc.

Original issue reported on code.google.com by daiweili on 12 Feb 2014 at 2:38

Attachments: