aboutsummaryrefslogtreecommitdiff
path: root/include/sys
diff options
context:
space:
mode:
authorBrent Cook <busterb@gmail.com>2014-11-19 07:43:07 -0600
committerBrent Cook <bcook@openbsd.org>2014-12-03 17:07:17 -0600
commitcccdd689e39b51af02b156229e5236a2a69dcdcb (patch)
tree79a77dcdc785a109aaaeb4a2a47507933525e47b /include/sys
parent1bbde19a7c0db8d25fb496dea3e05e3dbc0bbeaf (diff)
downloadportable-cccdd689e39b51af02b156229e5236a2a69dcdcb.tar.gz
portable-cccdd689e39b51af02b156229e5236a2a69dcdcb.tar.bz2
portable-cccdd689e39b51af02b156229e5236a2a69dcdcb.zip
add minimal winsock->BSD networking header shims
also add license header to existing shims
Diffstat (limited to 'include/sys')
-rw-r--r--include/sys/ioctl.h11
-rw-r--r--include/sys/mman.h5
-rw-r--r--include/sys/select.h10
-rw-r--r--include/sys/socket.h10
-rw-r--r--include/sys/times.h10
-rw-r--r--include/sys/types.h5
6 files changed, 51 insertions, 0 deletions
diff --git a/include/sys/ioctl.h b/include/sys/ioctl.h
new file mode 100644
index 0000000..a255506
--- /dev/null
+++ b/include/sys/ioctl.h
@@ -0,0 +1,11 @@
1/*
2 * Public domain
3 * sys/ioctl.h compatibility shim
4 */
5
6#ifndef _WIN32
7#include_next <sys/ioctl.h>
8#else
9#include <win32netcompat.h>
10#define ioctl(fd, type, arg) ioctlsocket(fd, type, arg)
11#endif
diff --git a/include/sys/mman.h b/include/sys/mman.h
index cb1fa21..d9eb6a9 100644
--- a/include/sys/mman.h
+++ b/include/sys/mman.h
@@ -1,3 +1,8 @@
1/*
2 * Public domain
3 * sys/mman.h compatibility shim
4 */
5
1#include_next <sys/mman.h> 6#include_next <sys/mman.h>
2 7
3#ifndef LIBCRYPTOCOMPAT_MMAN_H 8#ifndef LIBCRYPTOCOMPAT_MMAN_H
diff --git a/include/sys/select.h b/include/sys/select.h
new file mode 100644
index 0000000..5ca0ea1
--- /dev/null
+++ b/include/sys/select.h
@@ -0,0 +1,10 @@
1/*
2 * Public domain
3 * sys/select.h compatibility shim
4 */
5
6#ifndef _WIN32
7#include_next <sys/select.h>
8#else
9#include <win32netcompat.h>
10#endif
diff --git a/include/sys/socket.h b/include/sys/socket.h
new file mode 100644
index 0000000..17e84f1
--- /dev/null
+++ b/include/sys/socket.h
@@ -0,0 +1,10 @@
1/*
2 * Public domain
3 * sys/socket.h compatibility shim
4 */
5
6#ifndef _WIN32
7#include_next <sys/socket.h>
8#else
9#include <win32netcompat.h>
10#endif
diff --git a/include/sys/times.h b/include/sys/times.h
new file mode 100644
index 0000000..5b9841b
--- /dev/null
+++ b/include/sys/times.h
@@ -0,0 +1,10 @@
1/*
2 * Public domain
3 * sys/times.h compatibility shim
4 */
5
6#ifndef _WIN32
7#include_next <sys/times.h>
8#else
9#include <win32netcompat.h>
10#endif
diff --git a/include/sys/types.h b/include/sys/types.h
index 34c3e03..bceedc2 100644
--- a/include/sys/types.h
+++ b/include/sys/types.h
@@ -1,3 +1,8 @@
1/*
2 * Public domain
3 * sys/types.h compatibility shim
4 */
5
1#include_next <sys/types.h> 6#include_next <sys/types.h>
2 7
3#ifndef LIBCRYPTOCOMPAT_SYS_TYPES_H 8#ifndef LIBCRYPTOCOMPAT_SYS_TYPES_H