Advertisement
Guest User

Untitled

a guest
Jun 19th, 2016
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.42 KB | None | 0 0
  1. . "$topsrcdir/b2g/config/mozconfigs/common"
  2.  
  3. if [ "$TARGET_BUILD_VARIANT" != "user" ] ; then
  4. ENABLE_MARIONETTE=1
  5. ENABLE_TESTS=1
  6. fi
  7.  
  8. mk_add_options MOZ_OBJDIR="$GECKO_OBJDIR"
  9.  
  10. if [ "$TARGET_ARCH" = "x86" ]; then
  11. ac_add_options --target=i686-linux-android
  12. elif [ "$TARGET_ARCH" = "arm64" ]; then
  13. ac_add_options --target=aarch64-linux-android
  14. else
  15. ac_add_options --target=arm-linux-androideabi
  16. fi
  17.  
  18. ac_add_options --with-gonk="$GONK_PATH"
  19.  
  20. ac_add_options --enable-application=b2g
  21.  
  22. # Follow the section 'Bootstrap dependencies' at
  23. #
  24. # https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Build_Instructions/Simple_Firefox_for_Android_build
  25. #
  26. # for installing the Android NDK. Choose 'Firefox for Android' at the
  27. # prompt. Alternatively, you can also download the NDK manually and set
  28. # the shell variable B2G_ANDROID_NDK_PATH to the NDK's directory.
  29.  
  30. B2G_ANDROID_NDK_PATH=${B2G_ANDROID_NDK_PATH:="$HOME/.mozbuild/android-ndk-r11b"}
  31. ac_add_options --with-android-ndk="${B2G_ANDROID_NDK_PATH}"
  32.  
  33. # Some Android releases don't have their own SDK. We use the next lower
  34. # version in these cases.
  35.  
  36. case $PLATFORM_SDK_VERSION in
  37. 22)
  38. ac_add_options --with-android-version=21
  39. ;;
  40. 20)
  41. ac_add_options --with-android-version=19
  42. ;;
  43. 11|10)
  44. ac_add_options --with-android-version=9
  45. ;;
  46. *)
  47. ac_add_options --with-android-version=$PLATFORM_SDK_VERSION
  48. ;;
  49. esac
  50.  
  51. ac_add_options --enable-debug-symbols
  52. if [ "${B2G_DEBUG:-0}" != "0" ]; then
  53. ac_add_options --enable-debug
  54. fi
  55.  
  56. if [ "${B2G_NOOPT:-0}" != "0" ]; then
  57. ac_add_options --disable-optimize
  58. fi
  59.  
  60. if [ "${B2G_DUMP_PAINTING:-0}" != "0" ]; then
  61. ac_add_options --enable-dump-painting
  62. fi
  63.  
  64. ac_add_options --with-ccache
  65.  
  66. if [ "${DISABLE_JEMALLOC:-0}" != "0" ] ||
  67. [ "${PLATFORM_SDK_VERSION:-0}" -ge "22" -a "$MALLOC_IMPL" != "dlmalloc" ]; then
  68. ac_add_options --disable-jemalloc
  69. fi
  70.  
  71. ac_add_options --disable-printing
  72.  
  73. if [ "${B2G_VALGRIND:-0}" != "0" ]; then
  74. ac_add_options --enable-valgrind
  75. ac_add_options --enable-profiling
  76. fi
  77.  
  78. if [ "${B2G_PROFILING:-0}" != "0" ]; then
  79. ac_add_options --enable-profiling
  80. fi
  81.  
  82. if [ "$HOST_OS" != "linux" ]; then
  83. ac_add_options --disable-crashreporter
  84. fi
  85.  
  86. if [ "${B2G_UPDATER:-0}" != "0" ]; then
  87. # Note: if B2G_UPDATE_CHANNEL isn't set, then configure will use its own
  88. # default, which is "default".
  89. ac_add_options --enable-updater
  90. ac_add_options --enable-update-channel="${B2G_UPDATE_CHANNEL}"
  91. fi
  92.  
  93. # Enable dump() from JS.
  94. export CXXFLAGS="-DMOZ_ENABLE_JS_DUMP $EXTRA_INCLUDE ${CXXFLAGS}"
  95.  
  96. # In order to support x86 64bis, Google change x86 toolchain from lollipop.
  97. # Prefix was changed from i686-linux-android to x86_64-linux-android
  98. # Add "-m32" to build x86 32bits
  99. if [ "$TARGET_ARCH" = "x86" ]; then
  100. case "$GECKO_TOOLS_PREFIX" in
  101. *x86_64-linux-android-*)
  102. export CFLAGS="-m32 ${CFLAGS}"
  103. export CXXFLAGS="-m32 ${CXXFLAGS}"
  104. export LDFLAGS="-m32 ${LDFLAGS}"
  105. export ASFLAGS="-m32 ${ASFLAGS}"
  106. ;;
  107. esac
  108. fi
  109.  
  110. ac_add_options --with-fpu="$ARCH_ARM_VFP"
  111.  
  112. if [ "${MOZ_DMD:-0}" != 0 ]; then
  113. ac_add_options --enable-dmd
  114. fi
  115.  
  116. if [ "${ENABLE_GLOBAL_PRELINK:-0}" != 0 ]; then
  117. # Disable ELF_HACK on B2G for prelink.
  118. ac_add_options --disable-elf-hack
  119. fi
  120.  
  121. if [ "$TARGET_BUILD_VARIANT" = eng ]; then
  122. # bug 979947 - Engineering builds should have
  123. # the profiler enabled by default
  124. ac_add_options --enable-profiling
  125. fi
  126. . "$topsrcdir/b2g/config/mozconfigs/common.override"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement