Bugreport for crosscompiling

Torsten Mohr (tmohr@stuttgart.netsurf.de)
Sun, 11 Jul 1999 11:45:18 +0200 (MEST)


Dear Kernel-Developers,

i'd like to report some bugs. The following bugs
_ONLY_ appear when i try to crosscompile the kernel.

Here's my report. I wrote it with the instructions
in /usr/src/lnux/REPORTING-BUGS.

[1.] One line summary of the problem:

Problems when i try to crosscompile the kernel for
arm-linux-aout and ppc-linux-elf.

[2.] Full description of the problem/report:

I installed binutils-2.9.1 and egcs-1.1.2
for the following architectures:

arm-linux-aout:
Untar'ed binutils in /tmp, cd'ed into it,
# sh configure --target=arm-linux-aout \
--prefix=/opt/lin-arm
# make
# make install

[Added /opt/lin-arm/bin to PATH]

Untar'ed egcs in /tmp, cd'ed into it,
# sh configure --target=arm-linux-aout \
--prefix=/opt/lin-arm
# make
[ADDED "-Dinhibit-libc" in egcs/gcc/Makefile to
LIBGCC2_CFLAGS]
# make
# make install

ppc-linux-elf:
And the same for "ppc-linux-elf".

Now i try to crosscompile the kernel for ARM:

In /usr/src/linux i changed the following variables
in the Makefile:

ARCH = arm
CROSS_COMPILE = arm-linux-aout-

When i try "make mrproper":
schleim:/usr/src/linux # make mrproper
Makefile:228: *** target file `symlinks' has \
both : and :: entries. Stop.

And that's true, the top Makefile includes
arch/${ARCH}/Makefile and there is a line that
begins with "symlinks::". And there is also a line
that begins with "symlinks:" in the top Makefile.

I don't know about ":: sections", there was no info in
the info page for "Gnu Make". So i changed "::" to ":".

This lead to:
# make mrproper
...
make: *** arch/arm/drivers: No such file or \
directory. Stop.

So i created this directory ( arch/arm/drivers ):
# make mrproper
...
make[1]: Entering directory \
`/usr/src/linux-2.2.10/arch/arm/drivers'
make[1]: *** No rule to make target `mrproper'. Stop.

Then i commented out line 223 in arch/arm/Makefile
which is needed for the item "archmrproper":

# @$(MAKE) -C arch/$(ARCH)/drivers mrproper

This works. Now a "make menuconfig" leads to a screen
where it says that there is an internal error which should
be reported.
A file /usr/src/linux/MCerror is created. It contains one
line:
scripts/Menuconfig: MCmenu0: command not found

A "make config" works fine. So i try a "make dep":
make[2]: Entering directory `/usr/src/linux-2.2.10/arch/arm/drivers'
make[2]: *** No rule to make target `fastdep'. Stop.

So i created a Makefile "arch/arm/drivers/Makefile" with a
line "fastdep:" so there is a dummy line for "fastdep".
Now a "make dep" leads to no errors.

But a "make zImage" or "make Image" leads to a lot of errors
that seem to be related to missing files:
...
/usr/src/linux/include/asm/param.h:1: asm/proc/param.h: No such file or director
/usr/src/linux/include/asm/ptrace.h:4: asm/proc/ptrace.h: No such file or direct
/usr/src/linux/include/asm/page.h:4: asm/arch/memory.h: No such file or director
/usr/src/linux/include/asm/page.h:5: asm/proc/page.h: No such file or directory
/usr/src/linux/include/asm/system.h:147: asm/proc/system.h: No such file or dire

include/asm is a symbolic link to include/arm-asm.
But in include/arm-asm there is no proc, only "proc-armo"
and "proc-armv". So i tried symbolic links from "proc-armo"
and "proc-armv" to "proc", but both lead to lots of errors.
(missing include files and problems with "coda.h"(u_quad_t)).

PPC:
i changed two lines in the top Makefile:
ARCH = ppc
CROSS_COMPILE = ppc-linux-elf-

"make mrproper" works fine. "make xconfig" leads to a
problems with X11, it does not react any more. A "make
menuconfig" leads to a screen that says i should report
an internal error.

I tried to compile the kernel for as few features as possible
but a "make zImage" or "make Image" leads to lots of problems
with "coda" (coda_fs_i.h).

[3.] Keywords (i.e., modules, networking, kernel):
CROSSCOMPILING, ARM, PPC, CODA, "make xconfig", "make menuconfig"

[4.] Kernel version (from /proc/version):
I use "2.2.10" on the host and for cross compiling

[6.] A small shell script or example program which triggers the
problem (if possible)
Please see item 2 for this. I included all the
commands i made.

[7.] Environment
It seems to me that these information are not relevant for
this problem.

Best regards,
Torsten Mohr.

email: tmohr@stuttgart.netsurf.de

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/