digitalmars.D - Dub and posix
- Russel Winder via Digitalmars-d (15/15) Jan 18 2016 Looking at the DStep compilation issue, it transpires that Debian and
- Jacob Carlborg (7/11) Jan 18 2016 What happens if one specifies a non-existing path for a flag like -L?
- Russel Winder via Digitalmars-d (20/33) Jan 18 2016 Linker ignores.
- Jacob Carlborg (4/10) Jan 18 2016 And a glob (*) would most likely not work?
- Russel Winder via Digitalmars-d (14/30) Jan 18 2016 if you tried something like that, you would get all present LLVM
- Johannes Pfau (3/25) Jan 18 2016 I guess they use pkg-config? Not sure if you can use that in dub...
- Jacob Carlborg (5/7) Jan 18 2016 Hmm, true. I was thinking that one would only have one version
Looking at the DStep compilation issue, it transpires that Debian and Fedora need different linker flags even though they are both posix. Does anyone know how to specify liner flags at this level of granularity? It turns out this is a frustrating issue in every build system :-( --=20 Russel. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder ekiga.n= et 41 Buckmaster Road m: +44 7770 465 077 xmpp: russel winder.org.uk London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
Jan 18 2016
On 2016-01-18 10:13, Russel Winder via Digitalmars-d wrote:Looking at the DStep compilation issue, it transpires that Debian and Fedora need different linker flags even though they are both posix. Does anyone know how to specify liner flags at this level of granularity?What happens if one specifies a non-existing path for a flag like -L? Does the linker ignore that or will it cause an error? If it's ignored, then I guess it wouldn't be a problem to add it for all Posix systems. A bit ugly though. -- /Jacob Carlborg
Jan 18 2016
On Mon, 2016-01-18 at 13:58 +0100, Jacob Carlborg via Digitalmars-d wrote:On 2016-01-18 10:13, Russel Winder via Digitalmars-d wrote:Linker ignores.Looking at the DStep compilation issue, it transpires that Debian and Fedora need different linker flags even though they are both posix. Does anyone know how to specify liner flags at this level of granularity?=20 What happens if one specifies a non-existing path for a flag like -L?=C2=A0 Does the linker ignore that or will it cause an error?If it's ignored, then I guess it wouldn't be a problem to add it for all=C2=A0 Posix systems. A bit ugly though.I am just trying this out. I added -L/usr/lib64/llvm in the relevant line of dub.json and everything seems to work nicely on Fedora. Sadly on Debian there is no version independent location for LLVM as far as I can tell. "lflags-posix": ["-lclang", "-rpath", ".", "-L.", "-L/usr/lib64/llvm", "-L/= usr/lib/llvm-3.7/lib"], Works on both Fedora and Debian, but it hardwires 3.7. --=20 Russel. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder ekiga.n= et 41 Buckmaster Road m: +44 7770 465 077 xmpp: russel winder.org.uk London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
Jan 18 2016
On 2016-01-18 14:23, Russel Winder via Digitalmars-d wrote:I am just trying this out. I added -L/usr/lib64/llvm in the relevant line of dub.json and everything seems to work nicely on Fedora. Sadly on Debian there is no version independent location for LLVM as far as I can tell. "lflags-posix": ["-lclang", "-rpath", ".", "-L.", "-L/usr/lib64/llvm", "-L/usr/lib/llvm-3.7/lib"], Works on both Fedora and Debian, but it hardwires 3.7.And a glob (*) would most likely not work? -- /Jacob Carlborg
Jan 18 2016
On Mon, 2016-01-18 at 15:33 +0100, Jacob Carlborg via Digitalmars-d wrote:On 2016-01-18 14:23, Russel Winder via Digitalmars-d wrote: =20if you tried something like that, you would get all present LLVM versions in the path which would likely lead to some chaos. --=20 Russel. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder ekiga.n= et 41 Buckmaster Road m: +44 7770 465 077 xmpp: russel winder.org.uk London SW11 1EN, UK w: www.russel.org.uk skype: russel_winderI am just trying this out. I added -L/usr/lib64/llvm in the relevant line of dub.json and everything seems to work nicely on Fedora. Sadly on Debian there is no version independent location for LLVM as far as I can tell. =20 "lflags-posix": ["-lclang", "-rpath", ".", "-L.", "- L/usr/lib64/llvm", "-L/usr/lib/llvm-3.7/lib"], =20 Works on both Fedora and Debian, but it hardwires 3.7.=20 And a glob (*) would most likely not work?
Jan 18 2016
Am Mon, 18 Jan 2016 15:05:28 +0000 schrieb Russel Winder via Digitalmars-d <digitalmars-d puremagic.com>:On Mon, 2016-01-18 at 15:33 +0100, Jacob Carlborg via Digitalmars-d wrote:I guess they use pkg-config? Not sure if you can use that in dub...On 2016-01-18 14:23, Russel Winder via Digitalmars-d wrote:if you tried something like that, you would get all present LLVM versions in the path which would likely lead to some chaos.I am just trying this out. I added -L/usr/lib64/llvm in the relevant line of dub.json and everything seems to work nicely on Fedora. Sadly on Debian there is no version independent location for LLVM as far as I can tell. "lflags-posix": ["-lclang", "-rpath", ".", "-L.", "- L/usr/lib64/llvm", "-L/usr/lib/llvm-3.7/lib"], Works on both Fedora and Debian, but it hardwires 3.7.And a glob (*) would most likely not work?
Jan 18 2016
On 2016-01-18 16:05, Russel Winder via Digitalmars-d wrote:if you tried something like that, you would get all present LLVM versions in the path which would likely lead to some chaos.Hmm, true. I was thinking that one would only have one version installed. But that might not be the case. -- /Jacob Carlborg
Jan 18 2016