Skip to content

Commit 1b300e6

Browse files
authored
Add klystron as a git submodule (kometbomb#245)
1 parent 85df204 commit 1b300e6

File tree

4 files changed

+14
-7
lines changed

4 files changed

+14
-7
lines changed

.circleci/config.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ jobs:
55
- image: gcc:8
66
steps:
77
- run: apt-get update && apt-get install -y zip libsdl2-dev libsdl2-image-dev
8-
- run: git clone https://github.com/kometbomb/klystron.git
9-
- run: git clone https://github.com/kometbomb/klystrack.git && cd klystrack && git checkout $CIRCLE_BRANCH
10-
- run: cd klystrack && make CC=gcc CFG=release RES_PATH=.
11-
- run: cd klystrack && zip -j /tmp/klystrack-linux64.zip bin.release/klystrack doc/Default.kt && zip -r /tmp/klystrack-linux64.zip res key examples LICENSE doc/SDL.txt doc/SDL_image.txt
8+
- checkout
9+
- run: git submodule init && git submodule update --remote
10+
- run: make CC=gcc CFG=release RES_PATH=.
11+
- run: zip -j /tmp/klystrack-linux64.zip bin.release/klystrack doc/Default.kt && zip -r /tmp/klystrack-linux64.zip res key examples LICENSE doc/SDL.txt doc/SDL_image.txt
1212
#- run: cd klystrack && make clean
1313
#- run: SDL_ROOT_DIR=/usr/x86_64-win32-mingw32 COMSPEC=1 && cd klystrack && make CC=x86_64-win32-mingw32-gcc CFG=release RES_PATH=.
1414
#- run: cd klystrack && zip -j /tmp/klystrack-win32.zip bin.release/klystrack doc/Default.kt && zip -r /tmp/klystrack-win32.zip res key examples LICENSE doc/SDL.txt doc/SDL_image.txt

.gitmodules

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[submodule "klystron"]
2+
path = klystron
3+
url = https://github.com/kometbomb/klystron.git

Makefile

+6-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
TARGET := klystrack
2-
KLYSTRON=../klystron
2+
KLYSTRON=klystron
33
ECHO := echo
44
CFG := debug
55
MACHINE :=
@@ -19,7 +19,7 @@ SDL_IMAGEVER := 2.0.3
1919
THEMES :=
2020
REV := cp -f
2121

22-
CFLAGS := $(MACHINE) -ftree-vectorize -std=gnu99 --no-strict-aliasing -Werror
22+
CFLAGS := $(MACHINE) -ftree-vectorize -std=gnu99 -Wno-strict-aliasing -Werror
2323

2424
ifdef COMSPEC
2525
TARGET := $(TARGET).exe
@@ -46,7 +46,7 @@ else
4646
CONFIG_PATH := ~/.klystrack
4747
endif
4848

49-
EXTFLAGS := -DNOSDL_MIXER -DUSESDLMUTEXES -DENABLEAUDIODUMP -DSTEREOOUTPUT -DUSESDL_IMAGE $(EXTFLAGS)
49+
EXTFLAGS := -DNOSDL_MIXER -DUSESDLMUTEXES -DENABLEAUDIODUMP -DSTEREOOUTPUT -DUSESDL_IMAGE $(EXTFLAGS) $(CFLAGS)
5050
LDFLAGS := -L $(KLYSTRON)/bin.$(CFG) -lengine_gfx -lengine_util -lengine_snd -lengine_gui -lm $(SDLLIBS)
5151
INCLUDEFLAGS := -I src $(SDLFLAGS) -I $(KLYSTRON)/src -L$(KLYSTRON)/bin.$(CFG) -DRES_PATH="$(RES_PATH)" -DCONFIG_PATH="$(CONFIG_PATH)" $(EXTFLAGS) -DKLYSTRON=$(KLYSTRON)
5252

@@ -77,6 +77,8 @@ else
7777
endif
7878
endif
7979

80+
CFLAGS += -Wno-strict-aliasing
81+
8082
# $(1) = subdir, $(2) = filename prefix (i.e. subdir without a slash)
8183
define directory_defs
8284
SRC := $$(notdir $$(wildcard src/$(value 1)/*$(EXT)))
@@ -200,6 +202,7 @@ nightly: zip
200202
@cp zip/$(ARCHIVE) zip/klystrack-nightly-`date +"%Y%m%d" | tr -d '\n'`-win32.zip
201203

202204
clean:
205+
make -C klystron clean
203206
@rm -rf deps objs.debug objs.release objs.profile bin.release bin.debug bin.profile zip temp res
204207

205208
bin.$(CFG)/$(TARGET): $(OBJS)

klystron

Submodule klystron added at a8e55d1

0 commit comments

Comments
 (0)