1 |
EAPI 7 specifies that nonfatal has to be implemented both as a bash |
2 |
function and a fallback executable, so that it can be used e.g. via |
3 |
find/xargs. |
4 |
|
5 |
Bug: https://bugs.gentoo.org/622894 |
6 |
--- |
7 |
bin/ebuild-helpers/nonfatal | 14 ++++++++++++++ |
8 |
1 file changed, 14 insertions(+) |
9 |
create mode 100755 bin/ebuild-helpers/nonfatal |
10 |
|
11 |
diff --git a/bin/ebuild-helpers/nonfatal b/bin/ebuild-helpers/nonfatal |
12 |
new file mode 100755 |
13 |
index 000000000..5da07cc71 |
14 |
--- /dev/null |
15 |
+++ b/bin/ebuild-helpers/nonfatal |
16 |
@@ -0,0 +1,14 @@ |
17 |
+#!/bin/bash |
18 |
+# Copyright 1999-2018 Gentoo Foundation |
19 |
+# Distributed under the terms of the GNU General Public License v2 |
20 |
+ |
21 |
+source "${PORTAGE_BIN_PATH}"/isolated-functions.sh || exit 1 |
22 |
+ |
23 |
+if ! ___eapi_has_nonfatal; then |
24 |
+ die "${0##*/} not supported in this EAPI" |
25 |
+fi |
26 |
+if [[ $# -lt 1 ]]; then |
27 |
+ die "${0##*/}: Missing argument" |
28 |
+fi |
29 |
+ |
30 |
+PORTAGE_NONFATAL=1 exec "$@" |
31 |
-- |
32 |
2.16.2 |