Index: Makefile =================================================================== RCS file: /home/pcvs/ports/security/clamav/Makefile,v retrieving revision 1.160 diff -u -r1.160 Makefile --- Makefile 21 Feb 2011 11:35:52 -0000 1.160 +++ Makefile 22 Feb 2011 17:57:59 -0000 @@ -18,7 +18,8 @@ LHA "Enable lha archives support" On \ UNZOO "Enable zoo archives support" On \ UNRAR "Enable rar archives support" On \ - LLVM "Enable JIT Bytecode compiler" On \ + LLVM "Enable JIT Bytecode compiler (bundled LLVM)" Off \ + LLVM_PORTS "Enable JIT Bytecode compiler (from Ports)" On \ TESTS "Run compile-time tests (req. python)" On \ MILTER "Compile the milter interface" Off \ LDAP "libmilter was built with LDAP" Off \ @@ -139,9 +140,16 @@ CONFIGURE_ARGS+=--without-iconv .endif -.if defined(WITH_LLVM) && ( ${ARCH} == "i386" || ${ARCH} == "amd64" ) +.if (defined(WITH_LLVM) || defined(WITH_LLVM_PORTS)) && ( ${ARCH} == "i386" || ${ARCH} == "amd64" ) CONFIGURE_ARGS+=--enable-llvm USE_GMAKE= yes +. if defined(WITH_LLVM_PORTS) +BUILD_DEPENDS+= llvm-config:${PORTSDIR}/devel/llvm +CONFIGURE_ARGS+=--with-system-llvm=${LOCALBASE}/bin/llvm-config +. endif +. if defined(WITH_LLVM) && defined(WITH_LLVM_PORTS) +IGNORE=Select only one LLVM +. endif . if defined(WITH_TESTS) USE_PYTHON_BUILD= yes . endif @@ -203,7 +211,7 @@ @${REINPLACE_CMD} -e 's|0x100000000|0x100000000ULL|g' \ ${WRKSRC}/libclamunrar/unrar.c -.if defined(WITH_LLVM) && defined(WITH_TESTS) +.if (defined(WITH_LLVM) || defined(WITH_LLVM_PORTS)) && defined(WITH_TESTS) pre-configure: @if ! ${PYTHON_CMD} -c "import thread" >/dev/null 2>&1; then \ ${ECHO_MSG} ""; \