blob: b65f0331dd6964fd61b9936cead4e729af3b4ce4 (
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
|
# Copyright 2022-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
ADA_COMPAT=( gcc_12 gcc_13 )
PYTHON_COMPAT=( python3_{10..13} python3_13t )
inherit ada python-any-r1 multiprocessing
SpecV=0.31.2
SpecN="commonmark-spec"
Spec=${SpecN}-${SpecV}
DESCRIPTION="Provides a markdown parser written in Ada"
HOMEPAGE="https://github.com/AdaCore/markdown"
SRC_URI="https://github.com/AdaCore/${PN}/archive/refs/tags/v${PV}.tar.gz
-> ${P}.tar.gz
test? (
https://github.com/commonmark/${SpecN}/archive/refs/tags/${SpecV}.tar.gz
-> ${Spec}.tar.gz
)"
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64 ~arm64 ~x86"
IUSE="test"
RESTRICT="!test? ( test )"
RDEPEND="${ADA_DEPS}
dev-ada/gprbuild[${ADA_USEDEP}]
dev-ada/VSS[${ADA_USEDEP}]"
DEPEND="${RDEPEND}"
BDEPEND="test? ( ${PYTHON_DEPS} )"
src_prepare() {
if use test; then
mv ../${Spec} ${SpecN} || die
sed -i -e "s|python3|python|" Makefile || die
fi
default
}
src_compile() {
gprbuild -v -p -j$(makeopts_jobs) -XBUILD_MODE=dev gnat/markdown.gpr \
-cargs ${ADAFLAGS} || die
}
src_test() {
emake build_tests
emake check_markdown
diff -u testsuite/commonmark/xfails.txt \
commonmark-spec/markdown_tests_result || die
}
|