PDA

View Full Version : Missing LSB files in SLES 12



darrint
29-Jan-2015, 20:33
I am with an ISV trying to get our LSB compliant application working on SLES 12.


# rpm -i RPMS/noarch/mytestrpm-1.0-0.noarch.rpm
error: Failed dependencies:
lsb-core-noarch is needed by mytestrpm-1.0-0.noarch


I don't think this should be possible based on the documentation I've read.


# lsb_release
LSB Version: n/a
# lsb_release -a
LSB Version: n/a
Distributor ID: SUSE LINUX
Description: SUSE Linux Enterprise Server 12
Release: 12
Codename: 12


I don't believe that "n/a" is what should be showing up as lsb version. I can't find anything in the repositories to satisfy the lsb-core-* dependencies or provide /etc/lsb-release. Am I missing something obvious?

ab
29-Jan-2015, 21:52
A few things come to mind:

First, this looks like your own RPM, meaning you probably have the spec
file defining the requirement. Assuming the RPM you built on this system
has a program within that actually runs, meaning all dependencies are
actually satisfied regardless of the package's defined requirements (from
your spec file), your package is incorrect (since it is complaining about
a missing dependency that is actually there).

Second, the version should not matter as the error does not mention a
required version, just a dependent package by name. If you look for that
package using rpm or zypper you should see it, presumably, since (see
previous paragraph/point) your application presumably runs on this box:



rpm -qf `which lsb_release`


Use the returned package's name in your spec file as the dependency
instead of lsb-core-noarch and maybe that will help.

Finally, I would try using 'zypper' to install anything as it will pull
in dependencies if it can find them where 'rpm' will not unless all
dependencies are specified on the command line. Using zypper will not
help you if the package dependencies call for incorrect packages, but most
of the time that is not the case.


--
Good luck.

If you find this post helpful and are logged into the web interface,
show your appreciation and click on the star below...

malcolmlewis
29-Jan-2015, 22:07
On Thu 29 Jan 2015 08:52:29 PM CST, ab wrote:

A few things come to mind:

First, this looks like your own RPM, meaning you probably have the spec
file defining the requirement. Assuming the RPM you built on this
system has a program within that actually runs, meaning all
dependencies are actually satisfied regardless of the package's defined
requirements (from your spec file), your package is incorrect (since it
is complaining about a missing dependency that is actually there).

Second, the version should not matter as the error does not mention a
required version, just a dependent package by name. If you look for
that package using rpm or zypper you should see it, presumably, since
(see previous paragraph/point) your application presumably runs on this
box:



rpm -qf `which lsb_release`


Use the returned package's name in your spec file as the dependency
instead of lsb-core-noarch and maybe that will help.

Finally, I would try using 'zypper' to install anything as it will pull
in dependencies if it can find them where 'rpm' will not unless all
dependencies are specified on the command line. Using zypper will not
help you if the package dependencies call for incorrect packages, but
most of the time that is not the case.

Hi
Further to ab's comment, if your building for multiple distros and
releases then use a %if wrapper eg;


%if 0%{?suse_version} == 1315
BuildRequires: lsb-release
%else
BuildRequires: lsb-core

More info here;
https://en.opensuse.org/openSUSE:Build_Service_cross_distribution_howto

--
Cheers Malcolm °¿° LFCS, SUSE Knowledge Partner (Linux Counter #276890)
SUSE Linux Enterprise Desktop 12 GNOME 3.10.1 Kernel 3.12.32-33-default
If you find this post helpful and are logged into the web interface,
please show your appreciation and click on the star below... Thanks!

darrint
29-Jan-2015, 22:19
Yes. I am with an ISV trying to produce a single RPM which works on all LSB compliant Linux distributions. RHEL 5, RHEL 6, SLES 10, SLES 11, as well as CentOS and Oracle variants. We have been successfully implementing this for years, until SLES 12.

https://www.suse.com/partners/isv/porting_and_migration.html

SuSE makes strong statements recommending that I follow the LSB standard.

http://refspecs.linuxbase.org/LSB_4.0.0/LSB-Core-generic/LSB-Core-generic/pkgdepend.html

I believe I am correctly implementing my package dependencies according to the LSB standard. There should be installable packages or some other mechanism for providing those lsb-core-* dependencies. (Or I am doing it wrong.)

http://refspecs.linuxbase.org/LSB_4.0.0/LSB-Core-generic/LSB-Core-generic/lsbrelease.html

The example output of the lsb_release command is given in the standard. SuSE 12 returns "n/a" which strongly indicates to me that something is missing from my install. I need to know where to get the missing bits.

We only ever use zypper for package installation.

We perplexed as to why the LSB mechanisms are missing in SLES 12. Or we have somehow failed to install them.

malcolmlewis
29-Jan-2015, 22:35
On Thu 29 Jan 2015 09:24:02 PM CST, darrint wrote:


Yes. I am with an ISV trying to produce a single RPM which works on all
LSB compliant Linux distributions. RHEL 5, RHEL 6, SLES 10, SLES 11, as
well as CentOS and Oracle variants. We have been successfully
implementing this for years, until SLES 12.

https://www.suse.com/partners/isv/porting_and_migration.html

SuSE makes strong statements recommending that I follow the LSB
standard.

http://refspecs.linuxbase.org/LSB_4.0.0/LSB-Core-generic/LSB-Core-generic/pkgdepend.html

I believe I am correctly implementing my package dependencies according
to the LSB standard. There should be installable packages or some other
mechanism for providing those lsb-core-* dependencies. (Or I am doing it
wrong.)

http://refspecs.linuxbase.org/LSB_4.0.0/LSB-Core-generic/LSB-Core-generic/lsbrelease.html

The example output of the lsb_release command is given in the standard.
SuSE 12 returns "n/a" which strongly indicates to me that something is
missing from my install. I need to know where to get the missing bits.

We only ever use zypper for package installation.

We perplexed as to why the LSB mechanisms are missing in SLES 12. Or we
have somehow failed to install them.




Hi
It's best effort as 4 is old...
https://lizards.opensuse.org/2014/08/25/lsb-best-effort/

--
Cheers Malcolm °¿° LFCS, SUSE Knowledge Partner (Linux Counter #276890)
SUSE Linux Enterprise Desktop 12 GNOME 3.10.1 Kernel 3.12.32-33-default
If you find this post helpful and are logged into the web interface,
please show your appreciation and click on the star below... Thanks!

darrint
29-Jan-2015, 22:38
# rpm -qip --provides lsb-4.0-26.1.2.i586.rpm
warning: lsb-4.0-26.1.2.i586.rpm: Header V3 RSA/SHA256 Signature, key ID 3dbdc284: NOKEY
Name : lsb
Version : 4.0
Release : 26.1.2
Architecture: i586
Install Date: (not installed)
Group : System/Fhs
Size : 104
License : GPL-2.0+
Signature : RSA/SHA256, Thu Sep 25 04:35:45 2014, Key ID b88b2fd43dbdc284
Source RPM : lsb-4.0-26.1.2.src.rpm
Build Date : Thu Sep 25 04:35:36 2014
Build Host : build24
Relocations : /usr
Packager : http://bugs.opensuse.org
Vendor : openSUSE
URL : http://www.linuxbase.org/
Summary : Linux Standard Base Core
Description :
Necessary files and dependencies for the Linux Standard Base (LSB)
Core.
Distribution: openSUSE 13.2
lsb = 2.0
lsb = 4.0-26.1.2
lsb(x86-32) = 4.0-26.1.2
lsb-core-ia32 = 2.0
lsb-core-ia32 = 3.2
lsb-core-ia32 = 4.0
lsb-core-noarch = 2.0
lsb-core-noarch = 3.2
lsb-core-noarch = 4.0
lsb-graphics-ia32 = 2.0
lsb-graphics-ia32 = 3.2
lsb-graphics-ia32 = 4.0
lsb-graphics-noarch = 2.0
lsb-graphics-noarch = 3.2
lsb-graphics-noarch = 4.0


This package is present in openSUSE. Similar mechanisms are present in SLES 10 and 11. Why is (or where has) it gone in SLES 12?

darrint
29-Jan-2015, 23:08
Thanks. That is what I was missing. Very disappointing though.

ab
29-Jan-2015, 23:26
One of the SUSE devs has a version 4.1 here:

https://build.opensuse.org/package/binaries/home:kukuk:sles/lsb?repository=SLE_12

I found this in the SLES 12 DVD 1:

/mnt/suse/noarch/lsb-release-2.0-23.13.noarch.rpm

I do not suppose that helps, does it? It does not have any 'provides'
listed, though.

--
Good luck.

If you find this post helpful and are logged into the web interface,
show your appreciation and click on the star below...