There have been requests to permit users to open and build selected netbeans.org modules without having the complete
source tree available.
Created attachment 66879 [details]
Initial patch for apisupport.project which lets you open orphaned netbeans.org projects
Created attachment 66940 [details]
I think I have this working. I don't want to push an implementation today because I am not confident there is no
potential for regressions (some subtle code in the build system had to be patched) and I will be on vacation next week.
Michal if you have a moment to review the patch, that would be great.
Quick usage guide:
1. Create an nb_all dir wherever you like. It must have at least the nbbuild dir from the netbeans.org source tree (with
the patches in this issue applied).
2. Create nbbuild/user.build.properties and in it set the property 'netbeans.dest.dir' to the full path to a NetBeans
IDE installation you would like to both compile against and build into (you should not use your real development IDE,
rather a copy).
3. Run: ant -f nbbuild/build.xml bootstrap
4. Add subdirs for any netbeans.org module projects you would like to work on. (The modules may be already present in
the target platform. If they are not, you need to check out sources for any transitive dependencies not in the target
5. Using an IDE whose apisupport.project has also been patched as in this issue, open the desired projects and work
1. Source projects should open without error and without displaying error badges, assuming all dependencies are
available in either source or binary form.
2. You can build the projects normally. The modules will be built into the target platform (overwriting any existing
copy of the module).
3. You can use Run and Debug to start the target platform with a test userdir after building the modules, set
4. You can Test the source projects normally.
5. Code completion should work against APIs present in other modules. If those modules are available in source form, you
will get popup Javadoc automatically, and can navigate to sources. If not, you can still add popup Javadoc capability
for all published APIs:
a. Download "NetBeans API Documentation" from AU.
b. Open NetBeans Platform Manager.
c. Select the "default" platform and note the location of NetBeansAPIDocs.zip in the Javadoc tab.
d. Create a new platform; select the same dir as you specified for netbeans.dest.dir.
e. In the new platform, add NetBeansAPIDocs.zip to the Javadoc tab.
1. If you want to work on unit or functional tests, you need to have all test-to-test dependencies available as source
projects, because we do not distribute test libraries. Sometimes the transitive dependency tree can get a bit big. For
example, if the functional tests use org.netbeans.junit.ide.ProjectSupport, then you need to check out java.j2seproject
(in whose unit test dir this class resides), then its dependencies in turn: projectapi, projectui, openide.filesystems,
and openide.util. Test-to-module dependencies (e.g. nbjunit, jellytools, ...) can however be satisfied from the target
2. If you add new source modules to the tree, you will need to both restart NetBeans and delete the
nbbuild/nbproject/private/ dir in order to reset all caches and ensure that the new sources are recognized.
3. Various targets in nbbuild/build.xml not used in the above scenarios may or may not work usefully, though this should
not affect routine module development.
4. The target platform needs to be new enough to support any API calls you are making from source modules into binary
modules. If the platform is older, you could see error badges. Besides getting a newer platform, this can be corrected
by adding sources of the new version of the API module to the tree.
I wrote up a wiki page documenting the feature.
Implementing: core-main #8647aaf569db
Integrated into 'main-golden', available in build *200808221401* on http://bits.netbeans.org/dev/nightly/
User: Jesse Glick <firstname.lastname@example.org>
Log: #143236: support orphaned netbeans.org modules.
Integrated into 'main-golden', will be available in build *200811130201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
User: Jesse Glick <email@example.com>
Log: #143236 clean-up; test was failing.