Name: jodd Version: 3.8.0 Release: 1%{?dist} Summary: A set of Java tools and micro frameworks # Source files are without license headers https://github.com/oblac/jodd/issues/358 License: BSD URL: http://jodd.org/ Source0: https://github.com/oblac/jodd/archive/v%{version}/%{name}-%{version}.tar.gz # sh jodd-get-poms.sh Source1: jodd-%{version}-poms.tar.xz Source2: jodd-get-poms.sh # Add servlet 3.1 missing methods Patch0: jodd-3.8.0-port-jodd-servlet-to-servlet-api3.1.patch BuildRequires: maven-local BuildRequires: mvn(ch.qos.logback:logback-classic) BuildRequires: mvn(ch.qos.logback:logback-core) BuildRequires: mvn(com.h2database:h2) BuildRequires: mvn(com.sun.mail:javax.mail) BuildRequires: mvn(commons-logging:commons-logging) BuildRequires: mvn(javax.el:javax.el-api) BuildRequires: mvn(javax.mail:javax.mail-api) BuildRequires: mvn(javax.servlet:javax.servlet-api) BuildRequires: mvn(javax.servlet.jsp:jsp-api) BuildRequires: mvn(junit:junit) BuildRequires: mvn(mysql:mysql-connector-java) BuildRequires: mvn(org.apache.felix:maven-bundle-plugin) BuildRequires: mvn(org.apache.tomcat:tomcat-catalina) BuildRequires: mvn(org.glassfish.web:javax.servlet.jsp) BuildRequires: mvn(org.hsqldb:hsqldb) BuildRequires: mvn(org.powermock:powermock-api-mockito) BuildRequires: mvn(org.powermock:powermock-module-junit4) BuildRequires: mvn(org.slf4j:slf4j-api) BuildRequires: mvn(org.slf4j:slf4j-simple) BuildRequires: mvn(org.ow2.asm:asm) BuildRequires: mvn(postgresql:postgresql) BuildArch: noarch %description Jodd is lightweight Java frameworks and tools for building super web applications. Packed in only 1 Mb. Ingredients: IoC container, MVC framework, AOP engine, DB-object mapper, transaction manager, validation tool, HTML parsers, pages decorator, properties, BeanUtil, JDateTime, email, many utilities... and more. %package bean Summary: Jodd BeanUtil %description bean Jodd BeanUtil is fast and powerful bean manipulation library. %package core Summary: Jodd Core %description core Jodd Core tools and utilities, including type converters, JDateTime, cache etc. %package db Summary: Jodd DbOom %description db Jodd DB is efficient and thin database facade; DbOom is convenient database object mapper. %package decora Summary: Jodd Decora %description decora Jodd Decora is web decoration framework to help in creating sites consisting of pages based on templates. This gives a consistent look/feel, navigation and layout scheme. Decora intercepts requests, process the content and merges it with decorator to create a final page result. %package htmlstapler Summary: Jodd HtmlStapler %description htmlstapler Jodd HtmlStapler is a tool for automatic packaging of web resources included by HTML page: javascript and CSS files. Just by enabling HtmlStapler in your web application, all multiple resource (javascript and css) links will be automatically and transparently replaced by a single link(s) - without any user modification of HTML page or using of server-side technologies. %package http Summary: Jodd HTTP client %description http Jodd HTTP client is easy-to-use http client. %package joy Summary: Jodd Joy %description joy Jodd Joy is set of Jodd extensions that makes development of web applications even easier. %package json Summary: Jodd JSON %description json Jodd JSON parser. %package jtx Summary: Jodd JTX %description jtx Jodd JTX transaction manager. %package lagarto Summary: Jodd Lagarto %description lagarto Jodd Lagarto is fast and versatile all purpose HTML parser. Includes Jerry and CSSelly. %package log Summary: Jodd Log %description log Jodd Log is simple logging facade. %package madvoc Summary: Jodd Madvoc %description madvoc Jodd Madvoc is elegant web MVC framework that uses CoC and annotations in a pragmatic way to simplify web application development. %package mail Summary: Jodd Mail %description mail Jodd Mail is a little tool for sending and receiving emails. %package petite Summary: Jodd Petite %description petite Jodd Petite is slick and lightweight DI container that uses annotations and supports sufficient most of features offered by other containers. %package props Summary: Jodd Props %description props Jodd Props is super properties replacement, featuring: UTF8, sections, profiles, macros and more. %package proxetta Summary: Jodd Proxetta %description proxetta Jodd Proxetta is the fastest proxy creator with unique approach for defying pointcuts and advices. %package servlet Summary: Jodd Servlet %description servlet Jodd Servlet is set of web tools, including the nice tag library, wrappers and some filters. %package swingspy Summary: Jodd SwingSpy %description swingspy Jodd SwingSpy is standalone tool for exploring the swing UI components. %package upload Summary: Jodd Upload %description upload Jodd Upload is library for managing uploads. %package vtor Summary: Jodd VTor %description vtor Jodd VTor is focused validation framework for any Java object. %package javadoc Summary: Javadoc for %{name} %description javadoc This package contains javadoc for %{name}. %prep %setup -q -n %{name}-%{version} -a1 # Cleanup find -name '*.class' -print -delete find -name '*.jar' -print -delete find -name '*.rar' -print -delete find -name '*.zip' -print -delete %patch0 -p1 # Use system ASM rm -r %{name}-proxetta/src/main/java/jodd/asm5 find ./%{name}-proxetta -name "*.java" -exec sed -i "s/jodd.asm5/org.objectweb.asm/g" {} + %pom_add_dep org.ow2.asm:asm:5.0.3 %{name}-proxetta # This is a dummy POM added just to ease building in the RPM platforms cat > pom.xml << EOF 4.0.0 org.jodd jodd-parent pom Jodd - Parent %{version} Jodd Parent jodd-bean jodd-core jodd-db jodd-decora jodd-htmlstapler jodd-http jodd-joy jodd-json jodd-jtx jodd-lagarto jodd-log jodd-madvoc jodd-mail jodd-petite jodd-props jodd-proxetta jodd-servlet jodd-swingspy jodd-upload jodd-vtor org.apache.maven.plugins maven-javadoc-plugin 2.7 UTF-8 true true Jodd JavaDoc \${project.version}
Jodd JavaDocs
true \${basedir}/src/main/javadoc/jodd.css -Xdoclint:none http://docs.oracle.com/javase/8/docs/api/
org.apache.maven.plugins maven-javadoc-plugin 2.7 javadoc
EOF # Force glassfish apis %pom_change_dep -r javax.servlet: ::3.1.0 jodd-decora jodd-htmlstapler jodd-joy jodd-lagarto jodd-madvoc jodd-servlet %pom_change_dep -r javax.servlet.jsp: ::2.3.2-b01 jodd-htmlstapler jodd-joy jodd-lagarto jodd-madvoc jodd-servlet for m in bean \ core \ db \ decora \ htmlstapler \ http \ joy \ json \ jtx \ lagarto \ log \ madvoc \ mail \ petite \ props \ proxetta \ servlet \ swingspy \ upload \ vtor; do %pom_add_plugin org.apache.maven.plugins:maven-compiler-plugin:3.0 %{name}-${m} ' 1.8 1.8 UTF-8 ' # Add OSGi support %pom_xpath_inject "pom:project" "bundle" %{name}-${m} %pom_add_plugin org.apache.felix:maven-bundle-plugin:2.3.7 %{name}-${m} " true \${project.artifactId} \${project.version} bundle-manifest process-classes manifest " # fix test deps %pom_add_dep junit:junit:4.12:test %{name}-${m} done %pom_add_plugin org.apache.maven.plugins:maven-jar-plugin:2.4 %{name}-core " test-jar " %pom_add_dep org.jodd:jodd-core:'${project.version}':test %{name}-bean "test-jar" for m in props proxetta; do %pom_add_dep org.jodd:jodd-bean:'${project.version}':test %{name}-${m} done %pom_add_dep org.slf4j:slf4j-simple:1.7.2:test %{name}-log %pom_add_dep com.h2database:h2:1.1.111:test %{name}-db %pom_add_dep mysql:mysql-connector-java:5.1.37:test %{name}-db %pom_add_dep postgresql:postgresql:9.4-1201-jdbc41:test %{name}-db %pom_add_dep org.apache.tomcat:tomcat-catalina:7.0.59:test %{name}-http # ClassNotFoundException: org.apache.jasper.servlet.JspServlet %pom_add_dep org.glassfish.web:javax.servlet.jsp:2.3.3-b02:test %{name}-http %pom_add_dep javax.el:javax.el-api:3.0.0:test %{name}-servlet for m in db joy; do %pom_add_dep org.hsqldb:hsqldb:2.2.9:test %{name}-${m} done for m in joy madvoc; do %pom_add_dep org.jodd:jodd-http:'${project.version}':test %{name}-${m} done for m in joy madvoc petite servlet vtor; do %pom_add_dep org.mockito:mockito-all:1.9.5:test %{name}-${m} done for m in log decora; do %pom_add_dep org.mockito:mockito-all:1.9.5:test %{name}-${m} %pom_add_dep org.powermock:powermock-api-mockito:1.6.4:test %{name}-${m} %pom_add_dep org.powermock:powermock-module-junit4:1.6.4:test %{name}-${m} done %pom_add_dep ch.qos.logback:logback-core:1.1.7:test %{name}-log %pom_add_dep ch.qos.logback:logback-classic:1.1.7:test %{name}-log # com.icegreen:greenmail:1.5.2 https://bugzilla.redhat.com/show_bug.cgi?id=1368521 rm jodd-mail/src/test/java/jodd/mail/EmailGreenTest.java # Remove test failure # java.lang.NullPointerException: null rm %{name}-core/src/test/java/jodd/util/ClassLoaderUtilTest.java rm %{name}-http/src/test/java/jodd/JoddHttpTest.java # java.lang.AssertionError: expected:<-1585535100000> but was:<-1585531500000> rm %{name}-core/src/test/java/jodd/datetime/JDateTimeTest.java # java.lang.IllegalArgumentException: Can't instantiate context-class # org.apache.catalina.core.StandardContext for host StandardEngine[Tomcat].StandardHost[localhost] # Use org.apache.tomcat:tomcat-catalina:7.0.47 # org.apache.tomcat.embed:tomcat-embed-core:7.0.47 # org.apache.tomcat.embed:tomcat-embed-jasper:7.0.47 # org.apache.tomcat.embed:tomcat-embed-logging-juli:7.0.47 # org.apache.tomcat.embed:tomcat-embed-logging-log4j:7.0.47 rm %{name}-http/src/test/java/jodd/http/EncodingTest.java \ %{name}-http/src/test/java/jodd/http/HttpBrowserTest.java \ %{name}-http/src/test/java/jodd/http/HttpRedirectTest.java # Circular dependecy cycle jodd-proxetta <--> jodd-petite rm -r %{name}-proxetta/src/test/java/jodd/proxetta/petite sed -i '/PETITE/d' jodd-proxetta/src/test/java/jodd/JoddProxettaTest.java sed -i '/MAIL/d' jodd-proxetta/src/test/java/jodd/JoddProxettaTest.java sed -i '/PROPS/d' jodd-proxetta/src/test/java/jodd/JoddProxettaTest.java sed -i '/SERVLET/d' jodd-proxetta/src/test/java/jodd/JoddProxettaTest.java sed -i '/UPLOAD/d' jodd-proxetta/src/test/java/jodd/JoddProxettaTest.java %mvn_package :%{name}-core::tests: %{name}-core %mvn_package :%{name}-parent __noinstall %build %mvn_build -s -- -Dproject.build.sourceEncoding=UTF-8 %install %mvn_install %files bean -f .mfiles-%{name}-bean %files core -f .mfiles-%{name}-core %doc CONTRIBUTING.md README.md TODO.md %license COPYING LICENSE %files db -f .mfiles-%{name}-db %files decora -f .mfiles-%{name}-decora %files htmlstapler -f .mfiles-%{name}-htmlstapler %files http -f .mfiles-%{name}-http %files joy -f .mfiles-%{name}-joy %files json -f .mfiles-%{name}-json %files jtx -f .mfiles-%{name}-jtx %files lagarto -f .mfiles-%{name}-lagarto %files log -f .mfiles-%{name}-log %license COPYING LICENSE %files madvoc -f .mfiles-%{name}-madvoc %files mail -f .mfiles-%{name}-mail %files petite -f .mfiles-%{name}-petite %files props -f .mfiles-%{name}-props %files proxetta -f .mfiles-%{name}-proxetta %files servlet -f .mfiles-%{name}-servlet %files swingspy -f .mfiles-%{name}-swingspy %files upload -f .mfiles-%{name}-upload %files vtor -f .mfiles-%{name}-vtor %files javadoc -f .mfiles-javadoc %license COPYING LICENSE %changelog * Thu Nov 10 2016 gil cattaneo 3.8.0-1 - update to 3.8.0 * Thu Dec 24 2015 gil cattaneo 3.6.7-1 - update to 3.6.7 * Tue Aug 04 2015 gil cattaneo 3.6.6-1 - initial rpm