Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

67 lines
3.0KB

  1. #!/bin/bash
  2. set -ex
  3. export PATH=`pwd`/depot_tools:"$PATH"
  4. # https://github.com/prahladyeri/tuxdrive/issues/3
  5. apt-get install python3-pip -y
  6. pip3 install httplib2 --upgrade
  7. fetch v8
  8. cd v8 # if this fails, exit! hence the set -ex
  9. #gclient sync -r 6.9.427.6 # 55da769bafac8b531cd8b388df56161b8b7c6416
  10. #gclient sync -r 7.1.69 #
  11. #gclient sync -r lkgr/6.9
  12. #gclient sync -r 6.9.427.13 # https://ci.appveyor.com/project/pmed/v8pp
  13. #gclient sync -r 7.5.288.23 # https://github.com/pmed/v8-nuget/
  14. #gclient sync -r 8.0.426.15 # stupid test
  15. #gclient sync -r 7.2.1 # stupid test
  16. #gclient sync -r 8.2.297.1 # https://github.com/pmed/v8-nuget/
  17. #gclient sync -r 9.3.345.3 # https://github.com/pmed/v8-nuget/
  18. gclient sync -r 10.0.139.9 # https://github.com/pmed/v8-nuget/
  19. # Looks like we have to use GN now: https://github.com/v8/v8/wiki/Building-with-GN
  20. # initial build
  21. # temp
  22. #rm -rf out/x64.release
  23. ./tools/dev/gm.py x64.release
  24. # we don't want std::_Cr, but std::__1 like everybody else is using
  25. # note that this is only relevant if use_custom_libcxx = true.
  26. # unfortunately I don't know how to specify v8 to use libc++ from the system
  27. # I asked a question about this here: https://groups.google.com/forum/#!topic/v8-users/Do5MvAvYFgs
  28. sed -i.bak 's/_LIBCPP_ABI_VERSION=Cr/_LIBCPP_ABI_VERSION=1/' build/config/c++/BUILD.gn
  29. # workaround, see notes.txt
  30. echo "v8_enable_embedded_builtins = false" | tee -a out/x64.release/args.gn
  31. echo "v8_use_external_startup_data = false" | tee -a out/x64.release/args.gn
  32. echo "v8_use_snapshot = false" | tee -a out/x64.release/args.gn
  33. # set below to true to make it use libc++ (although it will use the one it is bundled with,
  34. # and also it will enable unsafe abi stuff, which means basically alpha features afaik)
  35. echo "use_custom_libcxx = false" | tee -a out/x64.release/args.gn
  36. # possibly they use a different version of clang compiling v8.
  37. # however, I already set my own, probably newer clang version.
  38. # ran into: https://groups.google.com/forum/#!topic/v8-users/Jb1VSouy2Z0
  39. #echo "is_clang = false" | tee -a out/x64.release/args.gn
  40. # setting to true now, and see if we use this clang on starcry if it works..
  41. echo "is_clang = true" | tee -a out/x64.release/args.gn
  42. # the only remaining issue was: undefined reference to `typeinfo for v8::ArrayBuffer::Allocator'
  43. # this is the case with (gnu) libstd++ , only remaining issue for me
  44. # https://github.com/danbev/learning-v8/pull/4
  45. echo "use_rtti = true" | tee -a out/x64.release/args.gn
  46. # produce monolith (single static all in one .a file)
  47. echo "v8_monolithic = true" | tee -a out/x64.release/args.gn
  48. ninja -C out/x64.release v8_monolith
  49. # produce .so files (shared libs)
  50. # temporary disable the .so files (I'm not using them for now, and they are slow to build)
  51. #sed -i.bak '/^v8_monolithic/d' out/x64.release/args.gn
  52. #echo "is_component_build = true" | tee -a out/x64.release/args.gn
  53. #ninja -C out/x64.release