Sync with portage [Tue Apr 18 02:04:51 MSK 2017].

mhiretskiy 855
root 7 years ago
parent 9a95c44912
commit 189ed9830b

@ -1 +1,2 @@
DIST ec2-ami-tools-1.5.6.zip 156541 SHA256 7aa6f2e581d52febf8850b3657a2f01c2f0180d91d33bdb1c246d485c1194708 SHA512 77ce82acbccf32bb1b900ef0b8c7440d4fc05e9b883081432935c6fef94b1f27191a0147e73c9eec680eca94c62075ab81bb8b0c33bec56bb2b861876de0129d WHIRLPOOL 1c7d20edde821e307eb8190413658e48d49a9c17d73b6c67a93b89f6b22512b1149c524d0a8111c5e6d36ca26465ae4a7f44cf4adf523318692dbef9213ce1ac
DIST ec2-ami-tools-1.5.7.zip 156611 SHA256 5a45d9f393d2e144124d23d2312b3a8918c5a3f7463b48d55f8db3d56a3fb29f SHA512 2754ded47cbe842f58e12207c4bb7f81c8cd366dc506cbadfa9bda74d91fd5f8e1cafbb117612b14833368ff5943c4943a072d1679f23f591c15f2f49b61b4c2 WHIRLPOOL d88c0259683d7823fd911e357e2b13516cb845972e728a2ae93d29741be3cfa49a1604cfea47f815c5d104bdd71b6c162a26224b3c632d4836976a56d1b640e4

@ -0,0 +1,51 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
USE_RUBY="ruby21 ruby22"
inherit ruby-single versionator
DESCRIPTION="Command-line tools that serve as client interface to the Amazon EC2 web service"
HOMEPAGE="http://developer.amazonwebservices.com/connect/entry.jspa?externalID=368&categoryID=88"
SRC_URI="http://s3.amazonaws.com/ec2-downloads/${P}.zip"
LICENSE="Amazon
|| ( Ruby GPL-2 )"
SLOT="0"
KEYWORDS="~amd64 ~x86"
DEPEND="app-arch/unzip"
RDEPEND="
${RUBY_DEPS}
virtual/ruby-ssl
net-misc/rsync
net-misc/curl"
src_prepare() {
# Remove a left behind license file.
rm -f lib/ec2/oem/LICENSE.txt || die 'Removal of LICENSE failed.'
eapply_user
}
src_install() {
dobin bin/*
insinto /usr
doins -r lib
insinto /etc/ec2/amitools
doins etc/ec2/amitools/*
dodir /etc/env.d
echo "EC2_AMITOOL_HOME=/usr" >> "${T}"/99${PN} || die "Can't write environment variable."
doenvd "${T}"/99${PN}
}
pkg_postinst() {
ewarn "Remember to run \`env-update && source /etc/profile\` if you plan"
ewarn "to use these tools in a shell before logging out (or restarting"
ewarn "your login manager)."
}

@ -9,7 +9,7 @@ SRC_URI="mirror://sourceforge/mktwpol/${P}.tar.gz"
LICENSE="CC-BY-SA-3.0"
SLOT="0"
KEYWORDS="amd64 ppc ~x86 ~x86-fbsd"
KEYWORDS="amd64 ppc x86 ~x86-fbsd"
IUSE=""
RDEPEND="app-admin/tripwire"

@ -13,7 +13,7 @@ if [[ "${PV}" == "9999" ]] ; then
EGIT_REPO_URI="https://github.com/gentoo-perl/perl-cleaner.git"
else
SRC_URI="mirror://gentoo/${P}.tar.bz2 https://dev.gentoo.org/~dilfridge/distfiles/${P}.tar.bz2"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh ~sparc x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
LICENSE="GPL-2"

@ -3,7 +3,7 @@
EAPI="5"
USE_RUBY="ruby21"
USE_RUBY="ruby21 ruby22"
RUBY_FAKEGEM_RECIPE_TEST="rspec3"

@ -11,7 +11,7 @@ SRC_URI="https://github.com/Tripwire/tripwire-open-source/archive/${PV}.tar.gz -
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 ~ppc ~x86 ~x86-fbsd"
KEYWORDS="amd64 ~ppc x86 ~x86-fbsd"
IUSE="libressl ssl static +tools"
DEPEND="sys-devel/automake

@ -9,7 +9,7 @@ SRC_URI="https://github.com/akopytov/sysbench/archive/${PV}.tar.gz -> ${P}.tar.g
LICENSE="GPL-2+"
SLOT="0"
KEYWORDS="amd64 ~x86"
KEYWORDS="amd64 x86"
IUSE="aio mysql postgres test"
RDEPEND="aio? ( dev-libs/libaio )

@ -1,2 +1 @@
DIST hashcat-3.30.tar.gz 3970267 SHA256 d255147cbbf6b3cacea81b818ee228170969b61487dd7d49b339fc94dfe53e8e SHA512 8f160a5ec4bd9add83cfc468e9335dcfc9297585180c67263fce18235a8b748f75205fa5bd5ddd1c34efc65569d94408ba98c6181a2b1ab760f33371f92c3c54 WHIRLPOOL c9396118d4223175f7bb19f095a590b66ba8cdbb9970a1e84b406b7423a6a0b3009491dd6c8b7394d38eee1f796fe290ac88b839e30d6166077ae54fbedc528b
DIST hashcat-3.40.tar.gz 4099155 SHA256 92627197daa850dc7d723793150801c0791fe31f6c767de68417cee097ad6f4c SHA512 fd8d1927703cfe56c7708c460cc142de4ce64d96b651ed68817b70e6a53cac376a191d16752cbb7cabfcb0230299301173a5eda6c27e6188e79b5d83d758378e WHIRLPOOL bcd25930b4a9616f7a0ebd19575432d98a8abd67083ca434758d40d887ca642418a0305d54e4a0ade662f34059cdc1705097423733d02d97ba1eda0213280e4d
DIST hashcat-3.5.0.tar.gz 4103461 SHA256 af764698f48145ac96cf01c65cf76bcb88e205aeb4614025ae32d847571c4390 SHA512 7efc860461894a550fbacc406a40fec400232a120818180abba3d53f26bd3a503f58e7d189e4afad0f871c2244ff68371b145af58ab097478fe2d73f39c9a6b3 WHIRLPOOL 927ac7bfe902fcc9ead971f785f8231656335c1c190ffda1bb40b5affb8d7a3fb67d084102513a44e457a9d5ba1fba3969aa0e954669a33071fc65fba0b2424f

@ -1,49 +0,0 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit eutils pax-utils multilib
DESCRIPTION="World's fastest and most advanced password recovery utility"
HOMEPAGE="https://github.com/hashcat/hashcat"
SRC_URI="https://github.com/hashcat/hashcat/archive/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~x86 ~amd64"
IUSE="custom-cflags video_cards_nvidia video_cards_fglrx"
DEPEND="virtual/opencl"
RDEPEND="${DEPEND}"
src_prepare() {
#do not strip
sed -i "/LFLAGS += -s/d" src/Makefile
#do not add random CFLAGS
sed -i "s/-O2//" src/Makefile || die
export PREFIX=/usr
export LIBRARY_FOLDER="/usr/$(get_libdir)"
eapply_user
}
src_compile() {
default
pax-mark -mr hashcat
}
src_test() {
if use video_cards_nvidia; then
addwrite /dev/nvidia0
addwrite /dev/nvidiactl
addwrite /dev/nvidia-uvm
if [ ! -w /dev/nvidia0 ]; then
einfo "To run these tests, portage likely must be in the video group."
einfo "Please run \"gpasswd -a portage video\" if the tests will fail"
fi
elif use vidia_cards_fglrx; then
addwrite /dev/ati
fi
#this always exits with 255 despite success
#./hashcat -b -m 2500 || die "Test failed"
./hashcat -a 3 -m 1500 nQCk49SiErOgk
}

@ -11,7 +11,7 @@ SRC_URI="https://github.com/KiCad/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="|| ( GPL-3+ CC-BY-3.0 ) GPL-2"
SLOT="0"
KEYWORDS="amd64 ~x86"
KEYWORDS="amd64 x86"
IUSE="html pdf"
LANGS="en fr it ja nl pl"
for lang in ${LANGS}; do

@ -28,15 +28,15 @@ REQUIRED_USE="
"
RDEPEND="
>=app-editors/gedit-3.16[python?]
>=app-editors/gedit-3.16
>=dev-libs/glib-2.32:2
>=dev-libs/libpeas-1.7.0[gtk,python?]
>=dev-libs/libpeas-1.7.0[gtk]
>=x11-libs/gtk+-3.9:3
>=x11-libs/gtksourceview-3.21.3:3.0
python? (
${PYTHON_DEPS}
>=app-editors/gedit-3.16[introspection,${PYTHON_USEDEP}]
dev-libs/libpeas[${PYTHON_USEDEP}]
>=app-editors/gedit-3.16[introspection,python,${PYTHON_USEDEP}]
dev-libs/libpeas[python,${PYTHON_USEDEP}]
>=dev-python/dbus-python-0.82[${PYTHON_USEDEP}]
dev-python/pycairo[${PYTHON_USEDEP}]
dev-python/pygobject:3[cairo,${PYTHON_USEDEP}]

@ -38,7 +38,7 @@ COMMON_DEPEND="
${PYTHON_DEPS}
dev-python/pycairo[${PYTHON_USEDEP}]
>=dev-python/pygobject-3:3[cairo,${PYTHON_USEDEP}]
dev-libs/libpeas[${PYTHON_USEDEP}] )
dev-libs/libpeas[python,${PYTHON_USEDEP}] )
spell? ( >=app-text/gspell-0.2.5:0= )
"
RDEPEND="${COMMON_DEPEND}

@ -0,0 +1,12 @@
diff -r e2da872593c0 configure.in
--- a/configure.in Tue Mar 24 22:15:53 2015 -0400
+++ b/configure.in Mon Apr 17 10:13:05 2017 +0200
@@ -4449,7 +4449,7 @@
AC_CHECK_HEADER(ncurses/curses.h, curses_h_file=ncurses/curses.h)
AC_CHECK_HEADER(ncurses/term.h, term_h_file=ncurses/term.h)
XE_ADD_OBJS(terminfo.o)
- XE_PREPEND(-lncurses, LIBS)
+ XE_PREPEND($(pkg-config ncurses --libs), LIBS)
if test "$ac_cv_header_ncurses_curses_h" != "yes" ; then
dnl Try again, and check for the bogus ncurses/ include bug.

@ -64,6 +64,8 @@ src_prepare() {
# see bug 576512
epatch "${FILESDIR}"/xemacs-21.4.24-gcc5.patch
epatch "${FILESDIR}"/xemacs-21.4.24-glibc-macro.patch
# see bug 615544
epatch "${FILESDIR}"/xemacs-21.4.24-ncurses-tinfo.patch
# Some binaries and man pages are installed under suffixed names
# to avoid collions with their GNU Emacs counterparts (see below).

@ -1,4 +1,4 @@
# Copyright 1999-2016 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# Note: xemacs currently does not work with a hardened profile. If you
@ -63,6 +63,8 @@ src_prepare() {
epatch "${FILESDIR}"/xemacs-21.4.19-db.patch
# see bug 576512
epatch "${FILESDIR}"/xemacs-21.4.24-gcc5.patch
# see bug 615544
epatch "${FILESDIR}"/xemacs-21.4.24-ncurses-tinfo.patch
# Some binaries and man pages are installed under suffixed names
# to avoid collions with their GNU Emacs counterparts (see below).

@ -1,6 +1,4 @@
DIST ruby-2.0.0-p247.tar.bz2 10804581 SHA256 08e3d4b85b8a1118a8e81261f59dd8b4ddcfd70b6ae554e0ec5ceb99c3185e8a SHA512 9bd793d0df8f0704fb1521a937c09ecc89b777851312793f0b3391df11dec8239808585697b932c4a94665fa29c7781503166dbd109f269811788c4c648f285f WHIRLPOOL 59eb0a5d71125b63226435d825f5793fd9ff7f065851b902ee45f974fdaf5f5498d12b07d8e20e668a1e4636dbc8f34d025f8713bd98e3c565327484e484a863
DIST ruby-2.1.5.tar.xz 9371780 SHA256 22ba1eb8d475c9ed7e0541418d86044c1ea4c093ab79c300c38fc0f721afe9a3 SHA512 8a257da64158d49bc2810695baf4b5849ef83e3dde452bf1e4823e52e8261225427d729fce2fb4e9b53d6d17ca9c96d491f242535c2f963738b74f90944e2a0b WHIRLPOOL 7dab5db91e56ba95a221c456fbcebfb86aff038a084b7638f504e91e4c9b45a0ad7ee0296d6531281c33d75a31ee4f5ad05af6567a93034316f3992ebc5d6bf3
DIST ruby-2.2.0.tar.xz 10304244 SHA256 848714e280fc5fb44dbac3b060b206e56c1947006324ee68a174d68b483ef8ca SHA512 cd7e52faa464df8aca7ccfa23a5f06248e1ad82bc8c9f1829aa1b51ff37b15973b8caaa68e914d837325b8d59427fda4f3cad82c50925e1c84e688324a2a155d WHIRLPOOL 6d06101015b6dee7f0f4409597b481d3ad08679237ad884866e513bbad2d851afc09ac414c60871d2ceeb9221013497f0c482c481c95c3e8f20a4664e95148fa
DIST ruby-2.2.2.tar.xz 10463044 SHA256 f033b5d08ab57083e48c1d81bcd7399967578c370b664da90e12a32891424462 SHA512 bd72d0a4c017e2527659f64ef2781bbe8bd540a2302eaa60234a12282fd53c359e04205c56385402c67e81bb9dab3b88de53de82e12bb13e3386c26301043b64 WHIRLPOOL ee9c3a664ac1d67bd9ff4ed8fcc7d4c8e9b6e2f5774c938f876223b22022b498932afc41990890a03b560c65ffe29a039761d18bbeeab46fe13cbfff515bc115
DIST ruby-2.3.0.tar.xz 11294412 SHA256 70125af0cfd7048e813a5eecab3676249582bfb65cfd57b868c3595f966e4097 SHA512 d893c5e6db5a0533e0da48d899c619964388852ef90e7d1b92a4363d5f189cd2dba32a009581f62b9f42a8e6027975fc3c18b64faf356f5e3ac43a8d69ec5327 WHIRLPOOL 1d39136dad87580339f87057649d136e1b76cb58118b275d6847b791be8f6882820de892d9fb7144991a7acf30c355311fd289d1a7931fd018b3b95398945c07
DIST ruby-2.4.1.tar.xz 9939188 SHA256 4fc8a9992de3e90191de369270ea4b6c1b171b7941743614cc50822ddc1fe654 SHA512 e6fd290b6edd166348b70f0f1c56f7ed9d956c4c1eb91d97d0548041ca4196b9b75ec1ad35c745bdbfd4de195899093e7205d7f02b014ecf1c48e6f31cf25903 WHIRLPOOL b45a6e3bd70e6ef802d084ad87ad0eddd85932e07939bd6ed6a2e6944aa289f231971fedd7d1eece792becb08312f37b80073a2a9df070f61f32747c0708523e

@ -1,12 +0,0 @@
(add-to-list 'load-path "@SITELISP@")
(autoload 'ruby-mode "ruby-mode" "Major mode to edit ruby files." t)
(add-to-list 'auto-mode-alist '("Rakefile\\'" . ruby-mode))
(add-to-list 'auto-mode-alist '("\\.\\(rake\\|rb\\)\\'" . ruby-mode))
(add-to-list 'interpreter-mode-alist '("ruby" . ruby-mode))
(autoload 'run-ruby "inf-ruby" "Run an inferior Ruby process" t)
(autoload 'inf-ruby-keys "inf-ruby" "Set local key defs for inf-ruby in ruby-mode")
(add-hook 'ruby-mode-hook 'inf-ruby-keys)

@ -1,12 +0,0 @@
(add-to-list 'load-path "@SITELISP@")
(autoload 'ruby-mode "ruby-mode" "Major mode to edit ruby files." t)
(add-to-list 'auto-mode-alist '("Rakefile\\'" . ruby-mode))
(add-to-list 'auto-mode-alist '("\\.\\(rake\\|rb\\)\\'" . ruby-mode))
(add-to-list 'interpreter-mode-alist '("ruby" . ruby-mode))
(autoload 'run-ruby "inf-ruby" "Run an inferior Ruby process" t)
(autoload 'inf-ruby-keys "inf-ruby" "Set local key defs for inf-ruby in ruby-mode")
(add-hook 'ruby-mode-hook 'inf-ruby-keys)

@ -1,18 +0,0 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
inherit elisp
DESCRIPTION="Emacs major mode for editing Ruby code"
HOMEPAGE="http://www.ruby-lang.org/"
SRC_URI="mirror://ruby/ruby-${PV}.tar.xz"
LICENSE="GPL-3+"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos"
S="${WORKDIR}/ruby-${PV}/misc"
DOCS="README"
SITEFILE="50${PN}-gentoo-${PV}.el"

@ -1,18 +0,0 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
inherit elisp
DESCRIPTION="Emacs major mode for editing Ruby code"
HOMEPAGE="http://www.ruby-lang.org/"
SRC_URI="mirror://ruby/ruby-${PV}.tar.xz"
LICENSE="GPL-3+"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos"
S="${WORKDIR}/ruby-${PV}/misc"
DOCS="README"
SITEFILE="50${PN}-gentoo-${PV}.el"

@ -1,4 +1,4 @@
# Copyright 1999-2015 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=3
@ -65,7 +65,8 @@ src_install() {
insinto "${CLSOURCEROOT%/}/swank"
doins *.lisp swank.asd || die
dodir "${CLSYSTEMROOT}" || die
dosym "${CLSOURCEROOT%/}/swank/swank.asd" "${CLSYSTEMROOT}" || die
dosym "${EPREFIX}${CLSOURCEROOT%/}/swank/swank.asd" \
"${CLSYSTEMROOT%/}/swank.asd" || die
## install contribs
elisp-install ${PN}/contrib/ contrib/*.{el,elc,scm,goo} || die

@ -17,7 +17,7 @@ if [[ ${PV} = *9999* ]]; then
SRC_URI=""
else
SRC_URI="http://wiki.qemu-project.org/download/${P}.tar.bz2"
KEYWORDS="~amd64 ~arm64 ~ppc ~ppc64 ~x86 ~x86-fbsd"
KEYWORDS="amd64 ~arm64 ~ppc ~ppc64 x86 ~x86-fbsd"
fi
# bug #606088

@ -1,770 +0,0 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
PYTHON_COMPAT=( python2_7 )
PYTHON_REQ_USE="ncurses,readline"
PLOCALES="bg de_DE fr_FR hu it tr zh_CN"
inherit eutils flag-o-matic linux-info toolchain-funcs multilib python-r1 \
user udev fcaps readme.gentoo-r1 pax-utils l10n
if [[ ${PV} = *9999* ]]; then
EGIT_REPO_URI="git://git.qemu.org/qemu.git"
inherit git-r3
SRC_URI=""
else
SRC_URI="http://wiki.qemu-project.org/download/${P}.tar.bz2"
KEYWORDS="amd64 ~arm64 ~ppc ~ppc64 x86 ~x86-fbsd"
fi
# bug #606088
SRC_URI+="
https://dev.gentoo.org/~tamiko/distfiles/${P}-CVE-2016-9602-patches.tar.xz"
DESCRIPTION="QEMU + Kernel-based Virtual Machine userland tools"
HOMEPAGE="http://www.qemu.org http://www.linux-kvm.org"
LICENSE="GPL-2 LGPL-2 BSD-2"
SLOT="0"
IUSE="accessibility +aio alsa bluetooth bzip2 +caps +curl debug +fdt
glusterfs gnutls gtk gtk2 infiniband iscsi +jpeg kernel_linux
kernel_FreeBSD lzo ncurses nfs nls numa opengl +pin-upstream-blobs +png
pulseaudio python rbd sasl +seccomp sdl sdl2 selinux smartcard snappy
spice ssh static static-user systemtap tci test +threads usb usbredir
vde +vhost-net virgl virtfs +vnc vte xattr xen xfs"
COMMON_TARGETS="aarch64 alpha arm cris i386 m68k microblaze microblazeel
mips mips64 mips64el mipsel or32 ppc ppc64 s390x sh4 sh4eb sparc
sparc64 x86_64"
IUSE_SOFTMMU_TARGETS="${COMMON_TARGETS}
lm32 moxie ppcemb tricore unicore32 xtensa xtensaeb"
IUSE_USER_TARGETS="${COMMON_TARGETS}
armeb mipsn32 mipsn32el ppc64abi32 ppc64le sparc32plus tilegx"
use_softmmu_targets=$(printf ' qemu_softmmu_targets_%s' ${IUSE_SOFTMMU_TARGETS})
use_user_targets=$(printf ' qemu_user_targets_%s' ${IUSE_USER_TARGETS})
IUSE+=" ${use_softmmu_targets} ${use_user_targets}"
# Allow no targets to be built so that people can get a tools-only build.
# Block USE flag configurations known to not work.
REQUIRED_USE="${PYTHON_REQUIRED_USE}
gtk2? ( gtk )
qemu_softmmu_targets_arm? ( fdt )
qemu_softmmu_targets_microblaze? ( fdt )
qemu_softmmu_targets_ppc? ( fdt )
qemu_softmmu_targets_ppc64? ( fdt )
sdl2? ( sdl )
static? ( static-user !alsa !bluetooth !gtk !gtk2 !opengl !pulseaudio )
virtfs? ( xattr )
vte? ( gtk )"
# Dependencies required for qemu tools (qemu-nbd, qemu-img, qemu-io, ...)
# and user/softmmu targets (qemu-*, qemu-system-*).
#
# Yep, you need both libcap and libcap-ng since virtfs only uses libcap.
#
# The attr lib isn't always linked in (although the USE flag is always
# respected). This is because qemu supports using the C library's API
# when available rather than always using the extranl library.
#
# To configure and compile qemu user targets or tools alone the following
# dependencies are not strictly necessary:
# alsa? ( >=media-libs/alsa-lib-1.0.13 )
# fdt? ( >=sys-apps/dtc-1.4.0[static-libs(+)] )
# pulseaudio? ( media-sound/pulseaudio )
# seccomp? ( >=sys-libs/libseccomp-2.1.0[static-libs(+)] )
# but these are so few it is not worth the effort to separate this list.
TARGETS_DEPEND="
>=dev-libs/glib-2.0[static-libs(+)]
>=x11-libs/pixman-0.28.0[static-libs(+)]
sys-libs/zlib[static-libs(+)]
accessibility? (
app-accessibility/brltty[api]
app-accessibility/brltty[static-libs(+)]
)
aio? ( dev-libs/libaio[static-libs(+)] )
alsa? ( >=media-libs/alsa-lib-1.0.13 )
bluetooth? ( net-wireless/bluez )
bzip2? ( app-arch/bzip2[static-libs(+)] )
caps? ( sys-libs/libcap-ng[static-libs(+)] )
curl? ( >=net-misc/curl-7.15.4[static-libs(+)] )
fdt? ( >=sys-apps/dtc-1.4.0[static-libs(+)] )
glusterfs? ( >=sys-cluster/glusterfs-3.4.0[static-libs(+)] )
gnutls? (
dev-libs/nettle:=[static-libs(+)]
>=net-libs/gnutls-3.0:=[static-libs(+)]
)
gtk? (
gtk2? (
x11-libs/gtk+:2
vte? ( x11-libs/vte:0 )
)
!gtk2? (
x11-libs/gtk+:3
vte? ( x11-libs/vte:2.91 )
)
)
infiniband? ( sys-fabric/librdmacm:=[static-libs(+)] )
iscsi? ( net-libs/libiscsi )
jpeg? ( virtual/jpeg:0=[static-libs(+)] )
lzo? ( dev-libs/lzo:2[static-libs(+)] )
ncurses? (
sys-libs/ncurses:0=[unicode]
sys-libs/ncurses:0=[static-libs(+)]
)
nfs? ( >=net-fs/libnfs-1.9.3[static-libs(+)] )
numa? ( sys-process/numactl[static-libs(+)] )
opengl? (
virtual/opengl
media-libs/libepoxy[static-libs(+)]
media-libs/mesa[static-libs(+)]
media-libs/mesa[egl,gbm]
)
png? ( media-libs/libpng:0=[static-libs(+)] )
pulseaudio? ( media-sound/pulseaudio )
python? ( ${PYTHON_DEPS} )
rbd? ( sys-cluster/ceph[static-libs(+)] )
sasl? ( dev-libs/cyrus-sasl[static-libs(+)] )
sdl? (
!sdl2? (
media-libs/libsdl[X]
>=media-libs/libsdl-1.2.11[static-libs(+)]
)
sdl2? (
media-libs/libsdl2[X]
media-libs/libsdl2[static-libs(+)]
)
)
seccomp? ( >=sys-libs/libseccomp-2.1.0[static-libs(+)] )
smartcard? ( >=app-emulation/libcacard-2.5.0[static-libs(+)] )
snappy? ( app-arch/snappy[static-libs(+)] )
spice? (
>=app-emulation/spice-protocol-0.12.3
>=app-emulation/spice-0.12.0[static-libs(+)]
)
ssh? ( >=net-libs/libssh2-1.2.8[static-libs(+)] )
systemtap? ( dev-util/systemtap )
usbredir? ( >=sys-apps/usbredir-0.6[static-libs(+)] )
usb? ( >=virtual/libusb-1-r2[static-libs(+)] )
vde? ( net-misc/vde[static-libs(+)] )
virgl? ( media-libs/virglrenderer[static-libs(+)] )
virtfs? ( sys-libs/libcap )
xattr? ( sys-apps/attr[static-libs(+)] )
xen? ( app-emulation/xen-tools:= )
xfs? ( sys-fs/xfsprogs[static-libs(+)] )"
X86_FIRMWARE_DEPEND="
>=sys-firmware/ipxe-1.0.0_p20130624
pin-upstream-blobs? (
~sys-firmware/seabios-1.10.1
~sys-firmware/sgabios-0.1_pre8
~sys-firmware/vgabios-0.7a
)
!pin-upstream-blobs? (
sys-firmware/seabios
sys-firmware/sgabios
sys-firmware/vgabios
)"
CDEPEND="
!static? ( ${TARGETS_DEPEND//\[static-libs(+)]} )
qemu_softmmu_targets_i386? ( ${X86_FIRMWARE_DEPEND} )
qemu_softmmu_targets_x86_64? ( ${X86_FIRMWARE_DEPEND} )"
DEPEND="${CDEPEND}
dev-lang/perl
=dev-lang/python-2*
sys-apps/texinfo
virtual/pkgconfig
kernel_linux? ( >=sys-kernel/linux-headers-2.6.35 )
gtk? ( nls? ( sys-devel/gettext ) )
static? ( ${TARGETS_DEPEND} )
static-user? ( ${TARGETS_DEPEND} )
test? (
dev-libs/glib[utils]
sys-devel/bc
)"
RDEPEND="${CDEPEND}
selinux? ( sec-policy/selinux-qemu )"
PATCHES=(
"${FILESDIR}"/${PN}-2.5.0-cflags.patch
"${FILESDIR}"/${PN}-2.5.0-sysmacros.patch
"${FILESDIR}"/${PN}-2.7.0-CVE-2016-8669-1.patch #597108
"${FILESDIR}"/${PN}-2.8.0-CVE-2016-9908.patch #601826
"${FILESDIR}"/${PN}-2.8.0-CVE-2016-9912.patch #602630
"${FILESDIR}"/${PN}-2.8.0-CVE-2016-10028.patch #603444
"${FILESDIR}"/${PN}-2.8.0-CVE-2016-10155.patch #606720
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-2615.patch #608034
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-2630.patch #609396
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5525-1.patch #606264
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5525-2.patch
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5552.patch #606722
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5578.patch #607000
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5579.patch #607100
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5667.patch #607766
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5856.patch #608036
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5857.patch #608038
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5898.patch #608520
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5931.patch #608728
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5973.patch #609334
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-5987.patch #609398
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-6058.patch #609638
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-2620.patch #609206
"${FILESDIR}"/${PN}-2.8.0-CVE-2017-6505.patch #612220
"${S}-CVE-2016-9602-patches"
)
STRIP_MASK="/usr/share/qemu/palcode-clipper"
QA_PREBUILT="
usr/share/qemu/openbios-ppc
usr/share/qemu/openbios-sparc64
usr/share/qemu/openbios-sparc32
usr/share/qemu/palcode-clipper
usr/share/qemu/s390-ccw.img
usr/share/qemu/u-boot.e500"
QA_WX_LOAD="usr/bin/qemu-i386
usr/bin/qemu-x86_64
usr/bin/qemu-alpha
usr/bin/qemu-arm
usr/bin/qemu-cris
usr/bin/qemu-m68k
usr/bin/qemu-microblaze
usr/bin/qemu-microblazeel
usr/bin/qemu-mips
usr/bin/qemu-mipsel
usr/bin/qemu-or32
usr/bin/qemu-ppc
usr/bin/qemu-ppc64
usr/bin/qemu-ppc64abi32
usr/bin/qemu-sh4
usr/bin/qemu-sh4eb
usr/bin/qemu-sparc
usr/bin/qemu-sparc64
usr/bin/qemu-armeb
usr/bin/qemu-sparc32plus
usr/bin/qemu-s390x
usr/bin/qemu-unicore32"
DOC_CONTENTS="If you don't have kvm compiled into the kernel, make sure you have the
kernel module loaded before running kvm. The easiest way to ensure that the
kernel module is loaded is to load it on boot.
For AMD CPUs the module is called 'kvm-amd'.
For Intel CPUs the module is called 'kvm-intel'.
Please review /etc/conf.d/modules for how to load these.
Make sure your user is in the 'kvm' group. Just run
$ gpasswd -a <USER> kvm
then have <USER> re-login.
For brand new installs, the default permissions on /dev/kvm might not let
you access it. You can tell udev to reset ownership/perms:
$ udevadm trigger -c add /dev/kvm
If you want to register binfmt handlers for qemu user targets:
For openrc:
# rc-update add qemu-binfmt
For systemd:
# ln -s /usr/share/qemu/binfmt.d/qemu.conf /etc/binfmt.d/qemu.conf"
pkg_pretend() {
if use kernel_linux && kernel_is lt 2 6 25; then
eerror "This version of KVM requres a host kernel of 2.6.25 or higher."
elif use kernel_linux; then
if ! linux_config_exists; then
eerror "Unable to check your kernel for KVM support"
else
CONFIG_CHECK="~KVM ~TUN ~BRIDGE"
ERROR_KVM="You must enable KVM in your kernel to continue"
ERROR_KVM_AMD="If you have an AMD CPU, you must enable KVM_AMD in"
ERROR_KVM_AMD+=" your kernel configuration."
ERROR_KVM_INTEL="If you have an Intel CPU, you must enable"
ERROR_KVM_INTEL+=" KVM_INTEL in your kernel configuration."
ERROR_TUN="You will need the Universal TUN/TAP driver compiled"
ERROR_TUN+=" into your kernel or loaded as a module to use the"
ERROR_TUN+=" virtual network device if using -net tap."
ERROR_BRIDGE="You will also need support for 802.1d"
ERROR_BRIDGE+=" Ethernet Bridging for some network configurations."
use vhost-net && CONFIG_CHECK+=" ~VHOST_NET"
ERROR_VHOST_NET="You must enable VHOST_NET to have vhost-net"
ERROR_VHOST_NET+=" support"
if use amd64 || use x86 || use amd64-linux || use x86-linux; then
CONFIG_CHECK+=" ~KVM_AMD ~KVM_INTEL"
fi
use python && CONFIG_CHECK+=" ~DEBUG_FS"
ERROR_DEBUG_FS="debugFS support required for kvm_stat"
# Now do the actual checks setup above
check_extra_config
fi
fi
if grep -qs '/usr/bin/qemu-kvm' "${EROOT}"/etc/libvirt/qemu/*.xml; then
eerror "The kvm/qemu-kvm wrappers no longer exist, but your libvirt"
eerror "instances are still pointing to it. Please update your"
eerror "configs in /etc/libvirt/qemu/ to use the -enable-kvm flag"
eerror "and the right system binary (e.g. qemu-system-x86_64)."
die "update your virt configs to not use qemu-kvm"
fi
}
pkg_setup() {
enewgroup kvm 78
}
# Sanity check to make sure target lists are kept up-to-date.
check_targets() {
local var=$1 mak=$2
local detected sorted
pushd "${S}"/default-configs >/dev/null || die
# Force C locale until glibc is updated. #564936
detected=$(echo $(printf '%s\n' *-${mak}.mak | sed "s:-${mak}.mak::" | LC_COLLATE=C sort -u))
sorted=$(echo $(printf '%s\n' ${!var} | LC_COLLATE=C sort -u))
if [[ ${sorted} != "${detected}" ]] ; then
eerror "The ebuild needs to be kept in sync."
eerror "${var}: ${sorted}"
eerror "$(printf '%-*s' ${#var} configure): ${detected}"
die "sync ${var} to the list of targets"
fi
popd >/dev/null
}
handle_locales() {
# Make sure locale list is kept up-to-date.
local detected sorted
detected=$(echo $(cd po && printf '%s\n' *.po | grep -v messages.po | sed 's:.po$::' | sort -u))
sorted=$(echo $(printf '%s\n' ${PLOCALES} | sort -u))
if [[ ${sorted} != "${detected}" ]] ; then
eerror "The ebuild needs to be kept in sync."
eerror "PLOCALES: ${sorted}"
eerror " po/*.po: ${detected}"
die "sync PLOCALES"
fi
# Deal with selective install of locales.
if use nls ; then
# Delete locales the user does not want. #577814
rm_loc() { rm po/$1.po || die; }
l10n_for_each_disabled_locale_do rm_loc
else
# Cheap hack to disable gettext .mo generation.
rm -f po/*.po
fi
}
src_prepare() {
check_targets IUSE_SOFTMMU_TARGETS softmmu
check_targets IUSE_USER_TARGETS linux-user
# Alter target makefiles to accept CFLAGS set via flag-o
sed -i -r \
-e 's/^(C|OP_C|HELPER_C)FLAGS=/\1FLAGS+=/' \
Makefile Makefile.target || die
default
# Fix ld and objcopy being called directly
tc-export AR LD OBJCOPY
# Verbose builds
MAKEOPTS+=" V=1"
# Run after we've applied all patches.
handle_locales
}
##
# configures qemu based on the build directory and the build type
# we are using.
#
qemu_src_configure() {
debug-print-function ${FUNCNAME} "$@"
local buildtype=$1
local builddir="${S}/${buildtype}-build"
mkdir "${builddir}"
local conf_opts=(
--prefix=/usr
--sysconfdir=/etc
--libdir=/usr/$(get_libdir)
--docdir=/usr/share/doc/${PF}/html
--disable-bsd-user
--disable-guest-agent
--disable-strip
--disable-werror
# We support gnutls/nettle for crypto operations. It is possible
# to use gcrypt when gnutls/nettle are disabled (but not when they
# are enabled), but it's not really worth the hassle. Disable it
# all the time to avoid automatically detecting it. #568856
--disable-gcrypt
--python="${PYTHON}"
--cc="$(tc-getCC)"
--cxx="$(tc-getCXX)"
--host-cc="$(tc-getBUILD_CC)"
$(use_enable debug debug-info)
$(use_enable debug debug-tcg)
--enable-docs
$(use_enable tci tcg-interpreter)
$(use_enable xattr attr)
)
# Disable options not used by user targets. This simplifies building
# static user targets (USE=static-user) considerably.
conf_notuser() {
if [[ ${buildtype} == "user" ]] ; then
echo "--disable-${2:-$1}"
else
use_enable "$@"
fi
}
conf_opts+=(
$(conf_notuser accessibility brlapi)
$(conf_notuser aio linux-aio)
$(conf_notuser bzip2)
$(conf_notuser bluetooth bluez)
$(conf_notuser caps cap-ng)
$(conf_notuser curl)
$(conf_notuser fdt)
$(conf_notuser glusterfs)
$(conf_notuser gnutls)
$(conf_notuser gnutls nettle)
$(conf_notuser gtk)
$(conf_notuser infiniband rdma)
$(conf_notuser iscsi libiscsi)
$(conf_notuser jpeg vnc-jpeg)
$(conf_notuser kernel_linux kvm)
$(conf_notuser lzo)
$(conf_notuser ncurses curses)
$(conf_notuser nfs libnfs)
$(conf_notuser numa)
$(conf_notuser opengl)
$(conf_notuser png vnc-png)
$(conf_notuser rbd)
$(conf_notuser sasl vnc-sasl)
$(conf_notuser sdl)
$(conf_notuser seccomp)
$(conf_notuser smartcard)
$(conf_notuser snappy)
$(conf_notuser spice)
$(conf_notuser ssh libssh2)
$(conf_notuser usb libusb)
$(conf_notuser usbredir usb-redir)
$(conf_notuser vde)
$(conf_notuser vhost-net)
$(conf_notuser virgl virglrenderer)
$(conf_notuser virtfs)
$(conf_notuser vnc)
$(conf_notuser vte)
$(conf_notuser xen)
$(conf_notuser xen xen-pci-passthrough)
$(conf_notuser xfs xfsctl)
)
if [[ ! ${buildtype} == "user" ]] ; then
# audio options
local audio_opts="oss"
use alsa && audio_opts="alsa,${audio_opts}"
use sdl && audio_opts="sdl,${audio_opts}"
use pulseaudio && audio_opts="pa,${audio_opts}"
conf_opts+=(
--audio-drv-list="${audio_opts}"
)
use gtk && conf_opts+=( --with-gtkabi=$(usex gtk2 2.0 3.0) )
use sdl && conf_opts+=( --with-sdlabi=$(usex sdl2 2.0 1.2) )
fi
case ${buildtype} in
user)
conf_opts+=(
--enable-linux-user
--disable-system
--disable-blobs
--disable-tools
)
local static_flag="static-user"
;;
softmmu)
conf_opts+=(
--disable-linux-user
--enable-system
--disable-tools
--with-system-pixman
)
local static_flag="static"
;;
tools)
conf_opts+=(
--disable-linux-user
--disable-system
--disable-blobs
--enable-tools
)
local static_flag="static"
;;
esac
local targets="${buildtype}_targets"
[[ -n ${targets} ]] && conf_opts+=( --target-list="${!targets}" )
# Add support for SystemTAP
use systemtap && conf_opts+=( --enable-trace-backend=dtrace )
# We always want to attempt to build with PIE support as it results
# in a more secure binary. But it doesn't work with static or if
# the current GCC doesn't have PIE support.
if use ${static_flag}; then
conf_opts+=( --static --disable-pie )
else
gcc-specs-pie && conf_opts+=( --enable-pie )
fi
echo "../configure ${conf_opts[*]}"
cd "${builddir}"
../configure "${conf_opts[@]}" || die "configure failed"
# FreeBSD's kernel does not support QEMU assigning/grabbing
# host USB devices yet
use kernel_FreeBSD && \
sed -i -E -e "s|^(HOST_USB=)bsd|\1stub|" "${S}"/config-host.mak
}
src_configure() {
local target
python_setup
softmmu_targets= softmmu_bins=()
user_targets= user_bins=()
for target in ${IUSE_SOFTMMU_TARGETS} ; do
if use "qemu_softmmu_targets_${target}"; then
softmmu_targets+=",${target}-softmmu"
softmmu_bins+=( "qemu-system-${target}" )
fi
done
for target in ${IUSE_USER_TARGETS} ; do
if use "qemu_user_targets_${target}"; then
user_targets+=",${target}-linux-user"
user_bins+=( "qemu-${target}" )
fi
done
softmmu_targets=${softmmu_targets#,}
user_targets=${user_targets#,}
[[ -n ${softmmu_targets} ]] && qemu_src_configure "softmmu"
[[ -n ${user_targets} ]] && qemu_src_configure "user"
qemu_src_configure "tools"
}
src_compile() {
if [[ -n ${user_targets} ]]; then
cd "${S}/user-build"
default
fi
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build"
default
fi
cd "${S}/tools-build"
default
}
src_test() {
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build"
pax-mark m */qemu-system-* #515550
emake -j1 check
emake -j1 check-report.html
fi
}
qemu_python_install() {
python_domodule "${S}/scripts/qmp/qmp.py"
python_doscript "${S}/scripts/kvm/vmxcap"
python_doscript "${S}/scripts/qmp/qmp-shell"
python_doscript "${S}/scripts/qmp/qemu-ga-client"
}
# Generate binfmt support files.
# - /etc/init.d/qemu-binfmt script which registers the user handlers (openrc)
# - /usr/share/qemu/binfmt.d/qemu.conf (for use with systemd-binfmt)
generate_initd() {
local out="${T}/qemu-binfmt"
local out_systemd="${T}/qemu.conf"
local d="${T}/binfmt.d"
einfo "Generating qemu binfmt scripts and configuration files"
# Generate the debian fragments first.
mkdir -p "${d}"
"${S}"/scripts/qemu-binfmt-conf.sh \
--debian \
--exportdir "${d}" \
--qemu-path "${EPREFIX}/usr/bin" \
|| die
# Then turn the fragments into a shell script we can source.
sed -E -i \
-e 's:^([^ ]+) (.*)$:\1="\2":' \
"${d}"/* || die
# Generate the init.d script by assembling the fragments from above.
local f qcpu package interpreter magic mask
cat "${FILESDIR}"/qemu-binfmt.initd.head >"${out}" || die
for f in "${d}"/qemu-* ; do
source "${f}"
# Normalize the cpu logic like we do in the init.d for the native cpu.
qcpu=${package#qemu-}
case ${qcpu} in
arm*) qcpu="arm";;
mips*) qcpu="mips";;
ppc*) qcpu="ppc";;
s390*) qcpu="s390";;
sh*) qcpu="sh";;
sparc*) qcpu="sparc";;
esac
cat <<EOF >>"${out}"
if [ "\${cpu}" != "${qcpu}" -a -x "${interpreter}" ] ; then
echo ':${package}:M::${magic}:${mask}:${interpreter}:'"\${QEMU_BINFMT_FLAGS}" >/proc/sys/fs/binfmt_misc/register
fi
EOF
echo ":${package}:M::${magic}:${mask}:${interpreter}:OC" >>"${out_systemd}"
done
cat "${FILESDIR}"/qemu-binfmt.initd.tail >>"${out}" || die
}
src_install() {
if [[ -n ${user_targets} ]]; then
cd "${S}/user-build"
emake DESTDIR="${ED}" install
# Install binfmt handler init script for user targets.
generate_initd
doinitd "${T}/qemu-binfmt"
# Install binfmt/qemu.conf.
insinto "/usr/share/qemu/binfmt.d"
doins "${T}/qemu.conf"
fi
if [[ -n ${softmmu_targets} ]]; then
cd "${S}/softmmu-build"
emake DESTDIR="${ED}" install
# This might not exist if the test failed. #512010
[[ -e check-report.html ]] && dohtml check-report.html
if use kernel_linux; then
udev_newrules "${FILESDIR}"/65-kvm.rules-r1 65-kvm.rules
fi
if use python; then
python_foreach_impl qemu_python_install
fi
fi
cd "${S}/tools-build"
emake DESTDIR="${ED}" install
# Disable mprotect on the qemu binaries as they use JITs to be fast #459348
pushd "${ED}"/usr/bin >/dev/null
pax-mark mr "${softmmu_bins[@]}" "${user_bins[@]}" # bug 575594
popd >/dev/null
# Install config file example for qemu-bridge-helper
insinto "/etc/qemu"
doins "${FILESDIR}/bridge.conf"
# Remove the docdir placed qmp-commands.txt
mv "${ED}/usr/share/doc/${PF}/html/qmp-commands.txt" "${S}/docs/" || die
cd "${S}"
dodoc Changelog MAINTAINERS docs/specs/pci-ids.txt
newdoc pc-bios/README README.pc-bios
dodoc docs/qmp-*.txt
if [[ -n ${softmmu_targets} ]]; then
# Remove SeaBIOS since we're using the SeaBIOS packaged one
rm "${ED}/usr/share/qemu/bios.bin"
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../seabios/bios.bin /usr/share/qemu/bios.bin
fi
# Remove vgabios since we're using the vgabios packaged one
rm "${ED}/usr/share/qemu/vgabios.bin"
rm "${ED}/usr/share/qemu/vgabios-cirrus.bin"
rm "${ED}/usr/share/qemu/vgabios-qxl.bin"
rm "${ED}/usr/share/qemu/vgabios-stdvga.bin"
rm "${ED}/usr/share/qemu/vgabios-vmware.bin"
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../vgabios/vgabios.bin /usr/share/qemu/vgabios.bin
dosym ../vgabios/vgabios-cirrus.bin /usr/share/qemu/vgabios-cirrus.bin
dosym ../vgabios/vgabios-qxl.bin /usr/share/qemu/vgabios-qxl.bin
dosym ../vgabios/vgabios-stdvga.bin /usr/share/qemu/vgabios-stdvga.bin
dosym ../vgabios/vgabios-vmware.bin /usr/share/qemu/vgabios-vmware.bin
fi
# Remove sgabios since we're using the sgabios packaged one
rm "${ED}/usr/share/qemu/sgabios.bin"
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../sgabios/sgabios.bin /usr/share/qemu/sgabios.bin
fi
# Remove iPXE since we're using the iPXE packaged one
rm "${ED}"/usr/share/qemu/pxe-*.rom
if use qemu_softmmu_targets_x86_64 || use qemu_softmmu_targets_i386; then
dosym ../ipxe/8086100e.rom /usr/share/qemu/pxe-e1000.rom
dosym ../ipxe/80861209.rom /usr/share/qemu/pxe-eepro100.rom
dosym ../ipxe/10500940.rom /usr/share/qemu/pxe-ne2k_pci.rom
dosym ../ipxe/10222000.rom /usr/share/qemu/pxe-pcnet.rom
dosym ../ipxe/10ec8139.rom /usr/share/qemu/pxe-rtl8139.rom
dosym ../ipxe/1af41000.rom /usr/share/qemu/pxe-virtio.rom
fi
fi
DISABLE_AUTOFORMATTING=true
readme.gentoo_create_doc
}
pkg_postinst() {
DISABLE_AUTOFORMATTING=true
readme.gentoo_print_elog
if [[ -n ${softmmu_targets} ]] && use kernel_linux; then
udev_reload
fi
fcaps cap_net_admin /usr/libexec/qemu-bridge-helper
}
pkg_info() {
echo "Using:"
echo " $(best_version app-emulation/spice-protocol)"
echo " $(best_version sys-firmware/ipxe)"
echo " $(best_version sys-firmware/seabios)"
if has_version 'sys-firmware/seabios[binary]'; then
echo " USE=binary"
else
echo " USE=''"
fi
echo " $(best_version sys-firmware/vgabios)"
}

@ -67,7 +67,6 @@ REQUIRED_USE="${PYTHON_REQUIRED_USE}
# when available rather than always using the extranl library.
ALL_DEPEND="
>=dev-libs/glib-2.0[static-libs(+)]
>=x11-libs/pixman-0.28.0[static-libs(+)]
sys-libs/zlib[static-libs(+)]
python? ( ${PYTHON_DEPS} )
systemtap? ( dev-util/systemtap )
@ -76,6 +75,7 @@ ALL_DEPEND="
# Dependencies required for qemu tools (qemu-nbd, qemu-img, qemu-io, ...)
# softmmu targets (qemu-system-*).
SOFTMMU_TOOLS_DEPEND="
>=x11-libs/pixman-0.28.0[static-libs(+)]
accessibility? (
app-accessibility/brltty[api]
app-accessibility/brltty[static-libs(+)]

@ -75,7 +75,6 @@ REQUIRED_USE="${PYTHON_REQUIRED_USE}
# but these are so few it is not worth the effort to separate this list.
ALL_DEPEND="
>=dev-libs/glib-2.0[static-libs(+)]
>=x11-libs/pixman-0.28.0[static-libs(+)]
sys-libs/zlib[static-libs(+)]
python? ( ${PYTHON_DEPS} )
systemtap? ( dev-util/systemtap )
@ -84,6 +83,7 @@ ALL_DEPEND="
# Dependencies required for qemu tools (qemu-nbd, qemu-img, qemu-io, ...)
# softmmu targets (qemu-system-*).
SOFTMMU_TOOLS_DEPEND="
>=x11-libs/pixman-0.28.0[static-libs(+)]
accessibility? (
app-accessibility/brltty[api]
app-accessibility/brltty[static-libs(+)]

@ -1 +1,2 @@
DIST eselect-postgresql-1.2.1.tbz2 3645 SHA256 661ef3cbb1627798af3c8d6c526f4a6367620a5fef08c287a633e1babf43f938 SHA512 9b24cb7620dd3de979ef595c60ebf607cd9da5c7d3c4da19ebe242c25961883e2db54341f916690abb9fe7a76663d9f1ac73fc76c90389f72eff425aa6fb43e4 WHIRLPOOL e7ef4f3d250f4f345d28bccdd43fa1639b8ed80b9f6a4aabd4f7df5f4337845ee0f4ce653fde596209094b01fc0e5c624872affbfa042382f3963a49d600827f
DIST eselect-postgresql-2.0.tbz2 4326 SHA256 8f56309350f91abaa98eeead42dbd6b186b858f25f207010fe9d10271c754f55 SHA512 bc72d752bc4b2d8f3c255d446253143ff0036f6ca1a0c10eb19e23b8242bd5a912272298034279a6f9ca50c13fccbb6b89c79ed647f762a2ccb36f416060cd87 WHIRLPOOL 9fced29136ee861a78651905329d6a3156bfdbdf61427accc7aa5ac33e934c97e6f673d7a3f5b634d020be01ff0f0533218b8d9d3b83253963f32eae8d82f004

@ -0,0 +1,35 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
DESCRIPTION="Utility to select the default PostgreSQL slot"
HOMEPAGE="http://www.gentoo.org/"
SRC_URI="http://dev.gentoo.org/~titanofold/${P}.tbz2"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~ppc-macos ~x86-solaris"
IUSE=""
RDEPEND="app-admin/eselect"
# All dev-db/postgresql ebuilds from 10.0 on are well supported. Earlier
# ebuilds may present some quality of life issues.
PDEPEND="
!<dev-db/postgresql-9.6.2-r1:9.6
!<dev-db/postgresql-9.5.6-r1:9.5
!<dev-db/postgresql-9.4.11-r1:9.4
!<dev-db/postgresql-9.3.16-r1:9.3
!<dev-db/postgresql-9.2.20-r1
"
src_install() {
insinto /usr/share/eselect/modules
doins postgresql.eselect
dosym /usr/bin/eselect /usr/bin/postgresql-config
}
pkg_postinst() {
postgresql-config update
}

@ -1 +0,0 @@
DIST x-unikey-1.0.4.tar.bz2 561391 SHA256 aa7dd444853538bcba0f24c4c19692c34d4553a1df213a260c2628a7116b2dd9 SHA512 47abe4087957c4926550a0121d5cdc7b760f39691fae91c8e0562fc0f4577c22a04192667d362c9838b87fd97d2111afef1260fc88d8234bc5656bab248b5b06 WHIRLPOOL 144788e4a43e55c5a30fbb11eba6953d147823d3229550cbec370d583fd1a74e97f68c3e14b1988074788561f4e0adb836829f06ab88b1f725051dd3840256d9

@ -1,9 +0,0 @@
# x-unikey works only with *.UTF-8 locales
#LANG=en_US.UTF-8
# Uncomment this if you use XIM.
#GTK_IM_MODULE="xim"
#XMODIFIERS="@im=unikey"
# If you use unikey-gtk only, then comment this
#GTK_IM_MODULE="unikey"

@ -1,12 +0,0 @@
diff -Naur x-unikey-1.0.4.orig/src/ukengine/usrkeymap.cpp x-unikey-1.0.4/src/ukengine/usrkeymap.cpp
--- x-unikey-1.0.4.orig/src/ukengine/usrkeymap.cpp 2008-12-18 00:39:38.000000000 +0900
+++ x-unikey-1.0.4/src/ukengine/usrkeymap.cpp 2008-12-18 00:38:56.000000000 +0900
@@ -23,6 +23,8 @@
#include "stdafx.h"
#include <iostream>
+#include <cstring>
+
using namespace std;
#include <ctype.h>

@ -1,31 +0,0 @@
diff -ur x-unikey-1.0.4.orig/src/ukengine/mactab.cpp x-unikey-1.0.4/src/ukengine/mactab.cpp
--- x-unikey-1.0.4.orig/src/ukengine/mactab.cpp 2006-04-09 14:46:02.000000000 +0300
+++ x-unikey-1.0.4/src/ukengine/mactab.cpp 2009-08-10 14:50:50.000000000 +0300
@@ -287,7 +287,7 @@
char key[MAX_MACRO_KEY_LEN];
// Parse the input item
- char * pos = strchr(item, ':');
+ const char * pos = strchr(item, ':');
if (pos == NULL)
return -1;
int keyLen = (int)(pos - item);
diff -ur x-unikey-1.0.4.orig/src/ukengine/usrkeymap.cpp x-unikey-1.0.4/src/ukengine/usrkeymap.cpp
--- x-unikey-1.0.4.orig/src/ukengine/usrkeymap.cpp 2006-04-09 02:31:40.000000000 +0300
+++ x-unikey-1.0.4/src/ukengine/usrkeymap.cpp 2009-08-10 14:48:44.000000000 +0300
@@ -21,6 +21,8 @@
* Boston, MA 02111-1307, USA.
*/
+#include <stdio.h>
+
#include "stdafx.h"
#include <iostream>
using namespace std;
@@ -262,4 +264,4 @@
return i;
}
return -1;
-}
\ No newline at end of file
+}

@ -1,20 +0,0 @@
--- x-unikey-1.0.4.orig/src/unikey-gtk/Makefile.am 2005-10-16 12:39:15.000000000 +0900
+++ x-unikey-1.0.4/src/unikey-gtk/Makefile.am 2008-12-18 00:48:37.000000000 +0900
@@ -34,7 +34,7 @@
install-data-hook:
gtk-query-immodules-2.0 \
- > @gtk_sysconfdir@/gtk.immodules
+ > $(DESTDIR)@gtk_sysconfdir@/gtk.immodules
## $(moduledir)/im-vn.la \
## @GTK_PREFIX@/lib/gtk-2.0/@GTK_VERSION@/immodules/*.la \
@@ -42,7 +42,7 @@
uninstall-hook:
gtk-query-immodules-2.0 > \
- @gtk_sysconfdir@/gtk.immodules
+ $(DESTDIR)@gtk_sysconfdir@/gtk.immodules
## @GTK_PREFIX@/lib/gtk-2.0/@GTK_VERSION@/immodules/*.la \

@ -1,11 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="project">
<email>cjk@gentoo.org</email>
<name>Cjk</name>
</maintainer>
<upstream>
<remote-id type="sourceforge">unikey</remote-id>
</upstream>
</pkgmetadata>

@ -1,77 +0,0 @@
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
inherit autotools eutils multilib gnome2-utils
DESCRIPTION="Vietnamese X Input Method"
HOMEPAGE="http://www.unikey.org/"
SRC_URI="mirror://sourceforge/unikey/${P}.tar.bz2"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~ppc x86"
IUSE="nls gtk"
RDEPEND="x11-libs/libX11
x11-libs/libSM
x11-libs/libICE
gtk? ( >=x11-libs/gtk+-2.2:2 )
nls? ( virtual/libintl )"
DEPEND="${RDEPEND}
dev-libs/glib
virtual/pkgconfig
nls? ( sys-devel/gettext )"
pkg_setup() {
# An arch specific config directory is used on multilib systems
has_multilib_profile && GTK2_CONFDIR="/etc/gtk-2.0/${CHOST}"
GTK2_CONFDIR=${GTK2_CONFDIR:=/etc/gtk-2.0/}
}
src_prepare() {
epatch "${FILESDIR}"/${P}-gcc43.patch \
"${FILESDIR}"/${P}-gcc44.patch \
"${FILESDIR}"/${P}-gentoo.patch
eautoreconf
}
src_configure() {
local myconf
# --with-gtk-sysconfdir to prevent sandbox violation only
use gtk && myconf="--with-unikey-gtk --with-gtk-sysconfdir=${GTK2_CONFDIR}"
econf ${myconf}
}
src_install() {
if use gtk;then
dodir "${GTK2_CONFDIR}"
# emake DESTDIR="${D}" install -C src/unikey-gtk || die
fi
# dobin src/xim/ukxim src/gui/unikey
emake DESTDIR="${D}" install
doenvd "${FILESDIR}/01x-unikey"
dodoc AUTHORS CREDITS ChangeLog NEWS README TODO
cd doc
dodoc README1ST keymap-syntax manual options ukmacro \
unikey-manual-0.9.pdf unikey.png unikeyrc
}
pkg_postinst() {
elog
elog "Go to /etc/env.d/01x-unikey and uncomment appropriate lines"
elog "to enable x-unikey"
elog
if use gtk; then
gnome2_query_immodules_gtk2
elog "If you want to use x-unikey as the default gtk+ input method,"
elog "change GTK_IM_MODULE in /etc/env.d/01x-unikey to \"unikey\""
elog
fi
}
pkg_postrm() {
use gtk && gnome2_query_immodules_gtk2
}

@ -49,7 +49,7 @@ src_install() {
ewarn "as directory already exists there. Will assume you know"
ewarn "what you're doing."
else
dosym /usr/share/sgml/docbook/dsssl-stylesheets-${PV} \
dosym ../../docbook/dsssl-stylesheets-${PV} \
/usr/share/sgml/stylesheets/dsssl/docbook
fi

@ -49,7 +49,7 @@ src_install() {
ewarn "as directory already exists there. Will assume you know"
ewarn "what you're doing."
else
dosym /usr/share/sgml/docbook/dsssl-stylesheets-${PV} \
dosym ../../docbook/dsssl-stylesheets-${PV} \
/usr/share/sgml/stylesheets/dsssl/docbook
fi

@ -1,4 +1,4 @@
# Copyright 1999-2014 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=4
@ -27,7 +27,7 @@ src_compile() {
src_install() {
cd src
dobin expander boxcomment align_columns align_comments where_is
dosym /usr/bin/boxcomment /usr/bin/unboxcomment
dosym boxcomment /usr/bin/unboxcomment
insinto /usr/share/${P}
doins "${S}"/service

@ -0,0 +1,26 @@
From acc785dd63379f08f08b52fae9d7e5c5666495c8 Mon Sep 17 00:00:00 2001
From: Gilles Dartiguelongue <eva@gentoo.org>
Date: Mon, 17 Apr 2017 00:15:58 +0200
Subject: [PATCH] Silence gobject-introspection warning on version-less imports
---
plugins/charmap/charmap/__init__.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/plugins/charmap/charmap/__init__.py b/plugins/charmap/charmap/__init__.py
index b504cb61..6f8c2b61 100644
--- a/plugins/charmap/charmap/__init__.py
+++ b/plugins/charmap/charmap/__init__.py
@@ -16,6 +16,9 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+import gi
+gi.require_version('Gucharmap', '2.90')
+
from gi.repository import GObject, Gio, Pango, Gtk, Gtranslator, Gucharmap
from .panel import CharmapPanel
import sys
--
2.12.2

@ -0,0 +1,51 @@
From 1e4d042f7e9b28a58bd09af5c97e4282441113d2 Mon Sep 17 00:00:00 2001
From: Gilles Dartiguelongue <eva@gentoo.org>
Date: Sun, 16 Apr 2017 23:48:29 +0200
Subject: [PATCH 1/2] Switch gucharmap plugin to python3 loader
---
plugins/charmap/charmap/__init__.py | 2 +-
plugins/charmap/gtr-charmap.plugin.desktop.in | 2 +-
src/gtr-plugins-engine.c | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/plugins/charmap/charmap/__init__.py b/plugins/charmap/charmap/__init__.py
index 414157b1..b504cb61 100644
--- a/plugins/charmap/charmap/__init__.py
+++ b/plugins/charmap/charmap/__init__.py
@@ -17,7 +17,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
from gi.repository import GObject, Gio, Pango, Gtk, Gtranslator, Gucharmap
-from panel import CharmapPanel
+from .panel import CharmapPanel
import sys
import gettext
diff --git a/plugins/charmap/gtr-charmap.plugin.desktop.in b/plugins/charmap/gtr-charmap.plugin.desktop.in
index 3949c5f6..a872a545 100644
--- a/plugins/charmap/gtr-charmap.plugin.desktop.in
+++ b/plugins/charmap/gtr-charmap.plugin.desktop.in
@@ -1,5 +1,5 @@
[Plugin]
-Loader=python
+Loader=python3
Module=charmap
IAge=3
_Name=Character Map
diff --git a/src/gtr-plugins-engine.c b/src/gtr-plugins-engine.c
index 903ea735..8e41010a 100644
--- a/src/gtr-plugins-engine.c
+++ b/src/gtr-plugins-engine.c
@@ -64,7 +64,7 @@ gtr_plugins_engine_init (GtrPluginsEngine * engine)
GTR_TYPE_PLUGINS_ENGINE,
GtrPluginsEnginePrivate);
- peas_engine_enable_loader (PEAS_ENGINE (engine), "python");
+ peas_engine_enable_loader (PEAS_ENGINE (engine), "python3");
engine->priv->plugin_settings = g_settings_new ("org.gnome.gtranslator.plugins");
--
2.12.2

@ -0,0 +1,82 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
GNOME2_LA_PUNT="yes"
PYTHON_COMPAT=( python{3_4,3_5} )
inherit gnome2 python-single-r1
DESCRIPTION="An enhanced gettext po file editor for GNOME"
HOMEPAGE="https://wiki.gnome.org/Apps/Gtranslator"
LICENSE="GPL-3+ FDL-1.1+"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86"
IUSE="+introspection gnome-dictionary gucharmap spell"
REQUIRED_USE="gucharmap? ( introspection ${PYTHON_REQUIRED_USE} )"
COMMON_DEPEND="
>=dev-libs/glib-2.32:2[dbus]
>=x11-libs/gtk+-3.4.2:3[introspection?]
>=x11-libs/gtksourceview-3.0.0:3.0[introspection?]
>=dev-libs/gdl-3.6:3=
>=dev-libs/libxml2-2.4.12:2
>=dev-libs/json-glib-0.12.0
>=dev-libs/libpeas-1.2[gtk]
gnome-extra/libgda:5=
>=app-text/iso-codes-0.35
gnome-base/gsettings-desktop-schemas
gnome-dictionary? ( app-dicts/gnome-dictionary:= )
gucharmap? ( ${PYTHON_DEPS} )
introspection? ( >=dev-libs/gobject-introspection-0.9.3 )
spell? ( app-text/gtkspell:3= )
"
RDEPEND="${COMMON_DEPEND}
x11-themes/gnome-icon-theme-symbolic
gucharmap? (
>=dev-libs/libpeas-1.2[gtk,python,${PYTHON_USEDEP}]
dev-python/pygobject:3[${PYTHON_USEDEP}]
gnome-extra/gucharmap:2.90[introspection]
x11-libs/gtk+:3[introspection] )
"
DEPEND="${COMMON_DEPEND}
>=dev-util/gtk-doc-am-1
>=dev-util/intltool-0.50.1
>=sys-devel/gettext-0.17
virtual/pkgconfig
"
# eautoreconf requires gnome-base/gnome-common, app-text/yelp-tools
PATCHES=(
# Switch plugin to python3 loader
"${FILESDIR}"/${P}-gucharmap-python3.patch
# Silence g-i import warnings
"${FILESDIR}"/${P}-gi-silence.patch
)
pkg_setup() {
use gucharmap && python-single-r1_pkg_setup
}
src_prepare() {
DOCS="AUTHORS ChangeLog HACKING INSTALL NEWS README THANKS"
gnome2_src_prepare
if ! use gucharmap ; then
# don't install charmap plugin, it requires gnome-extra/gucharmap
sed -e 's:\scharmap\s: :g' -i plugins/Makefile.* ||
die "sed plugins/Makefile.* failed"
fi
}
src_configure() {
gnome2_src_configure \
--disable-static \
$(use_enable introspection) \
$(use_with gnome-dictionary dictionary) \
$(use_with spell gtkspell)
}

@ -5,6 +5,10 @@
<email>gnome@gentoo.org</email>
<name>Gentoo GNOME Desktop</name>
</maintainer>
<use>
<flag name="gnome-dictionary">Enable plugin for dictionary lookups using <pkg>app-dicts/gnome-dictionary</pkg>.</flag>
<flag name="gucharmap">Enable plugin for unicode symbols selection using <pkg>gnome-extra/gucharmap</pkg>.</flag>
</use>
<upstream>
<remote-id type="sourceforge">gtranslator</remote-id>
</upstream>

@ -15,7 +15,7 @@ HOMEPAGE="https://github.com/ConradIrwin/jist"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"
KEYWORDS="amd64"
IUSE=""
ruby_add_rdepend "dev-ruby/json:*"

@ -1 +0,0 @@
DIST uvconv-1.1.3b.tar.gz 36895 SHA256 b5c7ae6c6ae62de748dd24cc2665a4e18f2ae14a999004d64551823235b4bf14 SHA512 4a5058dea321b7441699ffdd8c5ef9f1f72632ef5e73ecce1d59434b8e8ea7c028739ba7f79123e7bc08439249cbc5b590e3341970ba576149b6d5e42a3d4c87 WHIRLPOOL b716972cc114975fb560cbf5950fb635abcc63ebc0bb41755363433286a3abf9978678058176cd8df50d9bc7f04d8ab5101dc8f5de14b4b590b81d23c8095c6b

@ -1,10 +0,0 @@
--- uvconv.orig/uvconvert/uvconvert.cpp 2004-07-26 05:19:18.000000000 +0900
+++ uvconv/uvconvert/uvconvert.cpp 2008-12-17 17:57:23.000000000 +0900
@@ -19,6 +19,7 @@
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
--------------------------------------------------------------------------------*/
+#include <cstring>
#include "prehdr.h"
#include "vnconv.h"

@ -1,13 +0,0 @@
diff --git a/uvconvert/Makefile b/uvconvert/Makefile
index 8819779..c610965 100644
--- a/uvconvert/Makefile
+++ b/uvconvert/Makefile
@@ -6,7 +6,7 @@ OPTFLAGS="-O3"
all: uvconv
uvconv: ${OBJS} libvnconv
- ${CXX} ${CXXFLAGS} ${OPTFLAGS} -o $@ ${OBJS} ${LIBS}
+ ${CXX} ${CXXFLAGS} ${OPTFLAGS} -o $@ ${OBJS} ${LIBS} ${LDFLAGS}
${OBJS}: %.o: %.cpp
${CXX} ${CXXFLAGS} ${OPTFLAGS} -c $< -o $@ -I${INCLUDE_DIR}

@ -1,11 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="project">
<email>cjk@gentoo.org</email>
<name>Cjk</name>
</maintainer>
<upstream>
<remote-id type="sourceforge">unikey</remote-id>
</upstream>
</pkgmetadata>

@ -1,32 +0,0 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="4"
inherit eutils toolchain-funcs
DESCRIPTION="A small utility that converts among Vietnamese charsets"
HOMEPAGE="http://unikey.org/"
SRC_URI="mirror://sourceforge/unikey/${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 x86"
IUSE=""
S="${WORKDIR}/${PN}"
src_prepare() {
epatch "${FILESDIR}"/${P}-gcc43.patch
epatch "${FILESDIR}"/${P}-ldflags.patch
}
src_compile() {
emake CXX="$(tc-getCXX)" OPTFLAGS="${CFLAGS}" -C uvconvert
}
src_install() {
dobin uvconvert/${PN}
doman uvconv.1
dodoc readme.txt AUTHORS CREDITS changes.txt
}

@ -16,7 +16,7 @@ SRC_URI="https://googletest.googlecode.com/files/${P}.zip"
LICENSE="BSD"
SLOT="0"
KEYWORDS="~alpha amd64 ~arm ~arm64 hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos"
KEYWORDS="~alpha amd64 ~arm ~arm64 hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos"
IUSE="examples static-libs"
DEPEND="app-arch/unzip

@ -11,7 +11,7 @@ SRC_URI="https://www.percona.com/downloads/XtraBackup/Percona-XtraBackup-${PV}/s
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="amd64 ~x86"
KEYWORDS="amd64 x86"
IUSE=""
DEPEND="

@ -14,7 +14,7 @@ HOMEPAGE="http://www.phpmyadmin.net/"
SRC_URI="https://files.phpmyadmin.net/${MY_PN}/${MY_PV}/${MY_P}.tar.xz"
LICENSE="GPL-2"
KEYWORDS="alpha amd64 hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~ppc-macos ~x64-macos ~x86-macos"
KEYWORDS="alpha amd64 hppa ~ia64 ~ppc ~ppc64 ~sparc x86 ~x86-fbsd ~ppc-macos ~x64-macos ~x86-macos"
IUSE="setup"
RDEPEND="

@ -14,7 +14,7 @@ HOMEPAGE="https://www.phpmyadmin.net/"
SRC_URI="https://files.phpmyadmin.net/${MY_PN}/${MY_PV}/${MY_P}.tar.xz"
LICENSE="GPL-2"
KEYWORDS="alpha amd64 ~arm hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~ppc-macos ~x64-macos ~x86-macos"
KEYWORDS="alpha amd64 ~arm hppa ~ia64 ~ppc ~ppc64 ~sparc x86 ~x86-fbsd ~ppc-macos ~x64-macos ~x86-macos"
IUSE="setup"
RDEPEND="

@ -0,0 +1,65 @@
# Directory that contains the unix socket. Created and controlled by
# the related initscript. The directory created will be owned
# root:postgres with mode 1775.
#
# /run/postgresql is the default directory.
PG_SOCKET_DIRECTORY="/run/postgresql"
# Which port and socket to bind PostgreSQL
PGPORT="5432"
# How long to wait for server to start in seconds
START_TIMEOUT=10
# NICE_QUIT ignores new connections and wait for clients to disconnect from
# server before shutting down. NICE_TIMEOUT in seconds determines how long to
# wait for this to succeed.
NICE_TIMEOUT=60
# Forecfully disconnect clients from server and shut down. This is performed
# after NICE_QUIT. Terminated client connections have their open transactions
# rolled back.
# Set RUDE_QUIT to "NO" to disable. RUDE_TIMEOUT in seconds.
RUDE_QUIT="YES"
RUDE_TIMEOUT=30
# If the server still fails to shutdown, you can force it to quit by setting
# this to YES and a recover-run will execute on the next startup.
# Set FORCE_QUIT to "YES" to enable. FORCE_TIMEOUT in seconds.
FORCE_QUIT="NO"
FORCE_TIMEOUT=2
# Extra options to run postmaster with, e.g.:
# -N is the maximal number of client connections
# -B is the number of shared buffers and has to be at least 2x the value for -N
# Please read the man-page to postmaster for more options. Many of these
# options can be set directly in the configuration file.
#PGOPTS="-N 512 -B 1024"
# Pass extra environment variables. If you have to export environment variables
# for the database process, this can be done here.
# Don't forget to escape quotes.
#PG_EXTRA_ENV="PGPASSFILE=\"/path/to/.pgpass\""
##############################################################################
#
# The following values should not be arbitrarily changed.
#
# `emerge --config dev-db/postgresql:@SLOT@' uses these values to
# determine where to create the data directory, where to place the
# configuration files, and any additional options to pass to initdb.
#
# The initscript also uses these variables to inform PostgreSQL where to find
# its data directory and configuration files.
#
##############################################################################
# Location of configuration files
PGDATA="/etc/postgresql-@SLOT@/"
# Where the data directory is located/to be created
DATA_DIR="/var/lib/postgresql/@SLOT@/data"
# Additional options to pass to initdb.
# See `man initdb' for available options.
PG_INITDB_OPTS="--encoding=UTF8"

@ -0,0 +1,65 @@
# Comma-separated list of directories that contain a unix
# socket. Created and controlled by the related initscript. The
# directories created will be owned root:postgres with mode 1775.
#
# /run/postgresql is the default directory.
PG_SOCKET_DIRECTORIES="/run/postgresql"
# Which port and socket to bind PostgreSQL
PGPORT="5432"
# How long to wait for server to start in seconds
START_TIMEOUT=10
# NICE_QUIT ignores new connections and wait for clients to disconnect from
# server before shutting down. NICE_TIMEOUT in seconds determines how long to
# wait for this to succeed.
NICE_TIMEOUT=60
# Forecfully disconnect clients from server and shut down. This is performed
# after NICE_QUIT. Terminated client connections have their open transactions
# rolled back.
# Set RUDE_QUIT to "NO" to disable. RUDE_TIMEOUT in seconds.
RUDE_QUIT="YES"
RUDE_TIMEOUT=30
# If the server still fails to shutdown, you can force it to quit by setting
# this to YES and a recover-run will execute on the next startup.
# Set FORCE_QUIT to "YES" to enable. FORCE_TIMEOUT in seconds.
FORCE_QUIT="NO"
FORCE_TIMEOUT=2
# Extra options to run postmaster with, e.g.:
# -N is the maximal number of client connections
# -B is the number of shared buffers and has to be at least 2x the value for -N
# Please read the man-page to postmaster for more options. Many of these
# options can be set directly in the configuration file.
#PGOPTS="-N 512 -B 1024"
# Pass extra environment variables. If you have to export environment variables
# for the database process, this can be done here.
# Don't forget to escape quotes.
#PG_EXTRA_ENV="PGPASSFILE=\"/path/to/.pgpass\""
##############################################################################
#
# The following values should not be arbitrarily changed.
#
# `emerge --config dev-db/postgresql:@SLOT@' uses these values to
# determine where to create the data directory, where to place the
# configuration files, and any additional options to pass to initdb.
#
# The initscript also uses these variables to inform PostgreSQL where to find
# its data directory and configuration files.
#
##############################################################################
# Location of configuration files
PGDATA="/etc/postgresql-@SLOT@/"
# Where the data directory is located/to be created
DATA_DIR="/var/lib/postgresql/@SLOT@/data"
# Additional options to pass to initdb.
# See `man initdb' for available options.
PG_INITDB_OPTS="--encoding=UTF8"

@ -0,0 +1,153 @@
#!/sbin/openrc-run
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
extra_started_commands="reload promote"
PG_CTL="/usr/@LIBDIR@/postgresql-@SLOT@/bin/pg_ctl"
description="PostgreSQL @SLOT@ -- the world's most advanced open source database --
${RC_SERVICE} is a wrapper around pg_ctl with additional administrative checks
and convenience"
get_config() {
[ -f "${PGDATA%/}/postgresql.conf" ] || return 1
eval echo $(sed -e 's:#.*::' "${PGDATA%/}/postgresql.conf" \
| awk '$1 == "'$1'" { print ($2 == "=" ? $3 : $2) }')
}
depend() {
use net
provide postgresql
if [ "$(get_config log_destination)" = "syslog" ]; then
use logger
fi
}
configured_port=$(get_config port)
: ${configured_port:=${PGPORT}}
checkconfig() {
# Check that DATA_DIR has been set
if [ -z "${DATA_DIR}" ] ; then
eerror "DATA_DIR not set"
eerror "HINT: Perhaps you need to update /etc/conf.d/postgresql-@SLOT@"
return 1
fi
# Check that DATA_DIR exists
if [ ! -d "${DATA_DIR}" ] ; then
eerror "Directory not found: ${DATA_DIR}"
eerror "HINT: Ensure that DATA_DIR points to the right path."
eerror "HINT: Or perhaps you need to create the database cluster:"
eerror " emerge --config dev-db/postgresql:@SLOT@"
return 1
fi
# Check for the existence of PostgreSQL's config files, and set the
# proper mode and ownership.
# Only three files should be checked as potentially other files
# may be in PGDATA that should not be touched.
local file
for file in postgresql pg_hba pg_ident ; do
file="${PGDATA%/}/${file}.conf"
if [ -f "${file}" ] ; then
checkpath -f -m 0600 -o postgres:postgres "${file}"
else
eerror "${file} not found"
eerror "HINT: mv ${DATA_DIR%/}/*.conf ${PGDATA}"
return 1
fi
done
# Set the proper permission for the socket path and create it if
# it doesn't exist.
checkpath -d -m 1775 -o root:postgres "${PG_SOCKET_DIRECTORY}"
if [ -e "${PG_SOCKET_DIRECTORY%/}/.s.PGSQL.${configured_port}" ] ; then
eerror "Socket conflict."
eerror "A server is already listening on:"
eerror " ${PG_SOCKET_DIRECTORY%/}/.s.PGSQL.${configured_port}"
eerror "HINT: Change PGPORT to listen on a different socket."
return 1
fi
}
start() {
checkconfig || return 1
ebegin "Starting PostgreSQL @SLOT@"
rm -f "${DATA_DIR%/}/postmaster.pid"
su - postgres -c \
"PGPORT=${configured_port} ${PG_EXTRA_ENV} ${PG_CTL} start \
-s -w -t ${START_TIMEOUT} -l ${DATA_DIR%/}/postmaster.log \
-D ${PGDATA} \
-o '--data-directory=${DATA_DIR} \
--unix-socket-directory=${PG_SOCKET_DIRECTORY} \
${PGOPTS}'"
local retval=$?
if [ $retval -ne 0 ] ; then
eerror "Check the log for a possible explanation of the above error."
eerror "The log may be located at:"
eerror " ${DATA_DIR%/}/postmaster.log"
eerror "Or wherever you configured PostgreSQL @SLOT@ to log."
fi
eend $retval
}
stop() {
local seconds=$(( ${NICE_TIMEOUT} + ${RUDE_TIMEOUT} + ${FORCE_TIMEOUT} ))
ebegin "Stopping PostgreSQL @SLOT@ (this can take up to ${seconds} seconds)"
su - postgres -c \
"${PG_CTL} stop -t ${NICE_TIMEOUT} -s -D ${DATA_DIR} -m smart"
local retval=$?
if [ "${RUDE_QUIT}" != "NO" -a ${retval} -ne 0 ] ; then
einfo "Previous attempt failed. Trying RUDE_QUIT."
su - postgres -c \
"${PG_CTL} stop -t ${RUDE_TIMEOUT} -s -D ${DATA_DIR} -m fast"
retval=$?
fi
if [ "${FORCE_QUIT}" = "YES" -a ${retval} -ne 0 ] ; then
einfo "Previous step failed. Trying FORCE_QUIT."
ewarn "A recover-run might be executed on next startup."
su - postgres -c \
"${PG_CTL} stop -t ${FORCE_TIMEOUT} -s -D ${DATA_DIR} -m immediate"
retval=$?
fi
eend ${retval}
}
status() {
ebegin "Checking PostgreSQL @SLOT@ status"
su - postgres -c "${PG_CTL} status -D ${DATA_DIR}"
eend $?
}
description_reload="Simply sends the postgres process a SIGHUP signal, causing
it to reread its configuration files (postgresql.conf, pg_hba.conf,
etc.). This allows changing of configuration-file options that do not
require a complete restart to take effect."
reload() {
ebegin "Reloading PostgreSQL @SLOT@ configuration"
su - postgres -c "${PG_CTL} reload -s -D ${DATA_DIR}"
eend $?
}
description_promote="If the server is in standby, it is commanded to exit
recovery and begin read-write operations."
promote() {
ebegin "Promoting PostgreSQL @SLOT@"
su - postgres -c "${PG_CTL} promote -s -D ${DATA_DIR}"
eend $?
}

@ -0,0 +1,158 @@
#!/sbin/openrc-run
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
extra_started_commands="reload promote"
PG_CTL="/usr/@LIBDIR@/postgresql-@SLOT@/bin/pg_ctl"
description="PostgreSQL @SLOT@ -- the world's most advanced open source database --
${RC_SERVICE} is a wrapper around pg_ctl with additional administrative checks
and convenience"
get_config() {
[ -f "${PGDATA%/}/postgresql.conf" ] || return 1
eval echo $(sed -e 's:#.*::' "${PGDATA%/}/postgresql.conf" \
| awk '$1 == "'$1'" { print ($2 == "=" ? $3 : $2) }')
}
depend() {
use net
provide postgresql
if [ "$(get_config log_destination)" = "syslog" ]; then
use logger
fi
}
configured_port=$(get_config port)
: ${configured_port:=${PGPORT}}
checkconfig() {
# Check that DATA_DIR has been set
if [ -z "${DATA_DIR}" ] ; then
eerror "DATA_DIR not set"
eerror "HINT: Perhaps you need to update /etc/conf.d/postgresql-@SLOT@"
return 1
fi
# Check that DATA_DIR exists
if [ ! -d "${DATA_DIR}" ] ; then
eerror "Directory not found: ${DATA_DIR}"
eerror "HINT: Ensure that DATA_DIR points to the right path."
eerror "HINT: Or perhaps you need to create the database cluster:"
eerror " emerge --config dev-db/postgresql:@SLOT@"
return 1
fi
# Check for the existence of PostgreSQL's config files, and set the
# proper mode and ownership.
# Only three files should be checked as potentially other files
# may be in PGDATA that should not be touched.
local file
for file in postgresql pg_hba pg_ident ; do
file="${PGDATA%/}/${file}.conf"
if [ -f "${file}" ] ; then
checkpath -f -m 0600 -o postgres:postgres "${file}"
else
eerror "${file} not found"
eerror "HINT: mv ${DATA_DIR%/}/*.conf ${PGDATA}"
return 1
fi
done
# Set the proper permission for the socket paths and create it if
# it doesn't exist.
set -f; IFS=','
local s
for s in ${PG_SOCKET_DIRECTORIES}; do
checkpath -d -m 1775 -o root:postgres "${s}"
if [ -e "${s%/}/.s.PGSQL.${configured_port}" ] ; then
eerror "Socket conflict."
eerror "A server is already listening on:"
eerror " ${s%/}/.s.PGSQL.${configured_port}"
eerror "HINT: Change PGPORT to listen on a different socket."
return 1
fi
done
set +f; unset IFS
}
start() {
checkconfig || return 1
ebegin "Starting PostgreSQL @SLOT@"
rm -f "${DATA_DIR%/}/postmaster.pid"
su - postgres -c \
"PGPORT=${configured_port} ${PG_EXTRA_ENV} ${PG_CTL} start \
-s -w -t ${START_TIMEOUT} -l ${DATA_DIR%/}/postmaster.log \
-D ${PGDATA} \
-o '--data-directory=${DATA_DIR} \
--unix-socket-directories=${PG_SOCKET_DIRECTORIES} \
${PGOPTS}'"
local retval=$?
if [ $retval -ne 0 ] ; then
eerror "Check the log for a possible explanation of the above error."
eerror "The log may be located at:"
eerror " ${DATA_DIR%/}/postmaster.log"
eerror "Or wherever you configured PostgreSQL @SLOT@ to log."
fi
eend $retval
}
stop() {
local seconds=$(( ${NICE_TIMEOUT} + ${RUDE_TIMEOUT} + ${FORCE_TIMEOUT} ))
ebegin "Stopping PostgreSQL @SLOT@ (this can take up to ${seconds} seconds)"
su - postgres -c \
"${PG_CTL} stop -t ${NICE_TIMEOUT} -s -D ${DATA_DIR} -m smart"
local retval=$?
if [ "${RUDE_QUIT}" != "NO" -a ${retval} -ne 0 ] ; then
einfo "Previous attempt failed. Trying RUDE_QUIT."
su - postgres -c \
"${PG_CTL} stop -t ${RUDE_TIMEOUT} -s -D ${DATA_DIR} -m fast"
retval=$?
fi
if [ "${FORCE_QUIT}" = "YES" -a ${retval} -ne 0 ] ; then
einfo "Previous step failed. Trying FORCE_QUIT."
ewarn "A recover-run might be executed on next startup."
su - postgres -c \
"${PG_CTL} stop -t ${FORCE_TIMEOUT} -s -D ${DATA_DIR} -m immediate"
retval=$?
fi
eend ${retval}
}
status() {
ebegin "Checking PostgreSQL @SLOT@ status"
su - postgres -c "${PG_CTL} status -D ${DATA_DIR}"
eend $?
}
description_reload="Simply sends the postgres process a SIGHUP signal, causing
it to reread its configuration files (postgresql.conf, pg_hba.conf,
etc.). This allows changing of configuration-file options that do not
require a complete restart to take effect."
reload() {
ebegin "Reloading PostgreSQL @SLOT@ configuration"
su - postgres -c "${PG_CTL} reload -s -D ${DATA_DIR}"
eend $?
}
description_promote="If the server is in standby, it is commanded to exit
recovery and begin read-write operations."
promote() {
ebegin "Promoting PostgreSQL @SLOT@"
su - postgres -c "${PG_CTL} promote -s -D ${DATA_DIR}"
eend $?
}

@ -0,0 +1,434 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
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-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
use static-libs || find "${ED}" -name '*.a' -delete
local f bn
for f in $(find "${ED}/usr/$(get_libdir)/postgresql-${SLOT}/bin" \
-mindepth 1 -maxdepth 1)
do
bn=$(basename "${f}")
# Temporarily tack on tmp to workaround a file collision
# issue. This is only necessary for 9.7 and earlier. 10 never
# had this issue.
dosym "../$(get_libdir)/postgresql-${SLOT}/bin/${bn}" \
"/usr/bin/${bn}${SLOT/.}tmp"
done
local linkname mansec
for mansec in {1,3,7} ; do
for f in "${ED}"/usr/share/postgresql-${SLOT}/man/man${mansec}/* ; do
bn=$(basename "${f}")
linkname=${bn/%.${mansec}/${SLOT/.}.${mansec}}
dosym ../../postgresql-${SLOT}/man/man${mansec}/$bn \
/usr/share/man/man${mansec}/${linkname}
done
done
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-9.2" | newconfd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.init-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
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_preinst() {
# Find all of the slot-specific symlinks, if any, in /usr/bin (e.g.,
# /usr/bin/psql96). They may have been created by the
# postgresql.eselect module, but they're handled within this ebuild
# now. It's alright if we momentarily delete /usr/bin/psql as it
# will be recreated by the eselect module in pkg_ppostinst(). This
# is only necessary for 9.7 and earlier. 10 and later were never
# handled in this manner.
local canonicalise
if type -p realpath > /dev/null; then
canonicalise=realpath
elif type -p readlink > /dev/null; then
canonicalise='readlink -f'
else
# can't die, subshell
die "No readlink nor realpath found, cannot canonicalise"
fi
local l
# First remove any symlinks in /usr/bin that may have been created
# by the old eselect
for l in $(find "${ROOT%/}/usr/bin" -mindepth 1 -maxdepth 1 -type l) ; do
if [[ $(${canonicalise} "${l}") == *postgresql-${SLOT}* ]] ; then
rm "${l}" || ewarn "Couldn't remove ${l}"
fi
done
# Then move the symlinks created by the ebuild to their proper place.
for l in "${ED}"/usr/bin/*tmp ; do
mv "${l}" "${l%tmp}" \
|| ewarn "Couldn't rename $(basename ${l}) to $(basename ${l%tmp})"
done
}
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
ebegin "Continuing initialization in 5 seconds (Control-C to cancel)"
sleep 5
eend 0
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
# unix_socket_directory has no effect in postgresql.conf as it's
# overridden in the initscript
sed '/^#unix_socket_directory/d' -i "${PGDATA%/}"/postgresql.conf
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() {
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,439 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
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-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
# Rely on $PATH being in the proper order so that the correct
# install program is used for modules utilizing PGXS in both
# hardened and non-hardened environments. (Bug #528786)
sed 's/@install_bin@/install -c/' -i src/Makefile.global.in || 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
use static-libs || find "${ED}" -name '*.a' -delete
local f bn
for f in $(find "${ED}/usr/$(get_libdir)/postgresql-${SLOT}/bin" \
-mindepth 1 -maxdepth 1)
do
bn=$(basename "${f}")
# Temporarily tack on tmp to workaround a file collision
# issue. This is only necessary for 9.7 and earlier. 10 never
# had this issue.
dosym "../$(get_libdir)/postgresql-${SLOT}/bin/${bn}" \
"/usr/bin/${bn}${SLOT/.}tmp"
done
local linkname mansec
for mansec in {1,3,7} ; do
for f in "${ED}"/usr/share/postgresql-${SLOT}/man/man${mansec}/* ; do
bn=$(basename "${f}")
linkname=${bn/%.${mansec}/${SLOT/.}.${mansec}}
dosym ../../postgresql-${SLOT}/man/man${mansec}/$bn \
/usr/share/man/man${mansec}/${linkname}
done
done
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-9.3" | newconfd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.init-9.3-r1" | newinitd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.service" | \
systemd_newunit - ${PN}-${SLOT}.service
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_preinst() {
# Find all of the slot-specific symlinks, if any, in /usr/bin (e.g.,
# /usr/bin/psql96). They may have been created by the
# postgresql.eselect module, but they're handled within this ebuild
# now. It's alright if we momentarily delete /usr/bin/psql as it
# will be recreated by the eselect module in pkg_ppostinst(). This
# is only necessary for 9.7 and earlier. 10 and later were never
# handled in this manner.
local canonicalise
if type -p realpath > /dev/null; then
canonicalise=realpath
elif type -p readlink > /dev/null; then
canonicalise='readlink -f'
else
# can't die, subshell
die "No readlink nor realpath found, cannot canonicalise"
fi
local l
# First remove any symlinks in /usr/bin that may have been created
# by the old eselect
for l in $(find "${ROOT%/}/usr/bin" -mindepth 1 -maxdepth 1 -type l) ; do
if [[ $(${canonicalise} "${l}") == *postgresql-${SLOT}* ]] ; then
rm "${l}" || ewarn "Couldn't remove ${l}"
fi
done
# Then move the symlinks created by the ebuild to their proper place.
for l in "${ED}"/usr/bin/*tmp ; do
mv "${l}" "${l%tmp}" \
|| ewarn "Couldn't rename $(basename ${l}) to $(basename ${l%tmp})"
done
}
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
ebegin "Continuing initialization in 5 seconds (Control-C to cancel)"
sleep 5
eend 0
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
# unix_socket_directory has no effect in postgresql.conf as it's
# overridden in the initscript
sed '/^#unix_socket_directories/,+1d' -i "${PGDATA%/}"/postgresql.conf
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() {
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,471 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
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-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
# Rely on $PATH being in the proper order so that the correct
# install program is used for modules utilizing PGXS in both
# hardened and non-hardened environments. (Bug #528786)
sed 's/@install_bin@/install -c/' -i src/Makefile.global.in || die
use server || epatch "${FILESDIR}/${PN}-9.4.10-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
use static-libs || find "${ED}" -name '*.a' -delete
local f bn
for f in $(find "${ED}/usr/$(get_libdir)/postgresql-${SLOT}/bin" \
-mindepth 1 -maxdepth 1)
do
bn=$(basename "${f}")
# Temporarily tack on tmp to workaround a file collision
# issue. This is only necessary for 9.7 and earlier. 10 never
# had this issue.
dosym "../$(get_libdir)/postgresql-${SLOT}/bin/${bn}" \
"/usr/bin/${bn}${SLOT/.}tmp"
done
local linkname mansec
for mansec in {1,3,7} ; do
for f in "${ED}"/usr/share/postgresql-${SLOT}/man/man${mansec}/* ; do
bn=$(basename "${f}")
linkname=${bn/%.${mansec}/${SLOT/.}.${mansec}}
dosym ../../postgresql-${SLOT}/man/man${mansec}/$bn \
/usr/share/man/man${mansec}/${linkname}
done
done
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-9.3" | newconfd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.init-9.3-r1" | newinitd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.service" | \
systemd_newunit - ${PN}-${SLOT}.service
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_preinst() {
# Find all of the slot-specific symlinks, if any, in /usr/bin (e.g.,
# /usr/bin/psql96). They may have been created by the
# postgresql.eselect module, but they're handled within this ebuild
# now. It's alright if we momentarily delete /usr/bin/psql as it
# will be recreated by the eselect module in pkg_ppostinst(). This
# is only necessary for 9.7 and earlier. 10 and later were never
# handled in this manner.
local canonicalise
if type -p realpath > /dev/null; then
canonicalise=realpath
elif type -p readlink > /dev/null; then
canonicalise='readlink -f'
else
# can't die, subshell
die "No readlink nor realpath found, cannot canonicalise"
fi
local l
# First remove any symlinks in /usr/bin that may have been created
# by the old eselect
for l in $(find "${ROOT%/}/usr/bin" -mindepth 1 -maxdepth 1 -type l) ; do
if [[ $(${canonicalise} "${l}") == *postgresql-${SLOT}* ]] ; then
rm "${l}" || ewarn "Couldn't remove ${l}"
fi
done
# Then move the symlinks created by the ebuild to their proper place.
for l in "${ED}"/usr/bin/*tmp ; do
mv "${l}" "${l%tmp}" \
|| ewarn "Couldn't rename $(basename ${l}) to $(basename ${l%tmp})"
done
}
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
ebegin "Continuing initialization in 5 seconds (Control-C to cancel)"
sleep 5
eend 0
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
# unix_socket_directory has no effect in postgresql.conf as it's
# overridden in the initscript
sed '/^#unix_socket_directories/,+1d' -i "${PGDATA%/}"/postgresql.conf
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() {
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,477 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="5"
PYTHON_COMPAT=( python2_7 python3_{4,5,6} )
inherit eutils flag-o-matic linux-info multilib pam prefix python-single-r1 \
systemd user versionator
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~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-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
# Rely on $PATH being in the proper order so that the correct
# install program is used for modules utilizing PGXS in both
# hardened and non-hardened environments. (Bug #528786)
sed 's/@install_bin@/install -c/' -i src/Makefile.global.in || die
use server || epatch "${FILESDIR}/${PN}-9.5.5-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 !alpha spinlocks) \
$(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
use static-libs || find "${ED}" -name '*.a' -delete
local f bn
for f in $(find "${ED}/usr/$(get_libdir)/postgresql-${SLOT}/bin" \
-mindepth 1 -maxdepth 1)
do
bn=$(basename "${f}")
# Temporarily tack on tmp to workaround a file collision
# issue. This is only necessary for 9.7 and earlier. 10 never
# had this issue.
dosym "../$(get_libdir)/postgresql-${SLOT}/bin/${bn}" \
"/usr/bin/${bn}${SLOT/.}tmp"
done
local linkname mansec
for mansec in {1,3,7} ; do
for f in "${ED}"/usr/share/postgresql-${SLOT}/man/man${mansec}/* ; do
bn=$(basename "${f}")
linkname=${bn/%.${mansec}/${SLOT/.}.${mansec}}
dosym ../../postgresql-${SLOT}/man/man${mansec}/$bn \
/usr/share/man/man${mansec}/${linkname}
done
done
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-9.3" | newconfd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.init-9.3-r1" | newinitd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.service" | \
systemd_newunit - ${PN}-${SLOT}.service
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_preinst() {
# Find all of the slot-specific symlinks, if any, in /usr/bin (e.g.,
# /usr/bin/psql96). They may have been created by the
# postgresql.eselect module, but they're handled within this ebuild
# now. It's alright if we momentarily delete /usr/bin/psql as it
# will be recreated by the eselect module in pkg_ppostinst(). This
# is only necessary for 9.7 and earlier. 10 and later were never
# handled in this manner.
local canonicalise
if type -p realpath > /dev/null; then
canonicalise=realpath
elif type -p readlink > /dev/null; then
canonicalise='readlink -f'
else
# can't die, subshell
die "No readlink nor realpath found, cannot canonicalise"
fi
local l
# First remove any symlinks in /usr/bin that may have been created
# by the old eselect
for l in $(find "${ROOT%/}/usr/bin" -mindepth 1 -maxdepth 1 -type l) ; do
if [[ $(${canonicalise} "${l}") == *postgresql-${SLOT}* ]] ; then
rm "${l}" || ewarn "Couldn't remove ${l}"
fi
done
# Then move the symlinks created by the ebuild to their proper place.
for l in "${ED}"/usr/bin/*tmp ; do
mv "${l}" "${l%tmp}" \
|| ewarn "Couldn't rename $(basename ${l}) to $(basename ${l%tmp})"
done
}
pkg_postinst() {
postgresql-config update
if use alpha && use server ; then
ewarn "PostgreSQL 9.5+ no longer has native spinlock support on Alpha platforms."
ewarn "As a result, performance will be extremely degraded."
fi
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
ebegin "Continuing initialization in 5 seconds (Control-C to cancel)"
sleep 5
eend 0
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
# unix_socket_directory has no effect in postgresql.conf as it's
# overridden in the initscript
sed '/^#unix_socket_directories/,+1d' -i "${PGDATA%/}"/postgresql.conf
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() {
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,474 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="5"
PYTHON_COMPAT=( python2_7 python3_{4,5,6} )
inherit eutils flag-o-matic linux-info multilib pam prefix python-single-r1 \
systemd user versionator
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~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-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
# Rely on $PATH being in the proper order so that the correct
# install program is used for modules utilizing PGXS in both
# hardened and non-hardened environments. (Bug #528786)
sed 's/@install_bin@/install -c/' -i src/Makefile.global.in || die
use server || epatch "${FILESDIR}/${PN}-${SLOT}.1-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
use static-libs || find "${ED}" -name '*.a' -delete
local f bn
for f in $(find "${ED}/usr/$(get_libdir)/postgresql-${SLOT}/bin" \
-mindepth 1 -maxdepth 1)
do
bn=$(basename "${f}")
# Temporarily tack on tmp to workaround a file collision
# issue. This is only necessary for 9.7 and earlier. 10 never
# had this issue.
dosym "../$(get_libdir)/postgresql-${SLOT}/bin/${bn}" \
"/usr/bin/${bn}${SLOT/.}tmp"
done
local linkname mansec
for mansec in {1,3,7} ; do
for f in "${ED}"/usr/share/postgresql-${SLOT}/man/man${mansec}/* ; do
bn=$(basename "${f}")
linkname=${bn/%.${mansec}/${SLOT/.}.${mansec}}
dosym ../../postgresql-${SLOT}/man/man${mansec}/$bn \
/usr/share/man/man${mansec}/${linkname}
done
done
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-9.3" | newconfd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.init-9.3-r1" | newinitd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.service" | \
systemd_newunit - ${PN}-${SLOT}.service
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_preinst() {
# Find all of the slot-specific symlinks, if any, in /usr/bin (e.g.,
# /usr/bin/psql96). They may have been created by the
# postgresql.eselect module, but they're handled within this ebuild
# now. It's alright if we momentarily delete /usr/bin/psql as it
# will be recreated by the eselect module in pkg_ppostinst(). This
# is only necessary for 9.7 and earlier. 10 and later were never
# handled in this manner.
local canonicalise
if type -p realpath > /dev/null; then
canonicalise=realpath
elif type -p readlink > /dev/null; then
canonicalise='readlink -f'
else
# can't die, subshell
die "No readlink nor realpath found, cannot canonicalise"
fi
local l
# First remove any symlinks in /usr/bin that may have been created
# by the old eselect
for l in $(find "${ROOT%/}/usr/bin" -mindepth 1 -maxdepth 1 -type l) ; do
if [[ $(${canonicalise} "${l}") == *postgresql-${SLOT}* ]] ; then
rm "${l}" || ewarn "Couldn't remove ${l}"
fi
done
# Then move the symlinks created by the ebuild to their proper place.
for l in "${ED}"/usr/bin/*tmp ; do
mv "${l}" "${l%tmp}" \
|| ewarn "Couldn't rename $(basename ${l}) to $(basename ${l%tmp})"
done
}
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
ebegin "Continuing initialization in 5 seconds (Control-C to cancel)"
sleep 5
eend 0
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
# unix_socket_directory has no effect in postgresql.conf as it's
# overridden in the initscript
sed '/^#unix_socket_directories/,+1d' -i "${PGDATA%/}"/postgresql.conf
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() {
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
}

@ -10,8 +10,8 @@ inherit eutils flag-o-matic git-2 linux-info multilib pam prefix \
KEYWORDS=""
# Fix if needed
SLOT="9.7"
# Bump when rc released.
SLOT="10"
EGIT_REPO_URI="git://git.postgresql.org/git/postgresql.git"
@ -39,7 +39,7 @@ wanted_languages() {
}
CDEPEND="
>=app-eselect/eselect-postgresql-1.2.0
>=app-eselect/eselect-postgresql-2.0
sys-apps/less
virtual/libintl
kerberos? ( virtual/krb5 )
@ -174,17 +174,13 @@ src_install() {
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
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.confd" | newconfd - ${PN}-${SLOT}
"${FILESDIR}/${PN}.confd-9.3" | newconfd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.init" | newinitd - ${PN}-${SLOT}
"${FILESDIR}/${PN}.init-9.3-r1" | newinitd - ${PN}-${SLOT}
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.service" | \
@ -194,26 +190,74 @@ src_install() {
use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session
local f bn
for f in $(find "${ED}/usr/$(get_libdir)/postgresql-${SLOT}/bin" \
-mindepth 1 -maxdepth 1)
do
bn=$(basename "${f}")
# Temporarily tack on tmp to workaround a file collision
# issue. This is only necessary for 9.7 and earlier. 10 never
# had this issue.
dosym "../$(get_libdir)/postgresql-${SLOT}/bin/${bn}" \
"/usr/bin/${bn}${SLOT/.}tmp"
done
local linkname mansec
for mansec in {1,3,7} ; do
for f in "${ED}"/usr/share/postgresql-${SLOT}/man/man${mansec}/* ; do
bn=$(basename "${f}")
linkname=${bn/%.${mansec}/${SLOT/.}.${mansec}}
dosym ../../postgresql-${SLOT}/man/man${mansec}/$bn \
/usr/share/man/man${mansec}/${linkname}
done
done
if use prefix ; then
keepdir /run/postgresql
fperms 0775 /run/postgresql
fi
}
pkg_preinst() {
# Find all of the slot-specific symlinks, if any, in /usr/bin (e.g.,
# /usr/bin/psql97). They may have been created by the
# postgresql.eselect module, but they're handled within this ebuild
# now. It's alright if we momentarily delete /usr/bin/psql as it
# will be recreated by the eselect module in pkg_ppostinst(). We
# only worry about the 9.7 slot as that's the last slot that had its
# slot-specific links generated by eselect.
#
# This can be removed when 10 is the lowest slot in the tree.
local canonicalise
if type -p realpath > /dev/null; then
canonicalise=realpath
elif type -p readlink > /dev/null; then
canonicalise='readlink -f'
else
# can't die, subshell
die "No readlink nor realpath found, cannot canonicalise"
fi
local l
# First remove any symlinks in /usr/bin that may have been created
# by the old eselect
for l in $(find "${ROOT%/}/usr/bin" -mindepth 1 -maxdepth 1 -type l) ; do
[[ $(${canonicalise} "${l}") == *postgresql-9.7* ]] && rm "${l}"
done
# Then move the symlinks created by the ebuild to their proper place.
for l in "${ED}"/usr/bin/*tmp ; do
mv "${l}" "${l%tmp}" \
|| ewarn "Couldn't rename $(basename ${l}) to $(basename ${l%tmp})"
done
}
pkg_postinst() {
postgresql-config update
elog "If you need a global psqlrc-file, you can place it in:"
elog " ${EROOT%/}/etc/postgresql-${SLOT}/"
if [[ -z ${REPLACING_VERSIONS} ]] ; then
elog
elog "It looks like this is your first time installing PostgreSQL. Run the"
elog "following command in all active shells to pick up changes to the default"
elog "environment:"
elog " source /etc/profile"
fi
elog
elog "Gentoo specific documentation:"
elog "https://wiki.gentoo.org/wiki/PostgreSQL"
@ -297,21 +341,10 @@ pkg_config() {
einfo "The database cluster will be created in:"
einfo " ${DATA_DIR}"
einfo
if [ -z "$PG_AUTOCONFIG" ] ; then
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
else
einfo "PG_AUTOCONFIG set, not prompting"
fi
ebegin "Continuing initialization in 5 seconds (Control-C to cancel)"
sleep 5
eend 0
if [ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ] ; then
eerror "The given directory, '${DATA_DIR}', is not empty."
@ -339,6 +372,10 @@ pkg_config() {
ln -s "${PGDATA%/}"/{pg_{hba,ident},postgresql}.conf "${DATA_DIR%/}"
fi
# unix_socket_directory has no effect in postgresql.conf as it's
# overridden in the initscript
sed '/^#unix_socket_directories/,+1d' -i "${PGDATA%/}"/postgresql.conf
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

@ -20,6 +20,6 @@ DIST go-linux-s390x-bootstrap-1.8.tbz 57124869 SHA256 70bb859e80268b3421587d8518
DIST go-linux-s390x-bootstrap.tbz 49809007 SHA256 80a87bc5ac2239c99f8d7425fbc6f4fefba63f549b0835505c25378c08114656 SHA512 1b7500e6c42508b6cb07214620070065262349d2cd3698deeac0638d0bf0bfeb89c59c2d72a284af34f3071b4cfb9ce543c5fdec7add4a46adc9580295909439 WHIRLPOOL d3782cb515ab67720105224e02d96ab1ca86518db661719b2d0f7c48aa1f4f896a7cc5fed5b6ddc032c8206e8a10c6262646be0e59def61723936044d6ceb143
DIST go-solaris-amd64-bootstrap-1.8.tbz 54926326 SHA256 83053f333d56d72ddbe9a8f293f8afeff31739806d49ebaa144811a5438b17bc SHA512 52b849e5b9a940e10de7ba3df0ebdf6e1c5d631de9581d936c9edf8f38e6bb3314acbc2b2d5202b0528fde2a359d52bc0c6f39acf9b1b614725e4b4a947ed10d WHIRLPOOL 2d58085d88fa612a7dfb087df33d2c5ee6b6d4c0b0c0363d5dcef014a6e3e9703816e8a111d1348e1e1a4ebcdde58694a869a27ae42e0deec154529f1a794991
DIST go-solaris-amd64-bootstrap.tbz 48367195 SHA256 92ebdbf001f243a78a6c2d8ee30e929ba2cecbedf8e0fc07e129b04b107453ad SHA512 cf8725db0d001d61badee71624799a3c9e75f61f77ab090c1f6c490d694c4be367019b28d88306045d877ab5a324a1f9b0674293caf3acb19c193fc3746a48f2 WHIRLPOOL 672c6642e340b6d4f38b633f67fdc3202e3725022a8a61e2129276fccd6c42ddc24ed06c1d57eb31a25ea8056b79686619cbb36431b9c23b6d4be5bcb715bd89
DIST go1.7.4.src.tar.gz 14198817 SHA256 4c189111e9ba651a2bb3ee868aa881fab36b2f2da3409e80885ca758a6b614cc SHA512 dc9950c3ea7100e536ad58fd93505d584276b7c50d4b8fe2ba7f20fd043dcf0d315b735c48945302055e91517594cc2b0061ccec9478a8ab48f1f2836c20afb3 WHIRLPOOL 054f496555dd30e0ba6a3c449b915ea048d5f85f1cf6d2ef6e8aa84939b6e9674b30cfccee99d050c5d75d028cf43d83bf0267703ffb02dfc5bc780fd0a1706f
DIST go1.7.5.src.tar.gz 14204325 SHA256 4e834513a2079f8cbbd357502cccaac9507fd00a1efe672375798858ff291815 SHA512 2dda0780a8b24d71fec4ddeb6858c58a42845f51d9afc171d924a7b763101878cc7f29ae1dd35f129b4ee45b84d45211093a1d20639745fed36b49fb7fe1ba07 WHIRLPOOL b28ab10558d9f8fba87d5db2c839a84eab0b61244d75f4b3d42b443365ca8a1ae1c60c2e1073ef2b4a854d957c26111fcc286b7caae4be892e6cba0e4b24e21d
DIST go1.8.1.src.tar.gz 15331455 SHA256 33daf4c03f86120fdfdc66bddf6bfff4661c7ca11c5da473e537f4d69b470e57 SHA512 f01fe7b35ac23101610f6fc169b88dafe2edc49b3b044d5d0aff771b05dcb2c8d2e7a5090ed6dbe67f861e78e792ace32e209ed464399ca02dcd186b13ec8037 WHIRLPOOL c358ca23740183afac4ecf83a6b7daeeef3e6481f29cb5f98b911cb1d661921db2e16ac2528f0ec59633920f1484e7fa777275e46313e20cc8b32baed9054d24
DIST go1.8.src.tar.gz 15320083 SHA256 406865f587b44be7092f206d73fc1de252600b79b3cacc587b74b5ef5c623596 SHA512 9742dd8ec0364793e44a55207238c7339236a4da3a6e7cbb3b4eca45e957c7c0cb725e7d7430b9a04630285468d32dac686facfc57f3f58885b80bbb3d333ada WHIRLPOOL 62d7b1729d3a192142b7b1af20c797736ae631bb87e7c82487601e669d69547212669c216e66d0d64ad83884d348ed3dacf2f9fd9d923f85c673adadd0ff4aae

@ -1,221 +0,0 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
export CBUILD=${CBUILD:-${CHOST}}
export CTARGET=${CTARGET:-${CHOST}}
MY_PV=${PV/_/}
inherit toolchain-funcs
BOOTSTRAP_DIST="https://dev.gentoo.org/~williamh/dist"
SRC_URI="!gccgo? (
kernel_Darwin? (
x64-macos? ( ${BOOTSTRAP_DIST}/go-darwin-amd64-bootstrap.tbz )
)
kernel_FreeBSD? (
amd64-fbsd? ( ${BOOTSTRAP_DIST}/go-freebsd-amd64-bootstrap.tbz )
x86-fbsd? ( ${BOOTSTRAP_DIST}/go-freebsd-386-bootstrap-1.tbz )
)
kernel_linux? (
amd64? ( ${BOOTSTRAP_DIST}/go-linux-amd64-bootstrap.tbz )
arm? ( ${BOOTSTRAP_DIST}/go-linux-arm-bootstrap.tbz )
arm64? ( ${BOOTSTRAP_DIST}/go-linux-arm64-bootstrap.tbz )
ppc64? (
${BOOTSTRAP_DIST}/go-linux-ppc64-bootstrap.tbz
${BOOTSTRAP_DIST}/go-linux-ppc64le-bootstrap.tbz
)
s390? ( ${BOOTSTRAP_DIST}/go-linux-s390x-bootstrap.tbz )
x86? ( ${BOOTSTRAP_DIST}/go-linux-386-bootstrap-1.tbz )
)
kernel_SunOS? (
x64-solaris? ( ${BOOTSTRAP_DIST}/go-solaris-amd64-bootstrap.tbz )
)
)
"
if [[ ${PV} = 9999 ]]; then
EGIT_REPO_URI="git://github.com/golang/go.git"
inherit git-r3
else
SRC_URI+="https://storage.googleapis.com/golang/go${MY_PV}.src.tar.gz"
case ${PV} in
*9999*|*_rc*) ;;
*)
KEYWORDS="-* amd64 arm ~arm64 ~ppc64 x86 ~amd64-fbsd ~x86-fbsd ~x64-macos ~x64-solaris"
;;
esac
fi
DESCRIPTION="A concurrent garbage collected and typesafe programming language"
HOMEPAGE="http://www.golang.org"
LICENSE="BSD"
SLOT="0/${PV}"
IUSE="gccgo"
DEPEND="gccgo? ( >=sys-devel/gcc-5[go] )"
RDEPEND="!<dev-go/go-tools-0_pre20150902"
# These test data objects have writable/executable stacks.
QA_EXECSTACK="usr/lib/go/src/debug/elf/testdata/*.obj"
# Do not complain about CFLAGS, etc, since Go doesn't use them.
QA_FLAGS_IGNORED='.*'
REQUIRES_EXCLUDE="/usr/lib/go/src/debug/elf/testdata/*"
# The tools in /usr/lib/go should not cause the multilib-strict check to fail.
QA_MULTILIB_PATHS="usr/lib/go/pkg/tool/.*/.*"
# The go language uses *.a files which are _NOT_ libraries and should not be
# stripped. The test data objects should also be left alone and unstripped.
STRIP_MASK="/usr/lib/go/pkg/*.a
/usr/lib/go/src/debug/elf/testdata/*
/usr/lib/go/src/debug/dwarf/testdata/*
/usr/lib/go/src/runtime/race/*.syso"
if [[ ${PV} != 9999 ]]; then
S="${WORKDIR}"/go
fi
go_arch()
{
# By chance most portage arch names match Go
local portage_arch=$(tc-arch $@)
case "${portage_arch}" in
x86) echo 386;;
x64-*) echo amd64;;
ppc64) [[ $(tc-endian $@) = big ]] && echo ppc64 || echo ppc64le ;;
s390) echo s390x ;;
*) echo "${portage_arch}";;
esac
}
go_arm()
{
case "${1:-${CHOST}}" in
armv5*) echo 5;;
armv6*) echo 6;;
armv7*) echo 7;;
*)
die "unknown GOARM for ${1:-${CHOST}}"
;;
esac
}
go_os()
{
case "${1:-${CHOST}}" in
*-linux*) echo linux;;
*-darwin*) echo darwin;;
*-freebsd*) echo freebsd;;
*-netbsd*) echo netbsd;;
*-openbsd*) echo openbsd;;
*-solaris*) echo solaris;;
*-cygwin*|*-interix*|*-winnt*)
echo windows
;;
*)
die "unknown GOOS for ${1:-${CHOST}}"
;;
esac
}
go_tuple()
{
echo "$(go_os $@)_$(go_arch $@)"
}
go_cross_compile()
{
[[ $(go_tuple ${CBUILD}) != $(go_tuple) ]]
}
pkg_pretend()
{
# make.bash does not understand cross-compiling a cross-compiler
if [[ $(go_tuple) != $(go_tuple ${CTARGET}) ]]; then
die "CHOST CTARGET pair unsupported: CHOST=${CHOST} CTARGET=${CTARGET}"
fi
}
src_unpack()
{
if [[ ${PV} = 9999 ]]; then
git-r3_src_unpack
fi
default
}
src_compile()
{
export GOROOT_BOOTSTRAP="${WORKDIR}"/go-$(go_os)-$(go_arch)-bootstrap
if use gccgo; then
mkdir -p "${GOROOT_BOOTSTRAP}/bin" || die
local go_binary=$(gcc-config --get-bin-path)/go-5
[[ -x ${go_binary} ]] || go_binary=$(
find "${EPREFIX}"/usr/${CHOST}/gcc-bin/*/go-5 | sort -V | tail -n1)
[[ -x ${go_binary} ]] || die "go-5: command not found"
ln -s "${go_binary}" "${GOROOT_BOOTSTRAP}/bin/go" || die
fi
export GOROOT_FINAL="${EPREFIX}"/usr/lib/go
export GOROOT="$(pwd)"
export GOBIN="${GOROOT}/bin"
# Go's build script does not use BUILD/HOST/TARGET consistently. :(
export GOHOSTARCH=$(go_arch ${CBUILD})
export GOHOSTOS=$(go_os ${CBUILD})
export CC=$(tc-getBUILD_CC)
export GOARCH=$(go_arch)
export GOOS=$(go_os)
export CC_FOR_TARGET=$(tc-getCC)
export CXX_FOR_TARGET=$(tc-getCXX)
if [[ ${ARCH} == arm ]]; then
export GOARM=$(go_arm)
fi
elog "GOROOT_BOOTSTRAP is ${GOROOT_BOOTSTRAP}"
cd src
./make.bash || die "build failed"
}
src_test()
{
go_cross_compile && return 0
cd src
PATH="${GOBIN}:${PATH}" \
./run.bash -no-rebuild || die "tests failed"
}
src_install()
{
local bin_path f x
dodir /usr/lib/go
insinto /usr/lib/go
# There is a known issue which requires the source tree to be installed [1].
# Once this is fixed, we can consider using the doc use flag to control
# installing the doc and src directories.
# [1] https://golang.org/issue/2775
doins -r bin doc lib pkg src
fperms -R +x /usr/lib/go/bin /usr/lib/go/pkg/tool
cp -a misc "${D}"/usr/lib/go/misc
if go_cross_compile; then
bin_path="bin/$(go_tuple)"
else
bin_path=bin
fi
for x in ${bin_path}/*; do
f=${x##*/}
dosym ../lib/go/${bin_path}/${f} /usr/bin/${f}
done
dodoc AUTHORS CONTRIBUTORS PATENTS README.md
}

@ -12,6 +12,6 @@ SRC_URI="http://concurrencykit.org/releases/${MY_P}.tar.gz -> ${P}.tar.gz"
LICENSE="Apache-2.0 BSD-2"
SLOT="0"
KEYWORDS="amd64 ~x86"
KEYWORDS="amd64 x86"
S="${WORKDIR}/${MY_P}"

@ -0,0 +1,84 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
GNOME2_LA_PUNT="yes"
PYTHON_COMPAT=( python{3_4,3_5} )
inherit autotools eutils gnome2 multilib python-single-r1 virtualx
DESCRIPTION="A GObject plugins library"
HOMEPAGE="https://developer.gnome.org/libpeas/stable/"
LICENSE="LGPL-2+"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-fbsd ~amd64-linux ~x86-linux"
IUSE="+gtk glade jit lua +python"
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
RDEPEND="
>=dev-libs/glib-2.38:2
>=dev-libs/gobject-introspection-1.39:=
glade? ( >=dev-util/glade-3.9.1:3.10 )
gtk? ( >=x11-libs/gtk+-3:3[introspection] )
lua? (
>=dev-lua/lgi-0.9.0
jit? ( >=dev-lang/luajit-2:2 )
!jit? ( =dev-lang/lua-5.1*:0 ) )
python? (
${PYTHON_DEPS}
>=dev-python/pygobject-3.2:3[${PYTHON_USEDEP}] )
"
DEPEND="${RDEPEND}
>=dev-util/gtk-doc-am-1.11
>=dev-util/intltool-0.40
virtual/pkgconfig
dev-libs/gobject-introspection-common
gnome-base/gnome-common
"
# eautoreconf needs gobject-introspection-common, gnome-common
pkg_setup() {
use python && python-single-r1_pkg_setup
}
src_prepare() {
# Gentoo uses unversioned lua - lua.pc instad of lua5.1.pc, /usr/bin/lua instead of /usr/bin/lua5.1
eapply "${FILESDIR}"/${PN}-1.14.0-lua.pc.patch
eautoreconf
gnome2_src_prepare
}
src_configure() {
# Wtf, --disable-gcov, --enable-gcov=no, --enable-gcov, all enable gcov
# What do we do about gdb, valgrind, gcov, etc?
local myconf=(
$(use_enable glade glade-catalog)
$(use_enable gtk)
--disable-static
# py2 not supported anymore
--disable-python2
$(use_enable python python3)
# lua
$(use_enable lua lua5.1)
$(use_enable $(usex jit lua jit) luajit)
)
gnome2_src_configure "${myconf[@]}"
}
src_test() {
# This looks fixed since 1.18.0:
#
# FIXME: Tests fail because of some bug involving Xvfb and Gtk.IconTheme
# DO NOT REPORT UPSTREAM, this is not a libpeas bug.
# To reproduce:
# >>> from gi.repository import Gtk
# >>> Gtk.IconTheme.get_default().has_icon("gtk-about")
# This should return True, it returns False for Xvfb
virtx emake check
}

@ -1 +1,2 @@
DIST pegtl-1.3.1.tar.gz 67183 SHA256 34201d56284a449c72798a0536020c6b46684c371a0a886f4c3c586c9372e9bc SHA512 6655be7806112878e2da00916b348c28939bc96e2a317eb00089be341fd5306ce5a1388ca5dbba21bcd7be2d6c24e3964b6a730031a16a7dd8ef6ec6acd6899e WHIRLPOOL b5582ac29ad6c1b24ee8f9c4c525c8c944fbe9e8d38a45353ae01574c479a2f70a0ac75271e58cc6332780594224524fc5dca7f36fa170f2b5b283bcb3728280
DIST pegtl-2.0_pre1.tar.gz 146966 SHA256 25708e0553ce8c95b5cd8dd7f3fbe53859dfaacf83fb174e6d247d72d30f232e SHA512 180bd8b44ccfe406c818af6b3f5f22eb4cfc7bea6043af5141c6c5ed9b2770624326e67d6dfc47a22aaee3697e5cf1d2744d0a3d3d01a4ce47457189f2b19839 WHIRLPOOL eed51d7c090cfab6b90566a30f20ee36873987b9dc41a1a3c5976106ff1e989078dfd9e6d9abe7511e6c8a94c88d5c75a63af2cf68fc2981ed3b5467c14b9d99

@ -0,0 +1,19 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit cmake-utils vcs-snapshot
COMMIT="bce83a6c7928c4cc8f9a5e18efbca40d18394d32"
DESCRIPTION="header-only library for creating parsers according to Parsing Expression Grammar"
HOMEPAGE="https://github.com/taocpp/PEGTL"
SRC_URI="${HOMEPAGE}/archive/${COMMIT}.tar.gz -> ${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="test"
DEPEND=""
RDEPEND="${DEPEND}"

@ -13,6 +13,7 @@ KEYWORDS="~amd64"
IUSE=""
DEPEND="
dev-lang/ocaml:=
dev-ml/ppx_core:=
dev-ml/ppx_driver:=
dev-ml/ppx_metaquot:=

@ -13,6 +13,7 @@ KEYWORDS="~amd64"
IUSE=""
DEPEND="
dev-lang/ocaml:=
dev-ml/ppx_core:=
dev-ml/ppx_driver:=
dev-ml/ppx_type_conv:=

@ -17,7 +17,10 @@ IUSE="test"
RDEPEND=""
DEPEND="${RDEPEND}
dev-perl/Email-Address
test? ( virtual/perl-Test-Simple )
test? (
virtual/perl-Test-Simple
dev-perl/JSON
)
"
SRC_TEST="do"

@ -10,7 +10,7 @@ inherit perl-module
DESCRIPTION="Locate per-dist and per-module shared files"
SLOT="0"
KEYWORDS="~alpha amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~ppc-aix ~x86-solaris"
KEYWORDS="~alpha amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc x86 ~ppc-aix ~x86-solaris"
IUSE="test"
RDEPEND="

@ -11,7 +11,7 @@ inherit perl-module
DESCRIPTION="Interface for creation of Perl Filters"
SLOT="0"
KEYWORDS="~alpha amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
KEYWORDS="~alpha amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc x86 ~ppc-aix ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
IUSE=""
DEPEND="

