32bit LC on 64bit Linux - hints

Deploying to Linux? Get penguinated here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
AxWald
Posts: 578
Joined: Thu Mar 06, 2014 2:57 pm

32bit LC on 64bit Linux - hints

Post by AxWald » Mon Mar 28, 2016 7:21 pm

Hi,

seems there's a bit of confusion about this - running 32bit versions of LC on 64bit Linux systems. Some say it works, some say it doesn't, there's some few hints what's required all over the forum - so when I decided to give Linux another try I quickly became rather confused, too.

But since it's now running I think it may help some other poor soul if I provide a short "how-did-I-do-it". On the stage:
  • A 64bit computer (AMD Phenom II X4 B20e, AMD SB750 chipset)
  • Centos 7 64bit (very closely related to RedHat/ Fedora), freshly installed
  • LiveCode Community 6.7.10 (32bit, for sure)
  • Me, quite the Linux nOOb ;-)
LC waits in the Download directory, executable bit set. "Run" does nothing at all.
So, Terminal from here:

------------------------------------------------
[awa@djehenna Downloads]$ su
Password:

{Always good to be da boss, just in case ...}

[root@djehenna Downloads]# ls
LiveCodeCommunityInstaller-6_7_10-Linux.x86

{Now let's check what's lacking:}

[root@djehenna Downloads]# ldd LiveCodeCommunityInstaller-6_7_10-Linux.x86
not a dynamic executable

{Maybe we need a 32bit glibc? Found a hint to try i686 ...}

[root@djehenna Downloads]# yum list glibc
{...}
Installed Packages
glibc.x86_64 2.17-106.el7_2.4 @anaconda
Available Packages
glibc.i686 2.17-106.el7_2.4 updates

