#* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * #* * #* File....: Makefile * #* Name....: SoPlex Makefile * #* Author..: Thorsten Koch * #* Copyright by Author, All rights reserved * #* * #* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * .PHONY: depend clean ARCH := $(shell uname -m | \ sed \ -e s/sun../sparc/ \ -e s/i.86/x86/ \ -e s/IP../mips/ \ -e s/9000..../hppa/) OSTYPE := $(shell uname -s | tr A-Z a-z) OPT = opt ZLIB = true COMP = gnu CXX = g++ DCXX = g++ LINT = flexelint CPPFLAGS = -Isrc CXXFLAGS = -O LDFLAGS = -lm ARFLAGS = cr DFLAGS = -MM SRCDIR = extra BINDIR = bin LIBDIR = lib NAME = lpconv FLAGS = # OBJECT = lpconv.o #------------------------------------------------------------------------------ #--- NOTHING TO CHANGE FROM HERE ON ------------------------------------------- #------------------------------------------------------------------------------ GCCWARN = -Wall -W -Wpointer-arith -Wbad-function-cast \ -Wcast-align -Wwrite-strings -Wconversion \ -Wstrict-prototypes -Wmissing-prototypes \ -Wmissing-declarations -Wno-unknown-pragmas \ -Wctor-dtor-privacy -Wnon-virtual-dtor -Wreorder \ -Woverloaded-virtual -Wsign-promo -Wsynth -Wundef \ -Wcast-qual -Wold-style-cast -Wshadow # -Weffc++ -Wredundant-decls BASE = $(OSTYPE).$(ARCH).$(COMP).$(OPT) TARGET = $(NAME).$(BASE) LIBNAME = soplex.$(BASE) BINARY = $(BINDIR)/$(TARGET) DEPEND = extra/lpconv.dep OBJDIR = obj/O.$(BASE) OBJXXX = $(addprefix $(OBJDIR)/,$(OBJECT)) LIBXXX = $(addprefix $(OBJDIR)/,$(LIBOBJ)) OBJSRC = $(addprefix $(SRCDIR)/,$(OBJECT:.o=.cpp)) LIBSRC = $(addprefix $(SRCDIR)/,$(LIBOBJ:.o=.cpp)) #----------------------------------------------------------------------------- include make/make.$(BASE) #----------------------------------------------------------------------------- ifeq ($(ZLIB),true) CPPFLAGS += -DWITH_ZLIB $(ZLIB_FLAGS) LDFLAGS += $(ZLIB_LDFLAGS) endif $(BINARY): $(OBJXXX) $(LIBDIR)/lib$(LIBNAME).a $(CXX) $(CXXFLAGS) $(OBJXXX) \ -L$(LIBDIR) -l$(LIBNAME) $(LDFLAGS) -o $@ clean: -rm -rf $(OBJXXX) $(BINARY) depend: $(SHELL) -ec '$(DCXX) $(DFLAGS) $(CPPFLAGS) \ $(OBJSRC:.o=.cpp) $(LIBSRC:.o=.cpp) \ | sed '\''s|^\([0-9A-z]\{1,\}\)\.o|$$\(OBJDIR\)/\1.o|g'\'' \ >$(DEPEND)' -include $(DEPEND) $(OBJDIR)/%.o: $(SRCDIR)/%.cpp $(CXX) $(CPPFLAGS) $(CXXFLAGS) -c $< -o $@ # --- EOF ---------------------------------------------------------------------