@ -1,2 +1,3 @@
DIST Sub-Uplevel-0.25.tar.gz 27618 SHA256 2dcca582a7ea5bada576eb27c4be1d1b064fb22175bdbd6d696c45d083560505 SHA512 647667f69621b1e9c17f41f5b5edd2b75a7c84e853b7fe1bd3f3ca74f14539a63843300b88b8245d20f9730a5a1466287770dd09c1ab597574b8da9d77775aec WHIRLPOOL f438b26a960ae5e2133e05e9d280ef876064124728d37ff79e40ff24b2e584a856f8e548e46a766b6de3c22ead53d7899061f7d25bc72c9f0a4ecd3438f71d4a
DIST Sub-Uplevel-0.2600.tar.gz 28119 SHA256 e833e29b7d6037efee6d7ee2056cbb8aaaa908e4f5451969043093eb2917a166 SHA512 f10c59c0458d9a1d6e832246c8c852bb88c65871b4d24688393985dfc10d982a0db2f2f8805c26ba232a755c88382f327af62390c3ee3ae68e33c90d042654e3 WHIRLPOOL bb73b891806f3d54e51d54a7e48743c4a70ef66e1c3d8cdb63c0e3555f0774fd6113dc6918b250ba55ab9b34221f4049809e593e7859be65667bc43a48b24edd
DIST Sub-Uplevel-0.2800.tar.gz 28361 SHA256 b4f3f63b80f680a421332d8851ddbe5a8e72fcaa74d5d1d98f3c8cc4a3ece293 SHA512 655bab9441bc81e4002db2e715b5c1f771ee35a03bc643a44d4a279aca55431fe17e64332919311a51db2dc02c16b5f97c5751595e61ad0ab96cd0a10ac2d230 WHIRLPOOL ab027c292f66ae01b6b5ca9cef278674caf68f3e77c0460803dcb09566e842832aca84617e52fff11688cddc594512dbee608774c5e213bbbde91dc777ef9689

@ -0,0 +1,24 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
DIST_AUTHOR=DAGOLDEN
DIST_VERSION=0.2800
inherit perl-module
DESCRIPTION="Apparently run a function in a higher stack frame"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~x64-solaris ~x86-solaris"
IUSE="test"
RDEPEND="virtual/perl-Carp"
DEPEND="${RDEPEND}
>=virtual/perl-ExtUtils-MakeMaker-6.170.0
test? (
virtual/perl-Exporter
virtual/perl-File-Spec
virtual/perl-Test-Simple
)
"

@ -1 +1,2 @@
DIST Test-File-1.442.tar.gz 26895 SHA256 653123c08b50601eadad24638621c3c161cf97ac3127f3c7b7fe205b28115d88 SHA512 efddd0d86fbe6ccdd3d1051950aa5ca7619e56485718b15a7260eabf2a8d257c511c05b181ac708fef63b949781658d93c48b384b6197353a6cb6aa2a4f58471 WHIRLPOOL 9277c5fe67e81215ec3fccc0b7b3896d9a1198429a1ec466cf74db8e1a7d38a260143904cd9a04e4493ad9b9080c911d937ba606a4e5e610aac73d874c0ad761
DIST Test-File-1.443.tar.gz 27065 SHA256 61b4a6ab8f617c8c7b5975164cf619468dc304b6baaaea3527829286fa58bcd5 SHA512 9ad66b3a9dc1c3752a4ec22934db9139ac010ac3237a3de018d4ec4a65ac047f0152ab9e7979a2615412c1af02a1f2dfa0dbfdf5eba5358628b1b443232c45b2 WHIRLPOOL d2c224dc06642357407dd946e7f9f8aa996603c3ed467d18860b909b4b73e8796eb81500e7ec0de97b166380ef9ce6c55a94922c563f45df02f700d098ac4603

@ -0,0 +1,31 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
DIST_AUTHOR=BDFOY
DIST_VERSION=1.443
inherit perl-module
DESCRIPTION="Test file attributes"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="test"
RDEPEND="
"
DEPEND="${RDEPEND}
>=virtual/perl-ExtUtils-MakeMaker-6.640.0
test? (
>=virtual/perl-Test-Simple-0.950.0
dev-perl/Test-utf8
)
"
src_prepare() {
if use test; then
perl_rm_files t/pod.t t/pod_coverage.t t/test_manifest
sed -i -e '/Test::Manifest/d' Makefile.PL || die "Can't patch Makefile.PL"
fi
perl-module_src_prepare
}

@ -5,4 +5,8 @@
<email>perl@gentoo.org</email>
<name>Gentoo Perl Project</name>
</maintainer>
<upstream>
<remote-id type="cpan">Test-File</remote-id>
<remote-id type="cpan-module">Test::File</remote-id>
</upstream>
</pkgmetadata>

@ -2,3 +2,4 @@ DIST Tree-Simple-1.18.tar.gz 32851 SHA256 cfbcdf0e02fb94134e1308ef5c3feb4ca4d4ff
DIST Tree-Simple-1.27.tgz 46811 SHA256 ec3f9447744172c798a2191276c8ab2f4296f51e3b4e3fd48fa242e8509c566c SHA512 61cc1b7350adbae47fdd23693f212b700363e388e650fbb1e740f6ca615d6b61ac71e2283ee96fb68987bc8f3f295948edd9a981fd45f87e1a68fa92edfd3df1 WHIRLPOOL 3938373603f119fc0b4d160b144ddb01be382c4f246e3281e7fa9d3d1f14ce064c3f22bed4e84590cc3304318809f79122f134d6481fb81ea3ef9339b5cc366e
DIST Tree-Simple-1.29.tgz 47322 SHA256 695e693587241d56d6b5a6e1477f548bcf71a0b0e4bf14b06ef2965e499bfe2c SHA512 d6ed79878bf9e8cb4bf82a85dd4d11c70968be53b08d73905d49fff70ec21ca53c604df1e139c0304763e592e42db831c411d03dc8cd1bbb2834cf037088b746 WHIRLPOOL a87fac94e3437b075d97db8bebfcd19b640117c11040434cdc7b341feb23fb55739cced9fee86813d7d051d8d2db2924641102952ae0d405aa183523acaf2764
DIST Tree-Simple-1.30.tgz 48264 SHA256 5d8b76105d6d3168382f40a215e1a83e16bc0eca7acd4336bb0d9a6355dd92e4 SHA512 41d94b040a882edf0f5777276246e8e55bf3f19bcc93f6facea5076136b3d8931d663e5a989e5045c104e76aca86d14dfe63bc7e39cd9d8542ea47c1dc202c0d WHIRLPOOL db01a2b87eca350c99b0da1aa28f97ddba1f8bf66940854080615d75d11f02810406fbdf4ababce43e41bd19bdbbc99b29acba1f9e882a7af5edd4f29c1f62df
DIST Tree-Simple-1.31.tgz 49287 SHA256 1745edd71b516cd570676fc1d63e1baa6019cd6132a37446b064592557500cc9 SHA512 ec35f8256256c9a053c2643d55ea6aeb1c354ff9f19d01697f26ecefaa2f1e966c00ec9a5d33528c9ba1f02155a27aab94c17f1403125e1b4ade3ff724966a4e WHIRLPOOL d4135c9023a772a62bd96405effd05ba0dd33ede78ff9c9c27b7414c59a7317b63b3a4bb6b6dbb8ab79c6a1d7ad9fd0680dc31635cf6c1a7d4c7a0ac56d2b0a8

@ -0,0 +1,27 @@
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
DIST_AUTHOR=RSAVAGE
DIST_VERSION=1.31
DIST_A_EXT=tgz
inherit perl-module
DESCRIPTION="A simple tree object"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~x86"
IUSE="test minimal"
RDEPEND="
>=virtual/perl-Scalar-List-Utils-1.180.0
"
DEPEND="${RDEPEND}
virtual/perl-ExtUtils-MakeMaker
test? (
!minimal? ( dev-perl/Test-Memory-Cycle )
>=dev-perl/Test-Exception-0.150.0
>=virtual/perl-Test-Simple-1.1.2
)
"

@ -16,7 +16,7 @@ LICENSE="BSD"
KEYWORDS="~amd64 ~arm ~x86 ~amd64-linux ~x86-linux"
IUSE="test"
DEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
DEPEND="dev-python/setuptools_scm[${PYTHON_USEDEP}]
test? ( dev-python/nose[${PYTHON_USEDEP}] )"
python_test() {

@ -1,3 +1 @@
DIST image_transport_plugins-1.9.2.tar.gz 23734 SHA256 b610f50cdbab30abaa94980b22a444c5d898c571e3f57f0cf83ecde53877fdf0 SHA512 5ac7429cf61699f1827fdf15374aee5d951cd6aa77321f245bfe4e9771647e1bae5902646f30cb88019675e48732cd4f705eafe0931268684a449bef356bf972 WHIRLPOOL 7136449bf3fbc5f161a89c4fabac2d24fc4d4548186895e95a0aa7175ac196b5859d63da0cd59b418a570c10c767f19a8a9e7d0d408cd2c0517bff5407a512df
DIST image_transport_plugins-1.9.3.tar.gz 25291 SHA256 2d9b10f1e3c22145d58ba922dcafc72b149bb4561e641fff17eddf1510294271 SHA512 51ec14f5bef48e337146e303a4b87290c932d418621e3ae65d5a2f96247c4d0e9ac63df5c4e102f1532737448b272f07e2ce841030a33b8701febacad1698781 WHIRLPOOL c255da767e2dd668eef9499e26822b7eb3d6c144343287a34e3d396574776b29eff2ed90c384f99e1f9b53031a0f6d14a7311c0d2022bd4fc46af53c0a432025
DIST image_transport_plugins-1.9.5.tar.gz 26268 SHA256 a3dcd3af617bcafba5b8dab5fbd89183fbaf31798ee4e4e63a91059fa110168c SHA512 54f459719a386f028578889f9b88b8b080f495d75899cee6c8bfb58204970fb2395b2a8da70034eb391ba62f4ce462cb89b97bcdc576a177444613076b5ed02c WHIRLPOOL 1796f983cd0a904b6cce58ecec4a59034ab23ca8ca7a3c2a9b3fa8764d60c1426754c3a6bdb9eaf8bcff1859768af76b3d4f3a3350ee6cd6af5cc89f90ae639a

@ -1,24 +0,0 @@
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
ROS_REPO_URI="https://github.com/ros-perception/image_transport_plugins"
KEYWORDS="~amd64 ~arm"
ROS_SUBDIR=${PN}
PYTHON_COMPAT=( python2_7 )
inherit ros-catkin
DESCRIPTION="Plugin to image_transport for transparently sending depth images using PNG compression"
LICENSE="BSD"
SLOT="0"
IUSE=""
RDEPEND="
dev-ros/cv_bridge
dev-ros/dynamic_reconfigure[${PYTHON_USEDEP}]
dev-ros/image_transport
dev-ros/tf
media-libs/opencv
"
DEPEND="${RDEPEND}"

@ -1,23 +0,0 @@
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
ROS_REPO_URI="https://github.com/ros-perception/image_transport_plugins"
KEYWORDS="~amd64 ~arm"
ROS_SUBDIR=${PN}
PYTHON_COMPAT=( python2_7 )
inherit ros-catkin
DESCRIPTION="Plugin to image_transport for transparently sending depth images using PNG compression"
LICENSE="BSD"
SLOT="0"
IUSE=""
RDEPEND="
dev-ros/cv_bridge
dev-ros/dynamic_reconfigure[${PYTHON_USEDEP}]
dev-ros/image_transport
media-libs/opencv
"
DEPEND="${RDEPEND}"

@ -1,4 +1,4 @@
# Copyright 1999-2016 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
@ -18,6 +18,6 @@ RDEPEND="
dev-ros/cv_bridge
dev-ros/dynamic_reconfigure[${PYTHON_USEDEP}]
dev-ros/image_transport
media-libs/opencv
media-libs/opencv:=
"
DEPEND="${RDEPEND}"

@ -1,4 +1,4 @@
# Copyright 1999-2014 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
@ -18,6 +18,6 @@ RDEPEND="
dev-ros/cv_bridge
dev-ros/dynamic_reconfigure[${PYTHON_USEDEP}]
dev-ros/image_transport
media-libs/opencv
media-libs/opencv:=
"
DEPEND="${RDEPEND}"

@ -1,3 +1 @@
DIST image_transport_plugins-1.9.2.tar.gz 23734 SHA256 b610f50cdbab30abaa94980b22a444c5d898c571e3f57f0cf83ecde53877fdf0 SHA512 5ac7429cf61699f1827fdf15374aee5d951cd6aa77321f245bfe4e9771647e1bae5902646f30cb88019675e48732cd4f705eafe0931268684a449bef356bf972 WHIRLPOOL 7136449bf3fbc5f161a89c4fabac2d24fc4d4548186895e95a0aa7175ac196b5859d63da0cd59b418a570c10c767f19a8a9e7d0d408cd2c0517bff5407a512df
DIST image_transport_plugins-1.9.3.tar.gz 25291 SHA256 2d9b10f1e3c22145d58ba922dcafc72b149bb4561e641fff17eddf1510294271 SHA512 51ec14f5bef48e337146e303a4b87290c932d418621e3ae65d5a2f96247c4d0e9ac63df5c4e102f1532737448b272f07e2ce841030a33b8701febacad1698781 WHIRLPOOL c255da767e2dd668eef9499e26822b7eb3d6c144343287a34e3d396574776b29eff2ed90c384f99e1f9b53031a0f6d14a7311c0d2022bd4fc46af53c0a432025
DIST image_transport_plugins-1.9.5.tar.gz 26268 SHA256 a3dcd3af617bcafba5b8dab5fbd89183fbaf31798ee4e4e63a91059fa110168c SHA512 54f459719a386f028578889f9b88b8b080f495d75899cee6c8bfb58204970fb2395b2a8da70034eb391ba62f4ce462cb89b97bcdc576a177444613076b5ed02c WHIRLPOOL 1796f983cd0a904b6cce58ecec4a59034ab23ca8ca7a3c2a9b3fa8764d60c1426754c3a6bdb9eaf8bcff1859768af76b3d4f3a3350ee6cd6af5cc89f90ae639a

@ -1,24 +0,0 @@
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
ROS_REPO_URI="https://github.com/ros-perception/image_transport_plugins"
KEYWORDS="~amd64 ~arm"
ROS_SUBDIR=${PN}
PYTHON_COMPAT=( python2_7 )
inherit ros-catkin
DESCRIPTION="Plugin to image_transport for transparently sending images encoded as JPEG or PNG"
LICENSE="BSD"
SLOT="0"
IUSE=""
RDEPEND="
dev-ros/cv_bridge
dev-ros/dynamic_reconfigure[${PYTHON_USEDEP}]
dev-ros/image_transport
dev-ros/tf
media-libs/opencv
"
DEPEND="${RDEPEND}"

@ -1,23 +0,0 @@
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
ROS_REPO_URI="https://github.com/ros-perception/image_transport_plugins"
KEYWORDS="~amd64 ~arm"
ROS_SUBDIR=${PN}
PYTHON_COMPAT=( python2_7 )
inherit ros-catkin
DESCRIPTION="Plugin to image_transport for transparently sending images encoded as JPEG or PNG"
LICENSE="BSD"
SLOT="0"
IUSE=""
RDEPEND="
dev-ros/cv_bridge
dev-ros/dynamic_reconfigure[${PYTHON_USEDEP}]
dev-ros/image_transport
media-libs/opencv
"
DEPEND="${RDEPEND}"

@ -1,4 +1,4 @@
# Copyright 1999-2016 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
@ -18,6 +18,6 @@ RDEPEND="
dev-ros/cv_bridge
dev-ros/dynamic_reconfigure[${PYTHON_USEDEP}]
dev-ros/image_transport
media-libs/opencv
media-libs/opencv:=
"
DEPEND="${RDEPEND}"

@ -1,4 +1,4 @@
# Copyright 1999-2014 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
@ -18,6 +18,6 @@ RDEPEND="
dev-ros/cv_bridge
dev-ros/dynamic_reconfigure[${PYTHON_USEDEP}]
dev-ros/image_transport
media-libs/opencv
media-libs/opencv:=
"
DEPEND="${RDEPEND}"

@ -16,7 +16,7 @@ IUSE=""
RDEPEND="
dev-ros/rosconsole
media-libs/opencv[contrib(+)]
media-libs/opencv:=[contrib(+)]
dev-libs/boost:=[threads,python,${PYTHON_USEDEP}]
dev-ros/sensor_msgs[${CATKIN_MESSAGES_CXX_USEDEP},${CATKIN_MESSAGES_PYTHON_USEDEP}]
"

@ -1,4 +1,4 @@
# Copyright 1999-2016 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
@ -16,7 +16,7 @@ IUSE=""
RDEPEND="
dev-ros/rosconsole
media-libs/opencv[contrib(+)]
media-libs/opencv:=[contrib(+)]
dev-libs/boost:=[threads,python,${PYTHON_USEDEP}]
dev-ros/sensor_msgs[${CATKIN_MESSAGES_CXX_USEDEP},${CATKIN_MESSAGES_PYTHON_USEDEP}]
"

@ -15,6 +15,7 @@ IUSE=""
RDEPEND="
dev-ros/cv_bridge
media-libs/opencv:=
dev-ros/eigen_conversions
dev-ros/image_geometry
dev-ros/image_transport

@ -1,4 +1,4 @@
# Copyright 1999-2014 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
@ -15,6 +15,7 @@ IUSE=""
RDEPEND="
dev-ros/cv_bridge
media-libs/opencv:=
dev-ros/eigen_conversions
dev-ros/image_geometry
dev-ros/image_transport

@ -15,6 +15,7 @@ IUSE=""
RDEPEND="
dev-ros/roscpp
media-libs/opencv:=
dev-ros/dynamic_reconfigure[${PYTHON_USEDEP}]
dev-ros/image_geometry
dev-ros/image_transport

@ -1,4 +1,4 @@
# Copyright 1999-2015 Gentoo Foundation
# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
@ -15,6 +15,7 @@ IUSE=""
RDEPEND="
dev-ros/roscpp
media-libs/opencv:=
dev-ros/dynamic_reconfigure[${PYTHON_USEDEP}]
dev-ros/image_geometry
dev-ros/image_transport

@ -36,6 +36,7 @@ RDEPEND="
dev-ros/image_transport
dev-ros/rosconsole
dev-ros/cv_bridge
media-libs/opencv:=
dev-ros/polled_camera
dev-ros/diagnostic_updater
dev-ros/camera_info_manager

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save