[zeromq-dev] zmq cmake patch

Pavol Malosek malosek at fastmq.com
Thu Nov 20 12:59:57 CET 2008


In attachment is patch against rev. 641 it adds only very basic support for 
cmake (only zmq and zmq_server is build on Linux).
It is based on your work and should be seen as a model and starting point. 
I'm "few hours" cmake user and hence your experience is important for us, 
anyway here are my notes to cmake support.

1. At first we would like to use as many macros provided by cmake as 
 Searching for thread library can be done with find_package Threads. There's 
FindSDL.cmake and FindJava.cmake in Modules directory and we should 
presumably use those.

2. Add as less new files as possible.
 I have moved code from zmq_platform_checks.cmake and 
zmq_cmake_policies.cmake into main CMakeLists.txt file they are easy to spot 
and modiffy. Note that changes should be able to make even user which is not 
so familiar with cmake and with no so much time to explore all the cmake 

3. If something is getting wrong stop the configure process.
 For example if you are on unsupported platform or some library was not 
found all the process should be stopped with some warning.

4. We prefer to build shared libraries by default.

5. Do not make it look ZMQ specific.
 Your are creating macros zmq_find_unicap.cmake which can be acctualy 
FindUnicap.cmake and used with find_package interface.

Do not take an offence, maybe I have missed something and you have good 
reason to do thing the way you do it, we just need a little explanation.
Anyway as soon as you are signing Copyright Assignment and License we will 
create you branch where we can continue work on cmake patch.

Believe that we have spend a long time to fight with autotools and cmake 
seems for us like a nice option to move forward.


----- Original Message ----- 
From: "George Neill" <georgen at neillnet.com>
To: "Pavol Malosek" <malosek at fastmq.com>
Cc: <zeromq-dev at lists.zeromq.org>
Sent: Wednesday, November 19, 2008 5:44 PM
Subject: Re: [zeromq-dev] zmq cmake patch

> Sounds like a plan, let me know if I can answer any questions.  I
> tried to put all of the cmake stuff in a directory (less the
> CMakeLists.txt files).  I suppose you could certainly consolidate some
> of those files, however the layout/files I propose in the patch made
> sense to me when i created it.  I'll be curious to see what you
> change.
> Thanks much,
> George.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: zmq_cmake.diff
Type: application/octet-stream
Size: 7970 bytes
Desc: not available
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20081120/e40f5fcb/attachment.obj>

More information about the zeromq-dev mailing list