RPM harbour packages include bin path

The /usr/bin path is part of the filesystem package

# rpm -qf /usr/bin
filesystem-3.1+git5-1.7.1.jolla.noarch

but some applications do package it into there rpms:

# rpm -qf /usr/bin
harbour-screen-message-0.3.1-1.armv7hl
filesystem-3.1+git5-1.7.1.jolla.noarch
harbour-scribble-0.4-2.armv7hl
harbour-simplecrop-1.1.3-1.armv7hl
harbour-fishtheke-0.8-1.armv7hl
harbour-barcode-1.0.44-1.armv7hl
...



LANG=C rpm -V harbour-tasklist harbour-fahrplan2
.........    /usr/bin (replaced)
.........    /usr/bin (replaced)

Maybe a check to prevent this should be included into the harbour validation process?

5 Likes

Easy mistake to make.
That does show up as an error as an Error in standard rpmlint run though, even if harbour doesn’t care.

harbour-simplecrop.armv7hl: E: standard-dir-owned-by-package /usr/bin

And yeah, this is a disease:

 $ rpm -qf /usr/bin | wc -l
156

The fix, by the way, is in the .spec file:

## do not do this:
%files
...
%{_bindir}

## do this:
%files
...
%{_bindir}/*
6 Likes

Thanks, I’m going to check my code today :sweat_smile:

And corrected as well :slight_smile:

I just checked this; when you create a new project, the .yaml file contains the following:

Files:
  - '%{_bindir}'
  - '%{_datadir}/%{name}'
  - '%{_datadir}/applications/%{name}.desktop'
  - '%{_datadir}/icons/hicolor/*/apps/%{name}.png'

I think %{_bindir}/* or even %{_bindir}/%{name} would do better. The former works with my Battery Buddy, as I ship two binaries, but most apps would do with the latter…

So, this is a bug in the skeleton project itself, too, and I guess Jolla packages are also using it…

1 Like

Good catch, @vige maybe that would be some low-hanging fruit to fix in SDK 3.7.

Thank you, this is likely going to be fixed in SDK 3.8.

1 Like