Skip to content
Snippets Groups Projects
Select Git revision
  • bec19c499d2b6fa430664d16b8b5395dac33c8c6
  • devel default protected
  • amin/radio_info
  • release-7.5 protected
  • fix-scanres-memleak
  • profile
  • release-7.5-17839 protected
  • helen_eml_mode
  • acs
  • release-7.3 protected
  • mmenshikov/acs_methods
  • ubus_md
  • mmenshikov/acs_methods-release-7.3
  • dev_opclass_from_scan
  • release-7.4.0alpha2-shsw protected
  • bw_73
  • acx/scanres-cache
  • dev_probe_sta_upgade
  • mld_ifname
  • cac_action
  • single_wiphy
21 results

install-dependencies.sh

Blame
  • Roman Azarenko's avatar
    Roman Azarenko authored
    Functional testing (both regular and API) relies on starting some services through supervisord. The set of services,
    however, is different between regular and API functional testing.
    
    For instance, functional testing does *not* expect `wifimngr` to run through supervisord, but instead executes it
    separately. API test, on the other hand, expects supervisord to start `wifimngr`. The supervisord configuration file,
    however, was the same for both instances.
    
    At the time when regular functional test reloads supervisord configuration, the `wifimngr` executable hasn't been
    compiled yet, and supervisord reports the following:
    
    	ubusd: added process group
    	wifimngr: added process group
    	ubusd                            RUNNING   pid 285, uptime 0:00:03
    	wifimngr                         FATAL     Exited too quickly (process log may have details)
    
    The supervisord log file then contains this:
    
    	valgrind: /builds/iopsys/wifimngr/wifimngr: No such file or directory
    
    which is expected, since `wifimngr` hasn't been compiled yet.
    
    * In supervisord v3.x, the abovementioned fatal error still results in a zero return code of `supervisorctl status all`.
    The error thus goes unnoticed, and the pipeline continues.
    * In supervisord v4.x, `supervisorctl status` correctly exits with a non-zero exit code, thus interrupting the script
    and failing the pipeline.
    
    The solution here is to have dedicated configuration for regular and API functional testing, where regular functional
    testing doesn't use supervisord to manage wifimngr. There are multiple ways to approach this (two complete configs,
    config per process etc). I picked two complete configs for simplicity, but this can be changed later.
    bec19c49
    History
    install-dependencies.sh 512 B
    #!/bin/bash
    
    set -euxo pipefail
    
    echo "install dependencies"
    
    pwd
    
    # libwifi
    cd /opt/dev
    rm -fr easy-soc-libs
    git clone https://dev.iopsys.eu/iopsys/easy-soc-libs.git
    cd easy-soc-libs
    git checkout c8c406568822b170e373a54fbf32323e960259ff
    cd libeasy
    make CFLAGS+="-I/usr/include/libnl3"
    mkdir -p /usr/include/easy
    cp easy.h event.h utils.h if_utils.h debug.h hlist.h /usr/include/easy
    cp -a libeasy*.so* /usr/lib
    cd ../libwifi
    make WIFI_TYPE=TEST
    cp wifi.h /usr/include
    cp -a libwifi-6.so* /usr/lib
    sudo ldconfig