Re: [ubuntu-uk] 64 vs 32bit Applications

2016-06-01 Thread Liam Proven
On 1 June 2016 at 12:33, Nigel Verity  wrote:
> I've recently gone over to 64bit Ubuntu versions on all my boxes and this
> raised a question. Does every binary object in the repositories have to be
> compiled twice - once for 32 and again for 64bit architectures - or can
> 32bit compilations run on a 64bit host?
>
> If they are separate versions is there a likelihood that some particularly
> obscure packages will fall by the wayside simply through being considered
> not worth compiling for 64bit? Perhaps there is a formal policy on this.

As a general rule, 64-bit x86 OSes can run 32-bit code. So it is
perfectly possible to run old binaries on a 64-bit OS.

E.g. Microsoft has not updated Skype for Linux in years, and it is
only available as a 32-bit binary, but it still works fine. However,
it requires a whole load of 32-bit libraries to be installed to
support it -- however, they come from the Ubuntu repositories and get
updated along with the rest of the OS.

-- 
Liam Proven • Profile: http://lproven.livejournal.com/profile
Email: lpro...@cix.co.uk • GMail/G+/Twitter/Flickr/Facebook: lproven
MSN: lpro...@hotmail.com • Skype/AIM/Yahoo/LinkedIn: liamproven
Cell/Mobiles: +44 7939-087884 (UK) • +420 702 829 053 (ČR)

-- 
ubuntu-uk@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-uk
https://wiki.ubuntu.com/UKTeam/


Re: [ubuntu-uk] 64 vs 32bit Applications

2016-06-01 Thread Paul Waring
On Wed, Jun 01, 2016 at 11:33:11AM +0100, Nigel Verity wrote:
>I don't have a technical issue but I'd welcome a bit of enlightenment.
> 
>I've recently gone over to 64bit Ubuntu versions on all my boxes and this
>raised a question. Does every binary object in the repositories have to be
>compiled twice - once for 32 and again for 64bit architectures - or can
>32bit compilations run on a 64bit host?

In theory 32 bit software should run on a 64 bit architecture (assuming
x86) as 64 bit CPUs can still run 32 bit code.

>If they are separate versions is there a likelihood that some particularly
>obscure packages will fall by the wayside simply through being considered
>not worth compiling for 64bit? Perhaps there is a formal policy on this.

There's an Ask Ubuntu topic about this very question:

http://askubuntu.com/questions/359156/how-do-you-run-a-32-bit-program-on-a-64-bit-version-of-ubuntu

The short answer seems to be that if you install software via the
official repositories it will 'just work'. If you want to run unpackaged
software then you need to do a bit of fiddling to ensure that you get
the right versions of the relevant libraries (it took me several days to
get a piece of legacy 32 bit software to run on Scientific Linux when
they dropped out of the box support for 32 bit).

-- 
Paul Waring
Freelance consultant
http://www.pwaring.com

-- 
ubuntu-uk@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-uk
https://wiki.ubuntu.com/UKTeam/


Re: [ubuntu-uk] 64 vs 32bit Applications

2016-06-01 Thread Alan Pope
Hi Nige,

On 1 June 2016 at 11:33, Nigel Verity  wrote:
> I've recently gone over to 64bit Ubuntu versions on all my boxes and this
> raised a question. Does every binary object in the repositories have to be
> compiled twice - once for 32 and again for 64bit architectures

Yes. Take a random app like chromium in 16.04:-

http://packages.ubuntu.com/search?keywords=chromium
http://packages.ubuntu.com/xenial/chromium-browser

Note there's a 32-bit (i386) build:-

http://packages.ubuntu.com/xenial/i386/chromium-browser/download

..and a 64-bit (amd64) build:-

http://packages.ubuntu.com/xenial/amd64/chromium-browser/download

Both were compiled separately on different machines in the Launchpad build farm.

https://launchpad.net/~canonical-chromium-builds/+archive/ubuntu/stage/+build/9739028

" Successfully built on lgw01-02
Started on 2016-05-13
Finished on 2016-05-14 (took 7 hours, 28 minutes, 11.8 seconds)"

https://launchpad.net/~canonical-chromium-builds/+archive/ubuntu/stage/+build/9739030

"Successfully built on lgw01-48
Started on 2016-05-13
Finished on 2016-05-13 (took 6 hours, 32 minutes, 4.7 seconds"

as well as a build for armhf.

https://launchpad.net/~canonical-chromium-builds/+archive/ubuntu/stage/+build/9739029

" Successfully built on kishi08 (highbank)
Started on 2016-05-13
Finished on 2016-05-14 (took 12 hours, 20 minutes, 34.6 seconds)"

Maybe, in the future chromium will build on an aarch64 (64-bit arm)
machine too :)

> - or can
> 32bit compilations run on a 64bit host?
>

That works too!

Skype for example is a good example of a 32 bit (i386) app which runs
on 64 bit (amd64) machines. However it's possible to install 32-bit
versions of apps from the archive on a 64-bit machine, should you need
to, just suffix :i386 on the end:-

sudo apt install foo:i386

> If they are separate versions is there a likelihood that some particularly
> obscure packages will fall by the wayside simply through being considered
> not worth compiling for 64bit? Perhaps there is a formal policy on this.
>

No, we monitor things with FTBFS (Fail to build from source) and
correct those issues.

In fact it's more likely these days to be the other way round, in that
some things build on 64-bit but don't build for 32-bit, as some newer
packages are 64-bit only for whatever reason.

If a package is available in one arch and not the other, generally
it's a bug - known or not.

Cheers,
Al.

-- 
ubuntu-uk@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-uk
https://wiki.ubuntu.com/UKTeam/


[ubuntu-uk] 64 vs 32bit Applications

2016-06-01 Thread Nigel Verity
Hi

I don't have a technical issue but I'd welcome a bit of enlightenment.

I've recently gone over to 64bit Ubuntu versions on all my boxes and this 
raised a question. Does every binary object in the repositories have to be 
compiled twice - once for 32 and again for 64bit architectures - or can 32bit 
compilations run on a 64bit host?

If they are separate versions is there a likelihood that some particularly 
obscure packages will fall by the wayside simply through being considered not 
worth compiling for 64bit? Perhaps there is a formal policy on this.

Thanks

Nige  -- 
ubuntu-uk@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-uk
https://wiki.ubuntu.com/UKTeam/