libk  gen-ident.awk at [8618103a4e]

File global/gen-ident.awk artifact 730afca5a3 part of check-in 8618103a4e


BEGIN {
	defs = ""
	FS = ":"
	ORS = ""
	print "#include <k/internal.egroup.h>\n"
	print "extern const char"
}

{
	if (NR != 1) sep = ","
	print sep"\n\t*"$1"_error_strings[]"
	defs = defs "\t{ \""$1"\", \"k "$4"\", "$1"_error_strings },\n"
}

END {
	print ";\n"
	print "struct kglobal_module_record kglobal_module_ident[] = {\n"
		print defs
	print "};"
}