[Pharo-project] Pharo 2.0 on Raspberry Pi ?
Hi, Does anyone know how to make Pharo 2.0 run on a Raspberry Pi ? I am running an up to date 2012-10-28-wheezy-raspbian (Linux raspberrypi 3.2.27+ #250 PREEMPT Thu Oct 18 19:03:02 BST 2012 armv6l). There seems to be a Stack VM on it, it does run Smalltalk code, but there is some initialization error, a loop of VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 22 November 2012 8:55:09.996 pm in PharoDebug.log. I will (try to) look deeper into this, but if someone knows how to get things working, I would be grateful for any help. It would be really great if we as a community would be able to offer this as an option. Thx, Sven PS: I specifically want to run a (possibly patched) Pharo 2.0 image, not something else. -- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
I am making progress. It seems 1.4 does run out of the box, at least headless: pi@raspberrypi ~/Pharo-1.4 $ cat test.st FileStream stdout nextPutAll: 'Hello World, 42 factorial = '; print: 42 factorial; crlf; flush. Smalltalk quitPrimitive. pi@raspberrypi ~/Pharo-1.4 $ /usr/lib/squeak/4.4.7-2357/squeakvm -vm-display-null -vm-sound-null /home/pi/Pharo-1.4/Pharo-1.4.image /home/pi/Pharo-1.4/test.st Hello World, 42 factorial = 1405006117752879898543142606244511569936384000000000 No HTTP server like apache is installed by default, lucky Zn comes with Pharo then ;-) pi@raspberrypi ~/Pharo-1.4 $ cat zn.st ZnServer startDefaultOn: 1701. pi@raspberrypi ~/Pharo-1.4 $ /usr/lib/squeak/4.4.7-2357/squeakvm -vm-display-null -vm-sound-null /home/pi/Pharo-1.4/Pharo-1.4.image /home/pi/Pharo-1.4/zn.st And now visit http://localhost:1701 or (with avahi-daemon installed) http://raspberrypi.local:1701 from another machine, at first sight everything seems to work as expected. Things are a bit slow with the slower ARM CPU and a Stack VM, but that is normal. As for 2.0, there seems to be some startup problem: THERE_BE_DRAGONS_HERE ==== Startup Error: FileDoesNotExist: file:///usr/lib/squeak/4.4.7-2357 23 November 2012 5:33:13.051 pm VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 23 November 2012 5:33:13.068 pm VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 23 November 2012 5:33:13.089 pm VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 23 November 2012 5:33:13.106 pm VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 23 November 2012 5:33:13.123 pm Some code is referring to the VM directory and that seems to fail. Funny there is no better/usable stacktrace. I wonder whether FileSystem is completely supported on older VMs ? Sven On 23 Nov 2012, at 13:57, Sven Van Caekenberghe <sven@stfx.eu> wrote:
Hi,
Does anyone know how to make Pharo 2.0 run on a Raspberry Pi ?
I am running an up to date 2012-10-28-wheezy-raspbian (Linux raspberrypi 3.2.27+ #250 PREEMPT Thu Oct 18 19:03:02 BST 2012 armv6l). There seems to be a Stack VM on it, it does run Smalltalk code, but there is some initialization error, a loop of
VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 22 November 2012 8:55:09.996 pm
in PharoDebug.log.
I will (try to) look deeper into this, but if someone knows how to get things working, I would be grateful for any help.
It would be really great if we as a community would be able to offer this as an option.
Thx,
Sven
PS: I specifically want to run a (possibly patched) Pharo 2.0 image, not something else.
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
Hello. Can you share prebuilt VM? I have linux mobile phone (meegoOS with ARMv7 processor). And I really want pharo on it. I try built VM by myself but without success. Best regards, Denis 2012/11/23 Sven Van Caekenberghe <sven@stfx.eu>
I am making progress.
It seems 1.4 does run out of the box, at least headless:
pi@raspberrypi ~/Pharo-1.4 $ cat test.st
FileStream stdout nextPutAll: 'Hello World, 42 factorial = '; print: 42 factorial; crlf; flush.
Smalltalk quitPrimitive.
pi@raspberrypi ~/Pharo-1.4 $ /usr/lib/squeak/4.4.7-2357/squeakvm -vm-display-null -vm-sound-null /home/pi/Pharo-1.4/Pharo-1.4.image /home/pi/Pharo-1.4/test.st
Hello World, 42 factorial = 1405006117752879898543142606244511569936384000000000
No HTTP server like apache is installed by default, lucky Zn comes with Pharo then ;-)
pi@raspberrypi ~/Pharo-1.4 $ cat zn.st
ZnServer startDefaultOn: 1701.
pi@raspberrypi ~/Pharo-1.4 $ /usr/lib/squeak/4.4.7-2357/squeakvm -vm-display-null -vm-sound-null /home/pi/Pharo-1.4/Pharo-1.4.image /home/pi/Pharo-1.4/zn.st
And now visit http://localhost:1701 or (with avahi-daemon installed) http://raspberrypi.local:1701 from another machine, at first sight everything seems to work as expected. Things are a bit slow with the slower ARM CPU and a Stack VM, but that is normal.
As for 2.0, there seems to be some startup problem:
THERE_BE_DRAGONS_HERE ==== Startup Error: FileDoesNotExist: file:///usr/lib/squeak/4.4.7-2357 23 November 2012 5:33:13.051 pm
VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 23 November 2012 5:33:13.068 pm
VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 23 November 2012 5:33:13.089 pm
VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 23 November 2012 5:33:13.106 pm
VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 23 November 2012 5:33:13.123 pm
Some code is referring to the VM directory and that seems to fail. Funny there is no better/usable stacktrace.
I wonder whether FileSystem is completely supported on older VMs ?
Sven
On 23 Nov 2012, at 13:57, Sven Van Caekenberghe <sven@stfx.eu> wrote:
Hi,
Does anyone know how to make Pharo 2.0 run on a Raspberry Pi ?
I am running an up to date 2012-10-28-wheezy-raspbian (Linux raspberrypi 3.2.27+ #250 PREEMPT Thu Oct 18 19:03:02 BST 2012 armv6l). There seems to be a Stack VM on it, it does run Smalltalk code, but there is some initialization error, a loop of
VM: unix - armv7l - linux - THERE_BE_DRAGONS_HERE MessageNotUnderstood: receiver of "do:" is nil 22 November 2012 8:55:09.996 pm
in PharoDebug.log.
I will (try to) look deeper into this, but if someone knows how to get things working, I would be grateful for any help.
It would be really great if we as a community would be able to offer this as an option.
Thx,
Sven
PS: I specifically want to run a (possibly patched) Pharo 2.0 image, not something else.
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
Hi Denis, On 24 Nov 2012, at 11:25, Denis Kudriashov <dionisiydk@gmail.com> wrote:
Hello.
Can you share prebuilt VM? I have linux mobile phone (meegoOS with ARMv7 processor). And I really want pharo on it. I try built VM by myself but without success.
Best regards, Denis
Here is a .tgz of the VM https://dl.dropbox.com/u/16235440/raspberrypi-squeak.tgz as well as some additional info about the executables pi@raspberrypi ~ $ file /usr/lib/squeak/4.4.7-2357/squeakvm /usr/lib/squeak/4.4.7-2357/squeakvm: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.26, BuildID[sha1]=0xee98a23c74f457d15c4b70c8c21e640dd0b375d9, stripped pi@raspberrypi ~ $ file /usr/lib/squeak/4.4.7-2357/so.UUIDPlugin /usr/lib/squeak/4.4.7-2357/so.UUIDPlugin: ELF 32-bit LSB shared object, ARM, version 1 (SYSV), dynamically linked, BuildID[sha1]=0xe3771585b163d3706ba159f7e024488615e56771, stripped pi@raspberrypi ~ $ ldd /usr/lib/squeak/4.4.7-2357/squeakvm /usr/lib/arm-linux-gnueabihf/libcofi_rpi.so (0x4031c000) libm.so.6 => /lib/arm-linux-gnueabihf/libm.so.6 (0x40192000) libdl.so.2 => /lib/arm-linux-gnueabihf/libdl.so.2 (0x40085000) libfreetype.so.6 => /usr/lib/arm-linux-gnueabihf/libfreetype.so.6 (0x40001000) libnsl.so.1 => /lib/arm-linux-gnueabihf/libnsl.so.1 (0x40090000) libgcc_s.so.1 => /lib/arm-linux-gnueabihf/libgcc_s.so.1 (0x400e7000) libc.so.6 => /lib/arm-linux-gnueabihf/libc.so.6 (0x40325000) /lib/ld-linux-armhf.so.3 (0x400b6000) libz.so.1 => /lib/arm-linux-gnueabihf/libz.so.1 (0x4010f000) I hope your system is compatible⦠Regards, Sven -- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
Hello. Thank's for share. But unfortunatelly I cant run squeakvm. I have error -sh: ./squeakvm: not found (same with full headless image script) I extract tar to usr/lib and I can run hello.sh file with some echo from it. But squeakvm strangelly not work. And I have other executalbe binaries which I can just copy to phone and run. Google not help me yet Best regards, Denis 2012/11/24 Sven Van Caekenberghe <sven@stfx.eu>
Hi Denis,
On 24 Nov 2012, at 11:25, Denis Kudriashov <dionisiydk@gmail.com> wrote:
Hello.
Can you share prebuilt VM? I have linux mobile phone (meegoOS with ARMv7 processor). And I really want pharo on it. I try built VM by myself but without success.
Best regards, Denis
Here is a .tgz of the VM
https://dl.dropbox.com/u/16235440/raspberrypi-squeak.tgz
as well as some additional info about the executables
pi@raspberrypi ~ $ file /usr/lib/squeak/4.4.7-2357/squeakvm /usr/lib/squeak/4.4.7-2357/squeakvm: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.26, BuildID[sha1]=0xee98a23c74f457d15c4b70c8c21e640dd0b375d9, stripped
pi@raspberrypi ~ $ file /usr/lib/squeak/4.4.7-2357/so.UUIDPlugin /usr/lib/squeak/4.4.7-2357/so.UUIDPlugin: ELF 32-bit LSB shared object, ARM, version 1 (SYSV), dynamically linked, BuildID[sha1]=0xe3771585b163d3706ba159f7e024488615e56771, stripped
pi@raspberrypi ~ $ ldd /usr/lib/squeak/4.4.7-2357/squeakvm /usr/lib/arm-linux-gnueabihf/libcofi_rpi.so (0x4031c000) libm.so.6 => /lib/arm-linux-gnueabihf/libm.so.6 (0x40192000) libdl.so.2 => /lib/arm-linux-gnueabihf/libdl.so.2 (0x40085000) libfreetype.so.6 => /usr/lib/arm-linux-gnueabihf/libfreetype.so.6 (0x40001000) libnsl.so.1 => /lib/arm-linux-gnueabihf/libnsl.so.1 (0x40090000) libgcc_s.so.1 => /lib/arm-linux-gnueabihf/libgcc_s.so.1 (0x400e7000) libc.so.6 => /lib/arm-linux-gnueabihf/libc.so.6 (0x40325000) /lib/ld-linux-armhf.so.3 (0x400b6000) libz.so.1 => /lib/arm-linux-gnueabihf/libz.so.1 (0x4010f000)
I hope your system is compatibleâ¦
Regards,
Sven
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
Besides, "ldd squeakvm" from squeak dir not see file. But ls -l show me squeakvm with full permissions 2012/11/25 Denis Kudriashov <dionisiydk@gmail.com>
Hello. Thank's for share.
But unfortunatelly I cant run squeakvm. I have error -sh: ./squeakvm: not found (same with full headless image script) I extract tar to usr/lib and I can run hello.sh file with some echo from it. But squeakvm strangelly not work. And I have other executalbe binaries which I can just copy to phone and run. Google not help me yet
Best regards, Denis
2012/11/24 Sven Van Caekenberghe <sven@stfx.eu>
Hi Denis,
On 24 Nov 2012, at 11:25, Denis Kudriashov <dionisiydk@gmail.com> wrote:
Hello.
Can you share prebuilt VM? I have linux mobile phone (meegoOS with ARMv7 processor). And I really want pharo on it. I try built VM by myself but without success.
Best regards, Denis
Here is a .tgz of the VM
https://dl.dropbox.com/u/16235440/raspberrypi-squeak.tgz
as well as some additional info about the executables
pi@raspberrypi ~ $ file /usr/lib/squeak/4.4.7-2357/squeakvm /usr/lib/squeak/4.4.7-2357/squeakvm: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.26, BuildID[sha1]=0xee98a23c74f457d15c4b70c8c21e640dd0b375d9, stripped
pi@raspberrypi ~ $ file /usr/lib/squeak/4.4.7-2357/so.UUIDPlugin /usr/lib/squeak/4.4.7-2357/so.UUIDPlugin: ELF 32-bit LSB shared object, ARM, version 1 (SYSV), dynamically linked, BuildID[sha1]=0xe3771585b163d3706ba159f7e024488615e56771, stripped
pi@raspberrypi ~ $ ldd /usr/lib/squeak/4.4.7-2357/squeakvm /usr/lib/arm-linux-gnueabihf/libcofi_rpi.so (0x4031c000) libm.so.6 => /lib/arm-linux-gnueabihf/libm.so.6 (0x40192000) libdl.so.2 => /lib/arm-linux-gnueabihf/libdl.so.2 (0x40085000) libfreetype.so.6 => /usr/lib/arm-linux-gnueabihf/libfreetype.so.6 (0x40001000) libnsl.so.1 => /lib/arm-linux-gnueabihf/libnsl.so.1 (0x40090000) libgcc_s.so.1 => /lib/arm-linux-gnueabihf/libgcc_s.so.1 (0x400e7000) libc.so.6 => /lib/arm-linux-gnueabihf/libc.so.6 (0x40325000) /lib/ld-linux-armhf.so.3 (0x400b6000) libz.so.1 => /lib/arm-linux-gnueabihf/libz.so.1 (0x4010f000)
I hope your system is compatibleâ¦
Regards,
Sven
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
Denis, I just redownloaded the archive that I posted, and I was able to run from the newly created directory. I am afraid there is some binary incompatibility with your device. Maybe you could try recompiling from the official linux vm archive ? Sven On 25 Nov 2012, at 09:28, Denis Kudriashov <dionisiydk@gmail.com> wrote:
Besides, "ldd squeakvm" from squeak dir not see file. But ls -l show me squeakvm with full permissions
2012/11/25 Denis Kudriashov <dionisiydk@gmail.com> Hello. Thank's for share.
But unfortunatelly I cant run squeakvm. I have error -sh: ./squeakvm: not found (same with full headless image script) I extract tar to usr/lib and I can run hello.sh file with some echo from it. But squeakvm strangelly not work. And I have other executalbe binaries which I can just copy to phone and run. Google not help me yet
Best regards, Denis
2012/11/24 Sven Van Caekenberghe <sven@stfx.eu> Hi Denis,
On 24 Nov 2012, at 11:25, Denis Kudriashov <dionisiydk@gmail.com> wrote:
Hello.
Can you share prebuilt VM? I have linux mobile phone (meegoOS with ARMv7 processor). And I really want pharo on it. I try built VM by myself but without success.
Best regards, Denis
Here is a .tgz of the VM
https://dl.dropbox.com/u/16235440/raspberrypi-squeak.tgz
as well as some additional info about the executables
pi@raspberrypi ~ $ file /usr/lib/squeak/4.4.7-2357/squeakvm /usr/lib/squeak/4.4.7-2357/squeakvm: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.26, BuildID[sha1]=0xee98a23c74f457d15c4b70c8c21e640dd0b375d9, stripped
pi@raspberrypi ~ $ file /usr/lib/squeak/4.4.7-2357/so.UUIDPlugin /usr/lib/squeak/4.4.7-2357/so.UUIDPlugin: ELF 32-bit LSB shared object, ARM, version 1 (SYSV), dynamically linked, BuildID[sha1]=0xe3771585b163d3706ba159f7e024488615e56771, stripped
pi@raspberrypi ~ $ ldd /usr/lib/squeak/4.4.7-2357/squeakvm /usr/lib/arm-linux-gnueabihf/libcofi_rpi.so (0x4031c000) libm.so.6 => /lib/arm-linux-gnueabihf/libm.so.6 (0x40192000) libdl.so.2 => /lib/arm-linux-gnueabihf/libdl.so.2 (0x40085000) libfreetype.so.6 => /usr/lib/arm-linux-gnueabihf/libfreetype.so.6 (0x40001000) libnsl.so.1 => /lib/arm-linux-gnueabihf/libnsl.so.1 (0x40090000) libgcc_s.so.1 => /lib/arm-linux-gnueabihf/libgcc_s.so.1 (0x400e7000) libc.so.6 => /lib/arm-linux-gnueabihf/libc.so.6 (0x40325000) /lib/ld-linux-armhf.so.3 (0x400b6000) libz.so.1 => /lib/arm-linux-gnueabihf/libz.so.1 (0x4010f000)
I hope your system is compatibleâ¦
Regards,
Sven
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
2012/11/25 Sven Van Caekenberghe <sven@stfx.eu>
Denis,
I just redownloaded the archive that I posted, and I was able to run from the newly created directory. I am afraid there is some binary incompatibility with your device. Maybe you could try recompiling from the official linux vm archive ?
I will try it at future. (I am not friendly with C world) Thank's for help
On 23 Nov 2012, at 13:57, Sven Van Caekenberghe <sven@...> wrote:
Hi,
Does anyone know how to make Pharo 2.0 run on a Raspberry Pi ?
The out of the box VM is rather old. I have recompiled the stack VM from the latest source tarball http://www.squeakvm.org/unix/release/Squeak-4.10.2.2614- src.tar.gz and it seems the Pharo 1.4 image is happy with it. As soon as I get back I'll test the 2.0 image too and keep you posted.
On 24 Nov 2012, at 11:44, Dan Corneanu <dan.corneanu@gmail.com> wrote:
The out of the box VM is rather old. I have recompiled the stack VM from the latest source tarball http://www.squeakvm.org/unix/release/Squeak-4.10.2.2614- src.tar.gz and it seems the Pharo 1.4 image is happy with it.
Thanks, Dan, I will have a look at building the VM from that archive. -- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
Hi Dan, On 24 Nov 2012, at 14:15, Sven Van Caekenberghe <sven@stfx.eu> wrote:
On 24 Nov 2012, at 11:44, Dan Corneanu <dan.corneanu@gmail.com> wrote:
The out of the box VM is rather old. I have recompiled the stack VM from the latest source tarball http://www.squeakvm.org/unix/release/Squeak-4.10.2.2614- src.tar.gz and it seems the Pharo 1.4 image is happy with it.
Thanks, Dan, I will have a look at building the VM from that archive.
Following the standard instructions (no config customization), I managed to build a vm ! For some reason, no X11 support was built, but I now have -rwxr-xr-x 1 pi pi 9349 Nov 24 14:15 so.vm-display-null -rwxr-xr-x 1 pi pi 6278 Nov 24 14:15 so.vm-sound-null -rwxr-xr-x 1 pi pi 894438 Nov 24 14:15 squeakvm and I can run headless Pharo 1.4 doing HTTP and stuff. I guess I'll have to study the build process and options a bit more. I would like to have at least X11 support, but reducing the builtin plugins to have a smaller executable interests me too. Thanks again for the help. Sven -- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
did you have a look into build/CMakeFiles ? there is an error and an output log maybe you find some useful information there. Did you install the dev libs for OpenGL? sudo apt-get install libgl1-mesa-dev libglu1-mesa-dev keep me posted, Dan. On Sat, Nov 24, 2012 at 5:56 PM, Sven Van Caekenberghe <sven@stfx.eu> wrote:
Hi Dan,
On 24 Nov 2012, at 14:15, Sven Van Caekenberghe <sven@stfx.eu> wrote:
On 24 Nov 2012, at 11:44, Dan Corneanu <dan.corneanu@gmail.com> wrote:
The out of the box VM is rather old. I have recompiled the stack VM from the latest source tarball http://www.squeakvm.org/unix/release/Squeak-4.10.2.2614- src.tar.gz and it seems the Pharo 1.4 image is happy with it.
Thanks, Dan, I will have a look at building the VM from that archive.
Following the standard instructions (no config customization), I managed to build a vm !
For some reason, no X11 support was built, but I now have
-rwxr-xr-x 1 pi pi 9349 Nov 24 14:15 so.vm-display-null -rwxr-xr-x 1 pi pi 6278 Nov 24 14:15 so.vm-sound-null -rwxr-xr-x 1 pi pi 894438 Nov 24 14:15 squeakvm
and I can run headless Pharo 1.4 doing HTTP and stuff.
I guess I'll have to study the build process and options a bit more.
I would like to have at least X11 support, but reducing the builtin plugins to have a smaller executable interests me too.
Thanks again for the help.
Sven
-- Sven Van Caekenberghe http://stfx.eu Smalltalk is the Red Pill
On Sat, Nov 24, 2012 at 10:44:51AM +0000, Dan Corneanu wrote:
On 23 Nov 2012, at 13:57, Sven Van Caekenberghe <sven@...> wrote:
Hi,
Does anyone know how to make Pharo 2.0 run on a Raspberry Pi ?
The out of the box VM is rather old. I have recompiled the stack VM from the latest source tarball http://www.squeakvm.org/unix/release/Squeak-4.10.2.2614- src.tar.gz and it seems the Pharo 1.4 image is happy with it.
Just a clarification of terminology - this is the standard interpreter VM, as opposed to a stack VM that provides the additional object memory and interpreter features required for the Cog jit on platforms that support it. Dave
The out of the box VM is rather old. I have recompiled the stack VM from the latest source tarball http://www.squeakvm.org/unix/release/Squeak-4.10.2.2614- src.tar.gz and it seems the Pharo 1.4 image is happy with it.
Just a clarification of terminology - this is the standard interpreter VM, as opposed to a stack VM that provides the additional object memory and interpreter features required for the Cog jit on platforms that support it.
Dave
Yes, you are right. Sorry for the confusion I have created.
participants (4)
-
Dan Corneanu -
David T. Lewis -
Denis Kudriashov -
Sven Van Caekenberghe