2

I have installed FreeBSD 9 and I need to install phantomjs. It is available in /usr/ports/lang/phantomjs but the version is 1.0 while I need a more recent version. There is a patch to update to version 1.4.1 but I don't know how to apply this patch. I've googled this and read the FreeBSD Porter's Handbook several times but I'm still lost.

Also there is no entry about phantomjs in /usr/ports/UPDATING file.

Thanks for your help.

1 Answer 1

2

You need to update your port tree. Run:

portsnap fetch update

If you want to keep your port tree updated on a regular basis you can create a periodic script.
This is the script I use on my dev machine, /usr/local/etc/periodic/weekly/910.portsnap

#!/bin/sh -
#
#

# If there is a global system configuration file, suck it in.
#
if [ -r /etc/defaults/periodic.conf ]
then
    . /etc/defaults/periodic.conf
    source_periodic_confs
fi

case "$weekly_portsnap_enable" in
    [Yy][Ee][Ss])
        echo ""
        echo "Updating ports tree via portsnap:"

        portsnap cron update | grep -v /;;

    *)  rc=0;;
esac

exit $rc

Don't forget to chmod+x 910.portsnap and add weekly_portsnap_enable="YES" to your /etc/periodic.conf file.

1
  • 1
    If ever anyone is interested in running phantomjs 1.6.1, intructions provided at code.google.com/p/phantomjs/issues/detail?id=597#c1 works perfectly with FreeBSD9 and clang. Unfortunately, you'll have to build by hand, as port tree only contains version 1.4, which the subbject of the question.
    – user130370
    Commented Aug 3, 2012 at 15:38

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .