summaryrefslogtreecommitdiff
path: root/pkgtools
diff options
context:
space:
mode:
Diffstat (limited to 'pkgtools')
-rw-r--r--pkgtools/libnbcompat/files/nbcompat.awk22
1 files changed, 11 insertions, 11 deletions
diff --git a/pkgtools/libnbcompat/files/nbcompat.awk b/pkgtools/libnbcompat/files/nbcompat.awk
index 147739009bc..c1946624a60 100644
--- a/pkgtools/libnbcompat/files/nbcompat.awk
+++ b/pkgtools/libnbcompat/files/nbcompat.awk
@@ -3,22 +3,22 @@ BEGIN { process = 1 }
/NBCOMPAT template section follows\./ { process = 0 }
/^\#[ ]*define[ ]+PACKAGE_.*/ {
- if (process == 0)
+ if (process == 1) {
+ print "/* " $0 " */";
next;
- print "/* " $0 " */";
- next;
+ }
}
/^\#[ ]*define[ ]+/ {
- if (process == 0)
+ if (process == 1) {
+ guard = $0;
+ sub("^#[ ]*define[ ]+", "", guard);
+ sub("[ ]+.*", "", guard);
+ print "#ifndef " guard;
+ print $0;
+ print "#endif";
next;
- guard = $0;
- sub("^#[ ]*define[ ]+", "", guard);
- sub("[ ]+.*", "", guard);
- print "#ifndef " guard;
- print $0;
- print "#endif";
- next;
+ }
}
{ print }