Permalink
Browse files

Merge pull request #7 from danc86/master

Build cleanups for Xfce
  • Loading branch information...
2 parents e6c1d0d + 4d521eb commit dbe208f46e8e991d273e123d50bb46d4d98914d9 @alexkay committed Jul 6, 2012
View
@@ -1,4 +1,5 @@
-libexec_PROGRAMS = xmonad-log-applet
+plugindir = $(PLUGIN_DIR)
+plugin_PROGRAMS = xmonad-log-applet
xmonad_log_applet_SOURCES = main.c
@@ -16,20 +17,20 @@ appletdir = $(LIBPANEL_APPLET_DIR)
if PANEL_XFCE4
applet_files = xmonad-log-applet.desktop
$(applet_files): $(applet_files:.desktop=.desktop.in)
- $(SED) -e "s|\@LIBEXECDIR\@|$(libexecdir)|" $< > $@
+ $(SED) -e "s|\@PLUGIN_DIR\@|$(PLUGIN_DIR)|" $< > $@
else
applet_files = org.gnome.panel.XmonadLogApplet.panel-applet
$(applet_files): $(applet_files:.panel-applet=.panel-applet.in)
- $(SED) -e "s|\@LIBEXECDIR\@|$(libexecdir)|" $< > $@
+ $(SED) -e "s|\@PLUGIN_DIR\@|$(PLUGIN_DIR)|" $< > $@
endif
applet_DATA = $(applet_files)
+if !PANEL_XFCE4
servicedir = $(SESSION_BUS_SERVICES_DIR)
service_in_files = org.gnome.panel.applet.XmonadLogAppletFactory.service.in
-if !PANEL_XFCE4
service_DATA = $(service_in_files:.service.in=.service)
org.gnome.panel.applet.XmonadLogAppletFactory.service: $(service_in_files)
- $(SED) -e "s|\@LIBEXECDIR\@|$(libexecdir)|" $< > $@
+ $(SED) -e "s|\@PLUGIN_DIR\@|$(PLUGIN_DIR)|" $< > $@
endif
DISTCLEANFILES = \
View
@@ -28,21 +28,25 @@ AS_IF(
[test "x$panel" = xgnome2],
[PKG_CHECK_MODULES(LIBPANEL, libpanelapplet-3.0 >= 2.32.0)]
LIBPANEL_APPLET_DIR=`$PKG_CONFIG --variable=prefix libpanelapplet-3.0`/share/gnome-panel/applets
+ PLUGIN_DIR=`$PKG_CONFIG --variable=prefix libpanelapplet-3.0`/libexec
[AC_DEFINE(PANEL_GNOME2, 1, [panel version])]
,
[test "x$panel" = xgnome3],
[PKG_CHECK_MODULES(LIBPANEL, libpanelapplet-4.0 >= 3.0.0)]
LIBPANEL_APPLET_DIR=`$PKG_CONFIG --variable=libpanel_applet_dir libpanelapplet-4.0`
+ PLUGIN_DIR=`$PKG_CONFIG --variable=prefix libpanelapplet-4.0`/libexec
[AC_DEFINE(PANEL_GNOME3, 1, [panel version])]
,
[test "x$panel" = xxfce4],
[PKG_CHECK_MODULES(LIBPANEL, libxfce4panel-1.0 >= 4.6.0)]
LIBPANEL_APPLET_DIR=`$PKG_CONFIG --variable=prefix libxfce4panel-1.0`/share/xfce4/panel-plugins
+ PLUGIN_DIR=`$PKG_CONFIG --variable=libdir libxfce4panel-1.0`/xfce4/panel/plugins
[AC_DEFINE(PANEL_XFCE4, 1, [panel version])]
,
[AC_MSG_ERROR([Unknown panel type, use gnome2, gnome3 or xfce4])]
)
AC_SUBST([LIBPANEL_APPLET_DIR])
+AC_SUBST([PLUGIN_DIR])
AM_CONDITIONAL([PANEL_GNOME2], [test "x$panel" = xgnome2])
AM_CONDITIONAL([PANEL_GNOME3], [test "x$panel" = xgnome3])
@@ -1,6 +1,6 @@
[Applet Factory]
Id=XmonadLogAppletFactory
-Location=@LIBEXECDIR@/xmonad-log-applet
+Location=@PLUGIN_DIR@/xmonad-log-applet
Name=Xmonad Log Factory
Description=Factory for the xmonad-log-applet
@@ -1,3 +1,3 @@
[D-BUS Service]
Name=org.gnome.panel.applet.XmonadLogAppletFactory
-Exec=@LIBEXECDIR@/xmonad-log-applet
+Exec=@PLUGIN_DIR@/xmonad-log-applet
@@ -3,6 +3,6 @@ Type=X-XFCE-PanelPlugin
Name=Xmonad Log Applet
Comment=Monitor your Xmonad log
Icon=xmonad-log-applet
-X-XFCE-Exec=@LIBEXECDIR@/xmonad-log-applet
+X-XFCE-Exec=@PLUGIN_DIR@/xmonad-log-applet
X-XFCE-Unique=false
X-XFCE-Internal=false

0 comments on commit dbe208f

Please sign in to comment.