aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/imv.c5
-rw-r--r--src/loader.c5
-rw-r--r--src/navigator.c5
3 files changed, 15 insertions, 0 deletions
diff --git a/src/imv.c b/src/imv.c
index 717a77b..8ba96ea 100644
--- a/src/imv.c
+++ b/src/imv.c
@@ -22,6 +22,11 @@
#include "viewport.h"
#include "util.h"
+/* Some systems like GNU/Hurd don't define PATH_MAX */
+#ifndef PATH_MAX
+#define PATH_MAX 4096
+#endif
+
enum scaling_mode {
SCALING_NONE,
SCALING_DOWN,
diff --git a/src/loader.c b/src/loader.c
index f8876dd..51291bf 100644
--- a/src/loader.c
+++ b/src/loader.c
@@ -8,6 +8,11 @@
#include <SDL2/SDL.h>
#include <FreeImage.h>
+/* Some systems like GNU/Hurd don't define PATH_MAX */
+#ifndef PATH_MAX
+#define PATH_MAX 4096
+#endif
+
static void block_usr1_signal(void);
static int is_thread_cancelled(void);
static void *bg_new_img(void *data);
diff --git a/src/navigator.c b/src/navigator.c
index 6fa884b..e100224 100644
--- a/src/navigator.c
+++ b/src/navigator.c
@@ -8,6 +8,11 @@
#include <stdio.h>
#include <time.h>
+/* Some systems like GNU/Hurd don't define PATH_MAX */
+#ifndef PATH_MAX
+#define PATH_MAX 4096
+#endif
+
struct imv_navigator {
int num_paths;
int cur_path;