skip to Main Content

I have a Yocto project that is on the "kirkstone" branch, i want to add chirpstack into the build.

but when i tried to execute the following command

bitbake chirpstack 

i get the following build error:

Build Configuration:
BB_VERSION           = "2.0.0"
BUILD_SYS            = "x86_64-linux"
NATIVELSBSTRING      = "universal"
TARGET_SYS           = "aarch64-poky-linux"
MACHINE              = "tv4000"
DISTRO               = "ir-tiny"
DISTRO_VERSION       = "4.0.2"
TUNE_FEATURES        = "aarch64 armv8a crc cortexa53 crypto"
TARGET_FPU           = ""
meta                 
meta-poky            
meta-yocto-bsp       = "kirkstone:236f30b8a9cb1751aae290cc94da06d8f6917b30"
meta-oe              
meta-python          
meta-networking      
meta-filesystems     
meta-webserver       = "kirkstone:a47ef046619d639dfbd3be2a13ef6d5b40fd40a1"
meta-freescale       = "kirkstone:da51a9af29d25411ff16c2b735c391bc335ba5c0"
meta-clang           = "kirkstone:2d08d6bf376a1e06c53164fd6283b03ec2309da4"
meta-ir-imx          
meta-ir-rust         
meta-ir              
meta-ir-chirpstack   = "chirpstack-kirkstone:d8d07b690fd174ded488356673d622ecf4504bd5"

Initialising tasks: 100% |#########################################################################################################################################################################################################################################| Time: 0:00:03
Sstate summary: Wanted 33 Local 28 Mirrors 0 Missed 5 Current 288 (84% match, 98% complete)
NOTE: Executing Tasks
ERROR: chirpstack-4.3.0-r0 do_compile: oe_runmake failed
ERROR: chirpstack-4.3.0-r0 do_compile: ExecutionError('/home/patrickyuan/tv4000/poky/build/tmp/work/cortexa53-crypto-poky-linux/chirpstack/4.3.0-r0/temp/run.do_compile.5514', 1, None, None)
ERROR: Logfile of failure stored in: /home/patrickyuan/tv4000/poky/build/tmp/work/cortexa53-crypto-poky-linux/chirpstack/4.3.0-r0/temp/log.do_compile.5514
Log data follows:
| DEBUG: Executing shell function do_compile
| NOTE: make -j 4
| yarn install
| yarn install v1.22.18
| warning You don't appear to have an internet connection. Try the --offline flag to use the cache for registry queries.
| [1/4] Resolving packages...
| [2/4] Fetching packages...
| error An unexpected error occurred: "https://registry.yarnpkg.com/@ant-design/colors/-/colors-6.0.0.tgz: getaddrinfo EAI_AGAIN registry.yarnpkg.com".
| info If you think this is a bug, please open a bug report with the information provided in "/home/patrickyuan/tv4000/poky/build/tmp/work/cortexa53-crypto-poky-linux/chirpstack/4.3.0-r0/git/ui/yarn-error.log".
| info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
| make: *** [Makefile:10: dependencies] Error 1
| ERROR: oe_runmake failed
| WARNING: exit code 1 from a shell command.
ERROR: Task (/home/patrickyuan/tv4000/poky/build/../../meta-innerrange/meta-ir-chirpstack/recipes-chirpstack/chirpstack/chirpstack_4.3.0.bb:do_compile) failed with exit code '1'
NOTE: Tasks Summary: Attempted 1208 tasks of which 1207 didn't need to be rerun and 1 failed.

I confirm that the network connectivity is ok on my ubuntu VM build machine.

and I could download the package directly if I put the url into a browser.

and i am not building the yocto image in a docker container.

2

Answers


  1. As specified in the bitbake manual:

    Bitbake intentionally only allows the do_fetch task to access the network, in your case, the task do_compile is trying to access the network hence why its failing.

    It is not recommended, but if you want to allow the do_compile task to access the network you need to set the [network] varFlag to ‘1’.

    python() {
         d.setVarFlag(task, 'network', '1')
    }
    
    Login or Signup to reply.
  2. As @ah008a answered with the details of network flag, you can also directly set it with:

    do_compile[network] = "1"
    

    or, to remove the confusion, set do_compile network flag in an anonymous function:

    python() {
        d.setVarFlag('do_compile', 'network', '1')
    }
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search