Re: Which Docker to use?

2018-11-11 Thread Jon Degenhardt via Digitalmars-d-learn

On Monday, 22 October 2018 at 18:44:01 UTC, Jacob Carlborg wrote:

On 2018-10-21 20:45, Jon Degenhardt wrote:

The issue that caused me to go to Ubuntu 16.04 had to do with 
uncaught exceptions when using LTO with the gold linker and 
LDC 1.5. Problem occurred with 14.04, but not 16.04. I should 
go back and retest on Ubuntu 14.04 with a more recent LDC, it 
may well have been corrected. The issue thread is here: 
https://github.com/ldc-developers/ldc/issues/2390.


Ah, that might be the reason. I am not using LTO. You might 
want to try a newer version of LDC as well since 1.5 is quite 
old now.


I switched to LDC 1.12.0. The problem remains with LTO and static 
builds on Ubuntu 14.04. Ubuntu 16.04 is required, at least with 
LTO of druntime/phobos. The good news on this front is that the 
regularly updated dlang2 docker images work fine with LTO on 
druntime/phobos (using the LTO build support available in LDC 
1.9.0). Examples of travis-ci setups for both dlanguage and 
dlang2 docker images are available on the tsv-utils travis 
config: 
https://github.com/eBay/tsv-utils/blob/master/.travis.yml. Look 
for the DOCKERSPECIAL environment variables.


Re: Which Docker to use?

2018-10-22 Thread Jacob Carlborg via Digitalmars-d-learn

On 2018-10-21 20:45, Jon Degenhardt wrote:

My comment painted too broad a brush. I had forgotten how specific the 
issue I saw was. Apologies for the confusion.


The issue that caused me to go to Ubuntu 16.04 had to do with uncaught 
exceptions when using LTO with the gold linker and LDC 1.5. Problem 
occurred with 14.04, but not 16.04. I should go back and retest on 
Ubuntu 14.04 with a more recent LDC, it may well have been corrected. 
The issue thread is here: 
https://github.com/ldc-developers/ldc/issues/2390.


Ah, that might be the reason. I am not using LTO. You might want to try 
a newer version of LDC as well since 1.5 is quite old now.


--
/Jacob Carlborg


Re: Which Docker to use?

2018-10-21 Thread Jon Degenhardt via Digitalmars-d-learn

On Sunday, 21 October 2018 at 18:11:37 UTC, Jacob Carlborg wrote:

On 2018-10-18 01:15, Jon Degenhardt wrote:

I need to use docker to build static linked Linux executables. 
My reason
is specific, may be different than the OP's. I'm using 
Travis-CI to
build executables. Travis-CI uses Ubuntu 14.04, but static 
linking fails
on 14.04. The standard C library from Ubuntu 16.04 or later is 
needed.

There may be other/better ways to do this, I don't know.


That's interesting. I've built static binaries for DStep using 
LDC on Travis CI without any problems.


My comment painted too broad a brush. I had forgotten how 
specific the issue I saw was. Apologies for the confusion.


The issue that caused me to go to Ubuntu 16.04 had to do with 
uncaught exceptions when using LTO with the gold linker and LDC 
1.5. Problem occurred with 14.04, but not 16.04. I should go back 
and retest on Ubuntu 14.04 with a more recent LDC, it may well 
have been corrected. The issue thread is here: 
https://github.com/ldc-developers/ldc/issues/2390.


Re: Which Docker to use?

2018-10-21 Thread Jacob Carlborg via Digitalmars-d-learn

On 2018-10-18 01:15, Jon Degenhardt wrote:


I need to use docker to build static linked Linux executables. My reason
is specific, may be different than the OP's. I'm using Travis-CI to
build executables. Travis-CI uses Ubuntu 14.04, but static linking fails
on 14.04. The standard C library from Ubuntu 16.04 or later is needed.
There may be other/better ways to do this, I don't know.


That's interesting. I've built static binaries for DStep using LDC on 
Travis CI without any problems.


--
/Jacob Carlborg


Re: Which Docker to use?

2018-10-20 Thread Jon Degenhardt via Digitalmars-d-learn

On Friday, 19 October 2018 at 22:16:04 UTC, Ky-Anh Huynh wrote:
On Wednesday, 17 October 2018 at 23:15:53 UTC, Jon Degenhardt 
wrote:


I need to use docker to build static linked Linux executables. 
My reason is specific, may be different than the OP's. I'm 
using Travis-CI to build executables. Travis-CI uses Ubuntu 
14.04, but static linking fails on 14.04. The standard C 
library from Ubuntu 16.04 or later is needed. There may be 
other/better ways to do this, I don't know.


Yes I'm also using Travis-CI and that's why I need some Docker 
support.


I'm using dlanguage/ldc. The reason for that choice was because 
it was what was available when I put the travis build together. 
As you mentioned, it hasn't been updated in a while. I'm still 
producing this build with an older ldc version, but when I move 
to a more current version I'll have to switch to a different 
docker image.


My travis config is here: 
https://github.com/eBay/tsv-utils/blob/master/.travis.yml. Look 
for the sections referencing the DOCKERSPECIAL environment 
variable.


Re: Which Docker to use?

2018-10-19 Thread Ky-Anh Huynh via Digitalmars-d-learn
On Wednesday, 17 October 2018 at 23:15:53 UTC, Jon Degenhardt 
wrote:


I need to use docker to build static linked Linux executables. 
My reason is specific, may be different than the OP's. I'm 
using Travis-CI to build executables. Travis-CI uses Ubuntu 
14.04, but static linking fails on 14.04. The standard C 
library from Ubuntu 16.04 or later is needed. There may be 
other/better ways to do this, I don't know.


Yes I'm also using Travis-CI and that's why I need some Docker 
support.


Re: Which Docker to use?

2018-10-17 Thread Jon Degenhardt via Digitalmars-d-learn
On Wednesday, 17 October 2018 at 08:08:44 UTC, Gary Willoughby 
wrote:
On Wednesday, 17 October 2018 at 03:37:21 UTC, Ky-Anh Huynh 
wrote:

Hi,

I need to build some static binaries with LDC. I also need to 
execute builds on both platform 32-bit and 64-bit.



From Docker Hub there are two image groups:

* language/ldc (last update 5 months ago)
* dlang2/ldc-ubuntu (updated recently)


Which one do you suggest?

Thanks a lot.


To be honest, you don't need docker for this. You can just 
download LDC in a self-contained folder and use it as is.


https://github.com/ldc-developers/ldc/releases

That's what I do on Linux.


I need to use docker to build static linked Linux executables. My 
reason is specific, may be different than the OP's. I'm using 
Travis-CI to build executables. Travis-CI uses Ubuntu 14.04, but 
static linking fails on 14.04. The standard C library from Ubuntu 
16.04 or later is needed. There may be other/better ways to do 
this, I don't know.


Re: Which Docker to use?

2018-10-17 Thread Gary Willoughby via Digitalmars-d-learn

On Wednesday, 17 October 2018 at 03:37:21 UTC, Ky-Anh Huynh wrote:

Hi,

I need to build some static binaries with LDC. I also need to 
execute builds on both platform 32-bit and 64-bit.



From Docker Hub there are two image groups:

* language/ldc (last update 5 months ago)
* dlang2/ldc-ubuntu (updated recently)


Which one do you suggest?

Thanks a lot.


To be honest, you don't need docker for this. You can just 
download LDC in a self-contained folder and use it as is.


https://github.com/ldc-developers/ldc/releases

That's what I do on Linux.