brickstore: 2024.5.2 -> 2024.12.3

Update to its newest release
(https://github.com/rgriebl/brickstore/releases/tag/v2024.12.3) and
refactored changing the qcoro CMake file to use patches for relevant
parts
This commit is contained in:
langsjo 2025-05-08 19:09:23 +03:00
parent b22909a5fe
commit a585c294fb
3 changed files with 40 additions and 10 deletions

View File

@ -16,13 +16,13 @@ let
in
stdenv.mkDerivation (finalAttrs: {
pname = "brickstore";
version = "2024.5.2";
version = "2024.12.3";
src = fetchFromGitHub {
owner = "rgriebl";
repo = "brickstore";
rev = "v${finalAttrs.version}";
hash = "sha256-Bu9oNbZm3lx/CfYAReHyWe/kW+kaefDWeBtWLHOCORU=";
hash = "sha256-4sxPplZ1t8sSfwTCeeBtfU4U0gcE9FROt6dKvkfyO6Q=";
fetchSubmodules = true;
};
@ -45,16 +45,14 @@ stdenv.mkDerivation (finalAttrs: {
tbb
];
preConfigure = ''
sed -i '/^)$/d' cmake/BuildQCoro.cmake
patches = [
./qcoro-cmake.patch # Don't have CMake fetch qcoro from github, get it from nixpkgs
./qjsonvalue-include.patch # Add a required '#include <QtCore/QJsonValue>'
];
# Since we get qcoro from nixpkgs instead, change the CMake file to reflect the right directory
preConfigure = ''
substituteInPlace cmake/BuildQCoro.cmake \
--replace-fail 'FetchContent_Declare(' ' ' \
--replace-fail ' qcoro' ' ' \
--replace-fail ' GIT_REPOSITORY https://github.com/danvratil/qcoro.git' ' ' \
--replace-fail ' GIT_TAG v''${QCORO_VERSION}' ' ' \
--replace-fail 'FetchContent_GetProperties(qcoro)' ' ' \
--replace-fail 'FetchContent_Populate(qcoro)' ' ' \
--replace-fail \
'add_subdirectory(''${qcoro_SOURCE_DIR} ''${qcoro_BINARY_DIR} EXCLUDE_FROM_ALL)' \
'add_subdirectory(${qcoro.src} ${qcoro}bin/qcoro)'

View File

@ -0,0 +1,20 @@
diff --git a/cmake/BuildQCoro.cmake b/cmake/BuildQCoro.cmake
index 941e813..41c88c6 100644
--- a/cmake/BuildQCoro.cmake
+++ b/cmake/BuildQCoro.cmake
@@ -14,14 +14,6 @@ if (BACKEND_ONLY)
set(QCORO_WITH_QML OFF)
endif()
-FetchContent_Declare(
- qcoro
- GIT_REPOSITORY https://github.com/danvratil/qcoro.git
- GIT_TAG v${QCORO_VERSION}
- SOURCE_SUBDIR "NeedManualAddSubDir" # make it possible to add_subdirectory below
-)
-
-FetchContent_MakeAvailable(qcoro)
set(mll ${CMAKE_MESSAGE_LOG_LEVEL})
if (NOT VERBOSE_FETCH)

View File

@ -0,0 +1,12 @@
diff --git a/src/bricklink/order.cpp b/src/bricklink/order.cpp
index 14426e5b..59856f0c 100755
--- a/src/bricklink/order.cpp
+++ b/src/bricklink/order.cpp
@@ -16,6 +16,7 @@
#include <QtSql/QSqlError>
#include <QtSql/QSqlQueryModel>
#include <QtCore/QLoggingCategory>
+#include <QtCore/QJsonValue>
#include "bricklink/core.h"
#include "bricklink/io.h"