mirror of
https://gitlab.com/kelteseth/ScreenPlay.git
synced 2024-11-25 20:22:39 +01:00
Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
e2c1618458
@ -1,50 +1,66 @@
|
||||
{
|
||||
"version": 4,
|
||||
"cmakeMinimumRequired": {
|
||||
"major": 3,
|
||||
"minor": 18,
|
||||
"patch": 0
|
||||
},
|
||||
"configurePresets": [
|
||||
{
|
||||
"name": "ScreenPlay_64bit_Debug_Windows",
|
||||
"displayName": "ScreenPlay 64bit Debug Windows",
|
||||
"description": "Windows only!",
|
||||
"generator": "Ninja",
|
||||
"binaryDir": "${sourceDir}/../build_ScreenPlay_Qt_6_3_0_MSVC2019",
|
||||
"architecture": {
|
||||
"value": "x64",
|
||||
"strategy": "external"
|
||||
},
|
||||
"cacheVariables": {
|
||||
"CMAKE_BUILD_TYPE": "Debug",
|
||||
"CMAKE_PREFIX_PATH": "C:/Qt/6.3.1/msvc2019_64",
|
||||
"CMAKE_TOOLCHAIN_FILE": "${sourceDir}/../ScreenPlay-vcpkg/scripts/buildsystems/vcpkg.cmake",
|
||||
"VCPKG_TARGET_TRIPLET": "x64-windows"
|
||||
}
|
||||
},
|
||||
{
|
||||
"name": "ScreenPlay_64bit_Debug_Linux",
|
||||
"displayName": "ScreenPlay 64bit Debug Linux",
|
||||
"description": "Linux only!",
|
||||
"generator": "Ninja",
|
||||
"binaryDir": "${sourceDir}/../build_ScreenPlay_Qt_6_3_0_GCC",
|
||||
"architecture": {
|
||||
"value": "x64",
|
||||
"strategy": "external"
|
||||
},
|
||||
"cacheVariables": {
|
||||
"CMAKE_BUILD_TYPE": "Debug",
|
||||
"CMAKE_PREFIX_PATH": "~/aqt/6.3.1/gcc_64",
|
||||
"CMAKE_TOOLCHAIN_FILE": "${sourceDir}/../ScreenPlay-vcpkg/scripts/buildsystems/vcpkg.cmake",
|
||||
"VCPKG_TARGET_TRIPLET": "x64-linux"
|
||||
}
|
||||
"version": 4,
|
||||
"cmakeMinimumRequired": {
|
||||
"major": 3,
|
||||
"minor": 18,
|
||||
"patch": 0
|
||||
},
|
||||
"configurePresets": [
|
||||
{
|
||||
"name": "windows-debug",
|
||||
"displayName": "ScreenPlay 64bit Debug Windows",
|
||||
"description": "Windows only!",
|
||||
"generator": "Ninja",
|
||||
"binaryDir": "${sourceDir}/../build_ScreenPlay_Qt_6_4_1_MSVC2019",
|
||||
"condition": {
|
||||
"type": "equals",
|
||||
"lhs": "${hostSystemName}",
|
||||
"rhs": "Windows"
|
||||
},
|
||||
"architecture": {
|
||||
"value": "x64",
|
||||
"strategy": "external"
|
||||
},
|
||||
"cacheVariables": {
|
||||
"CMAKE_BUILD_TYPE": "Debug",
|
||||
"CMAKE_PREFIX_PATH": "C:/Qt/6.4.1/msvc2019_64",
|
||||
"CMAKE_TOOLCHAIN_FILE": "${sourceDir}/../ScreenPlay-vcpkg/scripts/buildsystems/vcpkg.cmake",
|
||||
"VCPKG_TARGET_TRIPLET": "x64-windows"
|
||||
}
|
||||
],
|
||||
"buildPresets": [
|
||||
{
|
||||
"name": "default",
|
||||
"configurePreset": "ScreenPlay_64bit_Debug"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "linux-debug",
|
||||
"displayName": "ScreenPlay 64bit Debug Linux",
|
||||
"description": "Linux only!",
|
||||
"generator": "Ninja",
|
||||
"binaryDir": "${sourceDir}/../build_ScreenPlay_Qt_6_4_1_GCC",
|
||||
"condition": {
|
||||
"type": "equals",
|
||||
"lhs": "${hostSystemName}",
|
||||
"rhs": "Linux"
|
||||
},
|
||||
"architecture": {
|
||||
"value": "x64",
|
||||
"strategy": "external"
|
||||
},
|
||||
"cacheVariables": {
|
||||
"CMAKE_CXX_COMPILER": "g++",
|
||||
"CMAKE_C_COMPILER": "gcc",
|
||||
"CMAKE_BUILD_TYPE": "Debug",
|
||||
"CMAKE_PREFIX_PATH": "$env{HOME}/aqt/6.4.1/gcc_64",
|
||||
"CMAKE_TOOLCHAIN_FILE": "${sourceDir}/../ScreenPlay-vcpkg/scripts/buildsystems/vcpkg.cmake",
|
||||
"VCPKG_TARGET_TRIPLET": "x64-linux"
|
||||
}
|
||||
}
|
||||
],
|
||||
"buildPresets": [
|
||||
{
|
||||
"name": "linux-debug",
|
||||
"configurePreset": "linux-debug"
|
||||
},
|
||||
{
|
||||
"name": "windows-debug",
|
||||
"configurePreset": "windows-debug"
|
||||
}
|
||||
]
|
||||
}
|
@ -1,31 +1,29 @@
|
||||
# Developer Setup
|
||||
1. Install latest [git + git-lfs](https://git-scm.com/)
|
||||
2. Install [python 3](https://www.python.org/)
|
||||
2. Install latest [python 3](https://www.python.org/)
|
||||
3. Clone ScreenPlay
|
||||
``` bash
|
||||
git clone --recursive https://gitlab.com/kelteseth/ScreenPlay.git ScreenPlay
|
||||
git clone --recursive https://gitlab.com/kelteseth/ScreenPlay.git ScreenPlay/ScreenPlay
|
||||
```
|
||||
4. Download the latest __Qt 6.3.x__ for you platform. Earlier versions are not supported!
|
||||
4. Download the latest __Qt 6.4.x__ for you platform. Earlier versions are not supported!
|
||||
1. [Install instructions Windows](#windows)
|
||||
1. [Install instructions Linux](#linux)
|
||||
1. [Install instructions MacOSX](#macosx)
|
||||
5. Start the following script to download all needed dependencies automatically. This will create a ScreenPlay-vcpkg folder in the same directory as your ScreenPlay source folder.
|
||||
``` bash
|
||||
cd Tools
|
||||
py setup.py
|
||||
# Windows defaults to python
|
||||
python setup.py
|
||||
# Linux and macOS uses python3
|
||||
python3 setup.py
|
||||
```
|
||||
* This will install these dependencies via __vcpkg__
|
||||
* openSSL
|
||||
* sentry-native
|
||||
* doctest
|
||||
* infoware
|
||||
|
||||
<div>
|
||||
<img width="100%" height="auto" src="../.gitlab/media/QtCreator_kit.png">
|
||||
</div>
|
||||
|
||||
5. Open __QtCreator__ and open the settings `Tools -> Options`
|
||||
6. Clone an existing kit like `Qt 6.3.1 MSVC2019 64bit` and add `ScreenPlay` to the new kit name
|
||||
6. Clone an existing kit like `Qt 6.4.1 MSVC2019 64bit` and add `ScreenPlay` to the new kit name
|
||||
5. Edit CMake variables amd add CMAKE_TOOLCHAIN_FILE and VCPKG_TARGET_TRIPLET
|
||||
* `Kits -> <Your_Kit> -> CMake Configuration`
|
||||
|
||||
@ -39,7 +37,6 @@ Append this:
|
||||
-DVCPKG_TARGET_TRIPLET:STRING=arm64-osx
|
||||
```
|
||||
|
||||
|
||||
6. Save and close the settings.
|
||||
7. Open Project via `File -> Open File or Project` and select your `CMakeLists.txt`. Then select __our created kit__, press `Configure Project`
|
||||
<div>
|
||||
@ -54,7 +51,7 @@ Append this:
|
||||
1. [Download and install Qt binary installer from qt.io](https://www.qt.io/download-qt-installer)
|
||||
- Install the Maintaince tool
|
||||
- Select the following features to install:
|
||||
- Qt 6.3.1
|
||||
- Qt 6.4.1
|
||||
- MSVC 2019 64-bit
|
||||
- **ALL Additional Libraries**
|
||||
- Qt Quick 3d
|
||||
@ -63,16 +60,17 @@ Append this:
|
||||
- Developer and Designer Tools
|
||||
- Cmake
|
||||
- Ninja
|
||||
## Linux via qt.io account
|
||||
1. Install dependencies for your distro:
|
||||
## Linux dependencies
|
||||
1. Install dependencies for Debian/Ubuntu:
|
||||
``` bash
|
||||
# Debian/Ubuntu
|
||||
sudo apt install build-essential git gpg ffmpeg mesa-common-dev libxkbcommon-* libfontconfig curl zip unzip tar git pkg-config apt-transport-https ca-certificates gnupg software-properties-common wget software-properties-common python3-pip libgl1-mesa-dev lld ninja-build cmake qml-module-qt-websockets qtwebengine5-* -y
|
||||
sudo apt install build-essential git gpg ffmpeg mesa-common-dev libxkbcommon-* libfontconfig curl zip unzip tar cmake pkg-config apt-transport-https ca-certificates gnupg software-properties-common wget software-properties-common python3 python3-pip libgl1-mesa-dev lld ninja-build qml-module-qt-websockets qtwebengine5-* -y
|
||||
```
|
||||
|
||||
## Linux via qt.io account
|
||||
1. [Download and install Qt binary installer from qt.io](https://www.qt.io/download-qt-installer)
|
||||
- Install the Maintaince tool
|
||||
- Select the following features to install:
|
||||
- Qt 6.3.1
|
||||
- Qt 6.4.1
|
||||
- GCC
|
||||
- **ALL Additional Libraries**
|
||||
- Qt Quick 3d
|
||||
@ -83,26 +81,20 @@ sudo apt install build-essential git gpg ffmpeg mesa-common-dev libxkbcommon-
|
||||
- OpenSSL 64-bit binaries
|
||||
- Cmake
|
||||
- Ninja
|
||||
## Linux via aqt command line & VSCode
|
||||
|
||||
## Linux via aqt
|
||||
1. Alternativly download via aqt
|
||||
```
|
||||
pip3 install -U pip
|
||||
pip3 install aqtinstall
|
||||
aqt install-qt -O ~/aqt linux desktop 6.3.1 gcc_64 -m all
|
||||
python3 -m pip install aqtinstall
|
||||
python3 -m aqt install-qt -O ~/aqt linux desktop 6.4.1 gcc_64 -m all
|
||||
python3 -m aqt install-tool -O ~/aqt linux desktop tools_qtcreator
|
||||
```
|
||||
1. Open VSCode and install the `CMake Tools`
|
||||
1. ctrl + p: `CMake: Select Configure Preset`
|
||||
2. Select `ScreenPlay 64bit Debug Linux`
|
||||
3. ctrl + p: `CMake: Configure`
|
||||
4. ctrl + p: `CMake: Build`
|
||||
### Fix python scripts not in path:
|
||||
```
|
||||
vim ~/.bashrc
|
||||
```
|
||||
Add at the end of the file and restart the console/terminal:
|
||||
```
|
||||
export PATH="~/.local/bin:$PATH"
|
||||
```
|
||||
|
||||
|
||||
## MacOSX
|
||||
1. Install XCode 13+ , open and restart your device.
|
||||
@ -111,7 +103,7 @@ export PATH="~/.local/bin:$PATH"
|
||||
1. [Download and install Qt binary installer from qt.io](https://www.qt.io/download-qt-installer)
|
||||
- Install the Maintaince tool
|
||||
- Select the following features to install:
|
||||
- Qt 6.3.1
|
||||
- Qt 6.4.1
|
||||
- Qt WebEngine
|
||||
- **ALL Additional Libraries**
|
||||
- Qt Quick 3d
|
||||
@ -123,7 +115,7 @@ export PATH="~/.local/bin:$PATH"
|
||||
- Cmake
|
||||
- Ninja
|
||||
1. Change your default kit:
|
||||
- `QtCreator -> Options -> Kits -> Select your default kit (Desktop Qt 6.3.1) -> Change c and c++ Compiler to Apple Clang (x86_64)`
|
||||
- `QtCreator -> Options -> Kits -> Select your default kit (Desktop Qt 6.4.1) -> Change c and c++ Compiler to Apple Clang (x86_64)`
|
||||
|
||||
|
||||
# Developer docs
|
||||
|
@ -3,6 +3,7 @@
|
||||
#include "qarchive_enums.hpp"
|
||||
#include "qarchivediskcompressor.hpp"
|
||||
#include "qarchivediskextractor.hpp"
|
||||
#include <QDesktopServices>
|
||||
|
||||
#if defined(Q_OS_WIN)
|
||||
#include <sentry.h>
|
||||
@ -93,24 +94,8 @@ bool Util::writeJsonObjectToFile(const QString& absoluteFilePath, const QJsonObj
|
||||
*/
|
||||
void Util::openFolderInExplorer(const QString& url) const
|
||||
{
|
||||
|
||||
QString path = QUrl::fromUserInput(url).toLocalFile();
|
||||
|
||||
QProcess explorer;
|
||||
#ifdef Q_OS_WIN
|
||||
explorer.setProgram("explorer.exe");
|
||||
// When we have space in the path like
|
||||
// C:\Program Files (x86)\Steam\...
|
||||
// we cannot set the path as an argument. But we can set the working it
|
||||
// to the wanted path and open the current path via the dot.
|
||||
explorer.setWorkingDirectory(QDir::toNativeSeparators(path));
|
||||
explorer.setArguments({ "." });
|
||||
#elif defined(Q_OS_OSX)
|
||||
explorer.setProgram("open");
|
||||
explorer.setArguments({ QDir::toNativeSeparators(path) });
|
||||
#endif
|
||||
|
||||
explorer.startDetached();
|
||||
const QString path = QUrl::fromUserInput(url).toLocalFile();
|
||||
QDesktopServices::openUrl(QUrl::fromLocalFile(path));
|
||||
}
|
||||
|
||||
/*!
|
||||
|
Loading…
Reference in New Issue
Block a user