2 # Makefile for binutils under openVMS (Alpha and Vax)
4 # For use with gnu-make for vms
6 # Created by Klaus K"ampf, kkaempf@rmi.de
10 # Distribution version, filled in by configure.com
20 CFLAGS=/include=([],[-.include],[-.bfd])$(DEFS)
21 DEFS=/define=("TARGET=$(TARGET)")
22 LIBS=,gnu_cc_library:libgcc/lib,sys$$library:vaxcrtl.olb/lib,gnu_cc_library:crt0.obj
24 CFLAGS=/noopt/debug/include=([],[-.include],[-.bfd])$(DEFS)\
25 /warnings=disable=(missingreturn,implicitfunc,longextern)
26 DEFS=/define=("TARGET=$(TARGET)","const=","unlink=remove")
27 LIBS=,sys$$library:vaxcrtl.olb/lib
30 BFDLIB = [-.bfd]libbfd.olb/lib
31 BFDLIB_DEP = [-.bfd]libbfd.olb
32 LIBIBERTY_DEP = [-.libiberty]libiberty.olb
33 LIBIBERTY = [-.libiberty]libiberty.olb/lib
34 OPCODES_DEP = [-.opcodes]libopcodes.olb
35 OPCODES = [-.opcodes]libopcodes.olb/lib
37 DEBUG_OBJS = rddbg.obj,debug.obj,stabs.obj,ieee.obj,rdcoff.obj
39 WRITE_DEBUG_OBJS = $(DEBUG_OBJS),wrstabs.obj
41 BULIBS = []bucomm.obj,version.obj,filemode.obj
43 ADDL_DEPS = $(BULIBS),$(BFDLIB_DEP),$(LIBIBERTY_DEP)
44 ADDL_LIBS = $(BULIBS),$(BFDLIB),$(LIBIBERTY)
46 SIZEOBJS = $(ADDL_DEPS),size.obj
48 STRINGSOBJS = $(ADDL_DEPS),strings.obj
50 NMOBJS = $(ADDL_DEPS),nm.obj
52 OBJDUMPOBJS = $(ADDL_DEPS),objdump.obj,prdbg.obj,$(DEBUG_OBJS),$(OPCODES_DEP)
54 all: config.h size.exe strings.exe objdump.exe nm.exe
57 link/exe=$@ size.obj,$(ADDL_LIBS)$(LIBS)
59 strings.exe: $(STRINGSOBJS)
60 link/exe=$@ strings.obj,$(ADDL_LIBS)$(LIBS)
63 link/exe=$@ nm.obj,$(ADDL_LIBS)$(LIBS)
65 objdump.exe: $(OBJDUMPOBJS)
66 link/exe=$@ objdump.obj,prdbg.obj,$(DEBUG_OBJS),$(BFDLIB),$(OPCODES),$(ADDL_LIBS)$(LIBS)
69 version.obj: version.c
70 $(CC) $(CFLAGS)/define=(VERSION="""$(VERSION)""") $<
74 $(MAKE) -f makefile.vms "CC=$(CC)"
78 $(MAKE) -f makefile.vms "CC=$(CC)"
81 [-.libiberty]libiberty.olb:
83 $(MAKE) -f makefile.vms "CC=$(CC)"
86 [-.opcodes]libopcodes.olb:
88 $(MAKE) -f makefile.vms "CC=$(CC)"