Gentoo Archives: gentoo-commits

From: Andrew Ammerlaan <andrewammerlaan@××××××.net>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/proj/guru:master commit in: dev-cpp/mastodonpp/
Date: Sat, 28 Nov 2020 13:58:01
Message-Id: 1606487319.f8ca58ad6502dd0e0b91c1fce2004dc7ce283766.andrewammerlaan@gentoo
1 commit: f8ca58ad6502dd0e0b91c1fce2004dc7ce283766
2 Author: Ronny (tastytea) Gutbrod <gentoo <AT> tastytea <DOT> de>
3 AuthorDate: Fri Nov 27 14:18:00 2020 +0000
4 Commit: Andrew Ammerlaan <andrewammerlaan <AT> riseup <DOT> net>
5 CommitDate: Fri Nov 27 14:28:39 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=f8ca58ad
7
8 dev-cpp/mastodonpp: New package.
9
10 C++ wrapper for the Mastodon and Pleroma APIs.
11
12 Signed-off-by: Ronny (tastytea) Gutbrod <gentoo <AT> tastytea.de>
13
14 dev-cpp/mastodonpp/Manifest | 1 +
15 dev-cpp/mastodonpp/mastodonpp-0.5.7.ebuild | 59 ++++++++++++++++++++++++++++++
16 dev-cpp/mastodonpp/mastodonpp-9999.ebuild | 59 ++++++++++++++++++++++++++++++
17 dev-cpp/mastodonpp/metadata.xml | 16 ++++++++
18 4 files changed, 135 insertions(+)
19
20 diff --git a/dev-cpp/mastodonpp/Manifest b/dev-cpp/mastodonpp/Manifest
21 new file mode 100644
22 index 00000000..0d31c4cf
23 --- /dev/null
24 +++ b/dev-cpp/mastodonpp/Manifest
25 @@ -0,0 +1 @@
26 +DIST mastodonpp-0.5.7.tar.gz 48181 BLAKE2B cce2b9b61c3cb88a5246888d97b5495979b15e41b1e6d5499d09f00cd24fc94b78a983d634ec28dee0d537642294542235efa261faaa3320ab905f7196b16133 SHA512 83efbd32f7cde6a19546c21d99ed1c8b747ac995b69a5e87876bd0ea0aa9c932d0d255ed2cbe5b0fe4a92aec06d6c75d455f13e9537aade31176ec757916b27a
27
28 diff --git a/dev-cpp/mastodonpp/mastodonpp-0.5.7.ebuild b/dev-cpp/mastodonpp/mastodonpp-0.5.7.ebuild
29 new file mode 100644
30 index 00000000..60770d51
31 --- /dev/null
32 +++ b/dev-cpp/mastodonpp/mastodonpp-0.5.7.ebuild
33 @@ -0,0 +1,59 @@
34 +# Copyright 1999-2020 Gentoo Authors
35 +# Distributed under the terms of the GNU General Public License v2
36 +
37 +EAPI=7
38 +
39 +inherit cmake
40 +[[ "${PV}" == "9999" ]] && inherit git-r3
41 +
42 +DESCRIPTION="C++ wrapper for the Mastodon and Pleroma APIs."
43 +HOMEPAGE="https://schlomp.space/tastytea/mastodonpp"
44 +if [[ "${PV}" != "9999" ]]; then
45 + SRC_URI="https://schlomp.space/tastytea/mastodonpp/archive/${PV}.tar.gz -> ${P}.tar.gz"
46 + S="${WORKDIR}/${PN}"
47 + KEYWORDS="~amd64"
48 +else
49 + EGIT_REPO_URI="https://schlomp.space/tastytea/mastodonpp.git"
50 +fi
51 +
52 +LICENSE="AGPL-3"
53 +SLOT="0"
54 +IUSE="doc examples test"
55 +
56 +RDEPEND=">=net-misc/curl-7.56.0[ssl]"
57 +DEPEND="${RDEPEND}"
58 +BDEPEND="
59 + doc? ( app-doc/doxygen[dot] )
60 + test? ( dev-cpp/catch )
61 +"
62 +
63 +RESTRICT="!test? ( test )"
64 +
65 +src_configure() {
66 + local mycmakeargs=(
67 + -DWITH_EXAMPLES=NO
68 + -DWITH_TESTS="$(usex test)"
69 + -DWITH_DOC="$(usex doc)"
70 + )
71 +
72 + cmake_src_configure
73 +}
74 +
75 +src_test() {
76 + BUILD_DIR="${BUILD_DIR}/tests" cmake_src_test
77 +}
78 +
79 +src_install() {
80 + if use doc; then
81 + HTML_DOCS="${BUILD_DIR}/doc/html/*"
82 + fi
83 +
84 + if use examples; then
85 + docinto examples
86 + for file in examples/*.cpp; do
87 + dodoc ${file}
88 + done
89 + fi
90 +
91 + cmake_src_install
92 +}
93
94 diff --git a/dev-cpp/mastodonpp/mastodonpp-9999.ebuild b/dev-cpp/mastodonpp/mastodonpp-9999.ebuild
95 new file mode 100644
96 index 00000000..60770d51
97 --- /dev/null
98 +++ b/dev-cpp/mastodonpp/mastodonpp-9999.ebuild
99 @@ -0,0 +1,59 @@
100 +# Copyright 1999-2020 Gentoo Authors
101 +# Distributed under the terms of the GNU General Public License v2
102 +
103 +EAPI=7
104 +
105 +inherit cmake
106 +[[ "${PV}" == "9999" ]] && inherit git-r3
107 +
108 +DESCRIPTION="C++ wrapper for the Mastodon and Pleroma APIs."
109 +HOMEPAGE="https://schlomp.space/tastytea/mastodonpp"
110 +if [[ "${PV}" != "9999" ]]; then
111 + SRC_URI="https://schlomp.space/tastytea/mastodonpp/archive/${PV}.tar.gz -> ${P}.tar.gz"
112 + S="${WORKDIR}/${PN}"
113 + KEYWORDS="~amd64"
114 +else
115 + EGIT_REPO_URI="https://schlomp.space/tastytea/mastodonpp.git"
116 +fi
117 +
118 +LICENSE="AGPL-3"
119 +SLOT="0"
120 +IUSE="doc examples test"
121 +
122 +RDEPEND=">=net-misc/curl-7.56.0[ssl]"
123 +DEPEND="${RDEPEND}"
124 +BDEPEND="
125 + doc? ( app-doc/doxygen[dot] )
126 + test? ( dev-cpp/catch )
127 +"
128 +
129 +RESTRICT="!test? ( test )"
130 +
131 +src_configure() {
132 + local mycmakeargs=(
133 + -DWITH_EXAMPLES=NO
134 + -DWITH_TESTS="$(usex test)"
135 + -DWITH_DOC="$(usex doc)"
136 + )
137 +
138 + cmake_src_configure
139 +}
140 +
141 +src_test() {
142 + BUILD_DIR="${BUILD_DIR}/tests" cmake_src_test
143 +}
144 +
145 +src_install() {
146 + if use doc; then
147 + HTML_DOCS="${BUILD_DIR}/doc/html/*"
148 + fi
149 +
150 + if use examples; then
151 + docinto examples
152 + for file in examples/*.cpp; do
153 + dodoc ${file}
154 + done
155 + fi
156 +
157 + cmake_src_install
158 +}
159
160 diff --git a/dev-cpp/mastodonpp/metadata.xml b/dev-cpp/mastodonpp/metadata.xml
161 new file mode 100644
162 index 00000000..a4a476a4
163 --- /dev/null
164 +++ b/dev-cpp/mastodonpp/metadata.xml
165 @@ -0,0 +1,16 @@
166 +<?xml version="1.0" encoding="UTF-8"?>
167 +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
168 +<pkgmetadata>
169 + <maintainer type="person">
170 + <email>gentoo@××××××××.de</email>
171 + <name>Ronny (tastytea) Gutbrod</name>
172 + </maintainer>
173 + <upstream>
174 + <maintainer>
175 + <name>tastytea</name>
176 + <email>tastytea@××××××××.de</email>
177 + </maintainer>
178 + <doc>https://doc.schlomp.space/mastodonpp/</doc>
179 + <bugs-to>https://schlomp.space/tastytea/mastodonpp/issues</bugs-to>
180 + </upstream>
181 +</pkgmetadata>