WeakRef updated to better support Tango -- and a question

Sean Kelly sean at invisibleduck.org
Tue Mar 25 11:58:11 PDT 2008


== Quote from Jason House (jason.james.house at gmail.com)'s article
> Sean Kelly Wrote:
> > == Quote from Jaaon House (jason.james.house at gmail.com)'s article
> > > Lars Ivar Igesund Wrote:
> > > > Jason House Wrote:
> > > >
> > > > > Regardless, adding -lgtango and -lgphobos doesn't solve my linking issues.
> > > > > Below is a copy and paste of the complete output.  I also attached my TT
> > > > > code that's causing my problem.
> > > >
> > > > I wasn't suggesting that these were missing, but rather that you got the Phobos version of the runtime. If that is not the case, could you
> > please take it to the Tango forum or create a ticket?
> > > >
> > > > Lars Ivar
> > > Given that I must continue using 0.99.4, and the ensuing pain to rebuild and install Tango without the installer, what is the easiest way to
> > test this?
> >
> > Use any non-template Tango routine and see if you get a linker error
> >  when building the app.
> They're sprinkled throughout the 9000+ line code base.  It all worked before I tried using the weak ref stuff.  I also know that -lgtango was required with
gdc to compile with gdc.  I added -lgphobos based off of this thread.

I was actually suggesting creating a simple "hello world" app and see if it links.

> > But I'll admit to being a bit surprised that the
> > Tango build process is painful.  It amounts to running one script,
> > at least for the base lib.
> I'm not set up for building Tango every day.  The code I used to build/install 0.99.4 was purged from my machine.  I can't go to the Tango web site and
download 0.99.4 anymore.  I have to go to svn.  That means looking up the svn repository, finding the code, and checking it out.  Then I have to poke around
the Tango web site until I find the instructions on building and installing Tango (again, I don't do it every day).  Running the build script is a step in the
process, but I know it isn't everything.  The build script creates stuff, but then the proper files have to get moved to the proper locations.  That includes stuff
like tracking down which directories gdc uses.
> Maybe I'm slow, but that's not a 2 minute task for me.

I'm not sure if you're aware of it, but all previous Tango releases are still available on the website.  Here's the page:

http://dsource.org/projects/tango/wiki/PreviousReleases

As for building the base lib, run /trunk/lib/build-dmd.sh or /trunk/lib/build-gdc.sh as appropriat.  For the user portion that typically is built into libtango-
user-dmd.a (or libgphobos.a, I beleive), you can call trunk/lib/build-tango.sh to generate this lib or simply use DSSS/rebuild/Bud and forget about building
the lib altogether.  There are also install scripts in /trunk/lib called install-dmd.sh and install-gdc.sh to automate the install for you, or you can copy the libs
to /usr/lib and the import files to wherever your include path is set to find them.  In short, /trunk/lib is where you go to build and install Tango at the
moment.  We've been discussing restructuring things to make the location of scripts, etc, a bit more self-evident, but that hasn't happened yet.

As for this particular issue, the most likely explanation is that you're not linking against the proper lib for Tango as Lars said previously.


Sean



More information about the Digitalmars-d mailing list