Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for enchant2 #64

Open
vp1981 opened this issue Jul 1, 2020 · 1 comment
Open

Add support for enchant2 #64

vp1981 opened this issue Jul 1, 2020 · 1 comment

Comments

@vp1981
Copy link

vp1981 commented Jul 1, 2020

Hello,
patch below adds support for enchant2 (change in location of header files).

From ed5d23b31271b1b418fa137f60e063770c2028c4 Mon Sep 17 00:00:00 2001
From: Vladimir Lomov <vladimir@node2-smoon7.bkoty.ru>
Date: Wed, 1 Jul 2020 11:35:32 +0800
Subject: [PATCH 2/3] xneur: adapted code for enchant2

Signed-off-by: Vladimir Lomov <vladimir@node2-smoon7.bkoty.ru>
---
 xneur/lib/lib/CMakeLists.txt | 4 ++--
 xneur/lib/lib/xneur.h        | 2 +-
 xneur/lib/lib/xneurlib.c     | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/xneur/lib/lib/CMakeLists.txt b/xneur/lib/lib/CMakeLists.txt
index 2d14ccd..20f3828 100644
--- a/xneur/lib/lib/CMakeLists.txt
+++ b/xneur/lib/lib/CMakeLists.txt
@@ -5,7 +5,7 @@ include_directories(../main)
 include_directories(../misc)
 include_directories(../notify)
 include_directories(/usr/include/X11)
-include_directories(/usr/include/enchant)
+include_directories(/usr/include/enchant-2)
 
 set(xneur_SRCS
 	xneurlib.c 
@@ -73,7 +73,7 @@ if(SPELL)
 	# Should we handle case when both enabled?
 	if("${SPELL}" STREQUAL "enchant")
 		find_package(PkgConfig)
-		pkg_check_modules(ENCHANT REQUIRED enchant>=1.0)
+		pkg_check_modules(ENCHANT REQUIRED enchant-2>=2.0)
 		include_directories(${ENCHANT_INCLUDE_DIRS})
 		target_compile_definitions(xnlib PRIVATE WITH_ENCHANT=1)
 	elseif("${SPELL}" STREQUAL "aspell")
diff --git a/xneur/lib/lib/xneur.h b/xneur/lib/lib/xneur.h
index 4a63919..b249f7c 100644
--- a/xneur/lib/lib/xneur.h
+++ b/xneur/lib/lib/xneur.h
@@ -29,7 +29,7 @@
 #endif
 
 #ifdef WITH_ENCHANT
-#	include <enchant/enchant.h>
+#	include <enchant-2/enchant.h>
 #endif
 
 struct _window *main_window;
diff --git a/xneur/lib/lib/xneurlib.c b/xneur/lib/lib/xneurlib.c
index 5bf7c0e..f49d424 100644
--- a/xneur/lib/lib/xneurlib.c
+++ b/xneur/lib/lib/xneurlib.c
@@ -30,7 +30,7 @@
 #endif
 
 #ifdef WITH_ENCHANT
-#	include <enchant/enchant.h>
+#	include <enchant-2/enchant.h>
 #endif
 
 #include "xneur.h"
-- 
2.27.0
@gerasiov
Copy link
Contributor

gerasiov commented Jan 9, 2021

#80

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants