Bug 458715

Summary: unable to build the lib
Product: [Frameworks and Libraries] frameworks-syntax-highlighting Reporter: yannick.kohn
Component: frameworkAssignee: KWrite Developers <kwrite-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: nicolas.fella
Priority: NOR    
Version First Reported In: 5.97.0   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: msvc build error and cmd rcc error

Description yannick.kohn 2022-09-04 21:05:20 UTC
Created attachment 151819 [details]
msvc build error and cmd rcc error

Hi,

I have tried to compile the lib on Windows MSVC 2019 x64 and Qt 5.15.6 
I have followed the guideline to compile the last snapshot available on github
I use cmake and then open the .sln generated. It seems that the cpp file from the qrc is not generated. If it try to do the rcc manually, it failed because the file index.katesyntax is not present.  I have missed something ?
Comment 1 Nicolas Fella 2022-09-04 22:08:17 UTC
index.katesyntax is generated at build time: https://invent.kde.org/frameworks/syntax-highlighting/-/blob/master/data/CMakeLists.txt#L60 and is marked as a dependency of the qrc build: https://invent.kde.org/frameworks/syntax-highlighting/-/blob/master/data/CMakeLists.txt#L68

It builds fine on our Windows CI: https://invent.kde.org/frameworks/syntax-highlighting/-/jobs/461572

That uses the Ninja CMake generator though, not the Visual Studio generator. I don't see anything obviously wrong in out CMake code, so this might be a bug in CMake
Comment 2 yannick.kohn 2022-09-05 12:00:59 UTC
Hi,

I have tried with Ninja and it works fine. Files are generated and it compiles without issue. I guess can be good to specify this on the windows build guidelines! Thanks !