394
395 % cp jconsole/build.properties collections
396 % cp jconsole/build.xml collections
397 % cp jconsole/nbproject/project.xml collections/nbproject
398
399 Change the set of files included in the project
400 The collections sources are all under one directory, and we want to include
401 them all. The same is true of the tests. So edit
402 collections/build.properties so that it contains these lines:
403
404 includes=\
405 java/util/
406 excludes=\
407 java/util/Calendar.java,\
408 java/util/jar/,\
409 java/util/logging/,\
410 java/util/prefs/,\
411 java/util/regex/,\
412 java/util/spi/,\
413 java/util/zip/,\
414 **/*-XLocales.java
415 jtreg.tests=\
416 java/util/**/*Collection/ \
417 java/util/**/*Map/ \
418 java/util/**/*Set/ \
419 java/util/**/*List/
420
421 Notice the trailing "/" in some of those pathnames: that tells NetBeans to
422 treat the path as a directory and include (or exclude) everything beneath
423 it in the hierarchy. Note also how we include java/util, but then exclude
424 several directories under that which are not related to collections.
425
426 The build.xml for collections is about as simple as can be. First, change the
427 name of the project:
428
429 <project name="collections" default="build" basedir=".">
430
431 Then remove the -pre-compile target from the build.xml. Change the
432 -post-compile target to create collections.jar without any manifest, and
433 to only contain the collections-related classes. The jar task now looks
434 like this:
|
394
395 % cp jconsole/build.properties collections
396 % cp jconsole/build.xml collections
397 % cp jconsole/nbproject/project.xml collections/nbproject
398
399 Change the set of files included in the project
400 The collections sources are all under one directory, and we want to include
401 them all. The same is true of the tests. So edit
402 collections/build.properties so that it contains these lines:
403
404 includes=\
405 java/util/
406 excludes=\
407 java/util/Calendar.java,\
408 java/util/jar/,\
409 java/util/logging/,\
410 java/util/prefs/,\
411 java/util/regex/,\
412 java/util/spi/,\
413 java/util/zip/,\
414 **/*-XLocales.java.template
415 jtreg.tests=\
416 java/util/**/*Collection/ \
417 java/util/**/*Map/ \
418 java/util/**/*Set/ \
419 java/util/**/*List/
420
421 Notice the trailing "/" in some of those pathnames: that tells NetBeans to
422 treat the path as a directory and include (or exclude) everything beneath
423 it in the hierarchy. Note also how we include java/util, but then exclude
424 several directories under that which are not related to collections.
425
426 The build.xml for collections is about as simple as can be. First, change the
427 name of the project:
428
429 <project name="collections" default="build" basedir=".">
430
431 Then remove the -pre-compile target from the build.xml. Change the
432 -post-compile target to create collections.jar without any manifest, and
433 to only contain the collections-related classes. The jar task now looks
434 like this:
|