Created
February 23, 2019 22:51
-
-
Save adabo/1a5658f8187042931d83eec4e356bc28 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CC=gcc | |
#CXX=g++ | |
CXX=$(shell root-config --cxx) | |
RM=rm -f | |
#CPPFLAGS=-g $(shell root-config --cflags) | |
CPPFLAGS=$(shell root-config --cflags) | |
LDFLAGS=-g $(shell root-config --ldflags) | |
LDLIBS=$(shell root-config --libs) | |
SRCS=main.cpp item.cpp item.h backpack.cpp backpack.h constants.h | |
OBJS=$(subst .cc,.o,$(SRCS)) | |
all: main | |
main: $(OBJS) | |
$(CXX) $(LDFLAGS) -o main $(OBJS) $(LDLIBS) | |
depend: .depend | |
.depend: $(SRCS) | |
$(RM) ./.depend | |
$(CXX) $(CPPFLAGS) -MM $^>>./.depend; | |
clean: | |
$(RM) $(OBJS) | |
distclean: clean | |
$(RM) *~ .depend | |
include .depend |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment