Add submodule requirement to makefile

This commit is contained in:
Bad Diode 2022-03-04 14:16:32 +01:00
parent 4760ae8f10
commit 9f81a64787
1 changed files with 6 additions and 1 deletions

View File

@ -3,6 +3,7 @@ BUILD_DIR ?= build
SRC_MAIN ?= $(SRC_DIR)/main.c SRC_MAIN ?= $(SRC_DIR)/main.c
EXE_NAME ?= fbtest EXE_NAME ?= fbtest
BIN := $(BUILD_DIR)/$(EXE_NAME) BIN := $(BUILD_DIR)/$(EXE_NAME)
BASE_UXN := src/uxn/src/uxn.h
CC ?= cc CC ?= cc
CFLAGS := -Wall -Wextra -pedantic CFLAGS := -Wall -Wextra -pedantic
@ -23,12 +24,16 @@ endif
main: $(BIN) main: $(BIN)
$(BIN): $(SRC_MAIN) $(BUILD_DIR) $(BIN): $(SRC_MAIN) $(BUILD_DIR) $(BASE_UXN)
$(CC) $(CFLAGS) -o $(BIN) $(SRC_MAIN) $(CC) $(CFLAGS) -o $(BIN) $(SRC_MAIN)
$(BUILD_DIR): $(BUILD_DIR):
mkdir -p $(BUILD_DIR) mkdir -p $(BUILD_DIR)
$(BASE_UXN):
git submodule init
git submodule update
run: $(BIN) run: $(BIN)
# NOTE: This should probably be done on the C code. # NOTE: This should probably be done on the C code.
echo 0 > /sys/class/graphics/fbcon/cursor_blink echo 0 > /sys/class/graphics/fbcon/cursor_blink