Sophie

Sophie

distrib > Mageia > 7 > i586 > media > core-release-src > by-pkgid > b05ce89a38f6e3d0ce85ba214bb5b5b6 > files > 3

h2-1.4.196-2.mga7.src.rpm

Name:           h2
Version:        1.4.196
Release:        %mkrel 2
Group:          Development/Java
Summary:        Java SQL database

# Most classes are dual licensed as EPL/MPL
# One class is triple licensed EPL/MPL/LGPL: src/main/org/h2/jdbcx/JdbcConnectionPool.java
# Some tests are ASL licensed
License:        (EPL or MPLv2.0 or LGPLv3+) and ASL 2.0
URL:            http://www.h2database.com
Source0:        http://www.h2database.com/h2-2017-06-10.zip
Source1:        http://repo2.maven.org/maven2/com/h2database/h2/%{version}/h2-%{version}.pom

Patch0:         port-to-lucene-6.patch

BuildArch: noarch

BuildRequires:  javapackages-local
BuildRequires:  lucene >= 6.1.0
BuildRequires:  lucene-analysis >= 6.1.0
BuildRequires:  lucene-queryparser >= 6.1.0
BuildRequires:  slf4j
BuildRequires:  felix-osgi-core
BuildRequires:  glassfish-servlet-api
BuildRequires:  jts

%description
H2 is a the Java SQL database. The main features of H2 are: Very fast, open
source, JDBC API; Embedded and server modes; In-memory databases; Browser
based Console application; Small footprint: around 1 MB jar file size.

%package javadoc
Summary:        Javadoc for %{name}

%description javadoc
This package contains the API documentation for %{name}.

%prep
%setup -q -n %{name}
%patch0 -p2

# Because no Fedora package provides org.osgi.service.jdbc interfaces yet
rm src/main/org/h2/util/OsgiDataSourceFactory.java
sed -i -e '/OsgiDataSourceFactory/d' src/main/org/h2/util/DbDriverActivator.java
sed -i -e '/org.osgi.service.jdbc/d' src/main/META-INF/MANIFEST.MF

# Delete pre-built binaries
find -name '*.class' -delete
find -name '*.jar' -delete
find -name '*.exe' -delete
find -name '*.dll' -delete

%if 0%{?mageia} >= 7
# Fix jts package name
sed -i -e 's/com\.vividsolutions\.jts/org.locationtech.jts/' $(find -name *.java)
sed -i -e 's/vividsolutions/vividsolutions locationtech/' src/tools/org/h2/build/doc/dictionary.txt
%endif

# Don't attempt to download from Internet
sed -i -e '/downloadTest();/d' -e '/download();/d' \
  src/tools/org/h2/build/Build.java

# Tests that use the network
sed -i -e '/TestNetUtils/d' \
  src/test/org/h2/test/TestAll.java

# Use system libraries instead
mkdir ext
ln -s -T $(build-classpath jts) ext/jts-core-1.14.0.jar
ln -s -T $(build-classpath glassfish-servlet-api) ext/servlet-api-3.1.0.jar
ln -s -T $(build-classpath slf4j/api) ext/slf4j-api-1.6.0.jar
ln -s -T $(build-classpath slf4j/nop) ext/slf4j-nop-1.6.0.jar
ln -s -T $(build-classpath lucene/lucene-core) ext/lucene-core-6.1.0.jar
ln -s -T $(build-classpath lucene/lucene-analyzers-common) ext/lucene-analyzers-common-6.1.0.jar
ln -s -T $(build-classpath lucene/lucene-queryparser) ext/lucene-queryparser-6.1.0.jar
ln -s -T $(build-classpath felix/org.osgi.core) ext/org.osgi.core-4.2.0.jar

echo "classic queryparser" >> src/tools/org/h2/build/doc/dictionary.txt

%build
export JAVA_HOME=%{_jvmdir}/java
sh build.sh jar docs

%install
%mvn_artifact %SOURCE1 bin/h2-%{version}.jar
%mvn_install -J docs/javadoc

%files -f .mfiles
%doc docs/index.html
%doc docs/html
%license src/docsrc/html/license.html

%files javadoc -f .mfiles-javadoc
%license src/docsrc/html/license.html




%changelog
* Tue Sep 25 2018 daviddavid <daviddavid> 1.4.196-2.mga7
  (not released yet)
+ Revision: 1305142
- Fix build against newer lucenes (sync with fc29)
+ umeabot <umeabot>
- Mageia 7 Mass Rebuild

* Wed Oct 11 2017 daviddavid <daviddavid> 1.4.196-1.mga7
+ Revision: 1170886
- Update to latest upstream revision (sync with fc27)
- Drop upstreamed patch
- Port to lucene 6
- Enable fast test suite
- Install with xmvn

* Wed Mar 02 2016 neoclust <neoclust> 1.3.176-7.mga6
+ Revision: 982096
- Second rebuild of the java stack

* Tue Feb 23 2016 neoclust <neoclust> 1.3.176-6.mga6
+ Revision: 976391
- First rebuild of the java stack
- sync package h2 with fedora

* Tue Feb 09 2016 umeabot <umeabot> 1.3.176-3.mga6
+ Revision: 951476
- Mageia 6 Mass Rebuild

* Tue Dec 30 2014 pterjan <pterjan> 1.3.176-2.mga5
+ Revision: 807393
- Sync with Fedora 21
+ daviddavid <daviddavid>
- sync with fc21 (update to 1.3.176)
- switch to %%mvn_artifact and javapackages-local
+ umeabot <umeabot>
- Second Mageia 5 Mass Rebuild
- Mageia 5 Mass Rebuild

* Fri Oct 18 2013 umeabot <umeabot> 1.3.168-2.mga4
+ Revision: 522280
- Mageia 4 Mass Rebuild

* Mon Feb 18 2013 dmorgan <dmorgan> 1.3.168-1.mga3
+ Revision: 398954
- New version

* Sat Jan 12 2013 umeabot <umeabot> 1.3.155-3.mga3
+ Revision: 353069
- Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild

* Sun Nov 27 2011 dmorgan <dmorgan> 1.3.155-2.mga2
+ Revision: 172471
- Rename pom file

* Mon Sep 05 2011 dmorgan <dmorgan> 1.3.155-1.mga2
+ Revision: 138661
- Fix groups
- Adapt to mageia guidelines
- Clean spec file
+ gil <gil>
- imported package h2


* Fri Jun 10 2011 gil <gil> 1.2.147-0.%%mkrel
- initial rpm