-# $OpenBSD: Makefile,v 1.12 2021/12/24 08:31:55 jsing Exp $
+# $OpenBSD: Makefile,v 1.13 2022/01/12 07:55:25 tb Exp $
-TESTS = \
+PROGS = \
asn1api \
asn1basic \
asn1complex \
rfc5280time \
string_table
-PROGS = ${TESTS}
-
-REGRESS_TARGETS= all_tests
-
-LDADD= -lcrypto
-DPADD= ${LIBCRYPTO} ${LIBSSL}
+DPADD+= ${LIBCRYPTO} ${LIBSSL}
WARNINGS= Yes
LDFLAGS+= -lcrypto
CFLAGS+= -DLIBRESSL_INTERNAL -Wall -Wundef -Werror
+CFLAGS+= -I${.CURDIR}/../../../../lib/libcrypto/asn1
+CFLAGS+= -I${.CURDIR}/../../../../lib/libcrypto/bytestring
+
+LDADD_asn1basic = ${CRYPTO_INT}
+
+.for p in ${PROGS}
+REGRESS_TARGETS += run-$p
-all_tests: ${TESTS}
- @for test in $>; do \
- echo "\n======== $$test ========"; \
- ./$$test; \
- done
+run-$p: $p
+ @./$p
+.endfor
.include <bsd.regress.mk>
-/* $OpenBSD: asn1basic.c,v 1.3 2022/01/06 15:21:33 jsing Exp $ */
+/* $OpenBSD: asn1basic.c,v 1.4 2022/01/12 07:55:25 tb Exp $ */
/*
* Copyright (c) 2017, 2021 Joel Sing <jsing@openbsd.org>
*
#include <stdio.h>
#include <string.h>
+#include "asn1_locl.h"
+
static void
hexdump(const unsigned char *buf, size_t len)
{