[arch-projects] [mkinitcpio][PATCH 1/3] mkinitcpio: catch more buildtime errors
Move the unsetting of the errtrace and ERR trap flags to after the
image has been built. This lets us capture errors during module
installation to the build root and the call to depmod. Either of these
steps failing could be hazardous and should prompt a failure.
Signed-off-by: Dave Reisner
depmod doesn't care where modules are, within reason, and separating
modules into the respective hierarchies only serves to irritate users
who go looking for modules in the rootfs (aka me). Forget all this and
dump everything into the kernel/ dir.
Signed-off-by: Dave Reisner
From: Tom Gunderson
[Thursday 16 February 2012] [17:35:34] <falconindy> tomegun: im
forging your name on a mkinitcpio patch
On Fri, Feb 17, 2012 at 3:06 PM, Dave Reisner
From: Tom Gunderson
[...] Signed-off-by: Tom Gundersen
Not a very impressive forgery, but apart from that no objections. -t
On Fri, Feb 17, 2012 at 09:06:01AM -0500, Dave Reisner wrote:
From: Tom Gunderson
This increases compression efficiency, which might be useful on an image containing a lot of modules.
For the usecase I had in mind, this reduced the size by about a quarter.
Signed-off-by: Tom Gundersen
^ borka, bork bork
Signed-off-by: Dave Reisner
--- Resending this as its rebased/rewritten with Tom's name on it. mkinitcpio | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/mkinitcpio b/mkinitcpio index f79fbcb..637795f 100755 --- a/mkinitcpio +++ b/mkinitcpio @@ -341,6 +341,9 @@ trap '(( ++builderrors ))' ERR if (( ${#ADDED_MODULES[*]} )); then cp "${MODPATHS[@]}" "$BUILDROOT/lib/modules/$KERNELVERSION/kernel"
+ # unzip modules prior to recompression + gzip -dr "$BUILDROOT/lib/modules/$KERNELVERSION/kernel" + msg "Generating module dependencies" install -m644 -t "$BUILDROOT/lib/modules/$KERNELVERSION" \ "$BASEDIR/lib/modules/$KERNELVERSION"/modules.{builtin,order} -- 1.7.9.1
participants (2)
-
Dave Reisner
-
Tom Gundersen