| 1 | # Copyright 1999-2012 Gentoo Foundation |
1 | # Copyright 1999-2012 Gentoo Foundation |
| 2 | # Distributed under the terms of the GNU General Public License v2 |
2 | # Distributed under the terms of the GNU General Public License v2 |
| 3 | # $Header: /var/cvsroot/gentoo-x86/eclass/vdr-plugin-2.eclass,v 1.5 2012/05/25 19:56:13 hd_brummy Exp $ |
3 | # $Header: /var/cvsroot/gentoo-x86/eclass/vdr-plugin-2.eclass,v 1.6 2012/06/10 14:21:20 hd_brummy Exp $ |
| 4 | |
4 | |
| 5 | # @ECLASS: vdr-plugin-2.eclass |
5 | # @ECLASS: vdr-plugin-2.eclass |
| 6 | # @MAINTAINER: |
6 | # @MAINTAINER: |
| 7 | # vdr@gentoo.org |
7 | # vdr@gentoo.org |
| 8 | # @BLURB: common vdr plugin ebuild functions |
8 | # @BLURB: common vdr plugin ebuild functions |
| … | |
… | |
| 41 | # Quote: where the first of these three directories to exist will be the one to |
41 | # Quote: where the first of these three directories to exist will be the one to |
| 42 | # use, ignoring any more general directories which might exist as well. |
42 | # use, ignoring any more general directories which might exist as well. |
| 43 | # |
43 | # |
| 44 | # For more details about it please take a look at the eutils.class. |
44 | # For more details about it please take a look at the eutils.class. |
| 45 | |
45 | |
| 46 | inherit base multilib eutils flag-o-matic |
46 | inherit base eutils flag-o-matic multilib toolchain-funcs |
| 47 | |
47 | |
| 48 | if ! has "${EAPI:-4}" 4; then |
48 | if ! has "${EAPI:-4}" 4; then |
| 49 | die "API of vdr-plugin-2.eclass in EAPI=\"${EAPI}\" not established" |
49 | die "API of vdr-plugin-2.eclass in EAPI=\"${EAPI}\" not established" |
| 50 | fi |
50 | fi |
| 51 | |
51 | |
| … | |
… | |
| 289 | |
289 | |
| 290 | gettext_missing |
290 | gettext_missing |
| 291 | |
291 | |
| 292 | local I18N_OBJECT=$( grep i18n.o Makefile ) |
292 | local I18N_OBJECT=$( grep i18n.o Makefile ) |
| 293 | if [[ -n ${I18N_OBJECT} ]]; then |
293 | if [[ -n ${I18N_OBJECT} ]]; then |
|
|
294 | |
|
|
295 | if [[ "${KEEP_I18NOBJECT:-no}" = "yes" ]]; then |
|
|
296 | dev_check "Forced to keep i18n.o" |
|
|
297 | else |
| 294 | sed -i "s:i18n.o::g" Makefile |
298 | sed -i "s:i18n.o::g" Makefile |
| 295 | dev_check "OBJECT i18n.o found" |
299 | dev_check "OBJECT i18n.o found" |
| 296 | dev_check "removed per sed \n" |
300 | dev_check "removed per sed \n" |
|
|
301 | fi |
|
|
302 | |
| 297 | else |
303 | else |
| 298 | dev_check "OBJECT i18n.o not found in Makefile" |
304 | dev_check "OBJECT i18n.o not found in Makefile" |
| 299 | dev_check "all fine or manual review needed? \n" |
305 | dev_check "all fine or manual review needed? \n" |
| 300 | fi |
306 | fi |
| 301 | |
307 | |
| … | |
… | |
| 362 | append-flags -fPIC |
368 | append-flags -fPIC |
| 363 | |
369 | |
| 364 | # Plugins need to be compiled with position independent code, otherwise linking |
370 | # Plugins need to be compiled with position independent code, otherwise linking |
| 365 | # VDR against it will fail |
371 | # VDR against it will fail |
| 366 | if has_version ">=media-video/vdr-1.7.13"; then |
372 | if has_version ">=media-video/vdr-1.7.13"; then |
| 367 | append-flags -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE |
373 | append-cppflags -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE |
| 368 | fi |
374 | fi |
|
|
375 | |
|
|
376 | # missing ${chost}- tag |
|
|
377 | tc-export CC CXX |
| 369 | |
378 | |
| 370 | # Where should the plugins live in the filesystem |
379 | # Where should the plugins live in the filesystem |
| 371 | VDR_PLUGIN_DIR="/usr/$(get_libdir)/vdr/plugins" |
380 | VDR_PLUGIN_DIR="/usr/$(get_libdir)/vdr/plugins" |
| 372 | VDR_CHECKSUM_DIR="${VDR_PLUGIN_DIR%/plugins}/checksums" |
381 | VDR_CHECKSUM_DIR="${VDR_PLUGIN_DIR%/plugins}/checksums" |
| 373 | |
382 | |