Commit de1be1c1 authored by Gildas Bazin's avatar Gildas Bazin

* Makefile.am, bootstrap, mozilla/Makefile.am: don't try to build pic _and_...

* Makefile.am, bootstrap, mozilla/Makefile.am: don't try to build pic _and_ non-pic code on win32 as there's no need for pic code on this platform. This should almost reduce the compilation time by a factor of 2 when the mozilla plugin is activated in the build process.
parent a51b1992
......@@ -253,8 +253,10 @@ if BUILD_GETOPT
OPT_SOURCES_libvlc_getopt = $(SOURCES_libvlc_getopt)
endif
if BUILD_MOZILLA
if !HAVE_WIN32
LIBRARIES_libvlc_pic = lib/libvlc_pic.a
endif
endif
EXTRA_DIST += \
$(SOURCES_libvlc_beos) \
......
#! /bin/sh
## bootstrap file for the VLC media player
## $Id: bootstrap,v 1.72 2003/10/07 21:13:01 sam Exp $
## $Id: bootstrap,v 1.73 2003/10/20 10:37:56 gbazin Exp $
##
## Authors: Sam Hocevar <sam@zoy.org>
......@@ -90,6 +90,12 @@ SUBDIRS = ${subdirs}
libvlcdir = \$(libdir)/vlc/${basedir}
include Modules.am
if HAVE_WIN32
# There's no need for pic code on win32 so get rid of this to substantially
# reduce the compilation time.
pic = no
endif
clean: clean-local
clean-local:
-rm -f *.a *.so *.dll *.sl *.dylib
......
......@@ -27,6 +27,7 @@ if HAVE_WIN32
LIBRARIES_mozilla = npvlc$(LIBEXT)
SOURCES_win32 = support/npwin.cpp
CPPFLAGS_mozilla_EXTRA = -DXP_WIN -DXP_WIN32
LIBRARIES_libvlc = $(top_builddir)/lib/libvlc.a
else
if HAVE_DARWIN
# We don't define LIBRARIES_mozilla because we'll be using project builder, or not...
......@@ -35,10 +36,14 @@ BUNDLE_mozilla = VLC\ Plugin.plugin
vlc_moz_FLAGS = `$(VLC_CONFIG) --libs vlc builtin pic mozilla`
moz_CFLAGS = `$(MOZILLA_CONFIG) --cflags plugin java nspr/obsolete nspr oji xpcom xpconnect`
moz_plugin_FLAGS = -I$(srcdir)/../include -c -F/System/Library/Frameworks/CoreFoundation.framework $(moz_CFLAGS) -I/Developer/Headers/FlatCarbon -arch ppc -fno-common -fpascal-strings -O0 -Wmost -Wno-four-char-constants -Wno-unknown-pragmas -DXP_MACOSX=1 -DNO_X11=1 -DUSE_SYSTEM_CONSOLE=1 -pipe -fmessage-length=0 -g -include mozilla-config.h
pic = pic
LIBRARIES_libvlc = $(top_builddir)/lib/libvlc_pic.a
else
LIBRARIES_mozilla = libvlcplugin$(LIBEXT)
SOURCES_unix = support/npunix.c
pic = pic
LIBRARIES_libvlc = $(top_builddir)/lib/libvlc_pic.a
endif
endif
......@@ -48,9 +53,9 @@ noinst_LIBRARIES_mozilla = libplugin.a
endif
libplugin_a_SOURCES = $(SOURCES_mozilla)
libplugin_a_CFLAGS = `$(VLC_CONFIG) --cflags mozilla pic` \
libplugin_a_CFLAGS = `$(VLC_CONFIG) --cflags mozilla $(pic)` \
$(CPPFLAGS_mozilla_EXTRA) -Imozilla
libplugin_a_CXXFLAGS = `$(VLC_CONFIG) --cxxflags mozilla pic` \
libplugin_a_CXXFLAGS = `$(VLC_CONFIG) --cxxflags mozilla $(pic)` \
$(CPPFLAGS_mozilla_EXTRA) -Imozilla
libplugin_a_DEPENDENCIES = $(DATA_npvlc_rc)
......@@ -62,8 +67,8 @@ plugindir = $(libdir)/mozilla/plugins
$(LIBRARIES_mozilla): $(libplugin_a_OBJECTS) \
$(libplugin_a_DEPENDENCIES) stamp-pic
$(CXXLINK) $(libplugin_a_OBJECTS) $(DATA_npvlc_rc) \
$(top_builddir)/lib/libvlc_pic.a -shared \
`$(VLC_CONFIG) --libs vlc mozilla builtin pic`
$(LIBRARIES_libvlc) -shared \
`$(VLC_CONFIG) --libs vlc mozilla builtin $(pic)`
vlcintf_xpt_DATA = vlcintf.xpt
vlcintf_xptdir = $(libdir)/mozilla/components
......@@ -93,7 +98,7 @@ VLC\ Plugin.plugin:
/usr/bin/g++3 $(moz_plugin_FLAGS) $(srcdir)/vlcshell.cpp -o $(srcdir)/libplugin_a-vlcshell.o
/usr/bin/g++3 $(moz_plugin_FLAGS) $(srcdir)/vlcpeer.cpp -o $(srcdir)/libplugin_a-vlcpeer.o
/usr/bin/g++3 $(moz_plugin_FLAGS) $(srcdir)/support/npmac.cpp -o $(srcdir)/libplugin_a-npmac.o
/usr/bin/g++3 $(srcdir)/libplugin_a-vlcplugin.o $(srcdir)/libplugin_a-vlcshell.o $(srcdir)/libplugin_a-vlcpeer.o $(srcdir)/libplugin_a-npmac.o -o $(srcdir)/VLC\ Plugin.plugin/Contents/MacOS/VLC\ Plugin -L/usr/lib -F/System/Library/Frameworks/CoreFoundation.framework -framework CoreFoundation -arch ppc -bundle -read_only_relocs suppress $(top_srcdir)/lib/libvlc_pic.a -dylib $(vlc_moz_FLAGS)
/usr/bin/g++3 $(srcdir)/libplugin_a-vlcplugin.o $(srcdir)/libplugin_a-vlcshell.o $(srcdir)/libplugin_a-vlcpeer.o $(srcdir)/libplugin_a-npmac.o -o $(srcdir)/VLC\ Plugin.plugin/Contents/MacOS/VLC\ Plugin -L/usr/lib -F/System/Library/Frameworks/CoreFoundation.framework -framework CoreFoundation -arch ppc -bundle -read_only_relocs suppress $(LIBRARIES_libvlc) -dylib $(vlc_moz_FLAGS)
cp $(top_srcdir)/extras/MacOSX/plugin/Info.plist $(srcdir)/VLC\ Plugin.plugin/Contents/Info.plist
cp $(top_srcdir)/extras/MacOSX/plugin/pbdevelopment.plist $(srcdir)/VLC\ Plugin.plugin/Contents/pbdevelopment.plist
cp -r $(top_srcdir)/extras/MacOSX/plugin/English.lproj $(srcdir)/VLC\ Plugin.plugin/Contents/Resources/
......@@ -111,7 +116,7 @@ clean-stamp:
rm -f stamp-pic
stamp-pic: FORCE
@for dep in "" `$(VLC_CONFIG) --target builtin pic`; do \
@for dep in "" `$(VLC_CONFIG) --target builtin $(pic)`; do \
if test "$${dep}" -nt "$(LIBRARIES_mozilla)"; then \
rm -f $@; \
break; \
......
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