1
0

Accepting request 506233 from devel:languages:python

OBS-URL: https://build.opensuse.org/request/show/506233
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-astropy?expand=0&rev=1
This commit is contained in:
Dominique Leuenberger 2017-08-24 16:28:41 +00:00 committed by Git OBS Bridge
commit 9e075a5780
6 changed files with 2498 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
.osc

3
astropy-1.3.2.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:2f1de9d239b76a7d940a7bd66408e370874c84476566a3ae693fd06653836ad0
size 8420201

1
python-astropy-rpmlintrc Normal file
View File

@ -0,0 +1 @@
addFilter('devel-file-in-non-devel-package .*/wcs/.*')

2322
python-astropy.changes Normal file

File diff suppressed because it is too large Load Diff

148
python-astropy.spec Normal file
View File

@ -0,0 +1,148 @@
#
# spec file for package python-astropy
#
# Copyright (c) 2017 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/
#
%bcond_without test
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-astropy
Version: 1.3.2
Release: 0
Summary: Community-developed python astronomy tools
License: BSD-3-Clause
Group: Development/Languages/Python
Url: http://astropy.org
Source: https://files.pythonhosted.org/packages/source/a/astropy/astropy-%{version}.tar.gz
# Mark wcs headers as false positives for devel-file-in-non-devel-package
# These are used by the python files so they must be available.
Source100: python-astropy-rpmlintrc
BuildRequires: %{python_module Cython >= 0.21}
BuildRequires: %{python_module numpy-devel >= 1.7.0}
BuildRequires: %{python_module devel}
BuildRequires: %{python_module jupyter_ipython}
BuildRequires: %{python_module ply}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: hdf5-devel
BuildRequires: libxml2-tools
BuildRequires: python-rpm-macros
BuildRequires: pkgconfig(cfitsio)
BuildRequires: pkgconfig(erfa) >= 1.3.0
BuildRequires: pkgconfig(expat)
BuildRequires: pkgconfig(wcslib)
# Documentation
BuildRequires: %{python_module Pillow}
%if %{with test}
# Optional requirements
BuildRequires: %{python_module Jinja2}
BuildRequires: %{python_module PyYAML}
BuildRequires: %{python_module beautifulsoup4}
BuildRequires: %{python_module bleach}
BuildRequires: %{python_module h5py}
BuildRequires: %{python_module jplephem}
BuildRequires: %{python_module matplotlib}
BuildRequires: %{python_module pandas}
BuildRequires: %{python_module scipy}
# Test requirements
BuildRequires: %{python_module mpmath}
BuildRequires: %{python_module pytest}
%endif
Requires: hdf5
Requires: liberfa1 >= 1.3.0
Requires: python-numpy >= 1.7.0
Recommends: python-Jinja2
Recommends: python-PyYAML
Recommends: python-bleach
Recommends: python-beautifulsoup4
Recommends: python-h5py
Recommends: python-pandas
Recommends: python-scipy
Recommends: python-jplephem
Recommends: python-matplotlib
Recommends: libxml2-tools
Recommends: python-scikit-image
Requires(post): update-alternatives
Requires(preun): update-alternatives
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%python_subpackages
%description
Astropy is a package intended to contain core functionality and some
common tools needed for performing astronomy and astrophysics research with
Python. It also provides an index for other astronomy packages and tools for
managing them.
%prep
%setup -q -n astropy-%{version}
# Make sure bundled libs are not used
rm -rf cextern/expat
rm -rf cextern/erfa
rm -rf cextern/cfitsio
rm -rf cextern/wcslib
echo "[build]" >> setup.cfg
echo "use_system_libraries=1" >> setup.cfg
%build
%python_build --use-system-libraries --offline
%install
%python_install --use-system-libraries --offline
%python_expand %fdupes %{buildroot}%{$python_sitearch}
%python_clone -a %{buildroot}%{_bindir}/fitscheck
%python_clone -a %{buildroot}%{_bindir}/fitsdiff
%python_clone -a %{buildroot}%{_bindir}/fitsheader
%python_clone -a %{buildroot}%{_bindir}/fitsinfo
%python_clone -a %{buildroot}%{_bindir}/fits2bitmap
%python_clone -a %{buildroot}%{_bindir}/samp_hub
%python_clone -a %{buildroot}%{_bindir}/volint
%python_clone -a %{buildroot}%{_bindir}/wcslint
%check
export PYTHONDONTWRITEBYTECODE=1
pushd static
%{python_expand export PYTHONPATH="%{buildroot}%{$python_sitearch}"
$python -c "import astropy;astropy.test()"
rm -rf %{buildroot}%{$python_sitearch}/astropy/wcs/tests/extension/build
}
popd
%post
%{python_install_alternative fitscheck fitsdiff fitsheader fitsinfo fits2bitmap samp_hub volint wcslint}
%preun
%python_uninstall_alternative fitscheck
%files %{python_files}
%defattr(-,root,root,-)
%doc CHANGES.rst README.rst
%doc licenses/
%python_alternative %{_bindir}/fitscheck
%python_alternative %{_bindir}/fitsdiff
%python_alternative %{_bindir}/fitsheader
%python_alternative %{_bindir}/fitsinfo
%python_alternative %{_bindir}/fits2bitmap
%python_alternative %{_bindir}/samp_hub
%python_alternative %{_bindir}/volint
%python_alternative %{_bindir}/wcslint
%{python_sitearch}/astropy/
%{python_sitearch}/astropy-%{version}-py*.egg-info
%changelog