The PhantomJS QPA hardcoded usage of QFontconfigDatabase on
Unix-not-OSX, causing build failures in "bundle all the libraries" mode.
Use QGenericUnixFontDatabase instead, which is QFontconfigDatabase if
fontconfig is enabled, and QBasicFontDatabase if it isn't. This means
that the bundled-qtdeps build will use only the fonts bundled with Qt,
and won't be able to find them on a machine that doesn't have the source
tree, which is suboptimal, but at least this makes the bundled-qtdeps
build complete successfully again.
Part of issue #12467.
In this mode, system-provided libraries will be used for all of
Qt's dependencies, but Qt and QtWebkit themselves are still the
bundled copies. This mode actually works.
Now that this mode exists, disable fontconfig in the "everything
bundled" mode, because it drags in the system freetype and several
other system libraries. (There is no bundled fontconfig.)
Part of issue #12467.
This is how we arrange for QtWebkit to use QtBase's bundled copy of
sqlite; without it, QtWebkit will attempt to use a system-provided
library instead, and if headers are unavailable, the build will fail.
Part of issue #12467.
As with the system-qtwebkit option, this does not actually work at this
point, but it enables experimentation toward getting it to work.
Part of issue #12467.
* build.sh now handles building qt and qtwebkit.
* preconfig.sh is now only responsible for accumulating arguments
to pass to qt's configure script.
* preconfig.sh doesn't have command line arguments of its own;
anything on its command line will be passed directly to qt's
configure script.
* first pass of adjustments to the qt configure parameters
to try to get a more static build - unfortunately, system
sqlite, libz, libpng, and libexpat are still getting pulled
in somehow (mostly via fontconfig, I think).
Part of issue #12467.
Invoking build.sh with --system-qtwebkit will skip the build of Qt and
QtWebkit and use the qmake in $PATH to build PhantomJS proper.
This doesn't actually *work* at the moment because the bundled
copy of Webkit has patches not yet merged upstream, but it's still
useful to have for testing purposes.
Part of issue #12467.
* Allow any patchlevel of Qt 5.3.x.
* Do it in the master .pro file instead of main.cpp; this makes the build
fail immediately rather than after compiling a bunch of stuff.
Part of issue #12467.
* Ignore src/phantomjs_plugin_import.cpp, which is now created during
the build.
* Add leading slashes to a bunch of files that should not be ignored if
they crop up in subdirectories.
Part of issue #12467.
window.callPhantom formerly used Array.prototype.splice for cloning
its arguments to the internal _phantom.call. This relied on
non-standard behaviour of the splice method when only a single
argument was passed to it (it requires 2 arguments).
The correct method for cloning the arguments array is to use
Array.prototype.slice, which accepts a single argument (index) and
returns a new array from the specified index.
https://github.com/ariya/phantomjs/issues/12306
Currently, the build script will continue to try to build PhantomJS
even when either QtBase or QtWebKit failed to compile. In such a
case, the script should return early and emit an error message.
https://github.com/ariya/phantomjs/issues/12433
The last reference test.pdf in the tests was using a complete different region
of the input "image.jpg" because the used phantomjs version used to generate it
had a bug. This bug was fixed in 833eb824f5bae07f1b157d6757e7e3c98343f812
("Don't scale the unit px to 1/2.54 points for PDFs") and
1daa2eb4dd49efb848ff96e37f298a774520cc9b ("Disable page shrinking for pdf
printing to create accurate output").
The new version should now use the same region of the input image as the other
generated files for the gif, jpg and png tests. The only difference is the
extra height is still displayed on a second page but this is currently expected
by phantomjs.
https://github.com/ariya/phantomjs/issues/11590 ("page.paperSize is not
accurate for .pdf")
PDFs are not rendered like PNG or other image formats by phantomjs because it
uses the printer functionality of Qt+Webkit. But Webkit uses some printer
"optimization" to save paper by shrinking the output. Such shrinking results in
too small content on a page.
https://github.com/ariya/phantomjs/issues/11590 ("page.paperSize is not
accurate for .pdf")
The unit px is one point inside the HTML source page but phantomjs handles it
without reason as 1/2.54 points. This makes the page smaller than expected when
trying to render a page as PDF.
https://github.com/ariya/phantomjs/issues/11590 ("page.paperSize is not
accurate for .pdf")