pkgsrc/textproc/tokyodystopia/Makefile
obache 3b22e3b7cf Introduce PKG_OPTIONS for database/tokyocabinet to select compression support
(zlib/bzip2/lzo/lzma and enabled by default for former two).

LZO and LZMA supports are exclusive, optional and should be selected by
user's use-case (priority of data compression ratio, compression speed,
or so on).

Furthermore, Tokyocabinet uses archives/lzmalib for lzma support, but lzmalib
conflicts with archivers/xz.
It means if tokyocabinet is installed with lzma, failed to install xz,
and result in failure of "make extract" for packages using .lzma/.xz distfiles.
This issue also resolved by optionify lzma support and disabled by default.

This changes also make tokyocabinet ABI changes, so bump PKGREVISION
and recursive bump.

OKed to commit in freeze by wiz@.
2009-12-19 12:56:45 +00:00

44 lines
1.2 KiB
Makefile

# $NetBSD: Makefile,v 1.13 2009/12/19 12:56:45 obache Exp $
#
DISTNAME= tokyodystopia-0.9.13
PKGREVISION= 1
CATEGORIES= textproc
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=tokyocabinet/}
MAINTAINER= obache@NetBSD.org
HOMEPAGE= http://1978th.net/tokyodystopia/
COMMENT= Full-text search system
LICENSE= gnu-lgpl-v2.1
PKG_DESTDIR_SUPPORT= user-destdir
GNU_CONFIGURE= yes
USE_TOOLS+= gmake pkg-config
PKGCONFIG_OVERRIDE+= tokyodystopia.pc.in
TEST_TARGET= check
BUILDLINK_API_DEPENDS.tokyocabinet+= tokyocabinet>=1.4.29
.include "../../databases/tokyocabinet/buildlink3.mk"
.if !empty(PKG_BUILD_OPTIONS.tokyocabinet:Mbzip2)
CONFIGURE_ARGS+= --enable-bzip
CONFIGURE_ARGS+= --with-bzip=${BUILDLINK_PREFIX.bzip2}
.else
CONFIGURE_ARGS+= --disable-bzip
.endif
.if !empty(PKG_BUILD_OPTIONS.tokyocabinet:Mzlib)
CONFIGURE_ARGS+= --enable-zlib
CONFIGURE_ARGS+= --with-zlib=${BUILDLINK_PREFIX.zlib}
.else
CONFIGURE_ARGS+= --disable-zlib
.endif
.include "../../mk/pthread.buildlink3.mk"
PTHREAD_AUTO_VARS= yes
CONFIGURE_ARGS+= --enable-pthread
SUBST_CLASSES+= pthread
SUBST_STAGE.pthread= pre-configure
SUBST_FILES.pthread= configure
SUBST_SED.pthread= -e 's|-lpthread|${PTHREAD_LIBS}|'
.include "../../mk/bsd.pkg.mk"