Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2004-09-26 07:46:41


Rene Rivera <grafik.list_at_[hidden]> writes:

> Rene Rivera wrote:
>
>> David Abrahams wrote:
>>
>>> Calling cw_env.bat may be needed in order to establish the PATH
>>> needed to find the C++ runtime DLLs. If you eliminated that call,
>>> maybe we need to find a way to do the same thing that doesn't mess up
>>> the errorlevel.
>> I talked with Stefan off-list and I think I have a solution to the
>> problem. Hopefully it works and I'll commit the change :-)
>
> OK. I believe the problem is now resolved. The problem is a "bug"
> introduced in the cwenv.bat of CodeWarrior 9. There is now an
> additional last action this script takes:
>
> ========
> rem Not sure why we sometimes have errors...
> set ERRORLEVEL=0
> ========
>
> Doing that is just plain wrong. It forever sets the error from that
> point forward.

In some sense this is my fault. I reported to MW that their setup
script often exits with an error code despite success, which prevents

       cwenv.bat && mwcc ...

from succeeding. If you konw the right fix, would you please email
Ed Swartz (Cc'd here) and let him know?

> My suggestion for them to fix it is to use a command that is
> guaranteed to succeed to clear the ERRORLEVEL like "cd >nul".

Ah. Well, maybe there's no need to notify him, then ;-)

Boy, the .bat language sucks.

-- 
Dave Abrahams
Boost Consulting
http://www.boost-consulting.com

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk