[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
gnumach oskit/ds_routines.c ./configure ./confi...
From: |
Roland McGrath |
Subject: |
gnumach oskit/ds_routines.c ./configure ./confi... |
Date: |
Mon, 21 Oct 2002 05:32:14 -0400 |
CVSROOT: /cvsroot/hurd
Module name: gnumach
Changes by: Roland McGrath <address@hidden> 02/10/21 05:32:14
Modified files:
oskit : ds_routines.c
. : configure config.h.in configure.in
Log message:
2002-10-21 Roland McGrath <address@hidden>
* configure.in: Check for oskit/dev/stream.h.
* configure, config.h.in: Regenerated.
* oskit/ds_routines.c (dev_open_com): Query for an oskit_streamdev_t
and open it.
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gnumach/gnumach/oskit/ds_routines.c.diff?tr1=1.6&tr2=1.7&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnumach/gnumach/configure.diff?tr1=1.8&tr2=1.9&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnumach/gnumach/config.h.in.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gnumach/gnumach/configure.in.diff?tr1=1.14&tr2=1.15&r1=text&r2=text
Patches:
Index: gnumach/config.h.in
diff -u gnumach/config.h.in:1.2 gnumach/config.h.in:1.3
--- gnumach/config.h.in:1.2 Mon May 27 19:01:49 2002
+++ gnumach/config.h.in Mon Oct 21 05:32:14 2002
@@ -7,3 +7,6 @@
/* Define this to nonzero to enable the software FPU emulator,
used on machines that have no FPU. */
#undef FPE
+
+/* Define if you have the <oskit/dev/stream.h> header file. */
+#undef HAVE_OSKIT_DEV_STREAM_H
Index: gnumach/configure
diff -u gnumach/configure:1.8 gnumach/configure:1.9
--- gnumach/configure:1.8 Sat Jul 20 01:24:22 2002
+++ gnumach/configure Mon Oct 21 05:32:14 2002
@@ -1257,10 +1257,51 @@
echo "$ac_t""yes, ok" 1>&6
fi
+for ac_hdr in oskit/dev/stream.h
+do
+ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+echo "configure:1265: checking for $ac_hdr" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.$ac_ext <<EOF
+#line 1270 "configure"
+#include "confdefs.h"
+#include <$ac_hdr>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1275: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=yes"
+else
+ echo "$ac_err" >&5
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=no"
+fi
+rm -f conftest*
+fi
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ ac_tr_hdr=HAVE_`echo $ac_hdr | sed
'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
+ cat >> confdefs.h <<EOF
+#define $ac_tr_hdr 1
+EOF
+
+else
+ echo "$ac_t""no" 1>&6
+fi
+done
+
+
SMP_LIBS=
if test $MAXCPUS -gt 1; then
echo $ac_n "checking for smp_init in -loskit_smp""... $ac_c" 1>&6
-echo "configure:1264: checking for smp_init in -loskit_smp" >&5
+echo "configure:1305: checking for smp_init in -loskit_smp" >&5
ac_lib_var=`echo oskit_smp'_'smp_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1268,7 +1309,7 @@
ac_save_LIBS="$LIBS"
LIBS="-loskit_smp $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 1272 "configure"
+#line 1313 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -1279,7 +1320,7 @@
smp_init()
; return 0; }
EOF
-if { (eval echo configure:1283: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } &&
test -s conftest${ac_exeext}; then
+if { (eval echo configure:1324: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } &&
test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
Index: gnumach/configure.in
diff -u gnumach/configure.in:1.14 gnumach/configure.in:1.15
--- gnumach/configure.in:1.14 Sat Jul 20 01:24:22 2002
+++ gnumach/configure.in Mon Oct 21 05:32:14 2002
@@ -96,6 +96,8 @@
AC_MSG_RESULT([yes, ok])
fi
+AC_CHECK_HEADERS(oskit/dev/stream.h)
+
AC_SUBST(SMP_LIBS)SMP_LIBS=
if test $MAXCPUS -gt 1; then
AC_CHECK_LIB(oskit_smp, smp_init, [SMP_LIBS=-loskit_smp], [
Index: gnumach/oskit/ds_routines.c
diff -u gnumach/oskit/ds_routines.c:1.6 gnumach/oskit/ds_routines.c:1.7
--- gnumach/oskit/ds_routines.c:1.6 Fri Jun 14 19:59:41 2002
+++ gnumach/oskit/ds_routines.c Mon Oct 21 05:32:14 2002
@@ -49,6 +49,9 @@
#include <oskit/unsupp/bus_walk.h>
#include <oskit/dev/bus.h>
#include <oskit/dev/blk.h>
+#ifdef HAVE_OSKIT_DEV_STREAM_H
+# include <oskit/dev/stream.h>
+#endif
#include <oskit/dev/net.h>
#include <oskit/dev/linux.h>
#include <oskit/com/stream.h>
@@ -401,6 +404,9 @@
oskit_bus_t *bus;
oskit_blkdev_t *blkdev;
oskit_netdev_t *netdev;
+#ifdef oskit_streamdev_open
+ oskit_streamdev_t *streamdev;
+#endif
oskit_error_t rc;
inline void asyncio_init (device_t dev)
{
@@ -465,6 +471,29 @@
ops = &net_device_ops;
rc = ds_netdev_open (dev, netdev);
}
+#ifdef oskit_streamdev_open
+ else if (oskit_device_query (com_device, &oskit_streamdev_iid,
+ (void **) &streamdev) == 0)
+ {
+ rc = oskit_streamdev_open (streamdev,
+ ((mode & D_READ) ? OSKIT_DEV_OPEN_READ : 0)
+ | ((mode & D_WRITE)
+ ? OSKIT_DEV_OPEN_WRITE : 0),
+ &dev->com.stream.io);
+ oskit_streamdev_release (streamdev);
+ if (OSKIT_SUCCEEDED (rc))
+ {
+ if (oskit_stream_query (dev->com.stream.io, &oskit_asyncio_iid,
+ (void **) &dev->com.stream.aio) == 0)
+ {
+ asyncio_init (dev);
+ ops = &asyncio_device_ops;
+ }
+ else
+ ops = &stream_device_ops;
+ }
+ }
+#endif
if (OSKIT_FAILED (rc))
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- gnumach oskit/ds_routines.c ./configure ./confi...,
Roland McGrath <=