From d1651ac194329f3124ba8115ad7251d0506bb2e1 Mon Sep 17 00:00:00 2001 From: Handa Wang <7058128+superwhd@users.noreply.github.com> Date: Fri, 18 Oct 2024 13:03:32 +0800 Subject: [PATCH] [script] perserving the permission when cp openthread files (#95) In some environments, `cp` may produce files which have different permissions from the source files. This can fail the build of OTBR. Hence we need to add `-p` option in the command to preserve the permissions. --- script/make-firmware.bash | 2 +- script/otbr-setup.bash | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/script/make-firmware.bash b/script/make-firmware.bash index fcd463e7..58261b5c 100755 --- a/script/make-firmware.bash +++ b/script/make-firmware.bash @@ -193,7 +193,7 @@ build_ot() rm -rf openthread # git_archive_all doesn't accept symbolic link, so make a copy of openthread and make # it not a submodule - cp -r ../openthread . + cp -rp ../openthread . rm openthread/.git # Build diff --git a/script/otbr-setup.bash b/script/otbr-setup.bash index 57fc3b7c..130772d9 100755 --- a/script/otbr-setup.bash +++ b/script/otbr-setup.bash @@ -191,7 +191,7 @@ apt-get install -y --no-install-recommends git python3-pip su -c "DOCKER=1 ${build_options[*]} script/bootstrap" pi rm -rf /home/pi/repo/ot-br-posix/third_party/openthread/repo -cp -r /home/pi/repo/openthread /home/pi/repo/ot-br-posix/third_party/openthread/repo +cp -rp /home/pi/repo/openthread /home/pi/repo/ot-br-posix/third_party/openthread/repo apt-get purge -y cmake pip3 install scikit-build