mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2025-12-20 16:20:09 +01:00
Fix build on windows
Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
parent
2fbd53a6b3
commit
e689e67004
1 changed files with 5 additions and 0 deletions
|
|
@ -28,7 +28,10 @@
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
|
|
||||||
|
#ifndef _WIN32
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#if CAIRO_HAS_PS_SURFACE
|
#if CAIRO_HAS_PS_SURFACE
|
||||||
#include <cairo-ps.h>
|
#include <cairo-ps.h>
|
||||||
|
|
@ -172,6 +175,7 @@ test_surface (const cairo_test_context_t *ctx,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* test propagation of file errors - for now this is unix-only */
|
/* test propagation of file errors - for now this is unix-only */
|
||||||
|
#ifndef _WIN32
|
||||||
if (access("/dev/full", W_OK) == 0) {
|
if (access("/dev/full", W_OK) == 0) {
|
||||||
surface = file_constructor ("/dev/full", WIDTH_IN_POINTS, HEIGHT_IN_POINTS);
|
surface = file_constructor ("/dev/full", WIDTH_IN_POINTS, HEIGHT_IN_POINTS);
|
||||||
cairo_surface_finish (surface);
|
cairo_surface_finish (surface);
|
||||||
|
|
@ -188,6 +192,7 @@ test_surface (const cairo_test_context_t *ctx,
|
||||||
cairo_test_log (ctx,
|
cairo_test_log (ctx,
|
||||||
"/dev/full does not exist; skipping write test.\n");
|
"/dev/full does not exist; skipping write test.\n");
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/* construct the real surface */
|
/* construct the real surface */
|
||||||
wc.ctx = ctx;
|
wc.ctx = ctx;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue