CMake supports assembler out of the box. Just be sure to enable the “ASM” language in your project. If an assembler source file needs preprocessing, also set the source file’s compilation options:
project(assembler C ASM)
set_property(SOURCE foo.s APPEND PROPERTY COMPILE_OPTIONS "-x" "assembler-with-cpp")
add_executable(hello foo.s bar.c)