1 |
commit: 9f2b33191158b517d3aea3de953b4610d8add860 |
2 |
Author: Chema Alonso Josa <nimiux <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Oct 28 14:29:00 2017 +0000 |
4 |
Commit: José María Alonso <nimiux <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Oct 28 14:29:00 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/lisp.git/commit/?id=9f2b3319 |
7 |
|
8 |
glo-utils.eclass: Drop obsolete eclass |
9 |
|
10 |
eclass/glo-utils.eclass | 45 --------------------------------------------- |
11 |
1 file changed, 45 deletions(-) |
12 |
|
13 |
diff --git a/eclass/glo-utils.eclass b/eclass/glo-utils.eclass |
14 |
deleted file mode 100644 |
15 |
index dd7dab8f..00000000 |
16 |
--- a/eclass/glo-utils.eclass |
17 |
+++ /dev/null |
18 |
@@ -1,45 +0,0 @@ |
19 |
-# Copyright 1999-2010 Gentoo Foundation |
20 |
-# Distributed under the terms of the GNU General Public License v2 |
21 |
-# $Header: $ |
22 |
-# |
23 |
-# This eclass contains various utilities used in the Gentoo Lisp overlay |
24 |
-# |
25 |
-# Public functions: |
26 |
-# |
27 |
-# glo_usev flagname [<if_yes> [<if_no>]] |
28 |
-# If $(use FLAGNAME) return true, echo IF_YES to standard output, |
29 |
-# otherwise echo IF_NO. IF_YES defaults to FLAGNAME if not specified |
30 |
-# |
31 |
-# glo_best_flag flag+ |
32 |
-# Echo to stdout the first active USE flag among those supplied as parameters. |
33 |
-# If none are active, echo the first one |
34 |
-# |
35 |
- |
36 |
-glo_usev() { |
37 |
- if [[ $# < 1 || $# > 3 ]]; then |
38 |
- echo "Usage: ${0} flag [if_yes [if_no]]" |
39 |
- die "${0}: wrong number of arguments: $#" |
40 |
- fi |
41 |
- local if_yes="${2:-${1}}" if_no="${3}" |
42 |
- if useq ${1} ; then |
43 |
- printf "%s" "${if_yes}" |
44 |
- return 0 |
45 |
- else |
46 |
- printf "%s" "${if_no}" |
47 |
- return 1 |
48 |
- fi |
49 |
-} |
50 |
- |
51 |
-glo_best_flag() { |
52 |
- if [[ $# < 1 ]]; then |
53 |
- echo "Usage: ${0} flag+" |
54 |
- die "${0}: wrong number of arguments: $#" |
55 |
- fi |
56 |
- for flag in $@ ; do |
57 |
- if use ${flag} ; then |
58 |
- echo ${flag} |
59 |
- return |
60 |
- fi |
61 |
- done |
62 |
- echo ${1} |
63 |
-} |