2014-06-13 12:57:35 +02:00
|
|
|
# To use clang, run: make CXX=clang++
|
2012-07-10 23:46:00 +02:00
|
|
|
|
2014-06-13 12:57:35 +02:00
|
|
|
CXXFLAGS = $(shell mapnik-config --cflags) -fPIC
|
2012-07-10 23:46:00 +02:00
|
|
|
|
|
|
|
LIBS = $(shell mapnik-config --libs --ldflags --dep-libs)
|
|
|
|
|
|
|
|
SRC = $(wildcard *.cpp)
|
|
|
|
|
|
|
|
OBJ = $(SRC:.cpp=.o)
|
|
|
|
|
|
|
|
BIN = hello.input
|
|
|
|
|
|
|
|
all : $(SRC) $(BIN)
|
|
|
|
|
|
|
|
$(BIN) : $(OBJ)
|
|
|
|
$(CXX) -shared $(OBJ) $(LIBS) -o $@
|
|
|
|
|
|
|
|
.cpp.o :
|
|
|
|
$(CXX) -c $(CXXFLAGS) $< -o $@
|
|
|
|
|
|
|
|
.PHONY : clean
|
|
|
|
|
|
|
|
clean:
|
|
|
|
rm -f $(OBJ)
|
|
|
|
rm -f $(BIN)
|
|
|
|
|
2012-07-10 23:50:43 +02:00
|
|
|
deploy : all
|
2012-07-10 23:46:00 +02:00
|
|
|
cp hello.input $(shell mapnik-config --input-plugins)
|
|
|
|
|
2014-06-13 12:57:35 +02:00
|
|
|
install: all deploy
|