From 100c4786a407290a62eb92a4f0dcce5fedd4a5ec06e2a981e94f8a895bdda6cd Mon Sep 17 00:00:00 2001 From: Sascha Peilicke Date: Thu, 1 Sep 2011 06:55:38 +0000 Subject: [PATCH] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pysnmp?expand=0&rev=12 --- pysnmp-4.1.14a.tar.bz2 | 3 -- pysnmp-4.1.16c.tar.gz | 3 ++ python-pysnmp.spec | 80 ++++++++++++++++++++++++++---------------- 3 files changed, 52 insertions(+), 34 deletions(-) delete mode 100644 pysnmp-4.1.14a.tar.bz2 create mode 100644 pysnmp-4.1.16c.tar.gz diff --git a/pysnmp-4.1.14a.tar.bz2 b/pysnmp-4.1.14a.tar.bz2 deleted file mode 100644 index fd988d3..0000000 --- a/pysnmp-4.1.14a.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:39367f4aa7266c80f0d7d424e89f0a27b665bc1730f2cbb6fc5a0870b6a8ddef -size 140578 diff --git a/pysnmp-4.1.16c.tar.gz b/pysnmp-4.1.16c.tar.gz new file mode 100644 index 0000000..e6ff914 --- /dev/null +++ b/pysnmp-4.1.16c.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2b16665388313201bf64e329f96f39424ddf2704a001443a037aff4d004ae55b +size 186533 diff --git a/python-pysnmp.spec b/python-pysnmp.spec index 752aa53..ce120d7 100644 --- a/python-pysnmp.spec +++ b/python-pysnmp.spec @@ -1,33 +1,57 @@ -%define modname pysnmp -Name: python-%{modname} -URL: http://pysnmp.sourceforge.net/ -Summary: SNMP framework for Python -Version: 4.1.14 -%define prever a -Release: 1 -License: Other License(s), see package -Group: Development/Libraries/Python -Source: %{modname}-%{version}%{prever}.tar.bz2 -BuildRoot: %{_tmppath}/%{name}-%{version}-root -%{py_requires} -Requires: python-crypto python-asn1 -BuildRequires: python-devel +# +# spec file for package python-pysnmp +# +# Copyright (c) 2011 SUSE LINUX Products 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/ +# -%if 0%{?suse_version} != 1110 +Name: python-pysnmp +Version: 4.1.16c +Release: 0 +Url: http://pysnmp.sourceforge.net/ +Summary: A pure-Python SNMPv1/v2c/v3 library +License: Other License(s), see package +Group: Development/Languages/Python +Source: http://pypi.python.org/packages/source/p/pysnmp/pysnmp-%{version}.tar.gz +BuildRoot: %{_tmppath}/%{name}-%{version}-build +BuildRequires: python-devel +BuildRequires: python-pycrypto +BuildRequires: python-pyasn1 +Requires: python-pycrypto +Requires: python-pyasn1 +%if 0%{?suse_version} +%py_requires +%if 0%{?suse_version} > 1110 BuildArch: noarch %endif +%endif +%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %description This project aims at developing an SNMP v1/v2c/v3 engine written in the Python -programming language. +programming language: -Authors: --------- - Ilya Etingof + * Complete SNMPv1/v2c and SNMPv3 engine support + * Can act Manager and/or Agent role + * Manager and Agent side MIB support + * Asynchronous operations support + * Pure-Python implementation + * py2exe and .egg friendly + * Twisted binding %package utils Group: Development/Tools/Other -Requires: python-pysnmp >= %version +Requires: python-pysnmp Summary: Python-pysnmp libsmi utilities # Needed for build-pysnmp-mib Requires: libsmi > 0.4.5 @@ -35,31 +59,25 @@ Requires: libsmi > 0.4.5 %description utils Utitilites used for the creation of python mib description files. -Authors: --------- - Ilya Etingof - %prep -%setup -q -n %{modname}-%{version}%{prever} +%setup -q -n pysnmp-%{version} %build -export CFLAGS="$RPM_OPT_FLAGS" python setup.py build %install -rm -rf %{buildroot} -python setup.py install --prefix=%{_prefix} --root=%{buildroot} --record-rpm=INSTALLED_FILES.full +python setup.py install --prefix=%{_prefix} --root=%{buildroot} install -m 0755 -d %{buildroot}%{_bindir} install -m 0755 tools/libsmi2pysnmp %{buildroot}%{_bindir}/libsmi2pysnmp install -m 0755 tools/build-pysnmp-mib %{buildroot}%{_bindir}/build-pysnmp-mib -grep -v "/usr/bin" INSTALLED_FILES.full > INSTALLED_FILES %clean rm -rf %{buildroot} -%files -f INSTALLED_FILES -%defattr(-,root,root) +%files +%defattr(-,root,root,-) %doc CHANGES LICENSE README THANKS TODO docs examples +%{python_sitelib}/* %files utils %defattr(-,root,root)