Commit Graph

2 Commits

Author SHA1 Message Date
Tobias Hunger d341d077c5 cmake-server: Implement ServerProtocol 1.0
Enable the initial handshake of the client to complete the connection
to the server.

The handshake sets the protocol version that client and server will
use to talk to each other. The only way to change this is to quit the
server and start over.

CMake specific information is also set during the initial handshake.
Since cmake so far never had to change basic information about any project
while running, it was decided to keep this information static and
require a restart of the cmake server to change any of these.
2016-09-19 08:57:57 -04:00
Tobias Hunger b13d3e0d0b cmake-server: Bare-bones server implementation
Adds a bare-bones cmake-server implementation and makes it possible
to start that with "cmake -E server".

Communication happens via stdin/stdout for now.

Protocol is based on Json objects surrounded by magic strings
("[== CMake Server ==[" and "]== CMake Server ==]"), which simplifies
Json parsing significantly.

This patch also defines an interface used to implement different
versions of the protocol spoken by the server, but does not include
any protocol implementaiton.
2016-09-19 08:57:57 -04:00