1#	$NetBSD: Makefile,v 1.6 2012/07/30 10:25:24 christos Exp $
2
3.include "bsd.own.mk"
4
5CRYPTODIST=${NETBSDSRCDIR}/crypto
6.include "${NETBSDSRCDIR}/crypto/Makefile.openssl"
7
8regen:
9	for i in $$(find ${OPENSSLSRC} -name \*86.pl) \
10		  ${OPENSSLSRC}/crypto/x86cpuid.pl; do \
11		perl -I${OPENSSLSRC}/crypto/perlasm \
12		-I${OPENSSLSRC}/crypto/bn/asm $$i elf -fPIC \
13		| sed -e 's,^\.file.*$$,#include <machine/asm.h>,' \
14			-e 's/	call	OPENSSL_cpuid_setup/	PIC_PROLOGUE!	call	PIC_PLT(OPENSSL_cpuid_setup)!	PIC_EPILOGUE/' | tr '!' '\n' \
15		> $$(basename $$i .pl).S; \
16	done
17