Hi Ged,

I'm sad to hear how much effort it was to install CMake on your machine, and 
very surprised to hear that it crashed your machine. 
On most x86 and amd64 distributions, the `pip3 install cmake` step takes a few 
seconds because it is precompiled. Which os/distro/arch are you using? 
You mention Debian Stretch (9). The package from apt-get is version 3.7.2 which 
is definitely too old. But using pip3, with Debian Stretch in a new docker 
debian:9 container it takes 2.971 seconds to install:

    root@9e6c4f667db4:/# time pip3 install cmake
    Collecting cmake
      Downloading 
https://files.pythonhosted.org/packages/2e/e6/988e201a5fea43dafcdcfd7b4b8e971c0adf22ee554cd1fa1a84237ea41a/cmake-3.21.0-py2.py3-none-manylinux_2_5_x86_64.manylinux1_x86_64.whl
 (19.8MB)
        100% |################################| 19.8MB 109kB/s
    Installing collected packages: cmake
    Successfully installed cmake-3.21.0

    real    0m5.178s
    user    0m2.971s
    sys     0m0.602s
    root@9e6c4f667db4:/#

You're right that milter is required by default now.  The approach with the old 
build system was so the optional stuff would be skipped if you didn't have it.  
- No libbz2? No support for bzip2.
- No libxml2? No support for DMG, DOCX, MHTML, and other types that use XML.
- No pcre or pcre2 library? Some regexes won't work.
Etc. 

Personally I don't think this is acceptable. I don't trust everyone to remember 
to install the "optional" dependencies, and we certainly don't test the project 
in every variation with some or all of the (previously) optional dependencies 
omitted.  I wouldn't be surprised if there are crashes with some features 
disabled. 

I accept that requiring milter by default doesn't quite fall into the same 
category in that it won't cause clamscan failures, or false negatives or 
anything. But I think users should still be able to expect that a default build 
gives them all the features. But I mostly don't want to deal with a situation 
where a user on distribution-X can't find clamsubmit because the package 
maintainer accidentally installed libjson-c instead of libjson-c-devel (just an 
example).  That's my mindset. That's why I chose to make everything required 
for a default CMake build.

If you don't want to build clamav-milter, you can use `-D ENABLE_MILTER=OFF` 
and then skip the milter dependency. 
See the INSTALL.md file for more options: 
https://github.com/Cisco-Talos/clamav/blob/239ede802387ec89b25502b2f8bb0fee0778728f/INSTALL.md#custom-cmake-options

Sorry I really have zero interest in bringing back and update Autotools for 
0.104.
For what it's worth, we do plan to publish a clamav 0.103.4 patch version 
alongside an 0.104.1 version in probably 2 months (give or take).  Depending on 
how 0.104 adoption goes, we could have an 0.103.5 version as well, but I don’t 
expect that we will.

Regards,
Micah

> -----Original Message-----
> From: clamav-users <clamav-users-boun...@lists.clamav.net> On Behalf Of
> G.W. Haywood via clamav-users
> Sent: Friday, July 23, 2021 12:32 PM
> To: Micah Snyder (micasnyd) via clamav-users <clamav-
> us...@lists.clamav.net>
> Cc: G.W. Haywood <cla...@jubileegroup.co.uk>
> Subject: Re: [clamav-users] ClamAV® blog: ClamAV 0.104.0 Release
> Candidate is here!
> 
> Hi Micah,
> 
> On Thu, 22 Jul 2021, Micah Snyder (micasnyd) via clamav-users wrote:
> > G.W. Haywood via clamav-users wrote:
> >> On Thu, 22 Jul 2021, Joel Esler (jesler) via clamav-users wrote:
> >>
> >>> ...
> >>> ClamAV 0.104.0 Release Candidate is here!
> >>> ...
> >>>  Please help us validate this release. We need your feedback, so let
> >>> us know what you find ...
> >>
> >> It won't build on Debian Stretch:
> >> ...
> >> CMake 3.14 or higher is required.  You are running version 3.13.4 ...
> >
> > The CMake project has been moving relatively quickly the past few
> > years. We depend on some of the newish features (though they're
> > already up to 3.21 now).  The easiest way to get a newer version of
> > CMake is to install it through Python 3's package manager: pip.
> >
> > I just finished updating the online documentation for building with
> > CMake.  I've included instructions for how to install CMake, using pip
> > if necessary for some systems:
> > https://docs.clamav.net/manual/Installing/Installing-from-source-Unix.
> > html#install-prerequisites
> 
> The first two attempts crashed the machine.  The first after half an hour, the
> second after two hours but by then I was in bed.  I 'time'd the third attempt.
> Five and a half hours.  Well the root partition is on NFS, but even so...
> 8<----------------------------------------------------------------------
> $ time python3 -m pip install --user cmake Looking in indexes:
> https://pypi.org/simple, https://www.piwheels.org/simple Collecting cmake
>    Using cached https://files.pythonhosted.org/.../cmake-3.21.0.tar.gz
>    Installing build dependencies ... done Building wheels for collected
> packages: cmake
>    Running setup.py bdist_wheel for cmake ... done
>    Stored in directory: /home/ged/.cache/pip/wheels/56/3b/6e/6f...1d
> Successfully built cmake
> Installing collected packages: cmake
>    ...
> Successfully installed cmake-3.21.0
> 
> real    329m38.416s
> user    42m44.762s
> sys     7m39.186s
> 8<----------------------------------------------------------------------
> 
> > I hope this works for okay for you.
> 
> It worked in the end, thanks.  At least it built some executables, I haven't
> tried running them and probably won't for the moment as there are other
> fish to fry.
> 
> It took me about a day to get cmake set up.  Then cmake insisted on things
> like libmiter and valgrind by default, which I guess like me most people
> probably won't want.  I wonder if you should consider a reprieve for
> autotools, at least until the major distros have a cmake that will build
> ClamAV, because I think what I had to do would be well beyond the
> attention span of most ClamAV users.
> 
> When I rebuilt 0.103.3 using autotools to compare with the cmake build, it
> somewhat curiously failed to find libmilter although I'd installed it for the
> cmake build.  I haven't investigated that yet.
> 
> The cmake build was about 20% quicker than using autotools.
> 
> HTH
> 
> --
> 
> 73,
> Ged.
> 
> _______________________________________________
> 
> clamav-users mailing list
> clamav-users@lists.clamav.net
> https://lists.clamav.net/mailman/listinfo/clamav-users
> 
> 
> Help us build a comprehensive ClamAV guide:
> https://github.com/vrtadmin/clamav-faq
> 
> http://www.clamav.net/contact.html#ml

_______________________________________________

clamav-users mailing list
clamav-users@lists.clamav.net
https://lists.clamav.net/mailman/listinfo/clamav-users


Help us build a comprehensive ClamAV guide:
https://github.com/vrtadmin/clamav-faq

http://www.clamav.net/contact.html#ml

Reply via email to