README 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166
  1. THE AMSTERDAM COMPILER KIT V6.0pre4
  2. ===================================
  3. © 1987-2005 Vrije Universiteit, Amsterdam 2010-08-08
  4. INTRODUCTION
  5. ============
  6. The Amsterdam Compiler Kit is a complete compiler toolchain consisting of
  7. front end compilers for a number of different languages, code generators,
  8. support libraries, and all the tools necessary to go from source code to
  9. executable on any of the platforms it supports.
  10. This is an early prerelease of the apocryphal version 6.0 release. Not a
  11. lot is supported, the build mechanism needs work, and a lot of things are
  12. probably broken. However, what's there should be sufficient to get things
  13. done and to evaluate how the full 6.0 release should work.
  14. SUPPORT
  15. =======
  16. Languages:
  17. ANSI C, Pascal, Modula 2. K&R is supported via the ANSI C compiler.
  18. Platforms:
  19. pc86 produces bootable floppy disk images for 8086 PCs
  20. linux386 produces ELF executables for PC Linux systems
  21. cpm produces i80 CP/M .COM files
  22. INSTALLATION
  23. ============
  24. The version 6.0 build mechanism has been completely rewritten and is based
  25. around the Prime Mover build tool (see http://primemover.sf.net for more
  26. information). Installation ought to be fairly straightforward.
  27. Requirements:
  28. - an ANSI C compiler. Currently, I'm afraid, it's hard-coded to use gcc.
  29. To change, try changing the variable definitions in first/c.pm. This also
  30. needs to be available as 'cc' from the shell.
  31. - about 20MB free in /tmp (or some other temporary directory).
  32. - about 6MB in the target directory.
  33. Instructions:
  34. - edit config.pm. There's a small section at the top containing some editable
  35. variables. Probably the only one you may want to edit is PREFIX, which
  36. changes where the ACK installs to.
  37. - Run:
  38. ./pm configure
  39. ...from the command line. This will write out a configuration file.
  40. - Run:
  41. ./pm
  42. ...from the command line. This will actually do the build. This takes
  43. about two minutes on my 1.6GHz Athlon Linux machine and about 30 on my
  44. 166MHz Pentium OpenBSD machine.
  45. - Run:
  46. ./pm install
  47. ...from the command line (possibly with sudo). This will install the built
  48. ACK into whatever directory you nominated in PREFIX.
  49. The ACK should now be ready to use.
  50. USAGE
  51. =====
  52. Currently I haven't sorted out all the documentation --- it's supplied in the
  53. distribution, but not all of it gets installed yet --- so here is a quickstart
  54. guide.
  55. The main command to use is 'ack'. This invokes the compiler and the linker.
  56. Some useful options include:
  57. -m<platform> build for the specified platform
  58. -o <file> specifies the output file
  59. -c produce a .o file
  60. -c.s produce a .s assembly file
  61. -O enable optimisation
  62. -ansi compile ANSI C (when using the C compiler)
  63. <file> build file
  64. ack figures out which language to use from the file extension:
  65. .c C (ANSI or K&R)
  66. .b Basic
  67. .mod Modula-2
  68. .ocm Occam 1
  69. .p Pascal
  70. .o object files
  71. .s assembly files
  72. For further information, see the man page (which actually does get
  73. installed, but is rather out of date).
  74. There are some (known working) example programs in the 'examples' directory.
  75. A sample command line is:
  76. ack -mlinux386 -O examples/paranoia.c
  77. GOTCHAS
  78. =======
  79. There are some things you should be aware of.
  80. - Look at plat/<PLATFORMNAME>/README for information about the two supported
  81. platforms.
  82. - The library support is fairly limited; for C, it's at roughly the ANSI C
  83. level, and for the other languages it's similar.
  84. - When compiling languages other than C, the ACK will usually look at the
  85. first character of the file. If it's a #, then the file will be run through
  86. the C preprocessor anyway.
  87. - BSD systems may need to up the number of file descriptors (e.g.
  88. 'ulimit -n 200') before the ACK will compile.
  89. - The ACK uses its own .o format. You won't be able to mix the ACK's object
  90. files and another compiler's.
  91. DISCLAIMER
  92. ==========
  93. The ACK is mature, well-tested software, but the environment in which it was
  94. developed for and tested under is rather different from that available on
  95. today's machines. There will probably be little in the way of logical bugs,
  96. but there may be many compilation and API bugs.
  97. If you wish to use the ACK, *please* join the mailing list. We are interested
  98. in any reports of success and particularly, failure. If it does fail for you,
  99. we would love to know why, in as much detail as possible. Bug fixes are even
  100. more welcome.
  101. The ACK is licensed under a BSD-like license. Please see the 'Copyright' file
  102. for the full text.
  103. You can find the mailing list on the project's web site:
  104. http://tack.sourceforge.net/
  105. Please enjoy.
  106. David Given (dtrg on Sourceforge)
  107. dg@cowlark.com
  108. 2010-08-08