File release-notes-openSUSE.spec of Package release-notes-openSUSE.2463
#
# spec file for package release-notes-openSUSE
#
# Copyright (c) 2014 SUSE LINUX Products 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-openSUSE
BuildRequires: docbook-xsl-stylesheets
BuildRequires: libxslt
BuildRequires: recode
BuildRequires: update-desktop-files
BuildRequires: w3m
BuildRequires: xml2po
BuildRequires: xmlcharent
%ifarch i586 x86_64 ppc ppc64
BuildRequires: xmlgraphics-fop
%endif
Summary: Release Notes for this openSUSE Release
License: GFDL-1.2
Group: Documentation/SUSE
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Version: 13.1.10
Release: 0
Provides: release-notes = %{version}
Source0: release-notes-opensuse-%{version}.tar.bz2
Source8: %{name}.desktop.in
Url: http://en.opensuse.org
%description
This package contains the release notes with the most important changes
for this openSUSE release. In HTML format, they are available in the
help center.
The release notes are maintained in the public SVN repository at
https://svn.opensuse.org/svn/opensuse-doc/trunk/release-notes/opensuse.
%prep
%setup -q -n release-notes-opensuse-%{version}
# rfile=RELEASE-NOTES-openSUSE.en.po
rfile=po/en.po
[ -f $rfile ] || {
echo $rfile is missing
exit 1
}
%build
%define SUSE_PROD openSUSE
./configure --prefix=/usr
# xmlgraphics-fop does not build on armv7l aarch64
%ifarch armv7l aarch64
LANG="en_US.UTF-8" make all arch=%_arch prod=slprof SUSE_PROD=%SUSE_PROD
%else
LANG="en_US.UTF-8" make all pdf arch=%_arch prod=slprof SUSE_PROD=%SUSE_PROD
%endif
%install
make DESTDIR=$RPM_BUILD_ROOT SUSE_PROD=%SUSE_PROD install
rnpath="${RPM_BUILD_ROOT}"/usr/share/doc/release-notes/%SUSE_PROD
[ -f $rnpath/RELEASE-NOTES.cs.html ] && {
[ -f $rnpath/RELEASE-NOTES.sk.html ] || {
ln -s RELEASE-NOTES.cs.html $rnpath/RELEASE-NOTES.sk.html
# ln -s RELEASE-NOTES.cs.rtf $rnpath/RELEASE-NOTES.sk.rtf
}
}
for h in $rnpath/RELEASE-NOTES.*.html; do
ln -s ${h#$rnpath/} ${h/html/rtf}
done
mkdir -p $RPM_BUILD_ROOT/usr/share/susehelp/meta
sed 's/@SUSE_PROD@/%{SUSE_PROD}/' $RPM_SOURCE_DIR/%{name}.desktop.in \
> $RPM_BUILD_ROOT/usr/share/susehelp/meta/%{name}.desktop
{
for f in "${RPM_BUILD_ROOT}"/usr/share/doc/release-notes/%SUSE_PROD/RELEASE-NOTES.*.html ; do
l=${f%\.html}
l=${l##*\.}
echo "DocPath[$l]=/usr/share/doc/release-notes/%{SUSE_PROD}/RELEASE-NOTES.$l.html"
done
} >>$RPM_BUILD_ROOT/usr/share/susehelp/meta/%{name}.desktop
%suse_update_desktop_file $RPM_BUILD_ROOT/usr/share/susehelp/meta/%{name}.desktop
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root)
%doc fdl.txt
%dir /usr/share/susehelp
%dir /usr/share/susehelp/meta
/usr/share/susehelp/meta/%{name}.desktop
%doc /usr/share/doc/release-notes
%changelog