updating to build against new harness and to use newer PMD version 3.1

git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@3505 51baf565-9d33-0410-a72c-fc3788e3496d
This commit is contained in:
Radim Kubacki
2005-05-26 20:26:59 +00:00
parent 2eb65c2e9a
commit 43c6bee9d2
12 changed files with 80 additions and 91 deletions

View File

@@ -1,4 +1,4 @@
.nbattrs
.nbintdb
pmdsuite.properties
build
build.ant.properties

View File

@@ -1,34 +1,20 @@
<project basedir="." default="nbm" name="PMD netbeans module">
<property name="pmd.jar" value="pmd-2.1.jar"/>
<property file="nbproject/suite-locator.properties"/>
<property file="${suite.properties}"/>
<fail unless="netbeans.dest.dir">You must set suite.properties to a file defining netbeans.dest.dir</fail>
<import file="${harness.dir}/build.xml"/>
<property name="pmd.jar" value="pmd-3.1.jar"/>
<property name="VERSION" value="1.0"/>
<property file="build.ant.properties"/>
<property name="nbm.homepage" value="http://pmd.sourceforge.net/"/>
<property name="dist.base" value="www.netbeans.org/example"/> <!-- XXX what should be here? -->
<property name="nbm.module.author" value="Ole-Martin Mørk and Gunnlaugur Þór Briem"/>
<property name="license.file" value="LICENSE.txt"/>
<property name="keystore" value="${user.home}/.pmdkeystore"/>
<import file="../nbbuild/module-scripts/projectized.xml"/>
<target name="files-init" depends="basic-init">
<patternset id="module.files">
<include name="${module.jar}"/>
<include name="${javahelp.jar}" if="has.javahelp"/>
<include name="${nb.system.dir}/Modules/${code.name.base.dashes}.xml"/>
<include name="${nb.modules.dir}/ext/${pmd.jar}"/>
<include name="${nb.modules.dir}/ext/saxpath-1.0-fcs.jar"/>
<include name="${nb.modules.dir}/ext/jakarta-oro-2.0.jar"/>
<include name="${nb.modules.dir}/ext/jaxen-core-1.0-fcs.jar"/>
</patternset>
</target>
<target name="netbeans-extra" depends="init">
<mkdir dir="${netbeans.dest.dir}/${cluster.dir}/${nb.modules.dir}/ext"/>
<copy todir="${netbeans.dest.dir}/${cluster.dir}/${nb.modules.dir}/ext">
<mkdir dir="${netbeans.dest.dir}/${cluster.dir}/modules/ext"/>
<copy todir="${netbeans.dest.dir}/${cluster.dir}/modules/ext">
<fileset dir="lib">
<include name="${pmd.jar}"/>
<include name="saxpath-1.0-fcs.jar"/>
@@ -49,7 +35,6 @@
<include name="lib/saxpath-1.0-fcs.jar"/>
<include name="lib/jaxen-core-1.0-fcs.jar"/>
<include name="lib/jakarta-oro-2.0.jar"/>
<exclude name="**/.nbattrs"/>
</zipfileset>
<zipfileset dir="." fullpath="pmd.nbm" includes="build/pmd.nbm"/>
</zip>

View File

@@ -1,7 +1,11 @@
---++ BUILDING
Cluster build harness is required to build the PMD plugin for NetBeans IDE.
Get it from http://wiki.java.net/bin/view/Netbeans/ModuleDevelopment40 and
configure to build a pmd-netbeans module into extra cluster. Example of
neceseary changes is in cluster-harness.diff file.
The trunk version of NetBeans IDE is used to develop the PMD plugin
using the new plugin development support.
Read the documentation of this support to get details about the
configuration. For a quick setup it should be enough to copy
the 'pmdsuite.properties.template' file into pmdsuite.properties' edit its
content according to comments.

View File

@@ -1,52 +0,0 @@
diff -aur nbbuild.orig/modules.xml nbbuild/modules.xml
--- nbbuild.orig/modules.xml 2004-12-07 02:35:34.000000000 +0100
+++ nbbuild/modules.xml 2004-12-18 23:13:10.000000000 +0100
@@ -11,6 +11,11 @@
<cnb>org.netbeans.modules.snipe</cnb>
</module>
+ <module>
+ <path>pmd-netbeans</path>
+ <cnb>pmd</cnb>
+ </module>
+
<!-- =================================== -->
<!-- ===== Netbeans Modules ======== -->
<!-- =================================== -->
Only in nbbuild: modules.xml~
diff -aur nbbuild.orig/user.build.properties nbbuild/user.build.properties
--- nbbuild.orig/user.build.properties 2004-12-07 02:40:25.000000000 +0100
+++ nbbuild/user.build.properties 2004-12-18 23:18:16.000000000 +0100
@@ -10,11 +10,11 @@
# Microsystems, Inc. All Rights Reserved.
# the name of your cluster
-clustername=mycluster1
+clustername=extra
# The location of your binary netbeans installation. Modules will be installed
# into this location.
-netbeans.dest.dir=c:/netbeans
+netbeans.dest.dir=/opt/ide/nbr40/netbeans
# netbeans.user directory to use when launching netbeans
# with "ant tryme"
Only in nbbuild: user.build.properties~
diff -aur nbbuild.orig/user.cluster.properties nbbuild/user.cluster.properties
--- nbbuild.orig/user.cluster.properties 2004-12-07 02:35:34.000000000 +0100
+++ nbbuild/user.cluster.properties 2004-12-18 22:59:17.000000000 +0100
@@ -3,11 +3,11 @@
user.cluster=cluster.mycluster1
# the directory under ${netbeans.home} containing your cluster
-cluster.mycluster1.dir=mycluster1
+cluster.mycluster1.dir=extra
# the list of modules (the names of the directories containing
# the modules, rooted at nbbuild/..)
-cluster.mycluster1= snipe
+cluster.mycluster1=pmd-netbeans
# image, \
# utilities/group, \
# apisupport/lite, \
Only in nbbuild: user.cluster.properties~

