Bernard Leak wrote:
cat > test.awk <<EOF
BEGIN {
 FS="[ \t]+GPG_ERR_";
}

//^#/ { next; }

{
   print "  { " $1 ", \"GPG_ERR_" $2 "\" },";
}
EOF

Are you sure your syntax here is correct? On my sparc machine which is running glibc-2.3.5, gcc-3.4.4 and binutils-2.16.1, I get the following output when running your test:

  { , "GPG_ERR_" },
  { , "GPG_ERR_" },
  { , "GPG_ERR_" },
  { , "GPG_ERR_" },
  { , "GPG_ERR_" },

However, notice this:

root:~# cat test.in | gawk '{print $1}'
7
114
52
9
77
root:~# cat test.in | gawk '{print $2}'
GPG_ERR_E2BIG
GPG_ERR_EALREADY
GPG_ERR_EBADE
GPG_ERR_EBADF
GPG_ERR_EBADFD

It appears from this test that the fields are being recognized correctly.

--
JH
--
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to