+#include <caca.h>
+
+#ifndef CACA_API_VERSION_1
+ /* Upward compatibility macros */
+ typedef char cucul_canvas_t;
+ typedef struct caca_bitmap cucul_dither_t;
+ typedef char caca_display_t;
+# define CUCUL_COLOR_DEFAULT CACA_COLOR_LIGHTGRAY
+# define CUCUL_COLOR_BLACK CACA_COLOR_BLACK
+# define cucul_clear_canvas(x) caca_clear()
+# define cucul_create_canvas(x,y) "" /* kinda hacky */
+# define cucul_create_dither caca_create_bitmap
+# define cucul_dither_bitmap(x,y,z,t,u,v,w) caca_draw_bitmap(y,z,t,u,v,w)
+# define cucul_free_dither caca_free_bitmap
+# define cucul_free_canvas(x)
+# define cucul_get_canvas_width(x) caca_get_width()
+# define cucul_get_canvas_height(x) caca_get_height()
+# define cucul_set_color(x,y,z) caca_set_color(y,z)
+# define caca_create_display(x) (caca_init() ? NULL : "") /* hacky, too */
+# define caca_free_display(x) caca_end()
+# define caca_get_event(x,y,z,t) *(z) = caca_get_event(y)
+# define caca_refresh_display(x) caca_refresh()
+# define caca_set_display_title(x,y) caca_set_window_title(y)
+#endif
+