Re: [Oorexx-devel] Update on ooRexx -> Android

2023-12-16 Thread Thomas Grundmann-Kahr
Hi P.O.,

Sorry for the Late reply. I really dont think that this is any good. Android TV 
is an operating System based on Android but cut down to minimal Features for 
Multimedia streaming and so one. We would not be alle to test or run ooRexx on 
it.

In we want to try ooRexx on a device it would have to be a smart phone or 
Android Running on a Virtual machine like yours.

To get back to your VM's. I still havent figured out how to Transfer files to 
the VM.
But im working on the APK (Package to install an App in Android) as soon it is 
available I will contact you and we will figure out a way to install my apk.

Best regards
Thomas


Von: P. O. Jonsson 
Gesendet: Sonntag, Dezember 10, 2023 1:40 PM
An: Open Object Rexx Developer Mailing List 
Betreff: Re: [Oorexx-devel] Update on ooRexx -> Android

Hi Thomas,

What would be a good platform for testing, something like this?

<https://www.googleadservices.com/pagead/aclk?sa=L=DChcSEwi1rP7k7oSDAxUUxNUKHfQZAQ0YABATGgJ3cw=2==www.google.com=CAASJeRoLPSNj9hindG1uxLlCqAlSHUhfeOgLAKzskSj0x-Tnr9NHzQ=AOD64_0SMi_tHf1xpbIoGo7FSuyRYZE2Dw=5==2ahUKEwiNzPfk7oSDAxUcSfEDHXx9CdsQwg8oAHoECAUQMw=>
[41o2ixAoxAL._SR600,315_PIWhiteStrip,BottomLeft,0,35_PIStarRatingTHREEANDHALF,BottomLeft,360,-6_SR600,315_ZA31,445,290,400,400,AmazonEmberBold,12,4,0,0,5_SCLZZZ_FMpng_BG255,255,255.jpg]
Android 13.0 TV Box 4GB RAM 64GB ROM,TV Box Android mit RK3528 Quad-Core 64bit 
Cortex-A53 chip,Smart TV Box 8K UHD Videos,2.4G/5G Dual WiFi Bluetooth 5.0 mit 
kabelloser 
Mini-Tastatur,Schwarz<https://www.googleadservices.com/pagead/aclk?sa=L=DChcSEwi1rP7k7oSDAxUUxNUKHfQZAQ0YABATGgJ3cw=2==www.google.com=CAASJeRoLPSNj9hindG1uxLlCqAlSHUhfeOgLAKzskSj0x-Tnr9NHzQ=AOD64_0SMi_tHf1xpbIoGo7FSuyRYZE2Dw=5==2ahUKEwiNzPfk7oSDAxUcSfEDHXx9CdsQwg8oAHoECAUQMw=>
googleadservices.com<https://www.googleadservices.com/pagead/aclk?sa=L=DChcSEwi1rP7k7oSDAxUUxNUKHfQZAQ0YABATGgJ3cw=2==www.google.com=CAASJeRoLPSNj9hindG1uxLlCqAlSHUhfeOgLAKzskSj0x-Tnr9NHzQ=AOD64_0SMi_tHf1xpbIoGo7FSuyRYZE2Dw=5==2ahUKEwiNzPfk7oSDAxUcSfEDHXx9CdsQwg8oAHoECAUQMw=>


Any advice welcome

Von meinem iPhone gesendet

Am 10.12.2023 um 12:24 schrieb Erich Steinböck :


Hi Thomas,
the CMake config issues seem to be fixed. Found and not found configs look 
reasonable.

I'm not aware of any other ooRexx cross-compile attempt, so this is new 
territory for us.
To complete your build you can try commenting out the six lines after # Build 
the rexx.img file
and add a line
message(STATUS "rexximage ${ORX_IMAGE_OUTPUT_LOCATION}/rexx.img")
When the build has completed you can run the built rexximage executable in an 
Android shell.
The above message will show you which argument you should supply (although the 
path might be different between what your compile host sees and what the 
Android shell sees).

Moving an existing rexx.img might also work as long as host and Android are the 
same bitness and architecture.

Are you cross-building for a different architecture, like from x86 to ARM?
Does the cross build allow building Android 32 bit (when your host is 64 bit)?
Do you run the Android code on an Emulator or are you pushing the build 
artifacts to an actual Android hardware?
Did you note down the steps necessary to successfully set up Android NDK and 
Emulator for an ooRexx cross-compile?  If yes, can you share the them?
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Update on ooRexx -> Android

2023-12-16 Thread Thomas Grundmann-Kahr
Hi Erich,

to your questions:

Yes, ist Perfectly Fine to build for 32 bit on a 64 bit machine. Its also 
possible to build for ARM on any host system. Its as simple as setting a flag 
to do so.
At the moment Im on x86_64 and build for x86_64. So no difference.

Im running a virtual device on my laptop. Its much more comfortable to work 
like that.

There are 2 ways to install the Android NDK. As far as I know, there is a 
standalone version which I think is CLI.
Just for building this is perfectly fine. But in most cases Android Studio is 
necessary for one or the other reason.

So, I just can explain the process in combination with Android Studio. In fact, 
I did so in my Seminar Paper. I will attach it for you. Every step should be 
explained in my paper. Still, if you run into troubles just reach out.

Best regards
Thomas


Von: Erich Steinböck 
Gesendet: Sonntag, Dezember 10, 2023 12:24 PM
An: Open Object Rexx Developer Mailing List 
Betreff: Re: [Oorexx-devel] Update on ooRexx -> Android

Hi Thomas,
the CMake config issues seem to be fixed. Found and not found configs look 
reasonable.

I'm not aware of any other ooRexx cross-compile attempt, so this is new 
territory for us.
To complete your build you can try commenting out the six lines after # Build 
the rexx.img file
and add a line
message(STATUS "rexximage ${ORX_IMAGE_OUTPUT_LOCATION}/rexx.img")
When the build has completed you can run the built rexximage executable in an 
Android shell.
The above message will show you which argument you should supply (although the 
path might be different between what your compile host sees and what the 
Android shell sees).

Moving an existing rexx.img might also work as long as host and Android are the 
same bitness and architecture.

Are you cross-building for a different architecture, like from x86 to ARM?
Does the cross build allow building Android 32 bit (when your host is 64 bit)?
Do you run the Android code on an Emulator or are you pushing the build 
artifacts to an actual Android hardware?
Did you note down the steps necessary to successfully set up Android NDK and 
Emulator for an ooRexx cross-compile?  If yes, can you share the them?
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Update on ooRexx -> Android

2023-12-10 Thread P. O. Jonsson
Hi Thomas,What would be a good platform for testing, something like this?Android 13.0 TV Box 4GB RAM 64GB ROM,TV Box Android mit RK3528 Quad-Core 64bit Cortex-A53 chip,Smart TV Box 8K UHD Videos,2.4G/5G Dual WiFi Bluetooth 5.0 mit kabelloser Mini-Tastatur,Schwarzgoogleadservices.comAny advice welcome Von meinem iPhone gesendetAm 10.12.2023 um 12:24 schrieb Erich Steinböck :Hi Thomas,the CMake config issues seem to be fixed. Found and not found configs look reasonable.I'm not aware of any other ooRexx cross-compile attempt, so this is new territory for us.To complete your build you can try commenting out the six lines after # Build the rexx.img fileand add a linemessage(STATUS "rexximage ${ORX_IMAGE_OUTPUT_LOCATION}/rexx.img")When the build has completed you can run the built rexximage executable in an Android shell.The above message will show you which argument you should supply (although the path might be different between what your compile host sees and what the Android shell sees).Moving an existing rexx.img might also work as long as host and Android are the same bitness and architecture.Are you cross-building for a different architecture, like from x86 to ARM?Does the cross build allow building Android 32 bit (when your host is 64 bit)?Do you run the Android code on an Emulator or are you pushing the build artifacts to an actual Android hardware?Did you note down the steps necessary to successfully set up Android NDK and Emulator for an ooRexx cross-compile?  If yes, can you share the them?
___Oorexx-devel mailing listOorexx-devel@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/oorexx-devel___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Update on ooRexx -> Android

2023-12-10 Thread Erich Steinböck
Hi Thomas,
the CMake config issues seem to be fixed. Found and not found configs look
reasonable.

I'm not aware of any other ooRexx cross-compile attempt, so this is new
territory for us.
To complete your build you can try commenting out the six lines after #
Build the rexx.img file
and add a line
message(STATUS "rexximage ${ORX_IMAGE_OUTPUT_LOCATION}/rexx.img")
When the build has completed you can run the built rexximage executable in
an Android shell.
The above message will show you which argument you should supply (although
the path might be different between what your compile host sees and what
the Android shell sees).

Moving an existing rexx.img might also work as long as host and Android are
the same bitness and architecture.

Are you cross-building for a different architecture, like from x86 to ARM?
Does the cross build allow building Android 32 bit (when your host is 64
bit)?
Do you run the Android code on an Emulator or are you pushing the build
artifacts to an actual Android hardware?
Did you note down the steps necessary to successfully set up Android NDK
and Emulator for an ooRexx cross-compile?  If yes, can you share the them?
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Update on ooRexx -> Android

2023-12-09 Thread Thomas Grundmann-Kahr
Hi Erich,

thank you so much! It works!
But let me explain:


  *
I worked with the latest commits. 12748
  *
The output of cmake-command is in the cmake_command.txt File.
  *
The CMakeError.log is attached too. Although, it doesnt seem to be much 
different. There are more errors regarding pthread now.
  *
It works seamlessly till rexximage. But that is understandable as I know.
Normally I change something in the CMakeLists.txt. I forgot to mention. 
rexx.img will be created and as I understood the executable rexximage is 
necessary for that step.
The problem at this point is that rexximage was created over the Android 
Toolchain and so the created file is not executable on the host machine 
anymore. So, rexx.img cannot be created.
I solved this problem easily with commenting out everything regarding rexx.img 
and taking a rexx.img file which was build for my Linux Ubuntu Host System and 
simply copied it to /lib folder.
On my Android Device this works. As I understood one needs a working rexximage 
File for the Host System to create rexx.img during the compilation process. I 
dont know which strategy is best here. What I already did was to change the 
CMakeLists.txt, so that no rexx.img file is created during the compilation. 
Instead, an already existing rexx.img File file is copied into the right 
folder. That works but is not the solution, I guess. I would be thankful for a 
strategy how to solve this problem in a good way. Maybe there is already a 
strategy because this will happen with every cross-compilation of oorexx, right?


Besides that, everything is working Erich. No "getstackbase" or "getstacksize" 
errors anymore. Commenting out rexx.img and it compiles without any problem.
Output build:
...
[ 71%] Built target rexx_exe
[ 72%] Building CXX object 
CMakeFiles/rexximage.dir/utilities/rexximage/rexximage.cpp.o
[ 72%] Linking CXX executable bin/rexximage
[ 72%] Built target rexximage
[ 72%] Building CXX object CMakeFiles/rxapi.dir/rexxapi/server/APIServer.cpp.o
[ 73%] Building CXX object 
CMakeFiles/rxapi.dir/rexxapi/server/APIServerInstance.cpp.o
[ 73%] Building CXX object 
CMakeFiles/rxapi.dir/rexxapi/server/APIServerThread.cpp.o
[ 73%] Building CXX object 
CMakeFiles/rxapi.dir/rexxapi/server/MacroSpaceManager.cpp.o
[ 73%] Building CXX object 
CMakeFiles/rxapi.dir/rexxapi/server/QueueManager.cpp.o
[ 74%] Building CXX object 
CMakeFiles/rxapi.dir/rexxapi/server/RegistrationManager.cpp.o
[ 74%] Building CXX object CMakeFiles/rxapi.dir/rexxapi/common/CSStream.cpp.o
[ 74%] Building CXX object 
CMakeFiles/rxapi.dir/rexxapi/common/RegistrationTable.cpp.o
[ 75%] Building CXX object 
CMakeFiles/rxapi.dir/rexxapi/common/ServiceMessage.cpp.o
[ 75%] Building CXX object 
CMakeFiles/rxapi.dir/rexxapi/common/platform/unix/SysAPIManager.cpp.o
[ 75%] Building CXX object CMakeFiles/rxapi.dir/common/Utilities.cpp.o
[ 76%] Building CXX object 
CMakeFiles/rxapi.dir/common/platform/unix/SysProcess.cpp.o
[ 76%] Building CXX object 
CMakeFiles/rxapi.dir/common/platform/unix/SysSemaphore.cpp.o
[ 76%] Building CXX object 
CMakeFiles/rxapi.dir/common/platform/unix/SysThread.cpp.o
[ 76%] Building CXX object 
CMakeFiles/rxapi.dir/rexxapi/common/platform/unix/SysCSStream.cpp.o
[ 77%] Building CXX object 
CMakeFiles/rxapi.dir/rexxapi/server/platform/unix/APIService.cpp.o
[ 77%] Linking CXX executable bin/rxapi
[ 77%] Built target rxapi
[ 77%] Generating bin/PlatformObjects.orx
[ 77%] Generating bin/CoreClasses.orx
[ 78%] Generating bin/StreamClasses.orx
[ 79%] Generating lib/rexx.img
/bin/sh: 1: /home/roottjk/oorexx/oorexxbuild/current/bin/rexximage: not found
make[2]: *** [CMakeFiles/rexx_img.dir/build.make:77: lib/rexx.img] Error 127
make[1]: *** [CMakeFiles/Makefile2:451: CMakeFiles/rexx_img.dir/all] Error 2
make: *** [Makefile:156: all] Error 2

Have a good day.
Thomas


From: Erich Steinb?ck 
Sent: Saturday, December 9, 2023 7:44 PM
To: Open Object Rexx Developer Mailing List 
Subject: Re: [Oorexx-devel] Update on ooRexx -> Android

Hi Thomas,
I've committed a fix to our CMake - it should now be able handle the missing 
libpthread on Android.

The attached CMakeError.log don't show all HAVE_PTHREAD_* configuration errors 
- not sure why, but it shows issues with libpthread not found which should now 
go away.
Please delete the CMake cache, re-run cmake, and provide the CMake build outout 
and also again the log file.

Determining if the include file filehdr.h exists failed with the following output:
Change Dir: /home/roottjk/oorexx/oorexxbuild/current/CMakeFiles/CMakeTmp

Run Build Command(s):/usr/bin/gmake -f Makefile cmTC_54208/fast && /usr/bin/gmake  -f CMakeFiles/cmTC_54208.dir/build.make CMakeFiles/cmTC_54208.dir/build
gmake[1]: Entering directory '/home/roottjk/oorexx/oorexxbuild/current/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_54208.dir/CheckIncludeFile.c.o
/home/roottjk/Android/Sdk/ndk/26.1.10909125/toolchains/llvm/prebuilt/linux-x

Re: [Oorexx-devel] Update on ooRexx -> Android

2023-12-09 Thread Erich Steinböck
Hi Thomas,
I've committed a fix to our CMake - it should now be able handle the
missing libpthread on Android.

The attached CMakeError.log don't show all HAVE_PTHREAD_* configuration
errors - not sure why, but it shows issues with libpthread not found which
should now go away.
Please delete the CMake cache, re-run cmake, and provide the CMake build
outout and also again the log file.
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Update on ooRexx -> Android

2023-12-09 Thread Thomas Grundmann-Kahr
Hi Erich,

sure! I attached the CMakeError.log File. Unfortunately, not every "not found" 
is an error.
If you need something else Im ready to deliver!

Best regards
Thomas

From: Erich Steinb?ck 
Sent: Friday, December 8, 2023 6:14 PM
To: Open Object Rexx Developer Mailing List 
Subject: Re: [Oorexx-devel] Update on ooRexx -> Android

Hi Thomas,
it seems that Android has no pthreads lib (it is built-in into libc instead).  
I will make appropriate changes to our CMake.
Can you attach CMakeFiles/CMakeError.log so that we can see why 
pthread_attr_get_np isn't found (and also none ogf the others).
Thanks!
Determining if the function nsleep exists failed with the following output:
Change Dir: /home/roottjk/oorexx/oorexxbuild/12695_bac/CMakeFiles/CMakeTmp

Run Build Command(s):/usr/bin/gmake -f Makefile cmTC_538d6/fast && /usr/bin/gmake  -f CMakeFiles/cmTC_538d6.dir/build.make CMakeFiles/cmTC_538d6.dir/build
gmake[1]: Entering directory '/home/roottjk/oorexx/oorexxbuild/12695_bac/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_538d6.dir/CheckFunctionExists.c.o
/home/roottjk/Android/Sdk/ndk/26.1.10909125/toolchains/llvm/prebuilt/linux-x86_64/bin/clang --target=x86_64-none-linux-android34 --sysroot=/home/roottjk/Android/Sdk/ndk/26.1.10909125/toolchains/llvm/prebuilt/linux-x86_64/sysroot   -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security  -DCHECK_FUNCTION_EXISTS=nsleep -fPIE -MD -MT CMakeFiles/cmTC_538d6.dir/CheckFunctionExists.c.o -MF CMakeFiles/cmTC_538d6.dir/CheckFunctionExists.c.o.d -o CMakeFiles/cmTC_538d6.dir/CheckFunctionExists.c.o -c /usr/share/cmake-3.22/Modules/CheckFunctionExists.c
Linking C executable cmTC_538d6
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_538d6.dir/link.txt --verbose=1
/home/roottjk/Android/Sdk/ndk/26.1.10909125/toolchains/llvm/prebuilt/linux-x86_64/bin/clang --target=x86_64-none-linux-android34 --sysroot=/home/roottjk/Android/Sdk/ndk/26.1.10909125/toolchains/llvm/prebuilt/linux-x86_64/sysroot -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security  -DCHECK_FUNCTION_EXISTS=nsleep -static-libstdc++ -Wl,--build-id=sha1 -Wl,--no-undefined-version -Wl,--fatal-warnings -Wl,--no-undefined -Qunused-argumentsCMakeFiles/cmTC_538d6.dir/CheckFunctionExists.c.o -o cmTC_538d6  -latomic -lm 
ld.lld: error: undefined symbol: nsleep
>>> referenced by CheckFunctionExists.c:17 (/usr/share/cmake-3.22/Modules/CheckFunctionExists.c:17)
>>>   CMakeFiles/cmTC_538d6.dir/CheckFunctionExists.c.o:(main)
>>> did you mean: usleep
>>> defined in: /home/roottjk/Android/Sdk/ndk/26.1.10909125/toolchains/llvm/prebuilt/linux-x86_64/sysroot/usr/lib/x86_64-linux-android/34/libc.so
clang: error: linker command failed with exit code 1 (use -v to see invocation)
gmake[1]: *** [CMakeFiles/cmTC_538d6.dir/build.make:100: cmTC_538d6] Error 1
gmake[1]: Leaving directory '/home/roottjk/oorexx/oorexxbuild/12695_bac/CMakeFiles/CMakeTmp'
gmake: *** [Makefile:127: cmTC_538d6/fast] Error 2



