Index: dbug/Makefile.am =================================================================== --- dbug/Makefile.am.orig +++ dbug/Makefile.am @@ -29,6 +29,12 @@ NROFF_INC = example1.r examp output4.r output5.r CLEANFILES = $(NROFF_INC) user.t user.ps +if CROSS_COMPILING +factorial=$(FACTORIAL) +else +factorial=$(top_builddir)/dbug/factorial$(EXEEXT) +endif + # Must be linked with libs that are not compiled yet noinst_PROGRAMS = factorial dbug_analyze @@ -44,19 +50,19 @@ user.ps: user.r $(NROFF_INC) -groff -mm user.r > $@ output1.r: factorial - ./factorial 1 2 3 4 5 | cat > $@ + $(factorial) 1 2 3 4 5 | cat > $@ output2.r: factorial - ./factorial -\#t:o 2 3 | cat >$@ + $(factorial) -\#t:o 2 3 | cat >$@ output3.r: factorial - ./factorial -\#d:t:o 3 | cat >$@ + $(factorial) -\#d:t:o 3 | cat >$@ output4.r: factorial - ./factorial -\#d,result:o 4 | cat >$@ + $(factorial) -\#d,result:o 4 | cat >$@ output5.r: factorial - ./factorial -\#d:f,factorial:F:L:o 3 | cat >$@ + $(factorial) -\#d:f,factorial:F:L:o 3 | cat >$@ .c.r: @RM@ -f $@ @SED@ -e 's!\\!\\\\!g' $< > $@