BIND 10 #257: src/lib/cc/session_unittests.cc and #include <unistd.h> for pipe, close, read, write, gethostbyname, ioctl
BIND 10 Development
do-not-reply at isc.org
Tue Jun 29 00:15:33 UTC 2010
#257: src/lib/cc/session_unittests.cc and #include <unistd.h> for pipe, close,
read, write, gethostbyname, ioctl
--------------------------+-------------------------------------------------
Reporter: jreed | Owner:
Type: defect | Status: new
Priority: minor | Milestone:
Component: Unclassified | Keywords:
Sensitive: 0 |
--------------------------+-------------------------------------------------
Noticed using linker with Sunstudio:
{{{
CC -DHAVE_CONFIG_H -I. -I../../.. -I../../../src/lib -I../../../src/lib
-I../../../src/lib/dns -I../../../src/lib/dns
-I/export/home/users/jreed/opt/sunstudio-built/gtest-1.5.0/include
-I/export/home/users/jreed/opt/sunstudio-built/gtest-1.5.0/include
-D_XPG4_2 -D__EXTENSIONS__ -I/udir/jreed/pkg/include -I../../../ext/asio
-g -library=stlport4 -features=tmplife -features=tmplrefstatic -c -o
run_unittests-session_unittests.o `test -f 'session_unittests.cc' ||
echo './'`session_unittests.cc
"../../../ext/asio/asio/detail/pipe_select_interrupter.hpp", line 45:
Error: The function "pipe" must have a prototype.
"../../../ext/asio/asio/detail/pipe_select_interrupter.hpp", line 65:
Error: close is not a member of file level.
...
}}}
and read, write, gethostname, and ioctl ...
These are all defined in unistd.h on SunOS 5.10.
{{{
Index: src/lib/cc/session_unittests.cc
===================================================================
--- src/lib/cc/session_unittests.cc (revision 2316)
+++ src/lib/cc/session_unittests.cc (working copy)
@@ -16,6 +16,8 @@
#include "config.h"
+// provides pipe(2) used by
ext/asio/asio/detail/pipe_select_interrupter.hpp
+#include <unistd.h>
// XXX: the ASIO header must be included before others. See session.cc.
#include <asio.hpp>
}}}
Okay to commit above? I didn't notice any problem with g++ on NetBSD.
--
Ticket URL: <http://bind10.isc.org/ticket/257>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development
More information about the bind10-tickets
mailing list