Hena has asked for the wisdom of the Perl Monks concerning the following question:

Hello Monks,

I'm trying to install Tk module with the cpan shell 'perl -MCPAN -e shell' command (install Tk). Problem is it fails as it cannot find the X include files. I assume these are then the *.h files, which in my kubuntu is in '/usr/X11R6/include/X11' directory. So is there a way to add new path to the selection what 'install Tk' command uses to find the include files?

Replies are listed 'Best First'.
Re: Problem installing Tk module
by gellyfish (Monsignor) on May 11, 2005 at 11:03 UTC

    It is easy to do manually - i.e. got to the ~/.cpan/build/<dist> directory and run:

    perl Makefile.PL INC="-I/usr/X11R6/include/X11" make make test make install
    and everything should be alright. See the documentation on ExtUtils::MakeMaker for more on the options for the Makefile.PL

    /J\