Skip to content

Commit 3baddf0

Browse files
danielmyhDaniel Myhrmanjohan-hultberg-work
committed
Fix fontconfig error in axoverlay example
Co-authored-by: Daniel Myhrman <[email protected]> Co-authored-by: Johan Olsson <[email protected]>
1 parent 849e6cf commit 3baddf0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

axoverlay/app/axoverlay.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
#include <errno.h>
3434
#include <glib-unix.h>
3535
#include <glib.h>
36+
#include <stdlib.h>
3637
#include <syslog.h>
3738

3839
#define PALETTE_VALUE_RANGE 255.0
@@ -357,6 +358,8 @@ static gboolean signal_handler(gpointer loop) {
357358
* API axoverlay.
358359
*/
359360
int main(void) {
361+
// Set XDG cache home to application's localdata directory for fontconfig
362+
setenv("XDG_CACHE_HOME", "/usr/local/packages/axoverlay/localdata", 1);
360363
GMainLoop* loop = NULL;
361364
GError* error = NULL;
362365
GError* error_text = NULL;

0 commit comments

Comments
 (0)