Skip to content

Commit 711a5d9

Browse files
committed
small changes
1 parent 1850486 commit 711a5d9

9 files changed

Lines changed: 45 additions & 9 deletions

File tree

.github/workflows/android.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,13 @@ jobs:
2929
submodules: recursive
3030
fetch-depth: 0 # fetch full history including tags
3131

32+
- name: Checkout Data Repo
33+
uses: actions/checkout@v6
34+
with:
35+
repository: cfrankb/cs3-data-private
36+
path: data
37+
token: ${{ secrets.CS3_REPO_TOKEN }} # Only if internal access is enabled
38+
3239
- name: Update build information
3340
run: |
3441
bin/setbuild.sh

.github/workflows/appImage-build.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,13 @@ jobs:
2929
submodules: recursive
3030
fetch-depth: 0 # fetch full history including tags
3131

32+
- name: Checkout Data Repo
33+
uses: actions/checkout@v6
34+
with:
35+
repository: cfrankb/cs3-data-private
36+
path: data
37+
token: ${{ secrets.CS3_REPO_TOKEN }} # Only if internal access is enabled
38+
3239
- name: Update build information
3340
run: |
3441
bin/setbuild.sh

.github/workflows/deb-package.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,13 @@ jobs:
2323
submodules: recursive
2424
fetch-depth: 0 # fetch full history including tags
2525

26+
- name: Checkout Data Repo
27+
uses: actions/checkout@v6
28+
with:
29+
repository: cfrankb/cs3-data-private
30+
path: data
31+
token: ${{ secrets.CS3_REPO_TOKEN }} # Only if internal access is enabled
32+
2633
- name: Update build information
2734
run: |
2835
bin/setbuild.sh

.github/workflows/macos.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,13 @@ jobs:
2525
submodules: recursive
2626
fetch-depth: 0 # fetch full history including tags
2727

28+
- name: Checkout Data Repo
29+
uses: actions/checkout@v6
30+
with:
31+
repository: cfrankb/cs3-data-private
32+
path: data
33+
token: ${{ secrets.CS3_REPO_TOKEN }} # Only if internal access is enabled
34+
2835
- name: Update build information
2936
run: |
3037
bin/setbuild.sh

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ local/*
1414
setup/*
1515
bb/*
1616
data/*
17+
data
1718
#VERSION
1819
#/CMakeLists.txt
1920
levels2.mapz

CMakeLists.txt

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ if(CMAKE_C_COMPILER MATCHES "x86_64-w64-mingw32.*")
99
endif()
1010

1111

12-
if(EMSCRIPTEN)
12+
if(CMAKE_SYSTEM_NAME STREQUAL "Emscripten")
1313
message(STATUS "Targeting Emscripten/WebAssembly ${CMAKE_SOURCE_DIR}")
1414
set(CMAKE_EXECUTABLE_SUFFIX ".html") # Optional: .html shell
1515
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -sUSE_SDL=0 -O3 -sUSE_ZLIB=1 ")
@@ -43,7 +43,8 @@ endif()
4343
add_subdirectory(src)
4444

4545
# Add External
46-
if(EMSCRIPTEN)
46+
#if(EMSCRIPTEN)
47+
if(CMAKE_SYSTEM_NAME STREQUAL "Emscripten")
4748
set(SDLMIXER_MOD_XMP ON CACHE BOOL "Enable libxmp module support")
4849
set(SDLMIXER_VENDORED ON CACHE BOOL "Use vendored libxmp")
4950
elseif(IS_MINGW)
@@ -58,6 +59,11 @@ elseif(IS_MINGW)
5859
#cmake --build build/mingw --target help
5960
endif()
6061

62+
if(CMAKE_SYSTEM_NAME STREQUAL "Emscripten")
63+
# Emscripten-specific setup
64+
else()
65+
# Non-Emscripten setup
66+
endif()
6167
add_subdirectory(external/SDL3 SDL3)
6268
add_subdirectory(external/SDL3_mixer SDL3_mixer)
6369

@@ -71,7 +77,8 @@ add_executable(${PROJECT_NAME} src/main.cpp)
7177
#add_subdirectory(tests)
7278

7379

74-
if(EMSCRIPTEN)
80+
#if(EMSCRIPTEN)
81+
if(CMAKE_SYSTEM_NAME STREQUAL "Emscripten")
7582
set(BPATH "${CMAKE_CURRENT_BINARY_DIR}")
7683
set(DATA_SRC "${CMAKE_SOURCE_DIR}/data")
7784
set(DATA_DST "${BPATH}/ems_data")
@@ -106,6 +113,7 @@ if(EMSCRIPTEN)
106113
-sASYNCIFY
107114
-sEXPORTED_RUNTIME_METHODS=ccall,cwrap
108115
-sEXPORTED_FUNCTIONS=_main,_malloc,_free
116+
#-sUSE_WEBGPU=1
109117
)
110118
target_link_libraries(${PROJECT_NAME}
111119
PRIVATE SDL3::SDL3 SDL3_mixer::SDL3_mixer src_lib

bin/build.sh

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,18 +30,16 @@ elif [[ "$1" == "run_ems" ]] ; then
3030
elif [[ "$1" == "clean" ]] ; then
3131
rm -rf build
3232
elif [[ "$1" == "bosses" ]] ; then
33-
DEST=/home/cfrankb/toolkit/gcc/cs3-runtime-sdl/data/pixels
33+
#DEST=/home/cfrankb/toolkit/gcc/cs3-runtime-sdl/data/pixels
34+
DEST=${PWD}/data/pixels
3435
cd techdocs/bosses
3536
python parse.py
3637
cd ../..
3738
cd tools/sheet
3839
make && build/sheet config/bosses.txt
3940
make && build/sheet config/beholder1.txt
40-
#build/sheet config/beholder1.txt
41-
#cp out/bosses.png ../../data/pixels/sheet0.obl
42-
#cp out/beholder1.png ../../data/pixels/sheet1.obl
4341
cp out/bosses.png ${DEST}/sheet0.obl
44-
cp out/beholder1.png ${DEST}//sheet1.obl
42+
cp out/beholder1.png ${DEST}/sheet1.obl
4543
elif [[ "$1" == "tests" ]] ; then
4644
cmake -S . -B build
4745
cmake --build build --target cs3-tests

src/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
**/CMakeLists.txt

src/shared/implementers/mu_sdl.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ class CMusicSDL : public IMusic
5858
MusicData m_data; // Background Music
5959
uint8_t m_type = TYPE_NONE;
6060
bool m_playing = false;
61-
#if defined(EMSCRIPTEN)
61+
#if defined(__EMSCRIPTEN__)
6262
std::string m_filepath;
6363
#endif
6464
};

0 commit comments

Comments
 (0)