Browse Source

sync uClibc patches, use only git for uCLibc-ng for now.

Waldemar Brodkorb 11 years ago
parent
commit
75f6c379c5

+ 1 - 6
target/config/Config.in.libc.choice

@@ -45,7 +45,7 @@ config ADK_TARGET_LIB_GLIBC
 	  http://www.gnu.org/libc
 	  http://www.gnu.org/libc
 
 
 config ADK_TARGET_LIB_UCLIBC
 config ADK_TARGET_LIB_UCLIBC
-	prompt "uClibc embedded C library (deprecated)"
+	prompt "uClibc embedded C library"
 	boolean
 	boolean
 	select ADK_uclibc
 	select ADK_uclibc
 	depends on \
 	depends on \
@@ -64,11 +64,6 @@ choice
 prompt "Target C library version"
 prompt "Target C library version"
 depends on !ADK_CHOOSE_TARGET_SYSTEM && !ADK_CHOOSE_TARGET_ARCH
 depends on !ADK_CHOOSE_TARGET_SYSTEM && !ADK_CHOOSE_TARGET_ARCH
 
 
-config ADK_TARGET_LIB_UCLIBC_NG_1_0_0
-	prompt "1.0.0rc1"
-	boolean
-	depends on ADK_TARGET_LIB_UCLIBC_NG
-
 config ADK_TARGET_LIB_UCLIBC_NG_GIT
 config ADK_TARGET_LIB_UCLIBC_NG_GIT
 	prompt "git"
 	prompt "git"
 	boolean
 	boolean

+ 0 - 1
target/config/Config.in.libc.default

@@ -22,7 +22,6 @@ config ADK_TARGET_LIBC
 
 
 config ADK_LIBC_VERSION
 config ADK_LIBC_VERSION
 	string
 	string
-	default "1.0.0rc1" if ADK_TARGET_LIB_UCLIBC_NG_1_0_0
 	default "1.1.4" if ADK_TARGET_LIB_MUSL_1_1_4
 	default "1.1.4" if ADK_TARGET_LIB_MUSL_1_1_4
 	default "0.9.33.2" if ADK_TARGET_LIB_UCLIBC_0_9_33_2
 	default "0.9.33.2" if ADK_TARGET_LIB_UCLIBC_0_9_33_2
 	default "2.19" if ADK_TARGET_LIB_GLIBC_2_19
 	default "2.19" if ADK_TARGET_LIB_GLIBC_2_19

+ 102 - 7
toolchain/uclibc/patches/0.9.34-git/0001-test-disable-test-when-UCLIBC_HAS_XLOCALE-is-n.patch

@@ -1,19 +1,24 @@
-From 78bcf3a7a5db798d301875adba55b7b33397b789 Mon Sep 17 00:00:00 2001
+From 7f42d10dfdfe506df0c6b4850a16da7d2ce8293a Mon Sep 17 00:00:00 2001
 From: Waldemar Brodkorb <wbx@openadk.org>
 From: Waldemar Brodkorb <wbx@openadk.org>
 Date: Thu, 28 Aug 2014 14:09:51 +0200
 Date: Thu, 28 Aug 2014 14:09:51 +0200
-Subject: [PATCH] test: disable test when UCLIBC_HAS_XLOCALE is n
+Subject: [PATCH 1/2] test: disable test when UCLIBC_HAS_XLOCALE is n
 
 
 wcsftime() is only implemented when locale support in uClibc
 wcsftime() is only implemented when locale support in uClibc
 is activated. So test will always fail when locale is deactivated
 is activated. So test will always fail when locale is deactivated
-by the user.
+by the user. Rename file name to be consistent with other test file
+names.
 
 
 Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
 Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
 ---
 ---
- test/time/Makefile.in | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
+ test/time/Makefile.in    |  2 +-
+ test/time/tst-wcsftime.c | 39 +++++++++++++++++++++++++++++++++++++++
+ test/time/tst_wcsftime.c | 39 ---------------------------------------
+ 3 files changed, 40 insertions(+), 40 deletions(-)
+ create mode 100644 test/time/tst-wcsftime.c
+ delete mode 100644 test/time/tst_wcsftime.c
 
 
 diff --git a/test/time/Makefile.in b/test/time/Makefile.in
 diff --git a/test/time/Makefile.in b/test/time/Makefile.in
-index 05f73a4..3b063f9 100644
+index 05f73a4..3f1d1a1 100644
 --- a/test/time/Makefile.in
 --- a/test/time/Makefile.in
 +++ b/test/time/Makefile.in
 +++ b/test/time/Makefile.in
 @@ -5,7 +5,7 @@ TESTS_DISABLED := bug-asctime bug-asctime_r time tst-mktime2 tst-posixtz \
 @@ -5,7 +5,7 @@ TESTS_DISABLED := bug-asctime bug-asctime_r time tst-mktime2 tst-posixtz \
@@ -21,10 +26,100 @@ index 05f73a4..3b063f9 100644
  
  
  ifneq ($(UCLIBC_HAS_XLOCALE),y)
  ifneq ($(UCLIBC_HAS_XLOCALE),y)
 -TESTS_DISABLED += tst-ftime_l
 -TESTS_DISABLED += tst-ftime_l
-+TESTS_DISABLED += tst-ftime_l tst_wcsftime.c
++TESTS_DISABLED += tst-ftime_l tst-wcsftime
  endif
  endif
  
  
  CFLAGS_tst-strptime2 := -std=c99
  CFLAGS_tst-strptime2 := -std=c99
+diff --git a/test/time/tst-wcsftime.c b/test/time/tst-wcsftime.c
+new file mode 100644
+index 0000000..6e35f1e
+--- /dev/null
++++ b/test/time/tst-wcsftime.c
+@@ -0,0 +1,39 @@
++#include <stdio.h>
++#include <time.h>
++#include <features.h>
++#ifdef __UCLIBC_HAS_WCHAR__
++#include <wchar.h>
++
++int
++main (int argc, char *argv[])
++{
++  wchar_t buf[200];
++  time_t t;
++  struct tm *tp;
++  int result = 0;
++  size_t n;
++
++  time (&t);
++  tp = gmtime (&t);
++
++  n = wcsftime (buf, sizeof (buf) / sizeof (buf[0]),
++		L"%H:%M:%S  %Y-%m-%d\n", tp);
++  if (n != 21)
++    result = 1;
++
++  wprintf (L"It is now %ls", buf);
++
++  wcsftime (buf, sizeof (buf) / sizeof (buf[0]), L"%A\n", tp);
++
++  wprintf (L"The weekday is %ls", buf);
++
++  return result;
++}
++
++#else
++int main(void)
++{
++	puts("Test requires WCHAR support; skipping");
++	return 0;
++}
++#endif
+diff --git a/test/time/tst_wcsftime.c b/test/time/tst_wcsftime.c
+deleted file mode 100644
+index 6e35f1e..0000000
+--- a/test/time/tst_wcsftime.c
++++ /dev/null
+@@ -1,39 +0,0 @@
+-#include <stdio.h>
+-#include <time.h>
+-#include <features.h>
+-#ifdef __UCLIBC_HAS_WCHAR__
+-#include <wchar.h>
+-
+-int
+-main (int argc, char *argv[])
+-{
+-  wchar_t buf[200];
+-  time_t t;
+-  struct tm *tp;
+-  int result = 0;
+-  size_t n;
+-
+-  time (&t);
+-  tp = gmtime (&t);
+-
+-  n = wcsftime (buf, sizeof (buf) / sizeof (buf[0]),
+-		L"%H:%M:%S  %Y-%m-%d\n", tp);
+-  if (n != 21)
+-    result = 1;
+-
+-  wprintf (L"It is now %ls", buf);
+-
+-  wcsftime (buf, sizeof (buf) / sizeof (buf[0]), L"%A\n", tp);
+-
+-  wprintf (L"The weekday is %ls", buf);
+-
+-  return result;
+-}
+-
+-#else
+-int main(void)
+-{
+-	puts("Test requires WCHAR support; skipping");
+-	return 0;
+-}
+-#endif
 -- 
 -- 
 1.8.5.2 (Apple Git-48)
 1.8.5.2 (Apple Git-48)
 
 

+ 44 - 0
toolchain/uclibc/patches/0.9.34-git/0002-test-skip-test-for-non-mmu-case.patch

@@ -0,0 +1,44 @@
+From fd8d6c5d6bebff0b3a106364e26e75399880b34b Mon Sep 17 00:00:00 2001
+From: Waldemar Brodkorb <wbx@openadk.org>
+Date: Thu, 28 Aug 2014 22:49:10 +0200
+Subject: [PATCH 2/2] test: skip test for non-mmu case
+
+Non-mmu targets have no fork(). In the case of vfork(),
+we can not test communication between parent and child
+in this way.
+
+Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
+---
+ test/librt/shmtest.c | 12 ++++++++++++
+ 1 file changed, 12 insertions(+)
+
+diff --git a/test/librt/shmtest.c b/test/librt/shmtest.c
+index a14302d..2be09cc 100644
+--- a/test/librt/shmtest.c
++++ b/test/librt/shmtest.c
+@@ -14,6 +14,8 @@
+ #include <sys/stat.h>
+ #include <sys/wait.h>
+ 
++#ifdef __ARCH_USE_MMU__
++
+ #define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]))
+ 
+ char shared_name[] = "/sharetest";
+@@ -102,3 +104,13 @@ int main(void) {
+ 	}
+ 	return 0;
+ }
++
++#else
++
++int main(void)
++{
++	printf("Skipping test on non-mmu host!\n");
++	return EXIT_SUCCESS;
++}
++
++#endif
+-- 
+1.8.5.2 (Apple Git-48)
+