If you are upgrading from HiPi version 0.51 or below, read the upgrade notes at Upgrading from HiPi 0.51 before continuing.
Using Debian Package
A HiPi debian package is available for Raspbian Stretch
Download libhipi-perl_0.67-1_armhf.deb then install and resolve dependencies.
sudo apt-get update sudo dpkg --install libhipi-perl_0.67-1_armhf.deb apt-get -y -f install
You don't have to run the seperate apt-get command to resolve dependencies if you use gdebi.
sudo apt-get update sudo apt-get install gdebi-core sudo gdebi libhipi-perl_0.67-1_armhf.deb
You can install from CPAN in the normal way.
cpan -i HiPi
If you would like to install dependencies first from the Raspbian repository (recommended) rather than have cpan build and install them locally, the list is:
sudo apt-get update sudo apt-get install libdevice-serialport-perl \ libfile-copy-recursive-perl \ libfile-slurp-perl \ libjson-perl \ libtry-tiny-perl \ libuniversal-require-perl \ libio-epoll-perl