Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/bin/dd Make compile on non-NetBSD.
details: https://anonhg.NetBSD.org/src/rev/b30015cf1bb2
branches: trunk
changeset: 759671:b30015cf1bb2
user: pooka <pooka%NetBSD.org@localhost>
date: Tue Dec 14 19:03:21 2010 +0000
description:
Make compile on non-NetBSD.
diffstat:
bin/dd/args.c | 16 +++++++++-------
1 files changed, 9 insertions(+), 7 deletions(-)
diffs (65 lines):
diff -r e877efb5ace9 -r b30015cf1bb2 bin/dd/args.c
--- a/bin/dd/args.c Tue Dec 14 18:51:56 2010 +0000
+++ b/bin/dd/args.c Tue Dec 14 19:03:21 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: args.c,v 1.29 2010/12/09 10:24:56 enami Exp $ */
+/* $NetBSD: args.c,v 1.30 2010/12/14 19:03:21 pooka Exp $ */
/*-
* Copyright (c) 1991, 1993, 1994
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)args.c 8.3 (Berkeley) 4/2/94";
#else
-__RCSID("$NetBSD: args.c,v 1.29 2010/12/09 10:24:56 enami Exp $");
+__RCSID("$NetBSD: args.c,v 1.30 2010/12/14 19:03:21 pooka Exp $");
#endif
#endif /* not lint */
@@ -55,7 +55,9 @@
#include "dd.h"
#include "extern.h"
-#ifndef SMALL
+#if !defined(SMALL) && defined(__NetBSD__)
+#define _HAVE_RUMPOPS
+
#include <rump/rumpclient.h>
#endif
@@ -76,7 +78,7 @@
static void f_skip(char *);
static void f_progress(char *);
-#ifndef SMALL
+#ifdef _HAVE_RUMPOPS
static void f_rif(char *);
static void f_rof(char *);
#endif
@@ -98,7 +100,7 @@
{ "obs", f_obs, C_OBS, C_BS|C_OBS },
{ "of", f_of, C_OF, C_OF|C_ROF },
{ "progress", f_progress, 0, 0 },
-#ifndef SMALL
+#ifdef _HAVE_RUMPOPS
{ "rif", f_rif, C_RIF|C_RUMP, C_RIF|C_IF },
{ "rof", f_rof, C_ROF|C_RUMP, C_ROF|C_OF },
#endif
@@ -199,7 +201,7 @@
* errx(1, "seek offsets cannot be larger than %d", INT_MAX);
*/
-#ifndef SMALL
+#ifdef _HAVE_RUMPOPS
if (ddflags & C_RUMP)
if (rumpclient_init() == -1)
err(1, "rumpclient init failed");
@@ -276,7 +278,7 @@
out.name = arg;
}
-#ifndef SMALL
+#ifdef _HAVE_RUMPOPS
#include <rump/rump.h>
#include <rump/rump_syscalls.h>
Home |
Main Index |
Thread Index |
Old Index