[BACK]Return to Makefile CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / security / botan2

File: [cvs.NetBSD.org] / pkgsrc / security / botan2 / Makefile (download)

Revision 1.4, Wed Nov 9 13:14:16 2022 UTC (2 months, 4 weeks ago) by joerg
Branch: MAIN
Changes since 1.3: +2 -2 lines

Reset MAINTAINER

# $NetBSD: Makefile,v 1.4 2022/11/09 13:14:16 joerg Exp $

DISTNAME=	Botan-2.19.2
PKGNAME=	${DISTNAME:tl}
CATEGORIES=	security
MASTER_SITES=	https://botan.randombit.net/releases/
EXTRACT_SUFX=	.tar.xz

MAINTAINER=	pkgsrc-users@NetBSD.org
HOMEPAGE=	https://botan.randombit.net/
COMMENT=	Portable, easy to use, and efficient C++ crypto library (v2)
LICENSE=	2-clause-bsd

HAS_CONFIGURE=		yes
USE_LANGUAGES=		c++

PYTHON_FOR_BUILD_ONLY=	yes

CONFIG_SHELL=		${PYTHONBIN}
CONFIGURE_SCRIPT=	./configure.py
CONFIGURE_ARGS+=	--prefix=${PREFIX} --with-zlib --with-boost
CONFIGURE_ARGS+=	--docdir=share/doc
CONFIGURE_ARGS+=	--without-sphinx

REPLACE_PYTHON+=	*.py src/scripts/*.py

.include "../../mk/compiler.mk"
.if !empty(PKGSRC_COMPILER:Mclang)
CONFIGURE_ARGS+=	--cc-bin=${CXX:Q} --cc=clang
.else
CONFIGURE_ARGS+=	--cc=gcc
.endif

PLIST_VARS+=		x86
.if ${MACHINE_ARCH} == "x86_64"
PLIST.x86=		yes
CONFIGURE_ARGS+=	--cpu=amd64
.elif ${MACHINE_ARCH} == "i386"
PLIST.x86=		yes
CONFIGURE_ARGS+=	--cpu=i386
.elif ${MACHINE_ARCH} == "powerpc"
CONFIGURE_ARGS+=	--cpu=ppc
.elif ${MACHINE_ARCH} == "powerpc64"
CONFIGURE_ARGS+=	--cpu=ppc64
.elif !empty(MACHINE_ARCH:Maarch64*)
CONFIGURE_ARGS+=	--cpu=arm64
.elif !empty(MACHINE_ARCH:Mearm*)
CONFIGURE_ARGS+=	--cpu=arm32
.endif

MAKE_FLAGS+=	LIB_OPT=${CXXFLAGS:Q}

USE_TOOLS+=	gmake

PY_PATCHPLIST=	yes

LDFLAGS.SunOS+=	-lnsl -lsocket

TEST_TARGET=	tests

post-test:
	cd ${WRKSRC} && ./botan-test

.include "../../devel/zlib/buildlink3.mk"
.include "../../devel/boost-libs/buildlink3.mk"
.include "../../lang/python/application.mk"
.include "../../lang/python/extension.mk"
.include "../../mk/bsd.pkg.mk"