Commit d2080f5b authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen

modules: Don't enforce linkage to -lole32

parent 2a42e0b7
......@@ -308,13 +308,16 @@ AC_ARG_ENABLE(winstore_app,
vlc_winstore_app=0
AS_IF([test "${SYS}" = "mingw32"],[
LIBCOM="-lole32"
AS_IF([test "${enable_winstore_app}" = "yes"], [
vlc_winstore_app=1
LIBCOM=""
VLC_ADD_LIBS([libvlccore], [-lruntimeobject])
AC_LIBOBJ([gai_strerror])
],[
VLC_ADD_LIBS([libvlccore],[-lwinmm])
])
AC_SUBST(LIBCOM)
])
AC_DEFINE_UNQUOTED(VLC_WINSTORE_APP, ${vlc_winstore_app}, [Define to 1 if you want to build for Windows Store apps])
......
......@@ -109,7 +109,7 @@ access_LTLIBRARIES += $(LTLIBaccess_qtsound)
EXTRA_LTLIBRARIES += libaccess_qtsound_plugin.la
libaccess_wasapi_plugin_la_SOURCES = access/wasapi.c
libaccess_wasapi_plugin_la_LIBADD = -lole32 -lksuser
libaccess_wasapi_plugin_la_LIBADD = $(LIBCOM) -lksuser
if HAVE_WASAPI
if !HAVE_WINSTORE
access_LTLIBRARIES += libaccess_wasapi_plugin.la
......@@ -186,7 +186,7 @@ endif
libdshow_plugin_la_SOURCES = access/dshow/vlc_dshow.h access/dshow/dshow.cpp access/dshow/access.h \
access/dshow/filter.cpp access/dshow/filter.h access/dshow/crossbar.cpp
libdshow_plugin_la_LIBADD = -lole32 -loleaut32 -luuid -lstrmiids -lksuser
libdshow_plugin_la_LIBADD = $(LIBCOM) -loleaut32 -luuid -lstrmiids -lksuser
if HAVE_WIN32_DESKTOP
access_LTLIBRARIES += libdshow_plugin.la
endif
......@@ -315,7 +315,7 @@ if HAVE_WIN32_DESKTOP
# Use an import library for C++ to retain C linker on other platforms.
libbda_la_SOURCES = access/dtv/bdadefs.h access/dtv/bdagraph.cpp access/dtv/bdagraph.hpp
libbda_la_LDFLAGS = -static
libbda_la_LIBADD = -lstrmiids -lole32 -loleaut32 -luuid
libbda_la_LIBADD = -lstrmiids $(LIBCOM) -loleaut32 -luuid
noinst_LTLIBRARIES += libbda.la
libdtv_plugin_la_DEPENDENCIES = libbda.la
......
......@@ -58,11 +58,11 @@ aout_LTLIBRARIES += libjack_plugin.la
endif
libmmdevice_plugin_la_SOURCES = audio_output/mmdevice.c audio_output/mmdevice.h
libmmdevice_plugin_la_LIBADD = -lole32 $(LIBM)
libmmdevice_plugin_la_LIBADD = $(LIBCOM) $(LIBM)
libwinstore_plugin_la_SOURCES = audio_output/winstore.c audio_output/mmdevice.h
libwinstore_plugin_la_LIBADD = -lole32
libwinstore_plugin_la_LIBADD = $(LIBCOM)
libwasapi_plugin_la_SOURCES = audio_output/wasapi.c
libwasapi_plugin_la_LIBADD = -lole32 -lksuser
libwasapi_plugin_la_LIBADD = $(LIBCOM) -lksuser
if HAVE_WASAPI
aout_LTLIBRARIES += libwasapi_plugin.la
if !HAVE_WINSTORE
......@@ -74,7 +74,7 @@ endif
libdirectsound_plugin_la_SOURCES = audio_output/directsound.c \
audio_output/windows_audio_common.h
libdirectsound_plugin_la_LIBADD = -lole32
libdirectsound_plugin_la_LIBADD = $(LIBCOM)
if HAVE_WIN32_DESKTOP
aout_LTLIBRARIES += libdirectsound_plugin.la
endif
......
......@@ -377,7 +377,7 @@ libdxva2_plugin_la_SOURCES = \
codec/avcodec/dxva2.c codec/avcodec/directx_va.c codec/avcodec/directx_va.h \
packetizer/h264_nal.c packetizer/h264_nal.h \
packetizer/hevc_nal.c packetizer/hevc_nal.h
libdxva2_plugin_la_LIBADD = -lole32 -lshlwapi -luuid
libdxva2_plugin_la_LIBADD = $(LIBCOM) -lshlwapi -luuid
if HAVE_AVCODEC_DXVA2
codec_LTLIBRARIES += libdxva2_plugin.la
endif
......@@ -387,7 +387,7 @@ libd3d11va_plugin_la_SOURCES = \
video_chroma/dxgi_fmt.c video_chroma/dxgi_fmt.h \
packetizer/h264_nal.c packetizer/h264_nal.h \
packetizer/hevc_nal.c packetizer/hevc_nal.h
libd3d11va_plugin_la_LIBADD = -lole32 -luuid
libd3d11va_plugin_la_LIBADD = $(LIBCOM) -luuid
if HAVE_WINSTORE
libd3d11va_plugin_la_LIBADD += -ld3d11
endif
......@@ -547,13 +547,13 @@ libdmo_plugin_la_SOURCES = codec/dmo/dmo.c codec/dmo/dmo.h codec/dmo/buffer.c
libqsv_plugin_la_CPPFLAGS = $(AM_CPPFLAGS)
libdmo_plugin_la_LIBADD = $(LIBM)
if HAVE_WIN32
libdmo_plugin_la_LIBADD += -lole32 -luuid
libdmo_plugin_la_LIBADD += $(LIBCOM) -luuid
codec_LTLIBRARIES += libdmo_plugin.la
endif
libmft_plugin_la_SOURCES = codec/mft.c packetizer/h264_nal.c packetizer/h264_nal.h
if HAVE_WIN32
libmft_plugin_la_LIBADD = -lole32 -luuid -lmfuuid -lmfplat
libmft_plugin_la_LIBADD = $(LIBCOM) -luuid -lmfuuid -lmfplat
codec_LTLIBRARIES += libmft_plugin.la
endif
......
......@@ -20,7 +20,7 @@ libqt_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(guidir)'
if HAVE_OS2
else
if HAVE_WIN32
libqt_plugin_la_LIBADD += -lole32 -lcomctl32 -luuid
libqt_plugin_la_LIBADD += $(LIBCOM) -lcomctl32 -luuid
else
libqt_plugin_la_LIBADD += $(X_LIBS) $(X_PRE_LIB) -lX11
endif
......
......@@ -57,7 +57,7 @@ endif
# SAPI TTS (win32)
libsapi_plugin_la_SOURCES = text_renderer/sapi.cpp
libsapi_plugin_la_LIBADD = -lole32
libsapi_plugin_la_LIBADD = $(LIBCOM)
if HAVE_SAPI
text_LTLIBRARIES += libsapi_plugin.la
endif
......@@ -163,7 +163,7 @@ libdirect2d_plugin_la_SOURCES = video_output/win32/direct2d.c \
video_output/win32/win32touch.c video_output/win32/win32touch.h
libdirect2d_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
-DMODULE_NAME_IS_direct2d
libdirect2d_plugin_la_LIBADD = -lgdi32 -lole32 -luuid
libdirect2d_plugin_la_LIBADD = -lgdi32 $(LIBCOM) -luuid
libdirect2d_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
if HAVE_WIN32_DESKTOP
vout_LTLIBRARIES += $(LTLIBdirect2d)
......@@ -177,7 +177,7 @@ libdirect3d9_plugin_la_SOURCES = video_output/win32/direct3d9.c \
video_output/win32/win32touch.c video_output/win32/win32touch.h
libdirect3d9_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
-DMODULE_NAME_IS_direct3d9
libdirect3d9_plugin_la_LIBADD = -lgdi32 -lole32 -luuid
libdirect3d9_plugin_la_LIBADD = -lgdi32 $(LIBCOM) -luuid
libdirect3d9_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
if HAVE_WIN32_DESKTOP
vout_LTLIBRARIES += $(LTLIBdirect3d9)
......@@ -193,9 +193,9 @@ if !HAVE_WINSTORE
libdirect3d11_plugin_la_SOURCES += video_output/win32/events.c \
video_output/win32/events.h \
video_output/win32/win32touch.c video_output/win32/win32touch.h
libdirect3d11_plugin_la_LIBADD = -lgdi32 -lole32 -luuid
libdirect3d11_plugin_la_LIBADD = -lgdi32 $(LIBCOM) -luuid
else
libdirect3d11_plugin_la_LIBADD = -ld3dcompiler_47 -lole32 -luuid
libdirect3d11_plugin_la_LIBADD = -ld3dcompiler_47 $(LIBCOM) -luuid
endif
libdirect3d11_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
vout_LTLIBRARIES += $(LTLIBdirect3d11)
......@@ -207,7 +207,7 @@ libdirectdraw_plugin_la_SOURCES = video_output/win32/directdraw.c \
video_output/win32/win32touch.c video_output/win32/win32touch.h
libdirectdraw_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
-DMODULE_NAME_IS_directdraw
libdirectdraw_plugin_la_LIBADD = -luser32 -lgdi32 -lole32 -luuid
libdirectdraw_plugin_la_LIBADD = -luser32 -lgdi32 $(LIBCOM) -luuid
libdirectdraw_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
if HAVE_WIN32_DESKTOP
vout_LTLIBRARIES += $(LTLIBdirectdraw)
......@@ -227,7 +227,7 @@ libglwin32_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
libwgl_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
-DMODULE_NAME_IS_wgl
libglwin32_plugin_la_LIBADD = -lopengl32 -lgdi32 -lole32 -luuid
libglwin32_plugin_la_LIBADD = -lopengl32 -lgdi32 $(LIBCOM) -luuid
libwgl_plugin_la_LIBADD = -lopengl32 -lgdi32
libglwin32_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
......@@ -244,7 +244,7 @@ libwingdi_plugin_la_SOURCES = video_output/win32/wingdi.c \
video_output/win32/win32touch.c video_output/win32/win32touch.h
libwingdi_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
-DMODULE_NAME_IS_wingdi
libwingdi_plugin_la_LIBADD = -lgdi32 -lole32 -luuid
libwingdi_plugin_la_LIBADD = -lgdi32 $(LIBCOM) -luuid
if HAVE_WIN32_DESKTOP
vout_LTLIBRARIES += libwingdi_plugin.la
endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment