lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]




2011/6/4 Florian Weimer <fw@deneb.enyo.de>
* Xavier Wang:

>> I notice that new HEAD in git repo add exp2/log2 support for symbian :)

> this patch add missing stdint.h for lj_def.h:

Please check if Symbian has <inttypes.h> or defines the types in
<stddef.h>.  <stdint.h> was created by the standardization committee,
so support for it is historically poor, but there is precedent for
<inttypes.h> (which is also in the standard).

Sorry for late reply :)

Symbian has not <inttypes.h>, and <stddef.h> don't have such integer types.

In fact, Symbian is developed in C++, it support C by a wrapper library libc,
all function it support (e.g. printf) are all wrappers to C++ function. So...

Thank you for your patience for this such old and being out of fashion
cellphone System. Symbian is just abandon by Nokia, now Nokia is planning
using Windows Phone 7 and Meego on their new product. But there are already a
large amount Symbian product in market.

Below is a summary of all problem I met in porting:

- Symbian don't support ARM exception ABI(?) I mean, the linking error of
  R_ARM_CALL.

- Symbian don't have exp2/log2/trunc function, now lj_vmmath.c handle this
  issue.

- Symbian don't have stdint.h.

- Symbian has a emulator on PC, but I have no idea how to support it. I just
  ignore it... :(


Other issue:

- I using gcc to build buildvm.exe, because using msvc to build ARM port of
  buildvm can't work(a lot of warnings, and crashs when generate lj_*def.h and
  lj_vm.s):

E:\SymbianProjects\GMClient\Bin\GMClient\Sources\luajit-2.0\src>cl /nologo /MT /O2 /W3 /D_CRT_SECURE_NO_DEPRECATE /DLUAJIT_TARGET=LUAJIT_ARCH_ARM /DLUAJIT_OS=LUAJIT_OS_OTHER buildvm*.c

buildvm.c
e:\symbianprojects\gmclient\bin\gmclient\sources\luajit-2.0\src\buildvm_arm.h(6020) : warning C4146: unary minus operator applied to unsigned type, result still unsigned
e:\symbianprojects\gmclient\bin\gmclient\sources\luajit-2.0\src\buildvm_arm.h(6034) : warning C4146: unary minus operator applied to unsigned type, result still unsigned
e:\symbianprojects\gmclient\bin\gmclient\sources\luajit-2.0\src\buildvm_arm.h(6073) : warning C4146: unary minus operator applied to unsigned type, result still unsigned

...

These warnings are shown in msvc build, also:
lj_vmmath.c
lj_vmmath.c(52) : warning C4146: unary minus operator applied to unsigned type, result still unsigned
lj_vmmath.c(53) : warning C4146: unary minus operator applied to unsigned type, result still unsigned
lj_vmmath.c(56) : warning C4146: unary minus operator applied to unsigned type, result still unsigned