update versioning reference
diff --git a/org.eclipse.wtp.releng.versionchecker/src/org/eclipse/wtp/releng/tools/versionchecker/VersionLister.java b/org.eclipse.wtp.releng.versionchecker/src/org/eclipse/wtp/releng/tools/versionchecker/VersionLister.java
index bb07eea..2f2ddd3 100644
--- a/org.eclipse.wtp.releng.versionchecker/src/org/eclipse/wtp/releng/tools/versionchecker/VersionLister.java
+++ b/org.eclipse.wtp.releng.versionchecker/src/org/eclipse/wtp/releng/tools/versionchecker/VersionLister.java
@@ -614,7 +614,7 @@
 		}
 		else {
 			// assumes file is bundled with test plugin
-			versionCheckerBundle.getResource(referenceFileName);
+			referenceDataURL = versionCheckerBundle.getResource(referenceFileName);
 		}
 		if (referenceDataURL != null) {
 			InputStream inStream = referenceDataURL.openStream();
@@ -748,6 +748,8 @@
 
 		// TODO: needs to really write UTF-8, or better, serialize DOM
 		referenceWriter.write("<?xml version=\"1.0\" encoding=\"UTF-8\"?>" + EOL);
+		
+		referenceWriter.write("<!DOCTYPE versioningData PUBLIC \"versioningDataID\" \"/versioningData.dtd\" >" + EOL);
 
 		referenceWriter.write("<versioningData>" + EOL);
 
@@ -802,7 +804,7 @@
 	private String getDefaultID() {
 		String defaultID = null;
 		String buildLabel = System.getProperty("buildLabel");
-		if (buildLabel != null && buildLabel.length() != 0) {
+		if (buildLabel != null && buildLabel.length() > 0) {
 			defaultID = clean(buildLabel);
 		}
 		else {
@@ -878,18 +880,18 @@
 	 * @return
 	 */
 	private String clean(String label) {
-		String result = label;
+		String result = label.trim();
 
-		String possibleResult = null;
-		int hPos = label.indexOf('-');
-		if (hPos > -1) {
-			possibleResult = label.substring(hPos + 1);
-			hPos = possibleResult.indexOf('-');
-			if (hPos > -1) {
-				possibleResult = possibleResult.substring(0, hPos);
-				result = possibleResult;
-			}
-		}
+//		String possibleResult = null;
+//		int hPos = label.indexOf('-');
+//		if (hPos > -1) {
+//			possibleResult = label.substring(hPos + 1);
+//			hPos = possibleResult.indexOf('-');
+//			if (hPos > -1) {
+//				possibleResult = possibleResult.substring(0, hPos);
+//				result = possibleResult;
+//			}
+//		}
 
 
 		return result;
diff --git a/tests/org.eclipse.wtp.releng.tests/versioningData.dtd b/tests/org.eclipse.wtp.releng.tests/versioningData.dtd
new file mode 100644
index 0000000..82f442a
--- /dev/null
+++ b/tests/org.eclipse.wtp.releng.tests/versioningData.dtd
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+   <!ELEMENT versioningData (referenceData*)>
+   <!ELEMENT referenceData (featureData, bundleData)>
+   <!ATTLIST referenceData id ID #REQUIRED>
+   <!ELEMENT featureData (entry*)>
+   <!ELEMENT bundleData (entry*)>
+   <!ELEMENT entry (name, version)>
+   <!ELEMENT name (#PCDATA)>
+   <!ELEMENT version (#PCDATA)>
\ No newline at end of file