home *** CD-ROM | disk | FTP | other *** search
/ Chip 2005 February / CMCD0205.ISO / Linux / gimp-2.2.0.tar.gz / gimp-2.2.0.tar / gimp-2.2.0 / INSTALL < prev    next >
Text File  |  2004-12-18  |  17KB  |  356 lines

  1. Installation instructions for GIMP 2.2
  2. --------------------------------------
  3.  
  4. There are some basic steps to building and installing The GIMP.
  5.  
  6. GIMP 2.2 replaces GIMP 2.0. It is advised that you uninstall GIMP 2.0
  7. before installing GIMP 2.2. If you want to keep GIMP 2.0 installed in
  8. parallel to GIMP 2.2, you have to choose a separate prefix which is
  9. not in your default library search path.
  10.  
  11. GIMP 2.2 is fully backward compatible to GIMP 2.0. Plug-ins and
  12. scripts written for GIMP 2.0 will continue to work and don't need to
  13. be changed nor recompiled to be used with GIMP 2.2.
  14.  
  15. The most important part is to make sure the requirements for a build
  16. are fulfilled.  We depend on a number of tools and libraries which are
  17. listed below. For libraries this means you need to also have the
  18. header files installed.
  19.  
  20.   ******************************************************************
  21.   * Unless you are experienced with building software from source, *
  22.   * you should not attempt to build all these libraries yourself!  *
  23.   * We suggest that you check if your distributor has development  *
  24.   * packages of them and use these instead.                        *
  25.   ******************************************************************
  26.  
  27.   1. You need to have installed a recent version of pkg-config available
  28.      from http://www.freedesktop.org/software/pkgconfig/.  
  29.  
  30.   2. You need to have installed GTK+ version 2.4.4 or better. Do not
  31.      try to use an older GTK+ version (1.2.x), it will not work.
  32.      GTK+ itself needs recent versions of GLib (>= 2.4.5),
  33.      Pango (>= 1.4.0) and ATK. Sources for these can be grabbed from
  34.      ftp://ftp.gtk.org/. GTK+-2.x and friends can be installed side
  35.      by side with GTK+-1.2.
  36.  
  37.   3. We require PangoFT2, a Pango backend that uses FreeType2. Make
  38.      sure you have FreeType2 and fontconfig installed before you
  39.      compile Pango.  FreeType2 can be downloaded from
  40.      http://www.freetype.org/.  Fontconfig from
  41.      http://freedesktop.org/fontconfig/.  GIMP 2.2 depends on
  42.      freetype2 being newer than version 2.1.7. Older versions are
  43.      known to have bugs that seriously affect stability of The GIMP.
  44.  
  45.   4. We use libart2. Grab the module libart_lgpl out of GNOME CVS or
  46.      fetch the tarball from
  47.      ftp://ftp.gnome.org/pub/gnome/sources/libart_lgpl/
  48.  
  49.   5. You may want to install other third party libraries or programs that
  50.      are needed for some of the available plugins. We recommend to check
  51.      that the following libraries are installed: libpng, libjpeg,
  52.      libtiff, gimp-print (4.2.x), gtkhtml-2, libmng, librsvg, libwmf.
  53.  
  54.   6. Configure the GIMP by running the `configure' script. You may want
  55.      to pass some options to it, see below.
  56.  
  57.   7. Build the GIMP by running `make'. The use of GNU make is recommened.
  58.      If you need to tweak the build to make it work with other flavours
  59.      of make, we'd appreciate if you'd send us a patch with the changes.
  60.  
  61.   8. Install the GIMP by running `make install'. In order to avoid clashes
  62.      with other versions of The GIMP, we install a binary called gimp-2.2.
  63.      By default there's also a link created so that you can type 'gimp'
  64.      to start gimp-2.2. If you have the 2.0 version installed, you should
  65.      still be able to run it using 'gimp-2.0'.
  66.  
  67. Please make sure you don't have any old GTK+-2.x, jpeg, etc. libraries 
  68. lying around on your system, otherwise configure may fail to find the 
  69. new ones.
  70.  
  71.  
  72. Generic instructions for configuring and compiling auto-configured
  73. packages are included below. Here is an illustration of commands that
  74. might be used to build and install the GIMP. The actual configuration,
  75. compilation and installation output is not shown.
  76.  
  77.   % tar xvfz gimp-2.2.x.tar.gz   # unpack the sources
  78.   % cd gimp-2.2.x                # change to the toplevel directory
  79.   % ./configure                  # run the `configure' script
  80.   % make                         # build the GIMP
  81.   % make install                 # install the GIMP
  82.  
  83.  
  84. The `configure' script examines your system, and adapts the GIMP to
  85. run on it. The script has many options, some of which are described in
  86. the generic instructions included at the end of this file. All of the
  87. options can be listed using the command `./configure --help'. There
  88. are several special options the GIMP `configure' script recognizes.
  89. These are:
  90.  
  91.   --enable-shared and --disable-shared.  This option affects whether
  92.      shared libraries will be built or not. Shared libraries provide
  93.      for much smaller executables. The default is to enable shared
  94.      libraries. Disabling shared libraries is almost never a good idea.
  95.  
  96.   --enable-debug and --disable-debug.  This option causes the build
  97.      process to compile with debugging enabled. If debugging is
  98.      disabled, the GIMP will instead be compiled with optimizations turned
  99.      on. The default is for debugging to be disabled. NOTE: This
  100.      option is intended primarily as a convenience for developers.
  101.  
  102.   --enable-ansi and --disable-ansi.  This option causes stricter
  103.      ANSI C checking to be performed when compiling with GCC. The
  104.      default is for strict checking to be disabled. NOTE: This option
  105.      is intended primarily as a convenience for developers.
  106.  
  107.   --enable-gimpdir=DIR.  This option changes the default directory
  108.      the gimp uses to search for its configuration files from ~/.gimp-2.2 
  109.      (the directory .gimp-2.2 in the users home directory) to DIR.
  110.  
  111.   --without-libtiff, --without-libjpeg, --without-libpng.  configure
  112.      will bail out if libtiff, libjpeg or libpng can not be found. You
  113.      better fix the underlying problem and install these libraries with
  114.      their header files. If you absolutely want to compile GIMP without
  115.      support for TIFF, JPEG or PNG you need to explicitely disable
  116.      them using the options given above.
  117.  
  118.   --without-exif.  If libexif is available, the JPEG plug-in will use
  119.      it to keep EXIF data in your JPEG files intact.  If this is
  120.      causing any trouble at compile-time, you can build --without-exif.
  121.      Get libexif from http://www.sourceforge.net/projects/libexif.
  122.  
  123.   --without-mng, --without-aa.  The MNG plug-in needs libmng and
  124.      configure checks for its presense. If for some reason you don't
  125.      want to build the MNG plug-in even though the library is installed,
  126.      use --without-mng to disable it expliticely. The same switch exists
  127.      for aalib, use --without-aa if you run into problems.
  128.  
  129.   --with-gif-compression=[lzw|rle|none].  Allows to tune the compression
  130.      algorithm used by the GIF plug-in. If you are afraid of Unisys' LZW
  131.      patent (which should have expired in most countries by now), you
  132.      can go for simple run-length encoding or even configure the plug-in
  133.      to create uncompressed GIFs.
  134.  
  135.   --enable-gtk-doc.  This option controls whether the libgimp API
  136.      references will be created using gtk-doc. The HTML pages are 
  137.      included in a standard tarball, so you will only need this if you
  138.      are building from CVS.
  139.  
  140.   --with-html-dir=PATH.  This option allows to specify where the
  141.      libgimp API reference should be installed. You might want to modify
  142.      the path so it points to the place where glib and gtk+ installled
  143.      their API references so that the libgimp reference can link to
  144.      them.
  145.  
  146.   --disable-print.  The print plug-in requires a recent version of
  147.      libgimpprint. If you don't have it already installed, download
  148.      it from http://gimp-print.sourceforge.net/. You need to pass
  149.      --without-gimp to gimp-print's configure script to build it without
  150.      having gimp-1.2 installed. If you want to compile GIMP without
  151.      support for printing, use the --disable-print option.
  152.  
  153.   --enable-mp. This options control whether to build GIMP with or without
  154.      support for multiple processors. This option is off by default. If
  155.      you do have multiply processors and run GIMP with an OS supporting
  156.      them you will like to enable this features to use all of your
  157.      horsepower. Enabling it on singleprocessor systems won't harm but
  158.      cause a bit processing overhead.
  159.  
  160.   --with-sendmail=[PATH]. This option is used to tell GIMP where to find
  161.      the sendmail command. Normally this options don't have to be used
  162.      because configure tries to find it in the usual places.
  163.  
  164.   --with-desktop-dir=[PATH]. This option specifies where to install
  165.      links to the gimp desktop files. These files are used by desktop
  166.      environments that comply to the specs published at freedesktop.org.
  167.      The default value ${prefix}/share should be fine if your desktop
  168.      environment is installed in the same prefix as gimp. No links are
  169.      created if the desktop directories don't exist or you used
  170.      --without-desktop-dir.
  171.  
  172.   --disable-default-binary. Use this option if you don't want to make
  173.      gimp-2.2 the default gimp installation. Otherwise a link called
  174.      gimp pointing to the gimp-2.2 executable will be installed.
  175.  
  176.   --enable-gimp-console.  In addition to the standard gimp binary,
  177.      build a console-only binary which does not link GTK+ at all.
  178.  
  179.  
  180. The `make' command builds several things:
  181.  - A bunch of public libraries in the directories starting with 'libgimp'.
  182.  - The plug-in programs in the 'plug-ins' directory.
  183.  - Some modules in the 'modules' subdirectory.
  184.  - The main GIMP program 'gimp-2.2' in `app'.
  185.  
  186. The `make install' commands installs the gimp header files associated 
  187. with the libgimp libraries, the plug-ins, some data files and the GIMP 
  188. executable. After running `make install' and assuming the build process 
  189. was successful you should be able to run `gimp'.
  190.  
  191.  
  192. When ./configure fails
  193. ======================
  194.  
  195. 'configure' uses pkg-config, a tool that replaces the old foo-config
  196. scripts. The most recent version is available from 
  197.     http://www.freedesktop.org/software/pkgconfig/
  198.  
  199. 'configure' tries to compile and run a short GTK+ program. There are
  200. several reasons why this might fail:
  201.  
  202. * pkg-config could not find the file 'gtk+-2.0.pc' that gets installed 
  203.   with GTK. (This file is used to get information about where GTK+ is
  204.   installed.)
  205.  
  206.   Fix: Either make sure that this file is in the path where pkg-config 
  207.   looks for it (try 'pkg-config --debug' or add the location of 
  208.   gtk+-2.0.pc to the environment variable PKG_CONFIG_PATH before running 
  209.   configure.
  210.  
  211. * Libraries you installed are not found when you attempt to start gimp.
  212.   The details of how to fix this problem will depend on the system:
  213.  
  214.   On Linux and other systems using ELF libraries, add the directory to
  215.   holding the library to /etc/ld.so.conf or to the environment variable
  216.   LD_LIBRARY_PATH, and run 'ldconfig'.
  217.  
  218.   On other systems, it may be necessary to encode this path
  219.   into the executable, by setting the LDFLAGS environment variable
  220.   before running configure. For example:
  221.  
  222.     LDFLAGS="-R/home/joe/lib" ./configure
  223.   or
  224.     LDFLAGS="-Wl,-rpath -Wl,/home/joe/lib" ./configure
  225.  
  226. * An old version of the GTK+ libraries was found instead of 
  227.   your newly installed version. This commonly happens if a
  228.   binary package of GTK+ was previously installed on your system,
  229.   and you later compiled GTK+ from source.
  230.  
  231.   Fix: Remove the old libraries and include files.  If you are afraid
  232.   that removing the old libraries may break other packages supplied by
  233.   your distributor, you can try installing GLib, GTK+ and other
  234.   libraries in a different prefix after setting the environment
  235.   variable PKG_CONFIG_LIBDIR to point to lib/pkgconfig/ in that new
  236.   prefix so that it does not try to read the *.pc files from the
  237.   default directory (/usr/lib/pkgconfig).  However, removing the old
  238.   packages is often the easier solution.
  239.  
  240. A detailed log of the ./configure output is written to the file
  241. config.log. This may help diagnose problems.
  242.  
  243.  
  244. When ./configure fails on plug-ins
  245. ==================================
  246.  
  247. There are some GIMP plug-ins that need additional third-party libraries 
  248. installed on your system. For example to compile the plug-ins that load 
  249. and save JPEG, PNG or TIFF files you need the related libraries and header 
  250. files installed, otherwise you'll get a message that plugin xyz will not 
  251. be build. 
  252.  
  253. If you are sure that those libraries are correctly installed, but configure
  254. fails to detect them, the following might help:
  255.  
  256. Set your LDFLAGS environment variable to look for the library in a certain
  257. place, e.g. if you are working in a bash shell you would say:
  258.       export LDFLAGS="-L<path_to_library> -L<path_to_another_one>"
  259. before you run configure.
  260.  
  261. Set your CPPFLAGS environment variable to look for the header file in a
  262. certain place, e.g. if you are working in a bash shell you would say:
  263.       export CPPFLAGS="-I<path_to_header_file> -I<path_to_another_one>"
  264. before you run configure.
  265.  
  266. * If the check for gimpprint fails even though you have version 4.2.x
  267.   installed, please try the latest available 4.2 package (which is
  268.   gimp-print 4.2.7 at the time of this writing).
  269.  
  270.  
  271.       Generic Instructions for Building Auto-Configured Packages
  272.       ==========================================================
  273.  
  274.  
  275. To compile this package:
  276.  
  277. 1.  Configure the package for your system.  In the directory that this
  278. file is in, type `./configure'.  If you're using `csh' on an old
  279. version of System V, you might need to type `sh configure' instead to
  280. prevent `csh' from trying to execute `configure' itself.
  281.  
  282. The `configure' shell script attempts to guess correct values for
  283. various system-dependent variables used during compilation, and
  284. creates the Makefile(s) (one in each subdirectory of the source
  285. directory).  In some packages it creates a C header file containing
  286. system-dependent definitions.  It also creates a file `config.status'
  287. that you can run in the future to recreate the current configuration.
  288. Running `configure' takes a minute or two.
  289.  
  290. To compile the package in a different directory from the one
  291. containing the source code, you must use GNU make.  `cd' to the
  292. directory where you want the object files and executables to go and
  293. run `configure' with the option `--srcdir=DIR', where DIR is the
  294. directory that contains the source code.  Using this option is
  295. actually unnecessary if the source code is in the parent directory of
  296. the one in which you are compiling; `configure' automatically checks
  297. for the source code in `..' if it does not find it in the current
  298. directory.
  299.  
  300. By default, `make install' will install the package's files in
  301. /usr/local/bin, /usr/local/lib, /usr/local/man, etc.  You can specify
  302. an installation prefix other than /usr/local by giving `configure' the
  303. option `--prefix=PATH'.
  304.  
  305. You can specify separate installation prefixes for machine-specific
  306. files and machine-independent files.  If you give `configure' the
  307. option `--exec-prefix=PATH', the package will use PATH as the prefix
  308. for installing programs and libraries.  Normally, all files are
  309. installed using the same prefix.
  310.  
  311. `configure' ignores any other arguments that you give it.
  312.  
  313. If your system requires unusual options for compilation or linking
  314. that `configure' doesn't know about, you can give `configure' initial
  315. values for some variables by setting them in the environment.  In
  316. Bourne-compatible shells, you can do that on the command line like
  317. this:
  318.         CC='gcc -traditional' DEFS=-D_POSIX_SOURCE ./configure
  319.  
  320. The `make' variables that you might want to override with environment
  321. variables when running `configure' are:
  322.  
  323. (For these variables, any value given in the environment overrides the
  324. value that `configure' would choose:)
  325. CC              C compiler program.
  326.                 Default is `cc', or `gcc' if `gcc' is in your PATH.
  327. INSTALL         Program to use to install files.
  328.                 Default is `install' if you have it, `cp' otherwise.
  329. INCLUDEDIR      Directory for `configure' to search for include files.
  330.                 Default is /usr/include.
  331.  
  332. (For these variables, any value given in the environment is added to
  333. the value that `configure' chooses:)
  334. DEFS            Configuration options, in the form '-Dfoo -Dbar ...'
  335. LIBS            Libraries to link with, in the form '-lfoo -lbar ...'
  336.  
  337. If you need to do unusual things to compile the package, we encourage
  338. you to teach `configure' how to do them and mail the diffs to the
  339. address given in the README so we can include them in the next
  340. release.
  341.  
  342. 2.  Type `make' to compile the package.
  343.  
  344. 3.  Type `make install' to install programs, data files, and
  345. documentation.
  346.  
  347. 4.  You can remove the program binaries and object files from the
  348. source directory by typing `make clean'.  To also remove the
  349. Makefile(s), the header file containing system-dependent definitions
  350. (if the package uses one), and `config.status' (all the files that
  351. `configure' created), type `make distclean'.
  352.  
  353. The file `configure.in' is used as a template to create `configure' by
  354. a program called `autoconf'.  You will only need it if you want to
  355. regenerate `configure' using a newer version of `autoconf'.
  356.