From e01daea353e129884942463d37d38a76d9b92400 Mon Sep 17 00:00:00 2001 From: nesbox Date: Fri, 21 Sep 2018 17:41:09 +0300 Subject: [PATCH] sokol demo moved to the examples dir --- CMakeLists.txt | 8 +++----- examples/makefile | 23 ----------------------- examples/{sdl-renderer.c => sdl/main.c} | 0 {sokol => examples/sokol}/main.c | 0 {sokol => examples/sokol}/sokol.m | 0 5 files changed, 3 insertions(+), 28 deletions(-) delete mode 100644 examples/makefile rename examples/{sdl-renderer.c => sdl/main.c} (100%) rename {sokol => examples/sokol}/main.c (100%) rename {sokol => examples/sokol}/sokol.m (100%) diff --git a/CMakeLists.txt b/CMakeLists.txt index ae037fc..adfafa3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -203,7 +203,7 @@ endif() if(NOT EMSCRIPTEN) set(EXAMPLE_DIR examples) set(EXAMPLE_SRC - ${EXAMPLE_DIR}/sdl-renderer.c + ${EXAMPLE_DIR}/sdl/main.c ) if(WIN32) @@ -228,15 +228,13 @@ endif() # Sokol renderer example ################################ -set(SOKOL_DIR sokol) - set(SOKOL_SRC - ${SOKOL_DIR}/main.c + ${EXAMPLE_DIR}/sokol/main.c ) if(APPLE) add_definitions(-DSOKOL_METAL) - set(SOKOL_SRC ${SOKOL_SRC} ${SOKOL_DIR}/sokol.m) + set(SOKOL_SRC ${SOKOL_SRC} ${EXAMPLE_DIR}/sokol/sokol.m) endif() add_executable(sokol ${SOKOL_SRC}) diff --git a/examples/makefile b/examples/makefile deleted file mode 100644 index 17b4405..0000000 --- a/examples/makefile +++ /dev/null @@ -1,23 +0,0 @@ -CC=gcc -OPT=-O3 -Wall -std=c99 -INCLUDES= \ - -I../include \ - -I../include/sdl2 \ - -I../include/tic80 - -LINKER_FLAGS= \ - -L../lib/mingw \ - -L../bin \ - -ltic80 \ - -lmingw32 -lSDL2main -lSDL2.dll \ - -mwindows - -SOURCES=\ - sdl-renderer.c - -SDL_RENDERER = ../bin/sdl-renderer.exe - -all: $(SDL_RENDERER) - -$(SDL_RENDERER): $(SOURCES) - $(CC) $(INCLUDES) $< $(OPT) $(LINKER_FLAGS) -o $@ diff --git a/examples/sdl-renderer.c b/examples/sdl/main.c similarity index 100% rename from examples/sdl-renderer.c rename to examples/sdl/main.c diff --git a/sokol/main.c b/examples/sokol/main.c similarity index 100% rename from sokol/main.c rename to examples/sokol/main.c diff --git a/sokol/sokol.m b/examples/sokol/sokol.m similarity index 100% rename from sokol/sokol.m rename to examples/sokol/sokol.m