[Xfce4-commits] <thunar-vfs:master> Move helpers to $(libdir)/thunar-vfs-1.

Nick Schermer noreply at xfce.org
Thu Aug 26 21:46:01 CEST 2010


Updating branch refs/heads/master
         to 3a86fb2837565f9ee525d00786747e94e93e9182 (commit)
       from 48d349de6894823254393dc4254dfd41ca478a24 (commit)

commit 3a86fb2837565f9ee525d00786747e94e93e9182
Author: Nick Schermer <nick at xfce.org>
Date:   Thu Aug 26 21:44:30 2010 +0200

    Move helpers to $(libdir)/thunar-vfs-1.
    
    Also link to libm to fix some compiler warnings.

 docs/ThumbnailersCacheFormat.txt                   |    2 +-
 thunar-vfs/Makefile.am                             |   24 ++++++++++++-------
 .../thunar-vfs-font-thumbnailer-1.desktop.in       |    4 +-
 thunar-vfs/thunar-vfs-mime-database.c              |    2 +-
 thunar-vfs/thunar-vfs-thumb.c                      |    2 +-
 thunar-vfs/thunar-vfs-update-thumbnailers-cache.c  |    2 +-
 6 files changed, 21 insertions(+), 15 deletions(-)

diff --git a/docs/ThumbnailersCacheFormat.txt b/docs/ThumbnailersCacheFormat.txt
index e72cecc..598f5f8 100644
--- a/docs/ThumbnailersCacheFormat.txt
+++ b/docs/ThumbnailersCacheFormat.txt
@@ -14,7 +14,7 @@ stay flexible wrt thumbnailers w/o adding more overhead to libthunar-vfs-1.so
 (and thereby to all applications using the library), the available thumbnailers
 for the ThunarVfsThumbFactory are determined by a separate utility program,
 named thunar-vfs-update-thumbnailers-cache-1, which is installed to the 
-$(libexecdir).
+$(libdir)/thunar-vfs-1/ directory.
 
 This program generates a thumbnailers.cache file in the users home directory,
 in $XDG_CACHE_HOME/Thunar/ (usually ~/.cache/Thunar/), which is a binary file
diff --git a/thunar-vfs/Makefile.am b/thunar-vfs/Makefile.am
index 5d22807..a3aeced 100644
--- a/thunar-vfs/Makefile.am
+++ b/thunar-vfs/Makefile.am
@@ -4,7 +4,7 @@ INCLUDES =								\
 	-I$(top_srcdir)							\
 	-DEXO_DISABLE_DEPRECATED					\
 	-DG_LOG_DOMAIN=\"thunar-vfs\"					\
-	-DLIBEXECDIR=\"$(libexecdir)\"					\
+	-DHELPERDIR=\"$(libdir)/thunar-vfs-$(THUNAR_VFS_VERSION_API)\"	\
 	-DPACKAGE_LOCALE_DIR=\"$(localedir)\"				\
 	-DSN_API_NOT_YET_FROZEN						\
 	-DTHUNAR_VFS_COMPILATION					\
@@ -145,7 +145,7 @@ libthunar_vfs_1_la_CFLAGS =						\
 libthunar_vfs_1_la_LDFLAGS =						\
 	-export-dynamic							\
 	-export-symbols-regex "^[^_].*"					\
-	-version-info $(THUNAR_VFS_VERINFO)					\
+	-version-info $(THUNAR_VFS_VERINFO)				\
 	$(PLATFORM_LDFLAGS)
 
 libthunar_vfs_1_la_LIBADD =						\
@@ -154,9 +154,11 @@ libthunar_vfs_1_la_LIBADD =						\
 	$(LIBFAM_LIBS)							\
 	$(LIBJPEG_LIBS)							\
 	$(LIBPNG_LIBS)							\
-	$(LIBSTARTUP_NOTIFICATION_LIBS)
+	$(LIBSTARTUP_NOTIFICATION_LIBS)					\
+	-lm
 
-libexec_PROGRAMS =							\
+thunar_vfs_helperdir = $(libdir)/thunar-vfs-$(THUNAR_VFS_VERSION_API)
+thunar_vfs_helper_PROGRAMS =						\
 	thunar-vfs-mime-cleaner-1					\
 	thunar-vfs-pixbuf-thumbnailer-1					\
 	thunar-vfs-update-thumbnailers-cache-1
@@ -169,7 +171,8 @@ thunar_vfs_mime_cleaner_1_CFLAGS =					\
 	$(PLATFORM_CFLAGS)
 
 thunar_vfs_mime_cleaner_1_LDADD =					\
-	$(LIBXFCE4UTIL_LIBS)
+	$(LIBXFCE4UTIL_LIBS)						\
+	-lm
 
 thunar_vfs_mime_cleaner_1_LDFLAGS =					\
 	-no-undefined							\
@@ -183,7 +186,8 @@ thunar_vfs_pixbuf_thumbnailer_1_CFLAGS =				\
 	$(PLATFORM_CFLAGS)
 
 thunar_vfs_pixbuf_thumbnailer_1_LDADD =					\
-	$(EXO_LIBS)
+	$(EXO_LIBS)							\
+	-lm
 
 thunar_vfs_pixbuf_thumbnailer_1_LDFLAGS =				\
 	-no-undefined							\
@@ -212,7 +216,8 @@ thunar_vfs_update_thumbnailers_cache_1_LDFLAGS =			\
 ## because there's not really a way to make it work w/o freetype.
 ##
 if HAVE_FREETYPE
