mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Christian Bjälevik" <nafallo@magicalforest.se>
To: LKML <linux-kernel@vger.kernel.org>
Cc: Debian-Kernel <debian-kernel@lists.debian.org>
Subject: PROBLEM: Cross-compiling fails (patch included)
Date: Thu, 16 Dec 2004 19:32:05 +0100	[thread overview]
Message-ID: <41C1D4A5.3080503@magicalforest.se> (raw)

[-- Attachment #1: Type: text/plain, Size: 1071 bytes --]

  Hi there!

When using kernel-package (Debian specific kernel-management) to 
cross-compile a kernel in a i386-chroot on my x86_64 laptop 
modules_install fails when trying to depmod things. Since we should not 
depmod those things if the arch being built isn't the same as 'uname -m' 
I wrote a patch for the Makefile to test those conditions.

Sincererly

PS I'm not subscribed to those lists, please CC me on reply. DS
-- 
Christian     .-.    Bjälevik
Eskilstuna    /v\    [SWEDEN]
ICQ UIN      // \\   60036598
Linux User  /(   )\  [344682]
GPG Key ID   ^^-^^   23FE8EB7
         Jabber & Email
    nafallo@magicalforest.se

-----------------------------
diff -puN Makefile.orig Makefile
--- Makefile.orig       2004-12-09 00:08:43.000000000 +0100
+++ Makefile    2004-12-08 23:59:34.000000000 +0100
@@ -788,7 +788,9 @@ depmod_opts := -b $(INSTALL_MOD_PATH) -r
  endif
  .PHONY: _modinst_post
  _modinst_post: _modinst_
+ifeq ([ uname -m ],$(ARCH))
         if [ -r System.map ]; then $(DEPMOD) -ae -F System.map 
$(depmod_opts) $$+endif

  else # CONFIG_MODULES


[-- Attachment #2: cross-compiling.patch --]
[-- Type: text/x-patch, Size: 409 bytes --]

diff -puN Makefile.orig Makefile
--- Makefile.orig	2004-12-09 00:08:43.000000000 +0100
+++ Makefile	2004-12-08 23:59:34.000000000 +0100
@@ -788,7 +788,9 @@ depmod_opts	:= -b $(INSTALL_MOD_PATH) -r
 endif
 .PHONY: _modinst_post
 _modinst_post: _modinst_
+ifeq ([ uname -m ],$(ARCH))
 	if [ -r System.map ]; then $(DEPMOD) -ae -F System.map $(depmod_opts) $(KERNELRELEASE); fi
+endif
 
 else # CONFIG_MODULES
 

             reply	other threads:[~2004-12-16 18:32 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-16 18:32 Christian Bjälevik [this message]
2004-12-16 23:41 ` Sam Ravnborg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=41C1D4A5.3080503@magicalforest.se \
    --to=nafallo@magicalforest.se \
    --cc=debian-kernel@lists.debian.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome