MantisBT - CMake
View Issue Details
0010577CMakeCMakepublic2010-04-20 03:452010-05-12 16:06
tisi 
Alex Neundorf 
normalminoralways
closedfixed 
CMake-2-8 
 
0010577: Initial ASM-Flags don't work
I've found this bug when i wanted to add an additional assembler, which needs always a flag to specify the target cpu.

When i set an initial flag within the CMAKE_ASM<DIALECT>_FLAGS_INIT Variable, the flag isn't used while assembling.

This is also true for CMAKE_ASM<DIALECT>_FLAGS_DEBUG_INIT, CMAKE_ASM<DIALECT>_FLAGS_RELEASE_INIT etc.
I've uploaded an example, which uses the gnu assembler. It doesn't link correctly on my machine, but that's not the problem (it's just an example). The problem is within the flags, when the gnu assembler is executed.

I've specified following initial flag (see in the Plattform directory):

SET(CMAKE_ASM${ASM_DIALECT}_FLAGS_INIT -mtune=i386)

After generating the Makefiles, I've executed make VERBOSE=1.
The assembler is executed as follows:

/c/Projekte/Tools/MinGW/3.4.5/bin/as.exe -o CMakeFiles/hello.dir/hello.s.obj /C/Projekte/CMakeAsmFlag/hello.s

So there is no -mtune=i386 flag there as expected.

I'm using MSYS Makefile Generator, but i think, this should occur also within other generators.


No tags attached.
zip CMakeAsmFlag.zip (1,311) 2010-04-20 03:45
https://public.kitware.com/Bug/file/3038/CMakeAsmFlag.zip
Issue History
2010-04-20 03:45tisiNew Issue
2010-04-20 03:45tisiFile Added: CMakeAsmFlag.zip
2010-04-20 15:50Alex NeundorfStatusnew => assigned
2010-04-20 15:50Alex NeundorfAssigned To => Alex Neundorf
2010-05-12 16:06Alex NeundorfNote Added: 0020726
2010-05-12 16:06Alex NeundorfStatusassigned => closed
2010-05-12 16:06Alex NeundorfResolutionopen => fixed

Notes
(0020726)
Alex Neundorf   
2010-05-12 16:06   
Thanks for the attached example.
I was able to reproduce it.
This feature was simply not yet implemented.
It is now, and I pushed it to git master.
If it still doesn't work for you, please reopen this bug report.

Alex