DVM - D Version Manager 0.2.0

Nick Sabalausky a at a.a
Wed May 18 00:15:50 PDT 2011


"Jacob Carlborg" <doob at me.com> wrote in message 
news:iqvpon$6p0$1 at digitalmars.com...
> On 2011-05-18 06:35, Nick Sabalausky wrote:
>>
>> Sounds cool, but dvm-0.2.0-linux-32 is just giving me "Illegal 
>> instruction"
>> on Kubuntu 10.04 x86-32. And I don't see any instructions for how to 
>> build
>> it anywhere in the source tree or on the homepage.
>
> Ok, strange. I built the tool on Ubuntu 11.04, maybe it's too new. How can 
> I build it to work on as many platforms as possible? The runtime 
> dependencies are just the same as a regular C application and zlib.
>

You know, I'm far from a Linux expert, but making compatible linux binaries 
seems to be quite a nightmare. In fact, I just recently went through hell 
myself trying to figure out how to compile a Hello World CGI app on my linux 
system and have it actually work on another linux system.

You can follow my fun-filled adventures through it with these discussions:

digitalmars.D.learn: "D CGI test: linux.so.2: bad ELF interpreter: No such 
file or directory" (2011/04/25)
digitalmars.D.learn: "Linux: How to statically link against system libs?" 
(2011/04/26)
http://ubuntuforums.org/showthread.php?t=1740277

But the bottom line seems to be: Linux is in a bigger DLL hell than windows 
has ever been, and I don't think *anyone* actually knows how to do it.

In my case, I ended up just installing an older version of linux in a VM and 
compiling inside that (CentOS 4, largely because I needed to be able to run 
on a CentOS server that wasn't happy with my Kubuntu 10.04 executables). The 
resulting binaries did work on my Kubuntu 10.04 machine, too, so I guess the 
trick is to just compile on the oldest machine you can. Go figure: All the 
focus everyone puts on updating to newer versions, and it ends up best to 
stick with the older versions - not because the older ones were better, but 
just *because* they're older. Meh. Anyway, pardon the rant :/

You'd think there'd be a way to compile in a backwards-compatible way on 
linux, but I'm getting the impression that if it's possible, no one actually 
knows how.

> Added build instructions at the bottom of: https://bitbucket.org/doob/dvm
>

Thanks :) I think I'm almost there. I've been using D2/Phobos/RDMD for the 
past year or so (plus my usual machine is a windows box), so I had a lot of 
setting up to do, but I think I've almost got it now. When I do, I'll post 
the final binary in case it helps anyone else (I can only make a 32-bit 
binary though).





More information about the Digitalmars-d-announce mailing list