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

Name:           kstars
Version:        14.12.3
Release:        0
Summary:        Desktop Planetarium
License:        GPL-2.0+
Group:          Productivity/Scientific/Astronomy
Source0:        %{name}-%{version}.tar.xz
# latest version from git master to fix build with newer libindi
Source1:        FindINDI.cmake
Source2:        FindNova.cmake
Patch0:         gcc6-fix.patch
Patch1:         support-newer-libindi.patch
BuildRequires:  Mesa-devel
BuildRequires:  fdupes
BuildRequires:  pkgconfig(cfitsio)
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
BuildRequires:  xplanet
BuildRequires:  xz
Recommends:     libindi
Recommends:     xplanet
Provides:       kstars-data = %{version}
Obsoletes:      kstars-data < %{version}
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

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.

%setup -q
%patch0 -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/

%ifarch ppc ppc64
export RPM_OPT_FLAGS="%{optflags} -mminimal-toc"
%cmake_kde4 -d build

%kde4_makeinstall -C build

# Remove static library
rm -f %{buildroot}%{_kde4_libdir}/libhtmesh.a


%fdupes -s %{buildroot}

%doc AUTHORS COPYING COPYING.DOC ChangeLog README README.customize README.ephemerides README.images kstars.lsm
%dir %{_kde4_datadir}/appdata
%doc %{_kde4_htmldir}/en/kstars/

openSUSE Build Service is sponsored by