core-image.bbclass 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. # Common code for generating core reference images
  2. #
  3. # Copyright (C) 2007-2011 Linux Foundation
  4. #
  5. # SPDX-License-Identifier: MIT
  6. # IMAGE_FEATURES control content of the core reference images
  7. #
  8. # By default we install packagegroup-core-boot and packagegroup-base-extended packages;
  9. # this gives us working (console only) rootfs.
  10. #
  11. # Available IMAGE_FEATURES:
  12. #
  13. # - weston - Weston Wayland compositor
  14. # - x11 - X server
  15. # - x11-base - X server with minimal environment
  16. # - x11-sato - OpenedHand Sato environment
  17. # - tools-debug - debugging tools
  18. # - eclipse-debug - Eclipse remote debugging support
  19. # - tools-profile - profiling tools
  20. # - tools-testapps - tools usable to make some device tests
  21. # - tools-sdk - SDK (C/C++ compiler, autotools, etc.)
  22. # - nfs-server - NFS server
  23. # - nfs-client - NFS client
  24. # - ssh-server-dropbear - SSH server (dropbear)
  25. # - ssh-server-openssh - SSH server (openssh)
  26. # - hwcodecs - Install hardware acceleration codecs
  27. # - package-management - installs package management tools and preserves the package manager database
  28. # - serial-autologin-root - with 'empty-root-password': autologin 'root' on the serial console
  29. # - dev-pkgs - development packages (headers, etc.) for all installed packages in the rootfs
  30. # - dbg-pkgs - debug symbol packages for all installed packages in the rootfs
  31. # - lic-pkgs - license packages for all installed pacakges in the rootfs, requires
  32. # LICENSE_CREATE_PACKAGE="1" to be set when building packages too
  33. # - doc-pkgs - documentation packages for all installed packages in the rootfs
  34. # - bash-completion-pkgs - bash-completion packages for recipes using bash-completion bbclass
  35. # - ptest-pkgs - ptest packages for all ptest-enabled recipes
  36. # - read-only-rootfs - tweaks an image to support read-only rootfs
  37. # - stateless-rootfs - systemctl-native not run, image populated by systemd at runtime
  38. # - splash - bootup splash screen
  39. #
  40. # Features for development purposes (previously part of debug-tweaks):
  41. # - empty-root-password - the root user has no password set
  42. # - allow-empty-password - users can have an empty password
  43. # - allow-root-login - the root user can login
  44. # - post-install-logging - log the output of postinstall scriptlets
  45. #
  46. FEATURE_PACKAGES_weston = "packagegroup-core-weston"
  47. FEATURE_PACKAGES_x11 = "packagegroup-core-x11"
  48. FEATURE_PACKAGES_x11-base = "packagegroup-core-x11-base"
  49. FEATURE_PACKAGES_x11-sato = "packagegroup-core-x11-sato"
  50. FEATURE_PACKAGES_tools-debug = "packagegroup-core-tools-debug"
  51. FEATURE_PACKAGES_eclipse-debug = "packagegroup-core-eclipse-debug"
  52. FEATURE_PACKAGES_tools-profile = "packagegroup-core-tools-profile"
  53. FEATURE_PACKAGES_tools-testapps = "packagegroup-core-tools-testapps"
  54. FEATURE_PACKAGES_tools-sdk = "packagegroup-core-sdk packagegroup-core-standalone-sdk-target"
  55. FEATURE_PACKAGES_nfs-server = "packagegroup-core-nfs-server"
  56. FEATURE_PACKAGES_nfs-client = "packagegroup-core-nfs-client"
  57. FEATURE_PACKAGES_ssh-server-dropbear = "packagegroup-core-ssh-dropbear"
  58. FEATURE_PACKAGES_ssh-server-openssh = "packagegroup-core-ssh-openssh"
  59. FEATURE_PACKAGES_hwcodecs = "${MACHINE_HWCODECS}"
  60. # IMAGE_FEATURES_REPLACES_foo = 'bar1 bar2'
  61. # Including image feature foo would replace the image features bar1 and bar2
  62. IMAGE_FEATURES_REPLACES_ssh-server-openssh = "ssh-server-dropbear"
  63. # Do not install openssh complementary packages if either packagegroup-core-ssh-dropbear or dropbear
  64. # is installed # to avoid openssh-dropbear conflict
  65. # see [Yocto #14858] for more information
  66. PACKAGE_EXCLUDE_COMPLEMENTARY:append = "${@bb.utils.contains_any('PACKAGE_INSTALL', 'packagegroup-core-ssh-dropbear dropbear', ' openssh', '' , d)}"
  67. # IMAGE_FEATURES_CONFLICTS_foo = 'bar1 bar2'
  68. # An error exception would be raised if both image features foo and bar1(or bar2) are included
  69. MACHINE_HWCODECS ??= ""
  70. CORE_IMAGE_BASE_INSTALL = '\
  71. packagegroup-core-boot \
  72. packagegroup-base-extended \
  73. \
  74. ${CORE_IMAGE_EXTRA_INSTALL} \
  75. '
  76. CORE_IMAGE_EXTRA_INSTALL ?= ""
  77. IMAGE_INSTALL ?= "${CORE_IMAGE_BASE_INSTALL}"
  78. inherit image