summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKeri Harris <keri@gentoo.org>2015-01-11 14:11:56 +0000
committerKeri Harris <keri@gentoo.org>2015-01-11 14:11:56 +0000
commit7a4ab38a7e6f76aacdc1ee868bf02cf4e95f81b5 (patch)
treecd6816db1c6ff5cb4f2783752e699a25218f80be /dev-lang
parentx86 stable, see bug 532086 (diff)
downloadgentoo-2-7a4ab38a7e6f76aacdc1ee868bf02cf4e95f81b5.tar.gz
gentoo-2-7a4ab38a7e6f76aacdc1ee868bf02cf4e95f81b5.tar.bz2
gentoo-2-7a4ab38a7e6f76aacdc1ee868bf02cf4e95f81b5.zip
Version bump
(Portage version: 2.2.14/cvs/Linux x86_64, signed Manifest commit with key A138F5ED)
Diffstat (limited to 'dev-lang')
-rw-r--r--dev-lang/tuprolog/ChangeLog10
-rw-r--r--dev-lang/tuprolog/files/build.xml5
-rw-r--r--dev-lang/tuprolog/files/tuprolog-2.9.0-no-ikvm.patch116
-rw-r--r--dev-lang/tuprolog/tuprolog-2.9.0.ebuild60
4 files changed, 189 insertions, 2 deletions
diff --git a/dev-lang/tuprolog/ChangeLog b/dev-lang/tuprolog/ChangeLog
index 6fc9b5ba10e9..e81dc3c1f4e3 100644
--- a/dev-lang/tuprolog/ChangeLog
+++ b/dev-lang/tuprolog/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for dev-lang/tuprolog
-# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/tuprolog/ChangeLog,v 1.54 2014/11/09 17:38:09 keri Exp $
+# Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/tuprolog/ChangeLog,v 1.55 2015/01/11 14:11:56 keri Exp $
+
+*tuprolog-2.9.0 (11 Jan 2015)
+
+ 11 Jan 2015; <keri@gentoo.org> +tuprolog-2.9.0.ebuild,
+ +files/tuprolog-2.9.0-no-ikvm.patch, files/build.xml:
+ Version bump
09 Nov 2014; <keri@gentoo.org> tuprolog-2.7.2.ebuild,
+files/tuprolog-2.7.2-no-ikvm.patch:
diff --git a/dev-lang/tuprolog/files/build.xml b/dev-lang/tuprolog/files/build.xml
index a59295990c43..f5b946fd56d6 100644
--- a/dev-lang/tuprolog/files/build.xml
+++ b/dev-lang/tuprolog/files/build.xml
@@ -38,6 +38,11 @@
<!-- build the jar file -->
<target depends="compile" name="jar">
<jar basedir="${build.dir}" jarfile="${dist.dir}/${jarfile}"/>
+ <jar basedir="${build.dir}" jarfile="${dist.dir}/2p.jar">
+ <manifest>
+ <attribute name="Main-Class" value="alice.tuprologx.ide.GUILauncher"/>
+ </manifest>
+ </jar>
</target>
<!-- generate javadocs -->
diff --git a/dev-lang/tuprolog/files/tuprolog-2.9.0-no-ikvm.patch b/dev-lang/tuprolog/files/tuprolog-2.9.0-no-ikvm.patch
new file mode 100644
index 000000000000..d94dc66bbac5
--- /dev/null
+++ b/dev-lang/tuprolog/files/tuprolog-2.9.0-no-ikvm.patch
@@ -0,0 +1,116 @@
+diff -urN tuprolog-2.9.0.orig/src/alice/tuprolog/LibraryManager.java tuprolog-2.9.0/src/alice/tuprolog/LibraryManager.java
+--- tuprolog-2.9.0.orig/src/alice/tuprolog/LibraryManager.java 2014-09-29 18:14:21.000000000 +0200
++++ tuprolog-2.9.0/src/alice/tuprolog/LibraryManager.java 2015-01-11 14:48:57.000000000 +0100
+@@ -9,11 +9,11 @@
+ import java.net.URL;
+ import java.net.URLClassLoader;
+ import java.util.*;
+-import cli.System.Reflection.Assembly;
++//import cli.System.Reflection.Assembly;
+
+ import alice.tuprolog.event.LibraryEvent;
+ import alice.tuprolog.event.WarningEvent;
+-import alice.util.AssemblyCustomClassLoader;
++//import alice.util.AssemblyCustomClassLoader;
+
+ /**
+ * @author Alex Benini
+@@ -179,31 +179,7 @@
+ } else
+ // .NET
+ {
+- Assembly asm = null;
+- boolean classFound = false;
+- className = "cli."
+- + className.substring(0, className.indexOf(","))
+- .trim();
+- for (int i = 0; i < paths.length; i++)
+- {
+- try
+- {
+- asm = Assembly.LoadFrom(paths[i]);
+- loader = new AssemblyCustomClassLoader(asm, urls);
+- lib = (Library) Class.forName(className, true, loader).newInstance();
+- if (lib != null)
+- {
+- classFound = true;
+- break;
+- }
+- } catch (Exception e)
+- {
+- e.printStackTrace();
+- continue;
+- }
+- }
+- if (!classFound)
+- throw new InvalidLibraryException(className, -1, -1);
++ throw new InvalidLibraryException(className, -1, -1);
+ }
+ }
+
+@@ -462,4 +438,4 @@
+ return optimizedDirectory;
+ }
+
+-}
+\ No newline at end of file
++}
+diff -urN tuprolog-2.9.0.orig/src/alice/tuprologx/ide/LibraryManager.java tuprolog-2.9.0/src/alice/tuprologx/ide/LibraryManager.java
+--- tuprolog-2.9.0.orig/src/alice/tuprologx/ide/LibraryManager.java 2014-09-29 18:14:21.000000000 +0200
++++ tuprolog-2.9.0/src/alice/tuprologx/ide/LibraryManager.java 2015-01-11 14:46:23.000000000 +0100
+@@ -18,7 +18,7 @@
+ package alice.tuprologx.ide;
+
+ import alice.tuprolog.*;
+-import alice.util.AssemblyCustomClassLoader;
++//import alice.util.AssemblyCustomClassLoader;
+
+ import java.io.File;
+ import java.net.URL;
+@@ -26,7 +26,7 @@
+ import java.util.ArrayList;
+ import java.util.Hashtable;
+ import java.util.StringTokenizer;
+-import cli.System.Reflection.Assembly;
++//import cli.System.Reflection.Assembly;
+
+ /**
+ * A dynamic manager for tuProlog libraries.
+@@ -155,10 +155,7 @@
+ // .NET
+ if(System.getProperty("java.vm.name").equals("IKVM.NET"))
+ {
+- Assembly asm = Assembly.LoadFrom(file.getPath());
+- loader = new AssemblyCustomClassLoader(asm, new URL[]{url});
+- libraryClassname = "cli." + libraryClassname.substring(0,
+- libraryClassname.indexOf(",")).trim();
++ throw new InvalidLibraryException(libraryClassname,-1,-1);
+ }
+ // JVM
+ else
+diff -urN tuprolog-2.9.0.orig/src/alice/util/AssemblyCustomClassLoader.java tuprolog-2.9.0/src/alice/util/AssemblyCustomClassLoader.java
+--- tuprolog-2.9.0.orig/src/alice/util/AssemblyCustomClassLoader.java 2014-09-29 18:14:21.000000000 +0200
++++ tuprolog-2.9.0/src/alice/util/AssemblyCustomClassLoader.java 1970-01-01 01:00:00.000000000 +0100
+@@ -1,21 +0,0 @@
+-package alice.util;
+-
+-import java.net.URL;
+-
+-public class AssemblyCustomClassLoader extends java.net.URLClassLoader
+-{
+- public AssemblyCustomClassLoader(cli.System.Reflection.Assembly asm, URL[] urls)
+- {
+- super(new java.net.URL[0], new ikvm.runtime.AssemblyClassLoader(asm));
+- // explicitly calling addURL() is safer than passing it to the super constructor,
+- // because this class loader instance may be used during the URL construction.
+- for (URL url : urls) {
+- addURL(url);
+- }
+- }
+-
+- public void addUrl(URL url)
+- {
+- addURL(url);
+- }
+-}
+\ No newline at end of file
diff --git a/dev-lang/tuprolog/tuprolog-2.9.0.ebuild b/dev-lang/tuprolog/tuprolog-2.9.0.ebuild
new file mode 100644
index 000000000000..aea7502007cc
--- /dev/null
+++ b/dev-lang/tuprolog/tuprolog-2.9.0.ebuild
@@ -0,0 +1,60 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/tuprolog/tuprolog-2.9.0.ebuild,v 1.1 2015/01/11 14:11:56 keri Exp $
+
+EAPI=3
+
+inherit eutils java-pkg-2 java-ant-2
+
+DESCRIPTION="tuProlog is a light-weight Prolog for Internet applications and infrastructures"
+HOMEPAGE="http://tuprolog.unibo.it/"
+SRC_URI="mirror://gentoo/${P}.tar.gz"
+
+LICENSE="LGPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="doc test"
+
+RDEPEND=">=virtual/jdk-1.7
+ >=dev-java/javassist-3"
+
+DEPEND="${RDEPEND}
+ dev-java/ant-core
+ test? (
+ dev-java/ant-junit4
+ dev-java/hamcrest-core
+ )"
+
+S="${WORKDIR}"/${P}
+
+EANT_GENTOO_CLASSPATH="javassist-3"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-no-ikvm.patch
+
+ cp "${FILESDIR}"/build.xml "${S}" || die
+ sed -i -e "s|test/unit|test|" "${S}"/build.xml \
+ || die "sed build.xml failed"
+}
+
+src_compile() {
+ eant jar $(use_doc)
+}
+
+src_test() {
+ cd "${S}"/dist
+ java-pkg_jar-from junit-4
+ java-pkg_jar-from hamcrest-core
+ cd "${S}"
+ ANT_TASKS="ant-junit4" eant -Djunit.jar=junit.jar test \
+ || die "eant test failed"
+}
+
+src_install() {
+ java-pkg_dojar dist/${PN}.jar
+ java-pkg_dojar dist/2p.jar
+
+ if use doc ; then
+ java-pkg_dohtml -r docs/* || die
+ fi
+}