RFR: 8252233: Enable debug-image target to support producing a pure debug image package

Magnus Ihse Bursie magnus.ihse.bursie at oracle.com
Fri Aug 28 07:51:50 UTC 2020


On 2020-08-27 23:26, Erik Joelsson wrote:
> Hello Andrew,
>
> We certainly appreciate contributions, but this patch as it currently 
> looks does not fit well with our current build system model. I'm 
> however not against adding a target for your usecase.
>
> On a high level, just as Severin pointed out, the term "debug" is used 
> for the type configuration we are building (release vs debug). For 
> debug information we have instead chosen the term "symbols", so the 
> target should rather be called symbols-image. Now I realize we already 
> have that target, for something slightly different. I introduced that 
> a long time ago for gcov symbols, with the intention of eventually 
> move the main debug symbols into it too, but that never happened. I 
> think we can just make that change now and let the symbols-image be 
> what you are asking for (in addition to the gcov files if those are 
> enabled). This will be one step in the direction of a bigger overhaul 
> of the images that I want to do anyway.
>
> On a lower level, in Main.gmk, all targets should be declared as calls 
> to the macro SetupTarget and in the correct section of the file. In 
> this case it would be around line 418 where the current symbols-image 
> is declared.
>
> The new file DebugImage.gmk contains a lot of duplication of logic 
> already implemented in Images.gmk, which can quite easily be extended 
> to cover your usecase.
>
> So all that said, this is how I would suggest to solve it:
>
> http://cr.openjdk.java.net/~erikj/8252233/webrev.01/index.html
Erik,

I fully agree with you in your analysis on the proper way to solve this. 
However, I have a hard time figuring out how the patch you supplied will 
achieve that. :-) Maybe you can help me understand how this would 
actually make the debug symbols be added to the symbol image?

/Magnus
>
> With this change, building the symbols image is part of the top level 
> product-images target (but separate from the more specific jdk-image 
> target). In Bundles.gmk, building the jdk bundles tar.gz gets slightly 
> simpler as the files can be found directly in the symbols image.
>
> I still need to test this properly on all platforms.
>
> /Erik
>
> On 2020-08-27 08:55, Andrew Leonard wrote:
>> Hi,
>> Please may I request a sponsor and review for this build enhancement to
>> provide a pure debug "image", for those developers that want to 
>> accompany
>> a straight jdk image with a debug-image when needed:
>>      https://bugs.openjdk.java.net/browse/JDK-8252233
>>      webrev: http://cr.openjdk.java.net/~aleonard/8252233/webrev.00/
>> We have been providing this as part of the openj9 builds at AdoptOpenJDK
>> for a while now, and would like to contribute it upstream to openjdk.
>>
>> Thanks
>> Andrew
>>
>> Andrew Leonard
>> Java Runtimes Development
>> IBM Hursley
>> IBM United Kingdom Ltd
>> internet email: andrew_m_leonard at uk.ibm.com
>>
>> Unless stated otherwise above:
>> IBM United Kingdom Limited - Registered in England and Wales with number
>> 741598.
>> Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire 
>> PO6 3AU
>>




More information about the build-dev mailing list