summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVincent Torri <vincent.torri@gmail.com>2013-10-29 16:15:21 +0100
committerCedric Bail <cedric.bail@samsung.com>2013-10-31 14:33:00 +0900
commit6e043dfb44006b7b48d1f54f907c00417fcf6baf (patch)
treeee2508db2ad0a7ef5eaa26704b1778ceaab389c6
parent3038d41ba1070b3b5c4e682429fbfad4ea4fbea9 (diff)
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.bail@samsung.com>
Diffstat (limited to '')
-rw-r--r--pc/evil.pc.in2
-rw-r--r--src/Makefile_Evil.am39
-rw-r--r--src/lib/evil/Evil.h3
-rw-r--r--src/lib/evil/evil_inet.c4
-rw-r--r--src/lib/evil/evil_inet.h2
-rw-r--r--src/lib/evil/evil_macro.h100
-rw-r--r--src/lib/evil/evil_macro_pop.h25
-rw-r--r--src/lib/evil/evil_mman.c3
-rw-r--r--src/lib/evil/evil_stdlib.c2
-rw-r--r--src/lib/evil/evil_util.c2
10 files changed, 4 insertions, 178 deletions
diff --git a/pc/evil.pc.in b/pc/evil.pc.in
index 6f5f08572e..cf4b855af8 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.
10Version: @VERSION@ 10Version: @VERSION@
11Libs: -L${libdir} -levil 11Libs: -L${libdir} -levil
12Libs.private: 12Libs.private:
13Cflags: -I${includedir}/evil-@VMAJ@ @EFL_WINDOWS_VERSION_CFLAGS@ -mms-bitfields 13Cflags: -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 af8512b852..9e68b6e68f 100644
--- a/src/Makefile_Evil.am
+++ b/src/Makefile_Evil.am
@@ -10,11 +10,9 @@ lib/evil/Evil.h \
10lib/evil/evil_fcntl.h \ 10lib/evil/evil_fcntl.h \
11lib/evil/evil_inet.h \ 11lib/evil/evil_inet.h \
12lib/evil/evil_langinfo.h \ 12lib/evil/evil_langinfo.h \
13lib/evil/evil_libgen.h \
14lib/evil/evil_macro.h \ 13lib/evil/evil_macro.h \
15lib/evil/evil_macro_pop.h \ 14lib/evil/evil_macro_pop.h \
16lib/evil/evil_main.h \ 15lib/evil/evil_main.h \
17lib/evil/evil_print.h \
18lib/evil/evil_stdlib.h \ 16lib/evil/evil_stdlib.h \
19lib/evil/evil_stdio.h \ 17lib/evil/evil_stdio.h \
20lib/evil/evil_string.h \ 18lib/evil/evil_string.h \
@@ -34,49 +32,15 @@ evilmmanheadersdir = $(includedir)/evil-@VMAJ@/sys
34dist_evilmmanheaders_DATA = \ 32dist_evilmmanheaders_DATA = \
35lib/evil/sys/mman.h 33lib/evil/sys/mman.h
36 34
37# gdtoa
38lib_evil_libevil_la_SOURCES = \ 35lib_evil_libevil_la_SOURCES = \
39lib/evil/gdtoa/arithchk.c \
40lib/evil/gdtoa/dmisc.c \
41lib/evil/gdtoa/dtoa.c \
42lib/evil/gdtoa/gd_arith.h \
43lib/evil/gdtoa/g_dfmt.c \
44lib/evil/gdtoa/gd_qnan.h \
45lib/evil/gdtoa/gdtoa.c \
46lib/evil/gdtoa/gdtoa_fltrnds.h \
47lib/evil/gdtoa/gdtoa.h \
48lib/evil/gdtoa/gdtoaimp.h \
49lib/evil/gdtoa/gethex.c \
50lib/evil/gdtoa/g_ffmt.c \
51lib/evil/gdtoa/g__fmt.c \
52lib/evil/gdtoa/gmisc.c \
53lib/evil/gdtoa/g_xfmt.c \
54lib/evil/gdtoa/hd_init.c \
55lib/evil/gdtoa/hexnan.c \
56lib/evil/gdtoa/misc.c \
57lib/evil/gdtoa/qnan.c \
58lib/evil/gdtoa/smisc.c \
59lib/evil/gdtoa/strtodg.c \
60lib/evil/gdtoa/strtof.c \
61lib/evil/gdtoa/strtopx.c \
62lib/evil/gdtoa/sum.c \
63lib/evil/gdtoa/ulp.c
64
65#evil
66lib_evil_libevil_la_SOURCES += \
67lib/evil/evil_dirent.c \ 36lib/evil/evil_dirent.c \
68lib/evil/evil_fcntl.c \ 37lib/evil/evil_fcntl.c \
69lib/evil/evil_fnmatch.c \ 38lib/evil/evil_fnmatch.c \
70lib/evil/evil_fnmatch_list_of_states.c \ 39lib/evil/evil_fnmatch_list_of_states.c \
71lib/evil/evil_inet.c \ 40lib/evil/evil_inet.c \
72lib/evil/evil_langinfo.c \ 41lib/evil/evil_langinfo.c \
73lib/evil/evil_libgen.c \
74lib/evil/evil_main.c \ 42lib/evil/evil_main.c \
75lib/evil/evil_mman.c \ 43lib/evil/evil_mman.c \
76lib/evil/evil_pformata.c \
77lib/evil/evil_pformatw.c \
78lib/evil/evil_printa.c \
79lib/evil/evil_printw.c \
80lib/evil/evil_pwd.c \ 44lib/evil/evil_pwd.c \
81lib/evil/evil_stdlib.c \ 45lib/evil/evil_stdlib.c \
82lib/evil/evil_stdio.c \ 46lib/evil/evil_stdio.c \
@@ -85,7 +49,6 @@ lib/evil/evil_time.c \
85lib/evil/evil_unistd.c \ 49lib/evil/evil_unistd.c \
86lib/evil/evil_util.c \ 50lib/evil/evil_util.c \
87lib/evil/evil_uuid.c \ 51lib/evil/evil_uuid.c \
88lib/evil/evil_pformat.h \
89lib/evil/evil_private.h \ 52lib/evil/evil_private.h \
90lib/evil/evil_fnmatch_private.h 53lib/evil/evil_fnmatch_private.h
91 54
@@ -95,7 +58,7 @@ else
95lib_evil_libevil_la_SOURCES += lib/evil/evil_link_xp.cpp 58lib_evil_libevil_la_SOURCES += lib/evil/evil_link_xp.cpp
96endif 59endif
97 60
98lib_evil_libevil_la_CFLAGS = @EVIL_CFLAGS@ @EVIL_CFLAGS_WRN@ 61lib_evil_libevil_la_CFLAGS = @EVIL_CFLAGS@ @EVIL_CFLAGS_WRN@ -D__MINGW_PRINTF_FORMAT
99lib_evil_libevil_la_CXXFLAGS = @EVIL_CXXFLAGS@ @EVIL_CFLAGS@ 62lib_evil_libevil_la_CXXFLAGS = @EVIL_CXXFLAGS@ @EVIL_CFLAGS@
100lib_evil_libevil_la_LIBADD = @EVIL_LIBS@ 63lib_evil_libevil_la_LIBADD = @EVIL_LIBS@
101lib_evil_libevil_la_LDFLAGS = @EFL_LTLIBRARY_FLAGS@ 64lib_evil_libevil_la_LDFLAGS = @EFL_LTLIBRARY_FLAGS@
diff --git a/src/lib/evil/Evil.h b/src/lib/evil/Evil.h
index eb84ec6614..e629d7668e 100644
--- a/src/lib/evil/Evil.h
+++ b/src/lib/evil/Evil.h
@@ -71,7 +71,6 @@
71 * Recommended reading: 71 * Recommended reading:
72 * 72 *
73 * @li @ref Evil_Mman 73 * @li @ref Evil_Mman
74 * @li @ref Evil_Libgen_Group
75 * @li @ref Evil_Unistd_Group 74 * @li @ref Evil_Unistd_Group
76 * @li @ref Evil_Dlfcn 75 * @li @ref Evil_Dlfcn
77 * @li @ref Evil_Pwd_Group 76 * @li @ref Evil_Pwd_Group
@@ -152,9 +151,7 @@ typedef unsigned long gid_t;
152#include "evil_fcntl.h" 151#include "evil_fcntl.h"
153#include "evil_inet.h" 152#include "evil_inet.h"
154#include "evil_langinfo.h" 153#include "evil_langinfo.h"
155#include "evil_libgen.h"
156#include "evil_main.h" 154#include "evil_main.h"
157#include "evil_print.h"
158#include "evil_stdlib.h" 155#include "evil_stdlib.h"
159#include "evil_stdio.h" 156#include "evil_stdio.h"
160#include "evil_string.h" 157#include "evil_string.h"
diff --git a/src/lib/evil/evil_inet.c b/src/lib/evil/evil_inet.c
index c24ebaf97f..e455d0ea00 100644
--- a/src/lib/evil/evil_inet.c
+++ b/src/lib/evil/evil_inet.c
@@ -22,7 +22,7 @@
22 * * modification of the management of the error 22 * * modification of the management of the error
23 */ 23 */
24 24
25#if ! _WIN32_WINNT >= _WIN32_WINNT_VISTA 25#if ! (_WIN32_WINNT >= _WIN32_WINNT_VISTA)
26 26
27#ifdef HAVE_CONFIG_H 27#ifdef HAVE_CONFIG_H
28# include "config.h" 28# include "config.h"
@@ -41,8 +41,6 @@
41#include "evil_macro.h" 41#include "evil_macro.h"
42#include "evil_inet.h" 42#include "evil_inet.h"
43#include "evil_private.h" 43#include "evil_private.h"
44#define APICHAR char
45#include "evil_print.h"
46 44
47#ifndef EMSGSIZE 45#ifndef EMSGSIZE
48# define EMSGSIZE WSAEMSGSIZE 46# define EMSGSIZE WSAEMSGSIZE
diff --git a/src/lib/evil/evil_inet.h b/src/lib/evil/evil_inet.h
index f8ff49b17f..4db49b8acd 100644
--- a/src/lib/evil/evil_inet.h
+++ b/src/lib/evil/evil_inet.h
@@ -18,7 +18,7 @@
18#define __EVIL_INET_H__ 18#define __EVIL_INET_H__
19 19
20 20
21#if ! _WIN32_WINNT >= _WIN32_WINNT_VISTA 21#if ! (_WIN32_WINNT >= _WIN32_WINNT_VISTA)
22 22
23 23
24/** 24/**
diff --git a/src/lib/evil/evil_macro.h b/src/lib/evil/evil_macro.h
index b2500d33c7..439c4ff016 100644
--- a/src/lib/evil/evil_macro.h
+++ b/src/lib/evil/evil_macro.h
@@ -2,15 +2,6 @@
2#define __EVIL_MACRO_H__ 2#define __EVIL_MACRO_H__
3 3
4 4
5#ifndef __cdecl
6# define EVIL_CDECL_IS_DEFINED
7# ifdef __GNUC__
8# define __cdecl __attribute__((__cdecl__))
9# else
10# define __cdecl
11# endif
12#endif /* __cdecl */
13
14 5
15#ifdef EAPI 6#ifdef EAPI
16# undef EAPI 7# undef EAPI
@@ -29,100 +20,9 @@
29#endif /* _WIN32 */ 20#endif /* _WIN32 */
30 21
31 22
32#ifndef __EVIL_GNUC_PREREQ
33# if defined __GNUC__ && defined __GNUC_MINOR__
34# define __EVIL_GNUC_PREREQ( major, minor )\
35 (__GNUC__ > (major) || (__GNUC__ == (major) && __GNUC_MINOR__ >= (minor)))
36# else
37# define __EVIL_GNUC_PREREQ( major, minor )
38# endif
39#endif /* __EVIL_GNUC_PREREQ */
40
41
42#ifndef __EVIL_NOTHROW
43# if __EVIL_GNUC_PREREQ( 3, 3 )
44# define __EVIL_NOTHROW __attribute__((__nothrow__))
45# else
46# define __EVIL_NOTHROW
47# endif
48#endif /* __EVIL_NOTHROW */
49
50
51#ifndef __EVIL_PRINTF
52# if __EVIL_GNUC_PREREQ( 2, 4 )
53# define __EVIL_PRINTF(fmt, arg) __attribute__((__format__ (__gnu_printf__, fmt, arg)))
54# else
55# define __EVIL_PRINTF(fmt, arg)
56# endif
57#endif /* __EVIL_PRINTF */
58
59
60#ifndef PATH_MAX 23#ifndef PATH_MAX
61# define PATH_MAX MAX_PATH 24# define PATH_MAX MAX_PATH
62#endif /* PATH_MAX */ 25#endif /* PATH_MAX */
63#ifdef fprintf
64# undef fprintf
65#endif
66
67#ifdef printf
68# undef printf
69#endif
70
71#ifdef sprintf
72# undef sprintf
73#endif
74
75#ifdef snprintf
76# undef snprintf
77#endif
78
79#ifdef vfprintf
80# undef vfprintf
81#endif
82
83#ifdef vprintf
84# undef vprintf
85#endif
86
87#ifdef vsprintf
88# undef vsprintf
89#endif
90
91#ifdef vsnprintf
92# undef vsnprintf
93#endif
94
95#ifdef fscanf
96# undef fscanf
97#endif
98
99#ifdef scanf
100# undef scanf
101#endif
102
103#ifdef sscanf
104# undef sscanf
105#endif
106
107#ifdef vfscanf
108# undef vfscanf
109#endif
110
111#ifdef vscanf
112# undef vscanf
113#endif
114
115#ifdef vsscanf
116# undef vsscanf
117#endif
118
119#ifdef asprintf
120# undef asprintf
121#endif
122
123#ifdef vasprintf
124# undef vasprintf
125#endif
126 26
127 27
128#if defined(_INTTYPES_H_) && defined(PRId64) 28#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 a82818da9b..bad78db38a 100644
--- a/src/lib/evil/evil_macro_pop.h
+++ b/src/lib/evil/evil_macro_pop.h
@@ -1,31 +1,6 @@
1#ifndef __EVIL_MACRO_POP_H__ 1#ifndef __EVIL_MACRO_POP_H__
2#define __EVIL_MACRO_POP_H__ 2#define __EVIL_MACRO_POP_H__
3 3
4
5#ifdef EVIL_CDECL_IS_DEFINED
6# undef __cdecl
7# undef EVIL_CDECL_IS_DEFINED
8#endif
9
10#define fprintf _evil_fprintfa
11#define printf _evil_printfa
12#define snprintf _evil_snprintfa
13#define sprintf _evil_sprintfa
14#define vfprintf _evil_vfprintfa
15#define vprintf _evil_vprintfa
16#define vsnprintf _evil_vsnprintfa
17#define vsprintf _evil_vsprintfa
18
19#define fscanf _evil_fscanf
20#define scanf _evil_scanf
21#define sscanf _evil_sscanf
22#define vfscanf _evil_vfscanf
23#define vscanf _evil_vscanf
24#define vsscanf _evil_vsscanf
25
26#define asprintf _evil_asprintf
27#define vasprintf _evil_vasprintf
28
29/* Redefine to GNU specific PRI... and SCN... macros. */ 4/* Redefine to GNU specific PRI... and SCN... macros. */
30 5
31#define PRId64 "lld" 6#define PRId64 "lld"
diff --git a/src/lib/evil/evil_mman.c b/src/lib/evil/evil_mman.c
index f6d22f7378..80632c73f8 100644
--- a/src/lib/evil/evil_mman.c
+++ b/src/lib/evil/evil_mman.c
@@ -22,9 +22,6 @@
22#include "sys/mman.h" 22#include "sys/mman.h"
23#include "evil_util.h" 23#include "evil_util.h"
24#include "evil_private.h" 24#include "evil_private.h"
25#define APICHAR char
26#include "evil_print.h"
27#include "evil_private.h"
28 25
29#ifdef __MINGW32CE__ 26#ifdef __MINGW32CE__
30# define _get_osfhandle(FILEDES) ((long)FILEDES) 27# define _get_osfhandle(FILEDES) ((long)FILEDES)
diff --git a/src/lib/evil/evil_stdlib.c b/src/lib/evil/evil_stdlib.c
index 3e063931a5..ae9c382d1f 100644
--- a/src/lib/evil/evil_stdlib.c
+++ b/src/lib/evil/evil_stdlib.c
@@ -20,8 +20,6 @@
20#include "evil_macro.h" 20#include "evil_macro.h"
21#include "evil_stdlib.h" 21#include "evil_stdlib.h"
22#include "evil_private.h" 22#include "evil_private.h"
23#define APICHAR char
24#include "evil_print.h"
25 23
26/* 24/*
27 * Environment variable related functions 25 * Environment variable related functions
diff --git a/src/lib/evil/evil_util.c b/src/lib/evil/evil_util.c
index a02c7c4ff8..0bc6501e67 100644
--- a/src/lib/evil/evil_util.c
+++ b/src/lib/evil/evil_util.c
@@ -17,8 +17,6 @@
17#include "evil_macro.h" 17#include "evil_macro.h"
18#include "evil_util.h" 18#include "evil_util.h"
19#include "evil_private.h" 19#include "evil_private.h"
20#define APICHAR char
21#include "evil_print.h"
22 20
23 21
24wchar_t * 22wchar_t *