1
0
mirror of https://review.coreboot.org/flashrom.git synced 2025-07-02 22:43:17 +02:00

Darwin / Mac OS X

Through DirectIO from coresystems GmbH we now support Darwin/Mac OS X.
DirectIO is available at http://www.coresystems.de/en/directio

Corresponding to flashrom svn r399 and coreboot v2 svn r3905.

Signed-off-by: Stefan Reinauer <stepan@coresystems.de>
Signed-off-by: Peter Stuge <peter@stuge.se>
Acked-by: Peter Stuge <peter@stuge.se>
This commit is contained in:
Stefan Reinauer
2009-01-26 01:23:31 +00:00
committed by Peter Stuge
parent a69c447b90
commit f79edb9a11
4 changed files with 45 additions and 5 deletions

View File

@ -30,6 +30,10 @@
#include <stdint.h>
#include <stdio.h>
#if (defined(__MACH__) && defined(__APPLE__))
#define __DARWIN__
#endif
#if defined(__FreeBSD__)
#include <machine/cpufunc.h>
#define off64_t off_t
@ -41,6 +45,11 @@
#define INW(x) __extension__ ({ u_int tmp = (x); inw(tmp); })
#define INL(x) __extension__ ({ u_int tmp = (x); inl(tmp); })
#else
#if defined(__DARWIN__)
#include <DirectIO/darwinio.h>
#define off64_t off_t
#define lseek64 lseek
#endif
#define OUTB outb
#define OUTW outw
#define OUTL outl