fidencio - r29862 - in enchant/trunk: . src

From: Fabiano Fid�ncio <fabiano_at_fidencio.org>
Date: Tue Jun 21 2011 - 08:01:26 CEST

Author: fidencio
Date: 2011-06-21 07:55:11 +0200 (Tue, 21 Jun 2011)
New Revision: 29862

Modified:
� enchant/trunk/README
� enchant/trunk/configure.in
� enchant/trunk/src/Makefile.am
Log:
Adding applespell option in build stuffs

� �- Now, applespell is compiled by default when
� �an OS X system is detected

� �- If you want to disable it in your mac,
� �please, use --disable-applespell

� �- Now, at least, it's building. I don't know
� �if it's working, probably we need of more
� �(is there?) tests.

� �- Updating README

� �- Many thanks, Dwayne Bailey, for all
� �support :-). Now, could you help us to test
� �and fix another issues with enchant?

Modified: enchant/trunk/README
===================================================================
--- enchant/trunk/README � � � �2011-06-20 20:02:45 UTC (rev 29861)
+++ enchant/trunk/README � � � �2011-06-21 05:55:11 UTC (rev 29862)
@@ -9,10 +9,11 @@

� �Enchant is meant to provide a generic interface into various existing
�spell checking libaries. These include, but are not limited to:
- � � � * Aspell/Pspell
- � � � * Ispell
- � � � * Hspell
- � � � * Uspell
+ � �* Apple Spell
+ � �* Aspell/Pspell
+ � �* Ispell
+ � �* Hspell
+ � �* Uspell

� �Enchant is also meant to be used in a cross-platform (XP) environment. Part
�of this means that Enchant wants to limit its number of external dependencies

Modified: enchant/trunk/configure.in
===================================================================
--- enchant/trunk/configure.in �2011-06-20 20:02:45 UTC (rev 29861)
+++ enchant/trunk/configure.in �2011-06-21 05:55:11 UTC (rev 29862)
@@ -32,6 +32,7 @@
�AC_ISC_POSIX
�AC_PROG_CC
�AC_PROG_CPP
+AC_PROG_OBJC
�AC_PROG_INSTALL
�AC_PROG_LN_S
�AC_PROG_MAKE_SET
@@ -198,6 +199,18 @@
�AM_CONDITIONAL(OS_WIN32, test "x$native_win32" = "xyes")
�AC_SUBST([ENCHANT_WIN32_RESOURCE])

+AC_MSG_CHECKING([for OS X])
+case ${host_os} in
+ � �*darwin*)
+ � �check_applespell=yes
+ � �;;
+ � �*)
+ � �check_applespell=no
+ � �;;
+esac
+AC_MSG_RESULT([$check_applespell])
+AM_CONDITIONAL(WITH_APPLESPELL, test "x$check_applespell" = "xyes")
+
�AC_SUBST(SOCKET_LIBS)

�# Courtesy of Glib: Ensure MSVC-compatible struct packing convention
@@ -485,6 +498,27 @@

�zemberek_dir=${datadir}/enchant/zemberek

+build_applespell=no
+
+APPLESPELL_CFLAGS=""
+APPLESPELL_LIBS=""
+APPLESPELL_LDFLAGS=""
+
+AC_ARG_ENABLE(applespell,
AS_HELP_STRING([--disable-applespell],[enable the applespell backend
@<:@default=auto@:>@]), check_applespell="$enableval",
check_applespell=yes)
+
+if test "x$check_applespell" != "xno"; then
+ � APPLESPELL_CFLAGS+=" -DXP_TARGET_COCOA -xobjective-c"
+ � APPLESPELL_LIBS+=" -lobjc"
+ � APPLESPELL_LDFLAGS+=" -framework Cocoa"
+ � build_applespell=yes
+fi
+
+AC_SUBST(APPLESPELL_CFLAGS)
+AC_SUBST(APPLESPELL_LIBS)
+AC_SUBST(APPLESPELL_LDFLAGS)
+
+AM_CONDITIONAL(WITH_APPLESPELL, test "$build_applespell" = yes)
+
�dnl =======================================================================================

�AC_OUTPUT([
@@ -529,6 +563,7 @@
� � � �Build Myspell/Hunspell backend: ${build_myspell}
� � � �Build Voikko backend: � � � � � ${build_voikko}
� � � �Build Zemberek backend: � � � � ${build_zemberek}
+ � � � Build Apple Spell backend: � � �${build_applespell}
� � � �Build a relocatable library: � �${relocatable_library}"

�if test "x$build_zemberek" = "xyes"; then

Modified: enchant/trunk/src/Makefile.am
===================================================================
--- enchant/trunk/src/Makefile.am � � � 2011-06-20 20:02:45 UTC (rev 29861)
+++ enchant/trunk/src/Makefile.am � � � 2011-06-21 05:55:11 UTC (rev 29862)
@@ -1,12 +1,12 @@
�SUBDIRS=. aspell ispell uspell myspell hspell applespell voikko zemberek

-INCLUDES=-I$(top_srcdir) $(ENCHANT_CFLAGS) $(CC_WARN_CFLAGS)
-DENCHANT_GLOBAL_MODULE_DIR=\"$(libdir)/enchant\"
-DENCHANT_GLOBAL_ORDERING=\"$(datadir)/enchant\" -D_ENCHANT_BUILD=1
-DENCHANT_VERSION_STRING=\"@ENCHANT_MAJOR_VERSION@.@ENCHANT_MINOR_VERSION@.@ENCHANT_MICRO_VERSION@\"
+INCLUDES=-I$(top_srcdir) $(ENCHANT_CFLAGS) $(CC_WARN_CFLAGS)
-DENCHANT_GLOBAL_MODULE_DIR=\"$(libdir)/enchant\"
-DENCHANT_GLOBAL_ORDERING=\"$(datadir)/enchant\" -D_ENCHANT_BUILD=1
-DENCHANT_VERSION_STRING=\"@ENCHANT_MAJOR_VERSION@.@ENCHANT_MINOR_VERSION@.@ENCHANT_MICRO_VERSION@\"
@APPLESPELL_CFLAGS@

�lib_LTLIBRARIES = libenchant.la

-libenchant_la_LIBADD= $(ENCHANT_LIBS) @ENCHANT_WIN32_RESOURCE@
+libenchant_la_LIBADD= $(ENCHANT_LIBS) @ENCHANT_WIN32_RESOURCE@
@APPLESPELL_LIBS@

-libenchant_la_LDFLAGS = -no-undefined -export-dynamic
+libenchant_la_LDFLAGS = -no-undefined -export-dynamic @APPLESPELL_LDFLAGS@
�if OS_WIN32
�libenchant_la_LDFLAGS += -avoid-version
�else
@@ -15,9 +15,15 @@

�libenchant_la_DEPENDENCIES = @ENCHANT_WIN32_RESOURCE@
�libenchant_la_SOURCES = prefix.c enchant.c pwl.c enchant.h prefix.h pwl.h
+if WITH_APPLESPELL
+libenchant_la_SOURCES += enchant_cocoa.m enchant_cocoa.h
+endif

�libenchant_includedir = $(includedir)/enchant
�libenchant_include_HEADERS = enchant.h enchant-provider.h enchant++.h
+if WITH_APPLESPELL
+libenchant_include_HEADERS += enchant_cocoa.h
+endif

�EXTRA_DIST=enchant.i

-- 
Fabiano Fid�ncio
Received on Tue Jun 21 08:01:38 2011

This archive was generated by hypermail 2.1.8 : Tue Jun 21 2011 - 08:01:39 CEST