Skip to content

Commit

Permalink
[test] fix socat version to 1.7.4.4 (#2706)
Browse files Browse the repository at this point in the history
This commit changes the installation of socat from using 'apt' to
manual installation.

We found the latest socat version 1.8.0.3 has an issue when running
with OTBR docker. To avoid the error caused by version and facilitate
local development, the commit provides a script to install socat of
version `1.7.4.4` and replaces the installation in CI and scripts..

BTW, the installation in `install_openthread_binraries` is unnecessary
because `install_common_dependencies` will be done anyway.
  • Loading branch information
Irving-cl authored Feb 27, 2025
1 parent c501d42 commit bdb621c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/border_router.yml
Original file line number Diff line number Diff line change
Expand Up @@ -184,8 +184,9 @@ jobs:
if: ${{ success() && steps.check_cache_result.outputs.cache-hit != 'true' }}
run: |
sudo rm /etc/apt/sources.list.d/* && sudo apt-get update
sudo apt-get --no-install-recommends install -y python3-setuptools python3-wheel ninja-build socat nodejs npm
sudo apt-get --no-install-recommends install -y python3-setuptools python3-wheel ninja-build nodejs npm
python3 -m pip install -r third_party/openthread/repo/tests/scripts/thread-cert/requirements.txt
sudo bash third_party/openthread/repo/script/install_socat
- name: Build OpenThread
if: ${{ success() && steps.check_cache_result.outputs.cache-hit != 'true' }}
run: |
Expand Down
8 changes: 4 additions & 4 deletions tests/scripts/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,7 @@ install_common_dependencies()
coreutils \
git \
libprotobuf-dev \
protobuf-compiler \
socat
protobuf-compiler
}

install_openthread_binraries()
Expand All @@ -79,8 +78,6 @@ install_openthread_binraries()
cmake .. -GNinja -DOT_PLATFORM=simulation -DOT_FULL_LOGS=1 -DOT_COMMISSIONER=ON -DOT_JOINER=ON
ninja
sudo ninja install

sudo apt-get install --no-install-recommends -y socat
}

configure_network()
Expand All @@ -97,18 +94,21 @@ case "$(uname)" in
install_common_dependencies

if [ "$BUILD_TARGET" == script-check ] || [ "$BUILD_TARGET" == docker-check ]; then
sudo bash third_party/openthread/repo/script/install_socat
install_openthread_binraries
configure_network
exit 0
fi

if [ "$BUILD_TARGET" == check ] || [ "$BUILD_TARGET" == meshcop ]; then
sudo bash third_party/openthread/repo/script/install_socat
install_openthread_binraries
sudo apt-get install --no-install-recommends -y avahi-daemon avahi-utils
configure_network
fi

if [ "$BUILD_TARGET" == ncp_mode ]; then
sudo bash third_party/openthread/repo/script/install_socat
sudo apt-get install --no-install-recommends -y avahi-daemon avahi-utils
fi

Expand Down

0 comments on commit bdb621c

Please sign in to comment.