Сравнение psi-1.5-r1 с psi-9999

/usr/portage/net-im/psi/psi-9999.ebuild 2023-10-09 14:52:34.448368475 +0300
1
# Copyright 1999-2022 Gentoo Authors
1
# Copyright 1999-2023 Gentoo Authors
2 2
# Distributed under the terms of the GNU General Public License v2
3 3

  
4 4
EAPI=7
5 5

  
6
PLOCALES="be bg ca cs de en eo es et fa fi fr he hu it ja kk mk nl pl pt pt_BR ru sk sl sr@latin sv sw uk ur_PK vi zh_CN zh_TW"
6
PLOCALES="be bg ca cs de el en eo es et fa fi fr he hu it ja kk mk nl pl pt_BR pt ru sk sl sr@latin sv sw uk ur_PK vi zh_CN zh_TW"
7 7
PLOCALE_BACKUP="en"
8 8

  
9
inherit plocale qmake-utils xdg
9
inherit git-r3 cmake plocale qmake-utils xdg
10 10

  
11 11
DESCRIPTION="Qt XMPP client"
12 12
HOMEPAGE="https://psi-im.org"
13
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.xz
14
	https://github.com/psi-im/psi-l10n/archive/${PV}.tar.gz -> psi-l10n-${PV}.tar.gz"
15 13

  
16
LICENSE="GPL-2"
14
PSI_URI="https://github.com/psi-im"
15
PSI_PLUS_URI="https://github.com/psi-plus"
16
EGIT_REPO_URI="${PSI_URI}/${PN}.git"
17
PSI_LANGS_URI="${PSI_URI}/psi-l10n.git"
18
PSI_PLUS_LANGS_URI="${PSI_PLUS_URI}/psi-plus-l10n.git"
19
EGIT_MIN_CLONE_TYPE="single"
20
LICENSE="GPL-2 iconsets? ( all-rights-reserved )"
17 21
SLOT="0"
18
KEYWORDS="amd64 x86"
19
IUSE="aspell crypt dbus debug doc enchant +hunspell webengine whiteboarding xscreensaver"
22
KEYWORDS=""
23
IUSE="aspell crypt dbus debug doc enchant extras +hunspell iconsets keyring webengine xscreensaver"
20 24

  
21 25
REQUIRED_USE="
22 26
	?? ( aspell enchant hunspell )
27
	iconsets? ( extras )
23 28
"
24 29

  
25 30
BDEPEND="
26 31
	dev-qt/linguist-tools:5
27 32
	virtual/pkgconfig
28 33
	doc? ( app-doc/doxygen[dot] )
34
	extras? ( >=sys-devel/qconf-2.4 )
29 35
"
30 36
DEPEND="
31 37
	app-crypt/qca:2[ssl]
......
34 40
	dev-qt/qtgui:5
35 41
	dev-qt/qtmultimedia:5
36 42
	dev-qt/qtnetwork:5
43
	dev-qt/qtsql:5[sqlite]
44
	dev-qt/qtsvg:5
37 45
	dev-qt/qtwidgets:5
38 46
	dev-qt/qtx11extras:5
39 47
	dev-qt/qtxml:5
40 48
	net-dns/libidn:0
49
	net-libs/http-parser:=
50
	net-libs/usrsctp
41 51
	sys-libs/zlib[minizip]
42 52
	x11-libs/libX11
43 53
	x11-libs/libxcb
......
45 55
	dbus? ( dev-qt/qtdbus:5 )
46 56
	enchant? ( app-text/enchant:2 )
47 57
	hunspell? ( app-text/hunspell:= )
58
	keyring? ( dev-libs/qtkeychain:=[qt5(+)] )
48 59
	webengine? (
49 60
		dev-qt/qtwebchannel:5
50 61
		dev-qt/qtwebengine:5[widgets]
62
		net-libs/http-parser
51 63
	)
52
	whiteboarding? ( dev-qt/qtsvg:5 )
53
	xscreensaver? ( x11-libs/libXScrnSaver )
54 64
"
55 65
RDEPEND="${DEPEND}
56 66
	dev-qt/qtimageformats
67
	crypt? ( app-crypt/qca[gpg] )
