$(TOPDIR), make: Intermediate commit of revised build architecture

This commit is contained in:
Jan Lindemann 2002-06-08 09:26:58 +00:00 committed by Jan Lindemann
commit 405f0aa49d
8 changed files with 212 additions and 31 deletions

View file

@ -3,14 +3,25 @@
# contact@jannet.de
# $Id$
# doesn't work :-(
ifndef PROJECT
PROJECT := yannet
LIBNAME := yannet
else
LIBNAME := $(PROJECT)
PROJECT := ytools
REQUIRED = make misc slog platform \
devutil \
hash \
hexdump \
lbuffer \
debug \
cfgfile gtopts \
lock sigsync shmem \
usrv uclnt statecheck msgfmt \
YMisc YError \
YThread YMutex YCbContr \
YTimeB YStopWatch YStopWatchList YStopWatchQueue YStopWatchThreadList \
lib
endif
LIBNAME := $(PROJECT)
ifndef TOPDIR
TOPDIR := $(MODDIR)
endif
@ -42,7 +53,8 @@ GCC_REV = $(shell gcc -v 2>&1 | grep version | awk '{ split($$3,a,"."); pri
CPP = g++
#LIBNAME = $(PROJECT)
EXE_SH = $(wildcard *.sh)
CFILES = $(wildcard *.c)
CPPFILES = $(wildcard *.cc *.cpp)
CALLSRC = $(CFILES) $(CPPFILES)
@ -85,13 +97,18 @@ ALL_CSRC = $(LOCAL_CSRC) $(PREREQ_CSRC)
TEXTCLEAN = $(wildcard *~ .*~ .*.swp *.rep)
INCLUDE = -I. -I$(TOPDIR)/include -I$(MODDIR)/include $(PROJECT_INCLUDE) $(LOCAL_INCLUDE)
INSTALL_LIBDIR = $(PREFIX)/lib
INSTALL_HDRDIR = $(PREFIX)/include
INSTALL_BINDIR = $(PREFIX)/bin
SO_SUFFIX = so.$(VERSION)
LIB_A = $(LIBDIR)/lib$(LIBNAME).a
ifeq ($(LIBTYPE),shared)
LIB_SO = $(LIBDIR)/lib$(LIBNAME).so
INSTALLED_LIB_SO = $(INSTALL_LIBDIR)/lib$(LIBNAME).so
else
endif
LIB_SO = $(LIBDIR)/lib$(LIBNAME).$(SO_SUFFIX)
INSTALLED_LIB_SO = $(INSTALL_LIBDIR)/lib$(LIBNAME).$(SO_SUFFIX)
INSTALLED_LIB_A = $(INSTALL_LIBDIR)/lib$(LIBNAME).a
INSTALLED_EXE = $(INSTALL_BINDIR)/$(EXE)
INSTALLED_EXE_SH = $(addprefix $(INSTALL_BINDIR)/,$(EXE_SH))
MEMBERS = $(LIB_A)($(OBJ))
#PREFIX = ../# CAUTION: This breaks the installation in the project
#MEMWATCH = -DMEMWATCH -DMW_STDIO