View Single Post
Posts: 635 | Thanked: 1,535 times | Joined on Feb 2014 @ Germany
#208
I used Schturmans Guide for NOOBS.
It is not necessary to build the RPMs as root or use the root home directory.

Just modify the spec file for example like this:


Code:
Name:          okboard-spanish
Version:       0.1
Release:       1
Summary:       Spanish language for OKBoard
Group:         System/Tools
Vendor:        YourName/Alias
Distribution:  SailfishOS
Packager: YourName/Alias <your@mail.adress>


License:       GPL

%description
Spanish language files for OkBoard

%files

%defattr(-,root,root,-)
/usr/share/okboard/es.tre.gz
/usr/share/okboard/predict-es.db.gz
/usr/share/okboard/predict-es.ng.gz

%post

%postun
if [ $1 = 0 ]; then
    // Do stuff specific to uninstalls
rm -rf /usr/share/okboard/es.tre.gz
rm -rf /usr/share/okboard/predict-es.db.gz
rm -rf /usr/share/okboard/predict-es.ng.gz

else
if [ $1 = 1 ]; then
    // Do stuff specific to upgrades
echo "It's just upgrade"
fi
fi

%changelog
* Wed Jan 20 2016 YourName <your@mail.adress> 0.1
- First build
GZip the three files for OKBoard like described in the Readme.md.

Create the folder
/home/nemo/rpmbuild/BUILD/okboard-spanish-0.1-1.arm/usr/share/okboard

The folder name in the BUILD directory depends on the spec file entries.
<Name>-<Version>-<Release>.arm

Copy the three OKBoard language files into the newly created folder.

Copy your created .spec file to /home/nemo/rpmbuild/SPECS

Build the RPM on your Jolla.

Last edited by mautz; 2016-01-20 at 13:51.
 

The Following 4 Users Say Thank You to mautz For This Useful Post: