Gentoo Archives: gentoo-dev

From: Joerg Bornkessel <hd_brummy@g.o>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] [PATCH] vdr-plugin-2.eclass: add EAPI 7 support
Date: Fri, 13 Jul 2018 22:24:09
Message-Id: 21ff46fb-5abf-6301-369b-9b23982174f0@astrali.lan
1 Please review,
2
3 changes makes the vdr-plugin-2.eclass to be able handle EAPI 7 support.
4 Its just 1 line for this,
5 The rest is clean up, or better i should say, i removed the internal
6 vdr_dev_check function and replaced it by the eqawarn function.
7 I know, in the eclass is still EAPI 4,5 support, but we have a lot of
8 ebuilds, untached thins years, they use the EAPI 4,5.
9 This needs fixed at first in the tree, than we can safely remove the
10 EAPI 4,5 support.
11
12 Thanks
13
14
15 --- vdr-plugin-2.eclass.old 2018-07-13 14:16:24.134895457 +0200
16 +++ vdr-plugin-2.eclass 2018-07-13 23:56:14.924419576 +0200
17 @@ -53,19 +53,6 @@
18 # PO_SUBDIR="bla foo/bla"
19 # @CODE
20
21 -# @ECLASS-VARIABLE: VDR_MAINTAINER_MODE
22 -# @DEFAULT_UNSET
23 -# @DESCRIPTION:
24 -# Output from function vdr_dev_check if it is defined in ebuild or eclass,
25 -# helpfull for gentoo ebuild developer
26 -#
27 -# This will also install any debug files in /usr/share/vdr/maintainer-data
28 -#
29 -# This is intended to be set by user in make.conf. Ebuilds must not set
30 -# it.
31 -#
32 -# VDR_MAINTAINER_MODE=1
33 -
34 # @FUNCTION: fix_vdr_libsi_include
35 # @DESCRIPTION:
36 # Plugins failed on compile with wrong path of libsi includes,
37 @@ -91,7 +78,7 @@
38 # Applying your own local/user patches:
39 # This is done by using the
40 # (EAPI = 4,5) epatch_user() function of the eutils.eclass,
41 -# (EAPI = 6) eapply_user function integrated in EAPI = 6.
42 +# (EAPI = 6,7) eapply_user function integrated in EAPI = 6.
43 # Simply add your patches into one of these directories:
44 # /etc/portage/patches/<CATEGORY>/<PF|P|PN>/
45 # Quote: where the first of these three directories to exist will be
46 the one to
47 @@ -103,7 +90,7 @@
48 inherit flag-o-matic toolchain-funcs unpacker
49
50 case ${EAPI:-0} in
51 - 4|5|6)
52 + 4|5|6|7)
53 ;;
54 *) die "EAPI ${EAPI} unsupported."
55 ;;
56 @@ -187,7 +174,7 @@
57 }
58
59 fix_vdr_libsi_include() {
60 - vdr_dev_check "Fixing include of libsi-headers"
61 + eqawarn "Fixing include of libsi-headers"
62 local f
63 for f; do
64 sed -i "${f}" \
65 @@ -270,7 +257,7 @@
66
67 local GETTEXT_MISSING=$( grep xgettext Makefile )
68 if [[ -z ${GETTEXT_MISSING} ]]; then
69 - vdr_dev_check "Plugin isn't converted to gettext handling \n"
70 + eqawarn "Plugin isn't converted to gettext handling!"
71 fi
72 }
73
74 @@ -319,26 +306,26 @@
75 if [[ -n ${I18N_OBJECT} ]]; then
76
77 if [[ "${KEEP_I18NOBJECT:-no}" = "yes" ]]; then
78 - vdr_dev_check "Forced to keep i18n.o"
79 + eqawarn "Forced to keep i18n.o"
80 else
81 sed -i "s:i18n.o::g" Makefile
82 - vdr_dev_check "OBJECT i18n.o found"
83 - vdr_dev_check "removed per sed \n"
84 + eqawarn "OBJECT i18n.o found"
85 + eqawarn "removed per sed"
86 fi
87
88 else
89 - vdr_dev_check "OBJECT i18n.o not found in Makefile"
90 - vdr_dev_check "all fine or manual review needed? \n"
91 + eqawarn "OBJECT i18n.o not found in MAKEFILE"
92 + eqawarn "all fine or manual review needed?"
93 fi
94
95 local I18N_STRING=$( [[ -e i18n.h ]] && grep tI18nPhrase i18n.h )
96 if [[ -n ${I18N_STRING} ]]; then
97 sed -i
98 "s:^extern[[:space:]]*const[[:space:]]*tI18nPhrase://static const
99 tI18nPhrase:" i18n.h
100 - vdr_dev_check "obsolete tI18nPhrase found"
101 - vdr_dev_check "disabled per sed, please recheck \n"
102 + eqawarn "obsolete tI18nPhrase found"
103 + eqawarn "disabled per sed, please recheck \n"
104 else
105 - vdr_dev_check "obsolete tI18nPhrase not found, fine..."
106 - vdr_dev_check "please review, may be in subdir... \n"
107 + eqawarn "obsolete tI18nPhrase not found, fine..."
108 + eqawarn "please review, may be in subdir..."
109 fi
110 }
111
112 @@ -351,7 +338,7 @@
113 -e "s:^#include[[:space:]]*\"i18n.h\"://:"
114 done
115
116 - vdr_dev_check "removed i18n.h include in ${@}"
117 + eqawarn "removed i18n.h include in ${@}"
118 }
119
120 vdr-plugin-2_print_enable_command() {
121 @@ -572,7 +559,7 @@
122 DESTDIR="${D}" \
123 || die "emake install (makefile target) failed"
124 else
125 - vdr_dev_check "Plugin use still the old Makefile handling"
126 + eqawarn "Plugin use still the old Makefile handling"
127 insinto "${VDR_PLUGIN_DIR}"
128 doins libvdr-*.so.*
129 fi
130
131
132 --
133 Joerg Bornkessel <hd_brummy@g.o>
134 GnuPG Key: 0x93EB5F4DAA5832A1
135 Fingerprint: 0E0A A1EE 1DF4 41D7 A3F5 21C2 93EB 5F4D AA58 32A1

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies