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

Import tinystl as a submodule

Streetwalrus Einstein преди 10 години
родител
ревизия
f0c6ca9b63
променени са 4 файла, в които са добавени 10 реда и са изтрити 6 реда
  1. 3 0
      .gitmodules
  2. 4 4
      Makefile
  3. 2 2
      README.md
  4. 1 0
      external/tinystl

+ 3 - 0
.gitmodules

@@ -0,0 +1,3 @@
+[submodule "external/tinystl"]
+	path = external/tinystl
+	url = git://github.com/mendsley/tinystl.git

+ 4 - 4
Makefile

@@ -2,7 +2,7 @@ NAME = WalrusRPG
 
 DEBUG = FALSE
 
-CFLAGS_COMMON = -Wall -W -marm -I include -I art -fdiagnostics-color=always
+CFLAGS_COMMON = -Wall -W -marm -fdiagnostics-color=always
 
 ifeq ($(DEBUG),FALSE)
 	CFLAGS_COMMON += -Ofast -flto
@@ -21,12 +21,12 @@ LDFLAGS = $(CFLAGS_COMMON) -Wl,--gc-sections
 ZEHN = genzehn
 ZEHNFLAGS = --name "$(NAME)" --compress
 
-INCDIR = include
 SRCDIR = src
 
 SOURCES_C = art/sprites.c $(wildcard $(SRCDIR)/*.c)
 SOURCES_CPP = $(wildcard $(SRCDIR)/*.cpp)
 OBJS = $(patsubst %.c,%.o,$(SOURCES_C)) $(patsubst %.cpp,%.o,$(SOURCES_CPP))
+INCLUDE = -I include -I art -I external/tinystl/include
 
 DISTDIR = bin
 ELF = $(DISTDIR)/$(NAME).elf
@@ -43,11 +43,11 @@ art/sprites.c: sprites
 
 %.o: %.c| sprites
 	@echo "CC: $@"
-	@$(CC) $(CFLAGS) -I$(INCDIR) -c $< -o $@
+	@$(CC) $(CFLAGS) $(INCLUDE) -c $< -o $@
 
 %.o: %.cpp| sprites
 	@echo "CPP: $@"
-	@$(CPP) $(CPPFLAGS) -I$(INCDIR) -c $< -o $@
+	@$(CPP) $(CPPFLAGS) $(INCLUDE) -c $< -o $@
 
 
 $(ELF): $(OBJS) |sprites

+ 2 - 2
README.md

@@ -7,8 +7,8 @@ A J-RPG engine for the TI-Nspire. There's still a lot of work before anything wo
 The build system currently depends on Vogtinator's [ConvertImg](https://github.com/Vogtinator/ConvertImg),
 as well as GNU Make and the Ndless toolchain.
 
-We use the [tinystl](https://github.com/mendley/tinystl) library to keep binaries small, so be
-sure to install the headers into your ~/.ndless/include directory.
+We use the [tinystl](https://github.com/mendsley/tinystl) library to keep binaries small, so be
+sure to clone the submodules as well !
 
 To compile the project, simply run make (-j friendly).
 

+ 1 - 0
external/tinystl

@@ -0,0 +1 @@
+Subproject commit 35b11da8e1a5a264e85f46915fc3b93466ee2575