2019-12-14 21:43:49 +01:00
|
|
|
# How to compile on a Raspberry Pi
|
|
|
|
|
|
|
|
### Clone RPi VK Driver
|
|
|
|
git clone https://github.com/Yours3lf/rpi-vk-driver.git
|
|
|
|
cd rpi-vk-driver
|
|
|
|
mkdir build
|
|
|
|
cd build
|
|
|
|
|
|
|
|
### Run CMake
|
|
|
|
cmake .. -DCMAKE_BUILD_TYPE=Release
|
|
|
|
|
|
|
|
### Build project
|
|
|
|
cmake --build . --target all
|
|
|
|
|
|
|
|
### Run install.sh
|
|
|
|
|
|
|
|
|
|
|
|
|
2019-12-07 16:31:00 +01:00
|
|
|
# How to cross compile the RPi VK Driver
|
|
|
|
|
|
|
|
### Clone compiler
|
|
|
|
git clone https://github.com/raspberrypi/tools.git
|
|
|
|
|
|
|
|
### Establish sysroot
|
2019-12-07 19:28:09 +01:00
|
|
|
rsync -az --delete-after --safe-links [user]@[ipaddress]:/{lib,usr} tools/arm-bcm2708/arm-rpi-4.9.3-linux-gnueabihf/arm-linux-gnueabihf/sysroot
|
2019-12-07 16:31:00 +01:00
|
|
|
|
|
|
|
### Clone RPi VK Driver
|
2019-12-07 16:45:43 +01:00
|
|
|
git clone https://github.com/Yours3lf/rpi-vk-driver.git
|
|
|
|
cd rpi-vk-driver
|
|
|
|
mkdir build
|
|
|
|
cd build
|
2019-12-07 16:31:00 +01:00
|
|
|
|
|
|
|
### Run CMake
|
2019-12-07 16:45:43 +01:00
|
|
|
cmake .. -DCMAKE_TOOLCHAIN_FILE=../toolchain.cmake -DCMAKE_BUILD_TYPE=Release
|
2019-12-07 16:31:00 +01:00
|
|
|
|
|
|
|
### Build project
|
2019-12-07 16:45:43 +01:00
|
|
|
cmake --build . --target all
|
2019-12-07 16:31:00 +01:00
|
|
|
|
|
|
|
### Deploy files
|
2019-12-07 16:45:43 +01:00
|
|
|
scp librpi-vk-driver.so [user]@[ipaddress]:/home/[user]/librpi-vk-driver.so
|
|
|
|
scp rpi-vk-driver.json [user]@[ipaddress]:/home/[user]/rpi-vk-driver.json
|
|
|
|
scp install.sh [user]@[ipaddress]:/home/[user]/install.sh
|
2019-12-07 16:31:00 +01:00
|
|
|
|
|
|
|
### Run install.sh on your RPi
|