Errors building source for cross development



  • Still has the same error using onion-minimal-build

    Any other ideas?

    Thanks



  • I need to see the build log, run with make -j1 V=s then post the log.



  • log.bin

    Have attached the output of the make command.
    The system wont let me attach a txt file so I have renamed the log.txt file to log.bin.
    You will need to change the .bin back to .txt to read the log.

    The last part of the log file where the error is in my original post.

    I presume the screen output is what you mean by the build log file as I cannot find any other log file in the make directory or its subdirectories



  • @Lachlan-Peter run make menuconfig, look in "Utilities" submenu and disable "findutils-find" then make clean and make -j 8

    That should fix the issue.



  • @crispyoz

    In menuconfig, all findutils are not enabled (findutils-find, findutils-locate, findutils-args).
    This is not where the problem lies.

    The problem is the Makefile in 'tools' that makes 'findutils'. You can see in my original post that it is the tools/Makefile where the error occurs.

    Unfortunately I cannot remove 'findutils' from the Makefile as it is a requirement for building 'quilt'. If I remove the entry for 'findutils' in 'tools/Makefil' at line 28, I get the follwing error:

    time: tools/patch-image/compile#0.04#0.01#0.09
    make[2]: *** No rule to make target 'tools/findutils/compile', needed by 'tools/quilt/compile'. Stop.
    make[2]: Leaving directory '/home/lachlan/omega/source'
    make[1]: *** [tools/Makefile:150: /home/lachlan/omega/source/staging_dir/target-mips_24kc_musl/stamp/.tools_compile_yynyyyyynyyyynyynnyyyyyyyyyyyyyyyyyyyynyynynyyyynnyy] Error 2

    There is nothing in the tools/findutils/Makefile that helps me determine the problem.

    Any further ideas?



  • @Lachlan-Peter

    Note: There is a different folder and different makefile for 'findutils' in 'tools' and 'package/feeds/packages/findutils'. It is the 'tools' version that is giving the problem. menuconfig probably disables the package created in Utilities.



  • @Lachlan-Peter
    Immediately before the 'findutils failure', there is more error information:

    checking for BEOS mounted file system support functions... no
    checking whether it is possible to resort to fread on /etc/mnttab... no
    configure: error: could not determine how to read list of mounted file systems
    make[3]: *** [Makefile:22: /home/lachlan/omega/source/build_dir/host/findutils-4.6.0/.configured] Error 1
    make[3]: Leaving directory '/home/lachlan/omega/source/tools/findutils'
    Command exited with non-zero status 2
    time: tools/findutils/compile#23.95#6.64#54.33
    make[2]: *** [tools/Makefile:154: tools/findutils/compile] Error 2
    make[2]: Leaving directory '/home/lachlan/omega/source'
    make[1]: *** [tools/Makefile:150: /home/lachlan/omega/source/staging_dir/target-mips_24kc_musl/stamp/.tools_compile_yynyyyyynyyyyynyynnyyyyyyyyyyyyyyyyyyyynyynynyyyynnyy] Error 2
    make[1]: Leaving directory '/home/lachlan/omega/source'
    make: *** [/home/lachlan/omega/source/include/toplevel.mk:218: world] Error 2

    It seems from what I can find on the web, the problem with 'findutils' is because there is no way to determine the mounted file systems.

    There are references on the web that say this can be worked around by disabling the error. An example is:
    https://github.com/StephanTLavavej/mingw-distro/blob/master/coreutils.patch

    However, I can't find the reference to "could not determine how to read mounted file systems" in any Makefile or configure file. Therefore it is difficult to determine a work around.

    Any ideas ?



  • @Lachlan-Peter post the contents your .config file so I can test it. I build on Ubuntu 20 myself so I should be able to duplicate your issue.



  • config.bin

    The config file is attached. I had to rename it from .config to config.bin so I could upload it. You will need to rename it correctly before using it.

    Thanks



  • @Lachlan-Peter You config indicates you are building for the wrong device. ar71xx instead of ramips_mt76x8. Run make menuconfig, at the top choose the target device as Mediateck ralink MIPS, in Sub target menu choose MT76x8 based boards, Target profile set to Multiple Devices, in Target Devices choose Omega2+

    Then run make clean and make -j 8

    If you still have the issue can you run ls -la .config and post the output



  • I don't know why the problem occurred with the config file. I was using the work computer for the last attempt when I downloaded the .config file.

    I am back on my main machine where I have checked each time that I am using Media Ralink MIPS/MT76x8 based coards/Multiple Devices/Onion Omega 2 & Onion Omega 2.

    However, things have deteriorated on my main machine. I cant even get as far as I did previously. Here are the exact steps I have done using a clean install

    $ git clone https://github.com/OnionIoT/source.git
    $ cd source
    $ sh scripts/onion-feed-setup.sh
    $ sh scripts/onion-minimal-build.sh
    ( Also tried adding $ python scripts/onion-setup-build.py but same result)

    Edit: /usr/include/asm-generic/int-ll64.h line 31
    from: extension typedef unsigned long long __64;
    to: typedef uint64_t __64;
    This prevents errors with __u64 different typedef's

    $ make menuconfig
    Target System : MediaTek Ralink MIPS default
    Subtarget : MT76x8 based boards default
    Target Profile: Multiple Devices default
    Target Devices: Onion Omega2, Onion Omega2+ default

       Added: 
                   Development: gdb
                    Libraries: libgpiod
       Save and exit
    

    $ make -j1 V=s

    Error is:
    checking whether sleep is declared... no
    checking for socklen_t... no
    checking for socklen_t equivalent... configure: error: Cannot find a type to use in place of socklen_t
    make[3]: *** [Makefile:46: /home/lachlan/omega/source/build_dir/host/sed-4.5/.configured] Error 1
    make[3]: Leaving directory '/home/lachlan/omega/source/tools/sed'
    Command exited with non-zero status 2
    time: tools/sed/compile#10.72#3.68#13.83
    make[2]: *** [tools/Makefile:154: tools/sed/compile] Error 2
    make[2]: Leaving directory '/home/lachlan/omega/source'
    make[1]: *** [tools/Makefile:150: /home/lachlan/omega/source/staging_dir/target-mipsel_24kc_musl/stamp/.tools_compile_yynyyyyynyyyyynyynnyyyynyyyyyyyyyyyyyyynyynynnyyynnyy] Error 2
    make[1]: Leaving directory '/home/lachlan/omega/source'
    make: *** [/home/lachlan/omega/source/include/toplevel.mk:218: world] Error 2

    The .config file is attached:
    config.bin

    Previously 'make' went way past this point.
    Dont know why the compile is failing even earlier than it did before on a clean 'git'



  • @Lachlan-Peter I built using your new config and it builds fine. I recall that when I upgraded my Ubuntu 18.x to 20 my build system broke and needed to install some additional stuff on my Ubuntu 20 system. I was able to identify the required stuff by working though the buld log. Alas I didn't record the steps because I have so many backups and images I never expect to do it again. If you send the entire build log I can probably work it out again for you.

    just run make clean, then make -j1 V=s > build.log, post the file and I will take a look.



  • I didnt see this previously as the errors scrolled off the page, but it seems that the errors are in
    $ sh scripts/onion-feed-setup.sh

    I get the following warnings when running scripts/onion-feed-setup.sh:
    WARNING: Makefile 'package/utils/busybox/Makefile' has a dependency on 'libpam', which does not exist
    WARNING: Makefile 'package/utils/busybox/Makefile' has a build dependency on 'libpam', which does not exist
    WARNING: Makefile 'package/network/utils/curl/Makefile' has a dependency on 'libgnutls', which does not exist
    WARNING: Makefile 'package/network/utils/curl/Makefile' has a dependency on 'libopenldap', which does not exist
    WARNING: Makefile 'package/network/utils/curl/Makefile' has a dependency on 'libidn2', which does not exist
    WARNING: Makefile 'package/network/utils/curl/Makefile' has a dependency on 'libssh2', which does not exist
    WARNING: Makefile 'package/boot/kexec-tools/Makefile' has a dependency on 'liblzma', which does not exist
    WARNING: Makefile 'package/network/services/lldpd/Makefile' has a dependency on 'libnetsnmp', which does not exist

    WARNING: No feed for package 'Onion-Console' found
    WARNING: No feed for package 'transmission-daemon' found
    WARNING: No feed for source package 'libuuid' found

    WARNING: Makefile 'package/feeds/onion/transmission-console-app/Makefile' has a dependency on 'Onion-Console', which does not exist
    WARNING: Makefile 'package/feeds/onion/transmission-console-app/Makefile' has a dependency on 'transmission-daemon', which does not exist
    WARNING: Makefile 'package/feeds/onion/zeromq/Makefile' has a build dependency on 'libuuid', which does not exist

    WARNING: bluez-examples not installed
    WARNING: bluez-libs not installed
    WARNING: bluez-utils not installed
    WARNING: pulseaudio-daemon not installed
    WARNING: pulseaudio-profiles not installed
    WARNING: pulseaudio-tools not installed
    Uninstalling package 'avrdude'
    Collecting package info: done
    WARNING: Makefile 'package/feeds/onion/arduino-dock/Makefile' has a dependency on 'avrdude', which does not exist
    WARNING: Makefile 'package/feeds/onion/arduino-dock/Makefile' has a dependency on 'avrdude', which does not exist

    I tried addressing this with the following but it did not work:
    $ sudo apt-get install libpam0g-dev libgnutls28-dev libldap2-dev libidn2-0-dev libssh2-1-dev liblzma-dev libnet-snmp-perl

    Im not sure if I need to provide these packages as architecture specific but I cant find mips versions of them



  • @Lachlan-Peter These warnings are usual. I need to see your complete build log.

    make -j1 V=s > build.log



  • build.bin
    I have added the build log.
    Note that it has started to fail much earlier in the build now (at the build of sed instead of findutils). This happens on two separate machines.
    Thanks for any insight.



  • @Lachlan-Peter The log you attached is not that of the verbose make, it looks like a standard make. Are you sure you are using the command I gave you?

    make -j1 V=s > build.log

    The log file will be large as it contains a lot of detail, so you probably need to zip it, but without it, I can't assist you further.



  • I have attached a zip file (you will need to change the extension from .bin) which contains two files.

    the build.log file is the file from :
    make -j1 V=s > build.log

    the build.terminal.log is a copy of the output on the terminal during the build process.

    Thanks
    build.bin



  • @Lachlan-Peter Can you post the output of make -v also gcc -v



  • lachlan@xps:~/omega/source$ make -v
    GNU Make 4.2.1
    Built for x86_64-pc-linux-gnu
    Copyright (C) 1988-2016 Free Software Foundation, Inc.
    License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html
    This is free software: you are free to change and redistribute it.
    There is NO WARRANTY, to the extent permitted by law.

    lachlan@xps:~/omega/source$ gcc -v
    Using built-in specs.
    COLLECT_GCC=gcc
    COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/9/lto-wrapper
    OFFLOAD_TARGET_NAMES=nvptx-none:hsa
    OFFLOAD_TARGET_DEFAULT=1
    Target: x86_64-linux-gnu
    Configured with: ../src/configure -v --with-pkgversion='Ubuntu 9.3.0-17ubuntu1~20.04' --with-bugurl=file:///usr/share/doc/gcc-9/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++,gm2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-9 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-plugin --enable-default-pie --with-system-zlib --with-target-system-zlib=auto --enable-objc-gc=auto --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none=/build/gcc-9-HskZEa/gcc-9-9.3.0/debian/tmp-nvptx/usr,hsa --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
    Thread model: posix
    gcc version 9.3.0 (Ubuntu 9.3.0-17ubuntu1~20.04)
    lachlan@xps:~/omega/source$



  • The above make and gcc details are from my work machine, not my main machine at home, but this has the same errors and is running 20.04.2 LTS the same as my home machine, and both are fully up-to-date and should be setup identical.

    Also, I notice in the output:
    "checking whether we are cross compiling... no"
    I would have though that we are cross compiling to build libraries for the omega?


Log in to reply
 

Looks like your connection to Community was lost, please wait while we try to reconnect.