Bug 12494 - build-system: libcurl required even with --enable-libclamav-only
build-system: libcurl required even with --enable-libclamav-only
Status: RESOLVED FIXED
Product: ClamAV
Classification: ClamAV
Component: All
stable
x86_64 GNU/Linux
: P3 normal
: 0.101.0
Assigned To: ClamAV team
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2020-02-14 15:34 EST by Michael Orlitzky
Modified: 2021-07-12 14:40 EDT (History)
3 users (show)

See Also:
QA Contact:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Orlitzky 2020-02-14 15:34:52 EST
clamav-devel $ ./configure --without-libcurl --enable-libclamav-only
...
checking for libcurl installation... configure: error: libcurl not found. libcurl (e.g. libcurl-devel) is required in order to build freshclam and clamsubmit.

The release notes for v0.102.0 suggest that this should work:

> Added ./configure --enable-libclamav-only option, for those wishing to bypass building of libfreshclam and the ClamAV CLI applications. This option also bypasses the libcurl dependency requirement.
Comment 1 Mickey Sola 2020-02-24 12:50:09 EST
I'll look into this.

The option worked during testing, but I don't think --without-libcurl was ever used in conjunction with it. It's possible that options results in a codepath where the flags to ignore running the setup macros for other binaries aren't set correctly, but I won't know for sure 'till I dig a bit.

In the meantime, could you try with *just* --enable-libclamav-only?
Comment 2 Michael Orlitzky 2020-02-24 13:07:01 EST
(In reply to Mickey Sola from comment #1)
> 
> In the meantime, could you try with *just* --enable-libclamav-only?

If you have libcurl installed and don't pass --without-libcurl, then it will still be detected and everything's fine:

  $ ./configure --enable-libclamav-only
  ...
  checking for curl-config... /usr/bin/curl-config
  checking for curl_easy_init in -lcurl... yes
  ...
  configure: Summary of miscellaneous features
              ...
              libcurl     : /usr

But if you don't have libcurl installed, no matter what you do, the build fails looking for it:

  $ sudo mv /usr/bin/curl-config /usr/bin/curl-config.bak
  $ ./configure --enable-libclamav-only
  ...
  checking for libcurl installation... configure: error: libcurl not found.
  libcurl (e.g. libcurl-devel) is required in order to build freshclam and
  clamsubmit.
Comment 3 Micah Snyder 2021-07-12 14:40:44 EDT
It appears we forgot to close this after Mickey fixed it, here: https://github.com/Cisco-Talos/clamav/commit/3ed42fcca433ca065f3816fbed66e1f5053680da

But also the autotools build system has been removed in 0.104. The same feature exists in the new CMake build and it should not have this bug.