gil pushed to thymeleaf (master). "Initial import (#1199840)."

notifications at fedoraproject.org notifications at fedoraproject.org
Tue Mar 31 05:07:53 UTC 2015


>From 364c4c5acd4077a1e3e05e14c8ced10516c4c087 Mon Sep 17 00:00:00 2001
From: gil <puntogil at libero.it>
Date: Tue, 31 Mar 2015 07:07:38 +0200
Subject: Initial import (#1199840).


diff --git a/.gitignore b/.gitignore
index e69de29..110eae9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/thymeleaf-2.1.4.RELEASE.tar.gz
diff --git a/W3C-license.txt b/W3C-license.txt
new file mode 100644
index 0000000..a755965
--- /dev/null
+++ b/W3C-license.txt
@@ -0,0 +1,38 @@
+By obtaining, using and/or copying this work, you (the licensee) agree that you have read,
+understood, and will comply with the following terms and conditions.
+
+Permission to copy, modify, and distribute this software and its documentation,
+with or without modification, for any purpose and without fee or royalty is hereby granted,
+provided that you include the following on ALL copies of the software and
+documentation or portions thereof, including modifications:
+
+* The full text of this NOTICE in a location viewable to users of the redistributed or derivative work.
+* Any pre-existing intellectual property disclaimers, notices, or terms and conditions. If none exist,
+  the W3C Software Short Notice should be included (hypertext is preferred, text is permitted) within the
+  body of any redistributed or derivative code.
+* Notice of any changes or modifications to the files, including the date changes were made.
+  (We recommend you provide URIs to the location from which the code is derived.)
+
+Disclaimers
+
+THIS SOFTWARE AND DOCUMENTATION IS PROVIDED "AS IS," AND COPYRIGHT HOLDERS MAKE NO REPRESENTATIONS OR WARRANTIES,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO, WARRANTIES OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE
+OR THAT THE USE OF THE SOFTWARE OR DOCUMENTATION WILL NOT INFRINGE ANY THIRD PARTY PATENTS, COPYRIGHTS,
+TRADEMARKS OR OTHER RIGHTS.
+
+COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF
+ANY USE OF THE SOFTWARE OR DOCUMENTATION.
+
+The name and trademarks of copyright holders may NOT be used in advertising or publicity pertaining to the
+software without specific, written prior permission. Title to copyright in this software and any associated
+documentation will at all times remain with copyright holders.
+Notes
+
+This version: http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
+
+This formulation of W3C's notice and license became active on December 31 2002. This version removes the
+copyright ownership notice such that this license can be used with materials other than those owned by the W3C,
+reflects that ERCIM is now a host of the W3C, includes references to this specific dated version of the license,
+and removes the ambiguous grant of "use". Otherwise, this version is the same as the previous version and
+is written so as to preserve the Free Software Foundation's assessment of GPL compatibility and
+OSI's certification under the Open Source Definition.
\ No newline at end of file
diff --git a/sources b/sources
index e69de29..14786bc 100644
--- a/sources
+++ b/sources
@@ -0,0 +1 @@
+0f54f4f2600dd91e5c8f7438494fa495  thymeleaf-2.1.4.RELEASE.tar.gz
diff --git a/thymeleaf-2.1.4-commons-ognl.patch b/thymeleaf-2.1.4-commons-ognl.patch
new file mode 100644
index 0000000..b4e835a
--- /dev/null
+++ b/thymeleaf-2.1.4-commons-ognl.patch
@@ -0,0 +1,89 @@
+diff -Nru thymeleaf-thymeleaf-2.1.4.RELEASE/pom.xml thymeleaf-thymeleaf-2.1.4.RELEASE.commons-ognl/pom.xml
+--- thymeleaf-thymeleaf-2.1.4.RELEASE/pom.xml	2014-12-21 22:26:15.000000000 +0100
++++ thymeleaf-thymeleaf-2.1.4.RELEASE.commons-ognl/pom.xml	2015-03-08 18:21:31.469994092 +0100
+@@ -95,7 +95,7 @@
+     <maven.compile.target>1.5</maven.compile.target>
+     <servlet-api.version>2.5</servlet-api.version>
+     <nekohtml.version>1.9.21</nekohtml.version>
+-    <ognl.version>3.0.8</ognl.version>
++    <ognl.version>4.0-incubating-SNAPSHOT</ognl.version>
+     <javassist.version>3.16.1-GA</javassist.version>
+     <unbescape.version>1.1.0.RELEASE</unbescape.version>
+     <slf4j.version>1.6.6</slf4j.version>
+@@ -266,8 +266,8 @@
+     </dependency>
+ 
+     <dependency>
+-      <groupId>ognl</groupId>
+-      <artifactId>ognl</artifactId>
++      <groupId>org.apache.commons</groupId>
++      <artifactId>commons-ognl</artifactId>
+       <version>${ognl.version}</version>
+       <scope>compile</scope>
+       <exclusions>
+diff -Nru thymeleaf-thymeleaf-2.1.4.RELEASE/src/main/java/org/thymeleaf/context/OGNLVariablesMapPropertyAccessor.java thymeleaf-thymeleaf-2.1.4.RELEASE.commons-ognl/src/main/java/org/thymeleaf/context/OGNLVariablesMapPropertyAccessor.java
+--- thymeleaf-thymeleaf-2.1.4.RELEASE/src/main/java/org/thymeleaf/context/OGNLVariablesMapPropertyAccessor.java	2014-12-21 22:26:15.000000000 +0100
++++ thymeleaf-thymeleaf-2.1.4.RELEASE.commons-ognl/src/main/java/org/thymeleaf/context/OGNLVariablesMapPropertyAccessor.java	2015-03-08 18:29:20.727026468 +0100
+@@ -22,9 +22,9 @@
+ 
+ import java.util.Map;
+ 
+-import ognl.MapPropertyAccessor;
+-import ognl.OgnlException;
+-import ognl.OgnlRuntime;
++import org.apache.commons.ognl.MapPropertyAccessor;
++import org.apache.commons.ognl.OgnlException;
++import org.apache.commons.ognl.OgnlRuntime;
+ import org.thymeleaf.exceptions.TemplateProcessingException;
+ 
+ /**
+@@ -34,7 +34,7 @@
+  * works exactly same like {@code MapPropertyAccessor}.
+  *
+  * @author Michal Kreuzman
+- * @see ognl.MapPropertyAccessor
++ * @see org.apache.commons.ognl.MapPropertyAccessor
+  * @since 2.0
+  */
+ final class OGNLVariablesMapPropertyAccessor extends MapPropertyAccessor {
+diff -Nru thymeleaf-thymeleaf-2.1.4.RELEASE/src/main/java/org/thymeleaf/standard/expression/OgnlVariableExpressionEvaluator.java thymeleaf-thymeleaf-2.1.4.RELEASE.commons-ognl/src/main/java/org/thymeleaf/standard/expression/OgnlVariableExpressionEvaluator.java
+--- thymeleaf-thymeleaf-2.1.4.RELEASE/src/main/java/org/thymeleaf/standard/expression/OgnlVariableExpressionEvaluator.java	2014-12-21 22:26:15.000000000 +0100
++++ thymeleaf-thymeleaf-2.1.4.RELEASE.commons-ognl/src/main/java/org/thymeleaf/standard/expression/OgnlVariableExpressionEvaluator.java	2015-03-08 18:35:30.935800270 +0100
+@@ -27,8 +27,8 @@
+ import javassist.CtClass;
+ import javassist.CtMethod;
+ import javassist.LoaderClassPath;
+-import ognl.Ognl;
+-import ognl.OgnlException;
++import org.apache.commons.ognl.Ognl;
++import org.apache.commons.ognl.OgnlException;
+ import org.slf4j.Logger;
+ import org.slf4j.LoggerFactory;
+ import org.thymeleaf.Configuration;
+@@ -90,7 +90,7 @@
+             }
+             
+             if (expressionTree == null) {
+-                expressionTree = ognl.Ognl.parseExpression(expression);
++                expressionTree = org.apache.commons.ognl.Ognl.parseExpression(expression);
+                 if (cache != null && null != expressionTree) {
+                     cache.put(OGNL_CACHE_PREFIX + expression, expressionTree);
+                 }
+@@ -111,7 +111,7 @@
+ 
+             setVariableRestrictions(expContext, evaluationRoot, contextVariables);
+ 
+-            final Object result = Ognl.getValue(expressionTree, contextVariables, evaluationRoot);
++            final Object result = org.apache.commons.ognl.Ognl.getValue(expressionTree, contextVariables, evaluationRoot);
+ 
+             if (!expContext.getPerformTypeConversion()) {
+                 return result;
+@@ -213,7 +213,7 @@
+             // We must load by class name here instead of "OgnlOps.class.getName()" because
+             // the latter would cause the class to be loaded and therefore it would not be
+             // possible to modify it.
+-            final CtClass ognlClass = pool.get("ognl.OgnlOps");
++            final CtClass ognlClass = pool.get("org.apache.commons.ognl.OgnlOps");
+             final CtClass fixClass = pool.get(OgnlVariableExpressionEvaluator.class.getName());
+             
+             final CtMethod ognlMethod = 
diff --git a/thymeleaf.spec b/thymeleaf.spec
new file mode 100644
index 0000000..fb2eb8b
--- /dev/null
+++ b/thymeleaf.spec
@@ -0,0 +1,98 @@
+%global namedreltag .RELEASE
+%global namedversion %{version}%{?namedreltag}
+Name:          thymeleaf
+Version:       2.1.4
+Release:       3%{?dist}
+Summary:       XML/XHTML/HTML5 template engine for Java
+# The Fedora Packaging Committee granted thymeleaf a bundling exception to carry
+# altered DTDs (... is fine, assuming the license allows it)
+# https://fedorahosted.org/fpc/ticket/516
+# W3C: src/main/resources/org/thymeleaf/dtd/standard/xhtml1-frameset.dtd
+#  src/main/resources/org/thymeleaf/dtd/standard/xhtml1-strict.dtd
+#  src/main/resources/org/thymeleaf/dtd/standard/xhtml1-transitional.dtd
+#  src/main/resources/org/thymeleaf/dtd/standard/xhtml-lat1.ent
+#  src/main/resources/org/thymeleaf/dtd/standard/xhtml-symbol.ent
+#  src/main/resources/org/thymeleaf/dtd/standard/xhtml-special.ent
+License:       ASL 2.0 and W3C
+URL:           http://www.thymeleaf.org/
+Source0:       https://github.com/thymeleaf/thymeleaf/archive/%{name}-%{namedversion}.tar.gz
+# from http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
+Source1:       W3C-license.txt
+# Replace ognl 3.0.8
+Patch0:        thymeleaf-2.1.4-commons-ognl.patch
+
+BuildRequires: maven-local
+BuildRequires: mvn(javax.servlet:javax.servlet-api)
+BuildRequires: mvn(net.sourceforge.nekohtml:nekohtml)
+BuildRequires: mvn(org.apache.commons:commons-ognl)
+BuildRequires: mvn(org.javassist:javassist)
+BuildRequires: mvn(org.slf4j:slf4j-api)
+BuildRequires: mvn(org.unbescape:unbescape)
+
+BuildArch:     noarch
+
+%description
+Thymeleaf is a Java library. It is an XML/XHTML/HTML5 template engine
+(extensible to other formats) that can work both in web and
+non-web environments. It is better suited for serving XHTML/HTML5 at the
+view layer of web applications, but it can process any XML file
+even in offline environments. 
+
+%package javadoc
+Summary:       Javadoc for %{name}
+
+%description javadoc
+This package contains javadoc for %{name}.
+
+%prep
+%setup -q -n %{name}-%{name}-%{namedversion}
+find -name "*.class" -delete
+find -name "*.jar" -print -delete
+
+%patch0 -p1
+
+%pom_remove_plugin :maven-gpg-plugin
+%pom_remove_plugin :maven-source-plugin
+%pom_xpath_remove "pom:plugin[pom:artifactId = 'maven-javadoc-plugin']/pom:executions"
+%pom_xpath_remove "pom:plugin[pom:artifactId = 'maven-javadoc-plugin']/pom:configuration/pom:reportOutputDirectory"
+
+%pom_xpath_set "pom:properties/pom:maven.compile.source" 1.6
+%pom_xpath_set "pom:properties/pom:maven.compile.target" 1.6
+
+# Default is US-ASCII
+%pom_xpath_set "pom:plugin[pom:artifactId = 'maven-compiler-plugin']/pom:configuration/pom:encoding" UTF-8
+%pom_xpath_set "pom:plugin[pom:artifactId = 'maven-resources-plugin']/pom:configuration/pom:encoding" UTF-8
+
+%pom_xpath_set "pom:dependency[pom:groupId = 'javax.servlet']/pom:version" 3.1.0
+%pom_xpath_set "pom:dependency[pom:groupId = 'javax.servlet']/pom:artifactId" javax.servlet-api
+
+chmod 644 ChangeLog.txt NOTICE.txt
+
+cp -p %{SOURCE1} .
+sed -i 's/\r//' W3C-license.txt
+
+%mvn_file : %{name}
+
+%build
+
+%mvn_build
+
+%install
+%mvn_install
+
+%files -f .mfiles
+%doc ChangeLog.txt CONTRIBUTING.markdown README.txt RELEASING.txt USAGE.txt
+%license LICENSE.txt NOTICE.txt W3C-license.txt
+
+%files javadoc -f .mfiles-javadoc
+%license LICENSE.txt NOTICE.txt W3C-license.txt
+
+%changelog
+* Thu Mar 19 2015 gil cattaneo <puntogil at libero.it> 2.1.4-3
+- add W3C license
+
+* Thu Mar 19 2015 gil cattaneo <puntogil at libero.it> 2.1.4-2
+- fix license tag
+
+* Sun Mar 08 2015 gil cattaneo <puntogil at libero.it> 2.1.4-1
+- initial rpm
-- 
cgit v0.10.2


	http://pkgs.fedoraproject.org/cgit/thymeleaf.git/commit/?h=master&id=364c4c5acd4077a1e3e05e14c8ced10516c4c087


More information about the scm-commits mailing list