summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrillig <rillig>2005-11-24 10:08:00 +0000
committerrillig <rillig>2005-11-24 10:08:00 +0000
commit9fd9523366be6bdce73a02531a5522cd31070a4c (patch)
tree5055e551c870f20c1a7e46b31e853c4dc4b0998d
parent0bd98631586c69fbd7deba6f4ec57f74635f64cb (diff)
downloadpkgsrc-9fd9523366be6bdce73a02531a5522cd31070a4c.tar.gz
regen.
-rw-r--r--doc/pkgsrc.html63
-rw-r--r--doc/pkgsrc.txt33
2 files changed, 67 insertions, 29 deletions
diff --git a/doc/pkgsrc.html b/doc/pkgsrc.html
index c14430f4828..eb2e9d88d15 100644
--- a/doc/pkgsrc.html
+++ b/doc/pkgsrc.html
@@ -12960,22 +12960,22 @@ nbftp% <strong class="userinput"><code>chmod 755 .</code></strong>
these macros are usually ones that describe the target
CPU and operating system. Depending of which of the
macros are defined, you can write code that uses
- features unique to a specific platform. The best way to
- handle these differences is to use the GNU autotools
- (automake, autoconf, etc.) to check for specific
- features (like the existence of a header file, a
- function or a library).</p>
-
- <p>If that is not possible you can use the predefined
- macros below to configure your code to the platform it
- runs on. Almost every operating system, hardware
- architecture and compiler has its own macro. For
- example, if the macros <code class=
- "varname">__GNUC__</code>, <code class=
- "varname">__i386__</code> and <code class=
+ features unique to a specific platform. Generally you
+ should rather use the GNU autotools (automake,
+ autoconf, etc.) to check for specific features (like
+ the existence of a header file, a function or a
+ library), but sometimes this is not possible or
+ desired.</p>
+
+ <p>In that case you can use the predefined macros below
+ to configure your code to the platform it runs on.
+ Almost every operating system, hardware architecture
+ and compiler has its own macro. For example, if the
+ macros <code class="varname">__GNUC__</code>,
+ <code class="varname">__i386__</code> and <code class=
"varname">__NetBSD__</code> are all defined, you know
- that you are using NetBSD on an Intel CPU, and your
- compiler is GCC.</p>
+ that you are using NetBSD on an i386 compatible CPU,
+ and your compiler is GCC.</p>
<div class="sect3" lang="en" xml:lang="en">
<div class="titlepage">
@@ -13072,12 +13072,29 @@ nbftp% <strong class="userinput"><code>chmod 755 .</code></strong>
<div class="variablelist">
<dl>
- <dt><span class="term">SunPro 5.7 + Solaris 8 +
- SPARC</span></dt>
+ <dt><span class="term">GCC 3.3.3 + SuSE Linux 9.1 +
+ i386</span></dt>
<dd>
- <p>__SVR4, __sparc, __sun, __unix, sparc, sun,
- unix.</p>
+ <p>__ELF__, __gnu_linux__, __i386, _i386__,
+ __linux, __linux__, __unix, __unix__, i386,
+ linux, unix.</p>
+ </dd>
+
+ <dt><span class="term">GCC 2.95 + NetBSD 1.6.2 +
+ i386</span></dt>
+
+ <dd>
+ <p>__ELF__, __NetBSD__, __i386, _i386__,
+ i386.</p>
+ </dd>
+
+ <dt><span class="term">GCC 3.3.3 + NetBSD 2.0 +
+ i386</span></dt>
+
+ <dd>
+ <p>__ELF__, __NetBSD__, __i386, _i386__,
+ i386.</p>
</dd>
<dt><span class="term">GCC 4 + Solaris 8 +
@@ -13088,6 +13105,14 @@ nbftp% <strong class="userinput"><code>chmod 755 .</code></strong>
__SVR4, __svr4__, __unix, __unix__, sparc, sun,
unix.</p>
</dd>
+
+ <dt><span class="term">SunPro 5.7 + Solaris 8 +
+ SPARC</span></dt>
+
+ <dd>
+ <p>__SVR4, __sparc, __sun, __unix, sparc, sun,
+ unix.</p>
+ </dd>
</dl>
</div>
</div>
diff --git a/doc/pkgsrc.txt b/doc/pkgsrc.txt
index 18fada4b7ee..680738154d7 100644
--- a/doc/pkgsrc.txt
+++ b/doc/pkgsrc.txt
@@ -4933,15 +4933,15 @@ The C preprocessor has a set of predefined macros that can be queried by using
#ifdef FOO or #if defined(FOO). Among these macros are usually ones that
describe the target CPU and operating system. Depending of which of the macros
are defined, you can write code that uses features unique to a specific
-platform. The best way to handle these differences is to use the GNU autotools
-(automake, autoconf, etc.) to check for specific features (like the existence
-of a header file, a function or a library).
+platform. Generally you should rather use the GNU autotools (automake,
+autoconf, etc.) to check for specific features (like the existence of a header
+file, a function or a library), but sometimes this is not possible or desired.
-If that is not possible you can use the predefined macros below to configure
-your code to the platform it runs on. Almost every operating system, hardware
-architecture and compiler has its own macro. For example, if the macros
-__GNUC__, __i386__ and __NetBSD__ are all defined, you know that you are using
-NetBSD on an Intel CPU, and your compiler is GCC.
+In that case you can use the predefined macros below to configure your code to
+the platform it runs on. Almost every operating system, hardware architecture
+and compiler has its own macro. For example, if the macros __GNUC__, __i386__
+and __NetBSD__ are all defined, you know that you are using NetBSD on an i386
+compatible CPU, and your compiler is GCC.
15.4.1.1. CPP defines for operating systems
@@ -4984,15 +4984,28 @@ that may help you to choose the right ones. For example, if you want to
conditionally compile code on Solaris, don't use __sun__, as the SunPro
compiler does not define it. Use __sun instead.
-SunPro 5.7 + Solaris 8 + SPARC
+GCC 3.3.3 + SuSE Linux 9.1 + i386
- __SVR4, __sparc, __sun, __unix, sparc, sun, unix.
+ __ELF__, __gnu_linux__, __i386, _i386__, __linux, __linux__, __unix,
+ __unix__, i386, linux, unix.
+
+GCC 2.95 + NetBSD 1.6.2 + i386
+
+ __ELF__, __NetBSD__, __i386, _i386__, i386.
+
+GCC 3.3.3 + NetBSD 2.0 + i386
+
+ __ELF__, __NetBSD__, __i386, _i386__, i386.
GCC 4 + Solaris 8 + SPARC
__ELF__, __sparc, __sparc__, __sun, __sun__, __SVR4, __svr4__, __unix,
__unix__, sparc, sun, unix.
+SunPro 5.7 + Solaris 8 + SPARC
+
+ __SVR4, __sparc, __sun, __unix, sparc, sun, unix.
+
15.4.3. Getting a list of CPP defines
If your system uses the GNU C Compiler, you can get a list of symbols that are