From 1fe690d691fd4263caac21583eb2ee3a4923d06a Mon Sep 17 00:00:00 2001 From: Than Ngo Date: Sep 06 2016 14:36:11 +0000 Subject: fix build failure with luajit 2.1 --- diff --git a/cantor-16.08.0-luajit.patch b/cantor-16.08.0-luajit.patch index 892f311..051644f 100644 --- a/cantor-16.08.0-luajit.patch +++ b/cantor-16.08.0-luajit.patch @@ -1,14 +1,47 @@ -diff -up cantor-16.08.0/cmake/FindLuaJIT.cmake.luajit cantor-16.08.0/cmake/FindLuaJIT.cmake ---- cantor-16.08.0/cmake/FindLuaJIT.cmake.luajit 2016-08-09 18:02:32.000000000 -0500 -+++ cantor-16.08.0/cmake/FindLuaJIT.cmake 2016-09-06 09:23:37.525636689 -0500 -@@ -1,6 +1,9 @@ +diff -up cantor-16.08.0/cmake/FindLuaJIT.cmake.than cantor-16.08.0/cmake/FindLuaJIT.cmake +--- cantor-16.08.0/cmake/FindLuaJIT.cmake.than 2016-09-06 16:07:30.539296387 +0200 ++++ cantor-16.08.0/cmake/FindLuaJIT.cmake 2016-09-06 16:08:06.383945859 +0200 +@@ -1,6 +1,6 @@ SET (LuaJIT_FOUND FALSE) SET (LUAJIT_LIBRARY_NAME luajit-5.1) -SET (LUAJIT_INCLUDE_DIRS /usr/include/luajit-2.0 /usr/local/include/luajit-2.0) -+SET (LUAJIT_INCLUDE_DIRS -+ /usr/include/luajit-2.1 /usr/local/include/luajit-2.1 -+ /usr/include/luajit-2.0 /usr/local/include/luajit-2.0 -+ ) ++SET (LUAJIT_INCLUDE_DIRS /usr/include/luajit-2.1 /usr/local/include/luajit-2.1) FIND_PATH (LUAJIT_INCLUDE_DIR lua.h ${LUAJIT_INCLUDE_DIRS} ) FIND_LIBRARY (LUAJIT_LIBRARY NAMES ${LUAJIT_LIBRARY_NAME} PATHS ${CMAKE_LIBRARY_PATH}) +diff -up cantor-16.08.0/src/backends/lua/luaexpression.cpp.than cantor-16.08.0/src/backends/lua/luaexpression.cpp +--- cantor-16.08.0/src/backends/lua/luaexpression.cpp.than 2016-09-06 16:22:52.745555302 +0200 ++++ cantor-16.08.0/src/backends/lua/luaexpression.cpp 2016-09-06 16:23:14.702728153 +0200 +@@ -26,7 +26,7 @@ + #include "imageresult.h" + #include "helpresult.h" + +-#include // need the luajit-2.0 prefix to avoid conflicts with Lua 5.2 ++#include // need the luajit-2.0 prefix to avoid conflicts with Lua 5.2 + + #include + #include +diff -up cantor-16.08.0/src/backends/lua/luahelper.cpp.than cantor-16.08.0/src/backends/lua/luahelper.cpp +--- cantor-16.08.0/src/backends/lua/luahelper.cpp.than 2016-09-06 16:23:45.007586540 +0200 ++++ cantor-16.08.0/src/backends/lua/luahelper.cpp 2016-09-06 16:23:56.292161439 +0200 +@@ -20,7 +20,7 @@ + + #include "luahelper.h" + +-#include // need the luajit-2.0 prefix to avoid conflicts with Lua 5.2 ++#include // need the luajit-2.0 prefix to avoid conflicts with Lua 5.2 + #include + #include + +diff -up cantor-16.08.0/src/backends/lua/luasession.h.than cantor-16.08.0/src/backends/lua/luasession.h +--- cantor-16.08.0/src/backends/lua/luasession.h.than 2016-09-06 16:23:27.272254647 +0200 ++++ cantor-16.08.0/src/backends/lua/luasession.h 2016-09-06 16:23:36.916891324 +0200 +@@ -22,7 +22,7 @@ + #define _LUASESSION_H + + #include "session.h" +-#include // need the luajit-2.0 prefix to avoid conflicts with Lua 5.2 ++#include // need the luajit-2.0 prefix to avoid conflicts with Lua 5.2 + + class LuaExpression; + diff --git a/cantor.spec b/cantor.spec index a0f0c07..f929b2f 100644 --- a/cantor.spec +++ b/cantor.spec @@ -2,7 +2,7 @@ Name: cantor Summary: KDE Frontend to Mathematical Software Version: 16.08.0 -Release: 5%{?dist} +Release: 6%{?dist} License: GPLv2+ URL: https://quickgit.kde.org/?p=%{name}.git @@ -16,7 +16,9 @@ URL: https://quickgit.kde.org/?p=%{name}.git Source0: http://download.kde.org/%{stable}/applications/%{version}/src/%{name}-%{version}.tar.xz ## upstreamable patches +%if 0%{?fedora} > 25 Patch100: cantor-16.08.0-luajit.patch +%endif %global majmin_ver %(echo %{version} | cut -d. -f1,2) BuildRequires: analitza-devel >= %{majmin_ver} @@ -209,6 +211,9 @@ fi %changelog +* Tue Sep 06 2016 Than Ngo - 16.08.0-6 +- fix build failure with luajit 2.1 + * Tue Sep 06 2016 Rex Dieter - 16.08.0-5 - fix luajit-2.1 detection (#1371250)