{Here it is, let's give it a try!}

[root@djehenna Downloads]# yum install glibc.i686
{... this isn't too interesting ...}
Installed:
glibc.i686 0:2.17-106.el7_2.4
Dependency Installed:
nss-softokn-freebl.i686 0:3.16.2.3-13.el7_1
Complete!

{Trying the ldd again, and BINGO:}

[root@djehenna Downloads]# ldd ./LiveCodeCommunityInstaller-6_7_10-Linux.x86
linux-gate.so.1 => (0xf76e7000)
libdl.so.2 => /lib/libdl.so.2 (0xf76cc000)
libpthread.so.0 => /lib/libpthread.so.0 (0xf76b2000)
libX11.so.6 => not found
libXext.so.6 => not found
libstdc++.so.6 => not found
libm.so.6 => /lib/libm.so.6 (0xf766f000)
libgcc_s.so.1 => not found
libc.so.6 => /lib/libc.so.6 (0xf74b2000)
/lib/ld-linux.so.2 (0xf76e8000)

{Now installing all the lacking stuff from above:}

[root@djehenna Downloads]# yum install libX11.so.6

{Repeating this with anything "not found", until:}

[root@djehenna Downloads]# ldd ./LiveCodeCommunityInstaller-6_7_10-Linux.x86
linux-gate.so.1 => (0xf771d000)
libdl.so.2 => /lib/libdl.so.2 (0xf7701000)
libpthread.so.0 => /lib/libpthread.so.0 (0xf76e7000)
libX11.so.6 => /lib/libX11.so.6 (0xf75ab000)
libXext.so.6 => /lib/libXext.so.6 (0xf7598000)
libstdc++.so.6 => /lib/libstdc++.so.6 (0xf74ab000)
libm.so.6 => /lib/libm.so.6 (0xf7469000)
libgcc_s.so.1 => /lib/libgcc_s.so.1 (0xf744e000)
libc.so.6 => /lib/libc.so.6 (0xf7291000)
/lib/ld-linux.so.2 (0xf771e000)
libxcb.so.1 => /lib/libxcb.so.1 (0xf726c000)
libXau.so.6 => /lib/libXau.so.6 (0xf7267000)

{Installer starts now, but no fonts at all :/ We need a 32bit libpango:}

[root@djehenna Downloads]# yum list pango
{...}
Installed Packages
pango.x86_64 1.36.8-2.el7 @anaconda
Available Packages
pango.i686 1.36.8-2.el7 base

{We'll try the i686 again:}

[root@djehenna Downloads]# yum install pango.i686
{... again, this isn't too much interesting ...}
Complete!

{Installer starts with fonts, installs, LC starts! wOOOOt!}
------------------------------------------------

This should give you an idea where the problems are, even if you use another distribution. May it save you the time it took me to find this all out!

Have fun!

PS: Cannot say too much how well LC works - didn't try yet ;-)
At least there seems to be a problem with the "ask file" dialog - but this will be solved later. I'll report.
All code published by me here was created with Community Editions of LC (thus is GPLv3).
If you use it in closed source projects, or for the Apple AppStore, or with XCode
you'll violate some license terms - read your relevant EULAs & Licenses!

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9801
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: 32bit LC on 64bit Linux - hints

Post by FourthWorld » Mon Mar 28, 2016 8:10 pm

With Ubuntu the one-liner Neil provided here did the trick for me:
http://forums.livecode.com/viewtopic.ph ... 39#p104639

That said, I can't recommend v6 for new work going forward. Fairly soon it'll join v5, v4, and other earlier versions in being EOL'd, as soon as v8.0 goes final.

For new work work it's very useful to at least test with v8.0 because if you encounter any problems it's best to find and report them so they can be addressed before final release.

And with some 2000+ fixes and enhancements (many specific to Linux systems), v8 has a lot going for it over v6.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

AxWald
Posts: 578
Joined: Thu Mar 06, 2014 2:57 pm

Re: 32bit LC on 64bit Linux - hints

Post by AxWald » Mon Mar 28, 2016 10:03 pm

Hi,
FourthWorld wrote:With Ubuntu the one-liner Neil provided here did the trick for me:
http://forums.livecode.com/viewtopic.ph ... 39#p104639
Been there, tried that - no i386 versions in the repos anymore, for Centos or Solus at least. What is important is that here the i686 packages contained them!
And there are many other distributions besides Ubuntu ...
FourthWorld wrote:That said, I can't recommend v6 for new work going forward.
I don't need anything that's in 7 - I need small, fast standalones instead ;-) Just d'lled 6.7.10, and I could live happy and contently with this line (ongoing bugfixes assumed) for the next years.
FourthWorld wrote:Fairly soon it'll join v5, v4, and other earlier versions in being EOL'd, as soon as v8.0 goes final.
Would be a pity, IMHO. I'd rather EOL the 7 once 8.2 is out (7 is only a stepping stone on the way to 8, isn't it?), rename 6 to "LC Classic" and 8 to "LC NextGen" or so.
This way you'd have 2 products, with distinct features:
  • LC Classic as "the Original", fast, lightweight, versatile. A workhorse, aimed at database work, server applications, Basic IT teaching, Raspberry etc. No big development anymore, only support, a bit optimization & bug fixes. As long as it's still in use.
  • And LC NewGen, "teh Flagship". For multimedia, games, mobile, touch, with unicode & widgets - all the fancy, exciting new stuff.
But that's off topic here, for sure. Maybe you want to think about, Richard, maybe it's time to start a discussion about this - to find out what the ppl are thinking, it could be interesting. Up to you, I'd appreciate it.

Have fun!
All code published by me here was created with Community Editions of LC (thus is GPLv3).
If you use it in closed source projects, or for the Apple AppStore, or with XCode
you'll violate some license terms - read your relevant EULAs & Licenses!

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9801
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: 32bit LC on 64bit Linux - hints

Post by FourthWorld » Mon Mar 28, 2016 10:30 pm

AxWald wrote:And there are many other distributions besides Ubuntu ...
True, which is why I specified that the fix I'd found had only been confirmed here under Ubuntu.

The great thing about Linux is that it's infinitely configurable; the bad thing about Linux is that it's infinitely configurable. ;)
I don't need anything that's in 7 - I need small, fast standalones instead ;-) Just d'lled 6.7.10, and I could live happy and contently with this line (ongoing bugfixes assumed) for the next years.
...until something in the OS changes requiring changes to the engine.
FourthWorld wrote:Fairly soon it'll join v5, v4, and other earlier versions in being EOL'd, as soon as v8.0 goes final.
Would be a pity, IMHO. I'd rather EOL the 7 once 8.2 is out (7 is only a stepping stone on the way to 8, isn't it?), rename 6 to "LC Classic" and 8 to "LC NextGen" or so.
This way you'd have 2 products, with distinct features:
  • LC Classic as "the Original", fast, lightweight, versatile. A workhorse, aimed at database work, server applications, Basic IT teaching, Raspberry etc. No big development anymore, only support, a bit optimization & bug fixes. As long as it's still in use.
  • And LC NewGen, "teh Flagship". For multimedia, games, mobile, touch, with unicode & widgets - all the fancy, exciting new stuff.
But that's off topic here, for sure. Maybe you want to think about, Richard, maybe it's time to start a discussion about this - to find out what the ppl are thinking, it could be interesting. Up to you, I'd appreciate it.
You're welcome to start such a discussion, but personally I see it as lowering return-on-investment for all of us relative to just putting all resources toward making one great version.

Maintaining both versions is costly, and since v8 is a superset of v6 in both features and fixes I don't see much benefit in the additional expense.

What have you encountered in v8 that prevents you from using it? Lets fix those while its in testing so the final build can do exactly what you need.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: 32bit LC on 64bit Linux - hints

Post by mwieder » Wed Mar 30, 2016 5:55 am

Wow... that's definitely going about things the hard way.
All that *should* be required is to load the ia32lib libraries to support 32-bit binaries.

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: 32bit LC on 64bit Linux - hints

Post by mwieder » Wed Mar 30, 2016 5:58 am

What have you encountered in v8 that prevents you from using it? Lets fix those while its in testing so the final build can do exactly what you need.
Well, there's the raspberry pi, for starters.
I won't miss LC7 when it goes, but I'll mourn for LC6 for applications that don't need a lot of bloatware baggage.

AxWald
Posts: 578
Joined: Thu Mar 06, 2014 2:57 pm

Re: 32bit LC on 64bit Linux - hints

Post by AxWald » Fri Apr 01, 2016 10:27 am

Hi,
FourthWorld wrote:The great thing about Linux is that it's infinitely configurable; the bad thing about Linux is that it's infinitely configurable. ;)
And the most bad thing is that nearly every other distributon has another way to do it ;-)
FourthWorld wrote:You're welcome to start such a discussion, but personally I see it as lowering return-on-investment for all of us relative to just putting all resources toward making one great version.
Maintaining both versions is costly, and since v8 is a superset of v6 in both features and fixes I don't see much benefit in the additional expense.
I'll do this, actually have a draft already. With a poll asking how many ppl would wish continued (limited, for sure) support for the 6.* line. What forum section would you suggest? Feature request?
FourthWorld wrote:What have you encountered in v8 that prevents you from using it? Lets fix those while its in testing so the final build can do exactly what you need.
To be honest, I haven't encountered much because I only downloaded it a few days ago (due to your suggestion), and couldn't do much testing yet.
Was impressed by the nearly equal size (file size and RAM chunk taken), was disappointed by the slowness. In a real live test of one of my programs (mostly file IO, chunk juggling, database queries, math/crypt operations) V8 took about double the time compared to V6.
Will do more testing, in the limited time frame my current occupation allows.

mwieder wrote:All that *should* be required is to load the ia32lib libraries to support 32-bit binaries.
This is where a Linux-nOOb like me starts to run against the wall - there are no i386/ 32bit libraries anymore in the repositories of at least the 2 64bit distributions I tried (CentOS, Solus). ;-)
Well, as shown in the OP, they actually are, but clandestinely hidden in the i686 packages! I spent literally hours tormenting the package managers searching for any i386 or -32 stuff ...
mwieder wrote:I won't miss LC7 when it goes, but I'll mourn for LC6 for applications that don't need a lot of bloatware baggage.
Where can I sign this?

Have fun!
All code published by me here was created with Community Editions of LC (thus is GPLv3).
If you use it in closed source projects, or for the Apple AppStore, or with XCode
you'll violate some license terms - read your relevant EULAs & Licenses!

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: 32bit LC on 64bit Linux - hints

Post by mwieder » Fri Apr 01, 2016 3:29 pm

This is where a Linux-nOOb like me starts to run against the wall - there are no i386/ 32bit libraries anymore in the repositories of at least the 2 64bit distributions I tried (CentOS, Solus). ;-)
Well, as shown in the OP, they actually are, but clandestinely hidden in the i686 packages! I spent literally hours tormenting the package managers searching for any i386 or -32 stuff ...
Bummer. Are the multiarch libraries in the repos? Personally I like ia32lib over multiarch, but I know some distros are going that route to get 32-bit compatibility.
V8 took about double the time compared to V6.
That just seems wrong. I mean, not the fact that you're seeing the slowdown, but the fact that it takes twice as long.
I'd be really interested to see some sample code if you can throw some together in your spare time... no doubt there's some engine optimization that can be done to bring this up to speed, the way the string routines were tweaked.
With a poll asking how many ppl would wish continued (limited, for sure) support for the 6.* line.
Have you thought about building a 64-bit LC6 from source? If you're interested in LC6 as an end result and not so much in the wider-distribution aspect, you can always just build your own and use that. When I originally did the 64-bit port I found that things were noticeably faster due partly to not having to go through the 32-bit shims.

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9801
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: 32bit LC on 64bit Linux - hints

Post by FourthWorld » Fri Apr 01, 2016 4:56 pm

mwieder wrote:
What have you encountered in v8 that prevents you from using it? Lets fix those while its in testing so the final build can do exactly what you need.
Well, there's the raspberry pi, for starters.
Since the first Linux.ARM build with v6.5.0, there have been fewer than a dozen builds for that platform, while there have been many dozens for officially supported platforms. Clearly this is not an issue specific to v8.

It's more of a logistics issue, and one actively being worked on for the v8 cycle: to date the Linux/ARM builds have been Fraser's personal work, and integrating it into the automated build system has only recently been green-lighted by Kevin. I'm told the remaining work isn't more than a couple day's worth, but the challenge at the moment is getting a couple days of Fraser's time while we keep asking him to work on Linux/x86 issues. In the absence of being able to clone Fraser, it may be that the integration of Linux/ARM doesn't happen until late into the v8.0 cycle. But it is in queue to be done as soon as resource availability permits.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: 32bit LC on 64bit Linux - hints

Post by mwieder » Fri Apr 01, 2016 5:01 pm

being able to clone Fraser
+1 :D

AxWald
Posts: 578
Joined: Thu Mar 06, 2014 2:57 pm

Re: 32bit LC on 64bit Linux - hints

Post by AxWald » Fri Apr 01, 2016 6:59 pm

Hi,
mwieder wrote:
V8 took about double the time compared to V6.
That just seems wrong. I mean, not the fact that you're seeing the slowdown, but the fact that it takes twice as long.
I'd be really interested to see some sample code [...]
Wasn't serious testing, just a Q&D try.

I compiled a (known good) socket server (in both versions) that (besides other) accepts an article number & a price tier, queries a SQLite db a few times, compiles real-time article data and a tier-specific price, sends this back & writes some log entries. Here I saw no differences (~150 articles/ second) - guess the database access time & the writing of the log are the limiting factors. CPU stress and RAM hunger seemed rather equal, too.

On the other side I had a modified version of my testclient that did a loop:
Getting a randomseed, creating 2 random integers and a formatted numeric string (each in a given range), firing the socket query, opening a 4K txt-file, reading it, extracting a line, appending this to a variable, closing the file.
The time measured was exactly this - the time the client needed to do this 10.000 times was about 5 sec. for V8.0dp16 and ~ 2.5 sec. for V6.7.10 stable. Both on Win 10-64.
It's to mention that besides this the client received the replies from the socket server, as they came. Again, CPU stress and RAM hunger seemed rather equal.
mwieder wrote:Have you thought about building a 64-bit LC6 from source?
Sounds like a nightmare to me ;-))

Nah, I'm just playing around with Linux, learning it basically, needing to bring some LC stuff on Linux in the coming time. It's so alien!
And for this I'll scrap my Solus & install a 32-bit CentOS 6.7, I need to test my LC tools-to-be on 32bit anyways (target system is such as I got word today).

Besides, my further tries with 6.7.10 on Linux wasn't this successful- file dialogs are borked, text is vanishing, seems my tricky installation isn't what I hoped ;-) Another reason to try it on on a 32bit Linux.

Have fun!
All code published by me here was created with Community Editions of LC (thus is GPLv3).
If you use it in closed source projects, or for the Apple AppStore, or with XCode
you'll violate some license terms - read your relevant EULAs & Licenses!

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9250
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: 32bit LC on 64bit Linux - hints

Post by richmond62 » Sat Apr 02, 2016 6:31 pm

Frankly I would just install the latest 7 series 64 bit version and stop worrying about things.

Although, having said that, I am running Livecode 4.5 on Xubuntu 64-bit without a backward glance.

AxWald
Posts: 578
Joined: Thu Mar 06, 2014 2:57 pm

Re: 32bit LC on 64bit Linux - hints

Post by AxWald » Sun Apr 03, 2016 6:30 pm

Hi,

you're a prophet:
richmond62 wrote:Frankly I would just install the latest 7 series 64 bit version and stop worrying about things.
Well, nearly. It's a LC 8-64 that started for the first time close to the time of your posting ;-)

Meanwhile on another partition:
Heavy discussions between me & a 32bit CentOS that cannot accept it has to have an eth0 ...
(This beats Win 3.1 for Workgroups, by far!)

Have fun!
All code published by me here was created with Community Editions of LC (thus is GPLv3).
If you use it in closed source projects, or for the Apple AppStore, or with XCode
you'll violate some license terms - read your relevant EULAs & Licenses!

mwieder
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3581
Joined: Mon Jan 22, 2007 7:36 am
Location: Berkeley, CA, US
Contact:

Re: 32bit LC on 64bit Linux - hints

Post by mwieder » Sun Apr 03, 2016 6:43 pm

Well, nearly. It's a LC 8-64 that started for the first time close to the time of your posting ;-)
Hooray! And note that if it comes to that, you can build 32-bit binaries using a 64-bit base system - there are checkboxes on the standalone builder panel when you're ready to create an app.
(This beats Win 3.1 for Workgroups, by far!)
LOL

Post Reply

Return to “Linux”