Makefile with ROOT required


ROOT Version: 6.14/04
Platform: Linux Ubuntu
Compiler: Not Provided


My makefile works for my setup but without ROOT objects. Sorry if this a noob request, I just started learning all of this.Screenshot_3
I just need help in modifying the MakeFile in order to use ROOT’s objects in my analysis

makefile:

CXX		  := g++
CXX_FLAGS := -Wall -Wextra -std=c++17 -ggdb
BIN		:= bin
SRC		:= src
INCLUDE	:= include
LIB		:= lib

LIBRARIES	:=
EXECUTABLE	:= main


all: $(BIN)/$(EXECUTABLE)

run: clean all
	clear
	./$(BIN)/$(EXECUTABLE)

$(BIN)/$(EXECUTABLE): $(SRC)/*.C
	$(CXX) $(CXX_FLAGS) -I$(INCLUDE) -L$(LIB) $^ -o $@ $(LIBRARIES)

clean:
	-rm $(BIN)/*

Errors

g++ -Wall -Wextra -std=c++17 -ggdb -Iinclude -Llib src/cFCgraphics.C src/signal.C -o bin/main 
src/cFCgraphics.C:6:10: fatal error: TROOT.h: No such file or directory
 #include "TROOT.h"
          ^~~~~~~~~
compilation terminated.
In file included from src/signal.h:3:0,
                 from src/signal.C:3:
src/cFCgraphics.h:7:10: fatal error: TApplication.h: No such file or directory
 #include "TApplication.h"
          ^~~~~~~~~~~~~~~~
compilation terminated.
Makefile:19: recipe for target 'bin/main' failed
make: *** [bin/main] Error 1

Makefile.txt (419 Bytes)

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.