aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArmin Kuster <akuster808@gmail.com>2019-04-13 10:29:39 -0700
committerArmin Kuster <akuster808@gmail.com>2019-04-14 10:54:20 -0700
commit5959e4f4bf6120edf82c71e6c7a0b6118f275419 (patch)
tree4176dad6cc87e6d4885215a6fa20683903468c65
parentab3c84c4d34cb07a3a2bfa0893dc3bd0103190a9 (diff)
downloadmeta-security-5959e4f4bf6120edf82c71e6c7a0b6118f275419.tar.gz
meta-security-5959e4f4bf6120edf82c71e6c7a0b6118f275419.tar.bz2
meta-security-5959e4f4bf6120edf82c71e6c7a0b6118f275419.zip
clamav-native: fix new build issue
re-arch the reciped to build properly. Fixed /var/lib/clamav dir issue Signed-off-by: Armin Kuster <akuster808@gmail.com>
-rw-r--r--recipes-security/clamav/clamav_0.99.4.bb41
1 files changed, 19 insertions, 22 deletions
diff --git a/recipes-security/clamav/clamav_0.99.4.bb b/recipes-security/clamav/clamav_0.99.4.bb
index 32dc59c..7d8767e 100644
--- a/recipes-security/clamav/clamav_0.99.4.bb
+++ b/recipes-security/clamav/clamav_0.99.4.bb
@@ -4,8 +4,8 @@ HOMEPAGE = "http://www.clamav.net/index.html"
SECTION = "security"
LICENSE = "LGPL-2.1"
-DEPENDS = "libtool db libmspack chrpath-replacement-native clamav-native"
-DEPENDS_class-native = "db-native"
+DEPENDS = "libtool db libmspack openssl zlib llvm chrpath-replacement-native clamav-native"
+DEPENDS_class-native = "db-native openssl-native zlib-native"
LIC_FILES_CHKSUM = "file://COPYING.LGPL;beginline=2;endline=3;md5=4b89c05acc71195e9a06edfa2fa7d092"
@@ -36,39 +36,35 @@ INSTALL_CLAMAV_CVD ?= "1"
# disable the internal one. This is a known issue
# If you want LLVM support, use the one in core
-PACKAGECONFIG ?= "ncurses openssl bz2 zlib llvm"
-PACKAGECONFIG += " ${@bb.utils.contains("DISTRO_FEATURES", "ipv6", "ipv6", "", d)}"
-PACKAGECONFIG += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)}"
+CLAMAV_USR_DIR = "${STAGING_DIR_NATIVE}/usr"
+CLAMAV_USR_DIR_class-target = "${STAGING_DIR_HOST}/usr"
-PACKAGECONFIG[llvm] = "--with-system-llvm --with-llvm-linking=dynamic --disable-llvm, ,llvm"
+PACKAGECONFIG_class-target ?= "ncurses bz2"
+PACKAGECONFIG_class-target += " ${@bb.utils.contains("DISTRO_FEATURES", "ipv6", "ipv6", "", d)}"
+PACKAGECONFIG_class-target += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd', '', d)}"
PACKAGECONFIG[pcre] = "--with-pcre=${STAGING_LIBDIR}, --without-pcre, libpcre"
-PACKAGECONFIG[xml] = "--with-xml=${STAGING_LIBDIR}/.., --with-xml=no, libxml2,"
+PACKAGECONFIG[xml] = "--with-xml=${CLAMAV_USR_DIR}, --disable-xml, libxml2,"
PACKAGECONFIG[json] = "--with-libjson=${STAGING_LIBDIR}, --without-libjson, json,"
PACKAGECONFIG[curl] = "--with-libcurl=${STAGING_LIBDIR}, --without-libcurl, curl,"
PACKAGECONFIG[ipv6] = "--enable-ipv6, --disable-ipv6"
-PACKAGECONFIG[openssl] = "--with-openssl=${STAGING_DIR_HOST}/usr, --without-openssl, openssl, openssl"
-PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_DIR_HOST}/usr --disable-zlib-vcheck , --without-zlib, zlib, "
-PACKAGECONFIG[bz2] = "--with-libbz2-prefix=${STAGING_LIBDIR}/.., --without-libbz2-prefix, "
-PACKAGECONFIG[ncurses] = "--with-libncurses-prefix=${STAGING_LIBDIR}/.., --without-libncurses-prefix, ncurses, "
+PACKAGECONFIG[bz2] = "--with-libbz2-prefix=${CLAMAV_USR_DIR}, --without-libbz2-prefix, "
+PACKAGECONFIG[ncurses] = "--with-libncurses-prefix=${CLAMAV_USR_DIR}, --without-libncurses-prefix, ncurses, "
PACKAGECONFIG[systemd] = "--with-systemdsystemunitdir=${systemd_unitdir}/system/, --without-systemdsystemunitdir, "
-EXTRA_OECONF += " --with-user=${UID} --with-group=${GID} \
- --without-libcheck-prefix --disable-unrar \
- --disable-mempool \
- --program-prefix="" \
- --disable-yara \
- --disable-rpath \
- "
-
-EXTRA_OECONF_class-native += "--without-libcheck-prefix --disable-unrar \
+EXTRA_OECONF_CLAMAV = "--without-libcheck-prefix --disable-unrar \
--with-system-llvm --with-llvm-linking=dynamic --disable-llvm \
--disable-mempool \
--program-prefix="" \
--disable-yara \
- --without-libbz2-prefix --without-zlib \
+ --disable-xml \
+ --with-openssl=${CLAMAV_USR_DIR} \
+ --with-zlib=${CLAMAV_USR_DIR} --disable-zlib-vcheck \
"
+EXTRA_OECONF_class-native += "${EXTRA_OECONF_CLAMAV}"
+EXTRA_OECONF_class-target += "--with-user=${UID} --with-group=${GID} --disable-rpath ${EXTRA_OECONF_CLAMAV}"
+
do_configure () {
cd ${S}
./configure ${CONFIGUREOPTS} ${EXTRA_OECONF}
@@ -117,6 +113,7 @@ pkg_postinst_ontarget_${PN} () {
if [ -e /etc/init.d/populate-volatile.sh ] ; then
${sysconfdir}/init.d/populate-volatile.sh update
fi
+ mkdir -p ${localstatedir}/lib/clamav
chown -R ${UID}:${GID} ${localstatedir}/lib/clamav
}
@@ -177,7 +174,7 @@ RREPLACES_${PN} += "${PN}-systemd"
RCONFLICTS_${PN} += "${PN}-systemd"
SYSTEMD_SERVICE_${PN} = "${BPN}.service"
-RDEPENDS_${PN} += "openssl ncurses-libncurses libbz2 ncurses-libtinfo clamav-freshclam clamav-libclamav"
+RDEPENDS_${PN} = "openssl ncurses-libncurses libbz2 ncurses-libtinfo clamav-freshclam clamav-libclamav"
RDEPENDS_${PN}_class-native = ""
BBCLASSEXTEND = "native"