require '_h2ph_pre.ph';

unless(defined(&__SYSTM_H__)) {
    eval 'sub __SYSTM_H__ () {1;}' unless defined(&__SYSTM_H__);
    require 'sys/queue.ph';
    require 'machine/stdarg.ph';
    if((defined(&BYTE_ORDER) ? &BYTE_ORDER : 0) == (defined(&BIG_ENDIAN) ? &BIG_ENDIAN : 0)) {
	eval 'sub SCARG {
	    local($p, $k) = @_;
    	    eval q((($p)-> ($k->{be}->{datum})));
	}' unless defined(&SCARG);
    }
 elsif((defined(&BYTE_ORDER) ? &BYTE_ORDER : 0) == (defined(&LITTLE_ENDIAN) ? &LITTLE_ENDIAN : 0)) {
	eval 'sub SCARG {
	    local($p, $k) = @_;
    	    eval q((($p)-> ($k->{le}->{datum})));
	}' unless defined(&SCARG);
    } else {
	die("what byte order is this machine?");
    }
    if(defined( &_KERNEL)  && defined( &SYSCALL_DEBUG)) {
    }
    eval 'sub insque {
        local($q,$p) = @_;
	    eval q( &_insque($q, $p));
    }' unless defined(&insque);
    eval 'sub remque {
        local($q) = @_;
	    eval q( &_remque($q));
    }' unless defined(&remque);
    if(defined(&__KPRINTF_ATTRIBUTE__)) {
    } else {
    }
    eval 'sub HOOK_REMOVE () {0x1;}' unless defined(&HOOK_REMOVE);
    eval 'sub HOOK_FREE () {0x2;}' unless defined(&HOOK_FREE);
    eval 'sub startuphook_establish {
        local($fn, $arg) = @_;
	    eval q( &hook_establish( &startuphook_list, 1, ($fn), ($arg)));
    }' unless defined(&startuphook_establish);
    eval 'sub startuphook_disestablish {
        local($vhook) = @_;
	    eval q( &hook_disestablish( &startuphook_list, ($vhook)));
    }' unless defined(&startuphook_disestablish);
    eval 'sub dostartuphooks () {
        eval q( &dohooks( &startuphook_list,  &HOOK_REMOVE| &HOOK_FREE));
    }' unless defined(&dostartuphooks);
    eval 'sub shutdownhook_establish {
        local($fn, $arg) = @_;
	    eval q( &hook_establish( &shutdownhook_list, 0, ($fn), ($arg)));
    }' unless defined(&shutdownhook_establish);
    eval 'sub shutdownhook_disestablish {
        local($vhook) = @_;
	    eval q( &hook_disestablish( &shutdownhook_list, ($vhook)));
    }' unless defined(&shutdownhook_disestablish);
    eval 'sub doshutdownhooks () {
        eval q( &dohooks( &shutdownhook_list,  &HOOK_REMOVE));
    }' unless defined(&doshutdownhooks);
    eval 'sub PWR_RESUME () {0;}' unless defined(&PWR_RESUME);
    eval 'sub PWR_SUSPEND () {1;}' unless defined(&PWR_SUSPEND);
    eval 'sub PWR_STANDBY () {2;}' unless defined(&PWR_STANDBY);
    if(defined(&GPROF)) {
    }
    require 'lib/libkern/libkern.ph';
    if(defined( &DDB) || defined( &KGDB)) {
    }
    if(defined(&BOOT_CONFIG)) {
    }
}
1;
