alfis-0.8.5.ebuild 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289
  1. # Copyright 2017-2024 Gentoo Authors
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=8
  4. CRATES="
  5. adler@1.0.2
  6. aead@0.5.2
  7. aes@0.8.4
  8. aes-gcm@0.10.3
  9. ahash@0.8.11
  10. allocator-api2@0.2.18
  11. android-tzdata@0.1.1
  12. android_system_properties@0.1.5
  13. atk-sys@0.10.0
  14. autocfg@1.3.0
  15. base64@0.22.1
  16. base64ct@1.6.0
  17. bincode@1.3.3
  18. bitflags@1.3.2
  19. bitflags@2.6.0
  20. blake2@0.9.2
  21. blakeout@0.3.0
  22. block-buffer@0.10.4
  23. boxfnonce@0.1.1
  24. bumpalo@3.16.0
  25. byteorder@1.5.0
  26. cairo-sys-rs@0.10.0
  27. cc@1.1.0
  28. cfg-if@1.0.0
  29. chacha20@0.9.1
  30. chacha20poly1305@0.10.1
  31. chrono@0.4.38
  32. cipher@0.4.4
  33. const-oid@0.9.6
  34. convert_case@0.4.0
  35. core-foundation-sys@0.8.6
  36. cpufeatures@0.2.12
  37. crc32fast@1.4.2
  38. crypto-common@0.1.6
  39. crypto-mac@0.8.0
  40. ctr@0.9.2
  41. curve25519-dalek@4.1.3
  42. curve25519-dalek-derive@0.1.1
  43. der@0.7.9
  44. deranged@0.3.11
  45. derive_more@0.99.18
  46. digest@0.9.0
  47. digest@0.10.7
  48. ed25519@2.2.3
  49. ed25519-dalek@2.1.1
  50. equivalent@1.0.1
  51. fiat-crypto@0.2.9
  52. flate2@1.0.30
  53. form_urlencoded@1.2.1
  54. gdk-pixbuf-sys@0.10.0
  55. gdk-sys@0.10.0
  56. generic-array@0.14.7
  57. getopts@0.2.21
  58. getrandom@0.2.15
  59. ghash@0.5.1
  60. gio-sys@0.10.1
  61. glib-sys@0.10.1
  62. gobject-sys@0.10.0
  63. gtk-sys@0.10.0
  64. half@1.8.3
  65. hashbrown@0.14.5
  66. heck@0.3.3
  67. hermit-abi@0.3.9
  68. hex@0.4.3
  69. hkdf@0.12.4
  70. hmac@0.12.1
  71. iana-time-zone@0.1.60
  72. iana-time-zone-haiku@0.1.2
  73. idna@0.5.0
  74. indexmap@2.2.6
  75. inout@0.1.3
  76. is-docker@0.2.0
  77. is-wsl@0.4.0
  78. itoa@1.0.11
  79. javascriptcore-rs-sys@0.2.0
  80. js-sys@0.3.69
  81. lazy_static@1.5.0
  82. libc@0.2.155
  83. log@0.4.22
  84. lru@0.12.3
  85. memchr@2.7.4
  86. miniz_oxide@0.7.4
  87. mio@1.0.0
  88. num-bigint@0.4.6
  89. num-conv@0.1.0
  90. num-integer@0.1.46
  91. num-traits@0.2.19
  92. num_cpus@1.16.0
  93. num_threads@0.1.7
  94. once_cell@1.19.0
  95. opaque-debug@0.3.1
  96. open@5.2.0
  97. pango-sys@0.10.0
  98. pathdiff@0.2.1
  99. percent-encoding@2.3.1
  100. pkcs8@0.10.2
  101. pkg-config@0.3.30
  102. poly1305@0.8.0
  103. polyval@0.6.2
  104. powerfmt@0.2.0
  105. ppv-lite86@0.2.17
  106. proc-macro2@1.0.86
  107. quote@1.0.36
  108. rand@0.8.5
  109. rand_chacha@0.3.1
  110. rand_core@0.6.4
  111. ring@0.17.8
  112. rustc_version@0.4.0
  113. rustls@0.23.11
  114. rustls-pki-types@1.7.0
  115. rustls-webpki@0.102.5
  116. rustversion@1.0.17
  117. ryu@1.0.18
  118. semver@1.0.23
  119. serde@1.0.204
  120. serde_bytes@0.11.15
  121. serde_cbor@0.11.2
  122. serde_derive@1.0.204
  123. serde_json@1.0.120
  124. serde_spanned@0.6.6
  125. sha2@0.10.8
  126. signature@2.2.0
  127. simplelog@0.12.2
  128. soup-sys@0.10.0
  129. spin@0.9.8
  130. spki@0.7.3
  131. spmc@0.3.0
  132. sqlite@0.36.0
  133. sqlite3-src@0.6.1
  134. sqlite3-sys@0.17.0
  135. strum@0.18.0
  136. strum_macros@0.18.0
  137. subtle@2.6.1
  138. syn@1.0.109
  139. syn@2.0.70
  140. system-deps@1.3.2
  141. termcolor@1.4.1
  142. thiserror@1.0.61
  143. thiserror-impl@1.0.61
  144. thread-priority@1.1.0
  145. time@0.3.36
  146. time-core@0.1.2
  147. time-macros@0.2.18
  148. tinyfiledialogs@3.9.1
  149. tinyvec@1.8.0
  150. tinyvec_macros@0.1.1
  151. toml@0.5.11
  152. toml@0.8.14
  153. toml_datetime@0.6.6
  154. toml_edit@0.22.15
  155. typenum@1.17.0
  156. unicode-bidi@0.3.15
  157. unicode-ident@1.0.12
  158. unicode-normalization@0.1.23
  159. unicode-segmentation@1.11.0
  160. unicode-width@0.1.13
  161. universal-hash@0.5.1
  162. untrusted@0.9.0
  163. ureq@2.10.0
  164. url@2.5.2
  165. urlencoding@1.3.3
  166. uuid@1.10.0
  167. version-compare@0.0.10
  168. version_check@0.9.4
  169. wasi@0.11.0+wasi-snapshot-preview1
  170. wasm-bindgen@0.2.92
  171. wasm-bindgen-backend@0.2.92
  172. wasm-bindgen-macro@0.2.92
  173. wasm-bindgen-macro-support@0.2.92
  174. wasm-bindgen-shared@0.2.92
  175. web-view@0.7.3
  176. webkit2gtk-sys@0.12.0
  177. webpki-roots@0.26.3
  178. webview-sys@0.6.2
  179. widestring@1.1.0
  180. winapi@0.3.9
  181. winapi-i686-pc-windows-gnu@0.4.0
  182. winapi-util@0.1.8
  183. winapi-x86_64-pc-windows-gnu@0.4.0
  184. windows-core@0.52.0
  185. windows-service@0.7.0
  186. windows-sys@0.52.0
  187. windows-targets@0.52.6
  188. windows_aarch64_gnullvm@0.52.6
  189. windows_aarch64_msvc@0.52.6
  190. windows_i686_gnu@0.52.6
  191. windows_i686_gnullvm@0.52.6
  192. windows_i686_msvc@0.52.6
  193. windows_x86_64_gnu@0.52.6
  194. windows_x86_64_gnullvm@0.52.6
  195. windows_x86_64_msvc@0.52.6
  196. winnow@0.6.13
  197. winres@0.1.12
  198. x25519-dalek@2.0.1
  199. zerocopy@0.7.35
  200. zerocopy-derive@0.7.35
  201. zeroize@1.8.1
  202. zeroize_derive@1.4.2
  203. "
  204. declare -A GIT_CRATES=(
  205. ['ecies-ed25519-ng']="https://github.com/Revertron/ecies-ed25519-ng;554ca29a1bbd55f0c7e2f75cb3c7e0e3030afc15"
  206. # from Cargo.lock
  207. ['ureq']="https://github.com/algesten/ureq;1cad58f5a4f359e318858810de51666d63de70e8"
  208. ['web-view']="https://github.com/Boscop/web-view;82d7cbce6228b1a964673cc0f22944ad808eab42"
  209. )
  210. inherit cargo desktop fcaps systemd tmpfiles
  211. MY_PN="${PN^}"
  212. DESCRIPTION="Alternative Free Identity System"
  213. HOMEPAGE="https://github.com/Revertron/Alfis"
  214. SRC_URI="
  215. https://github.com/Revertron/${MY_PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz
  216. ${CARGO_CRATE_URIS}
  217. "
  218. S="${WORKDIR}/${MY_PN}-${PV}"
  219. LICENSE="AGPL-3"
  220. # Dependent crate licenses
  221. LICENSE+="
  222. Apache-2.0 BSD GPL-3 MIT ISC ZLIB Unicode-DFS-2016 MPL-2.0
  223. "
  224. SLOT="0"
  225. KEYWORDS="amd64 ~arm64 ~x86"
  226. IUSE="X"
  227. RESTRICT="mirror"
  228. DEPEND="
  229. dev-db/sqlite:3
  230. X? (
  231. dev-libs/glib:2
  232. x11-libs/gtk+:3
  233. net-libs/webkit-gtk:4
  234. )
  235. "
  236. RDEPEND="
  237. ${DEPEND}
  238. acct-user/${PN}
  239. acct-group/${PN}
  240. "
  241. FILECAPS=(
  242. cap_net_bind_service+ep "usr/bin/${PN}"
  243. )
  244. src_configure() {
  245. local myfeatures=($(usex X webgui ''))
  246. cargo_src_configure --no-default-features
  247. }
  248. src_install() {
  249. cargo_src_install
  250. insinto /etc
  251. doins "${PN}.toml"
  252. newtmpfiles "contrib/systemd/${PN}.tmpfiles" "${PN}.conf"
  253. systemd_dounit "contrib/systemd/${PN}"{,-default-config}.service
  254. use X && {
  255. domenu contrib/
  256. local icon='' size=''
  257. for icon in img/logo/*.png; do
  258. size="${icon##*/${PN}_icon}"
  259. newicon -s "${size%%.*}" "${icon}" "${PN}.png"
  260. done
  261. doicon -s scalable "img/logo/${PN}_icon.svg"
  262. }
  263. }
  264. pkg_postinst() {
  265. fcaps_pkg_postinst
  266. tmpfiles_process "${PN}.conf"
  267. }