diff --git a/contrib/sdk/sources/newlib/libc/include/kos32sys.h b/contrib/sdk/sources/newlib/libc/include/kos32sys.h index afefbac03f..ad67e5852a 100644 --- a/contrib/sdk/sources/newlib/libc/include/kos32sys.h +++ b/contrib/sdk/sources/newlib/libc/include/kos32sys.h @@ -15,7 +15,9 @@ extern "C" { // #define DBG(format,...) //#endif -#define TYPE_3_BORDER_WIDTH 5 +#define TYPE_3_BORDER_WIDTH 5 +#define WIN_STATE_MINIMIZED 0x02 +#define WIN_STATE_ROLLED 0x04 typedef unsigned int color_t; @@ -428,7 +430,7 @@ void* user_realloc(void *mem, size_t size) return val; }; -static inline void* UserRrealloc(void *mem, size_t size) __attribute__ ((alias ("user_realloc"))); +static inline void* UserRealloc(void *mem, size_t size) __attribute__ ((alias ("user_realloc"))); void *get_resource(void *data, uint32_t id); diff --git a/contrib/sdk/sources/newlib/libc/include/pixlib3.h b/contrib/sdk/sources/newlib/libc/include/pixlib3.h new file mode 100644 index 0000000000..afab7aa6f6 --- /dev/null +++ b/contrib/sdk/sources/newlib/libc/include/pixlib3.h @@ -0,0 +1,33 @@ +#ifndef __PIXLIB3_H__ +#define __PIXLIB3_H__ + +#include + +#define HW_BIT_BLIT (1<<0) /* BGRX blitter */ +#define HW_TEX_BLIT (1<<1) /* stretch blit */ +#define HW_VID_BLIT (1<<2) /* planar and packed video */ + + +struct bitmap; +typedef struct bitmap bitmap_t; + +uint32_t pxInit(int hw); +void pxFini(); + +bitmap_t *pxCreateBitmap(uint32_t width, uint32_t height); + +int pxDestroyBitmap(bitmap_t *bitmap); + +void *pxLockBitmap(bitmap_t *bitmap, uint32_t *pitch); + +int pxResizeBitmap(bitmap_t *bitmap, uint32_t width, uint32_t height); + +int pxBlitBitmap(bitmap_t *bitmap, int dst_x, int dst_y, + uint32_t w, uint32_t h, int src_x, int src_y); + +int pxCreateClient(int x, int y, uint32_t width, uint32_t height); + +int pxResizeClient(int x, int y, uint32_t width, uint32_t height); + +#endif + diff --git a/contrib/sdk/sources/newlib/libc/include/sys/_default_fcntl.h b/contrib/sdk/sources/newlib/libc/include/sys/_default_fcntl.h index 396208bbb0..998c8e11b8 100644 --- a/contrib/sdk/sources/newlib/libc/include/sys/_default_fcntl.h +++ b/contrib/sdk/sources/newlib/libc/include/sys/_default_fcntl.h @@ -43,7 +43,6 @@ extern "C" { #define O_NONBLOCK _FNONBLOCK #define O_NOCTTY _FNOCTTY /* For machines which care - */ -#if defined (_WIN32) || defined (__CYGWIN__) #define _FBINARY 0x10000 #define _FTEXT 0x20000 #define _FNOINHERIT 0x40000 @@ -66,7 +65,6 @@ extern "C" { #define _O_BINARY O_BINARY #define _O_RAW O_BINARY #define _O_NOINHERIT O_NOINHERIT -#endif #ifndef _POSIX_SOURCE diff --git a/contrib/sdk/sources/newlib/libc/sys/fstat.c b/contrib/sdk/sources/newlib/libc/sys/fstat.c index ecfbe73c3e..f4d299c3d4 100644 --- a/contrib/sdk/sources/newlib/libc/sys/fstat.c +++ b/contrib/sdk/sources/newlib/libc/sys/fstat.c @@ -59,6 +59,7 @@ _DEFUN (fstat, (fd, buf), buf->st_mode = S_IFREG|S_IRUSR|S_IWUSR|S_IXUSR; } buf->st_blksize = 4096; + buf->st_size = info.size; time.tm_sec = info.atime.sec; time.tm_min = info.atime.min;