/* c-name, lisp-[symbol-]name, package, filename */

DEFUN(FBoundp, "fboundp", CL, "cl-syms", );

makepackage clisp.h > clisp.s

In clisp.s:
extern struct StringC CLS$fboundp asm("_STR$fboundp");
struct RAWSymbol CL$fboundp = {
    _vt$Symbol,
    &CLS$fboundp,
    &NilSymbol,
    &CLPackage,
#ifdef AUTOLOAD
    _value = (char*)"cl-syms";
    _flags = Symbol::is_autoload;
#else
    _value = CLF$FBoundp;
    _flags = Symbol::has_function+Symbol::is_constant;
#endif			     
};

CLPackage = ....;

clisp.hh:
extern Symbol Fboundp_sym asm("CL$fboundp");
extern Function Fboundp asm("CLF$Fboundp");

In cl-syms.C:

#include "clisp.hh"

Root * FBoundp1(Root *arg) { ... }

Builtin_1 FBoundp(Fboundp_sym, FBoundp1);

func.C:
Builtin_1::Builtin_1(Symbol *sym, Func1)
{
    name = sym;
#ifdef AUTOLOAD
    sym->sym_function(this);
#endif
    op = func1;
}

symbol.c:
Symbol::fvalue()
{
     if (_flags & is_autoload) {
	 load(_value);
     }
}

general case:

(defun fname ( ) ...)

compiles into:

Root * fname_code(args) { ... }

Function fname_desc = { code, ...};

LFunction fname_func(fname_sym, fname_desc);

LFunction::LFunction(sym, desc, code)
{
    sym->set_function(this);
    func = desc;
}
