Skip to content

Commit b3c9663

Browse files
committed
Update build manual
1 parent e12d03e commit b3c9663

File tree

3 files changed

+56
-63
lines changed

3 files changed

+56
-63
lines changed

BUILDING.md

Lines changed: 54 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -1,57 +1,57 @@
11
## Available methods to build HyperHDR:
2-
### 1. [Native build](https://github.com/awawa-dev/HyperHDR/wiki/Compiling-HyperHDR#native-build)
3-
### 2. [Build a HyperHDR installer for any supported Linux system on any system using Docker](https://github.com/awawa-dev/HyperHDR/wiki/Compiling-HyperHDR#build-a-hyperhdr-installer-for-any-supported-linux-system-on-any-system-using-docker)
4-
### 3. [Github Action (online - easiest)](https://github.com/awawa-dev/HyperHDR/wiki/Compiling-HyperHDR#github-action-online---easiest)
2+
### 1. [Native build](#native-build)
3+
### 2. [Build a HyperHDR installer for any supported Linux system on any system using Docker](#build-a-hyperhdr-installer-for-any-supported-linux-system-on-any-system-using-docker)
4+
### 3. [Online: Github Action](#onlinegithub-action)
55

66
## Available CMake HyperHDR configuration options:
77
Use -D prefix when configuring the build.
88

99
* LED DEVICES
10-
* ENABLE_SPIDEV = ON | OFF, enables SPI LED devices on supported systems
11-
* ENABLE_SPI_FTDI = ON | OFF, enables SPI libFTDI/FTDI controller on supported systems
12-
* ENABLE_WS281XPWM = ON | OFF, enables WS281x LED library on supported systems
10+
* ENABLE_SPIDEV = ON | OFF, enables SPI LED devices on supported systems
11+
* ENABLE_SPI_FTDI = ON | OFF, enables SPI libFTDI/FTDI controller on supported systems
12+
* ENABLE_WS281XPWM = ON | OFF, enables WS281x LED library on supported systems
1313

1414
* SOFTWARE GRABBERS
15-
* ENABLE_DX = ON | OFF, enables the DirectX11 software grabber (Windows)
16-
* ENABLE_FRAMEBUFFER = ON | OFF, enables the Framebuffer software grabber (Linux)
17-
* ENABLE_MAC_SYSTEM = ON | OFF, enables the macOS software grabber (macOS)
18-
* ENABLE_PIPEWIRE = ON | OFF, enables the Pipewire software grabber (Linux)
19-
* ENABLE_PIPEWIRE_EGL = ON | OFF, enables EGL for the Pipewire grabber (Linux)
20-
* ENABLE_X11 = ON | OFF, enables the X11 software grabber (Linux)
21-
* ENABLE_AMLOGIC = ON | OFF, forces the Amlogic software grabber (Linux)
15+
* ENABLE_DX = ON | OFF, enables the DirectX11 software grabber (Windows)
16+
* ENABLE_FRAMEBUFFER = ON | OFF, enables the Framebuffer software grabber (Linux)
17+
* ENABLE_MAC_SYSTEM = ON | OFF, enables the macOS software grabber (macOS)
18+
* ENABLE_PIPEWIRE = ON | OFF, enables the Pipewire software grabber (Linux)
19+
* ENABLE_PIPEWIRE_EGL = ON | OFF, enables EGL for the Pipewire grabber (Linux)
20+
* ENABLE_X11 = ON | OFF, enables the X11 software grabber (Linux)
21+
* ENABLE_AMLOGIC = ON | OFF, forces the Amlogic software grabber (Linux)
2222

2323
* HARDWARE GRABBERS
24-
* ENABLE_AVF = ON | OFF, enables the AVF USB grabber support (macOS)
25-
* ENABLE_MF = ON | OFF, enables the MediaFoundation USB grabber support (Windows)
26-
* ENABLE_V4L2 = ON | OFF, enables the V4L2 USB grabber support (Linux)
24+
* ENABLE_AVF = ON | OFF, enables the AVF USB grabber support (macOS)
25+
* ENABLE_MF = ON | OFF, enables the MediaFoundation USB grabber support (Windows)
26+
* ENABLE_V4L2 = ON | OFF, enables the V4L2 USB grabber support (Linux)
2727

2828
* SOUND CAPTURING
29-
* ENABLE_SOUNDCAPLINUX = ON | OFF, enables the ALSA sound grabber (Linux)
30-
* ENABLE_SOUNDCAPMACOS = ON | OFF, enables the sound grabber (macOS)
31-
* ENABLE_SOUNDCAPWINDOWS = ON | OFF, enables the sound grabber (Windows)
29+
* ENABLE_SOUNDCAPLINUX = ON | OFF, enables the ALSA sound grabber (Linux)
30+
* ENABLE_SOUNDCAPMACOS = ON | OFF, enables the sound grabber (macOS)
31+
* ENABLE_SOUNDCAPWINDOWS = ON | OFF, enables the sound grabber (Windows)
3232

3333
* SERVICE SUPPORT
34-
* ENABLE_BONJOUR = ON | OFF, enables mDNS (do not disable unless required)
35-
* ENABLE_CEC = ON | OFF, enables the HDMI-CEC support (Linux)
36-
* ENABLE_MQTT = ON | OFF, enables the MQTT support
37-
* ENABLE_POWER_MANAGEMENT = ON | OFF, enables sleep/wake up OS events support
38-
* ENABLE_PROTOBUF = ON | OFF, enables Proto-Buffer server
39-
* ENABLE_SYSTRAY = ON | OFF, enables the systray-widget
40-
* ENABLE_ZSTD = ON | OFF, enables ZSTD support for LUT decompression
34+
* ENABLE_BONJOUR = ON | OFF, enables mDNS (do not disable unless required)
35+
* ENABLE_CEC = ON | OFF, enables the HDMI-CEC support (Linux)
36+
* ENABLE_MQTT = ON | OFF, enables the MQTT support
37+
* ENABLE_POWER_MANAGEMENT = ON | OFF, enables sleep/wake up OS events support
38+
* ENABLE_PROTOBUF = ON | OFF, enables Proto-Buffer server
39+
* ENABLE_SYSTRAY = ON | OFF, enables the systray-widget
40+
* ENABLE_ZSTD = ON | OFF, enables ZSTD support for LUT decompression
4141

4242
* BUILD FEATURES
43-
* USE_SHARED_LIBS = ON | OFF, if disabled, build the application as monolithic
44-
* USE_EMBEDDED_WEB_RESOURCES = ON | OFF, if enable, embed web content into the application
45-
* USE_PRECOMPILED_HEADERS = ON | OFF, use pre-compiled headers when building
46-
* USE_CCACHE_CACHING = ON | OFF, enable CCache support if available
47-
* USE_SYSTEM_MQTT_LIBS = ON | OFF, prefer system qMQTT libs
48-
* USE_SYSTEM_FLATBUFFERS_LIBS = ON | OFF, prefer system Flatbuffers libs
49-
* USE_SYSTEM_SDBUS_CPP_LIBS = ON | OFF, prefer system sdbus_c++ libs
50-
* USE_SYSTEM_LUNASVG_LIBS = ON | OFF, prefer system lunasvg libs
51-
* USE_SYSTEM_NANOPB_LIBS = ON | OFF, prefer system nanopb libs
52-
* USE_SYSTEM_STB_LIBS = ON | OFF, prefer system stb libs
53-
* USE_STATIC_QT_PLUGINS = ON | OFF, embed static QT-plugins into the application
54-
* USE_STANDARD_INSTALLER_NAME = ON | OFF, use standard Linux package naming
43+
* USE_SHARED_LIBS = ON | OFF, build the application as non-monolithic
44+
* USE_EMBEDDED_WEB_RESOURCES = ON | OFF, embed web content into the app
45+
* USE_PRECOMPILED_HEADERS = ON | OFF, use pre-compiled headers when building
46+
* USE_CCACHE_CACHING = ON | OFF, enable CCache support if available
47+
* USE_SYSTEM_MQTT_LIBS = ON | OFF, prefer system qMQTT libs
48+
* USE_SYSTEM_FLATBUFFERS_LIBS = ON | OFF, prefer system Flatbuffers libs
49+
* USE_SYSTEM_SDBUS_CPP_LIBS = ON | OFF, prefer system sdbus_c++ libs
50+
* USE_SYSTEM_LUNASVG_LIBS = ON | OFF, prefer system lunasvg libs
51+
* USE_SYSTEM_NANOPB_LIBS = ON | OFF, prefer system nanopb libs
52+
* USE_SYSTEM_STB_LIBS = ON | OFF, prefer system stb libs
53+
* USE_STATIC_QT_PLUGINS = ON | OFF, embed static QT-plugins into the app
54+
* USE_STANDARD_INSTALLER_NAME = ON | OFF, use standard Linux package naming
5555

5656
----
5757

@@ -64,10 +64,7 @@ Use -D prefix when configuring the build.
6464
```console
6565
sudo apt-get update
6666

67-
sudo apt-get install build-essential cmake git libayatana-appindicator3-dev libasound2-dev wget unzip pkg-config
68-
libegl-dev libflatbuffers-dev flatbuffers-compiler libftdi1-dev libgl-dev libglvnd-dev liblzma-dev libgtk-3-dev
69-
libpipewire-0.3-dev libqt5serialport5-dev libssl-dev libx11-dev libsystemd-dev libturbojpeg0-dev libusb-1.0-0-dev
70-
libzstd-dev python3 pkg-config qtbase5-dev
67+
sudo apt-get install build-essential cmake flatbuffers-compiler git libasound2-dev libayatana-appindicator3-dev libegl-dev libflatbuffers-dev libftdi1-dev libgl-dev libglvnd-dev libgtk-3-dev liblzma-dev libpipewire-0.3-dev libssl-dev libsystemd-dev libturbojpeg0-dev libusb-1.0-0-dev libx11-dev libzstd-dev ninja-build patchelf pkg-config python3 qt6-serialport-dev qt6-base-dev unzip wget
7168
```
7269

7370
For Raspberry Pi CEC support (optional)
@@ -78,45 +75,41 @@ sudo apt-get install libcec-dev libp8-platform-dev libudev-dev
7875
### Fedora
7976

8077
```console
81-
sudo dnf -y group install "C Development Tools and Libraries" "Development Tools"
78+
sudo dnf -y install alsa-lib-devel chrpath cmake fedora-packager flatbuffers-compiler flatbuffers-devel gcc gcc-c++ git gtk3-devel libX11-devel libayatana-appindicator-gtk3-devel libftdi-c++-devel libglvnd-devel libusb1-devel libzstd-devel mesa-libEGL-devel mesa-libGL-devel ninja-build openssl-devel pipewire-devel pkg-config qt6-qtbase-devel qt6-qtserialport-devel systemd-devel turbojpeg-devel unzip wget xz-devel
8279

83-
sudo dnf -y install cmake chrpath git alsa-lib-devel flatbuffers-devel flatbuffers-compiler fedora-packager
84-
mesa-libEGL-devel libftdi-c++-devel mesa-libGL-devel gtk3-devel libglvnd-devel libayatana-appindicator-gtk3-devel
85-
pipewire-devel qt5-qtserialport-devel qt5-qtbase-devel openssl-devel turbojpeg-devel libusb1-devel libX11-devel
86-
libzstd-devel pkg-config wget xz-devel systemd-devel unzip
8780
```
8881

8982
### Arch Linux
9083

9184
```console
9285
sudo pacman -Syy
9386

94-
sudo pacman -S base-devel qt5-base openssl chrpath cmake flatbuffers git alsa-lib gtk3 libayatana-appindicator
95-
libftdi libglvnd libjpeg-turbo qt5-serialport wayland libx11 freetds libfbclient mariadb-libs postgresql-libs
96-
pipewire python mesa dpkg xz fakeroot binutils pkgfile bash systemd-libs wget unzip
87+
sudo pacman -S alsa-lib base-devel bash binutils chrpath cmake dpkg fakeroot flatbuffers freetds git gtk3 libayatana-appindicator libfbclient libftdi libglvnd libjpeg-turbo libx11 mariadb-libs mesa ninja openssl pipewire pkgfile postgresql-libs python qt6-base qt6-serialport sdbus-cpp systemd-libs unzip wayland wget xz
9788
```
9889

9990
### Windows
10091

101-
We assume a 64bit Windows 10. Install the following;
92+
We assume a 64bit Windows 10. Install the following:
93+
10294
- [Git](https://git-scm.com/downloads) (Check during installation: Add to PATH)
10395
- [CMake (Windows win64-x64 Installer)](https://cmake.org/download/) (Check during installation: Add to PATH)
10496
- [Visual Studio 2022 Community Edition](https://visualstudio.microsoft.com/downloads/)
105-
- Select 'Desktop development with C++'
106-
- On the right, just select `MSVC v143 VS 2022 C++ x64/x86-Buildtools` and latest `Windows 10 SDK`. Everything else is not needed, but you can stay with default selection.
97+
- Select 'Desktop development with C++'
98+
- On the right, just select `MSVC v143 VS 2022 C++ x64/x86-Buildtools` and latest `Windows 10 SDK`. Everything else is not needed, but you can stay with default selection.
10799
- [OpenSSL](https://slproweb.com/products/Win32OpenSSL.html) (for QT5.15-6.2: OpenSSL v1.1.1, for QT6: OpenSSL 3)
108100
- [libjpeg-turbo](https://github.com/libjpeg-turbo/libjpeg-turbo/releases)
109101
- [Python 3 (Windows x86-64 executable installer)](https://www.python.org/downloads/windows/) (Check during installation: Add to PATH and Debug Symbols)
110-
- Open a console window and execute `pip install aqtinstall`.
111-
- Now we can download Qt to _C:\Qt_ `mkdir c:\Qt && aqt install -O c:\Qt 6.8.3 windows desktop win64_msvc2022_64 -m qtserialport`
112-
- May need to add QT6 path before compiling, for example: `set CMAKE_PREFIX_PATH=C:\Qt\6.8.3\msvc2022_64\lib\cmake\` or for older QT5 `set Qt5_Dir=C:\Qt\5.15.2\msvc2019_64\lib\cmake\Qt5\`
102+
- Open a console window and execute `pip install aqtinstall`.
103+
- Now we can download Qt to _C:\Qt_ `mkdir c:\Qt && aqt install -O c:\Qt 6.8.3 windows desktop win64_msvc2022_64 -m qtserialport`
104+
- May need to add QT6 path before compiling, for example: `set CMAKE_PREFIX_PATH=C:\Qt\6.8.3\msvc2022_64\lib\cmake\` or for older QT5 `set Qt5_Dir=C:\Qt\5.15.2\msvc2019_64\lib\cmake\Qt5\`
113105
- Optional for creating installer packages: [NSIS 3.x](https://sourceforge.net/projects/nsis/files/NSIS%203/) ([direct link](https://sourceforge.net/projects/nsis/files/latest/download))
114106

115-
Hint: after you execute the configuration command in the build folder (for example ```cmake -DCMAKE_BUILD_TYPE=Release ..```) you should receive *.sln solution project file that can be opened in Visual Studio. Select `hyperhdr` project as default for the solution to run it after compilation.
107+
> [!TIP]
108+
> After you execute the configuration command in the build folder (for example ```cmake -DCMAKE_BUILD_TYPE=Release ..```) you should receive *.sln solution project file that can be opened in Visual Studio. Select `hyperhdr` project as default for the solution to run it after compilation.
116109
117110
### macOS
118111
First install [brew](https://brew.sh/) manager.
119-
Next: `brew install qt@6 cmake xz pkg-config`
112+
Next: `brew install qtbase qtserialport cmake xz pkg-config`
120113

121114
## Compiling and installing HyperHDR
122115

@@ -186,7 +179,7 @@ PROJECT=Generic DEVICE=Generic ARCH=x86_64 ./scripts/create_addon hyperhdr
186179

187180
# Build a HyperHDR installer for any supported Linux system on any system using Docker
188181

189-
All you need is Docker and bash, which is available on every supported system, even on Windows where you only need to enable "Windows Subsystem for Linux". You don't need to install any packages to build HyperHDR because the script uses Docker images provided by https://github.com/awawa-dev/HyperHDR.dev.docker which contain everything you need to build the installer. Thanks to this, you can compile eg. the aarch64 HyperHDR installer for Raspberry Pi even on a PC. Run the `build.sh` script in the main directory.
182+
All you need is Docker and bash, which is available on every supported system, even on Windows where you only need to enable "Windows Subsystem for Linux". You don't need to install any packages to build HyperHDR because the script uses Docker images provided by https://github.com/awawa-dev/HyperDockerBuilder which contain everything you need to build the installer. Thanks to this, you can compile eg. the aarch64 HyperHDR installer for Raspberry Pi even on a PC. Run the `build.sh` script in the main directory.
190183

191184
```console
192185
pi@ubuntu:~/hyperhdr$ ./build.sh
@@ -202,7 +195,7 @@ DISTRO_NAME | DISTRO_VERSION | ARCHITECTURE - these are only for linux targets
202195
debian | bookworm | amd64
203196
debian | trixie | armhf
204197
debian | trixie | arm64
205-
debian | trixie | amd64
198+
debian | trixie | amd64
206199
ubuntu | jammy | amd64
207200
ubuntu | noble | amd64
208201
ubuntu | questing | amd64
@@ -225,7 +218,7 @@ The `build.sh` script can also be used to natively build macOS/Windows installer
225218

226219
----
227220

228-
# Github Action (online - easiest)
221+
# Online:Github Action
229222

230223
Fork HyperHDR project. Now you must enable project's `Settings → Actions → Actions permissions → Allow all actions and reusable workflows` and save it.
231224
Once you've done this, any change, even using the Github online editor, will immediately trigger the build in the Actions tab. If this did not happen, you probably did not enable the option described or did it later after making the changes.

include/led-drivers/other/DriverOtherFile.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class DriverOtherFile : public LedDevice
1919
bool init(QJsonObject deviceConfig) override;
2020
int open() override;
2121
int close() override;
22-
int writeColors(const std::vector<ColorRgb>* ledValues, const SharedOutputColors infiniteColors);
22+
int writeColors(const std::vector<ColorRgb>* ledValues, const SharedOutputColors& infiniteColors);
2323
int writeFiniteColors(const std::vector<ColorRgb>& ledValues) override;
2424
std::pair<bool, int> writeInfiniteColors(SharedOutputColors nonlinearRgbColors) override;
2525

sources/led-drivers/other/DriverOtherFile.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ std::pair<bool, int> DriverOtherFile::writeInfiniteColors(SharedOutputColors non
100100
return { false,0 };
101101
}
102102

103-
int DriverOtherFile::writeColors(const std::vector<ColorRgb>* ledValues, const SharedOutputColors nonlinearRgbColors)
103+
int DriverOtherFile::writeColors(const std::vector<ColorRgb>* ledValues, const SharedOutputColors& nonlinearRgbColors)
104104
{
105105
QTextStream out(_file);
106106
size_t result = 0;

0 commit comments

Comments
 (0)