[cmake-developers] How to deal with assembler files

Brad King brad.king at kitware.com
Tue Mar 8 08:56:29 EST 2011


On 03/07/2011 03:44 PM, Alexander Neundorf wrote:
> Testing the Intel compiler under Windows...

I just tried this but have no time to work further on it now.  The compiler
does use -S to generate assembly, but there are at least 3 problems:

(1) The command line needs "-Fo" instead of "-o" to specify the output file name.
(2) The assembler extension on Windows is ".asm" so CMake does not recognize the
    "main.s" source file.
(3) The "icl" tool cannot compile its own assembly:

    $ icl -S main.c
    $ icl main.asm
    (errors)

I was able to fix the errors for (3) by replacing "." with "_" in a few labels.
Then the build produces HelloAsm.exe which runs as expected.

-Brad



More information about the cmake-developers mailing list