summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVlad Voicu <vladv@rosedu.org>2012-03-05 20:08:54 (GMT)
committervlad <vlad@tyrion.(none)>2012-10-13 13:55:45 (GMT)
commit5427ffbb3ea13cd4ee078dd640db8cd43bab303d (patch)
treecce1ad5ba9fe55a5d77201f620e9904f790d851c /SwifTools
parent5ca749621b991e6a1e10d7a809d0fe1f0680ca74 (diff)
downloadswift-contrib-5427ffbb3ea13cd4ee078dd640db8cd43bab303d.zip
swift-contrib-5427ffbb3ea13cd4ee078dd640db8cd43bab303d.tar.bz2
Added HAVE_HUNSPELL to flags when building
Diffstat (limited to 'SwifTools')
-rw-r--r--SwifTools/SConscript11
-rw-r--r--SwifTools/SpellCheckerFactory.h2
2 files changed, 10 insertions, 3 deletions
diff --git a/SwifTools/SConscript b/SwifTools/SConscript
index d383317..177438a 100644
--- a/SwifTools/SConscript
+++ b/SwifTools/SConscript
@@ -7,8 +7,10 @@ Import("env")
if env["SCONS_STAGE"] == "flags" :
env["SWIFTOOLS_FLAGS"] = {
"LIBPATH": [Dir(".")],
- "LIBS": ["SwifTools", "libhunspell-1.3"]
+ "LIBS": ["SwifTools"]
}
+ if env["HAVE_HUNSPELL"] :
+ env.MergeFlags(env["HUNSPELL_FLAGS"])
################################################################################
# Build
@@ -29,11 +31,18 @@ if env["SCONS_STAGE"] == "build" :
"Linkify.cpp",
"TabComplete.cpp",
"LastLineTracker.cpp",
+ ]
+
+ if swiftools_env["HAVE_HUNSPELL"] :
+ swiftools_env.MergeFlags(swiftools_env["HUNSPELL_FLAGS"])
+ swiftools_env.Append(CPPDEFINES = ["HAVE_HUNSPELL"])
+ sources += [
"SpellCheckerFactory.cpp",
"HunspellChecker.cpp",
"SpellParser.cpp",
]
+
if swiftools_env.get("HAVE_SPARKLE", 0) :
swiftools_env.MergeFlags(swiftools_env["SPARKLE_FLAGS"])
swiftools_env.Append(CPPDEFINES = ["HAVE_SPARKLE"])
diff --git a/SwifTools/SpellCheckerFactory.h b/SwifTools/SpellCheckerFactory.h
index 85aa8b6..d58a9ec 100644
--- a/SwifTools/SpellCheckerFactory.h
+++ b/SwifTools/SpellCheckerFactory.h
@@ -6,8 +6,6 @@
#pragma once
-#define HAVE_HUNSPELL
-
namespace Swift {
class SpellChecker;
class SpellCheckerFactory {