Bug 155856 - Port C++ SDK examples make files to cmake / qmake
Summary: Port C++ SDK examples make files to cmake / qmake
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: difficultyMedium, easyHack, skillCpp, skillScript
Depends on:
Blocks: Dev-related
  Show dependency treegraph
 
Reported: 2023-06-15 14:00 UTC by Hossein
Modified: 2024-01-19 20:17 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Hossein 2023-06-15 14:00:07 UTC
There are various C++ SDK examples available via LibreOffice SDK. some of them are listed here:

C++ examples
https://api.libreoffice.org/examples/examples.html#Cpp_examples

Others can be found inside odk/examples/cpp/, and also odk/examples/DevelopersGuide/. These examples are supposed to be built using GNU Make, which has several problems, and need many dependencies. On the other hand, building the examples using modern build tools like cmake and qmake is much easier.

This task here is to port C++ SDK examples makefile to cmake and or qmake. Below you can find some examples on how to port the make files to cmake/qmake.

Blog post: Using cmake to build LibreOffice C++ SDK examples
https://dev.blog.documentfoundation.org/2022/04/19/using-cmake-to-build-libreoffice-cpp-sdk-examples/

Video: LibreOffice SDK Examples Overhaul - LibreOffice Conference 2021
https://www.youtube.com/watch?v=zWLFv5AR3uY

Example: LOConvertor
https://github.com/hosseinn/loconvertor
Comment 1 dev.limarev 2024-01-18 22:39:34 UTC
If you don't mind I'd be happy to assign it
Comment 2 Hossein 2024-01-18 23:07:08 UTC
(In reply to dev.limarev from comment #1)
> If you don't mind I'd be happy to assign it
There is an ongoing work for this issue, and I am going to merge this patch soon:

tdf#155856 Port C++ SDK example make file to cmake / qmake
https://gerrit.libreoffice.org/c/core/+/153540

Once it is merged, you can use this patch as a blueprint, and do the same for other SDK examples.

Anyway, this is a multi-hacker EasyHack, so you can work on it without assigning to yourself.
Comment 3 dev.limarev 2024-01-19 20:17:02 UTC
(In reply to Hossein from comment #2)

No problem! I added cmake find modules to LO SDK: https://gerrit.libreoffice.org/c/core/+/162321

Of course, cmake <Package>-config.cmake is the right way, not Find<Package>.cmake, because it depends on build and install stage. But such changes requires LO SDK to be build by cmake.