This commit is contained in:
ccunatbrule
2021-10-28 22:25:44 +02:00
parent e0ea19e1e3
commit c551aef195
798 changed files with 12417 additions and 16 deletions

View File

@@ -1,15 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path=""/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER">
<classpathentry kind="src" path="src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-16">
<attributes>
<attribute name="module" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="lib" path="C:/Users/christian/eclipse-workspace/LesEcuriesdelaBoissiereJAVA_Script/mariadb-java-client-2.7.4.jar">
<classpathentry kind="lib" path="//NASCCB/Documents/Programmation/eclipse-workspace/Ecurie-Projet/src/mysql-connector-java-8.0.26/mariadb-java-client-2.7.4.jar">
<attributes>
<attribute name="module" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path=""/>
<classpathentry kind="output" path="bin"/>
</classpath>

View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>Ecurie_ccunatbrule</name>
<name>Ecurie-Projet</name>
<comment></comment>
<projects>
</projects>

View File

@@ -0,0 +1,14 @@
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=16
org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
org.eclipse.jdt.core.compiler.compliance=16
org.eclipse.jdt.core.compiler.debug.lineNumber=generate
org.eclipse.jdt.core.compiler.debug.localVariable=generate
org.eclipse.jdt.core.compiler.debug.sourceFile=generate
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning
org.eclipse.jdt.core.compiler.release=enabled
org.eclipse.jdt.core.compiler.source=16

View File

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 16 KiB

View File

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 14 KiB

View File

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

View File

Before

Width:  |  Height:  |  Size: 43 KiB

After

Width:  |  Height:  |  Size: 43 KiB

BIN
bin/images/favicon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.2 KiB

BIN
bin/images/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

BIN
src/images/choix1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

BIN
src/images/choix2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB

BIN
src/images/favicon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.2 KiB

BIN
src/images/logo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

View File

@@ -23,6 +23,7 @@ public class BDD {
}
catch(ClassNotFoundException exp) {
System.out.println("Abscence du pilote JDBC !");
System.out.println("Vérifier Project -> Build Path -> Configure -> Libraries -> Add External JARs");
}
}
public void seConnecter() {

View File

@@ -10,7 +10,7 @@ public class ModeleEleve
{
public static ArrayList<Eleve> selectAll() {
ArrayList<Eleve> lesEleves = new ArrayList<Eleve>();
String requete = "select * from compteeleve;";
String requete = "select * from Eleve;";
try {
BDD uneBDD = new BDD();
uneBDD.seConnecter();
@@ -43,7 +43,7 @@ public class ModeleEleve
return lesEleves;
}
public static Eleve selectWhere(String mail) {
String requete = "select * from compteeleve where adressemail='" + mail + "';";
String requete = "select * from Eleve where adressemail='" + mail + "';";
Eleve unEleve = null;
try {
BDD uneBDD = new BDD();
@@ -76,7 +76,7 @@ public class ModeleEleve
return unEleve;
}
public static void insert(Eleve unEleve) {
String requete = "insert into CompteEleve (privilege, dateenregistre, pseudo, prenom, nom, sexe, age, adresse, mdp, adressemail, galop, imageeleve) values ('"
String requete = "insert into Eleve (privilege, dateenregistre, pseudo, prenom, nom, sexe, age, adresse, mdp, adressemail, galop, imageeleve) values ('"
+ "2', NOW(), 'NEW', '"
+ unEleve.getPrenom() + "', '"
+ unEleve.getNom() + "', '"
@@ -120,7 +120,7 @@ public class ModeleEleve
else { valueAdresse = ", adresse = '"+ unEleve.getAdresse() +"'"; }
if (String.valueOf(unEleve.getGalop()).equals("")) { valueGalop = ""; }
else { valueGalop = ", galop = "+ unEleve.getGalop(); }
String requete = "update compteeleve set adressemail ='"+ unEleve.getMail() +"'" + valuePrenom + valueNom + valueSexe + valueAge + valueAdresse + valueGalop + " where adressemail='"+ mail +"';";
String requete = "update Eleve set adressemail ='"+ unEleve.getMail() +"'" + valuePrenom + valueNom + valueSexe + valueAge + valueAdresse + valueGalop + " where adressemail='"+ mail +"';";
try {
BDD uneBDD = new BDD();
uneBDD.seConnecter();
@@ -134,7 +134,7 @@ public class ModeleEleve
}
}
public static void delete(String mail) {
String requete = "delete from CompteEleve where adressemail='" + mail + "';";
String requete = "delete from Eleve where adressemail='" + mail + "';";
try {
BDD uneBDD = new BDD();
uneBDD.seConnecter();

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,4 @@
build-date: 2021-06-08 16:39:29 +0000
os-info: Linux i386 4.1.12-124.48.6.el6uek.x86_64
compiler: javac 1.8.0_241
build-tool: Apache Ant(TM) version 1.10.7 compiled on September 1 2019

View File

@@ -0,0 +1,5 @@
version: 8.0.26
branch: release/8.0.26
date: 2021-06-08 14:49:03 +0100
commit: 9aae1e450989d62c06616c1dcda3e404ef84df70
short: 9aae1e45

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,28 @@
Copyright (c) 2000, 2021, Oracle and/or its affiliates.
This is a release of MySQL Connector/J, a JDBC Type 4 driver for MySQL that
also supports the new X DevAPI.
License information can be found in the LICENSE file.
This distribution may include materials developed by third parties.
For license and attribution notices for these materials, please refer to the
LICENSE file.
For more information on MySQL Connector/J, visit
https://dev.mysql.com/doc/connector-j/8.0/en/
For additional downloads and the source of MySQL Connector/J, visit
https://dev.mysql.com/downloads/
MySQL Connector/J is brought to you by the MySQL team at Oracle.
Notice:
- In order to use the logging capabilities provided by the default
implementation com.mysql.cj.log.Slf4JLogger, it is required to add one or
more jars for Simple Logging Facade for Java (SLF4J) to your CLASSPATH.
- To use the X DevAPI features in Connector/J, you also need the external
library protobuf-java, which you can download manually from the official
Maven repository and add it to the CLASSPATH, or use Maven's automatic
dependency resolution features by adding a dependency to "GroupId: mysql"
and "ArtifactId: mysql-connector-java" to your project's pom.xml file.

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>misc</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.m2e.core.maven2Builder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.m2e.core.maven2Nature</nature>
</natures>
</projectDescription>

View File

@@ -0,0 +1,66 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2019, 2020, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License, version 2.0, as published by the
Free Software Foundation.
This program is also distributed with certain software (including but not
limited to OpenSSL) that is licensed under separate terms, as designated in a
particular file or component or in included license documentation. The
authors of MySQL hereby grant you an additional permission to link the
program and your derivative works with the separately licensed software that
they have included with MySQL.
Without limiting anything contained in the foregoing, this file, which is
part of MySQL Connector/J, is also subject to the Universal FOSS Exception,
version 1.0, a copy of which can be found at
http://oss.oracle.com/licenses/universal-foss-exception.
This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License, version 2.0,
for more details.
You should have received a copy of the GNU General Public License along with
this program; if not, write to the Free Software Foundation, Inc.,
51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-->
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Product Id="*" Name="MySQL Connector J" Language="1033" Version="$(var.ProductVersion)" Manufacturer="Oracle Corporation" UpgradeCode="a887f346-5f02-4cf1-bb85-bf34b4c5f248">
<Package InstallerVersion="200" Compressed="yes" />
<Upgrade Id="574f7b74-d753-4965-995d-2de6a79afd01">
<UpgradeVersion OnlyDetect="no"
Minimum="6.0.0"
IncludeMinimum="yes"
Maximum="8.0.12"
IncludeMaximum="yes"
Property="OLDERVERSIONBEINGUPGRADED_OLD"/>
</Upgrade>
<Upgrade Id="a887f346-5f02-4cf1-bb85-bf34b4c5f248">
<UpgradeVersion OnlyDetect="no"
Minimum="8.0.13"
IncludeMinimum="yes"
Maximum="$(var.ProductVersion)"
Property="OLDERVERSIONBEINGUPGRADED"
IncludeMaximum="yes" />
</Upgrade>
<Media Id="1" Cabinet="media1.cab" EmbedCab="yes" />
<Directory Id="TARGETDIR" Name="SourceDir">
<Directory Id="ProgramFilesFolder">
<Directory Id="MySQL" Name="MySQL">
<Directory Id="INSTALLLOCATION" Name="MySQL Connector J 8.0">
<!-- Components Autogenerated using the WiX tool named Heat. See the Project properties for cmd line. -->
</Directory>
</Directory>
</Directory>
</Directory>
<Feature Id="ProductFeature" Title="wix_solution" Level="1">
<ComponentGroupRef Id="ConnJZipContents"/>
</Feature>
<InstallExecuteSequence>
<RemoveExistingProducts After="InstallInitialize" />
</InstallExecuteSequence>
</Product>
</Wix>

View File

@@ -0,0 +1,5 @@
@PRODUCT_NAME@@PRODUCT_SUFFIX@ (@MYSQL_CJ_VERSION@@MYSQL_CJ_VERSION_SNAPSHOT@@DEB_VERSION_SUFFIX@@ID_RELEASE@) @CODENAME@; urgency=low
* For release notes, please refer to https://dev.mysql.com/doc/relnotes/connector-j/8.0/en/
-- @MAINTAINER_EMAIL@ @PACKAGE_TIMESTAMP@

View File

@@ -0,0 +1 @@
9

View File

@@ -0,0 +1,14 @@
Source: @PRODUCT_NAME@@PRODUCT_SUFFIX@
Section: database
Priority: optional
Maintainer: Oracle MySQL Product Engineering Team <mysql-build@oss.oracle.com>
Standards-Version: 3.9.2
Build-Depends: debhelper (>= 8.9.4)
Homepage: http://dev.mysql.com/downloads/connector/j/
Package: @PRODUCT_NAME@@PRODUCT_SUFFIX@
Section: database
Architecture: all
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: MySQL Connector/J
Standardized MySQL database driver for Java

View File

@@ -0,0 +1,9 @@
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Upstream-Name: @PRODUCT@
Upstream-Contact: MySQL Release Engineering <mysql-build@oss.oracle.com>
Source: http://dev.mysql.com/
Files: *
Copyright: 2002, 2021, Oracle and/or its affiliates.
License:
For licensing information see the LICENSE file in this distribution.

View File

@@ -0,0 +1,8 @@
dist/toArchive/@PACKAGE_NAME@/@PRODUCT_NAME@@PRODUCT_SUFFIX@-@VERSION_FULL@.jar usr/share/java
#legal
dist/toArchive/@PACKAGE_NAME@/@LIC_FILE@ usr/share/doc/@PRODUCT_NAME@@PRODUCT_SUFFIX@
dist/toArchive/@PACKAGE_NAME@/README usr/share/doc/@PRODUCT_NAME@@PRODUCT_SUFFIX@
dist/toArchive/@PACKAGE_NAME@/CHANGES usr/share/doc/@PRODUCT_NAME@@PRODUCT_SUFFIX@
dist/toArchive/@PACKAGE_NAME@/INFO_SRC usr/share/doc/@PRODUCT_NAME@@PRODUCT_SUFFIX@
dist/toArchive/@PACKAGE_NAME@/INFO_BIN usr/share/doc/@PRODUCT_NAME@@PRODUCT_SUFFIX@

View File

@@ -0,0 +1,77 @@
#!/usr/bin/make -f
# Copyright (c) 2016, 2020, Oracle and/or its affiliates.
#
# This program is free software; you can redistribute it and/or modify it under
# the terms of the GNU General Public License, version 2.0, as published by the
# Free Software Foundation.
#
# This program is also distributed with certain software (including but not
# limited to OpenSSL) that is licensed under separate terms, as designated in a
# particular file or component or in included license documentation. The
# authors of MySQL hereby grant you an additional permission to link the
# program and your derivative works with the separately licensed software that
# they have included with MySQL.
#
# Without limiting anything contained in the foregoing, this file, which is
# part of MySQL Connector/J, is also subject to the Universal FOSS Exception,
# version 1.0, a copy of which can be found at
# http://oss.oracle.com/licenses/universal-foss-exception.
#
# This program is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE. See the GNU General Public License, version 2.0,
# for more details.
#
# You should have received a copy of the GNU General Public License along with
# this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
upstream_version := $(shell dpkg-parsechangelog | sed -n -e'/^Version: / { s/Version: //; s/-[^-]\+$$//; p }')
base_version = $(shell echo $(upstream_version) | sed -e's/r[0-9]\+$$//')
ANT_COMMON_OPTIONS=\
-Dcom.mysql.cj.build.dir.driver=build/driver \
-Dcom.mysql.cj.extra.libs=@WITH_JARDEPS@ \
-Dcom.mysql.cj.build.driver.version.status=@MYSQL_CJ_VERSION_STATUS@ \
-Dcom.mysql.cj.build.driver.version.extra=@MYSQL_CJ_VERSION_EXTRA@ \
-Dcom.mysql.cj.build.driver.version.snapshot=@MYSQL_CJ_VERSION_SNAPSHOT@ \
-Dcom.mysql.cj.build.driver.extraName=@PRODUCT_SUFFIX@ \
-Dcom.mysql.cj.dist.licenseUrl=@MYSQL_CJ_LICENSEURL@ \
-Djava.awt.headless=true
ifeq ($(ANT_HOME),)
ANT_CMD=ant
else
ANT_CMD=$(ANT_HOME)/bin/ant
endif
ANT_OPTS=-Xmx512M
ifneq ($(JAVA_HOME),)
ANT_JAVA_OPT=-Dcom.mysql.cj.build.jdk=$(JAVA_HOME)
endif
ifneq ($(COMMERCIAL),)
ANT_COM_OPT=-Dcom.mysql.cj.build.commercial=true
endif
%:
#dh $@ --with autoreconf
dh $@
override_dh_auto_configure:
override_dh_auto_build:
echo $(PATH)
echo $(JAVA_HOME)
$(ANT_CMD) \
$(ANT_COMMON_OPTIONS) \
$(ANT_JAVA_OPT) \
$(ANT_COM_OPT) \
full-package-no-sources
override_dh_auto_clean:
$(ANT_CMD) $(ANT_COMMON_OPTIONS) clean
override_dh_installchangelogs:
dh_installchangelogs -XCHANGES

View File

@@ -0,0 +1 @@
3.0 (quilt)

View File

@@ -0,0 +1,2 @@
version=3
http://mysql.osuosl.org/Downloads/@PRODUCT_NAME@-(.+)\.tar\.gz

View File

@@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!--
Copyright (c) 2006, 2020, Oracle and/or its affiliates.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License, version 2.0, as published by the
Free Software Foundation.
This program is also distributed with certain software (including but not
limited to OpenSSL) that is licensed under separate terms, as designated in a
particular file or component or in included license documentation. The
authors of MySQL hereby grant you an additional permission to link the
program and your derivative works with the separately licensed software that
they have included with MySQL.
Without limiting anything contained in the foregoing, this file, which is
part of MySQL Connector/J, is also subject to the Universal FOSS Exception,
version 1.0, a copy of which can be found at
http://oss.oracle.com/licenses/universal-foss-exception.
This program is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License, version 2.0,
for more details.
You should have received a copy of the GNU General Public License along with
this program; if not, write to the Free Software Foundation, Inc.,
51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-->
<project>
<modelVersion>4.0.0</modelVersion>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>@MYSQL_CJ_VERSION@</version>
<packaging>jar</packaging>
<name>MySQL Connector/J</name>
<description>JDBC Type 4 driver for MySQL</description>
<licenses>
<license>
<name>The GNU General Public License, v2 with FOSS exception</name>
<distribution>repo</distribution>
<comments>For detailed license information see the LICENSE file in this distribution.</comments>
</license>
</licenses>
<url>http://dev.mysql.com/doc/connector-j/en/</url>
<scm>
<connection>scm:git:git@github.com:mysql/mysql-connector-j.git</connection>
<url>https://github.com/mysql/mysql-connector-j</url>
</scm>
<organization>
<name>Oracle Corporation</name>
<url>http://www.oracle.com</url>
</organization>
<dependencies>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java</artifactId>
<version>3.11.4</version>
</dependency>
</dependencies>
</project>

View File

@@ -0,0 +1,197 @@
# Copyright (c) 2017, 2020, Oracle and/or its affiliates.
#
# This program is free software; you can redistribute it and/or modify it under
# the terms of the GNU General Public License, version 2.0, as published by the
# Free Software Foundation.
#
# This program is also distributed with certain software (including but not
# limited to OpenSSL) that is licensed under separate terms, as designated in a
# particular file or component or in included license documentation. The
# authors of MySQL hereby grant you an additional permission to link the
# program and your derivative works with the separately licensed software that
# they have included with MySQL.
#
# Without limiting anything contained in the foregoing, this file, which is
# part of MySQL Connector/J, is also subject to the Universal FOSS Exception,
# version 1.0, a copy of which can be found at
# http://oss.oracle.com/licenses/universal-foss-exception.
#
# This program is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
# FOR A PARTICULAR PURPOSE. See the GNU General Public License, version 2.0,
# for more details.
#
# You should have received a copy of the GNU General Public License along with
# this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
# You can pass these options to "rpmbuild"
#
# --define="commercial <nonempty>"
# --define="with_ant <path>"
# --define="with_java <path>"
# --define="with_jardeps <path>"
# --define="with_docs <path>"
#
# The 'with_docs' option should have a path that points out
#
# <docs-base>/en/html/connector-j.html
# <docs-base>/en/html/mvl.css (not really used)
# <docs-base>/en/pdf/connector-j.pdf
# <docs-base>/en/txt/connector-j.txt
# Some linux distributions doesn't set the "dist" macro. There is a
# list how to identify dists here
# https://en.opensuse.org/openSUSE:Build_Service_cross_distribution_howto
# SuSE will not set "dist", others do
%if 0%{?suse_version} == 1315
%global dist .sles12
%global sles12 1
%endif
%if 0%{?suse_version} == 1500
%global dist .sl15
%global sles15 1
%endif
%if 0%{?commercial:1}
%global lic_tag Commercial
%else
%global lic_tag GPLv2
%endif
Summary: Standardized MySQL database driver for Java
Name: @MYSQL_CJ_EXTENDED_PROD_NAME@
Version: @MYSQL_CJ_VERSION_NUMERIC@
Release: @MYSQL_CJ_RPM_RELEASE_FULL@%{?dist}
Epoch: 1
License: %{lic_tag}
Group: Development/Libraries
URL: http://dev.mysql.com/downloads/connector/j/
Source0: https://cdn.mysql.com/Downloads/Connector-J/@MYSQL_CJ_FULL_PROD_NAME@.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildArch: noarch
%if 0%{?commercial:1}
Obsoletes: mysql-connector-java < %{version}-%{release}
Provides: mysql-connector-java = %{version}-%{release}
%endif
%if 0%{!?with_ant:1}
BuildRequires: ant
%endif
%if 0%{!?with_java:1}
BuildRequires: java-devel >= 1:1.8.0
%endif
%if 0%{?sles12:1} || 0%{?sles15:1}
Requires: java-headless >= 1.8.0
%else
Requires: java-headless >= 1:1.8.0
%endif
%description
MySQL provides connectivity for client applications developed in the
Java programming language with @MYSQL_CJ_DISPLAY_PROD_NAME@, a driver that
implements the [Java Database Connectivity (JDBC) API]
(http://www.oracle.com/technetwork/java/javase/jdbc/).
@MYSQL_CJ_DISPLAY_PROD_NAME@ @MYSQL_CJ_VERSION_SERIES@ is a JDBC Type 4 driver that is compatible with
the [JDBC 4.2](http://docs.oracle.com/javase/8/docs/technotes/guides/jdbc/)
specification. The Type 4 designation means that the driver is a pure
Java implementation of the MySQL protocol and does not rely on the
MySQL client libraries.
For detailed information please visit the official
[@MYSQL_CJ_DISPLAY_PROD_NAME@ documentation]
(http://dev.mysql.com/doc/connector-j/en/).
%prep
%setup -q -n @MYSQL_CJ_FULL_PROD_NAME@
%build
COMMON_OPTIONS="\
-Dcom.mysql.cj.build.dir.driver=build/driver
-Dcom.mysql.cj.extra.libs=%{with_jardeps} \
-Dcom.mysql.cj.build.driver.version.status=@MYSQL_CJ_VERSION_STATUS@ \
-Dcom.mysql.cj.build.driver.version.extra=@MYSQL_CJ_VERSION_EXTRA@ \
-Dcom.mysql.cj.build.driver.version.snapshot=@MYSQL_CJ_VERSION_SNAPSHOT@ \
-Dcom.mysql.cj.build.driver.extraName=@MYSQL_CJ_EXTRA_NAME@ \
-Dcom.mysql.cj.dist.licenseUrl=@MYSQL_CJ_LICENSEURL@ \
-Djava.awt.headless=true"
%if 0%{?with_ant:1}
export ANT_HOME=%{with_ant}
export ANT_CMD="${ANT_HOME}/bin/ant"
%else
export ANT_CMD="ant"
%endif
export ANT_OPTS=-Xmx512M
%if 0%{?with_java:1}
export JAVA_HOME=%{with_java}
export PATH=${JAVA_HOME}/bin:$PATH
COMMON_OPTIONS="${COMMON_OPTIONS} -Dcom.mysql.cj.build.jdk=${JAVA_HOME}"
%endif
%if 0%{?commercial:1}
COMMON_OPTIONS="${COMMON_OPTIONS} -Dcom.mysql.cj.build.commercial=true"
%endif
# Get the file revision-info.properties again because it was excluded
# from SOURCES
cp %{_tmppath}/@MYSQL_CJ_FULL_PROD_NAME@/revision-info.properties .
${ANT_CMD} \
${COMMON_OPTIONS} \
full-package-no-sources
# We use the 'full-package-no-sources' as there are changes done only
# when creating a package, 'dist' is not enough. To make it a bit easier
# in the install step, we rename the directory with the content
mv dist/toArchive/@PACKAGE_NAME@ package-content
# The 'package' target doesn't copy the HTML or PDF doc like 'dist',
# we copy it here
%if 0%{?with_docs:1}
mkdir -p package-content/docs
cp %{with_docs}/en/html/connector-j.html package-content/docs/
cp %{with_docs}/en/html/mvl.css package-content/docs/
cp %{with_docs}/en/pdf/connector-j.pdf package-content/docs/
cp %{with_docs}/en/txt/connector-j.txt package-content/docs/
%endif
%install
install -d -m 0755 %{buildroot}%{_javadir}
install -p -m 0644 package-content/@MYSQL_CJ_FULL_PROD_NAME@.jar %{buildroot}%{_javadir}/%{name}.jar
%clean
rm -rf %{buildroot}
%files
%doc package-content/CHANGES
# EL6 doesn't like 'license' macro here, so we use 'doc'
%doc package-content/LICENSE
%doc package-content/README
%doc package-content/INFO_BIN
%doc package-content/INFO_SRC
%if 0%{?with_docs:1}
# README.txt is a rename of "connector-j.txt"
%doc package-content/docs/connector-j.txt
%doc package-content/docs/connector-j.pdf
%doc package-content/docs/connector-j.html
%doc package-content/docs/mvl.css
%endif
%{_javadir}/%{name}.jar
%changelog
* Mon Nov 27 2017 MySQL Release Engineering <mysql-build@oss.oracle.com> - 8.0.9-1
- Set more in "build.xml"
* Tue Mar 14 2017 MySQL Release Engineering <mysql-build@oss.oracle.com> - 6.0.7-1
- initial package

Some files were not shown because too many files have changed in this diff Show More