]>
Commit | Line | Data |
---|---|---|
cb0e7c25 TG |
1 | # |
2 | # makefile for gas | |
3 | # | |
4 | # Created by Klaus Kaempf, [email protected] | |
5 | # | |
6 | #CC=gcc | |
7 | CC=cc | |
cb0e7c25 TG |
8 | |
9 | ifeq ($(CC),gcc) | |
10 | DEFS= | |
11 | CFLAGS=/include=([],[-.bfd],[.config],[-.include],[-])$(DEFS) | |
12 | LFLAGS= | |
13 | LIBS=,GNU_CC_LIBRARY:libgcc/lib,sys$$library:vaxcrtl.olb/lib,GNU_CC_LIBRARY:crt0.obj | |
14 | else | |
15 | #DEFS=/define=("VMS_DEBUG","DEBUG2","DEBUG3","DEBUG5","DEBUG_SYMS","DEBUG_ALPHA") | |
16 | OPT=/noopt/debug | |
17 | CFLAGS=/names=(as_is,shortened)\ | |
fb792462 | 18 | /include=([],[-.bfd],[.config],"../include","../")$(DEFS)$(OPT)\ |
cb0e7c25 TG |
19 | /prefix=(all,except=("getopt","optarg","optopt","optind","opterr")) |
20 | #LFLAGS=/debug/map=as.map | |
cb0e7c25 TG |
21 | endif |
22 | ||
aba69ce4 | 23 | OBJS:=targ-cpu.obj,obj-format.obj,atof-targ.obj,app.obj,as.obj,\ |
1222b291 TG |
24 | atof-generic.obj,cond.obj,compress-debug.obj,depend.obj,expr.obj,\ |
25 | flonum-konst.obj,flonum-copy.obj,flonum-mult.obj,\ | |
26 | frags.obj,hash.obj,input-file.obj,\ | |
cb0e7c25 TG |
27 | input-scrub.obj,literal.obj,messages.obj,output-file.obj,read.obj,\ |
28 | subsegs.obj,symbols.obj,write.obj,listing.obj,ecoff.obj,stabs.obj,sb.obj,\ | |
29 | macro.obj,ehopt.obj,dw2gencfi.obj,dwarf2dbg.obj,remap.obj | |
30 | ||
aba69ce4 TG |
31 | ifeq ($(ARCH),IA64) |
32 | OBJS:=$(OBJS),te-vms.obj | |
33 | endif | |
34 | ||
cb0e7c25 | 35 | LIBIBERTY = [-.libiberty]libiberty.olb |
cb0e7c25 TG |
36 | LIBBFD = [-.bfd]libbfd.olb |
37 | LIBOPCODES = [-.opcodes]libopcodes.olb | |
cb0e7c25 TG |
38 | |
39 | all: as.exe | |
40 | ||
41 | as.exe: $(OBJS) $(LIBOPCODES) $(LIBBFD) $(LIBIBERTY) | |
42 | link$(LFLAGS)/exe=$@ $(OBJS),$(LIBOPCODES)/lib,$(LIBBFD)/lib,$(LIBIBERTY)/lib$(LIBS) | |
43 | ||
44 | ifneq ($(CC),gcc) | |
45 | # Work-around a DEC-C bug. | |
46 | targ-cpu.obj: targ-cpu.c targ-cpu.h | |
47 | $(COMPILE.c) /noopt/obj=$@ $< | |
48 | endif | |
49 | ||
b11d79f2 TG |
50 | te-vms.obj: [.config]te-vms.c |
51 | $(COMPILE.c) /obj=$@ $< + sys$$library:sys$$lib_c.tlb/lib | |
52 | ||
cb0e7c25 TG |
53 | clean: |
54 | $$ purge | |
55 | $(RM) *.obj; | |
56 | $(RM) *.exe; | |
57 | $(RM) atof-targ.c; | |
58 | $(RM) obj-format.c; | |
59 | $(RM) obj-format.h; | |
60 | $(RM) targ-env.h; | |
61 | $(RM) targ-cpu.h; | |
62 | $(RM) targ-cpu.c; |