Date: Mon, 6 Jul 1998 06:46:20 +0000 (GMT) From: Terry Lambert <tlambert@primenet.com> To: wjw@digiware.nl Cc: mike@smith.net.au, terry@lambert.org, hackers@FreeBSD.ORG Subject: Re: adding to sysctl env. Message-ID: <199807060646.XAA21779@usr02.primenet.com> In-Reply-To: <199807052039.UAA10241@digi.digiware.nl> from "Willem Jan Withagen" at Jul 5, 98 10:39:30 pm
next in thread | previous in thread | raw e-mail | index | archive | help
> If an include file requires another include file. > eg. sys/sysctl.h requires sys/kernel.h > > Does the include for kernel.h go into sysctl.h? No. If it compiles without it, it's not "required". In general, this is so you can put things that are in the kernel.h namespace (like your own functions with the same name) and still include sysctl.h. Admittedly, the dependency you describe seems like an organizational bug. At the very least, it should have #warn'ed you. > Reason I ask, is that there were no errors when I compiled without > the inclusion, but that was the problem I could not see the > debug.vlinkxlate in sysctl. :-( You need to look into why there were no errors. At a minimum, there should have been a linktime error, if a macro was confused as an external function reference. The man page is useful, but the inclusion of the kernel.h was probably for some other prototype, not the sysctl prototype, IMO. You need to narrow down your problem to make sure you aren't documenting an #include that is necessary for your implementation, and not for sysctl's in general. Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199807060646.XAA21779>