On 14.11.2011 08:58, Peter Kümmel wrote:
On 13.11.2011 21:21, Uwe Stöhr wrote:
Today I took the time and restarted from scratch, meaning to set up a clean new 
build system.
I followed the instructions bit by bit but CMake does not compile. In contrary 
to my old system it
even didn't start a compilation.

I fail to execute the build.bat script. Windows stops at this construct:

First you should start with plain cmake commands. The batch script is only a 
try to simplify things.
But I'll have a look at it.

Peter



if [%GNUWIN32_DIR%]==[] (
        echo GNUWIN32_DIR not set.
        echo Downloading win32 deps.
        set DEPENDENCIES_DOWNLOAD="-DLYX_DEPENDENCIES_DOWNLOAD=1"
) else (
        echo LyX deps : "%GNUWIN32_DIR%"
        set PATH=%GNUWIN32_DIR%\bin;%PATH%
)

and tells me that there is a syntax error. When I change the construct to

if [%GNUWIN32_DIR%]==[] (
        echo GNUWIN32_DIR not set.
) else (
        ::echo LyX deps : "%GNUWIN32_DIR%"
        ::set PATH=%GNUWIN32_DIR%\bin;%PATH%
)

I also get a syntax error that ")" is not allowed at this position. I played 
with this now for more
than an hour and also read the batch file syntax definition and parsed some 
forums - without any
success.
Also when I omit this structure and use

set PATH=%GNUWIN32_DIR%\bin;%PATH

directly, I get no syntax error, but nothing happens. The script finishes 
without invoking a
compilation.
I use the script that is currently in SVN trunk and invoke it from within a 
MSVC console with the
command
build.bat -install

Can anybody help me please?

Somehow reusing PATH does not work: set PATH=%GNUWIN32_DIR%\bin;%PATH%
But this has nothing to do with cmake, it's ms batch file scripting.

I would set all needed environment variables and call a batch script with a 
one-line cmake call.

Peter




regards Uwe


Reply via email to