mozinfo.rst 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170
  1. .. _mozinfo:
  2. =======
  3. mozinfo
  4. =======
  5. ``mozinfo`` is a solution for representing a subset of build
  6. configuration and run-time data.
  7. ``mozinfo`` data is typically accessed through a ``mozinfo.json`` file
  8. which is written to the :term:`object directory` during build
  9. configuration. The code for writing this file lives in
  10. :py:mod:`mozbuild.mozinfo`.
  11. ``mozinfo.json`` is an object/dictionary of simple string values.
  12. The attributes in ``mozinfo.json`` are used for many purposes. One use
  13. is to filter tests for applicability to the current build. For more on
  14. this, see :ref:`test_manifests`.
  15. .. _mozinfo_attributes:
  16. mozinfo.json Attributes
  17. =================================
  18. ``mozinfo`` currently records the following attributes.
  19. appname
  20. The application being built.
  21. Value comes from ``MOZ_APP_NAME`` from ``config.status``.
  22. Optional.
  23. asan
  24. Whether address sanitization is enabled.
  25. Values are ``true`` and ``false``.
  26. Always defined.
  27. bin_suffix
  28. The file suffix for binaries produced with this build.
  29. Values may be an empty string, as not all platforms have a binary
  30. suffix.
  31. Always defined.
  32. bits
  33. The number of bits in the CPU this build targets.
  34. Values are typically ``32`` or ``64``.
  35. Universal Mac builds do not have this key defined.
  36. Unkown processor architectures (see ``processor`` below) may not have
  37. this key defined.
  38. Optional.
  39. buildapp
  40. The path to the XUL application being built.
  41. For desktop Firefox, this is ``browser``. For Fennec, it's
  42. ``mobile/android``. For B2G, it's ``b2g``.
  43. crashreporter
  44. Whether the crash reporter is enabled for this build.
  45. Values are ``true`` and ``false``.
  46. Always defined.
  47. datareporting
  48. Whether data reporting (MOZ_DATA_REPORTING) is enabled for this build.
  49. Values are ``true`` and ``false``.
  50. Always defined.
  51. debug
  52. Whether this is a debug build.
  53. Values are ``true`` and ``false``.
  54. Always defined.
  55. healthreport
  56. Whether the Health Report feature is enabled.
  57. Values are ``true`` and ``false``.
  58. Always defined.
  59. mozconfig
  60. The path of the :ref:`mozconfig file <mozconfig>` used to produce this build.
  61. Optional.
  62. nightly_build
  63. Whether this is a nightly build.
  64. Values are ``true`` and ``false``.
  65. Always defined.
  66. os
  67. The operating system the build is produced for. Values for tier-1
  68. supported platforms are ``linux``, ``win``, ``mac``, ``b2g``, and
  69. ``android``. For other platforms, the value is the lowercase version
  70. of the ``OS_TARGET`` variable from ``config.status``.
  71. Always defined.
  72. processor
  73. Information about the processor architecture this build targets.
  74. Values come from ``TARGET_CPU``, however some massaging may be
  75. performed.
  76. If the build is a universal build on Mac (it targets both 32-bit and
  77. 64-bit), the value is ``universal-x86-x86_64``.
  78. If the value starts with ``arm``, the value is ``arm``.
  79. If the value starts with a string of the form ``i[3-9]86]``, the
  80. value is ``x86``.
  81. Always defined.
  82. release_or_beta
  83. Whether this is a release or beta build.
  84. Values are ``true`` and ``false``.
  85. Always defined.
  86. tests_enabled
  87. Whether tests are enabled for this build.
  88. Values are ``true`` and ``false``.
  89. Always defined.
  90. toolkit
  91. The widget toolkit in case. The value comes from the
  92. ``MOZ_WIDGET_TOOLKIT`` ``config.status`` variable.
  93. Always defined.
  94. topsrcdir
  95. The path to the source directory the build came from.
  96. Always defined.
  97. wave
  98. Whether Wave audio support is enabled.
  99. Values are ``true`` and ``false``.
  100. Always defined.
  101. webm
  102. Whether WebM support is enabled.
  103. Values are ``true`` and ``false``.
  104. Always defined.