Unresolved symbols and conflicting types on master branch !

  • Hi,

    I am building the libreELEC-AML image from a clean environment and I am getting unresolved symbols and conflicting types. Any idea on what is going wrong ?

    Environment setup:

    $ git clone https://github.com/dtechsrv/LibreELEC-AML libreELEC-AML

    $ cd libreELEC-AML

    $ git status

    On branch master Your branch is up to date with 'origin/master'. nothing to commit, working tree clean

    Build command (it's the only option for s905):

    $ PROJECT=S905 ARCH=aarch64 DEVICE=KI-Plus make image

    Lots of errors similar to this:

    [ 242/2142] Compiling IDL librpc/idl/initshutdown.idl

    build.LibreELEC-KI-Plus.aarch64-9.2.8.3/samba-4.9.18/librpc/idl/auth.idl:107: error: Unable to determine origin of type

    'struct cli_credentials'

    Conflicting types error leading to make failure:

    [ 321/2142] Compiling IDL source4/librpc/idl/irpc.idl

    make[1]: Entering directory 'libreELEC-AML/build.LibreELEC-KI-Plus.aarch64-9.2.8.3/u-boot-tools-aml-2016.03'

    /usr/include/libfdt_env.h:27:30: error: conflicting types for 'fdt64_t'

    27 | typedef uint64_t FDT_BITWISE fdt64_t;

    | ^~~~~~~

    In file included from <command-line>:

    ././include/libfdt_env.h:19:16: note: previous declaration of 'fdt64_t' was here

    19 | typedef __be64 fdt64_t;

    | ^~~~~~~

    So header files from /usr/include/ are conflicting with ./build.LibreELEC-KI-Plus.aarch64-9.2.8.3/u-boot-tools-aml-2016.03/include/

    By the way I am able to build from this https://github.com/LibreELEC/LibreELEC.tv but my box is not supported so I'm trying LibreELEC-AML.

    Regards.

    Edited once, last by frigOS (March 1, 2022 at 12:43 AM).

  • Build command (it's the only option for s905):


    $ PROJECT=S905 ARCH=aarch64 DEVICE=KI-Plus make image

    Well, that’s not the "only" option, in fact, it won't work either. Even LE9.0 did not support native 64-bit builds for amlogic devices.

    Try this:

    Code: cat build.sh | grep KI-Plus
    PROJECT=S905 DEVICE=KI-Plus ARCH=arm make image -j8
  • I wiped out everything again and started fresh from new git + PROJECT=S905 DEVICE=KI-Plus ARCH=arm make image and make fails at the exact same place :(

    I'm compiling on Kubuntu 20.04 Any idea why /usr/include conflicts with the project ?

    Well, that’s not the "only" option, in fact, it won't work either. Even LE9.0 did not support native 64-bit builds for amlogic devices.

    Try this:

    Code: cat build.sh | grep KI-Plus
    PROJECT=S905 DEVICE=KI-Plus ARCH=arm make image -j8

    Interrestingly enough omitting ARCH on make statement suggest aarch64 as the only valid choice but that doesn't fix my problem.

    Code
    PROJECT=S905 DEVICE=KI-Plus make image
    =================================================================================
    ERROR: Architecture not found, use a valid Architecture
    for your project or create a new config
    =================================================================================
    Valid Architectures for your project: S905
    - aarch64

    Regards

  • I wiped out everything again and started fresh from new git + PROJECT=S905 DEVICE=KI-Plus ARCH=arm make image and make fails at the exact same place :(

    Google can help diagnose compilation issues, because in most cases these are related to the operating system or kernel, possibly gcc, or depends on a not-installed or conflicts with an installed *-dev package on your system. The number of options is quite a lot, so the easiest is to drop the resulting error into Google.

    I searched for it too, and this is one of the possible reasons that the libfdt-dev package is installed on your system and conflicts with it. I used Debian 10.10 for the last build and I don't have this package installed.

    Edit:

    The libfdt-dev package was really causing the problem, but hopefully I was able to fix this issue:

  • It's best to use an "era appropriate" version of Ubuntu to build images or the docker template we ship in distro sources else weird toolchain issues can cause issues. All official LE 9.2 images were built with Ubuntu 18.04 - so I'd use that.