char line[BUFSIZ], *command;
char line[BUFSIZ], command[sizeof fmt + strlen (header->name) + 2 * strlen (CC) + strlen (INC) + strlen (macrofile)];
check_header (const struct header *header, const char **except){  char line[BUFSIZ], *command;  FILE *input;  int result = 0;  int found[header->nsyms];  int i;  memset (found, '\0', header->nsyms * sizeof (int));  command = alloca (sizeof fmt + strlen (header->name) + 2 * strlen (CC)		    + strlen (INC) + strlen (macrofile));  if (command == NULL)    {      puts ("No more memory.");      exit (1);    }  printf ("=== %s ===\n", header->name);  sprintf (command, fmt, header->name, CC, INC, CC, macrofile);  /* First see whether this subset is supported at all.  */  if (header->subset != NULL)    {      sprintf (line, testfmt, header->subset, header->subset, CC, INC, CC,	       macrofile);      if (xsystem (line))	{	  printf ("!! not available\n");	  return 0;	}    }  if (xsystem (command))    {      puts ("system() returned nonzero");      result = 1;    }  input = fopen (macrofile, "r");  if (input == NULL)    {      printf ("Could not read %s: ", macrofile);      perror (NULL);      return 1;    }  while (fgets (line, sizeof line, input) != NULL)    {      const char **ignore;      if (strlen (line) < 9 || line[7] != ' ')	{ /* "#define A" */	  printf ("Malformed input, expected '#define MACRO'\ngot '%s'\n",		  line);	  result = 1;	  continue;	}      /* Find next char after the macro identifier; this can be either	 a space or an open parenthesis.  */      line[8 + strcspn (&line[8], " (")] = '\0';      /* Now check whether it's one of the required macros.  */      for (i = 0; i < header->nsyms; ++i)	if (!strcmp (&line[8], header->syms[i]))	  break;      if (i < header->nsyms)	{	  found[i] = 1;	  continue;	}      /* Symbols starting with "_" are ok.  */      if (line[8] == '_')	continue;      /* Maybe one of the symbols which are always defined.  */      for (ignore = except; *ignore != NULL; ++ignore)	if (! strcmp (&line[8], *ignore))	  break;      if (*ignore != NULL)	continue;      /* Otherwise the symbol better should match one of the following.  */      for (i = 0; i < header->nmaybe; ++i)	if (fnmatch (header->maybe[i], &line[8], 0) == 0)	  break;      if (i < header->nmaybe)	continue;      printf ("*  invalid macro `%s'\n", &line[8]);      result |= 1;    }  fclose (input);  remove (macrofile);  for (i = 0; i < header->nsyms; ++i)    if (found[i] == 0)      printf ("** macro `%s' not defined\n", header->syms[i]);  return result;}