parent
cd76f473d6
commit
2fb6ba244d
@ -0,0 +1,145 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
inherit eutils multilib user systemd toolchain-funcs
|
||||
|
||||
MY_P="${P/_/-}"
|
||||
|
||||
DESCRIPTION="Single process stack of various system monitors"
|
||||
HOMEPAGE="http://www.gkrellm.net/"
|
||||
SRC_URI="http://gkrellm.srcbox.net/${MY_P}.tar.bz2"
|
||||
|
||||
LICENSE="GPL-3"
|
||||
SLOT="2"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux"
|
||||
IUSE="gnutls hddtemp libressl lm_sensors nls ntlm ssl kernel_FreeBSD X"
|
||||
|
||||
RDEPEND="
|
||||
dev-libs/glib:2
|
||||
hddtemp? ( app-admin/hddtemp )
|
||||
gnutls? ( net-libs/gnutls )
|
||||
!gnutls? (
|
||||
ssl? (
|
||||
!libressl? ( dev-libs/openssl:0= )
|
||||
libressl? ( dev-libs/libressl:= )
|
||||
)
|
||||
)
|
||||
lm_sensors? ( sys-apps/lm_sensors )
|
||||
nls? ( virtual/libintl )
|
||||
ntlm? ( net-libs/libntlm )
|
||||
X? (
|
||||
x11-libs/gdk-pixbuf
|
||||
x11-libs/gtk+:2
|
||||
x11-libs/libICE
|
||||
x11-libs/libSM
|
||||
x11-libs/libX11
|
||||
x11-libs/pango
|
||||
)"
|
||||
DEPEND="${RDEPEND}
|
||||
virtual/pkgconfig
|
||||
nls? ( sys-devel/gettext )"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-2.3.5-cifs.patch
|
||||
"${FILESDIR}"/${PN}-2.3.5-config.patch
|
||||
"${FILESDIR}"/${PN}-2.3.5-width.patch
|
||||
"${FILESDIR}"/${PN}-2.3.5-sansfont.patch
|
||||
"${FILESDIR}"/${P}-fix_gtk_deprecation_warning.patch
|
||||
"${FILESDIR}"/${P}-fix_copypaste_error.patch
|
||||
"${FILESDIR}"/${P}-avoid_possible_busy_loop.patch
|
||||
"${FILESDIR}"/${P}-update_german_translation.patch.xz
|
||||
)
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
pkg_setup() {
|
||||
enewgroup gkrellmd
|
||||
enewuser gkrellmd -1 -1 -1 gkrellmd
|
||||
TARGET=
|
||||
use kernel_FreeBSD && TARGET="freebsd"
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
sed -e 's:-O2 ::' \
|
||||
-e 's:override CC:CFLAGS:' \
|
||||
-e 's:-L/usr/X11R6/lib::' \
|
||||
-i */Makefile || die "sed Makefile(s) failed"
|
||||
|
||||
sed -e "s:/usr/lib:${EPREFIX}/usr/$(get_libdir):" \
|
||||
-e "s:/usr/local/lib:${EPREFIX}/usr/local/$(get_libdir):" \
|
||||
-i src/${PN}.h || die "sed ${PN}.h failed"
|
||||
|
||||
epatch ${PATCHES[@]}
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
if use X ; then
|
||||
local sslopt=""
|
||||
if use gnutls; then
|
||||
sslopt="without-ssl=yes"
|
||||
elif use ssl; then
|
||||
sslopt="without-gnutls=yes"
|
||||
else
|
||||
sslopt="without-ssl=yes without-gnutls=yes"
|
||||
fi
|
||||
|
||||
emake \
|
||||
${TARGET} \
|
||||
CC="$(tc-getCC)" \
|
||||
STRIP="" \
|
||||
INSTALLROOT="${EPREFIX}/usr" \
|
||||
INCLUDEDIR="${EPREFIX}/usr/include/gkrellm2" \
|
||||
LOCALEDIR="${EPREFIX}/usr/share/locale" \
|
||||
$(usex nls "" "enable_nls=0") \
|
||||
$(usex lm_sensors "" "without-libsensors=yes") \
|
||||
$(usex ntlm "" "without-ntlm=yes") \
|
||||
${sslopt}
|
||||
else
|
||||
cd server || die
|
||||
emake \
|
||||
${TARGET} \
|
||||
CC="$(tc-getCC)" \
|
||||
LINK_FLAGS="$LDFLAGS -Wl,-E" \
|
||||
STRIP="" \
|
||||
$(usex nls "" "enable_nls=0") \
|
||||
$(usex lm_sensors "" "without-libsensors=yes")
|
||||
fi
|
||||
}
|
||||
|
||||
src_install() {
|
||||
if use X ; then
|
||||
emake \
|
||||
install${TARGET:+_}${TARGET} \
|
||||
$(usex nls "" "enable_nls=0") \
|
||||
STRIP="" \
|
||||
INSTALLDIR="${ED}/usr/bin" \
|
||||
INCLUDEDIR="${ED}/usr/include" \
|
||||
LOCALEDIR="${ED}/usr/share/locale" \
|
||||
PKGCONFIGDIR="${ED}/usr/$(get_libdir)/pkgconfig" \
|
||||
MANDIR="${ED}/usr/share/man/man1"
|
||||
|
||||
dohtml *.html
|
||||
|
||||
newicon src/icon.xpm ${PN}.xpm
|
||||
make_desktop_entry ${PN} GKrellM ${PN}
|
||||
else
|
||||
dobin server/gkrellmd
|
||||
|
||||
insinto /usr/include/gkrellm2
|
||||
doins server/gkrellmd.h
|
||||
doins shared/log.h
|
||||
fi
|
||||
|
||||
newinitd "${FILESDIR}"/gkrellmd.initd gkrellmd
|
||||
newconfd "${FILESDIR}"/gkrellmd.conf gkrellmd
|
||||
|
||||
systemd_dounit "${FILESDIR}"/gkrellmd.service
|
||||
|
||||
insinto /etc
|
||||
doins server/gkrellmd.conf
|
||||
|
||||
dodoc Changelog CREDITS README
|
||||
}
|
@ -1,190 +0,0 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
PYTHON_COMPAT=( python2_7 )
|
||||
|
||||
inherit distutils-r1 user
|
||||
|
||||
DESCRIPTION="Provides services for discovering, registering, and retrieving
|
||||
virtual machine images"
|
||||
HOMEPAGE="https://launchpad.net/glance"
|
||||
SRC_URI="https://launchpad.net/${PN}/kilo/${PV}/+download/${P}.tar.gz"
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64 x86"
|
||||
IUSE="doc mysql postgres +sqlite +swift test"
|
||||
REQUIRED_USE="|| ( mysql postgres sqlite )"
|
||||
|
||||
DEPEND="
|
||||
dev-python/setuptools[${PYTHON_USEDEP}]
|
||||
>=dev-python/pbr-0.8.0[${PYTHON_USEDEP}]
|
||||
<dev-python/pbr-1.0[${PYTHON_USEDEP}]
|
||||
test? (
|
||||
${RDEPEND}
|
||||
>=dev-python/hacking-0.10.0[${PYTHON_USEDEP}]
|
||||
<dev-python/hacking-0.11[${PYTHON_USEDEP}]
|
||||
>=dev-python/Babel-1.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/coverage-3.6[${PYTHON_USEDEP}]
|
||||
>=dev-python/fixtures-0.3.14[${PYTHON_USEDEP}]
|
||||
<dev-python/fixtures-1.3.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/mock-1.0[${PYTHON_USEDEP}]
|
||||
<dev-python/mock-1.1.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/sphinx-1.1.2[${PYTHON_USEDEP}]
|
||||
!~dev-python/sphinx-1.2.0[${PYTHON_USEDEP}]
|
||||
<dev-python/sphinx-1.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/requests-2.2.0[${PYTHON_USEDEP}]
|
||||
!~dev-python/requests-2.4.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/testrepository-0.0.18[${PYTHON_USEDEP}]
|
||||
>=dev-python/testtools-0.9.36[${PYTHON_USEDEP}]
|
||||
!~dev-python/testtools-1.2.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/psutil-1.1.1[${PYTHON_USEDEP}]
|
||||
<dev-python/psutil-2.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslotest-1.5.1[${PYTHON_USEDEP}]
|
||||
<dev-python/oslotest-1.6.0[${PYTHON_USEDEP}]
|
||||
dev-python/mysql-python[${PYTHON_USEDEP}]
|
||||
dev-python/psycopg[${PYTHON_USEDEP}]
|
||||
~dev-python/pysendfile-2.0.1[${PYTHON_USEDEP}]
|
||||
dev-python/qpid-python[${PYTHON_USEDEP}]
|
||||
>=dev-python/pyxattr-0.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-sphinx-2.5.0[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-sphinx-2.6.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/elasticsearch-py-1.3.0[${PYTHON_USEDEP}]
|
||||
)"
|
||||
|
||||
#note to self, wsgiref is a python builtin, no need to package it
|
||||
#>=dev-python/wsgiref-0.1.2[${PYTHON_USEDEP}]
|
||||
|
||||
RDEPEND="
|
||||
>=dev-python/greenlet-0.3.2[${PYTHON_USEDEP}]
|
||||
sqlite? (
|
||||
>=dev-python/sqlalchemy-0.9.7[sqlite,${PYTHON_USEDEP}]
|
||||
<=dev-python/sqlalchemy-0.9.99[sqlite,${PYTHON_USEDEP}]
|
||||
)
|
||||
mysql? (
|
||||
dev-python/mysql-python
|
||||
>=dev-python/sqlalchemy-0.9.7[${PYTHON_USEDEP}]
|
||||
<=dev-python/sqlalchemy-0.9.99[${PYTHON_USEDEP}]
|
||||
)
|
||||
postgres? (
|
||||
dev-python/psycopg:2
|
||||
>=dev-python/sqlalchemy-0.9.7[${PYTHON_USEDEP}]
|
||||
<=dev-python/sqlalchemy-0.9.99[${PYTHON_USEDEP}]
|
||||
)
|
||||
>=dev-python/anyjson-0.3.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/eventlet-0.16.1[${PYTHON_USEDEP}]
|
||||
!~dev-python/eventlet-0.17.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/pastedeploy-1.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/routes-1.12.3[${PYTHON_USEDEP}]
|
||||
!~dev-python/routes-2.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/webob-1.2.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/sqlalchemy-migrate-0.9.5[${PYTHON_USEDEP}]
|
||||
>=dev-python/httplib2-0.7.5[${PYTHON_USEDEP}]
|
||||
>=dev-python/kombu-2.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/pycrypto-2.6[${PYTHON_USEDEP}]
|
||||
>=dev-python/iso8601-0.1.9[${PYTHON_USEDEP}]
|
||||
dev-python/ordereddict[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-config-1.9.3[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-config-1.10.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-concurrency-1.8.0[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-concurrency-1.9.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-context-0.2.0[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-context-0.3.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-utils-1.4.0[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-utils-1.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/stevedore-1.3.0[${PYTHON_USEDEP}]
|
||||
<dev-python/stevedore-1.4.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/taskflow-0.7.1[${PYTHON_USEDEP}]
|
||||
<dev-python/taskflow-0.8.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/keystonemiddleware-1.5.0[${PYTHON_USEDEP}]
|
||||
<dev-python/keystonemiddleware-1.6.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/WSME-0.6[${PYTHON_USEDEP}]
|
||||
<dev-python/WSME-0.7[${PYTHON_USEDEP}]
|
||||
dev-python/posix_ipc[${PYTHON_USEDEP}]
|
||||
swift? (
|
||||
>=dev-python/python-swiftclient-2.2.0[${PYTHON_USEDEP}]
|
||||
<dev-python/python-swiftclient-2.5.0[${PYTHON_USEDEP}]
|
||||
)
|
||||
>=dev-python/oslo-vmware-0.11.1[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-vmware-0.12.0[${PYTHON_USEDEP}]
|
||||
dev-python/paste[${PYTHON_USEDEP}]
|
||||
>=dev-python/jsonschema-2.0.0[${PYTHON_USEDEP}]
|
||||
<dev-python/jsonschema-3.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/python-keystoneclient-1.2.0[${PYTHON_USEDEP}]
|
||||
<dev-python/python-keystoneclient-1.4.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/pyopenssl-0.11[${PYTHON_USEDEP}]
|
||||
>=dev-python/six-1.9.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-db-1.7.0[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-db-1.8.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-i18n-1.5.0[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-i18n-1.6.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-log-1.0.0[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-log-1.1.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-messaging-1.8.0[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-messaging-1.9.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-policy-0.3.1[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-policy-0.4.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-serialization-1.4.0[${PYTHON_USEDEP}]
|
||||
<dev-python/oslo-serialization-1.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/retrying-1.2.3[${PYTHON_USEDEP}]
|
||||
!~dev-python/retrying-1.3.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/osprofiler-0.3.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/glance_store-0.3.0[${PYTHON_USEDEP}]
|
||||
<dev-python/glance_store-0.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/semantic_version-2.3.1[${PYTHON_USEDEP}]
|
||||
"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/cve-2015-5163-stable-kilo.patch"
|
||||
"${FILESDIR}/cve-2015-5251-stable-kilo.patch"
|
||||
)
|
||||
|
||||
pkg_setup() {
|
||||
enewgroup glance
|
||||
enewuser glance -1 -1 /var/lib/glance glance
|
||||
}
|
||||
|
||||
python_prepare_all() {
|
||||
sed -i '/xattr/d' test-requirements.txt || die
|
||||
sed -i '/pysendfile/d' test-requirements.txt || die
|
||||
distutils-r1_python_prepare_all
|
||||
}
|
||||
|
||||
python_compile_all() {
|
||||
use doc && "${PYTHON}" setup.py build_sphinx
|
||||
}
|
||||
|
||||
python_test() {
|
||||
# https://bugs.launchpad.net/glance/+bug/1251105
|
||||
# https://bugs.launchpad.net/glance/+bug/1242501
|
||||
testr init
|
||||
testr run --parallel || die "failed testsuite under python2.7"
|
||||
}
|
||||
|
||||
python_install() {
|
||||
distutils-r1_python_install
|
||||
|
||||
for svc in api registry scrubber; do
|
||||
newinitd "${FILESDIR}/glance.initd" glance-${svc}
|
||||
done
|
||||
|
||||
diropts -m 0750 -o glance -g glance
|
||||
dodir /var/log/glance /var/lib/glance/images /var/lib/glance/scrubber
|
||||
keepdir /etc/glance
|
||||
keepdir /var/log/glance
|
||||
keepdir /var/lib/glance/images
|
||||
keepdir /var/lib/glance/scrubber
|
||||
|
||||
insinto /etc/glance
|
||||
insopts -m 0640 -o glance -g glance
|
||||
doins etc/*.ini
|
||||
doins etc/*.conf
|
||||
doins etc/*.sample
|
||||
}
|
||||
|
||||
python_install_all() {
|
||||
use doc && local HTML_DOCS=( doc/build/html/. )
|
||||
distutils-r1_python_install_all
|
||||
}
|
@ -1 +1 @@
|
||||
DIST paxtest-0.9.13.tar.gz 34451 SHA256 b1f9122e45927a05ea65ec9c3b8dad92377245e546c0eff08b0f8ad9ba6e4c75 SHA512 dc375f7b0c9dd3efcf22adae6cbf0724ae505c6b3a1c55de223665c454650f86014098a45226b3fc8e4b89d528152aaf458aa3b7d1c9ffc86b3be52f2af69d60 WHIRLPOOL 6d5066f759d01e7efd6b4e872bb9d9e1a7341f82f379e77dc8ae77139fa533abe004bdda9f8a35d90a1d2f4c8917d8ba4b1c56e65401522ccc1e99f99a158070
|
||||
DIST paxtest-0.9.14.tar.gz 34286 SHA256 7dead81fcdc8db2f88e3da1027e6d7c93596f2e6e4dac25ec9b54c41fa808048 SHA512 6e2d642e1dfe7e3381ed520956d2f5b19ad8c8e569c4ddcf43a2772a76ed67701bb18fe55d7fe2b82ff50644f92470622243ac974083d87448f560f6d48d8727 WHIRLPOOL bef2998611b0487590364648b8f5d4ddc470b212c2a8b0282f4220b1da8033f23299298b51dc932c35f37099f7076a99220726b30d91472ca266042f16c4ed02
|
||||
|
@ -0,0 +1,140 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
inherit eutils flag-o-matic user systemd
|
||||
|
||||
DESCRIPTION="Clam Anti-Virus Scanner"
|
||||
HOMEPAGE="http://www.clamav.net/"
|
||||
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~sparc-solaris ~x86-solaris"
|
||||
IUSE="bzip2 clamdtop iconv ipv6 libressl milter metadata-analysis-api selinux static-libs uclibc"
|
||||
|
||||
CDEPEND="bzip2? ( app-arch/bzip2 )
|
||||
clamdtop? ( sys-libs/ncurses:0 )
|
||||
iconv? ( virtual/libiconv )
|
||||
metadata-analysis-api? ( dev-libs/json-c )
|
||||
milter? ( || ( mail-filter/libmilter mail-mta/sendmail ) )
|
||||
dev-libs/libtommath
|
||||
>=sys-libs/zlib-1.2.2
|
||||
!libressl? ( dev-libs/openssl:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
sys-devel/libtool"
|
||||
# openssl is now *required* see this link as to why
|
||||
# http://blog.clamav.net/2014/02/introducing-openssl-as-dependency-to.html
|
||||
DEPEND="${CDEPEND}
|
||||
virtual/pkgconfig"
|
||||
RDEPEND="${CDEPEND}
|
||||
selinux? ( sec-policy/selinux-clamav )"
|
||||
|
||||
DOCS=( AUTHORS BUGS ChangeLog FAQ INSTALL NEWS README UPGRADE )
|
||||
|
||||
pkg_setup() {
|
||||
enewgroup clamav
|
||||
enewuser clamav -1 -1 /dev/null clamav
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
use ppc64 && append-flags -mminimal-toc
|
||||
use uclibc && export ac_cv_type_error_t=yes
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
econf \
|
||||
--disable-experimental \
|
||||
--disable-fanotify \
|
||||
--enable-id-check \
|
||||
--with-dbdir="${EPREFIX}"/var/lib/clamav \
|
||||
--with-system-tommath \
|
||||
--with-zlib="${EPREFIX}"/usr \
|
||||
$(use_enable bzip2) \
|
||||
$(use_enable clamdtop) \
|
||||
$(use_enable ipv6) \
|
||||
$(use_enable milter) \
|
||||
$(use_enable static-libs static) \
|
||||
$(use_with iconv) \
|
||||
$(use_with metadata-analysis-api libjson /usr)
|
||||
}
|
||||
|
||||
src_install() {
|
||||
default
|
||||
|
||||
rm -rf "${ED}"/var/lib/clamav
|
||||
newinitd "${FILESDIR}"/clamd.initd-r6 clamd
|
||||
newconfd "${FILESDIR}"/clamd.conf-r1 clamd
|
||||
|
||||
systemd_dotmpfilesd "${FILESDIR}/tmpfiles.d/clamav.conf"
|
||||
systemd_newunit "${FILESDIR}/clamd_at.service" "clamd@.service"
|
||||
systemd_dounit "${FILESDIR}/clamd.service"
|
||||
systemd_dounit "${FILESDIR}/freshclamd.service"
|
||||
|
||||
keepdir /var/lib/clamav
|
||||
fowners clamav:clamav /var/lib/clamav
|
||||
keepdir /var/log/clamav
|
||||
fowners clamav:clamav /var/log/clamav
|
||||
|
||||
dodir /etc/logrotate.d
|
||||
insinto /etc/logrotate.d
|
||||
newins "${FILESDIR}"/clamav.logrotate clamav
|
||||
|
||||
# Modify /etc/{clamd,freshclam}.conf to be usable out of the box
|
||||
sed -i -e "s:^\(Example\):\# \1:" \
|
||||
-e "s:.*\(PidFile\) .*:\1 ${EPREFIX}/var/run/clamav/clamd.pid:" \
|
||||
-e "s:.*\(LocalSocket\) .*:\1 ${EPREFIX}/var/run/clamav/clamd.sock:" \
|
||||
-e "s:.*\(User\) .*:\1 clamav:" \
|
||||
-e "s:^\#\(LogFile\) .*:\1 ${EPREFIX}/var/log/clamav/clamd.log:" \
|
||||
-e "s:^\#\(LogTime\).*:\1 yes:" \
|
||||
-e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \
|
||||
"${ED}"/etc/clamd.conf.sample || die
|
||||
sed -i -e "s:^\(Example\):\# \1:" \
|
||||
-e "s:.*\(PidFile\) .*:\1 ${EPREFIX}/var/run/clamav/freshclam.pid:" \
|
||||
-e "s:.*\(DatabaseOwner\) .*:\1 clamav:" \
|
||||
-e "s:^\#\(UpdateLogFile\) .*:\1 ${EPREFIX}/var/log/clamav/freshclam.log:" \
|
||||
-e "s:^\#\(NotifyClamd\).*:\1 ${EPREFIX}/etc/clamd.conf:" \
|
||||
-e "s:^\#\(ScriptedUpdates\).*:\1 yes:" \
|
||||
-e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \
|
||||
"${ED}"/etc/freshclam.conf.sample || die
|
||||
|
||||
if use milter ; then
|
||||
# MilterSocket one to include ' /' because there is a 2nd line for
|
||||
# inet: which we want to leave
|
||||
dodoc "${FILESDIR}"/clamav-milter.README.gentoo
|
||||
sed -i -e "s:^\(Example\):\# \1:" \
|
||||
-e "s:.*\(PidFile\) .*:\1 ${EPREFIX}/var/run/clamav/clamav-milter.pid:" \
|
||||
-e "s+^\#\(ClamdSocket\) .*+\1 unix:${EPREFIX}/var/run/clamav/clamd.sock+" \
|
||||
-e "s:.*\(User\) .*:\1 clamav:" \
|
||||
-e "s+^\#\(MilterSocket\) /.*+\1 unix:${EPREFIX}/var/run/clamav/clamav-milter.sock+" \
|
||||
-e "s:^\#\(AllowSupplementaryGroups\).*:\1 yes:" \
|
||||
-e "s:^\#\(LogFile\) .*:\1 ${EPREFIX}/var/log/clamav/clamav-milter.log:" \
|
||||
"${ED}"/etc/clamav-milter.conf.sample || die
|
||||
cat >> "${ED}"/etc/conf.d/clamd <<-EOF
|
||||
MILTER_NICELEVEL=19
|
||||
START_MILTER=no
|
||||
EOF
|
||||
|
||||
systemd_newunit "${FILESDIR}/clamav-milter.service-r1" clamav-milter.service
|
||||
fi
|
||||
|
||||
for i in clamd freshclam clamav-milter
|
||||
do
|
||||
[[ -f "${D}"/etc/"${i}".conf.sample ]] && mv "${D}"/etc/"${i}".conf{.sample,}
|
||||
done
|
||||
|
||||
prune_libtool_files --all
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
if use milter ; then
|
||||
elog "For simple instructions how to setup the clamav-milter read the"
|
||||
elog "clamav-milter.README.gentoo in /usr/share/doc/${PF}"
|
||||
fi
|
||||
if test -z $(find "${ROOT}"var/lib/clamav -maxdepth 1 -name 'main.c*' -print -quit) ; then
|
||||
ewarn "You must run freshclam manually to populate the virus database files"
|
||||
ewarn "before starting clamav for the first time.\n"
|
||||
fi
|
||||
}
|
@ -0,0 +1,154 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
PYTHON_COMPAT=( python2_7 )
|
||||
|
||||
inherit autotools eutils flag-o-matic multilib-minimal python-any-r1 versionator
|
||||
|
||||
MY_P="${P/mit-}"
|
||||
P_DIR=$(get_version_component_range 1-2)
|
||||
DESCRIPTION="MIT Kerberos V"
|
||||
HOMEPAGE="http://web.mit.edu/kerberos/www/"
|
||||
SRC_URI="http://web.mit.edu/kerberos/dist/krb5/${P_DIR}/${MY_P}-signed.tar"
|
||||
|
||||
LICENSE="openafs-krb5-a BSD MIT OPENLDAP BSD-2 HPND BSD-4 ISC RSA CC-BY-SA-3.0 || ( BSD-2 GPL-2+ )"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
|
||||
IUSE="doc +keyutils libressl openldap +pkinit selinux +threads test xinetd"
|
||||
|
||||
CDEPEND="
|
||||
!!app-crypt/heimdal
|
||||
>=sys-libs/e2fsprogs-libs-1.42.9[${MULTILIB_USEDEP}]
|
||||
|| (
|
||||
>=dev-libs/libverto-0.2.5[libev,${MULTILIB_USEDEP}]
|
||||
>=dev-libs/libverto-0.2.5[libevent,${MULTILIB_USEDEP}]
|
||||
>=dev-libs/libverto-0.2.5[tevent,${MULTILIB_USEDEP}]
|
||||
)
|
||||
keyutils? ( >=sys-apps/keyutils-1.5.8[${MULTILIB_USEDEP}] )
|
||||
openldap? ( >=net-nds/openldap-2.4.38-r1[${MULTILIB_USEDEP}] )
|
||||
pkinit? (
|
||||
!libressl? ( >=dev-libs/openssl-1.0.1h-r2:0[${MULTILIB_USEDEP}] )
|
||||
libressl? ( dev-libs/libressl[${MULTILIB_USEDEP}] )
|
||||
)
|
||||
xinetd? ( sys-apps/xinetd )
|
||||
abi_x86_32? (
|
||||
!<=app-emulation/emul-linux-x86-baselibs-20140508-r1
|
||||
!app-emulation/emul-linux-x86-baselibs[-abi_x86_32(-)]
|
||||
)"
|
||||
DEPEND="${CDEPEND}
|
||||
${PYTHON_DEPS}
|
||||
virtual/yacc
|
||||
doc? ( virtual/latex-base )
|
||||
test? (
|
||||
${PYTHON_DEPS}
|
||||
dev-lang/tcl:0
|
||||
dev-util/dejagnu
|
||||
)"
|
||||
RDEPEND="${CDEPEND}
|
||||
selinux? ( sec-policy/selinux-kerberos )"
|
||||
|
||||
S=${WORKDIR}/${MY_P}/src
|
||||
|
||||
MULTILIB_CHOST_TOOLS=(
|
||||
/usr/bin/krb5-config
|
||||
)
|
||||
|
||||
src_unpack() {
|
||||
unpack ${A}
|
||||
unpack ./"${MY_P}".tar.gz
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
epatch "${FILESDIR}/${PN}-1.12_warn_cflags.patch"
|
||||
epatch "${FILESDIR}/${PN}-config_LDFLAGS.patch"
|
||||
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
append-cppflags "-I${EPREFIX}/usr/include/et"
|
||||
# QA
|
||||
append-flags -fno-strict-aliasing
|
||||
append-flags -fno-strict-overflow
|
||||
|
||||
multilib-minimal_src_configure
|
||||
}
|
||||
|
||||
multilib_src_configure() {
|
||||
use keyutils || export ac_cv_header_keyutils_h=no
|
||||
ECONF_SOURCE=${S} \
|
||||
WARN_CFLAGS="set" \
|
||||
econf \
|
||||
$(use_with openldap ldap) \
|
||||
"$(multilib_native_use_with test tcl "${EPREFIX}/usr")" \
|
||||
$(use_enable pkinit) \
|
||||
$(use_enable threads thread-support) \
|
||||
--without-hesiod \
|
||||
--enable-shared \
|
||||
--with-system-et \
|
||||
--with-system-ss \
|
||||
--enable-dns-for-realm \
|
||||
--enable-kdc-lookaside-cache \
|
||||
--with-system-verto \
|
||||
--disable-rpath
|
||||
}
|
||||
|
||||
multilib_src_compile() {
|
||||
emake -j1
|
||||
}
|
||||
|
||||
multilib_src_test() {
|
||||
multilib_is_native_abi && emake -j1 check
|
||||
}
|
||||
|
||||
multilib_src_install() {
|
||||
emake \
|
||||
DESTDIR="${D}" \
|
||||
EXAMPLEDIR="${EPREFIX}/usr/share/doc/${PF}/examples" \
|
||||
install
|
||||
}
|
||||
|
||||
multilib_src_install_all() {
|
||||
# default database dir
|
||||
keepdir /var/lib/krb5kdc
|
||||
|
||||
cd ..
|
||||
dodoc README
|
||||
|
||||
if use doc; then
|
||||
dohtml -r doc/html/*
|
||||
docinto pdf
|
||||
dodoc doc/pdf/*.pdf
|
||||
fi
|
||||
|
||||
newinitd "${FILESDIR}"/mit-krb5kadmind.initd-r1 mit-krb5kadmind
|
||||
newinitd "${FILESDIR}"/mit-krb5kdc.initd-r1 mit-krb5kdc
|
||||
newinitd "${FILESDIR}"/mit-krb5kpropd.initd-r1 mit-krb5kpropd
|
||||
|
||||
insinto /etc
|
||||
newins "${ED}/usr/share/doc/${PF}/examples/krb5.conf" krb5.conf.example
|
||||
insinto /var/lib/krb5kdc
|
||||
newins "${ED}/usr/share/doc/${PF}/examples/kdc.conf" kdc.conf.example
|
||||
|
||||
if use openldap ; then
|
||||
insinto /etc/openldap/schema
|
||||
doins "${S}/plugins/kdb/ldap/libkdb_ldap/kerberos.schema"
|
||||
fi
|
||||
|
||||
if use xinetd ; then
|
||||
insinto /etc/xinetd.d
|
||||
newins "${FILESDIR}/kpropd.xinetd" kpropd
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
if has_version "<${CATEGORY}/${PN}-1.8.0" ; then
|
||||
elog "MIT split the Kerberos applications from the base Kerberos"
|
||||
elog "distribution. Kerberized versions of telnet, rlogin, rsh, rcp,"
|
||||
elog "ftp clients and telnet, ftp deamons now live in"
|
||||
elog "\"app-crypt/mit-krb5-appl\" package."
|
||||
fi
|
||||
}
|
@ -0,0 +1,128 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
inherit cmake-utils multibuild qmake-utils
|
||||
|
||||
MY_PN="${PN}-qt5"
|
||||
|
||||
DESCRIPTION="Qt Cryptographic Architecture (QCA)"
|
||||
HOMEPAGE="http://delta.affinix.com/qca/"
|
||||
SRC_URI="mirror://kde/stable/${MY_PN}/${PV}/src/${MY_PN}-${PV}.tar.xz"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="2"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~sparc-solaris"
|
||||
|
||||
IUSE="botan debug doc examples gcrypt gpg libressl logger nss +openssl pkcs11 +qt4 qt5 sasl softstore test"
|
||||
REQUIRED_USE="|| ( qt4 qt5 )"
|
||||
|
||||
RDEPEND="
|
||||
!app-crypt/qca-cyrus-sasl
|
||||
!app-crypt/qca-gnupg
|
||||
!app-crypt/qca-logger
|
||||
!app-crypt/qca-ossl
|
||||
!app-crypt/qca-pkcs11
|
||||
botan? ( dev-libs/botan )
|
||||
gcrypt? ( dev-libs/libgcrypt:= )
|
||||
gpg? ( app-crypt/gnupg )
|
||||
nss? ( dev-libs/nss )
|
||||
openssl? (
|
||||
!libressl? ( >=dev-libs/openssl-1.0.1:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
)
|
||||
pkcs11? (
|
||||
!libressl? ( dev-libs/openssl:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
dev-libs/pkcs11-helper
|
||||
)
|
||||
qt4? ( dev-qt/qtcore:4 )
|
||||
qt5? (
|
||||
dev-qt/qtcore:5
|
||||
dev-qt/qtconcurrent:5
|
||||
dev-qt/qtnetwork:5
|
||||
)
|
||||
sasl? ( dev-libs/cyrus-sasl:2 )
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
doc? ( app-doc/doxygen )
|
||||
test? (
|
||||
qt4? ( dev-qt/qttest:4 )
|
||||
qt5? ( dev-qt/qttest:5 )
|
||||
)
|
||||
"
|
||||
|
||||
S=${WORKDIR}/${MY_PN}-${PV}
|
||||
|
||||
DOCS=( README TODO )
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/${PN}-disable-pgp-test.patch"
|
||||
"${FILESDIR}/${P}-qt55.patch"
|
||||
"${FILESDIR}/${P}-fix-signals-slots.patch"
|
||||
)
|
||||
|
||||
qca_plugin_use() {
|
||||
echo -DWITH_${2:-$1}_PLUGIN=$(usex "$1")
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
MULTIBUILD_VARIANTS=( $(usev qt4) $(usev qt5) )
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
myconfigure() {
|
||||
local mycmakeargs=(
|
||||
-DQCA_FEATURE_INSTALL_DIR="${EPREFIX}$(${MULTIBUILD_VARIANT}_get_mkspecsdir)/features"
|
||||
-DQCA_PLUGINS_INSTALL_DIR="${EPREFIX}$(${MULTIBUILD_VARIANT}_get_plugindir)"
|
||||
$(qca_plugin_use botan)
|
||||
$(qca_plugin_use gcrypt)
|
||||
$(qca_plugin_use gpg gnupg)
|
||||
$(qca_plugin_use logger)
|
||||
$(qca_plugin_use nss)
|
||||
$(qca_plugin_use openssl ossl)
|
||||
$(qca_plugin_use pkcs11)
|
||||
$(qca_plugin_use sasl cyrus-sasl)
|
||||
$(qca_plugin_use softstore)
|
||||
$(cmake-utils_use_build test TESTS)
|
||||
)
|
||||
|
||||
if [[ ${MULTIBUILD_VARIANT} == qt4 ]]; then
|
||||
mycmakeargs+=(-DQT4_BUILD=ON)
|
||||
fi
|
||||
|
||||
cmake-utils_src_configure
|
||||
}
|
||||
|
||||
multibuild_foreach_variant myconfigure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
multibuild_foreach_variant cmake-utils_src_compile
|
||||
}
|
||||
|
||||
src_test() {
|
||||
mytest() {
|
||||
local -x QCA_PLUGIN_PATH="${BUILD_DIR}/lib/qca"
|
||||
cmake-utils_src_test
|
||||
}
|
||||
|
||||
multibuild_foreach_variant mytest
|
||||
}
|
||||
|
||||
src_install() {
|
||||
multibuild_foreach_variant cmake-utils_src_install
|
||||
|
||||
if use doc; then
|
||||
pushd "${BUILD_DIR}" >/dev/null || die
|
||||
doxygen Doxyfile.in || die
|
||||
dodoc -r apidocs/html
|
||||
popd >/dev/null || die
|
||||
fi
|
||||
|
||||
if use examples; then
|
||||
dodoc -r "${S}"/examples
|
||||
fi
|
||||
}
|
@ -0,0 +1,104 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
inherit autotools eutils linux-info readme.gentoo systemd user udev
|
||||
|
||||
#MY_P="${PN}-${PV%.*}-${PV##*.}"
|
||||
|
||||
DESCRIPTION="An open-source TCG Software Stack (TSS) v1.1 implementation"
|
||||
HOMEPAGE="http://trousers.sf.net"
|
||||
SRC_URI="mirror://sourceforge/trousers/${P}.tar.gz"
|
||||
|
||||
LICENSE="CPL-1.0 GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~arm ~arm64 ~m68k ~ppc ~ppc64 ~s390 ~sh ~x86"
|
||||
IUSE="doc libressl selinux" # gtk
|
||||
|
||||
# gtk support presently does NOT compile.
|
||||
# gtk? ( >=x11-libs/gtk+-2 )
|
||||
|
||||
CDEPEND=">=dev-libs/glib-2
|
||||
!libressl? ( >=dev-libs/openssl-0.9.7:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
"
|
||||
DEPEND="${CDEPEND}
|
||||
virtual/pkgconfig"
|
||||
RDEPEND="${CDEPEND}
|
||||
selinux? ( sec-policy/selinux-tcsd )"
|
||||
# S="${WORKDIR}/${P}git"
|
||||
|
||||
DOCS="AUTHORS ChangeLog NICETOHAVES README TODO"
|
||||
|
||||
DOC_CONTENTS="
|
||||
If you have problems starting tcsd, please check permissions and
|
||||
ownership on /dev/tpm* and ~tss/system.data
|
||||
"
|
||||
|
||||
pkg_setup() {
|
||||
# Check for driver (not sure it can be an rdep, because ot depends on the
|
||||
# version of virtual/linux-sources... Is that supported by portage?)
|
||||
linux-info_pkg_setup
|
||||
local tpm_kernel_version tpm_kernel_present tpm_module
|
||||
kernel_is ge 2 6 12 && tpm_kernel_version="yes"
|
||||
if linux_config_exists; then
|
||||
linux_chkconfig_present TCG_TPM && tpm_kernel_present="yes"
|
||||
else
|
||||
ewarn "No kernel configuration could be found."
|
||||
fi
|
||||
has_version app-crypt/tpm-emulator && tpm_module="yes"
|
||||
if [[ -n "${tpm_kernel_present}" ]]; then
|
||||
einfo "Good, you seem to have in-kernel TPM support."
|
||||
elif [[ -n "${tpm_module}" ]]; then
|
||||
einfo "Good, you seem to have TPM support with the external module."
|
||||
if [[ -n "${tpm_kernel_version}" ]]; then
|
||||
elog
|
||||
elog "Note that since you have a >=2.6.12 kernel, you could use"
|
||||
elog "the in-kernel driver instead of (CONFIG_TCG_TPM)."
|
||||
fi
|
||||
elif [[ -n "${tpm_kernel_version}" ]]; then
|
||||
eerror
|
||||
eerror "To use this package, you will have to activate TPM support"
|
||||
eerror "in your kernel configuration. That's at least CONFIG_TCG_TPM,"
|
||||
eerror "plus probably a chip specific driver (like CONFIG_TCG_ATMEL)."
|
||||
eerror
|
||||
else
|
||||
eerror
|
||||
eerror "To use this package, you should install a TPM driver."
|
||||
eerror "You can have the following options:"
|
||||
eerror " - install app-crypt/tpm-emulator"
|
||||
eerror " - switch to a >=2.6.12 kernel and compile the kernel module"
|
||||
eerror
|
||||
fi
|
||||
|
||||
# New user/group for the daemon
|
||||
enewgroup tss
|
||||
enewuser tss -1 -1 /var/lib/tpm tss
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
epatch "${FILESDIR}"/${P}-nouseradd.patch
|
||||
epatch "${FILESDIR}"/${P}-build.patch
|
||||
mv configure.in configure.ac || die
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
# econf --with-gui=$(usex gtk gtk openssl)
|
||||
econf --with-gui=openssl
|
||||
}
|
||||
|
||||
src_install() {
|
||||
keepdir /var/lib/tpm
|
||||
default
|
||||
use doc && dodoc doc/*
|
||||
newinitd "${FILESDIR}"/tcsd.initd tcsd
|
||||
newconfd "${FILESDIR}"/tcsd.confd tcsd
|
||||
systemd_dounit "${FILESDIR}"/tcsd.service
|
||||
udev_dorules "${FILESDIR}"/61-trousers.rules
|
||||
fowners tss:tss /var/lib/tpm
|
||||
prune_libtool_files
|
||||
readme.gentoo_create_doc
|
||||
}
|
@ -0,0 +1,251 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
# Note: xemacs currently does not work with a hardened profile. If you
|
||||
# want to use xemacs on a hardened profile then compile with the
|
||||
# -nopie flag in CFLAGS or help fix bug #75028.
|
||||
|
||||
EAPI=4
|
||||
|
||||
WANT_AUTOCONF="2.5"
|
||||
inherit eutils flag-o-matic multilib
|
||||
|
||||
DESCRIPTION="highly customizable open source text editor and application development system"
|
||||
HOMEPAGE="http://www.xemacs.org/"
|
||||
SRC_URI="http://ftp.xemacs.org/xemacs-21.5/${P}.tar.gz
|
||||
http://www.malfunction.de/afterstep/files/NeXT_XEmacs.tar.gz"
|
||||
|
||||
LICENSE="GPL-3+"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86 ~amd64-fbsd"
|
||||
IUSE="alsa debug eolconv gif gpm pop postgres ldap libressl xface nas dnd X jpeg tiff png mule motif freewnn canna xft xim athena neXt Xaw3d gdbm berkdb"
|
||||
|
||||
X_DEPEND="x11-libs/libXt x11-libs/libXmu x11-libs/libXext x11-misc/xbitmaps"
|
||||
|
||||
RDEPEND="
|
||||
berkdb? ( >=sys-libs/db-4 !!<sys-libs/db-4 )
|
||||
gdbm? ( >=sys-libs/gdbm-1.8.3[berkdb(+)] )
|
||||
>=sys-libs/zlib-1.1.4
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
>=media-libs/audiofile-0.2.3
|
||||
gpm? ( >=sys-libs/gpm-1.19.6 )
|
||||
postgres? ( dev-db/postgresql )
|
||||
ldap? ( net-nds/openldap )
|
||||
alsa? ( media-libs/alsa-lib )
|
||||
nas? ( media-libs/nas )
|
||||
X? ( $X_DEPEND !Xaw3d? ( !neXt? ( x11-libs/libXaw ) ) )
|
||||
dnd? ( x11-libs/dnd )
|
||||
motif? ( >=x11-libs/motif-2.3:0[xft=] )
|
||||
athena? ( x11-libs/libXaw )
|
||||
Xaw3d? ( x11-libs/libXaw3d )
|
||||
xft? ( media-libs/freetype:2 x11-libs/libXft x11-libs/libXrender >=media-libs/fontconfig-2.5.0 )
|
||||
neXt? ( x11-libs/neXtaw )
|
||||
xface? ( media-libs/compface )
|
||||
tiff? ( media-libs/tiff:0 )
|
||||
png? ( >=media-libs/libpng-1.2:0 )
|
||||
jpeg? ( virtual/jpeg:0 )
|
||||
canna? ( app-i18n/canna )
|
||||
freewnn? ( app-i18n/freewnn )
|
||||
>=sys-libs/ncurses-5.2
|
||||
>=app-eselect/eselect-emacs-1.15"
|
||||
|
||||
DEPEND="${RDEPEND}
|
||||
virtual/pkgconfig"
|
||||
|
||||
PDEPEND="app-xemacs/xemacs-base
|
||||
mule? ( app-xemacs/mule-base )"
|
||||
|
||||
src_unpack() {
|
||||
default_src_unpack
|
||||
|
||||
use neXt && unpack NeXT_XEmacs.tar.gz
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
use neXt && cp "${WORKDIR}"/NeXT.XEmacs/xemacs-icons/* "${S}"/etc/toolbar/
|
||||
find "${S}"/lisp -name '*.elc' -exec rm {} \; || die
|
||||
epatch "${FILESDIR}/${P}-ncurses-tinfo.patch"
|
||||
|
||||
# Some binaries and man pages are installed under suffixed names
|
||||
# to avoid collions with their GNU Emacs counterparts (see below).
|
||||
# Fix internal filename references.
|
||||
sed -i -e 's/exec gnuclient/&-xemacs/' lib-src/gnudoit || die
|
||||
sed -i -e '/^\.so/s/etags/&-xemacs/' etc/ctags.1 || die
|
||||
sed -i -e '/^\.so/s/gnuserv/&-xemacs/' etc/gnu{client,doit,attach}.1 || die
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
local myconf=""
|
||||
|
||||
if use X; then
|
||||
|
||||
myconf="${myconf} --with-widgets=athena"
|
||||
myconf="${myconf} --with-dialogs=athena"
|
||||
myconf="${myconf} --with-menubars=lucid"
|
||||
myconf="${myconf} --with-scrollbars=lucid"
|
||||
if use motif ; then
|
||||
myconf="--with-widgets=motif"
|
||||
myconf="${myconf} --with-dialogs=motif"
|
||||
myconf="${myconf} --with-scrollbars=motif"
|
||||
myconf="${myconf} --with-menubars=lucid"
|
||||
fi
|
||||
if use athena or use Xaw3d ; then
|
||||
myconf="--with-scrollbars=athena"
|
||||
fi
|
||||
|
||||
if use Xaw3d; then
|
||||
myconf="${myconf} --with-athena=3d"
|
||||
elif use neXt; then
|
||||
myconf="${myconf} --with-athena=next"
|
||||
else
|
||||
myconf="${myconf} --with-athena=xaw"
|
||||
fi
|
||||
|
||||
use dnd && myconf="${myconf} --with-dragndrop --with-offix"
|
||||
|
||||
myconf="${myconf} $(use_with tiff )"
|
||||
myconf="${myconf} $(use_with png )"
|
||||
myconf="${myconf} $(use_with jpeg )"
|
||||
myconf="${myconf} $(use_with xface )"
|
||||
|
||||
use xft && myconf="${myconf} --with-xft=emacs,tabs,menubars,gauges" ||
|
||||
myconf="${myconf} --with-xft=no"
|
||||
|
||||
else
|
||||
myconf="${myconf}
|
||||
--without-x
|
||||
--without-xpm
|
||||
--without-dragndrop
|
||||
--with-xft=no
|
||||
--with-gif=no"
|
||||
fi
|
||||
|
||||
if use mule ; then
|
||||
myconf="${myconf} --with-mule"
|
||||
|
||||
if use xim ; then
|
||||
if use motif ; then
|
||||
myconf="${myconf} --with-xim=motif"
|
||||
else
|
||||
myconf="${myconf} --with-xim=xlib"
|
||||
fi
|
||||
else
|
||||
myconf="${myconf} --with-xim=no"
|
||||
fi
|
||||
|
||||
myconf="${myconf} $(use_with canna )"
|
||||
myconf="${myconf} $(use_with freewnn wnn )"
|
||||
fi
|
||||
|
||||
# This determines the type of sounds we are playing
|
||||
local soundconf="native"
|
||||
|
||||
# This determines how these sounds should be played
|
||||
use nas && soundconf="${soundconf},nas"
|
||||
use alsa && soundconf="${soundconf},alsa"
|
||||
|
||||
myconf="${myconf} --with-sound=${soundconf}"
|
||||
|
||||
if use gdbm || use berkdb ; then
|
||||
use gdbm && mydb="gdbm"
|
||||
use berkdb && mydb="${mydb},berkdb"
|
||||
|
||||
myconf="${myconf} --with-database=${mydb}"
|
||||
else
|
||||
myconf="${myconf} --without-database"
|
||||
fi
|
||||
|
||||
use debug && myconf="${myconf} --with-debug" ||
|
||||
myconf="${myconf} --with-optimization"
|
||||
|
||||
econf ${myconf} \
|
||||
$(use_with gif ) \
|
||||
$(use_with gpm ) \
|
||||
$(use_with postgres postgresql ) \
|
||||
$(use_with ldap ) \
|
||||
$(use_with eolconv file-coding ) \
|
||||
$(use_with pop ) \
|
||||
--prefix=/usr \
|
||||
--with-ncurses \
|
||||
--with-msw=no \
|
||||
--with-mail-locking=flock \
|
||||
--with-site-lisp=yes \
|
||||
--with-site-modules=yes \
|
||||
--with-newgc \
|
||||
--enable-option-checking=no \
|
||||
--with-last-packages=/usr/lib/xemacs \
|
||||
|| die "configuration failed"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake EMACSLOADPATH="${S}"/lisp
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake prefix="${D}"/usr \
|
||||
mandir="${D}"/usr/share/man/man1 \
|
||||
infodir="${D}"/usr/share/info \
|
||||
libdir="${D}"/usr/$(get_libdir) \
|
||||
datadir="${D}"/usr/share \
|
||||
install || die
|
||||
|
||||
# Rename some applications installed in bin so that it is clear
|
||||
# which application installed them and so that conflicting
|
||||
# packages (emacs) can't clobber the actual applications.
|
||||
# Addresses bug #62991.
|
||||
for i in b2m ctags etags gnuclient gnudoit gnuattach; do
|
||||
mv "${D}"/usr/bin/${i} "${D}"/usr/bin/${i}-xemacs || die "mv ${i} failed"
|
||||
done
|
||||
|
||||
# rename man pages
|
||||
for i in ctags etags gnuserv gnuclient gnudoit gnuattach; do
|
||||
mv "${D}"/usr/share/man/man1/${i}{,-xemacs}.1 || die "mv ${i}.1 failed"
|
||||
done
|
||||
|
||||
# install base packages directories
|
||||
dodir /usr/lib/xemacs/xemacs-packages/
|
||||
dodir /usr/lib/xemacs/site-packages/
|
||||
dodir /usr/lib/xemacs/site-modules/
|
||||
dodir /usr/lib/xemacs/site-lisp/
|
||||
|
||||
if use mule;
|
||||
then
|
||||
dodir /usr/lib/xemacs/mule-packages
|
||||
fi
|
||||
|
||||
# remove extraneous info files
|
||||
cd "${D}"/usr/share/info
|
||||
rm -f dir info.info texinfo* termcap* standards*
|
||||
|
||||
cd "${S}"
|
||||
dodoc CHANGES-* ChangeLog INSTALL Installation PROBLEMS README*
|
||||
|
||||
newicon "${S}"/etc/${PN}-icon.xpm ${PN}.xpm
|
||||
|
||||
domenu "${FILESDIR}"/${PN}.desktop
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
eselect emacs update ifunset
|
||||
eselect gnuclient update ifunset
|
||||
|
||||
einfo "*************************************************"
|
||||
einfo "If you are upgrading from XEmacs 21.4 you should note the following"
|
||||
einfo "incompatibilities:"
|
||||
einfo "- Mule-UCS is no longer supported due to proper UTF-8 support in XEmacs 21.5"
|
||||
einfo "- The X resource class has changed from Emacs to XEmacs,"
|
||||
einfo " settings in your .Xdefaults file should be updated accordingly."
|
||||
|
||||
if use xft;
|
||||
then
|
||||
einfo "You have enabled Xft font support. Xft requires font names to be provided"
|
||||
einfo "in a different way, so you may need to adjust your .Xdefaults accordingly."
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
eselect emacs update ifunset
|
||||
eselect gnuclient update ifunset
|
||||
}
|
@ -0,0 +1,53 @@
|
||||
Important: The openrc libvirtd init script is now broken up into two
|
||||
separate services: libvirtd, that solely handles the daemon, and
|
||||
libvirt-guests, that takes care of clients during shutdown/restart of the
|
||||
host. In order to reenable client handling, edit /etc/conf.d/libvirt-guests
|
||||
and enable the service and start it:
|
||||
|
||||
$ rc-update add libvirt-guests
|
||||
$ service libvirt-guests start
|
||||
|
||||
|
||||
For the basic networking support (bridged and routed networks) you don't
|
||||
need any extra software. For more complex network modes including but not
|
||||
limited to NATed network, you can enable the 'virt-network' USE flag. It
|
||||
will pull in required runtime dependencies
|
||||
|
||||
|
||||
If you are using dnsmasq on your system, you will have to configure
|
||||
/etc/dnsmasq.conf to enable the following settings:
|
||||
|
||||
bind-interfaces
|
||||
interface or except-interface
|
||||
|
||||
Otherwise you might have issues with your existing DNS server.
|
||||
|
||||
|
||||
For openrc users:
|
||||
|
||||
Please use /etc/conf.d/libvirtd to control the '--listen' parameter for
|
||||
libvirtd.
|
||||
|
||||
Use /etc/init.d/libvirt-guests to manage clients on restart/shutdown of
|
||||
the host. The default configuration will suspend and resume running kvm
|
||||
guests with 'managedsave'. This behavior can be changed under
|
||||
/etc/conf.d/libvirt-guests
|
||||
|
||||
|
||||
For systemd users:
|
||||
|
||||
Please use /etc/systemd/system/libvirtd.service.d/00gentoo.conf
|
||||
to control the '--listen' parameter for libvirtd.
|
||||
|
||||
The configuration for the 'libvirt-guests.service' is found under
|
||||
/etc/libvirt/libvirt-guests.conf"
|
||||
|
||||
|
||||
If you have built libvirt without policykit support (USE=-policykit), you
|
||||
must change the unix sock group and/or perms in /etc/libvirt/libvirtd.conf
|
||||
in order to allow normal users to connect to libvirtd.
|
||||
|
||||
|
||||
If libvirtd is built with USE=caps, libvirt will now start qemu/kvm VMs
|
||||
with non-root privileges. Ensure any resources your VMs use are accessible
|
||||
by qemu:qemu.
|
@ -0,0 +1,134 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
inherit eutils multilib toolchain-funcs vcs-snapshot
|
||||
|
||||
DESCRIPTION="a lightweight PDF viewer and toolkit written in portable C"
|
||||
HOMEPAGE="http://mupdf.com/"
|
||||
SRC_URI="http://git.ghostscript.com/?p=mupdf.git;a=snapshot;h=987969ac033151810aade57d45c3d968dbf83d60;sf=tgz -> ${P}.tar.gz"
|
||||
|
||||
LICENSE="AGPL-3"
|
||||
MY_SOVER=1.7
|
||||
SLOT="0/${MY_SOVER}"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~ppc-macos ~x64-macos ~x86-macos"
|
||||
IUSE="X vanilla +curl javascript libressl +openssl static static-libs"
|
||||
|
||||
LIB_DEPEND="
|
||||
!libressl? ( dev-libs/openssl:0[static-libs?] )
|
||||
libressl? ( dev-libs/libressl[static-libs?] )
|
||||
media-libs/freetype:2[static-libs?]
|
||||
media-libs/jbig2dec[static-libs?]
|
||||
media-libs/openjpeg:2[static-libs?]
|
||||
net-misc/curl[static-libs?]
|
||||
virtual/jpeg[static-libs?]
|
||||
X? ( x11-libs/libX11[static-libs?]
|
||||
x11-libs/libXext[static-libs?] )
|
||||
javascript? ( dev-lang/mujs )"
|
||||
RDEPEND="${LIB_DEPEND}"
|
||||
DEPEND="${RDEPEND}
|
||||
virtual/pkgconfig
|
||||
static-libs? ( ${LIB_DEPEND} )
|
||||
static? ( ${LIB_DEPEND//?}
|
||||
app-arch/bzip2[static-libs]
|
||||
x11-libs/libXau[static-libs]
|
||||
x11-libs/libXdmcp[static-libs]
|
||||
x11-libs/libxcb[static-libs] )"
|
||||
|
||||
src_prepare() {
|
||||
rm -rf thirdparty || die
|
||||
|
||||
epatch \
|
||||
"${FILESDIR}"/${PN}-1.3-CFLAGS.patch \
|
||||
"${FILESDIR}"/${PN}-1.5-old-debian-files.patch \
|
||||
"${FILESDIR}"/${PN}-1.3-pkg-config.patch \
|
||||
"${FILESDIR}"/${PN}-1.5-Makerules-openssl-curl.patch \
|
||||
"${FILESDIR}"/${PN}-1.7a-system-mujs.patch
|
||||
|
||||
if has_version ">=media-libs/openjpeg-2.1:2" ; then
|
||||
epatch \
|
||||
"${FILESDIR}"/${PN}-1.5-openjpeg-2.1.patch
|
||||
fi
|
||||
|
||||
sed -e "/^libdir=/s:/lib:/$(get_libdir):" \
|
||||
-e "/^prefix=/s:=.*:=${EROOT}/usr:" \
|
||||
-i platform/debian/${PN}.pc || die
|
||||
|
||||
use vanilla || epatch \
|
||||
"${FILESDIR}"/${PN}-1.3-zoom-2.patch
|
||||
|
||||
#http://bugs.ghostscript.com/show_bug.cgi?id=693467
|
||||
sed -e '/^\(Actions\|MimeType\)=/s:\(.*\):\1;:' \
|
||||
-i platform/debian/${PN}.desktop || die
|
||||
|
||||
sed -e "1iOS = Linux" \
|
||||
-e "1iCC = $(tc-getCC)" \
|
||||
-e "1iLD = $(tc-getCC)" \
|
||||
-e "1iAR = $(tc-getAR)" \
|
||||
-e "1iverbose = yes" \
|
||||
-e "1ibuild = debug" \
|
||||
-e "1iprefix = ${ED}usr" \
|
||||
-e "1ilibdir = ${ED}usr/$(get_libdir)" \
|
||||
-e "1idocdir = ${ED}usr/share/doc/${PF}" \
|
||||
-e "1iHAVE_X11 = $(usex X)" \
|
||||
-e "1iWANT_OPENSSL = $(usex openssl)" \
|
||||
-e "1iWANT_CURL = $(usex curl)" \
|
||||
-e "1iHAVE_MUJS = $(usex javascript)" \
|
||||
-e "1iMUJS_LIBS = -lmujs" \
|
||||
-e "1iMUJS_CFLAGS =" \
|
||||
-i Makerules || die
|
||||
|
||||
if use static-libs || use static ; then
|
||||
cp -a "${S}" "${S}"-static || die
|
||||
#add missing Libs.private for xcb and freetype
|
||||
sed -e 's:\(pkg-config --libs\):\1 --static:' \
|
||||
-e '/^SYS_X11_LIBS = /s:\(.*\):\1 -lpthread:' \
|
||||
-e '/^SYS_FREETYPE_LIBS = /s:\(.*\):\1 -lbz2:' \
|
||||
-i "${S}"-static/Makerules || die
|
||||
fi
|
||||
|
||||
my_soname=libmupdf.so.${MY_SOVER}
|
||||
my_soname_js_none=libmupdf-js-none.so.${MY_SOVER}
|
||||
sed -e "\$a\$(MUPDF_LIB): \$(MUPDF_JS_NONE_LIB)" \
|
||||
-e "\$a\\\t\$(QUIET_LINK) \$(CC) \$(LDFLAGS) --shared -Wl,-soname -Wl,${my_soname} -Wl,--no-undefined -o \$@ \$^ \$(MUPDF_JS_NONE_LIB) \$(LIBS)" \
|
||||
-e "/^MUPDF_LIB :=/s:=.*:= \$(OUT)/${my_soname}:" \
|
||||
-e "\$a\$(MUPDF_JS_NONE_LIB):" \
|
||||
-e "\$a\\\t\$(QUIET_LINK) \$(CC) \$(LDFLAGS) --shared -Wl,-soname -Wl,${my_soname_js_none} -Wl,--no-undefined -o \$@ \$^ \$(LIBS)" \
|
||||
-e "/install/s: COPYING : :" \
|
||||
-i Makefile || die
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake XCFLAGS="-fpic"
|
||||
use static-libs && \
|
||||
emake -C "${S}"-static build/debug/lib${PN}{,-js-none}.a
|
||||
use static && \
|
||||
emake -C "${S}"-static XLIBS="-static"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
if use X ; then
|
||||
domenu platform/debian/${PN}.desktop
|
||||
doicon platform/debian/${PN}.xpm
|
||||
else
|
||||
rm docs/man/${PN}.1
|
||||
fi
|
||||
|
||||
emake install
|
||||
dosym ${my_soname} /usr/$(get_libdir)/lib${PN}.so
|
||||
|
||||
use static-libs && \
|
||||
dolib.a "${S}"-static/build/debug/lib${PN}{,-js-none}.a
|
||||
if use static ; then
|
||||
dobin "${S}"-static/build/debug/mu{tool,draw}
|
||||
use X && dobin "${S}"-static/build/debug/${PN}-x11
|
||||
fi
|
||||
use X && dosym ${PN}-x11 /usr/bin/${PN}
|
||||
|
||||
insinto /usr/$(get_libdir)/pkgconfig
|
||||
doins platform/debian/${PN}.pc
|
||||
|
||||
dodoc README docs/*.{txt,c}
|
||||
}
|
@ -0,0 +1,156 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
SCONS_MIN_VERSION="2.3.0"
|
||||
CHECKREQS_DISK_BUILD="2400M"
|
||||
CHECKREQS_DISK_USR="512M"
|
||||
CHECKREQS_MEMORY="1024M"
|
||||
|
||||
inherit eutils flag-o-matic multilib pax-utils scons-utils systemd user versionator check-reqs
|
||||
|
||||
MY_P=${PN}-src-r${PV/_rc/-rc}
|
||||
|
||||
DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
|
||||
HOMEPAGE="http://www.mongodb.org"
|
||||
SRC_URI="http://downloads.mongodb.org/src/${MY_P}.tar.gz"
|
||||
|
||||
LICENSE="AGPL-3 Apache-2.0"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="debug kerberos libressl mms-agent ssl +tools"
|
||||
|
||||
RDEPEND="app-arch/snappy
|
||||
>=dev-cpp/yaml-cpp-0.5.1
|
||||
>=dev-libs/boost-1.57[threads(+)]
|
||||
>=dev-libs/libpcre-8.30[cxx]
|
||||
dev-libs/snowball-stemmer
|
||||
net-libs/libpcap
|
||||
sys-libs/zlib
|
||||
mms-agent? ( app-admin/mms-agent )
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-1.0.1g:0= )
|
||||
libressl? ( dev-libs/libressl:= )
|
||||
)"
|
||||
DEPEND="${RDEPEND}
|
||||
>=sys-devel/gcc-4.8.2:*
|
||||
sys-libs/ncurses
|
||||
sys-libs/readline
|
||||
kerberos? ( dev-libs/cyrus-sasl[kerberos] )"
|
||||
PDEPEND="tools? ( >=app-admin/mongo-tools-${PV} )"
|
||||
|
||||
S=${WORKDIR}/${MY_P}
|
||||
|
||||
pkg_setup() {
|
||||
enewgroup mongodb
|
||||
enewuser mongodb -1 -1 /var/lib/${PN} mongodb
|
||||
|
||||
# Maintainer notes
|
||||
#
|
||||
# --use-system-tcmalloc is strongly NOT recommended:
|
||||
# https://www.mongodb.org/about/contributors/tutorial/build-mongodb-from-source/
|
||||
#
|
||||
# --c++11 is required by scons instead of auto detection:
|
||||
# https://jira.mongodb.org/browse/SERVER-19661
|
||||
|
||||
scons_opts="--variant-dir=build --cc=$(tc-getCC) --cxx=$(tc-getCXX) --c++11"
|
||||
scons_opts+=" --disable-warnings-as-errors"
|
||||
scons_opts+=" --use-system-boost"
|
||||
scons_opts+=" --use-system-pcre"
|
||||
scons_opts+=" --use-system-snappy"
|
||||
scons_opts+=" --use-system-stemmer"
|
||||
scons_opts+=" --use-system-yaml"
|
||||
|
||||
if use debug; then
|
||||
scons_opts+=" --dbg=on"
|
||||
fi
|
||||
|
||||
if use prefix; then
|
||||
scons_opts+=" --cpppath=${EPREFIX}/usr/include"
|
||||
scons_opts+=" --libpath=${EPREFIX}/usr/$(get_libdir)"
|
||||
fi
|
||||
|
||||
if use kerberos; then
|
||||
scons_opts+=" --use-sasl-client"
|
||||
fi
|
||||
|
||||
if use ssl; then
|
||||
scons_opts+=" --ssl"
|
||||
fi
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
epatch "${FILESDIR}/${PN}-3.0.0-fix-scons.patch"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
# respect mongoDB upstream's basic recommendations
|
||||
# see bug #536688 and #526114
|
||||
if ! use debug; then
|
||||
filter-flags '-m*'
|
||||
filter-flags '-O?'
|
||||
fi
|
||||
escons ${scons_opts} core tools
|
||||
}
|
||||
|
||||
src_install() {
|
||||
escons ${scons_opts} --nostrip install --prefix="${ED}"/usr
|
||||
|
||||
for x in /var/{lib,log}/${PN}; do
|
||||
keepdir "${x}"
|
||||
fowners mongodb:mongodb "${x}"
|
||||
done
|
||||
|
||||
doman debian/mongo*.1
|
||||
dodoc README docs/building.md
|
||||
|
||||
newinitd "${FILESDIR}/${PN}.initd-r2" ${PN}
|
||||
newconfd "${FILESDIR}/${PN}.confd-r2" ${PN}
|
||||
newinitd "${FILESDIR}/${PN/db/s}.initd-r2" ${PN/db/s}
|
||||
newconfd "${FILESDIR}/${PN/db/s}.confd-r2" ${PN/db/s}
|
||||
|
||||
insinto /etc
|
||||
newins "${FILESDIR}/${PN}.conf-r3" ${PN}.conf
|
||||
newins "${FILESDIR}/${PN/db/s}.conf-r2" ${PN/db/s}.conf
|
||||
|
||||
systemd_dounit "${FILESDIR}/${PN}.service"
|
||||
|
||||
insinto /etc/logrotate.d/
|
||||
newins "${FILESDIR}/${PN}.logrotate" ${PN}
|
||||
|
||||
# see bug #526114
|
||||
pax-mark emr "${ED}"/usr/bin/{mongo,mongod,mongos}
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
# wrt bug #461466
|
||||
if [[ "$(get_libdir)" == "lib64" ]]; then
|
||||
rmdir "${ED}"/usr/lib/ &>/dev/null
|
||||
fi
|
||||
}
|
||||
|
||||
src_test() {
|
||||
escons ${scons_opts} dbtest
|
||||
"${S}"/dbtest --dbpath=unittest || die "dbtest failed"
|
||||
escons ${scons_opts} smokeCppUnittests --smokedbprefix="smokecpptest" || die "smokeCppUnittests tests failed"
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
if [[ ${REPLACING_VERSIONS} < 3.0 ]]; then
|
||||
ewarn "!! IMPORTANT !!"
|
||||
ewarn " "
|
||||
ewarn "${PN} configuration files have changed !"
|
||||
ewarn " "
|
||||
ewarn "Make sure you migrate from /etc/conf.d/${PN} to the new YAML standard in /etc/${PN}.conf"
|
||||
ewarn " http://docs.mongodb.org/manual/reference/configuration-options/"
|
||||
ewarn " "
|
||||
ewarn "Make sure you also follow the upgrading process :"
|
||||
ewarn " http://docs.mongodb.org/master/release-notes/3.0-upgrade/"
|
||||
ewarn " "
|
||||
ewarn "MongoDB 3.0 introduces the WiredTiger storage engine."
|
||||
ewarn "WiredTiger is incompatible with MMAPv1 and you need to dump/reload your data if you want to use it."
|
||||
ewarn "Once you have your data dumped, you need to set storage.engine: wiredTiger in /etc/${PN}.conf"
|
||||
ewarn " http://docs.mongodb.org/master/release-notes/3.0-upgrade/#change-storage-engine-to-wiredtiger"
|
||||
fi
|
||||
}
|
@ -0,0 +1,374 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
# Testing within Portage's environment is broken, and the patch no
|
||||
# longer applies cleanly.
|
||||
RESTRICT="test"
|
||||
|
||||
PYTHON_COMPAT=( python{2_7,3_4} )
|
||||
|
||||
inherit eutils flag-o-matic linux-info multilib pam prefix python-single-r1 \
|
||||
systemd user versionator
|
||||
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~ppc-macos ~x86-solaris"
|
||||
|
||||
SLOT="$(get_version_component_range 1-2)"
|
||||
|
||||
SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2"
|
||||
|
||||
LICENSE="POSTGRESQL GPL-2"
|
||||
DESCRIPTION="PostgreSQL RDBMS"
|
||||
HOMEPAGE="http://www.postgresql.org/"
|
||||
|
||||
LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr
|
||||
zh_CN zh_TW"
|
||||
IUSE="doc kerberos kernel_linux ldap libressl nls pam perl -pg_legacytimestamp python
|
||||
+readline selinux +server ssl static-libs tcl threads uuid xml zlib"
|
||||
|
||||
for lingua in ${LINGUAS}; do
|
||||
IUSE+=" linguas_${lingua}"
|
||||
done
|
||||
|
||||
wanted_languages() {
|
||||
local enable_langs
|
||||
|
||||
for lingua in ${LINGUAS} ; do
|
||||
use linguas_${lingua} && enable_langs+="${lingua} "
|
||||
done
|
||||
|
||||
echo -n ${enable_langs}
|
||||
}
|
||||
|
||||
CDEPEND="
|
||||
>=app-eselect/eselect-postgresql-1.2.0
|
||||
sys-apps/less
|
||||
virtual/libintl
|
||||
kerberos? ( virtual/krb5 )
|
||||
ldap? ( net-nds/openldap )
|
||||
pam? ( virtual/pam )
|
||||
perl? ( >=dev-lang/perl-5.8 )
|
||||
python? ( ${PYTHON_DEPS} )
|
||||
readline? ( sys-libs/readline:0= )
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6-r1:0= )
|
||||
libressl? ( dev-libs/libressl:= )
|
||||
)
|
||||
tcl? ( >=dev-lang/tcl-8:0= )
|
||||
uuid? ( dev-libs/ossp-uuid )
|
||||
xml? ( dev-libs/libxml2 dev-libs/libxslt )
|
||||
zlib? ( sys-libs/zlib )
|
||||
"
|
||||
|
||||
DEPEND="${CDEPEND}
|
||||
!!<sys-apps/sandbox-2.0
|
||||
sys-devel/bison
|
||||
sys-devel/flex
|
||||
nls? ( sys-devel/gettext )
|
||||
xml? ( virtual/pkgconfig )
|
||||
"
|
||||
|
||||
RDEPEND="${CDEPEND}
|
||||
!dev-db/postgresql-docs:${SLOT}
|
||||
!dev-db/postgresql-base:${SLOT}
|
||||
!dev-db/postgresql-server:${SLOT}
|
||||
selinux? ( sec-policy/selinux-postgresql )
|
||||
"
|
||||
|
||||
pkg_setup() {
|
||||
use server && CONFIG_CHECK="~SYSVIPC" linux-info_pkg_setup
|
||||
|
||||
enewgroup postgres 70
|
||||
enewuser postgres 70 /bin/sh /var/lib/postgresql postgres
|
||||
|
||||
use python && python-single-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Work around PPC{,64} compilation bug where bool is already defined
|
||||
sed '/#ifndef __cplusplus/a #undef bool' -i src/include/c.h || die
|
||||
|
||||
# Set proper run directory
|
||||
sed "s|\(PGSOCKET_DIR\s\+\)\"/tmp\"|\1\"${EPREFIX}/run/postgresql\"|" \
|
||||
-i src/include/pg_config_manual.h || die
|
||||
|
||||
epatch "${FILESDIR}/pg_ctl-exit-status.patch"
|
||||
|
||||
use server || epatch "${FILESDIR}/${PN}-${SLOT}-no-server.patch"
|
||||
|
||||
if use pam ; then
|
||||
sed -e "s/\(#define PGSQL_PAM_SERVICE \"postgresql\)/\1-${SLOT}/" \
|
||||
-i src/backend/libpq/auth.c || \
|
||||
die 'PGSQL_PAM_SERVICE rename failed.'
|
||||
fi
|
||||
|
||||
epatch_user
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
case ${CHOST} in
|
||||
*-darwin*|*-solaris*)
|
||||
use nls && append-libs intl
|
||||
;;
|
||||
esac
|
||||
|
||||
export LDFLAGS_SL="${LDFLAGS}"
|
||||
export LDFLAGS_EX="${LDFLAGS}"
|
||||
|
||||
local PO="${EPREFIX%/}"
|
||||
|
||||
econf \
|
||||
--prefix="${PO}/usr/$(get_libdir)/postgresql-${SLOT}" \
|
||||
--datadir="${PO}/usr/share/postgresql-${SLOT}" \
|
||||
--docdir="${PO}/usr/share/doc/${PF}" \
|
||||
--includedir="${PO}/usr/include/postgresql-${SLOT}" \
|
||||
--mandir="${PO}/usr/share/postgresql-${SLOT}/man" \
|
||||
--sysconfdir="${PO}/etc/postgresql-${SLOT}" \
|
||||
--with-system-tzdata="${PO}/usr/share/zoneinfo" \
|
||||
$(use_enable !pg_legacytimestamp integer-datetimes) \
|
||||
$(use_enable threads thread-safety) \
|
||||
$(use_with kerberos gssapi) \
|
||||
$(use_with kerberos krb5) \
|
||||
$(use_with ldap) \
|
||||
$(use_with pam) \
|
||||
$(use_with perl) \
|
||||
$(use_with python) \
|
||||
$(use_with readline) \
|
||||
$(use_with ssl openssl) \
|
||||
$(use_with tcl) \
|
||||
$(use_with uuid ossp-uuid) \
|
||||
$(use_with xml libxml) \
|
||||
$(use_with xml libxslt) \
|
||||
$(use_with zlib) \
|
||||
"$(use_enable nls nls "$(wanted_languages)")"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake
|
||||
emake -C contrib
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install
|
||||
emake DESTDIR="${D}" install -C contrib
|
||||
|
||||
dodoc README HISTORY doc/{TODO,bug.template}
|
||||
|
||||
# man pages are already built, but if we have the target make them,
|
||||
# they'll be generated from source before being installed so we
|
||||
# manually install man pages.
|
||||
# We use ${SLOT} instead of doman for postgresql.eselect
|
||||
insinto /usr/share/postgresql-${SLOT}/man/
|
||||
doins -r doc/src/sgml/man{1,3,7}
|
||||
if ! use server; then
|
||||
# Remove man pages for non-existent binaries
|
||||
for m in {initdb,pg_{controldata,ctl,resetxlog},post{gres,master}}; do
|
||||
rm "${ED}/usr/share/postgresql-${SLOT}/man/man1/${m}.1"
|
||||
done
|
||||
fi
|
||||
docompress /usr/share/postgresql-${SLOT}/man/man{1,3,7}
|
||||
|
||||
insinto /etc/postgresql-${SLOT}
|
||||
newins src/bin/psql/psqlrc.sample psqlrc
|
||||
|
||||
dodir /etc/eselect/postgresql/slots/${SLOT}
|
||||
echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" > \
|
||||
"${ED}/etc/eselect/postgresql/slots/${SLOT}/base"
|
||||
|
||||
use static-libs || find "${ED}" -name '*.a' -delete
|
||||
|
||||
if use doc ; then
|
||||
docinto html
|
||||
dodoc doc/src/sgml/html/*
|
||||
|
||||
docinto sgml
|
||||
dodoc doc/src/sgml/*.{sgml,dsl}
|
||||
fi
|
||||
|
||||
if use server; then
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.confd" | newconfd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.init-pre_9.2" | newinitd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.service" | \
|
||||
systemd_newunit - ${PN}-${SLOT}.service
|
||||
|
||||
systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf
|
||||
|
||||
newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir
|
||||
|
||||
use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session
|
||||
|
||||
if use prefix ; then
|
||||
keepdir /run/postgresql
|
||||
fperms 0775 /run/postgresql
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
postgresql-config update
|
||||
|
||||
elog "If you need a global psqlrc-file, you can place it in:"
|
||||
elog " ${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
|
||||
if use server ; then
|
||||
elog
|
||||
elog "Gentoo specific documentation:"
|
||||
elog "https://wiki.gentoo.org/wiki/PostgreSQL"
|
||||
elog
|
||||
elog "Official documentation:"
|
||||
elog "http://www.postgresql.org/docs/${SLOT}/static/index.html"
|
||||
elog
|
||||
elog "The default location of the Unix-domain socket is:"
|
||||
elog " ${EROOT%/}/run/postgresql/"
|
||||
elog
|
||||
elog "Before initializing the database, you may want to edit PG_INITDB_OPTS"
|
||||
elog "so that it contains your preferred locale in:"
|
||||
elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
elog
|
||||
elog "Then, execute the following command to setup the initial database"
|
||||
elog "environment:"
|
||||
elog " emerge --config =${CATEGORY}/${PF}"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_prerm() {
|
||||
if use server && [[ -z ${REPLACED_BY_VERSION} ]] ; then
|
||||
ewarn "Have you dumped and/or migrated the ${SLOT} database cluster?"
|
||||
ewarn "\thttps://wiki.gentoo.org/wiki/PostgreSQL/QuickStart#Migrating_PostgreSQL"
|
||||
|
||||
ebegin "Resuming removal in 10 seconds (Control-C to cancel)"
|
||||
sleep 10
|
||||
eend 0
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
postgresql-config update
|
||||
}
|
||||
|
||||
pkg_config() {
|
||||
use server || die "USE flag 'server' not enabled. Nothing to configure."
|
||||
|
||||
[[ -f "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" ]] \
|
||||
&& source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
[[ -z "${PGDATA}" ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
[[ -z "${DATA_DIR}" ]] \
|
||||
&& DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data"
|
||||
|
||||
# environment.bz2 may not contain the same locale as the current system
|
||||
# locale. Unset and source from the current system locale.
|
||||
if [ -f "${EROOT%/}/etc/env.d/02locale" ]; then
|
||||
unset LANG
|
||||
unset LC_CTYPE
|
||||
unset LC_NUMERIC
|
||||
unset LC_TIME
|
||||
unset LC_COLLATE
|
||||
unset LC_MONETARY
|
||||
unset LC_MESSAGES
|
||||
unset LC_ALL
|
||||
source "${EROOT%/}/etc/env.d/02locale"
|
||||
[ -n "${LANG}" ] && export LANG
|
||||
[ -n "${LC_CTYPE}" ] && export LC_CTYPE
|
||||
[ -n "${LC_NUMERIC}" ] && export LC_NUMERIC
|
||||
[ -n "${LC_TIME}" ] && export LC_TIME
|
||||
[ -n "${LC_COLLATE}" ] && export LC_COLLATE
|
||||
[ -n "${LC_MONETARY}" ] && export LC_MONETARY
|
||||
[ -n "${LC_MESSAGES}" ] && export LC_MESSAGES
|
||||
[ -n "${LC_ALL}" ] && export LC_ALL
|
||||
fi
|
||||
|
||||
einfo "You can modify the paths and options passed to initdb by editing:"
|
||||
einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
einfo
|
||||
einfo "Information on options that can be passed to initdb are found at:"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html"
|
||||
einfo
|
||||
einfo "PG_INITDB_OPTS is currently set to:"
|
||||
if [[ -z "${PG_INITDB_OPTS}" ]] ; then
|
||||
einfo " (none)"
|
||||
else
|
||||
einfo " ${PG_INITDB_OPTS}"
|
||||
fi
|
||||
einfo
|
||||
einfo "Configuration files will be installed to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo
|
||||
einfo "The database cluster will be created in:"
|
||||
einfo " ${DATA_DIR}"
|
||||
einfo
|
||||
while [ "$correct" != "true" ] ; do
|
||||
einfo "Are you ready to continue? (y/n)"
|
||||
read answer
|
||||
if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then
|
||||
correct="true"
|
||||
elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then
|
||||
die "Aborting initialization."
|
||||
else
|
||||
echo "Answer not recognized"
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ] ; then
|
||||
eerror "The given directory, '${DATA_DIR}', is not empty."
|
||||
eerror "Modify DATA_DIR to point to an empty directory."
|
||||
die "${DATA_DIR} is not empty."
|
||||
fi
|
||||
|
||||
einfo "Creating the data directory ..."
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
mkdir -p "${DATA_DIR}"
|
||||
chown -Rf postgres:postgres "${DATA_DIR}"
|
||||
chmod 0700 "${DATA_DIR}"
|
||||
fi
|
||||
|
||||
einfo "Initializing the database ..."
|
||||
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}"
|
||||
else
|
||||
"${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS}
|
||||
fi
|
||||
|
||||
if [[ "${DATA_DIR%/}" != "${PGDATA%/}" ]] ; then
|
||||
mv "${DATA_DIR%/}"/{pg_{hba,ident},postgresql}.conf "${PGDATA}"
|
||||
ln -s "${PGDATA%/}"/{pg_{hba,ident},postgresql}.conf "${DATA_DIR%/}"
|
||||
fi
|
||||
|
||||
cat <<- EOF >> "${PGDATA%/}"/postgresql.conf
|
||||
# This is here because of https://bugs.gentoo.org/show_bug.cgi?id=518522
|
||||
# On the off-chance that you might need to work with UTF-8 encoded
|
||||
# characters in PL/Perl
|
||||
plperl.on_init = 'use utf8; use re; package utf8; require "utf8_heavy.pl";'
|
||||
EOF
|
||||
|
||||
einfo "The autovacuum function, which was in contrib, has been moved to the main"
|
||||
einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled"
|
||||
einfo "by default. You can disable it in the cluster's:"
|
||||
einfo " ${PGDATA%/}/postgresql.conf"
|
||||
einfo
|
||||
einfo "The PostgreSQL server, by default, will log events to:"
|
||||
einfo " ${DATA_DIR%/}/postmaster.log"
|
||||
einfo
|
||||
if use prefix ; then
|
||||
einfo "The location of the configuration files have moved to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo "To start the server:"
|
||||
einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'"
|
||||
einfo "To stop:"
|
||||
einfo " pg_ctl stop -D ${DATA_DIR}"
|
||||
einfo
|
||||
einfo "Or move the configuration files back:"
|
||||
einfo "mv ${PGDATA}*.conf ${DATA_DIR}"
|
||||
else
|
||||
einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL"
|
||||
einfo "instead of 'pg_ctl'."
|
||||
fi
|
||||
}
|
@ -0,0 +1,378 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
# Testing within Portage's environment is broken, and the patch no
|
||||
# longer applies cleanly.
|
||||
RESTRICT="test"
|
||||
|
||||
PYTHON_COMPAT=( python{2_7,3_4} )
|
||||
|
||||
inherit eutils flag-o-matic linux-info multilib pam prefix python-single-r1 \
|
||||
systemd user versionator
|
||||
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~ppc-macos ~x86-solaris"
|
||||
|
||||
SLOT="$(get_version_component_range 1-2)"
|
||||
|
||||
SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2"
|
||||
|
||||
LICENSE="POSTGRESQL GPL-2"
|
||||
DESCRIPTION="PostgreSQL RDBMS"
|
||||
HOMEPAGE="http://www.postgresql.org/"
|
||||
|
||||
LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr
|
||||
zh_CN zh_TW"
|
||||
IUSE="doc kerberos kernel_linux ldap libressl nls pam perl -pg_legacytimestamp python
|
||||
+readline selinux +server ssl static-libs tcl threads uuid xml zlib"
|
||||
|
||||
for lingua in ${LINGUAS}; do
|
||||
IUSE+=" linguas_${lingua}"
|
||||
done
|
||||
|
||||
wanted_languages() {
|
||||
local enable_langs
|
||||
|
||||
for lingua in ${LINGUAS} ; do
|
||||
use linguas_${lingua} && enable_langs+="${lingua} "
|
||||
done
|
||||
|
||||
echo -n ${enable_langs}
|
||||
}
|
||||
|
||||
CDEPEND="
|
||||
>=app-eselect/eselect-postgresql-1.2.0
|
||||
sys-apps/less
|
||||
virtual/libintl
|
||||
kerberos? ( virtual/krb5 )
|
||||
ldap? ( net-nds/openldap )
|
||||
pam? ( virtual/pam )
|
||||
perl? ( >=dev-lang/perl-5.8 )
|
||||
python? ( ${PYTHON_DEPS} )
|
||||
readline? ( sys-libs/readline:0= )
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6-r1:0= )
|
||||
libressl? ( dev-libs/libressl:= )
|
||||
)
|
||||
tcl? ( >=dev-lang/tcl-8:0= )
|
||||
uuid? ( dev-libs/ossp-uuid )
|
||||
xml? ( dev-libs/libxml2 dev-libs/libxslt )
|
||||
zlib? ( sys-libs/zlib )
|
||||
"
|
||||
|
||||
DEPEND="${CDEPEND}
|
||||
!!<sys-apps/sandbox-2.0
|
||||
sys-devel/bison
|
||||
sys-devel/flex
|
||||
nls? ( sys-devel/gettext )
|
||||
xml? ( virtual/pkgconfig )
|
||||
"
|
||||
|
||||
RDEPEND="${CDEPEND}
|
||||
!dev-db/postgresql-docs:${SLOT}
|
||||
!dev-db/postgresql-base:${SLOT}
|
||||
!dev-db/postgresql-server:${SLOT}
|
||||
selinux? ( sec-policy/selinux-postgresql )
|
||||
"
|
||||
|
||||
pkg_setup() {
|
||||
use server && CONFIG_CHECK="~SYSVIPC" linux-info_pkg_setup
|
||||
|
||||
enewgroup postgres 70
|
||||
enewuser postgres 70 /bin/sh /var/lib/postgresql postgres
|
||||
|
||||
use python && python-single-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Work around PPC{,64} compilation bug where bool is already defined
|
||||
sed '/#ifndef __cplusplus/a #undef bool' -i src/include/c.h || die
|
||||
|
||||
# Set proper run directory
|
||||
sed "s|\(PGSOCKET_DIR\s\+\)\"/tmp\"|\1\"${EPREFIX}/run/postgresql\"|" \
|
||||
-i src/include/pg_config_manual.h || die
|
||||
|
||||
epatch "${FILESDIR}/pg_ctl-exit-status.patch"
|
||||
|
||||
use server || epatch "${FILESDIR}/${PN}-${SLOT}-no-server.patch"
|
||||
|
||||
# Fix bug 486556 where the server would crash at start up because of
|
||||
# an infinite loop caused by a self-referencing symlink.
|
||||
epatch "${FILESDIR}/postgresql-9.1-tz-dir-overflow.patch"
|
||||
|
||||
if use pam ; then
|
||||
sed -e "s/\(#define PGSQL_PAM_SERVICE \"postgresql\)/\1-${SLOT}/" \
|
||||
-i src/backend/libpq/auth.c || \
|
||||
die 'PGSQL_PAM_SERVICE rename failed.'
|
||||
fi
|
||||
|
||||
epatch_user
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
case ${CHOST} in
|
||||
*-darwin*|*-solaris*)
|
||||
use nls && append-libs intl
|
||||
;;
|
||||
esac
|
||||
|
||||
export LDFLAGS_SL="${LDFLAGS}"
|
||||
export LDFLAGS_EX="${LDFLAGS}"
|
||||
|
||||
local PO="${EPREFIX%/}"
|
||||
|
||||
econf \
|
||||
--prefix="${PO}/usr/$(get_libdir)/postgresql-${SLOT}" \
|
||||
--datadir="${PO}/usr/share/postgresql-${SLOT}" \
|
||||
--docdir="${PO}/usr/share/doc/${PF}" \
|
||||
--includedir="${PO}/usr/include/postgresql-${SLOT}" \
|
||||
--mandir="${PO}/usr/share/postgresql-${SLOT}/man" \
|
||||
--sysconfdir="${PO}/etc/postgresql-${SLOT}" \
|
||||
--with-system-tzdata="${PO}/usr/share/zoneinfo" \
|
||||
$(use_enable !pg_legacytimestamp integer-datetimes) \
|
||||
$(use_enable threads thread-safety) \
|
||||
$(use_with kerberos gssapi) \
|
||||
$(use_with kerberos krb5) \
|
||||
$(use_with ldap) \
|
||||
$(use_with pam) \
|
||||
$(use_with perl) \
|
||||
$(use_with python) \
|
||||
$(use_with readline) \
|
||||
$(use_with ssl openssl) \
|
||||
$(use_with tcl) \
|
||||
$(use_with uuid ossp-uuid) \
|
||||
$(use_with xml libxml) \
|
||||
$(use_with xml libxslt) \
|
||||
$(use_with zlib) \
|
||||
"$(use_enable nls nls "$(wanted_languages)")"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake
|
||||
emake -C contrib
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install
|
||||
emake DESTDIR="${D}" install -C contrib
|
||||
|
||||
dodoc README HISTORY doc/{TODO,bug.template}
|
||||
|
||||
# man pages are already built, but if we have the target make them,
|
||||
# they'll be generated from source before being installed so we
|
||||
# manually install man pages.
|
||||
# We use ${SLOT} instead of doman for postgresql.eselect
|
||||
insinto /usr/share/postgresql-${SLOT}/man/
|
||||
doins -r doc/src/sgml/man{1,3,7}
|
||||
if ! use server; then
|
||||
# Remove man pages for non-existent binaries
|
||||
for m in {initdb,pg_{controldata,ctl,resetxlog},post{gres,master}}; do
|
||||
rm "${ED}/usr/share/postgresql-${SLOT}/man/man1/${m}.1"
|
||||
done
|
||||
fi
|
||||
docompress /usr/share/postgresql-${SLOT}/man/man{1,3,7}
|
||||
|
||||
insinto /etc/postgresql-${SLOT}
|
||||
newins src/bin/psql/psqlrc.sample psqlrc
|
||||
|
||||
dodir /etc/eselect/postgresql/slots/${SLOT}
|
||||
echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" > \
|
||||
"${ED}/etc/eselect/postgresql/slots/${SLOT}/base"
|
||||
|
||||
use static-libs || find "${ED}" -name '*.a' -delete
|
||||
|
||||
if use doc ; then
|
||||
docinto html
|
||||
dodoc doc/src/sgml/html/*
|
||||
|
||||
docinto sgml
|
||||
dodoc doc/src/sgml/*.{sgml,dsl}
|
||||
fi
|
||||
|
||||
if use server; then
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.confd" | newconfd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.init-pre_9.2" | newinitd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.service" | \
|
||||
systemd_newunit - ${PN}-${SLOT}.service
|
||||
|
||||
systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf
|
||||
|
||||
newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir
|
||||
|
||||
use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session
|
||||
|
||||
if use prefix ; then
|
||||
keepdir /run/postgresql
|
||||
fperms 0775 /run/postgresql
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
postgresql-config update
|
||||
|
||||
elog "If you need a global psqlrc-file, you can place it in:"
|
||||
elog " ${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
|
||||
if use server ; then
|
||||
elog
|
||||
elog "Gentoo specific documentation:"
|
||||
elog "https://wiki.gentoo.org/wiki/PostgreSQL"
|
||||
elog
|
||||
elog "Official documentation:"
|
||||
elog "http://www.postgresql.org/docs/${SLOT}/static/index.html"
|
||||
elog
|
||||
elog "The default location of the Unix-domain socket is:"
|
||||
elog " ${EROOT%/}/run/postgresql/"
|
||||
elog
|
||||
elog "Before initializing the database, you may want to edit PG_INITDB_OPTS"
|
||||
elog "so that it contains your preferred locale in:"
|
||||
elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
elog
|
||||
elog "Then, execute the following command to setup the initial database"
|
||||
elog "environment:"
|
||||
elog " emerge --config =${CATEGORY}/${PF}"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_prerm() {
|
||||
if use server && [[ -z ${REPLACED_BY_VERSION} ]] ; then
|
||||
ewarn "Have you dumped and/or migrated the ${SLOT} database cluster?"
|
||||
ewarn "\thttps://wiki.gentoo.org/wiki/PostgreSQL/QuickStart#Migrating_PostgreSQL"
|
||||
|
||||
ebegin "Resuming removal in 10 seconds (Control-C to cancel)"
|
||||
sleep 10
|
||||
eend 0
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
postgresql-config update
|
||||
}
|
||||
|
||||
pkg_config() {
|
||||
use server || die "USE flag 'server' not enabled. Nothing to configure."
|
||||
|
||||
[[ -f "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" ]] \
|
||||
&& source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
[[ -z "${PGDATA}" ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
[[ -z "${DATA_DIR}" ]] \
|
||||
&& DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data"
|
||||
|
||||
# environment.bz2 may not contain the same locale as the current system
|
||||
# locale. Unset and source from the current system locale.
|
||||
if [ -f "${EROOT%/}/etc/env.d/02locale" ]; then
|
||||
unset LANG
|
||||
unset LC_CTYPE
|
||||
unset LC_NUMERIC
|
||||
unset LC_TIME
|
||||
unset LC_COLLATE
|
||||
unset LC_MONETARY
|
||||
unset LC_MESSAGES
|
||||
unset LC_ALL
|
||||
source "${EROOT%/}/etc/env.d/02locale"
|
||||
[ -n "${LANG}" ] && export LANG
|
||||
[ -n "${LC_CTYPE}" ] && export LC_CTYPE
|
||||
[ -n "${LC_NUMERIC}" ] && export LC_NUMERIC
|
||||
[ -n "${LC_TIME}" ] && export LC_TIME
|
||||
[ -n "${LC_COLLATE}" ] && export LC_COLLATE
|
||||
[ -n "${LC_MONETARY}" ] && export LC_MONETARY
|
||||
[ -n "${LC_MESSAGES}" ] && export LC_MESSAGES
|
||||
[ -n "${LC_ALL}" ] && export LC_ALL
|
||||
fi
|
||||
|
||||
einfo "You can modify the paths and options passed to initdb by editing:"
|
||||
einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
einfo
|
||||
einfo "Information on options that can be passed to initdb are found at:"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html"
|
||||
einfo
|
||||
einfo "PG_INITDB_OPTS is currently set to:"
|
||||
if [[ -z "${PG_INITDB_OPTS}" ]] ; then
|
||||
einfo " (none)"
|
||||
else
|
||||
einfo " ${PG_INITDB_OPTS}"
|
||||
fi
|
||||
einfo
|
||||
einfo "Configuration files will be installed to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo
|
||||
einfo "The database cluster will be created in:"
|
||||
einfo " ${DATA_DIR}"
|
||||
einfo
|
||||
while [ "$correct" != "true" ] ; do
|
||||
einfo "Are you ready to continue? (y/n)"
|
||||
read answer
|
||||
if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then
|
||||
correct="true"
|
||||
elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then
|
||||
die "Aborting initialization."
|
||||
else
|
||||
echo "Answer not recognized"
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ] ; then
|
||||
eerror "The given directory, '${DATA_DIR}', is not empty."
|
||||
eerror "Modify DATA_DIR to point to an empty directory."
|
||||
die "${DATA_DIR} is not empty."
|
||||
fi
|
||||
|
||||
einfo "Creating the data directory ..."
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
mkdir -p "${DATA_DIR}"
|
||||
chown -Rf postgres:postgres "${DATA_DIR}"
|
||||
chmod 0700 "${DATA_DIR}"
|
||||
fi
|
||||
|
||||
einfo "Initializing the database ..."
|
||||
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}"
|
||||
else
|
||||
"${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS}
|
||||
fi
|
||||
|
||||
if [[ "${DATA_DIR%/}" != "${PGDATA%/}" ]] ; then
|
||||
mv "${DATA_DIR%/}"/{pg_{hba,ident},postgresql}.conf "${PGDATA}"
|
||||
ln -s "${PGDATA%/}"/{pg_{hba,ident},postgresql}.conf "${DATA_DIR%/}"
|
||||
fi
|
||||
|
||||
cat <<- EOF >> "${PGDATA%/}"/postgresql.conf
|
||||
# This is here because of https://bugs.gentoo.org/show_bug.cgi?id=518522
|
||||
# On the off-chance that you might need to work with UTF-8 encoded
|
||||
# characters in PL/Perl
|
||||
plperl.on_init = 'use utf8; use re; package utf8; require "utf8_heavy.pl";'
|
||||
EOF
|
||||
|
||||
einfo "The autovacuum function, which was in contrib, has been moved to the main"
|
||||
einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled"
|
||||
einfo "by default. You can disable it in the cluster's:"
|
||||
einfo " ${PGDATA%/}/postgresql.conf"
|
||||
einfo
|
||||
einfo "The PostgreSQL server, by default, will log events to:"
|
||||
einfo " ${DATA_DIR%/}/postmaster.log"
|
||||
einfo
|
||||
if use prefix ; then
|
||||
einfo "The location of the configuration files have moved to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo "To start the server:"
|
||||
einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'"
|
||||
einfo "To stop:"
|
||||
einfo " pg_ctl stop -D ${DATA_DIR}"
|
||||
einfo
|
||||
einfo "Or move the configuration files back:"
|
||||
einfo "mv ${PGDATA}*.conf ${DATA_DIR}"
|
||||
else
|
||||
einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL"
|
||||
einfo "instead of 'pg_ctl'."
|
||||
fi
|
||||
}
|
@ -0,0 +1,390 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
PYTHON_COMPAT=( python{2_7,3_4} )
|
||||
|
||||
inherit eutils flag-o-matic linux-info multilib pam prefix python-single-r1 \
|
||||
systemd user versionator
|
||||
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~ppc-macos ~x86-solaris"
|
||||
|
||||
SLOT="$(get_version_component_range 1-2)"
|
||||
|
||||
SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2"
|
||||
|
||||
LICENSE="POSTGRESQL GPL-2"
|
||||
DESCRIPTION="PostgreSQL RDBMS"
|
||||
HOMEPAGE="http://www.postgresql.org/"
|
||||
|
||||
LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr
|
||||
zh_CN zh_TW"
|
||||
IUSE="doc kerberos kernel_linux ldap libressl nls pam perl -pg_legacytimestamp python
|
||||
+readline selinux +server ssl static-libs tcl threads uuid xml zlib"
|
||||
|
||||
for lingua in ${LINGUAS}; do
|
||||
IUSE+=" linguas_${lingua}"
|
||||
done
|
||||
|
||||
wanted_languages() {
|
||||
local enable_langs
|
||||
|
||||
for lingua in ${LINGUAS} ; do
|
||||
use linguas_${lingua} && enable_langs+="${lingua} "
|
||||
done
|
||||
|
||||
echo -n ${enable_langs}
|
||||
}
|
||||
|
||||
CDEPEND="
|
||||
>=app-eselect/eselect-postgresql-1.2.0
|
||||
sys-apps/less
|
||||
virtual/libintl
|
||||
kerberos? ( virtual/krb5 )
|
||||
ldap? ( net-nds/openldap )
|
||||
pam? ( virtual/pam )
|
||||
perl? ( >=dev-lang/perl-5.8 )
|
||||
python? ( ${PYTHON_DEPS} )
|
||||
readline? ( sys-libs/readline:0= )
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6-r1:0= )
|
||||
libressl? ( dev-libs/libressl:= )
|
||||
)
|
||||
tcl? ( >=dev-lang/tcl-8:0= )
|
||||
uuid? ( dev-libs/ossp-uuid )
|
||||
xml? ( dev-libs/libxml2 dev-libs/libxslt )
|
||||
zlib? ( sys-libs/zlib )
|
||||
"
|
||||
|
||||
DEPEND="${CDEPEND}
|
||||
!!<sys-apps/sandbox-2.0
|
||||
sys-devel/bison
|
||||
sys-devel/flex
|
||||
nls? ( sys-devel/gettext )
|
||||
xml? ( virtual/pkgconfig )
|
||||
"
|
||||
|
||||
RDEPEND="${CDEPEND}
|
||||
!dev-db/postgresql-docs:${SLOT}
|
||||
!dev-db/postgresql-base:${SLOT}
|
||||
!dev-db/postgresql-server:${SLOT}
|
||||
selinux? ( sec-policy/selinux-postgresql )
|
||||
"
|
||||
|
||||
pkg_setup() {
|
||||
use server && CONFIG_CHECK="~SYSVIPC" linux-info_pkg_setup
|
||||
|
||||
enewgroup postgres 70
|
||||
enewuser postgres 70 /bin/sh /var/lib/postgresql postgres
|
||||
|
||||
use python && python-single-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Work around PPC{,64} compilation bug where bool is already defined
|
||||
sed '/#ifndef __cplusplus/a #undef bool' -i src/include/c.h || die
|
||||
|
||||
# Set proper run directory
|
||||
sed "s|\(PGSOCKET_DIR\s\+\)\"/tmp\"|\1\"${EPREFIX}/run/postgresql\"|" \
|
||||
-i src/include/pg_config_manual.h || die
|
||||
|
||||
use server || epatch "${FILESDIR}/${PN}-${SLOT}-no-server.patch"
|
||||
|
||||
# Fix bug 486556 where the server would crash at start up because of
|
||||
# an infinite loop caused by a self-referencing symlink.
|
||||
epatch "${FILESDIR}/postgresql-9.2-9.4-tz-dir-overflow.patch"
|
||||
|
||||
if use pam ; then
|
||||
sed -e "s/\(#define PGSQL_PAM_SERVICE \"postgresql\)/\1-${SLOT}/" \
|
||||
-i src/backend/libpq/auth.c || \
|
||||
die 'PGSQL_PAM_SERVICE rename failed.'
|
||||
fi
|
||||
|
||||
epatch_user
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
case ${CHOST} in
|
||||
*-darwin*|*-solaris*)
|
||||
use nls && append-libs intl
|
||||
;;
|
||||
esac
|
||||
|
||||
export LDFLAGS_SL="${LDFLAGS}"
|
||||
export LDFLAGS_EX="${LDFLAGS}"
|
||||
|
||||
local PO="${EPREFIX%/}"
|
||||
|
||||
econf \
|
||||
--prefix="${PO}/usr/$(get_libdir)/postgresql-${SLOT}" \
|
||||
--datadir="${PO}/usr/share/postgresql-${SLOT}" \
|
||||
--docdir="${PO}/usr/share/doc/${PF}" \
|
||||
--includedir="${PO}/usr/include/postgresql-${SLOT}" \
|
||||
--mandir="${PO}/usr/share/postgresql-${SLOT}/man" \
|
||||
--sysconfdir="${PO}/etc/postgresql-${SLOT}" \
|
||||
--with-system-tzdata="${PO}/usr/share/zoneinfo" \
|
||||
$(use_enable !pg_legacytimestamp integer-datetimes) \
|
||||
$(use_enable threads thread-safety) \
|
||||
$(use_with kerberos gssapi) \
|
||||
$(use_with kerberos krb5) \
|
||||
$(use_with ldap) \
|
||||
$(use_with pam) \
|
||||
$(use_with perl) \
|
||||
$(use_with python) \
|
||||
$(use_with readline) \
|
||||
$(use_with ssl openssl) \
|
||||
$(use_with tcl) \
|
||||
$(use_with uuid ossp-uuid) \
|
||||
$(use_with xml libxml) \
|
||||
$(use_with xml libxslt) \
|
||||
$(use_with zlib) \
|
||||
"$(use_enable nls nls "$(wanted_languages)")"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake
|
||||
emake -C contrib
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install
|
||||
emake DESTDIR="${D}" install -C contrib
|
||||
|
||||
dodoc README HISTORY doc/{TODO,bug.template}
|
||||
|
||||
# man pages are already built, but if we have the target make them,
|
||||
# they'll be generated from source before being installed so we
|
||||
# manually install man pages.
|
||||
# We use ${SLOT} instead of doman for postgresql.eselect
|
||||
insinto /usr/share/postgresql-${SLOT}/man/
|
||||
doins -r doc/src/sgml/man{1,3,7}
|
||||
if ! use server; then
|
||||
# Remove man pages for non-existent binaries
|
||||
for m in {initdb,pg_{controldata,ctl,resetxlog},post{gres,master}}; do
|
||||
rm "${ED}/usr/share/postgresql-${SLOT}/man/man1/${m}.1"
|
||||
done
|
||||
fi
|
||||
docompress /usr/share/postgresql-${SLOT}/man/man{1,3,7}
|
||||
|
||||
insinto /etc/postgresql-${SLOT}
|
||||
newins src/bin/psql/psqlrc.sample psqlrc
|
||||
|
||||
dodir /etc/eselect/postgresql/slots/${SLOT}
|
||||
echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" > \
|
||||
"${ED}/etc/eselect/postgresql/slots/${SLOT}/base"
|
||||
|
||||
use static-libs || find "${ED}" -name '*.a' -delete
|
||||
|
||||
if use doc ; then
|
||||
docinto html
|
||||
dodoc doc/src/sgml/html/*
|
||||
|
||||
docinto sgml
|
||||
dodoc doc/src/sgml/*.{sgml,dsl}
|
||||
fi
|
||||
|
||||
if use server; then
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.confd" | newconfd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.init" | newinitd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.service" | \
|
||||
systemd_newunit - ${PN}-${SLOT}.service
|
||||
|
||||
systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf
|
||||
|
||||
newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir
|
||||
|
||||
use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session
|
||||
|
||||
if use prefix ; then
|
||||
keepdir /run/postgresql
|
||||
fperms 0775 /run/postgresql
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
postgresql-config update
|
||||
|
||||
elog "If you need a global psqlrc-file, you can place it in:"
|
||||
elog " ${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
|
||||
if use server ; then
|
||||
elog
|
||||
elog "Gentoo specific documentation:"
|
||||
elog "https://wiki.gentoo.org/wiki/PostgreSQL"
|
||||
elog
|
||||
elog "Official documentation:"
|
||||
elog "http://www.postgresql.org/docs/${SLOT}/static/index.html"
|
||||
elog
|
||||
elog "The default location of the Unix-domain socket is:"
|
||||
elog " ${EROOT%/}/run/postgresql/"
|
||||
elog
|
||||
elog "Before initializing the database, you may want to edit PG_INITDB_OPTS"
|
||||
elog "so that it contains your preferred locale in:"
|
||||
elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
elog
|
||||
elog "Then, execute the following command to setup the initial database"
|
||||
elog "environment:"
|
||||
elog " emerge --config =${CATEGORY}/${PF}"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_prerm() {
|
||||
if use server && [[ -z ${REPLACED_BY_VERSION} ]] ; then
|
||||
ewarn "Have you dumped and/or migrated the ${SLOT} database cluster?"
|
||||
ewarn "\thttps://wiki.gentoo.org/wiki/PostgreSQL/QuickStart#Migrating_PostgreSQL"
|
||||
|
||||
ebegin "Resuming removal in 10 seconds (Control-C to cancel)"
|
||||
sleep 10
|
||||
eend 0
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
postgresql-config update
|
||||
}
|
||||
|
||||
pkg_config() {
|
||||
use server || die "USE flag 'server' not enabled. Nothing to configure."
|
||||
|
||||
[[ -f "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" ]] \
|
||||
&& source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
[[ -z "${PGDATA}" ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
[[ -z "${DATA_DIR}" ]] \
|
||||
&& DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data"
|
||||
|
||||
# environment.bz2 may not contain the same locale as the current system
|
||||
# locale. Unset and source from the current system locale.
|
||||
if [ -f "${EROOT%/}/etc/env.d/02locale" ]; then
|
||||
unset LANG
|
||||
unset LC_CTYPE
|
||||
unset LC_NUMERIC
|
||||
unset LC_TIME
|
||||
unset LC_COLLATE
|
||||
unset LC_MONETARY
|
||||
unset LC_MESSAGES
|
||||
unset LC_ALL
|
||||
source "${EROOT%/}/etc/env.d/02locale"
|
||||
[ -n "${LANG}" ] && export LANG
|
||||
[ -n "${LC_CTYPE}" ] && export LC_CTYPE
|
||||
[ -n "${LC_NUMERIC}" ] && export LC_NUMERIC
|
||||
[ -n "${LC_TIME}" ] && export LC_TIME
|
||||
[ -n "${LC_COLLATE}" ] && export LC_COLLATE
|
||||
[ -n "${LC_MONETARY}" ] && export LC_MONETARY
|
||||
[ -n "${LC_MESSAGES}" ] && export LC_MESSAGES
|
||||
[ -n "${LC_ALL}" ] && export LC_ALL
|
||||
fi
|
||||
|
||||
einfo "You can modify the paths and options passed to initdb by editing:"
|
||||
einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
einfo
|
||||
einfo "Information on options that can be passed to initdb are found at:"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html"
|
||||
einfo
|
||||
einfo "PG_INITDB_OPTS is currently set to:"
|
||||
if [[ -z "${PG_INITDB_OPTS}" ]] ; then
|
||||
einfo " (none)"
|
||||
else
|
||||
einfo " ${PG_INITDB_OPTS}"
|
||||
fi
|
||||
einfo
|
||||
einfo "Configuration files will be installed to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo
|
||||
einfo "The database cluster will be created in:"
|
||||
einfo " ${DATA_DIR}"
|
||||
einfo
|
||||
while [ "$correct" != "true" ] ; do
|
||||
einfo "Are you ready to continue? (y/n)"
|
||||
read answer
|
||||
if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then
|
||||
correct="true"
|
||||
elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then
|
||||
die "Aborting initialization."
|
||||
else
|
||||
echo "Answer not recognized"
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ] ; then
|
||||
eerror "The given directory, '${DATA_DIR}', is not empty."
|
||||
eerror "Modify DATA_DIR to point to an empty directory."
|
||||
die "${DATA_DIR} is not empty."
|
||||
fi
|
||||
|
||||
einfo "Creating the data directory ..."
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
mkdir -p "${DATA_DIR}"
|
||||
chown -Rf postgres:postgres "${DATA_DIR}"
|
||||
chmod 0700 "${DATA_DIR}"
|
||||
fi
|
||||
|
||||
einfo "Initializing the database ..."
|
||||
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}"
|
||||
else
|
||||
"${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS}
|
||||
fi
|
||||
|
||||
if [[ "${DATA_DIR%/}" != "${PGDATA%/}" ]] ; then
|
||||
mv "${DATA_DIR%/}"/{pg_{hba,ident},postgresql}.conf "${PGDATA}"
|
||||
ln -s "${PGDATA%/}"/{pg_{hba,ident},postgresql}.conf "${DATA_DIR%/}"
|
||||
fi
|
||||
|
||||
cat <<- EOF >> "${PGDATA%/}"/postgresql.conf
|
||||
# This is here because of https://bugs.gentoo.org/show_bug.cgi?id=518522
|
||||
# On the off-chance that you might need to work with UTF-8 encoded
|
||||
# characters in PL/Perl
|
||||
plperl.on_init = 'use utf8; use re; package utf8; require "utf8_heavy.pl";'
|
||||
EOF
|
||||
|
||||
einfo "The autovacuum function, which was in contrib, has been moved to the main"
|
||||
einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled"
|
||||
einfo "by default. You can disable it in the cluster's:"
|
||||
einfo " ${PGDATA%/}/postgresql.conf"
|
||||
einfo
|
||||
einfo "The PostgreSQL server, by default, will log events to:"
|
||||
einfo " ${DATA_DIR%/}/postmaster.log"
|
||||
einfo
|
||||
if use prefix ; then
|
||||
einfo "The location of the configuration files have moved to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo "To start the server:"
|
||||
einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'"
|
||||
einfo "To stop:"
|
||||
einfo " pg_ctl stop -D ${DATA_DIR}"
|
||||
einfo
|
||||
einfo "Or move the configuration files back:"
|
||||
einfo "mv ${PGDATA}*.conf ${DATA_DIR}"
|
||||
else
|
||||
einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL"
|
||||
einfo "instead of 'pg_ctl'."
|
||||
fi
|
||||
}
|
||||
|
||||
src_test() {
|
||||
einfo ">>> Test phase [check]: ${CATEGORY}/${PF}"
|
||||
|
||||
if use server && [[ ${UID} -ne 0 ]] ; then
|
||||
emake check
|
||||
|
||||
einfo "If you think other tests besides the regression tests are necessary, please"
|
||||
einfo "submit a bug including a patch for this ebuild to enable them."
|
||||
else
|
||||
use server || \
|
||||
ewarn 'Tests cannot be run without the "server" use flag enabled.'
|
||||
[[ ${UID} -eq 0 ]] || \
|
||||
ewarn 'Tests cannot be run as root. Enable "userpriv" in FEATURES.'
|
||||
|
||||
ewarn 'Skipping.'
|
||||
fi
|
||||
}
|
@ -0,0 +1,390 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
PYTHON_COMPAT=( python{2_7,3_4} )
|
||||
|
||||
inherit eutils flag-o-matic linux-info multilib pam prefix python-single-r1 \
|
||||
systemd user versionator
|
||||
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~ppc-macos ~x86-solaris"
|
||||
|
||||
SLOT="$(get_version_component_range 1-2)"
|
||||
|
||||
SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2"
|
||||
|
||||
LICENSE="POSTGRESQL GPL-2"
|
||||
DESCRIPTION="PostgreSQL RDBMS"
|
||||
HOMEPAGE="http://www.postgresql.org/"
|
||||
|
||||
LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr
|
||||
zh_CN zh_TW"
|
||||
IUSE="doc kerberos kernel_linux ldap libressl nls pam perl -pg_legacytimestamp python
|
||||
+readline selinux +server ssl static-libs tcl threads uuid xml zlib"
|
||||
|
||||
for lingua in ${LINGUAS}; do
|
||||
IUSE+=" linguas_${lingua}"
|
||||
done
|
||||
|
||||
wanted_languages() {
|
||||
local enable_langs
|
||||
|
||||
for lingua in ${LINGUAS} ; do
|
||||
use linguas_${lingua} && enable_langs+="${lingua} "
|
||||
done
|
||||
|
||||
echo -n ${enable_langs}
|
||||
}
|
||||
|
||||
CDEPEND="
|
||||
>=app-eselect/eselect-postgresql-1.2.0
|
||||
sys-apps/less
|
||||
virtual/libintl
|
||||
kerberos? ( virtual/krb5 )
|
||||
ldap? ( net-nds/openldap )
|
||||
pam? ( virtual/pam )
|
||||
perl? ( >=dev-lang/perl-5.8 )
|
||||
python? ( ${PYTHON_DEPS} )
|
||||
readline? ( sys-libs/readline:0= )
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6-r1:0= )
|
||||
libressl? ( dev-libs/libressl:= )
|
||||
)
|
||||
tcl? ( >=dev-lang/tcl-8:0= )
|
||||
uuid? ( dev-libs/ossp-uuid )
|
||||
xml? ( dev-libs/libxml2 dev-libs/libxslt )
|
||||
zlib? ( sys-libs/zlib )
|
||||
"
|
||||
|
||||
DEPEND="${CDEPEND}
|
||||
!!<sys-apps/sandbox-2.0
|
||||
sys-devel/bison
|
||||
sys-devel/flex
|
||||
nls? ( sys-devel/gettext )
|
||||
xml? ( virtual/pkgconfig )
|
||||
"
|
||||
|
||||
RDEPEND="${CDEPEND}
|
||||
!dev-db/postgresql-docs:${SLOT}
|
||||
!dev-db/postgresql-base:${SLOT}
|
||||
!dev-db/postgresql-server:${SLOT}
|
||||
selinux? ( sec-policy/selinux-postgresql )
|
||||
"
|
||||
|
||||
pkg_setup() {
|
||||
use server && CONFIG_CHECK="~SYSVIPC" linux-info_pkg_setup
|
||||
|
||||
enewgroup postgres 70
|
||||
enewuser postgres 70 /bin/sh /var/lib/postgresql postgres
|
||||
|
||||
use python && python-single-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Work around PPC{,64} compilation bug where bool is already defined
|
||||
sed '/#ifndef __cplusplus/a #undef bool' -i src/include/c.h || die
|
||||
|
||||
# Set proper run directory
|
||||
sed "s|\(PGSOCKET_DIR\s\+\)\"/tmp\"|\1\"${EPREFIX}/run/postgresql\"|" \
|
||||
-i src/include/pg_config_manual.h || die
|
||||
|
||||
use server || epatch "${FILESDIR}/${PN}-${SLOT}-no-server.patch"
|
||||
|
||||
# Fix bug 486556 where the server would crash at start up because of
|
||||
# an infinite loop caused by a self-referencing symlink.
|
||||
epatch "${FILESDIR}/postgresql-9.2-9.4-tz-dir-overflow.patch"
|
||||
|
||||
if use pam ; then
|
||||
sed -e "s/\(#define PGSQL_PAM_SERVICE \"postgresql\)/\1-${SLOT}/" \
|
||||
-i src/backend/libpq/auth.c || \
|
||||
die 'PGSQL_PAM_SERVICE rename failed.'
|
||||
fi
|
||||
|
||||
epatch_user
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
case ${CHOST} in
|
||||
*-darwin*|*-solaris*)
|
||||
use nls && append-libs intl
|
||||
;;
|
||||
esac
|
||||
|
||||
export LDFLAGS_SL="${LDFLAGS}"
|
||||
export LDFLAGS_EX="${LDFLAGS}"
|
||||
|
||||
local PO="${EPREFIX%/}"
|
||||
|
||||
econf \
|
||||
--prefix="${PO}/usr/$(get_libdir)/postgresql-${SLOT}" \
|
||||
--datadir="${PO}/usr/share/postgresql-${SLOT}" \
|
||||
--docdir="${PO}/usr/share/doc/${PF}" \
|
||||
--includedir="${PO}/usr/include/postgresql-${SLOT}" \
|
||||
--mandir="${PO}/usr/share/postgresql-${SLOT}/man" \
|
||||
--sysconfdir="${PO}/etc/postgresql-${SLOT}" \
|
||||
--with-system-tzdata="${PO}/usr/share/zoneinfo" \
|
||||
$(use_enable !pg_legacytimestamp integer-datetimes) \
|
||||
$(use_enable threads thread-safety) \
|
||||
$(use_with kerberos gssapi) \
|
||||
$(use_with kerberos krb5) \
|
||||
$(use_with ldap) \
|
||||
$(use_with pam) \
|
||||
$(use_with perl) \
|
||||
$(use_with python) \
|
||||
$(use_with readline) \
|
||||
$(use_with ssl openssl) \
|
||||
$(use_with tcl) \
|
||||
$(use_with uuid ossp-uuid) \
|
||||
$(use_with xml libxml) \
|
||||
$(use_with xml libxslt) \
|
||||
$(use_with zlib) \
|
||||
"$(use_enable nls nls "$(wanted_languages)")"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake
|
||||
emake -C contrib
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install
|
||||
emake DESTDIR="${D}" install -C contrib
|
||||
|
||||
dodoc README HISTORY doc/{TODO,bug.template}
|
||||
|
||||
# man pages are already built, but if we have the target make them,
|
||||
# they'll be generated from source before being installed so we
|
||||
# manually install man pages.
|
||||
# We use ${SLOT} instead of doman for postgresql.eselect
|
||||
insinto /usr/share/postgresql-${SLOT}/man/
|
||||
doins -r doc/src/sgml/man{1,3,7}
|
||||
if ! use server; then
|
||||
# Remove man pages for non-existent binaries
|
||||
for m in {initdb,pg_{controldata,ctl,resetxlog},post{gres,master}}; do
|
||||
rm "${ED}/usr/share/postgresql-${SLOT}/man/man1/${m}.1"
|
||||
done
|
||||
fi
|
||||
docompress /usr/share/postgresql-${SLOT}/man/man{1,3,7}
|
||||
|
||||
insinto /etc/postgresql-${SLOT}
|
||||
newins src/bin/psql/psqlrc.sample psqlrc
|
||||
|
||||
dodir /etc/eselect/postgresql/slots/${SLOT}
|
||||
echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" > \
|
||||
"${ED}/etc/eselect/postgresql/slots/${SLOT}/base"
|
||||
|
||||
use static-libs || find "${ED}" -name '*.a' -delete
|
||||
|
||||
if use doc ; then
|
||||
docinto html
|
||||
dodoc doc/src/sgml/html/*
|
||||
|
||||
docinto sgml
|
||||
dodoc doc/src/sgml/*.{sgml,dsl}
|
||||
fi
|
||||
|
||||
if use server; then
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.confd" | newconfd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.init-9.3" | newinitd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.service" | \
|
||||
systemd_newunit - ${PN}-${SLOT}.service
|
||||
|
||||
systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf
|
||||
|
||||
newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir
|
||||
|
||||
use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session
|
||||
|
||||
if use prefix ; then
|
||||
keepdir /run/postgresql
|
||||
fperms 0775 /run/postgresql
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
postgresql-config update
|
||||
|
||||
elog "If you need a global psqlrc-file, you can place it in:"
|
||||
elog " ${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
|
||||
if use server ; then
|
||||
elog
|
||||
elog "Gentoo specific documentation:"
|
||||
elog "https://wiki.gentoo.org/wiki/PostgreSQL"
|
||||
elog
|
||||
elog "Official documentation:"
|
||||
elog "http://www.postgresql.org/docs/${SLOT}/static/index.html"
|
||||
elog
|
||||
elog "The default location of the Unix-domain socket is:"
|
||||
elog " ${EROOT%/}/run/postgresql/"
|
||||
elog
|
||||
elog "Before initializing the database, you may want to edit PG_INITDB_OPTS"
|
||||
elog "so that it contains your preferred locale in:"
|
||||
elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
elog
|
||||
elog "Then, execute the following command to setup the initial database"
|
||||
elog "environment:"
|
||||
elog " emerge --config =${CATEGORY}/${PF}"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_prerm() {
|
||||
if use server && [[ -z ${REPLACED_BY_VERSION} ]] ; then
|
||||
ewarn "Have you dumped and/or migrated the ${SLOT} database cluster?"
|
||||
ewarn "\thttps://wiki.gentoo.org/wiki/PostgreSQL/QuickStart#Migrating_PostgreSQL"
|
||||
|
||||
ebegin "Resuming removal in 10 seconds (Control-C to cancel)"
|
||||
sleep 10
|
||||
eend 0
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
postgresql-config update
|
||||
}
|
||||
|
||||
pkg_config() {
|
||||
use server || die "USE flag 'server' not enabled. Nothing to configure."
|
||||
|
||||
[[ -f "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" ]] \
|
||||
&& source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
[[ -z "${PGDATA}" ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
[[ -z "${DATA_DIR}" ]] \
|
||||
&& DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data"
|
||||
|
||||
# environment.bz2 may not contain the same locale as the current system
|
||||
# locale. Unset and source from the current system locale.
|
||||
if [ -f "${EROOT%/}/etc/env.d/02locale" ]; then
|
||||
unset LANG
|
||||
unset LC_CTYPE
|
||||
unset LC_NUMERIC
|
||||
unset LC_TIME
|
||||
unset LC_COLLATE
|
||||
unset LC_MONETARY
|
||||
unset LC_MESSAGES
|
||||
unset LC_ALL
|
||||
source "${EROOT%/}/etc/env.d/02locale"
|
||||
[ -n "${LANG}" ] && export LANG
|
||||
[ -n "${LC_CTYPE}" ] && export LC_CTYPE
|
||||
[ -n "${LC_NUMERIC}" ] && export LC_NUMERIC
|
||||
[ -n "${LC_TIME}" ] && export LC_TIME
|
||||
[ -n "${LC_COLLATE}" ] && export LC_COLLATE
|
||||
[ -n "${LC_MONETARY}" ] && export LC_MONETARY
|
||||
[ -n "${LC_MESSAGES}" ] && export LC_MESSAGES
|
||||
[ -n "${LC_ALL}" ] && export LC_ALL
|
||||
fi
|
||||
|
||||
einfo "You can modify the paths and options passed to initdb by editing:"
|
||||
einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
einfo
|
||||
einfo "Information on options that can be passed to initdb are found at:"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html"
|
||||
einfo
|
||||
einfo "PG_INITDB_OPTS is currently set to:"
|
||||
if [[ -z "${PG_INITDB_OPTS}" ]] ; then
|
||||
einfo " (none)"
|
||||
else
|
||||
einfo " ${PG_INITDB_OPTS}"
|
||||
fi
|
||||
einfo
|
||||
einfo "Configuration files will be installed to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo
|
||||
einfo "The database cluster will be created in:"
|
||||
einfo " ${DATA_DIR}"
|
||||
einfo
|
||||
while [ "$correct" != "true" ] ; do
|
||||
einfo "Are you ready to continue? (y/n)"
|
||||
read answer
|
||||
if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then
|
||||
correct="true"
|
||||
elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then
|
||||
die "Aborting initialization."
|
||||
else
|
||||
echo "Answer not recognized"
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ] ; then
|
||||
eerror "The given directory, '${DATA_DIR}', is not empty."
|
||||
eerror "Modify DATA_DIR to point to an empty directory."
|
||||
die "${DATA_DIR} is not empty."
|
||||
fi
|
||||
|
||||
einfo "Creating the data directory ..."
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
mkdir -p "${DATA_DIR}"
|
||||
chown -Rf postgres:postgres "${DATA_DIR}"
|
||||
chmod 0700 "${DATA_DIR}"
|
||||
fi
|
||||
|
||||
einfo "Initializing the database ..."
|
||||
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}"
|
||||
else
|
||||
"${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS}
|
||||
fi
|
||||
|
||||
if [[ "${DATA_DIR%/}" != "${PGDATA%/}" ]] ; then
|
||||
mv "${DATA_DIR%/}"/{pg_{hba,ident},postgresql}.conf "${PGDATA}"
|
||||
ln -s "${PGDATA%/}"/{pg_{hba,ident},postgresql}.conf "${DATA_DIR%/}"
|
||||
fi
|
||||
|
||||
cat <<- EOF >> "${PGDATA%/}"/postgresql.conf
|
||||
# This is here because of https://bugs.gentoo.org/show_bug.cgi?id=518522
|
||||
# On the off-chance that you might need to work with UTF-8 encoded
|
||||
# characters in PL/Perl
|
||||
plperl.on_init = 'use utf8; use re; package utf8; require "utf8_heavy.pl";'
|
||||
EOF
|
||||
|
||||
einfo "The autovacuum function, which was in contrib, has been moved to the main"
|
||||
einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled"
|
||||
einfo "by default. You can disable it in the cluster's:"
|
||||
einfo " ${PGDATA%/}/postgresql.conf"
|
||||
einfo
|
||||
einfo "The PostgreSQL server, by default, will log events to:"
|
||||
einfo " ${DATA_DIR%/}/postmaster.log"
|
||||
einfo
|
||||
if use prefix ; then
|
||||
einfo "The location of the configuration files have moved to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo "To start the server:"
|
||||
einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'"
|
||||
einfo "To stop:"
|
||||
einfo " pg_ctl stop -D ${DATA_DIR}"
|
||||
einfo
|
||||
einfo "Or move the configuration files back:"
|
||||
einfo "mv ${PGDATA}*.conf ${DATA_DIR}"
|
||||
else
|
||||
einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL"
|
||||
einfo "instead of 'pg_ctl'."
|
||||
fi
|
||||
}
|
||||
|
||||
src_test() {
|
||||
einfo ">>> Test phase [check]: ${CATEGORY}/${PF}"
|
||||
|
||||
if use server && [[ ${UID} -ne 0 ]] ; then
|
||||
emake check
|
||||
|
||||
einfo "If you think other tests besides the regression tests are necessary, please"
|
||||
einfo "submit a bug including a patch for this ebuild to enable them."
|
||||
else
|
||||
use server || \
|
||||
ewarn 'Tests cannot be run without the "server" use flag enabled.'
|
||||
[[ ${UID} -eq 0 ]] || \
|
||||
ewarn 'Tests cannot be run as root. Enable "userpriv" in FEATURES.'
|
||||
|
||||
ewarn 'Skipping.'
|
||||
fi
|
||||
}
|
@ -0,0 +1,425 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
PYTHON_COMPAT=( python{2_7,3_4} )
|
||||
|
||||
inherit eutils flag-o-matic linux-info multilib pam prefix python-single-r1 \
|
||||
systemd user versionator
|
||||
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~ppc-macos ~x86-solaris"
|
||||
|
||||
SLOT="$(get_version_component_range 1-2)"
|
||||
|
||||
SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2"
|
||||
|
||||
LICENSE="POSTGRESQL GPL-2"
|
||||
DESCRIPTION="PostgreSQL RDBMS"
|
||||
HOMEPAGE="http://www.postgresql.org/"
|
||||
|
||||
LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr
|
||||
zh_CN zh_TW"
|
||||
IUSE="doc kerberos kernel_linux ldap libressl nls pam perl -pg_legacytimestamp python
|
||||
+readline selinux +server ssl static-libs tcl threads uuid xml zlib"
|
||||
|
||||
for lingua in ${LINGUAS}; do
|
||||
IUSE+=" linguas_${lingua}"
|
||||
done
|
||||
|
||||
wanted_languages() {
|
||||
local enable_langs
|
||||
|
||||
for lingua in ${LINGUAS} ; do
|
||||
use linguas_${lingua} && enable_langs+="${lingua} "
|
||||
done
|
||||
|
||||
echo -n ${enable_langs}
|
||||
}
|
||||
|
||||
CDEPEND="
|
||||
>=app-eselect/eselect-postgresql-1.2.0
|
||||
sys-apps/less
|
||||
virtual/libintl
|
||||
kerberos? ( virtual/krb5 )
|
||||
ldap? ( net-nds/openldap )
|
||||
pam? ( virtual/pam )
|
||||
perl? ( >=dev-lang/perl-5.8 )
|
||||
python? ( ${PYTHON_DEPS} )
|
||||
readline? ( sys-libs/readline:0= )
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6-r1:0= )
|
||||
libressl? ( dev-libs/libressl:= )
|
||||
)
|
||||
tcl? ( >=dev-lang/tcl-8:0= )
|
||||
xml? ( dev-libs/libxml2 dev-libs/libxslt )
|
||||
zlib? ( sys-libs/zlib )
|
||||
"
|
||||
|
||||
# uuid flags -- depend on sys-apps/util-linux for Linux libcs, or if no
|
||||
# supported libc in use depend on dev-libs/ossp-uuid. For BSD systems,
|
||||
# the libc includes UUID functions.
|
||||
UTIL_LINUX_LIBC=( elibc_{glibc,uclibc,musl} )
|
||||
BSD_LIBC=( elibc_{Free,Net,Open}BSD )
|
||||
|
||||
nest_usedep() {
|
||||
local front back
|
||||
while [[ ${#} -gt 1 ]]; do
|
||||
front+="${1}? ( "
|
||||
back+=" )"
|
||||
shift
|
||||
done
|
||||
echo "${front}${1}${back}"
|
||||
}
|
||||
|
||||
IUSE+=" ${UTIL_LINUX_LIBC[@]} ${BSD_LIBC[@]}"
|
||||
CDEPEND+="
|
||||
uuid? (
|
||||
${UTIL_LINUX_LIBC[@]/%/? ( sys-apps/util-linux )}
|
||||
$(nest_usedep ${UTIL_LINUX_LIBC[@]/#/!} ${BSD_LIBC[@]/#/!} dev-libs/ossp-uuid)
|
||||
)"
|
||||
|
||||
DEPEND="${CDEPEND}
|
||||
!!<sys-apps/sandbox-2.0
|
||||
sys-devel/bison
|
||||
sys-devel/flex
|
||||
nls? ( sys-devel/gettext )
|
||||
xml? ( virtual/pkgconfig )
|
||||
"
|
||||
|
||||
RDEPEND="${CDEPEND}
|
||||
!dev-db/postgresql-docs:${SLOT}
|
||||
!dev-db/postgresql-base:${SLOT}
|
||||
!dev-db/postgresql-server:${SLOT}
|
||||
selinux? ( sec-policy/selinux-postgresql )
|
||||
"
|
||||
|
||||
pkg_setup() {
|
||||
use server && CONFIG_CHECK="~SYSVIPC" linux-info_pkg_setup
|
||||
|
||||
enewgroup postgres 70
|
||||
enewuser postgres 70 /bin/sh /var/lib/postgresql postgres
|
||||
|
||||
use python && python-single-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Work around PPC{,64} compilation bug where bool is already defined
|
||||
sed '/#ifndef __cplusplus/a #undef bool' -i src/include/c.h || die
|
||||
|
||||
# Set proper run directory
|
||||
sed "s|\(PGSOCKET_DIR\s\+\)\"/tmp\"|\1\"${EPREFIX}/run/postgresql\"|" \
|
||||
-i src/include/pg_config_manual.h || die
|
||||
|
||||
# Fix bug 555198: Correct typo in assembly code for alpha architecture
|
||||
epatch "${FILESDIR}/${PN}-${SLOT}-alpha-fix-read-memory-barrier.patch"
|
||||
|
||||
use server || epatch "${FILESDIR}/${PN}-${SLOT}-no-server.patch"
|
||||
|
||||
# Fix bug 486556 where the server would crash at start up because of
|
||||
# an infinite loop caused by a self-referencing symlink.
|
||||
epatch "${FILESDIR}/postgresql-9.2-9.4-tz-dir-overflow.patch"
|
||||
|
||||
if use pam ; then
|
||||
sed -e "s/\(#define PGSQL_PAM_SERVICE \"postgresql\)/\1-${SLOT}/" \
|
||||
-i src/backend/libpq/auth.c || \
|
||||
die 'PGSQL_PAM_SERVICE rename failed.'
|
||||
fi
|
||||
|
||||
epatch_user
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
case ${CHOST} in
|
||||
*-darwin*|*-solaris*)
|
||||
use nls && append-libs intl
|
||||
;;
|
||||
esac
|
||||
|
||||
export LDFLAGS_SL="${LDFLAGS}"
|
||||
export LDFLAGS_EX="${LDFLAGS}"
|
||||
|
||||
local PO="${EPREFIX%/}"
|
||||
|
||||
local i uuid_config=""
|
||||
if use uuid; then
|
||||
for i in ${UTIL_LINUX_LIBC[@]}; do
|
||||
use ${i} && uuid_config="--with-uuid=e2fs"
|
||||
done
|
||||
for i in ${BSD_LIBC[@]}; do
|
||||
use ${i} && uuid_config="--with-uuid=bsd"
|
||||
done
|
||||
[[ -z $uuid_config ]] && uuid_config="--with-uuid=ossp"
|
||||
fi
|
||||
|
||||
econf \
|
||||
--prefix="${PO}/usr/$(get_libdir)/postgresql-${SLOT}" \
|
||||
--datadir="${PO}/usr/share/postgresql-${SLOT}" \
|
||||
--docdir="${PO}/usr/share/doc/${PF}" \
|
||||
--includedir="${PO}/usr/include/postgresql-${SLOT}" \
|
||||
--mandir="${PO}/usr/share/postgresql-${SLOT}/man" \
|
||||
--sysconfdir="${PO}/etc/postgresql-${SLOT}" \
|
||||
--with-system-tzdata="${PO}/usr/share/zoneinfo" \
|
||||
$(use_enable !pg_legacytimestamp integer-datetimes) \
|
||||
$(use_enable threads thread-safety) \
|
||||
$(use_with kerberos gssapi) \
|
||||
$(use_with ldap) \
|
||||
$(use_with pam) \
|
||||
$(use_with perl) \
|
||||
$(use_with python) \
|
||||
$(use_with readline) \
|
||||
$(use_with ssl openssl) \
|
||||
$(use_with tcl) \
|
||||
${uuid_config} \
|
||||
$(use_with xml libxml) \
|
||||
$(use_with xml libxslt) \
|
||||
$(use_with zlib) \
|
||||
"$(use_enable nls nls "$(wanted_languages)")"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake
|
||||
emake -C contrib
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install
|
||||
emake DESTDIR="${D}" install -C contrib
|
||||
|
||||
dodoc README HISTORY doc/{TODO,bug.template}
|
||||
|
||||
# man pages are already built, but if we have the target make them,
|
||||
# they'll be generated from source before being installed so we
|
||||
# manually install man pages.
|
||||
# We use ${SLOT} instead of doman for postgresql.eselect
|
||||
insinto /usr/share/postgresql-${SLOT}/man/
|
||||
doins -r doc/src/sgml/man{1,3,7}
|
||||
if ! use server; then
|
||||
# Remove man pages for non-existent binaries
|
||||
for m in {initdb,pg_{controldata,ctl,resetxlog},post{gres,master}}; do
|
||||
rm "${ED}/usr/share/postgresql-${SLOT}/man/man1/${m}.1"
|
||||
done
|
||||
fi
|
||||
docompress /usr/share/postgresql-${SLOT}/man/man{1,3,7}
|
||||
|
||||
insinto /etc/postgresql-${SLOT}
|
||||
newins src/bin/psql/psqlrc.sample psqlrc
|
||||
|
||||
dodir /etc/eselect/postgresql/slots/${SLOT}
|
||||
echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" > \
|
||||
"${ED}/etc/eselect/postgresql/slots/${SLOT}/base"
|
||||
|
||||
use static-libs || find "${ED}" -name '*.a' -delete
|
||||
|
||||
if use doc ; then
|
||||
docinto html
|
||||
dodoc doc/src/sgml/html/*
|
||||
|
||||
docinto sgml
|
||||
dodoc doc/src/sgml/*.{sgml,dsl}
|
||||
fi
|
||||
|
||||
if use server; then
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.confd" | newconfd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.init-9.3" | newinitd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.service" | \
|
||||
systemd_newunit - ${PN}-${SLOT}.service
|
||||
|
||||
systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf
|
||||
|
||||
newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir
|
||||
|
||||
use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session
|
||||
|
||||
if use prefix ; then
|
||||
keepdir /run/postgresql
|
||||
fperms 0775 /run/postgresql
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
postgresql-config update
|
||||
|
||||
elog "If you need a global psqlrc-file, you can place it in:"
|
||||
elog " ${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
|
||||
if use server ; then
|
||||
elog
|
||||
elog "Gentoo specific documentation:"
|
||||
elog "https://wiki.gentoo.org/wiki/PostgreSQL"
|
||||
elog
|
||||
elog "Official documentation:"
|
||||
elog "http://www.postgresql.org/docs/${SLOT}/static/index.html"
|
||||
elog
|
||||
elog "The default location of the Unix-domain socket is:"
|
||||
elog " ${EROOT%/}/run/postgresql/"
|
||||
elog
|
||||
elog "Before initializing the database, you may want to edit PG_INITDB_OPTS"
|
||||
elog "so that it contains your preferred locale in:"
|
||||
elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
elog
|
||||
elog "Then, execute the following command to setup the initial database"
|
||||
elog "environment:"
|
||||
elog " emerge --config =${CATEGORY}/${PF}"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_prerm() {
|
||||
if use server && [[ -z ${REPLACED_BY_VERSION} ]] ; then
|
||||
ewarn "Have you dumped and/or migrated the ${SLOT} database cluster?"
|
||||
ewarn "\thttps://wiki.gentoo.org/wiki/PostgreSQL/QuickStart#Migrating_PostgreSQL"
|
||||
|
||||
ebegin "Resuming removal in 10 seconds (Control-C to cancel)"
|
||||
sleep 10
|
||||
eend 0
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
postgresql-config update
|
||||
}
|
||||
|
||||
pkg_config() {
|
||||
use server || die "USE flag 'server' not enabled. Nothing to configure."
|
||||
|
||||
[[ -f "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" ]] \
|
||||
&& source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
[[ -z "${PGDATA}" ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
[[ -z "${DATA_DIR}" ]] \
|
||||
&& DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data"
|
||||
|
||||
# environment.bz2 may not contain the same locale as the current system
|
||||
# locale. Unset and source from the current system locale.
|
||||
if [ -f "${EROOT%/}/etc/env.d/02locale" ]; then
|
||||
unset LANG
|
||||
unset LC_CTYPE
|
||||
unset LC_NUMERIC
|
||||
unset LC_TIME
|
||||
unset LC_COLLATE
|
||||
unset LC_MONETARY
|
||||
unset LC_MESSAGES
|
||||
unset LC_ALL
|
||||
source "${EROOT%/}/etc/env.d/02locale"
|
||||
[ -n "${LANG}" ] && export LANG
|
||||
[ -n "${LC_CTYPE}" ] && export LC_CTYPE
|
||||
[ -n "${LC_NUMERIC}" ] && export LC_NUMERIC
|
||||
[ -n "${LC_TIME}" ] && export LC_TIME
|
||||
[ -n "${LC_COLLATE}" ] && export LC_COLLATE
|
||||
[ -n "${LC_MONETARY}" ] && export LC_MONETARY
|
||||
[ -n "${LC_MESSAGES}" ] && export LC_MESSAGES
|
||||
[ -n "${LC_ALL}" ] && export LC_ALL
|
||||
fi
|
||||
|
||||
einfo "You can modify the paths and options passed to initdb by editing:"
|
||||
einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
einfo
|
||||
einfo "Information on options that can be passed to initdb are found at:"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html"
|
||||
einfo
|
||||
einfo "PG_INITDB_OPTS is currently set to:"
|
||||
if [[ -z "${PG_INITDB_OPTS}" ]] ; then
|
||||
einfo " (none)"
|
||||
else
|
||||
einfo " ${PG_INITDB_OPTS}"
|
||||
fi
|
||||
einfo
|
||||
einfo "Configuration files will be installed to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo
|
||||
einfo "The database cluster will be created in:"
|
||||
einfo " ${DATA_DIR}"
|
||||
einfo
|
||||
while [ "$correct" != "true" ] ; do
|
||||
einfo "Are you ready to continue? (y/n)"
|
||||
read answer
|
||||
if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then
|
||||
correct="true"
|
||||
elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then
|
||||
die "Aborting initialization."
|
||||
else
|
||||
echo "Answer not recognized"
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ] ; then
|
||||
eerror "The given directory, '${DATA_DIR}', is not empty."
|
||||
eerror "Modify DATA_DIR to point to an empty directory."
|
||||
die "${DATA_DIR} is not empty."
|
||||
fi
|
||||
|
||||
einfo "Creating the data directory ..."
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
mkdir -p "${DATA_DIR}"
|
||||
chown -Rf postgres:postgres "${DATA_DIR}"
|
||||
chmod 0700 "${DATA_DIR}"
|
||||
fi
|
||||
|
||||
einfo "Initializing the database ..."
|
||||
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}"
|
||||
else
|
||||
"${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS}
|
||||
fi
|
||||
|
||||
if [[ "${DATA_DIR%/}" != "${PGDATA%/}" ]] ; then
|
||||
mv "${DATA_DIR%/}"/{pg_{hba,ident},postgresql}.conf "${PGDATA}"
|
||||
ln -s "${PGDATA%/}"/{pg_{hba,ident},postgresql}.conf "${DATA_DIR%/}"
|
||||
fi
|
||||
|
||||
cat <<- EOF >> "${PGDATA%/}"/postgresql.conf
|
||||
# This is here because of https://bugs.gentoo.org/show_bug.cgi?id=518522
|
||||
# On the off-chance that you might need to work with UTF-8 encoded
|
||||
# characters in PL/Perl
|
||||
plperl.on_init = 'use utf8; use re; package utf8; require "utf8_heavy.pl";'
|
||||
EOF
|
||||
|
||||
einfo "The autovacuum function, which was in contrib, has been moved to the main"
|
||||
einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled"
|
||||
einfo "by default. You can disable it in the cluster's:"
|
||||
einfo " ${PGDATA%/}/postgresql.conf"
|
||||
einfo
|
||||
einfo "The PostgreSQL server, by default, will log events to:"
|
||||
einfo " ${DATA_DIR%/}/postmaster.log"
|
||||
einfo
|
||||
if use prefix ; then
|
||||
einfo "The location of the configuration files have moved to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo "To start the server:"
|
||||
einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'"
|
||||
einfo "To stop:"
|
||||
einfo " pg_ctl stop -D ${DATA_DIR}"
|
||||
einfo
|
||||
einfo "Or move the configuration files back:"
|
||||
einfo "mv ${PGDATA}*.conf ${DATA_DIR}"
|
||||
else
|
||||
einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL"
|
||||
einfo "instead of 'pg_ctl'."
|
||||
fi
|
||||
}
|
||||
|
||||
src_test() {
|
||||
einfo ">>> Test phase [check]: ${CATEGORY}/${PF}"
|
||||
|
||||
if use server && [[ ${UID} -ne 0 ]] ; then
|
||||
emake check
|
||||
|
||||
einfo "If you think other tests besides the regression tests are necessary, please"
|
||||
einfo "submit a bug including a patch for this ebuild to enable them."
|
||||
else
|
||||
use server || \
|
||||
ewarn 'Tests cannot be run without the "server" use flag enabled.'
|
||||
[[ ${UID} -eq 0 ]] || \
|
||||
ewarn 'Tests cannot be run as root. Enable "userpriv" in FEATURES.'
|
||||
|
||||
ewarn 'Skipping.'
|
||||
fi
|
||||
}
|
@ -0,0 +1,428 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
PYTHON_COMPAT=( python{2_7,3_4} )
|
||||
|
||||
inherit eutils flag-o-matic linux-info multilib pam prefix python-single-r1 \
|
||||
systemd user versionator
|
||||
|
||||
# This is a prerelease version, so no keywords please
|
||||
KEYWORDS=""
|
||||
#KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~ppc-macos ~x86-solaris"
|
||||
|
||||
SLOT="$(get_version_component_range 1-2)"
|
||||
|
||||
MY_PV=${PV/_/}
|
||||
|
||||
S=${WORKDIR}/${PN}-${MY_PV}
|
||||
|
||||
SRC_URI="mirror://postgresql/source/v${MY_PV}/postgresql-${MY_PV}.tar.bz2"
|
||||
|
||||
LICENSE="POSTGRESQL GPL-2"
|
||||
DESCRIPTION="PostgreSQL RDBMS"
|
||||
HOMEPAGE="http://www.postgresql.org/"
|
||||
|
||||
LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr
|
||||
zh_CN zh_TW"
|
||||
IUSE="doc kerberos kernel_linux ldap libressl nls pam perl -pg_legacytimestamp python
|
||||
+readline selinux +server ssl static-libs tcl threads uuid xml zlib"
|
||||
|
||||
for lingua in ${LINGUAS}; do
|
||||
IUSE+=" linguas_${lingua}"
|
||||
done
|
||||
|
||||
wanted_languages() {
|
||||
local enable_langs
|
||||
|
||||
for lingua in ${LINGUAS} ; do
|
||||
use linguas_${lingua} && enable_langs+="${lingua} "
|
||||
done
|
||||
|
||||
echo -n ${enable_langs}
|
||||
}
|
||||
|
||||
CDEPEND="
|
||||
>=app-eselect/eselect-postgresql-1.2.0
|
||||
sys-apps/less
|
||||
virtual/libintl
|
||||
kerberos? ( virtual/krb5 )
|
||||
ldap? ( net-nds/openldap )
|
||||
pam? ( virtual/pam )
|
||||
perl? ( >=dev-lang/perl-5.8 )
|
||||
python? ( ${PYTHON_DEPS} )
|
||||
readline? ( sys-libs/readline:0= )
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6-r1:0= )
|
||||
libressl? ( dev-libs/libressl:= )
|
||||
)
|
||||
tcl? ( >=dev-lang/tcl-8:0= )
|
||||
xml? ( dev-libs/libxml2 dev-libs/libxslt )
|
||||
zlib? ( sys-libs/zlib )
|
||||
"
|
||||
|
||||
# uuid flags -- depend on sys-apps/util-linux for Linux libcs, or if no
|
||||
# supported libc in use depend on dev-libs/ossp-uuid. For BSD systems,
|
||||
# the libc includes UUID functions.
|
||||
UTIL_LINUX_LIBC=( elibc_{glibc,uclibc,musl} )
|
||||
BSD_LIBC=( elibc_{Free,Net,Open}BSD )
|
||||
|
||||
nest_usedep() {
|
||||
local front back
|
||||
while [[ ${#} -gt 1 ]]; do
|
||||
front+="${1}? ( "
|
||||
back+=" )"
|
||||
shift
|
||||
done
|
||||
echo "${front}${1}${back}"
|
||||
}
|
||||
|
||||
IUSE+=" ${UTIL_LINUX_LIBC[@]} ${BSD_LIBC[@]}"
|
||||
CDEPEND+="
|
||||
uuid? (
|
||||
${UTIL_LINUX_LIBC[@]/%/? ( sys-apps/util-linux )}
|
||||
$(nest_usedep ${UTIL_LINUX_LIBC[@]/#/!} ${BSD_LIBC[@]/#/!} dev-libs/ossp-uuid)
|
||||
)"
|
||||
|
||||
DEPEND="${CDEPEND}
|
||||
!!<sys-apps/sandbox-2.0
|
||||
sys-devel/bison
|
||||
sys-devel/flex
|
||||
nls? ( sys-devel/gettext )
|
||||
xml? ( virtual/pkgconfig )
|
||||
"
|
||||
|
||||
RDEPEND="${CDEPEND}
|
||||
!dev-db/postgresql-docs:${SLOT}
|
||||
!dev-db/postgresql-base:${SLOT}
|
||||
!dev-db/postgresql-server:${SLOT}
|
||||
selinux? ( sec-policy/selinux-postgresql )
|
||||
"
|
||||
|
||||
pkg_setup() {
|
||||
use server && CONFIG_CHECK="~SYSVIPC" linux-info_pkg_setup
|
||||
|
||||
enewgroup postgres 70
|
||||
enewuser postgres 70 /bin/sh /var/lib/postgresql postgres
|
||||
|
||||
use python && python-single-r1_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Work around PPC{,64} compilation bug where bool is already defined
|
||||
sed '/#ifndef __cplusplus/a #undef bool' -i src/include/c.h || die
|
||||
|
||||
# Set proper run directory
|
||||
sed "s|\(PGSOCKET_DIR\s\+\)\"/tmp\"|\1\"${EPREFIX}/run/postgresql\"|" \
|
||||
-i src/include/pg_config_manual.h || die
|
||||
|
||||
use server || epatch "${FILESDIR}/${PN}-${SLOT}-no-server.patch"
|
||||
|
||||
# Fix bug 486556 where the server would crash at start up because of
|
||||
# an infinite loop caused by a self-referencing symlink.
|
||||
epatch "${FILESDIR}/postgresql-9.2-9.4-tz-dir-overflow.patch"
|
||||
|
||||
if use pam ; then
|
||||
sed -e "s/\(#define PGSQL_PAM_SERVICE \"postgresql\)/\1-${SLOT}/" \
|
||||
-i src/backend/libpq/auth.c || \
|
||||
die 'PGSQL_PAM_SERVICE rename failed.'
|
||||
fi
|
||||
|
||||
epatch_user
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
case ${CHOST} in
|
||||
*-darwin*|*-solaris*)
|
||||
use nls && append-libs intl
|
||||
;;
|
||||
esac
|
||||
|
||||
export LDFLAGS_SL="${LDFLAGS}"
|
||||
export LDFLAGS_EX="${LDFLAGS}"
|
||||
|
||||
local PO="${EPREFIX%/}"
|
||||
|
||||
local i uuid_config=""
|
||||
if use uuid; then
|
||||
for i in ${UTIL_LINUX_LIBC[@]}; do
|
||||
use ${i} && uuid_config="--with-uuid=e2fs"
|
||||
done
|
||||
for i in ${BSD_LIBC[@]}; do
|
||||
use ${i} && uuid_config="--with-uuid=bsd"
|
||||
done
|
||||
[[ -z $uuid_config ]] && uuid_config="--with-uuid=ossp"
|
||||
fi
|
||||
|
||||
econf \
|
||||
--prefix="${PO}/usr/$(get_libdir)/postgresql-${SLOT}" \
|
||||
--datadir="${PO}/usr/share/postgresql-${SLOT}" \
|
||||
--docdir="${PO}/usr/share/doc/${PF}" \
|
||||
--includedir="${PO}/usr/include/postgresql-${SLOT}" \
|
||||
--mandir="${PO}/usr/share/postgresql-${SLOT}/man" \
|
||||
--sysconfdir="${PO}/etc/postgresql-${SLOT}" \
|
||||
--with-system-tzdata="${PO}/usr/share/zoneinfo" \
|
||||
$(use_enable !pg_legacytimestamp integer-datetimes) \
|
||||
$(use_enable threads thread-safety) \
|
||||
$(use_with kerberos gssapi) \
|
||||
$(use_with ldap) \
|
||||
$(use_with pam) \
|
||||
$(use_with perl) \
|
||||
$(use_with python) \
|
||||
$(use_with readline) \
|
||||
$(use_with ssl openssl) \
|
||||
$(use_with tcl) \
|
||||
${uuid_config} \
|
||||
$(use_with xml libxml) \
|
||||
$(use_with xml libxslt) \
|
||||
$(use_with zlib) \
|
||||
"$(use_enable nls nls "$(wanted_languages)")"
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake
|
||||
emake -C contrib
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install
|
||||
emake DESTDIR="${D}" install -C contrib
|
||||
|
||||
dodoc README HISTORY doc/{TODO,bug.template}
|
||||
|
||||
# man pages are already built, but if we have the target make them,
|
||||
# they'll be generated from source before being installed so we
|
||||
# manually install man pages.
|
||||
# We use ${SLOT} instead of doman for postgresql.eselect
|
||||
insinto /usr/share/postgresql-${SLOT}/man/
|
||||
doins -r doc/src/sgml/man{1,3,7}
|
||||
if ! use server; then
|
||||
# Remove man pages for non-existent binaries
|
||||
for m in {initdb,pg_{controldata,ctl,resetxlog},post{gres,master}}; do
|
||||
rm "${ED}/usr/share/postgresql-${SLOT}/man/man1/${m}.1"
|
||||
done
|
||||
fi
|
||||
docompress /usr/share/postgresql-${SLOT}/man/man{1,3,7}
|
||||
|
||||
insinto /etc/postgresql-${SLOT}
|
||||
newins src/bin/psql/psqlrc.sample psqlrc
|
||||
|
||||
dodir /etc/eselect/postgresql/slots/${SLOT}
|
||||
echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" > \
|
||||
"${ED}/etc/eselect/postgresql/slots/${SLOT}/base"
|
||||
|
||||
use static-libs || find "${ED}" -name '*.a' -delete
|
||||
|
||||
if use doc ; then
|
||||
docinto html
|
||||
dodoc doc/src/sgml/html/*
|
||||
|
||||
docinto sgml
|
||||
dodoc doc/src/sgml/*.{sgml,dsl}
|
||||
fi
|
||||
|
||||
if use server; then
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.confd" | newconfd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.init-9.3" | newinitd - ${PN}-${SLOT}
|
||||
|
||||
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
|
||||
"${FILESDIR}/${PN}.service" | \
|
||||
systemd_newunit - ${PN}-${SLOT}.service
|
||||
|
||||
systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfilesd ${PN}-${SLOT}.conf
|
||||
|
||||
newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir
|
||||
|
||||
use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session
|
||||
|
||||
if use prefix ; then
|
||||
keepdir /run/postgresql
|
||||
fperms 0775 /run/postgresql
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
postgresql-config update
|
||||
|
||||
elog "If you need a global psqlrc-file, you can place it in:"
|
||||
elog " ${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
|
||||
if use server ; then
|
||||
elog
|
||||
elog "Gentoo specific documentation:"
|
||||
elog "https://wiki.gentoo.org/wiki/PostgreSQL"
|
||||
elog
|
||||
elog "Official documentation:"
|
||||
elog "http://www.postgresql.org/docs/${SLOT}/static/index.html"
|
||||
elog
|
||||
elog "The default location of the Unix-domain socket is:"
|
||||
elog " ${EROOT%/}/run/postgresql/"
|
||||
elog
|
||||
elog "Before initializing the database, you may want to edit PG_INITDB_OPTS"
|
||||
elog "so that it contains your preferred locale in:"
|
||||
elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
elog
|
||||
elog "Then, execute the following command to setup the initial database"
|
||||
elog "environment:"
|
||||
elog " emerge --config =${CATEGORY}/${PF}"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_prerm() {
|
||||
if use server && [[ -z ${REPLACED_BY_VERSION} ]] ; then
|
||||
ewarn "Have you dumped and/or migrated the ${SLOT} database cluster?"
|
||||
ewarn "\thttps://wiki.gentoo.org/wiki/PostgreSQL/QuickStart#Migrating_PostgreSQL"
|
||||
|
||||
ebegin "Resuming removal in 10 seconds (Control-C to cancel)"
|
||||
sleep 10
|
||||
eend 0
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
postgresql-config update
|
||||
}
|
||||
|
||||
pkg_config() {
|
||||
use server || die "USE flag 'server' not enabled. Nothing to configure."
|
||||
|
||||
[[ -f "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" ]] \
|
||||
&& source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
[[ -z "${PGDATA}" ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/"
|
||||
[[ -z "${DATA_DIR}" ]] \
|
||||
&& DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data"
|
||||
|
||||
# environment.bz2 may not contain the same locale as the current system
|
||||
# locale. Unset and source from the current system locale.
|
||||
if [ -f "${EROOT%/}/etc/env.d/02locale" ]; then
|
||||
unset LANG
|
||||
unset LC_CTYPE
|
||||
unset LC_NUMERIC
|
||||
unset LC_TIME
|
||||
unset LC_COLLATE
|
||||
unset LC_MONETARY
|
||||
unset LC_MESSAGES
|
||||
unset LC_ALL
|
||||
source "${EROOT%/}/etc/env.d/02locale"
|
||||
[ -n "${LANG}" ] && export LANG
|
||||
[ -n "${LC_CTYPE}" ] && export LC_CTYPE
|
||||
[ -n "${LC_NUMERIC}" ] && export LC_NUMERIC
|
||||
[ -n "${LC_TIME}" ] && export LC_TIME
|
||||
[ -n "${LC_COLLATE}" ] && export LC_COLLATE
|
||||
[ -n "${LC_MONETARY}" ] && export LC_MONETARY
|
||||
[ -n "${LC_MESSAGES}" ] && export LC_MESSAGES
|
||||
[ -n "${LC_ALL}" ] && export LC_ALL
|
||||
fi
|
||||
|
||||
einfo "You can modify the paths and options passed to initdb by editing:"
|
||||
einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}"
|
||||
einfo
|
||||
einfo "Information on options that can be passed to initdb are found at:"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html"
|
||||
einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html"
|
||||
einfo
|
||||
einfo "PG_INITDB_OPTS is currently set to:"
|
||||
if [[ -z "${PG_INITDB_OPTS}" ]] ; then
|
||||
einfo " (none)"
|
||||
else
|
||||
einfo " ${PG_INITDB_OPTS}"
|
||||
fi
|
||||
einfo
|
||||
einfo "Configuration files will be installed to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo
|
||||
einfo "The database cluster will be created in:"
|
||||
einfo " ${DATA_DIR}"
|
||||
einfo
|
||||
while [ "$correct" != "true" ] ; do
|
||||
einfo "Are you ready to continue? (y/n)"
|
||||
read answer
|
||||
if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then
|
||||
correct="true"
|
||||
elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then
|
||||
die "Aborting initialization."
|
||||
else
|
||||
echo "Answer not recognized"
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ] ; then
|
||||
eerror "The given directory, '${DATA_DIR}', is not empty."
|
||||
eerror "Modify DATA_DIR to point to an empty directory."
|
||||
die "${DATA_DIR} is not empty."
|
||||
fi
|
||||
|
||||
einfo "Creating the data directory ..."
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
mkdir -p "${DATA_DIR}"
|
||||
chown -Rf postgres:postgres "${DATA_DIR}"
|
||||
chmod 0700 "${DATA_DIR}"
|
||||
fi
|
||||
|
||||
einfo "Initializing the database ..."
|
||||
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}"
|
||||
else
|
||||
"${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS}
|
||||
fi
|
||||
|
||||
if [[ "${DATA_DIR%/}" != "${PGDATA%/}" ]] ; then
|
||||
mv "${DATA_DIR%/}"/{pg_{hba,ident},postgresql}.conf "${PGDATA}"
|
||||
ln -s "${PGDATA%/}"/{pg_{hba,ident},postgresql}.conf "${DATA_DIR%/}"
|
||||
fi
|
||||
|
||||
cat <<- EOF >> "${PGDATA%/}"/postgresql.conf
|
||||
# This is here because of https://bugs.gentoo.org/show_bug.cgi?id=518522
|
||||
# On the off-chance that you might need to work with UTF-8 encoded
|
||||
# characters in PL/Perl
|
||||
plperl.on_init = 'use utf8; use re; package utf8; require "utf8_heavy.pl";'
|
||||
EOF
|
||||
|
||||
einfo "The autovacuum function, which was in contrib, has been moved to the main"
|
||||
einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled"
|
||||
einfo "by default. You can disable it in the cluster's:"
|
||||
einfo " ${PGDATA%/}/postgresql.conf"
|
||||
einfo
|
||||
einfo "The PostgreSQL server, by default, will log events to:"
|
||||
einfo " ${DATA_DIR%/}/postmaster.log"
|
||||
einfo
|
||||
if use prefix ; then
|
||||
einfo "The location of the configuration files have moved to:"
|
||||
einfo " ${PGDATA}"
|
||||
einfo "To start the server:"
|
||||
einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'"
|
||||
einfo "To stop:"
|
||||
einfo " pg_ctl stop -D ${DATA_DIR}"
|
||||
einfo
|
||||
einfo "Or move the configuration files back:"
|
||||
einfo "mv ${PGDATA}*.conf ${DATA_DIR}"
|
||||
else
|
||||
einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL"
|
||||
einfo "instead of 'pg_ctl'."
|
||||
fi
|
||||
}
|
||||
|
||||
src_test() {
|
||||
einfo ">>> Test phase [check]: ${CATEGORY}/${PF}"
|
||||
|
||||
if use server && [[ ${UID} -ne 0 ]] ; then
|
||||
emake check
|
||||
|
||||
einfo "If you think other tests besides the regression tests are necessary, please"
|
||||
einfo "submit a bug including a patch for this ebuild to enable them."
|
||||
else
|
||||
use server || \
|
||||
ewarn 'Tests cannot be run without the "server" use flag enabled.'
|
||||
[[ ${UID} -eq 0 ]] || \
|
||||
ewarn 'Tests cannot be run as root. Enable "userpriv" in FEATURES.'
|
||||
|
||||
ewarn 'Skipping.'
|
||||
fi
|
||||
}
|
@ -0,0 +1,37 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
DESCRIPTION="PKCS#11 helper library"
|
||||
HOMEPAGE="http://www.opensc-project.org/opensc/wiki/pkcs11-helper"
|
||||
SRC_URI="mirror://sourceforge/opensc/${PN}/${P}.tar.bz2"
|
||||
|
||||
LICENSE="|| ( BSD GPL-2 )"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
|
||||
IUSE="doc gnutls libressl nss static-libs"
|
||||
|
||||
RDEPEND="
|
||||
!libressl? ( >=dev-libs/openssl-0.9.7:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
gnutls? ( >=net-libs/gnutls-1.4.4 )
|
||||
nss? ( dev-libs/nss )"
|
||||
DEPEND="${RDEPEND}
|
||||
virtual/pkgconfig
|
||||
doc? ( >=app-doc/doxygen-1.4.7 )"
|
||||
|
||||
src_configure() {
|
||||
econf \
|
||||
--docdir="${EPREFIX}/usr/share/doc/${PF}" \
|
||||
$(use_enable doc) \
|
||||
$(use_enable gnutls crypto-engine-gnutls) \
|
||||
$(use_enable nss crypto-engine-nss) \
|
||||
$(use_enable static-libs static)
|
||||
}
|
||||
|
||||
src_install() {
|
||||
default
|
||||
find "${ED}" -name '*.la' -exec rm -f {} +
|
||||
}
|
@ -0,0 +1,122 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
inherit eutils toolchain-funcs flag-o-matic multilib versionator
|
||||
|
||||
MY_P="${P/_}"
|
||||
MY_DOCP="${PN}-$(get_version_component_range 1-3)-all-doc"
|
||||
|
||||
DESCRIPTION="C++ class libraries to simplify the development of network-centric, portable applications"
|
||||
HOMEPAGE="http://pocoproject.org/"
|
||||
SRC_URI="http://pocoproject.org/releases/poco-$(get_version_component_range 1-3)/${MY_P}-all.tar.bz2
|
||||
doc? ( mirror://sourceforge/poco/${MY_DOCP}.zip )"
|
||||
LICENSE="Boost-1.0"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~arm ~x86"
|
||||
IUSE="doc examples iodbc libressl mysql odbc sqlite ssl test"
|
||||
|
||||
DEPEND=">=dev-libs/libpcre-8.13
|
||||
dev-libs/expat
|
||||
sys-libs/zlib
|
||||
mysql? ( virtual/mysql )
|
||||
odbc? ( iodbc? ( dev-db/libiodbc )
|
||||
!iodbc? ( dev-db/unixODBC ) )
|
||||
ssl? (
|
||||
!libressl? ( dev-libs/openssl:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
)
|
||||
sqlite? ( dev-db/sqlite:3 )"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
S="${WORKDIR}/${MY_P}-all"
|
||||
|
||||
src_prepare() {
|
||||
epatch \
|
||||
"${FILESDIR}"/${PV}-gentoo.patch \
|
||||
"${FILESDIR}"/poco-1.4.4-patch-for-libpcre-8.32.patch
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
targets="libexecs"
|
||||
odbc="unixodbc"
|
||||
|
||||
if use ssl; then
|
||||
targets="${targets} NetSSL_OpenSSL-libexec Crypto-libexec"
|
||||
echo NetSSL_OpenSSL >> components
|
||||
echo Crypto >> components
|
||||
fi
|
||||
if use odbc; then
|
||||
targets="${targets} Data/ODBC-libexec"
|
||||
echo Data/ODBC >> components
|
||||
if use iodbc; then
|
||||
append-flags "-I/usr/include/iodbc"
|
||||
odbc="iodbc"
|
||||
fi
|
||||
fi
|
||||
if use sqlite; then
|
||||
targets="${targets} Data/SQLite-libexec"
|
||||
echo Data/SQLite >> components
|
||||
fi
|
||||
if use mysql; then
|
||||
targets="${targets} Data/MySQL-libexec"
|
||||
echo Data/MySQL >> components
|
||||
fi
|
||||
|
||||
if use test; then
|
||||
targets="${targets} cppunit tests"
|
||||
echo CppUnit >> components
|
||||
use ssl && targets="${targets} NetSSL_OpenSSL-tests Crypto-tests"
|
||||
use odbc && targets="${targets} Data/ODBC-tests"
|
||||
use sqlite && targets="${targets} Data/SQLite-tests"
|
||||
use mysql && targets="${targets} Data/MySQL-tests"
|
||||
fi
|
||||
|
||||
local myconf
|
||||
use test || myconf="--no-tests"
|
||||
# not autoconf
|
||||
./configure \
|
||||
--no-samples ${myconf} \
|
||||
--prefix=/usr \
|
||||
--unbundled \
|
||||
|| die "configure failed"
|
||||
|
||||
sed -i \
|
||||
-e 's|-O2||g' \
|
||||
-e "s|CC = .*|CC = $(tc-getCC)|" \
|
||||
-e "s|CXX = .*|CXX = $(tc-getCXX)|" \
|
||||
-e "s|RANLIB = .*|RANLIB = $(tc-getRANLIB)|" \
|
||||
-e "s|LIB = ar|LIB = $(tc-getAR)|" \
|
||||
-e "s|STRIP = .*|STRIP = /bin/true|" \
|
||||
-e "s|CFLAGS = |CFLAGS = ${CFLAGS}|" \
|
||||
-e "s|CXXFLAGS = |CXXFLAGS = ${CXXFLAGS} |" \
|
||||
-e "s|LINKFLAGS =|LINKFLAGS = ${LDFLAGS} |" \
|
||||
-e "s|SHAREDOPT_LINK = -Wl,-rpath,\$(LIBPATH)|SHAREDOPT_LINK =|" \
|
||||
build/config/Linux build/config/FreeBSD || die "sed failed"
|
||||
sed -i -e "s|SHLIBFLAGS)|SHLIBFLAGS) ${LDFLAGS}|" build/rules/lib || die
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
emake POCO_PREFIX=/usr GENTOO_ODBC="${odbc}" LIBDIR="$(get_libdir)" ${targets} || die "emake failed"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake POCO_PREFIX=/usr LIBDIR="$(get_libdir)" DESTDIR="${D}" install || die "emake install failed"
|
||||
|
||||
dodoc CHANGELOG CONTRIBUTORS NEWS README
|
||||
|
||||
use doc && dohtml -r "${WORKDIR}/${MY_DOCP}"/*
|
||||
|
||||
if use examples ; then
|
||||
for d in Net XML Data Util NetSSL_OpenSSL Foundation ; do
|
||||
insinto /usr/share/doc/${PF}/examples/${d}
|
||||
doins -r ${d}/samples
|
||||
done
|
||||
find "${D}/usr/share/doc/${PF}/examples" \
|
||||
-iname "*.sln" -or -iname "*.vcproj" -or \
|
||||
-iname "*.vmsbuild" -or -iname "*.properties" \
|
||||
| xargs rm
|
||||
fi
|
||||
}
|
@ -0,0 +1,43 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=4
|
||||
|
||||
DESCRIPTION="Uriparser is a strictly RFC 3986 compliant URI parsing library in C"
|
||||
HOMEPAGE="http://uriparser.sourceforge.net/"
|
||||
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
|
||||
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~x86-solaris"
|
||||
IUSE="doc qt4 test unicode"
|
||||
|
||||
RDEPEND=""
|
||||
DEPEND="virtual/pkgconfig
|
||||
doc? ( >=app-doc/doxygen-1.5.8
|
||||
qt4? ( dev-qt/qthelp:4 ) )
|
||||
test? ( >=dev-util/cpptest-1.1.1 )"
|
||||
|
||||
REQUIRED_USE="test? ( unicode )"
|
||||
|
||||
src_configure() {
|
||||
econf \
|
||||
--disable-sizedown \
|
||||
$(use_enable test) \
|
||||
--enable-char \
|
||||
$(use_enable unicode wchar_t) \
|
||||
$(use_enable doc) \
|
||||
--disable-dependency-tracking \
|
||||
--docdir=/usr/share/doc/${PF}/
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install || die "make install failed"
|
||||
dodoc AUTHORS ChangeLog THANKS || die
|
||||
|
||||
if use doc && use qt4; then
|
||||
insinto /usr/share/doc/${PF}/
|
||||
doins doc/*.qch || die # Using doins to avoid dodoc's compression
|
||||
fi
|
||||
}
|
@ -1,21 +0,0 @@
|
||||
# Copyright 1999-2014 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
MODULE_AUTHOR=MLEHMANN
|
||||
MODULE_VERSION=2.15
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION="Simple but non-blocking HTTP/HTTPS client"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64 x86"
|
||||
IUSE=""
|
||||
|
||||
RDEPEND=">=dev-perl/AnyEvent-6
|
||||
dev-perl/common-sense"
|
||||
DEPEND="${RDEPEND}"
|
||||
|
||||
SRC_TEST="do"
|
@ -1,25 +0,0 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
MODULE_AUTHOR=MLEHMANN
|
||||
MODULE_VERSION=2.21
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION="Simple but non-blocking HTTP/HTTPS client"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
RDEPEND="
|
||||
>=dev-perl/AnyEvent-5.330.0
|
||||
>=dev-perl/common-sense-3.300.0
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
virtual/perl-ExtUtils-MakeMaker
|
||||
"
|
||||
|
||||
SRC_TEST="do"
|
@ -1,3 +1 @@
|
||||
DIST AnyEvent-HTTP-2.15.tar.gz 27311 SHA256 7e1467ad76a6d77bb93426e4db375b2f550e39452ce4ed9173e586987a911f30 SHA512 16da33285e47264550e12a1433628bbcb540a5706a51d856435cc6a593944aa513dc908861c72e7eae6044fe7401148e0e9dfe04140392c7dc1f3d02e0a87787 WHIRLPOOL ed946968050b127e424e5a7137b3272d93620ca5f4537c7ecbad62c2ce2e2de1d7550dcac769efa818604e49c26cbc674956b7efef9a50ede8acb1fd3dccb052
|
||||
DIST AnyEvent-HTTP-2.21.tar.gz 26710 SHA256 9d4b30fe2f1b0f50f39feb72c237a7cc67dfadeb761afcb1ace78f0a6110256e SHA512 c3b940d9b419102bf49b8c38f991e350ca25eaf87255e1de6c49f1172091e8c0cb692d191e406f80ac05f77297b7c95fdb551893bbea02b0d18e08374a30b0e4 WHIRLPOOL 10d1624870b809c9866e758931ed2147d32d902145860b90e2e11c0a96feaab6a7f61dcacf5484eba4a10e725de4939e0d3da5081655321d0a6a7c674eb0e8ab
|
||||
DIST AnyEvent-HTTP-2.22.tar.gz 27965 SHA256 864544a4f35b3f14b59f42a26d338d98cfe8fae726eb3578dcf36eed0df5aa6e SHA512 3408b5339cc85e8d37dc6c4f40a0f1ad9436fb9b261e6a14b5a7913f8ee6c2ba7e80aec376af48190c76219fbcadf9c68c2d67c4ab60c77044093f6ec70f4aac WHIRLPOOL b8c92e89a9a22a1a2376c2893c190e3f5fe83f8017b1da6b3d33fc1807d3a24243f2048f904df682683fe22629aa875efb157e176b072f7f9ab0f2da9a4e22ae
|
||||
|
@ -1,25 +0,0 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
MODULE_AUTHOR=BINGOS
|
||||
MODULE_VERSION=2.14
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION='Mapping Perl releases on CPAN to the location of the tarballs'
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="test"
|
||||
|
||||
RDEPEND=""
|
||||
DEPEND="${RDEPEND}
|
||||
virtual/perl-ExtUtils-MakeMaker
|
||||
test? (
|
||||
virtual/perl-File-Spec
|
||||
virtual/perl-IO
|
||||
>=virtual/perl-Test-Simple-0.470.0
|
||||
)
|
||||
"
|
||||
|
||||
SRC_TEST="do parallel"
|
@ -1,2 +1 @@
|
||||
DIST CPAN-Perl-Releases-2.14.tar.gz 23361 SHA256 f25b724425ce874fc9c8dfc9a68635ee4f1607933a5c7d8d6f91fd5e958ab94b SHA512 413445ae36df4b9c93e7094242d2d7b54a943f2bbc0b2763ea0aebf0bdced7d7ae1a9996d39677053510715cd2862684504097b28864ebdbdaa7cf838a55bd53 WHIRLPOOL 248816017577b555a4e6829366f018da2d3b41d4ddb1ad29d461dcb6d2f4fb266ca0afb914646bdc3df595d1d5df712153685316fc586bebabf7cecf2ccb4423
|
||||
DIST CPAN-Perl-Releases-2.34.tar.gz 24163 SHA256 a4e3236b024c2b1b2f837222f433e6108b7adf926ec0883d205921d0d8e0928c SHA512 160014056e17cf6d6a111fd59beb4c5c6b574f992346821b5ed97e2d5b6e69ccfd0033572093eecfd8ed5384727ebb1dc56f7e59238573c85a182badc8cfe3cc WHIRLPOOL 7431e6a9e58e77b1d331611cbb4a31071e6285ccba659613ad74190032f29b10da100402c819b7014450facacddc8279cd610a6879cdae66a7e8104bfe3ad415
|
||||
|
@ -1,25 +0,0 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
MODULE_AUTHOR=BINGOS
|
||||
MODULE_VERSION=1.34
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION="Patch perl source a la Devel::PPPort's buildperl.pl"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
RDEPEND="
|
||||
>=dev-perl/File-pushd-1.0.0
|
||||
virtual/perl-IO
|
||||
virtual/perl-MIME-Base64
|
||||
dev-perl/Module-Pluggable
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
virtual/perl-ExtUtils-MakeMaker
|
||||
"
|
||||
|
||||
SRC_TEST="do parallel"
|
@ -1,2 +1 @@
|
||||
DIST Devel-PatchPerl-1.34.tar.gz 108652 SHA256 be294c95841f521a6b53f429e4fd2fc6f4b34a7fa1d66a8bba7434d5d12af643 SHA512 9e25285dd0a9c67357e627bd144fc43e5fa7644e6f647f9e69e84550c63e1173ca068cee8a883be6540c1d7a4f16533c7751552dfcf525260da187ea41a4e6b1 WHIRLPOOL 7b9761ce66db4cbe08ee1c1f1f8d473d1b0afc47aabf34b2de931019554691363acb41ba499e2939397484d8c8839c6a5d0855dc49650e836bc4fd9f7e54e905
|
||||
DIST Devel-PatchPerl-1.38.tar.gz 109406 SHA256 f3e55d9211f984c5956e7decd85e5d59b4d1613d3543bb4007be6f3d89ae2725 SHA512 4762d956107d7d86f1208ec706df5399493a388f8af24c741c20ef1aaa8b9202e1f6528725c2ee7e33e192c9c1b8d218774fcc5b4428d48683d1c56679fd134a WHIRLPOOL e9415fffde1afe6fc610d8c253d9724444ef88f2a05d719721ed148e24ca72298eed62a3096583906a80c5cba4ced12a1fafccd5f214dcd11a96f3781733cfa2
|
||||
|
@ -1,17 +0,0 @@
|
||||
# Copyright 1999-2014 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
MODULE_AUTHOR=MLEHMANN
|
||||
MODULE_VERSION=1.022
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION="Safe cleanup blocks"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
SRC_TEST="do"
|
@ -1,2 +1 @@
|
||||
DIST Guard-1.022.tar.gz 6793 SHA256 35f1ba97f19a5029ecd1eba94399259592e359e0f5686aef6e758496484a5869 SHA512 9eb1c4fa29f6190115fe11215ff5d27bb3e7f5ab60c7f40c4142ad9ff8aad91b0b169204e4d0f1b1638381c0c99e6a0b5627b8b6d60fad62f1392a9d1e49751e WHIRLPOOL 463c8231bb56114d2c75fedd3efc96c00b4401e5f15ad767a2520804fe0f5d37f2906538eddfe7b831fd1aeba32c7e5dcd1a57be1ff0aa3375452d91d40d1575
|
||||
DIST Guard-1.023.tar.gz 7065 SHA256 34c4ddf91fc93d1090d86da14df706d175b1610c67372c01e12ce9555d4dd1dc SHA512 a991d6f9ebfadffbcabaccc45d964c40c46c7212c6de089f0c496040e151236c59cc7dd7076464f0ef96936f2c4cd462fbedf8e729d522f1090682eda976676f WHIRLPOOL 63eb6e3167adf35fa3bb428b28e768f0922fa7e7df36243631ded455eefa3259af241ed8d857bd048856465ba42fabc81e0794e12ed71c19878f6968b06bd9d9
|
||||
|
@ -1,20 +0,0 @@
|
||||
# Copyright 1999-2014 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
MODULE_AUTHOR=MIYAGAWA
|
||||
MODULE_VERSION=0.15
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION="Store multiple values per key"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
RDEPEND="dev-perl/Filter"
|
||||
DEPEND="${RDEPEND}"
|
||||
|
||||
SRC_TEST=do
|
@ -1,2 +1 @@
|
||||
DIST Hash-MultiValue-0.15.tar.gz 19827 SHA256 805d0eba514f18d9af60f7d8baf50b5b6e004bbaa12da43642d40575f93c83c9 SHA512 fd97db887590c8c9ecbd0e58434df01fae8e3d2aa2335245ea1217d454e50c3bf1177921dd340f4cca3685808bebc573d13c892da7ccd685d3658c1db9d96465 WHIRLPOOL 6e53b5f51d85eb5adf09dd5648321b1a62838345d052bf28c934fcffc3aac0e0d7bd689089cc96659db3252530a495ecf106c3f3024b90419402730e11e8cab3
|
||||
DIST Hash-MultiValue-0.16.tar.gz 19841 SHA256 66181df7aa68e2786faf6895c88b18b95c800a8e4e6fb4c07fd176410a3c73f4 SHA512 a6e1cab00ff24492bc84343b83a1282ad0eaded6633e7c511389dfb1d21cd8987dc2f1ad9ab69df69f36b651d68c70df3160666ff9ee584dbb1b6ab7095b78ac WHIRLPOOL 57e563f204b16e46c6052655a37cc09e72c82203d6a85f07b5d171aec5be4287b4c1935bab5702f6c13412e862e21868f5ccaa5d9e49e01d64e7179acb1ca30a
|
||||
|
@ -1 +1 @@
|
||||
DIST Net-ARP-1.0.6.tgz 17304 SHA256 c285a78e1ca8f516d72dd9a5207737687282ba6c59046b890717e6adf421ba05 SHA512 6b5b6b4b5255e5bb9e9b85e359083e4c859d98da868e19af21571dd211d0b2622e667522d047fd724aedfc7c66e464677b8e90aa823160b6a965bc5a84420a90 WHIRLPOOL df92b37f581faa41827477ab00cfd4b35737beae79322691b73d92581e6ce82e0bac1be9ce5154b5e2d807370ae9b7e951a1a9fa13c0027db83dfde4f086cfe0
|
||||
DIST Net-ARP-1.0.9.tgz 71377 SHA256 53fc3883755d75bed1671f9844f131ad364bdfb18313ed1ea78dc67b6901b18e SHA512 c2dc333ab4675709a4b2d9e53cbcc2f7cb226b89c366a841240d9b8a72802f2ad68c8acc40b27878c720198b63df34cd26091cd5f3ae528b597d4b214a316a91 WHIRLPOOL 879ca15bfbca34192ce4a364ea9b61deb8384c3b86c494b9ab52bbe57419b6ddfe0f1d0e165e6a97f52e1e128da2e4801a17aa93589875872a459f29657c64f0
|
||||
|
@ -1,5 +1 @@
|
||||
DIST Net-SSH2-0.46.tar.gz 112190 SHA256 814f662140956d8b39cae277c1341d17b6be4494283cefbce70d234c8082dfe0 SHA512 36ffed2c96660c3a009b3ad42c944450cd710426953fb909d1e8989dcdb3d0d7807361c672d4904bff33cd1a206479149e7f2dc09c16b806a9ff2a6355e41ed8 WHIRLPOOL 9854701fb497306566bee86c5850fd7fc0466ce639c5ac794f63502b02dc093af60699625e57605660a0fc0a310b808ad3d313b72802a33b771482bbcdcbdd9f
|
||||
DIST Net-SSH2-0.47.tar.gz 114097 SHA256 b3f6c01dd98f347a7fa73fb470fb5abeebbe0820349b9ead8b622f02fae0ad4a SHA512 164a1c5752015cd405e733eaab24d8f0399fdc615a1e2bafb3c98f200f6feaa9eee72c59cdb829d373a34c78e2f4581156d96a2a2bf0bb45f402902d58fd6135 WHIRLPOOL 894dac5dd3414ea4b055f8ddf57cab0b4373dd76884a3e7627f6fe71bd431f36e779fab7553d02cd5c3bc90624056e53e30661982cfedb71513bc318cf83ac2f
|
||||
DIST Net-SSH2-0.48.tar.gz 114268 SHA256 b62c9fd708da50b0fc8a25d525e1416612b2095e377ec490651177c57de83a5d SHA512 b383f3f160e652f588096dc05c9d24a1c689367af6647537d5343384c08f869479a4c53e2cf1964fc87fa11d15db69c60c1708d6c2ab46e97a4472d0c1442a89 WHIRLPOOL 384636170a95990c7ed21098132ebf2516f26ef76a13022be439b8f6cc2e99fad9db86f4ee755968bdcb0d87d6f7258064b2c455ad464af868228c52f86fdfe8
|
||||
DIST Net-SSH2-0.52.tar.gz 114675 SHA256 d2bfa64d9d489c1be2e635fc70fcc1d69b0d3b11e1be24683151e1d10bb4dce1 SHA512 a5721ea48478191923808595cd43dbccb468902fc4feae38642c9ee1aa0fa86218afcaa9639cb776fc03eb4542e489660b6b7c229033750cd340f622b67d9834 WHIRLPOOL 49f45c6aa561370c398326c0e20123dd5b538527fdd9da7ba4d5c728e6652d0b83209775696e2e27cea24727ab0802613e1c1871f0e2a11f198937f341f60c2d
|
||||
DIST Net-SSH2-0.53.tar.gz 114860 SHA256 f072ecb816c6b9ef9ad03057a765590e8bc1ad401fdea215f272fa8405ce57dc SHA512 c3aaa97f2c5fe987c5f28fca2d6687b6ff759d6ab70f6136e581f439cd06af70de5410628187c94168db43464e0713eeed9f50185f7bf0305fd01e0ac7ee5817 WHIRLPOOL 647d02e1ea6289fb2c4ed1b566b225155b6ccadf15860184dd5f82be815d8a7eb8f49d937999f21a93fdbafefa9cc6ef9ef32bc8e144ba816b8afd9520d00bbd
|
||||
DIST Net-SSH2-0.55.tar.gz 123165 SHA256 492a23eba5e9951944087262a042136269c1434a678e0148ca3202e50259a43e SHA512 6ada62f1863c23d11bc09087e8336fcfdd3dfc3dec533d93151ab9d5cb41132601585809b7e5ed5ce03430dab6b063353d68600f9912ddb460f6ad661df31f51 WHIRLPOOL dd0ba4105bc7fca2f29e2803c887af19f5c4ede531ca14ffbbb6415c7d730d59619b897fd2833e0bc2348abec1c545a87138800048de0972538cce671406b8a1
|
||||
|
@ -1,21 +0,0 @@
|
||||
# Copyright 1999-2014 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
MODULE_AUTHOR=RKITOVER
|
||||
MODULE_VERSION=0.46
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION="Net::SSH2 - Support for the SSH 2 protocol via libssh2"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
RDEPEND="net-libs/libssh2
|
||||
>=virtual/perl-ExtUtils-MakeMaker-6.50"
|
||||
DEPEND="${RDEPEND}"
|
||||
|
||||
SRC_TEST="do"
|
@ -1,36 +0,0 @@
|
||||
# Copyright 1999-2014 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
MODULE_AUTHOR=RKITOVER
|
||||
MODULE_VERSION=0.47
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION="Net::SSH2 - Support for the SSH 2 protocol via libssh2"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="gcrypt"
|
||||
|
||||
RDEPEND="
|
||||
sys-libs/zlib
|
||||
net-libs/libssh2
|
||||
!gcrypt? (
|
||||
dev-libs/openssl
|
||||
)
|
||||
gcrypt? (
|
||||
dev-libs/libgcrypt:0
|
||||
)
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
>=virtual/perl-ExtUtils-MakeMaker-6.50
|
||||
"
|
||||
|
||||
SRC_TEST="do"
|
||||
|
||||
src_configure() {
|
||||
use gcrypt && myconf=gcrypt
|
||||
perl-module_src_configure
|
||||
}
|
@ -1,36 +0,0 @@
|
||||
# Copyright 1999-2014 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
MODULE_AUTHOR=RKITOVER
|
||||
MODULE_VERSION=0.48
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION="Net::SSH2 - Support for the SSH 2 protocol via libssh2"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="gcrypt"
|
||||
|
||||
RDEPEND="
|
||||
sys-libs/zlib
|
||||
net-libs/libssh2
|
||||
!gcrypt? (
|
||||
dev-libs/openssl
|
||||
)
|
||||
gcrypt? (
|
||||
dev-libs/libgcrypt:0
|
||||
)
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
>=virtual/perl-ExtUtils-MakeMaker-6.50
|
||||
"
|
||||
|
||||
SRC_TEST="do"
|
||||
|
||||
src_configure() {
|
||||
use gcrypt && myconf=gcrypt
|
||||
perl-module_src_configure
|
||||
}
|
@ -1,36 +0,0 @@
|
||||
# Copyright 1999-2014 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
MODULE_AUTHOR=RKITOVER
|
||||
MODULE_VERSION=0.52
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION="Net::SSH2 - Support for the SSH 2 protocol via libssh2"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="gcrypt"
|
||||
|
||||
RDEPEND="
|
||||
sys-libs/zlib
|
||||
net-libs/libssh2
|
||||
!gcrypt? (
|
||||
dev-libs/openssl
|
||||
)
|
||||
gcrypt? (
|
||||
dev-libs/libgcrypt:0
|
||||
)
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
>=virtual/perl-ExtUtils-MakeMaker-6.50
|
||||
"
|
||||
|
||||
SRC_TEST="do"
|
||||
|
||||
src_configure() {
|
||||
use gcrypt && myconf=gcrypt
|
||||
perl-module_src_configure
|
||||
}
|
@ -1,36 +0,0 @@
|
||||
# Copyright 1999-2014 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
MODULE_AUTHOR=RKITOVER
|
||||
MODULE_VERSION=0.53
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION="Net::SSH2 - Support for the SSH 2 protocol via libssh2"
|
||||
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="gcrypt"
|
||||
|
||||
RDEPEND="
|
||||
sys-libs/zlib
|
||||
net-libs/libssh2
|
||||
!gcrypt? (
|
||||
dev-libs/openssl
|
||||
)
|
||||
gcrypt? (
|
||||
dev-libs/libgcrypt:0
|
||||
)
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
>=virtual/perl-ExtUtils-MakeMaker-6.50
|
||||
"
|
||||
|
||||
SRC_TEST="do"
|
||||
|
||||
src_configure() {
|
||||
use gcrypt && myconf=gcrypt
|
||||
perl-module_src_configure
|
||||
}
|
@ -1,2 +1 @@
|
||||
DIST local-lib-1.008026.tar.gz 67540 SHA256 4c8ce3b5bdf2ff1868153e84bc0ce0c503adec145a6de3664f031b9f54fd04c2 SHA512 8923abcf78794da4a1ce71005e43e179f7009b08c3b05e0a76c3a6c6d61961ed066f83f52548a07c55d0a7b58965f57ab3b3a16afdf820fe014476ef4b743396 WHIRLPOOL 3151fc70212df4a167924e20587513a4683ee5c92b56424964f82f14cb7563a49dce60d907a990442b5c89c7a4b5c0987810e4d3cf518171e998820a4eec2aee
|
||||
DIST local-lib-2.000014.tar.gz 51593 SHA256 ae63356ab780c5a3aa46287b48daea748a3dd021d9b52dff8bf480b43787fa2b SHA512 3a7bb68af992215eb6787082fea7c09d5468aabe5c6478d028ce99ae878f6efdd8982804ba2c396af1fc0a5b46a4fa7f0e4831d9c32f1abd41ef631976c5efe8 WHIRLPOOL 990e3ca60a88544a0394fbb994832aff9c50988dde0372d8d7e437a72c28d30bf27438acfb8423aa57965bf58140e7a3284d6151a80cbd51bffc4ed201b6e6c1
|
||||
|
@ -1,42 +0,0 @@
|
||||
--- Makefile.PL 2013-11-05 18:07:13.000000000 +0000
|
||||
+++ Makefile.PL 2013-12-23 15:21:32.582135695 +0000
|
||||
@@ -37,6 +37,10 @@
|
||||
DEATH
|
||||
|
||||
my $cwd;
|
||||
+
|
||||
+{ # GENTOO
|
||||
+ last;
|
||||
+
|
||||
BEGIN {
|
||||
$cwd = Cwd::cwd();
|
||||
# watch out for fancy dashes. these can wind up in our @ARGV if the user is
|
||||
@@ -176,6 +180,8 @@
|
||||
}
|
||||
}
|
||||
|
||||
+} # END GENTOO
|
||||
+
|
||||
use inc::Module::Install;
|
||||
|
||||
name 'local-lib';
|
||||
@@ -185,6 +191,9 @@
|
||||
requires 'ExtUtils::Install' => '1.43'; # version INSTALL_BASE was added
|
||||
requires 'Module::Build' => '0.36'; # PERL_MB_OPT
|
||||
|
||||
+{ # GENTOO
|
||||
+ last;
|
||||
+
|
||||
# don't bother fixing CPAN.pm if bootstrapped from cpanminus
|
||||
unless ($ENV{PERL5_CPANM_IS_RUNNING}) {
|
||||
my $required_CPAN = '1.82';
|
||||
@@ -251,6 +260,9 @@
|
||||
auto_install;
|
||||
}
|
||||
chdir($cwd);
|
||||
+
|
||||
+} # END GENTOO
|
||||
+
|
||||
resources(
|
||||
# r/w: p5sagit@git.shadowcat.co.uk:local-lib.git
|
||||
repository => 'git://git.shadowcat.co.uk/p5sagit/local-lib.git',
|
@ -1,29 +0,0 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
MODULE_AUTHOR=HAARG
|
||||
MODULE_VERSION=1.008026
|
||||
inherit perl-module
|
||||
|
||||
DESCRIPTION='create and use a local lib/ for perl modules with PERL5LIB'
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}/${MODULE_VERSION}/0001_No_CPAN.patch"
|
||||
)
|
||||
|
||||
RDEPEND="
|
||||
>=virtual/perl-CPAN-1.820.0
|
||||
>=virtual/perl-ExtUtils-Install-1.430.0
|
||||
>=virtual/perl-ExtUtils-MakeMaker-6.740.0
|
||||
>=dev-perl/Module-Build-0.360.0
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
>=virtual/perl-ExtUtils-MakeMaker-6.590.0
|
||||
"
|
||||
|
||||
SRC_TEST="do parallel"
|
@ -1,3 +1,2 @@
|
||||
DIST amodem-1.11.tar.gz 19869 SHA256 00a4c19fb8a9e6dff9459a2cb021c0adc5c669ac1658685f2388457c409931c6 SHA512 f045a771215b50eb387a92209bd1aba0f47f7779b78b720ce49590d6e14ad0b176be6099f78e3b959a61f018b06768bad1f39555c77388d545d088f5cede3fb7 WHIRLPOOL b6b42dd5b240c4704ee26a86a43e9b254673bee2782c976317abf501075b0ed225028df650e03f1b88195c31d75269217ee573ac29370af2afc367cc7488fae9
|
||||
DIST amodem-1.12.0.tar.gz 19926 SHA256 725a9a57f8f636ba61083b557ee36cfb9b2d30b9a226e1ebd23f15c398357199 SHA512 7707545f77c0680959e6df398cf48c6600d2b9f94e26f6752a47a8434475cc4dff4147a00c7a8a89740d203aed4974ea4cb034921c2da93838bac5faf02816c5 WHIRLPOOL ad25d9ffd1979128396bacaad359974db2ba4d2f2d1d9e79dda61ca1108a6909f37ede43f1d12c7c27025486074fcad955caedff599a466a1fa58bfd57290447
|
||||
DIST amodem-1.12.tar.gz 27490 SHA256 d4842f2df83d0eda7036665d0699e2c265a1933a3b0c3d6555040c52bdac282e SHA512 7fc5927137f0c250092aafafcfacd218218874c4bd2803a126f5310cf22aa2339217094420cba7b003492477670ba83c04ff7610fc15b80c905eb75ee35b1d2d WHIRLPOOL 1c5f0337f47ddc5bd4812e891f7fa2c8c5699541eb5530def8d1b7bd2331b7a039c711077ddc5ba6c748b0ab7a887765f859e3782d29e2c0e1ced921a5d18ae1
|
||||
DIST amodem-1.13.tar.gz 20171 SHA256 e24145268ffd0540754d5ce17a21b2602488cd6f0b7be2907f1734e60f73ccc1 SHA512 daf1d86fd201153da46e5b0f31d07c0fdea2dc55aa3136d72de894e6ae6c9ddb753d4cd8227b5e3ac44a6803aff00c3299045ebd620b95d1ee8fb4945e7958b4 WHIRLPOOL cd1c74a9edf2691fa41cec96ac2db66119602fb7a1836b3f87de0c157365fd61c3c259e2a13762dcd756df021bb09e95d7f6ec8cec3ac0f3f0b75596497a4254
|
||||
|
@ -1,18 +0,0 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
PYTHON_COMPAT=( python{2_7,3_3,3_4} pypy pypy3 )
|
||||
|
||||
inherit distutils-r1
|
||||
|
||||
DESCRIPTION="Transmit data between two computers using audio"
|
||||
HOMEPAGE="https://github.com/romanz/amodem"
|
||||
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
|
||||
|
||||
LICENSE="MIT"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE=""
|
@ -1,2 +1,3 @@
|
||||
DIST python-barbicanclient-3.0.1.tar.gz 38349 SHA256 d298ee0fc9e785d44148d4590ac0d9eef05d560e379e98f75a7cb35ed6bfc7c8 SHA512 354d46e85d15af1b91ed4ded55918329d843b7b9d8374bb82a9fde771ca5e71336ecd2bcde65217338f85ffcf8910abb686e0e8853cb8bd0e0022c5298f8392a WHIRLPOOL b68f792f89df005bd1c14cebb44d6b4ba4aa3d391d66daf9714c74bbadd103f40785e8c9ebb8585a64608b3ff7e47ed102284efeffb1f30d49c2a6d5c9886446
|
||||
DIST python-barbicanclient-3.0.3.tar.gz 62286 SHA256 959aca2ce3af2eed0f57e2fa9f0f9a484e40adc6b371e2c0fcc588aae9ca2b18 SHA512 0974af19781029b75e9432005fd1a50a3026531927f3718bf42b999e20877cc126a0bdd37c2de311978c132a0bfa7dbe186eb4f2cc022b8aaf2b7dc3e5c9c794 WHIRLPOOL 36635ebb89a22c898a70ce77f3dee4a88fa6969e432a63b3d554ae5d0d53cf7d5cbc29d6e63300a7acc543a9cfb0428c1ecd71c1c13994138b5c3d490f5a1d9f
|
||||
DIST python-barbicanclient-3.3.0.tar.gz 82210 SHA256 d5c68354fb5d18a6fcdcd0a0788b3f502dd6ffa57a2e47a1426cce2d63ecb6cf SHA512 9c9ea055a375cb631f081ac0dc54ff20f60e6f6c3340b0f0a92a91eed4858202d9f85e00b662a8b3b7b5183633d8f5500f6925df5a182b20046d66be48b34e37 WHIRLPOOL 94a1d91a2bb8c8aaddfe775e7a5e955eace20e75e6c75707bd56aa62a1538193161d14534c1cd9d91ece5fb57a03f0fa7e71370531c576d1f5c35a0ed113830b
|
||||
|
@ -0,0 +1,32 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
PYTHON_COMPAT=( python2_7 python3_4 )
|
||||
|
||||
inherit distutils-r1
|
||||
|
||||
DESCRIPTION="Client library for Barbican API."
|
||||
HOMEPAGE="https://github.com/openstack/barbican"
|
||||
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
DEPEND="
|
||||
dev-python/setuptools[${PYTHON_USEDEP}]
|
||||
>=dev-python/pbr-1.4.0[${PYTHON_USEDEP}]
|
||||
<dev-python/pbr-2.0[${PYTHON_USEDEP}]
|
||||
"
|
||||
RDEPEND="
|
||||
>=dev-python/requests-2.5.2[${PYTHON_USEDEP}]
|
||||
>=dev-python/six-1.9.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/python-keystoneclient-1.6.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/cliff-1.14.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-i18n-1.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-serialization-1.4.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-utils-2.0.0[${PYTHON_USEDEP}]
|
||||
"
|
@ -0,0 +1,65 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
PYTHON_COMPAT=( python2_7 python3_3 python3_4 )
|
||||
|
||||
inherit distutils-r1
|
||||
|
||||
DESCRIPTION="A client for the OpenStack Nova API"
|
||||
HOMEPAGE="https://github.com/openstack/python-novaclient"
|
||||
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
|
||||
IUSE="test"
|
||||
|
||||
CDEPEND="
|
||||
>=dev-python/pbr-1.6[${PYTHON_USEDEP}]
|
||||
<dev-python/pbr-2.0[${PYTHON_USEDEP}]"
|
||||
DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
|
||||
${CDEPEND}
|
||||
test? (
|
||||
>=dev-python/coverage-3.6[${PYTHON_USEDEP}]
|
||||
>=dev-python/fixtures-1.3.1[${PYTHON_USEDEP}]
|
||||
>=dev-python/keyring-2.1[${PYTHON_USEDEP}]
|
||||
!~dev-python/keyring-3.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/mock-1.2[${PYTHON_USEDEP}]
|
||||
>=dev-python/requests-mock-0.6.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/sphinx-1.1.2[${PYTHON_USEDEP}]
|
||||
!~dev-python/sphinx-1.2.0[${PYTHON_USEDEP}]
|
||||
<dev-python/sphinx-1.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/os-client-config-1.4.0[${PYTHON_USEDEP}]
|
||||
!~dev-python/os-client-config-1.6.2[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-sphinx-2.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/testrepository-0.0.18[${PYTHON_USEDEP}]
|
||||
>=dev-python/testscenarios-0.4[${PYTHON_USEDEP}]
|
||||
>=dev-python/testtools-1.4.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/tempest-lib-0.8.0[${PYTHON_USEDEP}]
|
||||
)"
|
||||
RDEPEND="
|
||||
>=dev-python/iso8601-0.1.9[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-i18n-1.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-serialization-1.4.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-utils-2.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/prettytable-0.7[${PYTHON_USEDEP}]
|
||||
<dev-python/prettytable-0.8[${PYTHON_USEDEP}]
|
||||
>=dev-python/requests-2.5.2[${PYTHON_USEDEP}]
|
||||
>=dev-python/simplejson-2.2.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/six-1.9.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/Babel-1.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/python-keystoneclient-1.6.0[${PYTHON_USEDEP}]"
|
||||
|
||||
python_prepare_all() {
|
||||
# built in...
|
||||
sed -i '/^argparse/d' requirements.txt || die
|
||||
sed -i '/^hacking/d' test-requirements.txt || die
|
||||
distutils-r1_python_prepare_all
|
||||
}
|
||||
|
||||
python_test() {
|
||||
testr init
|
||||
testr run --parallel || die "testsuite failed under python2.7"
|
||||
}
|
@ -1,2 +1,3 @@
|
||||
DIST python-openstackclient-1.0.4.tar.gz 203012 SHA256 4ae6d7b35fd1da2a07959fea9639e506871abfb769c62f3692d2f2585605ac85 SHA512 d1076456ec9867c5dd6c13059bff56cb358eb675666cc5c38de0414b8c0ea26e057c286ebe2a0146f68ca50c1a416cac5f680ec72b633879cefafa25c76dc9c9 WHIRLPOOL 25df1e0209145a9e9c9c36676e1423d42129b2f8408aa22fdb18cf75f9b138009033b27002c76832448f026b518671fd49eb4bea8877bed560153ac5a88e2e4d
|
||||
DIST python-openstackclient-1.6.0.tar.gz 256666 SHA256 7400b86fc57032bfd7d4fed317ad2311bfb35ee192200c437b23c2ab85d49b24 SHA512 e62f9265566def5c43dc4fe6d4aeb7c61be802cd7f53db78bb3db681a97b140364afedff07a9e0bcc0622d39d9341150dab3ca7fa230b2c64a6c820d713acc89 WHIRLPOOL 6b7cd39f26fcd106f4e5819af8a54b4fb79e3a1dbb5aff79e7601392e25f6b7a80f94b1ff299e6d80d3afb7a064f03acfa202779f36677098f4b612dfc174d9c
|
||||
DIST python-openstackclient-1.7.1.tar.gz 265368 SHA256 c9a379d5688cf63e5ff9634929bac06204b562d2afe00fca14831ad0799e3240 SHA512 137d6bf2b6a2bd09073ca1ee63f3f6b38568baa3bc93796938e18dc694a6401353598369d8c7028d054cf31eed84bc38869375fa38649d4657b46907ba379b2c WHIRLPOOL afc99ef30eaba71059a3141eb4fe9c5f094e41cf35af12a44cf2209c3244747573651c7cbd722b750c48cc8c6897db574f3af8f1993892e953238e96d1f2f1e0
|
||||
|
@ -0,0 +1,81 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
PYTHON_COMPAT=( python2_7 python3_3 python3_4 )
|
||||
|
||||
inherit distutils-r1
|
||||
|
||||
DESCRIPTION="A client for the OpenStack APIs"
|
||||
HOMEPAGE="https://github.com/openstack/python-openstackclient"
|
||||
SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
|
||||
IUSE="doc test"
|
||||
REQUIRED_USE="test? ( doc )"
|
||||
|
||||
CDEPEND="
|
||||
>=dev-python/pbr-1.6[${PYTHON_USEDEP}]
|
||||
<dev-python/pbr-2.0[${PYTHON_USEDEP}]"
|
||||
DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
|
||||
${CDEPEND}
|
||||
test? (
|
||||
>=dev-python/coverage-3.6[${PYTHON_USEDEP}]
|
||||
>=dev-python/fixtures-1.3.1[${PYTHON_USEDEP}]
|
||||
>=dev-python/mock-1.2[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-sphinx-2.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslotest-1.10.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/requests-mock-0.6.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/os-testr-0.1.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/testrepository-0.0.18[${PYTHON_USEDEP}]
|
||||
>=dev-python/testtools-1.4.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/webob-1.2.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/tempest-lib-0.8.0[${PYTHON_USEDEP}]
|
||||
)
|
||||
doc? (
|
||||
>=dev-python/oslo-sphinx-2.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/sphinx-1.1.2[${PYTHON_USEDEP}]
|
||||
!~dev-python/sphinx-1.2.0[${PYTHON_USEDEP}]
|
||||
<dev-python/sphinx-1.3[${PYTHON_USEDEP}]
|
||||
)"
|
||||
RDEPEND="
|
||||
${CDEPEND}
|
||||
>=dev-python/six-1.9.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/Babel-1.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/cliff-1.14.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/cliff-tablib-1.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/os-client-config-1.4[${PYTHON_USEDEP}]
|
||||
!~dev-python/os-client-config-1.6.2[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-config-2.3.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-i18n-1.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-utils-2.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/python-glanceclient-0.18.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/python-keystoneclient-1.6.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/python-novaclient-2.28.1[${PYTHON_USEDEP}]
|
||||
>=dev-python/python-cinderclient-1.3.1[${PYTHON_USEDEP}]
|
||||
>=dev-python/python-neutronclient-2.6.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/requests-2.5.2[${PYTHON_USEDEP}]
|
||||
>=dev-python/stevedore-1.5.0[${PYTHON_USEDEP}]
|
||||
"
|
||||
|
||||
python_prepare_all() {
|
||||
sed -i '/^hacking/d' test-requirements.txt || die
|
||||
distutils-r1_python_prepare_all
|
||||
}
|
||||
|
||||
python_compile_all() {
|
||||
use doc && esetup.py build_sphinx
|
||||
}
|
||||
|
||||
python_test() {
|
||||
testr init
|
||||
testr run || die "testsuite failed under python2.7"
|
||||
}
|
||||
|
||||
python_install_all() {
|
||||
use doc && local HTML_DOCS=( doc/build/html/. )
|
||||
distutils-r1_python_install_all
|
||||
}
|
@ -0,0 +1,64 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
|
||||
PYTHON_COMPAT=( python2_7 python3_3 python3_4 )
|
||||
|
||||
inherit distutils-r1
|
||||
|
||||
DESCRIPTION="A library to assist in creating functional or integrated test suites for OpenStack projects."
|
||||
HOMEPAGE="https://pypi.python.org/pypi/tempest-lib https://github.com/openstack/tempest-lib"
|
||||
SRC_URI="mirror://pypi/t/${PN}/${P}.tar.gz"
|
||||
|
||||
LICENSE="Apache-2.0"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
IUSE="test"
|
||||
|
||||
CDEPEND="
|
||||
>=dev-python/pbr-1.6[${PYTHON_USEDEP}]
|
||||
<dev-python/pbr-2.0[${PYTHON_USEDEP}]
|
||||
"
|
||||
RDEPEND="
|
||||
${CDEPEND}
|
||||
>=dev-python/Babel-1.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/fixtures-1.3.1[${PYTHON_USEDEP}]
|
||||
>=dev-python/iso8601-0.1.9[${PYTHON_USEDEP}]
|
||||
>=dev-python/jsonschema-2.0.0[${PYTHON_USEDEP}]
|
||||
!~dev-python/jsonschema-2.5.0[${PYTHON_USEDEP}]
|
||||
<dev-python/jsonschema-3.0.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/httplib2-0.7.5[${PYTHON_USEDEP}]
|
||||
>=dev-python/paramiko-1.13.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/six-1.9.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-log-1.8.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/os-testr-0.1.0[${PYTHON_USEDEP}]"
|
||||
DEPEND="
|
||||
${CDEPEND}
|
||||
test? ( ${RDEPEND}
|
||||
>=dev-python/hacking-0.10[${PYTHON_USEDEP}]
|
||||
<dev-python/hacking-0.11[${PYTHON_USEDEP}]
|
||||
>=dev-python/coverage-3.6[${PYTHON_USEDEP}]
|
||||
>=dev-python/subunit-0.0.18[${PYTHON_USEDEP}]
|
||||
>=dev-python/sphinx-1.1.2[${PYTHON_USEDEP}]
|
||||
!~dev-python/sphinx-1.2.0[${PYTHON_USEDEP}]
|
||||
<dev-python/sphinx-1.3[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslo-sphinx-2.5.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/oslotest-1.7.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/testrepository-0.0.18[${PYTHON_USEDEP}]
|
||||
>=dev-python/testscenarios-0.4[${PYTHON_USEDEP}]
|
||||
>=dev-python/testtools-1.4.0[${PYTHON_USEDEP}]
|
||||
>=dev-python/mock-1.1[${PYTHON_USEDEP}]
|
||||
dev-python/nose[${PYTHON_USEDEP}]
|
||||
>=dev-python/ddt-0.7.0[${PYTHON_USEDEP}]
|
||||
)"
|
||||
|
||||
python_prepare_all() {
|
||||
sed -i '/^hacking/d' test-requirements.txt || die
|
||||
distutils-r1_python_prepare_all
|
||||
}
|
||||
|
||||
python_test() {
|
||||
nosetests tempest_lib/tests || die "Tests fail with ${EPYTHON}"
|
||||
}
|
@ -0,0 +1,50 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
inherit autotools eutils
|
||||
|
||||
MY_P="${P^g}"
|
||||
|
||||
DESCRIPTION="A Unix system friendly Scheme Interpreter"
|
||||
HOMEPAGE="http://practical-scheme.net/gauche/"
|
||||
SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tgz"
|
||||
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~x86-macos"
|
||||
IUSE="ipv6 libressl test"
|
||||
|
||||
RDEPEND="sys-libs/gdbm"
|
||||
DEPEND="${RDEPEND}
|
||||
test? (
|
||||
!libressl? ( dev-libs/openssl:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
)"
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
src_prepare() {
|
||||
epatch "${FILESDIR}"/${PN}-rpath.diff
|
||||
epatch "${FILESDIR}"/${PN}-gauche.m4.diff
|
||||
epatch "${FILESDIR}"/${PN}-ext-ldflags.diff
|
||||
epatch "${FILESDIR}"/${PN}-xz-info.diff
|
||||
epatch "${FILESDIR}"/${PN}-rfc.tls.diff
|
||||
eautoconf
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
econf \
|
||||
$(use_enable ipv6) \
|
||||
--with-slib="${EPREFIX}"/usr/share/slib
|
||||
}
|
||||
|
||||
src_test() {
|
||||
emake -j1 -s check
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake -j1 DESTDIR="${D}" install-pkg install-doc
|
||||
dodoc AUTHORS ChangeLog HACKING README
|
||||
}
|
@ -0,0 +1,70 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
inherit eutils toolchain-funcs
|
||||
|
||||
DESCRIPTION="Collection of programs that can be used to automate common tasks in debian/rules"
|
||||
HOMEPAGE="http://packages.qa.debian.org/d/debhelper.html http://joeyh.name/code/debhelper/"
|
||||
SRC_URI="mirror://debian/pool/main/d/${PN}/${P/-/_}.tar.xz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-linux"
|
||||
IUSE="test"
|
||||
DH_LINGUAS=( de es fr )
|
||||
IUSE+=" ${DH_LINGUAS[@]/#/linguas_}"
|
||||
|
||||
NLS_DEPEND=$(
|
||||
printf "linguas_%s? ( >=app-text/po4a-0.24 )\n" ${DH_LINGUAS[@]}
|
||||
)
|
||||
|
||||
RDEPEND="
|
||||
>=dev-lang/perl-5.10:=
|
||||
>=app-arch/dpkg-1.17
|
||||
dev-perl/TimeDate
|
||||
virtual/perl-Getopt-Long
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
${NLS_DEPEND}
|
||||
test? ( dev-perl/Test-Pod )
|
||||
"
|
||||
|
||||
S=${WORKDIR}/${PN}
|
||||
|
||||
src_compile() {
|
||||
tc-export CC
|
||||
|
||||
local LANGS="" USE_NLS=no lingua
|
||||
for lingua in ${DH_LINGUAS[@]}; do
|
||||
if use linguas_${lingua}; then
|
||||
LANGS+=" ${lingua}"
|
||||
USE_NLS=yes
|
||||
fi
|
||||
done
|
||||
|
||||
emake USE_NLS="${USE_NLS}" LANGS="${LANGS}" build
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" PREFIX="${EPREFIX}/usr" install
|
||||
dodoc doc/* debian/changelog
|
||||
docinto examples
|
||||
dodoc examples/*
|
||||
local lingua
|
||||
for manfile in *.1 *.7 ; do
|
||||
for lingua in ${DH_LINGUAS[@]}; do
|
||||
case ${manfile} in
|
||||
*.${lingua}.?)
|
||||
use linguas_${lingua} \
|
||||
&& cp ${manfile} "${T}"/${manfile/.${lingua}/} \
|
||||
&& doman -i18n=${lingua} "${T}"/${manfile/.${lingua}/}
|
||||
;;
|
||||
*)
|
||||
doman ${manfile}
|
||||
;;
|
||||
esac
|
||||
done
|
||||
done
|
||||
}
|
@ -0,0 +1,21 @@
|
||||
diff --git a/source/shared_lib/sources/platform/posix/socket.cpp b/source/shared_lib/sources/platform/posix/socket.cpp
|
||||
index a5d4b92..cb8ceb4 100644
|
||||
--- a/source/shared_lib/sources/platform/posix/socket.cpp
|
||||
+++ b/source/shared_lib/sources/platform/posix/socket.cpp
|
||||
@@ -2563,9 +2563,15 @@ int UPNP_Tools::upnp_init(void *param) {
|
||||
const char *upnp_minissdpdsock = NULL;
|
||||
int upnp_sameport = 0;
|
||||
int upnp_ipv6 = 0;
|
||||
+ unsigned char upnp_ttl = 2;
|
||||
int upnp_error = 0;
|
||||
|
||||
-#ifndef MINIUPNPC_VERSION_PRE1_6
|
||||
+#if (MINIUPNPC_API_VERSION >= 14)
|
||||
+ devlist = upnpDiscover(upnp_delay, upnp_multicastif, upnp_minissdpdsock, upnp_sameport, upnp_ipv6, upnp_ttl, &upnp_error);
|
||||
+
|
||||
+ if(SystemFlags::getSystemSettingType(SystemFlags::debugNetwork).enabled) SystemFlags::OutputDebug(SystemFlags::debugNetwork,"UPnP discover returned upnp_error = %d.\n",upnp_error);
|
||||
+ if(SystemFlags::VERBOSE_MODE_ENABLED) printf("UPnP discover returned upnp_error = %d.\n",upnp_error);
|
||||
+#elif (MINIUPNPC_API_VERSION >= 8)
|
||||
devlist = upnpDiscover(upnp_delay, upnp_multicastif, upnp_minissdpdsock, upnp_sameport, upnp_ipv6, &upnp_error);
|
||||
|
||||
if(SystemFlags::getSystemSettingType(SystemFlags::debugNetwork).enabled) SystemFlags::OutputDebug(SystemFlags::debugNetwork,"UPnP discover returned upnp_error = %d.\n",upnp_error);
|
@ -1 +1 @@
|
||||
DIST pyfa-1.12.0.tar.gz 5898063 SHA256 d22f725efee6cd48a30ccc16a04e913afa1a7e9e89a2004ef8ca12263663ae87 SHA512 c7cda257c0ebffee113df713b8e4a2578fc46ec4493a13341c3907cd8de99c19f4cb1dbae4fe4365134c9ebced618efee2614cb57889a50330d37cf5996ec602 WHIRLPOOL eaf0bc3907b0f32feb601319ca8630e18e8eababb8d3623e56ee3fdc45dfc30946c817e2040e10f0f0e13093672b4faf0e5893088a125bb056d14dd006d623f6
|
||||
DIST pyfa-1.15.0.tar.gz 6243527 SHA256 27ec6748b5f1083050d47a364a8699e521a614c5c643a639441c82168017123c SHA512 c966e3fd7627ef575247b00eacee7392f7f2d32b14485c2a7e5aa0c6f3fe6ad99c1a536bfcbfcc6de29fa4bdc177b6a12e0a571926c1b7b755ef9fc6f76f3bad WHIRLPOOL f6ba22d7f3899c4a3fd702a5d0145b39e06e70793da2682c6bb0df0b3772c02f250b59d05a4fee23f72d87010f02d916a944c0499852dc0be845e1ae56b61904
|
||||
|
@ -0,0 +1,147 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
GCONF_DEBUG="no"
|
||||
GNOME_TARBALL_SUFFIX="bz2"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
|
||||
inherit autotools eutils gnome2 multilib-minimal virtualx
|
||||
|
||||
DESCRIPTION="Gnome Virtual Filesystem"
|
||||
HOMEPAGE="https://www.gnome.org/"
|
||||
|
||||
LICENSE="GPL-2 LGPL-2"
|
||||
SLOT="2"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~sparc-solaris ~x86-solaris"
|
||||
IUSE="acl gnutls ipv6 kerberos libressl samba ssl zeroconf"
|
||||
|
||||
RDEPEND="
|
||||
>=gnome-base/gconf-2.32.4-r1[${MULTILIB_USEDEP}]
|
||||
>=dev-libs/glib-2.34.3[${MULTILIB_USEDEP}]
|
||||
>=dev-libs/libxml2-2.9.1-r4[${MULTILIB_USEDEP}]
|
||||
>=app-arch/bzip2-1.0.6-r4[${MULTILIB_USEDEP}]
|
||||
gnome-base/gnome-mime-data
|
||||
>=x11-misc/shared-mime-info-0.14
|
||||
>=dev-libs/dbus-glib-0.100.2[${MULTILIB_USEDEP}]
|
||||
acl? (
|
||||
>=sys-apps/acl-2.2.52-r1[${MULTILIB_USEDEP}]
|
||||
>=sys-apps/attr-2.4.47-r1[${MULTILIB_USEDEP}] )
|
||||
kerberos? ( >=virtual/krb5-0-r1[${MULTILIB_USEDEP}] )
|
||||
samba? ( >=net-fs/samba-3.6.23-r1[${MULTILIB_USEDEP}] )
|
||||
ssl? (
|
||||
gnutls? (
|
||||
>=net-libs/gnutls-2.12.23-r6[${MULTILIB_USEDEP}]
|
||||
!gnome-extra/gnome-vfs-sftp )
|
||||
!gnutls? (
|
||||
!libressl? ( >=dev-libs/openssl-1.0.1h-r2:0[${MULTILIB_USEDEP}] )
|
||||
libressl? ( dev-libs/libressl[${MULTILIB_USEDEP}] )
|
||||
!gnome-extra/gnome-vfs-sftp ) )
|
||||
zeroconf? ( >=net-dns/avahi-0.6.31-r2[${MULTILIB_USEDEP}] )
|
||||
abi_x86_32? (
|
||||
!<=app-emulation/emul-linux-x86-gtklibs-20140508-r1
|
||||
!app-emulation/emul-linux-x86-gtklibs[-abi_x86_32(-)]
|
||||
)
|
||||
"
|
||||
DEPEND="${RDEPEND}
|
||||
sys-devel/gettext
|
||||
gnome-base/gnome-common
|
||||
>=dev-util/intltool-0.40
|
||||
>=virtual/pkgconfig-0-r1[${MULTILIB_USEDEP}]
|
||||
>=dev-util/gtk-doc-am-1.13
|
||||
"
|
||||
|
||||
src_prepare() {
|
||||
# Allow the Trash on afs filesystems (#106118)
|
||||
epatch "${FILESDIR}"/${PN}-2.12.0-afs.patch
|
||||
|
||||
# Fix compiling with headers missing
|
||||
epatch "${FILESDIR}"/${PN}-2.15.2-headers-define.patch
|
||||
|
||||
# Fix for crashes running programs via sudo
|
||||
epatch "${FILESDIR}"/${PN}-2.16.0-no-dbus-crash.patch
|
||||
|
||||
# Fix automagic dependencies, upstream bug #493475
|
||||
epatch "${FILESDIR}"/${PN}-2.20.0-automagic-deps.patch
|
||||
epatch "${FILESDIR}"/${PN}-2.20.1-automagic-deps.patch
|
||||
|
||||
# Fix to identify ${HOME} (#200897)
|
||||
# thanks to debian folks
|
||||
epatch "${FILESDIR}"/${PN}-2.24.4-home_dir_fakeroot.patch
|
||||
|
||||
# Configure with gnutls-2.7, bug #253729
|
||||
# Fix building with gnutls-2.12, bug #388895
|
||||
epatch "${FILESDIR}"/${PN}-2.24.4-gnutls27.patch
|
||||
|
||||
# Prevent duplicated volumes, bug #193083
|
||||
epatch "${FILESDIR}"/${PN}-2.24.0-uuid-mount.patch
|
||||
|
||||
# Do not build tests with FEATURES="-test", bug #226221
|
||||
epatch "${FILESDIR}"/${PN}-2.24.4-build-tests-asneeded.patch
|
||||
|
||||
# Disable broken test, bug #285706
|
||||
epatch "${FILESDIR}"/${PN}-2.24.4-disable-test-async-cancel.patch
|
||||
|
||||
# Fix for automake-1.13 compatibility, #466944
|
||||
epatch "${FILESDIR}"/${P}-automake-1.13.patch
|
||||
|
||||
sed -e "s/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/" -i configure.in || die
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
}
|
||||
|
||||
multilib_src_configure() {
|
||||
local myconf=(
|
||||
--disable-schemas-install
|
||||
--disable-static
|
||||
--disable-cdda
|
||||
--disable-fam
|
||||
--disable-hal
|
||||
--disable-howl
|
||||
$(use_enable acl)
|
||||
$(use_enable gnutls)
|
||||
$(use_enable ipv6)
|
||||
$(use_enable kerberos krb5)
|
||||
$(use_enable samba)
|
||||
$(use_enable ssl openssl)
|
||||
$(use_enable zeroconf avahi)
|
||||
# Useless ? --enable-http-neon
|
||||
|
||||
# fix path to krb5-config
|
||||
KRB5_CONFIG=/usr/bin/${CHOST}-krb5-config
|
||||
)
|
||||
|
||||
# this works because of the order of configure parsing
|
||||
# so should always be behind the use_enable options
|
||||
# foser <foser@gentoo.org 19 Apr 2004
|
||||
use gnutls && use ssl && myconf+=( --disable-openssl )
|
||||
|
||||
#bug #519060
|
||||
#configure script is so messed up on res_init on Darwin
|
||||
[[ ${CHOST} == *-darwin* ]] && export LIBS="${LIBS} -lresolv"
|
||||
|
||||
ECONF_SOURCE=${S} \
|
||||
gnome2_src_configure "${myconf[@]}"
|
||||
|
||||
if multilib_is_native_abi; then
|
||||
ln -s "${S}"/doc/html doc/html || die
|
||||
fi
|
||||
}
|
||||
|
||||
multilib_src_test() {
|
||||
unset DISPLAY
|
||||
# Fix bug #285706
|
||||
unset XAUTHORITY
|
||||
Xemake check
|
||||
}
|
||||
|
||||
multilib_src_install() {
|
||||
gnome2_src_install
|
||||
}
|
||||
|
||||
multilib_src_install_all() {
|
||||
DOCS="AUTHORS ChangeLog HACKING NEWS README TODO"
|
||||
einstalldocs
|
||||
}
|
@ -0,0 +1,272 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI="5"
|
||||
|
||||
inherit eutils flag-o-matic autotools
|
||||
|
||||
PATCHSET_REV="-r1"
|
||||
|
||||
DESCRIPTION="A small but very powerful text-based mail client"
|
||||
HOMEPAGE="http://www.mutt.org/"
|
||||
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz
|
||||
mirror://bitbucket/${PN}/${PN}/downloads/${P}.tar.gz
|
||||
ftp://ftp.mutt.org/pub/mutt/${P}.tar.gz
|
||||
mirror://gentoo/${P}-gentoo-patches${PATCHSET_REV}.tar.bz2
|
||||
https://dev.gentoo.org/~grobian/distfiles/${P}-gentoo-patches${PATCHSET_REV}.tar.bz2"
|
||||
IUSE="berkdb crypt debug doc gdbm gnutls gpg idn imap kerberos libressl mbox nls nntp pop qdbm sasl selinux sidebar slang smime smtp ssl tokyocabinet"
|
||||
SLOT="0"
|
||||
LICENSE="GPL-2"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~x64-freebsd ~x86-freebsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
|
||||
CDEPEND="
|
||||
app-misc/mime-types
|
||||
nls? ( virtual/libintl )
|
||||
tokyocabinet? ( dev-db/tokyocabinet )
|
||||
!tokyocabinet? (
|
||||
qdbm? ( dev-db/qdbm )
|
||||
!qdbm? (
|
||||
gdbm? ( sys-libs/gdbm )
|
||||
!gdbm? ( berkdb? ( >=sys-libs/db-4 ) )
|
||||
)
|
||||
)
|
||||
imap? (
|
||||
gnutls? ( >=net-libs/gnutls-1.0.17 )
|
||||
!gnutls? (
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
)
|
||||
)
|
||||
sasl? ( >=dev-libs/cyrus-sasl-2 )
|
||||
)
|
||||
kerberos? ( virtual/krb5 )
|
||||
pop? (
|
||||
gnutls? ( >=net-libs/gnutls-1.0.17 )
|
||||
!gnutls? (
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
)
|
||||
)
|
||||
sasl? ( >=dev-libs/cyrus-sasl-2 )
|
||||
)
|
||||
smtp? (
|
||||
gnutls? ( >=net-libs/gnutls-1.0.17 )
|
||||
!gnutls? (
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
)
|
||||
)
|
||||
sasl? ( >=dev-libs/cyrus-sasl-2 )
|
||||
)
|
||||
idn? ( net-dns/libidn )
|
||||
gpg? ( >=app-crypt/gpgme-0.9.0 )
|
||||
smime? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
)
|
||||
slang? ( sys-libs/slang )
|
||||
!slang? ( >=sys-libs/ncurses-5.2:0 )
|
||||
"
|
||||
DEPEND="${CDEPEND}
|
||||
net-mail/mailbase
|
||||
doc? (
|
||||
dev-libs/libxml2
|
||||
dev-libs/libxslt
|
||||
app-text/docbook-xsl-stylesheets
|
||||
|| ( www-client/lynx www-client/w3m www-client/elinks )
|
||||
)"
|
||||
RDEPEND="${CDEPEND}
|
||||
selinux? ( sec-policy/selinux-mutt )
|
||||
"
|
||||
PATCHDIR="${WORKDIR}"/${P}-gentoo-patches${PATCHSET_REV}
|
||||
|
||||
src_prepare() {
|
||||
# Post-release hot-fixes grabbed from HG, this is what all following
|
||||
# patches are based on in my Mercurial patchqueue (mq).
|
||||
# If you ever take over or need to modify patches here, just check
|
||||
# out the gentoo branch(es) of Gentoo's Mutt Mercurial clone, and
|
||||
# the patchqueue as it'll save you a lot of work.
|
||||
# http://hg.code.sf.net/p/gentoomutt/code/
|
||||
# http://hg.code.sf.net/p/gentoomuttpatches/code/
|
||||
for rev in $(eval echo {0..${PR#r}}) ; do
|
||||
local revpatch="${PATCHDIR}"/mutt-gentoo-${PV}-r${rev}.patch
|
||||
[[ -e ${revpatch} ]] && \
|
||||
epatch "${revpatch}"
|
||||
done
|
||||
# fix compilation with ncurses[tinfo], #459260
|
||||
epatch "${PATCHDIR}"/ncurses-tinfo.patch
|
||||
|
||||
# this patch is non-generic and only works because we use a sysconfdir
|
||||
# different from the one used by the mailbase ebuild
|
||||
use prefix && epatch "${PATCHDIR}"/prefix-mailcap.patch
|
||||
|
||||
# must have fixes to compile or behave correctly, upstream
|
||||
# ignores, disagrees or simply doesn't respond/apply
|
||||
epatch "${PATCHDIR}"/bdb-prefix.patch # fix bdb detection
|
||||
# same category, but functional bits
|
||||
epatch "${PATCHDIR}"/dont-reveal-bbc.patch
|
||||
|
||||
# the big feature patches that upstream doesn't want to include, but
|
||||
# nearly every distro has due to their usefulness
|
||||
for p in "${PATCHDIR}"/[0-9][0-9]-*.patch ; do
|
||||
epatch "${p}"
|
||||
done
|
||||
|
||||
# we conditionalise this one, simply because it has considerable
|
||||
# impact on the code
|
||||
if use sidebar ; then
|
||||
epatch "${PATCHDIR}"/sidebar-20140412.patch
|
||||
epatch "${PATCHDIR}"/sidebar-dotpathsep.patch
|
||||
epatch "${PATCHDIR}"/sidebar-counts.patch
|
||||
fi
|
||||
|
||||
local upatches=
|
||||
# allow user patches
|
||||
epatch_user && upatches=" with user patches"
|
||||
|
||||
# patch version string for bug reports
|
||||
sed -i -e 's/"Mutt %s (%s)"/"Mutt %s (%s, Gentoo '"${PVR}${upatches}"')"/' \
|
||||
muttlib.c || die "failed patching in Gentoo version"
|
||||
|
||||
# many patches touch the buildsystem, we always need this
|
||||
AT_M4DIR="m4" eautoreconf
|
||||
|
||||
# the configure script contains some "cleverness" whether or not to setgid
|
||||
# the dotlock program, resulting in bugs like #278332
|
||||
sed -i -e 's/@DOTLOCK_GROUP@//' \
|
||||
Makefile.in || die "sed failed"
|
||||
|
||||
# don't just build documentation (lengthy process, with big dependencies)
|
||||
if use !doc ; then
|
||||
sed -i -e '/SUBDIRS =/s/doc//' Makefile.in || die
|
||||
fi
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
local myconf="
|
||||
$(use_enable crypt pgp) \
|
||||
$(use_enable debug) \
|
||||
$(use_enable gpg gpgme) \
|
||||
$(use_enable imap) \
|
||||
$(use_enable nls) \
|
||||
$(use_enable nntp) \
|
||||
$(use_enable pop) \
|
||||
$(use_enable smime) \
|
||||
$(use_enable smtp) \
|
||||
$(use_with idn) \
|
||||
$(use_with kerberos gss) \
|
||||
$(use slang && echo --with-slang=${EPREFIX}/usr) \
|
||||
$(use !slang && echo --with-curses=${EPREFIX}/usr) \
|
||||
--enable-compressed \
|
||||
--enable-external-dotlock \
|
||||
--enable-nfs-fix \
|
||||
--sysconfdir=${EPREFIX}/etc/${PN} \
|
||||
--with-docdir=${EPREFIX}/usr/share/doc/${PN}-${PVR} \
|
||||
--with-regex \
|
||||
--with-exec-shell=${EPREFIX}/bin/sh"
|
||||
|
||||
case $CHOST in
|
||||
*-solaris*)
|
||||
# Solaris has no flock in the standard headers
|
||||
myconf+=" --enable-fcntl --disable-flock"
|
||||
# wchar_t depends on locale
|
||||
myconf+=" --without-wc-funcs"
|
||||
;;
|
||||
*)
|
||||
myconf+=" --disable-fcntl --enable-flock"
|
||||
;;
|
||||
esac
|
||||
|
||||
# mutt prioritizes gdbm over bdb, so we will too.
|
||||
# hcache feature requires at least one database is in USE.
|
||||
if use tokyocabinet; then
|
||||
myconf="${myconf} --enable-hcache \
|
||||
--with-tokyocabinet --without-qdbm --without-gdbm --without-bdb"
|
||||
elif use qdbm; then
|
||||
myconf="${myconf} --enable-hcache \
|
||||
--without-tokyocabinet --with-qdbm --without-gdbm --without-bdb"
|
||||
elif use gdbm ; then
|
||||
myconf="${myconf} --enable-hcache \
|
||||
--without-tokyocabinet --without-qdbm --with-gdbm --without-bdb"
|
||||
elif use berkdb; then
|
||||
myconf="${myconf} --enable-hcache \
|
||||
--without-tokyocabinet --without-qdbm --without-gdbm --with-bdb"
|
||||
else
|
||||
myconf="${myconf} --disable-hcache \
|
||||
--without-tokyocabinet --without-qdbm --without-gdbm --without-bdb"
|
||||
fi
|
||||
|
||||
# there's no need for gnutls, ssl or sasl without socket support
|
||||
if use pop || use imap || use smtp ; then
|
||||
if use gnutls; then
|
||||
myconf="${myconf} --with-gnutls"
|
||||
elif use ssl; then
|
||||
myconf="${myconf} --with-ssl"
|
||||
fi
|
||||
# not sure if this should be mutually exclusive with the other two
|
||||
myconf="${myconf} $(use_with sasl)"
|
||||
else
|
||||
myconf="${myconf} --without-gnutls --without-ssl --without-sasl"
|
||||
fi
|
||||
|
||||
if use mbox; then
|
||||
myconf="${myconf} --with-mailpath=${EPREFIX}/var/spool/mail"
|
||||
else
|
||||
myconf="${myconf} --with-homespool=Maildir"
|
||||
fi
|
||||
|
||||
econf ${myconf} || die "configure failed"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" install || die "install failed"
|
||||
if use mbox; then
|
||||
insinto /etc/mutt
|
||||
newins "${FILESDIR}"/Muttrc.mbox Muttrc
|
||||
else
|
||||
insinto /etc/mutt
|
||||
doins "${FILESDIR}"/Muttrc
|
||||
fi
|
||||
|
||||
# A newer file is provided by app-misc/mime-types. So we link it.
|
||||
rm "${ED}"/etc/${PN}/mime.types
|
||||
dosym /etc/mime.types /etc/${PN}/mime.types
|
||||
|
||||
# A man-page is always handy, so fake one
|
||||
if use !doc; then
|
||||
emake -C doc DESTDIR="${D}" muttrc.man || die
|
||||
# make the fake slightly better, bug #413405
|
||||
sed -e 's#@docdir@/manual.txt#http://www.mutt.org/doc/devel/manual.html#' \
|
||||
-e 's#in @docdir@,#at http://www.mutt.org/,#' \
|
||||
-e "s#@sysconfdir@#${EPREFIX}/etc/${PN}#" \
|
||||
-e "s#@bindir@#${EPREFIX}/usr/bin#" \
|
||||
doc/mutt.man > mutt.1
|
||||
cp doc/muttbug.man flea.1
|
||||
cp doc/muttrc.man muttrc.5
|
||||
doman mutt.1 flea.1 muttrc.5
|
||||
else
|
||||
# nuke manpages that should be provided by an MTA, bug #177605
|
||||
rm "${ED}"/usr/share/man/man5/{mbox,mmdf}.5 \
|
||||
|| ewarn "failed to remove files, please file a bug"
|
||||
fi
|
||||
|
||||
if use !prefix ; then
|
||||
fowners root:mail /usr/bin/mutt_dotlock
|
||||
fperms g+s /usr/bin/mutt_dotlock
|
||||
fi
|
||||
|
||||
dodoc BEWARE COPYRIGHT ChangeLog NEWS OPS* PATCHES README* TODO VERSION
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
if [[ -z ${REPLACING_VERSIONS} ]] ; then
|
||||
echo
|
||||
elog "If you are new to mutt you may want to take a look at"
|
||||
elog "the Gentoo QuickStart Guide to Mutt E-Mail:"
|
||||
elog " https://wiki.gentoo.org/wiki/Mutt"
|
||||
echo
|
||||
fi
|
||||
}
|
@ -0,0 +1,26 @@
|
||||
diff --git a/smtpd/filter.c b/smtpd/filter.c
|
||||
index 062f00f..8af6eab 100644
|
||||
--- a/smtpd/filter.c
|
||||
+++ b/smtpd/filter.c
|
||||
@@ -726,7 +726,6 @@ filter_tx_io(struct io *io, int evt)
|
||||
struct filter_session *s = io->arg;
|
||||
size_t len, n;
|
||||
char *data;
|
||||
- char buf[65535];
|
||||
|
||||
log_trace(TRACE_FILTERS, "filter: filter_tx_io(%p, %s)", s, io_strevent(evt));
|
||||
|
||||
@@ -734,10 +733,9 @@ filter_tx_io(struct io *io, int evt)
|
||||
case IO_DATAIN:
|
||||
data = iobuf_data(&s->ibuf);
|
||||
len = iobuf_len(&s->ibuf);
|
||||
- memmove(buf, data, len);
|
||||
- buf[len] = 0;
|
||||
- log_trace(TRACE_FILTERS, "filter: filter_tx_io: datain (%zu) for req %016"PRIx64": %s",
|
||||
- len, s->id, buf);
|
||||
+
|
||||
+ log_trace(TRACE_FILTERS, "filter: filter_tx_io: datain (%zu) for req %016"PRIx64"",
|
||||
+ len, s->id);
|
||||
|
||||
n = fwrite(data, 1, len, s->ofile);
|
||||
if (n != len) {
|
@ -0,0 +1,319 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
inherit eutils flag-o-matic multilib pam ssl-cert systemd toolchain-funcs user versionator
|
||||
|
||||
MY_PV="${PV/_rc/-RC}"
|
||||
MY_SRC="${PN}-${MY_PV}"
|
||||
MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/official"
|
||||
VDA_PV="2.10.0"
|
||||
VDA_P="${PN}-vda-v13-${VDA_PV}"
|
||||
RC_VER="2.7"
|
||||
|
||||
DESCRIPTION="A fast and secure drop-in replacement for sendmail"
|
||||
HOMEPAGE="http://www.postfix.org/"
|
||||
SRC_URI="${MY_URI}/${MY_SRC}.tar.gz
|
||||
vda? ( http://vda.sourceforge.net/VDA/${VDA_P}.patch ) "
|
||||
|
||||
LICENSE="IBM"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd"
|
||||
IUSE="+berkdb cdb doc dovecot-sasl +eai hardened ldap ldap-bind libressl lmdb memcached mbox mysql nis pam postgres sasl selinux sqlite ssl vda"
|
||||
|
||||
DEPEND=">=dev-libs/libpcre-3.4
|
||||
dev-lang/perl
|
||||
berkdb? ( >=sys-libs/db-3.2:* )
|
||||
cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r1 ) )
|
||||
eai? ( dev-libs/icu:= )
|
||||
ldap? ( net-nds/openldap )
|
||||
ldap-bind? ( net-nds/openldap[sasl] )
|
||||
lmdb? ( >=dev-db/lmdb-0.9.11 )
|
||||
mysql? ( virtual/mysql )
|
||||
pam? ( virtual/pam )
|
||||
postgres? ( dev-db/postgresql:* )
|
||||
sasl? ( >=dev-libs/cyrus-sasl-2 )
|
||||
sqlite? ( dev-db/sqlite:3 )
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6g:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
)"
|
||||
|
||||
RDEPEND="${DEPEND}
|
||||
dovecot-sasl? ( net-mail/dovecot )
|
||||
memcached? ( net-misc/memcached )
|
||||
net-mail/mailbase
|
||||
!mail-mta/courier
|
||||
!mail-mta/esmtp
|
||||
!mail-mta/exim
|
||||
!mail-mta/mini-qmail
|
||||
!mail-mta/msmtp[mta]
|
||||
!mail-mta/netqmail
|
||||
!mail-mta/nullmailer
|
||||
!mail-mta/qmail-ldap
|
||||
!mail-mta/sendmail
|
||||
!mail-mta/opensmtpd
|
||||
!<mail-mta/ssmtp-2.64-r2
|
||||
!>=mail-mta/ssmtp-2.64-r2[mta]
|
||||
!net-mail/fastforward
|
||||
selinux? ( sec-policy/selinux-postfix )"
|
||||
|
||||
# No vda support for postfix-3.0
|
||||
REQUIRED_USE="ldap-bind? ( ldap sasl )
|
||||
!vda"
|
||||
|
||||
S="${WORKDIR}/${MY_SRC}"
|
||||
|
||||
pkg_setup() {
|
||||
# Add postfix, postdrop user/group (bug #77565)
|
||||
enewgroup postfix 207
|
||||
enewgroup postdrop 208
|
||||
enewuser postfix 207 -1 /var/spool/postfix postfix,mail
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
if use vda; then
|
||||
epatch "${DISTDIR}"/${VDA_P}.patch
|
||||
fi
|
||||
|
||||
sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \
|
||||
src/util/sys_defs.h || die "sed failed"
|
||||
|
||||
# change default paths to better comply with portage standard paths
|
||||
sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed"
|
||||
|
||||
sed -i -e "/readme_directory\/CONNECTION_CACHE_README/ i\
|
||||
\$readme_directory\/COMPATIBILITY_README:f:root:-:644" conf/postfix-files
|
||||
sed -i -e "/html_directory\/CONNECTION_CACHE_README/ i\
|
||||
\$html_directory\/COMPATIBILITY_README.html:f:root:-:644" conf/postfix-files
|
||||
|
||||
epatch_user
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE
|
||||
do
|
||||
local AUXLIBS_${name}=""
|
||||
done
|
||||
|
||||
# Make sure LDFLAGS get passed down to the executables.
|
||||
local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -ldl"
|
||||
AUXLIBS_PCRE="$(pcre-config --libs)"
|
||||
|
||||
use pam && mylibs="${mylibs} -lpam"
|
||||
|
||||
if use ldap; then
|
||||
mycc="${mycc} -DHAS_LDAP"
|
||||
AUXLIBS_LDAP="-lldap -llber"
|
||||
fi
|
||||
|
||||
if use mysql; then
|
||||
mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)"
|
||||
AUXLIBS_MYSQL="$(mysql_config --libs)"
|
||||
fi
|
||||
|
||||
if use postgres; then
|
||||
mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)"
|
||||
AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq"
|
||||
fi
|
||||
|
||||
if use sqlite; then
|
||||
mycc="${mycc} -DHAS_SQLITE"
|
||||
AUXLIBS_SQLITE="-lsqlite3 -lpthread"
|
||||
fi
|
||||
|
||||
if use ssl; then
|
||||
mycc="${mycc} -DUSE_TLS"
|
||||
mylibs="${mylibs} -lssl -lcrypto"
|
||||
fi
|
||||
|
||||
if use lmdb; then
|
||||
mycc="${mycc} -DHAS_LMDB"
|
||||
AUXLIBS_LMDB="-llmdb -lpthread"
|
||||
fi
|
||||
|
||||
if ! use eai; then
|
||||
mycc="${mycc} -DNO_EAI"
|
||||
fi
|
||||
|
||||
# broken. and "in other words, not supported" by upstream.
|
||||
# Use inet_protocols setting in main.cf
|
||||
#if ! use ipv6; then
|
||||
# mycc="${mycc} -DNO_IPV6"
|
||||
#fi
|
||||
|
||||
if use sasl; then
|
||||
if use dovecot-sasl; then
|
||||
# Set dovecot as default.
|
||||
mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\""
|
||||
fi
|
||||
if use ldap-bind; then
|
||||
mycc="${mycc} -DUSE_LDAP_SASL"
|
||||
fi
|
||||
mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl"
|
||||
mylibs="${mylibs} -lsasl2"
|
||||
elif use dovecot-sasl; then
|
||||
mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\""
|
||||
fi
|
||||
|
||||
if ! use nis; then
|
||||
mycc="${mycc} -DNO_NIS"
|
||||
fi
|
||||
|
||||
if ! use berkdb; then
|
||||
mycc="${mycc} -DNO_DB"
|
||||
if use cdb; then
|
||||
# change default hash format from Berkeley DB to cdb
|
||||
mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\""
|
||||
fi
|
||||
fi
|
||||
|
||||
if use cdb; then
|
||||
mycc="${mycc} -DHAS_CDB -I/usr/include/cdb"
|
||||
# Tinycdb is preferred.
|
||||
if has_version dev-db/tinycdb ; then
|
||||
einfo "Building with dev-db/tinycdb"
|
||||
AUXLIBS_CDB="-lcdb"
|
||||
else
|
||||
einfo "Building with dev-db/cdb"
|
||||
CDB_PATH="/usr/$(get_libdir)"
|
||||
for i in cdb.a alloc.a buffer.a unix.a byte.a ; do
|
||||
AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}"
|
||||
done
|
||||
fi
|
||||
fi
|
||||
|
||||
# Robin H. Johnson <robbat2@gentoo.org> 17/Nov/2006
|
||||
# Fix because infra boxes hit 2Gb .db files that fail a 32-bit fstat signed check.
|
||||
mycc="${mycc} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE"
|
||||
filter-lfs-flags
|
||||
|
||||
# Workaround for bug #76512
|
||||
if use hardened; then
|
||||
[[ "$(gcc-version)" == "3.4" ]] && replace-flags -O? -Os
|
||||
fi
|
||||
|
||||
# Remove annoying C++ comment style warnings - bug #378099
|
||||
append-flags -Wno-comment
|
||||
|
||||
sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs
|
||||
sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs
|
||||
|
||||
emake makefiles shared=yes dynamicmaps=no \
|
||||
shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \
|
||||
DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \
|
||||
AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \
|
||||
AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \
|
||||
AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \
|
||||
AUXLIBS_SQLITE="${AUXLIBS_SQLITE}"
|
||||
}
|
||||
|
||||
src_install () {
|
||||
local myconf
|
||||
use doc && myconf="readme_directory=\"/usr/share/doc/${PF}/readme\" \
|
||||
html_directory=\"/usr/share/doc/${PF}/html\""
|
||||
|
||||
LD_LIBRARY_PATH="${S}/lib" \
|
||||
/bin/sh postfix-install \
|
||||
-non-interactive \
|
||||
install_root="${D}" \
|
||||
config_directory="/etc/postfix" \
|
||||
manpage_directory="/usr/share/man" \
|
||||
command_directory="/usr/sbin" \
|
||||
mailq_path="/usr/bin/mailq" \
|
||||
newaliases_path="/usr/bin/newaliases" \
|
||||
sendmail_path="/usr/sbin/sendmail" \
|
||||
${myconf} \
|
||||
|| die "postfix-install failed"
|
||||
|
||||
# Fix spool removal on upgrade
|
||||
rm -Rf "${D}"/var
|
||||
keepdir /var/spool/postfix
|
||||
|
||||
# Install rmail for UUCP, closes bug #19127
|
||||
dobin auxiliary/rmail/rmail
|
||||
|
||||
# Provide another link for legacy FSH
|
||||
dosym /usr/sbin/sendmail /usr/$(get_libdir)/sendmail
|
||||
|
||||
# Install qshape tool and posttls-finger
|
||||
dobin auxiliary/qshape/qshape.pl
|
||||
doman man/man1/qshape.1
|
||||
dobin bin/posttls-finger
|
||||
doman man/man1/posttls-finger.1
|
||||
|
||||
# Performance tuning tools and their manuals
|
||||
dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink}
|
||||
doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1
|
||||
|
||||
# Set proper permissions on required files/directories
|
||||
dodir /var/lib/postfix
|
||||
keepdir /var/lib/postfix
|
||||
fowners -R postfix:postfix /var/lib/postfix
|
||||
fperms 0750 /var/lib/postfix
|
||||
fowners root:postdrop /usr/sbin/post{drop,queue}
|
||||
fperms 02711 /usr/sbin/post{drop,queue}
|
||||
|
||||
keepdir /etc/postfix
|
||||
if use mbox; then
|
||||
mypostconf="mail_spool_directory=/var/spool/mail"
|
||||
else
|
||||
mypostconf="home_mailbox=.maildir/"
|
||||
fi
|
||||
LD_LIBRARY_PATH="${S}/lib" \
|
||||
"${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \
|
||||
-e ${mypostconf} || die "postconf failed"
|
||||
|
||||
insinto /etc/postfix
|
||||
newins "${FILESDIR}"/smtp.pass saslpass
|
||||
fperms 600 /etc/postfix/saslpass
|
||||
|
||||
newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix
|
||||
# do not start mysql/postgres unnecessarily - bug #359913
|
||||
use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix"
|
||||
use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix"
|
||||
|
||||
dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES*
|
||||
use doc && mv "${S}"/examples "${D}"/usr/share/doc/${PF}/
|
||||
|
||||
pamd_mimic_system smtp auth account
|
||||
|
||||
if use sasl; then
|
||||
insinto /etc/sasl2
|
||||
newins "${FILESDIR}"/smtp.sasl smtpd.conf
|
||||
fi
|
||||
|
||||
# header files
|
||||
insinto /usr/include/postfix
|
||||
doins include/*.h
|
||||
|
||||
# Remove unnecessary files
|
||||
rm -f "${D}"/etc/postfix/{*LICENSE,access,aliases,canonical,generic}
|
||||
rm -f "${D}"/etc/postfix/{header_checks,relocated,transport,virtual}
|
||||
|
||||
if has_version mail-mta/postfix; then
|
||||
# let the sysadmin decide when to change the compatibility_level
|
||||
sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die
|
||||
fi
|
||||
|
||||
systemd_dounit "${FILESDIR}/${PN}.service"
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
# Do not install server.{key,pem) SSL certificates if they already exist
|
||||
if use ssl && [[ ! -f "${ROOT}"/etc/ssl/postfix/server.key \
|
||||
&& ! -f "${ROOT}"/etc/ssl/postfix/server.pem ]] ; then
|
||||
SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}"
|
||||
install_cert /etc/ssl/postfix/server
|
||||
chown postfix:mail "${ROOT}"/etc/ssl/postfix/server.{key,pem}
|
||||
fi
|
||||
|
||||
if [[ ! -e /etc/mail/aliases.db ]] ; then
|
||||
ewarn
|
||||
ewarn "You must edit /etc/mail/aliases to suit your needs"
|
||||
ewarn "and then run /usr/bin/newaliases. Postfix will not"
|
||||
ewarn "work correctly without it."
|
||||
ewarn
|
||||
fi
|
||||
}
|
@ -0,0 +1,314 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
inherit eutils flag-o-matic multilib pam ssl-cert systemd toolchain-funcs user versionator
|
||||
|
||||
MY_PV="${PV/_pre/-}"
|
||||
MY_SRC="${PN}-${MY_PV}"
|
||||
MY_URI="ftp://ftp.porcupine.org/mirrors/postfix-release/experimental"
|
||||
VDA_PV="2.10.0"
|
||||
VDA_P="${PN}-vda-v13-${VDA_PV}"
|
||||
RC_VER="2.7"
|
||||
|
||||
DESCRIPTION="A fast and secure drop-in replacement for sendmail"
|
||||
HOMEPAGE="http://www.postfix.org/"
|
||||
SRC_URI="${MY_URI}/${MY_SRC}.tar.gz
|
||||
vda? ( http://vda.sourceforge.net/VDA/${VDA_P}.patch ) "
|
||||
|
||||
LICENSE="IBM"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd"
|
||||
IUSE="+berkdb cdb doc dovecot-sasl +eai hardened ldap ldap-bind libressl lmdb memcached mbox mysql nis pam postgres sasl selinux sqlite ssl vda"
|
||||
|
||||
DEPEND=">=dev-libs/libpcre-3.4
|
||||
dev-lang/perl
|
||||
berkdb? ( >=sys-libs/db-3.2:* )
|
||||
cdb? ( || ( >=dev-db/tinycdb-0.76 >=dev-db/cdb-0.75-r1 ) )
|
||||
eai? ( dev-libs/icu:= )
|
||||
ldap? ( net-nds/openldap )
|
||||
ldap-bind? ( net-nds/openldap[sasl] )
|
||||
lmdb? ( >=dev-db/lmdb-0.9.11 )
|
||||
mysql? ( virtual/mysql )
|
||||
pam? ( virtual/pam )
|
||||
postgres? ( dev-db/postgresql:* )
|
||||
sasl? ( >=dev-libs/cyrus-sasl-2 )
|
||||
sqlite? ( dev-db/sqlite:3 )
|
||||
ssl? (
|
||||
!libressl? ( >=dev-libs/openssl-0.9.6g:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
)"
|
||||
|
||||
RDEPEND="${DEPEND}
|
||||
dovecot-sasl? ( net-mail/dovecot )
|
||||
memcached? ( net-misc/memcached )
|
||||
net-mail/mailbase
|
||||
!mail-mta/courier
|
||||
!mail-mta/esmtp
|
||||
!mail-mta/exim
|
||||
!mail-mta/mini-qmail
|
||||
!mail-mta/msmtp[mta]
|
||||
!mail-mta/netqmail
|
||||
!mail-mta/nullmailer
|
||||
!mail-mta/qmail-ldap
|
||||
!mail-mta/sendmail
|
||||
!mail-mta/opensmtpd
|
||||
!<mail-mta/ssmtp-2.64-r2
|
||||
!>=mail-mta/ssmtp-2.64-r2[mta]
|
||||
!net-mail/fastforward
|
||||
selinux? ( sec-policy/selinux-postfix )"
|
||||
|
||||
# No vda support for postfix-3.0
|
||||
REQUIRED_USE="ldap-bind? ( ldap sasl )
|
||||
!vda"
|
||||
|
||||
S="${WORKDIR}/${MY_SRC}"
|
||||
|
||||
pkg_setup() {
|
||||
# Add postfix, postdrop user/group (bug #77565)
|
||||
enewgroup postfix 207
|
||||
enewgroup postdrop 208
|
||||
enewuser postfix 207 -1 /var/spool/postfix postfix,mail
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
if use vda; then
|
||||
epatch "${DISTDIR}"/${VDA_P}.patch
|
||||
fi
|
||||
|
||||
sed -i -e "/^#define ALIAS_DB_MAP/s|:/etc/aliases|:/etc/mail/aliases|" \
|
||||
src/util/sys_defs.h || die "sed failed"
|
||||
|
||||
# change default paths to better comply with portage standard paths
|
||||
sed -i -e "s:/usr/local/:/usr/:g" conf/master.cf || die "sed failed"
|
||||
|
||||
epatch_user
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
for name in CDB LDAP LMDB MYSQL PCRE PGSQL SDBM SQLITE
|
||||
do
|
||||
local AUXLIBS_${name}=""
|
||||
done
|
||||
|
||||
# Make sure LDFLAGS get passed down to the executables.
|
||||
local mycc="-DHAS_PCRE" mylibs="${LDFLAGS} -ldl"
|
||||
AUXLIBS_PCRE="$(pcre-config --libs)"
|
||||
|
||||
use pam && mylibs="${mylibs} -lpam"
|
||||
|
||||
if use ldap; then
|
||||
mycc="${mycc} -DHAS_LDAP"
|
||||
AUXLIBS_LDAP="-lldap -llber"
|
||||
fi
|
||||
|
||||
if use mysql; then
|
||||
mycc="${mycc} -DHAS_MYSQL $(mysql_config --include)"
|
||||
AUXLIBS_MYSQL="$(mysql_config --libs)"
|
||||
fi
|
||||
|
||||
if use postgres; then
|
||||
mycc="${mycc} -DHAS_PGSQL -I$(pg_config --includedir)"
|
||||
AUXLIBS_PGSQL="-L$(pg_config --libdir) -lpq"
|
||||
fi
|
||||
|
||||
if use sqlite; then
|
||||
mycc="${mycc} -DHAS_SQLITE"
|
||||
AUXLIBS_SQLITE="-lsqlite3 -lpthread"
|
||||
fi
|
||||
|
||||
if use ssl; then
|
||||
mycc="${mycc} -DUSE_TLS"
|
||||
mylibs="${mylibs} -lssl -lcrypto"
|
||||
fi
|
||||
|
||||
if use lmdb; then
|
||||
mycc="${mycc} -DHAS_LMDB"
|
||||
AUXLIBS_LMDB="-llmdb -lpthread"
|
||||
fi
|
||||
|
||||
if ! use eai; then
|
||||
mycc="${mycc} -DNO_EAI"
|
||||
fi
|
||||
|
||||
# broken. and "in other words, not supported" by upstream.
|
||||
# Use inet_protocols setting in main.cf
|
||||
#if ! use ipv6; then
|
||||
# mycc="${mycc} -DNO_IPV6"
|
||||
#fi
|
||||
|
||||
if use sasl; then
|
||||
if use dovecot-sasl; then
|
||||
# Set dovecot as default.
|
||||
mycc="${mycc} -DDEF_SASL_SERVER=\\\"dovecot\\\""
|
||||
fi
|
||||
if use ldap-bind; then
|
||||
mycc="${mycc} -DUSE_LDAP_SASL"
|
||||
fi
|
||||
mycc="${mycc} -DUSE_SASL_AUTH -DUSE_CYRUS_SASL -I/usr/include/sasl"
|
||||
mylibs="${mylibs} -lsasl2"
|
||||
elif use dovecot-sasl; then
|
||||
mycc="${mycc} -DUSE_SASL_AUTH -DDEF_SERVER_SASL_TYPE=\\\"dovecot\\\""
|
||||
fi
|
||||
|
||||
if ! use nis; then
|
||||
mycc="${mycc} -DNO_NIS"
|
||||
fi
|
||||
|
||||
if ! use berkdb; then
|
||||
mycc="${mycc} -DNO_DB"
|
||||
if use cdb; then
|
||||
# change default hash format from Berkeley DB to cdb
|
||||
mycc="${mycc} -DDEF_DB_TYPE=\\\"cdb\\\""
|
||||
fi
|
||||
fi
|
||||
|
||||
if use cdb; then
|
||||
mycc="${mycc} -DHAS_CDB -I/usr/include/cdb"
|
||||
# Tinycdb is preferred.
|
||||
if has_version dev-db/tinycdb ; then
|
||||
einfo "Building with dev-db/tinycdb"
|
||||
AUXLIBS_CDB="-lcdb"
|
||||
else
|
||||
einfo "Building with dev-db/cdb"
|
||||
CDB_PATH="/usr/$(get_libdir)"
|
||||
for i in cdb.a alloc.a buffer.a unix.a byte.a ; do
|
||||
AUXLIBS_CDB="${AUXLIBS_CDB} ${CDB_PATH}/${i}"
|
||||
done
|
||||
fi
|
||||
fi
|
||||
|
||||
# Robin H. Johnson <robbat2@gentoo.org> 17/Nov/2006
|
||||
# Fix because infra boxes hit 2Gb .db files that fail a 32-bit fstat signed check.
|
||||
mycc="${mycc} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE"
|
||||
filter-lfs-flags
|
||||
|
||||
# Workaround for bug #76512
|
||||
if use hardened; then
|
||||
[[ "$(gcc-version)" == "3.4" ]] && replace-flags -O? -Os
|
||||
fi
|
||||
|
||||
# Remove annoying C++ comment style warnings - bug #378099
|
||||
append-flags -Wno-comment
|
||||
|
||||
sed -i -e "/^RANLIB/s/ranlib/$(tc-getRANLIB)/g" "${S}"/makedefs
|
||||
sed -i -e "/^AR/s/ar/$(tc-getAR)/g" "${S}"/makedefs
|
||||
|
||||
emake makefiles shared=yes dynamicmaps=no pie=yes \
|
||||
shlib_directory="/usr/$(get_libdir)/postfix/MAIL_VERSION" \
|
||||
DEBUG="" CC="$(tc-getCC)" OPT="${CFLAGS}" CCARGS="${mycc}" AUXLIBS="${mylibs}" \
|
||||
AUXLIBS_CDB="${AUXLIBS_CDB}" AUXLIBS_LDAP="${AUXLIBS_LDAP}" \
|
||||
AUXLIBS_LMDB="${AUXLIBS_LMDB}" AUXLIBS_MYSQL="${AUXLIBS_MYSQL}" \
|
||||
AUXLIBS_PCRE="${AUXLIBS_PCRE}" AUXLIBS_PGSQL="${AUXLIBS_PGSQL}" \
|
||||
AUXLIBS_SQLITE="${AUXLIBS_SQLITE}"
|
||||
}
|
||||
|
||||
src_install () {
|
||||
local myconf
|
||||
use doc && myconf="readme_directory=\"/usr/share/doc/${PF}/readme\" \
|
||||
html_directory=\"/usr/share/doc/${PF}/html\""
|
||||
|
||||
LD_LIBRARY_PATH="${S}/lib" \
|
||||
/bin/sh postfix-install \
|
||||
-non-interactive \
|
||||
install_root="${D}" \
|
||||
config_directory="/etc/postfix" \
|
||||
manpage_directory="/usr/share/man" \
|
||||
command_directory="/usr/sbin" \
|
||||
mailq_path="/usr/bin/mailq" \
|
||||
newaliases_path="/usr/bin/newaliases" \
|
||||
sendmail_path="/usr/sbin/sendmail" \
|
||||
${myconf} \
|
||||
|| die "postfix-install failed"
|
||||
|
||||
# Fix spool removal on upgrade
|
||||
rm -Rf "${D}"/var
|
||||
keepdir /var/spool/postfix
|
||||
|
||||
# Install rmail for UUCP, closes bug #19127
|
||||
dobin auxiliary/rmail/rmail
|
||||
|
||||
# Provide another link for legacy FSH
|
||||
dosym /usr/sbin/sendmail /usr/$(get_libdir)/sendmail
|
||||
|
||||
# Install qshape tool and posttls-finger
|
||||
dobin auxiliary/qshape/qshape.pl
|
||||
doman man/man1/qshape.1
|
||||
dobin bin/posttls-finger
|
||||
doman man/man1/posttls-finger.1
|
||||
|
||||
# Performance tuning tools and their manuals
|
||||
dosbin bin/smtp-{source,sink} bin/qmqp-{source,sink}
|
||||
doman man/man1/smtp-{source,sink}.1 man/man1/qmqp-{source,sink}.1
|
||||
|
||||
# Set proper permissions on required files/directories
|
||||
dodir /var/lib/postfix
|
||||
keepdir /var/lib/postfix
|
||||
fowners -R postfix:postfix /var/lib/postfix
|
||||
fperms 0750 /var/lib/postfix
|
||||
fowners root:postdrop /usr/sbin/post{drop,queue}
|
||||
fperms 02711 /usr/sbin/post{drop,queue}
|
||||
|
||||
keepdir /etc/postfix
|
||||
if use mbox; then
|
||||
mypostconf="mail_spool_directory=/var/spool/mail"
|
||||
else
|
||||
mypostconf="home_mailbox=.maildir/"
|
||||
fi
|
||||
LD_LIBRARY_PATH="${S}/lib" \
|
||||
"${D}"/usr/sbin/postconf -c "${D}"/etc/postfix \
|
||||
-e ${mypostconf} || die "postconf failed"
|
||||
|
||||
insinto /etc/postfix
|
||||
newins "${FILESDIR}"/smtp.pass saslpass
|
||||
fperms 600 /etc/postfix/saslpass
|
||||
|
||||
newinitd "${FILESDIR}"/postfix.rc6.${RC_VER} postfix
|
||||
# do not start mysql/postgres unnecessarily - bug #359913
|
||||
use mysql || sed -i -e "s/mysql //" "${D}/etc/init.d/postfix"
|
||||
use postgres || sed -i -e "s/postgresql //" "${D}/etc/init.d/postfix"
|
||||
|
||||
dodoc *README COMPATIBILITY HISTORY PORTING RELEASE_NOTES*
|
||||
use doc && mv "${S}"/examples "${D}"/usr/share/doc/${PF}/
|
||||
|
||||
pamd_mimic_system smtp auth account
|
||||
|
||||
if use sasl; then
|
||||
insinto /etc/sasl2
|
||||
newins "${FILESDIR}"/smtp.sasl smtpd.conf
|
||||
fi
|
||||
|
||||
# header files
|
||||
insinto /usr/include/postfix
|
||||
doins include/*.h
|
||||
|
||||
# Remove unnecessary files
|
||||
rm -f "${D}"/etc/postfix/{*LICENSE,access,aliases,canonical,generic}
|
||||
rm -f "${D}"/etc/postfix/{header_checks,relocated,transport,virtual}
|
||||
|
||||
if has_version mail-mta/postfix; then
|
||||
# let the sysadmin decide when to change the compatibility_level
|
||||
sed -i -e /^compatibility_level/"s/^/#/" "${D}"/etc/postfix/main.cf || die
|
||||
fi
|
||||
|
||||
systemd_dounit "${FILESDIR}/${PN}.service"
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
# Do not install server.{key,pem) SSL certificates if they already exist
|
||||
if use ssl && [[ ! -f "${ROOT}"/etc/ssl/postfix/server.key \
|
||||
&& ! -f "${ROOT}"/etc/ssl/postfix/server.pem ]] ; then
|
||||
SSL_ORGANIZATION="${SSL_ORGANIZATION:-Postfix SMTP Server}"
|
||||
install_cert /etc/ssl/postfix/server
|
||||
chown postfix:mail "${ROOT}"/etc/ssl/postfix/server.{key,pem}
|
||||
fi
|
||||
|
||||
if [[ ! -e /etc/mail/aliases.db ]] ; then
|
||||
ewarn
|
||||
ewarn "You must edit /etc/mail/aliases to suit your needs"
|
||||
ewarn "and then run /usr/bin/newaliases. Postfix will not"
|
||||
ewarn "work correctly without it."
|
||||
ewarn
|
||||
fi
|
||||
}
|
@ -0,0 +1,22 @@
|
||||
Fix exiv2.hpp if built with PNG support disabled (--without-zlib)
|
||||
|
||||
Fixed upstream in >=0.26
|
||||
|
||||
See also: http://dev.exiv2.org/issues/1103
|
||||
Gentoo bug 1: https://bugs.gentoo.org/show_bug.cgi?id=552046
|
||||
Gentoo bug 2: https://bugs.gentoo.org/show_bug.cgi?id=535836
|
||||
|
||||
Index: exiv2.hpp
|
||||
===================================================================
|
||||
--- a/include/exiv2/exiv2.hpp (revision 3887)
|
||||
+++ b/include/exiv2/exiv2.hpp (revision 3888)
|
||||
@@ -52,7 +52,9 @@
|
||||
#include "mrwimage.hpp"
|
||||
#include "orfimage.hpp"
|
||||
#include "pgfimage.hpp"
|
||||
+#ifdef EXV_HAVE_LIBZ
|
||||
#include "pngimage.hpp"
|
||||
+#endif
|
||||
#include "preview.hpp"
|
||||
#include "properties.hpp"
|
||||
#include "psdimage.hpp"
|
@ -1,2 +1,3 @@
|
||||
DIST nomacs-2.4.2-source.tar.bz2 1443270 SHA256 b0f52b919025a48a0e0300ea15c90b40d6ad892b055088fca02a8137e229bc3a SHA512 e3fae11ae8c385f9548bda32b2364967a457e9645fa4375da9d1cf85dc8fb150a56a19c3eab12ddef90d58f20a57d02a8720ddb8fef22c569ab6c28d54654f02 WHIRLPOOL ac21dd3afe3b45324daa6e07030203611c9f2de4ad1427ce4bb388d84ade5e38a686b42e0d757adbaa3a91fbb658d94f9f47de61e9ccf4ccc339af4ce1c4fd8d
|
||||
DIST nomacs-2.4.4-source.tar.bz2 1448716 SHA256 01b0cb48936ca0214c120a126069c50a9b8fe7ecbdb69bb4e5fe283d6b198257 SHA512 76cd5efaba09584757843e895b5b8293adcdab7df68a7d5bdcf38e9e5df04e38382944cf64293c9820815b9e6328793dd8e46afef5ffeaa80ddc4f7d43290fc2 WHIRLPOOL d858887f66cbbed858c1985313107839a8162052bfb825bc48f344516444a1e184e839c9a067283d7503b98a6993126ade3f39c0a85b50ca534f963335c85513
|
||||
DIST nomacs-2.4.6-source.tar.bz2 1457529 SHA256 b846e335c768593e9f36cdee1a5c186e7794c76770ea3cadc87cf264153e8960 SHA512 9389df46635e619e198388e8b161a840d15227dd902cf04c250e71211098a10fd808d710ebab71f3e9a437bdca9451f966c46d22c2ce2379b94b678e79e92d71 WHIRLPOOL 97ccd02cbeabda62888ed25065cd24ce9a297b7bae3f9343e903d0223e8107cab601834fbc6dcf31a0b7f8d9e93052ba5a1a08e9c5e006027994c27bdb6f3940
|
||||
|
@ -1,8 +1,12 @@
|
||||
DIST 03-infinality-2.6-2015.10.04.patch.xz 24444 SHA256 0c28892e9b6bc27afe9149da04fc9733c9323817dd81802f2f40c680a7f887a8 SHA512 8733a7c7c118dee7fd2303435fc9c10d66aba49bd16f1215fe069b5cf16242776f2701c02fa17bca772195f0fc569e35cff11f73fc5f77519d4858737d511db3 WHIRLPOOL 5e7fbbea273df890efe8a101106430bba54cf3ce52228cb3eb272302189397bc25b4451a9bfb4e8ba56413c39c9cd21bc1df9896f0232dd1825aad51fabc045d
|
||||
DIST freetype-2.5.5-infinality-patches.tar.xz 24380 SHA256 6b7bc373b068c71feca2e19c3741993ee0ff787984aa0653ca66814e05ef195f SHA512 8831e3337214cc57a0381c56ef6750f85b11f1b6358adaa3dda34d449f234335bede124be9d23df817ae8c06f80c8e3ce63ed3fc32eb05586b8c8e43ce52e575 WHIRLPOOL 27b945e9524e984ef57f96415a86095d91dea8fa8e402a3eb6a3d7c38a7636d53d5e47fc37b734ca88f41a499f3398ab9d7bd147e1424c19b09f41e17f2cbe8d
|
||||
DIST freetype-2.5.5.tar.bz2 1714529 SHA256 387bcc4b780b12484aa2ec9f7db1a55d8286eb5639f45fbc0fbba7a4e5a1afb9 SHA512 1fc72d24da1744a6a5faf3338e49912c81ce83f30def1e80a2a15b50e7f83893a4fe24a70ef88b65ecc217bed1c15d85804c364eba221b35e25531c727fe8559 WHIRLPOOL 57cf0f020cda6a66cfe8e2a30e1e997c0fd7f97bdaed38da65cce0b360fcc60cfdf1ba0724c1745668ae3f80743052e135edb8356dff4c90365caa6262d59158
|
||||
DIST freetype-2.6-infinality-patches.tar.xz 24356 SHA256 95bd7f6bd191063e4691e000b1f59aa776a6c0afb5501e19a88d7b72ec47831e SHA512 87e206ffe78b9411753c0491da9ef6bbea4f9dde45cba539f0d51e9c5c4461c94b75af8fc8b96b9b9d5c7d7c63ac1ec88c227e93db197c56e02ead60b502d9a0 WHIRLPOOL 3d671e637ed4f1b7adfa862be684f8513d58e7071ce7ef1e26ca3a4311c0ec5e1817409299f0266129fe0b2c2bd330fdf6e6894e05ef937ba94c95b6e860dcd0
|
||||
DIST freetype-2.6.1.tar.bz2 1744692 SHA256 2f6e9a7de3ae8e85bdd2fe237e27d868d3ba7a27495e65906455c27722dd1a17 SHA512 cbc003e8f353d47ddcc2110aa8ecfdc1df53e61698e1ed68ed60afd5fd1d10d921c9719a505196c95865a68482822f9cccf5d131ec36d64c0230def774e7bb4b WHIRLPOOL 6319c8764f8d29669b241f0152338d356761d65a75235544c0c831aa03700e8b663b40b501519e57f09968c98bc8d56d1005ad069c9ee066c679b3400e20779a
|
||||
DIST freetype-2.6.tar.bz2 1726219 SHA256 8469fb8124764f85029cc8247c31e132a2c5e51084ddce2a44ea32ee4ae8347e SHA512 0242c832dcac3d9dc5d434b7f5145e63f2289d5df32f16e1c7afc1e31c3c92f0dd374e20dfef79a9ecb26b14419f42b0d897c7154f249f629c35ee7af0aa5297 WHIRLPOOL bf7f105b74348a1ca0e95e21091670a5d73793e8aea8aa8e0dad515086885a182f3bced713c2cf76704c7814031f308a642d6db45a0c065627d0e7bdcaedffd6
|
||||
DIST freetype-doc-2.5.5.tar.bz2 108133 SHA256 68becbae3578a8101e9f3c55f10e435fb75535011d3f7a523719371e86e368e7 SHA512 0e2455433f72766ec88275d2e53e49630457579a83ca491697bb5ce12196ee964618d1af86956651557d34e8ea1d57f75f69e0d60ef90e943509bc571370fb64 WHIRLPOOL 28d13ae3ce9bc3fb278df9a963cef3622672fa288fc0fd654e874054bedccd8510a3dcf7636ea2ec107b5299984742607d2a9436d5e473202856e27bf262655f
|
||||
DIST freetype-doc-2.6.1.tar.bz2 477313 SHA256 69b1102c9f4e7d75ad2701618f7e5c084d819264755ecbf11893e3cc6de0e0f5 SHA512 8353c5324166004f8e65c92bbe9be567c7ed2681b0c125758df8be098cd51983016a1387d58b147c2d57c984fcd0a615fe580e38d6e0ed445c5781e28c7c77b3 WHIRLPOOL c1f9f27db8975d89f91c8fff4ed523536525747bf57d116d5dd220986370287e8b05a4678fe31cbb0c08461cd9a49cbd6d9d05769d22a03220227c40baed2359
|
||||
DIST freetype-doc-2.6.tar.bz2 477177 SHA256 4868ec0b2b6890a1db296b00ce302ebf311b93b08aabd7ffca902e9c16b3e470 SHA512 ca8e5c44ac912c939e891b1e3386852d1771806f1f5684429964a6bac284d5cb51e80645a4b492067ad8c46e0e91d1651e8f593b3d5c03c5bceeaec1c51b6b15 WHIRLPOOL e02cb2b4382aabfd0ed48a8e652467bc11dee0a7b7591a5d3755012f903218c5ed3030ee3eb9888393cc9bad52585687e7794f82883fdf1d64835a87c27c2cd2
|
||||
DIST ft2demos-2.5.5.tar.bz2 182006 SHA256 b87c7deb5d9b1fddb8520c091a5491cc63ecac4de25139e1da38aebee82195ea SHA512 c6e1855f2315665e39a894ecfcb65f8546de435c1dada0ea0a6665a1e3ef22331d6949cd9261dfb6b68e653631d4c2e74f8ea31b53b40e46f44ab4dae38e368b WHIRLPOOL 55d6add5e3fac008a39231e3805e151a5a9b7cafb6ef970e546d96d3fa338a6a4a744aeb59ea04804312164aedd5e5a21e19773dbf5c42a1acfc42d283d90930
|
||||
DIST ft2demos-2.6.1.tar.bz2 190308 SHA256 369d27ae65ba04c2e3e74cf948ebcc5aa51abd47cd2e1d7d5cad0bc1f82da2aa SHA512 9740e1ae7fa4f8a932de3766dc8512c22a847d606b99aaff568865a68e059b3970ca9708d6c17f4d171f6f9bb63194f2c3498adf5461e3233b3b3206c57c6d7e WHIRLPOOL 84d59e27300085e4551f622374d0080184f0180d4b3c9447492af906612c7da3cfb3bf66e8f038c3fa008c2d590d7956fc4a2d347190d45b028c729949182b69
|
||||
DIST ft2demos-2.6.tar.bz2 190240 SHA256 f8f4bc2a2e76e0dbe61838e452c5a7daf1d4bd9dfa44691940bf308f776d32b6 SHA512 f9b8dfe40266ffdd2927e0d2cfe641b9028de07935d0abcd0a2dadcf0359700c296cd2a9b0c4114f47c0cd1489db287224a31b7dbcb1f6b937b1bdfcda3c1db8 WHIRLPOOL 400796659c523f4c2c16c8c523161cbf34505be5a08d1eb601312362cf0eb226fa86561d199d34f0e1a9e83bd76525663e9a040865f456bfa3ed49b64d51720d
|
||||
|
@ -0,0 +1,162 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
inherit autotools-multilib flag-o-matic multilib toolchain-funcs
|
||||
|
||||
INFINALITY_PATCH="03-infinality-2.6-2015.10.04.patch"
|
||||
|
||||
DESCRIPTION="A high-quality and portable font engine"
|
||||
HOMEPAGE="http://www.freetype.org/"
|
||||
SRC_URI="mirror://sourceforge/freetype/${P/_/}.tar.bz2
|
||||
mirror://nongnu/freetype/${P/_/}.tar.bz2
|
||||
utils? ( mirror://sourceforge/freetype/ft2demos-${PV}.tar.bz2
|
||||
mirror://nongnu/freetype/ft2demos-${PV}.tar.bz2 )
|
||||
doc? ( mirror://sourceforge/freetype/${PN}-doc-${PV}.tar.bz2
|
||||
mirror://nongnu/freetype/${PN}-doc-${PV}.tar.bz2 )
|
||||
infinality? ( https://dev.gentoo.org/~polynomial-c/${INFINALITY_PATCH}.xz )"
|
||||
|
||||
LICENSE="|| ( FTL GPL-2+ )"
|
||||
SLOT="2"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x64-freebsd ~x86-freebsd ~x86-interix ~amd64-linux ~arm-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris ~x86-winnt"
|
||||
IUSE="X +adobe-cff bindist bzip2 debug doc fontforge harfbuzz
|
||||
infinality png static-libs utils"
|
||||
RESTRICT="!bindist? ( bindist )" # bug 541408
|
||||
|
||||
CDEPEND=">=sys-libs/zlib-1.2.8-r1[${MULTILIB_USEDEP}]
|
||||
bzip2? ( >=app-arch/bzip2-1.0.6-r4[${MULTILIB_USEDEP}] )
|
||||
harfbuzz? ( >=media-libs/harfbuzz-0.9.19[truetype,${MULTILIB_USEDEP}] )
|
||||
png? ( >=media-libs/libpng-1.2.51:=[${MULTILIB_USEDEP}] )
|
||||
utils? (
|
||||
X? (
|
||||
>=x11-libs/libX11-1.6.2[${MULTILIB_USEDEP}]
|
||||
>=x11-libs/libXau-1.0.7-r1[${MULTILIB_USEDEP}]
|
||||
>=x11-libs/libXdmcp-1.1.1-r1[${MULTILIB_USEDEP}]
|
||||
)
|
||||
)"
|
||||
DEPEND="${CDEPEND}
|
||||
virtual/pkgconfig"
|
||||
RDEPEND="${CDEPEND}
|
||||
abi_x86_32? ( utils? ( !app-emulation/emul-linux-x86-xlibs[-abi_x86_32(-)] ) )"
|
||||
PDEPEND="infinality? ( media-libs/fontconfig-infinality )"
|
||||
|
||||
src_prepare() {
|
||||
enable_option() {
|
||||
sed -i -e "/#define $1/a #define $1" \
|
||||
include/${PN}/config/ftoption.h \
|
||||
|| die "unable to enable option $1"
|
||||
}
|
||||
|
||||
disable_option() {
|
||||
sed -i -e "/#define $1/ { s:^:/*:; s:$:*/: }" \
|
||||
include/${PN}/config/ftoption.h \
|
||||
|| die "unable to disable option $1"
|
||||
}
|
||||
|
||||
# This is the same as the 01 patch from infinality
|
||||
epatch "${FILESDIR}"/${PN}-2.3.2-enable-valid.patch
|
||||
|
||||
if use infinality; then
|
||||
epatch ${WORKDIR}/${INFINALITY_PATCH}
|
||||
|
||||
# FT_CONFIG_OPTION_SUBPIXEL_RENDERING is already enabled in freetype-2.4.11
|
||||
enable_option TT_CONFIG_OPTION_SUBPIXEL_HINTING
|
||||
fi
|
||||
|
||||
if ! use bindist; then
|
||||
# See http://freetype.org/patents.html
|
||||
# ClearType is covered by several Microsoft patents in the US
|
||||
enable_option FT_CONFIG_OPTION_SUBPIXEL_RENDERING
|
||||
fi
|
||||
|
||||
if ! use adobe-cff; then
|
||||
enable_option CFF_CONFIG_OPTION_OLD_ENGINE
|
||||
fi
|
||||
|
||||
if use debug; then
|
||||
enable_option FT_DEBUG_LEVEL_TRACE
|
||||
enable_option FT_DEBUG_MEMORY
|
||||
fi
|
||||
|
||||
epatch "${FILESDIR}"/${PN}-2.4.11-sizeof-types.patch # 459966
|
||||
|
||||
if use utils; then
|
||||
cd "${WORKDIR}/ft2demos-${PV}" || die
|
||||
# Disable tests needing X11 when USE="-X". (bug #177597)
|
||||
if ! use X; then
|
||||
sed -i -e "/EXES\ +=\ ftdiff/ s:^:#:" Makefile || die
|
||||
fi
|
||||
cd "${S}" || die
|
||||
fi
|
||||
|
||||
# we need non-/bin/sh to run configure
|
||||
if [[ -n ${CONFIG_SHELL} ]] ; then
|
||||
sed -i -e "1s:^#![[:space:]]*/bin/sh:#!$CONFIG_SHELL:" \
|
||||
"${S}"/builds/unix/configure || die
|
||||
fi
|
||||
|
||||
autotools-utils_src_prepare
|
||||
}
|
||||
|
||||
multilib_src_configure() {
|
||||
append-flags -fno-strict-aliasing
|
||||
type -P gmake &> /dev/null && export GNUMAKE=gmake
|
||||
|
||||
local myeconfargs=(
|
||||
--enable-biarch-config
|
||||
$(use_with bzip2)
|
||||
$(use_with harfbuzz)
|
||||
$(use_with png)
|
||||
|
||||
# avoid using libpng-config
|
||||
LIBPNG_CFLAGS="$($(tc-getPKG_CONFIG) --cflags libpng)"
|
||||
LIBPNG_LDFLAGS="$($(tc-getPKG_CONFIG) --libs libpng)"
|
||||
)
|
||||
|
||||
autotools-utils_src_configure
|
||||
}
|
||||
|
||||
multilib_src_compile() {
|
||||
default
|
||||
|
||||
if multilib_is_native_abi && use utils; then
|
||||
einfo "Building utils"
|
||||
# fix for Prefix, bug #339334
|
||||
emake \
|
||||
X11_PATH="${EPREFIX}/usr/$(get_libdir)" \
|
||||
FT2DEMOS=1 TOP_DIR_2="${WORKDIR}/ft2demos-${PV}"
|
||||
fi
|
||||
}
|
||||
|
||||
multilib_src_install() {
|
||||
default
|
||||
|
||||
if multilib_is_native_abi && use utils; then
|
||||
einfo "Installing utils"
|
||||
rm "${WORKDIR}"/ft2demos-${PV}/bin/README || die
|
||||
local ft2demo
|
||||
for ft2demo in ../ft2demos-${PV}/bin/*; do
|
||||
./libtool --mode=install $(type -P install) -m 755 "$ft2demo" \
|
||||
"${ED}"/usr/bin || die
|
||||
done
|
||||
fi
|
||||
}
|
||||
|
||||
multilib_src_install_all() {
|
||||
if use fontforge; then
|
||||
# Probably fontforge needs less but this way makes things simplier...
|
||||
einfo "Installing internal headers required for fontforge"
|
||||
local header
|
||||
find src/truetype include/internal -name '*.h' | \
|
||||
while read header; do
|
||||
mkdir -p "${ED}/usr/include/freetype2/internal4fontforge/$(dirname ${header})" || die
|
||||
cp ${header} "${ED}/usr/include/freetype2/internal4fontforge/$(dirname ${header})" || die
|
||||
done
|
||||
fi
|
||||
|
||||
dodoc docs/{CHANGES,CUSTOMIZE,DEBUG,INSTALL.UNIX,*.txt,PROBLEMS,TODO}
|
||||
use doc && dohtml -r docs/*
|
||||
|
||||
prune_libtool_files --all
|
||||
}
|
@ -0,0 +1,48 @@
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Id$
|
||||
|
||||
EAPI=5
|
||||
inherit autotools
|
||||
|
||||
DESCRIPTION="A library for the manipulation of RDF file in LADSPA plugins"
|
||||
HOMEPAGE="https://github.com/swh/LRDF"
|
||||
SRC_URI="https://github.com/swh/LRDF/tarball/${PV} -> ${P}.tar.gz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux ~ppc-macos"
|
||||
IUSE="libressl static-libs"
|
||||
|
||||
RDEPEND="
|
||||
!libressl? ( >=dev-libs/openssl-1:0 )
|
||||
libressl? ( dev-libs/libressl )
|
||||
media-libs/raptor:2
|
||||
>=media-libs/ladspa-sdk-1.12"
|
||||
DEPEND="${RDEPEND}
|
||||
virtual/pkgconfig"
|
||||
|
||||
DOCS=( AUTHORS ChangeLog README )
|
||||
|
||||
src_unpack() {
|
||||
unpack ${A}
|
||||
mv *-LRDF-* "${S}"
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
sed -i -e 's:usr/local:usr:' examples/{instances,remove}_test.c || die #392221
|
||||
eautoreconf
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
econf $(use_enable static-libs static)
|
||||
}
|
||||
|
||||
src_test() {
|
||||
has_version media-plugins/swh-plugins && default #392221
|
||||
}
|
||||
|
||||
src_install() {
|
||||
default
|
||||
rm -f "${ED}"usr/lib*/liblrdf.la
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue