Update yara to the latest stable version 4.2.2. I'm not a yara user
so tests and send feedback as well OKs welcome.
Rafael
Index: Makefile
===================================================================
RCS file: /cvs/ports/security/yara/Makefile,v
retrieving revision 1.3
diff -u -p -r1.3 Makefile
--- Makefile 11 Mar 2022 19:54:09 -0000 1.3
+++ Makefile 5 Jul 2022 06:55:59 -0000
@@ -1,4 +1,4 @@
-SUBDIR =
+SUBDIR =
SUBDIR += main
SUBDIR += python
SUBDIR += python,python3
Index: Makefile.inc
===================================================================
RCS file: /cvs/ports/security/yara/Makefile.inc,v
retrieving revision 1.15
diff -u -p -r1.15 Makefile.inc
--- Makefile.inc 11 Mar 2022 19:54:10 -0000 1.15
+++ Makefile.inc 5 Jul 2022 06:55:59 -0000
@@ -1,13 +1,13 @@
-VERSION ?= 3.11.0
+VERSION ?= 4.2.2
CATEGORIES = security
-HOMEPAGE = http://virustotal.github.io/yara/
+HOMEPAGE = https://virustotal.github.io/yara/
-GH_ACCOUNT = VirusTotal
-GH_TAGNAME = v${VERSION}
+GH_ACCOUNT = VirusTotal
+GH_TAGNAME ?= v${VERSION}
# Apache v2
PERMIT_PACKAGE = Yes
-MAINTAINER ?= Remi Pointel <rpointel@openbsd.org>
+MAINTAINER ?= Remi Pointel <rpointel@openbsd.org>
Index: main/Makefile
===================================================================
RCS file: /cvs/ports/security/yara/main/Makefile,v
retrieving revision 1.7
diff -u -p -r1.7 Makefile
--- main/Makefile 11 Mar 2022 19:54:10 -0000 1.7
+++ main/Makefile 5 Jul 2022 06:55:59 -0000
@@ -1,24 +1,25 @@
COMMENT = pattern matching swiss knife
DISTNAME = yara-${VERSION}
-REVISION = 0
GH_PROJECT = yara
-WANTLIB += c crypto m magic pthread z
+WANTLIB += c crypto jansson m magic pthread z
-SHARED_LIBS += yara 0.0 # 0.0
+SHARED_LIBS += yara 1.0 # 0.0
-CONFIGURE_STYLE = autoreconf
-CONFIGURE_ARGS += --with-crypto \
- --enable-magic
+CONFIGURE_STYLE = autoreconf
+CONFIGURE_ARGS += --enable-cuckoo \
+ --enable-magic \
+ --with-crypto
CONFIGURE_ENV += LDFLAGS="-L${LOCALBASE}/lib" \
CFLAGS="-I${LOCALBASE}/include"
-LIB_DEPENDS += devel/libmagic
+LIB_DEPENDS += devel/libmagic \
+ devel/jansson
-AUTOCONF_VERSION = 2.69
-AUTOMAKE_VERSION = 1.14
+AUTOCONF_VERSION = 2.69
+AUTOMAKE_VERSION = 1.14
AUTORECONF = ./bootstrap.sh
.include <bsd.port.mk>
Index: main/distinfo
===================================================================
RCS file: /cvs/ports/security/yara/main/distinfo,v
retrieving revision 1.13
diff -u -p -r1.13 distinfo
--- main/distinfo 11 Nov 2019 20:34:33 -0000 1.13
+++ main/distinfo 5 Jul 2022 06:55:59 -0000
@@ -1,2 +1,2 @@
-SHA256 (yara-3.11.0.tar.gz) = 3oxUAoyEh1HAb1rMO3ScPvaxEQkLOfb/mRKVr0S9RjM=
-SIZE (yara-3.11.0.tar.gz) = 772122
+SHA256 (yara-4.2.2.tar.gz) = IL1WhXxLA3xLqucVh7fSLQt7uwdaevpRa6NdrlD63SU=
+SIZE (yara-4.2.2.tar.gz) = 1287486
Index: main/patches/patch-Makefile_am
===================================================================
RCS file: main/patches/patch-Makefile_am
diff -N main/patches/patch-Makefile_am
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ main/patches/patch-Makefile_am 5 Jul 2022 06:55:59 -0000
@@ -0,0 +1,12 @@
+Index: Makefile.am
+--- Makefile.am.orig
++++ Makefile.am
+@@ -15,7 +15,7 @@ AM_CFLAGS+=-g
+ endif
+
+ if OPTIMIZATION
+-AM_CFLAGS+=-O3
++#AM_CFLAGS+=-O3
+ else
+ AM_CFLAGS+=-O0
+ endif
Index: main/patches/patch-libyara_Makefile_am
===================================================================
RCS file: main/patches/patch-libyara_Makefile_am
diff -N main/patches/patch-libyara_Makefile_am
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ main/patches/patch-libyara_Makefile_am 5 Jul 2022 06:55:59 -0000
@@ -0,0 +1,12 @@
+Index: libyara/Makefile.am
+--- libyara/Makefile.am.orig
++++ libyara/Makefile.am
+@@ -107,7 +107,7 @@ AM_CFLAGS+=-g
+ endif
+
+ if OPTIMIZATION
+-AM_CFLAGS+=-O3
++#AM_CFLAGS+=-O3
+ else
+ AM_CFLAGS+=-O0
+ endif
Index: main/patches/patch-libyara_modules_pe_c
===================================================================
RCS file: main/patches/patch-libyara_modules_pe_c
diff -N main/patches/patch-libyara_modules_pe_c
--- main/patches/patch-libyara_modules_pe_c 11 Mar 2022 19:54:10 -0000 1.4
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,12 +0,0 @@
-Index: libyara/modules/pe.c
---- libyara/modules/pe.c.orig
-+++ libyara/modules/pe.c
-@@ -38,7 +38,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH D
- #include <openssl/bio.h>
- #include <openssl/pkcs7.h>
- #include <openssl/x509.h>
--#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
-+#if OPENSSL_VERSION_NUMBER < 0x10100000L
- #define X509_get_signature_nid(o) OBJ_obj2nid((o)->sig_alg->algorithm)
- #define X509_getm_notBefore X509_get_notBefore
- #define X509_getm_notAfter X509_get_notAfter
Index: main/pkg/PLIST
===================================================================
RCS file: /cvs/ports/security/yara/main/pkg/PLIST,v
retrieving revision 1.6
diff -u -p -r1.6 PLIST
--- main/pkg/PLIST 11 Mar 2022 19:54:10 -0000 1.6
+++ main/pkg/PLIST 5 Jul 2022 06:55:59 -0000
@@ -5,6 +5,7 @@ include/yara.h
include/yara/ahocorasick.h
include/yara/arena.h
include/yara/atoms.h
+include/yara/base64.h
include/yara/bitmask.h
include/yara/compiler.h
include/yara/error.h
@@ -17,6 +18,7 @@ include/yara/libyara.h
include/yara/limits.h
include/yara/mem.h
include/yara/modules.h
+include/yara/notebook.h
include/yara/object.h
include/yara/parser.h
include/yara/proc.h
@@ -32,7 +34,7 @@ include/yara/strutils.h
include/yara/threading.h
include/yara/types.h
include/yara/utils.h
-lib/libyara.a
+@static-lib lib/libyara.a
lib/libyara.la
@lib lib/libyara.so.${LIByara_VERSION}
lib/pkgconfig/yara.pc
Index: python/Makefile
===================================================================
RCS file: /cvs/ports/security/yara/python/Makefile,v
retrieving revision 1.13
diff -u -p -r1.13 Makefile
--- python/Makefile 11 Mar 2022 19:54:10 -0000 1.13
+++ python/Makefile 5 Jul 2022 06:55:59 -0000
@@ -2,9 +2,9 @@ COMMENT = Python extension that gives ac
GH_PROJECT = yara-python
-MODPY_EGG_VERSION = ${VERSION}
-PKGNAME = py-yara-${VERSION}
-REVISION =3
+MODPY_EGG_VERSION = 4.2.0
+PKGNAME = py-yara-${MODPY_EGG_VERSION}
+GH_TAGNAME = v${MODPY_EGG_VERSION}
WANTLIB += pthread ${MODPY_WANTLIB} yara
@@ -18,12 +18,12 @@ MODPY_DISTUTILS_BUILDARGS = --dynamic-li
MAKE_FLAG += CPPFLAGS="-I${LOCALBASE}/include/yara/"
pre-configure:
- ${SUBST_CMD} ${WRKSRC}/setup.py
+ ${SUBST_CMD} ${WRKSRC}/setup.py
BUILD_DEPENDS = security/yara/main>=${VERSION}
-RUN_DEPENDS = security/yara/main>=${VERSION}
+RUN_DEPENDS = security/yara/main>=${VERSION}
-TEST_DEPENDS = security/yara/python${MODPY_FLAVOR}=${VERSION}
+TEST_DEPENDS = security/yara/python${MODPY_FLAVOR}=${MODPY_EGG_VERSION}
do-test:
cd ${WRKSRC} && ${MODPY_BIN} ./tests.py
Index: python/distinfo
===================================================================
RCS file: /cvs/ports/security/yara/python/distinfo,v
retrieving revision 1.12
diff -u -p -r1.12 distinfo
--- python/distinfo 11 Nov 2019 20:34:33 -0000 1.12
+++ python/distinfo 5 Jul 2022 06:55:59 -0000
@@ -1,2 +1,2 @@
-SHA256 (yara-python-3.11.0.tar.gz) = EoDPpIRJAunVhIyE7Mh9o/wF+6y9dDcbtzjR9Pu6KFA=
-SIZE (yara-python-3.11.0.tar.gz) = 31830
+SHA256 (yara-python-4.2.0.tar.gz) = 6y331LSyYxqfoJt/5+Qe6hmgPS9yBO/xCnNB+KRD9VA=
+SIZE (yara-python-4.2.0.tar.gz) = 34459
Index: python/patches/patch-setup_py
===================================================================
RCS file: /cvs/ports/security/yara/python/patches/patch-setup_py,v
retrieving revision 1.2
diff -u -p -r1.2 patch-setup_py
--- python/patches/patch-setup_py 11 Mar 2022 19:54:10 -0000 1.2
+++ python/patches/patch-setup_py 5 Jul 2022 06:55:59 -0000
@@ -1,8 +1,9 @@
---- setup.py.orig Thu Aug 11 14:22:08 2016
-+++ setup.py Thu Aug 11 14:31:24 2016
-@@ -122,6 +122,10 @@ class BuildCommand(build):
- else:
- building_for_osx = False
+Index: setup.py
+--- setup.py.orig
++++ setup.py
+@@ -245,6 +245,10 @@ class BuildExtCommand(build_ext):
+ if has_header('stdbool.h'):
+ module.define_macros.append(('HAVE_STDBOOL_H', '1'))
+ if 'openbsd' in self.plat_name:
+ module.include_dirs.append('${LOCALBASE}/include')
No comments:
Post a Comment