Преглед на файлове

Better makefile order and gitignore

master
Ludovic 'Archivist' Lagouardette преди 4 години
родител
ревизия
8703bde308
променени са 2 файла, в които са добавени 31 реда и са изтрити 24 реда
  1. +4
    -0
      .gitignore
  2. +27
    -24
      Makefile

+ 4
- 0
.gitignore Целия файл

@ -0,0 +1,4 @@
.deps/*
src_deps/*
include_deps/*
build/*

+ 27
- 24
Makefile Целия файл

@ -30,6 +30,33 @@ DEPS := .deps/spdlog \
.deps/spdlog_sqlite \
.deps/sqlite3 \
.deps/jinx
#####################
# COMPILATION MODES #
#####################
all:
+make deps
+make executable
debug:
+make deps
+make debug_executable
release:
+make deps
+make release_executable
executable: deps
executable: build $(APP_DIR)/$(TARGET)
debug_executable: CFLAGS += -DDEBUG -g
debug_executable: CXXFLAGS += -DDEBUG -g
debug_executable: build $(APP_DIR)/$(TARGET)
gdb $(APP_DIR)/$(TARGET)
release_executable: CFLAGS += -O3 -march=native
release_executable: CXXFLAGS += -O3 -march=native
release_executable: build $(APP_DIR)/$(TARGET)
#############################
# DEPENDENCIES DECLARATIONS #
@ -93,30 +120,6 @@ $(DEPS_DIR)/libspdlog.a:
# PROJECT COMPILATION #
#######################
all:
+make deps
+make executable
debug:
+make deps
+make debug_executable
release:
+make deps
+make release_executable
executable: deps
executable: build $(APP_DIR)/$(TARGET)
debug_executable: CFLAGS += -DDEBUG -g
debug_executable: CXXFLAGS += -DDEBUG -g
debug_executable: build $(APP_DIR)/$(TARGET)
gdb $(APP_DIR)/$(TARGET)
release_executable: CFLAGS += -O3 -march=native
release_executable: CXXFLAGS += -O3 -march=native
release_executable: build $(APP_DIR)/$(TARGET)
$(OBJ_DIR)/%.cpp.o: %.cpp
@mkdir -p $(@D)
$(CXX) $(CXXFLAGS) $(INCLUDE) -c $< -o $@ $(LDFLAGS)

Зареждане…
Отказ
Запис