diff options
| author | JF002 <JF002@users.noreply.github.com> | 2021-02-04 16:34:28 (GMT) |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-02-04 16:34:28 (GMT) |
| commit | 6259b816287f8f74dadf50334a445cd9fe16d415 (patch) | |
| tree | 712cf7ca15f0d17b54909bbf45a4cc759c579392 /src/libs/mynewt-nimble/porting/update_generated_files.sh | |
| parent | 16ce5bbb7563f0af9394d4da0dae303aa9eda2fd (diff) | |
| parent | d90b7274fa8bbfa09f79660b45b550d91f7b0125 (diff) | |
Merge pull request #198 from JF002/update-nimble-1_3-master
Update to nimble 1.3 master branch
Diffstat (limited to 'src/libs/mynewt-nimble/porting/update_generated_files.sh')
| -rwxr-xr-x | src/libs/mynewt-nimble/porting/update_generated_files.sh | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/libs/mynewt-nimble/porting/update_generated_files.sh b/src/libs/mynewt-nimble/porting/update_generated_files.sh index c01dddd..6309ed2 100755 --- a/src/libs/mynewt-nimble/porting/update_generated_files.sh +++ b/src/libs/mynewt-nimble/porting/update_generated_files.sh @@ -23,6 +23,7 @@ if [ ! -f "project.yml" ]; then fi declare -A targets=( + ["nuttx"]="repos/apache-mynewt-nimble/porting/examples/nuttx/" ["linux"]="repos/apache-mynewt-nimble/porting/examples/linux/" ["linux_blemesh"]="repos/apache-mynewt-nimble/porting/examples/linux_blemesh/" ["porting_default"]="repos/apache-mynewt-nimble/porting/nimble" @@ -31,6 +32,11 @@ declare -A targets=( for target in "${!targets[@]}"; do echo "Updating target $target" - newt build "$target" > /dev/null 2>&1 - cp "bin/@apache-mynewt-nimble/targets/${target}/generated/include" "${targets[$target]}" -r + newt build "@apache-mynewt-nimble/porting/targets/$target" > /dev/null 2>&1 + cp "bin/@apache-mynewt-nimble/porting/targets/${target}/generated/include" "${targets[$target]}" -r + # Remove repo version and hash MYNEWT_VALS as it doesn't make much sense to commit them and they + # defeat the purpose of this script. + find "${targets[$target]}/include" -type f -name 'syscfg.h' -exec sed -i '/MYNEWT_VAL_REPO_*/,/#endif/d' {} \; + find "${targets[$target]}/include" -type f -name 'syscfg.h' -exec sed -i '/\/\*\*\* Repository/,/\*\//d' {} \; + find "${targets[$target]}/include" -type f -name 'syscfg.h' -exec sed -i '$!N;/^\n$/{$q;D;};P;D;' {} \; done |
