# $OpenBSD: Makefile,v 1.84 2019/09/08 23:04:22 Stephane Guedon 22Decembre $

COMMENT =	fast image processing library with low memory needs

VERSION = 8.8.2
DISTNAME =	vips-${VERSION}

SHARED_LIBS +=  vips                 53.1     # 53.1
SHARED_LIBS +=  vips-cpp             53.1     # 53.1

# the category used in the directory name, /usr/ports/<category>/portname,
# must be included and listed first.
CATEGORIES =	multimedia

HOMEPAGE = https://libvips.github.io/libvips/

# person who is responsible for the port. Use a complete email address with
# a real name, e.g., "MAINTAINER = John Doe <doe57@machine.somewhere.org>".
# If you maintain several ports, use the same line each time.
# If you no longer use the port, or are unwilling/unable to handle issues
# in a timely manner, *leave the field blank*.
# Default value is ports@openbsd.org, no need to fill in
#MAINTAINER =		???

# Licence
# LGPLv2+
PERMIT_PACKAGE =	Yes

# "make port-lib-depends-check" can help
WANTLIB = ${COMPILER_LIBCXX} c expat fontconfig freetype m z
WANTLIB += ffi glib-2.0 gmodule-2.0 gobject-2.0 gthread-2.0 iconv
WANTLIB += intl pcre

# where the source files and patches can be fetched
#
MASTER_SITES =		https://github.com/libvips/libvips/releases/download/v${VERSION}/

#EXTRACT_SUFX =		.tar.gz
#DISTFILES =		vips-${VERSION}

# Dependencies
#BUILD_DEPENDS =	???
RUN_DEPENDS =		devel/glib2
#LIB_DEPENDS =		???
#TEST_DEPENDS =		???

#MAKE_FLAGS =		???
#MAKE_ENV =		???
#FAKE_FLAGS =		???
#TEST_FLAGS =		???

SEPARATE_BUILD =	Yes  #

USE_GMAKE =		Yes

#USE_GROFF =		Yes

# Programs that require GNU libtool to build instead of the OpenBSD one
# should use this option. Add a comment explaining why. Don't use this if
# a port requires libtool's .m4 files but otherwise can use OpenBSD libtool,
# in that case use "BUILD_DEPENDS=devel/libtool" instead.

#USE_LIBTOOL=		gnu

# Set CONFIGURE_STYLE to value corresponding to some standard configuration
#	  perl [modbuild]: perl's MakeMaker Makefile.PL (modbuild: perl's
#	  Module::Build Build.PL)
#	  gnu [autoconf] [old] [dest]: gnu style configure (old: no
#	  sysconfdir), (dest: add DESTDIR, does not handle it),
#	  autoconf: run autoconf to regenerate configure script. implies gnu.
#	            (see also "do-gen" target below).
#	XXX: cygnus products do NOT use autoconf for making the main
#		configure from configure.in
#	  imake [noman]: port uses imake for configuration.
#	  (noman: no man page installation)
#	  simple: port has its own configure script
#	  none: override default CONFIGURE_STYLE coming from a module
#	        (needed for some ports using lang/python, etc.)

CONFIGURE_STYLE =	gnu

#CONFIGURE_ARGS =	"--disable-dependency-tracking"

# for gnu stuff
#AUTOCONF_VERSION =	??? (defaults to 2.13)
#AUTOMAKE_VERSION =	??? (defaults to 1.4)
# config.guess and others are copied here
#MODGNU_CONFIG_GUESS_DIRS = ??? (defaults to ${WRKSRC})

# Is the build automagic or is it interactive
#
#IS_INTERACTIVE =		Yes
#TEST_IS_INTERACTIVE =		Yes

# Assume you have one multiple choice flavor: 1 2 3 and switches a b.
# You would write
#
#FLAVORS =	1 2 3 a b
#FLAVOR ?=
# grab multiple choice value
#CHOICE = ${FLAVOR:Na:Nb}
# check that CHOICE is 1 OR 2 OR 3, or error out
#.if ${CHOICE} == "1"
# code for 1
#.elif ${CHOICE} == "2"
# code for 2
#.elif ${CHOICE} == "3"
# code for 3
#.else
#ERRORS += "Fatal: Conflicting flavor: ${FLAVOR}"
#.endif
# check for switches
#.if ${FLAVOR:Ma}
# code for a
#.endif
#.if ${FLAVOR:Mb}
# code for b
#.endif

# Things that we don't want to do for this port/package
# Generally, DON'T set anything to No if it's not needed.
# The time gained is not worth it.
#
#NO_BUILD =		Yes
#NO_TEST =		Yes

# Overrides for default values
#
#CFLAGS =		???
#LDFLAGS =		???
#MAKE_FILE =		???
#PKG_ARCH =		??? (* for arch-independent packages)
#WRKDIST =		??? if other than ${WRKDIR}/${DISTNAME}
#WRKSRC =		??? if other than ${WRKDIST}
#WRKBUILD =		??? if other than ${WRKSRC}
#WRKCONF =		??? if other than ${WRKBUILD}

#ALL_TARGET =		???
#INSTALL_TARGET =	???
#TEST_TARGET =		???

# For ports that use a script or autoreconf to generate autoconf/automake
# files (where "CONFIGURE_STYLE=autoconf" isn't enough), use some/all of these
# dependencies, and add a do-gen target:
# 
#BUILD_DEPENDS =	${MODGNU_AUTOCONF_DEPENDS} \
#			${MODGNU_AUTOMAKE_DEPENDS} \
#			devel/libtool
#
#do-gen:
#	cd ${WRKSRC}; ${AUTOCONF_ENV} ./autogen.sh

.include <bsd.port.mk>
