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.

DM3730: Arago tutorial failing - what am I missing (or stick with Poky?)

Part Number: DM3730

Tool/software:

Hi, 

I'm trying to upgrade our build as far as I can, for the DM3730 - we need it to support some better versions of display packages which aren't compatible with GCC version and kernel in the SDK. A former colleague worked on getting it to build in Poky with Fido, and I started investigating moving to Arago to have better integration with the TI system and current documentation (and to have a common build system of our other board, which never had to go that low/old of a release), as we want to support some better packages on the device. I ended up getting some toolchain errors, even when I'm following the Arago/TI tutorial https://lists.yoctoproject.org/g/meta-arago/wiki/29503#Cross-compile_toolchain. I have downloaded the arago-2011.08/armv7a and arm5te toolchains and added them to the path, just to cover my bases: `PATH=$HOME/tisdk/sources/oe-core/scripts:$HOME/arago-2011.09/armv5te::$HOME/arago-2011.09/armv7a:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin`. I currently have a minimal 12.04 Dockerfile setup as below, and have set up with `./oe-layertool-setup.sh -f configs/arago-fido-config.txt`.

I know it's not super related to the processor yet and is more of a general "arago" question, but I am really not sure of what's going on, since this is failing the basic setup steps. Is there something silly about my setup? Or are releases that old broken? Should I be continuing on Poky to newer releases? I am still deep in the learning phase so I'm still trying to figure out the best path forward especially when old wikis are no longer published. (http://arago-project.org/wiki)

# WARNING: This script should NEVER BE RUN WITH A DOCKER THAT ISN'T ROOTLESS!

# Use Ubuntu as the base layer.
FROM docker.io/ubuntu:12.04

# Set up environment variables for:
ENV LC_ALL=C \
LANG=C \
LANGUAGE=C

RUN sed -i s/archive/old-releases/g etc/apt/sources.list

RUN apt-get update -y && apt-get upgrade -y


ARG PACKAGES="time \
vim-tiny emacs \
screen \
gawk wget git-core diffstat unzip texinfo gcc-multilib \
build-essential chrpath socat \
python \
"

# web.archive.org/.../Setting_Up_Build_Environment
RUN apt-get install -y git build-essential diffstat texinfo gawk chrpath ${PACKAGES}

RUN echo "dash dash/sh boolean false" | debconf-set-selections && \
DEBIAN_FRONTEND=noninteractive dpkg-reconfigure dash

# Define the default container command, which is to open a bash shell.
CMD ["/bin/bash"]

$HOME/arago-2011.09/armv5te:
README arm-arago-linux-gnueabi bin environment-setup etc i686-linux include lib libexec share site-config usr version

$HOME/arago-2011.09/armv7a:
README arm-arago-linux-gnueabi bin environment-setup etc i686-linux include lib libexec share site-config usr version

$USER@CONTAINER:~/tisdk/build$ export PATH=$HOME/arago-2011.09/armv7a/bin:$HOME/arago-2011.09/armv5te:$PATH
$USER@CONTAINER:~/tisdk/build$ source conf/setenv
$USER@CONTAINER:~/tisdk/build$ bitbake ...
ERROR: No valid toolchain in PATH
ERROR: Traceback (most recent call last):
  File "$HOME/tisdk/sources/bitbake/lib/bb/cookerdata.py", line 175, in wrapped
    return func(fn, *args)
  File "$HOME/tisdk/sources/bitbake/lib/bb/cookerdata.py", line 185, in parse_config_file
    return bb.parse.handle(fn, data, include)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/__init__.py", line 107, in handle
    return h['handle'](fn, data, include)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/parse_py/ConfHandler.py", line 149, in handle
    statements.eval(data)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/ast.py", line 39, in eval
    statement.eval(data)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/ast.py", line 63, in eval
    bb.parse.ConfHandler.include(self.filename, s, self.lineno, data, False)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/parse_py/ConfHandler.py", line 95, in include
    ret = bb.parse.handle(fn, data, True)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/__init__.py", line 107, in handle
    return h['handle'](fn, data, include)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/parse_py/ConfHandler.py", line 149, in handle
    statements.eval(data)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/ast.py", line 39, in eval
    statement.eval(data)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/ast.py", line 61, in eval
    bb.parse.ConfHandler.include(self.filename, s, self.lineno, data, "include required")
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/parse_py/ConfHandler.py", line 95, in include
    ret = bb.parse.handle(fn, data, True)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/__init__.py", line 107, in handle
    return h['handle'](fn, data, include)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/parse_py/BBHandler.py", line 156, in handle
    statements.eval(d)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/ast.py", line 39, in eval
    statement.eval(data)
  File "$HOME/tisdk/sources/bitbake/lib/bb/parse/ast.py", line 111, in eval
    val = e.expand(groupd["value"], key + "[:=]")
  File "$HOME/tisdk/sources/bitbake/lib/bb/data_smart.py", line 355, in expand
    return self.expandWithRefs(s, varname).value
  File "$HOME/tisdk/sources/bitbake/lib/bb/data_smart.py", line 345, in expandWithRefs
    raise ExpansionError(varname, s, exc)
