From a4b86e67408718b6051e11169e7a75787091a41f Mon Sep 17 00:00:00 2001 From: Stefanos Chaliasos Date: Tue, 7 Jan 2020 08:14:37 +0200 Subject: [PATCH 1/2] Add missing Make dependencies --- Makefile | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index ae542a1f1..924d79460 100644 --- a/Makefile +++ b/Makefile @@ -6,8 +6,8 @@ SHELL = /bin/bash # inherit from env if set CC := $(CC) CXX := $(CXX) -CFLAGS := $(CFLAGS) -CXXFLAGS := $(CXXFLAGS) -std=c++11 +CFLAGS := $(CFLAGS) -MD +CXXFLAGS := $(CXXFLAGS) -std=c++11 -MD LDFLAGS := $(LDFLAGS) WARNING_FLAGS := -Wall -Wshadow -Wsign-compare -Wextra -Wunreachable-code -Wuninitialized -Wshadow RELEASE_FLAGS := -O3 -DNDEBUG @@ -41,8 +41,10 @@ man/tippecanoe.1: README.md PG= +DEPS=$(wildcard *.d) H = $(wildcard *.h) $(wildcard *.hpp) C = $(wildcard *.c) $(wildcard *.cpp) +OBJS = geojson.o jsonpull/jsonpull.o tile.o pool.o mbtiles.o geometry.o projection.o memfile.o mvt.o serial.o main.o text.o dirtiles.o plugin.o read_json.o write_json.o geobuf.o evaluator.o geocsv.o csv.o geojson-loop.o enumerate.o decode.o tile-join.o unit.o jsontool.o INCLUDES = -I/usr/local/include -I. LIBS = -L/usr/local/lib @@ -65,7 +67,7 @@ tippecanoe-json-tool: jsontool.o jsonpull/jsonpull.o csv.o text.o geojson-loop.o unit: unit.o text.o $(CXX) $(PG) $(LIBS) $(FINAL_FLAGS) $(CXXFLAGS) -o $@ $^ $(LDFLAGS) -lm -lz -lsqlite3 -lpthread --include $(wildcard *.d) +-include $(OBJS:.o=.d) %.o: %.c $(CC) -MMD $(PG) $(INCLUDES) $(FINAL_FLAGS) $(CFLAGS) -c -o $@ $< @@ -74,7 +76,7 @@ unit: unit.o text.o $(CXX) -MMD $(PG) $(INCLUDES) $(FINAL_FLAGS) $(CXXFLAGS) -c -o $@ $< clean: - rm -f ./tippecanoe ./tippecanoe-* ./tile-join ./unit *.o *.d */*.o */*.d tests/**/*.mbtiles tests/**/*.check + rm -f ./tippecanoe ./tippecanoe-* ./tile-join ./unit *.o *.d */*.o */*.d tests/**/*.mbtiles tests/**/*.check $(DEPS) indent: clang-format -i -style="{BasedOnStyle: Google, IndentWidth: 8, UseTab: Always, AllowShortIfStatementsOnASingleLine: false, ColumnLimit: 0, ContinuationIndentWidth: 8, SpaceAfterCStyleCast: true, IndentCaseLabels: false, AllowShortBlocksOnASingleLine: false, AllowShortFunctionsOnASingleLine: false, SortIncludes: false}" $(C) $(H) From 7c955c6b8e640da0f72efce9bfe5628453a259cd Mon Sep 17 00:00:00 2001 From: Stefanos Chaliasos Date: Sun, 19 Jan 2020 12:07:04 +0200 Subject: [PATCH 2/2] Remove -MD flag --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 924d79460..7957744b2 100644 --- a/Makefile +++ b/Makefile @@ -6,8 +6,8 @@ SHELL = /bin/bash # inherit from env if set CC := $(CC) CXX := $(CXX) -CFLAGS := $(CFLAGS) -MD -CXXFLAGS := $(CXXFLAGS) -std=c++11 -MD +CFLAGS := $(CFLAGS) +CXXFLAGS := $(CXXFLAGS) -std=c++11 LDFLAGS := $(LDFLAGS) WARNING_FLAGS := -Wall -Wshadow -Wsign-compare -Wextra -Wunreachable-code -Wuninitialized -Wshadow RELEASE_FLAGS := -O3 -DNDEBUG