因为对全部软件包逐一核对上游后发现 42 个的 `LICENSE=` 与上游实际授权不符,所以按上游的授权文件与源码文件头改正,并为其中被误标为开源、实为专有的软件补上 `RESTRICT`。 最严重的一类是专有软件被标成开源:`deepin-wine-helper` 与 `deepin-wine-plugin` 的 deb 内 copyright 写着 `All rights reserved by Wuhan Deepin Technology Co., Ltd.`,`app-misc/z-library` 的 deb control 写 `License: unknown`,`media-sound/qqmusic` 用的 `CC0-1.0` 是公共领域捐弃、与腾讯的服务协议完全相反。 `net-proxy/clash-rs` 此前只有 `LICENSE+=`、没有基底 `LICENSE=`,主程序的 Apache-2.0 完全没有声明。 `sys-kernel/xanmod-sources` 的 `LICENSE+=" CDDL"` 在 xanmod patch 与 genpatches 中都找不到依据,一并删除。 Signed-off-by: Zakk <zakk@gentoozh.org>
92 lines
2.3 KiB
Bash
92 lines
2.3 KiB
Bash
# Copyright 1999-2024 Gentoo Authors
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
EAPI="8"
|
|
|
|
inherit meson
|
|
|
|
DESCRIPTION="Archlinux's binary package manager"
|
|
HOMEPAGE="https://pacman.archlinux.page/ https://wiki.archlinux.org/title/Pacman"
|
|
|
|
if [[ "${PV}" == *9999 ]]; then
|
|
inherit git-r3
|
|
EGIT_REPO_URI="https://gitlab.archlinux.org/pacman/pacman"
|
|
else
|
|
SRC_URI="https://gitlab.archlinux.org/pacman/pacman/-/archive/v${PV}/${PN}-v${PV}.tar.bz2 -> ${P}.tar.bz2"
|
|
# Do *not* re-add ~x86!
|
|
# https://www.archlinux.org/news/phasing-out-i686-support/
|
|
KEYWORDS="-* ~amd64"
|
|
fi
|
|
|
|
S="${WORKDIR}/${PN}-v${PV}"
|
|
LICENSE="GPL-2+"
|
|
SLOT="0/10"
|
|
|
|
IUSE="curl doc +gpg test"
|
|
DEPEND="
|
|
app-crypt/archlinux-keyring
|
|
app-arch/libarchive:=[lzma]
|
|
gpg? ( >=app-crypt/gpgme-1.13.0:= )
|
|
curl? ( net-misc/curl )
|
|
dev-libs/openssl:0=
|
|
virtual/libiconv
|
|
virtual/libintl
|
|
"
|
|
RDEPEND="
|
|
${DEPEND}
|
|
"
|
|
BDEPEND="
|
|
app-text/asciidoc
|
|
doc? ( app-text/doxygen )
|
|
test? (
|
|
sys-apps/fakeroot
|
|
sys-apps/fakechroot
|
|
)
|
|
"
|
|
|
|
# Plenty tests fail because we're actually not on a archlinux system.
|
|
RESTRICT="test"
|
|
|
|
src_configure() {
|
|
local emesonargs=(
|
|
-Dbuildstatic=false
|
|
# fix #3299, see https://bugs.gentoo.org/878913; https://bugs.gentoo.org/878603
|
|
--localstatedir "${EPREFIX}/var"
|
|
# Help protect Gentoo users from shooting into their feet.
|
|
-Droot-dir="${EPREFIX}/var/chroot/archlinux"
|
|
# full doc with doxygen
|
|
$(meson_feature doc doxygen)
|
|
$(meson_feature gpg gpgme)
|
|
$(meson_feature curl curl)
|
|
)
|
|
if [[ "${PV}" == *9999 ]]; then
|
|
emesonargs+=( -Duse-git-version=true )
|
|
fi
|
|
meson_src_configure
|
|
}
|
|
|
|
src_install() {
|
|
meson_src_install
|
|
keepdir /var/lib/pacman
|
|
}
|
|
|
|
pkg_postinst() {
|
|
/usr/bin/pacman-key --init || die
|
|
/usr/bin/pacman-key --populate archlinux || die
|
|
|
|
einfo
|
|
einfo "The default root dir was set to ${EPREFIX}/var/chroot/archlinux"
|
|
einfo "to avoid breaking Gentoo systems due to oscitancy."
|
|
einfo "If you prefer another directory, take a look at"
|
|
einfo "pacman's parameter -r|--root."
|
|
einfo
|
|
einfo "You will need to setup at least one mirror in"
|
|
einfo " /etc/pacman.d/mirrorlist."
|
|
einfo "This list is installed by sys-apps/pacman-mirrorlist but can be"
|
|
einfo "updated manually by fetching from"
|
|
einfo "https://wiki.archlinux.org/index.php/Mirror"
|
|
einfo
|
|
einfo "With pacman 5.1 contrib packages were moved into a seprate package."
|
|
einfo
|
|
}
|