Enlightenment CVS committal
Author : doursse
Project : e17
Module : libs/embryo
Dir : e17/libs/embryo/src/lib
Modified Files:
Embryo.h embryo_private.h
Log Message:
* add evil support and remove evil windows code
* correctly handle alloca include
* remove trailing spaces
===================================================================
RCS file: /cvs/e/e17/libs/embryo/src/lib/Embryo.h,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -3 -r1.15 -r1.16
--- Embryo.h 31 Mar 2007 10:28:20 -0000 1.15
+++ Embryo.h 21 Mar 2008 17:18:25 -0000 1.16
@@ -2,14 +2,19 @@
#define _EMBRYO_H
#ifdef EAPI
-#undef EAPI
+# undef EAPI
#endif
-#ifdef _MSC_VER
-# ifdef BUILDING_DLL
-# define EAPI __declspec(dllexport)
+
+#ifdef _WIN32
+# ifdef EFL_EMBRYO_BUILD
+# ifdef DLL_EXPORT
+# define EAPI __declspec(dllexport)
+# else
+# define EAPI
+# endif /* ! DLL_EXPORT */
# else
# define EAPI __declspec(dllimport)
-# endif
+# endif /* ! EFL_EMBRYO_BUILD */
#else
# ifdef __GNUC__
# if __GNUC__ >= 4
@@ -20,7 +25,7 @@
# else
# define EAPI
# endif
-#endif
+#endif /* ! _WIN32 */
#ifdef __cplusplus
extern "C" {
@@ -43,7 +48,7 @@
EMBRYO_ERROR_NATIVE, /** Native function failed */
EMBRYO_ERROR_DIVIDE, /** Divide by zero */
EMBRYO_ERROR_SLEEP, /** Go into sleepmode - code can be
restarted */
-
+
EMBRYO_ERROR_MEMORY = 16, /** Out of memory */
EMBRYO_ERROR_FORMAT, /** Invalid file format */
EMBRYO_ERROR_VERSION, /** File is for a newer version of the
Embryo_Program */
@@ -62,7 +67,7 @@
#define EMBRYO_FUNCTION_MAIN -1 /* Start at program entry point */
#define EMBRYO_FUNCTION_CONT -2 /* Continue from last address */
/** An invalid cell reference */
-#define EMBRYO_CELL_NONE 0x7fffffff
+#define EMBRYO_CELL_NONE 0x7fffffff
/* program run return values */
#define EMBRYO_PROGRAM_OK 1
#define EMBRYO_PROGRAM_SLEEP 2
@@ -85,10 +90,10 @@
#define EMBRYO_FLOAT_TO_CELL(f) ((Embryo_Float_Cell) f).c
/** Embryo_Cell to float */
#define EMBRYO_CELL_TO_FLOAT(c) ((Embryo_Float_Cell) c).f
-
+
EAPI int embryo_init(void);
EAPI int embryo_shutdown(void);
-
+
EAPI Embryo_Program *embryo_program_new(void *data, int size);
EAPI Embryo_Program *embryo_program_const_new(void *data, int size);
EAPI Embryo_Program *embryo_program_load(char *file);
@@ -122,9 +127,9 @@
EAPI int embryo_parameter_cell_push(Embryo_Program *ep,
Embryo_Cell cell);
EAPI int embryo_parameter_string_push(Embryo_Program *ep,
const char *str);
EAPI int embryo_parameter_cell_array_push(Embryo_Program *ep,
Embryo_Cell *cells, int num);
-
+
#ifdef __cplusplus
-}
+}
#endif
#endif
===================================================================
RCS file: /cvs/e/e17/libs/embryo/src/lib/embryo_private.h,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -3 -r1.16 -r1.17
--- embryo_private.h 10 Jan 2006 07:33:12 -0000 1.16
+++ embryo_private.h 21 Mar 2008 17:18:25 -0000 1.17
@@ -8,12 +8,29 @@
#include <limits.h>
#include <stdarg.h>
#include <string.h>
-#if HAVE_ALLOCA_H
-#include <alloca.h>
+
+#ifdef HAVE_CONFIG_H
+# include "config.h"
+#endif
+
+#ifdef HAVE_ALLOCA_H
+# include <alloca.h>
+#elif defined __GNUC__
+# define alloca __builtin_alloca
+#elif defined _AIX
+# define alloca __alloca
+#elif defined _MSC_VER
+# include <malloc.h>
+# define alloca _alloca
+#else
+# include <stddef.h>
+# ifdef __cplusplus
+extern "C"
+# endif
+void *alloca (size_t);
#endif
#include "Embryo.h"
-#include "config.h"
#ifdef __GNUC__
# if __GNUC__ >= 4
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs