125 lines
2.6 KiB
Makefile
125 lines
2.6 KiB
Makefile
# Generated automatically from Makefile.in by configure.
|
|
#### Start of system configuration section. ####
|
|
|
|
|
|
srcdir = .
|
|
|
|
ifeq ($(srcdir),.)
|
|
srcdir = ../..
|
|
endif
|
|
|
|
VPATH := $(srcdir)
|
|
|
|
# Common prefix for machine-independent installed files.
|
|
prefix = /usr/local
|
|
|
|
# Common prefix for machine-dependent installed files.
|
|
exec_prefix = ${prefix}
|
|
|
|
bindir = $(exec_prefix)/bin
|
|
libdir = $(exec_prefix)/Sys/libs
|
|
|
|
INSTALL = /usr/bin/install -c
|
|
INSTALL_DATA = ${INSTALL} -m 644
|
|
|
|
CC = gcc
|
|
|
|
CFLAGS = -g -O2
|
|
LDFLAGS =
|
|
|
|
RANLIB = ranlib
|
|
AR = ar
|
|
|
|
#### End system configuration section ####
|
|
|
|
# I *love* GNU make!
|
|
define catenate
|
|
/bin/echo -n creating $@...
|
|
/bin/echo -e "$(^:%=#include \"%\"\n)" >$@
|
|
/bin/echo done
|
|
endef
|
|
|
|
FLAVOR_CFLAGS = -m$(CPU) -m$(FPU)
|
|
ifeq ($(FPU),__HAVE_68881__)
|
|
DEF_FPU = -D$(FPU)
|
|
else
|
|
DEF_FPU =
|
|
endif
|
|
|
|
OTHER_CFLAGS = -fomit-frame-pointer
|
|
ALL_CFLAGS = $(CFLAGS) $(FLAVOR_CFLAGS) $(INCS) $(OTHER_CFLAGS) $(DEFS)
|
|
|
|
INCS = -I$(srcdir) -I$(srcdir)/../library -I$(srcdir)/../include -I. -I$(srcdir)/../../inlines/include
|
|
DEFS = -D__DBINTERFACE_PRIVATE
|
|
LIB = libixnet.a
|
|
SHELL = sh
|
|
|
|
# Strip the executable (-s), don't look for standard libraries (-nostdlib)
|
|
# don't link in crt0.o (-nostartfiles)
|
|
# link in some libc.a files (-L../../glue/no-baserel -lglue)
|
|
# need some stuff in libgeneral.a
|
|
|
|
LINKFLAGS = -nostdlib -nostartfiles -L../../../glue/no-baserel -L../../../db/no-baserel
|
|
|
|
.S.o:
|
|
$(CC) $(ALL_CFLAGS) -traditional -c $< -o $@
|
|
|
|
.c.o:
|
|
$(CC) $(ALL_CFLAGS) -c $< -o $@
|
|
|
|
all: ixnet.library ixnet.debug
|
|
|
|
SRC_A4 = set_errno.c siglaunch.c
|
|
SRC_MISC = create_header.c parse_version.c
|
|
|
|
SRC = $(filter-out $(SRC_A4) $(SRC_MISC),$(notdir $(wildcard $(srcdir)/*.c)))
|
|
|
|
OBJ_N = start.o
|
|
|
|
IXLIBS = $(LIB)
|
|
|
|
LIBS = -lglue
|
|
|
|
|
|
$(LIB) : a4.o az.o
|
|
rm -f $@
|
|
$(AR) rv $@ $^
|
|
$(RANLIB) $@
|
|
|
|
ixnet.library: $(OBJ_N) $(IXLIBS)
|
|
$(CC) -s $(LINKFLAGS) $(OBJ_N) $(IXLIBS) $(LIBS) -o $@
|
|
|
|
ixnet.debug: $(OBJ_N) $(IXLIBS)
|
|
$(CC) -g $(LINKFLAGS) $(OBJ_N) $(IXLIBS) $(LIBS) -o $@
|
|
|
|
clean:
|
|
rm -rf 680?0 notrap
|
|
|
|
clobber: clean
|
|
rm -f Makefile
|
|
|
|
a4.o: a4.c
|
|
$(CC) $(ALL_CFLAGS) -ffixed-a4 -c $< -o $@
|
|
|
|
start.o: $(srcdir)/start.S version.h $(srcdir)/../include/sys/ixnet_syscall.def ix_internals.h
|
|
|
|
a4.c: $(SRC_A4)
|
|
@$(catenate)
|
|
|
|
az.c: $(SRC)
|
|
@$(catenate)
|
|
|
|
ix_internals.h: create_header
|
|
./create_header >$@
|
|
|
|
create_header: create_header.c $(srcdir)/../include/user.h ixnet.h
|
|
gcc $(CFLAGS) $(INCS) $(OTHER_CFLAGS) $(DEFS) $< -o $@
|
|
chmod u+x $@
|
|
|
|
parse_version: parse_version.c
|
|
gcc $(CFLAGS) $(OTHER_CFLAGS) -Dmc$(CPU) $(DEF_FPU) $(DEFS) $< -o $@
|
|
chmod u+x $@
|
|
|
|
version.h: parse_version $(srcdir)/../version.in
|
|
./parse_version $(srcdir) >$@
|