# $OpenBSD: Makefile.template,v 1.78 2018/07/09 15:00:06 jca Exp $

COMMENT = Programmers calculator, command line utility.
GH_ACCOUNT = vapier
GH_PROJECT = pcalc
GH_TAGNAME = v4
CATEGORIES = math
MAINTAINER = Charles Daniels <charles@cdaniels.net>

# GPLv2+
PERMIT_PACKAGE_CDROM = Yes

WANTLIB = c m

BUILD_DEPENDS = devel/bison
TEST_DEPENDS = devel/autoconf/2.69

# Part of the test suite fails under macppc, issue has been reported upstream:
# https://github.com/vapier/pcalc/issues/7
NOT_FOR_ARCHES = macppc

MAKE_FLAGS = BINDIR=${LOCALBASE}/bin/
FAKE_FLAGS = BINDIR=${LOCALBASE}/bin/
TEST_FLAGS = BINDIR=${LOCALBASE}/bin/

AUTOCONF_VERSION=2.69

TEST_ENV = AUTOCONF_VERSION=${AUTOCONF_VERSION}

USE_GMAKE = Yes

# Note: two test targets are currently disabled as a workaround for this issue:
# https://github.com/vapier/pcalc/issues/6
#
# This is known and documented by the upstream, and the suggested workaround is
# to ignore these specific test (https://github.com/vapier/pcalc#testing)
TEST_TARGET = check test

.include <bsd.port.mk>
