[cmake-developers] cmake server mode

michele pagot michele.pagot at hotmail.it
Wed Sep 28 19:18:33 EDT 2016


I'm interested in the cmake server mode. I've started from https://steveire.wordpress.com/2016/01/24/cmake-daemon-for-user-tools/ and then to  https://github.com/steveire/CMake.git and finally to the cmake official  git master branch as it seems e

I rebuilt it from scratch on Windows trying both VS2010 and MinGW. With this second one, using gcc4.8. Everything seems fine as the build works as expected and

the inline help report server mode with both compilers.


>> c:\......\cmake\cmake_master\build\buils_vs2010\bin\Debug\cmake.exe -E
> CMake Error: cmake version 3.6.20160928-g9a9b9
> Usage: c:\.......\cmake\cmake_master\build\buils_vs2010\bin\Debug\cmake.exe -E <command> [arguments...]
> Available commands:
>   capabilities              - Report capabilities built into cmake in JSON format
>   chdir dir cmd [args...]   - run command in a given directory
>   compare_files file1 file2 - check if file1 is same as file2
>   copy <file>... destination  - copy files to destination (either file or directory)
>   copy_directory <dir>... destination   - copy content of <dir>... directories to 'destination' directory
>   copy_if_different <file>... destination  - copy files if it has changed
>   echo [<string>...]        - displays arguments as text
>   echo_append [<string>...] - displays arguments as text but no new line
>   env [--unset=NAME]... [NAME=VALUE]... COMMAND [ARG]...
>                             - run command in a modified environment
>   environment               - display the current environment
>   make_directory <dir>...   - create parent and <dir> directories
>   md5sum <file>...          - create MD5 checksum of files
>   remove [-f] <file>...     - remove the file(s), use -f to force it
>   remove_directory dir      - remove a directory and its contents
>   rename oldname newname    - rename a file or directory (on one volume)
>   server                    - start cmake in server mode
>   sleep <number>...         - sleep for given number of seconds


but as I try to use it:

>> cmake -E server
> CMake Error: CMake was not built with server mode enabled
>
First issue: server reported in the help even if not included

the  new feature seems to be activated only if some special compiler capability are fulfilled. So I've changed compiler to gcc5.3 and now I'm even nor able to build due to errors like:

[  2%] Building CXX object Source/kwsys/CMakeFiles/cmsys.dir/RegularExpression.cxx.obj
[  2%] Building CXX object Source/kwsys/CMakeFiles/cmsys.dir/SystemTools.cxx.obj
c:/userdata/draft/cmake/cmake_master/cmake/Source/kwsys/SystemTools.cxx: In member function 'bool cmsys::SystemToolsPathCaseCmp::operator()(const string&, const string&) const':
c:/userdata/draft/cmake/cmake_master/cmake/Source/kwsys/SystemTools.cxx:465:43: error: 'strcasecmp' was not declared in this scope
     return strcasecmp(l.c_str(), r.c_str()) < 0;
                                           ^
c:/userdata/draft/cmake/cmake_master/cmake/Source/kwsys/SystemTools.cxx: In static member function 'static bool cmsys::SystemTools::ComparePath(const string&, const string&)':
c:/userdata/draft/cmake/cmake_master/cmake/Source/kwsys/SystemTools.cxx:4289:43: error: 'strcasecmp' was not declared in this scope
   return strcasecmp(c1.c_str(), c2.c_str()) == 0;
                                           ^
make[2]: *** [Source/kwsys/CMakeFiles/cmsys.dir/SystemTools.cxx.obj] Error 1
make[1]: *** [Source/kwsys/CMakeFiles/cmsys.dir/all] Error 2
make: *** [all] Error 2

Fixed by:
#endif
#include <stdio.h>
#include <stdlib.h>
#include <string>
#include <strings.h>
#include <sys/stat.h>










c:/userdata/draft/cmake/cmake_master/cmake/Utilities/cmlibarchive/libarchive/archive_read.c:825:1: error: conflicting types for 'archive_read_data'
 archive_read_data(struct archive *_a, void *buff, size_t s)
 ^
In file included from c:/userdata/draft/cmake/cmake_master/cmake/Utilities/cmlibarchive/libarchive/archive_read.c:51:0:
c:/userdata/draft/cmake/cmake_master/cmake/Utilities/cmlibarchive/libarchive/archive.h:581:24: note: previous declaration of 'archive_read_data' was here
 __LA_DECL la_ssize_t   archive_read_data(struct archive *,
                        ^
make[2]: *** [Utilities/cmlibarchive/libarchive/CMakeFiles/cmlibarchive.dir/archive_read.c.obj] Error 1
make[1]: *** [Utilities/cmlibarchive/libarchive/CMakeFiles/cmlibarchive.dir/all] Error 2
make: *** [all] Error 2


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake-developers/attachments/20160928/205f0188/attachment-0001.html>


More information about the cmake-developers mailing list