libindi/libindi.spec

138 lines
3.2 KiB
RPMSpec
Raw Normal View History

2021-05-13 11:29:28 +00:00
# Define boolean to quickly set option and dependencies for
# building QT5 client
%global build_qt5_client 1
# Define boolean to quickly set option and dependencies for
# unit tests
2022-01-06 16:51:40 +00:00
# s390x test fail https://github.com/indilib/indi/issues/1359
%ifarch s390x
%global build_tests 0
%else
2022-01-06 16:09:20 +00:00
%global build_tests 1
2022-01-06 16:51:40 +00:00
%endif
2021-05-13 11:29:28 +00:00
2022-02-05 14:34:57 +00:00
Name: libindi
2022-12-04 09:11:02 +00:00
Version: 1.9.9
2022-05-24 10:00:48 +00:00
Release: %autorelease
2022-02-05 14:34:57 +00:00
Summary: Instrument Neutral Distributed Interface
2009-02-09 15:58:11 +00:00
2022-02-05 14:34:57 +00:00
License: LGPLv2+ and GPLv2+
# See COPYRIGHT file for a description of the licenses and files covered
2009-02-09 15:58:11 +00:00
2022-02-05 14:34:57 +00:00
URL: http://www.indilib.org
2022-05-24 10:08:26 +00:00
Source0: https://github.com/indilib/indi/archive/v%{version}/indi-%{version}.tar.gz
2009-02-09 15:58:11 +00:00
2023-01-29 14:54:23 +00:00
# rawhideFix: add missing header complained about with Fedora38/rawhide
# https://github.com/indilib/indi/pull/1817
Patch: https://github.com/indilib/indi/pull/1817.patch
2017-10-08 07:23:18 +00:00
BuildRequires: cmake
2022-08-06 11:20:35 +00:00
BuildRequires: libev-devel
2022-02-27 12:55:05 +00:00
BuildRequires: libogg-devel
2015-09-07 09:13:23 +00:00
BuildRequires: libnova-devel
2022-02-27 12:55:05 +00:00
BuildRequires: libtheora-devel
2015-09-07 09:13:23 +00:00
BuildRequires: systemd
2017-10-08 07:23:18 +00:00
BuildRequires: pkgconfig(cfitsio)
2021-05-13 11:29:28 +00:00
BuildRequires: pkgconfig(fftw3)
2017-10-08 07:23:18 +00:00
BuildRequires: pkgconfig(libcurl)
BuildRequires: pkgconfig(gsl)
BuildRequires: pkgconfig(libjpeg)
BuildRequires: pkgconfig(libusb-1.0)
BuildRequires: pkgconfig(zlib)
2009-02-09 15:58:11 +00:00
2021-05-13 11:29:28 +00:00
%if 0%{?build_qt5_client}
BuildRequires: pkgconfig(Qt5Network)
%global qt5_client ON
%else
%global qt5_client OFF
%endif
%if 0%{?build_tests}
BuildRequires: pkgconfig(gtest)
BuildRequires: pkgconfig(gmock)
%global tests ON
%else
%global tests OFF
%endif
2018-01-02 12:16:51 +00:00
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
2009-02-09 15:58:11 +00:00
%description
INDI is a distributed control protocol designed to operate
astronomical instrumentation. INDI is small, flexible, easy to parse,
and scalable. It supports common DCS functions such as remote control,
data acquisition, monitoring, and a lot more.
2018-01-02 12:16:51 +00:00
2009-02-09 15:58:11 +00:00
%package devel
Summary: Libraries, includes, etc. used to develop an application with %{name}
2018-01-02 12:16:51 +00:00
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
2017-10-07 17:48:53 +00:00
Requires: %{name}-static%{?_isa} = %{version}-%{release}
2009-02-09 15:58:11 +00:00
%description devel
These are the header files needed to develop a %{name} application
2018-01-02 12:16:51 +00:00
%package libs
Summary: INDI shared libraries
%description libs
These are the shared libraries of INDI.
%package static
Summary: Static libraries, includes, etc. used to develop an application with %{name}
2018-01-02 12:16:51 +00:00
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
%description static
Static library needed to develop a %{name} application
2009-02-09 15:58:11 +00:00
%prep
2022-05-24 10:08:26 +00:00
%autosetup -p1 -n indi-%{version}
2022-01-06 16:09:20 +00:00
2021-05-13 11:29:28 +00:00
# For Fedora we want to put udev rules in %%{_udevrulesdir}
2015-09-07 09:13:23 +00:00
sed -i 's|/lib/udev/rules.d|%{_udevrulesdir}|g' CMakeLists.txt
chmod -x drivers/telescope/pmc8driver.h
chmod -x drivers/telescope/pmc8driver.cpp
2009-02-09 15:58:11 +00:00
%build
2021-05-13 11:29:28 +00:00
%cmake \
-DINDI_BUILD_QT5_CLIENT="%{qt5_client}" \
-DINDI_BUILD_UNITTESTS="%{tests}"
%cmake_build
2009-02-09 15:58:11 +00:00
%install
%cmake_install
2021-05-13 11:29:28 +00:00
%check
%if 0%{?build_tests}
2022-01-06 16:09:20 +00:00
%ctest --test-dir test
2021-05-13 11:29:28 +00:00
%endif
2009-02-09 15:58:11 +00:00
%files
2015-09-07 09:13:23 +00:00
%license COPYING.BSD COPYING.GPL COPYING.LGPL COPYRIGHT LICENSE
2018-05-26 10:39:08 +00:00
%doc AUTHORS ChangeLog NEWS README
2009-02-09 15:58:11 +00:00
%{_bindir}/*
%{_datadir}/indi
2015-09-07 09:13:23 +00:00
%{_udevrulesdir}/*.rules
2009-02-09 15:58:11 +00:00
2018-01-02 12:16:51 +00:00
%files libs
%license COPYING.BSD COPYING.GPL COPYING.LGPL COPYRIGHT LICENSE
%{_libdir}/*.so.*
%{_libdir}/indi/MathPlugins
2009-02-09 15:58:11 +00:00
%files devel
%{_includedir}/*
%{_libdir}/*.so
%{_libdir}/pkgconfig/*.pc
%files static
%{_libdir}/*.a
2009-02-09 15:58:11 +00:00
%changelog
2022-05-24 10:00:48 +00:00
%autochangelog