From 8b2a9c7c92fecdeaeca0fce447ffc1c8630eea20 Mon Sep 17 00:00:00 2001 From: Mattia Verga Date: Mon, 18 May 2020 14:37:55 +0200 Subject: [PATCH 1/2] Initial import in epel8 --- .gitignore | 1 + generate-tarball.sh | 28 ++++++++++ phd2.spec | 126 ++++++++++++++++++++++++++++++++++++++++++++ phd2_cflags.patch | 18 +++++++ sources | 1 + 5 files changed, 174 insertions(+) create mode 100644 .gitignore create mode 100755 generate-tarball.sh create mode 100644 phd2.spec create mode 100644 phd2_cflags.patch create mode 100644 sources diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1670158 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/phd2-2.6.8-purged.tar.xz diff --git a/generate-tarball.sh b/generate-tarball.sh new file mode 100755 index 0000000..35b828a --- /dev/null +++ b/generate-tarball.sh @@ -0,0 +1,28 @@ +#!/bin/sh + +VERSION=$1 + +tar -xzvf phd2-$VERSION.tar.gz + +#Remove pre-built software +rm -rf phd2-$VERSION/WinLibs +rm -rf phd2-$VERSION/extra_frameworks +rm -rf phd2-$VERSION/thirdparty/*.zip +rm -rf phd2-$VERSION/thirdparty/*.tar.gz +rm -rf phd2-$VERSION/thirdparty/*.tar.bz2 +rm -rf phd2-$VERSION/thirdparty/frameworks +rm -rf phd2-$VERSION/thirdparty/HID_Utilities +rm -rf phd2-$VERSION/thirdparty/include +rm -rf phd2-$VERSION/thirdparty/openssag +rm -rf phd2-$VERSION/thirdparty/VidCapture +find . -name "*.dll" -type f -delete +find . -name "*.lib" -type f -delete +find . -name "*.dylib" -type f -delete +find . -name "*.a" -type f -delete +find . -name "*.so" -type f -delete +rm -rf phd2-$VERSION/cameras/qhyccdlibs/qhyfirmware.zip + +tar -cJvf phd2-$VERSION-purged.tar.xz phd2-$VERSION + +#Remove temporary directory +rm -rf phd2-$VERSION diff --git a/phd2.spec b/phd2.spec new file mode 100644 index 0000000..f47d2a1 --- /dev/null +++ b/phd2.spec @@ -0,0 +1,126 @@ +Name: phd2 +Version: 2.6.8 +Release: 1%{?dist} +Summary: Telescope guiding software +# Main program files are BSD licensed +# Some components have different licenses: +# QHY camera headers are GPLv2+ +# SX camera headers are ICU +# INDI GUI is LGPLv2+ +License: BSD and (GPLv2+ and MIT and LGPLv2+) +URL: http://openphdguiding.org/ +# Download upstream tarball from +# https://github.com/OpenPHDGuiding/%%{name}/archive/v%%{version}.tar.gz +# and then run ./generate-tarball.sh %%{version} +Source0: %{name}-%{version}-purged.tar.xz +# Script to purge binaries and unneeded files from downloaded sources +Source1: generate-tarball.sh + +# Use C++14 flag +Patch99: phd2_cflags.patch + +BuildRequires: cmake3 +BuildRequires: desktop-file-utils +BuildRequires: dos2unix +BuildRequires: extra-cmake-modules +BuildRequires: gettext +BuildRequires: gtest-devel +BuildRequires: libappstream-glib +BuildRequires: libindi-static +BuildRequires: libnova-devel +BuildRequires: wxGTK3-devel + +BuildRequires: pkgconfig(cfitsio) +BuildRequires: pkgconfig(eigen3) +BuildRequires: pkgconfig(libcurl) +BuildRequires: pkgconfig(libindi) +BuildRequires: pkgconfig(libusb-1.0) +BuildRequires: pkgconfig(zlib) + +Requires: libindi + + +%description +PHD2 is telescope guiding software that simplifies the process of tracking +a guide star, letting you concentrate on other aspects of deep-sky imaging +or spectroscopy. + + +%prep +%autosetup -p1 + +# Remove spurious executable bit set on icons and docs +find icons -type f -print0 |xargs -0 chmod -x +chmod -x PHD_2.0_Architecture.docx + + +%build +mkdir -p %{_target_platform} +pushd %{_target_platform} +%{cmake3} -DUSE_SYSTEM_CFITSIO=ON \ + -DUSE_SYSTEM_LIBUSB=ON \ + -DUSE_SYSTEM_EIGEN3=ON \ + -DUSE_SYSTEM_GTEST=ON \ + -DUSE_SYSTEM_LIBINDI=ON \ + -DOPENSOURCE_ONLY=ON .. + +%make_build + + +%install +pushd %{_target_platform} +%make_install +popd + +%find_lang %{name} + +%check +env CTEST_OUTPUT_ON_FAILURE=1 make test -C %{_target_platform} + +desktop-file-validate %{buildroot}/%{_datadir}/applications/%{name}.desktop +appstream-util validate-relax --nonet %{buildroot}/%{_datadir}/metainfo/%{name}.appdata.xml + + +%files -f %{name}.lang +%doc README.txt PHD_2.0_Architecture.docx +%license LICENSE.txt +%{_bindir}/* +%{_datadir}/metainfo/%{name}.appdata.xml +%{_datadir}/applications/%{name}.desktop +%{_datadir}/phd2/ +%{_datadir}/pixmaps/* + + +%changelog +* Mon May 18 2020 Mattia Verga - 2.6.8-1 +- Upgrade to 2.6.8 + +* Sat Feb 08 2020 Mattia Verga - 2.6.7-1 +- Upgrade to 2.6.7 + +* Sat Mar 30 2019 Mattia Verga - 2.6.6-1 +- Upgrade to 2.6.6 +- Enable tests on i686 + +* Mon May 07 2018 Mattia Verga - 2.6.5-1 +- Upgrade to 2.6.5 +- Remove obsolete scriptlets +- Use upstream patch to disable third party drivers + +* Sat Nov 11 2017 Mattia Verga - 2.6.4-3.1 +- Change weak dependency to standard dependency for EPEL7 +- Change macros to cmake3 in EPEL + +* Sun Nov 05 2017 Mattia Verga - 2.6.4-3 +- Fix spurious exec bits and line endings +- Use more macros +- Purge another unneeded directory from sources +- Use C++14 flag + +* Sat Nov 04 2017 Mattia Verga - 2.6.4-2 +- Breakdown components licenses +- Add some useful docs +- Add weak dependency to libindi + +* Thu Nov 02 2017 Mattia Verga - 2.6.4-1 +- Initial packaging diff --git a/phd2_cflags.patch b/phd2_cflags.patch new file mode 100644 index 0000000..52f31f2 --- /dev/null +++ b/phd2_cflags.patch @@ -0,0 +1,18 @@ +diff -U 3 -dHrN -- a/cmake_modules/compiler_options.cmake b/cmake_modules/compiler_options.cmake +--- a/cmake_modules/compiler_options.cmake 2017-09-26 00:21:15.000000000 +0200 ++++ b/cmake_modules/compiler_options.cmake 2017-11-05 08:22:16.662695768 +0100 +@@ -64,10 +64,13 @@ + #set(CMAKE_LIBRARY_ARCHITECTURE x86) + else() + # c++11 options ++ check_cxx_compiler_flag(-std=c++14 HAS_CXX14_FLAG) + check_cxx_compiler_flag(-std=c++11 HAS_CXX11_FLAG) + check_cxx_compiler_flag(-std=c++0x HAS_CXX0X_FLAG) + +- if(HAS_CXX11_FLAG) ++ if(HAS_CXX14_FLAG) ++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14") ++ elseif(HAS_CXX11_FLAG) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") + elseif(HAS_CXX0X_FLAG) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++0x") diff --git a/sources b/sources new file mode 100644 index 0000000..f8ea090 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (phd2-2.6.8-purged.tar.xz) = 8f57cf49972af92e7618f39352fda2d890286cca7697e7c855f9ceab108172263693ff61bb25bc4a979d3196fa1bcd5bb8c5a6886350c435246f7993772ad1e2 From df1bae26e29e9023644420768cb3b8490e462a45 Mon Sep 17 00:00:00 2001 From: Troy Dawson Date: Thu, 10 Feb 2022 15:25:50 -0800 Subject: [PATCH 2/2] epel8-playground decommissioned : https://pagure.io/epel/issue/136 --- .gitignore | 1 - README.md | 3 -- dead.package | 1 + generate-tarball.sh | 28 ---------- phd2.spec | 126 -------------------------------------------- phd2_cflags.patch | 18 ------- sources | 1 - 7 files changed, 1 insertion(+), 177 deletions(-) delete mode 100644 .gitignore delete mode 100644 README.md create mode 100644 dead.package delete mode 100755 generate-tarball.sh delete mode 100644 phd2.spec delete mode 100644 phd2_cflags.patch delete mode 100644 sources diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 1670158..0000000 --- a/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/phd2-2.6.8-purged.tar.xz diff --git a/README.md b/README.md deleted file mode 100644 index 9722aaf..0000000 --- a/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# phd2 - -The phd2 package \ No newline at end of file diff --git a/dead.package b/dead.package new file mode 100644 index 0000000..a72aec0 --- /dev/null +++ b/dead.package @@ -0,0 +1 @@ +epel8-playground decommissioned : https://pagure.io/epel/issue/136 diff --git a/generate-tarball.sh b/generate-tarball.sh deleted file mode 100755 index 35b828a..0000000 --- a/generate-tarball.sh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/sh - -VERSION=$1 - -tar -xzvf phd2-$VERSION.tar.gz - -#Remove pre-built software -rm -rf phd2-$VERSION/WinLibs -rm -rf phd2-$VERSION/extra_frameworks -rm -rf phd2-$VERSION/thirdparty/*.zip -rm -rf phd2-$VERSION/thirdparty/*.tar.gz -rm -rf phd2-$VERSION/thirdparty/*.tar.bz2 -rm -rf phd2-$VERSION/thirdparty/frameworks -rm -rf phd2-$VERSION/thirdparty/HID_Utilities -rm -rf phd2-$VERSION/thirdparty/include -rm -rf phd2-$VERSION/thirdparty/openssag -rm -rf phd2-$VERSION/thirdparty/VidCapture -find . -name "*.dll" -type f -delete -find . -name "*.lib" -type f -delete -find . -name "*.dylib" -type f -delete -find . -name "*.a" -type f -delete -find . -name "*.so" -type f -delete -rm -rf phd2-$VERSION/cameras/qhyccdlibs/qhyfirmware.zip - -tar -cJvf phd2-$VERSION-purged.tar.xz phd2-$VERSION - -#Remove temporary directory -rm -rf phd2-$VERSION diff --git a/phd2.spec b/phd2.spec deleted file mode 100644 index f47d2a1..0000000 --- a/phd2.spec +++ /dev/null @@ -1,126 +0,0 @@ -Name: phd2 -Version: 2.6.8 -Release: 1%{?dist} -Summary: Telescope guiding software -# Main program files are BSD licensed -# Some components have different licenses: -# QHY camera headers are GPLv2+ -# SX camera headers are ICU -# INDI GUI is LGPLv2+ -License: BSD and (GPLv2+ and MIT and LGPLv2+) -URL: http://openphdguiding.org/ -# Download upstream tarball from -# https://github.com/OpenPHDGuiding/%%{name}/archive/v%%{version}.tar.gz -# and then run ./generate-tarball.sh %%{version} -Source0: %{name}-%{version}-purged.tar.xz -# Script to purge binaries and unneeded files from downloaded sources -Source1: generate-tarball.sh - -# Use C++14 flag -Patch99: phd2_cflags.patch - -BuildRequires: cmake3 -BuildRequires: desktop-file-utils -BuildRequires: dos2unix -BuildRequires: extra-cmake-modules -BuildRequires: gettext -BuildRequires: gtest-devel -BuildRequires: libappstream-glib -BuildRequires: libindi-static -BuildRequires: libnova-devel -BuildRequires: wxGTK3-devel - -BuildRequires: pkgconfig(cfitsio) -BuildRequires: pkgconfig(eigen3) -BuildRequires: pkgconfig(libcurl) -BuildRequires: pkgconfig(libindi) -BuildRequires: pkgconfig(libusb-1.0) -BuildRequires: pkgconfig(zlib) - -Requires: libindi - - -%description -PHD2 is telescope guiding software that simplifies the process of tracking -a guide star, letting you concentrate on other aspects of deep-sky imaging -or spectroscopy. - - -%prep -%autosetup -p1 - -# Remove spurious executable bit set on icons and docs -find icons -type f -print0 |xargs -0 chmod -x -chmod -x PHD_2.0_Architecture.docx - - -%build -mkdir -p %{_target_platform} -pushd %{_target_platform} -%{cmake3} -DUSE_SYSTEM_CFITSIO=ON \ - -DUSE_SYSTEM_LIBUSB=ON \ - -DUSE_SYSTEM_EIGEN3=ON \ - -DUSE_SYSTEM_GTEST=ON \ - -DUSE_SYSTEM_LIBINDI=ON \ - -DOPENSOURCE_ONLY=ON .. - -%make_build - - -%install -pushd %{_target_platform} -%make_install -popd - -%find_lang %{name} - -%check -env CTEST_OUTPUT_ON_FAILURE=1 make test -C %{_target_platform} - -desktop-file-validate %{buildroot}/%{_datadir}/applications/%{name}.desktop -appstream-util validate-relax --nonet %{buildroot}/%{_datadir}/metainfo/%{name}.appdata.xml - - -%files -f %{name}.lang -%doc README.txt PHD_2.0_Architecture.docx -%license LICENSE.txt -%{_bindir}/* -%{_datadir}/metainfo/%{name}.appdata.xml -%{_datadir}/applications/%{name}.desktop -%{_datadir}/phd2/ -%{_datadir}/pixmaps/* - - -%changelog -* Mon May 18 2020 Mattia Verga - 2.6.8-1 -- Upgrade to 2.6.8 - -* Sat Feb 08 2020 Mattia Verga - 2.6.7-1 -- Upgrade to 2.6.7 - -* Sat Mar 30 2019 Mattia Verga - 2.6.6-1 -- Upgrade to 2.6.6 -- Enable tests on i686 - -* Mon May 07 2018 Mattia Verga - 2.6.5-1 -- Upgrade to 2.6.5 -- Remove obsolete scriptlets -- Use upstream patch to disable third party drivers - -* Sat Nov 11 2017 Mattia Verga - 2.6.4-3.1 -- Change weak dependency to standard dependency for EPEL7 -- Change macros to cmake3 in EPEL - -* Sun Nov 05 2017 Mattia Verga - 2.6.4-3 -- Fix spurious exec bits and line endings -- Use more macros -- Purge another unneeded directory from sources -- Use C++14 flag - -* Sat Nov 04 2017 Mattia Verga - 2.6.4-2 -- Breakdown components licenses -- Add some useful docs -- Add weak dependency to libindi - -* Thu Nov 02 2017 Mattia Verga - 2.6.4-1 -- Initial packaging diff --git a/phd2_cflags.patch b/phd2_cflags.patch deleted file mode 100644 index 52f31f2..0000000 --- a/phd2_cflags.patch +++ /dev/null @@ -1,18 +0,0 @@ -diff -U 3 -dHrN -- a/cmake_modules/compiler_options.cmake b/cmake_modules/compiler_options.cmake ---- a/cmake_modules/compiler_options.cmake 2017-09-26 00:21:15.000000000 +0200 -+++ b/cmake_modules/compiler_options.cmake 2017-11-05 08:22:16.662695768 +0100 -@@ -64,10 +64,13 @@ - #set(CMAKE_LIBRARY_ARCHITECTURE x86) - else() - # c++11 options -+ check_cxx_compiler_flag(-std=c++14 HAS_CXX14_FLAG) - check_cxx_compiler_flag(-std=c++11 HAS_CXX11_FLAG) - check_cxx_compiler_flag(-std=c++0x HAS_CXX0X_FLAG) - -- if(HAS_CXX11_FLAG) -+ if(HAS_CXX14_FLAG) -+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14") -+ elseif(HAS_CXX11_FLAG) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") - elseif(HAS_CXX0X_FLAG) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++0x") diff --git a/sources b/sources deleted file mode 100644 index f8ea090..0000000 --- a/sources +++ /dev/null @@ -1 +0,0 @@ -SHA512 (phd2-2.6.8-purged.tar.xz) = 8f57cf49972af92e7618f39352fda2d890286cca7697e7c855f9ceab108172263693ff61bb25bc4a979d3196fa1bcd5bb8c5a6886350c435246f7993772ad1e2