Skip to content

Commit

Permalink
Build for widgets module (#15544)
Browse files Browse the repository at this point in the history
Change-Id: I5bccb4047f2f92ec0025da6198a556e5434d5764
  • Loading branch information
Artur- committed Jan 11, 2015
1 parent 44d34f5 commit b16e3db
Show file tree
Hide file tree
Showing 2 changed files with 175 additions and 0 deletions.
124 changes: 124 additions & 0 deletions widgets/build.xml
@@ -0,0 +1,124 @@
<?xml version="1.0"?>

<project name="vaadin-widgets" basedir="." default="publish-local" xmlns:ivy="antlib:org.apache.ivy.ant">
<description>
Widgets package for using Vaadin widgets with GWT 2.7+
</description>
<include file="../common.xml" as="common" />
<include file="../build.xml" as="vaadin" />
<include file="../gwt-files.xml" as="gwtfiles" />

<!-- global properties -->
<property name="module.name" value="vaadin-widgets" />
<property name="module.symbolic" value="com.vaadin.widgets" />
<property name="result.dir" value="result" />
<property name="result.src" value="${result.dir}/src" />
<property name="result.deps" value="${result.dir}/deps" />

<path id="classpath.compile.custom">
<fileset file="${gwt.user.jar}" />
<fileset file="${gwt.dev.jar}" />
</path>
<path id="classpath.test.custom" />

<union id="jar.includes">

</union>

<target name="dependencies">
<antcall target="common.dependencies" />
</target>

<target name="copysrc" depends="dependencies">
<delete dir="${result.deps}" />

<ivy:resolve transitive="false" type="jar" conf="build" />
<ivy:cachepath pathid="vaadin.jars" />
<ivy:resolve transitive="false" type="jar" conf="build-provided" />
<ivy:cachepath pathid="compile.deps" />
<unjar dest="${result.deps}">
<path refid="vaadin.jars" />
</unjar>

<copy todir="${result.src}">
<fileset dir="src" />
<fileset dir="${result.deps}">
<include name="com/vaadin/*.gwt.xml" />
<include name="com/vaadin/client/BrowserInfo.java" />
<include name="com/vaadin/client/DeferredWorker.java" />
<include name="com/vaadin/client/Profiler.java" />
<include name="com/vaadin/client/StyleConstants.java" />
<include name="com/vaadin/client/WidgetUtil.java" />
<include name="com/vaadin/client/data/**/*.java" />
<include name="com/vaadin/client/widget/**/*.java" />
<include name="com/vaadin/client/Focusable.java" />
<include name="com/vaadin/client/widgets/*.java" />
<include name="com/vaadin/client/renderers/*.java" />
<include name="com/vaadin/client/ui/SubPartAware.java" />
<include name="com/vaadin/client/ui/VProgressBar.java" />
<include name="com/vaadin/client/VSchedulerImpl.java" />

<include name="com/vaadin/shared/ui/grid/*.java" />
<include name="com/vaadin/shared/ui/grid/**/*.java" />
<include name="com/vaadin/shared/util/SharedUtil.java" />
<include name="com/vaadin/shared/VBrowserDetails.java" />
<include name="com/vaadin/shared/data/sort/SortDirection.java" />

<include name="com/vaadin/sass/linker/*.java" />

<exclude name="com/vaadin/shared/**/*Rpc.java" />
<exclude name="com/vaadin/shared/**/*State.java" />
</fileset>
</copy>

<mkdir dir="${result.src}/com/vaadin/themes" />
<copy todir="${result.src}/com/vaadin/themes/valo">
<fileset dir="${result.deps}/VAADIN/themes/valo" />
</copy>
<copy todir="${result.src}/com/vaadin/themes/base">
<fileset dir="${result.deps}/VAADIN/themes/base" />
</copy>
</target>
<target name="compile" description="Compiles the module" depends="dependencies,copysrc">
<property name="classes" location="${result.dir}/classes" />
<mkdir dir="${classes}" />

<javac destdir="${classes}" source="${vaadin.java.version}" target="${vaadin.java.version}" debug="true" encoding="UTF-8" includeantruntime="false">
<src path="${result.src}" />
<classpath refid="classpath.compile.custom" />
<classpath refid="compile.deps" />
</javac>
</target>

<target name="jar" depends="compile">
<property name="jar.file" location="${result.dir}/lib/${module.name}-${vaadin.version}.jar" />
<antcall target="common.jar">
<param name="src" value="${result.dir}/src" />
<reference refid="jar.includes" torefid="extra.jar.includes" />
</antcall>
</target>

<target name="publish-local" depends="jar">
<antcall target="common.sources.jar">
<reference torefid="extra.jar.includes" refid="jar.includes" />
</antcall>
<antcall target="common.javadoc.jar" />

<antcall target="common.publish-local" />
</target>

<target name="clean">
<antcall target="common.clean" />
</target>

<target name="checkstyle">
<antcall target="common.checkstyle">
<param name="cs.src" location="src" />
</antcall>
</target>

<target name="test" depends="checkstyle">
<!-- <antcall target="common.test.run" />-->
</target>

</project>
51 changes: 51 additions & 0 deletions widgets/ivy.xml
@@ -0,0 +1,51 @@
<?xml version="1.0" encoding="UTF-8"?>
<ivy-module version="2.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd"
xmlns:m="http://ant.apache.org/ivy/maven">

<info organisation="com.vaadin" module="vaadin-widgets"
revision="${vaadin.version}" />

<configurations>
<conf name="build" />
<conf name="build-provided" />
<conf name="ide" visibility="private" />
<conf name="test" />
</configurations>
<publications>
<artifact type="jar" ext="jar" />
<artifact type="source" ext="jar" m:classifier="sources" />
<artifact type="javadoc" ext="jar" m:classifier="javadoc" />
<artifact type="pom" ext="pom" />
</publications>
<dependencies defaultconf="build" defaultconfmapping="build,ide->default">
<!-- API DEPENDENCIES -->

<!-- LIBRARY DEPENDENCIES (compile time) -->
<!-- Project modules -->
<dependency org="com.vaadin" name="vaadin-shared"
rev="${vaadin.version}" conf="build,test->build">
<exclude type="pom" conf="test" />
</dependency>
<dependency org="com.vaadin" name="vaadin-client"
rev="${vaadin.version}" conf="build,test->build">
<exclude type="pom" conf="test" />
</dependency>
<dependency org="com.vaadin" name="vaadin-client-compiler"
rev="${vaadin.version}" conf="build,test->build">
<exclude type="pom" conf="test" />
</dependency>
<dependency org="com.vaadin" name="vaadin-themes"
rev="${vaadin.version}" conf="build,test->build">
<exclude type="pom" conf="test" />
</dependency>
<dependency org="com.vaadin" name="vaadin-sass-compiler"
rev="${vaadin.sass.version}"
conf="build-provided->default" />
<dependency org="junit" name="junit" rev="4.11"
conf="test->default" />

</dependencies>

</ivy-module>

0 comments on commit b16e3db

Please sign in to comment.