Libretro: Fixes ogg crashes on static platforms (#757)

This commit is contained in:
Samuel P 2020-01-30 02:10:52 +01:00 committed by GitHub
parent 06ccf0bdb0
commit 0279db31d2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -306,6 +306,15 @@ else
LD = $(CXX)
endif
CONFLICTING_NAMES=std_vorbis std_vorbis_close stb_vorbis_open_memory stb_vorbis_get_info \
stb_vorbis_seek stb_vorbis_get_samples_short_interleaved stb_vorbis_seek_start \
stb_vorbis_get_file_offset
ifeq ($(STATIC_LINKING),1)
PREFIX_DEFINES := $(foreach name,$(CONFLICTING_NAMES),-D$(name)=core_$(name))
CFLAGS += $(PREFIX_DEFINES)
CXXFLAGS += $(PREFIX_DEFINES)
endif
include Makefile.common
OBJECTS := $(SOURCES_C:.c=.o) $(SOURCES_CXX:.cpp=.o)