I am trying to build a Sailfish OS
app, and I need to use *.wav
files, which are to be distributed through the *.rpm
package. In my case, these files are to be put in /usr/share/[application_name]/sounds/*
. How do I set up the *.pro
and *.yamp
files accordingly?
I finally found an answer!
I want to thank to the owner of that project:
https://github.com/krig/metronom-sailfish
From the .pro
and the .yaml
files of this project i found out how to deploy the files. First, we declare that constant:DEPLOYMENT_PATH = /usr/share/$${TARGET}
which seems to hold the path to /usr/share/[appname]
. Next, we define some kind of a variable (TODO
: find a more detailed explanation of that). The definition of that first sets the path to the files, for example, data.files = data
(the second data
is the folder). Next, we set data.path
to $${DEPLOYMENT_PATH}
. We list all the files in OTHER_FILES
and add the setting, in our case, data
, to INSTALLS
. Now, that we are finished with the .pro
file, we move to the .yaml
file for the .rpm
and we add to the necessary line to the Files:
section, in our case, - '%{_datadir}/%{name}/data'
, the last being the folder we need to add. TODO
: to whoever is more experienced, please provide a more detailed answer.