File release-notes-sles.spec of Package release-notes-sles.5283

#
# spec file for package release-notes-sles
#
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#


Name:           release-notes-sles
Version:        12.1.20170726
Release:        0
Summary:        Release Notes for SUSE Linux Enterprise Server
License:        CC-BY-ND-3.0
Group:          Documentation/SUSE
Url:            http://www.suse.com/releasenotes/
BuildRequires:  daps
BuildRequires:  recode
BuildRequires:  suse-xsl-stylesheets >= 1.9.18
BuildRequires:  update-desktop-files
BuildRequires:  w3m
Requires:       dejavu-fonts
Requires:       google-opensans-fonts
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch
Source:         %{name}-%{version}.tar.bz2
Source1:        %{name}.desktop
Source100:      yast.xsl
Source101:      tmp.diff

%description
This package contains the release notes for SUSE Linux Enterprise Server.
After installing this package, the release notes files can be
found in the /usr/share/doc/release-notes directory.  The release notes
are available in the following output formats: PDF, HTML, and TXT.

%prep
%setup -q
cp %{S:100} .
# patch -p 1 < %{S:101}

%build
%define SUSE_PROD SUSE_Linux_Enterprise_Server_12
sed -i 's/@VERSION@/%{version}/' xml/release-notes.xml
make

%install
rnpath=%{buildroot}%{_datadir}/doc/release-notes/%{SUSE_PROD}
%{__install} -m 0644 -D LICENSE ${rnpath}/LICENSE
%{__install} -m 0644 -D "build/release-notes/single-html/release-notes/release-notes.html" "${rnpath}/RELEASE-NOTES.en.html"
%{__cp} -R "build/release-notes/single-html/release-notes/static/" "${rnpath}"
%{__install} -m 0644 -D "build/release-notes/yast-html/release-notes.html" "${rnpath}/RELEASE-NOTES.en.rtf"
%{__install} -m 0644 -D "build/release-notes/release-notes_color_en.pdf" "${rnpath}/RELEASE-NOTES.en.pdf"
%{__install} -m 0644 -D "build/release-notes/release-notes.txt" "${rnpath}/RELEASE-NOTES.en.txt"
%{__install} -m 0644 -D "%{_sourcedir}/%{name}.desktop" "%{buildroot}%{_datadir}/susehelp/meta/%{name}.desktop"
echo "DocPath=%{_datadir}/doc/release-notes/%{SUSE_PROD}/RELEASE-NOTES.en.html" > "%{buildroot}%{_datadir}/susehelp/meta/%{name}.desktop"
%suse_update_desktop_file %{buildroot}%{_datadir}/susehelp/meta/%{name}.desktop

%files
%defattr (-,root,root,-)
%doc %{_datadir}/doc/release-notes/
%dir %{_datadir}/susehelp/
%dir %{_datadir}/susehelp/meta/
%{_datadir}/susehelp/meta/%{name}.desktop

%changelog
openSUSE Build Service is sponsored by