bretantonio / navboard

Automatically exported from code.google.com/p/hackerskeyboard
0 stars 0 forks source link

Support 64bit platforms such as arm64-v8a #468

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
ndk-build jni files with android-ndk-r10d on MacPro 10.10.
with APP_ABI := all,but [arm64-v8a] complains error:
chackerskeyboard/java/jni/jni/org_pocketworkstation_pckeyboard_BinaryDictionary.
cpp:53:19: error: cast from 'latinime::Dictionary*' to 'jint {aka int}' loses 
precision [-fpermissive]
     return (jint) dictionary;

seems to cast 64bit pointer to 32bit pointer.

Original issue reported on code.google.com by ggso...@gmail.com on 10 Apr 2015 at 6:58

GoogleCodeExporter commented 8 years ago
I also encountered this problem when I tried to build the native code. I'm 
using Eclipse Juno and android-ndk-r10e on a Windows 7 (64 bit) machine. 

Original comment by keishik...@gmail.com on 8 Jun 2015 at 6:06

Attachments:

GoogleCodeExporter commented 8 years ago
Indeed, the code assumes 32bit pointers.

I've just submitted an untested patch that attempts to fix this by upgrading 
the opaque pointer type to "long", can you give this a try and let me know if 
it works?

https://code.google.com/p/hackerskeyboard/source/detail?r=3c2bd051b2c8ff5e3dc126
b487216a1bb336a72d

Original comment by Klaus.We...@gmail.com on 9 Jun 2015 at 6:08

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Thanks for the speedy reply.

Yep that worked. I no longer have errors during build.  However, suggested 
words are still not displaying. In the version I downloaded from the PlayStore, 
HK pops up suggested words when I start typing. It doesn't happen with my 
built-from-source HK. Thanks in advance.

Original comment by keishik...@gmail.com on 10 Jun 2015 at 2:58

Attachments:

GoogleCodeExporter commented 8 years ago
Can you check if it logs any warnings on startup, i.e. via "adb logcat"? It 
should log "loaded jni_pckeyboard" and "Loaded dictionary, len=..." on success.

Original comment by Klaus.We...@gmail.com on 10 Jun 2015 at 6:07

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
There's "loaded jni_pckeyboard" but there's no "Loaded dictionary, len=..." No 
warnings.

Original comment by keishik...@gmail.com on 11 Jun 2015 at 6:17

GoogleCodeExporter commented 8 years ago
Do you have the English dictionary downloaded? 
https://play.google.com/store/apps/details?id=org.pocketworkstation.dict.en

Building from source doesn't include the defalt English dictionary. I intend to 
not include it by default, but have not removed it yet from published builds to 
avoid surprises for people upgrading it.

Original comment by Klaus.We...@gmail.com on 11 Jun 2015 at 5:07

GoogleCodeExporter commented 8 years ago
I didn't download any dictionary. I'm just curious how come I have words being 
suggested to me (PlayStore HK) opposed to my self-compiled that didn't. 
Anyways, thank you for your help. Even without a dictionary, your keyboard is 
still the best there is. Thanks again and keep up the good work. 

Original comment by keishik...@gmail.com on 12 Jun 2015 at 5:29

GoogleCodeExporter commented 8 years ago
The Play Store version of Hacker's Keyboard embeds the English dictionary to 
maintain backwards compatibility with earlier versions, while other languages 
still need to be downloaded separately.

If you build your own, the build won't include any dictionary, so you need to 
download the English dictionary to make it work.

Original comment by Klaus.We...@gmail.com on 12 Jun 2015 at 6:05

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Hi, sorry for the super late reply. Anyways, I tried your suggestion (custom HK 
+ English dictionary from PlayStore) and it worked perfectly in my devices. 
Thank you so much for your help and looking forward to more enhancements for 
this amazing keyboard. :)

Original comment by keishik...@gmail.com on 23 Jun 2015 at 9:40

GoogleCodeExporter commented 8 years ago

Original comment by Klaus.We...@gmail.com on 24 Jun 2015 at 12:13