mirror of
https://github.com/moparisthebest/pacman
synced 2024-08-13 17:03:46 -04:00
makepkg: fix -r and --needed conflict
In makepkg, passing -sr --needed causes there to be a conflict when pacman goes to remove the dependencies, as the --needed flag is not an option for pacman -R. This patch makes --needed not get added to the PACMAN_OPTS array, but it acts like ASDEPS, and is only added to an install function. Signed-off-by: William Giokas <1007380@gmail.com> Signed-off-by: Allan McRae <allan@archlinux.org>
This commit is contained in:
parent
bafee395a6
commit
42b492b2fd
@ -54,6 +54,7 @@ readonly -a packaging_options other_options splitpkg_overrides
|
|||||||
|
|
||||||
# Options
|
# Options
|
||||||
ASDEPS=0
|
ASDEPS=0
|
||||||
|
NEEDED=0
|
||||||
ASROOT=0
|
ASROOT=0
|
||||||
CLEANUP=0
|
CLEANUP=0
|
||||||
DEP_BIN=0
|
DEP_BIN=0
|
||||||
@ -1985,6 +1986,7 @@ install_package() {
|
|||||||
|
|
||||||
local fullver pkgarch pkg pkglist
|
local fullver pkgarch pkg pkglist
|
||||||
(( ASDEPS )) && pkglist+=('--asdeps')
|
(( ASDEPS )) && pkglist+=('--asdeps')
|
||||||
|
(( NEEDED )) && pkglist+=('--needed')
|
||||||
|
|
||||||
for pkg in ${pkgname[@]}; do
|
for pkg in ${pkgname[@]}; do
|
||||||
fullver=$(get_full_version $pkg)
|
fullver=$(get_full_version $pkg)
|
||||||
@ -2471,7 +2473,7 @@ while true; do
|
|||||||
# Pacman Options
|
# Pacman Options
|
||||||
--asdeps) ASDEPS=1;;
|
--asdeps) ASDEPS=1;;
|
||||||
--noconfirm) PACMAN_OPTS+=" --noconfirm" ;;
|
--noconfirm) PACMAN_OPTS+=" --noconfirm" ;;
|
||||||
--needed) PACMAN_OPTS+=" --needed" ;;
|
--needed) NEEDED=1;;
|
||||||
--noprogressbar) PACMAN_OPTS+=" --noprogressbar" ;;
|
--noprogressbar) PACMAN_OPTS+=" --noprogressbar" ;;
|
||||||
|
|
||||||
# Makepkg Options
|
# Makepkg Options
|
||||||
|
Loading…
Reference in New Issue
Block a user