diff options
-rw-r--r-- | documentation/ref-manual/variables.rst | 30 |
1 files changed, 27 insertions, 3 deletions
diff --git a/documentation/ref-manual/variables.rst b/documentation/ref-manual/variables.rst index e43dc38f32..5dc7ecbba7 100644 --- a/documentation/ref-manual/variables.rst +++ b/documentation/ref-manual/variables.rst | |||
@@ -4154,9 +4154,33 @@ system and gives an overview of their function and contents. | |||
4154 | IMAGE_ROOTFS_EXTRA_SPACE = "41943040" | 4154 | IMAGE_ROOTFS_EXTRA_SPACE = "41943040" |
4155 | 4155 | ||
4156 | :term:`IMAGE_ROOTFS_MAXSIZE` | 4156 | :term:`IMAGE_ROOTFS_MAXSIZE` |
4157 | Defines the maximum size in Kbytes for the generated image. If the | 4157 | Defines the maximum allowed size of the generated image in kilobytes. |
4158 | generated image size is above that, the build will fail. It's a good | 4158 | The build will fail if the generated image size exceeds this value. |
4159 | idea to set this variable for images that need to fit on a limited | 4159 | |
4160 | The generated image size undergoes several calculation steps before being | ||
4161 | compared to :term:`IMAGE_ROOTFS_MAXSIZE`. | ||
4162 | In the first step, the size of the directory pointed to by :term:`IMAGE_ROOTFS` | ||
4163 | is calculated. | ||
4164 | In the second step, the result from the first step is multiplied | ||
4165 | by :term:`IMAGE_OVERHEAD_FACTOR`. | ||
4166 | In the third step, the result from the second step is compared with | ||
4167 | :term:`IMAGE_ROOTFS_SIZE`. The larger value of these is added to | ||
4168 | :term:`IMAGE_ROOTFS_EXTRA_SPACE`. | ||
4169 | In the fourth step, the result from the third step is checked for | ||
4170 | a decimal part. If it has one, it is rounded up to the next integer. | ||
4171 | If it does not, it is simply converted into an integer. | ||
4172 | In the fifth step, the :term:`IMAGE_ROOTFS_ALIGNMENT` is added to the result | ||
4173 | from the fourth step and "1" is subtracted. | ||
4174 | In the sixth step, the remainder of the division between the result | ||
4175 | from the fifth step and :term:`IMAGE_ROOTFS_ALIGNMENT` is subtracted from the | ||
4176 | result of the fifth step. In this way, the result from the fourth step is | ||
4177 | rounded up to the nearest multiple of :term:`IMAGE_ROOTFS_ALIGNMENT`. | ||
4178 | |||
4179 | Thus, if the :term:`IMAGE_ROOTFS_MAXSIZE` is set, is compared with the result | ||
4180 | of the above calculations and is independent of the final image type. | ||
4181 | No default value is set for :term:`IMAGE_ROOTFS_MAXSIZE`. | ||
4182 | |||
4183 | It's a good idea to set this variable for images that need to fit on a limited | ||
4160 | space (e.g. SD card, a fixed-size partition, ...). | 4184 | space (e.g. SD card, a fixed-size partition, ...). |
4161 | 4185 | ||
4162 | :term:`IMAGE_ROOTFS_SIZE` | 4186 | :term:`IMAGE_ROOTFS_SIZE` |