Simplify installation of rustc/cargo (#8626)
commit139815e23e6588f8215951563d77722763b0a00d
authorFred Emmott <fe@fb.com>
Wed, 11 Dec 2019 17:26:42 +0000 (11 09:26 -0800)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Wed, 11 Dec 2019 17:32:43 +0000 (11 09:32 -0800)
tree23dc2b23e85c06e4650b8ab91061a937e3ac0722
parentdeec628182123e313cf43170cb78e4fe10fd9a43
Simplify installation of rustc/cargo (#8626)

Summary:
1. use `ExternalProject_add` to let CMake handle fetching, verification,
   and installation as a build step instead of a configure step
2. instead of setting global variables, define targets; this makes it
   possible to mark the hack build as depending on rustc

This is basically the same as what I'm now doing for jemalloc. I'm
hoping to spend some time next year consistently doing this for our
third-party projects.
Pull Request resolved: https://github.com/facebook/hhvm/pull/8626

Reviewed By: jjergus

Differential Revision: D18917497

fbshipit-source-id: e15128d4c0ea4d1681a881c54d1e3098b7b243c7
hphp/hack/CMakeLists.txt
third-party/rustc/CMakeLists.txt [moved from CMake/HHVMRustVersion.cmake with 58% similarity]