Skip to content
Snippets Groups Projects
Commit f46b9b25 authored by Per Cederqvist's avatar Per Cederqvist
Browse files

New method of configuring the ansi-replacement include files.

parent ab45aa05
Branches
Tags
No related merge requests found
#!/bin/sh #!/bin/sh
# $Id: Config,v 1.3 1991/08/30 03:16:52 ceder Exp $ # $Id: Config,v 1.4 1991/09/03 22:12:52 ceder Exp $
x= x=
[ -d include ] || mkdir include [ -d include ] && rm -rf include
mkdir include
case "$1" in case "$1" in
+help | +hel | +he | +h | -h | -H) +help | +hel | +he | +h | -h | -H)
echo Usage: ./Config hosttype echo Usage: ./Config hosttype
...@@ -11,7 +13,7 @@ case "$1" in ...@@ -11,7 +13,7 @@ case "$1" in
echo balance sparc;; echo balance sparc;;
balance) balance)
x=balance;; x=balance;;
sun4 | sun4os4 | sparc | sparcos4) sun3 | sun3os4 | sun4 | sun4os4 | sparc | sparcos4)
x=sun4os4;; x=sun4os4;;
*) echo Unsupported host type "$1". *) echo Unsupported host type "$1".
x=error;; x=error;;
...@@ -20,8 +22,19 @@ esac ...@@ -20,8 +22,19 @@ esac
case "$x" in case "$x" in
error) false;; error) false;;
*) *)
rm -f include/m-config.h
rm -f scripts/import.make rm -f scripts/import.make
ln -s ../config/${x}-config.h include/m-config.h ln -s ../config/${x}-config.h include/m-config.h
ln -s ../config/${x}-defs.make scripts/import.make;; ln -s ../config/${x}-defs.make scripts/import.make
ln -s ../src/include/ansi/${x} include/ansi
cd include/ansi
cat links | while read link target; do \
rm ${link}; \
ln -s ../${target-Templates}/${link} ${link}; \
done
cd sys
cat links | while read link target; do \
rm ${link}; \
ln -s ../../${target-Templates}/sys/${link} ${link}; \
done;;
esac esac
...@@ -8,8 +8,7 @@ SERVER-VER = 1.0 ...@@ -8,8 +8,7 @@ SERVER-VER = 1.0
all: msg includes libraries binaries end-msg all: msg includes libraries binaries end-msg
includes: $(INCLUDEDIR)/m-config.h includes: $(INCLUDEDIR) $(INCLUDEDIR)/m-config.h
-mkdir $(INCLUDEDIR)
for i in $(SUBDIRS) ; \ for i in $(SUBDIRS) ; \
do \ do \
[ -d $$i ] && { echo making includes in directory $$i; \ [ -d $$i ] && { echo making includes in directory $$i; \
...@@ -17,7 +16,7 @@ includes: $(INCLUDEDIR)/m-config.h ...@@ -17,7 +16,7 @@ includes: $(INCLUDEDIR)/m-config.h
done done
libraries: $(INCLUDEDIR)/m-config.h libraries: $(INCLUDEDIR) $(INCLUDEDIR)/m-config.h
-mkdir $(LIBDIR) -mkdir $(LIBDIR)
for i in $(SUBDIRS) ; \ for i in $(SUBDIRS) ; \
do \ do \
...@@ -40,7 +39,7 @@ clean: ...@@ -40,7 +39,7 @@ clean:
(cd $$i; $(MAKE) $(EXPORTS) clean) } \ (cd $$i; $(MAKE) $(EXPORTS) clean) } \
done done
depend: $(INCLUDEDIR)/m-config.h msg includes depend: $(INCLUDEDIR) $(INCLUDEDIR)/m-config.h msg includes
distribution: clean distribution: clean
-$(RM) -r lyskom-$(SERVER-VER) -$(RM) -r lyskom-$(SERVER-VER)
...@@ -76,7 +75,6 @@ end-msg: ...@@ -76,7 +75,6 @@ end-msg:
@echo Finished at @echo Finished at
@date @date
$(INCLUDEDIR)/m-config.h: $(INCLUDEDIR) $(INCLUDEDIR)/m-config.h:
@echo You must run Config before Build or make. @echo You must run Config before Build or make.
@exit 1 @exit 1
TOPDIR = /usr/lyskom/src TOPDIR = /usr/lyskom
SCRIPTDIR = $(TOPDIR)/scripts SCRIPTDIR = $(TOPDIR)/scripts
include $(SCRIPTDIR)/import.make include $(SCRIPTDIR)/import.make
TARGET = -DCLIENT
SUBDIRS = ansi server SUBDIRS = ansi server
INSTALL-HDRS = $(wildcard *.h) INSTALL-HDRS = $(wildcard *.h)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment