mirror of
https://github.com/kanaka/mal.git
synced 2024-09-20 01:57:09 +03:00
7f45725c19
The modified implementations have been tested on Debian bullseye. * prefer later Ubuntu image, hopefully reducing the image count * for Ubuntu versions, prefer numerical versions to unsorted codenames * prefer packaged build systems to local rebuilds * prefer the current default version of each build system * delegate resolution of indirect dependencies to apt * xslt: remove intermediate run script. The initial motivation is to provide an explicit path to the python3 interpreter, as the versioned executable is not always in PATH. * Add DEBIAN_FRONTEND=noninteractive to some Dockerfiles. This is to workaround tzdata which prompts interactively by default. * Debian/Ubuntu do not ship a python->python2 link by default. * With the improved logo implementation in another branch, there is no need anymore to tweat the garbage collector settings. * logo: use upstream brandy compiler (instead of building). * guile: adjust deb-src mechanism to build ucblogo and workaround doc build bug.
52 lines
934 B
Makefile
52 lines
934 B
Makefile
uname_S := $(shell sh -c 'uname -s 2>/dev/null || echo not')
|
|
|
|
CXX=g++
|
|
ifeq ($(uname_S),Darwin)
|
|
# Native build on yosemite. Requires: brew install readline
|
|
READLINE=/usr/local/opt/readline
|
|
INCPATHS=-I$(READLINE)/include
|
|
LIBPATHS=-L$(READLINE)/lib
|
|
endif
|
|
|
|
LD=$(CXX)
|
|
AR=ar
|
|
|
|
DEBUG=-ggdb
|
|
CXXFLAGS=-O3 -Wall $(DEBUG) $(INCPATHS) -std=c++11
|
|
LDFLAGS=-O3 $(DEBUG) $(LIBPATHS) -L. -lreadline -lhistory
|
|
|
|
LIBSOURCES=Core.cpp Environment.cpp Reader.cpp ReadLine.cpp String.cpp \
|
|
Types.cpp Validation.cpp
|
|
LIBOBJS=$(LIBSOURCES:%.cpp=%.o)
|
|
|
|
MAINS=$(wildcard step*.cpp)
|
|
TARGETS=$(MAINS:%.cpp=%)
|
|
|
|
.PHONY: all clean
|
|
|
|
.SUFFIXES: .cpp .o
|
|
|
|
all: $(TARGETS)
|
|
|
|
dist: mal
|
|
|
|
mal: stepA_mal
|
|
cp $< $@
|
|
|
|
.deps: *.cpp *.h
|
|
$(CXX) $(CXXFLAGS) -MM *.cpp > .deps
|
|
|
|
$(TARGETS): %: %.o libmal.a
|
|
$(LD) $^ -o $@ $(LDFLAGS)
|
|
|
|
libmal.a: $(LIBOBJS)
|
|
$(AR) rcs $@ $^
|
|
|
|
.cpp.o:
|
|
$(CXX) $(CXXFLAGS) -c $< -o $@
|
|
|
|
clean:
|
|
rm -rf *.o $(TARGETS) libmal.a .deps mal
|
|
|
|
-include .deps
|