Bug 3838 - Alternatives Section 7.3 obsolete
Summary: Alternatives Section 7.3 obsolete
Status: RESOLVED FIXED
Alias: None
Product: Reference
Classification: Documentation
Component: handbook (show other bugs)
Version: 1.4
Hardware: x86 Multiple
: Medium normal
Target Milestone: 1.4
Assignee: Scott Rifenbark
QA Contact:
URL: http://git.yoctoproject.org/cgit/cgit...
Whiteboard: 6 Feb 2013: resolved
Depends on:
Blocks:
 
Reported: 2013-02-04 12:31 UTC by Radu Moisan
Modified: 2013-02-06 13:41 UTC (History)
3 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Radu Moisan 2013-02-04 12:31:26 UTC
From update-alternatives.bbclass

# This class is used to help the alternatives system which is useful when
# multiple sources provide same command. You can use update-alternatives
# command directly in your recipe, but in most cases this class simplifies
# that job.
#
# To use this class a number of variables should be defined:
#
# List all of the alternatives needed by a package:
# ALTERNATIVE_<pkg> = "name1 name2 name3 ..."
#
#   i.e. ALTERNATIVE_busybox = "sh sed test bracket"
#
# The pathname of the link
# ALTERNATIVE_LINK_NAME[name] = "target"
#
#   This is the name of the binary once it's been installed onto the runtime.
#   This name is global to all split packages in this recipe, and should match
#   other recipes with the same functionality.
#   i.e. ALTERNATIVE_LINK_NAME[bracket] = "/usr/bin/["
#
# NOTE: If ALTERNATIVE_LINK_NAME is not defined, it defaults to ${bindir}/name
#
# The default link to create for all targets
# ALTERNATIVE_TARGET = "target"
#
#   This is useful in a multicall binary case
#   i.e. ALTERNATIVE_TARGET = "/bin/busybox"
#
# A non-default link to create for a target
# ALTERNATIVE_TARGET[name] = "target"
#
#   This is the name of the binary as it's been install by do_install
#   i.e. ALTERNATIVE_TARGET[sh] = "/bin/bash"
#
# A package specific link for a target
# ALTERNATIVE_TARGET_<pkg>[name] = "target"
#
#   This is useful when a recipe provides multiple alternatives for the
#   same item.
#
# NOTE: If ALTERNATIVE_TARGET is not defined, it will inherit the value
# from ALTERNATIVE_LINK_NAME.
#
# NOTE: If the ALTERNATIVE_LINK_NAME and ALTERNATIVE_TARGET are the same,
# ALTERNATIVE_TARGET will have '.{BPN}' appended to it.  If the file
# referenced has not been renamed, it will also be renamed.  (This avoids
# the need to rename alternative files in the do_install step, but still
# supports it if necessary for some reason.)
#
# The default priority for any alternatives
# ALTERNATIVE_PRIORITY = "priority"
#
#   i.e. default is ALTERNATIVE_PRIORITY = "10"
#
# The non-default priority for a specific target
# ALTERNATIVE_PRIORITY[name] = "priority"
#
# The package priority for a specific target
# ALTERNATIVE_PRIORITY_<pkg>[name] = "priority"
#
#
# -----
#
#
# The following describes deprecated behavior, using any of the
# following modes will result in a warning, and eventually an error:
#
# There are two basic modes supported: 'single update' and 'batch update'
#
# 'single update' is used for a single alternative command, and you're
# expected to provide at least below keywords:
#
#     ALTERNATIVE_NAME - the name that the alternative is registered
#     ALTERNATIVE_PATH - the path of installed alternative
#
# ALTERNATIVE_PRIORITY and ALTERNATIVE_LINK are optional which have defaults
# in this class.
#
# 'batch update' is used if you have multiple alternatives to be updated.
# Unlike 'single update', 'batch update' in most times only require two
# parameters:
#
#     ALTERNATIVE_LINKS - a list of symbolic links for which you'd like to
#                         create alternatives, with space as delimiter, e.g:
#
#         ALTERNATIVE_LINKS = "${bindir}/cmd1 ${sbindir}/cmd2 ..."
#
#     ALTERNATIVE_PRIORITY - optional, applies to all
#
# To simplify the design, this class has the assumption that for a name
# listed in ALTERNATIVE_LINKS, say /path/cmd:
#
#     the name of the alternative would be: cmd
#     the path of installed alternative would be: /path/cmd.${BPN}
#     ${D}/path/cmd will be renamed to ${D}/path/cmd.{BPN} automatically
#     priority will be the same from ALTERNATIVE_PRIORITY
#
# If above assumption breaks your requirement, then you still need to use
# your own update-alternatives command directly.

The manual refers to second part in description, which is marked as obsolete.
Comment 1 Scott Rifenbark 2013-02-05 15:37:41 UTC
Updated the section so that the deprecated area is not mentioned.  Section now is more generalized.  Please review this section and comment.  If I receive no comments in a reasonable amount of time I will close the bug.

Thanks,
Scott

http://www.yoctoproject.org/docs/1.4/ref-manual/ref-manual.html#ref-classes-update-alternatives
Comment 2 Radu Moisan 2013-02-06 07:29:03 UTC
It is fine.
Comment 3 Scott Rifenbark 2013-02-06 13:41:23 UTC
Thanks for the look Radu.  I am going to mark it resolved.

Scott