There are two choices for installing pycapfile:
pycapfile may be installed with easy_install or pip:
$ sudo pip install pypcapfile
The source may be downloaded from the project’s Github Page. It uses the standard Python distutil package; run the included setup.py file with the “install” argument:
$ python setup.py install