File kstars.spec of Package kstars4
#
# spec file for package kstars
#
# Copyright (c) 2015 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: kstars
Version: 14.12.3
Release: 0
Summary: Desktop Planetarium
License: GPL-2.0+
Group: Productivity/Scientific/Astronomy
Url: http://edu.kde.org/kstars/
Source0: %{name}-%{version}.tar.xz
# latest version from git master to fix build with newer libindi
Source1: FindINDI.cmake
Source2: FindNova.cmake
Patch: gcc6-fix.patch
Patch1: support-newer-libindi.patch
BuildRequires: Mesa-devel
BuildRequires: fdupes
BuildRequires: libcfitsio-devel
BuildRequires: libeigen3-devel
BuildRequires: libindi
BuildRequires: libindi-devel
BuildRequires: libkde4-devel
BuildRequires: libnova-devel
BuildRequires: libqjson-devel
%if 0%{?suse_version}
BuildRequires: update-desktop-files
%endif
BuildRequires: xplanet
BuildRequires: xz
Recommends: libindi
Recommends: xplanet
Provides: kstars-data = %{version}
Obsoletes: kstars-data < %{version}
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%kde4_runtime_requires
%description
KStars is a Desktop Planetarium for KDE. It provides an accurate graphical
simulation of the night sky, from any location on Earth, at any date and time.
%prep
%setup -q
%patch -p1
#causes package requirement on libindi1 when built against libindi 1.4.1, I need to look into that...
%patch1 -p1
cp %{SOURCE1} cmake/modules/
cp %{SOURCE2} cmake/modules/
%build
%ifarch ppc ppc64
export RPM_OPT_FLAGS="%{optflags} -mminimal-toc"
%endif
%cmake_kde4 -d build
%make_jobs
%install
%kde4_makeinstall -C build
# Remove static library
rm -f %{buildroot}%{_kde4_libdir}/libhtmesh.a
%kde_post_install
%fdupes -s %{buildroot}
%files
%defattr(-,root,root,-)
%doc AUTHORS COPYING COPYING.DOC ChangeLog README README.customize README.ephemerides README.images kstars.lsm
%dir %{_kde4_datadir}/appdata
%doc %{_kde4_htmldir}/en/kstars/
%{_kde4_applicationsdir}/kstars.desktop
%{_kde4_appsdir}/kstars/
%{_kde4_bindir}/kstars
%{_kde4_configdir}/kstars.knsrc
%{_kde4_configkcfgdir}/kstars.kcfg
%{_kde4_datadir}/appdata/kstars.appdata.xml
%{_kde4_iconsdir}/hicolor/*/apps/kstars.*
%changelog