Re: [pcre-dev] 7.9-RC2 test release CMake error

Top Page
Delete this message
Author: Sheri
Date:  
To: pcre-dev
Subject: Re: [pcre-dev] 7.9-RC2 test release CMake error
Sheri wrote:
> Philip Hazel wrote:
>
>> My guess is that the variable CMAKE_BUILD_TYPE is not getting set in
>> your environment, somehow. Please add this line:
>>
>> MESSAGE(STATUS "CMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}")
>>
>> and see what output you get.
>>
>>
>>
> Currently I never see any cmake "status" messages anywhere. I tried the
> above and got no message, and the error situation persisted.
>
>
>> Something else to try! Please try changing that line to
>>
>>    STRING(TOUPPER "${CMAKE_BUILD_TYPE}" buildtype)  

>>
>> If the variable is unset, that should set "buildtype" to an empty
>> string.
>>
>>
>
> Changed as above, I did not get the error any more. But I still don't
> get any status messages, and therefore, no configuration summary.
>
>
>> I can only run it as a command-line thing, not interactively.
>>
>>
>>
> Have you tried running the CMakeSetup program? Surely it must work in Linux.
>
> Regards,
> Sheri
>
>
>

This is how I generally configure and make pcre:

Run Msys (shows terminal window)
In Msys, enter CMakeSetup<enter> (opens CMakeSetup windows)
Select PCRE source dir and desired output dir
Select Msys as target
Select various PCRE options
Click Configure and OK (closes the CMakeSetup window)
In Msys, cd to build directory
In Msys, enter make<enter>
(go through more steps if I want to rebuild the libraries with my coff
files)
wait until all the targets are built.
Open Windows Command Window
Copy RunTest.bat to output dir and edit it to supply relative path to
source dir
Run RunTest.bat
Run cpp tests (just for test purposes)
done.

I just tried this in Msys in my build dir:
make clean
(waited for completion)
cmake -C CMakeCache.txt

Among the output was the long lost configuration summary!

But, it also gave these errors:

CMakeCache.txt:17:
Parse error. Expected a command name, got unquoted argument with text
"//Build".
CMake Error: Error processing file:CMakeCache.txt

Line 17 in the cache file is the first of numerous comments in the file
taking the format:
//Build shared libraries instead of static ones.

There are other comments in the file in the format:
# It was generated by CMake: c:/cmake/bin/cmake.exe

The output concluded with this line:
-- Configuring incomplete, errors occurred!

Below is the complete console output in MSys after using "cmake -C
CMakeCache.txt"<enter>

$ cmake -C CMakeCache.txt
loading initial cache file CMakeCache.txt
CMake Error: Error in cmake code at
C:/pcre-7.9/pcre-7.9-RCX/Msys_Shared/CMakeCache.txt:17:
Parse error. Expected a command name, got unquoted argument with text
"//Build".
CMake Error: Error processing file:CMakeCache.txt
-- Could not find OPTIONAL package BZip2
-- Could not find OPTIONAL package ZLIB
-- Could not find OPTIONAL package Readline
--
--
-- PCRE configuration summary:
--
-- Install prefix .................. : C:/Program Files/PCRE
-- C compiler ...................... : C:/MinGW/bin/gcc.exe
-- C++ compiler .................... : c:/mingw/bin/g++.exe
-- C compiler flags ................ : -O3 -DNDEBUG
-- C++ compiler flags .............. : -O3 -DNDEBUG
--
-- Build C++ library ............... : ON
-- Enable UTF-8 support ............ : ON
-- Unicode properties .............. : ON
-- Newline char/sequence ........... : ANYCRLF
-- \R matches only ANYCRLF ......... : ON
-- EBCDIC coding ................... : OFF
-- Rebuild char tables ............. : OFF
-- No stack recursion .............. : ON
-- POSIX mem threshold ............. : 10
-- Internal link size .............. : 2
-- Match limit ..................... : 10000000
-- Match limit recursion ........... : MATCH_LIMIT
-- Build shared libs ............... : ON
-- Build static libs ............... : OFF
-- Build pcregrep .................. : ON
-- Build tests (implies pcretest) .. : ON
-- Link pcregrep with libz ......... : None
-- Link pcregrep with libbz2 ....... : None
-- Link pcretest with libreadline .. : None
-- Non-standard dll names (prefix) . : ON
-- Non-standard dll names (suffix) . : OFF
--
-- Configuring incomplete, errors occurred!