ProxymanApp / proxyman-windows-linux

Public tracker for Proxyman Windows/Linux
https://proxyman.io/
MIT License
106 stars 4 forks source link

Support for Linux aarch64 #420

Open JohnnyOhall opened 3 months ago

JohnnyOhall commented 3 months ago

Description

Would it be possible for create a release version that would work on Linux aarch64 devices?

Acceptance Criteria

additional release that includes .tar.gz or .AppImage file for aarch64 arcitecture (Such as Raspberry Pi's etc)

NghiaTranUIT commented 3 months ago

Can you show me how to support aarch64 arch? I built from my Intel PC, so it might not included in the AppImage

JohnnyOhall commented 3 months ago

I personally have not done this before but here are some steps I found:

To support aarch64 architecture, you need to build your application for the aarch64 target. Here is a step-by-step guide to cross-compile your application for aarch64 on an Intel PC and package it into an AppImage.

Steps to Cross-Compile for aarch64 and Create an AppImage:

  1. Install Cross-Compilation Tools: Install the necessary tools for cross-compiling to aarch64.
    sudo apt update sudo apt install gcc-aarch64-linux-gnu g++-aarch64-linux-gnu 
  2. Set Up Cross-Compilation Environment: Configure your build system (e.g., CMake, Makefile) to use the aarch64 cross-compiler. For CMake, you can create a toolchain file aarch64-toolchain.cmake:
    # aarch64-toolchain.cmake set(CMAKE_SYSTEM_NAME Linux) set(CMAKE_SYSTEM_PROCESSOR aarch64) set(CMAKE_C_COMPILER aarch64-linux-gnu-gcc) set(CMAKE_CXX_COMPILER aarch64-linux-gnu-g++) 
  3. Build the Application: Use the toolchain file to build your application for aarch64.
    mkdir build-aarch64 cd build-aarch64 cmake -DCMAKE_TOOLCHAIN_FILE=../aarch64-toolchain.cmake .. make 
  4. Create the AppImage: Use linuxdeploy and linuxdeploy-plugin-appimage to create the AppImage.
    wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage wget https://github.com/linuxdeploy/linuxdeploy-plugin-appimage/releases/download/continuous/linuxdeploy-plugin-appimage-x86_64.AppImage chmod +x linuxdeploy*.AppImage ./linuxdeploy-x86_64.AppImage --appdir AppDir --executable path/to/your/aarch64/executable ./linuxdeploy-plugin-appimage-x86_64.AppImage --appdir AppDir 
NghiaTranUIT commented 3 months ago

Thanks, I will try to support this arch on the next release 👍