1 %global __provides_exclude_from ^%{_libdir}/%{name}/.*\.so$
6 Summary: SQLite Java Wrapper/JDBC Driver
8 Group: Development/Libraries
10 URL: http://www.ch-werner.de/javasqlite/
11 Source0: http://www.ch-werner.de/javasqlite/%{name}-%{version}.tar.gz
12 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
14 # >= 3.4 for zeroblob stuff in %%check's test3
15 BuildRequires: sqlite-devel >= 3.4
16 BuildRequires: java-1.6.0-openjdk-devel
17 BuildRequires: java-1.6.0-openjdk-javadoc
18 Requires: java-1.6.0-openjdk
21 javasqlite is a Java wrapper including a basic JDBC driver for the
22 SQLite database engine. It is designed using JNI to interface to the
26 Summary: API documentation for %{name}
29 Requires: java-javadoc
32 API documentation for %{name}.
36 sed -e 's|@JNIPATH@|%{_libdir}/%{name}|' fc-jnipath.patch | patch -p1 --fuzz=0
37 sed -i -e 's/\r//g' doc/ajhowto.txt
38 f=ChangeLog ; iconv -f iso-8859-1 -t utf-8 $f > $f.utf8 ; mv $f.utf8 $f
42 # Note that --enable-load-extension has security concerns, see configure --help
44 --with-jardir=%{_libdir}/%{name}
45 --libdir=%{_libdir}/%{name}
48 export PATH="%{_jvmdir}/java-1.6.0/bin:$origpath" # bug 460761 (to be sure)
49 %configure $common_flags --with-jdk=%{_jvmdir}/java-1.6.0
50 make # Java build not parallel clean
51 make javadoc JAVADOCLINK=%{_javadocdir}/java
54 rm -rf $RPM_BUILD_ROOT
55 make install DESTDIR=$RPM_BUILD_ROOT
56 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/libsqlite_jni.la
57 install -dm 755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}
58 cp -pR doc/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}
61 rm -rf $RPM_BUILD_ROOT
65 for javaver in 1.6.0 ; do
66 jdir=%{_jvmdir}/java-$javaver/bin
67 export PATH="$jdir:$origpath" # bug 460761
68 # test2 is for SQLite 2.x, which we don't support
69 make JAVA_RUN="$jdir/java" JAVAC="$jdir/javac" test test3
73 %defattr(-,root,root,-)
74 %doc ChangeLog license.terms
75 %dir %{_libdir}/%{name}/
76 %{_libdir}/%{name}/sqlite.jar
77 %{_libdir}/%{name}/libsqlite_jni.so
80 %defattr(-,root,root,-)
82 %{_javadocdir}/%{name}
85 * Sun May 1 2011 Ville Skyttä <ville.skytta@iki.fi> - 20120209-1
86 - Use rpmbuild >= 4.9's built in Provides filtering.