linamh/net-fs/ncpfs/ncpfs-2.2.6-r5.ebuild

99 lines
2.4 KiB
Bash
Raw Normal View History

2022-03-01 11:46:08 +01:00
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
2023-07-20 20:28:34 +02:00
EAPI=8
2022-03-01 11:46:08 +01:00
inherit pam
DESCRIPTION="Provides access to Netware services using the NCP protocol"
HOMEPAGE="ftp://platan.vc.cvut.cz/pub/linux/ncpfs/"
SRC_URI="ftp://platan.vc.cvut.cz/pub/linux/${PN}/${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~mips ~ppc ~ppc64 ~x86"
IUSE="nls pam"
DEPEND="
nls? ( sys-devel/gettext )
pam? ( sys-libs/pam )"
2022-11-19 21:49:12 +01:00
RDEPEND="${DEPEND}
net-fs/ncpfs-modules
net-misc/ipx-utils"
2022-03-01 11:46:08 +01:00
PATCHES=(
# Build fixes.
"${FILESDIR}"/${P}-gcc4.patch
"${FILESDIR}"/${P}-missing-includes.patch
# Add a patch to fix multiple vulnerabilities.
# CVE-2010-0788, CVE-2010-0790, & CVE-2010-0791.
# http://seclists.org/fulldisclosure/2010/Mar/122
"${FILESDIR}"/${P}-multiple-vulns.patch
# Add a patch that removes the __attribute__((packed)); directive
# from several struct members in include/ncp/ncplib.h. This will
# cut down on a large number of compile warnings generated by modern
# gcc releases.
"${FILESDIR}"/${P}-remove-packed-attrib.patch
# Misc patches borrowed from Mageia.
"${FILESDIR}"/${P}-align-fix.patch
"${FILESDIR}"/${P}-getuid-fix.patch
"${FILESDIR}"/${P}-pam_ncp_auth-fix.patch
"${FILESDIR}"/${P}-servername-array-fix.patch
# Misc patches borrowed from Debian.
# Fixes Bug #497278
"${FILESDIR}"/${P}-drop-kernel-check.patch
"${FILESDIR}"/${P}-drop-mtab-support.patch
"${FILESDIR}"/${P}-no-suid-root.patch
"${FILESDIR}"/${P}-remove-libncp_atomic-header.patch
# Support LDFLAGS.
"${FILESDIR}"/${P}-ldflags-support.patch
# Bug 446696. This might need re-diffing if additional Makefile
# fixes are added.
"${FILESDIR}"/${P}-makefile-fix-soname-link.patch
2022-11-19 21:49:12 +01:00
#"${FILESDIR}"/${P}-gcc10.patch
2024-04-15 12:53:08 +02:00
"${FILESDIR}"/${P}-usr-merge.patch
2022-03-01 11:46:08 +01:00
)
DOCS=( FAQ README )
src_prepare() {
# Bug #273484.
sed -i '/ldconfig/d' lib/Makefile.in || die
2022-11-19 21:49:12 +01:00
append-cflags -fcommon
2022-03-01 11:46:08 +01:00
default
}
src_configure() {
# PHP integration no longer supported in Gentoo, per Bug #582516.
econf \
2024-04-15 12:53:08 +02:00
--prefix="${EPREFIX}/usr" \
2022-03-01 11:46:08 +01:00
$(use_enable nls) \
$(use_enable pam pam "$(getpam_mod_dir)") \
2022-11-19 21:49:12 +01:00
--disable-php \
--disable-ipx-tools
2022-03-01 11:46:08 +01:00
}
src_install() {
2024-04-15 12:53:08 +02:00
dodir $(getpam_mod_dir) /usr/sbin
2022-03-01 11:46:08 +01:00
# Install main software and headers.
emake DESTDIR="${D}" install
emake DESTDIR="${D}" install-dev
# Install a startup script in /etc/init.d and a conf file in /etc/conf.d
2022-11-19 21:49:12 +01:00
#newconfd "${FILESDIR}"/ipx.confd ipx
#newinitd "${FILESDIR}"/ipx.init ipx
2022-03-01 11:46:08 +01:00
einstalldocs
}