This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Build issues with Linux Kernel 3.12.10 for Debug

Hi,

i am using ccsv5.3 and sdk7 for am335x-evm Starter Kit. i followed the steps in the given link

http://processors.wiki.ti.com/index.php/Sitara_Linux_Training:_uboot_linux_debug_with_ccsv5_sdk7

but i get error message like this.

pls help

-------------------------------------------------------------------------------------------------------------------------------------------------------

jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$ make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- zImage


scripts/kconfig/conf --silentoldconfig Kconfig
warning: (SOC_OMAP5 && SOC_DRA7XX) selects ARM_ERRATA_799270 which has unmet direct dependencies (CPU_V7 && SMP)
warning: (SOC_OMAP5 && SOC_DRA7XX) selects ARM_ERRATA_799270 which has unmet direct dependencies (CPU_V7 && SMP)
  CHK     include/config/kernel.release
  UPD     include/config/kernel.release
  WRAP    arch/arm/include/generated/asm/auxvec.h
  WRAP    arch/arm/include/generated/asm/bitsperlong.h
  WRAP    arch/arm/include/generated/asm/cputime.h
  WRAP    arch/arm/include/generated/asm/current.h
  WRAP    arch/arm/include/generated/asm/emergency-restart.h
  WRAP    arch/arm/include/generated/asm/errno.h
  WRAP    arch/arm/include/generated/asm/exec.h
  WRAP    arch/arm/include/generated/asm/ioctl.h
  WRAP    arch/arm/include/generated/asm/ipcbuf.h
  WRAP    arch/arm/include/generated/asm/irq_regs.h
  WRAP    arch/arm/include/generated/asm/kdebug.h
  WRAP    arch/arm/include/generated/asm/local.h
  WRAP    arch/arm/include/generated/asm/local64.h
  WRAP    arch/arm/include/generated/asm/msgbuf.h
  WRAP    arch/arm/include/generated/asm/param.h
  WRAP    arch/arm/include/generated/asm/parport.h
  WRAP    arch/arm/include/generated/asm/poll.h
  WRAP    arch/arm/include/generated/asm/resource.h
  WRAP    arch/arm/include/generated/asm/sections.h
  WRAP    arch/arm/include/generated/asm/segment.h
  WRAP    arch/arm/include/generated/asm/sembuf.h
  WRAP    arch/arm/include/generated/asm/serial.h
  WRAP    arch/arm/include/generated/asm/shmbuf.h
  WRAP    arch/arm/include/generated/asm/siginfo.h
  WRAP    arch/arm/include/generated/asm/sizes.h
  WRAP    arch/arm/include/generated/asm/socket.h
  WRAP    arch/arm/include/generated/asm/sockios.h
  WRAP    arch/arm/include/generated/asm/termbits.h
  WRAP    arch/arm/include/generated/asm/termios.h
  WRAP    arch/arm/include/generated/asm/timex.h
  WRAP    arch/arm/include/generated/asm/trace_clock.h
  WRAP    arch/arm/include/generated/asm/unaligned.h
  CHK     include/generated/uapi/linux/version.h
  UPD     include/generated/uapi/linux/version.h
  CHK     include/generated/utsrelease.h
  UPD     include/generated/utsrelease.h
  Generating include/generated/mach-types.h
  CC      kernel/bounds.s
  GEN     include/generated/bounds.h
  CC      arch/arm/kernel/asm-offsets.s
  GEN     include/generated/asm-offsets.h
  CALL    scripts/checksyscalls.sh
  HOSTCC  scripts/dtc/checks.o
  HOSTCC  scripts/dtc/data.o
  SHIPPED scripts/dtc/dtc-lexer.lex.c
  SHIPPED scripts/dtc/dtc-parser.tab.h
  HOSTCC  scripts/dtc/dtc-lexer.lex.o
  SHIPPED scripts/dtc/dtc-parser.tab.c
  HOSTCC  scripts/dtc/dtc-parser.tab.o
  HOSTCC  scripts/dtc/dtc.o
  HOSTCC  scripts/dtc/flattree.o
  HOSTCC  scripts/dtc/fstree.o
  HOSTCC  scripts/dtc/livetree.o
  HOSTCC  scripts/dtc/srcpos.o
  HOSTCC  scripts/dtc/treesource.o
  HOSTCC  scripts/dtc/util.o
  HOSTLD  scripts/dtc/dtc
  HOSTCC  scripts/genksyms/genksyms.o
  SHIPPED scripts/genksyms/lex.lex.c
  SHIPPED scripts/genksyms/keywords.hash.c
  SHIPPED scripts/genksyms/parse.tab.h
  HOSTCC  scripts/genksyms/lex.lex.o
  SHIPPED scripts/genksyms/parse.tab.c
  HOSTCC  scripts/genksyms/parse.tab.o
  HOSTLD  scripts/genksyms/genksyms
  CC      scripts/mod/empty.o
as: unrecognized option '-EL'
make[2]: *** [scripts/mod/empty.o] Error 1
make[1]: *** [scripts/mod] Error 2
make: *** [scripts] Error 2
jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$

