June 01, 2013
On 06/01/2013 01:34 AM, Shriramana Sharma wrote:

> All programs compiled by *DMD* produce a segfault. Programs compiled
> by GDC work just fine.

It is likely that GDC is from the D1 era.

> What is this, some sort of incompatibility between compilers?

If one is D1 and the other is current D, it is possible.

> Like GDC went and told my system "hey look only D programs compiled by me
> should work"?!

Of courne not intentional like that but clearly there is some incompatibility there.

> I couldn't try LDC since they don't have Ubuntu packages

I don't know for sure but neither GDC nor LDC packages that come under Linux distributions are modern enough.

If so, I would remove GDC and try installing only dmd 2.063 again.

Ali

June 01, 2013
On Jun 1, 2013 3:46 PM, "Ali Çehreli" <acehreli@yahoo.com> wrote:
> If so, I would remove GDC
> and try installing only dmd
> 2.063 again.

Tried that in all sorts of combinations. Still no use.

Would there be some config files conflicting? But such conflicts would be reflected at compile time, not runtime, right?

Since I don't want to reinstall my Ubuntu system just for this (that would be so Windows-like!), I'd appreciate pointers to resolve the situation. Thanks.

Or should I take this to the d.gnu list or something?


June 01, 2013
On Saturday, 1 June 2013 at 11:43:15 UTC, Shriramana Sharma wrote:
> On Jun 1, 2013 3:46 PM, "Ali Çehreli" <acehreli@yahoo.com> wrote:
>> If so, I would remove GDC
>> and try installing only dmd
>> 2.063 again.
>
> Tried that in all sorts of combinations. Still no use.
>
> Would there be some config files conflicting? But such conflicts would be
> reflected at compile time, not runtime, right?
>
> Since I don't want to reinstall my Ubuntu system just for this (that would
> be so Windows-like!), I'd appreciate pointers to resolve the situation.
> Thanks.
>
> Or should I take this to the d.gnu list or something?

Sometimes running ldconfig will solve wierd problems like this.
June 01, 2013
On Sat, Jun 1, 2013 at 7:57 PM, Anthony Goins <neontotem@gmail.com> wrote:
>
> Sometimes running ldconfig will solve wierd problems like this.

Thanks and I tried that just now but no fruit. :-(

-- 
Shriramana Sharma ஶ்ரீரமணஶர்மா श्रीरमणशर्मा

June 05, 2013
On Saturday, 1 June 2013 at 10:11:35 UTC, Ali Çehreli wrote:
> On 06/01/2013 01:34 AM, Shriramana Sharma wrote:
>
> > All programs compiled by *DMD* produce a segfault. Programs
> compiled
> > by GDC work just fine.
>
> It is likely that GDC is from the D1 era.
>

Not that package,  it's an old D2 release, circa 2.046. and even then it has a different library name (libgphobos.a) and the module headers are installed in a separate directory from dmd.
June 05, 2013
On Saturday, 1 June 2013 at 14:41:13 UTC, Shriramana Sharma wrote:
> On Sat, Jun 1, 2013 at 7:57 PM, Anthony Goins <neontotem@gmail.com> wrote:
>>
>> Sometimes running ldconfig will solve wierd problems like this.
>
> Thanks and I tried that just now but no fruit. :-(

Try a *full* removal of the deb installations (dmd and gdc).

apt-get purge <program_name>

Then reinstall latest DMD first. and test before moving on with GDC.

If you are installing GDC from the distro, it's likely to be very old and of questionable use.

--rt
June 05, 2013
On Saturday, 1 June 2013 at 01:10:05 UTC, Shriramana Sharma wrote:
> On Sat, Jun 1, 2013 at 6:02 AM, Anthony Goins <neontotem@gmail.com> wrote:
>>
>> Works for me ubuntu 64.
>> Do you have both versions installed?
>
> Of course not. The later install from the distributed DEB (from
> dlang.org) overwrites the earlier one by apt install.
>

I would not trust the DEB package as my understanding is that the deb are not being properly produced at this time. Like I said, try a full removal using "purge" and reinstalling again.

See this ...
http://forum.dlang.org/thread/ffoovmyiwytfbvykcaew@forum.dlang.org?page=7#post-koionl:241d0t:241:40digitalmars.com

--rt
June 11, 2013
On Friday, 31 May 2013 at 17:14:46 UTC, Shriramana Sharma wrote:
> import std.stdio ;
>
> void foo ( int[] array ) {
> 	foreach ( i ; array ) { writeln ( i ) ; }
> }
>
> void main () {
> 	foo ( [ 1, 2, 3 ] ) ;
> }
>
> On both DMD 2.062 and 2.063 this compiles OK but causes a segfault.
> I'm running Kubuntu Raring 64-bit. Any hints?

If you can attach your test-case program that segfaults compiled on that Kubuntu x86_64 I would be grateful.

It will allow to see if it is OS problem, hardware problem or it is DMD that is producing bad code in some specific scenarios.

Also it is easier to debug and reverse program when binary is given.
Thanks in advance.
1 2
Next ›   Last »