Blame SPECS/mysql-connector-java.spec

6c8df2
%global     builddir        build-mysql-jdbc
6c8df2
%global     distdir         dist-mysql-jdbc
6c8df2
%global     java6_rtpath    %{java_home}/jre/lib/rt.jar
6c8df2
%global     java6_javacpath /usr/bin/javac
6c8df2
%global     java6_javapath  /usr/bin/javac
6c8df2
6c8df2
Summary:    Official JDBC driver for MySQL
6c8df2
Name:       mysql-connector-java
6c8df2
Version:    5.1.25
9347de
Release:    3%{?dist}
6c8df2
Epoch:      1 
6c8df2
6c8df2
# MySQL FLOSS Exception
6c8df2
License:    GPLv2 with exceptions
6c8df2
Group:      System Environment/Libraries
6c8df2
URL:        http://dev.mysql.com/downloads/connector/j/
6c8df2
6c8df2
# Mysql has a mirror redirector for its downloads
6c8df2
# You can get this tarball by following a link from:
6c8df2
# http://dev.mysql.com/get/Downloads/Connector-J/%{name}-%{version}.zip/from/pick#mirrors
6c8df2
#
6c8df2
# Following prebuilt jars and sources have been removed from the tarball:
6c8df2
#
6c8df2
# %{name}-%{version}-bin.jar
6c8df2
# src/lib/ant-contrib.jar
6c8df2
# src/lib/c3p0-0.9.1-pre6.jar
6c8df2
# src/lib/c3p0-0.9.1-pre6.src.zip
6c8df2
# src/lib/jboss-common-jdbc-wrapper.jar
6c8df2
# src/lib/jboss-common-jdbc-wrapper-src.jar
6c8df2
# src/lib/slf4j-api-1.6.1.jar
6c8df2
#
6c8df2
# See http://bugs.mysql.com/bug.php?id=28512 for details.
6c8df2
Source0:            %{name}-%{version}-nojars.tar.xz
6c8df2
6c8df2
# To make it easier a script generate-tarball.sh has been created:
6c8df2
# ./generate-tarball.sh version
6c8df2
# will create a new tarball compressed with xz and without those jar files.
6c8df2
Source1:           generate-tarball.sh 
6c8df2
6c8df2
# Patch to build with JDBC 4.1/Java 7
6c8df2
Patch0:             %{name}-jdbc-4.1.patch
6c8df2
6c8df2
BuildArch:          noarch
6c8df2
6c8df2
BuildRequires:      java-devel >= 1:1.6.0
6c8df2
BuildRequires:      ant >= 1.6.0
6c8df2
BuildRequires:      ant-contrib >= 1.0
6c8df2
BuildRequires:      jpackage-utils >= 1.6
6c8df2
BuildRequires:      jta >= 1.0
6c8df2
BuildRequires:      junit
6c8df2
BuildRequires:      slf4j
6c8df2
BuildRequires:      apache-commons-logging
6c8df2
6c8df2
Requires:           java >= 1:1.6.0
6c8df2
Requires:           jta >= 1.0
6c8df2
Requires:           slf4j
6c8df2
Requires:               jpackage-utils
6c8df2
6c8df2
%description
6c8df2
MySQL Connector/J is a native Java driver that converts JDBC (Java Database
6c8df2
Connectivity) calls into the network protocol used by the MySQL database.
6c8df2
It lets developers working with the Java programming language easily build
6c8df2
programs and applets that interact with MySQL and connect all corporate
6c8df2
data, even in a heterogeneous environment. MySQL Connector/J is a Type
6c8df2
IV JDBC driver and has a complete JDBC feature set that supports the
6c8df2
capabilities of MySQL.
6c8df2
6c8df2
%prep
6c8df2
%setup -q -n %{name}-%{version}
6c8df2
6c8df2
# Remove duplicate README.txt files
6c8df2
rm README README.txt
6c8df2
6c8df2
# fix line endings
6c8df2
sed -i 's/\r//' docs/README.txt
6c8df2
6c8df2
%patch0 -p1 -F3
6c8df2
6c8df2
%build
6c8df2
6c8df2
# We need both JDK1.5 (for JDBC3.0; appointed by $JAVA_HOME) and JDK1.6 (for JDBC4.0; appointed in the build.xml)
6c8df2
export CLASSPATH=$(build-classpath jdbc-stdext jta junit slf4j commons-logging.jar)
6c8df2
6c8df2
# We currently need to disable jboss integration because of missing jboss-common-jdbc-wrapper.jar (built from sources).
6c8df2
# See BZ#480154 and BZ#471915 for details.
6c8df2
rm -rf src/com/mysql/jdbc/integration/jboss
6c8df2
rm src/testsuite/regression/ConnectionRegressionTest.java
6c8df2
rm src/testsuite/regression/DataSourceRegressionTest.java
6c8df2
rm src/testsuite/simple/ReadOnlyCallableStatementTest.java
6c8df2
rm src/testsuite/simple/jdbc4/StatementsTest.java
6c8df2
6c8df2
ant -DbuildDir=%{builddir} -DdistDir=%{distdir} -Dcom.mysql.jdbc.java6.rtjar=%{java6_rtpath} -Dcom.mysql.jdbc.java6.javac=%{java6_javacpath} -Dcom.mysql.jdbc.java6.java=%{java6_javapath}
6c8df2
6c8df2
%install
6c8df2
install -d -m 755 $RPM_BUILD_ROOT%{_javadir}
6c8df2
install -m 644 %{builddir}/%{name}-%{version}-SNAPSHOT/%{name}-%{version}-SNAPSHOT-bin.jar \
6c8df2
    $RPM_BUILD_ROOT%{_javadir}/%{name}.jar
