patches/uClibc/0.9.30.2/290-blackfin-nommu-fork-stub.patch
author "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
Mon Dec 12 21:41:16 2011 +0200 (2011-12-12)
branch1.13
changeset 2845 0dc9d4931246
permissions -rw-r--r--
scripts: unset CONFIG_SITE

Some distributions (eg. openSUSE 12.1) systematically export
the CONFIG_SITE environment variable to point to a custom
script setting misc paths for ./configure.

This can, and does, break when cross-compiling for architectures
that are not supported by this script.

The simple workaround is to unset this variable.
NB: buildroot has a similar fix:
http://git.buildroot.org/buildroot/commit/?id=12c9f7dd6dee9c6029b4f9a12d6aac1516911ab4

Reported-by: Trevor Woerner <twoerner@gmail.com>
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@anciens.enib.fr>
(transplanted from 21f4f28e60ec0342133086c9a51e7f0e5b181fb8)
     1 From: Jie Zhang <jie.zhang@analog.com>
     2 Date: Mon, 1 Jun 2009 07:25:42 +0000 (+0000)
     3 Subject: Backport UCLIBC_HAS_STUBS config option from the upstream. This option makes uClibc... 
     4 X-Git-Url: http://blackfin.uclinux.org/git/?p=readonly-mirrors%2Ftoolchain.git;a=commitdiff_plain;h=cacea6b12bae6f6cfd08e2bbec536e9b23b342f5
     5 
     6 Backport UCLIBC_HAS_STUBS config option from the upstream. This option makes uClibc provide fork() stub on NOMMU targets. It's default off.
     7 
     8 
     9 git-svn-id: svn://localhost/svn/toolchain/trunk@3417 2adf4935-75e9-4407-93b2-34b21a1880a4
    10 ---
    11 
    12 Index: uClibc-0.9.30.2/libc/unistd/daemon.c
    13 ===================================================================
    14 --- uClibc-0.9.30.2.orig/libc/unistd/daemon.c	2010-01-13 22:22:31.000000000 +0100
    15 +++ uClibc-0.9.30.2/libc/unistd/daemon.c	2010-04-06 22:04:11.000000000 +0200
    16 @@ -55,7 +55,6 @@
    17  libc_hidden_proto(dup2)
    18  libc_hidden_proto(setsid)
    19  libc_hidden_proto(chdir)
    20 -libc_hidden_proto(fork)
    21  
    22  #ifndef __ARCH_USE_MMU__
    23  #include <sys/syscall.h>
    24 @@ -85,6 +84,8 @@
    25  	return ret;
    26  }
    27  #else
    28 +libc_hidden_proto(fork)
    29 +
    30  static inline pid_t fork_parent(void)
    31  {
    32  	switch (fork()) {