Build fix for amd64 Linux

This commit is contained in:
Keno Fischer 2012-05-25 20:04:41 -07:00
parent c3d4e51cd8
commit f21624349f
3 changed files with 17 additions and 17 deletions

View File

@ -42,7 +42,7 @@
#ifndef _MACHINE_IEEEFP_H_
#define _MACHINE_IEEEFP_H_
#if !defined(_SYS_CDEFS_H_) && !defined(_CDEFS_H_)
#if !defined(_SYS_CDEFS_H) && !defined(_SYS_CDEFS_H_) && !defined(_CDEFS_H_)
#error this file needs sys/cdefs.h as a prerequisite
#endif

View File

@ -29,8 +29,8 @@
#ifndef _FENV_H_
#define _FENV_H_
#include <sys/cdefs.h>
#include <sys/_types.h>
#include "include/cdefs-compat.h"
#include "include/types-compat.h"
#ifndef __fenv_static
#define __fenv_static static
@ -38,15 +38,15 @@
typedef struct {
struct {
__uint32_t __control;
__uint32_t __status;
__uint32_t __tag;
uint32_t __control;
uint32_t __status;
uint32_t __tag;
char __other[16];
} __x87;
__uint32_t __mxcsr;
uint32_t __mxcsr;
} fenv_t;
typedef __uint16_t fexcept_t;
typedef uint16_t fexcept_t;
/* Exception flags */
#define FE_INVALID 0x01
@ -114,8 +114,8 @@ feclearexcept(int __excepts)
__fenv_static inline int
fegetexceptflag(fexcept_t *__flagp, int __excepts)
{
__uint32_t __mxcsr;
__uint16_t __status;
uint32_t __mxcsr;
uint16_t __status;
__stmxcsr(&__mxcsr);
__fnstsw(&__status);
@ -129,8 +129,8 @@ int feraiseexcept(int __excepts);
__fenv_static inline int
fetestexcept(int __excepts)
{
__uint32_t __mxcsr;
__uint16_t __status;
uint32_t __mxcsr;
uint16_t __status;
__stmxcsr(&__mxcsr);
__fnstsw(&__status);
@ -140,7 +140,7 @@ fetestexcept(int __excepts)
__fenv_static inline int
fegetround(void)
{
__uint16_t __control;
uint16_t __control;
/*
* We assume that the x87 and the SSE unit agree on the
@ -155,8 +155,8 @@ fegetround(void)
__fenv_static inline int
fesetround(int __round)
{
__uint32_t __mxcsr;
__uint16_t __control;
uint32_t __mxcsr;
uint16_t __control;
if (__round & ~_ROUND_MASK)
return (-1);
@ -205,7 +205,7 @@ int fedisableexcept(int __mask);
static inline int
fegetexcept(void)
{
__uint16_t __control;
uint16_t __control;
/*
* We assume that the masks for the x87 and the SSE unit are

View File

@ -7,6 +7,7 @@
#include <sys/types.h>
#include <limits.h>
#include <stdint.h>
#ifdef __linux__
/* Not sure what to do about __pure2 on linux */
@ -16,7 +17,6 @@
#ifdef __WIN32__
/* Not sure what to do about __pure2 on linux */
#define __pure2
#include <stdint.h>
typedef uint8_t u_int8_t;
typedef uint16_t u_int16_t;
typedef uint32_t u_int32_t;