]> Cypherpunks repositories - gostls13.git/commitdiff
include/plan9: make mklibc.rc compatible with 9atom
authorDavid du Colombier <0intro@gmail.com>
Sat, 19 Apr 2014 07:55:09 +0000 (09:55 +0200)
committerDavid du Colombier <0intro@gmail.com>
Sat, 19 Apr 2014 07:55:09 +0000 (09:55 +0200)
Since there is no Runemask constant in UTF-8 enum in
9atom, removing the other constants leads to an empty
enum, which is illegal. Thus, we remove enum entirely.

LGTM=r
R=golang-codereviews, r
CC=golang-codereviews
https://golang.org/cl/82660044

include/plan9/mklibc.rc

index 460ef1ce4bef623c5e5f40c8b7db0a9e817f547e..449e15fdffa65c15f4e52d4096536c5d1824beb2 100755 (executable)
@@ -1,13 +1,8 @@
 #!/bin/rc
 
 pattern='/umuldiv/d
-       /UTFmax/d
-       /Runesync/d
-       /Runeself/d
-       /Runeerror/d
-       /Runemax/d
        /rune routines/,/^\/\*/d
        /print routines/,/^\/\*/d
        /error string for/,/^\/\*/d'
 
-sed -e $pattern /sys/include/libc.h
+sed -e $pattern /sys/include/libc.h | awk '/^enum/ && !n++, /^};/ {next}1'