README 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190
  1. # $Source$
  2. # $State$
  3. Installing the ACK on a modern platform
  4. =======================================
  5. This document provides some very quick and dirty instructions for installing
  6. the ACK on a modern platform. It is not intended as a substitute for the
  7. real instructions, which can be found in doc/install.pr.
  8. Let me repeat myself:
  9. THE FULL INSTALLATION INSTRUCTIONS ARE IN doc/install.pr.
  10. The ACK is a very large and complex package and has received minimal
  11. maintenance for the best part of a decade. During that time, the Unix
  12. world has moved on, and many APIs have changed. It compiles cleanly on
  13. my, dtrg's, test machine, which is a Debian Ubuntu Linux system. Your
  14. mileage may vary.
  15. All disclaimers now done, now on to the good stuff:
  16. Building the ACK
  17. ----------------
  18. I'm assuming you're using Linux here, because that's what I use. If you
  19. don't use Linux, please let me know if you have any trouble and I'll update
  20. the instructions.
  21. 1. Prerequisites
  22. The ACK wants to be built with a C compiler called cc. From what I've seen
  23. so far of the build system, this can be changed, but not easily.
  24. Most platforms have their compiler set up so that 'cc' invokes it, whatever
  25. it is; however, some don't. So far the only one I've met that doesn't do
  26. this is Solaris with gcc installed, but without the Sun native compiler.
  27. If this is the case, the simplest thing to do is to place a symlink to gcc
  28. (or your favourite C compiler) in your path somewhere. For example:
  29. ln -s /usr/bin/gcc ~/bin/cc
  30. 2. Configure the build.
  31. To do this, run the first/first script. You will be asked several
  32. questions.
  33. * What is the root of the ACK source tree?
  34. This is the directory that you have unpacked the distribution into.
  35. For example, /home/dg/src/Ack-5.6.
  36. * What is the root of the configuration tree?
  37. This is the directory that the build process will use for temporary
  38. files. You'll only need this during the compilation process; it can
  39. be removed afterwards.
  40. For example, /tmp/ack-conf
  41. * What is the root of the ACK binaries?
  42. This is the ACK's installation path; where the binaries will live.
  43. This needs to be writable during the build process --- if you want
  44. to install in /usr/local, you either have to make /usr/local
  45. writable or compile as root. Sorry!
  46. * What is your system type?
  47. Linux isn't on the list. Choose ANY.
  48. * Is this the system you are running on?
  49. Yes.
  50. * Are you satisfied?
  51. Yes.
  52. * What default machine do you wish to compile for?
  53. The ACK wants to know what architecture to target if you don't manually
  54. specify an architecture. Unfortunately, it can't generate runnable
  55. binaries for Linux or any other modern system (except possible Solaris
  56. on Sparc). I'd recommend you choose em44. This will produce portable
  57. binaries using the ACK's intermediate format, which you can run using
  58. the int interpreter.
  59. * What kind of Unix are you running?
  60. Linux is a mixture, but I pick SYS_5 and it works.
  61. * Do you wish to limit the installation?
  62. No. If you pick Yes, the script will ask detailed questions about
  63. exactly what you want to build. Modern systems are fast enough that
  64. we may as well build everything.
  65. * Which system call library do you wish to use on the VAX?
  66. I don't have a VAX; the only person I know who has one uses it to vacuum
  67. his carpets. I pick libsysV_2 with no ill effects.
  68. If the configuration script is happy, it will generate a script called
  69. INSTALL.
  70. 3. Do the compilation.
  71. The configuration script will recommend a command line. Execute this. On
  72. modern systems, the compilation doesn't take long.
  73. Check the output of the configuration script for "Failed" lines. On my
  74. system there are two:
  75. $ grep Failed INSTALL.out
  76. Failed for Intel 8080 download programs, see dl/Out
  77. Failed for Intel 8080 support
  78. You can ignore these. They aren't important.
  79. 4. Use the ACK.
  80. Ensure that the ACK's binary directory is on your path; this is /bin in
  81. the directory you specified during the configuration process. In my
  82. example, this is /usr/local/bin. The /man subdirectory should go on your
  83. manpath.
  84. To test your path, do: ack
  85. This should return silently.
  86. To test your manpath, do: man ack
  87. This will produce the documentation for the main compiler driver.
  88. If this works, you can remove the conf tree (/tmp/ack-conf in my example).
  89. Gotchas
  90. -------
  91. There are some things you should be aware of.
  92. * The ACK's archiver tool is called 'arch'. This conflicts on Linux platforms
  93. with a utility that displays the current architecture. If your compilation
  94. occasionally fails obscurely and displays something like 'i686', you are
  95. running afoul of this. As a workaround, rearrange your path so the ACK's
  96. bin directory comes first --- but do be aware that some Linux system
  97. tools may stop working.
  98. * By default, the ack tool will compile K&R C. Practically all C source these
  99. days is ANSI C --- use the -ansi switch to enable ANSI mode. No, the ACK is
  100. not C99 compatible.
  101. * Not all combinations of optimisation and architectures work. This is
  102. perfectly normal, but the combinations are not well documented. Everything
  103. supports -O.
  104. Disclaimer
  105. ----------
  106. The ACK is mature, well-tested software, but the environment in which it was
  107. developed for and tested under is rather different from that available on
  108. today's machines. There will probably be little in the way of logical bugs,
  109. but there may be many compilation and API bugs.
  110. If you wish to use the ACK, *please* join the mailing list. We are interested
  111. in any reports of success and particularly, failure. If it does fail for you,
  112. we would love to know why, in as much detail as possible. Bug fixes are even
  113. more welcome.
  114. The ACK is licensed under a BSD-like license. Please see the 'Copyright' file
  115. for the full text.
  116. You can find the mailing list on the project's web site:
  117. http://tack.sourceforge.net/
  118. Please enjoy.
  119. David Given (dtrg on Sourceforge)
  120. dg@cowlark.com
  121. 2005-06-24, 23:53
  122. # Revision history
  123. # $Log$
  124. # Revision 2.3 2006-07-18 17:21:34 dtrg
  125. # Added comment about the use of 'cc' rather than 'gcc'.
  126. #
  127. # Revision 2.2 2005/06/24 23:20:41 dtrg
  128. # Added some new readmes at the top level.