Commit 19bed424 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Generate Windows resource file on need basis

parent 4ca436a5
...@@ -4,6 +4,9 @@ bin_PROGRAMS = vlc ...@@ -4,6 +4,9 @@ bin_PROGRAMS = vlc
noinst_PROGRAMS = vlc-static noinst_PROGRAMS = vlc-static
vlclib_PROGRAMS = vlc-cache-gen vlclib_PROGRAMS = vlc-cache-gen
EXTRA_PROGRAMS = vlc-wrapper EXTRA_PROGRAMS = vlc-wrapper
EXTRA_DIST = vlc_win32_rc.rc.in
SUFFIXES = .rc.in .rc
AM_CFLAGS = `$(VLC_CONFIG) --cflags vlc` AM_CFLAGS = `$(VLC_CONFIG) --cflags vlc`
...@@ -18,6 +21,7 @@ endif ...@@ -18,6 +21,7 @@ endif
EXTRA_vlc_SOURCES = vlc.c winvlc.c EXTRA_vlc_SOURCES = vlc.c winvlc.c
if HAVE_WIN32 if HAVE_WIN32
vlc_SOURCES = winvlc.c vlc_SOURCES = winvlc.c
noinst_DATA = vlc_win32_rc.rc
endif endif
if HAVE_WINCE if HAVE_WINCE
vlc_SOURCES = winvlc.c vlc_SOURCES = winvlc.c
...@@ -44,7 +48,11 @@ vlc_LDADD += -lwininet vlc_win32_rc.$(OBJEXT) ...@@ -44,7 +48,11 @@ vlc_LDADD += -lwininet vlc_win32_rc.$(OBJEXT)
vlc_DEPENDENCIES += vlc_win32_rc.$(OBJEXT) vlc_DEPENDENCIES += vlc_win32_rc.$(OBJEXT)
endif endif
vlc_win32_rc.$(OBJEXT): $(top_builddir)/share/vlc_win32_rc.rc .rc.in.rc: $(top_builddir)/config.status
cd "$(top_builddir)" && \
$(SHELL) ./config.status --file="bin/$@"
vlc_win32_rc.$(OBJEXT): vlc_win32_rc.rc
$(WINDRES) --include-dir $(top_srcdir)/share -i $< -o $@ $(WINDRES) --include-dir $(top_srcdir)/share -i $< -o $@
vlc_cache_gen_SOURCES = cachegen.c vlc_cache_gen_SOURCES = cachegen.c
......
...@@ -4935,8 +4935,6 @@ AC_CONFIG_FILES([ ...@@ -4935,8 +4935,6 @@ AC_CONFIG_FILES([
projects/mozilla/vlc.r projects/mozilla/vlc.r
projects/mozilla/install.js projects/mozilla/install.js
share/Makefile share/Makefile
share/vlc_win32_rc.rc
share/libvlc_win32_rc.rc
compat/Makefile compat/Makefile
src/Makefile src/Makefile
src/test/Makefile src/test/Makefile
......
...@@ -55,9 +55,7 @@ DIST_rsrc = \ ...@@ -55,9 +55,7 @@ DIST_rsrc = \
newres.h \ newres.h \
resource.h \ resource.h \
vlc_wince_rc.rc \ vlc_wince_rc.rc \
vlc_beos.rsrc \ vlc_beos.rsrc
vlc_win32_rc.rc.in \
libvlc_win32_rc.rc.in
DIST_icons = vlc.ico DIST_icons = vlc.ico
......
...@@ -16,7 +16,7 @@ EXTRA_DIST = extras/COPYING \ ...@@ -16,7 +16,7 @@ EXTRA_DIST = extras/COPYING \
BUILT_SOURCES = ../include/vlc_about.h BUILT_SOURCES = ../include/vlc_about.h
CLEANFILES = $(BUILT_SOURCES) CLEANFILES = $(BUILT_SOURCES)
SUFFIXES = .pc.in .pc SUFFIXES = .pc.in .pc .rc.in .rc
############################################################################### ###############################################################################
# Headers # Headers
...@@ -157,6 +157,19 @@ CLEANFILES += $(pkgconfig_DATA) ...@@ -157,6 +157,19 @@ CLEANFILES += $(pkgconfig_DATA)
cd "$(top_builddir)" && \ cd "$(top_builddir)" && \
$(SHELL) ./config.status --file="src/$@" $(SHELL) ./config.status --file="src/$@"
##############################################################################
# Windows resource files
##############################################################################
if HAVE_WIN32
noinst_DATA = libvlc_win32_rc.rc
endif
EXTRA_DIST += libvlc_win32_rc.rc.in
.rc.in.rc: $(top_builddir)/config.status
cd "$(top_builddir)" && \
$(SHELL) ./config.status --file="src/$@"
############################################################################### ###############################################################################
# Building libvlc # Building libvlc
############################################################################### ###############################################################################
...@@ -195,7 +208,7 @@ libvlccore_la_DEPENDENCIES += libvlc_win32_rc.$(OBJEXT) ...@@ -195,7 +208,7 @@ libvlccore_la_DEPENDENCIES += libvlc_win32_rc.$(OBJEXT)
libvlccore_la_LDFLAGS += -Wl,libvlc_win32_rc.$(OBJEXT) libvlccore_la_LDFLAGS += -Wl,libvlc_win32_rc.$(OBJEXT)
endif endif
libvlc_win32_rc.$(OBJEXT): $(top_builddir)/share/libvlc_win32_rc.rc libvlc_win32_rc.$(OBJEXT): libvlc_win32_rc.rc
$(WINDRES) --include-dir $(top_srcdir)/share -i $< -o $@ $(WINDRES) --include-dir $(top_srcdir)/share -i $< -o $@
libvlc_la_SOURCES = $(SOURCES_libvlc_control) libvlc_la_SOURCES = $(SOURCES_libvlc_control)
......
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