Mon Nov 9 12:00:36 1998 Dave Brolley <brolley@cygnus.com>
[deliverable/binutils-gdb.git] / binutils / makefile.vms-in
CommitLineData
e10a4fc4 1#
66d45014 2# Makefile for binutils under openVMS (Alpha and Vax)
e10a4fc4
ILT
3#
4# For use with gnu-make for vms
5#
66d45014 6# Created by Klaus K"ampf, kkaempf@rmi.de
e10a4fc4
ILT
7#
8#
9
e72afe26 10# Distribution version, filled in by configure.com
66d45014 11VERSION=@VERSION@
e72afe26 12
66d45014
ILT
13ifeq ($(ARCH),ALPHA)
14TARGET=""vms-alpha""
15else
16TARGET=""vms-vax""
17endif
e72afe26 18
e10a4fc4 19ifeq ($(CC),gcc)
e72afe26
ILT
20CFLAGS=/include=([],[-.include],[-.bfd])$(DEFS)
21DEFS=/define=("TARGET=$(TARGET)")
ead31302 22LIBS=,gnu_cc_library:libgcc/lib,sys$$library:vaxcrtl.olb/lib,gnu_cc_library:crt0.obj
e10a4fc4 23else
66d45014
ILT
24CFLAGS=/noopt/debug/include=([],[-.include],[-.bfd])$(DEFS)\
25/warnings=disable=(missingreturn,implicitfunc,longextern)
26DEFS=/define=("TARGET=$(TARGET)","const=","unlink=remove")
2a774ae9 27LIBS=,sys$$library:vaxcrtl.olb/lib
e10a4fc4
ILT
28endif
29
2a774ae9
ILT
30BFDLIB = [-.bfd]libbfd.olb/lib
31BFDLIB_DEP = [-.bfd]libbfd.olb
32LIBIBERTY_DEP = [-.libiberty]libiberty.olb
33LIBIBERTY = [-.libiberty]libiberty.olb/lib
34OPCODES_DEP = [-.opcodes]libopcodes.olb
35OPCODES = [-.opcodes]libopcodes.olb/lib
e10a4fc4 36
2a774ae9 37DEBUG_OBJS = rddbg.obj,debug.obj,stabs.obj,ieee.obj,rdcoff.obj
e10a4fc4 38
2a774ae9 39WRITE_DEBUG_OBJS = $(DEBUG_OBJS),wrstabs.obj
e10a4fc4 40
2a774ae9 41BULIBS = []bucomm.obj,version.obj,filemode.obj
e10a4fc4 42
2a774ae9
ILT
43ADDL_DEPS = $(BULIBS),$(BFDLIB_DEP),$(LIBIBERTY_DEP)
44ADDL_LIBS = $(BULIBS),$(BFDLIB),$(LIBIBERTY)
e10a4fc4 45
2a774ae9 46SIZEOBJS = $(ADDL_DEPS),size.obj
e10a4fc4 47
2a774ae9 48STRINGSOBJS = $(ADDL_DEPS),strings.obj
e10a4fc4 49
2a774ae9 50NMOBJS = $(ADDL_DEPS),nm.obj
e10a4fc4 51
2a774ae9 52OBJDUMPOBJS = $(ADDL_DEPS),objdump.obj,prdbg.obj,$(DEBUG_OBJS),$(OPCODES_DEP)
e10a4fc4 53
2a774ae9 54all: config.h size.exe strings.exe objdump.exe nm.exe
e10a4fc4 55
2a774ae9
ILT
56size.exe: $(SIZEOBJS)
57 link/exe=$@ size.obj,$(ADDL_LIBS)$(LIBS)
58
59strings.exe: $(STRINGSOBJS)
60 link/exe=$@ strings.obj,$(ADDL_LIBS)$(LIBS)
61
62nm.exe: $(NMOBJS)
63 link/exe=$@ nm.obj,$(ADDL_LIBS)$(LIBS)
e10a4fc4 64
2a774ae9
ILT
65objdump.exe: $(OBJDUMPOBJS)
66 link/exe=$@ objdump.obj,prdbg.obj,$(DEBUG_OBJS),$(BFDLIB),$(OPCODES),$(ADDL_LIBS)$(LIBS)
67
68
69version.obj: version.c
e72afe26
ILT
70 $(CC) $(CFLAGS)/define=(VERSION="""$(VERSION)""") $<
71
72config.h:
73 $$ @configure
ead31302 74 $(MAKE) -f makefile.vms "CC=$(CC)"
e72afe26
ILT
75
76[-.bfd]libbfd.olb:
77 $(CD) [-.bfd]
ead31302 78 $(MAKE) -f makefile.vms "CC=$(CC)"
e72afe26
ILT
79 $(CD) [-.binutils]
80
81[-.libiberty]libiberty.olb:
82 $(CD) [-.libiberty]
ead31302 83 $(MAKE) -f makefile.vms "CC=$(CC)"
e72afe26
ILT
84 $(CD) [-.binutils]
85
86[-.opcodes]libopcodes.olb:
87 $(CD) [-.opcodes]
ead31302 88 $(MAKE) -f makefile.vms "CC=$(CC)"
e72afe26
ILT
89 $(CD) [-.binutils]
90
91clean:
92 $$ purge
93 $(RM) *.obj;
94 $(RM) *.exe;
66d45014
ILT
95
96distclean: clean
e72afe26 97 $(RM) config.h;
66d45014 98 $(RM) makefile.vms;
This page took 0.086552 seconds and 4 git commands to generate.