Summary: | lang/phantomjs: update to 2.1.1 | ||||||
---|---|---|---|---|---|---|---|
Product: | Ports & Packages | Reporter: | ncrogers | ||||
Component: | Individual Port(s) | Assignee: | Mark Felder <feld> | ||||
Status: | Closed FIXED | ||||||
Severity: | Affects Some People | CC: | h0rst, ncrogers, pete, vivek | ||||
Priority: | --- | Flags: | bugzilla:
maintainer-feedback?
(feld) |
||||
Version: | Latest | ||||||
Hardware: | Any | ||||||
OS: | Any | ||||||
Attachments: |
|
Description
ncrogers
2016-10-20 00:39:13 UTC
(In reply to ncrogers from comment #0) We can't do a git clone because the package is built in a jail with no internet access which is an intentional restriction. We could do a checkout and roll our own tarball and self-host that. That was my plan for attempting to update this port. I will look into it soon, but if you have progress in this area please let me know. Adding reference to conversation with PhantomJS devs - recommendation is to wait until version 2.5: https://github.com/ariya/phantomjs/issues/14597 Kind of related... It seems to me that phantomjs usefulness is much diminished if it does not have access to actual fonts to render text. I need to also install webfonts package wherever I use it. Could webfonts be made a run dependency on the next update? I build everything without X11 support to run on headless servers, so maybe that's why I don't automatically get the fonts. (In reply to Vick Khera from comment #3) I'll defer to the porters for this, but in my use-case we run it headless as well, although we don't require font rendering as part of our unit-test framework. our primary use-case is to verify that SCSS is being compiled correctly and that our .js code is working as well. actually, the xorg-fonts-truetype package provides nicer fonts than webfonts and also allows text to render. Good news - looks like PhantomJS v2.5.0. This includes the ability to build against system KDE which should make PhantomJS now build on FreeBSD. I hope to test this locally tomorrow. https://groups.google.com/forum/#!topic/phantomjs/AefOuwkgBh0 I'll keep my eye on this PR. Glad to see this finally has made progress. I have put some cycles into getting the phantomjs binary to build on 11-RELEASE. Since upstream hasn't updated their build instructions I'm documenting what steps were required to get my build working locally: - Current code lives in this Github repo: https://github.com/ariya/phantomjs https://github.com/ariya/phantomjs.git - Check out "master" branch - Install qt5 meta pkg and ensure that both "qmake" and "moc" exist under: /usr/local/lib/qt5/bin/ - in root of repository run "qmake' to generate Makefile - run "make" There is a bug I am needing to dig into where this exception is thrown when building: webpage.cpp:369:42: error: no member named 'WebSecurityEnabled' in 'QWebSettings'; did you mean 'WebAudioEnabled'? settings->setAttribute(QWebSettings::WebSecurityEnabled, phantomCfg->webSecurityEn... ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~ WebAudioEnabled /usr/local/include/qt5/QtWebKit/qwebsettings.h:89:9: note: 'WebAudioEnabled' declared here WebAudioEnabled, Applying this diff allows the code to compile, I'll research a proper fix for this shortly: $ git diff diff --git a/src/webpage.cpp b/src/webpage.cpp index ac309c65..1d8283f9 100644 --- a/src/webpage.cpp +++ b/src/webpage.cpp @@ -366,7 +366,7 @@ WebPage::WebPage(QObject* parent, const QUrl& baseUrl) // attribute "WebSecurityEnabled" must be applied during the initializing // security context for Document instance. Setting up it later will not cause any effect QWebSettings* settings = m_customWebPage->settings(); - settings->setAttribute(QWebSettings::WebSecurityEnabled, phantomCfg->webSecurityEnabled()); + // settings->setAttribute(QWebSettings::WebSecurityEnabled, phantomCfg->webSecurityEnabled()); m_mainFrame = m_customWebPage->mainFrame(); m_currentFrame = m_mainFrame; Created attachment 179343 [details]
update to phantomjs-2.1.1
Comment on attachment 179343 [details]
update to phantomjs-2.1.1
I tried to fix this port. Could anyone more experienced check this patch which compiles cleanly over here.
Fantastic work. Thanks for your efforts! Committed with minor changes. A commit references this bug: Author: feld Date: Sun Jan 29 19:11:36 UTC 2017 New revision: 432793 URL: https://svnweb.freebsd.org/changeset/ports/432793 Log: lang/phantomjs: Update to 2.1.1 PR: 213634 Changes: head/lang/phantomjs/Makefile head/lang/phantomjs/distinfo head/lang/phantomjs/files/patch-build.py head/lang/phantomjs/files/patch-build.sh head/lang/phantomjs/files/patch-configure head/lang/phantomjs/files/patch-src-phantomjs.pro head/lang/phantomjs/files/patch-src-qt-preconfig.sh head/lang/phantomjs/files/patch-src_qt_qtbase_configure head/lang/phantomjs/files/patch-src_qt_qtbase_src_3rdparty_icu__dependency.pri head/lang/phantomjs/files/patch-src_qt_qtbase_src_corelib_io_qstorageinfo__unix.cpp head/lang/phantomjs/files/patch-src_qt_qtbase_src_network_ssl_qsslcontext.cpp head/lang/phantomjs/files/patch-src_qt_qtbase_src_network_ssl_qsslsocket__openssl__symbols.cpp head/lang/phantomjs/files/patch-src_qt_qtbase_src_tools_qlalr_lalr.cpp |