summaryrefslogtreecommitdiff
path: root/dev-cpp/pficommon/pficommon-1.3.1.0.ebuild
diff options
context:
space:
mode:
Diffstat (limited to 'dev-cpp/pficommon/pficommon-1.3.1.0.ebuild')
-rw-r--r--dev-cpp/pficommon/pficommon-1.3.1.0.ebuild58
1 files changed, 58 insertions, 0 deletions
diff --git a/dev-cpp/pficommon/pficommon-1.3.1.0.ebuild b/dev-cpp/pficommon/pficommon-1.3.1.0.ebuild
new file mode 100644
index 000000000000..db9afe674b6f
--- /dev/null
+++ b/dev-cpp/pficommon/pficommon-1.3.1.0.ebuild
@@ -0,0 +1,58 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=4
+
+PYTHON_COMPAT=( python2_7 )
+PYTHON_REQ_USE='threads(+)'
+inherit python-any-r1 waf-utils eutils
+
+DESCRIPTION="General purpose C++ library for PFI"
+HOMEPAGE="https://github.com/pfi/pficommon"
+SRC_URI="https://github.com/pfi/pficommon/tarball/${PV} -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="fcgi imagemagick mprpc mysql postgres test"
+
+RDEPEND="fcgi? ( dev-libs/fcgi )
+ imagemagick? (
+ media-libs/lcms
+ media-gfx/imagemagick[cxx]
+ sys-devel/libtool
+ )
+ mprpc? ( dev-libs/msgpack )
+ mysql? ( virtual/mysql )
+ postgres? ( dev-db/postgresql )
+ "
+DEPEND="${RDEPEND}
+ ${PYTHON_DEPS}
+ test? ( dev-cpp/gtest )"
+
+src_unpack() {
+ unpack ${A}
+ mv pfi-pficommon-* "${S}"
+}
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-libdir.patch \
+ "${FILESDIR}"/${P}-soname.patch \
+ "${FILESDIR}"/${P}-postgresql.patch \
+ "${FILESDIR}"/${P}-gcc-4.7.patch \
+ "${FILESDIR}"/${P}-gcc6.patch
+}
+
+src_configure() {
+ if use fcgi; then
+ myconf="${myconf} --with-fcgi=/usr"
+ else
+ myconf="${myconf} --disable-fcgi"
+ fi
+ use imagemagick || myconf="${myconf} --disable-magickpp"
+ use mprpc || myconf="${myconf} --disable-mprpc"
+ if ! use mysql && ! use postgres; then
+ myconf="${myconf} --disable-database"
+ fi
+ waf-utils_src_configure ${myconf}
+}