Building kernel natively
- To: debian-arm@lists.debian.org
- Subject: Building kernel natively
- From: Magnus Berg <Magnus@Emdev.se>
- Date: Thu, 03 Sep 2009 14:55:05 +0200
- Message-id: <4A9FBCA9.10601@Emdev.se>
- In-reply-to: <56d259a00908290313o31e5b9d2v3a8d258eece9b6e7@mail.gmail.com>
- References: <8763cogcdy.fsf@pindar.marcbrockschmidt.de> <20090818182732.GD19413@deprecation.cyrius.com> <97a0a9ac0908270933rdfbcbfav56fe25cfb1697ddf@mail.gmail.com> <20090829053116.GC16593@deprecation.cyrius.com> <56d259a00908290313o31e5b9d2v3a8d258eece9b6e7@mail.gmail.com>
Hi
I've been having trouble building a kernel (2.6.30-6) for my QNAP TS-219 *on* my
TS-219. When I start the build process with make-kpkg, it starts by generating a
lot of files under debian/. In the file debian/ruleset/misc/defaults.mk, some
logic tries to determine which cross-compiler to use by interrogating
dpkg-architecture, but when building on the same architecture as the target, no
cross-compiler should be used.
But when defaults.mk checks the current architecture, it compares DEB_BUILD_ARCH
with DEB_HOST_ARCH_CPU, and since those are different (armel vs. arm), it
insists on using a cross-compiler and prepends arm-linux-gnueabi- to all build
tools.
The only solution I've found is to start the build process until it fails, then
edit the defaults.mk file so it makes a sane comparison and then restart the build.
I'm not even sure how the debian/ directory are created by make-kpkg, haven't
dug into it. Is there a better way to build natively? Or is it a plain bug?
Magnus
Reply to: