mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-31 05:09:12 +00:00
LibMedia: Don't link null PlaybackStream::create eagerly
This avoids static builds putting the "no-op" implementation of PlaybackStream::create() in the static archive before the strong implementation later. On ELF (and probably PE/COFF too), a weak definition in a static archive is chosen and locked-in as the definition before a strong definition later in the archive. Before this change, static builds would have no audio support at all.
This commit is contained in:
parent
d64566f19e
commit
b7f7f58e5f
Notes:
github-actions[bot]
2025-02-21 11:06:25 +00:00
Author: https://github.com/ADKaster
Commit: b7f7f58e5f
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3321
Reviewed-by: https://github.com/gmta ✅
1 changed files with 2 additions and 1 deletions
|
@ -6,7 +6,6 @@ endif()
|
|||
|
||||
set(SOURCES
|
||||
Audio/Loader.cpp
|
||||
Audio/PlaybackStream.cpp
|
||||
Audio/SampleFormats.cpp
|
||||
Color/ColorConverter.cpp
|
||||
Color/ColorPrimaries.cpp
|
||||
|
@ -47,4 +46,6 @@ elseif (LADYBIRD_AUDIO_BACKEND STREQUAL "OBOE")
|
|||
target_link_libraries(LibMedia PRIVATE log oboe::oboe)
|
||||
elseif (DEFINED LADYBIRD_AUDIO_BACKEND)
|
||||
message(FATAL_ERROR "Please update ${CMAKE_CURRENT_LIST_FILE} for audio backend ${LADYBIRD_AUDIO_BACKEND}")
|
||||
else ()
|
||||
target_sources(LibMedia PRIVATE Audio/PlaybackStream.cpp)
|
||||
endif()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue