You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to android-ndk
Hi all,
I am compiling a large amount of C and C++ code using the NDK. Found
and tracked down a problem that occurs only on this platform and not
when used on many other platforms- the standard:
char array[10];
or
char charval;
is being treated as an unsigned char. On other platforms it's treated
as a signed char. Apparently this is a known fact with ARM
compilation when using GCC. Supposedly you can do this:
gcc -fsigned_char file.c
to force chars to be signed_char. But since we don't have the ability
to pass variables to gcc here, we are supposed to use:
LOCAL_CFLAGS := -fsigned_char
Unfortunately that gives me the compiler error:
cc1plus: error: unrecognized command line option "-fsigned_char"
Does anyone know how I can make this adjustment to the compiler? I'd
really like to not have to search through 100s of thousands of lines
of code changing all char definitions to signed char!
Thanks in advance!
Onur Cinar
unread,
Jun 20, 2010, 1:32:38 AM6/20/10
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to android-ndk
Hi Dave,
Instead of underscore try with a minus sign between signed and char,
it should work: