Automake: How add a building step?

Posted by gege2061 on Stack Overflow See other posts from Stack Overflow or by gege2061
Published on 2010-04-20T20:11:36Z Indexed on 2010/04/20 20:13 UTC
Read the original article Hit count: 497

Filed under:
|

Hello,

Currently, I have a build chain, completly manage by automake, like:

.vala > .c > .o > .exe

I would like add a new step for preprocess a XML file .ui into a vala source:

.ui > .vala > .c > .o > .exe

I did this, in makefile.am

gtkbuilder2vala_SOURCES = \
    abstract-window.ui \
    main.vala \
    $(NULL)

And:

XSLTPROC = xsltproc
.ui.vala:
    $(XSLTPROC) ...

But make don't understand:

make: *** No rule to make target `abstract-window.c', needed by `gtkbuilder2vala-abstract-window.o'.  Stop.

This seems to be a limitation of make:

http://www.ensta.fr/~diam/dev/online/autoconf/autobook/autobook_180.html

if the translation takes three steps--from .m' to.x', then from .x' to.c', and finally to `.o'---then Automake's simplistic approach will break.

Have you another idea?

© Stack Overflow or respective owner

Related posts about automake

Related posts about autotools