2008-01-29 01:36:02 +01:00
|
|
|
#
|
2011-06-30 13:08:33 +02:00
|
|
|
# spec file for package python-magic
|
2008-01-29 01:36:02 +01:00
|
|
|
#
|
2016-01-21 12:51:33 +01:00
|
|
|
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
|
2008-01-29 01:36:02 +01:00
|
|
|
#
|
2008-08-21 18:07:05 +02:00
|
|
|
# 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.
|
|
|
|
|
2008-01-29 01:36:02 +01:00
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2011-10-02 16:37:56 +02:00
|
|
|
|
2016-02-18 12:51:37 +01:00
|
|
|
%{expand:%(sed -n -e '/^%%define somajor/,/^%%define libname/p' <%_sourcedir/file.spec)}
|
|
|
|
|
|
|
|
%define python python
|
|
|
|
|
2008-01-29 01:36:02 +01:00
|
|
|
Name: python-magic
|
|
|
|
%define build_python_bindings 1
|
2012-03-23 15:41:17 +01:00
|
|
|
BuildRequires: findutils
|
2011-10-02 16:37:56 +02:00
|
|
|
BuildRequires: libtool
|
2008-01-29 01:36:02 +01:00
|
|
|
BuildRequires: python-devel
|
2012-03-23 15:41:17 +01:00
|
|
|
BuildRequires: zlib-devel
|
2008-01-29 01:36:02 +01:00
|
|
|
Url: http://www.darwinsys.com/file/
|
2015-10-05 10:17:24 +02:00
|
|
|
Version: 5.25
|
2012-03-23 15:41:17 +01:00
|
|
|
Release: 0
|
2008-01-29 01:36:02 +01:00
|
|
|
Summary: Python module to use libmagic
|
2012-03-23 15:41:56 +01:00
|
|
|
License: BSD-3-Clause and BSD-4-Clause
|
2012-03-23 15:41:17 +01:00
|
|
|
Group: Development/Languages/Python
|
2008-01-29 01:36:02 +01:00
|
|
|
Source99: file.spec
|
|
|
|
%{expand:%(sed -n -e '/^Source:/,/^BuildRoot:/p' <%_sourcedir/file.spec)}
|
2016-02-18 12:51:37 +01:00
|
|
|
Requires: %libname
|
2008-01-29 01:36:02 +01:00
|
|
|
%global _sysconfdir /etc
|
|
|
|
%global _miscdir %{_datadir}/misc
|
|
|
|
|
|
|
|
%description
|
|
|
|
This package contains the python binding that require the magic "file"
|
|
|
|
interface.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%{expand:%(sed -n -e '/^%%prep/,/^%%install/p' <%_sourcedir/file.spec | sed -e '1d' -e '$d')}
|
|
|
|
|
|
|
|
%install
|
|
|
|
pushd python
|
2016-02-18 12:51:37 +01:00
|
|
|
%python setup.py install --root=%{buildroot} \
|
|
|
|
--prefix=%{_prefix} \
|
|
|
|
--record-rpm=../python_files
|
2008-01-29 01:36:02 +01:00
|
|
|
popd
|
|
|
|
|
|
|
|
%files -f python_files
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%doc python/README python/example.py
|
|
|
|
|
|
|
|
%changelog
|