[mckoi] Initial import (#832816).

gil gil at fedoraproject.org
Fri Aug 3 17:49:25 UTC 2012


commit 5c8da0a296b5805e239ef8db38d8befa52634b94
Author: gil <puntogil at libero.it>
Date:   Fri Aug 3 19:49:11 2012 +0200

    Initial import (#832816).

 .gitignore                        |    1 +
 mckoi-1.0.4-fix_fsf-address.patch |   36 ++++++++
 mckoi-1.0.4-jdk7.patch            |  179 +++++++++++++++++++++++++++++++++++++
 mckoi.spec                        |  134 +++++++++++++++++++++++++++
 sources                           |    1 +
 5 files changed, 351 insertions(+), 0 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index e69de29..15abab7 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/mckoi1.0.4.zip
diff --git a/mckoi-1.0.4-fix_fsf-address.patch b/mckoi-1.0.4-fix_fsf-address.patch
new file mode 100644
index 0000000..5c85417
--- /dev/null
+++ b/mckoi-1.0.4-fix_fsf-address.patch
@@ -0,0 +1,36 @@
+diff -Nru mckoi1.0.4/contrib/JDBCQueryTool.java mckoi1.0.4-gil/contrib/JDBCQueryTool.java
+--- mckoi1.0.4/contrib/JDBCQueryTool.java	2011-10-24 14:49:04.000000000 +0200
++++ mckoi1.0.4-gil/contrib/JDBCQueryTool.java	2012-07-19 11:19:49.189070710 +0200
+@@ -16,7 +16,7 @@
+  *
+  * 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., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
++ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+  *
+  * Change Log:
+  *
+diff -Nru mckoi1.0.4/docs/LICENSE.txt mckoi1.0.4-gil/docs/LICENSE.txt
+--- mckoi1.0.4/docs/LICENSE.txt	2011-10-24 14:49:02.000000000 +0200
++++ mckoi1.0.4-gil/docs/LICENSE.txt	2012-07-19 11:19:49.193070514 +0200
+@@ -2,7 +2,7 @@
+ 		       Version 2, June 1991
+ 
+  Copyright (C) 1989, 1991 Free Software Foundation, Inc.
+-                       59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
++                       51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+  Everyone is permitted to copy and distribute verbatim copies
+  of this license document, but changing it is not allowed.
+ 
+diff -Nru mckoi1.0.4/LICENSE.txt mckoi1.0.4-gil/LICENSE.txt
+--- mckoi1.0.4/LICENSE.txt	2011-10-24 14:49:18.000000000 +0200
++++ mckoi1.0.4-gil/LICENSE.txt	2012-07-19 11:19:49.183071006 +0200
+@@ -2,7 +2,7 @@
+ 		       Version 2, June 1991
+ 
+  Copyright (C) 1989, 1991 Free Software Foundation, Inc.
+-                       59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
++                       51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+  Everyone is permitted to copy and distribute verbatim copies
+  of this license document, but changing it is not allowed.
+ 
diff --git a/mckoi-1.0.4-jdk7.patch b/mckoi-1.0.4-jdk7.patch
new file mode 100644
index 0000000..a3b80e9
--- /dev/null
+++ b/mckoi-1.0.4-jdk7.patch
@@ -0,0 +1,179 @@
+diff -Nru src/main/java/com/mckoi/database/jdbc/MConnection.java src/main/java/com/mckoi/database/jdbc-gil/MConnection.java
+--- src/main/java/com/mckoi/database/jdbc/MConnection.java	2011-10-29 18:26:34.000000000 +0200
++++ src/main/java/com/mckoi/database/jdbc-gil/MConnection.java	2012-06-17 14:40:57.000000000 +0200
+@@ -29,6 +29,7 @@
+ import java.util.Properties;
+ import java.util.Vector;
+ import java.util.StringTokenizer;
++import java.util.concurrent.Executor;
+ import com.mckoi.database.global.ColumnDescription;
+ import com.mckoi.database.global.ObjectTransfer;
+ import com.mckoi.database.global.StreamableObject;
+@@ -906,6 +907,25 @@
+ 
+ //#ENDIF
+ 
++  public int getNetworkTimeout() throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setNetworkTimeout(Executor executor, int timeout) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++  public void abort(Executor executor) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public String getSchema() throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setSchema(String schema) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
+   // ---------- Inner classes ----------
+ 
+   /**
+diff -Nru src/main/java/com/mckoi/database/jdbc/MDatabaseMetaData.java src/main/java/com/mckoi/database/jdbc-gil/MDatabaseMetaData.java
+--- src/main/java/com/mckoi/database/jdbc/MDatabaseMetaData.java	2011-10-29 18:26:50.000000000 +0200
++++ src/main/java/com/mckoi/database/jdbc-gil/MDatabaseMetaData.java	2012-06-17 14:51:07.000000000 +0200
+@@ -1171,4 +1171,12 @@
+ 
+ //#ENDIF
+ 
++  public boolean generatedKeyAlwaysReturned() throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public ResultSet getPseudoColumns(String catalog, String schemaPattern, String tableNamePattern, String columnNamePattern) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
+ }
+diff -Nru src/main/java/com/mckoi/database/jdbc/MDriver.java src/main/java/com/mckoi/database/jdbc-gil/MDriver.java
+--- src/main/java/com/mckoi/database/jdbc/MDriver.java	2011-10-24 14:50:16.000000000 +0200
++++ src/main/java/com/mckoi/database/jdbc-gil/MDriver.java	2012-06-17 14:48:53.000000000 +0200
+@@ -29,11 +29,13 @@
+ 
+ import java.sql.*;
+ import java.io.*;
++import java.lang.NullPointerException;
+ import java.util.Properties;
+ import java.util.Enumeration;
+ import java.util.StringTokenizer;
+ import java.util.Vector;
+ import java.util.Hashtable;
++import java.util.logging.Logger;
+ import java.net.URL;
+ import java.net.MalformedURLException;
+ 
+@@ -629,4 +631,8 @@
+     return false;
+   }
+ 
++  public Logger getParentLogger() throws SQLFeatureNotSupportedException {
++    throw new NullPointerException();
++  }
++
+ }
+diff -Nru src/main/java/com/mckoi/database/jdbc/MPreparedStatement.java src/main/java/com/mckoi/database/jdbc-gil/MPreparedStatement.java
+--- src/main/java/com/mckoi/database/jdbc/MPreparedStatement.java	2011-10-24 15:10:02.000000000 +0200
++++ src/main/java/com/mckoi/database/jdbc-gil/MPreparedStatement.java	2012-06-17 14:45:52.000000000 +0200
+@@ -564,6 +564,13 @@
+   }
+ 
+ //#ENDIF
++  public boolean isCloseOnCompletion() throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void closeOnCompletion() throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
+ 
+   /**
+    * For diagnostics.
+diff -Nru src/main/java/com/mckoi/database/jdbc/MResultSet.java src/main/java/com/mckoi/database/jdbc-gil/MResultSet.java
+--- src/main/java/com/mckoi/database/jdbc/MResultSet.java	2011-10-29 18:28:46.000000000 +0200
++++ src/main/java/com/mckoi/database/jdbc-gil/MResultSet.java	2012-06-17 14:57:10.000000000 +0200
+@@ -1893,6 +1893,62 @@
+ 
+ //#ENDIF
+ 
++  public <T> T getObject(String columnLabel, Class<T> arg0) throws SQLException { 
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public <T> T getObject(int columnIndex, Class<T> arg0) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setNClob(String parameterName, Reader reader) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setBlob(String parameterName, java.io.InputStream inputStream) throws SQLException { 
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setClob(String parameterName, Reader reader) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setNCharacterStream(String parameterName, Reader value) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setCharacterStream(String parameterName, Reader reader) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setBinaryStream(String parameterName, InputStream x) throws SQLException { 
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setAsciiStream(String parameterName, InputStream x) throws SQLException { 
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setCharacterStream(String parameterName, Reader reader, long length) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setBinaryStream(String parameterName, InputStream x, long length) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setAsciiStream(String parameterName, InputStream x, long length) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setClob(String parameterName, Clob x) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
++  public void setBlob(String parameterName, Blob x) throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
++
+   // ---------- Finalize ----------
+ 
+   public void finalize() {
+diff -Nru src/main/java/com/mckoi/database/jdbc/MStatement.java src/main/java/com/mckoi/database/jdbc-gil/MStatement.java
+--- src/main/java/com/mckoi/database/jdbc/MStatement.java	2011-10-29 18:32:32.000000000 +0200
++++ src/main/java/com/mckoi/database/jdbc-gil/MStatement.java	2012-06-17 14:44:21.000000000 +0200
+@@ -598,7 +598,13 @@
+   }
+ 
+ //#ENDIF
++  public boolean isCloseOnCompletion() throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
+ 
++  public void closeOnCompletion() throws SQLException {
++    throw new SQLFeatureNotSupportedException();
++  }
+ 
+ 
+ 
diff --git a/mckoi.spec b/mckoi.spec
new file mode 100644
index 0000000..97368c2
--- /dev/null
+++ b/mckoi.spec
@@ -0,0 +1,134 @@
+Name:          mckoi
+Version:       1.0.4
+Release:       2%{?dist}
+Summary:       Open Source Java SQL Database
+Group:         Development/Libraries
+License:       GPLv2
+URL:           http://mckoi.com/database/
+Source0:       http://mckoi.com/database/ver/%{name}%{version}.zip
+
+Patch0:        %{name}-%{version}-jdk7.patch
+
+Patch1:        %{name}-%{version}-fix_fsf-address.patch
+
+BuildRequires: java-devel
+BuildRequires: jpackage-utils
+
+BuildRequires: javacc
+BuildRequires: maven
+BuildRequires: maven-compiler-plugin
+BuildRequires: maven-install-plugin
+BuildRequires: maven-jar-plugin
+BuildRequires: maven-javadoc-plugin
+BuildRequires: maven-resources-plugin
+BuildRequires: maven-surefire-plugin
+BuildRequires: zip
+
+BuildRequires: gnu-regexp
+
+Requires:      java
+Requires:      jpackage-utils
+BuildArch:     noarch
+
+%description
+Mckoi SQL Database is an Open Source SQL Database System written in Java.
+The Mckoi SQL Database project was started in 1998, and the goal was to
+build a database management system in a traditional shared disk/shared memory
+style architecture. Mckoi SQL Database includes some nice features such as
+write-ahead-logging. Many of the design ideas implemented in this project
+were carried through into MckoiDDB, the evolution of this project.
+
+%package javadoc
+Group:         Documentation
+Summary:       Javadoc for %{name}
+Requires:      jpackage-utils
+
+%description javadoc
+This package contains javadoc for %{name}.
+
+%package demos
+Group:         Development/Libraries
+Summary:       Demonstrations and samples for %{name}
+Requires:      %{name} = %{version}-%{release}
+Requires:      gnu-regexp
+
+%description demos
+This package contains sources archive demonstrations and samples for %{name}.
+
+%prep
+%setup -q -n %{name}%{version}
+find . -name '*.jar' -delete
+find . -name '*.class' -delete
+find . -name '*.bat' -delete
+unzip -qq src.zip
+%patch0 -p0
+%patch1 -p1
+
+# contrib require org.jboss.system
+# fix generics support for java 7
+sed -i "s|<source>1.3</source>|<source>1.5</source>|" pom.xml
+sed -i "s|<target>1.3</target>|<target>1.5</target>|" pom.xml
+
+sed -i "s|../mckoidb.jar:../gnu-regexp-1.0.8.jar|../target/MckoiSQLDB-%{version}.jar:%{_javadir}/gnu-regexp.jar|" test/*.sh
+chmod 755 test/*.sh
+
+sed -i 's/\r//' README.txt LICENSE.txt docs/LICENSE.txt
+
+cd src/main/java/com/mckoi/database/sql
+rm -rf TokenMgrError.java ParseException.java Token.java SimpleCharStream.java
+javacc.sh SQL.jj
+
+%build
+
+mvn-rpmbuild install javadoc:aggregate
+
+%install
+
+mkdir -p %{buildroot}%{_javadir}
+install -m 644 target/MckoiSQLDB-%{version}.jar \
+  %{buildroot}%{_javadir}/%{name}.jar
+( cd %{buildroot}%{_javadir} && ln -s %{name}.jar MckoiSQLDB.jar )
+
+mkdir -p %{buildroot}%{_mavenpomdir}
+install -pm 644 pom.xml %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom
+%add_maven_depmap JPP-%{name}.pom %{name}.jar -a "mckoi:mckoi"
+
+mkdir -p %{buildroot}%{_javadocdir}/%{name}
+cp -rp target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name}
+
+mkdir -p %{buildroot}%{_datadir}/%{name}
+(
+  cd src/main/java
+  zip ../../../%{name}-src -r com
+)
+cp -pr %{name}-src.zip %{buildroot}%{_datadir}/%{name}
+cp -pr contrib %{buildroot}%{_datadir}/%{name}
+cp -pr demo %{buildroot}%{_datadir}/%{name}
+cp -pr test %{buildroot}%{_datadir}/%{name}
+
+%check
+cd test
+sh ./runLocalTest.sh
+
+%files
+%{_javadir}/%{name}.jar
+%{_javadir}/MckoiSQLDB.jar
+%{_mavenpomdir}/JPP-%{name}.pom
+%{_mavendepmapfragdir}/%{name}
+%doc LICENSE.txt README.txt
+
+%files javadoc
+%{_javadocdir}/%{name}
+%doc LICENSE.txt
+
+%files demos
+%{_datadir}/%{name}
+%doc docs/*
+
+%changelog
+* Thu Jul 19 2012 gil cattaneo <puntogil at libero.it> 1.0.4-2
+- Added demos package. 
+- demos package contains also sources archive.
+
+* Sat Jun 16 2012 gil cattaneo <puntogil at libero.it> 1.0.4-1
+- initial rpm
\ No newline at end of file
diff --git a/sources b/sources
index e69de29..6d8b12a 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+c8a68a62938d6a4c557ad02a4e0edbbf  mckoi1.0.4.zip


More information about the scm-commits mailing list