+
+# sparc backend
+
+sparc_sources = \
+ be/sparc/sparc_emitter.c \
+ be/sparc/sparc_map_regs.c \
+ be/sparc/sparc_new_nodes.c \
+ be/sparc/sparc_transform.c \
+ be/sparc/bearch_sparc.c
+sparc_built_sources = \
+ be/sparc/gen_sparc_emitter.c \
+ be/sparc/gen_sparc_emitter.h \
+ be/sparc/gen_sparc_machine.c \
+ be/sparc/gen_sparc_machine.h \
+ be/sparc/gen_sparc_new_nodes.c.inl \
+ be/sparc/gen_sparc_new_nodes.h \
+ be/sparc/gen_sparc_regalloc_if.c \
+ be/sparc/gen_sparc_regalloc_if.h
+MAINTAINERCLEANFILES += $(sparc_built_sources)
+BUILT_SOURCES += $(sparc_built_sources)
+libfirm_la_SOURCES += $(sparc_sources) $(sparc_built_sources)
+
+EXTRA_DIST += \
+ be/sparc/sparc_emitter.h \
+ be/sparc/sparc_map_regs.h \
+ be/sparc/sparc_new_nodes.h \
+ be/sparc/sparc_nodes_attr.h \
+ be/sparc/sparc_spec.pl \
+ be/sparc/sparc_transform.h \
+ be/sparc/bearch_sparc.h \
+ be/sparc/bearch_sparc_t.h
+
+$(srcdir)/be/sparc/gen_sparc_new_nodes.c.inl $(srcdir)/be/sparc/gen_sparc_new_nodes.h: \
+ be/sparc/sparc_spec.pl be/scripts/generate_new_opcodes.pl
+ $(PERL) $(srcdir)/be/scripts/generate_new_opcodes.pl $(srcdir)/be/sparc/sparc_spec.pl $(srcdir)/be/sparc
+
+$(srcdir)/be/sparc/gen_sparc_emitter.c $(srcdir)/be/sparc/gen_sparc_emitter.h: \
+ be/sparc/sparc_spec.pl be/scripts/generate_emitter.pl
+ $(PERL) $(srcdir)/be/scripts/generate_emitter.pl $(srcdir)/be/sparc/sparc_spec.pl $(srcdir)/be/sparc
+
+$(srcdir)/be/sparc/gen_sparc_machine.c $(srcdir)/be/sparc/gen_sparc_machine.h: \
+ be/sparc/sparc_spec.pl be/scripts/generate_machine.pl
+ $(PERL) $(srcdir)/be/scripts/generate_machine.pl $(srcdir)/be/sparc/sparc_spec.pl $(srcdir)/be/sparc
+
+$(srcdir)/be/sparc/gen_sparc_regalloc_if.c $(srcdir)/be/sparc/gen_sparc_regalloc_if.h: \
+ be/sparc/sparc_spec.pl be/scripts/generate_machine.pl
+ $(PERL) $(srcdir)/be/scripts/generate_regalloc_if.pl $(srcdir)/be/sparc/sparc_spec.pl $(srcdir)/be/sparc
+
+# amd64 backend
+
+amd64_sources = \
+ be/amd64/amd64_emitter.c \
+ be/amd64/amd64_new_nodes.c \
+ be/amd64/amd64_transform.c \
+ be/amd64/bearch_amd64.c
+amd64_built_sources = \
+ be/amd64/gen_amd64_emitter.c \
+ be/amd64/gen_amd64_emitter.h \
+ be/amd64/gen_amd64_machine.c \
+ be/amd64/gen_amd64_machine.h \
+ be/amd64/gen_amd64_new_nodes.c.inl \
+ be/amd64/gen_amd64_new_nodes.h \
+ be/amd64/gen_amd64_regalloc_if.c \
+ be/amd64/gen_amd64_regalloc_if.h
+MAINTAINERCLEANFILES += $(amd64_built_sources)
+BUILT_SOURCES += $(amd64_built_sources)
+libfirm_la_SOURCES += $(amd64_sources) $(amd64_built_sources)
+
+EXTRA_DIST += \
+ be/amd64/amd64_emitter.h \
+ be/amd64/amd64_new_nodes.h \
+ be/amd64/amd64_nodes_attr.h \
+ be/amd64/amd64_spec.pl \
+ be/amd64/amd64_transform.h \
+ be/amd64/bearch_amd64_t.h
+
+$(srcdir)/be/amd64/gen_amd64_new_nodes.c.inl $(srcdir)/be/amd64/gen_amd64_new_nodes.h: \
+ be/amd64/amd64_spec.pl be/scripts/generate_new_opcodes.pl
+ $(PERL) $(srcdir)/be/scripts/generate_new_opcodes.pl $(srcdir)/be/amd64/amd64_spec.pl $(srcdir)/be/amd64
+
+$(srcdir)/be/amd64/gen_amd64_emitter.c $(srcdir)/be/amd64/gen_amd64_emitter.h: \
+ be/amd64/amd64_spec.pl be/scripts/generate_emitter.pl
+ $(PERL) $(srcdir)/be/scripts/generate_emitter.pl $(srcdir)/be/amd64/amd64_spec.pl $(srcdir)/be/amd64
+
+$(srcdir)/be/amd64/gen_amd64_machine.c $(srcdir)/be/amd64/gen_amd64_machine.h: \
+ be/amd64/amd64_spec.pl be/scripts/generate_machine.pl
+ $(PERL) $(srcdir)/be/scripts/generate_machine.pl $(srcdir)/be/amd64/amd64_spec.pl $(srcdir)/be/amd64
+
+$(srcdir)/be/amd64/gen_amd64_regalloc_if.c $(srcdir)/be/amd64/gen_amd64_regalloc_if.h: \
+ be/amd64/amd64_spec.pl be/scripts/generate_machine.pl
+ $(PERL) $(srcdir)/be/scripts/generate_regalloc_if.pl $(srcdir)/be/amd64/amd64_spec.pl $(srcdir)/be/amd64
+
+
+# TEMPLATE backend
+
+TEMPLATE_sources = \
+ be/TEMPLATE/TEMPLATE_emitter.c \
+ be/TEMPLATE/TEMPLATE_new_nodes.c \
+ be/TEMPLATE/TEMPLATE_transform.c \
+ be/TEMPLATE/bearch_TEMPLATE.c
+TEMPLATE_built_sources = \
+ be/TEMPLATE/gen_TEMPLATE_emitter.c \
+ be/TEMPLATE/gen_TEMPLATE_emitter.h \
+ be/TEMPLATE/gen_TEMPLATE_machine.c \
+ be/TEMPLATE/gen_TEMPLATE_machine.h \
+ be/TEMPLATE/gen_TEMPLATE_new_nodes.c.inl \
+ be/TEMPLATE/gen_TEMPLATE_new_nodes.h \
+ be/TEMPLATE/gen_TEMPLATE_regalloc_if.c \
+ be/TEMPLATE/gen_TEMPLATE_regalloc_if.h
+MAINTAINERCLEANFILES += $(TEMPLATE_built_sources)
+BUILT_SOURCES += $(TEMPLATE_built_sources)
+libfirm_la_SOURCES += $(TEMPLATE_sources) $(TEMPLATE_built_sources)
+
+EXTRA_DIST += \
+ be/TEMPLATE/TEMPLATE_emitter.h \
+ be/TEMPLATE/TEMPLATE_new_nodes.h \
+ be/TEMPLATE/TEMPLATE_nodes_attr.h \
+ be/TEMPLATE/TEMPLATE_spec.pl \
+ be/TEMPLATE/TEMPLATE_transform.h \
+ be/TEMPLATE/bearch_TEMPLATE_t.h
+
+$(srcdir)/be/TEMPLATE/gen_TEMPLATE_new_nodes.c.inl $(srcdir)/be/TEMPLATE/gen_TEMPLATE_new_nodes.h: \
+ be/TEMPLATE/TEMPLATE_spec.pl be/scripts/generate_new_opcodes.pl
+ $(PERL) $(srcdir)/be/scripts/generate_new_opcodes.pl $(srcdir)/be/TEMPLATE/TEMPLATE_spec.pl $(srcdir)/be/TEMPLATE
+
+$(srcdir)/be/TEMPLATE/gen_TEMPLATE_emitter.c $(srcdir)/be/TEMPLATE/gen_TEMPLATE_emitter.h: \
+ be/TEMPLATE/TEMPLATE_spec.pl be/scripts/generate_emitter.pl
+ $(PERL) $(srcdir)/be/scripts/generate_emitter.pl $(srcdir)/be/TEMPLATE/TEMPLATE_spec.pl $(srcdir)/be/TEMPLATE
+
+$(srcdir)/be/TEMPLATE/gen_TEMPLATE_machine.c $(srcdir)/be/TEMPLATE/gen_TEMPLATE_machine.h: \
+ be/TEMPLATE/TEMPLATE_spec.pl be/scripts/generate_machine.pl
+ $(PERL) $(srcdir)/be/scripts/generate_machine.pl $(srcdir)/be/TEMPLATE/TEMPLATE_spec.pl $(srcdir)/be/TEMPLATE
+
+$(srcdir)/be/TEMPLATE/gen_TEMPLATE_regalloc_if.c $(srcdir)/be/TEMPLATE/gen_TEMPLATE_regalloc_if.h: \
+ be/TEMPLATE/TEMPLATE_spec.pl be/scripts/generate_machine.pl
+ $(PERL) $(srcdir)/be/scripts/generate_regalloc_if.pl $(srcdir)/be/TEMPLATE/TEMPLATE_spec.pl $(srcdir)/be/TEMPLATE