1
0
mysql-connector-java/mysql-connector-java.spec
Michal Vyskocil dba89fbc38 - update to 5.1.25 (see CHANGES for full list)
* support for Connection Attributes when used with MySQL Server versions (5.6+).
  5.1.24
  * support of password expiration protocol. This introduces new boolean
    connection property disconnectOnExpiredPasswords.
  5.1.23
  * added support of password expiration protocol.
  * driver now allows the mechanism for caching MySQL server configuration
    values replaceable at runtime.
  * Connection.setReadOnly() will take advantage of server-side support for
    read-only transactions present in MySQL-5.6 and newer. Calling .isReadOnly()
    will incur a round-trip if useLocalSessionState.
  5.1.22
  * support of ON UPDATE CURRENT_TIMESTAMP for TIMESTAMP and DATETIME fields.
  5.1.21
  * new built-in authentication plugin
    com.mysql.jdbc.authentication.Sha256PasswordPlugin ("sha256_password").
  * Added new built-in authentication plugin
    com.mysql.jdbc.authentication.MysqlClearPasswordPlugin ("mysql_clear_password").
    It allows C/J based clients to connect to MySQL accounts.
  * the ability to add new client-side prepared statement parse info caches
  * implemented several JDBC-4.1 methods from Java-7:
  5.1.19:
  * Added support for pluggable authentication via the com.mysql.jdbc.AuthenticationPlugin
- rebase and rename mysql-connector-java-5.1.19-java7.patch to
  * mysql-connector-java-7-jdbc-4.1.patch

OBS-URL: https://build.opensuse.org/package/show/Java:packages/mysql-connector-java?expand=0&rev=15
2013-09-19 14:22:42 +00:00

134 lines
4.3 KiB
RPMSpec

#
# spec file for package mysql-connector-java
#
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# icecream 0
Name: mysql-connector-java
Version: 5.1.25
Release: 0
Summary: Official JDBC Driver for MySQL
License: GPL-2.0+
Group: Development/Libraries/Java
Url: http://www.mysql.com/downloads/api-jdbc-stable.html
# url-for-download: http://dev.mysql.com/get/Downloads/Connector-J/%{name}-%{version}.zip/from/pick#mirrors
# docs are now under very strict proprietary license by Oracle, so lets not distribute them
# remove bundled jars as well
# tar -xf %{name}-%{version}.tar.gz
# rm -rf %{name}-%{version}/docs
# find %{name}-%{version} -name '*jar' -delete
# tar -xJf %{name}-%{version}-suse.tar.xz
Source0: %{name}-%{version}-suse.tar.xz
# Patch to build Java 7/jdbc 4.1
Patch0: mysql-connector-java-7-jdbc-4.1.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildArch: noarch
BuildRequires: ant
BuildRequires: ant-contrib
BuildRequires: apache-commons-logging
#BuildRequires: java-1_5_0-gcj-compat-devel
BuildRequires: java-devel >= 1.6.0
#BuildRequires: jta >= 1.0
BuildRequires: geronimo-jta-1_1-api
BuildRequires: javapackages-tools
BuildRequires: junit
BuildRequires: slf4j
#!BuildIgnore: maven2-bootstrap
BuildRequires: log4j-mini
Requires: jta >= 1.0
Requires: log4j
Requires: slf4j
Provides: mm.mysql = %{version}
Obsoletes: mm.mysql < %{version}
# manual is no longer distributed
Provides: %{name}-manual = %{version}
Obsoletes: %{name}-manual < %{version}
%description
MySQL Connector/J is a native Java driver that converts JDBC (Java
Database Connectivity) calls into the network protocol used by the
MySQL database. It lets developers working with the Java programming
language easily build programs and applets that interact with MySQL and
connect all corporate data, even in a heterogeneous environment. MySQL
Connector/J is a Type IV JDBC driver and has a complete JDBC feature
set that supports the capabilities of MySQL.
%prep
%setup -q -n %{name}-%{version}
%patch0 -p1
# dup
rm -f README
# wrong end of line encoding
sed -i -e 's/.$//' README.txt
%build
# disable jboss integration
rm -rf src/com/mysql/jdbc/integration/jboss
rm src/testsuite/regression/ConnectionRegressionTest.java
rm src/testsuite/regression/DataSourceRegressionTest.java
rm src/testsuite/simple/ReadOnlyCallableStatementTest.java
rm src/testsuite/simple/jdbc4/StatementsTest.java
export CLASSPATH=$(build-classpath \
ant-contrib \
commons-logging \
slf4j \
jdbc-stdext\
jta \
junit \
log4j)
# we need jdk5 for jdbc3.0
# XXX: JAVA_HOME must be setup **after** CLASSPATH
#export JAVA_HOME=%{_libdir}/jvm/java-1.5.0-gcj
ant -DbuildDir=build-mysql-jdbc \
-DdistDir=dist-mysql-jdbc \
-Dcom.mysql.jdbc.java6.javac="%{javac}" \
-Dcom.mysql.jdbc.java6.java="%{java}" \
-Dcom.mysql.jdbc.java6.rtjar"=%{java_home}/jre/lib/rt.jar"
%install
install -d -m 755 %{buildroot}%{_javadir}
install ./build-mysql-jdbc/%{name}-%{version}-SNAPSHOT/%{name}-%{version}-SNAPSHOT-bin.jar \
%{buildroot}%{_javadir}/%{name}.jar
rm -rf %{buildroot}%{name}-%{version}/docs/release-test-output
# Install the Maven build information
install -d -m 755 %{buildroot}%{_mavenpomdir}
install -pm 644 src/doc/sources/pom.xml %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom
sed -i 's/>@.*</>%{version}</' %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom
%add_maven_depmap JPP-%{name}.pom %{name}.jar
%files
%defattr(0644,root,root,0755)
%doc CHANGES COPYING README.txt
%attr(0644,root,root) %{_javadir}/%{name}.jar
%config(noreplace) %{_mavendepmapfragdir}/*
%{_mavenpomdir}/*.pom
%changelog