Created attachment 193664 [details] check_clamav.log Hi all, When I try to compile clamav 0.100.0_1, it fails the unit_tests and does not complete the installation. gmake check-TESTS gmake[4]: Entering directory '/usr/ports/security/clamav/work/clamav-0.100.0/unit_tests' gmake[5]: Entering directory '/usr/ports/security/clamav/work/clamav-0.100.0/unit_tests' FAIL: check_clamav PASS: check_freshclam.sh PASS: check_sigtool.sh SKIP: check_unit_vg.sh FAIL: check1_clamscan.sh FAIL: check2_clamd.sh PASS: check3_clamd.sh PASS: check4_clamd.sh SKIP: check5_clamd_vg.sh SKIP: check6_clamd_vg.sh SKIP: check7_clamd_hg.sh SKIP: check8_clamd_hg.sh SKIP: check9_clamscan_vg.sh gmake[6]: Entering directory '/usr/ports/security/clamav/work/clamav-0.100.0/unit_tests' gmake[6]: Nothing to be done for 'all'. gmake[6]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.100.0/unit_tests' ============================================================================ Testsuite summary for ClamAV 0.100.0 ============================================================================ # TOTAL: 13 # PASS: 4 # SKIP: 6 # XFAIL: 0 # FAIL: 3 # XPASS: 0 # ERROR: 0 ============================================================================ See unit_tests/test-suite.log Please report to https://bugzilla.clamav.net/ ============================================================================ gmake[5]: *** [Makefile:1089: test-suite.log] Error 1 gmake[5]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.100.0/unit_tests' gmake[4]: *** [Makefile:1197: check-TESTS] Error 2 gmake[4]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.100.0/unit_tests' gmake[3]: *** [Makefile:1352: check-am] Error 2 gmake[3]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.100.0/unit_tests' gmake[2]: *** [Makefile:756: check-recursive] Error 1 gmake[2]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.100.0' *** Error code 2 Stop. make[1]: stopped in /usr/ports/security/clamav *** Error code 1 Stop. make: stopped in /usr/ports/security/clamav But this one installs version 0.99.4 and run unit_tests: gmake[4]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.99.4/unit_tests' gmake check-TESTS gmake[4]: Entering directory '/usr/ports/security/clamav/work/clamav-0.99.4/unit_tests' gmake[5]: Entering directory '/usr/ports/security/clamav/work/clamav-0.99.4/unit_tests' PASS: check_clamav PASS: check_freshclam.sh PASS: check_sigtool.sh SKIP: check_unit_vg.sh PASS: check1_clamscan.sh PASS: check2_clamd.sh PASS: check3_clamd.sh PASS: check4_clamd.sh SKIP: check5_clamd_vg.sh SKIP: check6_clamd_vg.sh SKIP: check7_clamd_hg.sh SKIP: check8_clamd_hg.sh SKIP: check9_clamscan_vg.sh ====================== All 7 tests passed (6 tests were not run) ====================== gmake[5]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.99.4/unit_tests' gmake[4]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.99.4/unit_tests' gmake[3]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.99.4/unit_tests' Making check in clamsubmit gmake[3]: Entering directory '/usr/ports/security/clamav/work/clamav-0.99.4/clamsubmit' gmake[3]: Nothing to be done for 'check'. gmake[3]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.99.4/clamsubmit' gmake[3]: Entering directory '/usr/ports/security/clamav/work/clamav-0.99.4' gmake[3]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.99.4' gmake[2]: Leaving directory '/usr/ports/security/clamav/work/clamav-0.99.4' ===> Staging for clamav-0.99.4 ===> Generating temporary packing list ===> Creating groups. . . . I've tried everything I could to find out where the problem is, but I could not.
Created attachment 193665 [details] check1_clamscan.sh.log
Created attachment 193666 [details] check2_clamd.sh.log
Hi, I could not reproduce the problem at all. On some servers the problem does not occur and in others it occurs.
Had the same problem with clang. If I compile it with gcc6 unit-test works.
Is this still happening with 0.100.1?
(In reply to Larry Rosenman from comment #5) Same result, fails with the same error message with clang, succeed with gcc6.
Testsuite summary for ClamAV 0.100.1 ============================================================================ # TOTAL: 13 # PASS: 4 # SKIP: 6 # XFAIL: 0 # FAIL: 3 # XPASS: 0 # ERROR: 0 Tested on Freebsd 11.1 with clang 4 and 11.2 with clang 6 the same fail results on few servers Any chance to fix this?
(In reply to Martinos from comment #7) What options do you pick for the port? Can you post a link to the test suite output? Thanks! (I'll need to get the clamav folks involved).
Created attachment 196910 [details] Test-suite from 11.2 clang6 I checked the content in these files from different systems, I mean 11.1 with clang4 and 11.2 with clang6, the content is practically the same, only the .tmp files are different
Option port below: ===> The following configuration options are available for clamav-0.100.1_1: ARC=on: Enable arch archives support ARJ=on: Enable arj archives support DMG_XAR=on: Enable DMG and XAR archives support DOCS=on: Build and/or install documentation EXPERIMENTAL=off: Build experimental code ICONV=on: Encoding conversion support via iconv IPV6=on: IPv6 protocol support JSON=on: JSON file/format/parser support LDAP=off: LDAP protocol support LHA=on: Enable lha archives support MILTER=off: Compile the milter interface PCRE=on: Use Perl Compatible Regular Expressions STDERR=off: Print logs to stderr instead of stdout TESTS=on: Run compile-time tests (req. python) UNRAR=on: RAR decompression support UNZOO=on: Enable zoo archives support
Hi, I have this issue too. I think i know where the problem is : it occurs when libmspack (port or package) is installed on the system.
Perfect!!! pkg delete libmspack and now work fine.
In my case this not a solution, libmspack is a dependency for open-vm-tools-nox11 and I need those.
Created attachment 199674 [details] clamav fix This patch should fix the issue. I have tested it on my own system (11.2-RELEASE-p5) and on poudriere (11.2-RELEASE-p5 i386/amd64). Portlint test passed successfully. It adds a few more fixes and improvements. - Solves the bug, by adding a MSPACK option (enabled by default) and a build dependency on pkg-config. - Makes massive use of options helpers and similar tools to improve Makefile's readability. In the rewriting I have not maintained the dependency of option LDAP on option MILTER and the two options are now indipendent: if this is bad, it as to be fixed on my patch. I avoided to do it directly because I am unsure it is needed. - Uses now libpcre2 consistently (before the port could link to libpcre2 by mistake). - Removes useless arguments about zlib in CONFIGURE_ARGS. - Reorders variables consistently with the standard order. - Cleans header. - Updates pkg-plist and sort if alphabetically. - Bump PORTREVISION, needed because of some fixes.
I made one more test: building the port with LDAP option set and MILTER unset and I verified that some binary file indeed links to libldap.so. Thus, I think I did well by making the two options independent.
Thanks, Lorenzo. I'll look at this shortly.
A commit references this bug: Author: ler Date: Fri Nov 30 02:34:21 UTC 2018 New revision: 486224 URL: https://svnweb.freebsd.org/changeset/ports/486224 Log: security/clamav: fix test failures. It adds a few more fixes and improvements. - Solves the bug, by adding a MSPACK option (enabled by default) and a build dependency on pkg-config. - Makes massive use of options helpers and similar tools to improve Makefile's readability. In the rewriting I have not maintained the dependency of option LDAP on option MILTER and the two options are now indipendent: if this is bad, it as to be fixed on my patch. I avoided to do it directly because I am unsure it is needed. - Uses now libpcre2 consistently (before the port could link to libpcre2 by mistake). - Removes useless arguments about zlib in CONFIGURE_ARGS. - Reorders variables consistently with the standard order. - Cleans header. - Updates pkg-plist and sort if alphabetically. - Bump PORTREVISION, needed because of some fixes. PR: 228468 Submitted by: phascolarctos@protonmail.ch Reported by: gondim@bsdinfo.com.br Changes: head/security/clamav/Makefile head/security/clamav/pkg-plist
Committed Thanks!