Code Monkey home page Code Monkey logo

Comments (4)

wlfsky avatar wlfsky commented on June 5, 2024

I build oatpp with aarch64-linux-gnu, arm-linux-gnueabihf;
build it with xilinx sdk 2018.3 arm32 and aarch64 ;
build it with zig build system arm32 and aarch64;

You must prepare openssl aarch64 , cmake 3.20+ and aarch64-linux-gnu first.
Ubuntu20.04 64
aarch64-linux-gnu-g++-10

oatpp src code in dir "oatpp-aarch64"

mkdir build-aarch64
cd build-aarch64

in Cmakelists.txt after first line:
set(CMAKE_SYSTEM_NAME Linux)
set(CMAKE_SYSTEM_PROCESSOR aarch64)
set(CMAKE_SYSROOT "/usr/lib/x86_64-linux-gnu")
SET(CMAKE_C_COMPILER "/usr/bin/aarch64-linux-gnu-gcc-10")
SET(CMAKE_CXX_COMPILER "/usr/bin/aarch64-linux-gnu-g++-10")
SET(CC "/usr/bin/aarch64-linux-gnu-gcc-10")
SET(CXX "/usr/bin/aarch64-linux-gnu-g++-10")
set(CMAKE_C_FLAGS "-lpthread")
set(CMAKE_CXX_FLAGS "-lpthread")
SET(OPENSSL_LIBRARIES /home/weilai/oatpp/openssl/lib)
SET(OPENSSL_INCLUDE_DIR /home/weilai/oatpp/openssl/include)
SET(CMAKE_INSTALL_PREFIX "/home/weilai/oatpp/build-aarch64")

~/cmake/cmake-3.27.1-linux-x86_64/bin/cmake ../oatpp-aarch64
make && make install
running...
...................................ok

but..... the executable I compiled on aarch64 did not run successfully.
On arm32 with xilinx 2018.3 is success.

with zig build system build oatpp success. build executable success. but run server program crash!
malloc(): corrupted top size
at this code
AppComponent components;

So, I don't know if oatpp really supports the aarch64 platform.

I hope it helps.

By the way, I think you've compiled it. You just can't find the compiled library file!

from oatpp.

weidqi avatar weidqi commented on June 5, 2024

Yes, the static library was not generated. Thank you for your help, I will try the method you suggested.

from oatpp.

wlfsky avatar wlfsky commented on June 5, 2024

"Cmakelists.txt", find
option(BUILD_SHARED_LIBS "Build shared libraries" ON)
set to
option(BUILD_SHARED_LIBS "Build shared libraries" OFF)
build.....
it build static library.

from oatpp.

weidqi avatar weidqi commented on June 5, 2024

Yes, using your method, the compilation for arm64 was also not successful. It is possible that it is not supported after all.

from oatpp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.