View File

Binary file not shown.

View File

Binary file not shown.

View File

@@ -1,16 +1,9 @@
Manifest-Version: 1.0
OpenIDE-Module-Specification-Version: 1.0
Created-By: Ole-Martin Mørk and Gunnlaugur Þór Briem
Class-Path: ext/pmd-2.1.jar ext/jaxen-core-1.0-fcs.jar ext/saxpath-1.0-fcs.jar ext/jakarta-oro-2.0.jar
OpenIDE-Module-Specification-Version: 1.1
Created-By: Ole-Martin Mørk and Gunnlaugur Þór Briem and Radim Kubacki
OpenIDE-Module: pmd
OpenIDE-Module-Layer: pmd/mf-layer.xml
OpenIDE-Module-IDE-Dependencies: IDE/1 > 4.29
OpenIDE-Module-Localizing-Bundle: pmd/Bundle.properties
OpenIDE-Module-Module-Dependencies:
org.netbeans.api.java/1,
org.openide.io > 1.0,
org.openide.src,
org.openide.loaders
OpenIDE-Module-Requires:
org.openide.windows.IOProvider

View File

@@ -0,0 +1 @@
private

View File

@@ -1 +1,17 @@
cp.extra=lib/jaxen-core-1.0-fcs.jar:lib/pmd-2.1.jar:lib/saxpath-1.0-fcs.jar:lib/jakarta-oro-2.0.jar
#cp.extra=lib/jaxen-core-1.0-fcs.jar:lib/pmd-2.1.jar:lib/saxpath-1.0-fcs.jar:lib/jakarta-oro-2.0.jar
extra.module.files=\
modules/ext/jaxen-core-1.0-fcs.jar,\
modules/ext/pmd-2.1.jar \
modules/ext/saxpath-1.0-fcs.jar \
modules/ext/jakarta-oro-2.0.jar
nbm.distribution=http://pmd.sourceforge.net/
license.file=LICENSE.txt
nbm.homepage=http://pmd.sourceforge.net/
nbm.module.author=Ole-Martin Mørk, Gunnlaugur Þór Briem, Radim Kubacki
#netbeans.dest.dir - absolute pathname of NB platform (or IDE or whatever) that
#you are building your module against, and into which your module will be built.
#Available in project.properties.
#netbeans.home - location of "platform*" cluster of the NetBeans IDE installation
#you are running. *Only defined* when you run an Ant script *inside* the IDE.

View File

@@ -2,7 +2,7 @@
<project xmlns="http://www.netbeans.org/ns/project/1">
<type>org.netbeans.modules.apisupport.project</type>
<configuration>
<data xmlns="http://www.netbeans.org/ns/nb-module-project/1">
<data xmlns="http://www.netbeans.org/ns/nb-module-project/2">
<code-name-base>pmd</code-name-base>
<path>pmd-netbeans</path>
<module-dependencies>
@@ -18,6 +18,7 @@
<code-name-base>org.openide.src</code-name-base>
<build-prerequisite/>
<compile-dependency/>
<run-dependency/>
</dependency>
<dependency>
<code-name-base>org.openide</code-name-base>
@@ -44,6 +45,30 @@
</dependency>
</module-dependencies>
<public-packages/>
<class-path-extension>
<!-- Deployed path, relative to dir containing module: -->
<runtime-relative-path>ext/jakarta-oro-2.0.jar</runtime-relative-path>
<!-- Path of library in your own sources, relative to project basedir: -->
<binary-origin>lib/jakarta-oro-2.0.jar</binary-origin>
</class-path-extension>
<class-path-extension>
<!-- Deployed path, relative to dir containing module: -->
<runtime-relative-path>ext/jaxen-core-1.0-fcs.jar</runtime-relative-path>
<!-- Path of library in your own sources, relative to project basedir: -->
<binary-origin>lib/jaxen-core-1.0-fcs.jar</binary-origin>
</class-path-extension>
<class-path-extension>
<!-- Deployed path, relative to dir containing module: -->
<runtime-relative-path>ext/saxpath-1.0-fcs.jar</runtime-relative-path>
<!-- Path of library in your own sources, relative to project basedir: -->
<binary-origin>lib/saxpath-1.0-fcs.jar</binary-origin>
</class-path-extension>
<class-path-extension>
<!-- Deployed path, relative to dir containing module: -->
<runtime-relative-path>ext/pmd-3.1.jar</runtime-relative-path>
<!-- Path of library in your own sources, relative to project basedir: -->
<binary-origin>lib/pmd-3.1.jar</binary-origin>
</class-path-extension>
</data>
</configuration>
</project>

View File

@@ -0,0 +1 @@
suite.properties=${basedir}/pmdsuite.properties

View File

@@ -0,0 +1,16 @@
# absolute pathname of NB platform (or IDE or whatever) that
# you are building your module against, and into which your
# module will be built
netbeans.dest.dir=/home/radim/devel/nb/nb_all/nbbuild/netbeans
# location of the build harness, usually
# "${netbeans.dest.dir}/harness"
harness.dir=/usr/local/netbeans/harness
# basename of cluster directory your module is to be built into
cluster.dir=extra
# the directory containing the sources of NetBeans IDE
netbeans.sources=<your_path>/netbeans-src