103 lines
3.0 KiB
RPMSpec
103 lines
3.0 KiB
RPMSpec
%define rel 7
|
|
%define rel_version %{rel}r2
|
|
|
|
Name: java-rxtx
|
|
Version: 2.1
|
|
Release: 4mamba
|
|
Summary: Provides access to serial ports
|
|
Group: System/Libraries/Java
|
|
Vendor: openmamba
|
|
Distribution: openmamba
|
|
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
|
|
URL: http://rxtx.qbang.org/wiki/index.php/Main_Page
|
|
# cvs -d:pserver:anonymous@qbang.org:/var/cvs/cvsroot co -r commapi-0-0-1 -D "2010-02-11" -d rxtx-20100211 rxtx-devel
|
|
# tar cjvf rxtx-20100211.tar.bz2 --exclude CVS --exclude .cvsignore rxtx-20100211
|
|
Source: http://rxtx.qbang.org/pub/rxtx/rxtx-%{version}-%{rel_version}.zip
|
|
Patch0: java-rxtx-2.1-loadlibrary.patch
|
|
Patch1: java-rxtx-2.1-no_utsrelease.patch
|
|
License: LGPL
|
|
## AUTOBUILDREQ-BEGIN
|
|
BuildRequires: glibc-devel
|
|
## AUTOBUILDREQ-END
|
|
BuildRequires: jpackage-utils
|
|
BuildRequires: kernelheaders
|
|
BuildRequires: make
|
|
Requires: jpackage-utils
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
|
|
|
%description
|
|
RXTX is an full implementation of java commapi which aims to support RS232 IEEE 1284, RS485, I2C and RawIO.
|
|
|
|
%prep
|
|
%setup -q -n rxtx-%{version}-%{rel_version}
|
|
|
|
for j in $(find . -name "*.jar"); do
|
|
rm -rf $j
|
|
done
|
|
|
|
for j in $(find . -name "*.hqx"); do
|
|
rm -rf $j
|
|
done
|
|
|
|
sed -e 's|@JNIPATH@|%{_libdir}/rxtx|' %{PATCH0} | patch -p0
|
|
|
|
%patch1 -p1
|
|
|
|
for j in $(find . -name "CVS"); do
|
|
rm -rf $j
|
|
done
|
|
|
|
iconv -f ISO_8859-1 -t UTF-8 ChangeLog >ChangeLog.utf-8
|
|
mv ChangeLog.utf-8 ChangeLog
|
|
|
|
sed -i 's,\(1\.5\*\),\1|1.6*,' configure
|
|
|
|
%build
|
|
export JAVA_HOME=%{_jvmdir}/jdk
|
|
%configure
|
|
make
|
|
|
|
%install
|
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
|
mkdir -p %{buildroot}{%{_javadir},%{_libdir}/rxtx}
|
|
|
|
make RXTX_PATH=%{buildroot}%{_libdir}/rxtx JHOME=%{buildroot}%{_javadir} install
|
|
|
|
# remove useless files
|
|
find %{buildroot} -name '*.la' -exec rm {} \;
|
|
|
|
%clean
|
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
|
|
|
%files
|
|
%defattr(-,root,root)
|
|
%dir %{_libdir}/rxtx
|
|
%{_libdir}/rxtx/librxtxI2C-%{version}-%{rel}.so
|
|
%{_libdir}/rxtx/librxtxI2C.so
|
|
%{_libdir}/rxtx/librxtxParallel-%{version}-%{rel}.so
|
|
%{_libdir}/rxtx/librxtxParallel.so
|
|
%{_libdir}/rxtx/librxtxRS485-%{version}-%{rel}.so
|
|
%{_libdir}/rxtx/librxtxRS485.so
|
|
%{_libdir}/rxtx/librxtxRaw-%{version}-%{rel}.so
|
|
%{_libdir}/rxtx/librxtxRaw.so
|
|
%{_libdir}/rxtx/librxtxSerial-%{version}-%{rel}.so
|
|
%{_libdir}/rxtx/librxtxSerial.so
|
|
%{_javadir}/RXTXcomm.jar
|
|
%doc AUTHORS COPYING
|
|
#ChangeLog INSTALL install-japanese.html PORTING
|
|
#%doc README* RMISecurityManager.html SerialPortInstructions.txt TODO
|
|
|
|
%changelog
|
|
* Wed Feb 06 2013 Silvan Calarco <silvan.calarco@mambasoft.it> 2.1-4mamba
|
|
- added no_utsrelease patch to disable kernel version dependent code checks
|
|
|
|
* Sat Mar 24 2012 Silvan Calarco <silvan.calarco@mambasoft.it> 2.1-3mamba
|
|
- buildrequire kernelheaders instead of kernel-mamba-headers
|
|
|
|
* Wed Mar 21 2012 Stefano Cotta Ramusino <stefano.cotta@openmamba.org> 2.1-2mamba
|
|
- fixed build with jdk 1.6
|
|
- remove static package
|
|
|
|
* Tue Mar 09 2010 gil <puntogil@libero.it> 2.1-1mamba
|
|
- package created by autospec
|