summaryrefslogtreecommitdiff
path: root/hurd/porting/guidelines.mdwn
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2011-08-25 10:44:26 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2011-08-25 10:44:26 +0200
commitb62db0d2e9f8311c74d2de7439ea5ea07bfe8272 (patch)
treee499ec51a137c629b22eb6bad48cc4ed318b4dbd /hurd/porting/guidelines.mdwn
parent8d29e149a8cbbf4503bb5ee259566a1da864bc6c (diff)
Document autoconf host_os tests
Diffstat (limited to 'hurd/porting/guidelines.mdwn')
-rw-r--r--hurd/porting/guidelines.mdwn23
1 files changed, 23 insertions, 0 deletions
diff --git a/hurd/porting/guidelines.mdwn b/hurd/porting/guidelines.mdwn
index 8f21a64f..0a9c133a 100644
--- a/hurd/porting/guidelines.mdwn
+++ b/hurd/porting/guidelines.mdwn
@@ -23,6 +23,29 @@ You may ask on the [[mailing lists/bug-hurd]] mailing list for details or
questions about fixing bugs.
+## <a name="autoconf"> Fixing configure.ac/in </a>
+
+The GNU/Hurd (and GNU/kFreeBSD) toolchain is extremely close to the GNU/Linux toolchain.
+configure.ac thus very often just needs to be fixed by using the same cases as Linux, that is, turn
+
+ switch "$host_os" in
+ case linux*)
+
+into
+
+ switch "$host_os" in
+ case linux*|k*bsd-gnu|gnu*)
+
+for a host_os case statement, or
+
+ switch "$host" in
+ case *-linux*)
+
+into
+
+ switch "$host" in
+ case *-linux*|*-k*bsd-gnu|*-gnu*)
+
## <a name="Undefined_bits_confname_h_tt_mac"> Undefined `bits/confname.h` macros (`PIPE_BUF`, ...) </a>
If macro `XXX` is undefined, but macro `_SC_XXX` or `_PC_XXX` is defined in `bits/confname.h`, you probably need to use `sysconf`, `pathconf` or `fpathconf` to obtain it dynamicaly.