⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 install

📁 早期freebsd实现
💻
📖 第 1 页 / 共 4 页
字号:
Installing GNU CC on VMS=========================   The VMS version of GNU CC is distributed in a backup savesetcontaining both source code and precompiled binaries.   To install the `gcc' command so you can use the compiler easily, inthe same manner as you use the VMS C compiler, you must install the VMSCLD file for GNU CC as follows:  1. Define the VMS logical names `GNU_CC' and `GNU_CC_INCLUDE' to     point to the directories where the GNU CC executables     (`gcc-cpp.exe', `gcc-cc1.exe', etc.) and the C include files are     kept respectively.  This should be done with the commands:          $ assign /system /translation=concealed -            disk:[gcc.] gnu_cc          $ assign /system /translation=concealed -            disk:[gcc.include.] gnu_cc_include     with the appropriate disk and directory names.  These commands can     be placed in your system startup file so they will be executed     whenever the machine is rebooted.  You may, if you choose, do this     via the `GCC_INSTALL.COM' script in the `[GCC]' directory.  2. Install the `GCC' command with the command line:          $ set command /table=sys$common:[syslib]dcltables -            /output=sys$common:[syslib]dcltables gnu_cc:[000000]gcc          $ install replace sys$common:[syslib]dcltables  3. To install the help file, do the following:          $ library/help sys$library:helplib.hlb gcc.hlp     Now you can invoke the compiler with a command like `gcc /verbose     file.c', which is equivalent to the command `gcc -v -c file.c' in     Unix.   If you wish to use GNU C++ you must first install GNU CC, and thenperform the following steps:  1. Define the VMS logical name `GNU_GXX_INCLUDE' to point to the     directory where the preprocessor will search for the C++ header     files. This can be done with the command:          $ assign /system /translation=concealed -            disk:[gcc.gxx_include.] gnu_gxx_include     with the appropriate disk and directory name.  If you are going to     be using libg++, this is where the libg++ install procedure will     install the libg++ header files.  2. Obtain the file `gcc-cc1plus.exe', and place this in the same     directory that `gcc-cc1.exe' is kept.     The GNU C++ compiler can be invoked with a command like `gcc /plus     /verbose file.cc', which is equivalent to the command `g++ -v -c     file.cc' in Unix.   We try to put corresponding binaries and sources on the VMSdistribution tape.  But sometimes the binaries will be from an olderversion than the sources, because we don't always have time to updatethem.  (Use the `/version' option to determine the version number ofthe binaries and compare it with the source file `version.c' to tellwhether this is so.)  In this case, you should use the binaries you getto recompile the sources.  If you must recompile, here is how:  1. Execute the command procedure `vmsconfig.com' to copy files     `vax-vms.h', `xm-vax-vms.h', `vax.c' and `vax.md' to `tm.h',     `config.h', `aux-output.c', and `md.' respectively, and to create     files `tconfig.h' and `hconfig.h'.  This procedure also creates     several linker option files used by `make-cc1.com' and a data file     used by `make-l2.com'.          $ @vmsconfig.com  2. Setup the logical names and command tables as defined above.  In     addition, define the VMS logical name `GNU_BISON' to point at the     to the directories where the Bison executable is kept.  This     should be done with the command:          $ assign /system /translation=concealed -            disk:[bison.] gnu_bison     You may, if you choose, use the `INSTALL_BISON.COM' script in the     `[BISON]' directory.  3. Install the `BISON' command with the command line:          $ set command /table=sys$common:[syslib]dcltables -            /output=sys$common:[syslib]dcltables -            gnu_bison:[000000]bison          $ install replace sys$common:[syslib]dcltables  4. Type `@make-gcc' to recompile everything (alternatively, you may     submit the file `make-gcc.com' to a batch queue).  If you wish to     build the GNU C++ compiler as well as the GNU CC compiler, you must     first edit `make-gcc.com' and follow the instructions that appear     in the comments.  5. In order to use GCC, you need a library of functions which GCC     compiled code will call to perform certain tasks, and these     functions are defined in the file `libgcc2.c'.  To compile this     you should use the command procedure `make-l2.com', which will     generate the library `libgcc2.olb'. `libgcc2.olb' should be built     using the compiler built from the same distribution that     `libgcc2.c' came from, and `make-gcc.com' will automatically do     all of this for you.     To install the library, use the following commands:          $ library gnu_cc:[000000]gcclib/delete=(new,eprintf)          $ library libgcc2/extract=*/output=libgcc2.obj          $ library gnu_cc:[000000]gcclib libgcc2.obj     The first command simply removes old modules that will be replaced     with modules from libgcc2.  If the VMS librarian complains about     those modules not being present, simply ignore the message and     continue on with the next command.     Whenever you update the compiler on your system, you should also     update the library with the above procedure.  6. You may wish to build GCC in such a way that no files are written     to the directory where the source files reside.  An example would     be the when the source files are on a read-only disk.  In these     cases, execute the following DCL commands (substituting your     actual path names):          $ assign dua0:[gcc.build_dir.]/translation=concealed, -                   dua1:[gcc.source_dir.]/translation=concealed  gcc_build          $ set default gcc_build:[000000]     where `dua1:[gcc.source_dir]' contains the source code, and     `dua0:[gcc.build_dir]' is meant to contain all of the generated     object files and executables.  Once you have done this, you can     proceed building GCC as described above.  (Keep in mind that     `gcc_build' is a rooted logical name, and thus the device names in     each element of the search list must be an actual physical device     name rather than another rooted logical name).  7. *If you are building GNU CC with a previous version of GNU CC, you     also should check to see that you have the newest version of the     assembler*.  In particular, GNU CC version 2 treats global constant     variables slightly differently from GNU CC version 1, and GAS     version 1.38.1 does not have the patches required to work with GCC     version 2. If you use GAS 1.38.1, then `extern const' variables     will not have the read-only bit set, and the linker will generate     warning messages about mismatched psect attributes for these     variables.  These warning messages are merely a nuisance, and can     safely be ignored.     If you are compiling with a version of GNU CC older than 1.33,     specify `/DEFINE=("inline=")' as an option in all the     compilations.  This requires editing all the `gcc' commands in     `make-cc1.com'. (The older versions had problems supporting     `inline'.)  Once you have a working 1.33 or newer GNU CC, you can     change this file back.  8. If you want to build GNU CC with the VAX C compiler, you will need     to make minor changes in `make-cccp.com' and `make-cc1.com' to     choose alternate definitions of `CC', `CFLAGS', and `LIBS'.  See     comments in those files.  However, you must also have a working     version of the GNU assembler (GNU as, aka GAS) as it is used as     the back-end for GNU CC to produce binary object modules and is     not included in the GNU CC sources.  GAS is also needed to compile     `libgcc2' in order to build `gcclib' (see above); `make-l2.com'     expects to be able to find it operational in     `gnu_cc:[000000]gnu-as.exe'.     To use GNU CC on VMS, you need the VMS driver programs `gcc.exe',     `gcc.com', and `gcc.cld'.  They are distributed with the VMS     binaries (`gcc-vms') rather than the GNU CC sources.  GAS is also     included in `gcc-vms', as is Bison.     Once you have successfully built GNU CC with VAX C, you should use     the resulting compiler to rebuild itself.  Before doing this, be     sure to restore the `CC', `CFLAGS', and `LIBS' definitions in     `make-cccp.com' and `make-cc1.com'.  The second generation     compiler will be able to take advantage of many optimizations that     must be suppressed when building with other compilers.   Under previous versions of GNU CC, the generated code wouldoccasionally give strange results when linked with the sharable`VAXCRTL' library. Now this should work.   Even with this version, however, GNU CC itself should not be linkedwith the sharable `VAXCRTL'.  The version of `qsort' in `VAXCRTL' has abug (known to be present in VMS versions V4.6 through V5.5) whichcauses the compiler to fail.   The executables that are generated by `make-cc1.com' and`make-cccp.com' use the object library version of `VAXCRTL' in order tomake use of the `qsort' routine in `gcclib.olb'.  If you wish to linkthe compiler executables with the shareable image version of `VAXCRTL',you should edit the file `tm.h' (created by `vmsconfig.com') to definethe macro `QSORT_WORKAROUND'.   `QSORT_WORKAROUND' is always defined when GNU CC is compiled withVAX C, to avoid a problem in case `gcclib.olb' is not yet available.Installing GNU CC on the WE32K===============================   These computers are also known as the 3b2, 3b5, 3b20 and othersimilar names.  (However, the 3b1 is actually a 68000; see *Note 3b1Install::.)   Don't use `-g' when compiling with the system's compiler.  Thesystem's linker seems to be unable to handle such a large program withdebugging information.   The system's compiler runs out of capacity when compiling `stmt.c'in GNU CC.  You can work around this by building `cpp' in GNU CC first,then use that instead of the system's preprocessor with the system's Ccompiler to compile `stmt.c'.  Here is how:     mv /lib/cpp /lib/cpp.att     cp cpp /lib/cpp.gnu     echo "/lib/cpp.gnu -traditional $*" > /lib/cpp     chmod +x /lib/cpp   The system's compiler produces bad code for some of the GNU CCoptimization files.  So you must build the stage 2 compiler withoutoptimization.  Then build a stage 3 compiler with optimization. Thatexecutable should work.  Here are the necessary commands:     make LANGUAGES=c CC=stage1/xgcc CFLAGS="-Bstage1/ -g"     make stage2     make CC=stage2/xgcc CFLAGS="-Bstage2/ -g -O"   You may need to raise the ULIMIT setting to build a C++ compiler, asthe file `cc1plus' is larger than one megabyte.Installing GNU CC on the MIPS==============================   See *Note Installation:: about whether to use `--with-stabs' or not.   The MIPS C compiler needs to be told to increase its table size forswitch statements with the `-Wf,-XNg1500' option in order to compile`cp-parse.c'.  If you use the `-O2' optimization option, you also needto use `-Olimit 3000'. Both of these options are automaticallygenerated in the `Makefile' that the shell script `configure' builds.If you override the `CC' make variable and use the MIPS compilers, youmay need to add `-Wf,-XNg1500 -Olimit 3000'.   MIPS computers running RISC-OS can support four differentpersonalities: default, BSD 4.3, System V.3, and System V.4 (olderversions of RISC-OS don't support V.4).  To configure GCC for theseplatforms use the following configurations:`mips-mips-riscos`rev''     Default configuration for RISC-OS, revision `rev'.`mips-mips-riscos`rev'bsd'     BSD 4.3 configuration for RISC-OS, revision `rev'.`mips-mips-riscos`rev'sysv4'     System V.4 configuration for RISC-OS, revision `rev'.`mips-mips-riscos`rev'sysv'     System V.3 configuration for RISC-OS, revision `rev'.   The revision `rev' mentioned above is the revision of RISC-OS touse.  You must reconfigure GCC when going from a RISC-OS revision 4 toRISC-OS revision 5.  This has the effect of avoiding a linker bug.   DECstations can support three different personalities: Ultrix, DECOSF/1, and OSF/rose.  To configure GCC for these platforms use thefollowing configurations:`decstation-ultrix'     Ultrix configuration.`decstation-osf1'     Dec's version of OSF/1.`decstation-osfrose'     Open Software Foundation reference port of OSF/1 which uses the     OSF/rose object file format instead of ECOFF.  Normally, you would     not select this configuration.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -