Skip to content

Commit

Permalink
The default for m4 is disable gnu options, except for gas.
Browse files Browse the repository at this point in the history
  • Loading branch information
albert committed Feb 10, 2014
1 parent a7c8704 commit 3632b18
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,10 @@
# .mig : Currently in use for the wordset, which is a .mi file (WRONG!)
# It could be, but it has been stolen.

# Would love to use -G but we need the patsubst macro.
M4=m4 ciforth.m4
# Normal use of m4
M4=m4 -G ciforth.m4
# Only needed for gas where we need the patsubst macro.
M4_GNU=m4 ciforth.m4

# ALL FILES STARTING IN ``ci86'' (OUTHER ``ci86.gnr'') ARE GENERATED

Expand Down Expand Up @@ -244,7 +246,7 @@ ci86.%.msm : VERSION %.cfg masm.m4 ci86.gnr

# Using FASM, generating a windows executable on linux.
ci86.%.fas : VERSION %.cfg fasm.m4 ci86.gnr
cat $+ | m4 >$(TEMPFILE)
cat $+ | $(M4) - >$(TEMPFILE)
sed $(TEMPFILE) -e '/Split here for doc/,$$d' \
>$@
sed $(TEMPFILE) -e '1,/Split here for doc/d' | \
Expand All @@ -255,7 +257,7 @@ ci86.%.fas : VERSION %.cfg fasm.m4 ci86.gnr
# Now that gas has the .Intel_syntax option, its source can be
# generated by m4 alone. In particular the order of operands.
ci86.%.s : VERSION %.cfg gas.m4 ci86.gnr ; \
cat $+ | $(M4) - >$(TEMPFILE)
cat $+ | $(M4_GNU) - >$(TEMPFILE)
sed $(TEMPFILE) -e '/Split here for doc/,$$d' >$@
sed $(TEMPFILE) -e '1,/Split here for doc/d' | \
sed -e '/Split here for test/,$$d' >$(@:%.s=%.rawdoc)
Expand Down

0 comments on commit 3632b18

Please sign in to comment.