summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog1
-rw-r--r--NEWS1
-rw-r--r--configure.ac10
-rw-r--r--src/lib/ecore/ecore_main.c7
4 files changed, 14 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index 719dfc99dc..281ed389e3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -2,6 +2,7 @@
2 2
3 * Eeze: add a dummy implementation of libmount when it is not available. 3 * Eeze: add a dummy implementation of libmount when it is not available.
4 * Ecore_Con: add systemd socket activation support (ECORE_CON_SOCKET_ACTIVATE). 4 * Ecore_Con: add systemd socket activation support (ECORE_CON_SOCKET_ACTIVATE).
5 * Ecore: notify systemd that we are ready as soon as the main loop is running.
5 6
62013-03-08 Igor Murzov 72013-03-08 Igor Murzov
7 8
diff --git a/NEWS b/NEWS
index 2729d5c34b..31b17ae0be 100644
--- a/NEWS
+++ b/NEWS
@@ -73,6 +73,7 @@ Additions:
73 * Ecore_x: Add manual render code before deiconify 73 * Ecore_x: Add manual render code before deiconify
74 * Eeze: Add a dummy libmount replacement for when libmount is not there. 74 * Eeze: Add a dummy libmount replacement for when libmount is not there.
75 * Ecore_Con: Add systemd socket activation support (ECORE_CON_SOCKET_ACTIVATE). 75 * Ecore_Con: Add systemd socket activation support (ECORE_CON_SOCKET_ACTIVATE).
76 * Ecore: notify systemd that we are ready as soon as the main loop is running.
76 77
77Deprecations: 78Deprecations:
78 * ecore_x: 79 * ecore_x:
diff --git a/configure.ac b/configure.ac
index 01ed6e2af8..6d54280354 100644
--- a/configure.ac
+++ b/configure.ac
@@ -137,6 +137,7 @@ case "$host_os" in
137 ;; 137 ;;
138esac 138esac
139 139
140want_systemd="no"
140have_wince="no" 141have_wince="no"
141have_win32="no" 142have_win32="no"
142have_windows="no" 143have_windows="no"
@@ -158,6 +159,7 @@ case "$host_os" in
158 ;; 159 ;;
159 linux*) 160 linux*)
160 have_linux="yes" 161 have_linux="yes"
162 want_systemd="yes"
161 ;; 163 ;;
162esac 164esac
163 165
@@ -1735,6 +1737,9 @@ if test "x${have_glib}" = "xno"; then
1735 want_g_main_loop="no" 1737 want_g_main_loop="no"
1736fi 1738fi
1737 1739
1740EFL_OPTIONAL_DEPEND_PKG([ECORE], [${want_systemd}], [SYSTEMD], [libsystemd-daemon])
1741
1742EFL_ADD_FEATURE([ECORE], [systemd-daemon], [${want_systemd}])
1738EFL_ADD_FEATURE([ECORE], [glib]) 1743EFL_ADD_FEATURE([ECORE], [glib])
1739EFL_ADD_FEATURE([ECORE], [g-main-loop]) 1744EFL_ADD_FEATURE([ECORE], [g-main-loop])
1740 1745
@@ -1885,26 +1890,21 @@ want_ecore_con_local_sockets="yes"
1885want_ecore_con_abstract_sockets="yes" 1890want_ecore_con_abstract_sockets="yes"
1886 1891
1887if test "${have_wince}" = "yes"; then 1892if test "${have_wince}" = "yes"; then
1888 want_systemd="no"
1889 want_curl="no" 1893 want_curl="no"
1890 want_cares="no" 1894 want_cares="no"
1891 want_ecore_con_local_sockets="no" 1895 want_ecore_con_local_sockets="no"
1892 want_ecore_con_abstract_sockets="no" 1896 want_ecore_con_abstract_sockets="no"
1893elif test "${have_win32}" = "yes"; then 1897elif test "${have_win32}" = "yes"; then
1894 want_systemd="no"
1895 want_cares="yes" 1898 want_cares="yes"
1896 want_ecore_con_abstract_sockets="no" 1899 want_ecore_con_abstract_sockets="no"
1897elif test "${have_darwin}" = "yes"; then 1900elif test "${have_darwin}" = "yes"; then
1898 want_systemd="no"
1899 want_cares="no" 1901 want_cares="no"
1900 want_ecore_con_abstract_sockets="no" 1902 want_ecore_con_abstract_sockets="no"
1901elif test "${have_ps3}" = "yes"; then 1903elif test "${have_ps3}" = "yes"; then
1902 want_systemd="no"
1903 want_cares="no" 1904 want_cares="no"
1904 want_ecore_con_local_sockets="no" 1905 want_ecore_con_local_sockets="no"
1905 want_ecore_con_abstract_sockets="no" 1906 want_ecore_con_abstract_sockets="no"
1906else 1907else
1907 want_systemd="yes"
1908 want_cares="no" 1908 want_cares="no"
1909fi 1909fi
1910 1910
diff --git a/src/lib/ecore/ecore_main.c b/src/lib/ecore/ecore_main.c
index e551ea71e0..df240c1632 100644
--- a/src/lib/ecore/ecore_main.c
+++ b/src/lib/ecore/ecore_main.c
@@ -25,6 +25,10 @@
25#include <fcntl.h> 25#include <fcntl.h>
26#include <sys/time.h> 26#include <sys/time.h>
27 27
28#ifdef HAVE_SYSTEMD
29# include <systemd/sd-daemon.h>
30#endif
31
28#ifdef _MSC_VER 32#ifdef _MSC_VER
29# include <float.h> 33# include <float.h>
30#endif 34#endif
@@ -949,6 +953,9 @@ EAPI void
949ecore_main_loop_begin(void) 953ecore_main_loop_begin(void)
950{ 954{
951 EINA_MAIN_LOOP_CHECK_RETURN; 955 EINA_MAIN_LOOP_CHECK_RETURN;
956#ifdef HAVE_SYSTEMD
957 sd_notify(0, "READY=1");
958#endif
952#ifndef USE_G_MAIN_LOOP 959#ifndef USE_G_MAIN_LOOP
953 _ecore_lock(); 960 _ecore_lock();
954 in_main_loop++; 961 in_main_loop++;