Skip to content

Instantly share code, notes, and snippets.

@Akaricchi
Created July 23, 2017 10:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Akaricchi/a0b2827ebd7d6feae5b390f951fb36e6 to your computer and use it in GitHub Desktop.
Save Akaricchi/a0b2827ebd7d6feae5b390f951fb36e6 to your computer and use it in GitHub Desktop.
From c9c7670b733627af13f5dbdcaf6c3b3723e2eb3a Mon Sep 17 00:00:00 2001
From: "Andrei \"Akari\" Alexeyev" <akari@alienslab.net>
Date: Sun, 23 Jul 2017 13:29:06 +0300
Subject: [PATCH] Arch Linux build fix
Pick up the correct LuaJIT headers, instead of the default Lua 5.3
headers.
---
CMakeLists.txt | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8d3ece7..0b7ee5c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -7,6 +7,10 @@ FIND_PACKAGE(Torch REQUIRED)
FIND_PACKAGE(CUDA 6.5 REQUIRED)
FIND_PACKAGE(MAGMA)
+FIND_PACKAGE(PkgConfig REQUIRED)
+pkg_check_modules(LUAJIT luajit REQUIRED)
+set(LUA_INCDIR "${LUAJIT_INCLUDE_DIRS}")
+
IF (NOT WIN32)
SET(CMAKE_C_FLAGS "-std=c99 -Werror=implicit-function-declaration ${CMAKE_C_FLAGS}")
ENDIF (NOT WIN32)
--
2.13.3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment