From edb49293b492ce674e45e27220d55bbec3e0fc90 Mon Sep 17 00:00:00 2001 From: rillig Date: Thu, 8 Feb 2007 23:25:10 +0000 Subject: CPP should not be set to /usr/ccs/bin/cpp. Building 64-bit binaries on Solaris/SPARC is no longer tricky. --- doc/guide/files/platforms.xml | 87 +++++++++++-------------------------------- 1 file changed, 22 insertions(+), 65 deletions(-) (limited to 'doc/guide') diff --git a/doc/guide/files/platforms.xml b/doc/guide/files/platforms.xml index d88edfb93e1..d46cc5d0116 100644 --- a/doc/guide/files/platforms.xml +++ b/doc/guide/files/platforms.xml @@ -1,4 +1,4 @@ - + Using pkgsrc on systems other than &os; @@ -795,81 +795,38 @@ file and inspect the contents before extracting it. - Sun WorkShop Compilers common components - You should set CC, CXX and - optionally, CPP in /etc/mk.conf, - e.g.: + You should set the following variables in your + mk.conf file: - - CC= cc - CXX= CC - CPP= /usr/ccs/lib/cpp - + + CC= cc + CXX= CC + CPP= cc -E + CXXCPP= CC -E + + + The CPP setting might break some + packages that use the C preprocessor for processing things other + than C source code. Building 64-bit binaries with SunPro - Building 64-bit binaries is a little trickier. First, you - need to bootstrap pkgsrc in 64-bit mode. One problem here is - that while building one of the programs in the bootstrap kit - (bmake), the CFLAGS - variable is not honored, even if it is set in the environment. - To work around this bug, you can create a simple shell script - called cc64 and put it somewhere in the - PATH: - - - #! /bin/sh - exec /opt/SUNWspro/bin/cc -xtarget=ultra -xarch=v9 ${1+"$@"} - - - Then, pass the definition for CC in the - environment of the bootstrap command: - - - &uprompt; cd bootstrap - &uprompt; CC=cc64 ./bootstrap - - - After bootstrapping, there are two alternative ways, - depending on whether you want to find bugs in packages or get - your system ready quickly. If you just want a running system, - add the following lines to your mk.conf - file: - - - CC= cc64 - CXX= CC64 - PKGSRC_COMPILER= sunpro - - - This way, all calls to the compiler will be intercepted by - the above wrapper and therefore get the necessary ABI options - automatically. (Don't forget to create the shell script - CC64, too.) - - To find packages that ignore the user-specified - CFLAGS and CXXFLAGS, add - the following lines to your mk.conf + To build 64-bit packages, you just need to have the + following lines in your mk.conf file: - - CC= cc - CXX= CC - PKGSRC_COMPILER= sunpro - CFLAGS= -xtarget=ultra -xarch=v9 - CXXFLAGS= -xtarget=ultra -xarch=v9 - LDFLAGS= -xtarget=ultra -xarch=v9 - + + PKGSRC_COMPILER= sunpro + ABI= 64 + - Packages that don't use the flags provided in the - configuration file will try to build 32-bit binaries and fail - during linking. Detecting this is useful to prevent bugs on - other platforms where the error would not show up but pass - silently. + This setting has been tested for the SPARC + architecture. Intel and AMD machines need some more + work. - Common problems Sometimes, when using libtool, -- cgit v1.2.3