Boost logo

Boost-Build :

From: David Abrahams (gclbb-jamboost_at_[hidden])
Date: 2003-05-14 06:14:11

Vladimir Prus <ghost_at_[hidden]> writes:

> David Abrahams wrote:
>> > Will try again tomorrow, just in case I was not attentive. I think the
>> > real problem is that I don't understand where the bug comes from.
>> The bug comes from the fact that all :X path modifiers rely on
>> facilities which first parse the path by separating out directory,
>> basename, extension, etc., and then reconstitute the unchanged parts,
>> inserting PATHSEP where neccessary.
>> That means foo/bar/baz.x becomes more like
>> directory: foo/bar
>> basename: baz
>> extension: x
>> If you strip the extension, say, it puts the first two parts back
>> together as:
>> foo/bar\baz
> Why, when merging "foo/bar" with "baz" we look at past-the-end symbol of
> "foo/bar" in hope that the right separator will be there?

Because it's simple and it gives the right result most of the time.
Can you propose a better rule?

> I believe that relies on the assumption that pointers in _pathname
> struct all refer to original filename

Not exactly. It just is only attempting to handle those cases where
the user will be completely astonished that a slash direction has

Dave Abrahams
Boost Consulting

Boost-Build list run by bdawes at, david.abrahams at, gregod at, cpdaniel at, john at