debuginfo/diz files in built images

Daniel D. Daugherty daniel.daugherty at oracle.com
Mon Sep 3 02:47:24 UTC 2012


On 9/2/12 7:26 PM, David Holmes wrote:
> The build will create debuginfo/diz files as requested - that's fine.
>
> What I'm unclear about is where those files should actually appear in 
> our build artifacts, specifically the jdk/jre images that are created.
>
> Internally when we create binary images RE strips all the 
> debuginfo/diz files out.

Not quite. The RE makefiles will put debug info files into a
separate debuginfo.zip file. This includes .debuginfo, .diz,
.map and .pdb files. For the regular bundles, the RE makefiles
will not include debug info files. Not quite the same as
stripping them out.


> But the build itself seems to treat them in an ad-hoc manner:
>
> - The new build deliberately excludes debuginfo/diz files associated 
> with binaries, but will include any related to libraries (via generic 
> copying routine). (It's obvious from the comments related to this that 
> there is some puzzlement as to this reasoning.)

Sorry I haven't looked at the new build system.


> - The old build also tries to exclude the files associated with 
> binaries, but only handles .debuginfo not .diz :(

During one round in the FDS project, I included .debuginfo/.diz files
right next to some of the binaries. Apparently that's not allowed without
explicit permission. The contents of the "bin" directory are controlled
and there are tests to verify those contents.

I changed the Makefiles for the few binaries that support FDS to not
install the debug info files with the binaries, but they are left in
the normal build artifacts location if someone has the need to use
them. Of course, I've had queries for debug info files for the binaries
to be included in the debuginfo.zip bundles. I'm not planning to fight
that battle.


> Those associated with libraries just seem to get copied if they happen 
> to be there

All of the logic that copies debug info files to the image should do
so if they happen to be there. Not all component support FDS now or
in the future so the logic needs to adapt to what is built.


> As I said this all seems very ad-hoc to me. I would expect to see no 
> debuginfo/diz files in a created image by default, and have a separate 
> target that would produce a tar file of all the debuginfo/diz files 
> ready to overlay on an existing image.

Close. The image has to have the debug info or .diz files in order for
the RE makefiles to generate the debuginfo.zip files. It is the RE
makefiles that handle the packaging. Just like the demos are always
built and it is the RE makefiles that put them in a separate bundle.


> Thoughts/comments?
>
> I have to deal with this for the SE Profile work, where we will not 
> want these files present in any of the images.

It should be fine if the Embedded profile does not generate debug info
files or if the Embedded profile generates debug info, but does not
copy the debug info files into the image area. The RE makefiles will
handle the presence or absence of debug info files.

However, the non-Embedded profile needs to continue to generate and
copy debug info files for those components that already support FDS.
If you change the non-Embedded logic to not copy the debug info files
into the image area, the RE debuginfo.zip bundle will not be created
and that will break FDS.

Dan


>
> David



More information about the build-dev mailing list