57 68
"
58 69

  
59
RESTRICT="test"
70
RESTRICT="test iconsets? ( bindist )"
60 71

  
61
src_configure() {
62
	CONF=(
63
		--prefix="${EPREFIX}"/usr
64
		--libdir="${EPREFIX}"/usr/$(get_libdir)
65
		--no-separate-debug-info
66
		--qtdir="$(qt5_get_bindir)/.."
67
		$(use_enable aspell)
68
		$(use_enable dbus qdbus)
69
		$(use_enable enchant)
70
		$(use_enable hunspell)
71
		$(use_enable xscreensaver xss)
72
		$(use_enable whiteboarding)
73
		$(use_enable webengine webkit)
74
		$(use_with webengine webkit qtwebengine)
75
	)
72
pkg_setup() {
73
	MY_PN=psi
74
	if use extras; then
75
		MY_PN=psi-plus
76
		ewarn "You're about to build patched version of Psi called Psi+."
77
		ewarn "It has new nice features not yet included to Psi."
78
		ewarn "Take a look at homepage for more info: http://psi-plus.com/"
79

  
80
		if use iconsets; then
81
			ewarn
82
			ewarn "Some artwork is from open source projects, but some is provided 'as-is'"
83
			ewarn "and has not clear licensing."
84
			ewarn "Possibly this build is not redistributable in some countries."
85
		fi
76 86

  
77
	use debug && CONF+=("--debug")
87
		EGIT_REPO_URI="${PSI_PLUS_URI}/${MY_PN}-snapshots.git"
88
	fi
89
}
78 90

  
79
	# This may generate warnings if passed option already matches with default.
80
	# Just ignore them. It's how qconf-based configure works and will be fixed in
81
	# future qconf versions.
82
	./configure "${CONF[@]}" || die "configure failed"
91
src_unpack() {
92
	git-r3_src_unpack
93

  
94
	# fetch translations
95
	unset EGIT_BRANCH EGIT_COMMIT
96
	EGIT_REPO_URI=$(usex extras "${PSI_PLUS_LANGS_URI}" "${PSI_LANGS_URI}")
97
	EGIT_CHECKOUT_DIR="${WORKDIR}/psi-l10n"
98
	git-r3_src_unpack
99

  
100
	if use iconsets; then
101
		unset EGIT_BRANCH EGIT_COMMIT
102
		EGIT_CHECKOUT_DIR="${WORKDIR}/resources" \
103
		EGIT_REPO_URI="${PSI_URI}/resources.git" \
104
		git-r3_src_unpack
105
	fi
106
}
83 107

  
84
	eqmake5 psi.pro
108
src_prepare() {
109
	cmake_src_prepare
110
	if use iconsets; then
111
		cp -a "${WORKDIR}/resources/iconsets" "${S}" || die "failed to copy additional iconsets"
112
	fi
113
}
114

  
115
src_configure() {
116
	local mycmakeargs=(
117
		-DPRODUCTION=OFF
118
		-DUSE_ASPELL=$(usex aspell)
119
		-DUSE_ENCHANT=$(usex enchant)
120
		-DUSE_HUNSPELL=$(usex hunspell)
121
		-DUSE_DBUS=$(usex dbus)
122
		-DINSTALL_PLUGINS_SDK=1
123
		-DUSE_KEYCHAIN=$(usex keyring)
124
		-DCHAT_TYPE=$(usex webengine webengine basic)
125
		-DUSE_XSS=$(usex xscreensaver)
126
		-DPSI_PLUS=$(usex extras)
127
	)
128
	cmake_src_configure
85 129
}
86 130

  
87 131
src_compile() {
88
	emake
132
	cmake_src_compile
89 133
	use doc && emake -C doc api_public
90 134
}
91 135

  
92 136
src_install() {
93
	emake INSTALL_ROOT="${D}" install
137
	cmake_src_install
94 138

  
95 139
	# this way the docs will be installed in the standard gentoo dir
96
	rm "${ED}"/usr/share/psi/{COPYING,README} || die "Installed file set seems to be changed by upstream"
140
	rm "${ED}"/usr/share/${MY_PN}/{COPYING,README.html} || die "doc files set seems to have changed"
97 141
	newdoc iconsets/roster/README README.roster
98 142
	newdoc iconsets/system/README README.system
99 143
	newdoc certs/README README.certs
100
	dodoc README
144
	dodoc README.html
101 145

  
102 146
	use doc && HTML_DOCS=( doc/api/. )
103 147
	einstalldocs
104 148

  
105 149
	# install translations
106 150
	local mylrelease="$(qt5_get_bindir)"/lrelease
107
	cd "${WORKDIR}/psi-l10n-${PV}" || die
108
	insinto /usr/share/psi
151
	cd "${WORKDIR}/psi-l10n" || die
152
	insinto /usr/share/${MY_PN}
109 153
	install_locale() {
110 154
		"${mylrelease}" "translations/${PN}_${1}.ts" || die "lrelease ${1} failed"
111 155
		doins "translations/${PN}_${1}.qm"
Спасибо!