diff options
author | Karl Trygve Kalleberg <karltk@gentoo.org> | 2004-04-27 22:30:51 +0000 |
---|---|---|
committer | Karl Trygve Kalleberg <karltk@gentoo.org> | 2004-04-27 22:30:51 +0000 |
commit | 48b216cf22632c58f998cd6b230ff6b52d72eee8 (patch) | |
tree | e53cee622b14d4ddc877ba6b741fb13f2c921131 /dev-java/mockobjects | |
parent | add inherit flag-o-matic (diff) | |
download | gentoo-2-48b216cf22632c58f998cd6b230ff6b52d72eee8.tar.gz gentoo-2-48b216cf22632c58f998cd6b230ff6b52d72eee8.tar.bz2 gentoo-2-48b216cf22632c58f998cd6b230ff6b52d72eee8.zip |
Initial import. Fixes #45992.
Diffstat (limited to 'dev-java/mockobjects')
-rw-r--r-- | dev-java/mockobjects/ChangeLog | 8 | ||||
-rw-r--r-- | dev-java/mockobjects/Manifest | 4 | ||||
-rw-r--r-- | dev-java/mockobjects/files/build.xml-0.09 | 427 | ||||
-rw-r--r-- | dev-java/mockobjects/files/digest-mockobjects-0.09 | 1 | ||||
-rw-r--r-- | dev-java/mockobjects/metadata.xml | 14 | ||||
-rw-r--r-- | dev-java/mockobjects/mockobjects-0.09.ebuild | 44 |
6 files changed, 498 insertions, 0 deletions
diff --git a/dev-java/mockobjects/ChangeLog b/dev-java/mockobjects/ChangeLog new file mode 100644 index 000000000000..e29256e1daba --- /dev/null +++ b/dev-java/mockobjects/ChangeLog @@ -0,0 +1,8 @@ +# ChangeLog for dev-java/mockobjects +# Copyright 2000-2004 Gentoo Technologies, Inc.; Distributed unde the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/dev-java/mockobjects/ChangeLog,v 1.1 2004/04/27 22:30:51 karltk Exp $ + +*mockobjects-0.09 (27 Apr 2004) + + 27 Apr 2004; Karl Trygve Kalleberg <karltk@gentoo.org> mockobjects-0.09.ebuild: + Initial import. Ebuild submitted by myself. diff --git a/dev-java/mockobjects/Manifest b/dev-java/mockobjects/Manifest new file mode 100644 index 000000000000..3efeffc19821 --- /dev/null +++ b/dev-java/mockobjects/Manifest @@ -0,0 +1,4 @@ +MD5 f0dc973a40dd0ac68d78c762d1843f26 mockobjects-0.09.ebuild 503 +MD5 24ba13ad7539c0ad85ee3ed8d14ffe71 ChangeLog 289 +MD5 0637a933ecb6e8cedfc4ddfcf3491728 metadata.xml 310 +MD5 c83c1a17a4d055ee848accd6747b9094 files/digest-mockobjects-0.09 80 diff --git a/dev-java/mockobjects/files/build.xml-0.09 b/dev-java/mockobjects/files/build.xml-0.09 new file mode 100644 index 000000000000..511d8757353b --- /dev/null +++ b/dev-java/mockobjects/files/build.xml-0.09 @@ -0,0 +1,427 @@ +<?xml version="1.0"?> +<project name="mockobjects" default="jar" basedir="."> + + <property file="${user.home}/build.properties" /> + <property file="build.properties" /> + + <property name="out.dir" value="out" /> + <property name="out.doc.dir" value="${out.dir}/doc" /> + <property name="out.javadoc.dir" value="${out.doc.dir}/javadoc" /> + <property name="core.classes" value="${out.dir}/core/classes" /> + <property name="jdk.classes" value="${out.dir}/jdk/classes" /> + <property name="j2ee.classes" value="${out.dir}/j2ee/classes" /> + <property name="httpclient.classes" value="${out.dir}/ext/httpclient/classes" /> + <property name="out.site.dir" value="${out.dir}/site" /> + <property name="out.src.dir" value="${out.dir}/src" /> + <property name="out.src.examples.dir" value="${out.src.dir}/examples" /> + <property name="out.xdoc.doc.dir" value="${out.dir}/xdoc/doc" /> + <property name="out.xdoc.site.dir" value="${out.dir}/xdoc/site" /> + <property name="conf.dir" value="conf" /> + + <target name="project-properties"> + <property name="project.fullname" value="Mock Objects" /> + <property name="project.version" value="0.09" /> + <property name="year" value="2002" /> + <property name="debug" value="on" /> + <property name="optimize" value="off" /> + <property name="deprecation" value="off" /> + </target> + + <target name="source-locations"> + <property name="src.dir" value="src" /> + <property name="src.core.dir" value="${src.dir}/core" /> + <property name="src.j2ee.dir" value="${src.dir}/j2ee" /> + <property name="src.jdk.dir" value="${src.dir}/jdk" /> + <property name="src.httpclient.dir" value="${src.dir}/extensions" /> + <property name="src.examples.dir" value="${src.dir}/examples" /> + <property name="doc.dir" value="doc" /> + <property name="xdoc.dir" value="${doc.dir}/xdocs" /> + <property name="skin.dir" value="${doc.dir}/skins" /> + <property name="lib.dir" value="lib" /> + <property name="j2ee.lib" value="lib/j2ee.jar" /> + </target> + + <target name="deliverable-names" depends="project-properties"> + <property name="dist.dir" value="dist" /> + <property name="jar.base.name" value="${ant.project.name}-${project.version}" /> + <property name="alt.jar.base.name" value="alt-${project.version}" /> + <property name="sources.zip.name" value="${ant.project.name}-src" /> + <property name="site.name" value="${ant.project.name}-website" /> + <property name="javadoc.name" value="${ant.project.name}-javadoc" /> + <property name="project.zip.name" value="${ant.project.name}-${project.version}" /> + </target> + + <target name="useful-file-patterns"> + <patternset id="java.src.files"> + <include name="**/*.java" /> + </patternset> + </target> + + <target name="check-availabilities" depends="source-locations"> + + <path id="lib.classpath"> + <fileset dir="${lib.dir}"> + <include name="*.jar" /> + <exclude name="j2ee.jar" /> + </fileset> + <pathelement location="${j2ee.lib}"/> + </path> + + <available property="jdk.version" value="1.2" classname="java.lang.ThreadLocal" /> + <available property="jdk.version" value="1.3" classname="java.lang.StrictMath" /> + <available property="jdk.version" value="1.4" classname="java.lang.CharSequence" /> + <available property="j2ee.version" value="1.2" + classpathref="lib.classpath" + classname="javax.servlet.Servlet" /> + <available property="j2ee.version" value="1.3" + classpathref="lib.classpath" + classname="javax.servlet.Filter" /> + <available property="httpclient" value="true" + classpathref="lib.classpath" + classname="org.apache.commons.httpclient.HttpClient" /> + + <property name="jar.j2ee.name" value="" /> + + <available property="jar.j2ee.name" + value="_j2ee${j2ee.version}" + classpathref="lib.classpath" + classname="javax.servlet.Servlet" /> + </target> + + <target name="call-me-first" + depends="project-properties, useful-file-patterns, check-availabilities"> + + <tstamp /> + + <echo message="--------- ${project.fullname} ${project.version} ---------" /> + <echo message="" /> + <echo message="java.class.path = ${java.class.path}" /> + <echo message="" /> + <echo message="java.home = ${java.home}" /> + <echo message="user.home = ${user.home}" /> + <echo message="ant.home = ${ant.home}" /> + <echo message="" /> + + <filter token="version" value="${project.version}" /> + <filter token="year" value="${year}" /> + <filter token="today" value="${TODAY}" /> + </target> + + <target name="compile-core" depends="call-me-first" + description="Compile mock objects core"> + + <mkdir dir="${core.classes}" /> + <javac destdir="${core.classes}" + debug="${debug}" + verbose="false" + optimize="${optimize}" + srcdir="${src.core.dir}"> + <classpath> + <path refid="lib.classpath" /> + <pathelement path="${java.class.path}" /> + </classpath> + </javac> + + </target> + + <target name="compile-jdk" depends="compile-core" + description="Compile all the java files for included libraries"> + + <mkdir dir="${jdk.classes}" /> + <javac destdir="${jdk.classes}" debug="${debug}" verbose="false" + optimize="${optimize}"> + <src path="${src.jdk.dir}/${jdk.version}" /> + <src path="${src.jdk.dir}/common" /> + <classpath> + <path refid="lib.classpath" /> + <pathelement path="${java.class.path}" /> + <pathelement path="${core.classes}" /> + </classpath> + </javac> + </target> + + <target name="compile-j2ee" + depends="compile-jdk" + if="j2ee.version" + description="Compile all the java files for included libraries"> + + <mkdir dir="${j2ee.classes}" /> + + <javac destdir="${j2ee.classes}" + debug="${debug}" + deprecation="${deprecation}" + verbose="false" + optimize="${optimize}"> + + <src path="${src.j2ee.dir}/common" /> + <src path="${src.j2ee.dir}/${j2ee.version}" /> + + <classpath> + <path refid="lib.classpath" /> + <pathelement path="${java.class.path}" /> + <pathelement path="${core.classes}" /> + <pathelement path="${jdk.classes}" /> + </classpath> + </javac> + </target> + + <target name="junit" + depends="call-me-first, compile-j2ee" + description="run the junit tests"> + + <mkdir dir="${core.classes}" /> + <mkdir dir="${jdk.classes}" /> + <mkdir dir="${j2ee.classes}" /> + + <junit fork="yes" haltonfailure="yes"> + <classpath> + <path refid="lib.classpath" /> + <pathelement location="${j2ee.classes}" /> + <pathelement location="${jdk.classes}" /> + <pathelement location="${core.classes}" /> + <pathelement path="${java.class.path}" /> + </classpath> + + <formatter type="plain" usefile="false" /> + + <batchtest> + <fileset dir="${core.classes}"> + <include name="test/**Test*.class" /> + <exclude name="test/**Test*$*.class" /> + <exclude name="**/AllTests.class" /> + </fileset> + + <fileset dir="${jdk.classes}"> + <include name="test/**Test*.class" /> + <exclude name="test/**Test*$*.class" /> + <exclude name="**/AllTests.class" /> + </fileset> + + <fileset dir="${j2ee.classes}"> + <include name="test/**Test*.class" /> + <exclude name="test/**Test*$*.class" /> + <exclude name="**/AllTests.class" /> + </fileset> + </batchtest> + </junit> + </target> + + <target name="compile-ext-httpclient" + depends="compile-jdk" + if="httpclient" + description="Compile all the java files for included libraries"> + <mkdir dir="${httpclient.classes}" /> + + <javac destdir="${httpclient.classes}" debug="${debug}" + deprecation="${deprecation}" verbose="false" + optimize="${optimize}"> + + <src path="${src.httpclient.dir}"/> + <include name="com/mockobjects/apache/**"/> + <include name="alt/org/apache/**"/> + + <classpath> + <path refid="lib.classpath" /> + <pathelement path="${java.class.path}" /> + <pathelement path="${core.classes}" /> + <pathelement path="${jdk.classes}" /> + </classpath> + </javac> + </target> + + <target name="copy-nonjava-files" + depends="call-me-first"> + </target> + + <target name="jar" + depends="jar-core, jar-jdk, jar-j2ee"/> + + <target name="jar-core" + depends="compile-core, deliverable-names" + description="Generate core mockobjects jar"> + <jar jarfile="${out.dir}/${ant.project.name}-core-${project.version}.jar" + manifest="${conf.dir}/manifest"> + <fileset dir="${core.classes}"> + <exclude name="test/**"/> + </fileset> + </jar> + </target> + + <target name="jar-jdk" + depends="deliverable-names" + description="Generate jdk mockobjects jar"> + <antcall target="_inner-jar"> + <param name="jarfile.name" + value="${out.dir}/${ant.project.name}-jdk${jdk.version}-${project.version}.jar" /> + <param name="alt.jarfile.name" + value="${out.dir}/${ant.project.name}-alt-jdk${jdk.version}-${project.version}.jar" /> + <param name="classes.dir" value="${jdk.classes}" /> + </antcall> + </target> + + <target name="jar-j2ee" + depends="deliverable-names" + if="j2ee.version" + description="Generate j2ee mockobjects jar"> + <antcall target="_inner-jar"> + <param name="jarfile.name" + value="${out.dir}/${ant.project.name}-jdk${jdk.version}-j2ee${j2ee.version}-${project.version}.jar" /> + <param name="alt.jarfile.name" + value="${out.dir}/${ant.project.name}-alt-jdk${jdk.version}-j2ee${j2ee.version}-${project.version}.jar" /> + <param name="classes.dir" value="${j2ee.classes}" /> + </antcall> + </target> + + <target name="_inner-jar" + depends="deliverable-names" > + <!-- requires jarfile.name, alt.jarfile.name, classes.dir --> + <jar jarfile="${jarfile.name}" + manifest="${conf.dir}/manifest"> + <fileset dir="${classes.dir}"> + <exclude name="alt/**"/> + <exclude name="test/**"/> + </fileset> + </jar> + <jar jarfile="${alt.jarfile.name}" + manifest="${conf.dir}/manifest"> + <fileset dir="${classes.dir}"> + <include name="alt/**"/> + <exclude name="test/**"/> + </fileset> + </jar> + </target> + + <target name="jar-ext-httpclient" + depends="compile-ext-httpclient" + description="Generate extension mockobjects jar"> + <jar jarfile="${out.dir}/${ant.project.name}-httpclient.jar" + manifest="${conf.dir}/manifest"> + <fileset dir="${httpclient.classes}"> + <exclude name="alt/**"/> + </fileset> + </jar> + <jar jarfile="${out.dir}/alt-httpclient.jar" + manifest="${conf.dir}/manifest"> + <fileset dir="${httpclient.classes}"> + <include name="alt/**"/> + </fileset> + </jar> + </target> + + <target name="javadoc" + depends="call-me-first, deliverable-names" + unless="javadoc.notrequired" + description="Generate the javadoc for the current version"> + <javadoc packagenames="com.mockobjects.*,alt.*" + destdir="${out.javadoc.dir}" + author="true" + public="true" version="true" use="true" + windowtitle="${project.fullname} ${project.version}" + doctitle="${project.fullname} ${project.version}" + bottom="Copyright &copy; ${year} Mock Objects. All Rights Reserved."> + + <classpath> + <path refid="lib.classpath" /> + <pathelement path="${java.class.path}" /> + </classpath> + <sourcepath> + <pathelement path="${src.dir}/core"/> + <pathelement path="${src.dir}/jdk/common"/> + <pathelement path="${src.dir}/jdk/1.3"/> + <pathelement path="${src.dir}/j2ee/common"/> + <pathelement path="${src.dir}/j2ee/1.3"/> + </sourcepath> + <group title="Core" packages="com.mockobjects"/> + <group title="JDK" packages="com.mockobjects.*"/> + <group title="J2ee"> + <package name="com.mockobjects.mail*"/> + <package name="com.mockobjects.servlet"/> + <package name="com.mockobjects.jms"/> + </group> + <group title="Utils" packages="com.mockobjects.util"/> + <group title="Alternative" packages="alt.*"/> + <group title="Tests" packages="test.mockobjects"/> + </javadoc> + </target> + + <target name="clean-compiled" + description="Clean up compiled class files" + depends="call-me-first" > + <delete quiet="true"> + <fileset dir="${core.classes}" /> + <fileset dir="${jdk.classes}" /> + <fileset dir="${j2ee.classes}" /> + </delete> + + </target> + + <target description="clean up all generated files" + name="clean" + depends="call-me-first"> + <delete> + <fileset dir="."> + <include name="**/*.bak" /> + </fileset> + </delete> + + <delete> + <fileset dir="." includes="**/*~" defaultexcludes="no" /> + </delete> + + <delete dir="${out.dir}" /> + </target> + + <target name="prepare-dist" + depends="jar,javadoc"> + <mkdir dir="${dist.dir}" /> + </target> + + <target name="zip-java-sources" + depends="deliverable-names"> + <zip zipfile="${out.dir}/${sources.zip.name}.zip" basedir="${src.dir}" /> + </target> + + <target description="Generate the distributables" + name="dist" + depends="call-me-first, prepare-dist, zip-java-sources"> + <zip zipfile="${dist.dir}/${ant.project.name}${project.version}.zip"> + <zipfileset dir="${out.dir}" prefix="lib"> + <include name="*.jar" /> + </zipfileset> + + <zipfileset dir="${out.dir}" prefix="src"> + <include name="${ant.project.name}-${project.version}-src.zip" /> + </zipfileset> + </zip> + </target> + +<!-- + ======================================================================== + Do it all + ======================================================================== + --> + <target name="all" + depends="clean, jar, javadoc, dist" + description="do it all (clean, jar, javadoc, dist)"> + </target> + + <target name="src" depends="clean,prepare-dist"> + <property name="dist.name" + value="${ant.project.name}-${project.version}"/> + <copy todir="${dist.dir}/${dist.name}"> + <fileset dir="${basedir}"> + <include name="${src.dir}/**"/> + <include name="build.xml"/> + <include name="${lib.dir}/**"/> + <include name="${conf.dir}/**"/> + </fileset> + </copy> + <tar tarfile="${dist.name}-src.tar" basedir="${dist.dir}"> + </tar> + <gzip zipfile="${dist.name}-src.tgz" + src="${dist.name}-src.tar" /> + <delete file="${dist.name}-src.tar" /> + </target> + +</project> + diff --git a/dev-java/mockobjects/files/digest-mockobjects-0.09 b/dev-java/mockobjects/files/digest-mockobjects-0.09 new file mode 100644 index 000000000000..685fa5f49337 --- /dev/null +++ b/dev-java/mockobjects/files/digest-mockobjects-0.09 @@ -0,0 +1 @@ +MD5 7303d44625729f914c7b93296ba72d9d mockobjects-java-0.09-gentoo.tar.bz2 98965 diff --git a/dev-java/mockobjects/metadata.xml b/dev-java/mockobjects/metadata.xml new file mode 100644 index 000000000000..f5e039ea7f4b --- /dev/null +++ b/dev-java/mockobjects/metadata.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> + +<pkgmetadata> +<herd>no-herd</herd> +<maintainer> + <email>karltk@gentoo.org</email> + <description>Primary maintainer</description> +</maintainer> + +<longdescription> + +</longdescription> +</pkgmetadata> diff --git a/dev-java/mockobjects/mockobjects-0.09.ebuild b/dev-java/mockobjects/mockobjects-0.09.ebuild new file mode 100644 index 000000000000..5299d604d655 --- /dev/null +++ b/dev-java/mockobjects/mockobjects-0.09.ebuild @@ -0,0 +1,44 @@ +# Copyright 1999-2004 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-java/mockobjects/mockobjects-0.09.ebuild,v 1.1 2004/04/27 22:30:51 karltk Exp $ + +inherit java-pkg + +DESCRIPTION="Test-first development process for building object-oriented software" +HOMEPAGE="http://mockobjects.sf.net" +SRC_URI="http://dev.gentoo.org/~karltk/java/distfiles/mockobjects-java-${PV}-gentoo.tar.bz2" +LICENSE="Apache-1.1" +SLOT="0" +KEYWORDS="~x86" +IUSE="doc junit jikes" +DEPEND="=dev-java/junit-3.8*" +RDEPEND="" +S=${WORKDIR}/mockobjects-java-${PV} + +src_unpack() { + unpack ${A} + cd ${S} + cp ${FILESDIR}/build.xml-${PV} build.xml || die + ( + cd lib + java-pkg_jar-from junit + ) + mkdir -p out/jdk/classes +} + +src_compile() { + # karltk: add jikes support soon + ant jar || die "failed to build jar" + if use doc ; then + ant javadoc || die "failed to create javadoc" + fi + if use junit ; then + ant junit || die "failed to run junit" + fi +} + +src_install() { + java-pkg_dojar out/*.jar + dodoc doc/README + dohtml -r out/doc/javadoc/* +} |