Hi,

I am trying to build a Linux framework for ML605 (Virtex6 FPGA) from Xilinx. I took a look inside the OE, there are several complete solutions for PowerPC, but nothing for MicroBlaze. Hence, based on some useful notes from Mr. Adrian Alonso which I found in his blog, I have started to build a Linux framework for MicroBlaze. After solving several issues, now I get stuck at the compiling phase of gcc for MicroBlaze. An error occurs when OE tries to patch gcc. It is listed as follows:

----------------------------------------------------------------
akzare@notebook:/opt/local/oe_mb$ bitbake helloworld-image -f
NOTE: Handling BitBake files: \ (7075/7075) [100 %]
Parsing of 7075 .bb files complete (6643 cached, 432 parsed). 7337 targets, 354 skipped, 0 masked, 0 errors.

Build Configuration:
BB_VERSION        = "1.10.2"
METADATA_BRANCH   = "master"
METADATA_REVISION = "c03c179"
TARGET_ARCH       = "microblaze"
TARGET_OS         = "linux"
MACHINE           = "xilinx-ml605"
DISTRO            = "angstrom"
DISTRO_VERSION    = "v20110127"

NOTE: Resolving any missing task queue dependencies
NOTE: Preparing runqueue
NOTE: Executing runqueue
NOTE: Running task 254 of 832 (ID: 645, virtual:native:/opt/local/oe_mb/openembedded/recipes/bison/bison_2.4.3.bb, do_configure)
NOTE: package bison-native-2.4.3-r9.0: task do_configure: Started
NOTE: Running task 289 of 832 (ID: 707, /opt/local/oe_mb/openembedded/recipes/gcc/gcc-cross-initial_4.5.bb, do_patch)
NOTE: package gcc-cross-initial-4.5-r31.1+svnr168622: task do_patch: Started
NOTE: Applying patch 'gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch' (openembedded/recipes/gcc/gcc-4.5/gcc-4.3.1-ARCH_FLAGS_FOR_TARGET.patch) NOTE: Applying patch '100-uclibc-conf.patch' (openembedded/recipes/gcc/gcc-4.5/100-uclibc-conf.patch) NOTE: Applying patch 'gcc-uclibc-locale-ctype_touplow_t.patch' (openembedded/recipes/gcc/gcc-4.5/gcc-uclibc-locale-ctype_touplow_t.patch) NOTE: Applying patch 'cache-amnesia.patch' (openembedded/recipes/gcc/gcc-4.5/cache-amnesia.patch) NOTE: Applying patch 'gcc-flags-for-build.patch' (openembedded/recipes/gcc/gcc-4.5/gcc-flags-for-build.patch) FATAL: Execution of 'quilt --quiltrc=/opt/local/oe_mb/tmp/sysroots/x86_64-linux/usr/bin/quiltrc push' failed with exit code 1:
Applying patch gcc-flags-for-build.patch
patching file Makefile.def
patching file gcc/Makefile.in
Hunk #1 succeeded at 755 (offset -11 lines).
patching file gcc/configure.ac
Hunk #1 succeeded at 1774 (offset -24 lines).
patching file Makefile.in
patching file gcc/configure
Hunk #1 succeeded at 705 (offset -2 lines).
Hunk #2 succeeded at 10912 (offset -71 lines).
Hunk #3 succeeded at 10920 (offset -71 lines).
Hunk #4 FAILED at 17111.
Hunk #5 FAILED at 17217.
2 out of 5 hunks FAILED -- rejects in file gcc/configure
patching file Makefile.tpl
patching file configure
Hunk #2 succeeded at 7950 (offset -87 lines).
Hunk #3 succeeded at 8016 (offset -87 lines).
patching file configure.ac
Hunk #1 succeeded at 3053 (offset -36 lines).
Hunk #2 succeeded at 3120 (offset -36 lines).
Patch gcc-flags-for-build.patch does not apply (enforce with -f)

ERROR: Error in executing python function in: /opt/local/oe_mb/openembedded/recipes/gcc/gcc-cross-initial_4.5.bb
ERROR: Exception:<type 'exceptions.SystemExit'> Message:1
ERROR: Printing the environment of the function
ERROR: Function patch_do_patch failed
ERROR: TaskFailed event exception, aborting
ERROR: Build of /opt/local/oe_mb/openembedded/recipes/gcc/gcc-cross-initial_4.5.bb do_patch failed ERROR: Task 707 (/opt/local/oe_mb/openembedded/recipes/gcc/gcc-cross-initial_4.5.bb, do_patch) failed with 256 FATAL: Execution of 'quilt --quiltrc=/opt/local/oe_mb/tmp/sysroots/x86_64-linux/usr/bin/quiltrc push' failed with exit code 1:
Applying patch gcc-flags-for-build.patch
patching file Makefile.def
patching file gcc/Makefile.in
Hunk #1 succeeded at 755 (offset -11 lines).
patching file gcc/configure.ac
Hunk #1 succeeded at 1774 (offset -24 lines).
patching file Makefile.in
patching file gcc/configure
Hunk #1 succeeded at 705 (offset -2 lines).
Hunk #2 succeeded at 10912 (offset -71 lines).
Hunk #3 succeeded at 10920 (offset -71 lines).
Hunk #4 FAILED at 17111.
Hunk #5 FAILED at 17217.
2 out of 5 hunks FAILED -- rejects in file gcc/configure
patching file Makefile.tpl
patching file configure
Hunk #2 succeeded at 7950 (offset -87 lines).
Hunk #3 succeeded at 8016 (offset -87 lines).
patching file configure.ac
Hunk #1 succeeded at 3053 (offset -36 lines).
Hunk #2 succeeded at 3120 (offset -36 lines).
Patch gcc-flags-for-build.patch does not apply (enforce with -f)

ERROR: TaskFailed event exception, aborting
ERROR: Build of virtual:native:/opt/local/oe_mb/openembedded/recipes/bison/bison_2.4.3.bb do_configure failed
----------------------------------------------------------------

Moreover, those are all things which I hacked in several files of OE to get this point where I am:

local.conf ->
----------------------------------------------------------------
MACHINE = "xilinx-ml605"
TARGET_ARCH = "microblaze"
TARGET_CPU = "microblaze"
TARGET_TUNE = "microblaze"
XILINX_BSP_PATH =
XILINX_BOARD = "ml507"
...
----------------------------------------------------------------

xilinx-ml605.conf ->
----------------------------------------------------------------
TARGET_ARCH = "microblaze"
TARGET_CPU = "microblaze"
TARGET_TUNE = "microblaze"
TARGET_FPU = "soft"
#tune for the microblaze cpu
require conf/machine/include/tune-microblaze.inc
PREFERRED_PROVIDER_virtual/kernel = "linux-xilinx"
KERNEL_IMAGETYPE = "uImage"
MACHINE_FEATURES = "kernel26 apm ext2 vfat ethernet screen"
MACHINE_EXTRA_RECOMMENDS = "kernel-modules"
UBOOT_ENTRYPOINT ?= "0x00000000"
UBOOT_LOADADDRESS ?= "0x00000000"
PREFERRED_VERSION_u-boot_xilinx-virtex5 = "u-boot-xilinx"
...
----------------------------------------------------------------

siteinfo.bbclass ->
----------------------------------------------------------------
def siteinfo_data(d):
    archinfo = {
        ...
        "ppc64": "endian-big bit-64 powerpc-common powerpc64-linux",
        "microblaze": "endian-big bit-32 powerpc-common",
        "sh3": "endian-little bit-32 sh-common",
    }

...
----------------------------------------------------------------

xilinx-bsp.bbclass ->
----------------------------------------------------------------
def map_target(a, d):
        import re
        board = bb.data.getVar('XILINX_BOARD', d, 1)
        cpu = bb.data.getVar('TARGET_CPU', d, 1)

        if re.match('powerpc', a):
                return 'ppc' + cpu + '-' + board
        elif re.match('microblaze', a):
                return 'microblaze' + '-' + board
        else:
                return 'system'

...
----------------------------------------------------------------

kernel-arch.bbclass ->
----------------------------------------------------------------
valid_archs = "alpha cris ia64 \
               ...
               m68knommu m68k ppc powerpc ppc64  \
               microblaze  \
               sparc sparc64 \
               ...
...
----------------------------------------------------------------

gcc-4.5.inc ->
----------------------------------------------------------------
# BRANCH = "gcc-4_5-branch"
BRANCH = "microblaze"
PR_append = "+svnr${SRCPV}"
...
----------------------------------------------------------------

Would you please let me know where the source of problem might be and how I may supposed to resolve it?

Thanks in advanced.

Best regards,
Ali


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.



_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

Reply via email to