From 83c048d1295b9df59d90a7513953c99a267eb1f5 Mon Sep 17 00:00:00 2001 From: Joel Grunbaum <joel.grunbaum@imc.com> Date: Tue, 11 Jan 2022 07:26:39 +0000 Subject: [PATCH] CYA Cmake, compiling on remote box --- Makefile | 36 +++++++++++++++++++++++------------- 1 files changed, 23 insertions(+), 13 deletions(-) diff --git a/Makefile b/Makefile index 96fba56..bcc17bc 100644 --- a/Makefile +++ b/Makefile @@ -1,16 +1,26 @@ -CC=gcc CXX=g++ -CXXFLAGS=-g -Wall -std=c++20 - -.PHONY: default all -default: all - -all: exec - -exec: main.o book.o - ${CXX} -o $@ $^ - -%: %.cpp %.hpp - ${CXX} ${CXXFLAGS} -o $@ $^ +CXXFLAGS=-g -Wall -static +#LDFLAGS=-rpath=/lib64/libstdc++.so.6 +json=json.o +ws=easywsclient/easywsclient.o +main=${json} ${ws} protocol.o book.o + +default: test click bot + +test: test.o strat.o ${main} + ${CXX} ${CXXFLAGS} ${LDFLAGS} -o $@ $^ + +click: click.o ${main} + ${CXX} ${CXXFLAGS} ${LDFLAGS} -o $@ $^ + +bot: bot.o strat.o ${main} + ${CXX} ${CXXFLAGS} ${LDFLAGS} -o $@ $^ + +%.o: %.cpp + ${CXX} ${CXXFLAGS} -c -o $@ $^ + +.PHONY: clean +clean: + rm -f ${main} test click bot -- Gitblit v1.9.3