mirror of
https://github.com/denoland/deno.git
synced 2024-12-22 15:24:46 -05:00
Run lastchange.py during setup.py
This commit is contained in:
parent
1cf4bc5ca1
commit
85ebc6b1ac
1 changed files with 29 additions and 12 deletions
|
@ -1,15 +1,36 @@
|
||||||
#!/usr/bin/env python
|
#!/usr/bin/env python
|
||||||
import third_party
|
import third_party
|
||||||
from util import run, build_path, build_mode
|
from util import run, root_path, build_path, build_mode
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
from distutils.spawn import find_executable
|
from distutils.spawn import find_executable
|
||||||
|
|
||||||
third_party.fix_symlinks()
|
|
||||||
third_party.download_gn()
|
def main():
|
||||||
third_party.download_clang_format()
|
os.chdir(root_path)
|
||||||
third_party.download_clang()
|
|
||||||
third_party.maybe_download_sysroot()
|
third_party.fix_symlinks()
|
||||||
|
third_party.download_gn()
|
||||||
|
third_party.download_clang_format()
|
||||||
|
third_party.download_clang()
|
||||||
|
third_party.maybe_download_sysroot()
|
||||||
|
|
||||||
|
write_lastchange()
|
||||||
|
|
||||||
|
mode = build_mode(default=None)
|
||||||
|
if mode is not None:
|
||||||
|
gn_gen(mode)
|
||||||
|
else:
|
||||||
|
gn_gen("release")
|
||||||
|
gn_gen("debug")
|
||||||
|
|
||||||
|
|
||||||
|
def write_lastchange():
|
||||||
|
run([
|
||||||
|
sys.executable, "build/util/lastchange.py", "-o",
|
||||||
|
"build/util/LASTCHANGE", "--source-dir", root_path,
|
||||||
|
"--filter="
|
||||||
|
])
|
||||||
|
|
||||||
|
|
||||||
def get_gn_args():
|
def get_gn_args():
|
||||||
|
@ -61,9 +82,5 @@ def gn_gen(mode):
|
||||||
env=third_party.google_env())
|
env=third_party.google_env())
|
||||||
|
|
||||||
|
|
||||||
mode = build_mode(default=None)
|
if __name__ == '__main__':
|
||||||
if mode is not None:
|
sys.exit(main())
|
||||||
gn_gen(mode)
|
|
||||||
else:
|
|
||||||
gn_gen("release")
|
|
||||||
gn_gen("debug")
|
|
||||||
|
|
Loading…
Reference in a new issue