This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 227070 - Be buildable with Ant 1.9.0
Summary: Be buildable with Ant 1.9.0
Status: RESOLVED FIXED
Alias: None
Product: www
Classification: Unclassified
Component: Builds & Repositories (show other bugs)
Version: 7.4
Hardware: All All
: P2 normal (vote)
Assignee: pgebauer
URL:
Keywords: PATCH_AVAILABLE
Depends on:
Blocks: 227096
  Show dependency tree
 
Reported: 2013-03-06 00:46 UTC by Jesse Glick
Modified: 2013-04-02 16:46 UTC (History)
3 users (show)

See Also:
Issue Type: TASK
Exception Reporter:


Attachments
Proposed patch (27.94 KB, patch)
2013-03-06 00:49 UTC, Jesse Glick
Details | Diff
Revised patch (29.25 KB, patch)
2013-03-06 01:40 UTC, Jesse Glick
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jesse Glick 2013-03-06 00:46:52 UTC
nbbuild currently does not build using the (as of this writing forthcoming) Ant 1.9.0, due to the introduction of generic signatures.
Comment 1 Jesse Glick 2013-03-06 00:49:58 UTC
Created attachment 132231 [details]
Proposed patch

Note that in some cases Project.getProperties is cast to Map<String,Object>, which is a no-op when compiled Ant 1.9.0 but is necessary to avoid a hard error (rather than merely an unchecked warning) when compiled against Ant 1.8.4. E.g.

for (Map.Entry<String,Object> entry : ((Map<String,Object>) p.getProperties()) {…}

Alternate style is

Map<String,Object> props = p.getProperties(); // ignore unchecked warning in 1.8.4
for (Map.Entry<String,Object> entry : props) {…}

though this still sort of needs an inlining when support for compiling against 1.8.4 is dropped.
Comment 2 Jesse Glick 2013-03-06 01:40:29 UTC
Created attachment 132234 [details]
Revised patch

Fixes compilation of javawebstart module. Now builds cluster.config=stableuc.
Comment 3 Jesse Glick 2013-03-12 12:58:24 UTC
1.9.0 now released and bundled with NB; do you plan to apply this patch?
Comment 4 Antonin Nebuzelsky 2013-03-25 13:05:14 UTC
Let's apply the patch. Assuming older 1.8.4 can still be used to build NB codebase...?
Comment 5 Jesse Glick 2013-03-25 15:26:26 UTC
Yes, the intention was that you could still use 1.8.4 to build if you preferred (though I have not rechecked this since submitting).

BTW now that JDK 7 is needed to run builds, nbbuild/antsrc gets a bunch of rawtypes warnings.
Comment 6 pgebauer 2013-04-02 15:02:32 UTC
Changes have been applied.
http://hg.netbeans.org/core-main/rev/2f69633a5158
Comment 7 Jesse Glick 2013-04-02 16:26:41 UTC
Thanks!
Comment 8 Jiri Rechtacek 2013-04-02 16:46:38 UTC
just for the record - http://hg.netbeans.org/core-main/rev/583072de8eb9