X-Git-Url: http://git.pld-linux.org/?a=blobdiff_plain;f=OpenIPMI.spec;h=84ab2c934da93e1676cc06b75b8b647ebcda814c;hb=e72862cba55f1ed8d7f214cdcc966ebdcb210e92;hp=36dc2f9c0a3b577af30e1893fa4eca325ecd2deb;hpb=698af8e68c2af49fa7811c05b979d8b40c1214b7;p=packages%2FOpenIPMI.git diff --git a/OpenIPMI.spec b/OpenIPMI.spec index 36dc2f9..84ab2c9 100644 --- a/OpenIPMI.spec +++ b/OpenIPMI.spec @@ -1,16 +1,18 @@ -# - check python package -# what about /usr/share/python2.4/site-packages/OpenIPMI.py ? - +# +# Conditional build: +%bcond_without gui # don't build tkinter-based GUI +# Summary: IPMI abstraction layer Summary(pl): Warstwa abstrakcji IPMI Name: OpenIPMI -Version: 2.0.1 -Release: 0.99 +Version: 2.0.8 +Release: 1 License: LGPL (library), GPL (ipmicmd) Group: Libraries Source0: http://dl.sourceforge.net/openipmi/%{name}-%{version}.tar.gz -# Source0-md5: b5474114ff84a872c5075744201bc4f0 +# Source0-md5: 3bfc9c232ef0d4ccc3c4355e17ba79d5 Patch0: %{name}-link.patch +Patch1: %{name}-python.patch URL: http://openipmi.sourceforge.net/ BuildRequires: autoconf BuildRequires: automake @@ -23,7 +25,12 @@ BuildRequires: net-snmp-devel BuildRequires: perl-devel BuildRequires: pkgconfig BuildRequires: popt-devel -BuildRequires: swig +BuildRequires: python-devel +%{?with_gui:BuildRequires: python-tkinter} +BuildRequires: tcl-devel +BuildRequires: rpm-pythonprov +BuildRequires: swig-perl >= 1.3.25 +BuildRequires: swig-python >= 1.3.25 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) %description @@ -74,10 +81,11 @@ Perl interface to OpenIPMI. Perlowy interfejs do OpenIPMI. %package -n python-%{name} -Summary: Python interface to OpenIPMI -Summary(pl): Pythonowy interfejs do OpenIPMI -Group: Development/Languages/Python -Requires: %{name} = %{version}-%{release} +Summary: Python interface to OpenIPMI +Summary(pl): Pythonowy interfejs do OpenIPMI +Group: Development/Languages/Python +Requires: %{name} = %{version}-%{release} +%pyrequires_eq python-libs %description -n python-%{name} Python interface to OpenIPMI. @@ -85,9 +93,23 @@ Python interface to OpenIPMI. %description -n perl-%{name} -l pl Pythonowy interfejs do OpenIPMI. +%package gui +Summary: OpenIPMI GUI +Summary(pl): Graficzny interfejs u¿ytkownika do OpenIPMI +Group: X11/Applications +Requires: python-%{name} = %{version}-%{release} +Requires: python-tkinter + +%description gui +OpenIPMI GUI. + +%description gui -l pl +Graficzny interfejs u¿ytkownika do OpenIPMI. + %prep %setup -q %patch0 -p1 +%patch1 -p1 %build %{__libtoolize} @@ -95,14 +117,21 @@ Pythonowy interfejs do OpenIPMI. %{__autoconf} %{__automake} CPPFLAGS="-I/usr/include/ncurses" -%configure -%{__make} +%configure \ + --without-glib12 \ + %{!?with_gui:--without-tkinter} +%{__make} \ + PYTHON_INSTALL_DIR=%{py_sitedir} %install rm -rf $RPM_BUILD_ROOT -%{__make} install \ - DESTDIR=$RPM_BUILD_ROOT +%{__make} install -j1 \ + DESTDIR=$RPM_BUILD_ROOT \ + PYTHON_INSTALL_DIR=%{py_sitedir} + +rm -f $RPM_BUILD_ROOT%{py_sitedir}/*.{py,la,a} \ + $RPM_BUILD_ROOT%{py_sitedir}/openipmigui/*.py %clean rm -rf $RPM_BUILD_ROOT @@ -113,7 +142,11 @@ rm -rf $RPM_BUILD_ROOT %files %defattr(644,root,root,755) %doc ChangeLog FAQ README* TODO -%attr(755,root,root) %{_bindir}/* +%attr(755,root,root) %{_bindir}/ipmi* +%attr(755,root,root) %{_bindir}/openipmicmd +%attr(755,root,root) %{_bindir}/openipmish +%attr(755,root,root) %{_bindir}/rmcp_ping +%attr(755,root,root) %{_bindir}/solterm %attr(755,root,root) %{_libdir}/lib*.so.*.*.* %{_mandir}/man[178]/* @@ -135,5 +168,15 @@ rm -rf $RPM_BUILD_ROOT %attr(755,root,root) %{perl_vendorarch}/auto/OpenIPMI/OpenIPMI.so %files -n python-%{name} -%attr(755,root,root) %{py_sitescriptdir}/*.so -%{py_sitescriptdir}/*.py[oc] +%defattr(644,root,root,755) +%attr(755,root,root) %{py_sitedir}/_OpenIPMI.so +%{py_sitedir}/OpenIPMI.py[co] + +%if %{with gui} +%files gui +%defattr(644,root,root,755) +%doc swig/python/openipmigui/TODO +%attr(755,root,root) %{_bindir}/openipmigui +%dir %{py_sitedir}/openipmigui +%{py_sitedir}/openipmigui/*.py[co] +%endif