Page MenuHomeFreeBSD

`make buildkernel' should display the build time in seconds
ClosedPublic

Authored by wosch on Jan 14 2018, 8:06 PM.
Referenced Files
Unknown Object (File)
Dec 23 2023, 1:24 AM
Unknown Object (File)
Nov 15 2023, 6:51 PM
Unknown Object (File)
Nov 10 2023, 8:55 AM
Unknown Object (File)
Nov 8 2023, 8:54 AM
Unknown Object (File)
Nov 6 2023, 9:25 PM
Unknown Object (File)
Nov 1 2023, 1:25 PM
Unknown Object (File)
Oct 28 2023, 12:32 PM
Unknown Object (File)
Oct 14 2023, 5:45 PM
Subscribers

Details

Summary

As described in https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=224433

the top level `make buildkernel' target should display the build time in seconds

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Thanks. Please re-upload with context. You can either use arc diff --create or simply generate a patch with huge amounts of context ([git] diff -U999999).

I updated the patch to cleanup the time temp file after build.

See also D13911. I like @bdrewery's suggestion that avoids needing a temp file.

See also D13911. I like @bdrewery's suggestion that avoids needing a temp file.

I would love to get rid of the the temp file. However, it is not easy as it sounds.

The timestamp needs to be stored in a global Makefile variable, and changed when the targets actually runs, not when we start the make command. The variable needs to be changed from a sub-shell, and later read by a another sub-shell. The whole point of a subshell is that it doesn't affect the calling session.

A temp file in this case is the simple solution.

The updated patch works without a temp file.

Note: there is a small semantic change. We display the time in seconds for all kernels build, not per kernel. For most users this is a non-issue, because they usually build only one kernel at a time.

This revision is now accepted and ready to land.Mar 16 2019, 5:43 PM
This revision was automatically updated to reflect the committed changes.