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.

AM62P: Missing 32-Bit Library Files Causing Build Errors in SDK (arago-2023.10)

Part Number: AM62P

Tool/software:

Hello,

We are encountering fatal build errors while compiling our application due to missing 32-bit library headers in the SDK arago-2023.10-toolchain-2023.10.sh. These errors are blocking the build process and preventing the application from launching.

The build errors indicate that the following 32-bit library headers are not present:

  • bits/typesizes-32.h
  • bits/timesize-32.h
  • bits/long-double-32.h
  • bits/floatn-32.h
  • bits/endian-32.h
  • bits/endianness-32.h
  • bits/pthreadtypes-32.h
  • bits/pthreadtypes-arch-32.h
  • bits/struct_rwlock-32.h
  • bits/setjmp-32.h
  • bits/local_lim-32.h

/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/typesizes.h:23:10: fatal error: bits/typesizes-32.h: No such file or directory
   23 | #include <bits/typesizes-32.h>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/timesize.h:23:10: fatal error: bits/timesize-32.h: No such file or directory
   23 | #include <bits/timesize-32.h>
      |          ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/timesize.h:23:10: fatal error: bits/timesize-32.h: No such file or directory
   23 | #include <bits/timesize-32.h>
      |          ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/long-double.h:23:10: fatal error: bits/long-double-32.h: No such file or directory
   23 | #include <bits/long-double-32.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/typesizes.h:23:10: fatal error: bits/typesizes-32.h: No such file or directory
   23 | #include <bits/typesizes-32.h>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/floatn.h:23:10: fatal error: bits/floatn-32.h: No such file or directory
   23 | #include <bits/floatn-32.h>
      |          ^~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/floatn.h:23:10: fatal error: bits/floatn-32.h: No such file or directory
   23 | #include <bits/floatn-32.h>
      |          ^~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/endian.h:23:10: fatal error: bits/endian-32.h: No such file or directory
   23 | #include <bits/endian-32.h>
      |          ^~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/endianness.h:23:10: fatal error: bits/endianness-32.h: No such file or directory
   23 | #include <bits/endianness-32.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/pthreadtypes.h:23:10: fatal error: bits/pthreadtypes-32.h: No such file or directory
   23 | #include <bits/pthreadtypes-32.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/pthreadtypes-arch.h:23:10: fatal error: bits/pthreadtypes-arch-32.h: No such file or directory
   23 | #include <bits/pthreadtypes-arch-32.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/struct_rwlock.h:23:10: fatal error: bits/struct_rwlock-32.h: No such file or directory
   23 | #include <bits/struct_rwlock-32.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/setjmp.h:23:10: fatal error: bits/setjmp-32.h: No such file or directory
   23 | #include <bits/setjmp-32.h>
      |          ^~~~~~~~~~~~~~~~~~
compilation terminated.
/opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/local_lim.h:23:10: fatal error: bits/local_lim-32.h: No such file or directory
   23 | #include <bits/local_lim-32.h>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.

Platform Details:

  • Architecture: 64-bit
  • Multilib: Enabled
  • SDK: arago-2023.10-toolchain-2023.10.sh

The errors occur even though multilib support is enabled in our environment, and the system architecture is 64-bit. It appears that the required 32-bit libraries are either missing or not properly included in the SDK.

Could you please assist us in understanding why these headers are missing and provide guidance on how to resolve this issue? If additional steps are needed to ensure 32-bit compatibility for our 64-bit platform, kindly provide details.

  • Hi Angelin,

    Which exact SDK version are you basing your work on?

    Do you have a "minimum application" you can provide that I can build against the devkit that shows your typical failures? Perhaps something as simple as a basic main.c file that includes a one of the headers you are expecting?

    Regards, Andreas

  • Hi Andreas,

    We are using the following SDK version for our work:

    • Yocto config using: processor-sdk-scarthgap-10.00.07.04-config.txt

    • Version: 10.00.07.04

    • SDK Version: arago-2023.10-toolchain-2023.10.sh
    • Location: /opt/arago-2023.10

    Below is a minimal C++ application (main.cpp) that reproduces the issue related to timesize-32.h in the timesize.h file:

    #include <bits/timesize.h>
    #include <iostream>

    int main() {
    std::cout << "Testing timesize.h inclusion" << std::endl;
    return 0;
    }

    When we attempt to compile this C++ application using the SDK, the following error occurs:

    /opt/arago-2023.10/sysroots/aarch64-oe-linux/usr/include/bits/timesize.h:23:10: fatal error: bits/timesize-32.h: No such file or directory
       23 | #include <bits/timesize-32.h>
          |          ^~~~~~~~~~~~~~~~~~~~
    compilation terminated.
    

    The issue appears to originate from the logic in timesize.h that attempts to include timesize-32.h based on the __WORDSIZE definition:

    #include <bits/wordsize.h>
    
    #if __WORDSIZE == 32
    
    #ifdef _MIPS_SIM
    
    #if _MIPS_SIM == _ABIO32
    #include <bits/timesize-32.h>
    #elif _MIPS_SIM == _ABIN32
    #include <bits/timesize-n32.h>
    #else
    #error "Unknown _MIPS_SIM"
    #endif
    
    #else /* _MIPS_SIM is not defined */
    #include <bits/timesize-32.h>
    #endif
    
    #elif __WORDSIZE == 64
    #include <bits/timesize-64.h>
    #else
    #error "Unknown __WORDSIZE detected"
    #endif /* matches #if __WORDSIZE == 32 */
      

    Even though our platform is 64-bit, the build is attempting to include the 32-bit-specific header timesize-32.h, which is missing from the SDK.

    Please let me know if you need further details or additional examples.

    Best regards,

    Angelin Christy 

  • Ok thanks for the additional details. Will look into it very soon.

    Regards, Andreas

  • Hi Angelin,

    I just tried this in the context of SDK v10.1, but had no issues building your little sample program, please see below steps:

    # Create test source
    a0797059@jiji:~/ti/ti-processor-sdk-linux-am62pxx-evm-10.01.10.04/linux-devkit
    $ cat <<EOF > main.cpp
    > #include <bits/timesize.h>
    #include <iostream>
    
    int main() {
    std::cout << "Testing timesize.h inclusion" << std::endl;
    return 0;
    }
    > EOF
    
    # Double-check test source
    a0797059@jiji:~/ti/ti-processor-sdk-linux-am62pxx-evm-10.01.10.04/linux-devkit
    $ cat main.cpp
    #include <bits/timesize.h>
    #include <iostream>
    
    int main() {
    std::cout << "Testing timesize.h inclusion" << std::endl;
    return 0;
    }
    
    # Source the devkit environment
    a0797059@jiji:~/ti/ti-processor-sdk-linux-am62pxx-evm-10.01.10.04/linux-devkit
    $ source environment-setup
    
    # Double-check to make sure compiler flags got set
    [linux-devkit]:~/ti/ti-processor-sdk-linux-am62pxx-evm-10.01.10.04/linux-devkit> echo $CXXFLAGS
    -mbranch-protection=standard --sysroot=/home/a0797059/ti/ti-processor-sdk-linux-am62pxx-evm-10.01.10.04/linux-devkit/sysroots/aarch64-oe-linux
    
    # Build test code
    [linux-devkit]:~/ti/ti-processor-sdk-linux-am62pxx-evm-10.01.10.04/linux-devkit> $CXX main.cpp
    
    # Take a quick look at the generated file
    [linux-devkit]:~/ti/ti-processor-sdk-linux-am62pxx-evm-10.01.10.04/linux-devkit> file a.out
    a.out: ELF 64-bit LSB executable, ARM aarch64, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-aarch64.so.1, BuildID[sha1]=757ee3a8476e1f175b9cc9ca4027b19e88f1fb06, for GNU/Linux 5.15.0, with debug_info, not stripped

    Can you try to re-create this?

    Regards, Andreas