So, I wouldn’t use #pragma. I don’t know how it works in your case but I know that when you use #pragma once
in the headers files, it might screwed up with include path depending on how you write it (I let you search on SO if that interests you), so I would rather recommend a basic ifndef against the double inclusion. So be sure of what you do if you use pragma.
Second, maybe you can create your own Makefile, there are good tutorials on Internet I guess. If you need to include a .h in a specific location you should use -I option (an upper case i) to specify the directory of all possible .h. If I remind well, -L is a linker option and you should put it after filenames when you compile : g++ compiler_args files linker_args
Here is one of my old makefile if it can help you:
```SRC = main.cpp \
src/DB.cpp \
src/Table.cpp
OBJ = $(SRC:%.cpp=%.o)
NAME = orm
CXX = g++
CXXFLAGS = -I ./ -Wall -Wextra -pedantic -Werror -std=c++14
RM = rm -f
all: $(NAME)
$(NAME): $(OBJ)
$(CXX) $(OBJ) -o $(NAME) -lmysqlcppconn
clean:
$(RM) $(OBJ)
fclean: clean
$(RM) $(NAME)
re: fclean all
```