summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichal Klocek <michal.klocek@qt.io>2019-08-23 15:41:39 +0200
committerMichal Klocek <michal.klocek@qt.io>2019-11-25 13:00:56 +0100
commitf6e67daeb4b357b265eeb2ff9992fbb969a55216 (patch)
tree130a02f2737434db7fd3d5dce12563450875377d
parent440116bb57a40021540e96be237da64b85b51991 (diff)
Add configurable v8/xfa support to qtpdf
Without v8/xfa support, compilation drops to ~650 files. Disable v8/xfa by default. Enabling v8 enables all xfa support. For example to enable full xfa support without xfa-tiff: qmake <src> -- --feature-pdf-v8 --no-feature-pdf-xfa-tiff Change-Id: I0525c22ed6ed84d5837ab9a238ef2c4219339895 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
-rw-r--r--src/buildtools/config/common.pri34
-rw-r--r--src/pdf/configure.json44
2 files changed, 74 insertions, 4 deletions
diff --git a/src/buildtools/config/common.pri b/src/buildtools/config/common.pri
index b5617cdfb..be09751c9 100644
--- a/src/buildtools/config/common.pri
+++ b/src/buildtools/config/common.pri
@@ -144,3 +144,37 @@ ccache {
}
qtConfig(force_asserts): gn_args += dcheck_always_on=true
+
+qtConfig(build-qtpdf) {
+ qtConfig(pdf-v8) {
+ gn_args += pdf_enable_v8=true
+ } else {
+ gn_args += pdf_enable_v8=false
+ }
+ qtConfig(pdf-xfa) {
+ gn_args += pdf_enable_xfa=true
+ } else {
+ gn_args += pdf_enable_xfa=false
+ }
+ qtConfig(pdf-xfa-bmp) {
+ gn_args += pdf_enable_xfa_bmp=true
+ } else {
+ gn_args += pdf_enable_xfa_bmp=false
+ }
+ qtConfig(pdf-xfa-gif) {
+ gn_args += pdf_enable_xfa_gif=true
+ } else {
+ gn_args += pdf_enable_xfa_gif=false
+ }
+ qtConfig(pdf-xfa-png) {
+ gn_args += pdf_enable_xfa_png=true
+ } else {
+ gn_args += pdf_enable_xfa_png=false
+ }
+ qtConfig(pdf-xfa-tiff) {
+ gn_args += pdf_enable_xfa_tiff=true
+ } else {
+ gn_args += pdf_enable_xfa_tiff=false
+ }
+}
+
diff --git a/src/pdf/configure.json b/src/pdf/configure.json
index a7376b578..48e68333e 100644
--- a/src/pdf/configure.json
+++ b/src/pdf/configure.json
@@ -8,9 +8,40 @@
"tests": {
},
"features": {
- "pdf-info": {
- "label": "Support Qt PDF rendering module",
- "purpose": "Enables building the Qt PDF rendering module.",
+ "pdf-v8": {
+ "label": "Support V8",
+ "purpose": "Enables javascript support.",
+ "autoDetect": "false",
+ "output": ["privateFeature" ]
+ },
+ "pdf-xfa": {
+ "label": "Support XFA",
+ "purpose": "Enables XFA support.",
+ "condition": "features.pdf-v8",
+ "output": ["privateFeature" ]
+ },
+ "pdf-xfa-bmp": {
+ "label": "Support XFA-BMP",
+ "purpose": "Enables XFA-BMP support.",
+ "condition": "features.pdf-xfa",
+ "output": ["privateFeature" ]
+ },
+ "pdf-xfa-gif": {
+ "label": "Support XFA-GIF",
+ "purpose": "Enables XFA-GIF support.",
+ "condition": "features.pdf-xfa",
+ "output": ["privateFeature" ]
+ },
+ "pdf-xfa-png": {
+ "label": "Support XFA-PNG",
+ "purpose": "Enables XFA-PNG support.",
+ "condition": "features.pdf-xfa",
+ "output": ["privateFeature" ]
+ },
+ "pdf-xfa-tiff": {
+ "label": "Support XFA-TIFF",
+ "purpose": "Enables XFA-TIFF support.",
+ "condition": "features.pdf-xfa",
"output": ["privateFeature" ]
}
},
@@ -20,7 +51,12 @@
{
"section": "Qt PDF",
"entries": [
- "pdf-info"
+ "pdf-v8",
+ "pdf-xfa",
+ "pdf-xfa-bmp",
+ "pdf-xfa-gif",
+ "pdf-xfa-png",
+ "pdf-xfa-tiff"
]
}
]