Coder Social home page Coder Social logo

phantomjs-linux-armv6l's Introduction

phantomjs-linux-armv6l

PhantomJS 1.9, compiled on Raspberry PI (Raspbian "wheezy").

PhantomJS is a headless WebKit with JavaScript API. It has fast and native support for various web standards: DOM handling, CSS selector, JSON, Canvas, and SVG. (http://phantomjs.org).

Installation on Raspberry PI

Download the archive and extract the binary:

$ cd /tmp
$ wget https://github.com/aeberhardo/phantomjs-linux-armv6l/archive/master.zip
$ unzip master.zip
$ cd phantomjs-linux-armv6l-master
$ bunzip2 *.bz2 && tar xf *.tar

The binary phantomjs is located in the bin directory:

$ ./phantomjs-1.9.0-linux-armv6l/bin/phantomjs --version
1.9.0

I achieved the best screenshot results with the following font configuration.

Caution: The following steps could mess up the font configuration for other applications!

$ cd /usr/share
$ sudo mv fonts fonts.bak
$ sudo mkdir fonts

$ sudo apt-get install --reinstall ttf-mscorefonts-installer

$ sudo rm /usr/share/fonts/truetype/msttcorefonts/andalemo.ttf
$ sudo rm /usr/share/fonts/truetype/msttcorefonts/Andale_Mono.ttf

$ sudo fc-cache -rv

Build Process

PhantomJS has been built using the process described below.

1. According to http://phantomjs.org/build.html :

$ sudo apt-get update
$ sudo apt-get install build-essential chrpath git-core libssl-dev libfontconfig1-dev
$ git clone git://github.com/ariya/phantomjs.git
$ cd phantomjs
$ git checkout 1.9

2. Download additional 3rdparty files:

$ mkdir src/qt/src/3rdparty/pixman && pushd src/qt/src/3rdparty/pixman && curl -O http://qt.gitorious.org/qt/qt/blobs/raw/4.8/src/3rdparty/pixman/README && curl -O http://qt.gitorious.org/qt/qt/blobs/raw/4.8/src/3rdparty/pixman/pixman-arm-neon-asm.h && curl -O http://qt.gitorious.org/qt/qt/blobs/raw/4.8/src/3rdparty/pixman/pixman-arm-neon-asm.S; popd

3. Open ./build.sh and delete lines 11-34:

.. ...
11 if [[ "$MAKEFLAGS" != "" ]]; then
12 MAKEFLAGS_JOBS=$(echo $MAKEFLAGS | egrep -o '\-j[0-9]+' | egrep -o '[0-9]+')
.. ...
34 fi
.. ...

4. Open ./src/qt/preconfig.sh and add the option ' -no-pch' to QT_CFG after ' -no-stl':

.. ...
29 QT_CFG+=' -no-exceptions'       # Don't use C++ exception
30 QT_CFG+=' -no-stl'              # No need for STL compatibility
31 QT_CFG+=' -no-pch'
.. ...

5. Start compilation:

$ nohup ./build.sh --confirm > build.sh.out 2> build.sh.err &

6. Create tarball according to http://phantomjs.org/build.html :

./deploy/package.sh

7. The tarball can be found in the ./deploy directory.

phantomjs-linux-armv6l's People

Contributors

accaliadeelementia avatar aeberhardo avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.