Skip to content

Commit

Permalink
build: fix missing libogg for web build
Browse files Browse the repository at this point in the history
  • Loading branch information
connorjclark committed Dec 10, 2023
1 parent 8da0127 commit a5254ef
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 25 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Expand Up @@ -184,7 +184,7 @@ set(MINIMP3_INCLUDE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/include/minimp3)
FetchContent_Declare(
allegro5
GIT_REPOSITORY https://github.com/connorjclark/allegro5.git
GIT_TAG be8afe0e5225b54e64d0df708744c8384645a490
GIT_TAG 08e0f7cb4793f1d86be30629f724324325be5b24
)
FetchContent_GetProperties(allegro5)
if(NOT allegro5_POPULATED)
Expand Down
2 changes: 2 additions & 0 deletions scripts/configure_emscripten.sh
Expand Up @@ -132,6 +132,8 @@ embuilder build sdl2

embuilder build libpng libpng-mt

embuilder build ogg vorbis

emcmake cmake \
-G "Ninja Multi-Config" \
-D ALLEGRO_SDL=ON \
Expand Down
24 changes: 0 additions & 24 deletions web/patches/allegro5.patch
Expand Up @@ -14,30 +14,6 @@ index 777324259..636d7d381 100644
want.callback = audio_callback;
want.userdata = sv;

diff --git a/cmake/FindVorbis.cmake b/cmake/FindVorbis.cmake
index a08e0e4c6..48654b5e4 100644
--- a/cmake/FindVorbis.cmake
+++ b/cmake/FindVorbis.cmake
@@ -25,16 +25,16 @@ if(OGG_FOUND)
set(FPHSA_NAME_MISMATCHED TRUE)
find_package_handle_standard_args(VORBIS DEFAULT_MSG
VORBIS_INCLUDE_DIR
- VORBIS_LIBRARY VORBISFILE_LIBRARY)
+ VORBIS_LIBRARY)
endif(OGG_FOUND)

if(VORBIS_FOUND)
- set(VORBIS_LIBRARIES ${VORBISFILE_LIBRARY} ${VORBIS_LIBRARY}
+ set(VORBIS_LIBRARIES ${VORBIS_LIBRARY}
${OGG_LIBRARY})
else(VORBIS_FOUND)
set(VORBIS_LIBRARIES)
endif(VORBIS_FOUND)

mark_as_advanced(VORBIS_INCLUDE_DIR)
-mark_as_advanced(VORBIS_LIBRARY VORBISFILE_LIBRARY)
+mark_as_advanced(VORBIS_LIBRARY VORBIS_LIBRARY)

diff --git a/src/sdl/sdl_display.c b/src/sdl/sdl_display.c
index 12fc8f14d..afbe4703d 100644
--- a/src/sdl/sdl_display.c
Expand Down

0 comments on commit a5254ef

Please sign in to comment.