in the .yaml file “Files’s” section as suggested by the libsailfishapp documentation
Used the qsTr() variables as suggested by the QML docs. And even lupdated the TS files to have qm files.
But in the end, it doesn’t seem to work, at least in the emulator, so I am wondering what did I forget ? I don’t see other modifications/files in other sailfish apps so I guess it’s something I’m missing when building the app from the Sailfish IDE. I failed in finding additional documentation so if you have something I’d be glad and thankful about it !
Hi! I don’t have the '%{_datadir}/%{name}/translations'} line so I don’t think it’s mandatory.
However you missed the first instruction and need to add this in your .pro:
/srv/mer/toolings/SailfishOS-4.2.0.21//opt/cross/bin/i486-meego-linux-gnu-ld: /usr/lib/crt1.o: in function _start': (.text+0x18): undefined reference to main’
Which means I lack a main function somewhere. Should I create a main in the initial page although my code has no C in it ?
Oh I hadn’t noticed that your app doesn’t use SailfishApp (which indeed requires a main .cpp file with a main function), so those instructions are probably not adapted. I don’t know then, sorry
The steps are explained in the How to use SailfishApp in your project paragraph.
But I don’t know the exact changes that you have to do to transform a pure QML project to one with a .cpp file and a main, what I had done a few years ago was to generate a Sailfish OS application with the SDK and start from the generated structure: Sailfish SDK Your First App - SailfishOS Documentation
So indeed @Sthocs you provided me with the solution, thank you very much.
For new comers struggling, bellow is the explanation of my struggling and how I’ve fixed it.
When I first created my app I followed the Creating an application in Python example, which did not require any c++ file to work.
But when I saw your commentary I decided to check the SDK documentation and discovered that you can (should ?) indeed add a .cpp file in the src/ folder.
I did so, added the proper libraries (I just copied the ones from Quickddit ) :