$OpenBSD$

Fix build on base-gcc.
Cherrypicked from commit 845acd7.

Index: main.c
--- main.c.orig
+++ main.c
@@ -78,10 +78,10 @@ static const int dimensions[] =
 };
 
 #define FONT_TEXTURE_SIZE 256
-const static unsigned int font_image_width = 112;
-const static unsigned int font_image_height = 84;
-const static unsigned int font_char_width = 7;
-const static unsigned int font_char_height = 14;
+#define FONT_IMAGE_WIDTH 112
+#define FONT_IMAGE_HEIGHT 84
+#define FONT_CHAR_WIDTH 7
+#define FONT_CHAR_HEIGHT 14
 #include "font_image.h"
 
 typedef struct {
@@ -135,7 +135,7 @@ FontData builtinFont = {
     .bitmap_height = 0,
     .character_width = 6, // actual width and height
     .character_height = 9,
-    .line_height = font_char_height,
+    .line_height = FONT_CHAR_HEIGHT,
     .font_size = 10.0,
     .texture_id = 0
 };
@@ -861,7 +861,7 @@ int get_line_advance(void)
     if (mainFont)
         return (int)(settings.line_spacing * mainFont->line_height);
 
-    return 2 * font_char_height;
+    return 2 * FONT_CHAR_HEIGHT;
 }
 
 int get_line_height(void)
@@ -869,7 +869,7 @@ int get_line_height(void)
     if (mainFont)
         return (int)(mainFont->line_height);
 
-    return 2 * font_char_height;
+    return 2 * FONT_CHAR_HEIGHT;
 }
 
 int get_character_width(void)
@@ -877,7 +877,7 @@ int get_character_width(void)
     if (mainFont)
         return mainFont->chars['X'].advance;
 
-    return font_char_width;
+    return FONT_CHAR_WIDTH;
 }
 
 int document_width(void)
@@ -1254,8 +1254,8 @@ pqrstuvwxyz{|}~
 int put_char_gl(int x, int y, char c)
 {
     int ret = 0;
-    int w = font_char_width;
-    int h = font_char_height;
+    int w = FONT_CHAR_WIDTH;
+    int h = FONT_CHAR_HEIGHT;
 
     glBindTexture(GL_TEXTURE_2D, mainFont->texture_id);
     glEnable(GL_BLEND);
@@ -1404,7 +1404,7 @@ void init_builtin_font(void)
 
     /* copy font_image into a larger texture 2^n sized buffer */
     copy_bitmap(builtinFont.bitmap, builtinFont.bitmap_width, builtinFont.bitmap_height, 0, 0,
-            font_image, font_image_width, font_image_height, font_image_width);
+            font_image, FONT_IMAGE_WIDTH, FONT_IMAGE_HEIGHT, FONT_IMAGE_WIDTH);
 
     /* fill information for builtin font */
     for (int i = 32; i < 128; i++)
@@ -1412,9 +1412,9 @@ void init_builtin_font(void)
         builtinFont.chars[i].available = 1;
         builtinFont.chars[i].top = builtinFont.character_height; /* actual height of X character in px */
         builtinFont.chars[i].left = 0;
-        builtinFont.chars[i].width = font_char_width;
-        builtinFont.chars[i].height = font_char_height;
-        builtinFont.chars[i].advance = font_char_width;
+        builtinFont.chars[i].width = FONT_CHAR_WIDTH;
+        builtinFont.chars[i].height = FONT_CHAR_HEIGHT;
+        builtinFont.chars[i].advance = FONT_CHAR_WIDTH;
 
         float pixel_x = 1.0f / builtinFont.bitmap_width;
         float pixel_y = 1.0f / builtinFont.bitmap_height;
@@ -1422,10 +1422,10 @@ void init_builtin_font(void)
         int c_col = (i - 32) % 16;
         int c_row = (i - 32) / 16;
 
-        builtinFont.chars[i].tex_coord0_x = pixel_x * c_col * font_char_width;
-        builtinFont.chars[i].tex_coord0_y = pixel_y * c_row * font_char_height;
-        builtinFont.chars[i].tex_coord1_x = pixel_x * (c_col + 1) * font_char_width;
-        builtinFont.chars[i].tex_coord1_y = pixel_y * (c_row + 1) * font_char_height;
+        builtinFont.chars[i].tex_coord0_x = pixel_x * c_col * FONT_CHAR_WIDTH;
+        builtinFont.chars[i].tex_coord0_y = pixel_y * c_row * FONT_CHAR_HEIGHT;
+        builtinFont.chars[i].tex_coord1_x = pixel_x * (c_col + 1) * FONT_CHAR_WIDTH;
+        builtinFont.chars[i].tex_coord1_y = pixel_y * (c_row + 1) * FONT_CHAR_HEIGHT;
     }
 }
 
