require '_h2ph_pre.ph';

no warnings qw(redefine misc);

unless(defined(&_SYS_DOMAIN_H_)) {
    eval 'sub _SYS_DOMAIN_H_ () {1;}' unless defined(&_SYS_DOMAIN_H_);
    require 'sys/mbuf.ph';
    require 'sys/socket.ph';
    require 'net/route.ph';
    if(defined(&_KERNEL)) {
	eval 'sub DOMAIN_DEFINE {
	    my($name) = @_;
    	    eval q( &extern \'struct domain\' $name;  &__link_set_add_data( &domains, $name));
	}' unless defined(&DOMAIN_DEFINE);
	eval 'sub DOMAIN_FOREACH {
	    my($dom) = @_;
    	    eval q( &STAILQ_FOREACH($dom,  &domains,  &dom_link));
	}' unless defined(&DOMAIN_FOREACH);
    }
}
1;
