89 lines
2.3 KiB
Plaintext
89 lines
2.3 KiB
Plaintext
[FILES]
|
|
|
|
If the installation is LSB compliant, the \fB"/etc/lsb-release"\fR
|
|
file should contain the \fBLSB_VERSION\fR field.
|
|
The value of the field should be a colon separated list of
|
|
supported module versions indicating the LSB specification
|
|
modules to which the installation is compliant. If the installation is not
|
|
compliant, the above field should
|
|
.B not
|
|
be present.
|
|
|
|
Optional fields are \fBDISTRIB_ID\fR, \fBDISTRIB_RELEASE\fR,
|
|
\fBDISTRIB_CODENAME\fR, \fBDISTRIB_DESCRIPTION\fR and can be used to
|
|
override information which is parsed from the
|
|
\fB"/etc/os-release"\fR file. Since \fB"/etc/os-release"\fR is the new
|
|
standard, there is no need anymore to add any of the optional
|
|
fields to \fB"/etc/lsb-release"\fR.
|
|
|
|
If the \fB"/etc/lsb-release.d"\fR directory exists, it is
|
|
searched for filenames which are taken as additional module-version
|
|
strings to add to \fBLSB_VERSION\fR.
|
|
|
|
The required line style is:
|
|
.br
|
|
"\fIDistributor\fR \fBrelease\fR \fIx.x\fR \fB(\fR\fICodename\fR\fB)\fR"
|
|
|
|
Where \fIDistributor\fR can be a couple of words, but then concatenated
|
|
(i.e. Linux Foo BarLinux Linux -> FooBarLinux),
|
|
.br
|
|
\fIx.x\fR starts with a digit followed by any non-blank characters,
|
|
\fICodename\fR will also be concatenated (blanks cleanup only).
|
|
|
|
[EXAMPLES]
|
|
If the "\fB/etc/lsb-release\fR" file contains:
|
|
|
|
LSB_VERSION="core-2.0-ia64:core-2.0-noarch"
|
|
.br
|
|
DISTRIB_DESCRIPTION="I enjoy using my distrib"
|
|
|
|
and the "\fB/etc/lsb-release.d\fR" directory contains:
|
|
|
|
graphics-2.0-ia64 graphics-2.0-noarch
|
|
|
|
and the "\fB/etc/os-release\fP" file contains:
|
|
|
|
NAME="SLES"
|
|
.br
|
|
VERSION="12-SP2"
|
|
.br
|
|
VERSION_ID="12.2"
|
|
.br
|
|
PRETTY_NAME="SUSE Linux Enterprise Server 12 SP2"
|
|
.br
|
|
ID="sles"
|
|
|
|
|
|
Then the results of various options will be:
|
|
|
|
.B $ ./lsb_release --all
|
|
.br
|
|
LSB Version: core-2.0-ia64:core-2.0-noarch:graphics-2.0-ia64:graphics-2.0-noarch
|
|
.br
|
|
Distributor ID: SUSE
|
|
.br
|
|
Description: I enjoy using my distrib
|
|
.br
|
|
Release: 12.2
|
|
.br
|
|
Codename: n/a
|
|
|
|
.B $ ./lsb_release -a -s
|
|
.br
|
|
1.0 SUSE "I enjoy using my distrib" 12.2 n/a
|
|
|
|
If the "/etc/lsb-release" file is absent (indicating this is
|
|
not an LSB compliant distribution), the result will be:
|
|
|
|
.B $ ./lsb_release -a
|
|
.br
|
|
LSB Version: n/a
|
|
.br
|
|
Distributor ID: SUSE
|
|
.br
|
|
Description: SUSE Linux Enterprise Server 12 SP2
|
|
.br
|
|
Release: 12.2
|
|
.br
|
|
Codename: n/a
|