summaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorRaphael Kubo da Costa <rakuco@FreeBSD.org>2012-09-11 22:50:15 +0300
committerChristian Beier <dontmind@freeshell.org>2012-09-14 18:47:37 +0200
commit95dd76327b79ff892b011876a959a8b8e40afe62 (patch)
tree71843360e75cb38aa8855bfecfb867218353f950 /CMakeLists.txt
parent2d18f3cdcfa0bca29dd83720d311682269b7d813 (diff)
downloadlibtdevnc-95dd76327b79ff892b011876a959a8b8e40afe62.tar.gz
libtdevnc-95dd76327b79ff892b011876a959a8b8e40afe62.zip
Use htobeNN(3) to convert numbers in websocket.c.
byteswap.h exists only on glibc, so building libvncserver with websockets support was not possible in other systems. Replace the inclusion of byteswap.h and the WS_* definitions with calls to htobeNN, which should perform the same conversions, be more portable and avoid the need to check for the platform's endianness.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt2
1 files changed, 2 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8814844..61b79c4 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -122,8 +122,10 @@ if(LIBGCRYPT_LIBRARIES)
endif(LIBGCRYPT_LIBRARIES)
+check_include_file("endian.h" LIBVNCSERVER_HAVE_ENDIAN_H)
check_include_file("fcntl.h" LIBVNCSERVER_HAVE_FCNTL_H)
check_include_file("netinet/in.h" LIBVNCSERVER_HAVE_NETINET_IN_H)
+check_include_file("sys/endian.h" LIBVNCSERVER_HAVE_SYS_ENDIAN_H)
check_include_file("sys/socket.h" LIBVNCSERVER_HAVE_SYS_SOCKET_H)
check_include_file("sys/stat.h" LIBVNCSERVER_HAVE_SYS_STAT_H)
check_include_file("sys/time.h" LIBVNCSERVER_HAVE_SYS_TIME_H)