1 # Unix fall-back makefile for the Netwide Assembler. For use if
2 # `configure' fails to generate a workable Makefile.
4 # The Netwide Assembler is copyright (C) 1996 Simon Tatham and
5 # Julian Hall. All rights reserved. The software is
6 # redistributable under the licence given in the file "Licence"
7 # distributed in the NASM archive.
9 # You may need to adjust these values.
15 # You _shouldn't_ need to adjust anything below this line.
17 exec_prefix = ${prefix}
18 bindir = ${exec_prefix}/bin
19 mandir = ${prefix}/man
22 INSTALL_PROGRAM = ${INSTALL}
23 INSTALL_DATA = ${INSTALL} -m 644
26 $(CC) -c $(CFLAGS) $*.c
28 NASM = nasm.o nasmlib.o float.o insnsa.o assemble.o labels.o \
29 parser.o outform.o outbin.o outaout.o outcoff.o outelf.o \
30 outobj.o outas86.o outrdf.o outdbg.o preproc.o listing.o \
33 NDISASM = ndisasm.o disasm.o sync.o nasmlib.o insnsd.o
41 $(CC) -o ndisasm $(NDISASM)
43 assemble.o: assemble.c nasm.h nasmlib.h assemble.h insns.h
44 disasm.o: disasm.c nasm.h disasm.h sync.h insns.h names.c
45 eval.o: eval.c eval.h nasm.h nasmlib.h
46 float.o: float.c nasm.h
47 insnsa.o: insnsa.c nasm.h insns.h
48 insnsd.o: insnsd.c nasm.h insns.h
49 labels.o: labels.c nasm.h nasmlib.h
50 listing.o: listing.c nasm.h nasmlib.h listing.h
51 nasm.o: nasm.c nasm.h nasmlib.h preproc.h parser.h assemble.h labels.h \
53 nasmlib.o: nasmlib.c nasm.h nasmlib.h
54 ndisasm.o: ndisasm.c nasm.h nasmlib.h sync.h disasm.h
55 outaout.o: outaout.c nasm.h nasmlib.h outform.h
56 outas86.o: outas86.c nasm.h nasmlib.h outform.h
57 outbin.o: outbin.c nasm.h nasmlib.h outform.h
58 outcoff.o: outcoff.c nasm.h nasmlib.h outform.h
59 outdbg.o: outdbg.c nasm.h nasmlib.h outform.h
60 outelf.o: outelf.c nasm.h nasmlib.h outform.h
61 outform.o: outform.c outform.h nasm.h
62 outobj.o: outobj.c nasm.h nasmlib.h outform.h
63 outrdf.o: outrdf.c nasm.h nasmlib.h outform.h
64 parser.o: parser.c nasm.h nasmlib.h parser.h float.h names.c
65 preproc.o: preproc.c nasm.h nasmlib.h macros.c
68 # These two source files are automagically generated from a single
69 # instruction-table file by a Perl script. They're distributed,
70 # though, so it isn't necessary to have Perl just to recompile NASM
71 # from the distribution.
73 insnsa.c insnsd.c: insns.dat insns.pl
74 perl insns.pl insns.dat
76 # This source file is generated from the standard macros file
77 # `standard.mac' by another Perl script. Again, it's part of the
78 # standard distribution.
80 macros.c: standard.mac macros.pl
81 perl macros.pl standard.mac
84 $(INSTALL_PROGRAM) nasm $(bindir)/nasm
85 $(INSTALL_PROGRAM) ndisasm $(bindir)/ndisasm
86 $(INSTALL_DATA) nasm.1 $(mandir)/man1/nasm.1
87 $(INSTALL_DATA) ndisasm.1 $(mandir)/man1/ndisasm.1
90 rm -f *.o nasm ndisasm
91 $(MAKE) -C rdoff clean
96 rdf_install install_rdf:
97 $(MAKE) -C rdoff install