Gentoo Archives: gentoo-commits

From: Craig Andrews <candrews@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-misc/lirc/
Date: Fri, 06 Apr 2018 18:46:25
Message-Id: 1523040307.856720e8b9d8584e294d58737caaf6ecb2905928.candrews@gentoo
1 commit: 856720e8b9d8584e294d58737caaf6ecb2905928
2 Author: Craig Andrews <candrews <AT> gentoo <DOT> org>
3 AuthorDate: Fri Apr 6 18:45:07 2018 +0000
4 Commit: Craig Andrews <candrews <AT> gentoo <DOT> org>
5 CommitDate: Fri Apr 6 18:45:07 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=856720e8
7
8 app-misc/lirc: 0.10.0 version bump
9
10 Package-Manager: Portage-2.3.28, Repoman-2.3.9
11
12 app-misc/lirc/Manifest | 1 +
13 app-misc/lirc/lirc-0.10.0.ebuild | 151 +++++++++++++++++++++++++++++++++++++++
14 2 files changed, 152 insertions(+)
15
16 diff --git a/app-misc/lirc/Manifest b/app-misc/lirc/Manifest
17 index 56886326f30..640fb7f681a 100644
18 --- a/app-misc/lirc/Manifest
19 +++ b/app-misc/lirc/Manifest
20 @@ -1,4 +1,5 @@
21 DIST lirc-0.10.0-rc2.tar.bz2 2552982 BLAKE2B d68639198dd7041865f6b7ac79cb94b63d8a85ee70f97628e27887d14f62814388a51521dabe91730570c382c6bb7edb36c15eba0f8ea9f5d4490dfce2bd121a SHA512 ab3426477f017e3a1b9da690189beae5086bbb52f88d302e6c91d7633f74ef781e6747f6b697b3ed6df13497a3e666f11c846104d2f00b975746d24bfd2a6cd5
22 +DIST lirc-0.10.0.tar.bz2 2523528 BLAKE2B 5c133b40936060fbaa0a9463b1b07d9197d935388e3eb4e46791b1f844b82ea6b6d42ae0c6ce249ca306688fa5d15718f5a3a54b497fc9f168b8b736b06bdd1e SHA512 06ccc1c8c80bfd17a6d180ae39a17779cbba341086f90a03a2e552bfb71e3abcb13f991312fba0e57df79c1882c1e29a2f273dddcd46a9ff53160b556e1547ab
23 DIST lirc-0.9.0.tar.bz2 857286 BLAKE2B 034c7b8492dd42301bb6d40da8c6c95f714b925ee50e7396290231684024dc3fe3bb64987db92d2a4e4d56203436007e68222bbf9a775bb9d29bbefcc4a7c1e4 SHA512 e91534c63e6065bd7da3b15e1676edf1672b8beb21864a6825df86247d7d165bf2dee6f8191732933e24e42a406e46afc55559948e4061eed2de7b08fac13431
24 DIST lirc-0.9.4a.tar.bz2 2292119 BLAKE2B 6ca7562716fde3327aa3f8f9913da7d349969f1bcac095bf2e9b1e3025d1e39176e2fb386ca08bcf80d458262f9eb96dab363ef3aa2c1d56b914ac8a36fcbacf SHA512 16be0ac5dd9b07d717ceba63cdc38c0db4a2bdcfc373ca6346d7cd4ab2cd2973aa7585d10b045fcaea952a3aabf7617c564ccb8268db6c62b172683a4b2cc188
25 DIST lirc-0.9.4c.tar.bz2 2311300 BLAKE2B f58f3b3a701e0ae787e34ec65c1d29b0faa75958b95aa43663a78dbe04c1c1d5456df5a6c5e41c673db9f589a7c2d41423b5f6a667fac890fb18f29fd797438b SHA512 0a0d0e025b87a55ec919c92824d8288bfaf35cfebae0ee97d86e344109f584baa72a2eff6d24fbc526900671d6092e0eebef8d1566559b0d153e122e3127c0cb
26
27 diff --git a/app-misc/lirc/lirc-0.10.0.ebuild b/app-misc/lirc/lirc-0.10.0.ebuild
28 new file mode 100644
29 index 00000000000..8ddbc22037b
30 --- /dev/null
31 +++ b/app-misc/lirc/lirc-0.10.0.ebuild
32 @@ -0,0 +1,151 @@
33 +# Copyright 1999-2018 Gentoo Foundation
34 +# Distributed under the terms of the GNU General Public License v2
35 +
36 +EAPI=6
37 +
38 +PYTHON_COMPAT=( python3_4 python3_5 )
39 +
40 +inherit eutils flag-o-matic linux-info python-single-r1 systemd xdg-utils
41 +
42 +DESCRIPTION="decode and send infra-red signals of many commonly used remote controls"
43 +HOMEPAGE="http://www.lirc.org/"
44 +
45 +LIRC_DRIVER_DEVICE="/dev/lirc0"
46 +
47 +MY_P=${PN}-${PV/_/-}
48 +
49 +if [[ "${PV/_pre/}" = "${PV}" ]]; then
50 + SRC_URI="mirror://sourceforge/lirc/${MY_P}.tar.bz2"
51 +else
52 + SRC_URI="http://www.lirc.org/software/snapshots/${MY_P}.tar.bz2"
53 +fi
54 +
55 +LICENSE="GPL-2+"
56 +SLOT="0"
57 +KEYWORDS="~amd64 ~arm64 ~ppc ~ppc64 ~x86"
58 +IUSE="audio +devinput doc ftdi gtk inputlirc static-libs systemd +uinput usb X"
59 +
60 +REQUIRED_USE="
61 + ${PYTHON_REQUIRED_USE}
62 + gtk? ( X )
63 +"
64 +
65 +S="${WORKDIR}/${MY_P}"
66 +
67 +COMMON_DEPEND="
68 + ${PYTHON_DEPS}
69 + audio? (
70 + >media-libs/portaudio-18
71 + media-libs/alsa-lib
72 + )
73 + dev-python/pyyaml[${PYTHON_USEDEP}]
74 + ftdi? ( dev-embedded/libftdi:0 )
75 + systemd? ( sys-apps/systemd )
76 + usb? ( virtual/libusb:0 )
77 + X? (
78 + x11-libs/libICE
79 + x11-libs/libSM
80 + x11-libs/libX11
81 + )
82 +"
83 +
84 +DEPEND="
85 + ${COMMON_DEPEND}
86 + dev-libs/libxslt
87 + doc? ( app-doc/doxygen )
88 + sys-apps/kmod
89 + sys-kernel/linux-headers
90 +"
91 +
92 +RDEPEND="
93 + ${COMMON_DEPEND}
94 + gtk? (
95 + x11-libs/vte[introspection]
96 + dev-python/pygobject[${PYTHON_USEDEP}]
97 + )
98 + inputlirc? ( app-misc/inputlircd )
99 +"
100 +
101 +pkg_setup() {
102 + use uinput && CONFIG_CHECK="INPUT_UINPUT"
103 +}
104 +
105 +src_configure() {
106 + xdg_environment_reset
107 + econf \
108 + --localstatedir="${EPREFIX}/var" \
109 + $(use_enable static-libs static) \
110 + $(use_enable devinput) \
111 + $(use_enable uinput) \
112 + $(use_with X x)
113 +}
114 +
115 +src_install() {
116 + default
117 +
118 + if use !gtk ; then
119 + # lirc-setup requires gtk
120 + rm "${ED%/}"/usr/bin/lirc-setup || die
121 + fi
122 +
123 + newinitd "${FILESDIR}"/lircd-0.8.6-r2 lircd
124 + newinitd "${FILESDIR}"/lircmd-0.9.4a-r2 lircmd
125 + newconfd "${FILESDIR}"/lircd.conf.4 lircd
126 + newconfd "${FILESDIR}"/lircmd-0.10.0.conf lircmd
127 +
128 + insinto /etc/modprobe.d/
129 + newins "${FILESDIR}"/modprobed.lirc lirc.conf
130 +
131 + newinitd "${FILESDIR}"/irexec-initd-0.9.4a-r2 irexec
132 + newconfd "${FILESDIR}"/irexec-confd irexec
133 +
134 + keepdir /etc/lirc
135 + if [[ -e "${ED%/}"/etc/lirc/lircd.conf ]]; then
136 + newdoc "${ED%/}"/etc/lirc/lircd.conf lircd.conf.example
137 + fi
138 +
139 + find "${ED}" -name '*.la' -delete || die
140 +
141 + # Avoid QA notice
142 + rm -d "${ED%/}"/var/run/lirc || die
143 + rm -d "${ED%/}"/var/run || die
144 +}
145 +
146 +pkg_preinst() {
147 + local dir="${EROOT%/}/etc/modprobe.d"
148 + if [[ -a "${dir}"/lirc && ! -a "${dir}"/lirc.conf ]]; then
149 + elog "Renaming ${dir}/lirc to lirc.conf"
150 + mv -f "${dir}/lirc" "${dir}/lirc.conf" || die
151 + fi
152 +
153 + # copy the first file that can be found
154 + if [[ -f "${EROOT%/}"/etc/lirc/lircd.conf ]]; then
155 + cp "${EROOT%/}"/etc/lirc/lircd.conf "${T}"/lircd.conf || die
156 + elif [[ -f "${EROOT%/}"/etc/lircd.conf ]]; then
157 + cp "${EROOT%/}"/etc/lircd.conf "${T}"/lircd.conf || die
158 + MOVE_OLD_LIRCD_CONF=1
159 + elif [[ -f "${ED%/}"/etc/lirc/lircd.conf ]]; then
160 + cp "${ED%/}"/etc/lirc/lircd.conf "${T}"/lircd.conf || die
161 + fi
162 +
163 + # stop portage from touching the config file
164 + if [[ -e "${ED%/}"/etc/lirc/lircd.conf ]]; then
165 + rm -f "${ED%/}"/etc/lirc/lircd.conf || die
166 + fi
167 +}
168 +
169 +pkg_postinst() {
170 + # copy config file to new location
171 + # without portage knowing about it
172 + # so it will not delete it on unmerge or ever touch it again
173 + if [[ -e "${T}"/lircd.conf ]]; then
174 + cp "${T}"/lircd.conf "${EROOT%/}"/etc/lirc/lircd.conf || die
175 + if [[ "$MOVE_OLD_LIRCD_CONF" = "1" ]]; then
176 + elog "Moved /etc/lircd.conf to /etc/lirc/lircd.conf"
177 + rm -f "${EROOT%/}"/etc/lircd.conf || die
178 + fi
179 + fi
180 +
181 + einfo "The new default location for lircd.conf is inside of"
182 + einfo "${EROOT%/}/etc/lirc/ directory"
183 +}