I'm trying to install the Perl module Linux::Inotify2
. The installation requires some C compiling.
Which compiler CPAN uses is the same one Perl was compiled with. Which one that is can be seen with:
perl -MConfig -le 'print "@Config{ qw/cc ccflags/ }"'
Which comes up:
gcc-4.7 -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
Now that seems to be a big problem for me because the latest gcc included in raspbian is 4.6
!
As a result, when I try to install Linux::Inotify2
, I get failures simply because:
/bin/sh: 1: gcc-4.7: not found
How can I get around this? Shouldn't Perl have been compiled with gcc-4.6 for raspbian if a newer version wasn't included? Do I have to install gcc-4.7 on my Pi?
Update:
Just making a symlink for gcc-4.7 that points to gcc-4.6 seems to be a decent workaround. Though I know this isn't ideal.