cmake and asm?

André Wöbbeking Woebbeking at kde.org
Sat Jan 20 18:40:02 CET 2007


On Saturday 20 January 2007, Alexander Neundorf wrote:
> On Tuesday 16 January 2007 21:03, Boudewijn Rempt wrote:
> > Hi,
> >
> > I've ported a bit of gwenview code to Krita, and it includes an
> > assembly file. The old makefile.am bit looks like this:
> >
> > AM_CCASFLAGS = -I$(srcdir) $(GV_ASM_DEF
> >
> > libgvimageutils_la_SOURCES = \
> >     asm_scale.S \
> >
> > How do I translate this to cmake?
>
> For now it should be possible to do something like the following:
> create a custom command which processes the asm file:
>
> add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/asm_scale.o
>                    COMMAND as ...
> ${CMAKE_CURRENT_SOURCE_DIR}/asm_scale.S -o
> ${CMAKE_CURRENT_BINARY_DIR}/asm_scale.o DEPENDS
> ${CMAKE_CURRENT_SOURCE_DIR}/asm_scale.S )

Two questions:
1) is the absolute path ${CMAKE_CURRENT_SOURCE_DIR}/ really needed
2) is "as" portable?


More information about the Kde-buildsystem mailing list