Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 8473 → Rev 8474

/programs/develop/tinypy/modules/kolibri/fs.c
8,7 → 8,7
extern tp_obj tp_list(TP);
extern tp_obj tp_dict(TP);
extern void _tp_raise(TP,tp_obj);
#define _cdecl __attribute__((cdecl))
// #define _cdecl __attribute__((cdecl))
extern int (* _cdecl con_printf)(const char* format,...);
 
#define call70(par, st) asm volatile ("int $0x40":"=a"(st):"a"(70), "b"(par))
/programs/develop/tinypy/tinypy/Makefile
5,12 → 5,12
SDK_DIR:= $(abspath ../../../../contrib/sdk)
 
LDFLAGS = -static -nostdlib -T $(SDK_DIR)/sources/newlib/app.lds \
--image-base 0 -lgcc -ldll -lc.dll
--image-base 0 -lgcc -lc.dll
 
CFLAGS = -U_Win32 -U_WIN32 -U__MINGW32__ -mpreferred-stack-boundary=2 \
-mincoming-stack-boundary=2 -fno-builtin -fno-common
 
INCLUDES= -I. -I$(SDK_DIR)/sources/newlib/libc/include -I$(CLAYER)/INCLUDE
INCLUDES= -I. -I$(SDK_DIR)/sources/newlib/libc/include
LIBPATH:= -L $(SDK_DIR)/lib -L /home/autobuild/tools/win32/mingw32/lib
 
 
/programs/develop/tinypy/tinypy/koconsole.c
1,9 → 1,9
#include "kolibri.h"
 
/*
#define __stdcall __attribute__((stdcall))
#define _cdecl __attribute__((cdecl))
#define _stdcall __attribute__((stdcall))
 
*/
void (* _stdcall con_init)(unsigned w_w, unsigned w_h, unsigned s_w, unsigned s_h, const char* t);
int (* _cdecl con_printf)(const char* format,...);
void (* _stdcall con_exit)(char bCloseWindow);
/programs/develop/tinypy/tinypy/kolibri.h
1,40 → 1,46
 
#ifndef NULL
#define NULL ((void*)0)
#endif
 
#pragma pack(push,1)
typedef struct
{
unsigned p00 __attribute__((packed));
unsigned p04 __attribute__((packed));
unsigned p08 __attribute__((packed));
unsigned p12 __attribute__((packed));
unsigned p16 __attribute__((packed));
char p20 __attribute__((packed));
char *p21 __attribute__((packed));
} kol_struct70 __attribute__((packed));
unsigned p00;
unsigned p04;
char *p08;
unsigned p12;
unsigned p16;
char p20;
char *p21;
} kol_struct70;
#pragma pack(pop)
 
 
#pragma pack(push,1)
typedef struct
{
unsigned p00 __attribute__((packed));
char p04 __attribute__((packed));
char p05[3] __attribute__((packed));
unsigned p08 __attribute__((packed));
unsigned p12 __attribute__((packed));
unsigned p16 __attribute__((packed));
unsigned p20 __attribute__((packed));
unsigned p24 __attribute__((packed));
unsigned p28 __attribute__((packed));
unsigned p32[2] __attribute__((packed));
unsigned p40 __attribute__((packed));
} kol_struct_BDVK __attribute__((packed));
unsigned p00;
char p04;
char p05[3];
unsigned p08;
unsigned p12;
unsigned p16;
unsigned p20;
unsigned p24;
unsigned p28;
unsigned long long p32;
unsigned p40;
} kol_struct_BDVK;
#pragma pack(pop)
 
#pragma pack(push,1)
typedef struct
{
char *name __attribute__((packed));
void *data __attribute__((packed));
} kol_struct_import __attribute__((packed));
char *name;
void *data;
} kol_struct_import;
#pragma pack(pop)
 
 
void kol_exit();
void kol_sleep(unsigned d);
void kol_wnd_define(unsigned x, unsigned y, unsigned w, unsigned h, unsigned c);
/programs/develop/tinypy/tinypy/kolibri_gui.c
14,7 → 14,7
extern void _tp_call(TP,tp_obj *dest, tp_obj fnc, tp_obj params);
extern int tp_bool(TP,tp_obj v);
extern tp_obj tp_has(TP,tp_obj self, tp_obj k);
#define _cdecl __attribute__((cdecl))
// #define _cdecl __attribute__((cdecl))
extern int (* _cdecl con_printf)(const char* format,...);
static tp_obj kolibri_show(TP)
{
/programs/develop/tinypy/tinypy/kolibri_net.c
8,7 → 8,7
extern tp_obj tp_fnc(TP,tp_obj v(TP));
extern tp_obj tp_get(TP,tp_obj self, tp_obj k);
tp_obj tp_has(TP,tp_obj self, tp_obj k);
#define _cdecl __attribute__((cdecl))
// #define _cdecl __attribute__((cdecl))
extern int (* _cdecl con_printf)(const char* format,...);
 
#define PRECISION 0.000001