July 18, 2018
On Wednesday, 18 July 2018 at 15:21:29 UTC, Russel Winder wrote:
> On Wed, 2018-07-18 at 14:20 +0000, Seb via Digitalmars-d wrote:
>> On Wednesday, 18 July 2018 at 12:56:05 UTC, Russel Winder wrote:
>> > [...]
>> 
>> You have openssl 1.1 installed, but vibe.d tries to link with openssl 1.0 by default.
>> 
>> See https://github.com/vibe-d/vibe.d#switching-between-openssl-versions
>> 
>> tl;dr: use
>> 
>> dub --override-config vibe-d:tls/openssl-1.1
>
> I went for the:
>
> dependency "vibe-d:tls" version="*"
> subConfiguration "vibe-d:tls" "openssl-1.1"
>
> in the dub.sdl file. I now have a build.
>
> I believe 1.1 should be the default if available, falling back to 1.0, 0.9,…

Of course, but it's not that easy, because dub doesn't support such a detection.
However, we can hack it:

https://github.com/vibe-d/vibe.d/pull/2190
July 18, 2018
On Wed, 2018-07-18 at 15:53 +0000, Seb via Digitalmars-d wrote: […]
> 
> Of course, but it's not that easy, because dub doesn't support
> such a detection.
> However, we can hack it:
> 
> https://github.com/vibe-d/vibe.d/pull/2190

Maybe this should be a requirement on Dub so as to avoid hacking?

-- 
Russel.
===========================================
Dr Russel Winder      t: +44 20 7585 2200
41 Buckmaster Road    m: +44 7770 465 077
London SW11 1EN, UK   w: www.russel.org.uk


July 18, 2018
On Wednesday, 18 July 2018 at 15:21:29 UTC, Russel Winder wrote:
> On Wed, 2018-07-18 at 14:20 +0000, Seb via Digitalmars-d wrote:
>> On Wednesday, 18 July 2018 at 12:56:05 UTC, Russel Winder wrote:
>> > [...]
>> 
>> You have openssl 1.1 installed, but vibe.d tries to link with openssl 1.0 by default.
>> 
>> See https://github.com/vibe-d/vibe.d#switching-between-openssl-versions
>> 
>> tl;dr: use
>> 
>> dub --override-config vibe-d:tls/openssl-1.1
>
> I went for the:
>
> dependency "vibe-d:tls" version="*"
> subConfiguration "vibe-d:tls" "openssl-1.1"
>
> in the dub.sdl file. I now have a build.
>
> I believe 1.1 should be the default if available, falling back to 1.0, 0.9,…
It would be very useful if dub would be able to check for missing libs.
It seams stupid, that after successful compilation you get the linker error.

Even if the needed libs are named different on different systems, it would be cool to collect the information what is needed in the dub.sdl/dub.json file.

So directly at the beginning you get a hint what is missing. And how to fix it,
especially if you use a system like Debian (/Ubuntu)

I ran into the exactly same chain of error messages, fixing them with the help of others,
and some search, this is not the most convenient experience if you start with vibe.d.

Regards mt.




July 18, 2018
Am Wed, 18 Jul 2018 13:29:00 +0100 schrieb Russel Winder:

> On Wed, 2018-07-18 at 11:41 +0000, Seb via Digitalmars-d wrote:
>> On Wednesday, 18 July 2018 at 11:35:05 UTC, Russel Winder wrote:
>> > On Tue, 2018-07-17 at 21:46 +0000, Radu via Digitalmars-d wrote:
>> > > On Tuesday, 17 July 2018 at 18:55:07 UTC, Russel Winder wrote:
>> > > > [...]
>> > > 
>> > > Missing openssl libs? Try installing openssl-dev package.
>> > 
>> > The Debian Sid openssl package is definitely installed. There doesn't seem to be a separate openssl-dev package.
>> 
>> It's called libssl-dev
> 
> libssl installed but libssl-dev not. I can't quite see why the linker ld needs the development files, it just needs the shared objects to be present.

Debian moved the lib*.so => lib*.so.123version symlinks into the -dev packages some time ago, so now you can't link without -dev packages. Not the smartest move imho....

-- 
Johannes
July 18, 2018
On Wed, 2018-07-18 at 17:45 +0000, Johannes Pfau via Digitalmars-d wrote:
> Am Wed, 18 Jul 2018 13:29:00 +0100 schrieb Russel Winder:
> 
> > 
[…]
> > libssl installed but libssl-dev not. I can't quite see why the
> > linker ld
> > needs the development files, it just needs the shared objects to be
> > present.
> 
> Debian moved the lib*.so => lib*.so.123version symlinks into the
> -dev
> packages some time ago, so now you can't link without -dev packages.
> Not
> the smartest move imho....

I think I shall find it hard to discover a reason why you are wrong, but clearly the Debian devs in charge managed to.

-- 
Russel.
===========================================
Dr Russel Winder      t: +44 20 7585 2200
41 Buckmaster Road    m: +44 7770 465 077
London SW11 1EN, UK   w: www.russel.org.uk


July 18, 2018
On Wed, Jul 18, 2018 at 07:08:32PM +0100, Russel Winder via Digitalmars-d wrote:
> On Wed, 2018-07-18 at 17:45 +0000, Johannes Pfau via Digitalmars-d wrote:
> > Am Wed, 18 Jul 2018 13:29:00 +0100 schrieb Russel Winder:
> […]
> > > libssl installed but libssl-dev not. I can't quite see why the linker ld needs the development files, it just needs the shared objects to be present.
> > 
> > Debian moved the lib*.so => lib*.so.123version symlinks into the
> > -dev packages some time ago, so now you can't link without -dev
> > packages.
> > Not the smartest move imho....
> 
> I think I shall find it hard to discover a reason why you are wrong, but clearly the Debian devs in charge managed to.
[...]

Having been using Debian for almost two decades, the impression I get is that generally -dev packages are required whenever you need to do anything related to compiling, which includes linking to the library.

The only time you don't need -dev packages is when you're running an already-compiled executable that's already linked with the library (which is generally the case for end users who don't routinely compile & link programs, hence this particular way of dividing -dev vs. non-dev packages).


T

-- 
Programming is not just an act of telling a computer what to do: it is also an act of telling other programmers what you wished the computer to do. Both are important, and the latter deserves care. -- Andrew Morton
July 18, 2018
On 2018-07-18 18:11, Martin Tschierschke wrote:

> Even if the needed libs are named different on different systems, it would be cool to collect the information what is needed in the dub.sdl/dub.json file.
> 
> So directly at the beginning you get a hint what is missing. And how to fix it,
> especially if you use a system like Debian (/Ubuntu)
> 
> I ran into the exactly same chain of error messages, fixing them with the help of others,
> and some search, this is not the most convenient experience if you start with vibe.d.

I'm doing that with DStep [1]. It was quite annoying and a lot of work to write, but it works.

[1] https://github.com/jacob-carlborg/dstep/blob/master/dub.json#L36

-- 
/Jacob Carlborg
July 31, 2018
Am Wed, 18 Jul 2018 19:08:32 +0100 schrieb Russel Winder:

> On Wed, 2018-07-18 at 17:45 +0000, Johannes Pfau via Digitalmars-d wrote:
>> Am Wed, 18 Jul 2018 13:29:00 +0100 schrieb Russel Winder:
>> 
>> 
> […]
>> > libssl installed but libssl-dev not. I can't quite see why the linker ld needs the development files, it just needs the shared objects to be present.
>> 
>> Debian moved the lib*.so => lib*.so.123version symlinks into the -dev packages some time ago, so now you can't link without -dev packages. Not the smartest move imho....
> 
> I think I shall find it hard to discover a reason why you are wrong, but clearly the Debian devs in charge managed to.

I actually found a reason why you do not want the .so symlink in normal runtime packages: If you have a library libfoo with different versions, i.e. 1.0 and 2.0, the libfoo packages for 1.0 and 2.0 do not have any conflicting files so you can in theory install both library versions (with same package name) at the same time. I don't know if debian supports this but I think on fedora it's possible to install multiple versions of the same package. Havin the .so symlink in the non-dev package would prevent this usage pattern.

-- 
Johannes
1 2
Next ›   Last »