Hello,
 
within a thesis for Mr. Flatscher I try to port the ooRexx on Android. First step is to make build for the Android platform and therefore I use cmake (ooRexx Version 5.0.0) and the android NDK. To become more familiar with the ooRexx build I tried first to build a debian package on Ubuntu 15.10. After a successful build for Ubuntu of version 5, I am working now on the build for Android. But now I have 2 main problems:
 
1: It seams there is a problem with a type definition in rxsockfn.cpp.
- Full errormessage:
 93%] Building CXX object CMakeFiles/rxsock.dir/extensions/rxsock/rxsockfn.cpp.o
/home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp: In function 'int SockSelect_impl(RexxCallContext*, RexxObjectPtr, RexxObjectPtr, RexxObjectPtr, int)':
/home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp:835:12: error: using typedef-name 'fd_set' after 'struct'
     struct fd_set   rSetS, *rSet = &rSetS;
            ^
In file included from /home/klemens/DEV/software/android-ndk-r10e/platforms/android-19/arch-arm/usr/include/unistd.h:34:0,
                 from /home/klemens/DEV/workspace/ooRexx/main/api/platform/unix/rexxapitypes.h:46,
                 from /home/klemens/DEV/workspace/ooRexx/main/api/rexx.h:65,
                 from /home/klemens/DEV/workspace/ooRexx/main/api/oorexxapi.h:47,
                 from /home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp:56:
/home/klemens/DEV/software/android-ndk-r10e/platforms/android-19/arch-arm/usr/include/sys/select.h:38:27: note: 'fd_set' has a previous declaration here
 typedef __kernel_fd_set   fd_set;
                           ^
/home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp:835:26: error: invalid type in declaration before ',' token
     struct fd_set   rSetS, *rSet = &rSetS;
                          ^
/home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp:836:12: error: using typedef-name 'fd_set' after 'struct'
     struct fd_set   wSetS, *wSet = &wSetS;
            ^
In file included from /home/klemens/DEV/software/android-ndk-r10e/platforms/android-19/arch-arm/usr/include/unistd.h:34:0,
                 from /home/klemens/DEV/workspace/ooRexx/main/api/platform/unix/rexxapitypes.h:46,
                 from /home/klemens/DEV/workspace/ooRexx/main/api/rexx.h:65,
                 from /home/klemens/DEV/workspace/ooRexx/main/api/oorexxapi.h:47,
                 from /home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp:56:
/home/klemens/DEV/software/android-ndk-r10e/platforms/android-19/arch-arm/usr/include/sys/select.h:38:27: note: 'fd_set' has a previous declaration here
 typedef __kernel_fd_set   fd_set;
                           ^
/home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp:836:26: error: invalid type in declaration before ',' token
     struct fd_set   wSetS, *wSet = &wSetS;
                          ^
/home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp:837:12: error: using typedef-name 'fd_set' after 'struct'
     struct fd_set   eSetS, *eSet = &eSetS;
            ^
In file included from /home/klemens/DEV/software/android-ndk-r10e/platforms/android-19/arch-arm/usr/include/unistd.h:34:0,
                 from /home/klemens/DEV/workspace/ooRexx/main/api/platform/unix/rexxapitypes.h:46,
                 from /home/klemens/DEV/workspace/ooRexx/main/api/rexx.h:65,
                 from /home/klemens/DEV/workspace/ooRexx/main/api/oorexxapi.h:47,
                 from /home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp:56:
/home/klemens/DEV/software/android-ndk-r10e/platforms/android-19/arch-arm/usr/include/sys/select.h:38:27: note: 'fd_set' has a previous declaration here
 typedef __kernel_fd_set   fd_set;
                           ^
/home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp:837:26: error: invalid type in declaration before ',' token
     struct fd_set   eSetS, *eSet = &eSetS;
                          ^
/home/klemens/DEV/workspace/ooRexx/main/extensions/rxsock/rxsockfn.cpp:921:46: error: cannot convert 'int*' to 'fd_set* {aka __kernel_fd_set*}' for argument '2' to 'int select(int, fd_set*, fd_set*, fd_set*, timeval*)'
     rc = select(max+1,rSet,wSet,eSet,timeOutP);
                                              ^
CMakeFiles/rxsock.dir/build.make:77: recipe for target 'CMakeFiles/rxsock.dir/extensions/rxsock/rxsockfn.cpp.o' failed
make[2]: *** [CMakeFiles/rxsock.dir/extensions/rxsock/rxsockfn.cpp.o] Error 1
CMakeFiles/Makefile2:630: recipe for target 'CMakeFiles/rxsock.dir/all' failed
make[1]: *** [CMakeFiles/rxsock.dir/all] Error 2
Makefile:136: recipe for target 'all' failed
make: *** [all] Error 2
 
 
2: The second problem refers to the curses.h - I had a similar problem with curses.h when building for Ubuntu, but in this case I installed the curses files with sudo apt-get install libncurses5-dev libncursesw5-dev. But for the android platform I cannot find this library and I don't know how to link it in the build.
 
[ 83%] Building CXX object CMakeFiles/orxncurses.dir/extensions/orxncurses/orxncurses.cpp.o
/home/klemens/DEV/workspace/ooRexx/main/extensions/orxncurses/orxncurses.cpp:50:20: fatal error: curses.h: No such file or directory
 #include <curses.h>
                    ^
compilation terminated.
CMakeFiles/orxncurses.dir/build.make:54: recipe for target 'CMakeFiles/orxncurses.dir/extensions/orxncurses/orxncurses.cpp.o' failed
make[2]: *** [CMakeFiles/orxncurses.dir/extensions/orxncurses/orxncurses.cpp.o] Error 1
CMakeFiles/Makefile2:132: recipe for target 'CMakeFiles/orxncurses.dir/all' failed
make[1]: *** [CMakeFiles/orxncurses.dir/all] Error 2
Makefile:136: recipe for target 'all' failed
make: *** [all] Error 2
 
I am not a professional in C/C++ programming language and also not for cmake. Maybe someone of you has an idea and can help me, I am thankful for any suggestions. 
 
I use:
cmake version: 3.2.2
android ndk: r10e
OS: ubuntu 1510
ooRexx: trunk
 
Best Regards, Klemens Engelbrechtsmüller
 
------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
_______________________________________________
Oorexx-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/oorexx-devel

Reply via email to