...
Please make sure to follow the instructions for compiling python prior to building swig since swig needs to be built against python.
swig.org
3.0.12
rhel6 and rhel7
./configure --with-python=/afs/slac/g/glast/ground/GLAST_EXT/redhat6-x86_64-64bit-gcc44/python/2.7.12-Miniconda2-4.2.11/bin --with-python3=/afs/slac/g/glast/ground/GLAST_EXT/redhat6-x86_64-64bit-gcc44/python/3.6.3-Miniconda3-4.3.31/bin --prefix=/afs/slac/g/glast/ground/GLAST_EXT/redhat6-x86_64-64bit-gcc44/swig/3.0.12
make
make install
Note that the python test suite has been disabled by the swig team, so there is no easy test of the installation.
1.3.31
These are the instructions to build SWIG version 1.3.31 on the various supported platforms at SLAC.
...