OpenJDK builds: Ant build issues with jdk (netbeans) sub-projects - awt2d, j2se and jarzip

Mike Duigou mike.duigou at oracle.com
Thu Jan 10 09:16:48 PST 2013


I've made a few patches over the last couple of years to the NetBeans projects mostly to make editting code and tests within the IDE easier but haven't ever spent much effort trying to build from within the IDE. I have been anticipating doing some work to see if building from within the IDE can be done more simply with the new build infrastructure once it is in place. As Anthony suggest though this will likely be full builds of all of OpenJDK.

Mike

On Jan 10 2013, at 06:25 , Anthony Petrov wrote:

> Hi Mani,
> 
> I realize this, and in fact the (now) old build system should have allow you to build e.g. AWT separately by invoking make from make/java/awt, make/sun/awt, and on X11 - make/sun/xawt directories.
> 
> However, the new build system does not generally support this kind of partial builds. For any "sub"-projects. You can only invoke make for the whole JDK in the top-level directory. This is how it is designed to work. Note that this new build system is able to resolve dependencies very quickly, and as a result incremental builds (i.e. when you change just a few files) should take very small amount of time. Even building the whole JDK for the first time takes significantly less time than with the old build system.
> 
> Given that we're switching to the new build system real soon, and the old build system will be deprecated and removed eventually, I strongly recommend you to try out the new one. You may want to clone the jdk8/build forest where it is fully implemented at the moment and play with it.
> 
> --
> best regards,
> Anthony
> 
> On 01/10/13 04:31, Mani Sarkar wrote:
>> Hi Anthony,
>> 
>> Thanks for responding to my post.
>> 
>> I'm aware of the make files available for other projects and
>> sub-projects from within the OpenJDK. But the reason I was requesting
>> help on building the Awt2d and J2se as they form part of the JDK project
>> and it would be handy to be able to build them separately (irrespective
>> of the netbeans projects) to the whole JDK project itself. Given that
>> the total build time for the JDK is longer than just building its
>> underlying components - developers would love working on separate
>> components in IDEs of their choice.
>> 
>> I'm working on wiki instructions to help with the Adopt OpenJDK
>> initiative which would assist adopters to build these projects via the
>> CLI or from withiin Eclipse.
>> 
>> At this stage I'm updating existing instructions to build OpenJDK and
>> its sub-projects in Eclipse and CLI - I have been able to build most of
>> the sub-projects except the two sub-projects under the /jdk/
>> folder.Besides moving the make files of these projects to the new build
>> system would also benefit future adopters to directly load them up in
>> their IDE and amend the underlying code and see the build results in the
>> console.
>> 
>> There is a potential for a larger number of users in our group to do
>> just this and more hence I'm involved in the process.  Any hint or help
>> would be most appreciated, as I think it might just be a matter of
>> configuration - I did read about sustaining these build.xml files for
>> future use on a couple of other mailing lists.
>> 
>> Thanks.
>> 
>> Regards,
>> Mani
>> 
>> On Wed, Jan 9, 2013 at 1:58 PM, Anthony Petrov
>> <anthony.petrov at oracle.com <mailto:anthony.petrov at oracle.com>> wrote:
>> 
>>    Hi Mani,
>> 
>>    Not many developers really use NetBeans when working on JDK code.
>>    And only a few (if any) actually build it from NetBeans. Since the
>>    main build system for JDK is makefiles-based, obviously the netbeans
>>    projects are almost never updated when something happens to the way
>>    the code is built. Thus the projects become outdated.
>> 
>>    The new build system (configure/make-based, see the makefiles/
>>    directory in JDK) is very fast. It does a very good job with
>>    incremental builds, so I suggest to use it for your purposes.
>> 
>>    --
>>    best regards,
>>    Anthony
>> 
>> 
>>    On 1/6/2013 19:00, Mani Sarkar wrote:
>> 
>>        Hi,
>> 
>>        I have been recommended to post my below query to your mailing
>>        list, if it is the right place to post. If not could you
>>        recommend who would be best placed to answer the below questions.
>> 
>>        Thanks.
>> 
>>        Regards,
>>        Mani
>> 
>>        On 01/05/2013 04:05 PM, Mani Sarkar wrote:
>> 
>>             Hi all,
>> 
>>             I have made some progress with the below three
>>        sub-projects, and have
>>             successfully built jarzip. But still get new error messages
>>        with
>>             awt2d and
>>             j2se.
>> 
>>             I answered my own question about the -source 8, its basically
>>             expecting the
>>             images/j2sdk-image to be assigned to the respective ALT_...
>>             variables via
>>             the make.options property in build.properties for all three
>>        projects.
>> 
>>             Unfortunately I wasn't able to build swing via the
>>        .../javax/swing/
>>             folder
>>             where the required make file(s) are present.
>> 
>>             But my other queries still stand, if you can throw some
>>        light on
>>             them, it
>>             would be help make progress with these builds using the new
>>        build
>>             system.
>> 
>>             Thanks.
>> 
>>             Regards,
>>             Mani
>> 
>>             On Sat, Jan 5, 2013 at 12:39 AM, Mani Sarkar
>>        <sadhak001 at gmail.com <mailto:sadhak001 at gmail.com>
>>        <mailto:sadhak001 at gmail.com <mailto:sadhak001 at gmail.com>>> wrote:
>> 
>>                 Hi All,
>> 
>>                 I have furthered my pursuits with building *OpenJDK
>>        projects *by
>>                 building
>> 
>>                 the JDK sub-projects like swing, etc... but came across
>>        issues with
>>                 building 3 different projects which I wasn't able to
>>        build due
>>                 configuration issues. These sub-projects are located
>>        under the
>>                 netbeans
>>                 subfolder under the .../jdk/make/ folder.
>> 
>>                 They all are getting compiled for version 8 with the
>>        below args
>>                 (which is
>>                 leading to a build failure):
>> 
>>                     -source 8 -target 8
>> 
>>                 *jdk/awt2d*
>> 
>>        https://github.com/____neomatrix369/BuildHelpers/____blob/master/____EclipseProjectsForOpenJDK/____Logs/jdk/awt2d/awt2dAntBuild.____log
>>        <https://github.com/__neomatrix369/BuildHelpers/__blob/master/__EclipseProjectsForOpenJDK/__Logs/jdk/awt2d/awt2dAntBuild.__log>
>>        <https://github.com/__neomatrix369/BuildHelpers/__blob/master/__EclipseProjectsForOpenJDK/__Logs/jdk/awt2d/awt2dAntBuild.__log
>>        <https://github.com/neomatrix369/BuildHelpers/blob/master/EclipseProjectsForOpenJDK/Logs/jdk/awt2d/awt2dAntBuild.log>>
>> 
>>                 *jdk/j2se*
>> 
>>        https://github.com/____neomatrix369/BuildHelpers/____blob/master/____EclipseProjectsForOpenJDK/____Logs/jdk/j2se/j2seAntBuild.log
>>        <https://github.com/__neomatrix369/BuildHelpers/__blob/master/__EclipseProjectsForOpenJDK/__Logs/jdk/j2se/j2seAntBuild.log>
>>        <https://github.com/__neomatrix369/BuildHelpers/__blob/master/__EclipseProjectsForOpenJDK/__Logs/jdk/j2se/j2seAntBuild.log
>>        <https://github.com/neomatrix369/BuildHelpers/blob/master/EclipseProjectsForOpenJDK/Logs/jdk/j2se/j2seAntBuild.log>__>
>> 
>>                 *jdk/jarzip*
>> 
>> 
>>        https://github.com/____neomatrix369/BuildHelpers/____blob/master/____EclipseProjectsForOpenJDK/____Logs/jdk/jarzip/____jarzipAntBuild.log
>>        <https://github.com/__neomatrix369/BuildHelpers/__blob/master/__EclipseProjectsForOpenJDK/__Logs/jdk/jarzip/__jarzipAntBuild.log>
>> 
>>        <https://github.com/__neomatrix369/BuildHelpers/__blob/master/__EclipseProjectsForOpenJDK/__Logs/jdk/jarzip/__jarzipAntBuild.log
>>        <https://github.com/neomatrix369/BuildHelpers/blob/master/EclipseProjectsForOpenJDK/Logs/jdk/jarzip/jarzipAntBuild.log>>
>> 
>>                 Where is this version configuration set for these
>>        projects, that
>>                 I can
>>                 change either through file changes or alternative
>>                 build.properties setting
>>                 changes? My other question is why are there no make files
>>                 available for the
>>                 jdk sub-projects (i.e. *awt2d, j2se,* etc...) except
>>        for under *
>>                 javax/swing* has make files to build this project
>>        instead Ant
>>                 build.xml
>> 
>>                 files are available. Is it possible to hook these ant
>>        files with
>>                 the new
>>                 build system, instead of only being able to build the
>>                 sub-projects via the
>>                 old build system (using the ALT_... variables via
>>        make.options).
>> 
>>                 Thanks.
>> 
>>                 Regards,
>>                 mani
>> 
>>                 --
>>                 Twitter: @theNeomatrix369
>>                 Blog: http://neomatrix369.wordpress.____com
>>        <http://neomatrix369.__wordpress.com
>>        <http://neomatrix369.wordpress.com>><http://__neomatrxi369.
>>        <http://neomatrxi369.>__wordpress.com <http://wordpress.com>
>> 
>>        <http://neomatrxi369.__wordpress.com
>>        <http://neomatrxi369.wordpress.com>>>
>> 
>>                 *Don't chase success, rather aim for "Excellence", and
>>        success
>>                 will come
>>                 chasing after you!*
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>>        --
>>        Twitter: @theNeomatrix369
>>        Blog: http://neomatrix369.wordpress.__com
>>        <http://neomatrix369.wordpress.com>
>>        <http://neomatrxi369.__wordpress.com
>>        <http://neomatrxi369.wordpress.com>>
>> 
>>        */Don't chase success, rather aim for "Excellence", and success
>>        will come chasing after you!/*
>> 
>> 
>> 
>> 
>> --
>> Twitter: @theNeomatrix369
>> Blog: http://neomatrix369.wordpress.com <http://neomatrxi369.wordpress.com>
>> 
>> */Don't chase success, rather aim for "Excellence", and success will
>> come chasing after you!/*



More information about the nb-projects-dev mailing list