diff options
Diffstat (limited to 'eclass')
| -rw-r--r-- | eclass/desktop.eclass | 8 | ||||
| -rw-r--r-- | eclass/rust.eclass | 2 |
2 files changed, 9 insertions, 1 deletions
diff --git a/eclass/desktop.eclass b/eclass/desktop.eclass index 299d3d6f739f..5dcc695bfcdc 100644 --- a/eclass/desktop.eclass +++ b/eclass/desktop.eclass @@ -50,6 +50,7 @@ _DESKTOP_IDS=() # defined in code (including reverse qualified domain if set); # defaults to <command> # comment: Comment (menu entry tooltip), defaults to DESCRIPTION +# force: Force-write resulting desktop file (overwrite existing) # @CODE # # Example usage: @@ -82,7 +83,7 @@ make_desktop_entry() { [[ -z ${1} ]] && die "make_desktop_entry: You must specify at least a command" if [[ ${eapi9} ]]; then - local args cats cmd comment desktopid entries icon name + local args cats cmd comment desktopid entries force icon name while [[ $# -gt 0 ]] ; do case "${1}" in -a|--args) @@ -95,6 +96,8 @@ make_desktop_entry() { desktopid="${2}"; shift 2 ;; -e|--entry) entries+=( "${2}" ); shift 2 ;; + -f|--force) + force=1; shift 1 ;; -i|--icon) icon="${2}"; shift 2 ;; -n|--name) @@ -259,6 +262,9 @@ make_desktop_entry() { _DESKTOP_IDS+=( "${desktopid}" ) fi local desktop="${T}/${desktopid}.desktop" + if [[ ! ${force} && -e ${ED}/usr/share/applications/${desktopid}.desktop ]]; then + die "make_desktop_entry: desktopid \"${desktopid}\" already exists, must be unique" + fi else local desktop_exec="${cmd%%[[:space:]]*}" desktop_exec="${desktop_exec##*/}" diff --git a/eclass/rust.eclass b/eclass/rust.eclass index 0365a7640594..a13ea067dba3 100644 --- a/eclass/rust.eclass +++ b/eclass/rust.eclass @@ -68,6 +68,7 @@ fi # Definitive list of Rust slots and the associated LLVM slot, newest first. declare -A -g -r _RUST_LLVM_MAP=( ["9999"]=21 + ["1.92.0"]=21 ["1.91.0"]=21 ["1.90.0"]=20 ["1.89.0"]=20 @@ -98,6 +99,7 @@ declare -A -g -r _RUST_LLVM_MAP=( # this array is used to store the Rust slots in a more convenient order for iteration. declare -a -g -r _RUST_SLOTS_ORDERED=( "9999" + "1.92.0" "1.91.0" "1.90.0" "1.89.0" |
