Bug#846742: meson: FTBFS: ld: final link failed: Bad value

2016-12-03 Thread Jussi Pakkanen
reassign 846742 gdc
stop

On Sat, Dec 3, 2016 at 9:21 AM, Lucas Nussbaum  wrote:

> Relevant part (hopefully):
>> /usr/bin/ld: dsimpleapp@exe/utils.d.o: relocation R_X86_64_PC32 against 
>> symbol 
>> `_D3std5array17__T8appenderTAyaZ8appenderFNaNbNfZS3std5array17__T8AppenderTAyaZ8Appender'
>>  can not be used when making a shared object; recompile with -fPIC
>> /usr/bin/ld: final link failed: Bad value
>> collect2: error: ld returned 1 exit status

This seems to be a bug in GDC since it happens on only this one
platform and net searching says that GCC has had problems with symbol
interpositioning in the past. This is easy to replicate without Meson.
Write this code to source.d:

import std.stdio;
import utils;
import std.string : format;

void printGreeting (string name)
{
writeln ("Hello, I am %s.".format (name));
}

void main ()
{
printGreeting ("a Meson D test");
}

Compiling it with 'gdc -o prog source.d' gives the same error.
Removing the string formatting portion makes it work again as does
compiling with -fPIC, but if that is somehow always needed GDC should
either add -fPIC itself, error out earlier or, at the very least,
print a more relevant error message. LDC compiles this same program
without errors without needing -fPIC.

If this issue is in GDC and it is not fixed until the next release,
Meson will fix the issue by changing the build dep from gdc to ldc.

Thanks,



Processed: Re: Bug#846742: meson: FTBFS: ld: final link failed: Bad value

2016-12-03 Thread Debian Bug Tracking System
Processing commands for cont...@bugs.debian.org:

> reassign 846742 gdc
Bug #846742 [src:meson] meson: FTBFS: ld: final link failed: Bad value
Bug reassigned from package 'src:meson' to 'gdc'.
No longer marked as found in versions meson/0.36.0-1.
Ignoring request to alter fixed versions of bug #846742 to the same values 
previously set
> stop
Stopping processing here.

Please contact me if you need assistance.
-- 
846742: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=846742
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems



Bug#846742: meson: FTBFS: ld: final link failed: Bad value

2016-12-03 Thread Lucas Nussbaum
Source: meson
Version: 0.36.0-1
Severity: serious
Tags: stretch sid
User: debian...@lists.debian.org
Usertags: qa-ftbfs-20161202 qa-ftbfs
Justification: FTBFS on amd64

Hi,

During a rebuild of all packages in sid, your package failed to build on
amd64.

Relevant part (hopefully):
> /usr/bin/ld: dsimpleapp@exe/utils.d.o: relocation R_X86_64_PC32 against 
> symbol 
> `_D3std5array17__T8appenderTAyaZ8appenderFNaNbNfZS3std5array17__T8AppenderTAyaZ8Appender'
>  can not be used when making a shared object; recompile with -fPIC
> /usr/bin/ld: final link failed: Bad value
> collect2: error: ld returned 1 exit status

The full build log is available from:
   http://aws-logs.debian.net/2016/12/02/meson_0.36.0-1_unstable.log

A list of current common problems and possible solutions is available at
http://wiki.debian.org/qa.debian.org/FTBFS . You're welcome to contribute!

About the archive rebuild: The rebuild was done on EC2 VM instances from
Amazon Web Services, using a clean, minimal and up-to-date chroot. Every
failed build was retried once to eliminate random failures.