Index: /trunk/build.xml
===================================================================
--- /trunk/build.xml	(revision 3829)
+++ /trunk/build.xml	(revision 3830)
@@ -254,5 +254,18 @@
 			</path>
 		</as:build-signatures>
-
+		
+		<!-- List of deprecated plugins -->
+		<loadfile property="deprecated-plugins" srcFile="src/org/openstreetmap/josm/plugins/PluginHandler.java">
+			<filterchain>
+				<linecontains>
+					<contains value="new DeprecatedPlugin("/>
+				</linecontains>
+				<tokenfilter>
+					<replaceregex pattern='.*new DeprecatedPlugin\("(.+?)".*' replace="\1|" flags="gi"/>
+				</tokenfilter>
+				<striplinebreaks/>
+			</filterchain>
+		</loadfile>
+		
 		<!-- Download plugins -->
 		<loadresource property="plugins">
@@ -263,6 +276,5 @@
 				</linecontainsregexp>
 				<linecontainsregexp negate="true">
-					<!-- List from PluginHandler.DEPRECATED_PLUGINS -->
-					<regexp pattern="mappaint|unglueplugin|ewmsplugin|ywms|tways-0.2|geotagged|landsat|namefinder|waypoints|slippy_map_chooser|tcx-support|usertools|AgPifoJ|utilsplugin"/>
+					<regexp pattern="${deprecated-plugins}"/>
 				</linecontainsregexp>
 				<tokenfilter>
