cedric pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=6e043dfb44006b7b48d1f54f907c00417fcf6baf

commit 6e043dfb44006b7b48d1f54f907c00417fcf6baf
Author: Vincent Torri <vincent.to...@gmail.com>
Date:   Tue Oct 29 16:15:21 2013 +0100

    evil: remove libgen and the GNU *printf code (both in mingw-w64).
    
    This should reduce the code size of evil and reduce maintainance as
    mingw does now take care of it.
    
    Signed-off-by: Cedric Bail <cedric.b...@samsung.com>
---
 pc/evil.pc.in                 |   2 +-
 src/Makefile_Evil.am          |  39 +---------------
 src/lib/evil/Evil.h           |   3 --
 src/lib/evil/evil_inet.c      |   4 +-
 src/lib/evil/evil_inet.h      |   2 +-
 src/lib/evil/evil_macro.h     | 100 ------------------------------------------
 src/lib/evil/evil_macro_pop.h |  25 -----------
 src/lib/evil/evil_mman.c      |   3 --
 src/lib/evil/evil_stdlib.c    |   2 -
 src/lib/evil/evil_util.c      |   2 -
 10 files changed, 4 insertions(+), 178 deletions(-)

diff --git a/pc/evil.pc.in b/pc/evil.pc.in
index 6f5f085..cf4b855 100644
--- a/pc/evil.pc.in
+++ b/pc/evil.pc.in
@@ -10,4 +10,4 @@ Description: Library that ports on Windows some specific Unix 
functions.
 Version: @VERSION@
 Libs: -L${libdir} -levil
 Libs.private:
-Cflags: -I${includedir}/evil-@VMAJ@ @EFL_WINDOWS_VERSION_CFLAGS@ -mms-bitfields
+Cflags: -I${includedir}/evil-@VMAJ@ @EFL_WINDOWS_VERSION_CFLAGS@ 
-mms-bitfields -D__MINGW_PRINTF_FORMAT
diff --git a/src/Makefile_Evil.am b/src/Makefile_Evil.am
index af8512b..9e68b6e 100644
--- a/src/Makefile_Evil.am
+++ b/src/Makefile_Evil.am
@@ -10,11 +10,9 @@ lib/evil/Evil.h \
 lib/evil/evil_fcntl.h \
 lib/evil/evil_inet.h \
 lib/evil/evil_langinfo.h \
-lib/evil/evil_libgen.h \
 lib/evil/evil_macro.h \
 lib/evil/evil_macro_pop.h \
 lib/evil/evil_main.h \
-lib/evil/evil_print.h \
 lib/evil/evil_stdlib.h \
 lib/evil/evil_stdio.h \
 lib/evil/evil_string.h \
@@ -34,49 +32,15 @@ evilmmanheadersdir = $(includedir)/evil-@VMAJ@/sys
 dist_evilmmanheaders_DATA = \
 lib/evil/sys/mman.h
 
-# gdtoa
 lib_evil_libevil_la_SOURCES = \
-lib/evil/gdtoa/arithchk.c \
-lib/evil/gdtoa/dmisc.c \
-lib/evil/gdtoa/dtoa.c \
-lib/evil/gdtoa/gd_arith.h \
-lib/evil/gdtoa/g_dfmt.c \
-lib/evil/gdtoa/gd_qnan.h \
-lib/evil/gdtoa/gdtoa.c \
-lib/evil/gdtoa/gdtoa_fltrnds.h \
-lib/evil/gdtoa/gdtoa.h \
-lib/evil/gdtoa/gdtoaimp.h \
-lib/evil/gdtoa/gethex.c \
-lib/evil/gdtoa/g_ffmt.c \
-lib/evil/gdtoa/g__fmt.c \
-lib/evil/gdtoa/gmisc.c \
-lib/evil/gdtoa/g_xfmt.c \
-lib/evil/gdtoa/hd_init.c \
-lib/evil/gdtoa/hexnan.c \
-lib/evil/gdtoa/misc.c \
-lib/evil/gdtoa/qnan.c \
-lib/evil/gdtoa/smisc.c \
-lib/evil/gdtoa/strtodg.c \
-lib/evil/gdtoa/strtof.c \
-lib/evil/gdtoa/strtopx.c \
-lib/evil/gdtoa/sum.c \
-lib/evil/gdtoa/ulp.c
-
-#evil
-lib_evil_libevil_la_SOURCES += \
 lib/evil/evil_dirent.c \
 lib/evil/evil_fcntl.c \
 lib/evil/evil_fnmatch.c \
 lib/evil/evil_fnmatch_list_of_states.c \
 lib/evil/evil_inet.c \
 lib/evil/evil_langinfo.c \
-lib/evil/evil_libgen.c \
 lib/evil/evil_main.c \
 lib/evil/evil_mman.c \
