CMake support

51 views
Skip to first unread message

Paul Harris

unread,
May 31, 2012, 9:45:05 AM5/31/12
to jansso...@googlegroups.com
Hi,

I'm surprised noone has brought this up yet...

Could we add support for the cmake build system?

Advantages:
* easier to support windows builds
* out-of-tree builds, so I can build static, dynamic, static-debug, dynamic-debug, static-debug-static-runtime, etc combinations (each one often needs to be independent in windows)
* used in many projects already.

thanks,
Paul

Petri Lehtinen

unread,
Jun 1, 2012, 1:57:32 AM6/1/12
to jansso...@googlegroups.com
Paul Harris wrote:
> Hi,
>
> I'm surprised noone has brought this up yet...

It has been brought up before:

https://github.com/akheron/jansson/issues/28
https://github.com/akheron/jansson/pull/48

> Could we add support for the cmake build system?
>
> Advantages:
> * easier to support windows builds
> * out-of-tree builds, so I can build static, dynamic, static-debug,
> dynamic-debug, static-debug-static-runtime, etc combinations (each one often
> needs to be independent in windows)
> * used in many projects already.

The Windows project files for VS 2010 are already included in master,
and will be a part of the next major release, so there's no point in
switching the build system because of Windows.

Petri

Paul Harris

unread,
Jun 1, 2012, 2:38:49 AM6/1/12
to jansso...@googlegroups.com
I would like to humbly disagree.  I use VS 2008 at the moment.
I will be looking to build on windows soon, so if I make a cmake setup, would you like me to contribute?

cheers,
Paul

Petri Lehtinen

unread,
Jun 1, 2012, 2:48:38 AM6/1/12
to jansso...@googlegroups.com
Paul Harris wrote:
> I would like to humbly disagree. I use VS 2008 at the moment. I will
> be looking to build on windows soon, so if I make a cmake setup,
> would you like me to contribute?

I'm not willing to maintain configuration for a build system I have no
clue about and that, in my opinion, is inferior to autotools. Jansson
also builds just fine on MinGW, so I still don't think that Windows
should have any more special treatment.

If the VS 2010 project files don't work on VS 2008, it's not hard to
create a project for VS 2008 by hand. Just include all the sources
under src/, jansson_config.h under win32/vs2010/, and use
src/jansson.def as the module-definition file for the linker.

Petri

Paul Harris

unread,
Jun 1, 2012, 2:50:40 AM6/1/12
to jansso...@googlegroups.com
Ok, I respect that.
I might try and maintain it under a fork on github (my first attempt with github).  If you have a look and like what you see, then you can perhaps look at using it.  Other people can pull from both our trees if they like it.

Paul Harris

unread,
Jun 1, 2012, 3:07:04 AM6/1/12
to jansso...@googlegroups.com
By the way, I like your API :)  good work!

Petri Lehtinen

unread,
Jun 1, 2012, 3:08:58 AM6/1/12
to jansso...@googlegroups.com
Paul Harris wrote:
> By the way, I like your API :) good work!

Thanks, I appreciate it. :)

Petri
Reply all
Reply to author
Forward
0 new messages