]> granicus.if.org Git - yasm/commitdiff
NASM preprocessor's genmacro needs to built differently for cross-building.
authorPeter Johnson <peter@tortall.net>
Sat, 14 Aug 2004 23:49:29 +0000 (23:49 -0000)
committerPeter Johnson <peter@tortall.net>
Sat, 14 Aug 2004 23:49:29 +0000 (23:49 -0000)
svn path=/trunk/yasm/; revision=1128

modules/preprocs/nasm/Makefile.inc

index da3865a6d4bc9c7937692e035c20653b096001f2..988435dd58809dcbcd7b31e873899a5761204b7b 100644 (file)
@@ -26,7 +26,13 @@ CLEANFILES += nasm-macros.c
 
 noinst_PROGRAMS += genmacro
 
-genmacro_SOURCES = modules/preprocs/nasm/genmacro.c
+genmacro_SOURCES =
+EXTRA_DIST += modules/preprocs/nasm/genmacro.c
+genmacro_LDADD = genmacro.$(OBJEXT)
+genmacro_LINK = $(CCLD_FOR_BUILD) -o $@
+
+genmacro.$(OBJEXT): modules/preprocs/nasm/genmacro.c
+       $(CC_FOR_BUILD) $(DEFAULT_INCLUDES) $(INCLUDES) -c -o $@ `test -f modules/preprocs/nasm/genmacro.c || echo '$(srcdir)/'`modules/preprocs/nasm/genmacro.c
 
 EXTRA_DIST += modules/preprocs/nasm/standard.mac
 EXTRA_DIST += modules/preprocs/nasm/tests/Makefile.inc