-
Notifications
You must be signed in to change notification settings - Fork 96
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AArch32 compatiblity issues #184
Comments
Do I understand it correctly that the compiler is crashing? |
Yes. It doesn't happen when I just print the CBOR_VERSION (it means that the library is compiled). The platform is a Cortex A9. ---UPDATE--- |
Now, I have the following problem that probably is due the size_t. Indeed, when I try do a simple operation like this:
I receive in output a malformed string: ---SOLUTION FOR THE FIRST ISSUE---
|
Thanks for the update, I guess this is kind of working as intended, but in retrospect it seems pretty dumb that we are tied to 8B size_t... Let me see if we can just swap it for int64_t. |
Ok, now I remember, size_t is sometimes used to represent the number of items (say in an array), not just bytes, under the assumption that since every item is at least 1B, size_t is guaranteed to fit the size of anything we can have in memory. This is not ideal because this could still work correctly in e.g. streaming mode decoding. But anyway, I think that is not the issue you are running into with your example.
Why is that string malformed? It should be |
Describe the bug
When I try to preallocate the map structure as
cbor_item_t* root = cbor_new_definite_map(2);
I receive the following error:To Reproduce
Compiler: arm-linux-gnueabihf-gcc
Compile the library for ARM.
cmake -DCMAKE_TOOLCHAIN_FILE=toolchain.armhf .
After the compile an example such as
create_items.c
with arm-linux-gnueabihf-gcc.Expected behavior
No errors.
Environment
libcbor 0.8.0
The content of toolchain.armhf is the following:
The text was updated successfully, but these errors were encountered: