[packages/phantomjs/dev-2.1: 3/9] build with bundled qt

glen glen at pld-linux.org
Wed Mar 23 07:05:49 CET 2016


commit 353cf764ebcdb405e5c0b9aa365efb9493636adc
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Tue Mar 22 22:45:52 2016 +0200

    build with bundled qt
    
    does not require Xvfb to run, really headless now

 phantomjs.spec | 27 +++++++++++++++++++++------
 1 file changed, 21 insertions(+), 6 deletions(-)
---
diff --git a/phantomjs.spec b/phantomjs.spec
index caccfa6..1ed6e16 100644
--- a/phantomjs.spec
+++ b/phantomjs.spec
@@ -8,11 +8,16 @@
 Summary:	Headless WebKit with a JavaScript API
 Name:		phantomjs
 Version:	2.1.1
-Release:	1
+Release:	0.1
 License:	BSD
 Group:		Applications/Networking
 Source0:	https://github.com/ariya/phantomjs/archive/%{version}/%{name}-%{version}.tar.gz
 # Source0-md5:	db2d71e67e3557a977c2f269f1ec7fee
+# https://github.com/ariya/phantomjs/tree/2.1.1/src/qt
+Source1:	https://github.com/Vitallium/qtbase/archive/b5cc0083a5766e773885e8dd624c51a967c17de0.tar.gz
+# Source1-md5:	ae375f9f522409ae262e949cd90bf880
+Source2:	https://github.com/Vitallium/qtwebkit/archive/e7b74331d695bfa8b77e39cdc50fc2d84a49a22a.tar.gz
+# Source2-md5:	94daad678e91ff9049ba26eb9e32febf
 Patch0:		%{name}-qt.patch
 Patch1:		%{name}-env.patch
 Patch3:		0003-unbundle-mongoose.patch
@@ -39,7 +44,20 @@ JSON, Canvas, and SVG. It can be used for screen scraping and web
 testing. It includes an implementation of the WebDriver API.
 
 %prep
-%setup -q
+%setup -q %{!?with_system_qt:-a1 -a2}
+
+%if %{without system_qt}
+rmdir src/qt/{qtbase,qtwebkit}
+mv qtbase-* src/qt/qtbase
+mv qtwebkit-* src/qt/qtwebkit
+
+# https://github.com/ariya/phantomjs/issues/13930
+# otherwise we get this error:
+# https://bugreports.qt.io/browse/QTBUG-48626
+touch src/qt/qtbase/.git
+touch src/qt/qtwebkit/.git
+touch src/qt/3rdparty/.git
+%endif
 
 # remove bundled sources
 rm -r src/mongoose
@@ -55,10 +73,7 @@ rm -r src/linenoise
 %{?with_system_qcommandline:%patch7 -p1}
 
 %build
-qmake-qt5
-%{__make} \
-	CXX="%{__cxx}" \
-	CXXFLAGS="%{rpmcxxflags} -fPIC"
+%{__python} build.py --confirm --release
 
 %install
 rm -rf $RPM_BUILD_ROOT
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/phantomjs.git/commitdiff/a82c74c1bebc21f1e68a4deede33d5d9c92de44c



More information about the pld-cvs-commit mailing list