blob: 86307877dbb7a58cd78328e56eec62caf95b8b4b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit autotools
if [[ ${PV} == *9999 ]] ; then
EGIT_REPO_URI="https://github.com/kyz/libmspack.git"
inherit git-r3
MY_P="${PN}-9999"
else
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~arm64-macos ~x64-macos ~x64-solaris"
MY_PV="${PV/_alpha/alpha}"
MY_P="${PN}-${MY_PV}"
SRC_URI="https://www.cabextract.org.uk/libmspack/libmspack-${MY_PV}.tar.gz"
fi
DESCRIPTION="A library for Microsoft compression formats"
HOMEPAGE="https://www.cabextract.org.uk/libmspack/"
LICENSE="LGPL-2.1"
SLOT="0"
IUSE="debug doc"
S="${WORKDIR}/${MY_P}"
src_prepare() {
if [[ ${PV} == *9999 ]] ; then
# Re-create file layout from release tarball
pushd "${WORKDIR}" > /dev/null || die
cp -aL "${S}"/${PN} "${WORKDIR}"/${PN}-source || die
rm -r "${S}" || die
mv "${WORKDIR}"/${PN}-source "${S}" || die
popd > /dev/null || die
fi
default
eautoreconf
}
src_configure() {
econf $(use_enable debug)
}
src_test() {
default
cd "${S}"/test || die
./cabd_test || die
}
src_install() {
use doc && HTML_DOCS=( doc/. )
default
if use doc ; then
rm "${ED}"/usr/share/doc/"${PF}"/html/{Makefile*,Doxyfile*} || die
fi
find "${ED}" -name '*.la' -delete || die
find "${ED}" -name "*.a" -delete || die
}
|