summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/loadlib_rel.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/loadlib_rel.c b/src/loadlib_rel.c
index 8f5820b..cc21a3d 100644
--- a/src/loadlib_rel.c
+++ b/src/loadlib_rel.c
@@ -55,6 +55,9 @@ static void setprogdir (lua_State *L);
#else
#define _PATH_MAX PATH_MAX
#endif
+#if defined(__linux__)
+ #include <unistd.h> /* readlink */
+#endif
static void setprogdir (lua_State *L) {
char progdir[_PATH_MAX + 1];