-lib/evil/evil_pformata.c \
-lib/evil/evil_pformatw.c \
-lib/evil/evil_printa.c \
-lib/evil/evil_printw.c \
 lib/evil/evil_pwd.c \
 lib/evil/evil_stdlib.c \
 lib/evil/evil_stdio.c \
@@ -85,7 +49,6 @@ lib/evil/evil_time.c \
 lib/evil/evil_unistd.c \
 lib/evil/evil_util.c \
 lib/evil/evil_uuid.c \
-lib/evil/evil_pformat.h \
 lib/evil/evil_private.h \
 lib/evil/evil_fnmatch_private.h
 
@@ -95,7 +58,7 @@ else
 lib_evil_libevil_la_SOURCES += lib/evil/evil_link_xp.cpp
 endif
 
-lib_evil_libevil_la_CFLAGS = @EVIL_CFLAGS@ @EVIL_CFLAGS_WRN@
+lib_evil_libevil_la_CFLAGS = @EVIL_CFLAGS@ @EVIL_CFLAGS_WRN@ 
-D__MINGW_PRINTF_FORMAT
 lib_evil_libevil_la_CXXFLAGS = @EVIL_CXXFLAGS@ @EVIL_CFLAGS@
 lib_evil_libevil_la_LIBADD = @EVIL_LIBS@
 lib_evil_libevil_la_LDFLAGS = @EFL_LTLIBRARY_FLAGS@
diff --git a/src/lib/evil/Evil.h b/src/lib/evil/Evil.h
index eb84ec6..e629d76 100644
--- a/src/lib/evil/Evil.h
+++ b/src/lib/evil/Evil.h
@@ -71,7 +71,6 @@
  * Recommended reading:
  *
  * @li @ref Evil_Mman
- * @li @ref Evil_Libgen_Group
  * @li @ref Evil_Unistd_Group
  * @li @ref Evil_Dlfcn
  * @li @ref Evil_Pwd_Group
@@ -152,9 +151,7 @@ typedef unsigned long  gid_t;
 #include "evil_fcntl.h"
 #include "evil_inet.h"
 #include "evil_langinfo.h"
-#include "evil_libgen.h"
 #include "evil_main.h"
-#include "evil_print.h"
 #include "evil_stdlib.h"
 #include "evil_stdio.h"
 #include "evil_string.h"
diff --git a/src/lib/evil/evil_inet.c b/src/lib/evil/evil_inet.c
index c24ebaf..e455d0e 100644
--- a/src/lib/evil/evil_inet.c
+++ b/src/lib/evil/evil_inet.c
@@ -22,7 +22,7 @@
  * * modification of the management of the error
  */
 
-#if ! _WIN32_WINNT >= _WIN32_WINNT_VISTA
+#if ! (_WIN32_WINNT >= _WIN32_WINNT_VISTA)
 
 #ifdef HAVE_CONFIG_H
 # include "config.h"
@@ -41,8 +41,6 @@
 #include "evil_macro.h"
 #include "evil_inet.h"
 #include "evil_private.h"
-#define APICHAR char
-#include "evil_print.h"
 
 #ifndef EMSGSIZE
 # define EMSGSIZE WSAEMSGSIZE
diff --git a/src/lib/evil/evil_inet.h b/src/lib/evil/evil_inet.h
index f8ff49b..4db49b8 100644
--- a/src/lib/evil/evil_inet.h
+++ b/src/lib/evil/evil_inet.h
@@ -18,7 +18,7 @@
 #define __EVIL_INET_H__
 
 
-#if ! _WIN32_WINNT >= _WIN32_WINNT_VISTA
+#if ! (_WIN32_WINNT >= _WIN32_WINNT_VISTA)
 
 
 /**
diff --git a/src/lib/evil/evil_macro.h b/src/lib/evil/evil_macro.h
index b2500d3..439c4ff 100644
--- a/src/lib/evil/evil_macro.h
+++ b/src/lib/evil/evil_macro.h
@@ -2,15 +2,6 @@
 #define __EVIL_MACRO_H__
 
 
-#ifndef __cdecl
-# define EVIL_CDECL_IS_DEFINED
-# ifdef __GNUC__
-#  define __cdecl __attribute__((__cdecl__))
-# else
-#  define __cdecl
-# endif
-#endif /* __cdecl */
-
 
 #ifdef EAPI
 # undef EAPI
@@ -29,100 +20,9 @@
 #endif /* _WIN32 */
 
 
-#ifndef __EVIL_GNUC_PREREQ
-# if defined __GNUC__ && defined __GNUC_MINOR__
-#  define __EVIL_GNUC_PREREQ( major, minor )\
-     (__GNUC__ > (major) || (__GNUC__ == (major) && __GNUC_MINOR__ >= (minor)))
-# else
-#  define __EVIL_GNUC_PREREQ( major, minor )
-# endif
-#endif /* __EVIL_GNUC_PREREQ */
-
-
-#ifndef  __EVIL_NOTHROW
-# if __EVIL_GNUC_PREREQ( 3, 3 )
-#  define __EVIL_NOTHROW  __attribute__((__nothrow__))
-# else
-#  define __EVIL_NOTHROW
-# endif
-#endif /* __EVIL_NOTHROW */
-
-
-#ifndef  __EVIL_PRINTF
-# if __EVIL_GNUC_PREREQ( 2, 4 )
-#  define __EVIL_PRINTF(fmt, arg) __attribute__((__format__ (__gnu_printf__, 
fmt, arg)))
-# else
-#  define __EVIL_PRINTF(fmt, arg)
-# endif
-#endif /* __EVIL_PRINTF */
-
-
 #ifndef PATH_MAX
 # define PATH_MAX MAX_PATH
 #endif /* PATH_MAX */
-#ifdef fprintf
-# undef fprintf
-#endif
-
-#ifdef printf
-# undef printf
-#endif
-
-#ifdef sprintf
-# undef sprintf
-#endif
-
-#ifdef snprintf
-# undef snprintf
-#endif
-
-#ifdef vfprintf
-# undef vfprintf
-#endif
-
-#ifdef vprintf
-# undef vprintf
-#endif
-
-#ifdef vsprintf
-# undef vsprintf
-#endif
-
-#ifdef vsnprintf
-# undef vsnprintf
-#endif
-
-#ifdef fscanf
-# undef fscanf
-#endif
-
-#ifdef scanf
-# undef scanf
-#endif
-
-#ifdef sscanf
-# undef sscanf
-#endif
-
-#ifdef vfscanf
-# undef vfscanf
-#endif
-
-#ifdef vscanf
-# undef vscanf
-#endif
-
-#ifdef vsscanf
-# undef vsscanf
-#endif
-
-#ifdef asprintf
-# undef asprintf
-#endif
-
-#ifdef vasprintf
-# undef vasprintf
-#endif
 
 
 #if defined(_INTTYPES_H_) && defined(PRId64)
diff --git a/src/lib/evil/evil_macro_pop.h b/src/lib/evil/evil_macro_pop.h
index a82818d..bad78db 100644
--- a/src/lib/evil/evil_macro_pop.h
+++ b/src/lib/evil/evil_macro_pop.h
@@ -1,31 +1,6 @@
 #ifndef __EVIL_MACRO_POP_H__
 #define __EVIL_MACRO_POP_H__
 
-
-#ifdef EVIL_CDECL_IS_DEFINED
-# undef __cdecl
-# undef EVIL_CDECL_IS_DEFINED
-#endif
-
-#define fprintf   _evil_fprintfa
-#define printf    _evil_printfa
-#define snprintf  _evil_snprintfa
-#define sprintf   _evil_sprintfa
-#define vfprintf  _evil_vfprintfa
-#define vprintf   _evil_vprintfa
-#define vsnprintf _evil_vsnprintfa
-#define vsprintf  _evil_vsprintfa
-
-#define fscanf    _evil_fscanf
-#define scanf     _evil_scanf
-#define sscanf    _evil_sscanf
-#define vfscanf   _evil_vfscanf
-#define vscanf    _evil_vscanf
-#define vsscanf   _evil_vsscanf
-
-#define asprintf  _evil_asprintf
-#define vasprintf _evil_vasprintf
-
 /* Redefine to GNU specific PRI... and SCN... macros.  */
 
 #define PRId64 "lld"
diff --git a/src/lib/evil/evil_mman.c b/src/lib/evil/evil_mman.c
index f6d22f7..80632c7 100644
--- a/src/lib/evil/evil_mman.c
+++ b/src/lib/evil/evil_mman.c
@@ -22,9 +22,6 @@
 #include "sys/mman.h"
 #include "evil_util.h"
 #include "evil_private.h"
-#define APICHAR char
-#include "evil_print.h"
-#include "evil_private.h"
 
 #ifdef __MINGW32CE__
 # define _get_osfhandle(FILEDES) ((long)FILEDES)
diff --git a/src/lib/evil/evil_stdlib.c b/src/lib/evil/evil_stdlib.c
index 3e06393..ae9c382 100644
--- a/src/lib/evil/evil_stdlib.c
+++ b/src/lib/evil/evil_stdlib.c
@@ -20,8 +20,6 @@
 #include "evil_macro.h"
 #include "evil_stdlib.h"
 #include "evil_private.h"
-#define APICHAR char
-#include "evil_print.h"
 
 /*
  * Environment variable related functions
diff --git a/src/lib/evil/evil_util.c b/src/lib/evil/evil_util.c
index a02c7c4..0bc6501 100644
--- a/src/lib/evil/evil_util.c
+++ b/src/lib/evil/evil_util.c
@@ -17,8 +17,6 @@
 #include "evil_macro.h"
 #include "evil_util.h"
 #include "evil_private.h"
-#define APICHAR char
-#include "evil_print.h"
 
 
 wchar_t *

-- 


Reply via email to