A demo project that showcase how to use C++ to conquer the universe, with the help of Djinni and WebAssembly :)
This demo implement exactly the same feature as JavaUniverse, but write the main logic in C++.
- openssl 1.0.2m;
- boost 1.65.1;
- C++ REST SDK 2.10.1;
- Djinni
- xcake
Due to GitHub file size limit, the libs
directory is ignored, you can download it here, and extract it as libs
.
./run_djinni.sh
cd cpp_project
xcake make
open CppUniverse.xcodeproj
./run_djinni.sh
- Just open the
android_project
folder in Android Studio.
./run_djinni.sh
cd ios_project
xcake make
open CppUniverse.xcodeproj
WIP...
- Add
-DCMAKE_INSTALL_PREFIX=`pwd`/out
to cmake command to specify install dir; 'cpprest/http_client.h' file not found with <angled> include; use "quotes" instead
problem solution;Arithmetic on a pointer to an incomplete type 'cpp_universe::Window'
: add#include "window.hpp"
to get the complete type info ofcpp_universe::Window
;- Extend djinni record to add utility method which is only used by one language;
- Djinni record is immutable;
- Building for Android:
- openssl need use r15c;
- boost 1.65.1 need r16;
- can't use nfs shared folder;
- find boost error;
'BOOST_STDLIB' macro redefined
;no matching member function for call to 'expires_from_now'
;
- Building for iOS:
find_package(Threads REQUIRED)
fail, solution;
All changes on C++ REST SDK can be found there.