require '_h2ph_pre.ph';

no warnings qw(redefine misc);

unless(defined(&_SYS_MQUEUE_H_)) {
    eval 'sub _SYS_MQUEUE_H_ () {1;}' unless defined(&_SYS_MQUEUE_H_);
    eval 'sub MQ_OPEN_MAX () {512;}' unless defined(&MQ_OPEN_MAX);
    eval 'sub MQ_PRIO_MAX () {32;}' unless defined(&MQ_PRIO_MAX);
    if(defined(&_KERNEL)) {
	require 'sys/condvar.ph';
	require 'sys/mutex.ph';
	require 'sys/queue.ph';
	require 'sys/selinfo.ph';
	require 'sys/types.ph';
	require 'sys/param.ph';
	eval 'sub MQ_UNLINKED () {0x10000000;}' unless defined(&MQ_UNLINKED);
	eval 'sub MQ_RECEIVE () {0x20000000;}' unless defined(&MQ_RECEIVE);
	eval 'sub MQ_NAMELEN () {( &KERNEL_NAME_MAX + 1);}' unless defined(&MQ_NAMELEN);
	eval 'sub MQ_DEF_MSGSIZE () {1024;}' unless defined(&MQ_DEF_MSGSIZE);
	eval 'sub MQ_PQSIZE () {32;}' unless defined(&MQ_PQSIZE);
	eval 'sub MQ_PQRESQ () {0;}' unless defined(&MQ_PQRESQ);
    }
}
1;
