diff options
author | Quentin Schulz <quentin.schulz@cherry.de> | 2025-01-27 19:37:04 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-02-18 15:47:37 +0000 |
commit | 9d7930a4e0d0566e41ad0e0cf551cab04e847d64 (patch) | |
tree | b9d968f5454135b8b1304fa66b4e5cff5ee4a4dc /documentation/ref-manual | |
parent | 09849475c8bdd711fc07c4ef4bb0ae13de046817 (diff) | |
download | poky-9d7930a4e0d0566e41ad0e0cf551cab04e847d64.tar.gz |
docs: use literalinclude for system requirements
The YAML variables for the host dependencies are updated by hand and
actually only used inside code blocks.
Let's migrate all instructions into separate shell scripts that are then
literalinclude'd into the Sphinx documentation.
This allows a few things:
- ability to run shellcheck on the scripts if we ever want to
- manually calling the appropriate script from a supported distro to
build stuff (distro or bitbake/yocto stuff)
- use this script to create containers to do CI of documentation on
different distros, to make sure our instructions are all up to date,
(From yocto-docs rev: 8d993022c2aefc0fde9baa949d39d7a3613f9f46)
Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de>
Reviewed-by: Antonin Godard <antonin.godard@bootlin.com>
Tested-by: Antonin Godard <antonin.godard@bootlin.com>
Signed-off-by: Antonin Godard <antonin.godard@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'documentation/ref-manual')
-rw-r--r-- | documentation/ref-manual/system-requirements.rst | 82 |
1 files changed, 47 insertions, 35 deletions
diff --git a/documentation/ref-manual/system-requirements.rst b/documentation/ref-manual/system-requirements.rst index b087d374d2..93b95a7fb2 100644 --- a/documentation/ref-manual/system-requirements.rst +++ b/documentation/ref-manual/system-requirements.rst | |||
@@ -158,9 +158,10 @@ Ubuntu and Debian | |||
158 | ----------------- | 158 | ----------------- |
159 | 159 | ||
160 | Here are the packages needed to build an image on a headless system | 160 | Here are the packages needed to build an image on a headless system |
161 | with a supported Ubuntu or Debian Linux distribution:: | 161 | with a supported Ubuntu or Debian Linux distribution: |
162 | 162 | ||
163 | $ sudo apt install &UBUNTU_DEBIAN_HOST_PACKAGES_ESSENTIAL; | 163 | .. literalinclude:: ../tools/host_packages_scripts/ubuntu_essential.sh |
164 | :language: shell | ||
164 | 165 | ||
165 | You also need to ensure you have the ``en_US.UTF-8`` locale enabled:: | 166 | You also need to ensure you have the ``en_US.UTF-8`` locale enabled:: |
166 | 167 | ||
@@ -189,64 +190,71 @@ If this is not the case, you can reconfigure the ``locales`` package to add it | |||
189 | $ sudo apt build-dep qemu | 190 | $ sudo apt build-dep qemu |
190 | $ sudo apt remove oss4-dev | 191 | $ sudo apt remove oss4-dev |
191 | 192 | ||
192 | Here are the packages needed to build Project documentation manuals:: | 193 | Here are the packages needed to build Project documentation manuals: |
193 | 194 | ||
194 | $ sudo apt install &UBUNTU_DEBIAN_HOST_PACKAGES_DOC; | 195 | .. literalinclude:: ../tools/host_packages_scripts/ubuntu_docs.sh |
196 | :language: shell | ||
195 | 197 | ||
196 | In addition to the previous packages, here are the packages needed to build the | 198 | In addition to the previous packages, here are the packages needed to build the |
197 | documentation in PDF format:: | 199 | documentation in PDF format: |
198 | 200 | ||
199 | $ sudo apt install &UBUNTU_DEBIAN_HOST_PACKAGES_DOC_PDF; | 201 | .. literalinclude:: ../tools/host_packages_scripts/ubuntu_docs_pdf.sh |
202 | :language: shell | ||
200 | 203 | ||
201 | Fedora Packages | 204 | Fedora Packages |
202 | --------------- | 205 | --------------- |
203 | 206 | ||
204 | Here are the packages needed to build an image on a headless system | 207 | Here are the packages needed to build an image on a headless system |
205 | with a supported Fedora Linux distribution:: | 208 | with a supported Fedora Linux distribution: |
206 | 209 | ||
207 | $ sudo dnf install &FEDORA_HOST_PACKAGES_ESSENTIAL; | 210 | .. literalinclude:: ../tools/host_packages_scripts/fedora_essential.sh |
211 | :language: shell | ||
208 | 212 | ||
209 | Here are the packages needed to build Project documentation manuals:: | 213 | Here are the packages needed to build Project documentation manuals: |
210 | 214 | ||
211 | $ sudo dnf install &FEDORA_HOST_PACKAGES_DOC; | 215 | .. literalinclude:: ../tools/host_packages_scripts/fedora_docs.sh |
212 | $ sudo pip3 install &PIP3_HOST_PACKAGES_DOC; | 216 | :language: shell |
217 | |||
218 | .. literalinclude:: ../tools/host_packages_scripts/pip3_docs.sh | ||
219 | :language: shell | ||
213 | 220 | ||
214 | In addition to the previous packages, here are the packages needed to build the | 221 | In addition to the previous packages, here are the packages needed to build the |
215 | documentation in PDF format:: | 222 | documentation in PDF format: |
216 | 223 | ||
217 | $ sudo dnf install &FEDORA_HOST_PACKAGES_DOC_PDF; | 224 | .. literalinclude:: ../tools/host_packages_scripts/fedora_docs_pdf.sh |
225 | :language: shell | ||
218 | 226 | ||
219 | openSUSE Packages | 227 | openSUSE Packages |
220 | ----------------- | 228 | ----------------- |
221 | 229 | ||
222 | Here are the packages needed to build an image on a headless system | 230 | Here are the packages needed to build an image on a headless system |
223 | with a supported openSUSE distribution:: | 231 | with a supported openSUSE distribution: |
224 | 232 | ||
225 | $ sudo zypper install &OPENSUSE_HOST_PACKAGES_ESSENTIAL; | 233 | .. literalinclude:: ../tools/host_packages_scripts/opensuse_essential.sh |
226 | $ sudo pip3 install &OPENSUSE_PIP3_HOST_PACKAGES_ESSENTIAL; | 234 | :language: shell |
227 | 235 | ||
228 | Here are the packages needed to build Project documentation manuals:: | 236 | Here are the packages needed to build Project documentation manuals: |
229 | 237 | ||
230 | $ sudo zypper install &OPENSUSE_HOST_PACKAGES_DOC; | 238 | .. literalinclude:: ../tools/host_packages_scripts/opensuse_docs.sh |
231 | $ sudo pip3 install &PIP3_HOST_PACKAGES_DOC; | 239 | :language: shell |
232 | 240 | ||
233 | In addition to the previous packages, here are the packages needed to build the | 241 | .. literalinclude:: ../tools/host_packages_scripts/pip3_docs.sh |
234 | documentation in PDF format:: | 242 | :language: shell |
235 | 243 | ||
236 | $ sudo zypper install &OPENSUSE_HOST_PACKAGES_DOC_PDF; | 244 | In addition to the previous packages, here are the packages needed to build the |
245 | documentation in PDF format: | ||
237 | 246 | ||
247 | .. literalinclude:: ../tools/host_packages_scripts/opensuse_docs_pdf.sh | ||
248 | :language: shell | ||
238 | 249 | ||
239 | AlmaLinux Packages | 250 | AlmaLinux Packages |
240 | ------------------ | 251 | ------------------ |
241 | 252 | ||
242 | Here are the packages needed to build an image on a headless system | 253 | Here are the packages needed to build an image on a headless system |
243 | with a supported AlmaLinux distribution:: | 254 | with a supported AlmaLinux distribution: |
244 | 255 | ||
245 | $ sudo dnf install -y epel-release | 256 | .. literalinclude:: ../tools/host_packages_scripts/almalinux_essential.sh |
246 | $ sudo yum install dnf-plugins-core | 257 | :language: shell |
247 | $ sudo dnf config-manager --set-enabled crb | ||
248 | $ sudo dnf makecache | ||
249 | $ sudo dnf install &ALMALINUX_HOST_PACKAGES_ESSENTIAL; | ||
250 | 258 | ||
251 | .. note:: | 259 | .. note:: |
252 | 260 | ||
@@ -261,15 +269,13 @@ with a supported AlmaLinux distribution:: | |||
261 | - The ``makecache`` command consumes additional Metadata from | 269 | - The ``makecache`` command consumes additional Metadata from |
262 | ``epel-release``. | 270 | ``epel-release``. |
263 | 271 | ||
264 | Here are the packages needed to build Project documentation manuals:: | 272 | Here are the packages needed to build Project documentation manuals: |
265 | |||
266 | $ sudo dnf install &ALMALINUX_HOST_PACKAGES_DOC; | ||
267 | $ sudo pip3 install &PIP3_HOST_PACKAGES_DOC; | ||
268 | 273 | ||
269 | In addition to the previous packages, here are the packages needed to build the | 274 | .. literalinclude:: ../tools/host_packages_scripts/almalinux_docs.sh |
270 | documentation in PDF format:: | 275 | :language: shell |
271 | 276 | ||
272 | $ sudo dnf install &ALMALINUX_HOST_PACKAGES_DOC_PDF; | 277 | .. literalinclude:: ../tools/host_packages_scripts/pip3_docs.sh |
278 | :language: shell | ||
273 | 279 | ||
274 | .. warning:: | 280 | .. warning:: |
275 | 281 | ||
@@ -278,6 +284,12 @@ documentation in PDF format:: | |||
278 | ``texlive-collection-latexextra``, so you may run into issues. These may be | 284 | ``texlive-collection-latexextra``, so you may run into issues. These may be |
279 | installed using `tlmgr <https://tug.org/texlive/tlmgr.html>`_. | 285 | installed using `tlmgr <https://tug.org/texlive/tlmgr.html>`_. |
280 | 286 | ||
287 | In addition to the previous packages, here are the packages needed to build the | ||
288 | documentation in PDF format: | ||
289 | |||
290 | .. literalinclude:: ../tools/host_packages_scripts/almalinux_docs_pdf.sh | ||
291 | :language: shell | ||
292 | |||
281 | .. _system-requirements-buildtools: | 293 | .. _system-requirements-buildtools: |
282 | 294 | ||
283 | Required Git, tar, Python, make and gcc Versions | 295 | Required Git, tar, Python, make and gcc Versions |