6c8df2
6c8df2
# Install the Maven build information
6c8df2
install -d -m 755 $RPM_BUILD_ROOT%{_mavenpomdir}
6c8df2
install -pm 644 src/doc/sources/pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{name}.pom
6c8df2
sed -i 's/>@.*%{version}</' $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{name}.pom
6c8df2
6c8df2
%add_maven_depmap
6c8df2
6c8df2
%files
6c8df2
%doc CHANGES COPYING docs
6c8df2
%{_javadir}/*.jar
6c8df2
%config(noreplace) %{_mavendepmapfragdir}/*
6c8df2
%{_mavenpomdir}/*.pom
6c8df2
6c8df2
%changelog
9347de
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 1:5.1.25-3
9347de
- Mass rebuild 2013-12-27
9347de
6c8df2
* Mon Nov  4 2013 Honza Horak <hhorak@redhat.com> - 1:5.1.25-2
6c8df2
- Remove versioned jars and some spec clean-up
6c8df2
  Resolves: #1023005
6c8df2
6c8df2
* Fri Jul 19 2013 Honza Horak <hhorak@redhat.com> - 1:5.1.25-1
6c8df2
- Update to 5.1.25
6c8df2
- Spec file clean-up, removing gcj support
6c8df2
6c8df2
* Mon Apr  8 2013 Honza Horak <hhorak@redhat.com> - 1:5.1.24-1
6c8df2
- Update to 5.1.24
6c8df2
6c8df2
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:5.1.22-2
6c8df2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
6c8df2
6c8df2
* Tue Sep 11 2012 Miloš Jakubíček <xjakub@fi.muni.cz> - 1:5.1.22-1
6c8df2
- Update to 5.1.22
6c8df2
6c8df2
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:5.1.21-3
6c8df2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
6c8df2
6c8df2
* Tue Jul 10 2012 Miloš Jakubíček <xjakub@fi.muni.cz> - 1:5.1.21-2
6c8df2
- More fuzz for mysql-connector-java-jdbc-4.1.patch
6c8df2
6c8df2
* Tue Jul 10 2012 Miloš Jakubíček <xjakub@fi.muni.cz> - 1:5.1.21-1
6c8df2
- Update to 5.1.21
6c8df2
6c8df2
* Sat May  5 2012 Tom Lane <tgl@redhat.com> 1:5.1.17-5
6c8df2
- Switch to noarch (non-GCJ) build
6c8df2
Resolves: #688937, #819139
6c8df2
- Fix mysql-connector-java-jdbc-4.1.patch to cover both driver classes
6c8df2
Related: #816696
6c8df2
6c8df2
* Wed Jan 25 2012 Deepak Bhole <dbhole@redhat.com> - 1:5.1.17-4
6c8df2
- Removed java-1.6.0-openjdk-devel requirement
6c8df2
6c8df2
* Wed Jan 25 2012 Deepak Bhole <dbhole@redhat.com> - 1:5.1.17-3
6c8df2
- Added patch to support build with JDBC 4.1/Java 7
6c8df2
6c8df2
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:5.1.17-2
6c8df2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
6c8df2
6c8df2
* Sat Aug 20 2011 Miloš Jakubíček <xjakub@fi.muni.cz> - 1:5.1.17-1
6c8df2
- Update to 5.1.17
6c8df2
6c8df2
* Thu Feb 10 2011 Miloš Jakubíček <xjakub@fi.muni.cz> - 1:5.1.15-1
6c8df2
- Update to 5.1.15, fix BZ#676464, changed BR: log4j to BR: slf4j
6c8df2
6c8df2
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:5.1.14-2
6c8df2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
6c8df2
6c8df2
* Tue Jan 18 2011 Milos Jakubicek <xjakub@fi.muni.cz> - 1:5.1.14-1
6c8df2
- Update to 5.1.14
6c8df2
6c8df2
* Fri Feb 19 2010 Milos Jakubicek <xjakub@fi.muni.cz> - 1:5.1.12-1
6c8df2
- Update to 5.1.12
6c8df2
6c8df2
* Fri Jan 29 2010 Milos Jakubicek <xjakub@fi.muni.cz> 1:5.1.11-1
6c8df2
- Update to 5.1.11
6c8df2
6c8df2
* Thu Jan 21 2010 Tom Lane <tgl@redhat.com> 1:5.1.8-3
6c8df2
- Clean up rpmlint complaints (/usr/lib/ references, old provides/obsoletes,
6c8df2
  tab usage)
6c8df2
6c8df2
* Fri Dec  4 2009 Mary Ellen Foster <mefoster at gmail.com> - 1:5.1.8-2
6c8df2
- Add Maven POM and depmap fragment
6c8df2
6c8df2
* Wed Aug 26 2009 Milos Jakubicek <xjakub@fi.muni.cz> - 1:5.1.8-1
6c8df2
- Update to 5.1.8 (resolves BZ#480154) with jboss integration disabled.
6c8df2
- Added BR: java-1.6.0-openjdk-devel, java-1.5.0-gcj-devel, jakarta-commons-logging
6c8df2
- Minor spec file updates: %%global instead of %%define, tabs instead of spaces
6c8df2
- Dropped unnecessary patch-build.xml and mysql-connector-java-noSunAppletSecurity.patch
6c8df2
6c8df2
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:3.1.12-8
6c8df2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
6c8df2
6c8df2
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:3.1.12-7
6c8df2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
6c8df2
6c8df2
* Mon Aug 11 2008 Tom "spot" Callaway <tcallawa@redhat.com> 1:3.1.12-6
6c8df2
- fix license tag
6c8df2
6c8df2
* Fri Apr 04 2008 Andrew Overholt <overholt@redhat.com> 1:3.1.12-5
6c8df2
- Rebuild for rhbz #234286.
6c8df2
6c8df2
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 1:3.1.12-4
6c8df2
- Autorebuild for GCC 4.3
6c8df2
6c8df2
* Thu Oct 05 2006 Christian Iseli <Christian.Iseli@licr.org> 1:3.1.12-3
6c8df2
 - rebuilt for unwind info generation, broken in gcc-4.1.1-21
6c8df2
6c8df2
* Thu Sep 21 2006 Igor Foox <ifoox@redhat.com> 1:3.1.12-2
6c8df2
- Remove jpp string from release.
6c8df2
6c8df2
* Fri Sep 08 2006 Igor Foox <ifoox@redhat.com> 1:3.1.12-1jpp_5fc
6c8df2
- Add dist tag.
6c8df2
6c8df2
* Thu Sep 07 2006 Igor Foox <ifoox@redhat.com> 1:3.1.12-1jpp_4fc
6c8df2
- Fix indentation of preamble.
6c8df2
- Fix version and epoch of jta Requires.
6c8df2
- Fix Group from Development/Libraries to System Environment/Libraries.
6c8df2
6c8df2
* Wed Sep 06 2006 Igor Foox <ifoox@redhat.com> 1:3.1.12-1jpp_3fc
6c8df2
- Remove duplicate readme files.
6c8df2
- Remove binary jars from distributed tarball, since they have no source
6c8df2
  attached to them, and are in violation of the LGPL.
6c8df2
- Change jta BR to 1.0 from 1.0.1 since geronimo-specs-compat is 1.0.
6c8df2
- Remove unneccessary 0 epoch from BRs.
6c8df2
6c8df2
* Thu Jul 20 2006 Igor Foox <ifoox@redhat.com> 1:3.1.12-1jpp_2fc
6c8df2
- Fix line endings.
6c8df2
- Change Group to standard Development/Java.
6c8df2
6c8df2
* Thu Jun 1 2006 Igor Foox <ifoox@redhat.com> 1:3.1.12-1jpp_1fc
6c8df2
- Natively compile
6c8df2
- Add mysql-connector-java-noSunAppletSecurity.patch to take out references
6c8df2
to sun classes
6c8df2
- Change BuildRoot to what Extras expects
6c8df2
6c8df2
* Thu Feb 2 2006 Jason Corley <jason.corley@gmail.com> 1:3.1.12-1jpp
6c8df2
- 3.1.12
6c8df2
- add some more docs from the tarball
6c8df2
- correct url
6c8df2
- remove vendor and distribution, should be defined in ~/.rpmmacros instead
6c8df2
6c8df2
* Sat May 14 2005 Jason Corley <jason.corley@gmail.com> 1:3.1.8-0.a.1jpp
6c8df2
- 3.1.8a
6c8df2
6c8df2
* Sun Feb 13 2005 Jason Corley <jason.corley@gmail.com> 1:3.1.6-1jpp
6c8df2
- Update to 3.1.6 now that it's considered stable
6c8df2
6c8df2
* Sat Feb 12 2005 Jason Corley <jason.corley@gmail.com> 1:3.0.16-1jpp
6c8df2
- Update to 3.0.16
6c8df2
6c8df2
* Mon Aug 23 2004 Fernando Nasser <fnasser@redhat.com> 1:3.0.14-1jpp
6c8df2
- Update to 3.0.14
6c8df2
- Rebuilt with Ant 1.6.2
6c8df2
6c8df2
* Wed Mar 24 2004 Kaj J. Niemi <kajtzu@fi.basen.net> 1:3.0.11-1jpp
6c8df2
- Bumped epoch, back to a "stable" release
6c8df2
6c8df2
* Fri Mar 19 2004 Kaj J. Niemi <kajtzu@fi.basen.net> 0:3.1.1-1jpp
6c8df2
- 3.1.1, supports stored procedures and SAVEPOINTs among other things.
6c8df2
- Tidy .spec file: nicer description and don't own %%{_javadir}
6c8df2
6c8df2
* Wed Jan 21 2004 David Walluck <david@anti-microsoft.org> 0:3.0.10-1jpp
6c8df2
- 3.0.10
6c8df2
- change group
6c8df2
6c8df2
* Sun Oct 05 2003 Henri Gomez <hgomez@users.sourceforge.net>  0:3.0.9-1jpp
6c8df2
- mysql-connector-j 3.0.9
6c8df2
6c8df2
* Mon Jul 07 2003 Henri Gomez <hgomez@users.sourceforge.net> 3.0.8.2jpp
6c8df2
- mysql-connector-j 3.0.8
6c8df2
- jar goes back in /usr/share/java
6c8df2
6c8df2
* Sun May 11 2003 David Walluck <david@anti-microsoft.org> 0:3.0.6-2jpp
6c8df2
- update for JPackage 1.5
6c8df2
6c8df2
* Tue Mar 25 2003 Nicolas Mailhot <Nicolas.Mailhot (at) JPackage.org> 3.0.6-1jpp
6c8df2
- For jpackage-utils 1.5
6c8df2
- New project name
6c8df2
- Requires java >= 1.4.1
6c8df2
6c8df2
* Thu Jun 06 2002 Henri Gomez <hgomez@users.sourceforge.net> 2.0.14.1jpp
6c8df2
- mm.mysql 2.0.14
6c8df2
6c8df2
* Tue May 07 2002 Henri Gomez <hgomez@users.sourceforge.net> 2.0.13.1jpp
6c8df2
- mm.mysql 2.0.13
6c8df2
6c8df2
* Tue Mar 26 2002 Henri Gomez <hgomez@users.sourceforge.net> 2.0.11.2jpp
6c8df2
- correct changelog
6c8df2
6c8df2
* Mon Feb 04 2002 Henri Gomez <hgomez@users.sourceforge.net>
6c8df2
- mm.mysql 2.0.11
6c8df2
6c8df2
* Thu Jan 17 2002 Henri Gomez <hgomez@users.sourceforge.net>
6c8df2
- mm.mysql 2.0.8
6c8df2
- seriously patch build.xml to make it compile on Linux boxes
6c8df2
  with both JDK 1.2/1.3 and 1.1
6c8df2
- added javadoc generation to build.xml
6c8df2
- changed manual to javadoc package
6c8df2
6c8df2
* Tue Feb 06 2001 Henri Gomez <hgomez@users.sourceforge.net>
6c8df2
- mm.mysql 2.0.4
6c8df2
- Fixes to getDecimal to fix decimal place wrong bug
6c8df2
6c8df2
* Mon Jan 15 2001 Henri Gomez <hgomez@users.sourceforge.net>
6c8df2
- Initial release mm.mysql 2.0.3
6c8df2
- detect jdbc-2.0 extension jar (javax.sql) and if present
6c8df2
  also build MysqlDataSource and MysqlDataSourceFactory
6c8df2
- build with IBM JDK 1.3.0 (cx130-20001114) and jikes 1.12
6c8df2
- build CLASSPATH=/usr/share/java/jdbc2_0-stdext.jar