Skip to content
Snippets Groups Projects
Commit 69a4cb2a authored by Robert Yang's avatar Robert Yang
Browse files

Support cross compiling (!81)

The environment variables should be override-able and extensible to
accommodate cross-compiling.
parent 35e2d306
No related branches found
No related tags found
No related merge requests found
...@@ -3,8 +3,8 @@ TARGET := osk-sdl ...@@ -3,8 +3,8 @@ TARGET := osk-sdl
SDL2_CFLAGS := $(shell sdl2-config --cflags) SDL2_CFLAGS := $(shell sdl2-config --cflags)
SDL2_LIBS := $(shell sdl2-config --libs) SDL2_LIBS := $(shell sdl2-config --libs)
CXX := g++ CXX ?= g++
CXXFLAGS := -std=c++14 -Wall -g $(SDL2_CFLAGS) CXXFLAGS := -std=c++14 -Wall -g $(CXXFLAGS) $(SDL2_CFLAGS)
LIBS := -lcryptsetup $(SDL2_LIBS) -lSDL2_ttf LIBS := -lcryptsetup $(SDL2_LIBS) -lSDL2_ttf
...@@ -23,7 +23,7 @@ $(OBJ_DIR)/%.o: $(SRC_DIR)/%.cpp ...@@ -23,7 +23,7 @@ $(OBJ_DIR)/%.o: $(SRC_DIR)/%.cpp
$(BIN_DIR)/$(TARGET): $(OBJECTS) $(BIN_DIR)/$(TARGET): $(OBJECTS)
@echo LD $@ @echo LD $@
@$(CXX) -o $@ $^ $(CXXFLAGS) $(LIBS) @$(CXX) -o $@ $^ $(CXXFLAGS) $(LDFLAGS) $(LIBS)
.PHONY: clean .PHONY: clean
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment