diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2018-07-14 21:03:06 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2018-07-14 21:03:06 +0100 |
commit | 8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch) | |
tree | 7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-java/freemarker/files | |
parent | 30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff) |
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-java/freemarker/files')
3 files changed, 208 insertions, 0 deletions
diff --git a/dev-java/freemarker/files/build.xml.patch b/dev-java/freemarker/files/build.xml.patch new file mode 100644 index 000000000000..33701f89175d --- /dev/null +++ b/dev-java/freemarker/files/build.xml.patch @@ -0,0 +1,60 @@ +diff -Naur a/build.xml b/build.xml +--- a/build.xml 2016-06-14 19:48:01.000000000 +0100 ++++ b/build.xml 2016-12-22 22:41:41.988262564 +0000 +@@ -27,6 +27,10 @@ + xmlns:u="http://freemarker.org/util" + > + ++ <path id="gentoo.classpath"> ++ <pathelement path="${gentoo.classpath}/"/> ++ </path> ++ + <!-- ================================================================== --> + <!-- Properties --> + <!-- ================================================================== --> +@@ -143,13 +147,11 @@ + /> + + <mkdir dir="${_javaccOutputDir}" /> +- <ivy:retrieve conf="parser" pattern="build/javacc-home.tmp/[artifact].[ext]" /> + <javacc:generate + target="src/main/javacc/FTL.jj" + outputdirectory="${_javaccOutputDir}" + javacchome="build/javacc-home.tmp" + /> +- <delete dir="build/javacc-home.tmp" /> + + <replace + file="${_javaccOutputDir}/FMParser.java" +@@ -271,6 +273,7 @@ + verify="yes" stubversion="1.2" + /> + ++<!-- + <ivy:cachepath conf="build.jsp2.0" pathid="ivy.dep.jsp2.0" /> + <javac srcdir="build/src-main-java-filtered" destdir="build/classes" deprecation="off" + debug="on" optimize="off" target="1.5" source="1.5" encoding="utf-8" +@@ -286,6 +289,7 @@ + freemarker/ext/jsp/FreeMarkerJspFactory21.java, + freemarker/ext/jsp/FreeMarkerJspApplicationContext.java" + /> ++!--> + + <!-- There's no build.jsp2.0, as those classes are part of the common build subset. --> + +@@ -301,6 +305,7 @@ + freemarker/ext/jsp/FreeMarkerJspApplicationContext.java" + /> + ++<!-- + <ivy:cachepath conf="build.jython2.0" pathid="ivy.dep.jython2.0" /> + <javac srcdir="build/src-main-java-filtered" destdir="build/classes" deprecation="off" + debug="on" optimize="off" target="1.5" source="1.5" encoding="utf-8" +@@ -325,6 +330,7 @@ + includes=" + freemarker/ext/jython/_Jython22VersionAdapter.java" + /> ++!--> + + <ivy:cachepath conf="build.jython2.5" pathid="ivy.dep.jython2.5" /> + <javac srcdir="build/src-main-java-filtered" destdir="build/classes" deprecation="off" diff --git a/dev-java/freemarker/files/freemarker-2.3.13-PyJavaInstance.patch b/dev-java/freemarker/files/freemarker-2.3.13-PyJavaInstance.patch new file mode 100644 index 000000000000..b0544d170b15 --- /dev/null +++ b/dev-java/freemarker/files/freemarker-2.3.13-PyJavaInstance.patch @@ -0,0 +1,22 @@ +--- src/freemarker/ext/jython/JythonModelCache.java.orig 2015-07-05 08:47:07.035000000 +0000 ++++ src/freemarker/ext/jython/JythonModelCache.java 2015-07-05 08:49:31.157000000 +0000 +@@ -10,7 +10,7 @@ + import org.python.core.PyDictionary;
+ import org.python.core.PyFloat;
+ import org.python.core.PyInteger;
+-import org.python.core.PyJavaInstance;
++import org.python.core.PyJavaType;
+ import org.python.core.PyLong;
+ import org.python.core.PyNone;
+ import org.python.core.PyObject;
+@@ -37,8 +37,8 @@ + protected TemplateModel create(Object obj) {
+ boolean asHash = false;
+ boolean asSequence = false;
+- if(obj instanceof PyJavaInstance) {
+- Object jobj = ((PyJavaInstance)obj).__tojava__(java.lang.Object.class);
++ if(obj instanceof PyJavaType) {
++ Object jobj = PyJavaType.wrapJavaObject(obj).__tojava__(Object.class);
+ // FreeMarker-aware, Jython-wrapped Java objects are left intact
+ if(jobj instanceof TemplateModel) {
+ return (TemplateModel)jobj;
diff --git a/dev-java/freemarker/files/freemarker-2.3.13-gentoo.patch b/dev-java/freemarker/files/freemarker-2.3.13-gentoo.patch new file mode 100644 index 000000000000..9eca29a827ad --- /dev/null +++ b/dev-java/freemarker/files/freemarker-2.3.13-gentoo.patch @@ -0,0 +1,126 @@ +diff -Nru freemarker-2.3.13.vanilla/build.xml freemarker-2.3.13/build.xml +--- freemarker-2.3.13.vanilla/build.xml 2008-06-21 00:46:08.000000000 +0200 ++++ freemarker-2.3.13/build.xml 2008-06-21 00:46:48.000000000 +0200 +@@ -69,21 +69,28 @@ + <pathelement path="${lib.log4j}"/> + <pathelement path="${lib.rhino}"/> + <pathelement path="${java.class.path}"/> ++ <fileset dir="lib" includes="*.jar"/> + </path> + + <path id="compile.classpath"> + <path refid="compile.nojsp.classpath"/> + <pathelement path="${lib.jsp21}"/> ++ <fileset dir="lib" includes="*.jar"/> ++ <fileset dir="lib/jsp-2.1" includes="*.jar"/> + </path> + + <path id="compile.jsp1.classpath"> + <path refid="compile.nojsp.classpath"/> + <pathelement path="${lib.jsp12}"/> ++ <fileset dir="lib" includes="*.jar"/> ++ <fileset dir="lib/jsp-1.2" includes="*.jar"/> + </path> + + <path id="compile.jsp2.classpath"> + <path refid="compile.nojsp.classpath"/> + <pathelement path="${lib.jsp20}"/> ++ <fileset dir="lib" includes="*.jar"/> ++ <fileset dir="lib/jsp-2.0" includes="*.jar"/> + </path> + + <path id="compile.classpath.testcases"> +@@ -92,6 +99,7 @@ + <pathelement path="${lib.jdom}"/> + <pathelement path="${lib.servlet}"/> + <pathelement path="${lib.jsp20}"/> ++ <fileset dir="lib" includes="*.jar"/> + </path> + + <path id="compile.classpath.javadoc"> +@@ -110,12 +118,14 @@ + <pathelement path="${src.dir}"/> + <pathelement path="${build.javacc.dir}"/> + <pathelement path="${java.class.path}"/> ++ <fileset dir="lib" includes="*.jar"/> + </path> + + <path id="compile.classpath.examples"> + <pathelement path="${lib.servlet}"/> + <pathelement path="${lib.dir}/freemarker.jar"/> + <pathelement path="${lib.struts}"/> ++ <fileset dir="lib" includes="*.jar"/> + </path> + + <path id="full.classpath"> +@@ -131,6 +141,7 @@ + <pathelement path="${lib.logkit}"/> + <pathelement path="${lib.log4j}"/> + <pathelement path="${java.class.path}"/> ++ <fileset dir="lib" includes="*.jar"/> + </path> + + +@@ -180,7 +191,6 @@ + + <patternset id="freemarker.compile.jdk15"> + <include name="freemarker/ext/beans/EnumModels.java"/> +- <include name="freemarker/ext/dom/SunInternalXalanXPathSupport.java"/>
+ </patternset> + + <patternset id="freemarker.compile.xalan"> +@@ -311,7 +321,6 @@ + <available file="lib/xalan.jar"/>
+ </and> + </condition> +- <antcall target="fetchlibs"/> + <available + property="log4j.available" + classname="org.apache.log4j.Logger" +diff -Nru freemarker-2.3.13.vanilla/src/freemarker/ext/jsp/FreeMarkerPageContext21.java freemarker-2.3.13/src/freemarker/ext/jsp/FreeMarkerPageContext21.java +--- freemarker-2.3.13.vanilla/src/freemarker/ext/jsp/FreeMarkerPageContext21.java 2008-06-21 00:46:08.000000000 +0200 ++++ freemarker-2.3.13/src/freemarker/ext/jsp/FreeMarkerPageContext21.java 2008-06-21 00:46:12.000000000 +0200 +@@ -2,11 +2,13 @@ + + import java.security.AccessController; + import java.security.PrivilegedAction; ++import java.util.Enumeration; + + import javax.el.ELContext; + import javax.servlet.jsp.JspApplicationContext; + import javax.servlet.jsp.JspContext; + import javax.servlet.jsp.JspFactory; ++import javax.servlet.jsp.ErrorData; + import javax.servlet.jsp.PageContext; + import javax.servlet.jsp.el.ELException; + import javax.servlet.jsp.el.ExpressionEvaluator; +@@ -24,6 +26,9 @@ + class FreeMarkerPageContext21 extends FreeMarkerPageContext { + private static final Logger logger = Logger.getLogger("freemarker.jsp"); + ++ public ErrorData getErrorData() { return null; } ++ public Enumeration getAttributeNames() { return getServletContext().getAttributeNames(); } ++ + static { + if(JspFactory.getDefaultFactory() == null) { + JspFactory.setDefaultFactory(new FreeMarkerJspFactory21()); +diff -Nru freemarker-2.3.13.vanilla/src/freemarker/ext/jython/JythonHashModel.java freemarker-2.3.13/src/freemarker/ext/jython/JythonHashModel.java +--- freemarker-2.3.13.vanilla/src/freemarker/ext/jython/JythonHashModel.java 2008-06-21 00:46:08.000000000 +0200 ++++ freemarker-2.3.13/src/freemarker/ext/jython/JythonHashModel.java 2008-06-21 00:46:12.000000000 +0200 +@@ -137,7 +137,7 @@ + { + throw new TemplateModelException(e); + } +- throw new TemplateModelException("'?keys' is not supported as there is no 'keys' nor 'keySet' attribute on an instance of " + object.__class__.__name__); ++ throw new TemplateModelException("'?keys' is not supported as there is no 'keys' nor 'keySet' attribute on an instance of " + object.getType()); + } + + /** +@@ -157,6 +157,6 @@ + { + throw new TemplateModelException(e); + } +- throw new TemplateModelException("'?values' is not supported as there is no 'values' attribute on an instance of " + object.__class__.__name__); ++ throw new TemplateModelException("'?values' is not supported as there is no 'values' attribute on an instance of " + object.getType()); + } + } |