config 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. # vim: filetype=yaml sw=2
  2. filename: '[% project %]-[% c("version") %]-[% c("var/build_id") %].tar.gz'
  3. version: '[% c("input_file_var/rust_version") %]'
  4. # those values can be changed from the input_files section of other
  5. # projects. See projects/tor/config and bug 28260.
  6. input_file_var:
  7. rust_version: 1.26.1
  8. prev_version: 1.25.0
  9. var:
  10. prev_version: '[% c("input_file_var/prev_version") %]'
  11. rust_arch: '[% c("arch") %]'
  12. container:
  13. use_container: 1
  14. targets:
  15. android:
  16. var:
  17. rust_arch: x86_64
  18. arch_deps:
  19. - libssl-dev
  20. - pkg-config
  21. - zlib1g-dev
  22. android-armv7:
  23. var:
  24. configure_opt: --enable-local-rust --enable-vendor --enable-extended --release-channel=stable --sysconfdir=etc --target=armv7-linux-androideabi --set=target.armv7-linux-androideabi.cc=$ANDROID_NDK_HOME/arm/bin/arm-linux-androideabi-gcc
  25. android-x86:
  26. var:
  27. configure_opt: --enable-local-rust --enable-vendor --enable-extended --release-channel=stable --sysconfdir=etc --target=i686-linux-android --set=target.i686-linux-android.cc=$ANDROID_NDK_HOME/x86/bin/i686-linux-android-gcc
  28. linux:
  29. var:
  30. rust_arch: x86_64
  31. deps:
  32. - libc6-dev-i386
  33. - lib32stdc++6
  34. - build-essential
  35. - python
  36. - automake
  37. - libssl-dev
  38. - pkg-config
  39. - hardening-wrapper
  40. # We use
  41. # `--enable-local-rust` to avoid downloading the required compiler during
  42. # build time
  43. #
  44. # `--enable-vendor` to avoid downloading crates during build time and just
  45. # use the ones which are shipped with the source
  46. #
  47. # `--enable-extended` to build not only rustc but cargo as well
  48. #
  49. # `--release-channel=stable` to just include stable features in the
  50. # compiler
  51. #
  52. # `--sysconfdir=etc` to avoid install failures as |make install| wants to
  53. # write to /etc otherwise
  54. #
  55. # the `target` triple to explicitly specify the architecture and platform
  56. # for the compiler/std lib. Ideally, it should not be needed unless one is
  57. # cross-compiling, but compiling `alloc_jemalloc` fails without that in a
  58. # 32bit container. "--host=x86_64-unknown-linux-gnu" is used in its
  59. # configure script in this case.
  60. # `--set=` to explicitly specify the C compiler. We need to compile the
  61. # bundled LLVM and it wants to use `cc`. However, we don't have that in
  62. # our compiled GCC resulting in weird errors due to C and C++ compiler
  63. # version mismatch. We avoid that with this configure option. We need to
  64. # build our own GCC in the first place as 4.7.2 is too old to get all the
  65. # Rust pieces compiled.
  66. configure_opt: --enable-local-rust --enable-vendor --enable-extended --release-channel=stable --sysconfdir=etc --target=x86_64-unknown-linux-gnu,i686-unknown-linux-gnu --set=target.x86_64-unknown-linux-gnu.cc=gcc --set=target.i686-unknown-linux-gnu.cc=gcc
  67. osx-x86_64:
  68. var:
  69. arch_deps:
  70. - libssl-dev
  71. - pkg-config
  72. configure_opt: --enable-local-rust --enable-vendor --enable-extended --release-channel=stable --sysconfdir=etc --target=x86_64-apple-darwin --set=target.x86_64-apple-darwin.cc=x86_64-apple-darwin-clang
  73. windows:
  74. var:
  75. arch_deps:
  76. - libssl-dev
  77. - pkg-config
  78. configure_opt: --enable-local-rust --enable-vendor --enable-extended --release-channel=stable --sysconfdir=etc --target=[% c("arch") %]-pc-windows-gnu
  79. input_files:
  80. - project: container-image
  81. - project: cmake
  82. name: cmake
  83. - project: '[% c("var/compiler") %]'
  84. name: '[% c("var/compiler") %]'
  85. - URL: 'https://static.rust-lang.org/dist/rustc-[% c("version") %]-src.tar.gz'
  86. name: rust
  87. sig_ext: asc
  88. file_gpg_id: 1
  89. gpg_keyring: rust.gpg
  90. - URL: 'https://static.rust-lang.org/dist/rust-[% c("var/prev_version") %]-[% c("var/rust_arch") %]-unknown-linux-gnu.tar.xz'
  91. name: prev_rust
  92. sig_ext: asc
  93. file_gpg_id: 1
  94. gpg_keyring: rust.gpg
  95. - filename: unwind.patch
  96. enable: '[% c("var/windows-i686") && !c("input_file_var/unwind_128") %]'
  97. - filename: unwind_128.patch
  98. enable: '[% c("input_file_var/unwind_128") %]'
  99. - filename: replace_pagesize_in_mmap.patch
  100. enable: '[% c("var/android") %]'
  101. - filename: 0001-Make-sure-dl_iterate_phdr-is-undefined-on-Android.patch
  102. enable: '[% c("var/android-armv7") %]'