The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Problem installing "phantomjs"

Discussion in 'General Discussion' started by Andrew Roy, Jul 9, 2015.

  1. Andrew Roy

    Andrew Roy Registered

    Joined:
    Jul 9, 2015
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Altrincham
    cPanel Access Level:
    Website Owner
    I installed "phantomjs" from "phantomjs.org/build.html" (You can see instruction for installation).



    but when I am running some commands related to phantomjs as shown in "phantomjs.org/screen-capture.html", then its showing some error "phantomjs: error while loading shared libraries: libfreetype.so.6: cannot open shared object file: No such file or directory".



    I want to use phantomjs for image capture and I did this for windows based ssystem but unable to configure it on centOS.



    Can you please help me out with this issue.
     
    #1 Andrew Roy, Jul 9, 2015
    Last edited by a moderator: Jul 9, 2015
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    676
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    Have you verified the "freetype" package is installed on your system? Also, is this application expecting it at a certain location?

    Thank you.
     
  3. Pascu

    Pascu Registered

    Joined:
    Jul 21, 2015
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    España, Alicante
    cPanel Access Level:
    Root Administrator
    Hi

    I recently installed WHM on CentOS 7 and I am trying to install Phantomjs 2.0.0
    I have all the dependencies installed I have even disabled the firewall ... no way to compile this ... somebody could tell me where I could come this error?

    Bests Regards
    Code:
    #######Please submit a full bug report,##########
    with preprocessed source if appropriate.
    See <" target="_blank" class="externalLink ProxyLink" data-proxy-href="http://bugzilla.redhat.com/bugzilla>" rel="nofollow">http://bugzilla.redhat.com/bugzilla> for instructions.
    make[2]: *** [.obj/qdatetimeparser.o] Error 4
    g++: error interno del compilador: Violación de segmento (programa cc1plus)
    Please submit a full bug report,
    with preprocessed source if appropriate.
    See <" target="_blank" class="externalLink ProxyLink" data-proxy-href="http://bugzilla.redhat.com/bugzilla>" rel="nofollow">http://bugzilla.redhat.com/bugzilla> for instructions.
    make[2]: *** [.obj/qdatetime.o] Error 4
    make[2]: se sale del directorio `/opt/phantomjs-2.0.0/src/qt/qtbase/src/corelib'
    make[1]: *** [sub-corelib-make_first] Error 2
    make[1]: se sale del directorio `/opt/phantomjs-2.0.0/src/qt/qtbase/src'
    make: *** [sub-src-make_first] Error 2
    
     
    #3 Pascu, Jan 6, 2016
    Last edited by a moderator: Jan 6, 2016
  4. Pascu

    Pascu Registered

    Joined:
    Jul 21, 2015
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    España, Alicante
    cPanel Access Level:
    Root Administrator
    Hi
    Here I leave information on how to install Phantomjs on CentOS 7
    Basically I need to find the installation package compiled whit build packege made, otherwise execute ./build It takes a lot of mime and from there the problems begin

    Code:
    PHANTOMJS ON CENTOS 7 / WHM / CPANEL
    Make sure you have installed the necessary dependencies to compile the script ... typically are this, for more info visit the official website
    
    yum install fontconfig freetype libfreetype.so.6 libfontconfig.so.1 libstdc++.so.6 gcc gcc-c++ make git openssl-devel freetype-devel fontconfig-devel
    
    1. Create a directory for this script, I have created in / opt
    mkdir -p /opt/phantomjs
    
    2. Download and unzip
    wget https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-1.9.8-linux-x86_64.tar.bz2
    tar -xjvf phantomjs-1.9.8-linux-x86_64.tar.bz2
    
    3. Moves the files to where the script will reside
    mv phantomjs-1.9.8-linux-x86_64/* /opt/phantomjs
    
    4. create symbolic links
    ln -s /opt/phantomjs/bin/phantomjs /usr/bin/phantomjs
    ln -s /opt/phantomjs/bin/phantomjs /usr/local/bin/phantomjs
    
    5.test phantomjs
    
    phantomjs /opt/phantomjs/examples/hello.js
    phantomjs -v
    
    6. Be a clean guy and delete files you no longer need
    
    run rm -rf  for phantomjs-1.9.8-linux-x86_64.tar.bz2 and phantomjs-1.9.8-linux-x86_64
    
    
    Bests regards !!! and if you want to see phantomjs working in a real site visit my website - Removed - and index your WebSite
     
    #4 Pascu, Jan 7, 2016
    Last edited by a moderator: Jan 8, 2016
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,854
    Likes Received:
    676
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
Loading...

Share This Page