Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Arch Linux
dbscripts
Commits
df487246
Verified
Commit
df487246
authored
Nov 18, 2021
by
Morten Linderud
🏄
Browse files
test/db-move: Fix split package handling
Signed-off-by:
Morten Linderud
<
morten@linderud.pw
>
parent
41758cf8
Changes
3
Hide whitespace changes
Inline
Side-by-side
db-move
View file @
df487246
...
...
@@ -112,11 +112,10 @@ for pkgbase in "${args[@]:2}"; do
add_pkgs+
=(
"
${
FTP_BASE
}
/
${
PKGPOOL
}
/
${
pkgfile
}
"
)
remove_pkgs+
=(
"
${
pkgname
}
"
)
done
debug_pkgpath
=
$(
getpkgfile
"
${
ftppath_debug_from
}
/
${
tarch
}
/
${
pkgbase
}
-debug-
${
pkgver
}
-
${
pkgarch
}
"
${
PKGEXTS
}
)
debug_pkgfile
=
"
${
debug_pkgpath
##*/
}
"
if
[[
-f
${
debug_pkgpath
}
]]
;
then
msg2
"Found debug package %s"
"
${
pkgbase
}
-debug"
msg2
"Found debug package %s
(%s)
"
"
${
pkgbase
}
-debug"
"
${
tarch
}
"
ln
-s
"../../../
${
DEBUGPKGPOOL
}
/
${
debug_pkgfile
}
"
"
${
ftppath_debug_to
}
/
${
tarch
}
/"
if
[[
-f
${
FTP_BASE
}
/
${
DEBUGPKGPOOL
}
/
${
debug_pkgfile
}
.sig
]]
;
then
ln
-s
"../../../
${
DEBUGPKGPOOL
}
/
${
debug_pkgfile
}
.sig"
"
${
ftppath_debug_to
}
/
${
tarch
}
/"
...
...
test/cases/db-move.bats
View file @
df487246
...
...
@@ -175,3 +175,21 @@ load ../lib/common
[ "$status" -ne 0 ]
[[ $output == *'notconfigured is not a valid'* ]]
}
@test "move split packages with debug" {
local arches=('x86_64')
local pkgs=('pkg-split-debuginfo')
local pkg
local pkgbase
local arch
for pkgbase in ${pkgs[@]}; do
releasePackage testing ${pkgbase}
done
db-update
db-move testing extra pkg-split-debuginfo
checkPackage extra pkg-split-debuginfo 1-1
checkPackage extra-debug pkg-split-debuginfo 1-1
}
test/fixtures/pkg-split-debuginfo/PKGBUILD
0 → 100644
View file @
df487246
pkgbase
=
pkg-split-debuginfo
pkgname
=(
'pkg-split-debuginfo1'
'pkg-split-debuginfo2'
)
pkgver
=
1
pkgrel
=
1
pkgdesc
=
"A split package called
${
pkgbase
}
with debuginfo"
arch
=(
'i686'
'x86_64'
)
url
=
'http://www.archlinux.org/'
license
=(
'GPL'
)
options
=(
'strip'
'debug'
)
package_pkg-split-debuginfo1
()
{
install
-D
-m755
/bin/true
${
pkgdir
}
/usr/bin/
${
pkgname
}
install
-D
/dev/null
"
${
pkgdir
}
"
/usr/bin/hello1
install
-D
/dev/null
"
${
pkgdir
}
"
/../
${
pkgname
}
-debug
/usr/lib/debug/usr/bin/hello1.debug
}
package_pkg-split-debuginfo2
()
{
install
-D
-m755
/bin/true
${
pkgdir
}
/usr/bin/
${
pkgname
}
install
-D
/dev/null
"
${
pkgdir
}
"
/usr/bin/hello2
install
-D
/dev/null
"
${
pkgdir
}
"
/../
${
pkgname
}
-debug
/usr/lib/debug/usr/bin/hello2.debug
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment