Typo
[linux_from_scratch_hints.git] / OLD / XFree86_4.2.99.4.txt
blobbb8b4e6d2fcbd0a5caf02c4768e95057db769910
1 TITLE:          XFree86 4.2.99.x for the Brave and/or Foolish
3 LFS VERSION:    4.0
5 AUTHOR:         Dagmar d'Surreal
7 EMAIL ADDRESS:  Thou shalt not spam. <`echo qntzne@fcrnxrnfl.arg | rot13`>
9 SYNOPSIS:       This hint explains how to obtain and install a beta-release
10                 copy of XFree86 from CVS.
12 EXPIRES:        2003-3-15
15 HINT:
17             *  *  *  First, a word of friendly advice  *  *  *
19   As with all software classified as being in BETA release, installation of
20   the software packages mentioned in this document is _not_ meant to be used
21   in a production environment, _nor_ is it meant for the weak of heart, _nor_
22   is it meant for beginners.  Attempting to follow the instructions contained
23   herein unsuccessfully could possibly render your system *unuseable*,
24   and the author of this document will not be responsible for it.  This
25   upgrade should not under any circumstances be considered a trivial matter.
26   You should carefully read this _entire_ document before following _any_ of
27   the instructions listed here.  Changes of this nature may not be easily
28   reversible!
30   If you happen to be a newbie, or even still smell like a newbie, you should
31   probably wait for the public release of XFree86 4.3.0 which is being
32   promised us Real Soon Now and search for a more formal set of instructions
33   then.  The only thing this document contains for you is forewarning about
34   what changes might be necessary at that future date.
36           *  *  *  Now, on to something more informative  *  *  *
38 Changelog
39 ---------
41   2003-Feb-17, Updated Appendix B with new libxml version
42                Removed reference to old Bison dependency (yay!)
43                Updated information about the "core" cursor theme
44                Pushed forward the expiry since the XFree86 team did same
45                Clarified reasons for Freetype2 symlinks in /usr/X11R6
46                Acronym cleanups
49 Overview
50 --------
52   I. Changes from 4.2.x
53   II. Quick List of Prerequisites
54   III. Obtaining the XFree86 Sources
55   IV. Configuring the Build
56   V. Compiling the Binaries
57   VI. Installing
58   VII. Configuration
59   VIII. Extra Information
61   Appendices
62   A - Zlib Compression Library
63   B - Libxml2 Library
64   C - PNG Graphics Library
65   D - Expat Library
66   E - Freetype2 Library
69 I. Changes from 4.2.x
70 ---------------------
72   XFree86 4.3.0 is a pretty sizeable change from 4.2.1 releases.  There are
73 better places (by far) to get a complete list of the changes, but the ones
74 that will be most immediately noticeable to us will be the colored cursor
75 changes, no longer having to build an external program to install one's own
76 TrueType fonts, and the lack of the expected Xft configuration file.
77 The last item in that list is a lot more dangerous than it would at first
78 seem to be.
80   The colored cursor changes are a nice feature which hasn't quite finished
81 cooking yet at the time of this writing.  The code itself appears to do
82 everything that it is supposed to do, however, the cursors themselves may
83 annoy you.  The default theme for the new cursors is called "redglass" and
84 your only other option at this time is called "whiteglass".  Although I have
85 been hearing a lot of complaints that redglass is ugly, whiteglass isn't much
86 of an option because somehow the PNG images of it that were used to make the
87 cursor files got a little broken, and some of the cursors have vertical lines
88 sliced out of them.  If you see this on your screen, now at least you'll know
89 it's not a hardware issue.  I'm sure this will be fixed in time for the final
90 release (although they'll probably still be ugly--get cracking Gimp fiends!).
91 It's not known whether or not the nVidia drivers (certainly more likely than
92 the ATI ones) will work with this release, but if you enabled the hardware
93 accellerated cursor shadow in your config, you'll probably want to go and
94 turn it off.  The shadows on these pointers are part of the image and not
95 removeable.  Two of them might look pretty weird.
97   A quick rundown on how you now go about installing TrueType fonts can be
98 covered in just three steps, provided you already have a directory named
99 /usr/X11R6/lib/X11/fonts/TrueType on your system.  First, install the font
100 file into that directory to make it accessible to everyone.  Second, in that
101 directory, run `mkfontscale`.  Thirdly, run `mkfontdir` as usual.  There
102 no more mucking around with running `xftcache` or `xset fp rehash` with this
103 release and this is a good thing.  By the way, I mentioned TrueType/ as the
104 place to install ttf fonts because /usr/X11R6/lib/X11/fonts/TTF appears to be
105 a special directory used by XFree86 which is always searched for fonts, and
106 is set up when X is installed.  If you never mess with this directory, it
107 and the fonts in it will always work, and nothing you do in the TrueType/
108 directory will be as likely to bring your display to an unreadable state.
110   The changes to the font system are, to my knowledge, one of the more wide-
111 sweeping changes for the 4.3.x release.  Some new default TTF font families
112 with strange names have been added, and Xft has been replaced with a newer
113 version that might have been called Xft2 if not for the fact that it looks
114 like instead they're going to call the old one Xft1 and the new one just Xft.
115 I know that seems confusing, and you should expect it to be confusing for
116 a while yet until they get all the kinks out.  Xft2 is not totally compatible
117 with Xft1, either, so expect packages to build against one or the other, but
118 not both.  The minor unpleasantness is that because of this, if you use
119 anything that links to or uses libXft, you'll likely have to upgrade it
120 to the next beta release of whatever it was anyway (this includes Pango and
121 Gnome!).  For the time being, however, it all seems binary-compatible enough
122 to not fall over and die when you upgrade X, but you might not be able to
123 compile new things that expect the old versions of Xft around.  (This might
124 not be entirely correct, since I had some fontconfig problems, but I haven't
125 yet seen evidence to confirm this one way or the other.  This is not something
126 you should spend more than 60 seconds worrying about tho'.)
129 II. Quick List of Pre-requisites
130 --------------------------------
132   This release of XFree86, presumably being more advanced than previous
133 versions, has a slightly larger number of things that should be installed
134 before you attempt to compile it.  Mercifully, this release isn't hampered by
135 ancient Bison syntax, so it doesn't really matter which version of Bison you
136 have installed.
138   The thing you will definitely need is CVS.  The XFree86 page mentions a
139 utility called CVSup which you should avoid like the plague.  It'll only take
140 a moment to install cvs if you don't already have it, and it requires no
141 knowledge or finesse to use.  Once tarballs are released you won't need this
142 anymore.
144   Like previous versions of XFree86, you will need to have shared library
145 versions of Freetype2 and zlib installed on the system.  Unlike previous
146 versions, this version also needs libpng, expat, and possibly libxml2 as well.
147 Libpng and Freetype2 may require additional attention on your part, so in the
148 appendices you'll find careful documentation explaining how those two should
149 be compiled to ensure they'll work.
152 III. Obtaining the XFree86 Sources
153 ----------------------------------
155   There are _no_ tarballs of the beta.  I'll save you a *huge* amount of time
156 by giving you another warning _against_ attempting to build CVSup for use in
157 obtaining the source as the XFree86.org site mentions.  Just use plain old
158 cvs to get the source unless you _already_ have CVSup (and Modula-3) on your
159 system and working.  Building Modula-3 and CVSup can make compiling the JRE
160 look easy.
162   Not only will I tell you to use cvs, I'll give you the commands you use...
164 CVSROOT=:pserver:anoncvs@anoncvs.xfree86.org:/cvs
165 export CVSROOT
166 cvs login
167 cvs -z3 checkout -A xc
169 ...if you stick #!/bin/sh in front of that, it's a perfectly useable shell
170 script.  Now find yourself a directory with about 700Mb of space free in it,
171 and run that puppy.  Enter "anoncvs" for the password and _wait_.
172 Sometimes it takes cvs awhile to get going, particularly with massive trees
173 of source code.  You should be seeing some crazy network activity already.
174 I was not joking about the 700Mb of space.  Fully 350Mb of that will be
175 source code, and it will need the rest of the space to compile.  The good
176 news is that the completed binaries will take up about the same amount of
177 space on your system as the previous version of XFree86 did.   After much
178 time has passed, you'll have a fresh set of sources to work from.
180   If you have any doubts about your compiler or expect to be doing strange
181 things to the source tree, now would be a _very_ good time to make a tarball
182 of the CVS source you just downloaded.  Normally any time you wish to update
183 your source tree you should be able to cd back into the directory _above_ the
184 xc/ directory and reissue the exact same commands as above (it'll take awhile
185 to check your files against the files on the remote server, but _far_ less
186 time than downloading the whole thing again would), however for paranoia or
187 out of habit a tarball might be handy for being able to nuke the entire
188 source tree and restoring your copy of the source to a known state of sanity.
190   
191 IV. Configuring the Build
192 -------------------------
194   While you can usually get away with skipping the creation of a a host.def
195 file to control the build process, this results in a very generic build not
196 very well matched to your system.  Once you have read the appendices and
197 ensured that the prerequisites are installed properly in your system, cd to
198 the top level source directory (xc/) and then create a file called host.def
199 in the config/cf/ directory containing the following lines
201 -----8<-----
202 #define HasFreetype2            YES
204 #define HasZlib                 YES
205 #define HasLibpng               YES
207 #define HasLibxml2              YES
209 #define HasExpat                YES
210 #define UseExpat                YES
212 #define DefaultGcc2i386Opt -O2 -fno-strength-reduce -march=i586 -mcpu=i686
213 ----->8-----
215   You may wish to edit the last line a bit with respect to the -march argument
216 but for anyone on a pentium or better these lines will work fine.  The
217 Has* directives are really all that's necessary to get XFree86 to use your
218 locally installed copies of the various libraries instead of building it's own
219 versions.  The UseExpat directive is there to enable XFree86's use of the
220 expat library for handing various things.  It appears that as long as expat
221 is present, XFree86 won't bother to use libxml2, but that may or may not be
222 entirely accurate.  In any case, we definitely want to prevent XFree86 from
223 building it's own version of libxml2 by issuing the HasLibxml2 directive. 
226 V. Compiling the Binaries
227 -------------------------
229   Once everything is ready, shake your rubber chicken over the monitor, cross
230 your fingers, and type:
232   make World 2>&1 | tee world.log
234   The build will take quite some time to complete, so be patient.  I've been
235 told that if you have already built the package once, and changes to the
236 source tree have been made (if you're familiar with the output of CVS, make
237 a log of what happens when you update your source so you can see if/when these
238 happen), you can try using `make Everything` instead of `make World` to
239 execute a partial rebuild of the sources without having the build scripts
240 methodically obliterate everything that's already been compiled.
242   If you're lucky enough for it to get all the way to the end on the first
243 try, then congratulations are in order!  If your build stops and complains
244 about undefined references to "inflate" or "deflate" then you need to re-read
245 the Appendices concerning how your library pre-requisites were installed.  If
246 you get any other kind of errors, well... this is a beta release and is not
247 actually guaranteed to compile.  Give it a few hours, re-run the cvs commands
248 to see if updates to the source tree have been made, and then try _a second
249 time_ before posting to a mailing list about it.  
252 VI. Installing
253 --------------
255   Assuming everything compiled, now would be a good time to make backups of
256 your important files, extra fonts, app-default customizations, KDM/GDM config,
257 etc.  You might also want to just make a backup of everything you're about
258 to delete on a CDR or something but that's up to you.   The one thing you
259 should definitely now do is remove _all_ your old XFree86 files.  This means
260 the following:
262 rm -rf /usr/X11R6 /usr/X11
263 rm -rf /var/X11R6 /var/X11
264 rm -rf /etc/X11
265 ldconfig
267   This way you will be certain to get a clean set of binaries that won't be
268 tripping over any leftovers from the previous install that might break things
269 for you.  Now that the way has been paved for your new installation, from the
270 xc/ directory, enter:
272 make install &&
273 make install.man &&
274 ldconfig
276   If these should stop at some point and complain about something being
277 missing (this happened to me with two unclean builds) then you may have gotten
278 a few things built out of sequence, which is no real calamity.  The first
279 thing you should try (which worked both times for me and shouldn't be likely
280 to be needed with a release tarball) is to simply cd into the subdirectory
281 where files are supposed to be missing and type just plain `make`.  If it runs
282 for a little bit, building this and that, and then ends normally, cd back to
283 the top level xc/ directory and run `make install` again.  If this doesn't
284 work, _then_ you can worry a little over it, but provided you have all the
285 requisites installed properly, you should have no problems whatsoever.
287   There is one last thing you must do, both for the sake of FHS-compliance and
288 to satisfy the whimsy of some archaic applications you might wish to compile.
289 You'll need to make some symlinks, using the commands below:
291 ln -sf /usr/X11R6/include/X11 /usr/include/X11
292 ln -sf /usr/X11R6/lib/X11 /usr/lib/X11
293 ln -sf /usr/X11R6/bin /usr/bin/X11
295   Now you can restore your fonts (although don't put anything new into the
296 /usr/X11R6/lib/X11/fonts/TTF directory!) and your app-defaults and your
297 xdm/gdm/kdm configuration files, and prepare to configure XFree86 using 
298 whatever configuration utility you normally use to create a new configuration
299 file.  As before, edit the FontPath directives to include where you installed
300 all your font files, but don't bother adding /usr/X11R6/lib/X11/TTF.  As was
301 the case with 4.2.1, this directory seems to be hard-wired as one that is
302 always searched for fonts, and can save your bacon if something goes horribly
303 wrong when you install some new broken TrueType font of your own into the
304 /usr/X11R6/lib/X11/TrueType directory.
307 VII. Configuration
308 ------------------
310   After running your usual configuration tool (`xf86cfg`, or if that fails,
311 `xf86config` is always a reliable console-only fallback) the usual caveats
312 apply to things you may have to edit.  You'll need to make sure the freetype
313 module isn't commented out by default in the new configuration file.  You'll
314 still need to add the entries for your custom font directories in the FontPath
315 section.  You may _also_ now need to edit /etc/fonts/fonts.conf and in the
316 top section add an entry for <dir>/usr/X11R6/lib/X11/fonts</dir> for the new
317 Xft2/fontconfig stuff, but only that one extra entry is needed.  Thankfully
318 this facility appears to search subdirectories without complaint.  I would
319 also recommend you do _not_ uncomment the DontZap directive so you can
320 CTL-ALT-BKSP your way out of X if something goes wrong.
322   Now that you think you have everything installed and properly configured,
323 with whatever account you'd normally use from the text console, simply run
324 `startx` and see if things start like they're supposed to.  Do not be alarmed
325 if you see a set of hideous green and white terminal windows and a clock
326 appear.  On this first attempt you're just trying to make sure the display is
327 working properly--you won't be happy if you find a problem when the machine is
328 trying to boot to runlevel 4 or 5.
330   If you're wondering where the colored mouse pointers you've heard so much
331 about went to, apparently all those radical changes have scared the XFree86
332 devs, and to prevent rioting in the streets XFree86 once again defaults to
333 the plain black-with-white-outlines set of cursors.  The new redglass and
334 whiteglass themes are still there, tho'.  If you want them, add something akin
335 to the following line to your ~/.Xdefaults file:
337 Xcursor.theme: redglass
339   At the moment, redglass and whiteglass are the only two new themes that ship
340 with the new XFree86 (get cracking, Gimp fiends!) that are meant for CRT/LCD
341 displays, and some searching of the web should turn up any further details
342 about them you might need.
343   
344   Provided you're satisfied with the way your display is working, you should
345 be able to reinstall GDM or KDM and switch your machine back to runlevel 4 or 5
346 now.  Have fun!
349                                    APPENDICES
350                                    ----------
353 Appendix A - zlib Library
354 -------------------------
356   XFree86 uses zlib compression for a number of things now.  To this end with
357 a little work we can convince it to use the system's version of the zlib
358 library, both to prevent it from installing an unnecessary version of it's
359 own into /usr/X11R6/lib and to keep other programs from screwing up later if
360 your system happens to be using a different version of zlib than XFree86
361 does.  LFS normally has you install a shared library version of zlib into
362 /usr, but just in case you missed it, here's the executive overview...
364   Get the zlib source for version 1.1.4 (current at the time of writing) from
365 http://www.libpng.org/pub/png/src/zlib-1.1.4.tar.bz2.  The md5sum for this
366 file should be ea16358be41384870acbdc372f9db152.   Untar the package somewhere
367 and run the shell script below to compile and install it with relatively
368 standard optimizations.  Note: The zlib authors have already spent quite a bit
369 of time worrying over optimizations at the assembly level.  Change PKG_ARCH
370 and PKG_CPU if you like, but don't mess with the CFLAGS setting!
372 -----8<-----
373 PKG_CPU=`uname -m`
374 PKG_ARCH=$PKG_CPU
376 CFLAGS="-fPIC -O3 -DHAVE_UNISTD_H -DUSE_MMAP -march=$PKG_ARCH -mcpu=$PKG_CPU" \
377 ./configure --prefix=/usr --shared &&
378 make &&
379 make test &&
380 make install
381 ----->8-----
384 Appendix B - libxml2 Library
385 ----------------------------
387   This library may actually not be necessary for XFree86 in light of it's
388 clear preference for the expat library, but numerous other things use it, and
389 we're very sensibly preventing XFree86 from building it's own version of this
390 library, so we might as well cover a proper way to build it.
392   Start by getting a copy of the source tarball for version 2.5.3 of libxml2
393 from http://ftp.gnome.org/pub/GNOME/sources/libxml2/2.4/libxml2-2.5.3.tar.bz2
394 which should have an md5sum of c2ee2c99309a732d0e9c32e530241012.  If you are
395 planning on using Gnome, you will need Python installed (2.2.2 works fine for
396 me) _before_ you build this library, since it will install some python
397 bindings which apparently some programs need to build.  For this reason we
398 are explicitly instructing the configure script to use both python and threads
399 and we will also do the self-tests as a sanity check.  The time to find out
400 something is wrong with this library is _now_ instead of 15 packages later,
401 because more than just this library will have to be rebuilt if this is done
402 incorrectly the first time.
404   You can use the shell script below to compile and install libxml2 2.5.3.
405 Feel free to change the optimization levels to anything you'd like.
407 -----8<-----
408 #!/bin/sh
409 PKG_CPU=`uname -m`
410 PKG_ARCH=$PKG_CPU
411 PKG_OPT="-O2 -fomit-frame-pointer"
413 CFLAGS="$PKG_OPT -march=$PKG_ARCH -mcpu=$PKG_CPU" ./configure \
414   --prefix=/usr --with-python --with-threads &&
415 make &&
416 make check && 
417 make install &&
418 ldconfig
419 ----->8-----
422 Appendix C - PNG Graphics Library
423 ---------------------------------
425   This library is necessary because it's used by parts of XFree86 to generate
426 those pretty alpha-transparencied mouse cursors.  Unfortunately at the moment
427 the latest release of the png library is _broken_ with respect to zlib, and
428 if you get any errors while building xcursorgen that mention undefined 
429 references to inflate or deflate, this is why.  You have two options:  The
430 first option being to use libpng 1.2.4 (which doesn't have this brokenness)
431 and the second (preferable) option is to apply a temporary patch found at
432 http://www.linuxfromscratch.org/~sklein/libpng-1.2.5-lz.patch to the 1.2.5
433 source tree which should eliminate the problem.  If by the time you are
434 building this 1.2.6 has been released, it will likely not be broken like this
435 and upgrading to it later is highly unlikely to have an adverse affect on 
436 XFree86.
438   Get the source from http://unc.dl.sourceforge.net/libpng/libpng-1.2.5.tar.bz2
439 (it's md5sum will report 3fc28af730f12ace49b14568de4ad934) and untar it
440 somewhere, and then use the following shell script to compile and install it
441 (after patching it, of course).  This package, like zlib, has already been
442 analyzed at length at the assembly level by it's authors, and no extra
443 optimizations you may apply are likely to do you any good.  Just be happy with
444 changing the PKG_ARCH and PKG_CPU settings.
446 -----8<-----
447 #!/bin/sh
448 PKG_CPU=`uname -m`
449 PKG_ARCH=$PKG_CPU
451 make ZLIBLIB=/usr/lib ZLIBINC=/usr/include prefix=/usr \
452   ALIGN="-march=$PKG_ARCH -mcpu=$PKG_CPU" -f scripts/makefile.linux &&
453 make prefix=/usr -f scripts/makefile.linux install &&
454 ldconfig
455 ----->8-----
458 Appendix D - Expat Library
459 --------------------------
461   This library is used by XFree86 for parsing configuration files (among other
462 things) and is apparently preferred over libxml2.  Thankfully it is very
463 straightforward to build as well.
465   The latest version of the expat library is 1.95.6 and can be obtained from
466 http://unc.dl.sourceforge.net/expat/expat-1.95.6.tar.gz.  It should have an
467 md5sum of ca78d94e83e9f077b5da2bfe28ba986a.
469   Feel free to change the optimizations used in the shell script below when
470 you install expat although the defaults should work for nearly everyone.
472 -----8<-----
473 #!/bin/sh
474 PKG_CPU=`uname -m`
475 PKG_ARCH=$PKG_CPU
476 PKG_OPT="-O2 -fomit-frame-pointer"
478 CFLAGS="$PKG_OPT -march=$PKG_ARCH -mcpu=$PKG_CPU" \
479   ./configure --prefix=/usr &&
480 make &&
481 make install &&
482 ldconfig
483 ----->8-----
484   
486 Appendix E - Freetype2 Library
487 ------------------------------
489   The Freetype2 library is used by Xft/Xft2 in XFree86 to render TrueType
490 fonts onto the display.  Without it, you don't get TrueType fonts at all, let
491 alone any anti-aliasing for them.  At the time of this writing, the latest
492 version of the Freetype2 library is 2.1.3, which is possibly the most advanced
493 version yet.  Perversely, it has the simplest compilation method.
495   One of the more useful improvements is that now the library seems to be
496 doing a much better job of handling wob/bow-ness (white text on a black field
497 versus black text on a white field) issues with anti-aliasing much more
498 gracefully.  In previous versions this caused anti-aliased text at small
499 font sizes to appear washed out and faded looking.  Considering that most
500 TrueType fonts which contain glyphs that are accessed by enabling the patent-
501 encumbered bytecode interpreter are already biased towards black text on a
502 light background, these glyphs will now look even worse in comparison to
503 what you will get without the bytecode interpreter (this translates into what
504 should be an improvement for people using light text on a dark background).
505 I highly recommend that users no longer enable the bytecode interpreter.
507   One of the caveats of version 2.1.3 of the Freetype2 library is that if
508 you attempted to get it to use the system's version of the zlib library
509 instead of linking in it's own miniature version, the result is a library
510 which is _broken_ with respect to zlib in much the same way as libpng-1.2.4
511 was.  Considering how small the size difference is (and that technically
512 calls to the shared zlib should take more time), the fact that this bug is
513 supposedly fixed in the cvs version of the library, and the trouble it would
514 take to work around it, it doesn't really make sense to attempt to turn 
515 use this feature either.  When the 2.1.4 version comes out which shouldn't
516 have this problem, users should be able to easily upgrade.  (It's possible
517 that this might even be the default behaviour in the new version, which
518 would mean the shell script below would't need any alteration.)
520   You can get a copy of the source code for the 2.1.3 version of the library
521 from http://unc.dl.sourceforge.net/freetype/freetype-2.1.3.tar.bz2 and it's
522 md5sum should be 09775a4111e066f782866d8a57d8481b.  Untar it anywhere you
523 like and build it with the shell script below.  You should be able to change
524 the optimizations used to anything you feel like.
526 -----8<----- 
527 #!/bin/sh
528 PKG_CPU=`uname -m`
529 PKG_ARCH=$PKG_CPU
530 PKG_OPT="-O2 -fomit-frame-pointer"
532 CFLAGS="$PKG_OPT -march=$PKG_ARCH -mcpu=$PKG_CPU" \
533   ./configure --prefix=/usr &&
534 make &&
535 make install &&
536 ldconfig
537 ----->8-----
539   One last note about the Freetype2 library... In the past, conflicting
540 versions of the library installed in /usr and /usr/X11R6 have caused problems
541 for some package authors which drove them to do unusual things to try to get
542 around them.  One of the more inflexible ways that were attempted was to get
543 the freetype2 headers by forcing the compiler to search /usr/X11R6/include
544 alone for them, expecting to get Freetype 2.0.6/9.  This _breaks_ when we
545 disable XFree86 building it's own version of the library.  Considering that
546 old version of Freetype2 was broken to begin with, and 2.1.3 can handle the
547 function calls without any problems, if at some point in the future you have
548 problems building things that appear to be the result of this kind of madness,
549 (which plagued the wxWindows library for some time) you can use the following
550 shell script to put symlinks into /usr/X11R6 pointing to all the parts of
551 Freetype2 in /usr.  This solves the problem and doesn't break anything in the
552 process.
554 ---------->8----------
555 #!/bin/sh
557 mkdir -p /usr/X11R6/lib &&
558 cd /usr/X11R6/lib
559 ln -s ../../lib/libfreetype.* .
560 mkdir -p /usr/X11R6/include && 
561 cd /usr/X11R6/include
562 ln -s ../../include/freetype2 .
563 ln -s ../../include/ft2build.h .
564 ----------8<----------