Move get_srcdir to where it is used
Summary:
Move get_srcdir function to cdefs.py, it's only
usage location.
Test Plan:
./test/functional/test_runner.py
Reviewers: #bitcoin_abc, jasonbcox
Reviewed By: #bitcoin_abc, jasonbcox
Subscribers: jasonbcox, teamcity
Differential Revision: https://reviews.bitcoinabc.org/D1500