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

Don't pass CC, CFLAGS et c via the environment. General cleanups.

parent aeb3b7e5
No related branches found
No related tags found
No related merge requests found
# Makefile for LysKOM
#
###############################################################################
#
# SPECIAL CONSIDERATIONS:
#
# - Requires GNU make.
# - CC, OPTIMIZE-FLAGS and other make variables are passed down
# in the environment.
# - C compiler must be ANSI conformant.
#
###############################################################################
#
# SPECIAL TARGETS:
###############################################################################
# Directories that you might want to override via the environment.
ifndef TOPDIR
TOPDIR = /usr/lyskom/src TOPDIR = /usr/lyskom/src
endif
ifndef SCRIPTDIR
SCRIPTDIR = $(TOPDIR)/scripts SCRIPTDIR = $(TOPDIR)/scripts
endif
TARGET = -DCLIENT
include $(SCRIPTDIR)/import.make include $(SCRIPTDIR)/import.make
TARGET = -DCLIENT
# All directories that make should traverse to when doing clean etc.
SUBDIRS = ansi server SUBDIRS = ansi server
...@@ -39,7 +13,7 @@ all: ...@@ -39,7 +13,7 @@ all:
for i in $(SUBDIRS); \ for i in $(SUBDIRS); \
do \ do \
echo making all in directory $$i; \ echo making all in directory $$i; \
(cd $$i; $(MAKE) all); \ (cd $$i; $(MAKE) $(EXPORTS) all); \
done done
...@@ -51,26 +25,15 @@ install: ...@@ -51,26 +25,15 @@ install:
for i in $(SUBDIRS); \ for i in $(SUBDIRS); \
do \ do \
echo making install in directory $$i; \ echo making install in directory $$i; \
(cd $$i; $(MAKE) install); \ (cd $$i; $(MAKE) $(EXPORTS) install); \
done done
clean: clean:
rm -vf ${OBJECTS} *~ core temp-Makefile Distfile *.o $(RM) *~ core temp-Makefile Distfile *.o
for i in $(SUBDIRS); \ for i in $(SUBDIRS); \
do \ do \
echo making clean in directory $$i; \ echo making clean in directory $$i; \
(cd $$i; $(MAKE) clean); \ (cd $$i; $(MAKE) $(EXPORTS) clean); \
done done
depend:;
depend: \ No newline at end of file
for i in $(SUBDIRS); \
do \
echo making depend in directory $$i; \
(cd $$i; $(MAKE) depend); \
done
>dependencies
specials:;
include dependencies
# Makefile for LysKOM
#
###############################################################################
#
# SPECIAL CONSIDERATIONS:
#
# - Requires GNU make.
# - CC, OPTIMIZE-FLAGS and other make variables are passed down
# in the environment.
# - C compiler must be ANSI conformant.
#
###############################################################################
#
# SPECIAL TARGETS:
###############################################################################
# Directories that you might want to override via the environment.
ifndef TOPDIR
TOPDIR = /usr/lyskom/src TOPDIR = /usr/lyskom/src
endif
ifndef SCRIPTDIR
SCRIPTDIR = $(TOPDIR)/scripts SCRIPTDIR = $(TOPDIR)/scripts
endif
TARGET = -DCLIENT
include $(SCRIPTDIR)/import.make include $(SCRIPTDIR)/import.make
TARGET = -DCLIENT
# All directories that make should traverse to when doing clean etc.
INSTALL-HDRS = smalloc.h INSTALL-HDRS = smalloc.h
...@@ -46,9 +19,4 @@ install: ...@@ -46,9 +19,4 @@ install:
clean: clean:
rm -vf ${OBJECTS} *~ core temp-Makefile Distfile *.o rm -vf ${OBJECTS} *~ core temp-Makefile Distfile *.o
depend: depend:;
>dependencies
specials:;
include dependencies
TOPDIR = /usr/lyskom/src
SCRIPTDIR = $(TOPDIR)/scripts
include $(SCRIPTDIR)/import.make
# All directories that make should traverse to when doing clean etc. # All directories that make should traverse to when doing clean etc.
# Note that client-support depends on libmisc. # Note that client-support depends on libmisc.
...@@ -7,7 +12,7 @@ all: ...@@ -7,7 +12,7 @@ all:
for i in $(SUBDIRS) ; \ for i in $(SUBDIRS) ; \
do \ do \
echo making all in directory $$i; \ echo making all in directory $$i; \
(cd $$i; $(MAKE) all) \ (cd $$i; $(MAKE) $(EXPORTS) all) \
done done
...@@ -15,8 +20,7 @@ depend: ...@@ -15,8 +20,7 @@ depend:
for i in $(SUBDIRS) ; \ for i in $(SUBDIRS) ; \
do \ do \
echo making depend in directory $$i; \ echo making depend in directory $$i; \
(cd $$i; $(MAKE) depend); \ (cd $$i; $(MAKE) $(EXPORTS) depend); \
echo make depend in directory $$i ready.; \
done done
...@@ -24,7 +28,7 @@ install: ...@@ -24,7 +28,7 @@ install:
for i in $(SUBDIRS) ; \ for i in $(SUBDIRS) ; \
do \ do \
echo making install in directory $$i; \ echo making install in directory $$i; \
(cd $$i; $(MAKE) install) \ (cd $$i; $(MAKE) $(EXPORTS) install) \
done done
...@@ -32,7 +36,7 @@ install-headers: ...@@ -32,7 +36,7 @@ install-headers:
for i in $(SUBDIRS) ; \ for i in $(SUBDIRS) ; \
do \ do \
echo making install-headers in directory $$i; \ echo making install-headers in directory $$i; \
(cd $$i; $(MAKE) install-headers) \ (cd $$i; $(MAKE) $(EXPORTS) install-headers) \
done done
...@@ -41,6 +45,6 @@ clean: ...@@ -41,6 +45,6 @@ clean:
for i in $(SUBDIRS); \ for i in $(SUBDIRS); \
do \ do \
echo making clean in directory $$i; \ echo making clean in directory $$i; \
(cd $$i; $(MAKE) clean) \ (cd $$i; $(MAKE) $(EXPORTS) clean) \
done done
# Makefile for LysKOM
#
###############################################################################
#
# SPECIAL CONSIDERATIONS:
#
# - Requires GNU make.
# - CC, OPTIMIZE-FLAGS and other make variables are passed down
# in the environment.
# - C compiler must be ANSI conformant.
#
###############################################################################
#
# SPECIAL TARGETS:
###############################################################################
# Directories that you might want to override via the environment.
ifndef TOPDIR
TOPDIR = /usr/lyskom/src TOPDIR = /usr/lyskom/src
endif
ifndef SCRIPTDIR
SCRIPTDIR = $(TOPDIR)/scripts SCRIPTDIR = $(TOPDIR)/scripts
endif
TARGET = -DCLIENT
include $(SCRIPTDIR)/import.make include $(SCRIPTDIR)/import.make
TARGET = -DCLIENT
# All directories that make should traverse to when doing clean etc.
LIBNAME = libansi.a LIBNAME = libansi.a
......
# Makefile for LysKOM
#
###############################################################################
#
# SPECIAL CONSIDERATIONS:
#
# - Requires GNU make.
# - CC, OPTIMIZE-FLAGS and other make variables are passed down
# in the environment.
# - C compiler must be ANSI conformant.
#
###############################################################################
#
# SPECIAL TARGETS:
###############################################################################
# Directories that you might want to override via the environment.
ifndef TOPDIR
TOPDIR = /usr/lyskom/src TOPDIR = /usr/lyskom/src
endif
ifndef SCRIPTDIR
SCRIPTDIR = $(TOPDIR)/scripts SCRIPTDIR = $(TOPDIR)/scripts
endif
TARGET = -DCLIENT
include $(SCRIPTDIR)/import.make include $(SCRIPTDIR)/import.make
TARGET = -DCLIENT
# All directories that make should traverse to when doing clean etc.
LIBOBJS = kom-errno.o misc-parser.o parser.o LIBOBJS = kom-errno.o misc-parser.o parser.o
...@@ -51,7 +24,7 @@ server-dir: ...@@ -51,7 +24,7 @@ server-dir:
.PHONY: liblyskom-server.a .PHONY: liblyskom-server.a
liblyskom-server.a: server-dir liblyskom-server.a: server-dir
(cd server-dir; make -f ../Makefile ../$@ TARGET=-DSERVER) (cd server-dir; make $(EXPORTS) -f ../Makefile ../$@ TARGET=-DSERVER)
ranlib $@ ranlib $@
...@@ -60,7 +33,7 @@ liblyskom-server.a: server-dir ...@@ -60,7 +33,7 @@ liblyskom-server.a: server-dir
.PHONY: liblyskom-client.a .PHONY: liblyskom-client.a
liblyskom-client.a: client-dir liblyskom-client.a: client-dir
(cd client-dir; make -f ../Makefile ../$@ TARGET=-DCLIENT) (cd client-dir; make $(EXPORTS) -f ../Makefile ../$@ TARGET=-DCLIENT)
ranlib $@ ranlib $@
...@@ -84,11 +57,6 @@ install-headers: ...@@ -84,11 +57,6 @@ install-headers:
tags: tags:
etags -t $(INCLUDEDIR)/*.h *.[hc] etags -t $(INCLUDEDIR)/*.h *.[hc]
#rdist: clean
# echo "(/usr/local/src/2kom/common) -> (nanny.lysator.liu.se)" >Distfile
# echo "install;" >>Distfile
# rdist
# Recreate the Makefile from Makefile # Recreate the Makefile from Makefile
include $(SCRIPTDIR)/Parallell-depend.make include $(SCRIPTDIR)/Parallell-depend.make
......
...@@ -13,24 +13,12 @@ ...@@ -13,24 +13,12 @@
# #
# SPECIAL TARGETS: # SPECIAL TARGETS:
############################################################################### ###############################################################################
# Directories that you might want to override via the environment.
ifndef TOPDIR
TOPDIR = /usr/lyskom/src TOPDIR = /usr/lyskom/src
endif
ifndef SCRIPTDIR
SCRIPTDIR = $(TOPDIR)/scripts SCRIPTDIR = $(TOPDIR)/scripts
endif
TARGET = -DCLIENT
include $(SCRIPTDIR)/import.make include $(SCRIPTDIR)/import.make
TARGET = -DCLIENT
# All directories that make should traverse to when doing clean etc.
LIBNAME = libmisc.a LIBNAME = libmisc.a
...@@ -38,9 +26,6 @@ LIBOBJS = pom.o s-collat-tabs.o s-string.o zmalloc.o ...@@ -38,9 +26,6 @@ LIBOBJS = pom.o s-collat-tabs.o s-string.o zmalloc.o
INSTALL-HDRS = pom.h s-collat-tabs.h s-string.h zmalloc.h INSTALL-HDRS = pom.h s-collat-tabs.h s-string.h zmalloc.h
#OBJECTS = numlist.o numlist2.o pom.o s-collat-tabs.o s-string.o \
# testnumlist.o zmalloc.o
all: $(LIBNAME) all: $(LIBNAME)
$(LIBNAME): $(LIBOBJS) $(LIBNAME): $(LIBOBJS)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment