generate_gn.sh 553 B

12345678910111213141516171819202122
  1. #!/bin/bash
  2. # This script generates BUILD.gn using template/BUILD.chromium.gn.template and
  3. # the gRPC repo in src/
  4. set -e
  5. # change directory to this script's directory
  6. cd `dirname "$0"`
  7. # copy template into grpc repo and run generate_projects in it
  8. cp template/BUILD.chromium.gn.template src/templates/BUILD.chromium.gn.template
  9. cd src
  10. ./tools/buildgen/generate_projects.sh
  11. rm templates/BUILD.chromium.gn.template # clean up
  12. cd ..
  13. # move the generated GN file back to this directory
  14. mv src/BUILD.chromium.gn BUILD.gn
  15. gn format --inplace BUILD.gn