Search code examples
ubuntuphantomjsarm64

Installing phantomjs binary on arm64 Ubuntu


It appears that a phantomjs package is available for arm64 architecture... see here and particularly here... it's for focal (20.04LTS).

But I'm trying to install the phantomjs binary on the following system:

# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 22.04.2 LTS
Release:        22.04
Codename:       jammy

# uname -i
aarch64

Is this possible? Or are there any way to install a phantomjs binary on this system?


Solution

  • Looks possible by adding

    $ sudo -s
    # echo 'deb [arch=arm64] http://archive.ubuntu.com/ubuntu focal main universe' >> /etc/apt/sources.list.d/phantomjs.list
    # apt update
    # apt policy phantomjs
    phantomjs:
    Installed: (none)
    Candidate: 2.1.1+dfsg-2ubuntu1
    Version table:
       2.1.1+dfsg-2ubuntu1 500
          500 http://archive.ubuntu.com/ubuntu focal/universe arm64 Packages
    

    You need to change repository/mirror to serve your special architecture arch64.


    Another alternative

    $ wget https://launchpad.net/ubuntu/+source/phantomjs/2.1.1+dfsg-2ubuntu1/+build/19118060/+files/phantomjs_2.1.1+dfsg-2ubuntu1_arm64.deb
    $ sudo apt install ./phantomjs_2.1.1+dfsg-2ubuntu1_arm64.deb
    $ sudo apt install -f # if dependencies are not happy