Skip to content

Commit 372e693

Browse files
author
zhangjipeng
committed
chore(build): remove 'WINCE' build macro define
Signed-off-by: zhangjipeng <zhangjipeng@xiaomi.com>
1 parent 3a23384 commit 372e693

6 files changed

Lines changed: 14 additions & 30 deletions

File tree

demos/tiger.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ void on_init(ps_context* gc, int w, int h)
231231
void on_draw(ps_context* gc)
232232
{
233233
int i;
234-
#if defined(WIN32) || defined(WINCE)
234+
#if defined(WIN32)
235235
clocktime_t t1, t2;
236236
#else
237237
suseconds_t t1, t2;
@@ -243,7 +243,7 @@ void on_draw(ps_context* gc)
243243
if (!change)
244244
return;
245245

246-
#if defined(WIN32) || defined(WINCE)
246+
#if defined(WIN32)
247247
t1 = get_clock();
248248
#else
249249
t1 = get_time();
@@ -286,14 +286,14 @@ void on_draw(ps_context* gc)
286286
else if (ps->m_paths[i].m_paintMode == 3)
287287
ps_paint(gc);
288288
}
289-
#if defined(WIN32) || defined(WINCE)
289+
#if defined(WIN32)
290290
t2 = get_clock();
291291
#else
292292
t2 = get_time();
293293
#endif
294294
change = 0;
295295

296-
#if defined(WIN32) || defined(WINCE)
296+
#if defined(WIN32)
297297
fprintf (stderr, "%f fps\n", 1000.0/get_clock_used_ms(t1, t2));
298298
#else
299299
fprintf(stderr, "draw frame use %.4f ms --- %.4f fps\n", (t2-t1)/1000.0, 1000.0/((t2-t1)/1000.0));

include/picasso.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
#define _PICASSO_H_
2121

2222
#ifdef DLL_EXPORT
23-
#if defined(WIN32) || defined(WINCE)
23+
#if defined(WIN32)
2424
#ifdef EXPORT
2525
#define PICAPI
2626
#define PEXPORT __declspec(dllexport)

include/picasso_backport.h

Whitespace-only changes.

src/include/memory_manager.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
#define mem_malloc(n) malloc(n)
1919
#define mem_calloc(n, s) calloc(n, s)
20-
#define mem_realloc(p, s) realloc(p, s)
2120
#define mem_free(p) free(p)
2221

2322
#define mem_deep_copy(d, s, l) memmove(d, s, l)

src/include/platform.h

Lines changed: 5 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,11 @@
6464
#define CPU_ARM 1
6565
#endif
6666

67+
/* CPU(ARM64) - ARM 64bit version */
68+
#if defined(__aarch64__)
69+
#define CPU_ARM64 1
70+
#endif
71+
6772
#if defined(__ARM_NEON__)
6873
#define CPU_ARM_NEON 1
6974
#endif
@@ -72,24 +77,6 @@
7277
#define CPU_ARM_VFP 1
7378
#endif
7479

75-
#if defined(WINCE) || defined(__WATCOMC__)
76-
/* math.h */
77-
#define sinf(x) ((float)sin(x))
78-
#define cosf(x) ((float)cos(x))
79-
#define acosf(x) ((float)acos(x))
80-
#define tanf(x) ((float)tan(x))
81-
#define asinf(x) ((float)asin(x))
82-
#define atan2f(x, y) ((float)atan2((x), (y)))
83-
#define powf(x, y) ((float)pow((x), (y)))
84-
#if defined(__WATCOMC__)
85-
#define sqrtf(x) ((float)sqrt((x)))
86-
#define fabsf(x) ((float)fabs((x)))
87-
#define fmodf(x, y) ((float)fmod((x), (y)))
88-
#define floorf(x) ((float)floor((x)))
89-
#define ceilf(x) ((float)ceil((x)))
90-
#endif
91-
#endif
92-
9380
#if COMPILER(GCC)
9481
#if __GNUC__ == 2 && __GNUC_MINOR__ < 96
9582
#define __builtin_expect(x, expected_value) (x)

test/timeuse.h

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,18 @@
1010
#include "unistd.h"
1111
#include "sys/time.h"
1212
#endif
13-
#if defined(WIN32) || defined(WINCE)
13+
#if defined(WIN32)
1414
#include <windows.h>
1515
#endif
1616

17-
#if defined(WIN32) || defined(WINCE)
17+
#if defined(WIN32)
1818
typedef long long suseconds_t;
1919
#define inline __inline
2020
#endif
2121

2222
static inline suseconds_t get_time()
2323
{
24-
#if defined(WIN32) || defined(WINCE)
24+
#if defined(WIN32)
2525
DWORD t1 = GetTickCount();
2626
#else
2727
struct timeval t;
@@ -31,7 +31,7 @@ static inline suseconds_t get_time()
3131
return t1;
3232
}
3333

34-
#if defined(WIN32) || defined(WINCE)
34+
#if defined(WIN32)
3535
typedef LARGE_INTEGER clocktime_t;
3636

3737
static inline clocktime_t get_clock()
@@ -93,6 +93,4 @@ static void enable_pmu_pmccntr(void)
9393
}
9494
#endif
9595

96-
97-
9896
#endif

0 commit comments

Comments
 (0)