X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=docs%2Fbuilding.sgml;h=99a36ac872a74cb895e137c7f4a88cd39ea24af0;hb=1b7a99e3e7f64c6f402e8aece32ba0b9a3703bfa;hp=e586e6f7c25539d31d897ca957ac1787a966166e;hpb=554da8398718899e551a88fd4ced498dd7ddd413;p=ghc-hetmet.git diff --git a/docs/building.sgml b/docs/building.sgml index e586e6f..99a36ac 100644 --- a/docs/building.sgml +++ b/docs/building.sgml @@ -1,10 +1,10 @@ -
+
-Building and Installing the Glasgow Functional Programming Tools Suite +Building the Glasgow Functional Programming Tools Suite The GHC Team
glasgow-haskell-{users,bugs}@haskell.org
January 2000 @@ -172,7 +172,7 @@ manual in detail. - + Things to check before you start typing @@ -182,32 +182,26 @@ Here's a list of things to check before you get started. -Disk space neededDisk space needed: About 30MB (five hamburgers' worth) of disk space -for the most basic binary distribution of GHC; more for some -platforms, e.g., Alphas. An extra ``bundle'' (e.g., concurrent -Haskell libraries) might take you to 8–10 hamburgers. - -You'll need over 100MB (say, 20 hamburgers' worth) if you need to -build the basic stuff from scratch. - - -All of the above are estimates of disk-space needs. (I don't yet -know the disk requirements for the non-GHC tools). - +Disk space needed +Disk space needed: About 40MB (one tenth of one hamburger's worth) of disk +space for the most basic binary distribution of GHC; more for some +platforms, e.g., Alphas. An extra ``bundle'' (e.g., concurrent Haskell +libraries) might take you to up to one fifth of a hamburger. You'll need +over 100MB (say, one fifth a hamburger's worth) if you need to build the +basic stuff from scratch. All of the above are +estimates of disk-space needs. (Note: our benchmark hamburger is a standard Double Whopper with Cheese, with an RRP of UKP2.99.) Use an appropriate machine, compilers, and things. - SPARC boxes, and PCs running Linux, FreeBSD, NetBSD, or Solaris are all fully supported. Win32 and HP boxes are in pretty good shape. DEC Alphas running OSF/1, Linux or some BSD variant, MIPS and AIX boxes will need some minimal porting effort before they work (as of 4.06). gives the full run-down on ports or lack thereof. - @@ -647,14 +641,11 @@ documentation that comes with the fptools projects: DocBook, pre-supposed -All our documentation is written in SGML, using the DocBook DTD and -processed using the Cygnus DocBook -tools, which is the most shrink-wrapped SGML suite that we -could find. Unfortunately, it's only packaged as RPMs. You can use it -to generate HTML, DVI (and hence PDF and Postscript) and RTF from any -DocBook source file (including this manual). N.B. The Cygnus version of the tools is assumed. Others, such as the SuSE version, may not work. +All our documentation is written in SGML, using the DocBook DTD. +Instructions on installing and configuring the DocBook tools are in the +installation guide (in the GHC user guide). + TeX: @@ -1239,7 +1230,8 @@ programs. It also builds the necessary tools for compilation to proceed. You should say gmake boot right after configuring your build tree, but note that this is a one-off, i.e., there's no need to re-do gmake boot if you should re-configure your build tree at a later -stage (no harm caused if you do though). +stage (no harm caused if you do though). Notably, you should say +gmake boot before you say gmake clean. @@ -1272,23 +1264,56 @@ install them? That is specified by reverses the effect of install. + clean: -remove all easily-rebuilt files. - +Delete all files from the current directory that are normally created +by building the program. Don't delete the files that record the +configuration, or files generated by gmake boot. +Also preserve files that could be made by building, but normally +aren't because the distribution comes with them. + + +distclean: + +Delete all files from the current directory that are created by +configuring or building the program. If you have unpacked the source +and built the program without creating any other files, make +distclean should leave only the files that were in the +distribution. + + + + +mostlyclean: + +Like clean, but may refrain from deleting a +few files that people normally don't want to recompile. + + + -veryclean: +maintainer-clean: -remove all files that can be rebuilt at all. -There's a danger here that you may remove a file that needs a more -obscure utility to rebuild it (especially if you started from a source -distribution). - - +Delete everything from the current directory that can be reconstructed +with this Makefile. This typically includes everything deleted by +distclean, plus more: C source files produced by +Bison, tags tables, Info files, and so on. + +One exception, however: make maintainer-clean +should not delete configure even if +configure can be remade using a rule in the +Makefile. More generally, make +maintainer-clean should not delete anything that needs to +exist in order to run configure and then begin to +build the program. + + + check: @@ -1427,7 +1452,7 @@ User's Guide section on "Separate Compilation"). - + The <Filename>Makefile</Filename> architecture <IndexTerm><Primary>makefile architecture</Primary></IndexTerm> @@ -2362,61 +2387,52 @@ the canned rules being included, and conflicting with yours. porting GHC -This section is for people trying to get GHC going by using the -supplied intermediate C (.hc) files. This would probably be because -no binaries have been provided, or because the machine is not ``fully +This section is for people trying to get GHC going by using the supplied +intermediate C (.hc) files. This would probably be +because no binaries have been provided, or because the machine is not ``fully supported''. -The intermediate C files are normally made available together with a -source release, please check the announce message for exact directions -of where to find them. If we haven't made them available or you -can't find them, please ask. +The intermediate C files are normally made available together with a source +release, please check the announce message for exact directions of where to +find them. If we haven't made them available or you can't find them, please +ask. -Assuming you've got them, unpack them on top of a fresh source tree. -Then follow the `normal' instructions in for setting -up a build tree. When you invoke the configure script, you'll have -to tell the script about your intentions: +Assuming you've got them, unpack them on top of a fresh source tree. This +will place matching .hc files next to the corresponding +Haskell source in the compiler subdirectory ghc and in +the language package of hslibs (i.e., in hslibs/lang). +Then follow the `normal' instructions in for setting up a build tree. - +The actual build process is fully automated by the +hc-build script located in the +distrib directory. If you eventually want to install GHC +into the directory INSTALL_DIRECTORY, the following +command will execute the whole build process (it won't install yet): + -foo% ./configure --enable-hc-boot +foo% distrib/hc-build --prefix=INSTALL_DIRECTORY - ---enable-hc-boot ---disable-hc-boot - - +--hc-build -Assuming it configures OK and you don't need to create mk/build.mk -for any other purposes, the next step is to proceed with a make boot -followed by make all. At the successful completion of make all, -you should end up with a binary of the compiler proper, -ghc/compiler/hsc, plus archives (but no .hi files!) of the prelude -libraries. To generate the Prelude interface files (and test drive the -bootstrapped compiler), re-run the configure script, but this time -without the option. After that re-create the -contents of ghc/lib: +By default, the installation directory is /usr/local. If +that is what you want, you may omit the argument to +hc-build. Generally, any option given to +hc-build is passed through to the configuration script +configure. If hc-build +successfully completes the build process, you can install the resulting +system, as normal, with - - - -foo% ./configure - .... -foo% cd ghc/lib -foo% make clean -foo% make boot -foo% make all +foo% make install - - That's the mechanics of the boot process, but, of course, if you're trying to boot on a platform that is not supported and significantly