Merge some more, in preparation for merge back into libc.
authorJim Meyering <jim@meyering.net>
Thu, 28 Nov 2002 09:19:26 +0000 (09:19 +0000)
committerJim Meyering <jim@meyering.net>
Thu, 28 Nov 2002 09:19:26 +0000 (09:19 +0000)
(_): Define only if not already defined.
Move definition to follow all #include directives.
Include unlocked-io.h only if !_LIBC.

lib/error.c

index 3161538..6af7cb8 100644 (file)
@@ -31,7 +31,6 @@
 #else
 # include "gettext.h"
 #endif
-#define _(msgid) gettext (msgid)
 
 #ifdef _LIBC
 # include <wchar.h>
@@ -59,7 +58,14 @@ void exit ();
 #endif
 
 #include "error.h"
-#include "unlocked-io.h"
+
+#if !_LIBC
+# include "unlocked-io.h"
+#endif
+
+#ifndef _
+# define _(String) String
+#endif
 
 /* If NULL, error will flush stdout, then print on stderr the program
    name, a colon and a space.  Otherwise, error will call this