require '_h2ph_pre.ph';

no warnings qw(redefine misc);

unless(defined(&_MENU_H_)) {
    eval 'sub _MENU_H_ () {1;}' unless defined(&_MENU_H_);
    require 'curses.ph';
    require 'eti.ph';
    eval 'sub REQ_BASE_NUM () {( &KEY_MAX + 0x200);}' unless defined(&REQ_BASE_NUM);
    eval 'sub REQ_LEFT_ITEM () {( &KEY_MAX + 0x201);}' unless defined(&REQ_LEFT_ITEM);
    eval 'sub REQ_RIGHT_ITEM () {( &KEY_MAX + 0x202);}' unless defined(&REQ_RIGHT_ITEM);
    eval 'sub REQ_UP_ITEM () {( &KEY_MAX + 0x203);}' unless defined(&REQ_UP_ITEM);
    eval 'sub REQ_DOWN_ITEM () {( &KEY_MAX + 0x204);}' unless defined(&REQ_DOWN_ITEM);
    eval 'sub REQ_SCR_ULINE () {( &KEY_MAX + 0x205);}' unless defined(&REQ_SCR_ULINE);
    eval 'sub REQ_SCR_DLINE () {( &KEY_MAX + 0x206);}' unless defined(&REQ_SCR_DLINE);
    eval 'sub REQ_SCR_DPAGE () {( &KEY_MAX + 0x207);}' unless defined(&REQ_SCR_DPAGE);
    eval 'sub REQ_SCR_UPAGE () {( &KEY_MAX + 0x208);}' unless defined(&REQ_SCR_UPAGE);
    eval 'sub REQ_FIRST_ITEM () {( &KEY_MAX + 0x209);}' unless defined(&REQ_FIRST_ITEM);
    eval 'sub REQ_LAST_ITEM () {( &KEY_MAX + 0x20a);}' unless defined(&REQ_LAST_ITEM);
    eval 'sub REQ_NEXT_ITEM () {( &KEY_MAX + 0x20b);}' unless defined(&REQ_NEXT_ITEM);
    eval 'sub REQ_PREV_ITEM () {( &KEY_MAX + 0x20c);}' unless defined(&REQ_PREV_ITEM);
    eval 'sub REQ_TOGGLE_ITEM () {( &KEY_MAX + 0x20d);}' unless defined(&REQ_TOGGLE_ITEM);
    eval 'sub REQ_CLEAR_PATTERN () {( &KEY_MAX + 0x20e);}' unless defined(&REQ_CLEAR_PATTERN);
    eval 'sub REQ_BACK_PATTERN () {( &KEY_MAX + 0x20f);}' unless defined(&REQ_BACK_PATTERN);
    eval 'sub REQ_NEXT_MATCH () {( &KEY_MAX + 0x210);}' unless defined(&REQ_NEXT_MATCH);
    eval 'sub REQ_PREV_MATCH () {( &KEY_MAX + 0x211);}' unless defined(&REQ_PREV_MATCH);
    eval 'sub MAX_COMMAND () {( &KEY_MAX + 0x211);}' unless defined(&MAX_COMMAND);
    eval 'sub O_ONEVALUE () {(0x1);}' unless defined(&O_ONEVALUE);
    eval 'sub O_SHOWDESC () {(0x2);}' unless defined(&O_SHOWDESC);
    eval 'sub O_ROWMAJOR () {(0x4);}' unless defined(&O_ROWMAJOR);
    eval 'sub O_IGNORECASE () {(0x8);}' unless defined(&O_IGNORECASE);
    eval 'sub O_SHOWMATCH () {(0x10);}' unless defined(&O_SHOWMATCH);
    eval 'sub O_NONCYCLIC () {(0x20);}' unless defined(&O_NONCYCLIC);
    eval 'sub O_SELECTABLE () {(0x40);}' unless defined(&O_SELECTABLE);
    eval 'sub O_RADIO () {(0x80);}' unless defined(&O_RADIO);
}
1;
