forked from enlightenment/efl
ecore-con: make curl support entirely runtime loaded via eina_module
this makes curl support a pure runtime-only thing. libcurl is loaded by eina_module (dlopen/dlsym) when curl is actually first needed (when a url connection/object is created). this means that ecore-con has no link or compile dependencies on curl, only runtime, AND this saves memory (due to curl inits using apparently a chunk of private pages). so this saves memory and moves the dependency to runtime (though still consider libcurl a dependency of efl - but like a binary executed, it's at runtime).
This commit is contained in:
parent
4ce3e1e72f
commit
2c1c6b9335
|
@ -1,3 +1,8 @@
|
|||
2013-10-10 Carsten Haitzler (The Rasterman)
|
||||
|
||||
* Ecore-con: use dlopen/dlsym (eina_module) to load libcurl to
|
||||
save memory (private pages) when not yet used by the process
|
||||
|
||||
2013-10-10 Michael Bouchaud (yoz)
|
||||
|
||||
* Emotion: add two events to trigger webcam plug and unplug
|
||||
|
|
1
NEWS
1
NEWS
|
@ -223,6 +223,7 @@ Improvements:
|
|||
- Add iterator for walking child of smart objects, table and a box.
|
||||
* Ecore_Con:
|
||||
- Rebase dns.c against upstream
|
||||
- URL support now dynamically loads libcurl at runtime via eina_module.
|
||||
* Edje:
|
||||
- Entry: cursor position and location will be passed when it's really changed in case of mouse down, move, and up event.
|
||||
- Entry: remove ecore_imf_context_reset in mouse up event because it's useless.
|
||||
|
|
17
configure.ac
17
configure.ac
|
@ -1969,26 +1969,12 @@ EFL_LIB_END([Ecore])
|
|||
|
||||
EFL_LIB_START([Ecore_Con])
|
||||
|
||||
### Additional options to configure
|
||||
|
||||
AC_ARG_ENABLE([curl],
|
||||
[AC_HELP_STRING([--disable-curl], [disable curl support. @<:@default=enabled@:>@])],
|
||||
[
|
||||
if test "x${enableval}" = "xyes" ; then
|
||||
want_curl="yes"
|
||||
else
|
||||
want_curl="no"
|
||||
fi
|
||||
],
|
||||
[want_curl="yes"])
|
||||
|
||||
### Default values
|
||||
|
||||
want_ecore_con_local_sockets="yes"
|
||||
want_ecore_con_abstract_sockets="yes"
|
||||
|
||||
if test "${have_wince}" = "yes"; then
|
||||
want_curl="no"
|
||||
want_cares="no"
|
||||
want_ecore_con_local_sockets="no"
|
||||
want_ecore_con_abstract_sockets="no"
|
||||
|
@ -2027,8 +2013,6 @@ EFL_INTERNAL_DEPEND_PKG([ECORE_CON], [ecore])
|
|||
|
||||
EFL_ADD_LIBS([ECORE_CON], [-lm])
|
||||
|
||||
EFL_OPTIONAL_DEPEND_PKG([ECORE_CON], [${want_curl}], [CURL], [libcurl])
|
||||
|
||||
EFL_OPTIONAL_DEPEND_PKG([ECORE_CON], [${want_cares}],
|
||||
[CARES], [libcares >= 1.6.1])
|
||||
AM_CONDITIONAL([HAVE_CARES], [test "x${have_cares}" = "xyes"])
|
||||
|
@ -2043,7 +2027,6 @@ fi
|
|||
|
||||
EFL_OPTIONAL_DEPEND_PKG([ECORE_CON], [${want_systemd}], [SYSTEMD], [libsystemd-daemon])
|
||||
|
||||
EFL_ADD_FEATURE([ECORE_CON], [curl])
|
||||
EFL_ADD_FEATURE([ECORE_CON], [cares])
|
||||
EFL_ADD_FEATURE([ECORE_CON], [local-sockets], [${want_ecore_con_local_sockets}])
|
||||
EFL_ADD_FEATURE([ECORE_CON], [abstract-sockets], [${want_ecore_con_abstract_sockets}])
|
||||
|
|
|
@ -17,9 +17,6 @@
|
|||
#elif HAVE_OPENSSL
|
||||
# include <openssl/ssl.h>
|
||||
#endif
|
||||
#ifdef HAVE_CURL
|
||||
#include <curl/curl.h>
|
||||
#endif
|
||||
|
||||
#define READBUFSIZ 65536
|
||||
|
||||
|
@ -199,11 +196,10 @@ struct _Ecore_Con_Server
|
|||
#endif
|
||||
};
|
||||
|
||||
#ifdef HAVE_CURL
|
||||
struct _Ecore_Con_Url
|
||||
{
|
||||
ECORE_MAGIC;
|
||||
CURL *curl_easy;
|
||||
void *curl_easy;
|
||||
struct curl_slist *headers;
|
||||
Eina_List *additional_headers;
|
||||
Eina_List *response_headers;
|
||||
|
@ -226,7 +222,6 @@ struct _Ecore_Con_Url
|
|||
Eina_Bool dead : 1;
|
||||
Eina_Bool multi : 1;
|
||||
};
|
||||
#endif
|
||||
|
||||
struct _Ecore_Con_Info
|
||||
{
|
||||
|
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue