INSTALL 17 KB

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