[vlc-commits] commit: Ugly and almost working npapi build rules ( Rémi Denis-Courmont )

git at videolan.org git at videolan.org
Mon Oct 11 22:10:13 CEST 2010


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Mon Oct 11 23:09:22 2010 +0300| [6a4df1923214a7ff27fbb5c55d6e807e1527b2c8] | committer: Rémi Denis-Courmont 

Ugly and almost working npapi build rules

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=6a4df1923214a7ff27fbb5c55d6e807e1527b2c8
---

 Makefile.am             |   40 ++++++++++++++++++----------------------
 extras/package/npapi.am |   30 ++++++++++++++++++++++++++++++
 2 files changed, 48 insertions(+), 22 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index a3a064d..b7404af 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -695,6 +695,10 @@ win32_debugdir=$(top_builddir)/symbols-$(VERSION)
 win32_lua_destdir=$(win32_destdir)/lua
 win32_xpi_destdir=$(win32_destdir)/vlc-plugin
 
+if HAVE_WIN32
+include extras/package/npapi.am
+endif
+
 #Win-common is for win32 and wince
 package-win-common: install
 # Check that tmp isn't in the way
@@ -792,9 +796,7 @@ if BUILD_OSDMENU
 		rm -f -- "$$file.tmp"; \
 	done
 endif
-#if BUILD_MOZILLA
-#	cp $(top_srcdir)/projects/mozilla/npvlc.dll.manifest $(win32_destdir)
-#endif
+	cp $(top_srcdir)/extras/mozilla/src/npvlc.dll.manifest $(win32_destdir)
 if BUILD_ACTIVEX
 	cp $(top_srcdir)/projects/activex/axvlc.dll.manifest $(win32_destdir)
 endif
@@ -829,29 +831,23 @@ package-win-base: package-win-common
 	  fi ; \
 	done
 
-package-win32-webplugin-common: package-win-base
-#if BUILD_MOZILLA
-#	mkdir -p "$(win32_xpi_destdir)/plugins"
-#	find $(destdir) -maxdepth 4 -name "*$(LIBEXT)" -exec cp {} "$(win32_xpi_destdir)/" \;
-#	cp $(top_srcdir)/projects/mozilla/npvlc.dll.manifest "$(win32_xpi_destdir)/plugins"
-#	cp "$(top_srcdir)/extras/package/win32/libvlc.dll.manifest" "$(win32_xpi_destdir)/plugins"
-#	cp -r $(win32_destdir)/plugins/ "$(win32_xpi_destdir)/plugins"
-#	rm -rf "$(win32_xpi_destdir)/plugins/plugins/*qt*"
-#	rm -rf "$(win32_xpi_destdir)/plugins/plugins/*skins*"
-#endif
+package-win32-webplugin-common: package-win-base build-win-npapi
+	mkdir -p "$(win32_xpi_destdir)/plugins"
+	find $(destdir) -maxdepth 4 -name "*$(LIBEXT)" -exec cp {} "$(win32_xpi_destdir)/" \;
+	cp $(top_srcdir)/extras/mozilla/src/npvlc.dll.manifest "$(win32_xpi_destdir)/plugins"
+	cp "$(top_srcdir)/extras/package/win32/libvlc.dll.manifest" "$(win32_xpi_destdir)/plugins"
+	cp -r $(win32_destdir)/plugins/ "$(win32_xpi_destdir)/plugins"
+	rm -rf "$(win32_xpi_destdir)/plugins/plugins/*qt*"
+	rm -rf "$(win32_xpi_destdir)/plugins/plugins/*skins*"
 
 package-win32-xpi: package-win32-webplugin-common
-#if BUILD_MOZILLA
-#	cp $(top_builddir)/projects/mozilla/install.rdf "$(win32_xpi_destdir)"
-#	cd $(win32_xpi_destdir) && zip -r "../vlc-$(VERSION).xpi" install.rdf plugins
-#endif
+	cp $(top_builddir)/extras/mozilla/src/install.rdf "$(win32_xpi_destdir)"
+	cd $(win32_xpi_destdir) && zip -r "../vlc-$(VERSION).xpi" install.rdf plugins
 
 package-win32-crx: package-win32-webplugin-common
-#if BUILD_MOZILLA
-#	cp $(top_builddir)/projects/mozilla/manifest.json "$(win32_xpi_destdir)"
-#	crxmake --pack-extension "$(win32_xpi_destdir)" \
-#		--extension-output "$(win32_destdir)/vlc-$(VERSION).crx" --ignore-file install.rdf
-#endif
+	cp $(top_builddir)/extras/mozilla/src/manifest.json "$(win32_xpi_destdir)"
+	crxmake --pack-extension "$(win32_xpi_destdir)" \
+		--extension-output "$(win32_destdir)/vlc-$(VERSION).crx" --ignore-file install.rdf
 
 package-win32-base-exe: package-win-base
 # Script installer
diff --git a/extras/package/npapi.am b/extras/package/npapi.am
new file mode 100644
index 0000000..26900d7
--- /dev/null
+++ b/extras/package/npapi.am
@@ -0,0 +1,30 @@
+#! /usr/bin/make -f
+
+build-npapi: stamp-npapi-build
+
+stamp-npapi-fetch:
+	rm -Rf npapi-vlc
+	git clone git://git.videolan.org/npapi-vlc.git npapi-vlc
+	touch $@
+
+stamp-npapi-autogen: stamp-npapi-fetch
+# extras/package/npapi.am
+	cd npapi-vlc && \
+	$(SHELL) ./autogen.sh
+	touch $@
+
+stamp-npapi-configure: stamp-npapi-autogen
+	cd npapi-vlc && \
+	$(SHELL) ./configure \
+		--host=$(host_alias) --build=$(build_alias) \
+		--with-mozilla-sdk-path="../$(srcdir)/extras/contrib/hosts/$(host_alias)/gecko-sdk" \
+		CPP="$(CPP)" CPPFLAGS="$(CPPFLAGS)" \
+		CC="$(CC)" CFLAGS="$(CFLAGS)" \
+		CXX="$(CXX)" CXXFLAGS="$(CXXFLAGS)" \
+		LD="$(LD)" LDFLAGS="$(LDFLAGS)" \
+		PKG_CONFIG_LIBDIR="../$(srcdir)/extras/contrib/lib/pkgconfig:../src"
+	touch $@
+
+stamp-npapi-build: stamp-npapi-configure
+	cd npapi-vlc && \
+	$(MAKE) $(MAKEFLAGS) all



More information about the vlc-commits mailing list