diff options
author | Tor Lillqvist <tml@novell.com> | 2005-08-10 07:29:27 +0800 |
---|---|---|
committer | Tor Lillqvist <tml@src.gnome.org> | 2005-08-10 07:29:27 +0800 |
commit | a40159746efa236f154c57ff57f0fe1cb4ec9e5e (patch) | |
tree | c6d2d602194b54f1c734b1af7748709b630fed6a | |
parent | a43c128c4bfe96ea35225cf1fb551c0cb8c5ac4a (diff) | |
download | gsoc2013-evolution-a40159746efa236f154c57ff57f0fe1cb4ec9e5e.tar gsoc2013-evolution-a40159746efa236f154c57ff57f0fe1cb4ec9e5e.tar.gz gsoc2013-evolution-a40159746efa236f154c57ff57f0fe1cb4ec9e5e.tar.bz2 gsoc2013-evolution-a40159746efa236f154c57ff57f0fe1cb4ec9e5e.tar.lz gsoc2013-evolution-a40159746efa236f154c57ff57f0fe1cb4ec9e5e.tar.xz gsoc2013-evolution-a40159746efa236f154c57ff57f0fe1cb4ec9e5e.tar.zst gsoc2013-evolution-a40159746efa236f154c57ff57f0fe1cb4ec9e5e.zip |
Use privsolib instead of privlib. On Unix they are the same, on Win32
2005-08-10 Tor Lillqvist <tml@novell.com>
* Makefile.am: Use privsolib instead of privlib. On Unix they are
the same, on Win32 privsolibdir is the same as libdir. Use the
macro name EVOLUTION_GLADEDIR as in e-util/e-util-private.h
instead of FILTER_GLADEDIR, so that the Win32 run-time path lookup
mechanism works. Use NO_UNDEFINED. Link explicitly with the actual
libraries used.
* filter-datespec.c: No localtime_r() on Win32, but we can use
plain localtime() which is thread-safe in the Microsoft C library.
* filter-datespec.c
* rule-editor.c: Include e-util-private.h for Win32 path run-time
lookup. Use EVOLUTION_GLADEDIR instead of FILTER_GLADEDIR, and do
the filter.glade pathname construction at run-time so it works
even when EVOLUTION_GLADEDIR is a function call on Win32.
svn path=/trunk/; revision=30063
-rw-r--r-- | filter/ChangeLog | 18 | ||||
-rw-r--r-- | filter/Makefile.am | 11 | ||||
-rw-r--r-- | filter/filter-datespec.c | 11 | ||||
-rw-r--r-- | filter/rule-editor.c | 7 |
4 files changed, 43 insertions, 4 deletions
diff --git a/filter/ChangeLog b/filter/ChangeLog index 75a9efac83..15e441b099 100644 --- a/filter/ChangeLog +++ b/filter/ChangeLog @@ -1,3 +1,21 @@ +2005-08-10 Tor Lillqvist <tml@novell.com> + + * Makefile.am: Use privsolib instead of privlib. On Unix they are + the same, on Win32 privsolibdir is the same as libdir. Use the + macro name EVOLUTION_GLADEDIR as in e-util/e-util-private.h + instead of FILTER_GLADEDIR, so that the Win32 run-time path lookup + mechanism works. Use NO_UNDEFINED. Link explicitly with the actual + libraries used. + + * filter-datespec.c: No localtime_r() on Win32, but we can use + plain localtime() which is thread-safe in the Microsoft C library. + + * filter-datespec.c + * rule-editor.c: Include e-util-private.h for Win32 path run-time + lookup. Use EVOLUTION_GLADEDIR instead of FILTER_GLADEDIR, and do + the filter.glade pathname construction at run-time so it works + even when EVOLUTION_GLADEDIR is a function call on Win32. + 2005-05-16 Not Zed <NotZed@Ximian.com> * moved e-error to e-util diff --git a/filter/Makefile.am b/filter/Makefile.am index 8c287ee637..72cebb002a 100644 --- a/filter/Makefile.am +++ b/filter/Makefile.am @@ -5,11 +5,11 @@ INCLUDES = \ -I $(top_srcdir) \ -I $(top_srcdir)/e-util \ -I $(top_srcdir)/widgets/misc \ - -DFILTER_GLADEDIR=\"$(gladedir)\" \ + -DEVOLUTION_GLADEDIR=\"$(gladedir)\" \ -DG_LOG_DOMAIN=\"filter\" \ $(LIBFILTER_CFLAGS) -privlib_LTLIBRARIES = \ +privsolib_LTLIBRARIES = \ libfilter.la libfilter_la_SOURCES = \ @@ -42,6 +42,13 @@ libfilter_la_SOURCES = \ rule-editor.c \ rule-editor.h +libfilter_la_LDFLAGS = $(NO_UNDEFINED) + +libfilter_la_LIBADD = \ + $(top_builddir)/e-util/libeutil.la \ + $(LIBFILTER_LIBS) \ + $(REGEX_LIBS) + EXTRA_DIST = \ $(glade_DATA) \ filter.error.xml \ diff --git a/filter/filter-datespec.c b/filter/filter-datespec.c index 1dbd357c04..0e7ecc43f7 100644 --- a/filter/filter-datespec.c +++ b/filter/filter-datespec.c @@ -36,6 +36,11 @@ #include "filter-datespec.h" #include "libedataserver/e-sexp.h" #include "e-util/e-error.h" +#include "e-util/e-util-private.h" + +#ifdef G_OS_WIN32 +#define localtime_r(tp,tmp) memcpy(tmp,localtime(tp),sizeof(struct tm)) +#endif #define d(x) @@ -398,8 +403,12 @@ button_clicked (GtkButton *button, FilterDatespec *fds) GtkWidget *toplevel; GtkDialog *dialog; GladeXML *gui; + char *filter_glade = g_build_filename (EVOLUTION_GLADEDIR, + "filter.glade", + NULL); - gui = glade_xml_new (FILTER_GLADEDIR "/filter.glade", "filter_datespec", NULL); + gui = glade_xml_new (filter_glade, "filter_datespec", NULL); + g_free (filter_glade); toplevel = glade_xml_get_widget (gui, "filter_datespec"); dialog = (GtkDialog *) gtk_dialog_new (); diff --git a/filter/rule-editor.c b/filter/rule-editor.c index d2953ffe63..ad45ab8672 100644 --- a/filter/rule-editor.c +++ b/filter/rule-editor.c @@ -32,6 +32,7 @@ #include <libgnome/gnome-i18n.h> #include "e-util/e-error.h" +#include "e-util/e-util-private.h" #include "rule-editor.h" static int enable_undo = 0; @@ -165,8 +166,12 @@ rule_editor_new (RuleContext *rc, const char *source, const char *label) { RuleEditor *re = (RuleEditor *) g_object_new (RULE_TYPE_EDITOR, NULL); GladeXML *gui; + char *filter_glade = g_build_filename (EVOLUTION_GLADEDIR, + "filter.glade", + NULL); - gui = glade_xml_new (FILTER_GLADEDIR "/filter.glade", "rule_editor", NULL); + gui = glade_xml_new (filter_glade, "rule_editor", NULL); + g_free (filter_glade); rule_editor_construct (re, rc, gui, source, label); gtk_widget_hide(glade_xml_get_widget (gui, "filter_source")); g_object_unref (gui); |