Index: /trunk/src/ash/bltin/kill.c
===================================================================
--- /trunk/src/ash/bltin/kill.c	(revision 842)
+++ /trunk/src/ash/bltin/kill.c	(revision 843)
@@ -30,5 +30,5 @@
  */
 
-#ifndef __sun__
+#ifdef HAVE_SYS_CDEFS_H
 #include <sys/cdefs.h>
 #endif
@@ -63,5 +63,5 @@
 extern void init_sys_signame(void);
 extern char sys_signame[NSIG][16];
-#endif 
+#endif
 
 #ifdef SHELL            /* sh (aka ash) builtin */
@@ -109,5 +109,5 @@
 #ifndef HAVE_SYS_SIGNAME
 			init_sys_signame();
-#endif 
+#endif
 			printf("%s\n", sys_signame[numsig]);
 			exit(0);
@@ -193,5 +193,5 @@
 #ifndef HAVE_SYS_SIGNAME
 	init_sys_signame();
-#endif 
+#endif
 	if (strncasecmp(sig, "sig", 3) == 0)
 		sig += 3;
@@ -230,9 +230,9 @@
 #ifndef _MSC_VER
 #warning TIOCGWINSZ is not present.
-#endif 
+#endif
 #endif
 #ifndef HAVE_SYS_SIGNAME
     init_sys_signame();
-#endif 
+#endif
 
 	for (len = 0, sig = 1; sig < NSIG; sig++) {
Index: /trunk/src/ash/bltin/printf.c
===================================================================
--- /trunk/src/ash/bltin/printf.c	(revision 842)
+++ /trunk/src/ash/bltin/printf.c	(revision 843)
@@ -30,5 +30,7 @@
  */
 
+#ifdef HAVE_SYS_CDEFS_H
 #include <sys/cdefs.h>
+#endif
 #ifndef lint
 #if !defined(BUILTIN) && !defined(SHELL)
@@ -77,5 +79,5 @@
 static char	*mklong(const char *, int);
 static void      check_conversion(const char *, const char *);
-static void	 usage(void); 
+static void	 usage(void);
 
 static void	b_count(int);
@@ -158,7 +160,7 @@
 		 * Basic algorithm is to scan the format string for conversion
 		 * specifications -- once one is found, find out if the field
-		 * width or precision is a '*'; if it is, gather up value. 
+		 * width or precision is a '*'; if it is, gather up value.
 		 * Note, format strings are reused as necessary to use up the
-		 * provided arguments, arguments of zero/null string are 
+		 * provided arguments, arguments of zero/null string are
 		 * provided to use up the format string.
 		 */
@@ -322,5 +324,5 @@
 
 /*
- * Print SysV echo(1) style escape string 
+ * Print SysV echo(1) style escape string
  *	Halts processing string if a \c escape is encountered.
  */
@@ -345,8 +347,8 @@
 		}
 
-		/* 
+		/*
 		 * %b string octal constants are not like those in C.
-		 * They start with a \0, and are followed by 0, 1, 2, 
-		 * or 3 octal digits. 
+		 * They start with a \0, and are followed by 0, 1, 2,
+		 * or 3 octal digits.
 		 */
 		if (ch == '0') {
@@ -390,5 +392,5 @@
 
 /*
- * Print "standard" escape characters 
+ * Print "standard" escape characters
  */
 static char *
@@ -519,5 +521,5 @@
 {
 	static char copy[64];
-	size_t len;	
+	size_t len;
 
 	len = strlen(str) + 2;
@@ -530,5 +532,5 @@
 	copy[len - 2] = ch;
 	copy[len - 1] = '\0';
-	return copy;	
+	return copy;
 }
 
Index: /trunk/src/ash/bltin/test.c
===================================================================
--- /trunk/src/ash/bltin/test.c	(revision 842)
+++ /trunk/src/ash/bltin/test.c	(revision 843)
@@ -11,5 +11,5 @@
  */
 
-#ifndef __sun__
+#ifdef HAVE_SYS_CDEFS_H
 #include <sys/cdefs.h>
 #endif
@@ -196,5 +196,5 @@
 #ifdef HAVE_SETPROGNAME
 	setprogname(argv[0]);
-#endif 
+#endif
 	if (strcmp(argv[0], "[") == 0) {
 		if (strcmp(argv[--argc], "]"))
@@ -292,5 +292,5 @@
 	if (t_lex(t_wp[1]), t_wp_op && t_wp_op->op_type == BINOP) {
 		return binop();
-	}	  
+	}
 
 	return strlen(*t_wp) > 0;
@@ -309,5 +309,5 @@
 	if ((opnd2 = *++t_wp) == NULL)
 		syntax(op->op_text, "argument expected");
-		
+
 	switch (op->op_num) {
 	case STREQ:
@@ -369,5 +369,5 @@
 #else
         return 0;
-#endif 
+#endif
 	case FILBDEV:
 #ifdef S_ISBLK
@@ -375,5 +375,5 @@
 #else
         return 0;
-#endif 
+#endif
 	case FILFIFO:
 #ifdef S_ISFIFO
@@ -381,5 +381,5 @@
 #else
         return 0;
-#endif 
+#endif
 	case FILSOCK:
 #ifdef S_ISSOCK
@@ -387,5 +387,5 @@
 #else
         return 0;
-#endif 
+#endif
 	case FILSYM:
 		return S_ISLNK(s.st_mode);
@@ -399,5 +399,5 @@
 #else
         return 0;
-#endif 
+#endif
 	case FILGZ:
 		return s.st_size > (off_t)0;
@@ -450,5 +450,5 @@
 		if (strcmp(s, op->op_text) == 0)
 	    		return op->op_type == BINOP &&
-	    		    (t[0] != ')' || t[1] != '\0'); 
+	    		    (t[0] != ')' || t[1] != '\0');
 		op++;
 	}
@@ -471,5 +471,5 @@
 	while (isspace((unsigned char)*p))
 	      p++;
-	
+
 	if (*p)
 	      error("%s: bad number", s);
Index: /trunk/src/ash/cd.c
===================================================================
--- /trunk/src/ash/cd.c	(revision 842)
+++ /trunk/src/ash/cd.c	(revision 843)
@@ -33,5 +33,5 @@
  */
 
-#ifndef __sun__
+#ifdef HAVE_SYS_CDEFS_H
 #include <sys/cdefs.h>
 #endif