ExpansionError: Failure expanding variable TOOLCHAIN_PATH[:=], expression was ${@bool(d.getVar('TOOLCHAIN_SYSPATH', d, 1)) and (os.path.exists(d.getVar('TOOLCHAIN_SYSPATH', d, 1)) and os.path.dirname(d.getVar('TOOLCHAIN_SYSPATH', d, 1)) or bb.fatal('No valid toolchain in PATH')) or ''} which triggered exception BBHandledException:

ERROR: Unable to parse conf/bitbake.conf: Failure expanding variable TOOLCHAIN_PATH[:=], expression was ${@bool(d.getVar('TOOLCHAIN_SYSPATH', d, 1)) and (os.path.exists(d.getVar('TOOLCHAIN_SYSPATH', d, 1)) and os.path.dirname(d.getVar('TOOLCHAIN_SYSPATH', d, 1)) or bb.fatal('No valid toolchain in PATH')) or ''} which triggered exception BBHandledException:
$USER@CONTAINER:~/tisdk/build$
USER@CONTAINER:~/tisdk/build$ arm-arago-linux-gnueabi-gcc --version
arm-arago-linux-gnueabi-gcc (GCC) 4.5.3 20110311 (prerelease)
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  • I also forgot to add: TI SDK was cloned at commit 9b78d5665371335e72e69662c984cae9a52e95ad, and `./oe-layertool-setup.sh -f configs/arago-fido-config.txt` completed without error.

  • Hello Nicole,

    Just to set expectations up front, the last software release TI did on DM3730 was 14 years ago: https://www.ti.com/tool/LINUXDVSDK-DM37X So unfortunately we are unable to answer any software or hardware design questions about this part.

    I will reassign your thread to a team member who is familiar with using Yocto with newer parts, just in case they have any ideas about Yocto in general. However, please keep in mind that their answer might be "sorry, we cannot comment".

    Regards,

    Nick

  • Hi Nicole,
    some quick things to double-check here:

    $USER@CONTAINER:~/tisdk/build$ export PATH=$HOME/arago-2011.09/armv7a/bin:$HOME/arago-2011.09/armv5te:$PATH

    After executing this line, can you try running those toolchains directly from the command prompt to see if they are working and accessible?

    Something like this should give you a GCC configuration dump (this is from my current system, your cross compiler name is probably different):

    $ arm-none-linux-gnueabihf-gcc -v
    Using built-in specs.
    COLLECT_GCC=/opt/arm-gnu-toolchain-13.3.rel1-x86_64-arm-none-linux-gnueabihf/bin/arm-none-linux-gnueabihf-gcc
    COLLECT_LTO_WRAPPER=/opt/arm-gnu-toolchain-13.3.rel1-x86_64-arm-none-linux-gnueabihf/bin/../libexec/gcc/arm-none-linux-gnueabihf/13.3.1/lto-wrapper
    Target: arm-none-linux-gnueabihf
    Configured with: /data/jenkins/workspace/GNU-toolchain/arm-13/src/gcc/configure --target=arm-none-linux-gnueabihf --prefix= --with-sysroot=/arm-none-linux-gnueabihf/libc --with-build-sysroot=/data/jenkins/workspace/GNU-toolchain/arm-13/build-arm-none-linux-gnueabihf/install//arm-none-linux-gnueabihf/libc --with-bugurl=https://bugs.linaro.org/ --enable-gnu-indirect-function --enable-shared --disable-libssp --disable-libmudflap --enable-checking=release --enable-languages=c,c++,fortran --with-gmp=/data/jenkins/workspace/GNU-toolchain/arm-13/build-arm-none-linux-gnueabihf/host-tools --with-mpfr=/data/jenkins/workspace/GNU-toolchain/arm-13/build-arm-none-linux-gnueabihf/host-tools --with-mpc=/data/jenkins/workspace/GNU-toolchain/arm-13/build-arm-none-linux-gnueabihf/host-tools --with-isl=/data/jenkins/workspace/GNU-toolchain/arm-13/build-arm-none-linux-gnueabihf/host-tools --with-arch=armv7-a --with-fpu=neon --with-float=hard --with-mode=thumb --with-arch=armv7-a --with-pkgversion='Arm GNU Toolchain 13.3.Rel1 (Build arm-13.24)'
    Thread model: posix
    Supported LTO compression algorithms: zlib
    gcc version 13.3.1 20240614 (Arm GNU Toolchain 13.3.Rel1 (Build arm-13.24))

    # Use Ubuntu as the base layer.
    FROM docker.io/ubuntu:12.04

    Something to double-check here. There seems to be 64-bit and 32-bit versions of Ubuntu 12. If your image is 64 bits ('amd64') you need to install the install the 32-bit support libraries as per the webarchive link you had. If the toolchain/versions are not compatible it may look like the file can't be found.

    Regards, Andreas

  • Thanks Andreas and Nick - 

    I think this helped me get onto the right track. Because the original linaro toolchain download wasn't available, I downloaded a slightly newer one. I had to change my EXTERNAL_TOOLCHAIN path in sources/meta-linaro/meta-linaro-toolchain/conf/distro/include/tcmode-external-linaro.inc. The version string was also causing a crash when parsed (by sources/meta-linaro/meta-linaro-toolchain/conf/distro/include/external-linaro-toolchain-versions.inc) because it was at version.split()[2], and it was expecting more strings than 5, so it crashed.

    That being sad, I'm likely just going to jump up versions, especially seeing as the meta-linaro-toolchain turns to meta-arm-toolchain in a few releases, and I've been walking our poky distro up versions, so I might try to switch over again on Dunfell or something newer. 

    Thanks for your help!

    ...tdisdk/build$ arm-none-linux-gnueabihf-gcc -v
    Using built-in specs.
    COLLECT_GCC=arm-none-linux-gnueabihf-gcc
    Target: arm-arago-linux-gnueabi
    Configured with: /home/a0868396/toolchain/arago-tmp/work/i686-armv7a-sdk-arago-linux-gnueabi/gcc-cross-sdk-4.5-r41.2+svnr170880-arago1/gcc-4_5-branch/configure --build=i686-linux --host=i686-linux --target=arm-arago-linux-gnueabi --prefix=/arago-2011.09/armv7a --exec_prefix=/arago-2011.09/armv7a --bindir=/arago-2011.09/armv7a/bin --sbindir=/arago-2011.09/armv7a/bin --libexecdir=/arago-2011.09/armv7a/libexec --datadir=/arago-2011.09/armv7a/share --sysconfdir=/arago-2011.09/armv7a/etc --sharedstatedir=/arago-2011.09/armv7a/share/com --localstatedir=/arago-2011.09/armv7a/var --libdir=/arago-2011.09/armv7a/lib --includedir=/arago-2011.09/armv7a/include --oldincludedir=/arago-2011.09/armv7a/include --infodir=/arago-2011.09/armv7a/share/info --mandir=/arago-2011.09/armv7a/share/man --enable-largefile --disable-nls --enable-ipv6 --with-gnu-ld --enable-shared --enable-languages=c,c++,objc,fortran --enable-threads=posix --disable-multilib --enable-c99 --enable-long-long --enable-symvers=gnu --enable-libstdcxx-pch --program-prefix=arm-arago-linux-gnueabi- --enable-target-optspace --enable-lto --enable-libssp --disable-bootstrap --disable-libgomp --disable-libmudflap --with-float=softfp --with-sysroot=/arago-2011.09/armv7a/arm-arago-linux-gnueabi --with-build-time-tools=/home/a0868396/toolchain/arago-tmp/sysroots/i686-linux/usr/armv7a/arm-arago-linux-gnueabi/bin --with-build-sysroot=/home/a0868396/toolchain/arago-tmp/sysroots/armv7a-arago-linux-gnueabi --disable-libunwind-exceptions --with-mpfr=/home/a0868396/toolchain/arago-tmp/sysroots/i686-linux/usr --with-system-zlib --enable-__cxa_atexit --with-ppl=no --with-cloog=no
    Thread model: posix
    gcc version 4.5.3 20110311 (prerelease) (GCC)