[CI] Let build_cmake.sh take a list of targets and use it
Summary:
This will reduce the build time for build-secp256k1, build-bench and
check-seeds and doesn't change the behavior by default.
I didn't update the ibd plans since there is nothing to gain here.
Test Plan: Run the CI build-secp256k1, build-bench and check-seeds build plans.
Reviewers: #bitcoin_abc, jasonbcox
Reviewed By: #bitcoin_abc, jasonbcox
Subscribers: jasonbcox
Differential Revision: https://reviews.bitcoinabc.org/D6373