49 lines
953 B
Makefile
49 lines
953 B
Makefile
#
|
|
# Makefile to create binaries form COBOL and C sources
|
|
#
|
|
|
|
prefix=..
|
|
exec_prefix=../../compiler
|
|
g_includes=-I/usr/local/include
|
|
g_libraries=-L/usr/local/lib
|
|
|
|
SHELL=/bin/sh
|
|
CCX=gcc
|
|
#COB=${exec_prefix}/htcobol
|
|
COB=htcobol
|
|
ASM=as
|
|
RM=rm -f
|
|
|
|
COPYBOOKS= -I../copybooks -I.
|
|
INCLUDES= -I/usr/local/include -I../../
|
|
CCXFLAGS= -g -DDEBUG ${INCLUDES}
|
|
LIBS= -L../../lib -lhtcobol -L/c/mingw/include -L/usr/local/lib -ldb -ldl -lm
|
|
EXTRALIBS=
|
|
LDFLAGS=
|
|
#COBFLAGS=-P -g -D -t ${COPYBOOKS}
|
|
COBFLAGS=-P ${COPYBOOKS}
|
|
ASMFLAGS=-D
|
|
|
|
SRC1 = tdb01a.cob
|
|
SRC2 = tdb01.c
|
|
|
|
OBJS = $(SRC2:.c=.o) $(SRC1:.cob=.o)
|
|
|
|
PROG1 = tdb01
|
|
PROGS = $(PROG1)
|
|
|
|
|
|
include ${prefix}/config/C.rules.in
|
|
include ${prefix}/config/COB.rules.in
|
|
include ${prefix}/config/COB.build.tmpl.in
|
|
|
|
all: ${PROGS}
|
|
|
|
${PROGS}: ${OBJS}
|
|
$(CCX) -g -o $@ ${OBJS} $(LDFLAGS) $(LIBS)
|
|
# strip $@
|
|
|
|
clean:
|
|
@${RM} ${OBJS} $(PROGS) $(PROG1)*lis ${PROG1}*txt ${PROG1}*s \
|
|
core *run.err.trace.txt *run.trace.txt temp*cob dbdat*
|