From jon@spock.org  Fri Oct 13 23:57:25 2000
Return-Path: <jon@spock.org>
Received: from spock.org (cm-24-169-0-39.nycap.rr.com [24.169.0.39])
	by hub.freebsd.org (Postfix) with ESMTP id AE6AB37B503
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 13 Oct 2000 23:57:24 -0700 (PDT)
Received: (from jon@localhost)
	by spock.org  serial EF600Q3T-B7F;
	Sat, 14 Oct 2000 02:57:18 -0400 (EDT)
	(envelope-from jon)
Message-Id: <200010140657.e9E6vIp07839@spock.org>
Date: Sat, 14 Oct 2000 02:57:18 -0400 (EDT)
From: Jonathan Chen <jon@spock.org>
Reply-To: jon@spock.org
To: FreeBSD-gnats-submit@freebsd.org
Subject: makedevops.pl HEADER section doesn't quite work
X-Send-Pr-Version: 3.2

>Number:         21982
>Category:       kern
>Synopsis:       makedevops.pl HEADER section doesn't quite work
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    n_hibma
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Oct 14 00:00:01 PDT 2000
>Closed-Date:    Sun Oct 15 08:22:36 PDT 2000
>Last-Modified:  Sun Oct 15 08:23:29 PDT 2000
>Originator:     Jonathan Chen
>Release:        all
>Organization:
>Environment:

	

>Description:

The HEADER section was introduced to sys/kern/makedevops.pl (1.10) by
n_hibma.  The name seems to suggest a section that would be generated into
the header file.  It doesn't do that.  Note that no existing .m files use
the HEADER section.

>How-To-Repeat:
echo > foo_if.m << EOF
INTERFACE foo;
HEADER {
  /* this should be in the header */
};
EOF
perl5 -w /usr/src/sys/kern/makedevops.pl -h foo_if.m

>Fix:

Index: sys/kern/makedevops.pl
===================================================================
RCS file: /export/ncvs/src/sys/kern/makedevops.pl,v
retrieving revision 1.12
diff -u -r1.12 makedevops.pl
--- sys/kern/makedevops.pl	1999/11/22 14:40:04	1.12
+++ sys/kern/makedevops.pl	2000/10/14 06:55:55
@@ -249,7 +249,7 @@
             $lineno++
          }
          if ( $hfile ) {
-             print CFILE $header;
+             print HFILE $header;
          }
       } elsif ( $line =~ m/^(STATIC|)METHOD/i ) {
          # Get the return type function name and delete that from

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->n_hibma 
Responsible-Changed-By: johan 
Responsible-Changed-When: Sat Oct 14 07:10:13 PDT 2000 
Responsible-Changed-Why:  
Nick introduced the code and knows the purpose of it. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=21982 
State-Changed-From-To: open->closed 
State-Changed-By: n_hibma 
State-Changed-When: Sun Oct 15 08:22:36 PDT 2000 
State-Changed-Why:  
Committed to current. Will backport i to 4.x in a week or so. 

Thanks. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=21982 
>Unformatted:
