<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[wolfSSL - Embedded SSL Library — iOS build with libwebsockets]]></title>
		<link>https://www.wolfssl.com/forums/topic1823-ios-build-with-libwebsockets.html</link>
		<atom:link href="https://www.wolfssl.com/forums/feed-rss-topic1823.xml" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in iOS build with libwebsockets.]]></description>
		<lastBuildDate>Fri, 26 Nov 2021 10:28:48 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: iOS build with libwebsockets]]></title>
			<link>https://www.wolfssl.com/forums/post6391.html#p6391</link>
			<description><![CDATA[<div class="codebox"><pre><code>#define HAVE_PKCS8</code></pre></div><p>is not needed. I fixed it with commenting out #define NO_PWDBASED</p>]]></description>
			<author><![CDATA[null@example.com (r-type)]]></author>
			<pubDate>Fri, 26 Nov 2021 10:28:48 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post6391.html#p6391</guid>
		</item>
		<item>
			<title><![CDATA[Re: iOS build with libwebsockets]]></title>
			<link>https://www.wolfssl.com/forums/post6390.html#p6390</link>
			<description><![CDATA[<p>Hi Kareem,<br />could you please point me to the missing option? I have an error with unresolved &quot;_ToTraditionalEnc&quot; referenced from&nbsp; &nbsp; &nbsp; wolfSSL_d2i_PKCS8PrivateKey_bio in libwolfssl.a(ssl.o). <br />I created options.h like this<br /></p><div class="codebox"><pre><code>#include &lt;IDE/XCODE/user_settings.h&gt;
#include &lt;wolfssl/wolfcrypt/settings.h&gt;</code></pre></div><p>And put following defines at the top of user_settings.h<br /></p><div class="codebox"><pre><code>#define WOLFSSL_LIBWEBSOCKETS
#define HAVE_EX_DATA
#define OPENSSL_NO_EC
#define OPENSSL_ALL
#define WOLFSSL_EITHER_SIDE
#define WC_RSA_NO_PADDING
#define WC_RSA_PSS
#define WOLFSSL_PSS_LONG_SALT
#define OPENSSL_EXTRA
#define HAVE_ALPN
#define HAVE_PKCS8</code></pre></div><p>I put HAVE_ALPN to fix unresolved _wolfSSL_get0_alpn_selected.<br />To fix unresolved ToTraditionalEnc I put HAVE_PKCS8, but it didn&#039;t help. May be it gets overridden somewhere else...</p><p>Thanks,<br />Roman</p>]]></description>
			<author><![CDATA[null@example.com (r-type)]]></author>
			<pubDate>Fri, 26 Nov 2021 10:18:28 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post6390.html#p6390</guid>
		</item>
		<item>
			<title><![CDATA[Re: iOS build with libwebsockets]]></title>
			<link>https://www.wolfssl.com/forums/post6353.html#p6353</link>
			<description><![CDATA[<p>Hi Kareem,<br />thanks, I&#039;ll give it a try.<br />I built it this way (with lws), but could not test yet if it really works:<br /></p><div class="codebox"><pre><code>./configure --host=arm-apple-darwin --disable-shared --prefix=${PWD}/inst --enable-opensslextra --enable-libwebsockets --enable-certgen --enable-certreq --enable-certext --enable-pkcs7 --enable-cryptocb --enable-aescfb --enable-alpn
make CC=&quot;$(xcrun --sdk iphoneos -f clang) -isysroot $(xcrun --sdk iphoneos --show-sdk-path) -arch arm64 -miphoneos-version-min=12.5&quot;
make install</code></pre></div>]]></description>
			<author><![CDATA[null@example.com (r-type)]]></author>
			<pubDate>Tue, 09 Nov 2021 19:26:50 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post6353.html#p6353</guid>
		</item>
		<item>
			<title><![CDATA[Re: iOS build with libwebsockets]]></title>
			<link>https://www.wolfssl.com/forums/post6348.html#p6348</link>
			<description><![CDATA[<p>Hi r-type,</p><p>You should continue to use our XCODE IDE project.&nbsp; To get around the options.h issue, create an options.h file which includes your settings.h file, and make sure your IDE is set to have the preprocessor define WOLFSSL_USER_SETTINGS.&nbsp; Alternatively, include user_settings.h followed by settings.h in your options.h file.</p><p>Thanks,<br />Kareem</p>]]></description>
			<author><![CDATA[null@example.com (kareem_wolfssl)]]></author>
			<pubDate>Thu, 04 Nov 2021 21:34:27 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post6348.html#p6348</guid>
		</item>
		<item>
			<title><![CDATA[iOS build with libwebsockets]]></title>
			<link>https://www.wolfssl.com/forums/post6345.html#p6345</link>
			<description><![CDATA[<p>Hi,<br />I&#039;m trying to build wolfSSL and libwebsockets for iOS. For that I extended IDE/XCODE/user_settings.h with <br /></p><div class="codebox"><pre><code>#define OPENSSL_EXTRA
#define WOLFSSL_LIBWEBSOCKETS</code></pre></div><p>and adjusted build script<br /></p><div class="codebox"><pre><code>WORKSPACE=$(eval &quot;pwd&quot;)
PROJ=wolfssl.xcodeproj
CONFIG=Release
SCHEME=wolfssl_ios
CONF_BUILD_DIR=${WORKSPACE}/simulator
xcodebuild clean build -project ${PROJ} -configuration ${CONFIG} \
           -scheme ${SCHEME} -destination generic/platform=iOS \
           BITCODE_GENERATION_MODE=bitcode \
           CONFIGURATION_BUILD_DIR=${CONF_BUILD_DIR}</code></pre></div><p>Build was successful and I have IDE/XCODE/simulator/libwolfssl_ios.a<br />But this way wolfssl/options.h is not generated and cannot be found by libwebsockets. Is it the same as user_settings.h?<br />Or should I better use autotools? I compiled wolfSSL for Mac with these switches:<br /></p><div class="codebox"><pre><code>CFLAGS=&#039;-target x86_64-apple-macos10.12&#039;
./configure --build=arm64-apple-darwin20.3.0 --target=x86_64-apple-darwin20.3.0 --host=x86_64-apple-darwin20.3.0 --prefix=${PWD}/inst --enable-opensslextra --enable-libwebsockets </code></pre></div><p>But I doubt just changing x86_64 to armv7 will give me iOS library ...</p>]]></description>
			<author><![CDATA[null@example.com (r-type)]]></author>
			<pubDate>Thu, 04 Nov 2021 10:04:28 +0000</pubDate>
			<guid>https://www.wolfssl.com/forums/post6345.html#p6345</guid>
		</item>
	</channel>
</rss>
