Ecore: ecore_con : make ecore_ipc compile on Windows.

SVN revision: 59389
This commit is contained in:
Vincent Torri 2011-05-14 18:30:43 +00:00
parent 3e9bc8fddd
commit bf8e99c128
6 changed files with 39 additions and 29 deletions

View File

@ -181,3 +181,4 @@
* Make ecore_con work on Windows (only the local connections
need a port)
* Make ecore_ipc compile on Windows

View File

@ -108,7 +108,7 @@ want_glib="no"
# core modules
want_ecore_con="yes"
want_ecore_ipc="no"
want_ecore_ipc="yes"
want_ecore_file="yes"
#want_ecore_config="no"
want_ecore_imf="no"
@ -165,6 +165,7 @@ want_ecore_evas_software_16_wince="no"
case "$host_os" in
mingw32ce* | cegcc*)
want_ecore_con="no"
want_ecore_ipc="no"
want_ecore_wince="yes"
want_ecore_evas_software_16_wince="yes"
;;
@ -187,7 +188,6 @@ case "$host_os" in
want_glib="auto"
want_gnutls="auto"
want_openssl="auto"
want_ecore_ipc="yes"
want_ecore_imf="yes"
want_ecore_cocoa="yes"
want_ecore_evas_software_sdl="yes"
@ -204,7 +204,6 @@ case "$host_os" in
want_inotify="yes"
want_tslib="yes"
want_ecore_fb="yes"
want_ecore_ipc="yes"
want_ecore_imf="yes"
want_ecore_x="yes"
want_ecore_evas_software_x11="yes"
@ -367,6 +366,7 @@ case "$host_os" in
EFL_ECORE_IMF_EVAS_BUILD="-DEFL_ECORE_IMF_EVAS_BUILD"
EFL_ECORE_INPUT_BUILD="-DEFL_ECORE_INPUT_BUILD"
EFL_ECORE_INPUT_EVAS_BUILD="-DEFL_ECORE_INPUT_EVAS_BUILD"
EFL_ECORE_IPC_BUILD="-DEFL_ECORE_IPC_BUILD"
;;
esac
@ -395,6 +395,7 @@ AC_SUBST(EFL_ECORE_IMF_BUILD)
AC_SUBST(EFL_ECORE_IMF_EVAS_BUILD)
AC_SUBST(EFL_ECORE_INPUT_BUILD)
AC_SUBST(EFL_ECORE_INPUT_EVAS_BUILD)
AC_SUBST(EFL_ECORE_IPC_BUILD)
AC_SUBST(EFL_ECORE_WINCE_BUILD)
AC_SUBST(EFL_ECORE_WIN32_BUILD)
AC_SUBST(EFL_ECORE_SDL_BUILD)

View File

@ -5,9 +5,13 @@
# undef EAPI
#endif
#ifdef _MSC_VER
# ifdef BUILDING_DLL
# define EAPI __declspec(dllexport)
#ifdef _WIN32
# ifdef EFL_ECORE_IPC_BUILD
# ifdef DLL_EXPORT
# define EAPI __declspec(dllexport)
# else
# define EAPI
# endif
# else
# define EAPI __declspec(dllimport)
# endif
@ -31,11 +35,9 @@
#ifdef __cplusplus
extern "C" {
#endif
#ifndef _ECORE_IPC_PRIVATE_H
typedef void Ecore_Ipc_Server; /**< An IPC connection handle */
typedef void Ecore_Ipc_Client; /**< An IPC connection handle */
#endif
typedef struct _Ecore_Ipc_Server Ecore_Ipc_Server; /**< An IPC connection handle */
typedef struct _Ecore_Ipc_Client Ecore_Ipc_Client; /**< An IPC connection handle */
/**
* Macros used for generic data packing

View File

@ -7,7 +7,9 @@ AM_CPPFLAGS = \
-I$(top_srcdir)/src/lib/ecore \
-I$(top_srcdir)/src/lib/ecore_con \
-I$(top_srcdir)/src/lib/ecore_ipc \
@SSL_CFLAGS@ @EINA_CFLAGS@
@EFL_ECORE_IPC_BUILD@ \
@SSL_CFLAGS@ \
@EINA_CFLAGS@
lib_LTLIBRARIES = libecore_ipc.la
includes_HEADERS = Ecore_Ipc.h

View File

@ -13,11 +13,18 @@
# include <winsock2.h>
#endif
#include "Ecore.h"
#include "ecore_private.h"
#include "Ecore_Con.h"
#include "ecore_ipc_private.h"
#if USE_GNUTLS_OPENSSL
# include <gnutls/openssl.h>
#elif USE_OPENSSL
# include <openssl/ssl.h>
#endif
#include <Ecore.h>
#include <ecore_private.h>
#include <Ecore_Con.h>
#include "Ecore_Ipc.h"
#include "ecore_ipc_private.h"
#define DLT_ZERO 0
#define DLT_ONE 1

View File

@ -34,20 +34,21 @@ extern int _ecore_ipc_log_dom;
#endif
#define CRIT(...) EINA_LOG_DOM_CRIT(_ecore_ipc_log_dom, __VA_ARGS__)
#if USE_GNUTLS_OPENSSL
# include <gnutls/openssl.h>
#elif USE_OPENSSL
# include <openssl/ssl.h>
#endif
#define ECORE_MAGIC_IPC_SERVER 0x87786556
#define ECORE_MAGIC_IPC_CLIENT 0x78875665
typedef struct _Ecore_Ipc_Client Ecore_Ipc_Client;
typedef struct _Ecore_Ipc_Server Ecore_Ipc_Server;
typedef struct _Ecore_Ipc_Msg_Head Ecore_Ipc_Msg_Head;
#if defined (_MSC_VER) || (defined (__SUNPRO_C) && __SUNPRO_C < 0x5100)
# pragma pack(1)
# define ECORE_IPC_STRUCT_PACKED
#elif defined (__GNUC__) || (defined (__SUNPRO_C) && __SUNPRO_C >= 0x5100)
# define ECORE_IPC_STRUCT_PACKED __attribute__((packed))
#else
# define ECORE_IPC_STRUCT_PACKED
#endif
#ifdef __sgi
#pragma pack 4
#endif
@ -59,11 +60,7 @@ struct _Ecore_Ipc_Msg_Head
int ref_to;
int response;
int size;
}
#ifdef _GNU_C_
__attribute__ ((packed));
#endif
;
} ECORE_IPC_STRUCT_PACKED;
#ifdef __sgi
#pragma pack 0
#endif