Determining if the function crypt exists in the crypt failed with the following output:
Change Dir: /home/roottjk/oorexx/oorexxbuild/12695_bac/CMakeFiles/CMakeTmp

Run Build Command(s):/usr/bin/gmake -f Makefile cmTC_576a6/fast && /usr/bin/gmake  -f CMakeFiles/cmTC_576a6.dir/build.make CMakeFiles/cmTC_576a6.dir/build
gmake[1]: Entering directory '/home/roottjk/oorexx/oorexxbuild/12695_bac/CMakeFiles/CMakeTmp'
Building C object CMakeFiles/cmTC_576a6.dir/CheckFunctionExists.c.o
/home/roottjk/Android/Sdk/ndk/26.1.10909125/toolchains/llvm/prebuilt/linux-x86_64/bin/clang --target=x86_64-none-linux-android34 --sysroot=/home/roottjk/Android/Sdk/ndk/26.1.10909125/toolchains/llvm/prebuilt/linux-x86_64/sysroot   -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security  -DCHECK_FUNCTION_EXISTS=crypt -fPIE -MD -MT CMakeFiles/cmTC_576a6.dir/CheckFunctionExists.c.o -MF CMakeFiles/cmTC_576a6.dir/CheckFunctionExists.c.o.d -o CMakeFiles/cmTC_576a6.dir/CheckFunctionExists.c.o -c /usr/share/cmake-3.22/Modules/CheckFunctionExists.c
Linking C executable cmTC_576a6
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_576a6.dir/link.txt --verbose=1
/home/roottjk/Android/Sdk/ndk/26.1.10909125/toolchains/llvm/prebuilt/linux-x86_64/bin/clang --target=x86_64-none-linux-android34 --sysroot=/home/roottjk/Android/Sdk/ndk/26.1.10909125/toolchains/llvm/prebuilt/linux-x86_64/sysroot -g -DANDROID -fdata-sections -ffunction-sections -funwind-tables -fstack-protector-strong -no-canonical-prefixes -D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security  -DCHECK_FUNCTION_EXISTS=crypt -static-libstdc++ -Wl,--build-id=sha1 -

Re: [Oorexx-devel] Update on ooRexx -> Android

2023-12-08 Thread Erich Steinböck
Hi Thomas,
it seems that Android has no pthreads lib (it is built-in into libc
instead).  I will make appropriate changes to our CMake.
Can you attach CMakeFiles/CMakeError.log so that we can see why
pthread_attr_get_np isn't found (and also none ogf the others).
Thanks!
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


Re: [Oorexx-devel] Update on ooRexx -> Android

2023-12-02 Thread Erich Steinböck
Hi Thomas,
thanks for reporting these issues!

PTHREAD cannot be handled by Android
>
The getStackSize and getStackBase functions require pthread_getattr_np.
It looks like this should be available on Android in  any API level - see
https://cs.android.com/android/platform/superproject/+/master:bionic/libc/include/pthread.h
which lists pthread_getattr_np()
cmake checks for the availability of this function and sets
HAVE_PTHREAD_ATTR_GET_NP appropriately.
Can you please provide the cmake command syntax you are using for the
cross-compile?
Can you please copy/paste the HAVE_PTHREAD_... results that cmake reports?

Please provide compiler error messages whenever possible (copy/paste text
preferred over screenshots).
"caused problems during compilation" isn't enough to investigate

I've just committed fixes for the SO_USELOOPBACK and the struct fd_set
issues.
___
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel