/usr/src/servers/pm/proto.h
In the section for file misc.c add a PROTOTYPE declaration for the new do_xxxx. The PROTOTYPE macro generatess ANSI prototypes or KR prototypes depending on the compiler used to build minix. Yuk.
For example,
_PROTOTYPE( int do_mygetpid, (void) ); _PROTOTYPE( void setreply, (int proc_nr, int result) );
The _PROTOTYPE macro is define like this:
#ifdef ANSI #define _PROTOTYPE(a,b) a##b #else #define _PROTOTYPE(a,b) a() #endif
When the preprocessor sees the two macro calls above it generates
If ANSI is defined, standard ANSI declarations are generated int do_mygetpid (void); void setreply (int proc_nr, int result); else old style Kernighan-Ritchie declarations with parameter list omitted: int do_mygetpid(); void setreply();