"Fossies" - the Fresh Open Source Software Archive

Member "Tk-804.036/README.linux" (20 Oct 2019, 4937 Bytes) of package /linux/misc/Tk-804.036.tar.gz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. See also the last Fossies "Diffs" side-by-side code changes report for "README.linux": 804.033_vs_804.034.

    1 System prerequisites for Perl/Tk on Linux
    2 
    3 Of course a C compiler (e.g. gcc) and a make tool (e.g. GNU make)
    4 needs to be installed. Additionally, some libraries and include files
    5 are required:
    6 
    7 Debian, Ubuntu:
    8 
    9 The following system packages should be installed:
   10 
   11     libx11-dev (minimal requirement for basic compilation of Perl/Tk)
   12     libfreetype6-dev libxft-dev (for freetype support, XFT=1)
   13     libpng-dev libz-dev (for using system library for Tk::PNG)
   14     libjpeg-dev (for using system library for Tk::JPEG)
   15 
   16 Command lines:
   17 
   18     apt-get install libx11-dev libfreetype6-dev libxft-dev libpng-dev libz-dev libjpeg-dev
   19     aptitude install libx11-dev libfreetype6-dev libxft-dev libpng-dev libz-dev libjpeg-dev
   20 
   21 CentOS, RedHat, Fedora:
   22 
   23 The following system packages should be installed:
   24 
   25     libX11-devel (minimal requirement for basic compilation of Perl/Tk)
   26     libXft-devel (for freetype support, XFT=1)
   27     libpng-devel zlib-devel (for using system library for Tk::PNG)
   28     libjpeg-devel (for using system library for Tk::JPEG)
   29 
   30 Command line:
   31 
   32     yum install libX11-devel libXft-devel libpng-devel zlib-devel libjpeg-devel
   33 
   34 openSUSE (12.x, 13.x, Leap, Tumbleweed):
   35 
   36 The following system packages should be installed:
   37 
   38     libX11-devel (minimal requirement for basic compilation of Perl/Tk)
   39     libXft-devel (for freetype support, XFT=1)
   40     libpng16-devel zlib-devel (for using system library for Tk::PNG)
   41     libjpeg8-devel (for using system library for Tk::JPEG)
   42 
   43   Note that the 16 in libpng16-devel and 8 in libjpeg8-devel might differ
   44   per version of your distribution. You can find out what version your
   45   distribution support using
   46 
   47     zypper search libpng libjpeg
   48 
   49 Command line:
   50 
   51     zypper in -l libX11-devel libXft-devel libpng16-devel zlib-devel libjpeg8-devel
   52 
   53 With all these requirements, building Perl/Tk is straightforward:
   54 
   55     perl Makefile.PL
   56     make
   57     make test
   58     make install
   59 
   60 XFT (freetype support) is enabled by default if the system
   61 prerequisites are met (see above). To explicitely turn it off, use
   62 
   63     perl Makefile.PL XFT=0
   64 
   65 It's recommended to install system's libpng, zlib, and libjpeg first.
   66 Otherwise the bundled (and usually older) versions of libpng, zlib,
   67 and libjpeg are used.
   68 
   69 On some systems the default /etc/fonts/fonts.conf does not include
   70 traditional X11 fonts by default (seen on a CentOS 6.4 installation,
   71 probably also the case for the equivalent RedHat version). If you need
   72 traditional X11 fonts (adobe-courier, adobe-helvetica, adobe-times
   73 etc.), then there are some options:
   74 
   75 * Provide a file /etc/fonts/local.conf with appropriate <dir>
   76   elements, e.g.
   77 
   78     <fontconfig>
   79       <dir>/usr/share/X11/fonts</dir>
   80     </fontconfig>
   81 
   82   This change would be global for all users.
   83 
   84 * Create a user-specific configuration file in ~/.fonts.conf with the
   85   same content.
   86 
   87 * Copy or symlink the directories with the X11 fonts into ~/.fonts
   88   (for a user only) or a global font directory like
   89   /usr/local/share/fonts.
   90 
   91 ----------------------------------------------------------------------
   92 Older instructions follow
   93 
   94 These days perl/Tk is developed on Linux so things should work.
   95 Nick uses SuSE Distributions, currently using SuSE 9.0.
   96 All SuSE's /usr/bin/perl (perl >= perl5.8.0) should work.
   97 SuSE's fontconfig is fine for building with XFT=1, but
   98 there are some dodgy TrueType fonts in its set.
   99 
  100 RedHat is more variable. Nick uses this version under RedHat7.* and
  101 RedHat9.0 at work. RedHat9.0 will build with XFT=1 but scalable
  102 fonts installed by default are limited.
  103 
  104 Main snag on RedHat is that /usr/bin/perl tends to be a RedHat
  105 patched version rather than an approved perl release. Its 5.8.0 has
  106 bugs which mean that it is worse that official perl5.8.0 in UTF-8
  107 locales - but UTF-8 locales are default on RedHat :-(
  108 
  109 Nick has installed this version with RedHat's perl on RedHat9.
  110 BUT there are a lot of reports that it doesn't work. If the problem
  111 hits you try this:
  112 
  113 1. Delete the unpacked version that had trouble - the bug mangles
  114    some files.
  115 
  116 2. Change to a non UTF-8 locale. i.e.
  117    echo $LANG            # find out what your locale is
  118    export LANG=en_GB     # what above printed but without UTF-8 bit
  119 
  120 3. tar xzf Tk804.026.tar.gz  # re-extract
  121    cd Tk804.026
  122 
  123 4. perl Makefile.PL          # normal build
  124    make
  125    make test
  126 
  127    (Steps 3 & 4 can be done using CPAN module provided you stay
  128     in non-UTF-8 locale.)
  129 
  130 5. Optionally:
  131    export LANG=en_GB.UTF-8 # or original from step 2
  132    make test               # prove it works in the locale
  133 
  134 6. make install
  135 
  136 Or just get perl5.8.3 kit from CPAN and build a real perl.
  137 
  138 
  139 Other issues are that distributions vary in the fonts they come
  140 with and window managers vary by user AND distribution.
  141 So a t/entry.t and t/listbox.t in particular (which are new tests
  142 compared to Tk800 series) sometimes fail a few subtests.
  143 Sometimes when run like:
  144 
  145   perl -Mblib t/entry.t
  146 
  147 they will pass :-(
  148 
  149 Nick Ing-Simmons 2004/03/18