[Pommed-commits] r391 - in trunk: . client-common gpomme wmpomme
jblache at alioth.debian.org
jblache at alioth.debian.org
Tue Nov 27 13:33:21 UTC 2007
Author: jblache
Date: 2007-11-27 13:33:20 +0000 (Tue, 27 Nov 2007)
New Revision: 391
Added:
trunk/client-common/
trunk/client-common/dbus-client.c
trunk/client-common/dbus-client.h
Removed:
trunk/client-common/dbus-client.c
trunk/client-common/dbus-client.h
trunk/dbus-client/
Modified:
trunk/gpomme/Makefile
trunk/gpomme/gpomme.c
trunk/wmpomme/Makefile
trunk/wmpomme/wmpomme.c
Log:
Hold common frontend code into client-common/ (rename dbus-client/).
Copied: trunk/client-common (from rev 379, trunk/dbus-client)
Deleted: trunk/client-common/dbus-client.c
===================================================================
--- trunk/dbus-client/dbus-client.c 2007-11-17 09:50:54 UTC (rev 379)
+++ trunk/client-common/dbus-client.c 2007-11-27 13:33:20 UTC (rev 391)
@@ -1,363 +0,0 @@
-/*
- * dbus-client.c -- shared DBus client routines for pommed clients
- *
- * $Id$
- *
- * Copyright (C) 2006-2007 Julien BLACHE <jb at jblache.org>
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
- */
-
-
-#include <stdio.h>
-
-#include <dbus/dbus.h>
-
-#include "dbus-client.h"
-
-
-static DBusError *err;
-static DBusConnection *conn;
-
-
-/* Method calls */
-/* WARNING: method calls are synchronous for now with a 250ms timeout */
-int
-mbp_call_lcd_getlevel(DBusPendingCallNotifyFunction cb, void *userdata)
-{
- DBusMessage *msg;
- DBusPendingCall *pending;
-
- int ret;
-
- msg = dbus_message_new_method_call("org.pommed", "/org/pommed/lcdBacklight",
- "org.pommed.lcdBacklight", "getLevel");
-
- if (msg == NULL)
- {
- printf("Failed to create method call message\n");
-
- return -1;
- }
-
- ret = dbus_connection_send_with_reply(conn, msg, &pending, 250);
- if (ret == FALSE)
- {
- printf("Could not send method call\n");
-
- dbus_message_unref(msg);
-
- return -1;
- }
-
- dbus_connection_flush(conn);
-
- dbus_message_unref(msg);
-
- dbus_pending_call_block(pending);
-
- cb(pending, userdata);
-
- return 0;
-}
-
-int
-mbp_call_kbd_getlevel(DBusPendingCallNotifyFunction cb, void *userdata)
-{
- DBusMessage *msg;
- DBusPendingCall *pending;
-
- int ret;
-
- msg = dbus_message_new_method_call("org.pommed", "/org/pommed/kbdBacklight",
- "org.pommed.kbdBacklight", "getLevel");
-
- if (msg == NULL)
- {
- printf("Failed to create method call message\n");
-
- return -1;
- }
-
- ret = dbus_connection_send_with_reply(conn, msg, &pending, 250);
- if (ret == FALSE)
- {
- printf("Could not send method call\n");
-
- dbus_message_unref(msg);
-
- return -1;
- }
-
- dbus_connection_flush(conn);
-
- dbus_message_unref(msg);
-
- dbus_pending_call_block(pending);
-
- cb(pending, userdata);
-
- return 0;
-}
-
-int
-mbp_call_ambient_getlevel(DBusPendingCallNotifyFunction cb, void *userdata)
-{
- DBusMessage *msg;
- DBusPendingCall *pending;
-
- int ret;
-
- msg = dbus_message_new_method_call("org.pommed", "/org/pommed/ambient",
- "org.pommed.ambient", "getLevel");
-
- if (msg == NULL)
- {
- printf("Failed to create method call message\n");
-
- return -1;
- }
-
- ret = dbus_connection_send_with_reply(conn, msg, &pending, 250);
- if (ret == FALSE)
- {
- printf("Could not send method call\n");
-
- dbus_message_unref(msg);
-
- return -1;
- }
-
-#if 0 /* Needs more work, using dispatch & stuff */
- ret = dbus_pending_call_set_notify(pending, cb, NULL, NULL);
- if (!ret)
- {
- printf("Failed to set callback\n");
-
- dbus_pending_call_unref(pending);
-
- return -1;
- }
-#endif /* 0 */
-
- dbus_connection_flush(conn);
-
- dbus_message_unref(msg);
-
- dbus_pending_call_block(pending);
-
- cb(pending, userdata);
-
- return 0;
-}
-
-int
-mbp_call_audio_getvolume(DBusPendingCallNotifyFunction cb, void *userdata)
-{
- DBusMessage *msg;
- DBusPendingCall *pending;
-
- int ret;
-
- msg = dbus_message_new_method_call("org.pommed", "/org/pommed/audio",
- "org.pommed.audio", "getVolume");
-
- if (msg == NULL)
- {
- printf("Failed to create method call message\n");
-
- return -1;
- }
-
- ret = dbus_connection_send_with_reply(conn, msg, &pending, 250);
- if (ret == FALSE)
- {
- printf("Could not send method call\n");
-
- dbus_message_unref(msg);
-
- return -1;
- }
-
- dbus_connection_flush(conn);
-
- dbus_message_unref(msg);
-
- dbus_pending_call_block(pending);
-
- cb(pending, userdata);
-
- return 0;
-}
-
-int
-mbp_call_audio_getmute(DBusPendingCallNotifyFunction cb, void *userdata)
-{
- DBusMessage *msg;
- DBusPendingCall *pending;
-
- int ret;
-
- msg = dbus_message_new_method_call("org.pommed", "/org/pommed/audio",
- "org.pommed.audio", "getMute");
-
- if (msg == NULL)
- {
- printf("Failed to create method call message\n");
-
- return -1;
- }
-
- ret = dbus_connection_send_with_reply(conn, msg, &pending, 250);
- if (ret == FALSE)
- {
- printf("Could not send method call\n");
-
- dbus_message_unref(msg);
-
- return -1;
- }
-
- dbus_connection_flush(conn);
-
- dbus_message_unref(msg);
-
- dbus_pending_call_block(pending);
-
- cb(pending, userdata);
-
- return 0;
-}
-
-
-/* Error checking, mainly for replies to method calls */
-
-int
-mbp_dbus_check_error(DBusMessage *msg)
-{
- DBusMessageIter iter;
-
- char *errmsg;
-
- if (dbus_message_get_type(msg) == DBUS_MESSAGE_TYPE_ERROR)
- {
- dbus_message_iter_init(msg, &iter);
- dbus_message_iter_get_basic(&iter, &errmsg);
-
- printf("DBus error: %s\n", errmsg);
-
- return 1;
- }
-
- return 0;
-}
-
-
-/* Connection init and cleanup */
-
-static int
-bus_add_match(DBusConnection *conn, char *match)
-{
- dbus_bus_add_match(conn, match, err);
- dbus_connection_flush(conn);
-
- if (dbus_error_is_set(err))
- {
- printf("Match error: %s\n", err->message);
-
- return -1;
- }
-
- return 0;
-}
-
-
-void
-mbp_dbus_cleanup(void)
-{
- if (conn != NULL)
- {
- dbus_error_free(err);
- dbus_connection_unref(conn);
-
- conn = NULL;
- }
-}
-
-
-DBusConnection *
-mbp_dbus_init(DBusError *error, unsigned int signals)
-{
- err = error;
-
- dbus_error_init(err);
-
- conn = dbus_bus_get(DBUS_BUS_SYSTEM, err);
- if (dbus_error_is_set(err))
- {
- printf("DBus system bus connection failed: %s\n", err->message);
-
- dbus_error_free(err);
-
- conn = NULL;
-
- return NULL;
- }
-
- dbus_connection_set_exit_on_disconnect(conn, FALSE);
-
- if ((signals & MBP_DBUS_SIG_LCD)
- && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/lcdBacklight',interface='org.pommed.signal.lcdBacklight'") < 0))
- {
- mbp_dbus_cleanup();
- return NULL;
- }
-
- if ((signals & MBP_DBUS_SIG_KBD)
- && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/kbdBacklight',interface='org.pommed.signal.kbdBacklight'") < 0))
- {
- mbp_dbus_cleanup();
- return NULL;
- }
-
- if ((signals & MBP_DBUS_SIG_VOL)
- && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/audioVolume',interface='org.pommed.signal.audioVolume'") < 0))
- {
- mbp_dbus_cleanup();
- return NULL;
- }
-
- if ((signals & MBP_DBUS_SIG_MUTE)
- && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/audioMute',interface='org.pommed.signal.audioMute'") < 0))
- {
- mbp_dbus_cleanup();
- return NULL;
- }
-
- if ((signals & MBP_DBUS_SIG_LIGHT)
- && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/ambientLight',interface='org.pommed.signal.ambientLight'") < 0))
- {
- mbp_dbus_cleanup();
- return NULL;
- }
-
- if ((signals & MBP_DBUS_SIG_EJECT)
- && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/cdEject',interface='org.pommed.signal.cdEject'") < 0))
- {
- mbp_dbus_cleanup();
- return NULL;
- }
-
- return conn;
-}
Copied: trunk/client-common/dbus-client.c (from rev 390, trunk/dbus-client/dbus-client.c)
===================================================================
--- trunk/client-common/dbus-client.c (rev 0)
+++ trunk/client-common/dbus-client.c 2007-11-27 13:33:20 UTC (rev 391)
@@ -0,0 +1,370 @@
+/*
+ * dbus-client.c -- shared DBus client routines for pommed clients
+ *
+ * $Id$
+ *
+ * Copyright (C) 2006-2007 Julien BLACHE <jb at jblache.org>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+
+#include <stdio.h>
+
+#include <dbus/dbus.h>
+
+#include "dbus-client.h"
+
+
+static DBusError *err;
+static DBusConnection *conn;
+
+
+/* Method calls */
+/* WARNING: method calls are synchronous for now with a 250ms timeout */
+int
+mbp_call_lcd_getlevel(DBusPendingCallNotifyFunction cb, void *userdata)
+{
+ DBusMessage *msg;
+ DBusPendingCall *pending;
+
+ int ret;
+
+ msg = dbus_message_new_method_call("org.pommed", "/org/pommed/lcdBacklight",
+ "org.pommed.lcdBacklight", "getLevel");
+
+ if (msg == NULL)
+ {
+ printf("Failed to create method call message\n");
+
+ return -1;
+ }
+
+ ret = dbus_connection_send_with_reply(conn, msg, &pending, 250);
+ if (ret == FALSE)
+ {
+ printf("Could not send method call\n");
+
+ dbus_message_unref(msg);
+
+ return -1;
+ }
+
+ dbus_connection_flush(conn);
+
+ dbus_message_unref(msg);
+
+ dbus_pending_call_block(pending);
+
+ cb(pending, userdata);
+
+ return 0;
+}
+
+int
+mbp_call_kbd_getlevel(DBusPendingCallNotifyFunction cb, void *userdata)
+{
+ DBusMessage *msg;
+ DBusPendingCall *pending;
+
+ int ret;
+
+ msg = dbus_message_new_method_call("org.pommed", "/org/pommed/kbdBacklight",
+ "org.pommed.kbdBacklight", "getLevel");
+
+ if (msg == NULL)
+ {
+ printf("Failed to create method call message\n");
+
+ return -1;
+ }
+
+ ret = dbus_connection_send_with_reply(conn, msg, &pending, 250);
+ if (ret == FALSE)
+ {
+ printf("Could not send method call\n");
+
+ dbus_message_unref(msg);
+
+ return -1;
+ }
+
+ dbus_connection_flush(conn);
+
+ dbus_message_unref(msg);
+
+ dbus_pending_call_block(pending);
+
+ cb(pending, userdata);
+
+ return 0;
+}
+
+int
+mbp_call_ambient_getlevel(DBusPendingCallNotifyFunction cb, void *userdata)
+{
+ DBusMessage *msg;
+ DBusPendingCall *pending;
+
+ int ret;
+
+ msg = dbus_message_new_method_call("org.pommed", "/org/pommed/ambient",
+ "org.pommed.ambient", "getLevel");
+
+ if (msg == NULL)
+ {
+ printf("Failed to create method call message\n");
+
+ return -1;
+ }
+
+ ret = dbus_connection_send_with_reply(conn, msg, &pending, 250);
+ if (ret == FALSE)
+ {
+ printf("Could not send method call\n");
+
+ dbus_message_unref(msg);
+
+ return -1;
+ }
+
+#if 0 /* Needs more work, using dispatch & stuff */
+ ret = dbus_pending_call_set_notify(pending, cb, NULL, NULL);
+ if (!ret)
+ {
+ printf("Failed to set callback\n");
+
+ dbus_pending_call_unref(pending);
+
+ return -1;
+ }
+#endif /* 0 */
+
+ dbus_connection_flush(conn);
+
+ dbus_message_unref(msg);
+
+ dbus_pending_call_block(pending);
+
+ cb(pending, userdata);
+
+ return 0;
+}
+
+int
+mbp_call_audio_getvolume(DBusPendingCallNotifyFunction cb, void *userdata)
+{
+ DBusMessage *msg;
+ DBusPendingCall *pending;
+
+ int ret;
+
+ msg = dbus_message_new_method_call("org.pommed", "/org/pommed/audio",
+ "org.pommed.audio", "getVolume");
+
+ if (msg == NULL)
+ {
+ printf("Failed to create method call message\n");
+
+ return -1;
+ }
+
+ ret = dbus_connection_send_with_reply(conn, msg, &pending, 250);
+ if (ret == FALSE)
+ {
+ printf("Could not send method call\n");
+
+ dbus_message_unref(msg);
+
+ return -1;
+ }
+
+ dbus_connection_flush(conn);
+
+ dbus_message_unref(msg);
+
+ dbus_pending_call_block(pending);
+
+ cb(pending, userdata);
+
+ return 0;
+}
+
+int
+mbp_call_audio_getmute(DBusPendingCallNotifyFunction cb, void *userdata)
+{
+ DBusMessage *msg;
+ DBusPendingCall *pending;
+
+ int ret;
+
+ msg = dbus_message_new_method_call("org.pommed", "/org/pommed/audio",
+ "org.pommed.audio", "getMute");
+
+ if (msg == NULL)
+ {
+ printf("Failed to create method call message\n");
+
+ return -1;
+ }
+
+ ret = dbus_connection_send_with_reply(conn, msg, &pending, 250);
+ if (ret == FALSE)
+ {
+ printf("Could not send method call\n");
+
+ dbus_message_unref(msg);
+
+ return -1;
+ }
+
+ dbus_connection_flush(conn);
+
+ dbus_message_unref(msg);
+
+ dbus_pending_call_block(pending);
+
+ cb(pending, userdata);
+
+ return 0;
+}
+
+
+/* Error checking, mainly for replies to method calls */
+
+int
+mbp_dbus_check_error(DBusMessage *msg)
+{
+ DBusMessageIter iter;
+
+ char *errmsg;
+
+ if (dbus_message_get_type(msg) == DBUS_MESSAGE_TYPE_ERROR)
+ {
+ dbus_message_iter_init(msg, &iter);
+ dbus_message_iter_get_basic(&iter, &errmsg);
+
+ printf("DBus error: %s\n", errmsg);
+
+ return 1;
+ }
+
+ return 0;
+}
+
+
+/* Connection init and cleanup */
+
+static int
+bus_add_match(DBusConnection *conn, char *match)
+{
+ dbus_bus_add_match(conn, match, err);
+ dbus_connection_flush(conn);
+
+ if (dbus_error_is_set(err))
+ {
+ printf("Match error: %s\n", err->message);
+
+ return -1;
+ }
+
+ return 0;
+}
+
+
+void
+mbp_dbus_cleanup(void)
+{
+ if (conn != NULL)
+ {
+ dbus_error_free(err);
+ dbus_connection_unref(conn);
+
+ conn = NULL;
+ }
+}
+
+
+DBusConnection *
+mbp_dbus_init(DBusError *error, unsigned int signals)
+{
+ err = error;
+
+ dbus_error_init(err);
+
+ conn = dbus_bus_get(DBUS_BUS_SYSTEM, err);
+ if (dbus_error_is_set(err))
+ {
+ printf("DBus system bus connection failed: %s\n", err->message);
+
+ dbus_error_free(err);
+
+ conn = NULL;
+
+ return NULL;
+ }
+
+ dbus_connection_set_exit_on_disconnect(conn, FALSE);
+
+ if ((signals & MBP_DBUS_SIG_LCD)
+ && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/lcdBacklight',interface='org.pommed.signal.lcdBacklight'") < 0))
+ {
+ mbp_dbus_cleanup();
+ return NULL;
+ }
+
+ if ((signals & MBP_DBUS_SIG_KBD)
+ && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/kbdBacklight',interface='org.pommed.signal.kbdBacklight'") < 0))
+ {
+ mbp_dbus_cleanup();
+ return NULL;
+ }
+
+ if ((signals & MBP_DBUS_SIG_VOL)
+ && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/audioVolume',interface='org.pommed.signal.audioVolume'") < 0))
+ {
+ mbp_dbus_cleanup();
+ return NULL;
+ }
+
+ if ((signals & MBP_DBUS_SIG_MUTE)
+ && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/audioMute',interface='org.pommed.signal.audioMute'") < 0))
+ {
+ mbp_dbus_cleanup();
+ return NULL;
+ }
+
+ if ((signals & MBP_DBUS_SIG_LIGHT)
+ && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/ambientLight',interface='org.pommed.signal.ambientLight'") < 0))
+ {
+ mbp_dbus_cleanup();
+ return NULL;
+ }
+
+ if ((signals & MBP_DBUS_SIG_EJECT)
+ && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/cdEject',interface='org.pommed.signal.cdEject'") < 0))
+ {
+ mbp_dbus_cleanup();
+ return NULL;
+ }
+
+ if ((signals & MBP_DBUS_SIG_VIDEO)
+ && (bus_add_match(conn, "type='signal',path='/org/pommed/notify/videoSwitch',interface='org.pommed.signal.videoSwitch'") < 0))
+ {
+ mbp_dbus_cleanup();
+ return NULL;
+ }
+
+ return conn;
+}
Deleted: trunk/client-common/dbus-client.h
===================================================================
--- trunk/dbus-client/dbus-client.h 2007-11-17 09:50:54 UTC (rev 379)
+++ trunk/client-common/dbus-client.h 2007-11-27 13:33:20 UTC (rev 391)
@@ -1,54 +0,0 @@
-/*
- * $Id$
- */
-#ifndef __MBP_DBUS_CLIENT_H__
-#define __MBP_DBUS_CLIENT_H__
-
-/* Signals to listen to */
-#define MBP_DBUS_SIG_NONE 0
-#define MBP_DBUS_SIG_LCD (1 << 0)
-#define MBP_DBUS_SIG_KBD (1 << 1)
-#define MBP_DBUS_SIG_VOL (1 << 2)
-#define MBP_DBUS_SIG_MUTE (1 << 3)
-#define MBP_DBUS_SIG_EJECT (1 << 4)
-#define MBP_DBUS_SIG_LIGHT (1 << 5)
-
-
-#define LCD_USER 0
-#define LCD_AUTO 1
-
-#define KBD_USER 0
-#define KBD_AUTO 1
-
-
-/* Method calls */
-int
-mbp_call_lcd_getlevel(DBusPendingCallNotifyFunction cb, void *userdata);
-
-int
-mbp_call_kbd_getlevel(DBusPendingCallNotifyFunction cb, void *userdata);
-
-int
-mbp_call_ambient_getlevel(DBusPendingCallNotifyFunction cb, void *userdata);
-
-int
-mbp_call_audio_getvolume(DBusPendingCallNotifyFunction cb, void *userdata);
-
-int
-mbp_call_audio_getmute(DBusPendingCallNotifyFunction cb, void *userdata);
-
-
-/* Error checking */
-int
-mbp_dbus_check_error(DBusMessage *msg);
-
-
-/* Connection init and cleanup */
-DBusConnection *
-mbp_dbus_init(DBusError *error, unsigned int signals);
-
-void
-mbp_dbus_cleanup(void);
-
-
-#endif /* !__MBP_DBUS_CLIENT_H__ */
Copied: trunk/client-common/dbus-client.h (from rev 390, trunk/dbus-client/dbus-client.h)
===================================================================
--- trunk/client-common/dbus-client.h (rev 0)
+++ trunk/client-common/dbus-client.h 2007-11-27 13:33:20 UTC (rev 391)
@@ -0,0 +1,55 @@
+/*
+ * $Id$
+ */
+#ifndef __MBP_DBUS_CLIENT_H__
+#define __MBP_DBUS_CLIENT_H__
+
+/* Signals to listen to */
+#define MBP_DBUS_SIG_NONE 0
+#define MBP_DBUS_SIG_LCD (1 << 0)
+#define MBP_DBUS_SIG_KBD (1 << 1)
+#define MBP_DBUS_SIG_VOL (1 << 2)
+#define MBP_DBUS_SIG_MUTE (1 << 3)
+#define MBP_DBUS_SIG_EJECT (1 << 4)
+#define MBP_DBUS_SIG_LIGHT (1 << 5)
+#define MBP_DBUS_SIG_VIDEO (1 << 6)
+
+
+#define LCD_USER 0
+#define LCD_AUTO 1
+
+#define KBD_USER 0
+#define KBD_AUTO 1
+
+
+/* Method calls */
+int
+mbp_call_lcd_getlevel(DBusPendingCallNotifyFunction cb, void *userdata);
+
+int
+mbp_call_kbd_getlevel(DBusPendingCallNotifyFunction cb, void *userdata);
+
+int
+mbp_call_ambient_getlevel(DBusPendingCallNotifyFunction cb, void *userdata);
+
+int
+mbp_call_audio_getvolume(DBusPendingCallNotifyFunction cb, void *userdata);
+
+int
+mbp_call_audio_getmute(DBusPendingCallNotifyFunction cb, void *userdata);
+
+
+/* Error checking */
+int
+mbp_dbus_check_error(DBusMessage *msg);
+
+
+/* Connection init and cleanup */
+DBusConnection *
+mbp_dbus_init(DBusError *error, unsigned int signals);
+
+void
+mbp_dbus_cleanup(void);
+
+
+#endif /* !__MBP_DBUS_CLIENT_H__ */
Modified: trunk/gpomme/Makefile
===================================================================
--- trunk/gpomme/Makefile 2007-11-26 10:37:05 UTC (rev 390)
+++ trunk/gpomme/Makefile 2007-11-27 13:33:20 UTC (rev 391)
@@ -17,7 +17,7 @@
CFLAGS = -g -O2 -Wall $(DBUS_CFLAGS) $(GTK_CFLAGS) $(CONFUSE_CFLAGS) $(GLADE_CFLAGS)
LDFLAGS = -lpthread $(DBUS_LIBS) $(GTK_LIBS) $(CONFUSE_LIBS) $(GLADE_LIBS)
-SOURCES = gpomme.c theme.c conffile.c ../dbus-client/dbus-client.c
+SOURCES = gpomme.c theme.c conffile.c ../client-common/dbus-client.c
POFILES = po/fr.po po/de.po po/es.po po/it.po
OBJS = $(SOURCES:%.c=%.o)
@@ -29,13 +29,13 @@
gpomme: $(OBJS) $(LIBS)
-gpomme.o: gpomme.c gpomme.h theme.h ../dbus-client/dbus-client.h
+gpomme.o: gpomme.c gpomme.h theme.h ../client-common/dbus-client.h
theme.o: theme.c theme.h gpomme.h
conffile.o: conffile.c conffile.h gpomme.h theme.h
-../dbus-client/dbus-client.o: ../dbus-client/dbus-client.c ../dbus-client/dbus-client.h
+../client-common/dbus-client.o: ../client-common/dbus-client.c ../client-common/dbus-client.h
%.mo: %.po
@echo Building $@...
@@ -49,4 +49,4 @@
clean:
rm -f gpomme $(OBJS) $(MOFILES)
- rm -f *~ po/*~ ../dbus-client/*~
+ rm -f *~ po/*~ ../client-common/*~
Modified: trunk/gpomme/gpomme.c
===================================================================
--- trunk/gpomme/gpomme.c 2007-11-26 10:37:05 UTC (rev 390)
+++ trunk/gpomme/gpomme.c 2007-11-27 13:33:20 UTC (rev 391)
@@ -47,7 +47,7 @@
#include "theme.h"
#include "conffile.h"
-#include "../dbus-client/dbus-client.h"
+#include "../client-common/dbus-client.h"
#define _(str) gettext(str)
Modified: trunk/wmpomme/Makefile
===================================================================
--- trunk/wmpomme/Makefile 2007-11-26 10:37:05 UTC (rev 390)
+++ trunk/wmpomme/Makefile 2007-11-27 13:33:20 UTC (rev 391)
@@ -6,18 +6,18 @@
CFLAGS = -g -O2 -Wall $(DBUS_CFLAGS)
LDFLAGS = -lXpm -lXext -lX11 $(DBUS_LIBS)
-SOURCES = wmgeneral.c wmpomme.c ../dbus-client/dbus-client.c
+SOURCES = wmgeneral.c wmpomme.c ../client-common/dbus-client.c
OBJS = $(SOURCES:%.c=%.o)
wmpomme: $(OBJS)
-wmpomme.o: wmpomme.c wmgeneral.h wmpomme-master.xpm ../dbus-client/dbus-client.h
+wmpomme.o: wmpomme.c wmgeneral.h wmpomme-master.xpm ../client-common/dbus-client.h
wmgeneral.o: wmgeneral.c wmgeneral.h
-../dbus-client/dbus-client.o: ../dbus-client/dbus-client.c ../dbus-client/dbus-client.h
+../client-common/dbus-client.o: ../client-common/dbus-client.c ../client-common/dbus-client.h
clean:
rm -f wmpomme $(OBJS)
- rm -f *~ ../dbus-client/*~
+ rm -f *~ ../client-common/*~
Modified: trunk/wmpomme/wmpomme.c
===================================================================
--- trunk/wmpomme/wmpomme.c 2007-11-26 10:37:05 UTC (rev 390)
+++ trunk/wmpomme/wmpomme.c 2007-11-27 13:33:20 UTC (rev 391)
@@ -42,7 +42,7 @@
#include "wmgeneral.h"
#include "wmpomme-master.xpm"
-#include "../dbus-client/dbus-client.h"
+#include "../client-common/dbus-client.h"
struct {
More information about the Pommed-commits
mailing list