PROPOSAL: Use Cmake as the build system for Samba

simo idra at samba.org
Wed Feb 17 16:05:55 MST 2010


On Thu, 2010-02-18 at 09:53 +1100, tridge at samba.org wrote:
> Hi Simo,
> 
>  > I didn't consider building cmake ourselves, I did instead consider
>  > deploying an already built binary. Would there be any problem with
>  > that ?
> 
> I doubt that would work. Even static binaries don't work on all
> systems, as they can have library dependencies (yes, static bins
> depend on libs, as I discovered recently with mtools, and the iconv
> dependencies on Linux).
> 
> So building a working cmake binary for all the weird systems in the
> build farm, plus future systems, would be very difficult.
> 
> Much easier to build it ourselves on the build machines (when cmake is
> not installed already).
> 
> We wouldn't build it each time - we'd just build it once and leave it
> installed, much like we do for the s4 smbtorture for s3.

I was considering the binary option only for those buildfarm machines
that can't build it and still haven't it installed. I suspect they will
be very few if any.
But as I said in the initial email one of the first steps would be to
asses if this is really problematic. If it turns out to be we can back
out without having committed too much.

>  > I haven't done a comparison with SCons but the independence of cmake
>  > from external interpreted languages is a feature I highly appreciate.
>  > 
>  > With python I see a problem, we already do not support anything less
>  > than 2.4 and soon python 3.0 will start to appear upstream. 2.4 and 3.0
>  > are not really compatible, so I think that adopting a build system that
>  > depends on python might give us trouble on some platforms in time.
> 
> We are already tied into python in a big way in Samba4, and that is
> likely to increase over time. Depending on python for building adds no
> additional problems that I can see, at least for s4.
> 
> For Samba3, depending on python adds a bit of pain, but I don't see it
> as being more of a pain than depending on cmake. Python has become a
> basic dependency of modern Unix systems. cmake hasn't :-)
> 
> The python-3 argument doesn't seem right to me. People already
> commonly have 3 versions of python installed on their systems, and I
> can't imagine any distro will drop python-2.x until all packages that
> depend on it (including Samba) are migrated.

The Samba 3 angle is the one under which I made the above python
comment. The reason why we are proposing CMake however is more about
it's proven record and capabilities. We are willing to dedicate effort
to something that resolves some of the main pains we had, namely lack of
knowledge/support of the current build system.
CMake looks like a good candidate.

Changing the build system is challenging enough, from our analysis CMake
looks like the best shot at being able to pull it out, the others looks
more like a shot in the dark.

Simo.

-- 
Simo Sorce
Samba Team GPL Compliance Officer <simo at samba.org>
Principal Software Engineer at Red Hat, Inc. <simo at redhat.com>



More information about the samba-technical mailing list