Hi,

the current usage of AC_DEFINE for TRACKER_LOCALEDIR is discouraged by
the gnu coding standards..
Read [1] and [2] for more details (in short: it breaks make --prefix=/foo)

The attached patch fixes that. As I used $localedir I had to bump the
autoconf requirement to 2.59 which is no problem though, as all major
distros ship a recent enough version afaik and it is only needed on
the developer machine anyway.

Please review and apply.

Cheers,
Michael

[1] 
http://www.gnu.org/software/autoconf/manual/html_node/Installation-Directory-Variables.html#Installation-Directory-Variables
[2] 
http://www.gnu.org/software/autoconf/manual/html_node/Defining-Directories.html


--
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?
diff --git a/configure.ac b/configure.ac
index ff43cc6..e5434d6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2,7 +2,7 @@
 # Process this file with autoconf to produce a configure script.
 # This file is part of Tracker.
 
-AC_PREREQ(2.57)
+AC_PREREQ(2.59)
 AC_INIT([tracker],[0.6.0],[EMAIL PROTECTED])
 
 AC_CONFIG_SRCDIR([src/trackerd/trackerd.c])
@@ -152,22 +152,6 @@ AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",
 AM_GLIB_GNU_GETTEXT
 IT_PROG_INTLTOOL([0.35.0])
 
-# The following lines replace AM_GLIB_DEFINE_LOCALEDIR(TRACKER_LOCALEDIR)
-# due to the bug with autoconf 2.60
-
-dnl Set TRACKER_LOCALEDIR in config.h.
-if test "x${prefix}" = "xNONE";
-then
-	TRACKER_LOCALEDIR="${ac_default_prefix}/${DATADIRNAME}/locale"
-else
-	TRACKER_LOCALEDIR="${prefix}/${DATADIRNAME}/locale"
-fi
-
-AC_DEFINE_UNQUOTED(TRACKER_LOCALEDIR, "$TRACKER_LOCALEDIR",
-		[The directory in which locale data will be stored])
-
-# end of AM_GLIB_DEFINE_LOCALEDIR(TRACKER_LOCALEDIR) replacement
-
 ####################################################################
 # check for newer glib (>= 2.12.0) for g_option_context_set_summary ()
 # availability
diff --git a/src/libtracker/Makefile.am b/src/libtracker/Makefile.am
index 76f82cd..b3abe92 100644
--- a/src/libtracker/Makefile.am
+++ b/src/libtracker/Makefile.am
@@ -1,5 +1,6 @@
 INCLUDES =				\
 	-DDATADIR=\""$(datadir)"\"	\
+	-DTRACKER_LOCALEDIR=\""$(localedir)"\" \
 	$(GLIB2_CFLAGS)			\
 	$(DBUS_CFLAGS)			
 
diff --git a/src/tracker-search-tool/Makefile.am b/src/tracker-search-tool/Makefile.am
index 6b2599c..753efa4 100644
--- a/src/tracker-search-tool/Makefile.am
+++ b/src/tracker-search-tool/Makefile.am
@@ -12,8 +12,7 @@ INCLUDES = 	\
 	$(GNOMEDESKTOP_CFLAGS)					\
 	$(DBUS_CFLAGS)						\
 	-DG_DISABLE_DEPRECATED					\
-	-DGNOMELOCALEDIR=\""$(prefix)/$(DATADIRNAME)/locale"\" 	\
-	-DLOCALEDIR=\"$(datadir)/locale\"			\
+	-DTRACKER_LOCALEDIR=\""$(localedir)"\"			\
 	-DDATADIR=\""$(datadir)"\"				\
 	-DGREP_COMMAND=\""$(GREP_COMMAND)"\"
 
diff --git a/src/trackerd/Makefile.am b/src/trackerd/Makefile.am
index afbe4f0..84ba9e3 100644
--- a/src/trackerd/Makefile.am
+++ b/src/trackerd/Makefile.am
@@ -1,6 +1,7 @@
 INCLUDES =				\
 	-DDATADIR=\""$(datadir)"\"	\
 	-DLIBDIR=\""$(libdir)"\"	\
+	-DTRACKER_LOCALEDIR=\""$(localdir)"\" \
 	-D_XOPEN_SOURCE_EXTENDED=1	\
 	-D_GNU_SOURCE=1			\
 	-D__EXTENSIONS__=1		\
-- 
1.5.0.3

_______________________________________________
tracker-list mailing list
tracker-list@gnome.org
http://mail.gnome.org/mailman/listinfo/tracker-list

Reply via email to