Skip to content

Commit f8182c7

Browse files
author
Simon Inns
committed
Make ld-json-converter convert PAL-M and fix nix environment to ensure SVG icons are displayed in ld-analyse
1 parent 5e0a178 commit f8182c7

4 files changed

Lines changed: 8 additions & 2 deletions

File tree

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ set(CMAKE_AUTOMOC ON)
119119
include(GNUInstallDirs)
120120
set(CMAKE_AUTOUIC ON)
121121

122-
find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets Sql)
122+
find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets Sql Svg)
123123
message(STATUS "Qt Version: ${QT_VERSION}")
124124

125125
find_package(PkgConfig REQUIRED)

flake.nix

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@
7777
python3Packages.numpy
7878
];
7979
EZPWD_DIR = "${ezpwdSrc}/c++";
80+
shellHook = ''
81+
export QT_PLUGIN_PATH=${pkgs.qt6.qtsvg}/lib/qt-6/plugins''${QT_PLUGIN_PATH:+:$QT_PLUGIN_PATH}
82+
'';
8083
};
8184
}
8285
);

src/ld-analyse/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ target_include_directories(ld-analyse PRIVATE
4040
)
4141

4242
target_link_libraries(ld-analyse PRIVATE
43-
Qt::Core Qt::Gui Qt::Widgets
43+
Qt::Core Qt::Gui Qt::Widgets Qt::Svg
4444
lddecode-library lddecode-chroma
4545
)
4646

src/ld-json-converter/lddecodemetadata.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,9 @@ static const VideoSystemDefaults &getSystemDefaults(const LdDecodeMetaData::Vide
9696
// Return true and set system if found; if not found, return false.
9797
bool parseVideoSystemName(QString name, VideoSystem &system)
9898
{
99+
// Accept "PAL-M" as an alias for "PAL_M"
100+
if (name == "PAL-M") name = "PAL_M";
101+
99102
// Search VIDEO_SYSTEM_DEFAULTS for a matching name
100103
for (const auto &defaults: VIDEO_SYSTEM_DEFAULTS) {
101104
if (name == defaults.name) {

0 commit comments

Comments
 (0)