aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorTom Harley2019-01-29 19:23:33 +0000
committerTom Harley2019-01-31 16:56:51 +0000
commitcf96cb370b3af5f11d8add5c468ec686457b9762 (patch)
tree255a152c29b8e0f90204c893402a88a7f117c9cb /Makefile
parentReorganise submodules (and submodulise solvitaire) (diff)
downloadmetasol-cf96cb370b3af5f11d8add5c468ec686457b9762.tar.gz
metasol-cf96cb370b3af5f11d8add5c468ec686457b9762.zip

Update submodules

I promise it works this time

Diffstat (limited to 'Makefile')
-rw-r--r--Makefile14
1 files changed, 11 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 14ed0a3..62fd1cc 100644
--- a/Makefile
+++ b/Makefile
@@ -1,9 +1,9 @@
CXX = g++
-CXXFLAGS = -ggdb3 -O0 -Wpedantic -Wall -Werror #-DNOTHREAD
+CXXFLAGS = -ggdb3 -O0 -Wpedantic -Wall -Werror
OUTPUT_OPTION = -MMD -MP -o $@
LINK.o = $(LINK.cc)
-LDFLAGS = -Lsolvitaire -Lthpool -Ldocopt -Ljsmn
+LDFLAGS = -Lthpool -Ldocopt -Ljsmn -Lsolvitaire
LDLIBS = -lpthread -lsol -lthpool -ldocopt -ljsmn
TRGT = centre
@@ -11,12 +11,20 @@ SRC = metasol.cpp centre.cpp
OBJ = $(SRC:.cpp=.o)
DEP = $(SRC:.cpp=.d)
-.PHONY: default all run
+.PHONY: default all run init-submodules
default: all
all: $(TRGT)
$(TRGT): $(OBJ)
+init-submodules:
+ git submodule init
+ git submodule update
+ $(MAKE) -C thpool
+ $(MAKE) -C jsmn
+ (cd docopt; cmake .; make docopt_s)
+ (cd solvitaire; sh build.sh)
+
run: $(TRGT)
./$<