Skip to content

Commit 709e70f

Browse files
committed
Updated iOS scripts for SDK 8.0
1 parent d2075b8 commit 709e70f

File tree

2 files changed

+23
-8
lines changed

2 files changed

+23
-8
lines changed

Build_iOS/configure.sh

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,10 @@
11
#!/bin/bash
22
set -e
33

4-
git clone --depth=1 https://github.com/x2on/OpenSSL-for-iPhone.git
5-
pushd OpenSSL-for-iPhone
6-
./build-libssl.sh
7-
popd
8-
mkdir openssl
9-
mv OpenSSL-for-iPhone/include openssl
10-
mv OpenSSL-for-iPhone/lib openssl
114
git clone https://git.gitorious.org/boostoniphone/galbraithjosephs-boostoniphone.git boostoniphone
125
pushd boostoniphone
13-
sed -e 's/\${BOOST_LIBS:=".*"}/\${BOOST_LIBS:="random thread filesystem regex locale system"}/g' -i .bak boost.sh
6+
sed -e 's/\${IPHONE_SDKVERSION:=7.0}/\${IPHONE_SDKVERSION:=8.0}/' -i .bak boost.sh
7+
sed -e 's/\${BOOST_LIBS:=".*"}/\${BOOST_LIBS:="random thread filesystem regex locale system date_time"}/g' -i .bak boost.sh
148
./boost.sh
159
pushd ios/framework/boost.framework/Versions/A
1610
mkdir Headers2
@@ -19,6 +13,15 @@ mv Headers2 Headers
1913
popd
2014
popd
2115
mv boostoniphone/ios/framework/boost.framework .
16+
17+
git clone --depth=1 https://github.com/x2on/OpenSSL-for-iPhone.git
18+
pushd OpenSSL-for-iPhone
19+
./build-libssl.sh
20+
popd
21+
mkdir openssl
22+
mv OpenSSL-for-iPhone/include openssl
23+
mv OpenSSL-for-iPhone/lib openssl
24+
2225
hg clone https://code.google.com/p/ios-cmake/
2326
mkdir build.ios
2427
pushd build.ios

Release/src/websockets/client/ws_client.cpp

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,21 @@
4141
#pragma GCC diagnostic ignored "-Wconversion"
4242
#pragma GCC diagnostic ignored "-Wunused-parameter"
4343
#pragma GCC diagnostic ignored "-Wignored-qualifiers"
44+
#if defined(__APPLE__)
45+
#include "stdlib.h"
46+
// Issue caused by iOS SDK 8.0
47+
#pragma push_macro("ntohll")
48+
#pragma push_macro("htonll")
49+
#undef ntohll
50+
#undef htonll
51+
#endif
4452
#include <websocketpp/config/asio_client.hpp>
4553
#include <websocketpp/config/asio_no_tls_client.hpp>
4654
#include <websocketpp/client.hpp>
55+
#if defined(__APPLE__)
56+
#pragma pop_macro("htonll")
57+
#pragma pop_macro("ntohll")
58+
#endif
4759
#pragma GCC diagnostic pop
4860
#else /* __GNUC__ */
4961
#pragma warning( disable : 4503 )

0 commit comments

Comments
 (0)