blob: 24cd80b2f91711ba5e78d30f59ca7cfa3985a873 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
$NetBSD: patch-lookups_Makefile,v 1.3 2014/07/23 14:09:52 adam Exp $
Avoid use of non-portable "local" keyword.
--- scripts/lookups-Makefile.orig 2014-07-21 14:28:07.000000000 +0000
+++ scripts/lookups-Makefile
@@ -87,16 +87,16 @@ fi
# command-line, not just check the Makefile.
want_dynamic() {
- local dyn_name="$1"
- local re="LOOKUP_${dyn_name}[ $tab]*=[ $tab]*2"
+ dyn_name="$1"
+ re="LOOKUP_${dyn_name}[ $tab]*=[ $tab]*2"
env | grep -q "^$re"
if [ $? -eq 0 ]; then return 0; fi
grep -q "^[ $tab]*$re" "$defs_source"
}
want_at_all() {
- local want_name="$1"
- local re="LOOKUP_${want_name}[ $tab]*=[ $tab]*."
+ want_name="$1"
+ re="LOOKUP_${want_name}[ $tab]*=[ $tab]*."
env | grep -q "^$re"
if [ $? -eq 0 ]; then return 0; fi
grep -q "^[ $tab]*$re" "$defs_source"
@@ -104,8 +104,8 @@ want_at_all() {
# Adapted want_at_all above to work for EXPERIMENTAL features
want_experimental() {
- local want_name="$1"
- local re="EXPERIMENTAL_${want_name}[ $tab]*=[ $tab]*."
+ want_name="$1"
+ re="EXPERIMENTAL_${want_name}[ $tab]*=[ $tab]*."
env | grep -q "^$re"
if [ $? -eq 0 ]; then return 0; fi
grep -q "^[ $tab]*$re" "$defs_source"
@@ -117,8 +117,7 @@ MODS=""
OBJ=""
emit_module_rule() {
- local lookup_name="$1"
- local mod_name pkgconf
+ lookup_name="$1"
if [ "${lookup_name%:*}" = "$lookup_name" ]
then
# Square brackets are redundant but benign for POSIX compliant tr,
|