Skip to content

Commit

Permalink
Reset git tree before generate/build
Browse files Browse the repository at this point in the history
  • Loading branch information
smoogipoo committed Sep 18, 2024
1 parent e207e72 commit a035dd9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
1 change: 1 addition & 0 deletions External/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ fi

# Build SDL
pushd SDL >/dev/null
git reset --hard HEAD
cmake -B build $FLAGS -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DSDL_SHARED_ENABLED_BY_DEFAULT=ON -DSDL_STATIC_ENABLED_BY_DEFAULT=ON
cmake --build build/ --config Release
$SUDO cmake --install build/ --prefix install_output --config Release
Expand Down
11 changes: 9 additions & 2 deletions SDL3-CS/generate_bindings.py
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,14 @@ def add(s: str):
add("SDL3/SDL_vulkan.h"),
]

def patch_sdl_types():
def prepare_sdl_source():
subprocess.run([
"git",
"reset",
"--hard",
"HEAD"
], cwd = SDL_root)

subprocess.run([
"git",
"apply",
Expand Down Expand Up @@ -298,7 +305,7 @@ def get_string_returning_functions(sdl_api):


def main():
patch_sdl_types()
prepare_sdl_source()

sdl_api = get_sdl_api_dump()

Expand Down

0 comments on commit a035dd9

Please sign in to comment.