-libexec_PROGRAMS +=							\
+thunar_vfs_font_thumbnailerdir = $(libdir)/thunar-vfs-$(THUNAR_VFS_VERSION_API)
+thunar_vfs_font_thumbnailer_PROGRAMS =					\
 	thunar-vfs-font-thumbnailer-1
 
 thunar_vfs_font_thumbnailer_1_SOURCES =					\
@@ -225,7 +230,8 @@ thunar_vfs_font_thumbnailer_1_CFLAGS =					\
 
 thunar_vfs_font_thumbnailer_1_LDADD =					\
 	$(FREETYPE_LIBS)						\
-	$(GDK_PIXBUF_LIBS)
+	$(GDK_PIXBUF_LIBS)						\
+	-lm
 
 thunar_vfs_font_thumbnailer_1_LDFLAGS =					\
 	-no-undefined							\
@@ -236,7 +242,7 @@ desktopdir = $(datadir)/thumbnailers
 desktop_in_files = 							\
 	thunar-vfs-font-thumbnailer-1.desktop.in
 %.desktop: %.desktop.in
-	sed -e "s,\@libexecdir\@,$(libexecdir),g" < $< > $@
+	sed -e "s,\@helperdir\@,$(thunar_vfs_font_thumbnailerdir),g" < $< > $@
 desktop_DATA = $(desktop_in_files:.desktop.in=.desktop)
 
 pkgconfigdir = $(libdir)/pkgconfig
diff --git a/thunar-vfs/thunar-vfs-font-thumbnailer-1.desktop.in b/thunar-vfs/thunar-vfs-font-thumbnailer-1.desktop.in
index 7284877..293d40f 100644
--- a/thunar-vfs/thunar-vfs-font-thumbnailer-1.desktop.in
+++ b/thunar-vfs/thunar-vfs-font-thumbnailer-1.desktop.in
@@ -3,8 +3,8 @@ Version=1.0
 Type=X-Thumbnailer
 Name=Thunar Font Thumbnailer
 Comment=Creates thumbnails for font files
-TryExec=@libexecdir@/thunar-vfs-font-thumbnailer-1
+TryExec=@helperdir@/thunar-vfs-font-thumbnailer-1
 MimeType=application/x-font-otf;application/x-font-pcf;application/x-font-ttf;application/x-font-type1;
-X-Thumbnailer-Exec=@libexecdir@/thunar-vfs-font-thumbnailer-1 -i %i -o %o -s %s
+X-Thumbnailer-Exec=@helperdir@/thunar-vfs-font-thumbnailer-1 -i %i -o %o -s %s
 
 # vi:set encoding=UTF-8:
diff --git a/thunar-vfs/thunar-vfs-mime-database.c b/thunar-vfs/thunar-vfs-mime-database.c
index 0e7d3e9..5b2a4e3 100644
--- a/thunar-vfs/thunar-vfs-mime-database.c
+++ b/thunar-vfs/thunar-vfs-mime-database.c
@@ -890,7 +890,7 @@ static gboolean
 thunar_vfs_mime_database_cleanup_timer (gpointer user_data)
 {
   /* invoke thunar-vfs-mime-cleaner */
-  g_spawn_command_line_async (LIBEXECDIR "/thunar-vfs-mime-cleaner-" THUNAR_VFS_VERSION_API, NULL);
+  g_spawn_command_line_async (HELPERDIR G_DIR_SEPARATOR_S "thunar-vfs-mime-cleaner-1", NULL);
 
   /* keep the timer alive */
   return TRUE;
diff --git a/thunar-vfs/thunar-vfs-thumb.c b/thunar-vfs/thunar-vfs-thumb.c
index 2302b6f..25b2c3c 100644
--- a/thunar-vfs/thunar-vfs-thumb.c
+++ b/thunar-vfs/thunar-vfs-thumb.c
@@ -566,7 +566,7 @@ thunar_vfs_thumb_factory_cache_monitor (ThunarVfsMonitor       *monitor,
 static void
 thunar_vfs_thumb_factory_cache_update (ThunarVfsThumbFactory *factory)
 {
-  gchar *argv[2] = { LIBEXECDIR G_DIR_SEPARATOR_S "/thunar-vfs-update-thumbnailers-cache-1", NULL };
+  gchar *argv[2] = { HELPERDIR G_DIR_SEPARATOR_S "thunar-vfs-update-thumbnailers-cache-1", NULL };
   GPid   pid;
 
   _thunar_vfs_return_if_fail (THUNAR_VFS_IS_THUMB_FACTORY (factory));
diff --git a/thunar-vfs/thunar-vfs-update-thumbnailers-cache.c b/thunar-vfs/thunar-vfs-update-thumbnailers-cache.c
index b9ddaa6..a8dec99 100644
--- a/thunar-vfs/thunar-vfs-update-thumbnailers-cache.c
+++ b/thunar-vfs/thunar-vfs-update-thumbnailers-cache.c
@@ -377,7 +377,7 @@ thumbnailers_load_pixbuf (GHashTable *thumbnailers)
       for (n = 0; mime_types[n] != NULL; ++n)
         {
           /* set our thumbnailer for all those mime types */
-          g_hash_table_insert (thumbnailers, mime_types[n], LIBEXECDIR G_DIR_SEPARATOR_S "thunar-vfs-pixbuf-thumbnailer-1 %s %i %o");
+          g_hash_table_insert (thumbnailers, mime_types[n], HELPERDIR G_DIR_SEPARATOR_S "thunar-vfs-pixbuf-thumbnailer-1 %s %i %o");
         }
     }
 }



More information about the Xfce4-commits mailing list