Hi !
Take a look at the aria2 PKGBUILD (https://gitea.artixlinux.org/packages/aria2/src/branch/master/PKGBUILD)
I think we could
simplify the package() function by removing this part:
# add bash completion
install -d "$pkgdir"/usr/share/bash-completion/completions
install -m644 "$pkgdir"/usr/share/doc/aria2/bash_completion/aria2c \
"$pkgdir"/usr/share/bash-completion/completions
and by adding this flag in the build() function:
./configure \
--with-bashcompletiondir=/usr/share/bash-completion/completions
::)