From: Alex P. <pes...@ma...> - 2012-07-25 13:01:33
|
>>>>> checking for gcc... arm-linux-androideabi-gcc >> Thanks for your response, but it's still not running, this parameter has >> changed nothing Default compiler should be your native gcc, not cross-compiler. |
From: JLM <so4...@ho...> - 2012-07-25 13:28:50
|
On 25/07/2012 15:01, Alex Peshkoff wrote: > >>>>>> checking for gcc... arm-linux-androideabi-gcc > >>> Thanks for your response, but it's still not running, this parameter has >>> changed nothing > > Default compiler should be your native gcc, not cross-compiler. > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel > Oh, so I must not use the NDK ? Even when I use the NDK toolchain for x86 instead of the ARM toolchain, I have the same problem. Indeed, libfbclient has just been compiled whitout the use of the NDK. Jean-Louis Meuriot |
From: Adriano d. S. F. <adr...@gm...> - 2012-07-25 13:37:13
|
On 25/07/2012 10:28, JLM wrote: > > Oh, so I must not use the NDK ? Of course you must. > Even when I use the NDK toolchain for > x86 instead of the ARM toolchain, I have the same problem. > Indeed, libfbclient has just been compiled whitout the use of the NDK. > > export NDK=/path/to/ndk Adriano |
From: marius a. p. <ma...@gm...> - 2012-07-19 10:02:08
|
On Thu, Jul 19, 2012 at 11:57 AM, J-L M <so4...@ho...> wrote: > Hello, > > We are trying to compile Firebird 2.1 for Android in order to use the > embedded version in our mobile device of our software. > > But for the moment it seems impossible for some reasons : Android uses his > own Libc called Bionic. And the problem is that there is a lot of missing > features in. There is no implementation of the POSIX IPC or System V IPC > inside, Android drop this to avoid denial-of-service. So, use of > semaphore, shared memory, etc, is not possible. > > We have written a more complet document of this porterage which describes > the problems in detail. > please post it to google docs > > Somebody have already attempt to compile or to make an Android version > of Firebird ? > I see there is some work on the firebird 3.x branch > What would be the good way to do that ? > > Otherwise, how to interest Firebird developpers to make this Android > version ? (Maybe I can create a topic in the tracker ) > Please use the list for conversations > Thanks in advance. > > > > Jean-Louis Meuriot > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > Firebird-Devel mailing list, web interface at > https://lists.sourceforge.net/lists/listinfo/firebird-devel > > |
From: JLM <so4...@ho...> - 2012-07-23 08:22:11
|
On 23/07/2012 04:03, Adriano dos Santos Fernandes wrote: > I tried it, with official NDK but got error compiling common/CharSet.cpp > which needs ICU. So not even the client compiled. > > --------------------------------------- > asfernandes:~/fb/dev/trunk.git$ echo $NDK > /home/asfernandes/android/android-ndk-r8 > > asfernandes:~/fb/dev/trunk.git$ ./autogen.sh --with-cross-build=android.arme > > /home/asfernandes/android/android-ndk-r8/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi-g++ > -ggdb -DFB_SEND_FLAGS=MSG_NOSIGNAL -DLINUX -DANDROID -DARM -pipe -MMD > -fPIC -fmessage-length=0 > -I/home/asfernandes/fb/dev/trunk.git/extern/libtommath > --sysroot=/home/asfernandes/android/android-ndk-r8/platforms/android-9/arch-arm > -I/home/asfernandes/fb/dev/trunk.git/extern/icu/source/common > -I/home/asfernandes/fb/dev/trunk.git/extern/icu/source/i18n -O3 > -fno-omit-frame-pointer > -I/home/asfernandes/fb/dev/trunk.git/src/include/gen > -I/home/asfernandes/fb/dev/trunk.git/src/include -pthread -fno-rtti > -c /home/asfernandes/fb/dev/trunk.git/src/common/CharSet.cpp -o > /home/asfernandes/fb/dev/trunk.git/temp/Release/common/CharSet.o > In file included from > /home/asfernandes/fb/dev/trunk.git/extern/icu/source/common/unicode/utypes.h:36, > from > /home/asfernandes/fb/dev/trunk.git/extern/icu/source/common/unicode/ucnv.h:56, > from > /home/asfernandes/fb/dev/trunk.git/src/common/../jrd/../common/unicode_util.h:33, > from > /home/asfernandes/fb/dev/trunk.git/src/common/../jrd/intl_classes.h:35, > from > /home/asfernandes/fb/dev/trunk.git/src/common/CharSet.cpp:95: > /home/asfernandes/fb/dev/trunk.git/extern/icu/source/common/unicode/umachine.h:52:33: > error: unicode/platform.h: No such file or directory > --------------------------------------- Since I tried to compile Firebird2.1, I add inch by inch libraries wich were missing in the NDK to compile. I take them from a debian ARM virtual machine. And I carry out the libfbclient.so successfully. Now, I will test this library. With Java, it's seems impossible because it can't communicate with Firebird for the moment. So I will try to use Qt Necessitas. Do you think Necessitas can runs with Firebird ? Jean-Louis Meuriot |
From: marius a. p. <ma...@gm...> - 2012-07-23 08:37:34
|
On Mon, Jul 23, 2012 at 11:21 AM, JLM <so4...@ho...> wrote: > On 23/07/2012 04:03, Adriano dos Santos Fernandes wrote: > > > I tried it, with official NDK but got error compiling common/CharSet.cpp > > which needs ICU. So not even the client compiled. > > > > --------------------------------------- > > asfernandes:~/fb/dev/trunk.git$ echo $NDK > > /home/asfernandes/android/android-ndk-r8 > > > > asfernandes:~/fb/dev/trunk.git$ ./autogen.sh > --with-cross-build=android.arme > > > > > /home/asfernandes/android/android-ndk-r8/toolchains/arm-linux-androideabi-4.4.3/prebuilt/linux-x86/bin/arm-linux-androideabi-g++ > > -ggdb -DFB_SEND_FLAGS=MSG_NOSIGNAL -DLINUX -DANDROID -DARM -pipe -MMD > > -fPIC -fmessage-length=0 > > -I/home/asfernandes/fb/dev/trunk.git/extern/libtommath > > > --sysroot=/home/asfernandes/android/android-ndk-r8/platforms/android-9/arch-arm > > -I/home/asfernandes/fb/dev/trunk.git/extern/icu/source/common > > -I/home/asfernandes/fb/dev/trunk.git/extern/icu/source/i18n -O3 > > -fno-omit-frame-pointer > > -I/home/asfernandes/fb/dev/trunk.git/src/include/gen > > -I/home/asfernandes/fb/dev/trunk.git/src/include -pthread -fno-rtti > > -c /home/asfernandes/fb/dev/trunk.git/src/common/CharSet.cpp -o > > /home/asfernandes/fb/dev/trunk.git/temp/Release/common/CharSet.o > > In file included from > > > /home/asfernandes/fb/dev/trunk.git/extern/icu/source/common/unicode/utypes.h:36, > > from > > > /home/asfernandes/fb/dev/trunk.git/extern/icu/source/common/unicode/ucnv.h:56, > > from > > > /home/asfernandes/fb/dev/trunk.git/src/common/../jrd/../common/unicode_util.h:33, > > from > > /home/asfernandes/fb/dev/trunk.git/src/common/../jrd/intl_classes.h:35, > > from > > /home/asfernandes/fb/dev/trunk.git/src/common/CharSet.cpp:95: > > > /home/asfernandes/fb/dev/trunk.git/extern/icu/source/common/unicode/umachine.h:52:33: > > error: unicode/platform.h: No such file or directory > > --------------------------------------- > > Since I tried to compile Firebird2.1, I add inch by inch libraries wich > were missing in the NDK to compile. I take them from a debian ARM > virtual machine. And I carry out the libfbclient.so successfully. > > Now, I will test this library. With Java, it's seems impossible because > it can't communicate with Firebird for the moment. So I will try to use > Qt Necessitas. Do you think Necessitas can runs with Firebird ? > qt does have support for firebird , so if you compile the ibase driver it should in theory load the ibfbclient.so that you compiled and then comunicate with another server from internet (for example) |
From: JLM <so4...@ho...> - 2012-07-27 08:04:15
|
Hello, It's OK, I succeed in cross-compile the libfbclient. But there is 2 errors during the compilation : 1. There is missing the platform.h file in the extern/icu/source/common/unicode/ repertory of the firebird sources. 2. In the NDK, the libsupc++.a library isn't in the platforms/android-9/arch-arm/usr/lib, so the linker can't find it. I make a symlink from platforms/android-9/arch-arm/usr/lib to sources/cxx-stl/gnu-libstdc++/4.4.3/libs/armeabi/libsupc++.a of the NDK, where the file is present. And it's OK. Jean-Louis Meuriot |
From: Alex P. <pes...@ma...> - 2012-07-27 11:45:40
|
On 07/27/12 12:03, JLM wrote: > Hello, > > It's OK, I succeed in cross-compile the libfbclient. > But there is 2 errors during the compilation : > > 1. There is missing the platform.h file in the > extern/icu/source/common/unicode/ repertory of the firebird sources. > Yes. And BTW - we need this file for Android anyway. Did you have a chance to build ICU for Android? > 2. In the NDK, the libsupc++.a library isn't in the > platforms/android-9/arch-arm/usr/lib, so the linker can't find it. I > make a symlink from platforms/android-9/arch-arm/usr/lib to > sources/cxx-stl/gnu-libstdc++/4.4.3/libs/armeabi/libsupc++.a of the NDK, > where the file is present. And it's OK. > There is a line in LDFLAGS += --sysroot=$(CROSS_PLATFORM) -L$(NDK)/sources/cxx-stl/gnu-libstdc++/libs/armeabi I suppose the difference is that my NDK misses 4.4.3 before libc. And it builds w/o such symlink. Even not sure how to fix this issue better... |
From: JLM <so4...@ho...> - 2012-07-30 13:38:01
|
On 27/07/2012 13:45, Alex Peshkoff wrote: > > Yes. And BTW - we need this file for Android anyway. > Did you have a chance to build ICU for Android? > I have tried to compile ICU but it's seems not ready to runs on Android. The configure is not predicted to compile on Android-ARM, there is still the problem of the libc... I found a tutorial to make an Android version of ICU : http://stackoverflow.com/questions/3944207/unicode-support-in-android-ndk but I prefere to not do that beacause it's a makeshift job, and above all, an informal way. Jean-Louis Meuriot |
From: Alex P. <pes...@ma...> - 2012-07-31 07:48:21
|
On 07/30/12 17:37, JLM wrote: > On 27/07/2012 13:45, Alex Peshkoff wrote: > >> Yes. And BTW - we need this file for Android anyway. >> Did you have a chance to build ICU for Android? >> > I have tried to compile ICU but it's seems not ready to runs on Android. > The > configure is not predicted to compile on Android-ARM, there is still the > problem of the libc... > > I found a tutorial to make an Android version of ICU : > http://stackoverflow.com/questions/3944207/unicode-support-in-android-ndk > > but I prefere to not do that beacause it's a makeshift job, and above > all, an informal way. > Afraid we can't expect formal way too soon - probably only in 4.9+, as your link says. Luckily we need only platform.h file, probably we may try to generate it once using the patches from stackoverflow and keep that file in our tree. Will try when return actively to Android port. The most interesting question now is - what fixes do we need to make fbclient work? |
From: JLM <so4...@ho...> - 2012-07-31 16:06:48
Attachments:
firebirdtraffic.wireshark
firebirdtraffic.txt
|
On 31/07/2012 09:48, Alex Peshkoff wrote: > The most interesting question now is - what fixes do we need to make > fbclient work? I've tried to use the libfbclient with Necessitas. I used the IBase driver compiled for Android Arm. The libfbclient is load, seems to apparently runs. The libfbclient manage to contact the firebird server but there is problems during communication. I used Wireshark to look at the traffic and I've seen packet's error during the communication, packet from libfbclient. In view of the fact that my local server and my virtual device have the same IP adress, is not easy to read... But you can look at the ports : gds-db is my server on local machine and the 50946 and 50947 ports are the virtual machine. The virtual device try twice time to connect despite that the server responds OK twice time. And after that, it's impossible to execute a query, the result is "the database is not open" I add attachments of txt and wireshark version of the capture file. Jean-Louis Meuriot |
From: Alex P. <pes...@ma...> - 2012-08-01 07:03:01
|
On 07/31/12 20:06, JLM wrote: > On 31/07/2012 09:48, Alex Peshkoff wrote: > >> The most interesting question now is - what fixes do we need to make >> fbclient work? > > I've tried to use the libfbclient with Necessitas. I used the IBase > driver compiled for Android Arm. > > The libfbclient is load, seems to apparently runs. That's already not bad! > The libfbclient manage to contact the firebird server but there is > problems during communication. I used Wireshark to look at the traffic > and I've seen packet's error during the communication, packet from > libfbclient. Sooner of all wireshark does not recognize an attempt to talk using new protocol, FB13. That extensions are silently ignored by old servers, but may drive packet dumper crazy. In hex form packets look OK for me. Moreover, they are accepted by server. BTW, what version is installed? 2.5 or older? > > In view of the fact that my local server and my virtual device have > the same IP adress, is not easy to read... > But you can look at the ports : gds-db is my server on local machine > and the 50946 and 50947 ports are the virtual machine. No problems. > The virtual device try twice time to connect despite that the server > responds OK twice time. Server response is OK for 'connect' operation, next client sends 'attach' with dbname, login and password - and this operation fails (must be non-0 response object in frame 10. Second attempt is to use slightly other protocol, but password validation anyway fails. > And after that, it's impossible to execute a query, the result is "the > database is not open" > > I add attachments of txt and wireshark version of the capture file. During cross-build you've got native fbclient and some utilities in gen/Native. Can you try to connet to server with that isql and see what happens? Txt dump from wireshark, sent to me, will be very useful. A. |
From: JLM <so4...@ho...> - 2012-08-01 07:44:11
Attachments:
isql-firebird-traffic.txt
|
On 01/08/2012 09:02, Alex Peshkoff wrote: > On 07/31/12 20:06, JLM wrote: > Sooner of all wireshark does not recognize an attempt to talk using new > protocol, FB13. That extensions are silently ignored by old servers, but > may drive packet dumper crazy. In hex form packets look OK for me. > Moreover, they are accepted by server. BTW, what version is installed? > 2.5 or older? It is the 2.5 version server wich is installed. > During cross-build you've got native fbclient and some utilities in > gen/Native. Can you try to connet to server with that isql and see what > happens? Txt dump from wireshark, sent to me, will be very useful. It doesn't run : SQL> connect /home/menlog/compilation/employee.fdb password masterkey user SYSDBA; Statement failed, SQLSTATE = HY000 unsupported on-disk structure for file /home/menlog/compilation/employee.fdb; found 12.1, support 11.2 And though, it's the employee database from my 3.0 firebird compilation. Txt dump from wireshark is attached. Jean-Louis Meuriot |
From: Alex P. <pes...@ma...> - 2012-08-01 07:58:58
|
> unsupported on-disk structure for file > /home/menlog/compilation/employee.fdb; found 12.1, support 11.2 > And though, it's the employee database from my 3.0 firebird compilation. It's very bad idea to try to open database, created with 3.0, using 2.5 server. It will never open. |
From: JLM <so4...@ho...> - 2012-08-01 10:11:20
|
> It's very bad idea to try to open database, created with 3.0, using 2.5 > server. It will never open. Of course... I didn't give expression to that... So, in the fact I can't do a make install of Firebird 3.0, I've tried the server 2.5, with the 2.5 employee database, with Qt Necessitas using the ARM Firebird 3.0 libfbclient. And it works ! But very rarely... On 70 test - 55 times there is a Fatal signal 11 (SIGSEGV) on the opening database (without any network traffic) - 11 times the program freeze on the opening database (without any network traffic) - and 5 times the database is open, an query is executed and I receive good results... Only 5 times... So, why it's so random ? No idea... Jean-Louis Meuriot |
From: Alex P. <pes...@ma...> - 2012-08-01 11:13:21
|
On 08/01/12 14:10, JLM wrote: >> It's very bad idea to try to open database, created with 3.0, using 2.5 >> server. It will never open. > Of course... I didn't give expression to that... > > So, in the fact I can't do a make install of Firebird 3.0, I've tried > the server 2.5, with the 2.5 employee database, with Qt Necessitas using > the ARM Firebird 3.0 libfbclient. > > And it works ! > > But very rarely... > On 70 test > - 55 times there is a Fatal signal 11 (SIGSEGV) on the opening database > (without any network traffic) > - 11 times the program freeze on the opening database (without any > network traffic) > - and 5 times the database is open, an query is executed and I receive > good results... Only 5 times... > > So, why it's so random ? No idea... Looks like races. They are random. Can you get stack traces for Android? In many cases they are enough to fix a bug. |
From: Alex P. <pes...@ma...> - 2012-08-02 07:49:38
|
On 08/01/12 18:56, JLM wrote: > I've got news ! > When I use the Debug version of libfbclient, there is no errors, it runs > perfectly, all the time. > > So, maybe the optimization of the release's code go a bit too far ? > Quite possible. Please try to decrease optimization level in builds/posix/make.android.arme. There is line OPTIMIZE_FLAGS=-O3 -fno-omit-frame-pointer -O0 instead -O3 will be good first attempt. > PS : How to see debug messages ? There is no more message in the > console than the release version... > Debug build does not mean a lot of debugging output - one will die in them. That's a lot of assertions, some additional checks and no optimization. Debug output can be turned on in separate modules when required. |
From: Alex P. <pes...@ma...> - 2012-08-02 07:58:51
|
> Quite possible. > Please try to decrease optimization level in > builds/posix/make.android.arme. There is line > OPTIMIZE_FLAGS=-O3 -fno-omit-frame-pointer > -O0 instead -O3 will be good first attempt. > PS. Do not forget to run config.status after changing this file. |
From: JLM <so4...@ho...> - 2012-08-01 13:17:22
Attachments:
runningtest
witherror
|
On 01/08/2012 13:13, Alex Peshkoff wrote: > Looks like races. They are random. > Can you get stack traces for Android? In many cases they are enough to > fix a bug. I get stack traces of Android. I send a version with error and a version without error. Jean-Louis Meuriot |
From: Alex P. <pes...@ma...> - 2012-08-01 13:29:24
|
On 08/01/12 17:16, JLM wrote: > On 01/08/2012 13:13, Alex Peshkoff wrote: > >> Looks like races. They are random. >> Can you get stack traces for Android? In many cases they are enough to >> fix a bug. > > > I get stack traces of Android. I send a version with error and a > version without error. Sorry - I've forgotten the most important detail. Please type make Debug to do cross-compile. You will get version with full debug info in gen/Debug. Stack trace should be much better readable with it. |
From: JLM <so4...@ho...> - 2012-08-01 14:56:47
|
I've got news ! When I use the Debug version of libfbclient, there is no errors, it runs perfectly, all the time. So, maybe the optimization of the release's code go a bit too far ? PS : How to see debug messages ? There is no more message in the console than the release version... Jean-Louis Meuriot |
From: JLM <so4...@ho...> - 2012-08-01 08:21:24
|
> It's very bad idea to try to open database, created with 3.0, using 2.5 > server. It will never open. Of course... I didn't react to that... But I can't do a make install of Firebird 3.0, it freezes. So I can't have a Firebird 3.0 server. |
From: Alex P. <pes...@ma...> - 2012-08-01 08:28:30
|
On 08/01/12 12:20, JLM wrote: >> It's very bad idea to try to open database, created with 3.0, using 2.5 >> server. It will never open. > Of course... I didn't react to that... > But I can't do a make install of Firebird 3.0, it freezes. So I can't > have a Firebird 3.0 server. But you can create a database, using 2.5! |
From: JLM <so4...@ho...> - 2012-08-02 08:47:35
|
> Quite possible. > Please try to decrease optimization level in > builds/posix/make.android.arme. There is line > OPTIMIZE_FLAGS=-O3 -fno-omit-frame-pointer > -O0 instead -O3 will be good first attempt. It runs ! So the O3 gcc optimization was the problem. We can now say that the libfbclient for Android is running ! Now it miss "only" the libfbserver :) Jean-Louis Meuriot |
From: Alex P. <pes...@ma...> - 2012-08-02 11:51:57
|
On 08/02/12 12:47, JLM wrote: >> Quite possible. >> Please try to decrease optimization level in >> builds/posix/make.android.arme. There is line >> OPTIMIZE_FLAGS=-O3 -fno-omit-frame-pointer >> -O0 instead -O3 will be good first attempt. > It runs ! > So the O3 gcc optimization was the problem. > We can now say that the libfbclient for Android is running ! > Probably worth trying with O1 & O2? I understand that client is not (typically) time critical, but we will need to compile server for that platform. > Now it miss "only" the libfbserver :) > Yes. This will need some time to solve IPC issues. |