|
@@ -6,7 +6,7 @@
|
|
|
|
|
|
Name: i2c-tools
|
|
Name: i2c-tools
|
|
Version: 3.0.2
|
|
Version: 3.0.2
|
|
-Release: 1%{?_dist_release}
|
|
+Release: 2%{?_dist_release}
|
|
Summary: A heterogeneous set of I2C tools for Linux
|
|
Summary: A heterogeneous set of I2C tools for Linux
|
|
Group: Applications/System
|
|
Group: Applications/System
|
|
License: GPLv2+
|
|
License: GPLv2+
|
|
@@ -35,6 +35,18 @@ eeproms in your system is very dangerous and is likely to render your system
|
|
unusable. Do not install, let alone use this, unless you really, _really_ know
|
|
unusable. Do not install, let alone use this, unless you really, _really_ know
|
|
what you are doing.
|
|
what you are doing.
|
|
|
|
|
|
|
|
+%package -n smbus-python
|
|
|
|
+Summary: Python module for SMBus access via I2C
|
|
|
|
+Group: Development/Languages
|
|
|
|
+BuildRequires: python-devel
|
|
|
|
+BuildRequires: python-setuptools
|
|
|
|
+Requires: python
|
|
|
|
+
|
|
|
|
+%description -n smbus-python
|
|
|
|
+This Python module allows SMBus access through the I2C /dev interface
|
|
|
|
+on Linux hosts. The host kernel must have I2C support, I2C device
|
|
|
|
+interface support, and a bus adapter driver.
|
|
|
|
+
|
|
|
|
|
|
%prep
|
|
%prep
|
|
%setup -q
|
|
%setup -q
|
|
@@ -46,12 +58,20 @@ pushd eepromer
|
|
make CFLAGS="$RPM_OPT_FLAGS -I../include"
|
|
make CFLAGS="$RPM_OPT_FLAGS -I../include"
|
|
popd
|
|
popd
|
|
|
|
|
|
|
|
+pushd py-smbus
|
|
|
|
+CFLAGS="%{optflags} -I../include" python setup.py build
|
|
|
|
+popd
|
|
|
|
|
|
%install
|
|
%install
|
|
rm -rf $RPM_BUILD_ROOT
|
|
rm -rf $RPM_BUILD_ROOT
|
|
make install DESTDIR=$RPM_BUILD_ROOT prefix=%{_prefix}
|
|
make install DESTDIR=$RPM_BUILD_ROOT prefix=%{_prefix}
|
|
install -m 755 eepromer/{eepromer,eeprom,eeprog} \
|
|
install -m 755 eepromer/{eepromer,eeprom,eeprog} \
|
|
$RPM_BUILD_ROOT%{_sbindir}
|
|
$RPM_BUILD_ROOT%{_sbindir}
|
|
|
|
+
|
|
|
|
+pushd py-smbus
|
|
|
|
+python setup.py install --root=%{buildroot} --compile --optimize=2
|
|
|
|
+popd
|
|
|
|
+
|
|
# cleanup
|
|
# cleanup
|
|
rm -f $RPM_BUILD_ROOT%{_bindir}/decode-edid.pl
|
|
rm -f $RPM_BUILD_ROOT%{_bindir}/decode-edid.pl
|
|
# Remove userland kernel headers, belong in glibc-kernheaders.
|
|
# Remove userland kernel headers, belong in glibc-kernheaders.
|
|
@@ -86,8 +106,16 @@ rm -rf $RPM_BUILD_ROOT
|
|
%doc eepromer/README*
|
|
%doc eepromer/README*
|
|
%{_sbindir}/eepro*
|
|
%{_sbindir}/eepro*
|
|
|
|
|
|
|
|
+%files -n smbus-python
|
|
|
|
+%defattr(0644,root,root,0755)
|
|
|
|
+%doc py-smbus/README
|
|
|
|
+%{python_sitearch}/smbus*
|
|
|
|
+
|
|
|
|
|
|
%changelog
|
|
%changelog
|
|
|
|
+* Sun Feb 06 2011 Munehiro Yamamoto <munepi@vinelinux.org> 3.0.2-2
|
|
|
|
+- added smbus-python package
|
|
|
|
+
|
|
* Tue Mar 16 2010 Daisuke SUZUKI <daisuke@linux.or.jp> 3.0.2-1
|
|
* Tue Mar 16 2010 Daisuke SUZUKI <daisuke@linux.or.jp> 3.0.2-1
|
|
- initial build for Vine Linux
|
|
- initial build for Vine Linux
|
|
|
|
|