Commit 893cefe1 authored by Per Cederqvist's avatar Per Cederqvist
Browse files

(DISKOBJS): Added version-info.o.

(C_SPECIALS): Added version-info.c.
(SPECIALS): Added version.incl.
(version.incl): New target (version.incl is now built from
	../../versions, it is no longer a source file).
(version-info.c): New target (also built from ../../versions).
parent 9cf71945
#
# $Id: Makefile.src,v 1.20 1994/06/18 18:52:41 ceder Exp $
# $Id: Makefile.src,v 1.21 1994/12/31 11:47:27 ceder Exp $
# Copyright (C) 1991, 1993, 1994 Lysator Academic Computer Association.
#
# This file is part of the LysKOM server.
......@@ -52,7 +52,7 @@ GENOBJS = connections.o log.o $(ATOMS) \
# Files for lyskomd.
DISKOBJS = ramkomd.o ram-smalloc.o simple-cache.o ram-parse.o ram-output.o \
disk-end-of-atomic.o cache-node.o string-malloc.o
disk-end-of-atomic.o cache-node.o string-malloc.o version-info.o
# Files for dbck.
......@@ -68,10 +68,11 @@ ENCRYPT = encrypt-passwd.o dbck-cache.o ram-smalloc.o ram-parse.o \
kom-types.o\
ram-output.o memory.o
C_SPECIALS = prot-a-parse-arg.c
C_SPECIALS = prot-a-parse-arg.c version-info.c
SPECIALS = call-switch.incl com.h fnc-def-init.incl \
prot-a-parse-arg.h fncdef-no-str-limit.txt .gdbinit \
version.incl \
$(C_SPECIALS)
PROGRAMS = lyskomd dbck updateLysKOM
......@@ -112,6 +113,31 @@ fncdef-no-str-limit.txt: fncdef.txt
cat $(srcdir)/fncdef.txt) \
| sed 's/([^)]*)//g' > fncdef-no-str-limit.txt
version.incl: @SRCTOPDIR@/versions
echo '/* Do not edit -- automaticaly generated file */' > $@.tmp
sed -n 's/SERVER-COMPAT-VERSION: //p' @SRCTOPDIR@/versions >>$@.tmp
echo '/* Do not edit -- automaticaly generated file */' >>$@.tmp
mv $@.tmp $@
version-info.c: @SRCTOPDIR@/versions
echo '/* Do not edit -- automaticaly generated file */' > $@.tmp
echo '#include <limits.h>' >>$@.tmp
echo '#include <sys/types.h>' >>$@.tmp
echo '#include "misc-types.h"' >>$@.tmp
echo '#include "s-string.h"' >>$@.tmp
echo '#include "kom-types.h"' >>$@.tmp
echo '#include "version-info.h"' >>$@.tmp
echo 'Version_info_internal kom_version_info = {' >>$@.tmp
sed -n 's/PROTOCOL-A-LEVEL: \(.*\)/ \1,/p' \
@SRCTOPDIR@/versions >>$@.tmp
sed -n 's/SERVER-SOFTWARE: \(.*\)/ "\1",/p' \
@SRCTOPDIR@/versions >>$@.tmp
sed -n 's/SERVER-VERSION: \(.*\)/ "\1"/p' \
@SRCTOPDIR@/versions >>$@.tmp
echo '};' >>$@.tmp
echo '/* Do not edit -- automaticaly generated file */' >>$@.tmp
mv $@.tmp $@
.gdbinit: Makefile
$(RM) -f .gdbinit
echo handle 13 nostop noprint >.gdbinit
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment