From 200dc0cdc7065a38d56fe54decbb26981fd4581a Mon Sep 17 00:00:00 2001 From: Ya-Chieh Wu Date: Tue, 18 Apr 2017 19:18:00 +0200 Subject: [PATCH] Bug 1345328 - modify moz.build to build pdfium as a build-in addon. r=rhelmer --HG-- rename : browser/extensions/mortar/host/pdf/install.rdf => browser/extensions/mortar/host/pdf/install.rdf.in --- .../host/pdf/{install.rdf => install.rdf.in} | 20 ++++++++++++------- browser/extensions/mortar/jar.mn | 14 +++++++++++++ browser/extensions/mortar/moz.build | 14 +++++++++++++ 3 files changed, 41 insertions(+), 7 deletions(-) rename browser/extensions/mortar/host/pdf/{install.rdf => install.rdf.in} (62%) create mode 100644 browser/extensions/mortar/jar.mn diff --git a/browser/extensions/mortar/host/pdf/install.rdf b/browser/extensions/mortar/host/pdf/install.rdf.in similarity index 62% rename from browser/extensions/mortar/host/pdf/install.rdf rename to browser/extensions/mortar/host/pdf/install.rdf.in index b918ac02030d..6b62a4768dd2 100644 --- a/browser/extensions/mortar/host/pdf/install.rdf +++ b/browser/extensions/mortar/host/pdf/install.rdf.in @@ -1,25 +1,31 @@ - + +#filter substitution + + ppapipdf.js@mozilla.org ppapipdf.js - ppapipdf.js - 0.1 + ppapi pdf + 1.0 2 true true + + - {ec8030f7-c20a-464f-9b0e-13a3a9e97384} - 37.0 - 45.* + {ec8030f7-c20a-464f-9b0e-13a3a9e97384} + @MOZ_APP_VERSION@ + @MOZ_APP_MAXVERSION@ - false + diff --git a/browser/extensions/mortar/jar.mn b/browser/extensions/mortar/jar.mn new file mode 100644 index 000000000000..cf82177bb85b --- /dev/null +++ b/browser/extensions/mortar/jar.mn @@ -0,0 +1,14 @@ +# This Source Code Form is subject to the terms of the Mozilla Public +# License, v. 2.0. If a copy of the MPL was not distributed with this +# file, You can obtain one at http://mozilla.org/MPL/2.0/. + +[features/ppapipdf.js@mozilla.org] chrome.jar: + +% content ppapipdf.js %content/ + content/ (./host/pdf/chrome/*) + +% resource ppapipdf.js %res/ + res/ (./host/pdf/ppapi*.js) + +% resource ppapi.js %res/ + res/ (./host/common/*) diff --git a/browser/extensions/mortar/moz.build b/browser/extensions/mortar/moz.build index 457278335091..244507cf5bd8 100644 --- a/browser/extensions/mortar/moz.build +++ b/browser/extensions/mortar/moz.build @@ -6,6 +6,20 @@ XPCSHELL_TESTS_MANIFESTS += ['test/unit/xpcshell.ini'] +DEFINES['MOZ_APP_VERSION'] = CONFIG['MOZ_APP_VERSION'] +DEFINES['MOZ_APP_MAXVERSION'] = CONFIG['MOZ_APP_MAXVERSION'] + + +FINAL_TARGET_FILES.features['ppapipdf.js@mozilla.org'] += [ + 'host/pdf/bootstrap.js' +] + +FINAL_TARGET_PP_FILES.features['ppapipdf.js@mozilla.org'] += [ + 'host/pdf/install.rdf.in' +] + +JAR_MANIFESTS += ['jar.mn'] + SOURCES += [ 'host/rpc.cc', ]