require '_h2ph_pre.ph';

no warnings qw(redefine misc);

unless(defined(&_FENV_H_)) {
    eval 'sub _FENV_H_ () {1;}' unless defined(&_FENV_H_);
    require 'sys/featuretest.ph';
    if(defined(&__vax__)) {
	unless(defined(&__TEST_FENV)) {
	    die("fenv.h is currently not supported for this architecture");
	}
    } else {
	eval 'sub __HAVE_FENV () {1;}' unless defined(&__HAVE_FENV);
	require 'machine/fenv.ph';
    }
    if((defined(&__arm__)  && defined(&__SOFTFP__)) || (defined(&__m68k__)  && !defined(&__HAVE_68881__)) || defined(&__mips_soft_float) || (defined(&__powerpc__)  && defined(&_SOFT_FLOAT)) || (defined(&__sh__)  && !defined(&__SH_FPU_ANY__)) || 0) {
	unless(defined(&__HAVE_FENV_SOFTFLOAT_DEFS)) {
	    eval 'sub __FENV_GET_FLAGS {
	        my($__envp) = @_;
    		eval q(($__envp)-> &__flags);
	    }' unless defined(&__FENV_GET_FLAGS);
	    eval 'sub __FENV_GET_MASK {
	        my($__envp) = @_;
    		eval q(($__envp)-> &__mask);
	    }' unless defined(&__FENV_GET_MASK);
	    eval 'sub __FENV_GET_ROUND {
	        my($__envp) = @_;
    		eval q(($__envp)-> &__round);
	    }' unless defined(&__FENV_GET_ROUND);
	    eval 'sub __FENV_SET_FLAGS {
	        my($__envp, $__val) = @_;
    		eval q(($__envp)-> &__flags = ($__val));
	    }' unless defined(&__FENV_SET_FLAGS);
	    eval 'sub __FENV_SET_MASK {
	        my($__envp, $__val) = @_;
    		eval q(($__envp)-> &__mask = ($__val));
	    }' unless defined(&__FENV_SET_MASK);
	    eval 'sub __FENV_SET_ROUND {
	        my($__envp, $__val) = @_;
    		eval q(($__envp)-> &__round = ($__val));
	    }' unless defined(&__FENV_SET_ROUND);
	}
    }
    if(defined(&_NETBSD_SOURCE) || defined(&_GNU_SOURCE)) {
    }
}
1;
