KangLin/SerialPortAssistant

Build Error on Raspberry Pi

Closed this issue · 4 comments

Hi!

I am trying to build SerialPortAssistant on Raspberry Pi, however it is failing with the following issue

$ sudo apt-get install clang qtcreator qtbase5-dev qt5-qmake cmake libasound2-dev libqt5erialport5-dev
$ mkdir SerialPortAssistant
$ cd SerialPortAssistant
$ git clone https://github.com/KangLin/RabbitCommon.git
$ git clone https://github.com/KangLin/SerialPortAssistant.git
$ mkdir build
$ cd build/
$ qmake ../SerialPortAssistant.pro
$ make install
...
../../App/MainWindow.cpp:36:14: fatal error: FrmStyle/FrmStyle.h: No such file or directory
   36 |     #include "FrmStyle/FrmStyle.h"
      |              ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.

QT 5.5.12 (GCC 10.2.1 20210110, 32 bit)

(I am not familiar with QT, however as there was no precompiled ARM32/ARM64 DEB suitable for Raspberry Pi I have to build it myself)

@r-colvin
I has change the master to support RabbitCommon v2.
Please rebuild it.
If you still have problems, please give feedback. I will help you solve it.

If you want to use versions earlier than v0.5.13, use RabbitCommon v1.0.10

Hi! sorry for the late reply - I have finally been able to test this, and I notice that the build instructions have changed - sadly, there appears to be a problem still

I cleared everything out to start again

$ git clone https://github.com/KangLin/SerialPortAssistant.git
$ cd SerialPortAssistant/
$ git clone https://github.com/KangLin/RabbitCommon.git
$ mkdir build
$ cd build/
$ cmake .. --config Release
CMake Error: The source directory "/home/user/SerialPortAssistant/build/Release" does not exist.
Specify --help for usage, or press the help button on the CMake GUI.
$ mkdir Release
$ cmake .. --config Release
CMake Error: The source directory "/home/user/SerialPortAssistant/SerialPortAssistant/build/--config" does not exist.
Specify --help for usage, or press the help button on the CMake GUI.

Sorry! clerical error.

Thank you for finding this clerical error.

  • Download source code and the deplendence in same directory

    git clone https://github.com/KangLin/RabbitCommon.git
    git clone https://github.com/KangLin/SerialPortAssistant.git
    
  • Build the build directory in the project root directory

    cd SerialPortAssistant
    mkdir build
    cd build
    # cmake configure
    cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=`pwd`/install [-DRabbitCommon_DIR=...]
    # compiling
    cmake --build . --config Release --target install
    cd install  # The program is installed in the install/bin directory