thanks

jawahar Krishnamoorthi

  • Hi Jawahar,

    Please start fresh. First export the needed environment variables:

    export CROSS_COMPILE=arm-linux-gnueabihf-
    export ARCH=arm

    Then add your toolchain folder to the $PATH variable:

    export PATH=$PATH:$HOME/ti-sdk-am335x-evm-07.00.00.00/linux-devkit/sysroots/i686-arago-linux/usr/bin

    Then, from the linux root folder, run:

    make tisdk_am335x-evm_defconfig

    Then add the debug configurations mentioned in the wiki page, be sure to correctly edit the Makefile and run:

    make zImage

    The zImage file will be generated inside <linux_dir>/arch/arm/boot/zImage.

    Best regards,
    Miroslav

  •  hi Miroslav,

    Thanks for your reply. i still get the same error. pls help
     

    -----------------------------------------------------------------

    CC      scripts/mod/empty.o
    as: unrecognized option '-EL'
    make[2]: *** [scripts/mod/empty.o] Error 1
    make[1]: *** [scripts/mod] Error 2
    make: *** [scripts] Error 2
    -------------------------------------------------------------------

    thanks

    Jawahar Krishnamoorthi

  • It seems like your build is calling the host system's "as" and not the "arm-linux-gnueabihf-as" from the cross compile toolchain.

    Can you please print the CROSS_COMPILE and PATH environment variables and post them here:

    echo $CROSS_COMPILE
    echo $PATH

    Best regards,
    Miroslav

  • Hi Miroslav

    Thanks for your reply.

    this is what i get.

    jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$ echo $CROSS_COMPILE
    arm-linux-gnueabihf-
    jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$ echo $PATH
    /usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/jawahar/sitara/ti-sdk-am335x-evm-07.00.00.00/linux-devkit/sysroots/i686-arago-linux/usr/bin
    jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$

    Thanks

    jawahar krishnamoorthi

  • Your environment seems normal. Can you please let me know what the output of the following command is:

    which arm-linux-gnueabihf-as

    Best regards,
    Miroslav

  • Hi Jawahar,

    Could you please provide us your host system (PC) informations?

    arch, os etc.,

  • Hi Miroslav

    Thanks for your reply.

    this is what i get.

    jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$ which arm-linux-gnueabihf-as


    /usr/bin/arm-linux-gnueabihf-as

    Thanks

    jawahar Krishnamoorthi

  • Jawahar, this doesn't seem exactly right. Can you please check if this isn't a soft link to the systems "as"? Do:

    ls -la /usr/bin/arm-linux-gnueabihf-as

    To make your system use the correct arm-linux-gnueabihf-as from the SDK's toolchain folder you should prepend and not append the toolchain path when you export the $PATH variable.

    Best regards,
    Miroslav

  • Hi.

    Thank you for your reply.

    OS: UBUNTU 12.04 LTS / 32 Bit

    Core: Intel® Pentium(R) Dual CPU E2180 @ 2.00GHz × 2

    Disk:236.2 GB

    Thanks

    Jawahar Krishnamoorthi

  • Hi Miroslav

    Thanks for the reply. i get the output like this.

    jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$ ls -la /usr/bin/arm-linux-gnueabihf-as
    -rwxr-xr-x 2 root root 569172 Apr 17  2012 /usr/bin/arm-linux-gnueabihf-as

    Thanks

    Jawahar Krishnamoorthi

  • There is a huge difference in the sizes of your version of the -as file and the one included in the toolchain from the SDK.

    Please try this:

    export PATH=$HOME//sitara/ti-sdk-am335x-evm-07.00.00.00/linux-devkit/sysroots/i686-arago-linux/usr/bin/:$PATH

    Then verify that the arm-linux-gnueabihf-as is the correct one with:

    which arm-linux-gnueabihf-as

    Then build again.

    Best regards,
    Miroslav

  • Hi Miroslav,

    jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$ echo $CROSS_COMPILE
    arm-linux-gnueabihf-
    jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$ echo $PATH
    /usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/home/jawahar/sitara/ti-sdk-am335x-evm-07.00.00.00/linux-devkit/sysroots/i686-arago-linux/usr/bin
    jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$


    jawahar@jawahar-desktop:~/sitara/ti-sdk-am335x-evm-07.00.00.00/board-support/linux-3.12.10-ti2013.12.01$ which arm-linux-gnueabihf-as


    /usr/bin/arm-linux-gnueabihf-as


    Jawahar should get like below output of "arm-linux-gnueabihf-as" if he exported the toolchain properly,

    /home/jawahar/sitara/ti-sdk-am335x-evm-07.00.00.00/linux-devkit/sysroots/i686-arago-linux/usr/bin/arm-linux-gnueabihf-as

    I hope that Jawahar had multiple copies of toolchains in different places in his host machine.

    Please correct me if I'm wrong.

  • Hi Miroslav

    Its Working... Thank you very much.

     OBJCOPY arch/arm/boot/zImage
      Kernel: arch/arm/boot/zImage is ready

    Thanks

    Jawahar Krishnamoorthi