summaryrefslogtreecommitdiff
path: root/script/build/serprog
diff options
context:
space:
mode:
authorRiku Viitanen <riku.viitanen@protonmail.com>2023-09-11 01:01:27 +0300
committerRiku Viitanen <riku.viitanen@protonmail.com>2023-09-11 01:01:32 +0300
commit7dc8632514aa13ba0c704dbe6cf7aeb38071d808 (patch)
tree5f4175eee70856ce5c231d87c294e3c64ff0a719 /script/build/serprog
parent34d3629ebf68595710015b52fbcd16a66b91df8c (diff)
clean up pico-serprog for release
moved cmake files into a separate build directory. this can just be deleted for the source release. might as well use cmake for the actual build too. that makes repeated builds faster for some reason. Signed-off-by: Riku Viitanen <riku.viitanen@protonmail.com>
Diffstat (limited to 'script/build/serprog')
-rwxr-xr-xscript/build/serprog/rp204012
1 files changed, 6 insertions, 6 deletions
diff --git a/script/build/serprog/rp2040 b/script/build/serprog/rp2040
index e265cc7a..3b4fbf14 100755
--- a/script/build/serprog/rp2040
+++ b/script/build/serprog/rp2040
@@ -51,14 +51,14 @@ main()
buildrom()
{
board=${1}
- (cd ${src_dir}; cmake -DPICO_BOARD="${board}" \
- -DPICO_SDK_PATH="${sdk_dir}" "${src_dir}" || \
- err "can't cmake ${src_dir}")
- make -C ${src_dir} clean
- make -C ${src_dir}
- mv ${src_dir}/pico_serprog.uf2 \
+ cmake -DPICO_BOARD="${board}" -DPICO_SDK_PATH="${sdk_dir}" \
+ -B "${src_dir}/build" "${src_dir}" \
+ || err "can't cmake ${src_dir}"
+ cmake --build "${src_dir}/build"
+ mv ${src_dir}/build/pico_serprog.uf2 \
${serprog_release_dir}/serprog_${board}.uf2 \
|| err "${board} serprog build failed!"
+ printf "output to ${serprog_release_dir}/serprog_${board}.uf2\n"
}
main $@