mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-02-12 13:30:34 +01:00
[perf] Need to version surface types
As cairo-perf-diff will execute the current cairo-perf against historical revisions, any introduced api must be protect in order to compile on old versions.
This commit is contained in:
parent
44b72ba6d7
commit
ef0d307d54
2 changed files with 14 additions and 0 deletions
|
|
@ -30,6 +30,8 @@
|
|||
|
||||
#define _GNU_SOURCE 1 /* for sched_getaffinity() and getline() */
|
||||
|
||||
#include "../cairo-version.h" /* for the real version */
|
||||
|
||||
#include "cairo-perf.h"
|
||||
#include "cairo-stats.h"
|
||||
|
||||
|
|
@ -98,9 +100,15 @@ target_is_measurable (const cairo_boilerplate_target_t *target)
|
|||
case CAIRO_SURFACE_TYPE_WIN32:
|
||||
case CAIRO_SURFACE_TYPE_BEOS:
|
||||
case CAIRO_SURFACE_TYPE_DIRECTFB:
|
||||
#if CAIRO_VERSION > CAIRO_VERSION_ENCODE(1,1,2)
|
||||
case CAIRO_SURFACE_TYPE_OS2:
|
||||
#endif
|
||||
#if CAIRO_VERSION > CAIRO_VERSION_ENCODE(1,9,3)
|
||||
case CAIRO_SURFACE_TYPE_QT:
|
||||
#endif
|
||||
#if CAIRO_VERSION > CAIRO_VERSION_ENCODE(1,9,3)
|
||||
case CAIRO_INTERNAL_SURFACE_TYPE_NULL:
|
||||
#endif
|
||||
return TRUE;
|
||||
case CAIRO_SURFACE_TYPE_PDF:
|
||||
case CAIRO_SURFACE_TYPE_PS:
|
||||
|
|
|
|||
|
|
@ -28,6 +28,8 @@
|
|||
|
||||
#define _GNU_SOURCE 1 /* for sched_getaffinity() */
|
||||
|
||||
#include "../cairo-version.h" /* for the real version */
|
||||
|
||||
#include "cairo-perf.h"
|
||||
#include "cairo-stats.h"
|
||||
|
||||
|
|
@ -92,8 +94,12 @@ target_is_measurable (const cairo_boilerplate_target_t *target)
|
|||
case CAIRO_SURFACE_TYPE_WIN32:
|
||||
case CAIRO_SURFACE_TYPE_BEOS:
|
||||
case CAIRO_SURFACE_TYPE_DIRECTFB:
|
||||
#if CAIRO_VERSION > CAIRO_VERSION_ENCODE(1,1,2)
|
||||
case CAIRO_SURFACE_TYPE_OS2:
|
||||
#endif
|
||||
#if CAIRO_VERSION > CAIRO_VERSION_ENCODE(1,9,4)
|
||||
case CAIRO_SURFACE_TYPE_QT:
|
||||
#endif
|
||||
return TRUE;
|
||||
case CAIRO_SURFACE_TYPE_PDF:
|
||||
case CAIRO_SURFACE_TYPE_PS:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue