Changeset 4171479 in clfs-sysroot
- Timestamp:
- Mar 17, 2009, 6:24:48 PM (16 years ago)
- Branches:
- master
- Children:
- f79dced
- Parents:
- b051602
- Location:
- patches
- Files:
-
- 1 added
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
patches/coreutils-7.1-uname-1.patch
rb051602 r4171479 1 Submitted By: Jim Gifford <jim at linuxfromscratch dot org> 2 Date: 2006-08-24 3 Initial Package Version: 5.97 4 Rediffed against 6.12 by Joe Ciccone on 2008-08-30 1 Submitted By: Jim Gifford <jim at cross-lfs dot org> 2 Date: 2009-02-21 3 Initial Package Version: 7.1 5 4 Upstream Status: Not Accepted 6 5 Origin: Gentoo - http://sources.gentoo.org/viewcvs.py/gentoo/src/patchsets/coreutils 7 6 Description: Display CPU Information from /proc/cpuinfo or /proc/sysinfo 8 7 8 Rediffed for 7.1 by Jim Gifford 9 9 Original Patch by - Matthew Burgess and Scot McPherson 10 10 11 diff -Naur coreutils- 6.12.orig/src/uname.c coreutils-6.12/src/uname.c12 --- coreutils- 6.12.orig/src/uname.c 2008-05-26 02:40:33.000000000 -040013 +++ coreutils- 6.12/src/uname.c 2008-08-31 12:03:12.000000000 -040011 diff -Naur coreutils-7.1.orig/src/uname.c coreutils-7.1/src/uname.c 12 --- coreutils-7.1.orig/src/uname.c 2008-09-18 00:06:57.000000000 -0700 13 +++ coreutils-7.1/src/uname.c 2009-02-21 21:48:22.417139823 -0800 14 14 @@ -50,6 +50,11 @@ 15 15 # include <mach-o/arch.h> … … 24 24 #include "error.h" 25 25 #include "quote.h" 26 @@ -15 8,6 +163,106@@26 @@ -155,6 +160,117 @@ 27 27 exit (status); 28 28 } … … 53 53 + if (tmp != buf) 54 54 + memmove(buf, tmp, strlen(tmp)+1); 55 + /* finally collapse whitespace */ 56 + tmp = buf; 57 + while (tmp[0] && tmp[1]) { 58 + if (isspace(tmp[0]) && isspace(tmp[1])) { 59 + memmove(tmp, tmp+1, strlen(tmp)); 60 + continue; 61 + } 62 + ++tmp; 63 + } 55 64 +} 56 65 + … … 65 74 + #elif defined(__arm__) 66 75 + "Processor", "Hardware" 67 + #elif defined(bfin) 76 + #elif defined(__avr32__) 77 + "processor", "cpu family" 78 + #elif defined(__bfin__) 68 79 + "CPU", "BOARD Name" 69 80 + #elif defined(__cris__) … … 131 142 printed. */ 132 143 133 @@ -30 5,10 +410,14 @@144 @@ -302,10 +418,14 @@ 134 145 if (toprint & PRINT_PROCESSOR) 135 146 { … … 147 158 } 148 159 #endif 149 @@ -3 61,9 +470,13 @@160 @@ -358,9 +478,13 @@ 150 161 if (element == unknown) 151 162 {
Note:
See TracChangeset
for help on using the changeset viewer.