OBS build error: directories not owned by a package (/usr/share/unity-greeter)

I’m new at packaging rpm’s (I have some experience in packaging for Arch Linux) and I’ve started work on some packages that are not on OBS (yet).

I’ve managed to tackle most hurdles (documentation for packaging for openSUSE is great), but I can’t seem to find the proper solution for this one:

   45s] steam-login-session-12.1-7.1.noarch.rpm: directories not owned by a package:
   45s]  - /usr/share/unity-greeter

My %files section is:

%license LICENSE

Some documenation states that removing the /usr/share/unity-greeter/ entry should resolve the error, but then it complains that the file is packages but not in the files section.

The package I’m working on is here: https://build.opensuse.org/package/show/home:tyrannishawk/steam-login-session

Can someone point me in the right direction?

Add this to your files-section:


But you know, there are macros for /usr/share

Is there unity-greeter for openSUSE? If yes, adding it to BuildRequires should fix the error. If not, why would someone need to package files that are useless on openSUSE? Just delete them.

Very useful link. Thanks!

Ah, that’s what it’s for. In that case removing this from the package will clean it up and resolve the issue. Thanks!