Sync with portage [Mon Jun 17 08:47:53 MSK 2019].

mhiretskiy 1436
root 5 years ago
parent e78b0c41a3
commit 2d17c316dc

Binary file not shown.

Binary file not shown.

@ -1,8 +1,6 @@
DIST ansible-2.6.14.tar.gz 10732165 BLAKE2B c753860a521c37357c7a5042391957680865416c036fcaf3920a65e291dc3ed3a52e94ad5b99acdb0d2c919e3be68b8462e462a935497dfe83b406adf4e63dad SHA512 ee532c0d61ab03a0937e89bfa7565f27f1905987784f31895e8ac6e4a8ecf76ca9f30201d278a68a995b8fc27151712dba2e79c13269a472d923355e36072e4e
DIST ansible-2.6.16.tar.gz 10738431 BLAKE2B b801eb524f631950c385f7a949bdeae288e95d1590ea96f98e955f6ebc4ccfc5970e3926727850e7ef13fbcd7118ad6388e516a8fe62b53f1bf8b4d5b484dbab SHA512 ff67803cf6afd512ab779b7c862d4427591c90bb0ed9391e32fc8ea30c24c70cc31c910c9af51b4dd423885f858f65c1c8d6274565c90296ecd7a00df3374977
DIST ansible-2.6.17.tar.gz 10742849 BLAKE2B 04667612ab7d149d7a322ce674c2256164c0d958d3e5b34cafeba0b90d4f0f07ee95a31bf0c205c13c90ee4d63c3045ce2fc51de8996a7dcb877d39e2da680f5 SHA512 ba46192549be3e853232d865116c176aebd8ed2b63fcbb45cb633d3809fc534004849a70a2abad80f9fe99deeb55af3883ce1bfe0db4a9afd2f6b8045936e860
DIST ansible-2.7.10.tar.gz 11844278 BLAKE2B c847b642ebe4cbc2194538a0b194cd5c0bb82e0ba2a6da2e272670c75596b9793e028d067ddb37000c07f2c2427b5b99248b16c544daed4976c0210b601d3c97 SHA512 4d58ef080c8ee02ef36eb3116ec89e4542b5b4042262953b2001081601fe1066237191cce5e647f354efa9e1933cf5010519d049e678a90e8ca08620cd1788a5
DIST ansible-2.7.11.tar.gz 11855636 BLAKE2B 3de8fa1287655f778b1d9036bf78a91387cf238209eb2bfd17ee79f7d77a2e03ae734901bdc04226d635b3d8543d122aaa251107befab8cc4a4fc63cfcd8deec SHA512 06f805a701f8284ac1a65251b9358cf6f27d420aabb1e29298f9e4d8aa73251bd4a8e8a3981f744b97b2f750fd3b594a9b505e5baa3ff2cb3aa7a37603ba48fa
DIST ansible-2.7.9.tar.gz 11830476 BLAKE2B 7688ce9f74b0ab1fafd0e31dce90d995a9d8ca90bbe436f2d4ee9d005069b6e1b2c4dd679c2430a6873233da54ae06d3ebf08736681ec2e59e5b3ddafa6bb1e2 SHA512 4d39c7d4eb97264ce8f92812fb986b24af0c663efa6d8cd1d9a4cb25731d55e7518e503c04764e62d0458916b601baaa7acc623f9f83ce8b93e7f22900e29a53
DIST ansible-2.8.0.tar.gz 14285827 BLAKE2B 090c314e0c707e24ce4c21722bfbb34d18d95e6e8cd63b06af78e41fedb3183adbdf6718da1bb8a2c7037f9ea9ffffb96add17a44cb199d0c000c1d6f88cd53e SHA512 fab8a0ac00e947e47ab606bee0a15e8c031f900b5e6fc68540429db0035ffdf3144e18e1d2265ac07bbea0a78873b85c43e636ee51ecfe14f3d612d2c54eb29c
DIST ansible-2.8.1.tar.gz 14299403 BLAKE2B defbe8fa8db7ab3325cf57df3bdfe901f53544b4c1b6460cefbfa9393acfe2a0e104f99468ad8e907d90d33842563bd7ab666d30f64572fd146c7ce46ff77048 SHA512 08be80584edfe28f11fe750735ade117deaf3a7c98fe15fb2fa0e3a5ed0c3f98cd126b60386e51d15ce275e8f1fc3eda0177bb56e0823b2f2b7702cc0e35be92

@ -1,66 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
PYTHON_COMPAT=( python2_7 python3_{5,6} )
inherit distutils-r1 eutils
DESCRIPTION="Model-driven deployment, config management, and command execution framework"
HOMEPAGE="https://ansible.com/"
SRC_URI="https://releases.ansible.com/${PN}/${P}.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="amd64 x86 ~x64-macos"
IUSE="doc test"
RDEPEND="
dev-python/paramiko[${PYTHON_USEDEP}]
dev-python/jinja[${PYTHON_USEDEP}]
dev-python/pyyaml[${PYTHON_USEDEP}]
dev-python/setuptools[${PYTHON_USEDEP}]
dev-python/cryptography[${PYTHON_USEDEP}]
dev-python/httplib2[${PYTHON_USEDEP}]
dev-python/six[${PYTHON_USEDEP}]
dev-python/netaddr[${PYTHON_USEDEP}]
net-misc/sshpass
virtual/ssh
"
DEPEND="
dev-python/setuptools[${PYTHON_USEDEP}]
>=dev-python/packaging-16.6[${PYTHON_USEDEP}]
doc? ( dev-python/sphinx[${PYTHON_USEDEP}] )
test? (
${RDEPEND}
dev-python/nose[${PYTHON_USEDEP}]
>=dev-python/mock-1.0.1[${PYTHON_USEDEP}]
dev-python/passlib[${PYTHON_USEDEP}]
dev-python/coverage[${PYTHON_USEDEP}]
dev-python/unittest2[${PYTHON_USEDEP}]
dev-vcs/git
)"
# not included in release tarball
RESTRICT="test"
python_compile_all() {
if use doc; then
cd docs/docsite || die
export CPUS=4
emake -f Makefile.sphinx html
fi
}
python_test() {
nosetests -d -w test/units -v --with-coverage --cover-package=ansible --cover-branches || die
}
python_install_all() {
use doc && local HTML_DOCS=( docs/docsite/_build/html/. )
distutils-r1_python_install_all
doman docs/man/man1/*.1
dodoc -r examples
}

@ -1,66 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
PYTHON_COMPAT=( python2_7 python3_{5,6,7} )
inherit distutils-r1 eutils
DESCRIPTION="Model-driven deployment, config management, and command execution framework"
HOMEPAGE="https://ansible.com/"
SRC_URI="https://releases.ansible.com/${PN}/${P}.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="amd64 ~arm ~arm64 x86 ~x64-macos"
IUSE="doc test"
RDEPEND="
dev-python/paramiko[${PYTHON_USEDEP}]
dev-python/jinja[${PYTHON_USEDEP}]
dev-python/pyyaml[${PYTHON_USEDEP}]
dev-python/setuptools[${PYTHON_USEDEP}]
dev-python/cryptography[${PYTHON_USEDEP}]
dev-python/httplib2[${PYTHON_USEDEP}]
dev-python/six[${PYTHON_USEDEP}]
dev-python/netaddr[${PYTHON_USEDEP}]
net-misc/sshpass
virtual/ssh
"
DEPEND="
dev-python/setuptools[${PYTHON_USEDEP}]
>=dev-python/packaging-16.6[${PYTHON_USEDEP}]
doc? ( dev-python/sphinx[${PYTHON_USEDEP}] )
test? (
${RDEPEND}
dev-python/nose[${PYTHON_USEDEP}]
>=dev-python/mock-1.0.1[${PYTHON_USEDEP}]
dev-python/passlib[${PYTHON_USEDEP}]
dev-python/coverage[${PYTHON_USEDEP}]
dev-python/unittest2[${PYTHON_USEDEP}]
dev-vcs/git
)"
# not included in release tarball
RESTRICT="test"
python_compile_all() {
if use doc; then
cd docs/docsite || die
export CPUS=4
emake -f Makefile.sphinx html
fi
}
python_test() {
nosetests -d -w test/units -v --with-coverage --cover-package=ansible --cover-branches || die
}
python_install_all() {
use doc && local HTML_DOCS=( docs/docsite/_build/html/. )
distutils-r1_python_install_all
doman docs/man/man1/*.1
dodoc -r examples
}

@ -13,7 +13,7 @@ SRC_URI="https://releases.ansible.com/${PN}/${P}.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~arm ~arm64 ~x86 ~x64-macos"
KEYWORDS="amd64 ~arm ~arm64 x86 ~x64-macos"
IUSE="doc test"
RESTRICT="test"

Binary file not shown.

@ -1,3 +1,2 @@
DIST hardlink-0.3.2.tar.bz2 15479 BLAKE2B dd6cfc312ed75dc6d9e37b898215ed90efe4734c5974297c9e29a51a69c9b2d4e91d9aa3bca1d42679307eecd95ee46e6f636c211d1ceafef1ea52428761d1ec SHA512 1d027f7b2f1974c950044fa8872dc58101800ca557a4d66406652fb43f64653f7dd39a70f4ac65f5f6bca9116de4ce44aeba2ef1fe446834641ba5c4c5604dff
DIST hardlink_0.2.0.tar.gz 12478 BLAKE2B 42918fbacdd230796e59f6ae7968599a90b63cc35876872ef34919377d6489c6c99d06f201a122f5859a283cea2672dbcc207e04c6b5ca0c54ab4e2f4178a970 SHA512 963fe90aa09e2bd548722b5c7f047fbd54fddf37967333e86251d7e5d1c646108ce90d78e7efeb8af6b9169b9a0bc5bc8b744afe1e813390f3e0bd535ce22005
DIST hardlink_0.3.0.tar.xz 14440 BLAKE2B cfbd02b008d49b129e0b75f67bf45d904e89a1e585d0e05e959770a4367ad0f5823f24cb4f3f6715310c749ba368ac00d378f8eb967a1b4437335eecee8a5077 SHA512 22a8945ce5dac74b05bb1231959823aec0cd364d6db9ad808df4acf232d894170c006ac1e88509604ce1859d41bd4a5d91e2b12c8010aa7fc7e19a77922c4486

@ -1,4 +1,4 @@
# Copyright 1999-2018 Gentoo Foundation
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=4
@ -13,7 +13,8 @@ SLOT="0"
KEYWORDS="amd64 ~arm ppc ppc64 x86"
IUSE=""
RDEPEND="dev-libs/libpcre"
RDEPEND="dev-libs/libpcre
!>=sys-apps/util-linux-2.34[hardlink]"
DEPEND="${RDEPEND}
virtual/pkgconfig"

@ -1,38 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit toolchain-funcs
DESCRIPTION="A tool which replaces copies of a file with hardlinks"
HOMEPAGE="https://jak-linux.org/projects/hardlink/"
SRC_URI="https://jak-linux.org/projects/${PN}/${PN}_${PV}.tar.xz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86"
RDEPEND="dev-libs/libpcre"
DEPEND="${RDEPEND}"
BDEPEND="virtual/pkgconfig"
DOCS=( README ${T}/README.rsync )
src_prepare() {
default
sed -i -e '/^CF/s:?=:+=:' -e '/^CF/s:-O2 -g::' Makefile || die
cat <<-EOF > "${T}"/README.rsync
https://hardlinkpy.googlecode.com/svn/trunk/hardlink.py has regex '^\..*\.\?{6,6}$'
for excluding rsync temporary files by default.
To accomplish same with this version, you can use following syntax:
# hardlink -x '^\..*\.\?{6,6}$'
This was discussed at https://bugs.gentoo.org/416613
EOF
}
src_compile() {
emake CC=$(tc-getCC)
}

@ -13,7 +13,10 @@ LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86"
RDEPEND="dev-libs/libpcre"
RDEPEND="
dev-libs/libpcre
!>=sys-apps/util-linux-2.34[hardlink]
"
DEPEND="${RDEPEND}"
BDEPEND="virtual/pkgconfig"

Binary file not shown.

@ -28,7 +28,7 @@ RDEPEND="
app-arch/lz4
virtual/acl
dev-python/llfuse[${PYTHON_USEDEP}]
dev-python/msgpack[${PYTHON_USEDEP}]
~dev-python/msgpack-0.5.6[${PYTHON_USEDEP}]
dev-python/pyzmq[${PYTHON_USEDEP}]
!libressl? ( dev-libs/openssl:0= )
libressl? ( dev-libs/libressl:0= )

@ -5,6 +5,10 @@
<email>blueness@gentoo.org</email>
<name>Anthony G. Basile</name>
</maintainer>
<maintainer type="person">
<email>slashbeast@gentoo.org</email>
<name>Piotr Karbowski</name>
</maintainer>
<upstream>
<remote-id type="github">borgbackup/borg</remote-id>
<remote-id type="pypi">borgbackup</remote-id>

Binary file not shown.

@ -12,7 +12,7 @@ SRC_URI="https://github.com/BLAKE2/libb2/archive/${GITHASH}.tar.gz -> ${P}.tar.g
LICENSE="CC0-1.0"
SLOT="0"
KEYWORDS="~amd64 ~hppa ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
KEYWORDS="~amd64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
IUSE="static-libs native-cflags openmp"
DEPEND="

@ -1,54 +0,0 @@
From: Gokturk Yuksek <gokturk@gentoo.org>
Subject: [PATCH] Make tests with CHECK optional at configure time
--- a/configure.ac
+++ b/configure.ac
@@ -63,7 +63,15 @@
PKG_CHECK_MODULES([LIBCRYPTO], [libcrypto], [], [])
-PKG_CHECK_MODULES([CHECK], [check], [], [])
+AC_ARG_ENABLE([tests],
+ [AS_HELP_STRING([--enable-tests],
+ [use check to run the unit tests])],
+ [enable_tests=$enableval],
+ [enable_tests=no])
+AM_CONDITIONAL([ENABLE_TESTS],[test '!' "$enable_tests" = no])
+if test '!' "$enable_tests" = no; then
+ PKG_CHECK_MODULES([CHECK], [check], [], [AC_MSG_NOTICE(Check package not found `make check` won't work)])
+fi
AC_ARG_ENABLE([coverage],
[AS_HELP_STRING([--enable-coverage],
@@ -123,11 +131,15 @@
Makefile
gtk-doc/Makefile
src/Makefile
- tests/Makefile
u2f-server/Makefile
u2f-server/u2f-server-version.h
u2f-server/u2f-server.pc
])
+if test '!' "$enable_tests" = no; then
+ AC_CONFIG_FILES([
+ tests/Makefile
+ ])
+fi
AC_OUTPUT
AC_MSG_NOTICE([summary of build options:
--- a/Makefile.am
+++ b/Makefile.am
@@ -25,7 +25,11 @@
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-SUBDIRS = u2f-server src tests gtk-doc
+SUBDIRS = u2f-server src gtk-doc
+
+if ENABLE_TESTS
+SUBDIRS+=tests
+endif
ACLOCAL_AMFLAGS = -I m4

Binary file not shown.

@ -1 +1,2 @@
DIST emacs-26.2.90.tar.xz 44412120 BLAKE2B 72eab92b3144e3807a612a1a4c87da23181ab9b42b12692401f666eae7fbdb3e832d4f5d9dbc6473df8de9af6046ad94bbb0874a57747b594dbae62435fe5357 SHA512 66e53ae2a6d89505111e7bc9b7a6e6324a9a5577d1ad8905244dbc8619b21ea410b20bd8bab0442ec226f7a0d5f2292e01171189517736e4fa5e0e15eba51074
DIST emacs-27.0.50_pre20180831.tar.xz 28668124 BLAKE2B fae74d9885889b042142f580e971c73c193306dca26b42dd87ac3d3d765312ce6695511d7d31a047d79803982f6345c4c319a3d83cea1313080170da97482fa2 SHA512 43b32d8943dc897dfc0c1fddb4261a196d3a604add5bcf87a93748125f15db2cac762d3550d6593b80e961ae35d543adc4d5937bac77970c658f93dba26f17e4

@ -0,0 +1,408 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit autotools elisp-common flag-o-matic multilib readme.gentoo-r1
if [[ ${PV##*.} = 9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://git.savannah.gnu.org/git/emacs.git"
EGIT_BRANCH="emacs-26"
EGIT_CHECKOUT_DIR="${WORKDIR}/emacs"
S="${EGIT_CHECKOUT_DIR}"
else
SRC_URI="https://dev.gentoo.org/~ulm/distfiles/emacs-${PV}.tar.xz
mirror://gnu-alpha/emacs/pretest/emacs-${PV}.tar.xz"
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
# FULL_VERSION keeps the full version number, which is needed in
# order to determine some path information correctly for copy/move
# operations later on
FULL_VERSION="${PV%%_*}"
S="${WORKDIR}/emacs-${FULL_VERSION}"
[[ ${FULL_VERSION} != ${PV} ]] && S="${WORKDIR}/emacs"
fi
DESCRIPTION="The extensible, customizable, self-documenting real-time display editor"
HOMEPAGE="https://www.gnu.org/software/emacs/"
LICENSE="GPL-3+ FDL-1.3+ BSD HPND MIT W3C unicode PSF-2"
SLOT="26"
IUSE="acl alsa aqua athena cairo dbus dynamic-loading games gconf gfile gif gpm gsettings gtk gtk2 gzip-el imagemagick +inotify jpeg kerberos lcms libxml2 livecd m17n-lib mailutils motif png selinux sound source ssl svg systemd +threads tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm xwidgets zlib"
REQUIRED_USE="?? ( aqua X )"
RDEPEND="sys-libs/ncurses:0=
>=app-eselect/eselect-emacs-1.16
>=app-emacs/emacs-common-gentoo-1.5[games?,X?]
acl? ( virtual/acl )
alsa? ( media-libs/alsa-lib )
dbus? ( sys-apps/dbus )
gpm? ( sys-libs/gpm )
!inotify? ( gfile? ( >=dev-libs/glib-2.28.6 ) )
kerberos? ( virtual/krb5 )
lcms? ( media-libs/lcms:2 )
libxml2? ( >=dev-libs/libxml2-2.2.0 )
mailutils? ( net-mail/mailutils[clients] )
!mailutils? ( net-libs/liblockfile )
selinux? ( sys-libs/libselinux )
ssl? ( net-libs/gnutls:0= )
systemd? ( sys-apps/systemd )
zlib? ( sys-libs/zlib )
X? (
x11-libs/libICE
x11-libs/libSM
x11-libs/libX11
x11-libs/libXext
x11-libs/libXfixes
x11-libs/libXinerama
x11-libs/libXrandr
x11-libs/libxcb
x11-misc/xbitmaps
gconf? ( >=gnome-base/gconf-2.26.2 )
gsettings? ( >=dev-libs/glib-2.28.6 )
gif? ( media-libs/giflib:0= )
jpeg? ( virtual/jpeg:0= )
png? ( >=media-libs/libpng-1.4:0= )
svg? ( >=gnome-base/librsvg-2.0 )
tiff? ( media-libs/tiff:0 )
xpm? ( x11-libs/libXpm )
imagemagick? ( >=media-gfx/imagemagick-6.6.2:0=
<media-gfx/imagemagick-7:0= )
xft? (
media-libs/fontconfig
media-libs/freetype
x11-libs/libXft
x11-libs/libXrender
cairo? ( >=x11-libs/cairo-1.12.18 )
m17n-lib? (
>=dev-libs/libotf-0.9.4
>=dev-libs/m17n-lib-1.5.1
)
)
gtk? (
gtk2? ( x11-libs/gtk+:2 )
!gtk2? (
x11-libs/gtk+:3
xwidgets? (
net-libs/webkit-gtk:4=
x11-libs/libXcomposite
)
)
)
!gtk? (
motif? (
>=x11-libs/motif-2.3:0
x11-libs/libXpm
x11-libs/libXmu
x11-libs/libXt
)
!motif? (
Xaw3d? (
x11-libs/libXaw3d
x11-libs/libXmu
x11-libs/libXt
)
!Xaw3d? ( athena? (
x11-libs/libXaw
x11-libs/libXmu
x11-libs/libXt
) )
)
)
)"
DEPEND="${RDEPEND}
X? ( x11-base/xorg-proto )"
BDEPEND="virtual/pkgconfig
gzip-el? ( app-arch/gzip )"
# pax_kernel? ( sys-apps/attr )
if [[ ${PV##*.} = 9999 ]]; then
BDEPEND="${BDEPEND}
sys-apps/texinfo"
fi
EMACS_SUFFIX="${PN/emacs/emacs-${SLOT}}"
SITEFILE="20${PN}-${SLOT}-gentoo.el"
src_prepare() {
if [[ ${PV##*.} = 9999 ]]; then
FULL_VERSION=$(sed -n 's/^AC_INIT([^,]*,[ \t]*\([^ \t,)]*\).*/\1/p' \
configure.ac)
[[ ${FULL_VERSION} ]] || die "Cannot determine current Emacs version"
einfo "Emacs branch: ${EGIT_BRANCH}"
einfo "Commit: ${EGIT_VERSION}"
einfo "Emacs version number: ${FULL_VERSION}"
[[ ${FULL_VERSION} =~ ^${PV%.*}(\..*)?$ ]] \
|| die "Upstream version number changed to ${FULL_VERSION}"
fi
eapply_user
# Fix filename reference in redirected man page
sed -i -e "/^\\.so/s/etags/&-${EMACS_SUFFIX}/" doc/man/ctags.1 || die
AT_M4DIR=m4 eautoreconf
}
src_configure() {
strip-flags
filter-flags -pie #526948
if use sh; then
replace-flags "-O[1-9]" -O0 #262359
elif use ia64; then
replace-flags "-O[2-9]" -O1 #325373
else
replace-flags "-O[3-9]" -O2
fi
local myconf
if use alsa; then
use sound || ewarn \
"USE flag \"alsa\" overrides \"-sound\"; enabling sound support."
myconf+=" --with-sound=alsa"
else
myconf+=" --with-sound=$(usex sound oss)"
fi
if use X; then
myconf+=" --with-x --without-ns"
myconf+=" $(use_with gconf)"
myconf+=" $(use_with gsettings)"
myconf+=" $(use_with toolkit-scroll-bars)"
myconf+=" $(use_with gif)"
myconf+=" $(use_with jpeg)"
myconf+=" $(use_with png)"
myconf+=" $(use_with svg rsvg)"
myconf+=" $(use_with tiff)"
myconf+=" $(use_with xpm)"
myconf+=" $(use_with imagemagick)"
if use xft; then
myconf+=" --with-xft"
myconf+=" $(use_with cairo)"
myconf+=" $(use_with m17n-lib libotf)"
myconf+=" $(use_with m17n-lib m17n-flt)"
else
myconf+=" --without-xft"
myconf+=" --without-cairo"
myconf+=" --without-libotf --without-m17n-flt"
use cairo && ewarn \
"USE flag \"cairo\" has no effect if \"xft\" is not set."
use m17n-lib && ewarn \
"USE flag \"m17n-lib\" has no effect if \"xft\" is not set."
fi
local f line
if use gtk; then
einfo "Configuring to build with GIMP Toolkit (GTK+)"
while read line; do ewarn "${line}"; done <<-EOF
Your version of GTK+ will have problems with closing open
displays. This is no problem if you just use one display, but
if you use more than one and close one of them Emacs may crash.
See <https://bugzilla.gnome.org/show_bug.cgi?id=85715>.
If you intend to use more than one display, then it is strongly
recommended that you compile Emacs with the Athena/Lucid or the
Motif toolkit instead.
EOF
if use gtk2; then
myconf+=" --with-x-toolkit=gtk2 --without-xwidgets"
use xwidgets && ewarn \
"USE flag \"xwidgets\" has no effect if \"gtk2\" is set."
else
myconf+=" --with-x-toolkit=gtk3 $(use_with xwidgets)"
fi
for f in motif Xaw3d athena; do
use ${f} && ewarn \
"USE flag \"${f}\" has no effect if \"gtk\" is set."
done
elif use motif; then
einfo "Configuring to build with Motif toolkit"
myconf+=" --with-x-toolkit=motif"
for f in Xaw3d athena; do
use ${f} && ewarn \
"USE flag \"${f}\" has no effect if \"motif\" is set."
done
elif use athena || use Xaw3d; then
einfo "Configuring to build with Athena/Lucid toolkit"
myconf+=" --with-x-toolkit=lucid $(use_with Xaw3d xaw3d)"
else
einfo "Configuring to build with no toolkit"
myconf+=" --with-x-toolkit=no"
fi
if ! use gtk; then
use gtk2 && ewarn \
"USE flag \"gtk2\" has no effect if \"gtk\" is not set."
use xwidgets && ewarn \
"USE flag \"xwidgets\" has no effect if \"gtk\" is not set."
fi
elif use aqua; then
einfo "Configuring to build with Nextstep (Cocoa) support"
myconf+=" --with-ns --disable-ns-self-contained"
myconf+=" --without-x"
else
myconf+=" --without-x --without-ns"
fi
econf \
--program-suffix="-${EMACS_SUFFIX}" \
--includedir="${EPREFIX}"/usr/include/${EMACS_SUFFIX} \
--infodir="${EPREFIX}"/usr/share/info/${EMACS_SUFFIX} \
--localstatedir="${EPREFIX}"/var \
--enable-locallisppath="${EPREFIX}/etc/emacs:${EPREFIX}${SITELISP}" \
--without-compress-install \
--without-hesiod \
--without-pop \
--with-file-notification=$(usev inotify || usev gfile || echo no) \
$(use_enable acl) \
$(use_with dbus) \
$(use_with dynamic-loading modules) \
$(use_with games gameuser ":gamestat") \
$(use_with gpm) \
$(use_with kerberos) $(use_with kerberos kerberos5) \
$(use_with lcms lcms2) \
$(use_with libxml2 xml2) \
$(use_with mailutils) \
$(use_with selinux) \
$(use_with ssl gnutls) \
$(use_with systemd libsystemd) \
$(use_with threads) \
$(use_with wide-int) \
$(use_with zlib) \
${myconf}
}
src_compile() {
# Disable sandbox when dumping. For the unbelievers, see bug #131505
emake RUN_TEMACS="SANDBOX_ON=0 LD_PRELOAD= env ./temacs"
}
src_install () {
emake DESTDIR="${D}" NO_BIN_LINK=t install
mv "${ED}"/usr/bin/{emacs-${FULL_VERSION}-,}${EMACS_SUFFIX} || die
mv "${ED}"/usr/share/man/man1/{emacs-,}${EMACS_SUFFIX}.1 || die
mv "${ED}"/usr/share/metainfo/{emacs-,}${EMACS_SUFFIX}.appdata.xml || die
# move info dir to avoid collisions with the dir file generated by portage
mv "${ED}"/usr/share/info/${EMACS_SUFFIX}/dir{,.orig} || die
touch "${ED}"/usr/share/info/${EMACS_SUFFIX}/.keepinfodir
docompress -x /usr/share/info/${EMACS_SUFFIX}/dir.orig
# avoid collision between slots, see bug #169033 e.g.
rm "${ED}"/usr/share/emacs/site-lisp/subdirs.el
rm -rf "${ED}"/usr/share/{appdata,applications,icons}
rm -rf "${ED}/usr/$(get_libdir)"
rm -rf "${ED}"/var
# remove unused <version>/site-lisp dir
rm -rf "${ED}"/usr/share/emacs/${FULL_VERSION}/site-lisp
# remove COPYING file (except for etc/COPYING used by describe-copying)
rm "${ED}"/usr/share/emacs/${FULL_VERSION}/lisp/COPYING
if use gzip-el; then
# compress .el files when a corresponding .elc exists
find "${ED}"/usr/share/emacs/${FULL_VERSION}/lisp -type f \
-name "*.elc" -print | sed 's/\.elc$/.el/' | xargs gzip -9n
assert "gzip .el failed"
fi
local cdir
if use source; then
cdir="/usr/share/emacs/${FULL_VERSION}/src"
insinto "${cdir}"
# This is not meant to install all the source -- just the
# C source you might find via find-function
doins src/*.{c,h,m}
elif has installsources ${FEATURES}; then
cdir="/usr/src/debug/${CATEGORY}/${PF}/${S#"${WORKDIR}/"}/src"
fi
sed -e "${cdir:+#}/^Y/d" -e "s/^[XY]//" >"${T}/${SITEFILE}" <<-EOF || die
X
;;; ${PN}-${SLOT} site-lisp configuration
X
(when (string-match "\\\\\`${FULL_VERSION//./\\\\.}\\\\>" emacs-version)
Y (setq find-function-C-source-directory
Y "${EPREFIX}${cdir}")
X (let ((path (getenv "INFOPATH"))
X (dir "${EPREFIX}/usr/share/info/${EMACS_SUFFIX}")
X (re "\\\\\`${EPREFIX}/usr/share/info\\\\>"))
X (and path
X ;; move Emacs Info dir before anything else in /usr/share/info
X (let* ((p (cons nil (split-string path ":" t))) (q p))
X (while (and (cdr q) (not (string-match re (cadr q))))
X (setq q (cdr q)))
X (setcdr q (cons dir (delete dir (cdr q))))
X (setq Info-directory-list (prune-directory-list (cdr p)))))))
EOF
elisp-site-file-install "${T}/${SITEFILE}" || die
dodoc README BUGS CONTRIBUTE
if use aqua; then
dodir /Applications/Gentoo
rm -rf "${ED}"/Applications/Gentoo/Emacs${EMACS_SUFFIX#emacs}.app
mv nextstep/Emacs.app \
"${ED}"/Applications/Gentoo/Emacs${EMACS_SUFFIX#emacs}.app || die
fi
DOC_CONTENTS="You can set the version to be started by /usr/bin/emacs
through the Emacs eselect module, which also redirects man and info
pages. Therefore, several Emacs versions can be installed at the
same time. \"man emacs.eselect\" for details.
\\n\\nIf you upgrade from Emacs version 24.2 or earlier, then it is
strongly recommended that you use app-admin/emacs-updater to rebuild
all byte-compiled elisp files of the installed Emacs packages."
use X && DOC_CONTENTS+="\\n\\nYou need to install some fonts for Emacs.
Installing media-fonts/font-adobe-{75,100}dpi on the X server's
machine would satisfy basic Emacs requirements under X11.
See also https://wiki.gentoo.org/wiki/Xft_support_for_GNU_Emacs
for how to enable anti-aliased fonts."
use aqua && DOC_CONTENTS+="\\n\\nEmacs${EMACS_SUFFIX#emacs}.app is in
\"${EPREFIX}/Applications/Gentoo\". You may want to copy or symlink
it into /Applications by yourself."
readme.gentoo_create_doc
}
pkg_preinst() {
# move Info dir file to correct name
local infodir=/usr/share/info/${EMACS_SUFFIX} f
if [[ -f ${ED}${infodir}/dir.orig ]]; then
mv "${ED}"${infodir}/dir{.orig,} || die
elif [[ -d "${ED}"${infodir} ]]; then
# this should not happen in EAPI 4
ewarn "Regenerating Info directory index in ${infodir} ..."
rm -f "${ED}"${infodir}/dir{,.*}
for f in "${ED}"${infodir}/*; do
if [[ ${f##*/} != *-[0-9]* && -e ${f} ]]; then
install-info --info-dir="${ED}"${infodir} "${f}" || die
fi
done
fi
}
pkg_postinst() {
elisp-site-regen
readme.gentoo_print_elog
if use livecd; then
# force an update of the emacs symlink for the livecd/dvd,
# because some microemacs packages set it with USE=livecd
eselect emacs update
elif [[ $(readlink "${EROOT}"/usr/bin/emacs) = ${EMACS_SUFFIX} ]]; then
# refresh symlinks in case any installed files have changed
eselect emacs set ${EMACS_SUFFIX}
else
eselect emacs update ifunset
fi
}
pkg_postrm() {
elisp-site-regen
eselect emacs update ifunset
}

@ -119,11 +119,8 @@ BDEPEND="virtual/pkgconfig
# pax_kernel? ( sys-apps/attr )
if [[ ${PV##*.} = 9999 ]]; then
DEPEND="${DEPEND}
BDEPEND="${BDEPEND}
sys-apps/texinfo"
RDEPEND="${RDEPEND}
!=app-editors/emacs-${PV%.*}*"
fi
EMACS_SUFFIX="${PN/emacs/emacs-${SLOT}}"

@ -1,4 +1,4 @@
# Copyright 1999-2018 Gentoo Foundation
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@ -121,7 +121,7 @@ BDEPEND="virtual/pkgconfig
# pax_kernel? ( sys-apps/attr )
if [[ ${PV##*.} = 9999 ]]; then
DEPEND="${DEPEND}
BDEPEND="${BDEPEND}
sys-apps/texinfo"
fi

@ -121,7 +121,7 @@ BDEPEND="virtual/pkgconfig
# pax_kernel? ( sys-apps/attr )
if [[ ${PV##*.} = 9999 ]]; then
DEPEND="${DEPEND}
BDEPEND="${BDEPEND}
sys-apps/texinfo"
fi

@ -16,7 +16,7 @@ if [[ ${PV} == 9999* ]]; then
else
SRC_URI="https://github.com/vim/vim/archive/v${PV}.tar.gz -> vim-${PV}.tar.gz
https://dev.gentoo.org/~radhermit/vim/vim-8.0.0938-gentoo-patches.tar.bz2"
KEYWORDS="alpha amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ppc64 sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~x86-solaris"
KEYWORDS="alpha amd64 ~arm ~arm64 hppa ia64 ppc ppc64 sparc x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~x86-solaris"
fi
DESCRIPTION="GUI version of the Vim text editor"

@ -1,5 +1,2 @@
DIST neovim-0.3.1.tar.gz 8937900 BLAKE2B 05de31d194a69b9cecd34210ecfe7460968f4255c850b9bb93b8ab8f5721463c434dd9249a43153c6e65584192bbe0a2720a474c5d8b3b73776148179d18943b SHA512 42c541608509dc0335203ee1c008045f0eaeebce8e18dffc554ab22a029da700bba9b8c721bd9d68337ddb4a56f8cf034fad2a3eb88d36baf8295e6648fce506
DIST neovim-0.3.2.tar.gz 9230960 BLAKE2B c9d0ee2f679f411c3ece2aa186e31d0143479f6ec19d4d54c34cd4be519a92e9f213fc821b347a0e3af6817b6ce745cdff523af41d5b558940b76d9df726253b SHA512 1192d9330da3ab543dcb39bdff517637c7a52be558ad07a60de27bbf051432064edc230b46ddd9cdcae006ba1340550128e4d4ced7105f1aab57b13c2c4479ae
DIST neovim-0.3.3.tar.gz 9231632 BLAKE2B 96bffabcc7c7c2edca79f64e51348954b550910d71c55d00dd3d91d9c51a75742e5a4b919701c24c00de1d372a4269b491028e61afcce45375360dc35f3b943e SHA512 2e2910e0dafdff69d2d9f54376c6d7c64e0f172bda02f85281fe6e694e7d81365e682793e454a0ca6f6c1b8a4ed9120bbfe574afa1fd0e6368e06af743d7d147
DIST neovim-0.3.4.tar.gz 9231575 BLAKE2B 92e727264442794ae27642451c90381262f9882e26d9865a2ff6c1bc4060b070ab49cd11194c3a88dafecda5bc1909963b2cc8b382198dc7c117ba056b7a4ebe SHA512 fbf22ccffbb36c082bfe9a66b3d0180a78581102732a44ab7a5417aef517c88b69406491854613a1cf347ddab6fc6e277f959887556d2c0068cf181e4d88c36b
DIST neovim-0.3.7.tar.gz 9231661 BLAKE2B 6eade77f8654bc95170f4c052c5700a6ad42aff920889bf4036e6ff931cdeeabb908aeedb44e68efca3500beb797cf2361e09d85456a2c17431e005a64bafff4 SHA512 1d770a4643a44da65f0a03c90e18e89f337b16ec3eca20dbffa21bcab10c836062ef82974437b64bd766f7b07317cd3dc8e3e72b9d5d0911b1d4f2c528cd20c2

@ -1,94 +0,0 @@
# Copyright 1999-2018 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils xdg-utils
DESCRIPTION="Vim-fork focused on extensibility and agility."
HOMEPAGE="https://neovim.io"
if [[ ${PV} == 9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/neovim/neovim.git"
else
SRC_URI="https://github.com/neovim/neovim/archive/v${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64 ~x86"
fi
LICENSE="Apache-2.0 vim"
SLOT="0"
IUSE="+clipboard +luajit +nvimpager python remote ruby +tui +jemalloc"
CDEPEND=">=dev-libs/libuv-1.2.0:0=
>=dev-libs/msgpack-1.0.0:0=
luajit? ( dev-lang/luajit:2 )
!luajit? (
dev-lang/lua:=
dev-lua/LuaBitOp
)
tui? (
>=dev-libs/libtermkey-0.19
>=dev-libs/unibilium-1.1.1:0=
)
dev-libs/libvterm
dev-lua/lpeg[luajit=]
dev-lua/mpack[luajit=]
jemalloc? ( dev-libs/jemalloc )
net-libs/libnsl"
DEPEND="
${CDEPEND}
dev-util/gperf
virtual/libiconv
virtual/libintl"
RDEPEND="
${CDEPEND}
python? ( dev-python/neovim-python-client )
ruby? ( dev-ruby/neovim-ruby-client )
remote? ( dev-python/neovim-remote )
clipboard? ( || ( x11-misc/xsel x11-misc/xclip ) )"
CMAKE_BUILD_TYPE=Release
src_prepare() {
# use our system vim dir
sed -e '/^# define SYS_VIMRC_FILE/s|$VIM|'"${EPREFIX}"'/etc/vim|' \
-i src/nvim/globals.h || die
# add eclass to bash filetypes
sed -e 's|*.ebuild|*.ebuild,*.eclass|' -i runtime/filetype.vim || die
cmake-utils_src_prepare
}
src_configure() {
local mycmakeargs=(
-DFEAT_TUI=$(usex tui)
-DENABLE_JEMALLOC=$(usex jemalloc)
-DPREFER_LUA=$(usex luajit no yes)
)
cmake-utils_src_configure
}
src_install() {
cmake-utils_src_install
# install a default configuration file
insinto /etc/vim
doins "${FILESDIR}"/sysinit.vim
# conditionally install a symlink for nvimpager
if use nvimpager; then
dosym ../share/nvim/runtime/macros/less.sh /usr/bin/nvimpager
fi
}
pkg_postinst() {
xdg_desktop_database_update
}
pkg_postrm() {
xdg_desktop_database_update
}

@ -1,94 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils xdg-utils
DESCRIPTION="Vim-fork focused on extensibility and agility."
HOMEPAGE="https://neovim.io"
if [[ ${PV} == 9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/neovim/neovim.git"
else
SRC_URI="https://github.com/neovim/neovim/archive/v${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64 ~x86"
fi
LICENSE="Apache-2.0 vim"
SLOT="0"
IUSE="+clipboard +luajit +nvimpager python remote ruby +tui +jemalloc"
CDEPEND=">=dev-libs/libuv-1.2.0:0=
>=dev-libs/msgpack-1.0.0:0=
luajit? ( dev-lang/luajit:2 )
!luajit? (
dev-lang/lua:=
dev-lua/LuaBitOp
)
tui? (
>=dev-libs/libtermkey-0.19
>=dev-libs/unibilium-2.0.0:0=
)
dev-libs/libvterm
dev-lua/lpeg[luajit=]
dev-lua/mpack[luajit=]
jemalloc? ( dev-libs/jemalloc )
net-libs/libnsl"
DEPEND="
${CDEPEND}
dev-util/gperf
virtual/libiconv
virtual/libintl"
RDEPEND="
${CDEPEND}
python? ( dev-python/neovim-python-client )
ruby? ( dev-ruby/neovim-ruby-client )
remote? ( dev-python/neovim-remote )
clipboard? ( || ( x11-misc/xsel x11-misc/xclip ) )"
CMAKE_BUILD_TYPE=Release
src_prepare() {
# use our system vim dir
sed -e '/^# define SYS_VIMRC_FILE/s|$VIM|'"${EPREFIX}"'/etc/vim|' \
-i src/nvim/globals.h || die
# add eclass to bash filetypes
sed -e 's|*.ebuild|*.ebuild,*.eclass|' -i runtime/filetype.vim || die
cmake-utils_src_prepare
}
src_configure() {
local mycmakeargs=(
-DFEAT_TUI=$(usex tui)
-DENABLE_JEMALLOC=$(usex jemalloc)
-DPREFER_LUA=$(usex luajit no yes)
)
cmake-utils_src_configure
}
src_install() {
cmake-utils_src_install
# install a default configuration file
insinto /etc/vim
doins "${FILESDIR}"/sysinit.vim
# conditionally install a symlink for nvimpager
if use nvimpager; then
dosym ../share/nvim/runtime/macros/less.sh /usr/bin/nvimpager
fi
}
pkg_postinst() {
xdg_desktop_database_update
}
pkg_postrm() {
xdg_desktop_database_update
}

@ -1,94 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils xdg-utils
DESCRIPTION="Vim-fork focused on extensibility and agility."
HOMEPAGE="https://neovim.io"
if [[ ${PV} == 9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/neovim/neovim.git"
else
SRC_URI="https://github.com/neovim/neovim/archive/v${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64 ~x86"
fi
LICENSE="Apache-2.0 vim"
SLOT="0"
IUSE="+clipboard +luajit +nvimpager python remote ruby +tui +jemalloc"
CDEPEND=">=dev-libs/libuv-1.2.0:0=
>=dev-libs/msgpack-1.0.0:0=
luajit? ( dev-lang/luajit:2 )
!luajit? (
dev-lang/lua:=
dev-lua/LuaBitOp
)
tui? (
>=dev-libs/libtermkey-0.19
>=dev-libs/unibilium-2.0.0:0=
)
dev-libs/libvterm
dev-lua/lpeg[luajit=]
dev-lua/mpack[luajit=]
jemalloc? ( dev-libs/jemalloc )
net-libs/libnsl"
DEPEND="
${CDEPEND}
dev-util/gperf
virtual/libiconv
virtual/libintl"
RDEPEND="
${CDEPEND}
python? ( dev-python/neovim-python-client )
ruby? ( dev-ruby/neovim-ruby-client )
remote? ( dev-python/neovim-remote )
clipboard? ( || ( x11-misc/xsel x11-misc/xclip ) )"
CMAKE_BUILD_TYPE=Release
src_prepare() {
# use our system vim dir
sed -e '/^# define SYS_VIMRC_FILE/s|$VIM|'"${EPREFIX}"'/etc/vim|' \
-i src/nvim/globals.h || die
# add eclass to bash filetypes
sed -e 's|*.ebuild|*.ebuild,*.eclass|' -i runtime/filetype.vim || die
cmake-utils_src_prepare
}
src_configure() {
local mycmakeargs=(
-DFEAT_TUI=$(usex tui)
-DENABLE_JEMALLOC=$(usex jemalloc)
-DPREFER_LUA=$(usex luajit no yes)
)
cmake-utils_src_configure
}
src_install() {
cmake-utils_src_install
# install a default configuration file
insinto /etc/vim
doins "${FILESDIR}"/sysinit.vim
# conditionally install a symlink for nvimpager
if use nvimpager; then
dosym ../share/nvim/runtime/macros/less.sh /usr/bin/nvimpager
fi
}
pkg_postinst() {
xdg_desktop_database_update
}
pkg_postrm() {
xdg_desktop_database_update
}

@ -1,95 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils xdg-utils
DESCRIPTION="Vim-fork focused on extensibility and agility."
HOMEPAGE="https://neovim.io"
if [[ ${PV} == 9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/neovim/neovim.git"
else
SRC_URI="https://github.com/neovim/neovim/archive/v${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64 ~x86"
fi
LICENSE="Apache-2.0 vim"
SLOT="0"
IUSE="+clipboard +luajit +nvimpager python remote ruby +tui +jemalloc"
CDEPEND="
dev-libs/libuv:0=
dev-libs/msgpack:0=
luajit? ( dev-lang/luajit:2 )
!luajit? (
dev-lang/lua:=
dev-lua/LuaBitOp
)
tui? (
dev-libs/libtermkey
>=dev-libs/unibilium-2.0.0:0=
)
dev-libs/libvterm
dev-lua/lpeg[luajit=]
dev-lua/mpack[luajit=]
jemalloc? ( dev-libs/jemalloc )
net-libs/libnsl"
DEPEND="
${CDEPEND}
dev-util/gperf
virtual/libiconv
virtual/libintl"
RDEPEND="
${CDEPEND}
python? ( dev-python/neovim-python-client )
ruby? ( dev-ruby/neovim-ruby-client )
remote? ( dev-python/neovim-remote )
clipboard? ( || ( x11-misc/xsel x11-misc/xclip ) )"
CMAKE_BUILD_TYPE=Release
src_prepare() {
# use our system vim dir
sed -e '/^# define SYS_VIMRC_FILE/s|$VIM|'"${EPREFIX}"'/etc/vim|' \
-i src/nvim/globals.h || die
# add eclass to bash filetypes
sed -e 's|*.ebuild|*.ebuild,*.eclass|' -i runtime/filetype.vim || die
cmake-utils_src_prepare
}
src_configure() {
local mycmakeargs=(
-DFEAT_TUI=$(usex tui)
-DENABLE_JEMALLOC=$(usex jemalloc)
-DPREFER_LUA=$(usex luajit no yes)
)
cmake-utils_src_configure
}
src_install() {
cmake-utils_src_install
# install a default configuration file
insinto /etc/vim
doins "${FILESDIR}"/sysinit.vim
# conditionally install a symlink for nvimpager
if use nvimpager; then
dosym ../share/nvim/runtime/macros/less.sh /usr/bin/nvimpager
fi
}
pkg_postinst() {
xdg_desktop_database_update
}
pkg_postrm() {
xdg_desktop_database_update
}

@ -12,7 +12,7 @@ if [[ ${PV} == 9999* ]] ; then
else
SRC_URI="https://github.com/vim/vim/archive/v${PV}.tar.gz -> vim-${PV}.tar.gz
https://dev.gentoo.org/~radhermit/vim/vim-8.0.0938-gentoo-patches.tar.bz2"
KEYWORDS="alpha amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ppc64 ~riscv ~s390 ~sh sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-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 ~riscv ~s390 ~sh sparc x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
DESCRIPTION="vim and gvim shared files"

@ -15,7 +15,7 @@ if [[ ${PV} == 9999* ]] ; then
else
SRC_URI="https://github.com/vim/vim/archive/v${PV}.tar.gz -> ${P}.tar.gz
https://dev.gentoo.org/~radhermit/vim/vim-8.0.0938-gentoo-patches.tar.bz2"
KEYWORDS="alpha amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ppc64 ~riscv ~s390 ~sh sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-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 ~riscv ~s390 ~sh sparc x86 ~ppc-aix ~x64-cygwin ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
DESCRIPTION="Vim, an improved vi-style text editor"

Binary file not shown.

@ -1,2 +1,3 @@
DIST buildah-1.8.2.tar.gz 5102103 BLAKE2B 2e19f8af15e5f4a3c6488a44cc0f51592bc6f5201f217ea814daf4b08691f08170debfa2de01d39ae20c6289ed0915383b958cd5e59d8b598d867053ee990af2 SHA512 0cb8dc62c4139a5b500d4021b05344c70c1ec86ff9850bcca87011ad522fe95981d373d73b30b7899959876d78cd15e565e034cf136aa271a72fa4810ff34cae
DIST buildah-1.8.3.tar.gz 5114332 BLAKE2B 55ef5e10e8a2a2b95ef8f8cd28a3ccdb3e734fc3ef64a890900e20a5b8994f92571e2cdec875813203fc4e98a8c4f09656d16bc4c6242194131a25713e054492 SHA512 f875c448f81ef272ad0b7be9c1579d6650983fed4e471095cd645ae1126b49d91ec15b55a072e722205154b681eefc0fb32f5a452d827e875eb0c4779f5d712b
DIST buildah-1.8.4.tar.gz 5122400 BLAKE2B b02a1cac77f5f16ab6cec3a74f11ee94675c717ead21fd791feb4cfbd08dcfb4313a1ee3134d3b9f9d20218935db35e28dab406a9f706ff2f46a2beb1abaa56b SHA512 a316e5e2bea7cded1db089bbc7831c9af69242caa6108c78d63864c012053bda3dc3da5bf70248b2742b2be1ad66aeb59c844558022c20f79236f5b1292d6366
DIST buildah-1.9.0.tar.gz 5123317 BLAKE2B d38c36c2407b3a77a5f738e00ae08c4312945d5c2a4bb930e116e32171ea22c20e0a78e56cce7977844ff0d60306f5446a9c1a117d790ea83cc53e1e83e63417 SHA512 8defe72b267790a6d777eed2a68f89721184eab8df972ef59287e69e1719d1174cb120d6a0c254f8a3963721d34414ec614fb5d3e52fb85a6940c659ee720686

@ -12,7 +12,7 @@ SLOT="0"
IUSE="ostree selinux"
EGO_PN="${HOMEPAGE#*//}"
EGIT_COMMIT="v${PV}"
GIT_COMMIT="e23314b"
GIT_COMMIT="af8fd4a"
SRC_URI="https://${EGO_PN}/archive/${EGIT_COMMIT}.tar.gz -> ${P}.tar.gz"
RDEPEND="app-crypt/gpgme:=
app-emulation/skopeo

@ -0,0 +1,57 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit bash-completion-r1 golang-vcs-snapshot
KEYWORDS="~amd64"
DESCRIPTION="A tool that facilitates building OCI images"
HOMEPAGE="https://github.com/containers/buildah"
LICENSE="Apache-2.0"
SLOT="0"
IUSE="ostree selinux"
EGO_PN="${HOMEPAGE#*//}"
EGIT_COMMIT="v${PV}"
GIT_COMMIT="00eb895"
SRC_URI="https://${EGO_PN}/archive/${EGIT_COMMIT}.tar.gz -> ${P}.tar.gz"
RDEPEND="app-crypt/gpgme:=
app-emulation/skopeo
dev-libs/libgpg-error:=
dev-libs/libassuan:=
sys-fs/lvm2:=
sys-libs/libseccomp:=
selinux? ( sys-libs/libselinux:= )"
DEPEND="${RDEPEND}"
RESTRICT="test"
REQUIRED_USE="!selinux? ( !ostree )"
S="${WORKDIR}/${P}/src/${EGO_PN}"
src_prepare() {
default
sed -e 's|^\(GIT_COMMIT ?= \).*|\1'${GIT_COMMIT}'|' -i Makefile || die
[[ -f ostree_tag.sh ]] || die
use ostree || { echo -e "#!/bin/sh\necho containers_image_ostree_stub" > \
ostree_tag.sh || die; }
[[ -f selinux_tag.sh ]] || die
use selinux || { echo -e "#!/bin/sh\ntrue" > \
selinux_tag.sh || die; }
}
src_compile() {
export -n GOCACHE XDG_CACHE_HOME
GOPATH="${WORKDIR}/${P}" emake all
}
src_install() {
dodoc CHANGELOG.md CONTRIBUTING.md README.md install.md troubleshooting.md
doman docs/*.1
dodoc -r docs/tutorials
dobin ${PN} imgtype
dobashcomp contrib/completions/bash/buildah
}
src_test() {
GOPATH="${WORKDIR}/${P}" emake test-unit
}

@ -1,3 +1,2 @@
DIST FAudio-19.01.tar.gz 885398 BLAKE2B 00b9c05cf67ed540a503937184d1c05faa957765c903473f94fddb0aa467efe79d90eb6f4fc88f61376849126104096e4b1204a6de6a31a74368cb991e8e44c0 SHA512 59447368eae94fc8a4bc1724a826bb4d8d53f65e4e5efa1f68fe0f7ea168f2c139e775975d93b26180b687cfb7419ec04bd2b285142a1fddb59e9575cc53e375
DIST FAudio-19.02.tar.gz 885974 BLAKE2B f8b2402f4005125c583637482a595da9f1a05ffb8c2836498fa5abed1bdae17aa1f1c2c28eb58e0e311bc82f47d48bcb3c626801942f18ecac2eab46c5913e3b SHA512 f3ea82aae5f90bbac286b8e72c1cb6a70e41fdf86f9c1043b465cb242f1232574e59e0ec724f3c317ed4c44a12d4dde87c8b1bc03832e1b011b4e61d9f70da39
DIST FAudio-19.03.tar.gz 886621 BLAKE2B 0cf0b60766d48472c72dc2aa9bbdb9a99db27836f38eccacb4be4bd98cf387b6009998018438e46835a9b9616d426b8a2c9f3c200b377bce2dc9bc18e42b0d37 SHA512 94e3e4f3f023879ef821d657e5a73ac25aab55c7be6a0afe77d75cabe644c9da083ae3c6a240b71af542da53a3eb34804e6a3193a0e619f89fcc20ff7d6ef095
DIST FAudio-19.06.tar.gz 899089 BLAKE2B a59ad9613bcfa71e1fc8be1f2d389f56b8f96430c354b7c7148d1e1e084102b6d8559cd258f3ab6969a4ac93e55ea2397b18dc417857e9ee0f022ea0dae65c0e SHA512 ba3ee18b47d8d85dc39e777c420522349f9873cf1528dd6c266f7254fe27cdb5bb6ab5bcbeab870938b509bfd006590d2380908b7d1e3fd679d2a434ce82eca6

@ -1,95 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
# shellcheck disable=SC2034
EAPI=7
CMAKE_MAKEFILE_GENERATOR="emake"
inherit cmake-multilib virtualx
FAUDIO_PN="FAudio"
FAUDIO_PV="${PV}"
FAUDIO_P="${FAUDIO_PN}-${FAUDIO_PV}"
if [[ "${PV}" == "9999" ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/FNA-XNA/${FAUDIO_PN}.git"
else
SRC_URI="https://github.com/FNA-XNA/${FAUDIO_PN}/archive/${FAUDIO_PV}.tar.gz -> ${FAUDIO_P}.tar.gz"
KEYWORDS="-* ~amd64 ~x86 ~x86-fbsd"
S="${WORKDIR}/${FAUDIO_P}"
fi
DESCRIPTION="FAudio - Accuracy-focused XAudio reimplementation for open platforms"
HOMEPAGE="https://fna-xna.github.io/"
LICENSE="ZLIB"
SLOT="0"
IUSE="+abi_x86_32 +abi_x86_64 debug ffmpeg xnasong test utils"
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 )"
COMMON_DEPEND="
>=media-libs/libsdl2-2.0.9[sound,${MULTILIB_USEDEP}]
ffmpeg? ( media-video/ffmpeg:=[${MULTILIB_USEDEP}] )
"
RDEPEND="${COMMON_DEPEND}
"
DEPEND="${COMMON_DEPEND}
"
multilib_src_configure() {
local mycmakeargs=(
"-DCMAKE_INSTALL_BINDIR=bin"
"-DCMAKE_INSTALL_INCLUDEDIR=include/${FAUDIO_PN}"
"-DCMAKE_INSTALL_LIBDIR=$(get_libdir)"
"-DCMAKE_INSTALL_PREFIX=${EPREFIX%/}/usr"
"-DCMAKE_BUILD_TYPE=$(usex debug Debug Release)"
"-DFORCE_ENABLE_DEBUGCONFIGURATION=$(usex debug ON OFF)"
"-DBUILD_TESTS=$(usex test ON OFF)"
"-DBUILD_UTILS=$(usex utils ON OFF)"
"-DFFMPEG=$(usex ffmpeg ON OFF)"
"-DXNASONG=$(usex xnasong ON OFF)"
)
if use ffmpeg; then
mycmakeargs+=( "-DFFmpeg_LIBRARY_DIRS=${PREFIX%/}/usr/$(get_libdir)" )
fi
cmake-utils_src_configure
}
src_configure() {
cmake-multilib_src_configure
}
multilib_src_compile() {
cmake-utils_src_make
emake -C "${BUILD_DIR}" all
}
multilib_src_install() {
# FIXME: do we want to install the FAudio tools?
cmake-utils_src_install
sed -e "s/%LIB%/$(get_libdir)/g" "${FILESDIR}/faudio.pc" \
> "${T}/faudio.pc" \
|| die "sed failed"
insinto "/usr/$(get_libdir)/pkgconfig"
doins "${T}/faudio.pc"
if use test; then
mkdir -p "${T}/$(get_libdir)"
cp "${BUILD_DIR}/faudio_tests" "${T}/$(get_libdir)/" || die "cp failed"
fi
}
faudio_test() {
XDG_RUNTIME_DIR="/run/user/0" virtx "${T}/$(get_libdir)/faudio_tests"
}
pkg_postinst() {
use test || return
# FIXME: FAudio tests are broken and also don't appear to work
# in the Portage sandbox.
multilib_foreach_abi faudio_test
}

@ -0,0 +1,48 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
if [[ ${PV} == "9999" ]]; then
EGIT_REPO_URI="git://git.osuosl.org/${PN}.git"
EGIT_BRANCH="master"
inherit git-r3 autotools
else
SRC_URI="http://ftp.osuosl.org/pub/osl/ganeti-instance-image/${P}.tar.gz"
fi
DESCRIPTION="Scripts to build out CD or image based VMs using Ganeti"
HOMEPAGE="http://code.osuosl.org/projects/ganeti-image"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
DEPEND=""
RDEPEND="app-arch/dump
>=app-emulation/ganeti-2.15.2-r7
app-emulation/qemu
sys-apps/util-linux
sys-fs/multipath-tools
sys-fs/e2fsprogs"
src_prepare() {
default
if [[ ${PV} == "9999" ]]; then
eautoreconf
fi
}
src_configure() {
econf --with-default-dir=/etc/ganeti
}
src_install() {
emake DESTDIR="${D}" install || die "install failed"
rm -rf "${D}"/usr/share/doc/${PN}
dodoc README.markdown NEWS ChangeLog
insinto /etc/ganeti
newins defaults ${PN}
}

@ -21,7 +21,7 @@ DEPEND=""
RDEPEND="|| ( >=app-emulation/virtualbox-5.0.28 >=app-emulation/virtualbox-bin-5.0.28 )
virtual/opengl
|| (
dev-libs/openssl:1.0.0
dev-libs/openssl-compat:1.0.0
=dev-libs/openssl-1.0*:0
)
dev-libs/hiredis:0/0.14

Binary file not shown.

@ -1,3 +1,2 @@
DIST thinkfan-0.9.3.tar.gz 39527 BLAKE2B e6a6d09493d94b4de9ada20dcc4b0251c5f2c148f7faa7f69c04fe2a279a9cfe253a0ea1a01fe94ed108e8731e2ba01edef5df10dfb887ea961a356dff733854 SHA512 d2a29f9cae636c22b66958f8ec50cb60a162d745c3967257bb5e20cc9e152894d4e8a66f897ffa4e49353eba4a42e3499bb9e554719974284089a46cfc6280d7
DIST thinkfan-1.0.1.tar.gz 77587 BLAKE2B 7a2d4d77be8a9abdafe2cdb8485c92dfe9850ad2309d45d0ac32e8c0e7e6db22ef6c2e16161cccbd6e6147497accc8ec3f5d4467dbe5d2fe6d7fdfd06bb3261f SHA512 61fac9e99f5a2974c5a80e2565956d203baf670dc4b97625389e91fe3fe4d026c07847c10e7d46a4f57914a8156aeea0141570202c0ce2b497f8a1daefa47d6e
DIST thinkfan-1.0.2.tar.gz 77653 BLAKE2B 1b40553380f9b873883f0dc587665f24cd2e07de7a7e743cb9f99a3282f380da2258265a612b1c97d2945fed31aee0d6cbc30ea2a18c0b212e877e7635eda336 SHA512 d9133538096a7c5757f599adfebc8217aa7334a102573d6757f03b5c012a09d600be923930fd9d62f4afa591f5eb7a70a1c328004bddef85494d1a7ce56b648f

@ -1,44 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit cmake-utils readme.gentoo-r1
DESCRIPTION="simple fan control program for thinkpads"
HOMEPAGE="http://thinkfan.sourceforge.net"
SRC_URI="https://github.com/vmatare/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="atasmart nvidia +yaml"
DEPEND="atasmart? ( dev-libs/libatasmart )
yaml? ( dev-cpp/yaml-cpp )"
RDEPEND="${DEPEND}
nvidia? ( x11-drivers/nvidia-drivers )"
PATCHES=( "${FILESDIR}"/${PN}-1.0.1-update-runscript.patch )
DOC_CONTENTS="
Please read the documentation and copy an appropriate
file to /etc/thinkfan.conf.
"
src_configure() {
local mycmakeargs+=(
-DCMAKE_INSTALL_DOCDIR=/usr/share/doc/${PF}
-DUSE_NVML="$(usex nvidia)"
-DUSE_ATASMART="$(usex atasmart)"
-DUSE_YAML="$(usex yaml)"
)
cmake-utils_src_configure
}
src_install() {
cmake-utils_src_install
readme.gentoo_create_doc
}

@ -11,7 +11,7 @@ SRC_URI="https://github.com/vmatare/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~x86"
KEYWORDS="amd64 x86"
IUSE="atasmart nvidia +yaml"
DEPEND="atasmart? ( dev-libs/libatasmart )

Binary file not shown.

@ -1,3 +1,7 @@
DIST dnetc517-linux-amd64.tar.gz 645416 BLAKE2B a6181c82e7bdb8995930b3c93c88dd588f707ea6429e4f7f27961928129423be571f0c63e7aa5d5d9a8e5e3687a8bd54e6dc6835f5317273aa3f99ee863e8320 SHA512 b22b59af2352a95156ea4b584f48d82e4b64080130d922bbb1797b2c62f7c401ec1263f2f0bd57103134f8fc76ef41a7e09d7da083ef0b46c44be4239005c21b
DIST dnetc517-linux-x86-elf-uclibc.tar.gz 676398 BLAKE2B 9edfa3f11b837841b362dd81bdd9a39882b6bd45942f11f6c8ebde4966351a0ea4c003eb27a36c2fe187034571d48a5d851d5931dc6121196f2097a22f9a1c30 SHA512 7b56fa8c6819fd7060612c13c8fb17ca1e949abbca965b7599bb072751acd1d0e95f1a90fb67172c6d406b54e0c52549582489802e538670bdb6d12f8354e2a7
DIST dnetc519b-linux-amd64.tar.gz 648333 BLAKE2B 54d787d5e9a98563bba1a0cc62f70900f0fa39becf6f48a66ae888e0ce0f1f2c64a79fc6c6b3fae724ed244e3f0286dc0f266332d851347b982bffcd1807696f SHA512 ea7899772ee8c5fbfbe96b6ec69b1a3237fe5ae96b17bb7e11e387fb833b471f3cce8809cf3c9987dfe33c7ca7082db560c36898094ace3e547077b7a5afc324
DIST dnetc521-linux-amd64.tar.gz 679350 BLAKE2B 401b83a893111a4b2d07ace93fc642b30ccd41a0273672e496b91d998ce6d38faa08a7ec13ca172d20bf785d010249b87c562b706783c6d3fe3610ef02b214ed SHA512 c5c4d6da4fd1cb6a648553718e708c8d14023d1824298f8070cdc887cbf9559e77c10908d8d9929bc0b48e2215a02c3376c4cf767ad807816abf3eba96650b1d
DIST dnetc521-linux-arm64.tar.gz 629291 BLAKE2B 12554db6c175b828e9e74864955db7e6f54b21408edc6b32a669d52d17465ed45d7985486855a330b295778656579582f208c0e5ecc34f6a2ea195c2ab1fab68 SHA512 cc9c8b76b9d3ada1ed586132c3cc340d2ada55a28d151fb62013aac44dbf13b764dd80498bce1db36536df366497cdc2aa55e761d92cfdd050b701a23336ad80
DIST dnetc521-linux-ppc-uclibc.tar.gz 718697 BLAKE2B 15f8438531b8074c8a56b86500c55b95eb33c62e4271023bab98601fadd3bc3d2afd1ae8562cadf8d724943515032c97a78084ddd12ef30c388456333ec60893 SHA512 31ad8999d262f0820275773f3387b0a9531ffaab662fa557cad504ed48d7e764d43ae198559b44ef9fe00a0a417e1780b327d2f1c4b7951ff760eb54393742e4
DIST dnetc521-linux-x86-elf-uclibc.tar.gz 744639 BLAKE2B 71a317c724b91f17c1e67da63d5da2e04479572c6e8c9e9df16c9a0cf5f1d56622a7d20bd791f46b7baa3147fd18c60c312b16cc311bad2e609945620a843f16 SHA512 9178b0d42989302b82d8c62f978e819f5b30bd6acff60501e947038e655096bed3e3382015b50d53f0f3fa819be22ffbba21419a5175a01dbc449030387629fc

@ -0,0 +1,100 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit user
MAJ_PV=${PV:0:6}
MIN_PV=${PV:7:9}
DESCRIPTION="distributed.net client"
HOMEPAGE="http://www.distributed.net"
SRC_URI_BASE="http://http.distributed.net/pub/dcti/v${MAJ_PV}"
SRC_URI_x86="x86? ( ${SRC_URI_BASE}/dnetc${MIN_PV}-linux-x86-elf-uclibc.tar.gz )"
SRC_URI_arm64="arm64? ( ${SRC_URI_BASE}/dnetc${MIN_PV}-linux-arm64.tar.gz )"
SRC_URI_amd64="amd64? ( ${SRC_URI_BASE}/dnetc${MIN_PV}-linux-amd64.tar.gz )"
SRC_URI_ppc="ppc? ( ${SRC_URI_BASE}/dnetc${MIN_PV}-linux-ppc-uclibc.tar.gz )"
#SRC_URI_sparc="sparc? ( ${SRC_URI_BASE}/dnetc${MIN_PV}-linux-sparc-v7.tar.gz )"
SRC_URI="${SRC_URI_amd64} ${SRC_URI_arm64} ${SRC_URI_ppc} ${SRC_URI_x86} ${SRC_URI_sparc}"
LICENSE="distributed.net GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~arm64 ~ppc ~x86" # sparc not available for this version
IUSE=""
RESTRICT="mirror"
DEPEND=""
RDEPEND="net-dns/bind-tools"
QA_PREBUILT="opt/distributed.net/dnetc"
case $ARCH in
amd64) suffix=amd64 ;;
arm64) suffix=amd64 ;;
ppc) suffix=ppc-elf-uclibc ;;
x86) suffix=x86-elf-uclibc ;;
esac
S="${WORKDIR}/dnetc${MIN_PV:0:3}-linux-${suffix}"
unset suffix
src_prepare() {
#export S="${WORKDIR}/$(getS)"
#echo "${S}"
#cd "${S}"
[[ -x dnetc ]] || die "Name of dnetc directory/binary for this platform undefined"
eapply_user
}
src_install() {
exeinto /opt/distributed.net
doexe dnetc
doman dnetc.1
dodoc docs/CHANGES.txt docs/dnetc.txt docs/readme.*
newinitd "${FILESDIR}"/dnetc.initd dnetc
newconfd "${FILESDIR}"/dnetc.confd dnetc
keepdir /var/spool/dnetc
}
pkg_preinst() {
# This is the upstream-recommended install process
# Flush buffers first, because the new binary might not be able to read
# them.
if [ -e /opt/distributed.net/dnetc ] && [ -e /etc/init.d/dnetc ]; then
einfo "flushing old buffers"
source /etc/conf.d/dnetc
if [ -e /opt/distributed.net/dnetc.ini ]; then
# use ini file
/opt/distributed.net/dnetc -quiet -ini /opt/distributed.net/dnetc.ini -flush
elif [ ! -e /opt/distributed.net/dnetc.ini ] && [ ! -z ${EMAIL} ]; then
# email adress from config
/opt/distributed.net/dnetc -quiet -flush -e ${EMAIL}
fi
einfo "removing old buffer files"
rm -f /opt/distributed.net/buff*
fi
enewgroup dnetc
enewuser dnetc -1 -1 /opt/distributed.net dnetc
}
pkg_postinst() {
chown -Rf dnetc:dnetc /opt/distributed.net
chmod 0555 /opt/distributed.net/dnetc
elog "To run distributed.net client in the background at boot:"
elog " rc-update add dnetc default"
elog ""
elog "Either configure your email address in /etc/conf.d/dnetc"
elog "or create the configuration file /opt/distributed.net/dnetc.ini"
}
pkg_postrm() {
if [ -d /opt/distributed.net ]; then
elog "All files has not been removed from /opt/distributed.net"
fi
}

Binary file not shown.

@ -11,7 +11,7 @@ SRC_URI="http://homebank.free.fr/public/${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
IUSE="+ofx"
KEYWORDS="amd64 ~ppc ~ppc64 x86"
KEYWORDS="amd64 ppc ~ppc64 x86"
RDEPEND=">=dev-libs/glib-2.39
>=net-libs/libsoup-2.26

@ -46,7 +46,7 @@ SRC_URI="
IUSE="gnome java kde"
LICENSE="LGPL-3"
SLOT="0"
KEYWORDS="-* ~amd64 ~x86"
KEYWORDS="-* amd64 ~x86"
RDEPEND="=app-office/${PN/-debug}-${PVR}[gnome=,java=,kde=]"

@ -51,7 +51,7 @@ SRC_URI="
IUSE="gnome java kde"
LICENSE="LGPL-3"
SLOT="0"
KEYWORDS="-* ~amd64 ~x86"
KEYWORDS="-* amd64 ~x86"
BIN_COMMON_DEPEND="
app-text/hunspell:0/1.6
@ -97,6 +97,7 @@ COMMON_DEPEND="
app-text/mythes
>=dev-cpp/clucene-2.3.3.4-r2
=dev-cpp/libcmis-0.5*
dev-db/mariadb-connector-c
dev-db/unixODBC
dev-lang/perl
dev-libs/boost:=[nls]

Binary file not shown.

@ -1,2 +1,3 @@
DIST TexMaths-0.46.1.oxt 1206650 BLAKE2B 649596405fc0eef78bde4e98eba833321cc88f2debe67bc4c287008447de8db146c32a0e03a3c80aa00f360992f05239b9eeccb942d6150f2c295fa82eb42972 SHA512 6f0409862bd45c3abf78496e611e82cacd38181e773d852586800733ddd64f0c2be3edeb6a87251328dc8183f8ae93e4a1666021b5ad89babf2534294710a9fa
DIST TexMaths-0.47.oxt 665591 BLAKE2B 23aa4804be0ab37e2a15ef4a2a287cd9105ad3bfeb772d4d3a63908543d5facbdc0500b9b83ab69b8b9e4237b5a278278addbb46c630dffe4a439613a31f0fa8 SHA512 cb8a06e37d1ebac32c19286b958705588dd10dcc3a09b75ba52e5c81d269391822372cec490c77e9b3fc54b0e7f29f24962e8d55c7a87735782a042661229dd1
DIST TexMaths-0.48.oxt 666714 BLAKE2B 63d811ec60fde66faaaa0ac6d41760eee87df2a1e9cfa023b5f3177bc845a693b54d99bb56fbcbfda64a9ec23ed342e11fa7af0be4241dadb267e06cf6543413 SHA512 29e42fd8fe75d1f14bec7fa0eaf531877d50720c8240a144a1cc3a47ee1feb4ba4b163672deb8e0d0b5ecf354370116d31a1ea3bb013a188122433f41e48cd0b

@ -0,0 +1,26 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
MY_P="TexMaths-${PV}"
OFFICE_EXTENSIONS=(
"${MY_P}.oxt"
)
inherit office-ext-r1
DESCRIPTION="LaTeX Equation Editor for LibreOffice"
HOMEPAGE="http://roland65.free.fr/texmaths/"
SRC_URI="mirror://sourceforge/${PN}/${MY_P}.oxt"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
RDEPEND="
app-text/dvisvgm
virtual/tex-base
"

Binary file not shown.

@ -15,7 +15,7 @@ if [[ ${PV} == *9999 ]]; then
EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/portage-utils.git"
else
SRC_URI="https://dev.gentoo.org/~grobian/distfiles/${P}.tar.xz"
KEYWORDS="~amd64 ~hppa ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
KEYWORDS="~amd64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
fi
RDEPEND="

@ -1,3 +1,2 @@
DIST unsymlink-lib-13.tar.gz 8736 BLAKE2B 5b44112299232185f3f7a5d88057caa7e9161ca03a3e79bebd9dbf70a61ddde255d3a24679b9004cc572fedcfc24ffeb42693319e5dfa1f8371f8fed1408b15d SHA512 c87676b80259f2a20fde257e2b090380c3b04be1542a5a92832487327b8d1eb737059a6e6898f713fa378b792e23d2896280b94cb00d7961a0beba81cd6b3bd2
DIST unsymlink-lib-14.tar.gz 10089 BLAKE2B 24252eb31a0a0fe83a260e8eee76d42c473d76dbebe4d2fd604d1ab663ea7439da4c03dd0b953efa30e0d74d654101b7a0264db1da50de826c5a5f4ae79f3ff0 SHA512 ab3ffcbc7cdcac98068a6e3c86e71cb472cff67aed1ddc570701ed6c34fa17e04d84a13bf5fb2696aeff0f8338b2464d1e06ce829ffc693011c51481ecba2be8
DIST unsymlink-lib-15.tar.gz 10145 BLAKE2B 500b78a84cd555319952ce6420af012354952ebd83983db121f1a48ee34d5c2ce9a9f56ce635d6f77eb38058b79d42cf94d2e421414095c188949db523aacbe0 SHA512 37b8cc4eb7b787a1ccc97750df9fcd4516c2c4ac110c5191b4be3999b1eb994ee567e0f4387aaafe243a745efa61c0d48d78b7f9a4a58bb7f896ccd7bdce03a7
DIST unsymlink-lib-16.tar.gz 10139 BLAKE2B 8e43fe85747d97fa44ae30cf6f276e8e5557141004c0c6ec5f1b998c0f5c121e9fb6bb3f7d711d11ca962c703caa7dc6014ddfde2c6ccf16807264a132e37940 SHA512 0c5ebab3622aad1f8a02c2530bfb3f6d48c0ac9744fdde94e8a9b151c5773d10ae642c122642d5f7e2bd442d5969863d8f5f0586c8ed484fa22ac42143a06417

@ -1,25 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PYTHON_COMPAT=( python{2_7,3_{5,6}} )
inherit python-single-r1
DESCRIPTION="Convert your system to SYMLINK_LIB=no"
HOMEPAGE="https://github.com/mgorny/unsymlink-lib"
SRC_URI="https://github.com/mgorny/unsymlink-lib/archive/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="BSD-2"
SLOT="0"
KEYWORDS="amd64"
IUSE=""
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
RDEPEND="${PYTHON_DEPS}
sys-apps/portage[${PYTHON_USEDEP}]"
src_install() {
python_doscript unsymlink-lib
dodoc README
}

Binary file not shown.

@ -22,7 +22,6 @@ DIST libc-0.2.42.crate 336080 BLAKE2B 0de0726bfb00ff42d67abf06efa26c1a4f8132b29b
DIST libsqlite3-sys-0.10.0.crate 2175426 BLAKE2B dc7cbbcb632e2de1e8fcd6372cb0a82ed044db1d8634fa88b4294efb01470528fc86cece8c1ba6c4800a97c39d78bebb4b858efaf7c3c74510f5cf675ca2a1f0 SHA512 df030105952e8e0ca9def15d914a2eb7fb81754c85465788f7a3df5626b647d4af7f93b11f2f6d6e3dba286fd101c779dd51de7f2732084ba9542120cbc0e299
DIST linked-hash-map-0.4.2.crate 15980 BLAKE2B f31e0dc6f6bb3af355981491e42ce70ac91cbcf059c3d7da8ad2160c40c379bf6d10aab1fdc8400df4497e30ae8dc8c37149ec23084b589fb9a17b8dcf7fbdb4 SHA512 e9ca0dcf09338b8bf2e669eae241b1d07a08c430b2c1fb8adde9a79218aac8f0ad3a13d515202fbf7d0d6f3607e64c4fb3b8b9fe9190655897ae7aeeeb91dbce
DIST lru-cache-0.1.1.crate 8645 BLAKE2B 027f7051ce930701b97017638f2091efef0b3be330fe1cf534d31c7040c8eb55d73d8e397644584d642e370ed2c109f6df61a6da020f6df5f5756cfccbdf9216 SHA512 f397be62edf59bcb36767e338427684274c3ec900d96f92c75859c61ae52f78c42a551bb298e256b76f65bc7b5765c453a07baa61dcb01bfb93ca8a41612b521
DIST mcfly-0.3.3.tar.gz 242714 BLAKE2B 05f038bfb502d0dd6938c6ecf2a8f36673a26e7bebd8b8f543f12c500db0b1b431c476384641fc0d66efc9fd537a2c94c0ef41bf26d1b2f78f3ddd551e94b51c SHA512 b68484256421f0e8f11326cc4e321fdc0bdccb9fb01e919c143338ec315c0a69c90e2d9977265096a34d3db5f2709663579e851f41b637903e3d12ca92959631
DIST mcfly-0.3.4.tar.gz 193516 BLAKE2B e30e438460788ab385924e729d1bd1a00eb6642eaa2f09d378ad20431218dee56153ac8a22c310b733202ac1929dc4e8c800ad480c66cfe3a21f96a79cff43b6 SHA512 49a69c6b4af6814333860262ced4d0d83703d397f5c2f46f9d4351eec9def91c0eff39069982ae67c8fbd5371d562e9e6afbb778472d83dee13aace62f456bf2
DIST memchr-2.0.1.crate 9858 BLAKE2B ccf5530245bdcf1b892b98858d1cfd8cdeec3765422f6d1503bfaf3e48744dabfbc1767212b310d1951f1594ec3d4ca09447ca72782ed272cc396113a7f9fef8 SHA512 50daeb73062c30b244c8fec965ff0c69c29571022a9228dafd1ed397164956e39fbe260b8adce33522b5cedcd7f9135500ac45d6bc0b5e72bf9e89ebea0954d1
DIST nodrop-0.1.12.crate 3033 BLAKE2B 69792f5ac9722dc570749795b6e0e6c6373c44614bf5861846af08d426d18e5929ad3c5b957adf3480e8c77444cec9d33b3e8b272eea9c7200f0cedf0d78e7ac SHA512 8f2856a6467715565ea5b3be181fc957f6cbc885797c15582ef5be5a71089201292ea58f94877496737dfd427b19523228fa4bde49d9413a8399d2e7888b99aa

@ -1,94 +0,0 @@
# Copyright 2017-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
CRATES="
ansi_term-0.11.0
argon2rs-0.2.5
arrayvec-0.4.7
atty-0.2.10
backtrace-0.3.9
backtrace-sys-0.1.24
bitflags-1.0.3
blake2-rfc-0.2.18
cc-1.0.18
cfg-if-0.1.5
clap-2.32.0
cloudabi-0.0.3
constant_time_eq-0.1.3
csv-1.0.1
csv-core-0.1.4
dirs-1.0.4
failure-0.1.2
failure_derive-0.1.2
fuchsia-zircon-0.3.3
fuchsia-zircon-sys-0.3.3
libc-0.2.42
libsqlite3-sys-0.10.0
linked-hash-map-0.4.2
lru-cache-0.1.1
memchr-2.0.1
nodrop-0.1.12
pkg-config-0.3.11
proc-macro2-0.4.20
quote-0.6.8
rand-0.4.3
rand-0.5.5
rand_core-0.2.1
redox_syscall-0.1.40
redox_termios-0.1.1
redox_users-0.2.0
relative-path-0.4.0
rusqlite-0.15.0
rustc-demangle-0.1.9
scoped_threadpool-0.1.9
serde-1.0.75
shellexpand-1.0.0
strsim-0.7.0
syn-0.14.9
synstructure-0.9.0
termion-1.5.1
textwrap-0.10.0
time-0.1.40
unicode-segmentation-1.2.1
unicode-width-0.1.5
unicode-xid-0.1.0
vcpkg-0.2.4
vec_map-0.8.1
winapi-0.3.5
winapi-i686-pc-windows-gnu-0.4.0
winapi-x86_64-pc-windows-gnu-0.4.0
"
inherit cargo
DESCRIPTION="Context-aware bash history search replacement (crtl-r)"
HOMEPAGE="https://github.com/cantino/mcfly"
SRC_URI="https://github.com/cantino/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz
$(cargo_crate_uris ${CRATES})"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"
DEPEND=""
RDEPEND=""
src_install() {
cargo_src_install --path=.
insinto "/usr/share/${PN}"
doins "${PN}.bash"
einstalldocs
}
pkg_postinst() {
local p="/usr/share/${PN}/${PN}.bash"
elog "To start using ${PN}"
elog "Add the following to your ~/.bashrc"
elog
elog "[[ -f ${p} ]] && source ${p}"
}

Binary file not shown.

@ -1,56 +1,34 @@
DIST aho-corasick-0.6.8.crate 26786 BLAKE2B 877bac172514332ef3c607fa3c9b4708822543f69091b3151d31d9297306dbcb0b6ce9cf5ba02f3c08f5baff337e3525ada8f22477770fd6aa12cce428694a36 SHA512 1adbce716a3082c3fcd3514c49af3872d926df14044767266707862c0ad7ee22848a6ce99903003c04a3e8f8cd91b38ec8ca5d4a2c9031bfec4c93cf71c15556
DIST aho-corasick-0.7.3.crate 55093 BLAKE2B 16dfd6505ac34c1b0351c736a913852a354da64177fbf8fabf35212a4deea087150ed7e558787061da1e71c995e3c876c155eb1c629865cc282ab8aee06c9539 SHA512 4250dc8fa38ad74e0c25375744f34eb06ff3bddbf16d6b4d757a9053ca16c3945d15c8f9deb11ea55d30b6d1c1744c4bccc388a4413b723a429445bf5ef3ffa9
DIST ansi_term-0.11.0.crate 17087 BLAKE2B 9bd35c045a01ce4c6c4a5db1b4f15e9412bb97426eec19d4421dffbec633de8d13452c13c1dc1b30998690b78d7ed38311aca700087f13a81f66bd1d5d7300c4 SHA512 a637466a380748f939b3af090b8c0333f35581925bc03f4dda9b3f95d338836403cf5487ae3af9ff68f8245a837f8ab061aabe57a126a6a2c20f2e972c77d1fa
DIST atty-0.2.11.crate 5916 BLAKE2B e502c23faaa9dd27cc5865b68a721b0403071edb483fca0c745707f4c0ca1b1787b5677b2d8ad7f327b8f5588ba784126ce78496c1db54f7ca4ce0ccea669499 SHA512 9d6417dc1e8abdb4969418525b36c451274fd76769adb57bef9875ef62ef521c50d58626ebc4f96d2bea32cbadb6999fd67653b570293d7253b403b6d0736c79
DIST bitflags-1.0.4.crate 15282 BLAKE2B 63f5feb47460c344983cef8822804b1c4ac2f3adfffcf206df2b05fafb9c7bfd73986721cde46705a3e4a0dc72a40683e4d369f2339adfc1b55208bad1766875 SHA512 81850d2be62eabb8486024ab263da67e6eb8ebfa732cac3a5d46a9186c564b2065cba15fa3da468bbd26eaf2b67038680e5de19d5dd99d78f60dae8a1776c8de
DIST cc-1.0.25.crate 43191 BLAKE2B 2f715c36150ea81406ac34224ebc5e0b95ba1bc5f80d36e78af6e6f4027521bd5e163c3ff0f08dac8b0791b797e1498c8a1151dfbc72a8a8008546e0b44ecf83 SHA512 0ae0d47c9ceb67aa0ec25b7b98ab4d378bd7a58fb7bbcd9bcc804a0deadcfae904f9353c218d63b8e7046b388c67d5316248accf1f8b69822c0f58ff465652a3
DIST cc-1.0.37.crate 44499 BLAKE2B d12551225fc4e20691a09fecc8a2a487090ce10ad7fe64b385cf54b74a124cf737aa31966f82d9a68e1a932dccb4ec495eb32cdb4dc808c985384fd0fa4b6950 SHA512 85cf4679d16df14a815563c459227ae85206eb79826099fcbd5f602fdfdc052f36237916a842d65d9a5ab57c559c18e645bb219422d85aa3690c11c0a8dcc92c
DIST cfg-if-0.1.6.crate 7411 BLAKE2B 0a19f5afaa89acfa7877e06e747c1e73af8b8a9886c97a803fc3d61d075b43f3fee6089c67ed28efe70aaf4082fc21dd5b24ea514fb1d761ba3d939dad496fee SHA512 e393816f659bb5b1e64ebc72a4b6e3e673afd00cba302c3c92c6f2e98db341a29197f6cf413107e569175a86aad85e74a93e2cd3a9fa9fa2d1b70b01c3fcf378
DIST clap-2.32.0.crate 196073 BLAKE2B c262241a3ad1d0f944467f4ea9884ca3dc05b5e05656fd7b73700e0daeec035c07a5d06316cc1273e37f74f2c00429b0ee99da298804dc4deff9a252ca56ce07 SHA512 ee2a66cec0d867d73fce35c055bcac77cc3ea9537b355be04be3ee17ddabefebfe3649cbdfc30ea356c54cf9f066369540eac4f5dc67e60cdadc9c66be014ef0
DIST clap-2.33.0.crate 196458 BLAKE2B 3bb62d817afc77b421a6282746b9b61367d224de6b614c7ed66bde452ce1046728077dab3368a46635b5c74d82ba3196586d87c0201478ce5b89638910dadb1a SHA512 f1075031414d48e4340bfe308904a95a31b72460724773c52a0bc8c004e625a04c904a39fc5420cb8c26a633321f9b5f4f69019c7aae5ed89900b63ed8c21a91
DIST fblog-1.2.0.crate 176759 BLAKE2B bba1157f78fa457ad9c091b7f7ad3db5e681e669676976c8ffec142a40f50d2feb0eef68a6e33850883715d2825561f12d842b5f8d88c42149dd5c8cd1b10e83 SHA512 bbdb8ccf29d0499e0df8b0bb187888d46e278f7c57a4a0224c4b055a74159030a50c497abd9a406b35327e9ac18114b9c24ad0d8a18fbc61e2ab9c9a02e8ca4b
DIST fblog-1.3.1.crate 176956 BLAKE2B 71ade0f0327ba9ce97de33c83a1120c578e7dc47ee5fdfbf3ff0d10aac8cf9a0d65cc786c61152813ba4b5a1b19993a7098a5ad1a225fa3fcdc1e1f8e4cacc42 SHA512 1ed97d34d267a1f5b75086ee41687cf3ef66efdc63bb613df76b18271cd597cba4a7087237ce134f21f7a71cb9644a89032b81511d4c365aae60b7a6c07293bd
DIST hlua-0.4.1.crate 30771 BLAKE2B b2b5b39f1a686d57fdfc54d97badd4b612913518da85cf901acf3f18cebaa7c8af8a919f659ccfa47f3eebe2827b742069f63167484f6f62274c07638a548f6e SHA512 992fa3236d19906bbb0dfa1054e89e2f78fa47e858f3cf7b2a6aeb3c6c031c49084115e18640e6fe105535a3fd124467b9f61783aedc5b9c2e670d2fe326280d
DIST itoa-0.4.3.crate 11061 BLAKE2B 76ab02d37c62453ddfee00788ed83805c3c57a66120fcd266401806c005bb55c00b90e074a39a0cdf99d8018181c5bd3f7c3a4fffcefcdc762e19191f0a362e6 SHA512 da1d1c988c2c81f37de8d048ca8f8fb8787c48c34e815dc64616368cb787990ae0255cf1a3259f87ad02964c9b3e1e20c759072442c18c7d32db1deac11b52c1
DIST itoa-0.4.4.crate 11147 BLAKE2B bb6f1caf1e58dc313bd3cfa2cf81252cb2ebc15e1f4c9adfcdedf46c5fa79811d5b0cbd58f1e91d1f62bf85d7b941b0dba535814fb43b5b70a38db791b45717c SHA512 f5e04bd908457e7592243ce64a99c5283428b767f4cc17d77946770411b06fccb0250625263c3e84a02a018ea7e8a0e4216e1929a71988bab8e1dbf603d3801d
DIST lazy_static-1.1.0.crate 12317 BLAKE2B 18c1c0312bc9b7835cef8a35797421be17a706f21a9dcb174527807c7617987fc165f1f99b6c7c665099ff90ab022b0aa4727e7764adc3dd23eb70245135cb6c SHA512 82df91ddf79e2c6e46cda92d6dc8afe20d428f40940a16a352db3c3482ec21ec4b5147bf723dd0b16320ebe0fea489d715671c7fecaf8d0d7982edad3b6919c5
DIST lazy_static-1.3.0.crate 10616 BLAKE2B caa2af77f69c96b5f35dbb2aad7e73784544e6baa5e1fcc2272738fcd3d5f0576480c8169cdddc665a953eb9b6b7ddeb69e93cfa60401458afbe783fff82d1b1 SHA512 08288790139876765b6d4a5988f47fd2a4bfc77c2f2406ad44e64920a471b5655c7f54cb197e5a40c29ee8b42aecbbefaac2b6f4a7dd2b5e24dd92c46cb9b822
DIST libc-0.2.43.crate 353810 BLAKE2B 909f92f7014f33404f0525bed202575c7410d19b2383c48faf760c601f88bbd2c61b2b57550d35443483598bd9d213e1f20c2d34ba9619fec2c38c0748c3654d SHA512 d53b9fc460c68ed77b9c1a23c093c927125c0946b5231c343cf239e706d859af42efc2c7a4b95fecb46ab6ea9dd8473f7de308176a7dbab18e220246c5a7a8fe
DIST libc-0.2.54.crate 401259 BLAKE2B 6fe5f258837fb21af63b445b2679d3d33a498dd10c7676f30df4a95917358f48995461e41b1ac4c944c079ae99edbce77667e68ce963a7447bf1d35a579e3ee0 SHA512 46f0263b227b107aedbd3c4171d8b3fe60ea9c2413ba9fc4cf3f4f8b92090b7aeec630b687ff55ae4507ff44144dad393a3912c6fc81f8864e630c0f15196cb8
DIST lua52-sys-0.1.2.crate 156154 BLAKE2B 8a6ad1d9edd6ad51febf8ed44b315f8a9578ccfb57408d8247a3f161b62c3c1403fe105963c60b8c89aa210ba03af6384e00d01b480dc16060a648360921f275 SHA512 5318ddcd1d78c40cada7cc64027684f448566257f3c4b957e9dd00b163dab16a8555782de961e500ace3b093ec1e2c9cc04fc6769d7b1e5350d8758028a3056f
DIST maplit-1.0.1.crate 8590 BLAKE2B 6f673c6ec08df4e239558ac6df9ee5cfb5b9e9af5cd9ac9452ef9e136400d415b9b41aa4ba4b4e6f1ddadbb9d42c64e7ca7496b25415ae19bb2283fb2d148e06 SHA512 8cb6d865e4a3e73d5af5e41bd48e7f971f1a361a5ac7999f915bbd7156d5a90caa07c4ae82d428217b12a6736c362fc64dcafc757b4e7fb66f645cfddc11b175
DIST memchr-2.1.0.crate 21479 BLAKE2B ca97d105cc780f2a22eb1eb7d6bf6755f012b1d15b5c55cffb9a63f3faaf48b5285cc7b4edbdb933c4e81565da163b325a4d570aee5cb479496d8b74c3d52d8e SHA512 6de3056b5fcdf08fcfda34be710d2f4ea326f056450a78a4fd096e5742cc40662d3003f3ef6ced26687dcee7591f5a8323d14df2cc286d732b1b22f05424c476
DIST memchr-2.2.0.crate 20939 BLAKE2B 224963d641cf2bcad4b32699c9673c81d730f714f2df18878ce4ed78c816d38a2050dce11f9b3a529d45456e16027461bcfef9d5f0e08f7a70175a74e61b0131 SHA512 19bb5fe9c4ff471e2f8cba0e3be3ebb715f0eaf3d9c012c05833e78243d8baa6b98e14eb4c9a900caca48aa539483972f4ff8e5a47aec5141f96f3f23fc24088
DIST numtoa-0.1.0.crate 8999 BLAKE2B 6a8cbf17458227fa87bdd6a35404e09afc092a1ea45d68c6c035e08a9d344fdb356b1bc7b52239dd6354ed9094e9338ccac599542bd7f0caf167ab8d17ad5fa7 SHA512 41b5c774048592c5867fba217c85d4ece4540e0f3ab0eea7dd1a6af340ba46dae42bbca62ea7fe3afdb258660f39a3d3082264c99dea67d3d1ae178d00a01354
DIST pkg-config-0.3.14.crate 13565 BLAKE2B bc457c2bee4034e7b5a5303bddf078e0b3e52018eb7513c5fa610ec9b272b95fab6cbbe35281e86bf0f97883526d91dcf8c156ea83e7dc23da0924a395b6c811 SHA512 bf120f0694f44d7b83b431eb28fe14ef3aca4d08ae0c2c9edbf8f184c145ba3faa479a6ab25e2d7e9f9d9f2d9a3fc21674fd4ddfe88bcc4fadad40bd8285656d
DIST redox_syscall-0.1.40.crate 14745 BLAKE2B c63cf49985accd6b6b54291aff7a7950ed3bd862b7833b19d56e8f350bc2772f427bd6d83da9f6b603622008e90cabb2801cd70ebdb3343fdac020e6b4344901 SHA512 86e74bd8bd4fa12eb8d667cc91ab55df573c0a466c7786af76eefe70f7c294db5a307538089e2e3de2d0bbeee5c1691327020cd0eeacd9d6ab95048eea88b012
DIST redox_syscall-0.1.54.crate 15668 BLAKE2B 2da177fdb698073829b29023e6cd0a2f422ad1cf1ac359b37d3f5cf4c12f6334eb241bd313fde0236afced49714af92469919d62119ad4ddc49448ab5d9a2589 SHA512 38ee15c2fa470428329b3888fef1f1b5bc57ffae96b6ec505fc051f33a8da86512afddfeb6966cb2342382a5cbccb624a825767d3492b3d6d21d6f8e97e57e9e
DIST redox_termios-0.1.1.crate 3227 BLAKE2B 0b109d34e942735e804dd3da2a9639506e8bf6eb5b1f69ae021b115b0b75ae5159e8457abdf647dabfc19d5119cd3a44b8966635d7862cc66a8a997e4468e1ab SHA512 201d051900e919e2c6c6769ef252e51979d90133df16b6605e2a2f424cfb2e6e505e21add75ef5854fe5e0cab1ed1f1c1451010f072ae4bc8703c585a4323981
DIST regex-1.0.5.crate 245770 BLAKE2B 2bb5dcf7778ff6e6316f80a028e9e0df34d77660dc1fb21250238de250335ea2546050b0c56c077c4e64788a0fd2b27f7ea6de639feb2b99590fe9e8a2d32e1b SHA512 a4ddc78fcae0a2b3c0e041382bc8c85a216ff380212762459637934c863782445cd289f5cd60c2a923ea9161f4dad9891210fe6a86cd6bbc8db8abd98ead34ce
DIST regex-1.1.6.crate 243429 BLAKE2B a41cf5b9fa83a7fd4e0a18b15d30f9faacc36267ab0546927061323427eabf4b66893a487f5f59043226d04b700e5ccdd77b47df0219562b6a6615453f271ffe SHA512 f2c039ea729f8360f086b83a8f3da4966932d9bf252ebdbd2058d0249afe997c08c2065efb597e88b55266a18fbe44aa61c67f49ec5047dc6a5bff310f04c32e
DIST regex-syntax-0.6.2.crate 238572 BLAKE2B 0fcd5a6b20260a2dbd8f4dc611bb8ad8f0eb747ab4ac88682515bbbdeefba5ab149301da4e86e28ccef0fabca7f75258037613ba770b6c45d6024c63bd38f406 SHA512 87ce094b8cf61dd8c026b983199728b8eab876766580d3a8074aee780c8f4f6fc0777f1060652f843e87ba7ed21905bdbcac411f736ff8ae0943900d71f6d068
DIST regex-syntax-0.6.6.crate 273068 BLAKE2B 283806a4fc1f0656d2984e8d970ef1db515a56ec08573e397fc342e6f61b6534941530a0ba7fbea69d3817a043dc110b11322ec14b50ce59c2976deb6a66e393 SHA512 5b21640438443394631d28ed1ee391e82bf8b2afc0b3cdbf67f33319064ef4771dc250dfc555d7ff0fb453da3b71e30caebb37ca5c0be446cc40726228c51b76
DIST ryu-0.2.6.crate 39911 BLAKE2B 3dda01a1da474c106d36f63dbc762f5b7eb37e5b0c545bcc4cc992ebabaf02e0649cbbb27f81971cd4c27cc51453f4981eac869768a0cdb31ece3a68a6f8976d SHA512 fa7596d53f3a16673df016aa75a4cc7a637456db595daeb9e4a0a393c7ab7d18b669bcd2886f65a4421897c0261ac57ff85d9c452772e172a4bb6c11b61a8f1f
DIST ryu-0.2.8.crate 42798 BLAKE2B 393eba320c417af8d2cc23f5fc2874d7813fc3cd4804f7cba1d374f073f74bda4de8208544f30a5650d21cccad28611c8ab2bbdce15ba63b88d6b17100ac5ea7 SHA512 15a17fa06cb971847386013b7bc80e0483bb30f62062ac1e3200d588cb52771a7d34cdd74aba51de46341d303bd29065cf1f8cdcc17c23576cfadaefe63384b4
DIST serde-1.0.80.crate 73057 BLAKE2B 13a4a49db02b91eba4ff731a2cdbadca0998d46d4f8781d8a2b134e1db0298d3aad4239590e753b6c1f79838754fbd6715279ee0c33425bece03e683e578b079 SHA512 0606758eb1f29310fb2863e1b22c554d9ff290af9365787fd7d0bd76217c81ed9dbd95f3b55c782293db38127dd272368fb59e3b1b9a1e2bf053d69c9ca3abe9
DIST serde-1.0.91.crate 71696 BLAKE2B d281605205a041ee0aae9755bcdb10951fd788b57a8f415628580e520950c98cc0edf0761812ed31a818f0d3858512c88faaaca49d16bb9bd72b187544e85c98 SHA512 8a335e214cddd1e1602d6bf0c01dfc5f19276154d846bde97f5a06914e8558b75bcd7eb8cee3273ed255314bbbee6a05f1f4ccaebd45bc5cc16a18c90e8635f3
DIST serde_json-1.0.32.crate 69507 BLAKE2B 943e59250dbafdecc4c55709105259ec2f51737290ecdd25d197329eb5c2ef618dcff155e38d19e29662ac13b9f6500fc04fdfcb0d18c8e2a87545e075f77b3c SHA512 31add4ee25db06aa61f4b94ddb57a54c38ea734de01bf91d159ecdaa0351265837336fdec7886e9d5b1056106a6d04acbecdd39f57e5f2a96642d462ce3a4c13
DIST serde_json-1.0.39.crate 69621 BLAKE2B 9eaa881f9a16d1895d2bc6f3aff3d6febd155d6ceff3c383968d0520d0f28dfa6fa57f2edd10c02eeb8448e2d87287d2cc04ee99f2c0bf96a60970c49aca14a9 SHA512 7180e5deb60e196f6b1ba3ac2a1bad6cea59d29f65fa7fb9258beb3d7012d6f3ea624e21fbb17868f5a21224f93b3f7b24875a94d50ba0d05e5b8d2aef632036
DIST strsim-0.7.0.crate 8435 BLAKE2B 6869075bc3949fbdec1b74548b816560d1bf3759ba4c3e972a84f885e6732edd25596d75a4b6f6b85d93821f559757d096cb5f0b0eb04dabd8bb974d214f3188 SHA512 3f92df0f444129b16fbb15c533b7bc1d6f18970b487b57345f74747fb7f41e3dc0cb61255712e94d419a5777b8f6a9cdf1a716718698c479eb98dfb6464d1983
DIST strsim-0.8.0.crate 9309 BLAKE2B 40a8be506c43ee1ffe006ddc7dee98c3d418bdd205d57b78f5d1e4c9312feb57e1eaf952e02d92d4e0932db240c6fba45beb06ea8c4fc6de1cf1faa8b6a3a939 SHA512 1d55a8d946cd55f5f37d06aea536549ded95739fa58c0f2da285a0041154c181f663682bdcac643aa198b3e762d694a04f058db985c62ebe22b5c16327ba6d34
DIST termion-1.5.1.crate 20659 BLAKE2B 5b4291c2c26a074c16eac2e7bcb40467380181bac69c941e5c958059dc239cbbfd74872d9bd3da65245d010f9fc39804c43dc96f4caab2499b021cf35977a6b0 SHA512 1d1536f08600c7c1f414b4579a1a6e7eff91f4c105504125118d3cadf71c7886a352d1c5f7e07f3d7c28aa8b4752f07b51eddb4d9adc6a9286f7b6bade2bec76
DIST termion-1.5.2.crate 22076 BLAKE2B c4a49c9f8bc28f98d6b99109a6eb824b28cb58badcf3254506cd85bcc61026d900cc3fd95c29971953ba6c0979daaa5de33294e7745b816badba912c5c889d41 SHA512 573432550daf6b9edf60783a056df7f1b40ac51585194c8a6181a7b21b22a9d95d9389b3dbf90a050dbacc8988e7b1bbb189756fb5444e11cabd06b3d6c0119b
DIST textwrap-0.10.0.crate 15986 BLAKE2B bcbd40fe4c8322e459c505e0f175b5b088322c33ba56d8c4b294788950681c2407ba08fae2c15711f8f0d5e1f0afed38f82deaffe1c2b16a4f4ab14723b71bb4 SHA512 cb50cc73f3f5ab704ef9e6d526b751f7e66de213fa534206e5b4e9da829f19aedda9f23f262f865fdb3247c703aeaa87f38099f6c575d1961ec923d62a9b2293
DIST textwrap-0.11.0.crate 17322 BLAKE2B 257428908342774593bbd3528fcdae710712ff54e8a711393a24356d8ba0e16e466a4b20c05f942c48ca76b3b5b5aaa90ec202f782cad892caa8b71ccf124da6 SHA512 f5c0fe4f28ff1a3a0931e8e235b5157a45f67967985bcc752418c5ec3481fca44a8ae4800088889b37e8cd0533f53d3c456d5ffd19b767b3f83a87b49a2e209a
DIST thread_local-0.3.6.crate 12388 BLAKE2B 290c35e5327e80a5cdca5609252b1efd1b78a654fc9ab4ba68eeaa3c2769d844f725d17d91cbb15048dbaac84913c51edcb39bb402882c9e7b4d0c4e4811518d SHA512 cd783d3d9caec43868da1f6118d4c4d520e03b9f1049d8f15d2c12482989401d3aee748e04a149953d35e5d6487355c2891d44569ef688bc1d45f01b6461d253
DIST ucd-util-0.1.1.crate 24221 BLAKE2B b03c4b21f30b1d7497814e22471f0ec94f52bf9815a8d8c454ab998040593e179e869e6e3d2fde61f993fc8d15ad6cd689f878bac9f0e1ea9a658d2dda242bf3 SHA512 3101bb088f9a804f311c23cfbec1b59ed6daebcc985af3c4a25cee5c1a0c0b8fe15a3b95516361cfc75bf0322895f2acc4835ee94122c782abfc8b0a1e6f8738
DIST ucd-util-0.1.3.crate 25897 BLAKE2B d67d250603625d7fe55b1bd17a8bff03ddf2e48b531e8f754f51dcd49370a2b66d0915842fb2fce85a69df2c38f9c086ac3c36115d40c5a8138e5451f71a1cfe SHA512 50a796feb198012241d73001bb53c8e3d3168df379de91d7ecaccfd829b08a356afe3db736fb8cced8748141d7a9e4b157440442c425816c78c0615c08e20f2e
DIST unicode-width-0.1.5.crate 15761 BLAKE2B 575e6bfe8b8b70cb0e5a167bf546df2964361a223b03a65bdc588c32d4cf9f01194daa8d6d1c90319f1f9981aa5b092dce67c9c97450be4ea630784d834cdbe2 SHA512 bd5ac5f0433953d79408074239edc7c43ce23d56659d467805d81ab01c576a3cf77ccedb3bba41d48bc4ad46a8905ac8a1927b99312053ef6295fd940a6766d2
DIST utf8-ranges-1.0.1.crate 9247 BLAKE2B e1a4a867c32b54b239338ba4c9a209cd5265320349a0a691f70793f1e4f1c9eddfd477cf2f11e4d4cd72e8f78e09fa32562eb0c57a3c7126a37675008b5ce7d8 SHA512 c17ca6aa679f1f974c9673fac6116c5bb48ff59ca65a968520d5e89c52a7d4409d578df4b28dd3feb4aee208d796a47641c4f1de71810de36905c6cd3439ff97
DIST utf8-ranges-1.0.2.crate 8510 BLAKE2B 877ff38444aec99bf8e0d09c6880d4835eb453c8c7e38fa5e7f8fe3cadd5b34b11a030193e46fe97b19fd90e94de156c0eaf12c613aae7cee47f0f016a3fb96d SHA512 ac168b908a34c4814a682b77502d2e5aa3130acb01fa87e29c78b760a61ba61b01f9fa2d67202604ac9824e0b2fe92143b72c0d4100a62ff9f53e4b00a4a12fb
DIST vec_map-0.8.1.crate 14959 BLAKE2B f5c179ccb4349d543747d5e3bb3edfca4bc9f3f64ba3c2d40fb1d9cba98433b7a0641387aafda6347c9b3603592c64bd820b217b46fbfcd37f802f298e5793ab SHA512 026cf10dc7ba98ae51dd312fc847cbaea41c25f0da5db6e0e22c2ecf75584bbf876d7bd96035fbbcf6696d702d5a3f25977e02a2d77cf519aa21e3ed05710e40
DIST version_check-0.1.5.crate 8173 BLAKE2B c1778a95fbc79e93bc25d6ee85c408cbcc2afc1a2317bd96b6d5e1c99862f26cc031e0a8b14451d7ea5a44d96c9b599c899bcebda36d3974effc51f9c236ca56 SHA512 cd3ca0b36108b0fe8e6a5c26614b4f3e3c36ffd13cd9eeb7693086b4a1f7b67c025613d90e79f4dd1bd3234a3e387b2ee890c6c410fe67d293b9b5503f5e9362
DIST winapi-0.3.6.crate 1029391 BLAKE2B 9a52085c3cb74d84bc66cee575da0105eeca69f6abd3c8c601a4de013bafea795f044748be10ec9ab419a9ec82a304a0b65ba4d74f6cb39baff91228f83009f1 SHA512 991eb3d6ba08d59e7f7ec81ebf469cecc56b3723b636392972d2fdc1d6f13d88f8a244ad5cbb20f6058d12b44e060ed663c12aa3fbcd1235ab511fafa105cd3c
DIST winapi-0.3.7.crate 1075776 BLAKE2B 694cea6d0d14fbe85ba718c0ca7b9db79ba8f943b44f4741d77000617de43314a2c657285736a032c138b5d2095b06146a2ac8d84b8efe2307ef44bb7073c604 SHA512 6871b93ad8d48e39b90cb7b31b3132f84665f965b4dfe06fcebdfb873e7d099007cf3d7a50e832a941c3425ad2f39c3ab48a77151e60863685b97fc05c71d134
DIST winapi-i686-pc-windows-gnu-0.4.0.crate 2918815 BLAKE2B 4d357e4d30f9552972170d65b9a5358b69c46a3e772fe05efc22f3d4ffc1caeeaad7aacdc7abd503a7ad0545f8bd7d22bf351dcb6df76f812fa4d45c34d65df0 SHA512 a672ccefd0730a8166fef1d4e39f9034d9ae426a3f5e28d1f4169fa5c5790767693f281d890e7804773b34acdb0ae1febac33cde8c50c0044a5a6152c7209ec2
DIST winapi-x86_64-pc-windows-gnu-0.4.0.crate 2947998 BLAKE2B 2ad1ea8b5fa07d544e910ccba043ae925269b76b26c9da356305b34b86741dd8b9aff0b9ffe3d562db4fcd7d7c46a11ce9e3168b782b1d89ae6881742b7ede82 SHA512 4a654af6a5d649dc87e00497245096b35a2894ae66f155cb62389902c3b93ddcc5cf7d0d8b9dd97b291d2d80bc686af2298e80abef6ac69883f4a54e79712513

@ -1,65 +0,0 @@
# Copyright 2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
CRATES="
aho-corasick-0.6.8
ansi_term-0.11.0
atty-0.2.11
bitflags-1.0.4
cc-1.0.25
cfg-if-0.1.6
clap-2.32.0
fblog-1.2.0
hlua-0.4.1
itoa-0.4.3
lazy_static-1.1.0
libc-0.2.43
lua52-sys-0.1.2
maplit-1.0.1
memchr-2.1.0
pkg-config-0.3.14
redox_syscall-0.1.40
redox_termios-0.1.1
regex-1.0.5
regex-syntax-0.6.2
ryu-0.2.6
serde-1.0.80
serde_json-1.0.32
strsim-0.7.0
termion-1.5.1
textwrap-0.10.0
thread_local-0.3.6
ucd-util-0.1.1
unicode-width-0.1.5
utf8-ranges-1.0.1
vec_map-0.8.1
version_check-0.1.5
winapi-0.3.6
winapi-i686-pc-windows-gnu-0.4.0
winapi-x86_64-pc-windows-gnu-0.4.0
"
inherit cargo
DESCRIPTION="Small command-line JSON Log viewer"
HOMEPAGE="https://github.com/brocode/fblog"
SRC_URI="$(cargo_crate_uris ${CRATES})"
LICENSE="WTFPL-2"
SLOT="0"
KEYWORDS="~amd64"
DEPEND=""
RDEPEND="${DEPEND}"
BDEPEND=">=virtual/rust-1.29.1"
DOCS=( README.org )
QA_FLAGS_IGNORED="/usr/bin/fblog"
src_install() {
cargo_src_install --path=.
einstalldocs
}

@ -1,3 +1 @@
DIST poppler-0.74.0.tar.xz 1514044 BLAKE2B af3821d5a5c68a3f2541cd9468fd7318ad0182cda66cea068dc42208fef6c2af78a401e50a6a5906cdc943de7339620937ddc6f69f0d8d1b15082aabc6cc3482 SHA512 4e48e2ffb559863ee693930db3b8594fd7e60e4b4ca3cdeb198faf90a6f4dbb5e102461492a12058221bc1218fe7e17c9085afb9e7956ae4bf26c11674315e66
DIST poppler-0.76.1.tar.xz 1531548 BLAKE2B edbd9c1be99aadf4f14608a1e0dc58a2fed351b10e18aa3c006f4e54cf0f2082deaded9c67a0181bb0f012bcbc550f1208e8a632df9cbe26261b735ca44cde60 SHA512 e4af2785948ecc89c105ab00269b0072b33feea25224e5beb158d515b1de789f979084bed2d4260c9659382cf437c25c0baf2444f5b4fbbba5c58afeb707b7ac
DIST poppler-0.77.0.tar.xz 1533068 BLAKE2B 9ce7db05bd9d0131f643096b84058e67ba416b34497af5e97c9b6f404131fc72c29ac05e60b77477d16e586df73b306e4a01c113be7ede0cf3956240db889a7f SHA512 7c82cf584541fcbfa7cecdb06be9c4ba6d03479fc248377b874afeab561eac24015915eee566edc35fafe785b9f381f492c1789c070e67a2c1b344879c156040

@ -1,127 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils flag-o-matic toolchain-funcs xdg-utils
if [[ ${PV} == *9999* ]] ; then
inherit git-r3
EGIT_REPO_URI="https://anongit.freedesktop.org/git/poppler/poppler.git"
SLOT="0/9999"
else
SRC_URI="https://poppler.freedesktop.org/${P}.tar.xz"
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 ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
SLOT="0/85" # CHECK THIS WHEN BUMPING!!! SUBSLOT IS libpoppler.so SOVERSION
fi
DESCRIPTION="PDF rendering library based on the xpdf-3.0 code base"
HOMEPAGE="https://poppler.freedesktop.org/"
LICENSE="GPL-2"
IUSE="cairo cjk curl cxx debug doc +introspection +jpeg +jpeg2k +lcms nss png qt5 tiff +utils"
# No test data provided
RESTRICT="test"
BDEPEND="
dev-util/glib-utils
virtual/pkgconfig
"
DEPEND="
media-libs/fontconfig
media-libs/freetype
sys-libs/zlib
cairo? (
dev-libs/glib:2
x11-libs/cairo
introspection? ( dev-libs/gobject-introspection:= )
)
curl? ( net-misc/curl )
jpeg? ( virtual/jpeg:0 )
jpeg2k? ( >=media-libs/openjpeg-2.3.0-r1:2= )
lcms? ( media-libs/lcms:2 )
nss? ( >=dev-libs/nss-3.19:0 )
png? ( media-libs/libpng:0= )
qt5? (
dev-qt/qtcore:5
dev-qt/qtgui:5
dev-qt/qtxml:5
)
tiff? ( media-libs/tiff:0 )
"
RDEPEND="${DEPEND}
cjk? ( app-text/poppler-data )
"
DOCS=( AUTHORS NEWS README README-XPDF )
PATCHES=(
"${FILESDIR}/${PN}-0.60.1-qt5-dependencies.patch"
"${FILESDIR}/${PN}-0.28.1-fix-multilib-configuration.patch"
"${FILESDIR}/${PN}-0.71.0-respect-cflags.patch"
"${FILESDIR}/${PN}-0.61.0-respect-cflags.patch"
"${FILESDIR}/${PN}-0.57.0-disable-internal-jpx.patch"
)
src_prepare() {
cmake-utils_src_prepare
# Clang doesn't grok this flag, the configure nicely tests that, but
# cmake just uses it, so remove it if we use clang
if [[ ${CC} == clang ]] ; then
sed -e 's/-fno-check-new//' -i cmake/modules/PopplerMacros.cmake || die
fi
if ! grep -Fq 'cmake_policy(SET CMP0002 OLD)' CMakeLists.txt ; then
sed -e '/^cmake_minimum_required/acmake_policy(SET CMP0002 OLD)' \
-i CMakeLists.txt || die
else
einfo "policy(SET CMP0002 OLD) - workaround can be removed"
fi
# we need to up the C++ version, bug #622526, #643278
append-cxxflags -std=c++11
}
src_configure() {
xdg_environment_reset
local mycmakeargs=(
-DBUILD_GTK_TESTS=OFF
-DBUILD_QT5_TESTS=OFF
-DBUILD_CPP_TESTS=OFF
-DENABLE_SPLASH=ON
-DENABLE_ZLIB=ON
-DENABLE_ZLIB_UNCOMPRESS=OFF
-DENABLE_UNSTABLE_API_ABI_HEADERS=ON
-DSPLASH_CMYK=OFF
-DUSE_FIXEDPOINT=OFF
-DUSE_FLOAT=OFF
-DWITH_Cairo=$(usex cairo)
-DENABLE_LIBCURL=$(usex curl)
-DENABLE_CPP=$(usex cxx)
-DWITH_JPEG=$(usex jpeg)
-DENABLE_DCTDECODER=$(usex jpeg libjpeg none)
-DENABLE_LIBOPENJPEG=$(usex jpeg2k openjpeg2 none)
-DENABLE_CMS=$(usex lcms lcms2 none)
-DWITH_NSS3=$(usex nss)
-DWITH_PNG=$(usex png)
$(cmake-utils_use_find_package qt5 Qt5Core)
-DWITH_TIFF=$(usex tiff)
-DENABLE_UTILS=$(usex utils)
)
use cairo && mycmakeargs+=( -DWITH_GObjectIntrospection=$(usex introspection) )
cmake-utils_src_configure
}
src_install() {
cmake-utils_src_install
# live version doesn't provide html documentation
if use cairo && use doc && [[ ${PV} != *9999* ]]; then
# For now install gtk-doc there
insinto /usr/share/gtk-doc/html/poppler
doins -r "${S}"/glib/reference/html/*
fi
}

@ -1,127 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils flag-o-matic toolchain-funcs xdg-utils
if [[ ${PV} == *9999* ]] ; then
inherit git-r3
EGIT_REPO_URI="https://anongit.freedesktop.org/git/poppler/poppler.git"
SLOT="0/9999"
else
SRC_URI="https://poppler.freedesktop.org/${P}.tar.xz"
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 ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
SLOT="0/87" # CHECK THIS WHEN BUMPING!!! SUBSLOT IS libpoppler.so SOVERSION
fi
DESCRIPTION="PDF rendering library based on the xpdf-3.0 code base"
HOMEPAGE="https://poppler.freedesktop.org/"
LICENSE="GPL-2"
IUSE="cairo cjk curl cxx debug doc +introspection +jpeg +jpeg2k +lcms nss png qt5 tiff +utils"
# No test data provided
RESTRICT="test"
BDEPEND="
dev-util/glib-utils
virtual/pkgconfig
"
DEPEND="
media-libs/fontconfig
media-libs/freetype
sys-libs/zlib
cairo? (
dev-libs/glib:2
x11-libs/cairo
introspection? ( dev-libs/gobject-introspection:= )
)
curl? ( net-misc/curl )
jpeg? ( virtual/jpeg:0 )
jpeg2k? ( >=media-libs/openjpeg-2.3.0-r1:2= )
lcms? ( media-libs/lcms:2 )
nss? ( >=dev-libs/nss-3.19:0 )
png? ( media-libs/libpng:0= )
qt5? (
dev-qt/qtcore:5
dev-qt/qtgui:5
dev-qt/qtxml:5
)
tiff? ( media-libs/tiff:0 )
"
RDEPEND="${DEPEND}
cjk? ( app-text/poppler-data )
"
DOCS=( AUTHORS NEWS README README-XPDF )
PATCHES=(
"${FILESDIR}/${PN}-0.60.1-qt5-dependencies.patch"
"${FILESDIR}/${PN}-0.28.1-fix-multilib-configuration.patch"
"${FILESDIR}/${PN}-0.71.0-respect-cflags.patch"
"${FILESDIR}/${PN}-0.61.0-respect-cflags.patch"
"${FILESDIR}/${PN}-0.57.0-disable-internal-jpx.patch"
)
src_prepare() {
cmake-utils_src_prepare
# Clang doesn't grok this flag, the configure nicely tests that, but
# cmake just uses it, so remove it if we use clang
if [[ ${CC} == clang ]] ; then
sed -e 's/-fno-check-new//' -i cmake/modules/PopplerMacros.cmake || die
fi
if ! grep -Fq 'cmake_policy(SET CMP0002 OLD)' CMakeLists.txt ; then
sed -e '/^cmake_minimum_required/acmake_policy(SET CMP0002 OLD)' \
-i CMakeLists.txt || die
else
einfo "policy(SET CMP0002 OLD) - workaround can be removed"
fi
# we need to up the C++ version, bug #622526, #643278
append-cxxflags -std=c++11
}
src_configure() {
xdg_environment_reset
local mycmakeargs=(
-DBUILD_GTK_TESTS=OFF
-DBUILD_QT5_TESTS=OFF
-DBUILD_CPP_TESTS=OFF
-DENABLE_SPLASH=ON
-DENABLE_ZLIB=ON
-DENABLE_ZLIB_UNCOMPRESS=OFF
-DENABLE_UNSTABLE_API_ABI_HEADERS=ON
-DSPLASH_CMYK=OFF
-DUSE_FIXEDPOINT=OFF
-DUSE_FLOAT=OFF
-DWITH_Cairo=$(usex cairo)
-DENABLE_LIBCURL=$(usex curl)
-DENABLE_CPP=$(usex cxx)
-DWITH_JPEG=$(usex jpeg)
-DENABLE_DCTDECODER=$(usex jpeg libjpeg none)
-DENABLE_LIBOPENJPEG=$(usex jpeg2k openjpeg2 none)
-DENABLE_CMS=$(usex lcms lcms2 none)
-DWITH_NSS3=$(usex nss)
-DWITH_PNG=$(usex png)
$(cmake-utils_use_find_package qt5 Qt5Core)
-DWITH_TIFF=$(usex tiff)
-DENABLE_UTILS=$(usex utils)
)
use cairo && mycmakeargs+=( -DWITH_GObjectIntrospection=$(usex introspection) )
cmake-utils_src_configure
}
src_install() {
cmake-utils_src_install
# live version doesn't provide html documentation
if use cairo && use doc && [[ ${PV} != *9999* ]]; then
# For now install gtk-doc there
insinto /usr/share/gtk-doc/html/poppler
doins -r "${S}"/glib/reference/html/*
fi
}

@ -11,7 +11,7 @@ if [[ ${PV} == *9999* ]] ; then
SLOT="0/9999"
else
SRC_URI="https://poppler.freedesktop.org/${P}.tar.xz"
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 ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
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 ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
SLOT="0/88" # CHECK THIS WHEN BUMPING!!! SUBSLOT IS libpoppler.so SOVERSION
fi

@ -3,3 +3,4 @@ DIST qpdf-7.1.1.tar.gz 7099282 BLAKE2B 9658dd1cc6f8d0e3dd13137db147e0f954f747b5b
DIST qpdf-8.2.1.tar.gz 8256216 BLAKE2B 67e9b897ed938b9dd2e8508efaddd4dd6f63568aa23332ef72918a0888cc1e1b8fe844f0c1424b8ab568ee5ce42f8efd04293cd525e9d8de0c5fe7b352f49367 SHA512 ef3aeb4a7ca3ec48ab62341533eedcb2a6d0985767317ab72c22f0c0ecfef6849bfdc34b1bcec6427c7bde166143adb409c895ff40d8be6628e6323e27697a8c
DIST qpdf-8.4.0.tar.gz 16981811 BLAKE2B ac0f7b6ab0ca5b421229bf3813cba6b59cc5b7472080246b1384db468e14a4e634f00e1e9e9347e2f8ac8d7e5c15c1b1c18e954f4249298e5ee4778f996fc4ee SHA512 13225c6285311e8fe89970971b082b9613e70d474ee71dd5572f1ae268234d366c2c9c7bf427c4758a746a1a27ecc0127d31044ab501dbc08885c8aa0a514028
DIST qpdf-8.4.1.tar.gz 16990752 BLAKE2B 6e7ccd212cf8d01aea3dc615f5924c0575392f19cdd20b35327a71bd1f97d7e515fe1a73cd2e3901964f621cafa19ab07a1314af19f40ded28d3e9f683c02ab0 SHA512 d5ac3376345650f05278f8b4d99182cd58b927537085a4a6415d3df0b80b7ddd80a7c33778ec8c3b85d9788ea081ea3266bd4a9315eda9820988e9e54a22f80d
DIST qpdf-8.4.2.tar.gz 16988263 BLAKE2B 358836310575fd0f454d4504a70796b72d2e3120c5820e2c33e84ea79c5c115d1c84f8d58392d870b5357407d0fbed05028bd854d164be0b32b348c587845300 SHA512 9cde046fb5e42dc331933294155583fb20408704a0cab3075cc3e97bd4643e3178e4162b8de7434aa2304097e7734f985fdc8e7b05cc028c37193dce91797f7a

@ -0,0 +1,57 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
DESCRIPTION="Command-line tool for structural, content-preserving transformation of PDF files"
HOMEPAGE="http://qpdf.sourceforge.net/"
SRC_URI="mirror://sourceforge/qpdf/${P}.tar.gz"
LICENSE="|| ( Apache-2.0 Artistic-2 )"
# subslot = libqpdf soname version
SLOT="0/21"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~m68k-mint ~sparc-solaris"
IUSE="doc examples perl static-libs test"
CDEPEND="
sys-libs/zlib
virtual/jpeg:0=
"
DEPEND="${CDEPEND}
test? (
sys-apps/diffutils
media-libs/tiff
app-text/ghostscript-gpl[tiff]
)
"
# Only need perl for the installed tools.
RDEPEND="${CDEPEND}
perl? ( >=dev-lang/perl-5.8 )
"
DOCS=( ChangeLog README.md TODO )
src_configure() {
local myeconfargs=(
$(use_enable static-libs static)
$(use_enable test test-compare-images)
)
CONFIG_SHELL=/bin/bash econf "${myeconfargs[@]}"
}
src_install() {
default
if ! use perl ; then
rm "${ED}"/usr/bin/fix-qdf || die
rm "${ED}"/usr/share/man/man1/fix-qdf.1 || die
fi
if use examples ; then
dobin examples/build/.libs/*
fi
find "${ED}" -name '*.la' -delete || die
}

@ -60,7 +60,7 @@ SRC_URI="https://github.com/${MY_PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~alpha amd64 ~arm arm64 ~mips ppc ppc64 ~sparc x86"
KEYWORDS="alpha amd64 ~arm arm64 ~mips ppc ppc64 ~sparc x86"
IUSE="doc examples jpeg math opencl osd png scrollview static-libs tiff training webp l10n_ar l10n_bg l10n_ca l10n_chr l10n_cs l10n_de l10n_da l10n_el l10n_es l10n_fi l10n_fr l10n_he l10n_hi l10n_hu l10n_id l10n_it l10n_ja l10n_ko l10n_lt l10n_lv l10n_nl l10n_no l10n_pl l10n_pt l10n_ro l10n_ru l10n_sk l10n_sl l10n_sr l10n_sv l10n_th l10n_tl l10n_tr l10n_uk l10n_vi l10n_zh-CN l10n_zh-TW"

Binary file not shown.

@ -19,11 +19,12 @@ KEYWORDS="~amd64 ~x86"
IUSE="gnat_2016 gnat_2017 +gnat_2018 gnat_2019 +shared static-libs"
RDEPEND="dev-python/pyyaml
dev-ada/gnatcoll-bindings[gnat_2016=,gnat_2017=,gnat_2018=,gnat_2019=]
dev-ada/gnatcoll-bindings[gnat_2016(-)?,gnat_2017(-)?,gnat_2018(-)?,gnat_2019(-)?]
dev-ada/gnatcoll-bindings[iconv,shared=,static-libs=]
${PYTHON_DEPS}"
DEPEND="${RDEPEND}
~dev-ada/langkit-2018"
~dev-ada/langkit-2018
dev-ada/gprbuild[gnat_2016(-)?,gnat_2017(-)?,gnat_2018(-)?,gnat_2019(-)?]"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
S="${WORKDIR}"/${MYP}

@ -23,7 +23,8 @@ RDEPEND="dev-python/pyyaml
dev-ada/gnatcoll-bindings[iconv,shared=,static-libs=]
${PYTHON_DEPS}"
DEPEND="${RDEPEND}
>=dev-ada/langkit-2018"
dev-ada/gprbuild[gnat_2018(-)?,gnat_2019(-)?]
>=dev-ada/langkit-2019"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"

Binary file not shown.

@ -1,3 +1,4 @@
DIST gtest-1.7.0.tar.gz 1001582 BLAKE2B 3d10c1e502c2fac1500d07301031a9328b29027a3f9719137e09d2c47556cf52bbc978a8fb7b37330a94beafa27d24c3bfc247b2f0d51306b53f43e7ae2373b4 SHA512 a9f5c047b39efb2d11b55ee9913662ca402ac6837b3ad2d278ecfbd1caf32ed4546f169e3e92503d57bf3b62ccf89cd062da1c7ea3638aae98e868d2766363c3
DIST gtest-1.8.0.tar.gz 1281617 BLAKE2B ac052b4d0eb0d8ded03a8c7dff05177818627b8a51f2dbc2c162b2ee2a5d1323539e7d0d02236d9ebb799995e018f0171c2fdaeb4de3bb339548265e50de79e6 SHA512 1dbece324473e53a83a60601b02c92c089f5d314761351974e097b2cf4d24af4296f9eb8653b6b03b1e363d9c5f793897acae1f0c7ac40149216035c4d395d9d
DIST gtest-1.8.1.tar.gz 992298 BLAKE2B 40ef3417fe424205c0617f07207347ce671ac87605f8ac9b8a333b0b06e3fbef9f556041ee324c18f957f3258ab9fe06704f31cdd038355fb7890180eb77ced1 SHA512 e6283c667558e1fd6e49fa96e52af0e415a3c8037afe1d28b7ff1ec4c2ef8f49beb70a9327b7fc77eb4052a58c4ccad8b5260ec90e4bceeac7a46ff59c4369d7
DIST gtest-1.9.0_pre20190607.tar.gz 958396 BLAKE2B 64ae2c86a320a6ed56d6f99383591f7a0176e3f1291144bddf6dc82733c78177963f95516bbaed494318d3d7451d164aeb0d4a192b415414bcc25b9875cf6e82 SHA512 6c17ba303ec1dc8a989075a6dc0eda9b023345d00f6b43e588676cc2cd291f8c508744e4aba86a6c6b651329ce47419ad04d5765ca5978eda507a1643e8a92c3

@ -0,0 +1,14 @@
Bug: https://bugs.gentoo.org/629620
Upstream PR: https://github.com/google/googletest/pull/2276
--- a/googletest/src/gtest-death-test.cc
+++ b/googletest/src/gtest-death-test.cc
@@ -1354,7 +1354,7 @@
if (!use_fork) {
static const bool stack_grows_down = StackGrowsDown();
- const auto stack_size = static_cast<size_t>(getpagesize());
+ const auto stack_size = static_cast<size_t>(getpagesize() * 8);
// MMAP_ANONYMOUS is not defined on Mac, so we use MAP_ANON instead.
void* const stack = mmap(nullptr, stack_size, PROT_READ | PROT_WRITE,
MAP_ANON | MAP_PRIVATE, -1, 0);

@ -0,0 +1,79 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
# Python is required for tests and some build tasks.
PYTHON_COMPAT=( python2_7 pypy )
GOOGLETEST_COMMIT=da10da05c262af0a9e8fa91789a272a3dec67655
inherit cmake-multilib python-any-r1
if [[ ${PV} == "9999" ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/google/googletest"
else
if [[ -z ${GOOGLETEST_COMMIT} ]]; then
MY_PV=release-${PV}
else
MY_PV=${GOOGLETEST_COMMIT}
fi
SRC_URI="https://github.com/google/googletest/archive/${MY_PV}.tar.gz -> ${P}.tar.gz"
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"
S="${WORKDIR}"/googletest-${MY_PV}
fi
DESCRIPTION="Google C++ Testing Framework"
HOMEPAGE="https://github.com/google/googletest"
LICENSE="BSD"
SLOT="0"
IUSE="doc examples test"
DEPEND="test? ( ${PYTHON_DEPS} )"
RDEPEND="!dev-cpp/gmock"
PATCHES=(
"${FILESDIR}"/${PN}-9999-increase-clone-stack-size.patch
)
pkg_setup() {
use test && python-any-r1_pkg_setup
}
src_prepare() {
cmake-utils_src_prepare
sed -i -e '/set(cxx_base_flags /s:-Werror::' \
googletest/cmake/internal_utils.cmake || die "sed failed!"
}
multilib_src_configure() {
local mycmakeargs=(
-DBUILD_GMOCK=ON
-DINSTALL_GTEST=ON
# tests
-Dgmock_build_tests=$(usex test)
-Dgtest_build_tests=$(usex test)
-DPYTHON_EXECUTABLE="${PYTHON}"
)
cmake-utils_src_configure
}
multilib_src_install_all() {
einstalldocs
if use doc; then
docinto googletest
dodoc -r googletest/docs/.
docinto googlemock
dodoc -r googlemock/docs/.
fi
if use examples; then
docinto examples
dodoc googletest/samples/*.{cc,h}
fi
}

@ -12,9 +12,14 @@ if [[ ${PV} == "9999" ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/google/googletest"
else
SRC_URI="https://github.com/google/googletest/archive/release-${PV}.tar.gz -> ${P}.tar.gz"
if [[ -z ${GOOGLETEST_COMMIT} ]]; then
MY_PV=release-${PV}
else
MY_PV=${GOOGLETEST_COMMIT}
fi
SRC_URI="https://github.com/google/googletest/archive/${MY_PV}.tar.gz -> ${P}.tar.gz"
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"
S="${WORKDIR}"/googletest-release-${PV}
S="${WORKDIR}"/googletest-${MY_PV}
fi
DESCRIPTION="Google C++ Testing Framework"
@ -28,8 +33,7 @@ DEPEND="test? ( ${PYTHON_DEPS} )"
RDEPEND="!dev-cpp/gmock"
PATCHES=(
"${FILESDIR}"/${PN}-9999-fix-gcc6-undefined-behavior.patch
"${FILESDIR}"/${PN}-1.8.0-increase-clone-stack-size.patch
"${FILESDIR}"/${PN}-9999-increase-clone-stack-size.patch
)
pkg_setup() {

@ -18,7 +18,10 @@ RESTRICT="mirror bindist"
DEPEND="dev-util/patchelf"
RDEPEND="
=dev-libs/openssl-1.0*:*
|| (
dev-libs/openssl-compat:1.0.0
=dev-libs/openssl-1.0*:*
)
media-libs/fontconfig
media-libs/freetype
media-libs/libpng:1.2

@ -18,7 +18,10 @@ RESTRICT="mirror bindist"
DEPEND="dev-util/patchelf"
RDEPEND="
=dev-libs/openssl-1.0*:*
|| (
dev-libs/openssl-compat:1.0.0
=dev-libs/openssl-1.0*:*
)
media-libs/fontconfig
media-libs/freetype
media-libs/libpng:1.2

Binary file not shown.

@ -1,2 +0,0 @@
DIST mariadb-galera-10.0.38.tar.gz 65157071 BLAKE2B c54341395101e27dd25183da3d09e7ddf72a07cf440a8aea5daa998d53012a93e1f04bb5020dba28d1337b5f11448be6ae3d8624c437db0cf090eff2aa10151d SHA512 219c2400ebdbf4c6933af1d2d1f88c7f795a988b408676a3c93dbb8c82bdb782f661e9a60f5e940baf31feda8e584e9764918e59cfbdfa1356af8712dde17425
DIST mysql-extras-20190310-0358Z.tar.bz2 331100 BLAKE2B 69f2b1ee404247e04b7d368c08c429f783fa45dface295be9fa2d94822d052a08a40e6a57bec3afc38886eb0badfcb52c92974c6df033bb90be66abb3f05249a SHA512 5fd4a320e4c224514b054cffbbdf3697ed7351cf71ee779c311f024388bbf12673821b0e12994acbccd30fe119214ea4b53edf87e2cb37be39d0448e4b2cf70b

@ -1,158 +0,0 @@
# @GENTOO_PORTAGE_EPREFIX@/etc/mysql/my.cnf: The global mysql configuration file.
# The following options will be passed to all MySQL clients
[client]
#password = your_password
port = 3306
socket = @GENTOO_PORTAGE_EPREFIX@/var/run/mysqld/mysqld.sock
[mysql]
character-sets-dir=@GENTOO_PORTAGE_EPREFIX@/usr/share/mysql/charsets
default-character-set=utf8
[mysqladmin]
character-sets-dir=@GENTOO_PORTAGE_EPREFIX@/usr/share/mysql/charsets
default-character-set=utf8
[mysqlcheck]
character-sets-dir=@GENTOO_PORTAGE_EPREFIX@/usr/share/mysql/charsets
default-character-set=utf8
[mysqldump]
character-sets-dir=@GENTOO_PORTAGE_EPREFIX@/usr/share/mysql/charsets
default-character-set=utf8
[mysqlimport]
character-sets-dir=@GENTOO_PORTAGE_EPREFIX@/usr/share/mysql/charsets
default-character-set=utf8
[mysqlshow]
character-sets-dir=@GENTOO_PORTAGE_EPREFIX@/usr/share/mysql/charsets
default-character-set=utf8
[myisamchk]
character-sets-dir=@GENTOO_PORTAGE_EPREFIX@/usr/share/mysql/charsets
[myisampack]
character-sets-dir=@GENTOO_PORTAGE_EPREFIX@/usr/share/mysql/charsets
# use [safe_mysqld] with mysql-3
[mysqld_safe]
err-log = @GENTOO_PORTAGE_EPREFIX@/var/log/mysql/mysql.err
# add a section [mysqld-4.1] or [mysqld-5.0] for specific configurations
[mysqld]
character-set-server = utf8
user = mysql
port = 3306
socket = @GENTOO_PORTAGE_EPREFIX@/var/run/mysqld/mysqld.sock
pid-file = @GENTOO_PORTAGE_EPREFIX@/var/run/mysqld/mysqld.pid
log-error = @GENTOO_PORTAGE_EPREFIX@/var/log/mysql/mysqld.err
basedir = @GENTOO_PORTAGE_EPREFIX@/usr
datadir = @DATADIR@
skip-external-locking
key_buffer_size = 16M
max_allowed_packet = 4M
table_open_cache = 400
sort_buffer_size = 512K
net_buffer_length = 16K
read_buffer_size = 256K
read_rnd_buffer_size = 512K
myisam_sort_buffer_size = 8M
lc_messages_dir = @GENTOO_PORTAGE_EPREFIX@/usr/share/mysql
#Set this to your desired error message language
lc_messages = en_US
# security:
# using "localhost" in connects uses sockets by default
# skip-networking
bind-address = 127.0.0.1
log-bin
server-id = 1
# point the following paths to different dedicated disks
tmpdir = @GENTOO_PORTAGE_EPREFIX@/tmp/
#log-update = @GENTOO_PORTAGE_EPREFIX@/path-to-dedicated-directory/hostname
# you need the debug USE flag enabled to use the following directives,
# if needed, uncomment them, start the server and issue
# #tail -f @GENTOO_PORTAGE_EPREFIX@/tmp/mysqld.sql @GENTOO_PORTAGE_EPREFIX@/tmp/mysqld.trace
# this will show you *exactly* what's happening in your server ;)
#log = @GENTOO_PORTAGE_EPREFIX@/tmp/mysqld.sql
#gdb
#debug = d:t:i:o,/tmp/mysqld.trace
#one-thread
# the rest of the innodb config follows:
# don't eat too much memory, we're trying to be safe on 64Mb boxes
# you might want to bump this up a bit on boxes with more RAM
innodb_buffer_pool_size = 128M
#
# i'd like to use @GENTOO_PORTAGE_EPREFIX@/var/lib/mysql/innodb, but that is seen as a database :-(
# and upstream wants things to be under @GENTOO_PORTAGE_EPREFIX@/var/lib/mysql/, so that's the route
# we have to take for the moment
#innodb_data_home_dir = @GENTOO_PORTAGE_EPREFIX@/var/lib/mysql/
#innodb_log_arch_dir = @GENTOO_PORTAGE_EPREFIX@/var/lib/mysql/
#innodb_log_group_home_dir = @GENTOO_PORTAGE_EPREFIX@/var/lib/mysql/
# you may wish to change this size to be more suitable for your system
# the max is there to avoid run-away growth on your machine
innodb_data_file_path = ibdata1:10M:autoextend:max:128M
# we keep this at around 25% of of innodb_buffer_pool_size
# sensible values range from 1MB to (1/innodb_log_files_in_group*innodb_buffer_pool_size)
innodb_log_file_size = 48M
# this is the default, increase it if you have very large transactions going on
innodb_log_buffer_size = 8M
# this is the default and won't hurt you
# you shouldn't need to tweak it
innodb_log_files_in_group=2
# see the innodb config docs, the other options are not always safe
innodb_flush_log_at_trx_commit = 1
innodb_lock_wait_timeout = 50
innodb_file_per_table
# Uncomment this to get FEDERATED engine support
#plugin-load=federated=ha_federated.so
loose-federated
# These settings are required for Galera clustering
#mysql settings
binlog_format=ROW
default-storage-engine=innodb
innodb_autoinc_lock_mode=2
query_cache_size=0
query_cache_type=0
bind-address=0.0.0.0
# Uncomment this section to activate Galera clustering
#wsrep_provider=@GENTOO_PORTAGE_EPREFIX@/usr/lib/galera/libgalera_smm.so
# You should change this name to something meaningful
#wsrep_cluster_name="my_wsrep_cluster"
# List all nodes of the cluster including this one
#wsrep_cluster_address="gcomm://172.16.8.5,172.16.8.6,172.16.8.4"
#wsrep_sst_method=rsync
[mysqldump]
quick
max_allowed_packet = 16M
[mysql]
# uncomment the next directive if you are not familiar with SQL
#safe-updates
[isamchk]
key_buffer_size = 20M
sort_buffer_size = 20M
read_buffer = 2M
write_buffer = 2M
[myisamchk]
key_buffer_size = 20M
sort_buffer_size = 20M
read_buffer_size = 2M
write_buffer_size = 2M
[mysqlhotcopy]
interactive-timeout
[mariadb]

@ -1,859 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
MY_EXTRAS_VER="20190310-0358Z"
SUBSLOT="18"
JAVA_PKG_OPT_USE="jdbc"
# Keeping eutils in EAPI=6 for emktemp in pkg_config
inherit eutils flag-o-matic prefix toolchain-funcs java-pkg-opt-2 user cmake-utils
SRC_URI="https://downloads.mariadb.org/interstitial/${P}/source/${P}.tar.gz "
# Gentoo patches to MySQL
if [[ "${MY_EXTRAS_VER}" != "live" && "${MY_EXTRAS_VER}" != "none" ]]; then
SRC_URI="${SRC_URI}
mirror://gentoo/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://gitweb.gentoo.org/proj/mysql-extras.git/snapshot/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~grknight/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~robbat2/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~jmbsvicetto/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2"
fi
HOMEPAGE="https://mariadb.org/"
DESCRIPTION="An enhanced, drop-in replacement for MySQL"
LICENSE="GPL-2 LGPL-2.1+"
SLOT="0/${SUBSLOT:-0}"
IUSE="bindist client-libs debug extraengine jdbc jemalloc latin1 libressl
numa odbc oqgraph pam +perl profiling selinux +server sphinx
sst-rsync sst-xtrabackup static systemtap tcmalloc
test tokudb xml yassl"
# Tests always fail when libressl is enabled due to hard-coded ciphers in the tests
RESTRICT="!bindist? ( bindist ) libressl? ( test )"
REQUIRED_USE="jdbc? ( extraengine server !static )
server? ( tokudb? ( jemalloc !tcmalloc ) )
!server? ( !extraengine )
?? ( tcmalloc jemalloc )
static? ( yassl !pam )"
KEYWORDS="~amd64 ~x86"
# Shorten the path because the socket path length must be shorter than 107 chars
# and we will run a mysql server during test phase
S="${WORKDIR}/mysql"
if [[ "${MY_EXTRAS_VER}" == "live" ]] ; then
MY_PATCH_DIR="${WORKDIR%/}/mysql-extras"
inherit git-r3
EGIT_REPO_URI="git://anongit.gentoo.org/proj/mysql-extras.git"
EGIT_CHECKOUT_DIR="${WORKDIR%/}/mysql-extras"
EGIT_CLONE_TYPE=shallow
else
MY_PATCH_DIR="${WORKDIR%/}/mysql-extras-${MY_EXTRAS_VER}"
fi
PATCHES=(
"${MY_PATCH_DIR}/01050_all_mariadb_mysql_config_cleanup-5.5.41.patch"
"${MY_PATCH_DIR}/20006_all_cmake_elib-mariadb-10.0.33.patch"
"${MY_PATCH_DIR}/20009_all_mariadb_myodbc_symbol_fix-5.5.38.patch"
"${MY_PATCH_DIR}/20018_all_mariadb-galera-10.0.20-without-clientlibs-tools.patch"
)
# Be warned, *DEPEND are version-dependant
# These are used for both runtime and compiletime
COMMON_DEPEND="
kernel_linux? (
sys-process/procps:0=
dev-libs/libaio:0=
)
>=sys-apps/sed-4
>=sys-apps/texinfo-4.7-r1
jemalloc? ( dev-libs/jemalloc:0= )
tcmalloc? ( dev-util/google-perftools:0= )
systemtap? ( >=dev-util/systemtap-1.3:0= )
!yassl? (
!libressl? ( <dev-libs/openssl-1.1.0:0= )
libressl? ( dev-libs/libressl:0= )
)
>=sys-libs/zlib-1.2.3:0=
sys-libs/ncurses:0=
!bindist? (
>=sys-libs/readline-4.1:0=
)
server? (
extraengine? (
odbc? ( dev-db/unixODBC:0= )
xml? ( dev-libs/libxml2:2= )
)
numa? ( sys-process/numactl )
oqgraph? ( >=dev-libs/boost-1.40.0:0= dev-libs/judy:0= )
pam? ( virtual/pam:0= )
tokudb? ( app-arch/snappy )
)
>=dev-libs/libpcre-8.41-r1:3=
"
DEPEND="virtual/yacc
static? ( sys-libs/ncurses[static-libs] )
|| ( >=sys-devel/gcc-3.4.6 >=sys-devel/gcc-apple-4.0 )
server? ( extraengine? ( jdbc? ( >=virtual/jdk-1.6 ) ) )
${COMMON_DEPEND}"
RDEPEND="selinux? ( sec-policy/selinux-mysql )
client-libs? ( !dev-db/mariadb-connector-c[mysqlcompat] !dev-db/mysql-connector-c )
!dev-db/mysql !dev-db/mariadb !dev-db/percona-server !dev-db/mysql-cluster
server? ( !prefix? ( dev-db/mysql-init-scripts ) )
${COMMON_DEPEND}
server? (
sys-apps/iproute2
=sys-cluster/galera-25*
sst-rsync? ( sys-process/lsof )
sst-xtrabackup? ( net-misc/socat[ssl] )
)
perl? ( !dev-db/mytop
virtual/perl-Getopt-Long
dev-perl/TermReadKey
virtual/perl-Term-ANSIColor
virtual/perl-Time-HiRes )
server? ( extraengine? ( jdbc? ( >=virtual/jre-1.6 ) ) )
"
# For other stuff to bring us in
# dev-perl/DBD-mysql is needed by some scripts installed by MySQL
# percona-xtrabackup-bin causes a circular dependency if DBD-mysql is not already installed
PDEPEND="perl? ( >=dev-perl/DBD-mysql-2.9004 )
server? ( sst-xtrabackup? ( || ( >=dev-db/percona-xtrabackup-bin-2.2.4 dev-db/percona-xtrabackup ) ) )"
pkg_setup() {
if [[ ${MERGE_TYPE} != binary ]] ; then
local GCC_MAJOR_SET=$(gcc-major-version)
local GCC_MINOR_SET=$(gcc-minor-version)
if use tokudb && [[ ${GCC_MAJOR_SET} -lt 4 || \
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
eerror "${PN} with tokudb needs to be built with gcc-4.7 or later."
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
die
fi
# Bug 565584. InnoDB now requires atomic functions introduced with gcc-4.7 on
# non x86{,_64} arches
if ! use amd64 && ! use x86 && [[ ${GCC_MAJOR_SET} -lt 4 || \
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
eerror "${PN} needs to be built with gcc-4.7 or later."
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
die
fi
fi
java-pkg-opt-2_pkg_setup
if has test ${FEATURES} && \
use server && ! has userpriv ${FEATURES} ; then
eerror "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
fi
# This should come after all of the die statements
enewgroup mysql 60 || die "problem adding 'mysql' group"
enewuser mysql 60 -1 /dev/null mysql || die "problem adding 'mysql' user"
}
pkg_preinst() {
java-pkg-opt-2_pkg_preinst
}
pkg_postinst() {
# Make sure the vars are correctly initialized
mysql_init_vars
# Create log directory securely if it does not exist
[[ -d "${ROOT}${MY_LOGDIR}" ]] || install -d -m0750 -o mysql -g mysql "${ROOT}${MY_LOGDIR}"
if use server ; then
if use pam; then
einfo
elog "This install includes the PAM authentication plugin."
elog "To activate and configure the PAM plugin, please read:"
elog "https://mariadb.com/kb/en/mariadb/pam-authentication-plugin/"
einfo
fi
if [[ -z "${REPLACING_VERSIONS}" ]] ; then
einfo
elog "You might want to run:"
elog "\"emerge --config =${CATEGORY}/${PF}\""
elog "if this is a new install."
elog
elog "If you are switching server implentations, you should run the"
elog "mysql_upgrade tool."
einfo
else
einfo
elog "If you are upgrading major versions, you should run the"
elog "mysql_upgrade tool."
einfo
fi
einfo
elog "Be sure to edit the my.cnf file to activate your cluster settings."
elog "This should be done after running \"emerge --config =${CATEGORY}/${PF}\""
elog "The first time the cluster is activated, you should add"
elog "--wsrep-new-cluster to the options in /etc/conf.d/mysql for one node."
elog "This option should then be removed for subsequent starts."
einfo
fi
}
src_unpack() {
unpack ${A}
# Grab the patches
[[ "${MY_EXTRAS_VER}" == "live" ]] && S="${WORKDIR%/}/mysql-extras" git-r3_src_unpack
mv -f "${WORKDIR%/}/${PN%%-galera}-${PV}" "${S}" || die
}
src_prepare() {
_disable_engine() {
echo > "${S%/}/storage/${1}/CMakeLists.txt" || die
}
_disable_plugin() {
echo > "${S%/}/plugin/${1}/CMakeLists.txt" || die
}
if use tcmalloc; then
echo "TARGET_LINK_LIBRARIES(mysqld tcmalloc)" >> "${S%/}/sql/CMakeLists.txt" || die
fi
# Don't build bundled xz-utils for tokudb
echo > "${S%/}/storage/tokudb/PerconaFT/cmake_modules/TokuThirdParty.cmake" || die
sed -i -e 's/ build_lzma//' -e 's/ build_snappy//' "${S%/}/storage/tokudb/PerconaFT/ft/CMakeLists.txt" || die
sed -i -e 's/add_dependencies\(tokuportability_static_conv build_jemalloc\)//' "${S%/}/storage/tokudb/PerconaFT/portability/CMakeLists.txt" || die
local plugin
local server_plugins=( handler_socket auth_socket feedback metadata_lock_info
locale_info qc_info server_audit semisync sql_errlog )
local test_plugins=( audit_null auth_examples daemon_example fulltext )
if ! use server; then # These plugins are for the server
for plugin in "${server_plugins[@]}" ; do
_disable_plugin "${plugin}"
done
fi
if ! use test; then # These plugins are only used during testing
for plugin in "${test_plugins[@]}" ; do
_disable_plugin "${plugin}"
done
fi
# Collides with mariadb-connector-c bug 655980
_disable_plugin auth_dialog
# Don't build Mroonga or example
_disable_engine mroonga
_disable_engine example
if ! use oqgraph ; then # avoids extra library checks
_disable_engine oqgraph
fi
cmake-utils_src_prepare
java-pkg-opt-2_src_prepare
}
src_configure(){
# bug 508724 mariadb cannot use ld.gold
tc-ld-disable-gold
# Bug #114895, bug #110149
filter-flags "-O" "-O[01]"
append-cxxflags -felide-constructors
# bug #283926, with GCC4.4, this is required to get correct behavior.
append-flags -fno-strict-aliasing
CMAKE_BUILD_TYPE="RelWithDebInfo"
# debug hack wrt #497532
mycmakeargs=(
-DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
-DCMAKE_INSTALL_PREFIX="${EPREFIX%/}/usr"
-DINSTALL_SYSCONFDIR="${EPREFIX%/}/etc/mysql"
-DINSTALL_BINDIR=bin
-DINSTALL_DOCDIR=share/doc/${PF}
-DINSTALL_DOCREADMEDIR=share/doc/${PF}
-DINSTALL_INCLUDEDIR=include/mysql
-DINSTALL_INFODIR=share/info
-DINSTALL_LIBDIR=$(get_libdir)
-DINSTALL_MANDIR=share/man
-DINSTALL_MYSQLSHAREDIR=share/mariadb
-DINSTALL_PLUGINDIR=$(get_libdir)/mariadb/plugin
-DINSTALL_SCRIPTDIR=share/mariadb/scripts
-DINSTALL_MYSQLDATADIR="${EPREFIX%/}/var/lib/mysql"
-DINSTALL_SBINDIR=sbin
-DINSTALL_SUPPORTFILESDIR="${EPREFIX%/}/usr/share/mariadb"
-DCOMPILATION_COMMENT="Gentoo Linux ${PF}"
-DWITH_UNIT_TESTS=$(usex test ON OFF)
-DWITH_ZLIB=system
-DENABLED_LOCAL_INFILE=1
-DMYSQL_UNIX_ADDR="${EPREFIX%/}/var/run/mysqld/mysqld.sock"
-DINSTALL_UNIX_ADDRDIR="${EPREFIX%/}/var/run/mysqld/mysqld.sock"
# The build forces this to be defined when cross-compiling. We pass it
# all the time for simplicity and to make sure it is actually correct.
-DSTACK_DIRECTION=$(tc-stack-grows-down && echo -1 || echo 1)
-DWITHOUT_CLIENTLIBS=YES
-DWITH_READLINE=$(usex bindist 1 0)
-DNOT_FOR_DISTRIBUTION=$(usex bindist 0 1)
-DENABLE_DTRACE=$(usex systemtap)
)
if use test ; then
mycmakeargs+=( -DINSTALL_MYSQLTESTDIR=share/mariadb/mysql-test )
else
mycmakeargs+=( -DINSTALL_MYSQLTESTDIR='' )
fi
if ! use yassl ; then
mycmakeargs+=( -DWITH_SSL=system )
else
mycmakeargs+=( -DWITH_SSL=bundled )
fi
if use server ; then
# Federated{,X} must be treated special otherwise they will not be built as plugins
if ! use extraengine ; then
mycmakeargs+=(
-DWITHOUT_FEDERATED_STORAGE_ENGINE=1
-DWITHOUT_FEDERATEDX_STORAGE_ENGINE=1 )
fi
mycmakeargs+=(
-DWITH_JEMALLOC=$(usex jemalloc system)
-DWITH_PCRE=system
-D$(usex sphinx WITH WITHOUT)_SPHINX_STORAGE_ENGINE=1
-D$(usex tokudb WITH WITHOUT)_TOKUDB_STORAGE_ENGINE=1
-D$(usex oqgraph WITH WITHOUT)_AUTH_PAM=1
-D$(usex extraengine WITH WITHOUT)_SEQUENCE_STORAGE_ENGINE=1
-D$(usex extraengine WITH WITHOUT)_SPIDER_STORAGE_ENGINE=1
-D$(usex extraengine WITH WITHOUT)_CONNECT_STORAGE_ENGINE=1
-DCONNECT_WITH_LIBXML2=$(usex xml)
-DCONNECT_WITH_ODBC=$(usex odbc)
-DCONNECT_WITH_JDBC=$(usex jdbc)
# Build failure and autodep wrt bug 639144
-DCONNECT_WITH_MONGO=OFF
-DWITH_WSREP=ON
-DINSTALL_SQLBENCHDIR=share/mariadb
)
# Workaround for MDEV-14524
use tokudb && mycmakeargs+=( -DTOKUDB_OK=1 )
if [[ ( -n ${MYSQL_DEFAULT_CHARSET} ) && ( -n ${MYSQL_DEFAULT_COLLATION} ) ]]; then
ewarn "You are using a custom charset of ${MYSQL_DEFAULT_CHARSET}"
ewarn "and a collation of ${MYSQL_DEFAULT_COLLATION}."
ewarn "You MUST file bugs without these variables set."
mycmakeargs+=(
-DDEFAULT_CHARSET=${MYSQL_DEFAULT_CHARSET}
-DDEFAULT_COLLATION=${MYSQL_DEFAULT_COLLATION}
)
elif ! use latin1 ; then
mycmakeargs+=(
-DDEFAULT_CHARSET=utf8
-DDEFAULT_COLLATION=utf8_general_ci
)
else
mycmakeargs+=(
-DDEFAULT_CHARSET=latin1
-DDEFAULT_COLLATION=latin1_swedish_ci
)
fi
mycmakeargs+=(
-DEXTRA_CHARSETS=all
-DDISABLE_SHARED=$(usex static YES NO)
-DWITH_EMBEDDED_SERVER=OFF
-DENABLED_PROFILING=$(usex profiling)
)
if use static; then
mycmakeargs+=( -DWITH_PIC=1 )
fi
if use jemalloc || use tcmalloc ; then
mycmakeargs+=( -DWITH_SAFEMALLOC=OFF )
fi
# Storage engines
mycmakeargs+=(
-DWITH_ARCHIVE_STORAGE_ENGINE=1
-DWITH_BLACKHOLE_STORAGE_ENGINE=1
-DWITH_CSV_STORAGE_ENGINE=1
-DWITH_HEAP_STORAGE_ENGINE=1
-DWITH_INNOBASE_STORAGE_ENGINE=1
-DWITH_MYISAMMRG_STORAGE_ENGINE=1
-DWITH_MYISAM_STORAGE_ENGINE=1
-DWITH_PARTITION_STORAGE_ENGINE=1
)
else
mycmakeargs+=(
-DWITHOUT_SERVER=1
-DWITH_EMBEDDED_SERVER=OFF
-DEXTRA_CHARSETS=none
-DINSTALL_SQLBENCHDIR=
)
fi
cmake-utils_src_configure
}
src_compile() {
cmake-utils_src_compile
}
src_install() {
cmake-utils_src_install
# Remove an unnecessary, private config header which will never match between ABIs and is not meant to be used
if [[ -f "${ED}/usr/include/mysql/server/private/config.h" ]] ; then
rm "${ED}/usr/include/mysql/server/private/config.h" || die
fi
# Make sure the vars are correctly initialized
mysql_init_vars
# Convenience links
einfo "Making Convenience links for mysqlcheck multi-call binary"
dosym "mysqlcheck" "/usr/bin/mysqlanalyze"
dosym "mysqlcheck" "/usr/bin/mysqlrepair"
dosym "mysqlcheck" "/usr/bin/mysqloptimize"
# INSTALL_LAYOUT=STANDALONE causes cmake to create a /usr/data dir
if [[ -d "${ED}/usr/data" ]] ; then
rm -Rf "${ED}/usr/data" || die
fi
# Unless they explicitly specific USE=test, then do not install the
# testsuite. It DOES have a use to be installed, esp. when you want to do a
# validation of your database configuration after tuning it.
if ! use test ; then
rm -rf "${D}/${MY_SHAREDSTATEDIR}/mysql-test"
fi
# Configuration stuff
einfo "Building default configuration ..."
insinto "${MY_SYSCONFDIR#${EPREFIX}}"
[[ -f "${S}/scripts/mysqlaccess.conf" ]] && doins "${S}"/scripts/mysqlaccess.conf
local mycnf_src="my.cnf-5.6"
sed -e "s!@DATADIR@!${MY_DATADIR}!g" \
"${FILESDIR}/${mycnf_src}" \
> "${TMPDIR}/my.cnf.ok" || die
use prefix && sed -i -r -e '/^user[[:space:]]*=[[:space:]]*mysql$/d' "${TMPDIR}/my.cnf.ok"
if use latin1 ; then
sed -i \
-e "/character-set/s|utf8|latin1|g" \
"${TMPDIR}/my.cnf.ok" || die
fi
eprefixify "${TMPDIR}/my.cnf.ok"
newins "${TMPDIR}/my.cnf.ok" my.cnf
if use server ; then
einfo "Including support files and sample configurations"
docinto "support-files"
local script
for script in \
"${S}"/support-files/magic
do
[[ -f "$script" ]] && dodoc "${script}"
done
docinto "scripts"
for script in "${S}"/scripts/mysql* ; do
[[ ( -f "$script" ) && ( "${script%.sh}" == "${script}" ) ]] && dodoc "${script}"
done
# Manually install supporting files that conflict with other packages
# but are needed for galera and initial installation
exeinto /usr/libexec/mariadb
doexe "${BUILD_DIR}/extra/my_print_defaults" "${BUILD_DIR}/extra/perror"
fi
#Remove mytop if perl is not selected
[[ -e "${ED}/usr/bin/mytop" ]] && ! use perl && rm -f "${ED}/usr/bin/mytop"
}
# Official test instructions:
# USE='extraengine perl server' \
# FEATURES='test userpriv -usersandbox' \
# ebuild mariadb-X.X.XX.ebuild \
# digest clean package
src_test() {
_disable_test() {
local rawtestname reason
rawtestname="${1}" ; shift
reason="${@}"
ewarn "test '${rawtestname}' disabled: '${reason}'"
echo ${rawtestname} : ${reason} >> "${T}/disabled.def"
}
local TESTDIR="${BUILD_DIR}/mysql-test"
local retstatus_unit
local retstatus_tests
if ! use server ; then
einfo "Skipping server tests due to minimal build."
return 0
fi
# Bug #213475 - MySQL _will_ object strenously if your machine is named
# localhost. Also causes weird failures.
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
if [[ $UID -eq 0 ]]; then
die "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
fi
has usersandbox $FEATURES && ewarn "Some tests may fail with FEATURES=usersandbox"
einfo ">>> Test phase [test]: ${CATEGORY}/${PF}"
# Run CTest (test-units)
cmake-utils_src_test
retstatus_unit=$?
# Ensure that parallel runs don't die
export MTR_BUILD_THREAD="$((${RANDOM} % 100))"
# Enable parallel testing, auto will try to detect number of cores
# You may set this by hand.
# The default maximum is 8 unless MTR_MAX_PARALLEL is increased
export MTR_PARALLEL="${MTR_PARALLEL:-auto}"
# create directories because mysqladmin might run out of order
mkdir -p "${T}"/var-tests{,/log} || die
# Run mysql tests
pushd "${TESTDIR}" > /dev/null || die
touch "${T}/disabled.def"
# These are failing in MariaDB 10.0 for now and are believed to be
# false positives:
#
# main.mysql_client_test, main.mysql_client_test_nonblock
# main.mysql_client_test_comp:
# segfaults at random under Portage only, suspect resource limits.
local t
for t in main.mysql_client_test main.mysql_client_test_nonblock \
main.mysql_client_test_comp rpl.rpl_extra_col_master_myisam ; do
_disable_test "$t" "False positives in Gentoo"
done
if ! use client-libs ; then
_disable_test main.plugin_auth "Needs client libraries built"
fi
# run mysql-test tests
perl mysql-test-run.pl --force --vardir="${T}/var-tests" --reorder --skip-test=tokudb --skip-test-list="${T}/disabled.def"
retstatus_tests=$?
popd > /dev/null || die
# Cleanup is important for these testcases.
pkill -9 -f "${S}/ndb" 2>/dev/null
pkill -9 -f "${S}/sql" 2>/dev/null
local failures=""
[[ $retstatus_unit -eq 0 ]] || failures="${failures} test-unit"
[[ $retstatus_tests -eq 0 ]] || failures="${failures} tests"
[[ -z "$failures" ]] || die "Test failures: $failures"
einfo "Tests successfully completed"
}
mysql_init_vars() {
MY_SHAREDSTATEDIR=${MY_SHAREDSTATEDIR="${EPREFIX}/usr/share/mariadb"}
MY_SYSCONFDIR=${MY_SYSCONFDIR="${EPREFIX}/etc/mysql"}
MY_LOCALSTATEDIR=${MY_LOCALSTATEDIR="${EPREFIX}/var/lib/mysql"}
MY_LOGDIR=${MY_LOGDIR="${EPREFIX}/var/log/mysql"}
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR=""
if [[ -f "${MY_SYSCONFDIR}/my.cnf" ]] ; then
MY_DATADIR=`"my_print_defaults" mysqld 2>/dev/null \
| sed -ne '/datadir/s|^--datadir=||p' \
| tail -n1`
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR=`grep ^datadir "${MY_SYSCONFDIR}/my.cnf" \
| sed -e 's/.*=\s*//' \
| tail -n1`
fi
fi
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR="${MY_LOCALSTATEDIR}"
einfo "Using default MY_DATADIR"
fi
elog "MySQL MY_DATADIR is ${MY_DATADIR}"
if [[ -z "${PREVIOUS_DATADIR}" ]] ; then
if [[ -e "${MY_DATADIR}" ]] ; then
# If you get this and you're wondering about it, see bug #207636
elog "MySQL datadir found in ${MY_DATADIR}"
elog "A new one will not be created."
PREVIOUS_DATADIR="yes"
else
PREVIOUS_DATADIR="no"
fi
export PREVIOUS_DATADIR
fi
else
if [[ ${EBUILD_PHASE} == "config" ]]; then
local new_MY_DATADIR
new_MY_DATADIR=`"my_print_defaults" mysqld 2>/dev/null \
| sed -ne '/datadir/s|^--datadir=||p' \
| tail -n1`
if [[ ( -n "${new_MY_DATADIR}" ) && ( "${new_MY_DATADIR}" != "${MY_DATADIR}" ) ]]; then
ewarn "MySQL MY_DATADIR has changed"
ewarn "from ${MY_DATADIR}"
ewarn "to ${new_MY_DATADIR}"
MY_DATADIR="${new_MY_DATADIR}"
fi
fi
fi
export MY_SHAREDSTATEDIR MY_SYSCONFDIR
export MY_LOCALSTATEDIR MY_LOGDIR
export MY_DATADIR
}
pkg_config() {
_getoptval() {
local mypd="${EROOT}"/usr/bin/my_print_defaults
local section="$1"
local flag="--${2}="
local extra_options="${3}"
"${mypd}" $extra_options $section | sed -n "/^${flag}/s,${flag},,gp"
}
local old_MY_DATADIR="${MY_DATADIR}"
local old_HOME="${HOME}"
# my_print_defaults needs to read stuff in $HOME/.my.cnf
export HOME=${EPREFIX}/root
# Make sure the vars are correctly initialized
mysql_init_vars
[[ -z "${MY_DATADIR}" ]] && die "Sorry, unable to find MY_DATADIR"
if [[ ! -x "${EROOT}/usr/sbin/mysqld" ]] ; then
die "Minimal builds do NOT include the MySQL server"
fi
if [[ ( -n "${MY_DATADIR}" ) && ( "${MY_DATADIR}" != "${old_MY_DATADIR}" ) ]]; then
local MY_DATADIR_s="${ROOT}/${MY_DATADIR}"
MY_DATADIR_s="${MY_DATADIR_s%%/}"
local old_MY_DATADIR_s="${ROOT}/${old_MY_DATADIR}"
old_MY_DATADIR_s="${old_MY_DATADIR_s%%/}"
if [[ ( -d "${old_MY_DATADIR_s}" ) && ( "${old_MY_DATADIR_s}" != / ) ]]; then
if [[ -d "${MY_DATADIR_s}" ]]; then
ewarn "Both ${old_MY_DATADIR_s} and ${MY_DATADIR_s} exist"
ewarn "Attempting to use ${MY_DATADIR_s} and preserving ${old_MY_DATADIR_s}"
else
elog "Moving MY_DATADIR from ${old_MY_DATADIR_s} to ${MY_DATADIR_s}"
mv --strip-trailing-slashes -T "${old_MY_DATADIR_s}" "${MY_DATADIR_s}" \
|| die "Moving MY_DATADIR failed"
fi
else
ewarn "Previous MY_DATADIR (${old_MY_DATADIR_s}) does not exist"
if [[ -d "${MY_DATADIR_s}" ]]; then
ewarn "Attempting to use ${MY_DATADIR_s}"
else
eerror "New MY_DATADIR (${MY_DATADIR_s}) does not exist"
die "Configuration Failed! Please reinstall ${CATEGORY}/${PN}"
fi
fi
fi
local pwd1="a"
local pwd2="b"
local maxtry=15
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
local tmp_mysqld_password_source=
for tmp_mysqld_password_source in mysql client; do
einfo "Trying to get password for mysql 'root' user from '${tmp_mysqld_password_source}' section ..."
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password)"
if [[ -n "${MYSQL_ROOT_PASSWORD}" ]]; then
if [[ ${MYSQL_ROOT_PASSWORD} == *$'\n'* ]]; then
ewarn "Ignoring password from '${tmp_mysqld_password_source}' section due to newline character (do you have multiple password options set?)!"
MYSQL_ROOT_PASSWORD=
continue
fi
einfo "Found password in '${tmp_mysqld_password_source}' section!"
break
fi
done
# Sometimes --show is required to display passwords in some implementations of my_print_defaults
if [[ "${MYSQL_ROOT_PASSWORD}" == '*****' ]]; then
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password --show)"
fi
unset tmp_mysqld_password_source
fi
MYSQL_TMPDIR="$(_getoptval mysqld tmpdir)"
# These are dir+prefix
MYSQL_RELAY_LOG="$(_getoptval mysqld relay-log)"
MYSQL_RELAY_LOG=${MYSQL_RELAY_LOG%/*}
MYSQL_LOG_BIN="$(_getoptval mysqld log-bin)"
MYSQL_LOG_BIN=${MYSQL_LOG_BIN%/*}
if [[ ! -d "${ROOT}/$MYSQL_TMPDIR" ]]; then
einfo "Creating MySQL tmpdir $MYSQL_TMPDIR"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_TMPDIR"
fi
if [[ ! -d "${ROOT}/$MYSQL_LOG_BIN" ]]; then
einfo "Creating MySQL log-bin directory $MYSQL_LOG_BIN"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_LOG_BIN"
fi
if [[ ! -d "${EROOT}/$MYSQL_RELAY_LOG" ]]; then
einfo "Creating MySQL relay-log directory $MYSQL_RELAY_LOG"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_RELAY_LOG"
fi
if [[ -d "${ROOT}/${MY_DATADIR}/mysql" ]] ; then
ewarn "You have already a MySQL database in place."
ewarn "(${ROOT}/${MY_DATADIR}/*)"
ewarn "Please rename or delete it if you wish to replace it."
die "MySQL database already exists!"
fi
# Bug #213475 - MySQL _will_ object strenously if your machine is named
# localhost. Also causes weird failures.
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
einfo "Please provide a password for the mysql 'root' user now"
einfo "or through the ${HOME}/.my.cnf file."
ewarn "Avoid [\"'\\_%] characters in the password"
read -rsp " >" pwd1 ; echo
einfo "Retype the password"
read -rsp " >" pwd2 ; echo
if [[ "x$pwd1" != "x$pwd2" ]] ; then
die "Passwords are not the same"
fi
MYSQL_ROOT_PASSWORD="${pwd1}"
unset pwd1 pwd2
fi
local options
local sqltmp="$(emktemp)"
# Fix bug 446200. Don't reference host my.cnf, needs to come first,
# see https://bugs.mysql.com/bug.php?id=31312
use prefix && options="${options} '--defaults-file=${MY_SYSCONFDIR}/my.cnf'"
# Figure out which options we need to disable to do the setup
local helpfile="${TMPDIR}/mysqld-help"
"${EROOT}/usr/sbin/mysqld" --verbose --help >"${helpfile}" 2>/dev/null
for opt in grant-tables host-cache name-resolve networking slave-start \
federated ssl log-bin relay-log slow-query-log external-locking \
log-slave-updates \
; do
optexp="--(skip-)?${opt}" optfull="--loose-skip-${opt}"
egrep -sq -- "${optexp}" "${helpfile}" && options="${options} ${optfull}"
done
einfo "Creating the mysql database and setting proper permissions on it ..."
# Now that /var/run is a tmpfs mount point, we need to ensure it exists before using it
PID_DIR="${EROOT}/var/run/mysqld"
if [[ ! -d "${PID_DIR}" ]]; then
install -d -m 755 -o mysql -g mysql "${PID_DIR}" || die "Could not create pid directory"
fi
if [[ ! -d "${MY_DATADIR}" ]]; then
install -d -m 750 -o mysql -g mysql "${MY_DATADIR}" || die "Could not create data directory"
fi
pushd "${TMPDIR}" &>/dev/null || die
# Filling timezones, see
# https://dev.mysql.com/doc/mysql/en/time-zone-support.html
"${EROOT}/usr/bin/mysql_tzinfo_to_sql" "${EROOT}/usr/share/zoneinfo" > "${sqltmp}" 2>/dev/null
local cmd=( "${EROOT}usr/share/mariadb/scripts/mysql_install_db" )
[[ -f "${cmd}" ]] || cmd=( "${EROOT}usr/bin/mysql_install_db" )
cmd+=( "--basedir=${EPREFIX}/usr" ${options} "--datadir=${ROOT}/${MY_DATADIR}" "--tmpdir=${ROOT}/${MYSQL_TMPDIR}" )
einfo "Command: ${cmd[*]}"
su -s /bin/sh -c "${cmd[*]}" mysql \
>"${TMPDIR}"/mysql_install_db.log 2>&1
if [ $? -ne 0 ]; then
grep -B5 -A999 -i "ERROR" "${TMPDIR}"/mysql_install_db.log 1>&2
die "Failed to initialize mysqld. Please review ${EPREFIX}/var/log/mysql/mysqld.err AND ${TMPDIR}/mysql_install_db.log"
fi
popd &>/dev/null || die
[[ -f "${ROOT}/${MY_DATADIR}/mysql/user.frm" ]] \
|| die "MySQL databases not installed"
use prefix || options="${options} --user=mysql"
local socket="${EROOT}/var/run/mysqld/mysqld${RANDOM}.sock"
local pidfile="${EROOT}/var/run/mysqld/mysqld${RANDOM}.pid"
local mysqld="${EROOT}/usr/sbin/mysqld \
${options} \
--log-warnings=0 \
--basedir=${EROOT}/usr \
--datadir=${ROOT}/${MY_DATADIR} \
--max_allowed_packet=8M \
--net_buffer_length=16K \
--socket=${socket} \
--pid-file=${pidfile} \
--tmpdir=${ROOT}/${MYSQL_TMPDIR}"
ebegin "Starting mysqld"
einfo "Command ${mysqld}"
${mysqld} &
rc=$?
while ! [[ -S "${socket}" || "${maxtry}" -lt 1 ]] ; do
maxtry=$((${maxtry}-1))
echo -n "."
sleep 1
done
eend $rc
if ! [[ -S "${socket}" ]]; then
die "Completely failed to start up mysqld with: ${mysqld}"
fi
ebegin "Setting root password"
# Do this from memory, as we don't want clear text passwords in temp files
local sql="UPDATE mysql.user SET Password = PASSWORD('${MYSQL_ROOT_PASSWORD}') WHERE USER='root'; FLUSH PRIVILEGES"
"${EROOT}/usr/bin/mysql" \
"--socket=${socket}" \
-hlocalhost \
-e "${sql}"
eend $?
if [[ -n "${sqltmp}" ]] ; then
ebegin "Loading \"zoneinfo\", this step may require a few seconds"
"${EROOT}/usr/bin/mysql" \
"--socket=${socket}" \
-hlocalhost \
-uroot \
--password="${MYSQL_ROOT_PASSWORD}" \
mysql < "${sqltmp}"
rc=$?
eend $?
[[ $rc -ne 0 ]] && ewarn "Failed to load zoneinfo!"
fi
# Stop the server and cleanup
einfo "Stopping the server ..."
kill $(< "${pidfile}" )
rm -f "${sqltmp}"
wait %1
einfo "Done"
}

@ -1,26 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="project">
<email>mysql-bugs@gentoo.org</email>
<name>MySQL</name>
</maintainer>
<use>
<flag name="client-libs">Build the client libraries from the server package instead of the C Connector packages</flag>
<flag name="extraengine">Add support for alternative storage engines (Archive, CSV, Blackhole, Federated(X), Partition)</flag>
<flag name="jdbc">Enable the CONNECT engine to access foreign databases via JDBC</flag>
<flag name="latin1">Use LATIN1 encoding instead of UTF8</flag>
<flag name="libressl">Enable SSL connections and crypto functions using <pkg>dev-libs/libressl</pkg></flag>
<flag name="numa">Enable NUMA support using <pkg>sys-process/numactl</pkg> (NUMA kernel support is also required)</flag>
<flag name="oqgraph">Add support for the Open Query GRAPH engine</flag>
<flag name="profiling">Add support for statement profiling (requires USE=community).</flag>
<flag name="server">Build the server program</flag>
<flag name="sst-rsync">Add tools needed to support the rsync SST method</flag>
<flag name="sst-xtrabackup">Add tools needed to support the xtrabackup and xtrabackup-v2 SST methods</flag>
<flag name="systemtap">Build support for profiling and tracing using <pkg>dev-util/systemtap</pkg></flag>
<flag name="sphinx">Add suport for the sphinx full-text search engine</flag>
<flag name="test">Install upstream testsuites for end use.</flag>
<flag name="tokudb">Add support for TokuDB storage engine</flag>
<flag name="yassl">Enable SSL connections and crypto functions using the bundled yaSSL</flag>
</use>
</pkgmetadata>

@ -1,6 +1,3 @@
DIST mariadb-10.0.35.tar.gz 66551252 BLAKE2B 69cc9c78f7c47a4b1760940cb0f395b4053fcc47c1087a0c2af873d4a998ee60915e1f4e64f7fe6474c7c1fa3dabe48a3b6621c67893b20526f01e56b0542e7a SHA512 01fc8d48be3f3847bb222835436ab938c6c5b5ac8ba6cc87b3b6d2a2201b7ab4b152dc1f7d9749c89de90097d50052714ac08aafbbb117fffac32bfb47e74779
DIST mariadb-10.0.37.tar.gz 64728382 BLAKE2B 3d794633cc400013be05c326681f11f8b27c7d6758b43f357ca93976a75ff931f6f6d205510b5df305c6f487485864d346e4fa14383be32dafcf2b8756eb045a SHA512 c3ba749f519cce3bb63fec6ee6819ad931f72d54258d4b7700c515cfeb137453271a408a9a353bf78715fe66a0c06539bdbf15f1c556a7b89a5c01af84f7fd49
DIST mariadb-10.0.38.tar.gz 64755921 BLAKE2B 64ea08a2256063639021204f8c92d8f27b2bc0df6c9733255220df5728c128bd971bb907f2a30623a1c2cc536d47b8759781f2ccd97075ebace7c759b5cf0c14 SHA512 020c9b8bed5f5ff4e8f621665cc37f56fe9fbb4bda1f64d4bd9fe1bcaaf79dc2c254e582ee690c9aa4f810cf3eeb96249cb3b4b54a6604d035accf03846ba4a9
DIST mariadb-10.1.34.tar.gz 65298561 BLAKE2B 3f3af7b8bad68a08f69befd3f3e7bd88b8cf058feb20309dc2cdbd16bf5d015c2cb0d1d9d2fdf831f6183c0b9bb25405124c24b2940467489e05d42c57f7b0a6 SHA512 3c18359006b340dcf724d1fce36dcc19916c42492269a7545e0726172b8f7b84860e10725c74e4458dae34572395f1650bf17838e9058544e0a6cfcbffd54f6d
DIST mariadb-10.1.37.tar.gz 63492946 BLAKE2B 0f19b402c597443ef970cbe2a2d85d51743cc2d05ab741897efb150f007d7be8b645706a2d0dc5a9f91c7a380d2313840f77d6e9b15f3335495f275b415e5a33 SHA512 b7c35cd67ad265ce2e3a4db20a2ae2b78745db96dc70a211f027a39b6dbb3dc900991c2ee1021ee6a97d12489c3e2a70252e2adf348a458af38b99c3de5a4f25
DIST mariadb-10.1.38.tar.gz 63535685 BLAKE2B c179ea2f60287c2bc1c0d1c47ae989ac2653a24063e8344cef2f3062fc6798e18b969e8f9aa8287104ce2518e6c644cb8d3a4650b5a0bc5dfde973e76e618955 SHA512 184582f3a902a989ba3d9c4d21288c014c8b469adbbb4cbabc621c5006022cef29baed8c1140ed4476b124da83b76dfa414295ed0c3374be826e75aca953a77b

@ -1,848 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
MY_EXTRAS_VER="20180809-1700Z"
SUBSLOT="18"
JAVA_PKG_OPT_USE="jdbc"
# Keeping eutils in EAPI=6 for emktemp in pkg_config
inherit eutils flag-o-matic prefix toolchain-funcs java-pkg-opt-2 user cmake-utils multilib-build
SRC_URI="https://downloads.mariadb.org/interstitial/${P}/source/${P}.tar.gz "
# Gentoo patches to MySQL
if [[ "${MY_EXTRAS_VER}" != "live" && "${MY_EXTRAS_VER}" != "none" ]]; then
SRC_URI="${SRC_URI}
mirror://gentoo/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://gitweb.gentoo.org/proj/mysql-extras.git/snapshot/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~grknight/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~robbat2/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~jmbsvicetto/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2"
fi
HOMEPAGE="https://mariadb.org/"
DESCRIPTION="An enhanced, drop-in replacement for MySQL"
LICENSE="GPL-2"
SLOT="0/${SUBSLOT:-0}"
IUSE="bindist client-libs debug extraengine jdbc jemalloc latin1 libressl
numa odbc oqgraph pam +perl profiling selinux +server sphinx
static static-libs systemtap tcmalloc
test tokudb xml yassl"
# Tests always fail when libressl is enabled due to hard-coded ciphers in the tests
RESTRICT="!bindist? ( bindist ) libressl? ( test )"
REQUIRED_USE="jdbc? ( extraengine server !static )
server? ( tokudb? ( jemalloc !tcmalloc ) )
?? ( tcmalloc jemalloc )
static? ( yassl !pam )"
KEYWORDS="alpha amd64 arm ~arm64 ~hppa ia64 ~mips ppc ppc64 ~s390 ~sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
# Shorten the path because the socket path length must be shorter than 107 chars
# and we will run a mysql server during test phase
S="${WORKDIR}/mysql"
if [[ "${MY_EXTRAS_VER}" == "live" ]] ; then
MY_PATCH_DIR="${WORKDIR%/}/mysql-extras"
inherit git-r3
EGIT_REPO_URI="git://anongit.gentoo.org/proj/mysql-extras.git"
EGIT_CHECKOUT_DIR="${WORKDIR%/}/mysql-extras"
EGIT_CLONE_TYPE=shallow
else
MY_PATCH_DIR="${WORKDIR%/}/mysql-extras-${MY_EXTRAS_VER}"
fi
PATCHES=(
"${MY_PATCH_DIR}/01050_all_mariadb_mysql_config_cleanup-5.5.41.patch"
"${MY_PATCH_DIR}/20006_all_cmake_elib-mariadb-10.0.33.patch"
"${MY_PATCH_DIR}/20009_all_mariadb_myodbc_symbol_fix-5.5.38.patch"
"${MY_PATCH_DIR}/20018_all_mariadb-10.0.20-without-clientlibs-tools.patch"
)
# Be warned, *DEPEND are version-dependant
# These are used for both runtime and compiletime
COMMON_DEPEND="
kernel_linux? (
sys-process/procps:0=
dev-libs/libaio:0=
)
>=sys-apps/sed-4
>=sys-apps/texinfo-4.7-r1
jemalloc? ( dev-libs/jemalloc:0= )
tcmalloc? ( dev-util/google-perftools:0= )
systemtap? ( >=dev-util/systemtap-1.3:0= )
!yassl? (
!libressl? ( dev-libs/openssl:0= !>=dev-libs/openssl-1.1 )
libressl? ( dev-libs/libressl:0= )
)
>=sys-libs/zlib-1.2.3:0=
sys-libs/ncurses:0=
!bindist? (
>=sys-libs/readline-4.1:0=
)
server? (
extraengine? (
odbc? ( dev-db/unixODBC:0= )
xml? ( dev-libs/libxml2:2= )
)
numa? ( sys-process/numactl )
oqgraph? ( >=dev-libs/boost-1.40.0:0= dev-libs/judy:0= )
pam? ( virtual/pam:0= )
tokudb? ( app-arch/snappy )
)
>=dev-libs/libpcre-8.41-r1:3=
!client-libs? ( dev-db/mysql-connector-c[${MULTILIB_USEDEP},static-libs?] )
"
DEPEND="virtual/yacc
static? ( sys-libs/ncurses[static-libs] )
|| ( >=sys-devel/gcc-3.4.6 >=sys-devel/gcc-apple-4.0 )
server? ( extraengine? ( jdbc? ( >=virtual/jdk-1.6 ) ) )
${COMMON_DEPEND}"
RDEPEND="selinux? ( sec-policy/selinux-mysql )
client-libs? ( !dev-db/mariadb-connector-c[mysqlcompat] !dev-db/mysql-connector-c )
!dev-db/mysql !dev-db/mariadb-galera !dev-db/percona-server !dev-db/mysql-cluster
server? ( !prefix? ( dev-db/mysql-init-scripts ) )
${COMMON_DEPEND}
perl? ( !dev-db/mytop
virtual/perl-Getopt-Long
dev-perl/TermReadKey
virtual/perl-Term-ANSIColor
virtual/perl-Time-HiRes )
server? ( extraengine? ( jdbc? ( >=virtual/jre-1.6 ) ) )
"
# For other stuff to bring us in
# dev-perl/DBD-mysql is needed by some scripts installed by MySQL
PDEPEND="perl? ( >=dev-perl/DBD-mysql-2.9004 )"
pkg_setup() {
if [[ ${MERGE_TYPE} != binary ]] ; then
local GCC_MAJOR_SET=$(gcc-major-version)
local GCC_MINOR_SET=$(gcc-minor-version)
if use tokudb && [[ ${GCC_MAJOR_SET} -lt 4 || \
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
eerror "${PN} with tokudb needs to be built with gcc-4.7 or later."
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
die
fi
# Bug 565584. InnoDB now requires atomic functions introduced with gcc-4.7 on
# non x86{,_64} arches
if ! use amd64 && ! use x86 && [[ ${GCC_MAJOR_SET} -lt 4 || \
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
eerror "${PN} needs to be built with gcc-4.7 or later."
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
die
fi
fi
java-pkg-opt-2_pkg_setup
if has test ${FEATURES} && \
use server && ! has userpriv ${FEATURES} ; then
eerror "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
fi
# This should come after all of the die statements
enewgroup mysql 60 || die "problem adding 'mysql' group"
enewuser mysql 60 -1 /dev/null mysql || die "problem adding 'mysql' user"
}
pkg_preinst() {
java-pkg-opt-2_pkg_preinst
}
pkg_postinst() {
# Make sure the vars are correctly initialized
mysql_init_vars
# Create log directory securely if it does not exist
[[ -d "${ROOT}${MY_LOGDIR}" ]] || install -d -m0750 -o mysql -g mysql "${ROOT}${MY_LOGDIR}"
if use server ; then
if use pam; then
einfo
elog "This install includes the PAM authentication plugin."
elog "To activate and configure the PAM plugin, please read:"
elog "https://mariadb.com/kb/en/mariadb/pam-authentication-plugin/"
einfo
fi
if [[ -z "${REPLACING_VERSIONS}" ]] ; then
einfo
elog "You might want to run:"
elog "\"emerge --config =${CATEGORY}/${PF}\""
elog "if this is a new install."
elog
elog "If you are switching server implentations, you should run the"
elog "mysql_upgrade tool."
einfo
else
einfo
elog "If you are upgrading major versions, you should run the"
elog "mysql_upgrade tool."
einfo
fi
einfo
elog "Be sure to edit the my.cnf file to activate your cluster settings."
elog "This should be done after running \"emerge --config =${CATEGORY}/${PF}\""
elog "The first time the cluster is activated, you should add"
elog "--wsrep-new-cluster to the options in /etc/conf.d/mysql for one node."
elog "This option should then be removed for subsequent starts."
einfo
fi
}
src_unpack() {
unpack ${A}
# Grab the patches
[[ "${MY_EXTRAS_VER}" == "live" ]] && S="${WORKDIR%/}/mysql-extras" git-r3_src_unpack
mv -f "${WORKDIR%/}/${P}" "${S}" || die
}
src_prepare() {
_disable_engine() {
echo > "${S%/}/storage/${1}/CMakeLists.txt" || die
}
_disable_plugin() {
echo > "${S%/}/plugin/${1}/CMakeLists.txt" || die
}
if use tcmalloc; then
echo "TARGET_LINK_LIBRARIES(mysqld tcmalloc)" >> "${S%/}/sql/CMakeLists.txt" || die
fi
# Don't build bundled xz-utils for tokudb
echo > "${S%/}/storage/tokudb/PerconaFT/cmake_modules/TokuThirdParty.cmake" || die
sed -i -e 's/ build_lzma//' -e 's/ build_snappy//' "${S%/}/storage/tokudb/PerconaFT/ft/CMakeLists.txt" || die
sed -i -e 's/add_dependencies\(tokuportability_static_conv build_jemalloc\)//' "${S%/}/storage/tokudb/PerconaFT/portability/CMakeLists.txt" || die
local plugin
local server_plugins=( handler_socket auth_socket feedback metadata_lock_info
locale_info qc_info server_audit semisync sql_errlog )
local test_plugins=( audit_null auth_examples daemon_example fulltext )
if ! use server; then # These plugins are for the server
for plugin in "${server_plugins[@]}" ; do
_disable_plugin "${plugin}"
done
fi
if ! use test; then # These plugins are only used during testing
for plugin in "${test_plugins[@]}" ; do
_disable_plugin "${plugin}"
done
fi
# Collides with mariadb-connector-c bug 655980
_disable_plugin auth_dialog
# Don't build Mroonga or example
_disable_engine mroonga
_disable_engine example
if ! use oqgraph ; then # avoids extra library checks
_disable_engine oqgraph
fi
cmake-utils_src_prepare
java-pkg-opt-2_src_prepare
}
src_configure(){
# bug 508724 mariadb cannot use ld.gold
tc-ld-disable-gold
# Bug #114895, bug #110149
filter-flags "-O" "-O[01]"
append-cxxflags -felide-constructors
# bug #283926, with GCC4.4, this is required to get correct behavior.
append-flags -fno-strict-aliasing
CMAKE_BUILD_TYPE="RelWithDebInfo"
# debug hack wrt #497532
mycmakeargs=(
-DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
-DCMAKE_INSTALL_PREFIX="${EPREFIX%/}/usr"
-DDEFAULT_SYSCONFDIR="${EPREFIX%/}/etc/mysql"
-DINSTALL_BINDIR=bin
-DINSTALL_DOCDIR=share/doc/${PF}
-DINSTALL_DOCREADMEDIR=share/doc/${PF}
-DINSTALL_INCLUDEDIR=include/mysql
-DINSTALL_INFODIR=share/info
-DINSTALL_LIBDIR=$(get_libdir)
-DINSTALL_MANDIR=share/man
-DINSTALL_MYSQLSHAREDIR=share/mariadb
-DINSTALL_PLUGINDIR=$(get_libdir)/mariadb/plugin
-DINSTALL_SCRIPTDIR=share/mariadb/scripts
-DINSTALL_MYSQLDATADIR="${EPREFIX%/}/var/lib/mysql"
-DINSTALL_SBINDIR=sbin
-DINSTALL_SUPPORTFILESDIR="${EPREFIX%/}/usr/share/mariadb"
-DCOMPILATION_COMMENT="Gentoo Linux ${PF}"
-DWITH_UNIT_TESTS=$(usex test ON OFF)
-DWITH_ZLIB=system
-DENABLED_LOCAL_INFILE=1
-DMYSQL_UNIX_ADDR="${EPREFIX%/}/var/run/mysqld/mysqld.sock"
-DINSTALL_UNIX_ADDRDIR="${EPREFIX%/}/var/run/mysqld/mysqld.sock"
# The build forces this to be defined when cross-compiling. We pass it
# all the time for simplicity and to make sure it is actually correct.
-DSTACK_DIRECTION=$(tc-stack-grows-down && echo -1 || echo 1)
-DWITHOUT_CLIENTLIBS=YES
-DWITH_READLINE=$(usex bindist 1 0)
-DNOT_FOR_DISTRIBUTION=$(usex bindist 0 1)
-DENABLE_DTRACE=$(usex systemtap)
)
if use test ; then
mycmakeargs+=( -DINSTALL_MYSQLTESTDIR=share/mariadb/mysql-test )
else
mycmakeargs+=( -DINSTALL_MYSQLTESTDIR='' )
fi
if ! use yassl ; then
mycmakeargs+=( -DWITH_SSL=system )
else
mycmakeargs+=( -DWITH_SSL=bundled )
fi
if use server ; then
# Federated{,X} must be treated special otherwise they will not be built as plugins
if ! use extraengine ; then
mycmakeargs+=(
-DWITHOUT_FEDERATED_STORAGE_ENGINE=1
-DWITHOUT_FEDERATEDX_STORAGE_ENGINE=1 )
fi
mycmakeargs+=(
-DWITH_JEMALLOC=$(usex jemalloc system)
-DWITH_PCRE=system
-D$(usex sphinx WITH WITHOUT)_SPHINX_STORAGE_ENGINE=1
-D$(usex tokudb WITH WITHOUT)_TOKUDB_STORAGE_ENGINE=1
-D$(usex oqgraph WITH WITHOUT)_AUTH_PAM=1
-D$(usex extraengine WITH WITHOUT)_SEQUENCE_STORAGE_ENGINE=1
-D$(usex extraengine WITH WITHOUT)_SPIDER_STORAGE_ENGINE=1
-D$(usex extraengine WITH WITHOUT)_CONNECT_STORAGE_ENGINE=1
-DCONNECT_WITH_LIBXML2=$(usex xml)
-DCONNECT_WITH_ODBC=$(usex odbc)
-DCONNECT_WITH_JDBC=$(usex jdbc)
# Build failure and autodep wrt bug 639144
-DCONNECT_WITH_MONGO=OFF
-DINSTALL_SQLBENCHDIR=share/mariadb
)
if [[ ( -n ${MYSQL_DEFAULT_CHARSET} ) && ( -n ${MYSQL_DEFAULT_COLLATION} ) ]]; then
ewarn "You are using a custom charset of ${MYSQL_DEFAULT_CHARSET}"
ewarn "and a collation of ${MYSQL_DEFAULT_COLLATION}."
ewarn "You MUST file bugs without these variables set."
mycmakeargs+=(
-DDEFAULT_CHARSET=${MYSQL_DEFAULT_CHARSET}
-DDEFAULT_COLLATION=${MYSQL_DEFAULT_COLLATION}
)
elif ! use latin1 ; then
mycmakeargs+=(
-DDEFAULT_CHARSET=utf8
-DDEFAULT_COLLATION=utf8_general_ci
)
else
mycmakeargs+=(
-DDEFAULT_CHARSET=latin1
-DDEFAULT_COLLATION=latin1_swedish_ci
)
fi
mycmakeargs+=(
-DEXTRA_CHARSETS=all
-DDISABLE_SHARED=$(usex static YES NO)
-DWITH_EMBEDDED_SERVER=OFF
-DENABLED_PROFILING=$(usex profiling)
)
if use static; then
mycmakeargs+=( -DWITH_PIC=1 )
fi
if use jemalloc || use tcmalloc ; then
mycmakeargs+=( -DWITH_SAFEMALLOC=OFF )
fi
# Storage engines
mycmakeargs+=(
-DWITH_ARCHIVE_STORAGE_ENGINE=1
-DWITH_BLACKHOLE_STORAGE_ENGINE=1
-DWITH_CSV_STORAGE_ENGINE=1
-DWITH_HEAP_STORAGE_ENGINE=1
-DWITH_INNOBASE_STORAGE_ENGINE=1
-DWITH_MYISAMMRG_STORAGE_ENGINE=1
-DWITH_MYISAM_STORAGE_ENGINE=1
-DWITH_PARTITION_STORAGE_ENGINE=1
)
else
mycmakeargs+=(
-DWITHOUT_SERVER=1
-DEXTRA_CHARSETS=none
-DINSTALL_SQLBENCHDIR=
)
fi
cmake-utils_src_configure
}
src_compile() {
cmake-utils_src_compile
}
src_install() {
cmake-utils_src_install
# Remove an unnecessary, private config header which will never match between ABIs and is not meant to be used
if [[ -f "${ED%/}/usr/include/mysql/server/private/config.h" ]] ; then
rm "${ED%/}/usr/include/mysql/server/private/config.h" || die
fi
# Make sure the vars are correctly initialized
mysql_init_vars
# Convenience links
einfo "Making Convenience links for mysqlcheck multi-call binary"
dosym "mysqlcheck" "/usr/bin/mysqlanalyze"
dosym "mysqlcheck" "/usr/bin/mysqlrepair"
dosym "mysqlcheck" "/usr/bin/mysqloptimize"
# INSTALL_LAYOUT=STANDALONE causes cmake to create a /usr/data dir
if [[ -d "${ED%/}/usr/data" ]] ; then
rm -Rf "${ED%/}/usr/data" || die
fi
# Unless they explicitly specific USE=test, then do not install the
# testsuite. It DOES have a use to be installed, esp. when you want to do a
# validation of your database configuration after tuning it.
if ! use test ; then
rm -rf "${D%/}/${MY_SHAREDSTATEDIR}/mysql-test"
fi
# Configuration stuff
einfo "Building default configuration ..."
insinto "${MY_SYSCONFDIR#${EPREFIX}}"
[[ -f "${S%/}/scripts/mysqlaccess.conf" ]] && doins "${S%/}"/scripts/mysqlaccess.conf
local mycnf_src="my.cnf-5.6-r1"
sed -e "s!@DATADIR@!${MY_DATADIR}!g" \
"${FILESDIR%/}/${mycnf_src}" \
> "${TMPDIR%/}/my.cnf.ok" || die
use prefix && sed -i -r -e '/^user[[:space:]]*=[[:space:]]*mysql$/d' "${TMPDIR%/}/my.cnf.ok"
if use latin1 ; then
sed -i \
-e "/character-set/s|utf8|latin1|g" \
"${TMPDIR%/}/my.cnf.ok" || die
fi
eprefixify "${TMPDIR%/}/my.cnf.ok"
newins "${TMPDIR}/my.cnf.ok" my.cnf
if use server ; then
einfo "Including support files and sample configurations"
docinto "support-files"
local script
for script in \
"${S%/}"/support-files/magic
do
[[ -f "$script" ]] && dodoc "${script}"
done
docinto "scripts"
for script in "${S%/}"/scripts/mysql* ; do
[[ ( -f "$script" ) && ( "${script%.sh}" == "${script}" ) ]] && dodoc "${script}"
done
# Manually install supporting files that conflict with other packages
# but are needed for galera and initial installation
exeinto /usr/libexec/mariadb
doexe "${BUILD_DIR}/extra/my_print_defaults" "${BUILD_DIR}/extra/perror"
fi
#Remove mytop if perl is not selected
[[ -e "${ED%/}/usr/bin/mytop" ]] && ! use perl && rm -f "${ED%/}/usr/bin/mytop"
}
# Official test instructions:
# USE='extraengine perl server' \
# FEATURES='test userpriv -usersandbox' \
# ebuild mariadb-X.X.XX.ebuild \
# digest clean package
src_test() {
_disable_test() {
local rawtestname reason
rawtestname="${1}" ; shift
reason="${@}"
ewarn "test '${rawtestname}' disabled: '${reason}'"
echo ${rawtestname} : ${reason} >> "${T}/disabled.def"
}
local TESTDIR="${BUILD_DIR}/mysql-test"
local retstatus_unit
local retstatus_tests
if ! use server ; then
einfo "Skipping server tests due to minimal build."
return 0
fi
# Bug #213475 - MySQL _will_ object strenously if your machine is named
# localhost. Also causes weird failures.
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
if [[ $UID -eq 0 ]]; then
die "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
fi
has usersandbox $FEATURES && ewarn "Some tests may fail with FEATURES=usersandbox"
einfo ">>> Test phase [test]: ${CATEGORY}/${PF}"
# Run CTest (test-units)
cmake-utils_src_test
retstatus_unit=$?
# Ensure that parallel runs don't die
export MTR_BUILD_THREAD="$((${RANDOM} % 100))"
# Enable parallel testing, auto will try to detect number of cores
# You may set this by hand.
# The default maximum is 8 unless MTR_MAX_PARALLEL is increased
export MTR_PARALLEL="${MTR_PARALLEL:-auto}"
# create directories because mysqladmin might run out of order
mkdir -p "${T}"/var-tests{,/log} || die
# Run mysql tests
pushd "${TESTDIR}" > /dev/null || die
touch "${T}/disabled.def"
# These are failing in MariaDB 10.0 for now and are believed to be
# false positives:
#
# main.mysql_client_test, main.mysql_client_test_nonblock
# main.mysql_client_test_comp:
# segfaults at random under Portage only, suspect resource limits.
local t
for t in main.mysql_client_test main.mysql_client_test_nonblock \
main.mysql_client_test_comp rpl.rpl_extra_col_master_myisam \
rpl.rpl_semi_sync_uninstall_plugin ; do
_disable_test "$t" "False positives in Gentoo"
done
if ! use client-libs ; then
_disable_test main.plugin_auth "Needs client libraries built"
fi
# run mysql-test tests
perl mysql-test-run.pl --force --vardir="${T}/var-tests" --reorder --skip-test=tokudb --skip-test-list="${T}/disabled.def"
retstatus_tests=$?
popd > /dev/null || die
# Cleanup is important for these testcases.
pkill -9 -f "${S}/ndb" 2>/dev/null
pkill -9 -f "${S}/sql" 2>/dev/null
local failures=""
[[ $retstatus_unit -eq 0 ]] || failures="${failures} test-unit"
[[ $retstatus_tests -eq 0 ]] || failures="${failures} tests"
[[ -z "$failures" ]] || die "Test failures: $failures"
einfo "Tests successfully completed"
}
mysql_init_vars() {
MY_SHAREDSTATEDIR=${MY_SHAREDSTATEDIR="${EPREFIX}/usr/share/mariadb"}
MY_SYSCONFDIR=${MY_SYSCONFDIR="${EPREFIX}/etc/mysql"}
MY_LOCALSTATEDIR=${MY_LOCALSTATEDIR="${EPREFIX}/var/lib/mysql"}
MY_LOGDIR=${MY_LOGDIR="${EPREFIX}/var/log/mysql"}
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR=""
if [[ -f "${MY_SYSCONFDIR}/my.cnf" ]] ; then
MY_DATADIR=`"my_print_defaults" mysqld 2>/dev/null \
| sed -ne '/datadir/s|^--datadir=||p' \
| tail -n1`
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR=`grep ^datadir "${MY_SYSCONFDIR}/my.cnf" \
| sed -e 's/.*=\s*//' \
| tail -n1`
fi
fi
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR="${MY_LOCALSTATEDIR}"
einfo "Using default MY_DATADIR"
fi
elog "MySQL MY_DATADIR is ${MY_DATADIR}"
if [[ -z "${PREVIOUS_DATADIR}" ]] ; then
if [[ -e "${MY_DATADIR}" ]] ; then
# If you get this and you're wondering about it, see bug #207636
elog "MySQL datadir found in ${MY_DATADIR}"
elog "A new one will not be created."
PREVIOUS_DATADIR="yes"
else
PREVIOUS_DATADIR="no"
fi
export PREVIOUS_DATADIR
fi
else
if [[ ${EBUILD_PHASE} == "config" ]]; then
local new_MY_DATADIR
new_MY_DATADIR=`"my_print_defaults" mysqld 2>/dev/null \
| sed -ne '/datadir/s|^--datadir=||p' \
| tail -n1`
if [[ ( -n "${new_MY_DATADIR}" ) && ( "${new_MY_DATADIR}" != "${MY_DATADIR}" ) ]]; then
ewarn "MySQL MY_DATADIR has changed"
ewarn "from ${MY_DATADIR}"
ewarn "to ${new_MY_DATADIR}"
MY_DATADIR="${new_MY_DATADIR}"
fi
fi
fi
export MY_SHAREDSTATEDIR MY_SYSCONFDIR
export MY_LOCALSTATEDIR MY_LOGDIR
export MY_DATADIR
}
pkg_config() {
_getoptval() {
local mypd="${EROOT}"/usr/bin/my_print_defaults
local section="$1"
local flag="--${2}="
local extra_options="${3}"
"${mypd}" $extra_options $section | sed -n "/^${flag}/s,${flag},,gp"
}
local old_MY_DATADIR="${MY_DATADIR}"
local old_HOME="${HOME}"
# my_print_defaults needs to read stuff in $HOME/.my.cnf
export HOME=${EPREFIX}/root
# Make sure the vars are correctly initialized
mysql_init_vars
[[ -z "${MY_DATADIR}" ]] && die "Sorry, unable to find MY_DATADIR"
if [[ ! -x "${EROOT}/usr/sbin/mysqld" ]] ; then
die "Minimal builds do NOT include the MySQL server"
fi
if [[ ( -n "${MY_DATADIR}" ) && ( "${MY_DATADIR}" != "${old_MY_DATADIR}" ) ]]; then
local MY_DATADIR_s="${ROOT}/${MY_DATADIR}"
MY_DATADIR_s="${MY_DATADIR_s%%/}"
local old_MY_DATADIR_s="${ROOT}/${old_MY_DATADIR}"
old_MY_DATADIR_s="${old_MY_DATADIR_s%%/}"
if [[ ( -d "${old_MY_DATADIR_s}" ) && ( "${old_MY_DATADIR_s}" != / ) ]]; then
if [[ -d "${MY_DATADIR_s}" ]]; then
ewarn "Both ${old_MY_DATADIR_s} and ${MY_DATADIR_s} exist"
ewarn "Attempting to use ${MY_DATADIR_s} and preserving ${old_MY_DATADIR_s}"
else
elog "Moving MY_DATADIR from ${old_MY_DATADIR_s} to ${MY_DATADIR_s}"
mv --strip-trailing-slashes -T "${old_MY_DATADIR_s}" "${MY_DATADIR_s}" \
|| die "Moving MY_DATADIR failed"
fi
else
ewarn "Previous MY_DATADIR (${old_MY_DATADIR_s}) does not exist"
if [[ -d "${MY_DATADIR_s}" ]]; then
ewarn "Attempting to use ${MY_DATADIR_s}"
else
eerror "New MY_DATADIR (${MY_DATADIR_s}) does not exist"
die "Configuration Failed! Please reinstall ${CATEGORY}/${PN}"
fi
fi
fi
local pwd1="a"
local pwd2="b"
local maxtry=15
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
local tmp_mysqld_password_source=
for tmp_mysqld_password_source in mysql client; do
einfo "Trying to get password for mysql 'root' user from '${tmp_mysqld_password_source}' section ..."
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password)"
if [[ -n "${MYSQL_ROOT_PASSWORD}" ]]; then
if [[ ${MYSQL_ROOT_PASSWORD} == *$'\n'* ]]; then
ewarn "Ignoring password from '${tmp_mysqld_password_source}' section due to newline character (do you have multiple password options set?)!"
MYSQL_ROOT_PASSWORD=
continue
fi
einfo "Found password in '${tmp_mysqld_password_source}' section!"
break
fi
done
# Sometimes --show is required to display passwords in some implementations of my_print_defaults
if [[ "${MYSQL_ROOT_PASSWORD}" == '*****' ]]; then
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password --show)"
fi
unset tmp_mysqld_password_source
fi
MYSQL_TMPDIR="$(_getoptval mysqld tmpdir)"
# These are dir+prefix
MYSQL_RELAY_LOG="$(_getoptval mysqld relay-log)"
MYSQL_RELAY_LOG=${MYSQL_RELAY_LOG%/*}
MYSQL_LOG_BIN="$(_getoptval mysqld log-bin)"
MYSQL_LOG_BIN=${MYSQL_LOG_BIN%/*}
if [[ ! -d "${ROOT}/$MYSQL_TMPDIR" ]]; then
einfo "Creating MySQL tmpdir $MYSQL_TMPDIR"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_TMPDIR"
fi
if [[ ! -d "${ROOT}/$MYSQL_LOG_BIN" ]]; then
einfo "Creating MySQL log-bin directory $MYSQL_LOG_BIN"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_LOG_BIN"
fi
if [[ ! -d "${EROOT}/$MYSQL_RELAY_LOG" ]]; then
einfo "Creating MySQL relay-log directory $MYSQL_RELAY_LOG"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_RELAY_LOG"
fi
if [[ -d "${ROOT}/${MY_DATADIR}/mysql" ]] ; then
ewarn "You have already a MySQL database in place."
ewarn "(${ROOT}/${MY_DATADIR}/*)"
ewarn "Please rename or delete it if you wish to replace it."
die "MySQL database already exists!"
fi
# Bug #213475 - MySQL _will_ object strenously if your machine is named
# localhost. Also causes weird failures.
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
einfo "Please provide a password for the mysql 'root' user now"
einfo "or through the ${HOME}/.my.cnf file."
ewarn "Avoid [\"'\\_%] characters in the password"
read -rsp " >" pwd1 ; echo
einfo "Retype the password"
read -rsp " >" pwd2 ; echo
if [[ "x$pwd1" != "x$pwd2" ]] ; then
die "Passwords are not the same"
fi
MYSQL_ROOT_PASSWORD="${pwd1}"
unset pwd1 pwd2
fi
local options
local sqltmp="$(emktemp)"
# Fix bug 446200. Don't reference host my.cnf, needs to come first,
# see https://bugs.mysql.com/bug.php?id=31312
use prefix && options="${options} '--defaults-file=${MY_SYSCONFDIR}/my.cnf'"
# Figure out which options we need to disable to do the setup
local helpfile="${TMPDIR}/mysqld-help"
"${EROOT}/usr/sbin/mysqld" --verbose --help >"${helpfile}" 2>/dev/null
for opt in grant-tables host-cache name-resolve networking slave-start \
federated ssl log-bin relay-log slow-query-log external-locking \
log-slave-updates \
; do
optexp="--(skip-)?${opt}" optfull="--loose-skip-${opt}"
egrep -sq -- "${optexp}" "${helpfile}" && options="${options} ${optfull}"
done
einfo "Creating the mysql database and setting proper permissions on it ..."
# Now that /var/run is a tmpfs mount point, we need to ensure it exists before using it
PID_DIR="${EROOT}/var/run/mysqld"
if [[ ! -d "${PID_DIR}" ]]; then
install -d -m 755 -o mysql -g mysql "${PID_DIR}" || die "Could not create pid directory"
fi
if [[ ! -d "${MY_DATADIR}" ]]; then
install -d -m 750 -o mysql -g mysql "${MY_DATADIR}" || die "Could not create data directory"
fi
pushd "${TMPDIR}" &>/dev/null || die
# Filling timezones, see
# https://dev.mysql.com/doc/mysql/en/time-zone-support.html
"${EROOT}/usr/bin/mysql_tzinfo_to_sql" "${EROOT}/usr/share/zoneinfo" > "${sqltmp}" 2>/dev/null
local cmd=( "${EROOT}usr/share/mariadb/scripts/mysql_install_db" )
[[ -f "${cmd}" ]] || cmd=( "${EROOT}usr/bin/mysql_install_db" )
cmd+=( "--basedir=${EPREFIX}/usr" ${options} "--datadir=${ROOT}/${MY_DATADIR}" "--tmpdir=${ROOT}/${MYSQL_TMPDIR}" )
einfo "Command: ${cmd[*]}"
su -s /bin/sh -c "${cmd[*]}" mysql \
>"${TMPDIR}"/mysql_install_db.log 2>&1
if [ $? -ne 0 ]; then
grep -B5 -A999 -i "ERROR" "${TMPDIR}"/mysql_install_db.log 1>&2
die "Failed to initialize mysqld. Please review ${EPREFIX}/var/log/mysql/mysqld.err AND ${TMPDIR}/mysql_install_db.log"
fi
popd &>/dev/null || die
[[ -f "${ROOT}/${MY_DATADIR}/mysql/user.frm" ]] \
|| die "MySQL databases not installed"
use prefix || options="${options} --user=mysql"
local socket="${EROOT}/var/run/mysqld/mysqld${RANDOM}.sock"
local pidfile="${EROOT}/var/run/mysqld/mysqld${RANDOM}.pid"
local mysqld="${EROOT}/usr/sbin/mysqld \
${options} \
--log-warnings=0 \
--basedir=${EROOT}/usr \
--datadir=${ROOT}/${MY_DATADIR} \
--max_allowed_packet=8M \
--net_buffer_length=16K \
--socket=${socket} \
--pid-file=${pidfile}
--tmpdir=${ROOT}/${MYSQL_TMPDIR}"
#einfo "About to start mysqld: ${mysqld}"
ebegin "Starting mysqld"
einfo "Command ${mysqld}"
${mysqld} &
rc=$?
while ! [[ -S "${socket}" || "${maxtry}" -lt 1 ]] ; do
maxtry=$((${maxtry}-1))
echo -n "."
sleep 1
done
eend $rc
if ! [[ -S "${socket}" ]]; then
die "Completely failed to start up mysqld with: ${mysqld}"
fi
ebegin "Setting root password"
# Do this from memory, as we don't want clear text passwords in temp files
local sql="UPDATE mysql.user SET Password = PASSWORD('${MYSQL_ROOT_PASSWORD}') WHERE USER='root'; FLUSH PRIVILEGES"
"${EROOT}/usr/bin/mysql" \
"--socket=${socket}" \
-hlocalhost \
-e "${sql}"
eend $?
if [[ -n "${sqltmp}" ]] ; then
ebegin "Loading \"zoneinfo\", this step may require a few seconds"
"${EROOT}/usr/bin/mysql" \
"--socket=${socket}" \
-hlocalhost \
-uroot \
--password="${MYSQL_ROOT_PASSWORD}" \
mysql < "${sqltmp}"
rc=$?
eend $?
[[ $rc -ne 0 ]] && ewarn "Failed to load zoneinfo!"
fi
# Stop the server and cleanup
einfo "Stopping the server ..."
kill $(< "${pidfile}" )
rm -f "${sqltmp}"
wait %1
einfo "Done"
}

@ -1,848 +0,0 @@
# Copyright 1999-2018 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
MY_EXTRAS_VER="20180809-1700Z"
SUBSLOT="18"
JAVA_PKG_OPT_USE="jdbc"
# Keeping eutils in EAPI=6 for emktemp in pkg_config
inherit eutils flag-o-matic prefix toolchain-funcs java-pkg-opt-2 user cmake-utils multilib-build
SRC_URI="https://downloads.mariadb.org/interstitial/${P}/source/${P}.tar.gz "
# Gentoo patches to MySQL
if [[ "${MY_EXTRAS_VER}" != "live" && "${MY_EXTRAS_VER}" != "none" ]]; then
SRC_URI="${SRC_URI}
mirror://gentoo/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://gitweb.gentoo.org/proj/mysql-extras.git/snapshot/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~grknight/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~robbat2/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~jmbsvicetto/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2"
fi
HOMEPAGE="https://mariadb.org/"
DESCRIPTION="An enhanced, drop-in replacement for MySQL"
LICENSE="GPL-2"
SLOT="0/${SUBSLOT:-0}"
IUSE="bindist client-libs debug extraengine jdbc jemalloc latin1 libressl
numa odbc oqgraph pam +perl profiling selinux +server sphinx
static static-libs systemtap tcmalloc
test tokudb xml yassl"
# Tests always fail when libressl is enabled due to hard-coded ciphers in the tests
RESTRICT="!bindist? ( bindist ) libressl? ( test )"
REQUIRED_USE="jdbc? ( extraengine server !static )
server? ( tokudb? ( jemalloc !tcmalloc ) )
?? ( tcmalloc jemalloc )
static? ( yassl !pam )"
KEYWORDS="alpha amd64 arm ~arm64 ~hppa ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
# Shorten the path because the socket path length must be shorter than 107 chars
# and we will run a mysql server during test phase
S="${WORKDIR}/mysql"
if [[ "${MY_EXTRAS_VER}" == "live" ]] ; then
MY_PATCH_DIR="${WORKDIR%/}/mysql-extras"
inherit git-r3
EGIT_REPO_URI="git://anongit.gentoo.org/proj/mysql-extras.git"
EGIT_CHECKOUT_DIR="${WORKDIR%/}/mysql-extras"
EGIT_CLONE_TYPE=shallow
else
MY_PATCH_DIR="${WORKDIR%/}/mysql-extras-${MY_EXTRAS_VER}"
fi
PATCHES=(
"${MY_PATCH_DIR}/01050_all_mariadb_mysql_config_cleanup-5.5.41.patch"
"${MY_PATCH_DIR}/20006_all_cmake_elib-mariadb-10.0.33.patch"
"${MY_PATCH_DIR}/20009_all_mariadb_myodbc_symbol_fix-5.5.38.patch"
"${MY_PATCH_DIR}/20018_all_mariadb-10.0.20-without-clientlibs-tools.patch"
)
# Be warned, *DEPEND are version-dependant
# These are used for both runtime and compiletime
COMMON_DEPEND="
kernel_linux? (
sys-process/procps:0=
dev-libs/libaio:0=
)
>=sys-apps/sed-4
>=sys-apps/texinfo-4.7-r1
jemalloc? ( dev-libs/jemalloc:0= )
tcmalloc? ( dev-util/google-perftools:0= )
systemtap? ( >=dev-util/systemtap-1.3:0= )
!yassl? (
!libressl? ( dev-libs/openssl:0= !>=dev-libs/openssl-1.1 )
libressl? ( dev-libs/libressl:0= )
)
>=sys-libs/zlib-1.2.3:0=
sys-libs/ncurses:0=
!bindist? (
>=sys-libs/readline-4.1:0=
)
server? (
extraengine? (
odbc? ( dev-db/unixODBC:0= )
xml? ( dev-libs/libxml2:2= )
)
numa? ( sys-process/numactl )
oqgraph? ( >=dev-libs/boost-1.40.0:0= dev-libs/judy:0= )
pam? ( virtual/pam:0= )
tokudb? ( app-arch/snappy )
)
>=dev-libs/libpcre-8.41-r1:3=
!client-libs? ( dev-db/mysql-connector-c[${MULTILIB_USEDEP},static-libs?] )
"
DEPEND="virtual/yacc
static? ( sys-libs/ncurses[static-libs] )
|| ( >=sys-devel/gcc-3.4.6 >=sys-devel/gcc-apple-4.0 )
server? ( extraengine? ( jdbc? ( >=virtual/jdk-1.6 ) ) )
${COMMON_DEPEND}"
RDEPEND="selinux? ( sec-policy/selinux-mysql )
client-libs? ( !dev-db/mariadb-connector-c[mysqlcompat] !dev-db/mysql-connector-c )
!dev-db/mysql !dev-db/mariadb-galera !dev-db/percona-server !dev-db/mysql-cluster
server? ( !prefix? ( dev-db/mysql-init-scripts ) )
${COMMON_DEPEND}
perl? ( !dev-db/mytop
virtual/perl-Getopt-Long
dev-perl/TermReadKey
virtual/perl-Term-ANSIColor
virtual/perl-Time-HiRes )
server? ( extraengine? ( jdbc? ( >=virtual/jre-1.6 ) ) )
"
# For other stuff to bring us in
# dev-perl/DBD-mysql is needed by some scripts installed by MySQL
PDEPEND="perl? ( >=dev-perl/DBD-mysql-2.9004 )"
pkg_setup() {
if [[ ${MERGE_TYPE} != binary ]] ; then
local GCC_MAJOR_SET=$(gcc-major-version)
local GCC_MINOR_SET=$(gcc-minor-version)
if use tokudb && [[ ${GCC_MAJOR_SET} -lt 4 || \
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
eerror "${PN} with tokudb needs to be built with gcc-4.7 or later."
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
die
fi
# Bug 565584. InnoDB now requires atomic functions introduced with gcc-4.7 on
# non x86{,_64} arches
if ! use amd64 && ! use x86 && [[ ${GCC_MAJOR_SET} -lt 4 || \
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
eerror "${PN} needs to be built with gcc-4.7 or later."
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
die
fi
fi
java-pkg-opt-2_pkg_setup
if has test ${FEATURES} && \
use server && ! has userpriv ${FEATURES} ; then
eerror "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
fi
# This should come after all of the die statements
enewgroup mysql 60 || die "problem adding 'mysql' group"
enewuser mysql 60 -1 /dev/null mysql || die "problem adding 'mysql' user"
}
pkg_preinst() {
java-pkg-opt-2_pkg_preinst
}
pkg_postinst() {
# Make sure the vars are correctly initialized
mysql_init_vars
# Create log directory securely if it does not exist
[[ -d "${ROOT}${MY_LOGDIR}" ]] || install -d -m0750 -o mysql -g mysql "${ROOT}${MY_LOGDIR}"
if use server ; then
if use pam; then
einfo
elog "This install includes the PAM authentication plugin."
elog "To activate and configure the PAM plugin, please read:"
elog "https://mariadb.com/kb/en/mariadb/pam-authentication-plugin/"
einfo
fi
if [[ -z "${REPLACING_VERSIONS}" ]] ; then
einfo
elog "You might want to run:"
elog "\"emerge --config =${CATEGORY}/${PF}\""
elog "if this is a new install."
elog
elog "If you are switching server implentations, you should run the"
elog "mysql_upgrade tool."
einfo
else
einfo
elog "If you are upgrading major versions, you should run the"
elog "mysql_upgrade tool."
einfo
fi
einfo
elog "Be sure to edit the my.cnf file to activate your cluster settings."
elog "This should be done after running \"emerge --config =${CATEGORY}/${PF}\""
elog "The first time the cluster is activated, you should add"
elog "--wsrep-new-cluster to the options in /etc/conf.d/mysql for one node."
elog "This option should then be removed for subsequent starts."
einfo
fi
}
src_unpack() {
unpack ${A}
# Grab the patches
[[ "${MY_EXTRAS_VER}" == "live" ]] && S="${WORKDIR%/}/mysql-extras" git-r3_src_unpack
mv -f "${WORKDIR%/}/${P}" "${S}" || die
}
src_prepare() {
_disable_engine() {
echo > "${S%/}/storage/${1}/CMakeLists.txt" || die
}
_disable_plugin() {
echo > "${S%/}/plugin/${1}/CMakeLists.txt" || die
}
if use tcmalloc; then
echo "TARGET_LINK_LIBRARIES(mysqld tcmalloc)" >> "${S%/}/sql/CMakeLists.txt" || die
fi
# Don't build bundled xz-utils for tokudb
echo > "${S%/}/storage/tokudb/PerconaFT/cmake_modules/TokuThirdParty.cmake" || die
sed -i -e 's/ build_lzma//' -e 's/ build_snappy//' "${S%/}/storage/tokudb/PerconaFT/ft/CMakeLists.txt" || die
sed -i -e 's/add_dependencies\(tokuportability_static_conv build_jemalloc\)//' "${S%/}/storage/tokudb/PerconaFT/portability/CMakeLists.txt" || die
local plugin
local server_plugins=( handler_socket auth_socket feedback metadata_lock_info
locale_info qc_info server_audit semisync sql_errlog )
local test_plugins=( audit_null auth_examples daemon_example fulltext )
if ! use server; then # These plugins are for the server
for plugin in "${server_plugins[@]}" ; do
_disable_plugin "${plugin}"
done
fi
if ! use test; then # These plugins are only used during testing
for plugin in "${test_plugins[@]}" ; do
_disable_plugin "${plugin}"
done
fi
# Collides with mariadb-connector-c bug 655980
_disable_plugin auth_dialog
# Don't build Mroonga or example
_disable_engine mroonga
_disable_engine example
if ! use oqgraph ; then # avoids extra library checks
_disable_engine oqgraph
fi
cmake-utils_src_prepare
java-pkg-opt-2_src_prepare
}
src_configure(){
# bug 508724 mariadb cannot use ld.gold
tc-ld-disable-gold
# Bug #114895, bug #110149
filter-flags "-O" "-O[01]"
append-cxxflags -felide-constructors
# bug #283926, with GCC4.4, this is required to get correct behavior.
append-flags -fno-strict-aliasing
CMAKE_BUILD_TYPE="RelWithDebInfo"
# debug hack wrt #497532
mycmakeargs=(
-DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
-DCMAKE_INSTALL_PREFIX="${EPREFIX%/}/usr"
-DDEFAULT_SYSCONFDIR="${EPREFIX%/}/etc/mysql"
-DINSTALL_BINDIR=bin
-DINSTALL_DOCDIR=share/doc/${PF}
-DINSTALL_DOCREADMEDIR=share/doc/${PF}
-DINSTALL_INCLUDEDIR=include/mysql
-DINSTALL_INFODIR=share/info
-DINSTALL_LIBDIR=$(get_libdir)
-DINSTALL_MANDIR=share/man
-DINSTALL_MYSQLSHAREDIR=share/mariadb
-DINSTALL_PLUGINDIR=$(get_libdir)/mariadb/plugin
-DINSTALL_SCRIPTDIR=share/mariadb/scripts
-DINSTALL_MYSQLDATADIR="${EPREFIX%/}/var/lib/mysql"
-DINSTALL_SBINDIR=sbin
-DINSTALL_SUPPORTFILESDIR="${EPREFIX%/}/usr/share/mariadb"
-DCOMPILATION_COMMENT="Gentoo Linux ${PF}"
-DWITH_UNIT_TESTS=$(usex test ON OFF)
-DWITH_ZLIB=system
-DENABLED_LOCAL_INFILE=1
-DMYSQL_UNIX_ADDR="${EPREFIX%/}/var/run/mysqld/mysqld.sock"
-DINSTALL_UNIX_ADDRDIR="${EPREFIX%/}/var/run/mysqld/mysqld.sock"
# The build forces this to be defined when cross-compiling. We pass it
# all the time for simplicity and to make sure it is actually correct.
-DSTACK_DIRECTION=$(tc-stack-grows-down && echo -1 || echo 1)
-DWITHOUT_CLIENTLIBS=YES
-DWITH_READLINE=$(usex bindist 1 0)
-DNOT_FOR_DISTRIBUTION=$(usex bindist 0 1)
-DENABLE_DTRACE=$(usex systemtap)
)
if use test ; then
mycmakeargs+=( -DINSTALL_MYSQLTESTDIR=share/mariadb/mysql-test )
else
mycmakeargs+=( -DINSTALL_MYSQLTESTDIR='' )
fi
if ! use yassl ; then
mycmakeargs+=( -DWITH_SSL=system )
else
mycmakeargs+=( -DWITH_SSL=bundled )
fi
if use server ; then
# Federated{,X} must be treated special otherwise they will not be built as plugins
if ! use extraengine ; then
mycmakeargs+=(
-DWITHOUT_FEDERATED_STORAGE_ENGINE=1
-DWITHOUT_FEDERATEDX_STORAGE_ENGINE=1 )
fi
mycmakeargs+=(
-DWITH_JEMALLOC=$(usex jemalloc system)
-DWITH_PCRE=system
-D$(usex sphinx WITH WITHOUT)_SPHINX_STORAGE_ENGINE=1
-D$(usex tokudb WITH WITHOUT)_TOKUDB_STORAGE_ENGINE=1
-D$(usex oqgraph WITH WITHOUT)_AUTH_PAM=1
-D$(usex extraengine WITH WITHOUT)_SEQUENCE_STORAGE_ENGINE=1
-D$(usex extraengine WITH WITHOUT)_SPIDER_STORAGE_ENGINE=1
-D$(usex extraengine WITH WITHOUT)_CONNECT_STORAGE_ENGINE=1
-DCONNECT_WITH_LIBXML2=$(usex xml)
-DCONNECT_WITH_ODBC=$(usex odbc)
-DCONNECT_WITH_JDBC=$(usex jdbc)
# Build failure and autodep wrt bug 639144
-DCONNECT_WITH_MONGO=OFF
-DINSTALL_SQLBENCHDIR=share/mariadb
)
if [[ ( -n ${MYSQL_DEFAULT_CHARSET} ) && ( -n ${MYSQL_DEFAULT_COLLATION} ) ]]; then
ewarn "You are using a custom charset of ${MYSQL_DEFAULT_CHARSET}"
ewarn "and a collation of ${MYSQL_DEFAULT_COLLATION}."
ewarn "You MUST file bugs without these variables set."
mycmakeargs+=(
-DDEFAULT_CHARSET=${MYSQL_DEFAULT_CHARSET}
-DDEFAULT_COLLATION=${MYSQL_DEFAULT_COLLATION}
)
elif ! use latin1 ; then
mycmakeargs+=(
-DDEFAULT_CHARSET=utf8
-DDEFAULT_COLLATION=utf8_general_ci
)
else
mycmakeargs+=(
-DDEFAULT_CHARSET=latin1
-DDEFAULT_COLLATION=latin1_swedish_ci
)
fi
mycmakeargs+=(
-DEXTRA_CHARSETS=all
-DDISABLE_SHARED=$(usex static YES NO)
-DWITH_EMBEDDED_SERVER=OFF
-DENABLED_PROFILING=$(usex profiling)
)
if use static; then
mycmakeargs+=( -DWITH_PIC=1 )
fi
if use jemalloc || use tcmalloc ; then
mycmakeargs+=( -DWITH_SAFEMALLOC=OFF )
fi
# Storage engines
mycmakeargs+=(
-DWITH_ARCHIVE_STORAGE_ENGINE=1
-DWITH_BLACKHOLE_STORAGE_ENGINE=1
-DWITH_CSV_STORAGE_ENGINE=1
-DWITH_HEAP_STORAGE_ENGINE=1
-DWITH_INNOBASE_STORAGE_ENGINE=1
-DWITH_MYISAMMRG_STORAGE_ENGINE=1
-DWITH_MYISAM_STORAGE_ENGINE=1
-DWITH_PARTITION_STORAGE_ENGINE=1
)
else
mycmakeargs+=(
-DWITHOUT_SERVER=1
-DEXTRA_CHARSETS=none
-DINSTALL_SQLBENCHDIR=
)
fi
cmake-utils_src_configure
}
src_compile() {
cmake-utils_src_compile
}
src_install() {
cmake-utils_src_install
# Remove an unnecessary, private config header which will never match between ABIs and is not meant to be used
if [[ -f "${ED%/}/usr/include/mysql/server/private/config.h" ]] ; then
rm "${ED%/}/usr/include/mysql/server/private/config.h" || die
fi
# Make sure the vars are correctly initialized
mysql_init_vars
# Convenience links
einfo "Making Convenience links for mysqlcheck multi-call binary"
dosym "mysqlcheck" "/usr/bin/mysqlanalyze"
dosym "mysqlcheck" "/usr/bin/mysqlrepair"
dosym "mysqlcheck" "/usr/bin/mysqloptimize"
# INSTALL_LAYOUT=STANDALONE causes cmake to create a /usr/data dir
if [[ -d "${ED%/}/usr/data" ]] ; then
rm -Rf "${ED%/}/usr/data" || die
fi
# Unless they explicitly specific USE=test, then do not install the
# testsuite. It DOES have a use to be installed, esp. when you want to do a
# validation of your database configuration after tuning it.
if ! use test ; then
rm -rf "${D%/}/${MY_SHAREDSTATEDIR}/mysql-test"
fi
# Configuration stuff
einfo "Building default configuration ..."
insinto "${MY_SYSCONFDIR#${EPREFIX}}"
[[ -f "${S%/}/scripts/mysqlaccess.conf" ]] && doins "${S%/}"/scripts/mysqlaccess.conf
local mycnf_src="my.cnf-5.6-r1"
sed -e "s!@DATADIR@!${MY_DATADIR}!g" \
"${FILESDIR%/}/${mycnf_src}" \
> "${TMPDIR%/}/my.cnf.ok" || die
use prefix && sed -i -r -e '/^user[[:space:]]*=[[:space:]]*mysql$/d' "${TMPDIR%/}/my.cnf.ok"
if use latin1 ; then
sed -i \
-e "/character-set/s|utf8|latin1|g" \
"${TMPDIR%/}/my.cnf.ok" || die
fi
eprefixify "${TMPDIR%/}/my.cnf.ok"
newins "${TMPDIR}/my.cnf.ok" my.cnf
if use server ; then
einfo "Including support files and sample configurations"
docinto "support-files"
local script
for script in \
"${S%/}"/support-files/magic
do
[[ -f "$script" ]] && dodoc "${script}"
done
docinto "scripts"
for script in "${S%/}"/scripts/mysql* ; do
[[ ( -f "$script" ) && ( "${script%.sh}" == "${script}" ) ]] && dodoc "${script}"
done
# Manually install supporting files that conflict with other packages
# but are needed for galera and initial installation
exeinto /usr/libexec/mariadb
doexe "${BUILD_DIR}/extra/my_print_defaults" "${BUILD_DIR}/extra/perror"
fi
#Remove mytop if perl is not selected
[[ -e "${ED%/}/usr/bin/mytop" ]] && ! use perl && rm -f "${ED%/}/usr/bin/mytop"
}
# Official test instructions:
# USE='extraengine perl server' \
# FEATURES='test userpriv -usersandbox' \
# ebuild mariadb-X.X.XX.ebuild \
# digest clean package
src_test() {
_disable_test() {
local rawtestname reason
rawtestname="${1}" ; shift
reason="${@}"
ewarn "test '${rawtestname}' disabled: '${reason}'"
echo ${rawtestname} : ${reason} >> "${T}/disabled.def"
}
local TESTDIR="${BUILD_DIR}/mysql-test"
local retstatus_unit
local retstatus_tests
if ! use server ; then
einfo "Skipping server tests due to minimal build."
return 0
fi
# Bug #213475 - MySQL _will_ object strenously if your machine is named
# localhost. Also causes weird failures.
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
if [[ $UID -eq 0 ]]; then
die "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
fi
has usersandbox $FEATURES && ewarn "Some tests may fail with FEATURES=usersandbox"
einfo ">>> Test phase [test]: ${CATEGORY}/${PF}"
# Run CTest (test-units)
cmake-utils_src_test
retstatus_unit=$?
# Ensure that parallel runs don't die
export MTR_BUILD_THREAD="$((${RANDOM} % 100))"
# Enable parallel testing, auto will try to detect number of cores
# You may set this by hand.
# The default maximum is 8 unless MTR_MAX_PARALLEL is increased
export MTR_PARALLEL="${MTR_PARALLEL:-auto}"
# create directories because mysqladmin might run out of order
mkdir -p "${T}"/var-tests{,/log} || die
# Run mysql tests
pushd "${TESTDIR}" > /dev/null || die
touch "${T}/disabled.def"
# These are failing in MariaDB 10.0 for now and are believed to be
# false positives:
#
# main.mysql_client_test, main.mysql_client_test_nonblock
# main.mysql_client_test_comp:
# segfaults at random under Portage only, suspect resource limits.
local t
for t in main.mysql_client_test main.mysql_client_test_nonblock \
main.mysql_client_test_comp rpl.rpl_extra_col_master_myisam \
rpl.rpl_semi_sync_uninstall_plugin ; do
_disable_test "$t" "False positives in Gentoo"
done
if ! use client-libs ; then
_disable_test main.plugin_auth "Needs client libraries built"
fi
# run mysql-test tests
perl mysql-test-run.pl --force --vardir="${T}/var-tests" --reorder --skip-test=tokudb --skip-test-list="${T}/disabled.def"
retstatus_tests=$?
popd > /dev/null || die
# Cleanup is important for these testcases.
pkill -9 -f "${S}/ndb" 2>/dev/null
pkill -9 -f "${S}/sql" 2>/dev/null
local failures=""
[[ $retstatus_unit -eq 0 ]] || failures="${failures} test-unit"
[[ $retstatus_tests -eq 0 ]] || failures="${failures} tests"
[[ -z "$failures" ]] || die "Test failures: $failures"
einfo "Tests successfully completed"
}
mysql_init_vars() {
MY_SHAREDSTATEDIR=${MY_SHAREDSTATEDIR="${EPREFIX}/usr/share/mariadb"}
MY_SYSCONFDIR=${MY_SYSCONFDIR="${EPREFIX}/etc/mysql"}
MY_LOCALSTATEDIR=${MY_LOCALSTATEDIR="${EPREFIX}/var/lib/mysql"}
MY_LOGDIR=${MY_LOGDIR="${EPREFIX}/var/log/mysql"}
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR=""
if [[ -f "${MY_SYSCONFDIR}/my.cnf" ]] ; then
MY_DATADIR=`"my_print_defaults" mysqld 2>/dev/null \
| sed -ne '/datadir/s|^--datadir=||p' \
| tail -n1`
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR=`grep ^datadir "${MY_SYSCONFDIR}/my.cnf" \
| sed -e 's/.*=\s*//' \
| tail -n1`
fi
fi
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR="${MY_LOCALSTATEDIR}"
einfo "Using default MY_DATADIR"
fi
elog "MySQL MY_DATADIR is ${MY_DATADIR}"
if [[ -z "${PREVIOUS_DATADIR}" ]] ; then
if [[ -e "${MY_DATADIR}" ]] ; then
# If you get this and you're wondering about it, see bug #207636
elog "MySQL datadir found in ${MY_DATADIR}"
elog "A new one will not be created."
PREVIOUS_DATADIR="yes"
else
PREVIOUS_DATADIR="no"
fi
export PREVIOUS_DATADIR
fi
else
if [[ ${EBUILD_PHASE} == "config" ]]; then
local new_MY_DATADIR
new_MY_DATADIR=`"my_print_defaults" mysqld 2>/dev/null \
| sed -ne '/datadir/s|^--datadir=||p' \
| tail -n1`
if [[ ( -n "${new_MY_DATADIR}" ) && ( "${new_MY_DATADIR}" != "${MY_DATADIR}" ) ]]; then
ewarn "MySQL MY_DATADIR has changed"
ewarn "from ${MY_DATADIR}"
ewarn "to ${new_MY_DATADIR}"
MY_DATADIR="${new_MY_DATADIR}"
fi
fi
fi
export MY_SHAREDSTATEDIR MY_SYSCONFDIR
export MY_LOCALSTATEDIR MY_LOGDIR
export MY_DATADIR
}
pkg_config() {
_getoptval() {
local mypd="${EROOT}"/usr/bin/my_print_defaults
local section="$1"
local flag="--${2}="
local extra_options="${3}"
"${mypd}" $extra_options $section | sed -n "/^${flag}/s,${flag},,gp"
}
local old_MY_DATADIR="${MY_DATADIR}"
local old_HOME="${HOME}"
# my_print_defaults needs to read stuff in $HOME/.my.cnf
export HOME=${EPREFIX}/root
# Make sure the vars are correctly initialized
mysql_init_vars
[[ -z "${MY_DATADIR}" ]] && die "Sorry, unable to find MY_DATADIR"
if [[ ! -x "${EROOT}/usr/sbin/mysqld" ]] ; then
die "Minimal builds do NOT include the MySQL server"
fi
if [[ ( -n "${MY_DATADIR}" ) && ( "${MY_DATADIR}" != "${old_MY_DATADIR}" ) ]]; then
local MY_DATADIR_s="${ROOT}/${MY_DATADIR}"
MY_DATADIR_s="${MY_DATADIR_s%%/}"
local old_MY_DATADIR_s="${ROOT}/${old_MY_DATADIR}"
old_MY_DATADIR_s="${old_MY_DATADIR_s%%/}"
if [[ ( -d "${old_MY_DATADIR_s}" ) && ( "${old_MY_DATADIR_s}" != / ) ]]; then
if [[ -d "${MY_DATADIR_s}" ]]; then
ewarn "Both ${old_MY_DATADIR_s} and ${MY_DATADIR_s} exist"
ewarn "Attempting to use ${MY_DATADIR_s} and preserving ${old_MY_DATADIR_s}"
else
elog "Moving MY_DATADIR from ${old_MY_DATADIR_s} to ${MY_DATADIR_s}"
mv --strip-trailing-slashes -T "${old_MY_DATADIR_s}" "${MY_DATADIR_s}" \
|| die "Moving MY_DATADIR failed"
fi
else
ewarn "Previous MY_DATADIR (${old_MY_DATADIR_s}) does not exist"
if [[ -d "${MY_DATADIR_s}" ]]; then
ewarn "Attempting to use ${MY_DATADIR_s}"
else
eerror "New MY_DATADIR (${MY_DATADIR_s}) does not exist"
die "Configuration Failed! Please reinstall ${CATEGORY}/${PN}"
fi
fi
fi
local pwd1="a"
local pwd2="b"
local maxtry=15
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
local tmp_mysqld_password_source=
for tmp_mysqld_password_source in mysql client; do
einfo "Trying to get password for mysql 'root' user from '${tmp_mysqld_password_source}' section ..."
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password)"
if [[ -n "${MYSQL_ROOT_PASSWORD}" ]]; then
if [[ ${MYSQL_ROOT_PASSWORD} == *$'\n'* ]]; then
ewarn "Ignoring password from '${tmp_mysqld_password_source}' section due to newline character (do you have multiple password options set?)!"
MYSQL_ROOT_PASSWORD=
continue
fi
einfo "Found password in '${tmp_mysqld_password_source}' section!"
break
fi
done
# Sometimes --show is required to display passwords in some implementations of my_print_defaults
if [[ "${MYSQL_ROOT_PASSWORD}" == '*****' ]]; then
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password --show)"
fi
unset tmp_mysqld_password_source
fi
MYSQL_TMPDIR="$(_getoptval mysqld tmpdir)"
# These are dir+prefix
MYSQL_RELAY_LOG="$(_getoptval mysqld relay-log)"
MYSQL_RELAY_LOG=${MYSQL_RELAY_LOG%/*}
MYSQL_LOG_BIN="$(_getoptval mysqld log-bin)"
MYSQL_LOG_BIN=${MYSQL_LOG_BIN%/*}
if [[ ! -d "${ROOT}/$MYSQL_TMPDIR" ]]; then
einfo "Creating MySQL tmpdir $MYSQL_TMPDIR"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_TMPDIR"
fi
if [[ ! -d "${ROOT}/$MYSQL_LOG_BIN" ]]; then
einfo "Creating MySQL log-bin directory $MYSQL_LOG_BIN"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_LOG_BIN"
fi
if [[ ! -d "${EROOT}/$MYSQL_RELAY_LOG" ]]; then
einfo "Creating MySQL relay-log directory $MYSQL_RELAY_LOG"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_RELAY_LOG"
fi
if [[ -d "${ROOT}/${MY_DATADIR}/mysql" ]] ; then
ewarn "You have already a MySQL database in place."
ewarn "(${ROOT}/${MY_DATADIR}/*)"
ewarn "Please rename or delete it if you wish to replace it."
die "MySQL database already exists!"
fi
# Bug #213475 - MySQL _will_ object strenously if your machine is named
# localhost. Also causes weird failures.
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
einfo "Please provide a password for the mysql 'root' user now"
einfo "or through the ${HOME}/.my.cnf file."
ewarn "Avoid [\"'\\_%] characters in the password"
read -rsp " >" pwd1 ; echo
einfo "Retype the password"
read -rsp " >" pwd2 ; echo
if [[ "x$pwd1" != "x$pwd2" ]] ; then
die "Passwords are not the same"
fi
MYSQL_ROOT_PASSWORD="${pwd1}"
unset pwd1 pwd2
fi
local options
local sqltmp="$(emktemp)"
# Fix bug 446200. Don't reference host my.cnf, needs to come first,
# see https://bugs.mysql.com/bug.php?id=31312
use prefix && options="${options} '--defaults-file=${MY_SYSCONFDIR}/my.cnf'"
# Figure out which options we need to disable to do the setup
local helpfile="${TMPDIR}/mysqld-help"
"${EROOT}/usr/sbin/mysqld" --verbose --help >"${helpfile}" 2>/dev/null
for opt in grant-tables host-cache name-resolve networking slave-start \
federated ssl log-bin relay-log slow-query-log external-locking \
log-slave-updates \
; do
optexp="--(skip-)?${opt}" optfull="--loose-skip-${opt}"
egrep -sq -- "${optexp}" "${helpfile}" && options="${options} ${optfull}"
done
einfo "Creating the mysql database and setting proper permissions on it ..."
# Now that /var/run is a tmpfs mount point, we need to ensure it exists before using it
PID_DIR="${EROOT}/var/run/mysqld"
if [[ ! -d "${PID_DIR}" ]]; then
install -d -m 755 -o mysql -g mysql "${PID_DIR}" || die "Could not create pid directory"
fi
if [[ ! -d "${MY_DATADIR}" ]]; then
install -d -m 750 -o mysql -g mysql "${MY_DATADIR}" || die "Could not create data directory"
fi
pushd "${TMPDIR}" &>/dev/null || die
# Filling timezones, see
# https://dev.mysql.com/doc/mysql/en/time-zone-support.html
"${EROOT}/usr/bin/mysql_tzinfo_to_sql" "${EROOT}/usr/share/zoneinfo" > "${sqltmp}" 2>/dev/null
local cmd=( "${EROOT}usr/share/mariadb/scripts/mysql_install_db" )
[[ -f "${cmd}" ]] || cmd=( "${EROOT}usr/bin/mysql_install_db" )
cmd+=( "--basedir=${EPREFIX}/usr" ${options} "--datadir=${ROOT}/${MY_DATADIR}" "--tmpdir=${ROOT}/${MYSQL_TMPDIR}" )
einfo "Command: ${cmd[*]}"
su -s /bin/sh -c "${cmd[*]}" mysql \
>"${TMPDIR}"/mysql_install_db.log 2>&1
if [ $? -ne 0 ]; then
grep -B5 -A999 -i "ERROR" "${TMPDIR}"/mysql_install_db.log 1>&2
die "Failed to initialize mysqld. Please review ${EPREFIX}/var/log/mysql/mysqld.err AND ${TMPDIR}/mysql_install_db.log"
fi
popd &>/dev/null || die
[[ -f "${ROOT}/${MY_DATADIR}/mysql/user.frm" ]] \
|| die "MySQL databases not installed"
use prefix || options="${options} --user=mysql"
local socket="${EROOT}/var/run/mysqld/mysqld${RANDOM}.sock"
local pidfile="${EROOT}/var/run/mysqld/mysqld${RANDOM}.pid"
local mysqld="${EROOT}/usr/sbin/mysqld \
${options} \
--log-warnings=0 \
--basedir=${EROOT}/usr \
--datadir=${ROOT}/${MY_DATADIR} \
--max_allowed_packet=8M \
--net_buffer_length=16K \
--socket=${socket} \
--pid-file=${pidfile} \
--tmpdir=${ROOT}/${MYSQL_TMPDIR}"
#einfo "About to start mysqld: ${mysqld}"
ebegin "Starting mysqld"
einfo "Command ${mysqld}"
${mysqld} &
rc=$?
while ! [[ -S "${socket}" || "${maxtry}" -lt 1 ]] ; do
maxtry=$((${maxtry}-1))
echo -n "."
sleep 1
done
eend $rc
if ! [[ -S "${socket}" ]]; then
die "Completely failed to start up mysqld with: ${mysqld}"
fi
ebegin "Setting root password"
# Do this from memory, as we don't want clear text passwords in temp files
local sql="UPDATE mysql.user SET Password = PASSWORD('${MYSQL_ROOT_PASSWORD}') WHERE USER='root'; FLUSH PRIVILEGES"
"${EROOT}/usr/bin/mysql" \
"--socket=${socket}" \
-hlocalhost \
-e "${sql}"
eend $?
if [[ -n "${sqltmp}" ]] ; then
ebegin "Loading \"zoneinfo\", this step may require a few seconds"
"${EROOT}/usr/bin/mysql" \
"--socket=${socket}" \
-hlocalhost \
-uroot \
--password="${MYSQL_ROOT_PASSWORD}" \
mysql < "${sqltmp}"
rc=$?
eend $?
[[ $rc -ne 0 ]] && ewarn "Failed to load zoneinfo!"
fi
# Stop the server and cleanup
einfo "Stopping the server ..."
kill $(< "${pidfile}" )
rm -f "${sqltmp}"
wait %1
einfo "Done"
}

@ -1,848 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
MY_EXTRAS_VER="20180809-1700Z"
SUBSLOT="18"
JAVA_PKG_OPT_USE="jdbc"
# Keeping eutils in EAPI=6 for emktemp in pkg_config
inherit eutils flag-o-matic prefix toolchain-funcs java-pkg-opt-2 user cmake-utils multilib-build
SRC_URI="https://downloads.mariadb.org/interstitial/${P}/source/${P}.tar.gz "
# Gentoo patches to MySQL
if [[ "${MY_EXTRAS_VER}" != "live" && "${MY_EXTRAS_VER}" != "none" ]]; then
SRC_URI="${SRC_URI}
mirror://gentoo/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://gitweb.gentoo.org/proj/mysql-extras.git/snapshot/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~grknight/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~robbat2/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2
https://dev.gentoo.org/~jmbsvicetto/distfiles/mysql-extras-${MY_EXTRAS_VER}.tar.bz2"
fi
HOMEPAGE="https://mariadb.org/"
DESCRIPTION="An enhanced, drop-in replacement for MySQL"
LICENSE="GPL-2"
SLOT="0/${SUBSLOT:-0}"
IUSE="bindist client-libs debug extraengine jdbc jemalloc latin1 libressl
numa odbc oqgraph pam +perl profiling selinux +server sphinx
static static-libs systemtap tcmalloc
test tokudb xml yassl"
# Tests always fail when libressl is enabled due to hard-coded ciphers in the tests
RESTRICT="!bindist? ( bindist ) libressl? ( test )"
REQUIRED_USE="jdbc? ( extraengine server !static )
server? ( tokudb? ( jemalloc !tcmalloc ) )
?? ( tcmalloc jemalloc )
static? ( yassl !pam )"
KEYWORDS="alpha amd64 arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-solaris ~x86-solaris"
# Shorten the path because the socket path length must be shorter than 107 chars
# and we will run a mysql server during test phase
S="${WORKDIR}/mysql"
if [[ "${MY_EXTRAS_VER}" == "live" ]] ; then
MY_PATCH_DIR="${WORKDIR%/}/mysql-extras"
inherit git-r3
EGIT_REPO_URI="git://anongit.gentoo.org/proj/mysql-extras.git"
EGIT_CHECKOUT_DIR="${WORKDIR%/}/mysql-extras"
EGIT_CLONE_TYPE=shallow
else
MY_PATCH_DIR="${WORKDIR%/}/mysql-extras-${MY_EXTRAS_VER}"
fi
PATCHES=(
"${MY_PATCH_DIR}/01050_all_mariadb_mysql_config_cleanup-5.5.41.patch"
"${MY_PATCH_DIR}/20006_all_cmake_elib-mariadb-10.0.33.patch"
"${MY_PATCH_DIR}/20009_all_mariadb_myodbc_symbol_fix-5.5.38.patch"
"${MY_PATCH_DIR}/20018_all_mariadb-10.0.20-without-clientlibs-tools.patch"
)
# Be warned, *DEPEND are version-dependant
# These are used for both runtime and compiletime
COMMON_DEPEND="
kernel_linux? (
sys-process/procps:0=
dev-libs/libaio:0=
)
>=sys-apps/sed-4
>=sys-apps/texinfo-4.7-r1
jemalloc? ( dev-libs/jemalloc:0= )
tcmalloc? ( dev-util/google-perftools:0= )
systemtap? ( >=dev-util/systemtap-1.3:0= )
!yassl? (
!libressl? ( dev-libs/openssl:0= !>=dev-libs/openssl-1.1 )
libressl? ( dev-libs/libressl:0= )
)
>=sys-libs/zlib-1.2.3:0=
sys-libs/ncurses:0=
!bindist? (
>=sys-libs/readline-4.1:0=
)
server? (
extraengine? (
odbc? ( dev-db/unixODBC:0= )
xml? ( dev-libs/libxml2:2= )
)
numa? ( sys-process/numactl )
oqgraph? ( >=dev-libs/boost-1.40.0:0= dev-libs/judy:0= )
pam? ( virtual/pam:0= )
tokudb? ( app-arch/snappy )
)
>=dev-libs/libpcre-8.41-r1:3=
!client-libs? ( dev-db/mysql-connector-c[${MULTILIB_USEDEP},static-libs?] )
"
DEPEND="virtual/yacc
static? ( sys-libs/ncurses[static-libs] )
|| ( >=sys-devel/gcc-3.4.6 >=sys-devel/gcc-apple-4.0 )
server? ( extraengine? ( jdbc? ( >=virtual/jdk-1.6 ) ) )
${COMMON_DEPEND}"
RDEPEND="selinux? ( sec-policy/selinux-mysql )
client-libs? ( !dev-db/mariadb-connector-c[mysqlcompat] !dev-db/mysql-connector-c )
!dev-db/mysql !dev-db/mariadb-galera !dev-db/percona-server !dev-db/mysql-cluster
server? ( !prefix? ( dev-db/mysql-init-scripts ) )
${COMMON_DEPEND}
perl? ( !dev-db/mytop
virtual/perl-Getopt-Long
dev-perl/TermReadKey
virtual/perl-Term-ANSIColor
virtual/perl-Time-HiRes )
server? ( extraengine? ( jdbc? ( >=virtual/jre-1.6 ) ) )
"
# For other stuff to bring us in
# dev-perl/DBD-mysql is needed by some scripts installed by MySQL
PDEPEND="perl? ( >=dev-perl/DBD-mysql-2.9004 )"
pkg_setup() {
if [[ ${MERGE_TYPE} != binary ]] ; then
local GCC_MAJOR_SET=$(gcc-major-version)
local GCC_MINOR_SET=$(gcc-minor-version)
if use tokudb && [[ ${GCC_MAJOR_SET} -lt 4 || \
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
eerror "${PN} with tokudb needs to be built with gcc-4.7 or later."
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
die
fi
# Bug 565584. InnoDB now requires atomic functions introduced with gcc-4.7 on
# non x86{,_64} arches
if ! use amd64 && ! use x86 && [[ ${GCC_MAJOR_SET} -lt 4 || \
${GCC_MAJOR_SET} -eq 4 && ${GCC_MINOR_SET} -lt 7 ]] ; then
eerror "${PN} needs to be built with gcc-4.7 or later."
eerror "Please use gcc-config to switch to gcc-4.7 or later version."
die
fi
fi
java-pkg-opt-2_pkg_setup
if has test ${FEATURES} && \
use server && ! has userpriv ${FEATURES} ; then
eerror "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
fi
# This should come after all of the die statements
enewgroup mysql 60 || die "problem adding 'mysql' group"
enewuser mysql 60 -1 /dev/null mysql || die "problem adding 'mysql' user"
}
pkg_preinst() {
java-pkg-opt-2_pkg_preinst
}
pkg_postinst() {
# Make sure the vars are correctly initialized
mysql_init_vars
# Create log directory securely if it does not exist
[[ -d "${ROOT}${MY_LOGDIR}" ]] || install -d -m0750 -o mysql -g mysql "${ROOT}${MY_LOGDIR}"
if use server ; then
if use pam; then
einfo
elog "This install includes the PAM authentication plugin."
elog "To activate and configure the PAM plugin, please read:"
elog "https://mariadb.com/kb/en/mariadb/pam-authentication-plugin/"
einfo
fi
if [[ -z "${REPLACING_VERSIONS}" ]] ; then
einfo
elog "You might want to run:"
elog "\"emerge --config =${CATEGORY}/${PF}\""
elog "if this is a new install."
elog
elog "If you are switching server implentations, you should run the"
elog "mysql_upgrade tool."
einfo
else
einfo
elog "If you are upgrading major versions, you should run the"
elog "mysql_upgrade tool."
einfo
fi
einfo
elog "Be sure to edit the my.cnf file to activate your cluster settings."
elog "This should be done after running \"emerge --config =${CATEGORY}/${PF}\""
elog "The first time the cluster is activated, you should add"
elog "--wsrep-new-cluster to the options in /etc/conf.d/mysql for one node."
elog "This option should then be removed for subsequent starts."
einfo
fi
}
src_unpack() {
unpack ${A}
# Grab the patches
[[ "${MY_EXTRAS_VER}" == "live" ]] && S="${WORKDIR%/}/mysql-extras" git-r3_src_unpack
mv -f "${WORKDIR%/}/${P}" "${S}" || die
}
src_prepare() {
_disable_engine() {
echo > "${S%/}/storage/${1}/CMakeLists.txt" || die
}
_disable_plugin() {
echo > "${S%/}/plugin/${1}/CMakeLists.txt" || die
}
if use tcmalloc; then
echo "TARGET_LINK_LIBRARIES(mysqld tcmalloc)" >> "${S%/}/sql/CMakeLists.txt" || die
fi
# Don't build bundled xz-utils for tokudb
echo > "${S%/}/storage/tokudb/PerconaFT/cmake_modules/TokuThirdParty.cmake" || die
sed -i -e 's/ build_lzma//' -e 's/ build_snappy//' "${S%/}/storage/tokudb/PerconaFT/ft/CMakeLists.txt" || die
sed -i -e 's/add_dependencies\(tokuportability_static_conv build_jemalloc\)//' "${S%/}/storage/tokudb/PerconaFT/portability/CMakeLists.txt" || die
local plugin
local server_plugins=( handler_socket auth_socket feedback metadata_lock_info
locale_info qc_info server_audit semisync sql_errlog )
local test_plugins=( audit_null auth_examples daemon_example fulltext )
if ! use server; then # These plugins are for the server
for plugin in "${server_plugins[@]}" ; do
_disable_plugin "${plugin}"
done
fi
if ! use test; then # These plugins are only used during testing
for plugin in "${test_plugins[@]}" ; do
_disable_plugin "${plugin}"
done
fi
# Collides with mariadb-connector-c bug 655980
_disable_plugin auth_dialog
# Don't build Mroonga or example
_disable_engine mroonga
_disable_engine example
if ! use oqgraph ; then # avoids extra library checks
_disable_engine oqgraph
fi
cmake-utils_src_prepare
java-pkg-opt-2_src_prepare
}
src_configure(){
# bug 508724 mariadb cannot use ld.gold
tc-ld-disable-gold
# Bug #114895, bug #110149
filter-flags "-O" "-O[01]"
append-cxxflags -felide-constructors
# bug #283926, with GCC4.4, this is required to get correct behavior.
append-flags -fno-strict-aliasing
CMAKE_BUILD_TYPE="RelWithDebInfo"
# debug hack wrt #497532
mycmakeargs=(
-DCMAKE_C_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
-DCMAKE_CXX_FLAGS_RELWITHDEBINFO="$(usex debug '' '-DNDEBUG')"
-DCMAKE_INSTALL_PREFIX="${EPREFIX%/}/usr"
-DDEFAULT_SYSCONFDIR="${EPREFIX%/}/etc/mysql"
-DINSTALL_BINDIR=bin
-DINSTALL_DOCDIR=share/doc/${PF}
-DINSTALL_DOCREADMEDIR=share/doc/${PF}
-DINSTALL_INCLUDEDIR=include/mysql
-DINSTALL_INFODIR=share/info
-DINSTALL_LIBDIR=$(get_libdir)
-DINSTALL_MANDIR=share/man
-DINSTALL_MYSQLSHAREDIR=share/mariadb
-DINSTALL_PLUGINDIR=$(get_libdir)/mariadb/plugin
-DINSTALL_SCRIPTDIR=share/mariadb/scripts
-DINSTALL_MYSQLDATADIR="${EPREFIX%/}/var/lib/mysql"
-DINSTALL_SBINDIR=sbin
-DINSTALL_SUPPORTFILESDIR="${EPREFIX%/}/usr/share/mariadb"
-DCOMPILATION_COMMENT="Gentoo Linux ${PF}"
-DWITH_UNIT_TESTS=$(usex test ON OFF)
-DWITH_ZLIB=system
-DENABLED_LOCAL_INFILE=1
-DMYSQL_UNIX_ADDR="${EPREFIX%/}/var/run/mysqld/mysqld.sock"
-DINSTALL_UNIX_ADDRDIR="${EPREFIX%/}/var/run/mysqld/mysqld.sock"
# The build forces this to be defined when cross-compiling. We pass it
# all the time for simplicity and to make sure it is actually correct.
-DSTACK_DIRECTION=$(tc-stack-grows-down && echo -1 || echo 1)
-DWITHOUT_CLIENTLIBS=YES
-DWITH_READLINE=$(usex bindist 1 0)
-DNOT_FOR_DISTRIBUTION=$(usex bindist 0 1)
-DENABLE_DTRACE=$(usex systemtap)
)
if use test ; then
mycmakeargs+=( -DINSTALL_MYSQLTESTDIR=share/mariadb/mysql-test )
else
mycmakeargs+=( -DINSTALL_MYSQLTESTDIR='' )
fi
if ! use yassl ; then
mycmakeargs+=( -DWITH_SSL=system )
else
mycmakeargs+=( -DWITH_SSL=bundled )
fi
if use server ; then
# Federated{,X} must be treated special otherwise they will not be built as plugins
if ! use extraengine ; then
mycmakeargs+=(
-DWITHOUT_FEDERATED_STORAGE_ENGINE=1
-DWITHOUT_FEDERATEDX_STORAGE_ENGINE=1 )
fi
mycmakeargs+=(
-DWITH_JEMALLOC=$(usex jemalloc system)
-DWITH_PCRE=system
-D$(usex sphinx WITH WITHOUT)_SPHINX_STORAGE_ENGINE=1
-D$(usex tokudb WITH WITHOUT)_TOKUDB_STORAGE_ENGINE=1
-D$(usex oqgraph WITH WITHOUT)_AUTH_PAM=1
-D$(usex extraengine WITH WITHOUT)_SEQUENCE_STORAGE_ENGINE=1
-D$(usex extraengine WITH WITHOUT)_SPIDER_STORAGE_ENGINE=1
-D$(usex extraengine WITH WITHOUT)_CONNECT_STORAGE_ENGINE=1
-DCONNECT_WITH_LIBXML2=$(usex xml)
-DCONNECT_WITH_ODBC=$(usex odbc)
-DCONNECT_WITH_JDBC=$(usex jdbc)
# Build failure and autodep wrt bug 639144
-DCONNECT_WITH_MONGO=OFF
-DINSTALL_SQLBENCHDIR=share/mariadb
)
if [[ ( -n ${MYSQL_DEFAULT_CHARSET} ) && ( -n ${MYSQL_DEFAULT_COLLATION} ) ]]; then
ewarn "You are using a custom charset of ${MYSQL_DEFAULT_CHARSET}"
ewarn "and a collation of ${MYSQL_DEFAULT_COLLATION}."
ewarn "You MUST file bugs without these variables set."
mycmakeargs+=(
-DDEFAULT_CHARSET=${MYSQL_DEFAULT_CHARSET}
-DDEFAULT_COLLATION=${MYSQL_DEFAULT_COLLATION}
)
elif ! use latin1 ; then
mycmakeargs+=(
-DDEFAULT_CHARSET=utf8
-DDEFAULT_COLLATION=utf8_general_ci
)
else
mycmakeargs+=(
-DDEFAULT_CHARSET=latin1
-DDEFAULT_COLLATION=latin1_swedish_ci
)
fi
mycmakeargs+=(
-DEXTRA_CHARSETS=all
-DDISABLE_SHARED=$(usex static YES NO)
-DWITH_EMBEDDED_SERVER=OFF
-DENABLED_PROFILING=$(usex profiling)
)
if use static; then
mycmakeargs+=( -DWITH_PIC=1 )
fi
if use jemalloc || use tcmalloc ; then
mycmakeargs+=( -DWITH_SAFEMALLOC=OFF )
fi
# Storage engines
mycmakeargs+=(
-DWITH_ARCHIVE_STORAGE_ENGINE=1
-DWITH_BLACKHOLE_STORAGE_ENGINE=1
-DWITH_CSV_STORAGE_ENGINE=1
-DWITH_HEAP_STORAGE_ENGINE=1
-DWITH_INNOBASE_STORAGE_ENGINE=1
-DWITH_MYISAMMRG_STORAGE_ENGINE=1
-DWITH_MYISAM_STORAGE_ENGINE=1
-DWITH_PARTITION_STORAGE_ENGINE=1
)
else
mycmakeargs+=(
-DWITHOUT_SERVER=1
-DEXTRA_CHARSETS=none
-DINSTALL_SQLBENCHDIR=
)
fi
cmake-utils_src_configure
}
src_compile() {
cmake-utils_src_compile
}
src_install() {
cmake-utils_src_install
# Remove an unnecessary, private config header which will never match between ABIs and is not meant to be used
if [[ -f "${ED%/}/usr/include/mysql/server/private/config.h" ]] ; then
rm "${ED%/}/usr/include/mysql/server/private/config.h" || die
fi
# Make sure the vars are correctly initialized
mysql_init_vars
# Convenience links
einfo "Making Convenience links for mysqlcheck multi-call binary"
dosym "mysqlcheck" "/usr/bin/mysqlanalyze"
dosym "mysqlcheck" "/usr/bin/mysqlrepair"
dosym "mysqlcheck" "/usr/bin/mysqloptimize"
# INSTALL_LAYOUT=STANDALONE causes cmake to create a /usr/data dir
if [[ -d "${ED%/}/usr/data" ]] ; then
rm -Rf "${ED%/}/usr/data" || die
fi
# Unless they explicitly specific USE=test, then do not install the
# testsuite. It DOES have a use to be installed, esp. when you want to do a
# validation of your database configuration after tuning it.
if ! use test ; then
rm -rf "${D%/}/${MY_SHAREDSTATEDIR}/mysql-test"
fi
# Configuration stuff
einfo "Building default configuration ..."
insinto "${MY_SYSCONFDIR#${EPREFIX}}"
[[ -f "${S%/}/scripts/mysqlaccess.conf" ]] && doins "${S%/}"/scripts/mysqlaccess.conf
local mycnf_src="my.cnf-5.6-r1"
sed -e "s!@DATADIR@!${MY_DATADIR}!g" \
"${FILESDIR%/}/${mycnf_src}" \
> "${TMPDIR%/}/my.cnf.ok" || die
use prefix && sed -i -r -e '/^user[[:space:]]*=[[:space:]]*mysql$/d' "${TMPDIR%/}/my.cnf.ok"
if use latin1 ; then
sed -i \
-e "/character-set/s|utf8|latin1|g" \
"${TMPDIR%/}/my.cnf.ok" || die
fi
eprefixify "${TMPDIR%/}/my.cnf.ok"
newins "${TMPDIR}/my.cnf.ok" my.cnf
if use server ; then
einfo "Including support files and sample configurations"
docinto "support-files"
local script
for script in \
"${S%/}"/support-files/magic
do
[[ -f "$script" ]] && dodoc "${script}"
done
docinto "scripts"
for script in "${S%/}"/scripts/mysql* ; do
[[ ( -f "$script" ) && ( "${script%.sh}" == "${script}" ) ]] && dodoc "${script}"
done
# Manually install supporting files that conflict with other packages
# but are needed for galera and initial installation
exeinto /usr/libexec/mariadb
doexe "${BUILD_DIR}/extra/my_print_defaults" "${BUILD_DIR}/extra/perror"
fi
#Remove mytop if perl is not selected
[[ -e "${ED%/}/usr/bin/mytop" ]] && ! use perl && rm -f "${ED%/}/usr/bin/mytop"
}
# Official test instructions:
# USE='extraengine perl server' \
# FEATURES='test userpriv -usersandbox' \
# ebuild mariadb-X.X.XX.ebuild \
# digest clean package
src_test() {
_disable_test() {
local rawtestname reason
rawtestname="${1}" ; shift
reason="${@}"
ewarn "test '${rawtestname}' disabled: '${reason}'"
echo ${rawtestname} : ${reason} >> "${T}/disabled.def"
}
local TESTDIR="${BUILD_DIR}/mysql-test"
local retstatus_unit
local retstatus_tests
if ! use server ; then
einfo "Skipping server tests due to minimal build."
return 0
fi
# Bug #213475 - MySQL _will_ object strenously if your machine is named
# localhost. Also causes weird failures.
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
if [[ $UID -eq 0 ]]; then
die "Testing with FEATURES=-userpriv is no longer supported by upstream. Tests MUST be run as non-root."
fi
has usersandbox $FEATURES && ewarn "Some tests may fail with FEATURES=usersandbox"
einfo ">>> Test phase [test]: ${CATEGORY}/${PF}"
# Run CTest (test-units)
cmake-utils_src_test
retstatus_unit=$?
# Ensure that parallel runs don't die
export MTR_BUILD_THREAD="$((${RANDOM} % 100))"
# Enable parallel testing, auto will try to detect number of cores
# You may set this by hand.
# The default maximum is 8 unless MTR_MAX_PARALLEL is increased
export MTR_PARALLEL="${MTR_PARALLEL:-auto}"
# create directories because mysqladmin might run out of order
mkdir -p "${T}"/var-tests{,/log} || die
# Run mysql tests
pushd "${TESTDIR}" > /dev/null || die
touch "${T}/disabled.def"
# These are failing in MariaDB 10.0 for now and are believed to be
# false positives:
#
# main.mysql_client_test, main.mysql_client_test_nonblock
# main.mysql_client_test_comp:
# segfaults at random under Portage only, suspect resource limits.
local t
for t in main.mysql_client_test main.mysql_client_test_nonblock \
main.mysql_client_test_comp rpl.rpl_extra_col_master_myisam \
rpl.rpl_semi_sync_uninstall_plugin ; do
_disable_test "$t" "False positives in Gentoo"
done
if ! use client-libs ; then
_disable_test main.plugin_auth "Needs client libraries built"
fi
# run mysql-test tests
perl mysql-test-run.pl --force --vardir="${T}/var-tests" --reorder --skip-test=tokudb --skip-test-list="${T}/disabled.def"
retstatus_tests=$?
popd > /dev/null || die
# Cleanup is important for these testcases.
pkill -9 -f "${S}/ndb" 2>/dev/null
pkill -9 -f "${S}/sql" 2>/dev/null
local failures=""
[[ $retstatus_unit -eq 0 ]] || failures="${failures} test-unit"
[[ $retstatus_tests -eq 0 ]] || failures="${failures} tests"
[[ -z "$failures" ]] || die "Test failures: $failures"
einfo "Tests successfully completed"
}
mysql_init_vars() {
MY_SHAREDSTATEDIR=${MY_SHAREDSTATEDIR="${EPREFIX}/usr/share/mariadb"}
MY_SYSCONFDIR=${MY_SYSCONFDIR="${EPREFIX}/etc/mysql"}
MY_LOCALSTATEDIR=${MY_LOCALSTATEDIR="${EPREFIX}/var/lib/mysql"}
MY_LOGDIR=${MY_LOGDIR="${EPREFIX}/var/log/mysql"}
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR=""
if [[ -f "${MY_SYSCONFDIR}/my.cnf" ]] ; then
MY_DATADIR=`"my_print_defaults" mysqld 2>/dev/null \
| sed -ne '/datadir/s|^--datadir=||p' \
| tail -n1`
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR=`grep ^datadir "${MY_SYSCONFDIR}/my.cnf" \
| sed -e 's/.*=\s*//' \
| tail -n1`
fi
fi
if [[ -z "${MY_DATADIR}" ]] ; then
MY_DATADIR="${MY_LOCALSTATEDIR}"
einfo "Using default MY_DATADIR"
fi
elog "MySQL MY_DATADIR is ${MY_DATADIR}"
if [[ -z "${PREVIOUS_DATADIR}" ]] ; then
if [[ -e "${MY_DATADIR}" ]] ; then
# If you get this and you're wondering about it, see bug #207636
elog "MySQL datadir found in ${MY_DATADIR}"
elog "A new one will not be created."
PREVIOUS_DATADIR="yes"
else
PREVIOUS_DATADIR="no"
fi
export PREVIOUS_DATADIR
fi
else
if [[ ${EBUILD_PHASE} == "config" ]]; then
local new_MY_DATADIR
new_MY_DATADIR=`"my_print_defaults" mysqld 2>/dev/null \
| sed -ne '/datadir/s|^--datadir=||p' \
| tail -n1`
if [[ ( -n "${new_MY_DATADIR}" ) && ( "${new_MY_DATADIR}" != "${MY_DATADIR}" ) ]]; then
ewarn "MySQL MY_DATADIR has changed"
ewarn "from ${MY_DATADIR}"
ewarn "to ${new_MY_DATADIR}"
MY_DATADIR="${new_MY_DATADIR}"
fi
fi
fi
export MY_SHAREDSTATEDIR MY_SYSCONFDIR
export MY_LOCALSTATEDIR MY_LOGDIR
export MY_DATADIR
}
pkg_config() {
_getoptval() {
local mypd="${EROOT}"/usr/bin/my_print_defaults
local section="$1"
local flag="--${2}="
local extra_options="${3}"
"${mypd}" $extra_options $section | sed -n "/^${flag}/s,${flag},,gp"
}
local old_MY_DATADIR="${MY_DATADIR}"
local old_HOME="${HOME}"
# my_print_defaults needs to read stuff in $HOME/.my.cnf
export HOME=${EPREFIX}/root
# Make sure the vars are correctly initialized
mysql_init_vars
[[ -z "${MY_DATADIR}" ]] && die "Sorry, unable to find MY_DATADIR"
if [[ ! -x "${EROOT}/usr/sbin/mysqld" ]] ; then
die "Minimal builds do NOT include the MySQL server"
fi
if [[ ( -n "${MY_DATADIR}" ) && ( "${MY_DATADIR}" != "${old_MY_DATADIR}" ) ]]; then
local MY_DATADIR_s="${ROOT}/${MY_DATADIR}"
MY_DATADIR_s="${MY_DATADIR_s%%/}"
local old_MY_DATADIR_s="${ROOT}/${old_MY_DATADIR}"
old_MY_DATADIR_s="${old_MY_DATADIR_s%%/}"
if [[ ( -d "${old_MY_DATADIR_s}" ) && ( "${old_MY_DATADIR_s}" != / ) ]]; then
if [[ -d "${MY_DATADIR_s}" ]]; then
ewarn "Both ${old_MY_DATADIR_s} and ${MY_DATADIR_s} exist"
ewarn "Attempting to use ${MY_DATADIR_s} and preserving ${old_MY_DATADIR_s}"
else
elog "Moving MY_DATADIR from ${old_MY_DATADIR_s} to ${MY_DATADIR_s}"
mv --strip-trailing-slashes -T "${old_MY_DATADIR_s}" "${MY_DATADIR_s}" \
|| die "Moving MY_DATADIR failed"
fi
else
ewarn "Previous MY_DATADIR (${old_MY_DATADIR_s}) does not exist"
if [[ -d "${MY_DATADIR_s}" ]]; then
ewarn "Attempting to use ${MY_DATADIR_s}"
else
eerror "New MY_DATADIR (${MY_DATADIR_s}) does not exist"
die "Configuration Failed! Please reinstall ${CATEGORY}/${PN}"
fi
fi
fi
local pwd1="a"
local pwd2="b"
local maxtry=15
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
local tmp_mysqld_password_source=
for tmp_mysqld_password_source in mysql client; do
einfo "Trying to get password for mysql 'root' user from '${tmp_mysqld_password_source}' section ..."
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password)"
if [[ -n "${MYSQL_ROOT_PASSWORD}" ]]; then
if [[ ${MYSQL_ROOT_PASSWORD} == *$'\n'* ]]; then
ewarn "Ignoring password from '${tmp_mysqld_password_source}' section due to newline character (do you have multiple password options set?)!"
MYSQL_ROOT_PASSWORD=
continue
fi
einfo "Found password in '${tmp_mysqld_password_source}' section!"
break
fi
done
# Sometimes --show is required to display passwords in some implementations of my_print_defaults
if [[ "${MYSQL_ROOT_PASSWORD}" == '*****' ]]; then
MYSQL_ROOT_PASSWORD="$(_getoptval "${tmp_mysqld_password_source}" password --show)"
fi
unset tmp_mysqld_password_source
fi
MYSQL_TMPDIR="$(_getoptval mysqld tmpdir)"
# These are dir+prefix
MYSQL_RELAY_LOG="$(_getoptval mysqld relay-log)"
MYSQL_RELAY_LOG=${MYSQL_RELAY_LOG%/*}
MYSQL_LOG_BIN="$(_getoptval mysqld log-bin)"
MYSQL_LOG_BIN=${MYSQL_LOG_BIN%/*}
if [[ ! -d "${ROOT}/$MYSQL_TMPDIR" ]]; then
einfo "Creating MySQL tmpdir $MYSQL_TMPDIR"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_TMPDIR"
fi
if [[ ! -d "${ROOT}/$MYSQL_LOG_BIN" ]]; then
einfo "Creating MySQL log-bin directory $MYSQL_LOG_BIN"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_LOG_BIN"
fi
if [[ ! -d "${EROOT}/$MYSQL_RELAY_LOG" ]]; then
einfo "Creating MySQL relay-log directory $MYSQL_RELAY_LOG"
install -d -m 770 -o mysql -g mysql "${EROOT}/$MYSQL_RELAY_LOG"
fi
if [[ -d "${ROOT}/${MY_DATADIR}/mysql" ]] ; then
ewarn "You have already a MySQL database in place."
ewarn "(${ROOT}/${MY_DATADIR}/*)"
ewarn "Please rename or delete it if you wish to replace it."
die "MySQL database already exists!"
fi
# Bug #213475 - MySQL _will_ object strenously if your machine is named
# localhost. Also causes weird failures.
[[ "${HOSTNAME}" == "localhost" ]] && die "Your machine must NOT be named localhost"
if [ -z "${MYSQL_ROOT_PASSWORD}" ]; then
einfo "Please provide a password for the mysql 'root' user now"
einfo "or through the ${HOME}/.my.cnf file."
ewarn "Avoid [\"'\\_%] characters in the password"
read -rsp " >" pwd1 ; echo
einfo "Retype the password"
read -rsp " >" pwd2 ; echo
if [[ "x$pwd1" != "x$pwd2" ]] ; then
die "Passwords are not the same"
fi
MYSQL_ROOT_PASSWORD="${pwd1}"
unset pwd1 pwd2
fi
local options
local sqltmp="$(emktemp)"
# Fix bug 446200. Don't reference host my.cnf, needs to come first,
# see https://bugs.mysql.com/bug.php?id=31312
use prefix && options="${options} '--defaults-file=${MY_SYSCONFDIR}/my.cnf'"
# Figure out which options we need to disable to do the setup
local helpfile="${TMPDIR}/mysqld-help"
"${EROOT}/usr/sbin/mysqld" --verbose --help >"${helpfile}" 2>/dev/null
for opt in grant-tables host-cache name-resolve networking slave-start \
federated ssl log-bin relay-log slow-query-log external-locking \
log-slave-updates \
; do
optexp="--(skip-)?${opt}" optfull="--loose-skip-${opt}"
egrep -sq -- "${optexp}" "${helpfile}" && options="${options} ${optfull}"
done
einfo "Creating the mysql database and setting proper permissions on it ..."
# Now that /var/run is a tmpfs mount point, we need to ensure it exists before using it
PID_DIR="${EROOT}/var/run/mysqld"
if [[ ! -d "${PID_DIR}" ]]; then
install -d -m 755 -o mysql -g mysql "${PID_DIR}" || die "Could not create pid directory"
fi
if [[ ! -d "${MY_DATADIR}" ]]; then
install -d -m 750 -o mysql -g mysql "${MY_DATADIR}" || die "Could not create data directory"
fi
pushd "${TMPDIR}" &>/dev/null || die
# Filling timezones, see
# https://dev.mysql.com/doc/mysql/en/time-zone-support.html
"${EROOT}/usr/bin/mysql_tzinfo_to_sql" "${EROOT}/usr/share/zoneinfo" > "${sqltmp}" 2>/dev/null
local cmd=( "${EROOT}usr/share/mariadb/scripts/mysql_install_db" )
[[ -f "${cmd}" ]] || cmd=( "${EROOT}usr/bin/mysql_install_db" )
cmd+=( "--basedir=${EPREFIX}/usr" ${options} "--datadir=${ROOT}/${MY_DATADIR}" "--tmpdir=${ROOT}/${MYSQL_TMPDIR}" )
einfo "Command: ${cmd[*]}"
su -s /bin/sh -c "${cmd[*]}" mysql \
>"${TMPDIR}"/mysql_install_db.log 2>&1
if [ $? -ne 0 ]; then
grep -B5 -A999 -i "ERROR" "${TMPDIR}"/mysql_install_db.log 1>&2
die "Failed to initialize mysqld. Please review ${EPREFIX}/var/log/mysql/mysqld.err AND ${TMPDIR}/mysql_install_db.log"
fi
popd &>/dev/null || die
[[ -f "${ROOT}/${MY_DATADIR}/mysql/user.frm" ]] \
|| die "MySQL databases not installed"
use prefix || options="${options} --user=mysql"
local socket="${EROOT}/var/run/mysqld/mysqld${RANDOM}.sock"
local pidfile="${EROOT}/var/run/mysqld/mysqld${RANDOM}.pid"
local mysqld="${EROOT}/usr/sbin/mysqld \
${options} \
--log-warnings=0 \
--basedir=${EROOT}/usr \
--datadir=${ROOT}/${MY_DATADIR} \
--max_allowed_packet=8M \
--net_buffer_length=16K \
--socket=${socket} \
--pid-file=${pidfile} \
--tmpdir=${ROOT}/${MYSQL_TMPDIR}"
#einfo "About to start mysqld: ${mysqld}"
ebegin "Starting mysqld"
einfo "Command ${mysqld}"
${mysqld} &
rc=$?
while ! [[ -S "${socket}" || "${maxtry}" -lt 1 ]] ; do
maxtry=$((${maxtry}-1))
echo -n "."
sleep 1
done
eend $rc
if ! [[ -S "${socket}" ]]; then
die "Completely failed to start up mysqld with: ${mysqld}"
fi
ebegin "Setting root password"
# Do this from memory, as we don't want clear text passwords in temp files
local sql="UPDATE mysql.user SET Password = PASSWORD('${MYSQL_ROOT_PASSWORD}') WHERE USER='root'; FLUSH PRIVILEGES"
"${EROOT}/usr/bin/mysql" \
"--socket=${socket}" \
-hlocalhost \
-e "${sql}"
eend $?
if [[ -n "${sqltmp}" ]] ; then
ebegin "Loading \"zoneinfo\", this step may require a few seconds"
"${EROOT}/usr/bin/mysql" \
"--socket=${socket}" \
-hlocalhost \
-uroot \
--password="${MYSQL_ROOT_PASSWORD}" \
mysql < "${sqltmp}"
rc=$?
eend $?
[[ $rc -ne 0 ]] && ewarn "Failed to load zoneinfo!"
fi
# Stop the server and cleanup
einfo "Stopping the server ..."
kill $(< "${pidfile}" )
rm -f "${sqltmp}"
wait %1
einfo "Done"
}

@ -1,9 +1,9 @@
# Copyright 1999-2018 Gentoo Foundation
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
POSTGRES_COMPAT=( 9.{3..6} 10 )
POSTGRES_COMPAT=( 9.{4..6} 10 )
inherit desktop postgres qmake-utils

@ -3,7 +3,7 @@
EAPI=6
POSTGRES_COMPAT=( 9.{3..6} 10 )
POSTGRES_COMPAT=( 9.{4..6} 10 )
inherit autotools postgres-multi

@ -3,7 +3,7 @@
EAPI=6
POSTGRES_COMPAT=( 9.{3..6} {10..11} )
POSTGRES_COMPAT=( 9.{4..6} {10..11} )
inherit autotools postgres-multi

@ -3,7 +3,7 @@
EAPI=6
POSTGRES_COMPAT=( 9.{3..6} {10..11} )
POSTGRES_COMPAT=( 9.{4..6} {10..11} )
inherit postgres-multi

@ -1,9 +1,9 @@
# Copyright 1999-2018 Gentoo Foundation
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
POSTGRES_COMPAT=( 9.{3..6} 10 )
POSTGRES_COMPAT=( 9.{4..6} 10 )
POSTGRES_USEDEP="server"
inherit postgres-multi

@ -3,7 +3,7 @@
EAPI="6"
POSTGRES_COMPAT=( 9.{3..6} {10..11} )
POSTGRES_COMPAT=( 9.{4..6} {10..11} )
POSTGRES_USEDEP="server"
inherit autotools eutils postgres-multi versionator

@ -1,17 +1,6 @@
DIST postgresql-10.6.tar.bz2 20350612 BLAKE2B b751085b8fce73efb2531378a553c8c956f5e05a0002de8fdc58c0f2a6cf2b9dfaff6bd621047a094a51e459bc8fc5b1658d6a754a396fa3b7aedc1024ea3b4c SHA512 5d4d5cee2a19ad1820c3411bc4851904e3059cdcacc837350694d54d7d59260b66c565c72cc14a3a10541a8fc49c5185f08f57b7a8c7e4c64ed2614da6e1201f
DIST postgresql-10.7.tar.bz2 18940030 BLAKE2B ce02d2c4ba97c1845b3708941bb7a9f6ee025fc4a881e35790279aadf5e35464d6716cfdeb4ad145ce4549e639ad01d333cff858f956607c0cd583af65f1cd3e SHA512 2fa8194e9ef540930eecc2a43907a77f7f185590046350d48fd625bdb1ab459095c4e2e0d2faac846935d7231ac672ace760633deeee365572768da619458ba9
DIST postgresql-10.8.tar.bz2 18958913 BLAKE2B d2e1664a53c5b2f24b412f497769ffd33e2f48977fa0f4503cb588497b61955a97497c87950ae60d498d75c7385fc63dd832b518174614f695d8882628a4ebb8 SHA512 c9cd0298f553e13e32d4315e17e9e61c1fd011391c5203282d9040f26fd08c85f749e6f2cea3bcc42d1ca153a1272bcd773196ef3bf2bdfb74cd12c5f523b7ca
DIST postgresql-11.1.tar.bz2 21263173 BLAKE2B d762b6e8b0e7b08b16ed252687118a0a4516172e38e8940879fd050f72d19ff045af949e72977a62c2ce0a788af7d42c9bde7748347566bec3694e337bba6f73 SHA512 35d00984e9f5f063a5b96e97aa1b40381ab76d07b2336bda5981fd80bef1324f56eefca5069ae78770ecd6ece5df85264e599fdb3478ecb71d4fdd0d7b6becca
DIST postgresql-11.2.tar.bz2 19714229 BLAKE2B 459674c08a0435363da29428bef7ec49a012b534b390ce6addafac000ce58ad0ad7ba4e1522f5279da29535399836971c61536827d481af766322935d7c6d01b SHA512 dae00a543fdeed36bc338abd4ccfd9fe9a8b6b2b7eaa00b1078e4f27802de75a461c27da2800bc9dd64e658681e5787bd03764bde79940656cae1e8c8716f011
DIST postgresql-11.3.tar.bz2 19718775 BLAKE2B f56686bff4e70c2b6333554a620a5c2d5c226654a1d61de43b4493c44a14e2bcd9c102dba420994878d328af52d933885e4948cd002f14b693aef1416697a0ea SHA512 03269bb88f44f3a81d5e3a8ca2fe59f63f784436840f08870b2e539755629cbde8ac288e0bb4472ee93294a88b37b814ddff48444254c1a3f7a10b4bb64f7133
DIST postgresql-12beta1.tar.bz2 20589423 BLAKE2B 622f936524bca74c20e27967b4cfcec31ba4ffc3132af516fc6dbb89843d688df41b72b7febe7060d2eb6716d64228124b4bc9831e9b11601be0fd95b7727710 SHA512 f46017659aa88141b056fc1852280c92ffbc3ba52d1cda2e3e302d3ec6ba478cc2a8ab04c87f10774b0401e8284fc46bb387a3e0e594a26a30ef7a4cf79b1de3
DIST postgresql-9.3.25.tar.bz2 17067593 BLAKE2B fd9ca5685e5511dcaa72da882b674846dcd5a16227e5b33ae06701fe7881df71847666c37925033c6cb01c916111a8f76df134491645f4d1e1dd48a008bd2831 SHA512 319e12b73853b74f5ef2c520d64795bb586ffd495ceab6518f7844de6e0a054aea821976c470108d346f8090c7d3949920d9c435432e33004b7caa7a77a5cdca
DIST postgresql-9.4.20.tar.bz2 17905682 BLAKE2B cb65228f8e78dc8b6303a06480a68de58ecac1fefa1342e4563f2c4051c9f5506b366b36c2dbd54207d25ae497625f8fc5e3e771174a6b3ec33c3c19d2c9ea08 SHA512 664c6e97979f38d263d1dc75a7db442f193a230435cad43ddfa2afcd42ac0d73b2aef0e846fddcc9008cd6d89cba2d5c0a4db93b111665646d3ff4d8f6fbe1e8
DIST postgresql-9.4.21.tar.bz2 16871522 BLAKE2B e6b8957f52a95d5fa56bc39756f1de83459882e40eee07c3ddf9e33eab39a0d61ee492864a920e7714ca1914a772dcc9048bc34072349197597cfb116aa94422 SHA512 850d1f59369457d9a8a42de8f0e4811f60e9164d2e7d7605fdabc04cc5ba2e3794d51e155d709419d06b8e070f214f7d3ef2328c6d37f125264ea008ca18ff5a
DIST postgresql-9.4.22.tar.bz2 16848787 BLAKE2B 5c2aaef13ef0cf33c421e6839877a8e4e1fc5dbe41d9cabefddd369925869f92f6c6b8a124b5778f9b25359103f0a7ada1eddcaf4bac498709f563928f25e7e3 SHA512 f11623a89b2320616fd53eda52da544bdfcb63bff08cb78fccde134ef628eee7ee90b3de6952f4e08c10297d356624faabf0e5b181b0105f51797796cd04efef
DIST postgresql-9.5.15.tar.bz2 18707696 BLAKE2B f1be26085953d5a15a6545aed3527b9eec6eb57c72f2e05401e43200e628b3a42ee824dd1cb0138556b97fe4922a991489dffa77329b653475874766c1d5b944 SHA512 2ea241b6751a2812c689da9bde40151ebb7cdabdd14e93d92f8bea1e3fcf5bc0d4854834999f33270329e22a09c5aeaf8d59d36ca6e8860704f81f3adcfb30d5
DIST postgresql-9.5.16.tar.bz2 17506874 BLAKE2B ce5c804315ce5d7ac95af2455322801f581c3aa8e943ffae40b7e14a95a4610b71956568a418f2f22b8a9814ff9fd1f9296efc974716c0096aa22dcdb7609ff7 SHA512 4583c825ed00a5ba915863b41c39cd9580492444ff299e44c3856db55fb4f0607d184534fe8977d915fb0730e6d638d8560be11915ce21b9d1f6971e7a285c7c
DIST postgresql-9.5.17.tar.bz2 17563469 BLAKE2B d40b7f95d03db594144b4882f36bbe22f348faab0b8d67eda3f946448bb0e09188eccdeb4d1c92742fb29a920b30ede55e536a863b22d2009283eab66679122d SHA512 bb468528b1f18166cda0be136f31a632859ffe6e6800233b1cb0e91ce11d2d00d3dc108a74580b5552a4d30b9f1b6849c91576cd497beac788c429815c66eac5
DIST postgresql-9.6.11.tar.bz2 20009048 BLAKE2B aa3e5b1e63c983226ea71737982e62eaff655af7e0f55f20ec886f5d7406b1e30e2fe5378b0dd1ef59e777f862ccc2386121653853d4c186a1b4853a9bbb1591 SHA512 a4314f92d1a661af4076d8c120533ecae76d91461043b8a6ad22dd6e5b562e0bf019bc7f3157a26d9666ba5866e254613ae5b690310168b029795dc088f8c060
DIST postgresql-9.6.12.tar.bz2 18759442 BLAKE2B 067b307318f65616651ee4502f420a84df26e906350f07ce5ab4a769608075f0d017b6d84b0ce5045662ab379e236b66cf751f7950d026f011d0915efcdfab3e SHA512 3a7a96caf682461f1f9bffdbe2b72b1ce00cc6680145e00c139e4af8b9dc8b8679fda1626de65921d6e187fa9290efc930584b98f1fd2aba1ba3d790a741a415
DIST postgresql-9.6.13.tar.bz2 18767279 BLAKE2B c1ec780a7f938f878425cbd6556145e60a613135129daaacc52e9a699cc448a22481b01fac20d0c09373ea6a026f39bc58234aae4f1126333b94f621981a8135 SHA512 65cc70410ad4a1a738b92855b92eecdbb9efbbca0eb9a45a138d47b696c8f9c9cd19073fbfdf5c80eea7633d0be29b4ed8acbadd38724acf8f18c90bb30f9b26

@ -1,144 +0,0 @@
--- a/contrib/Makefile
+++ b/contrib/Makefile
@@ -5,61 +5,10 @@
include $(top_builddir)/src/Makefile.global
SUBDIRS = \
- adminpack \
- auth_delay \
- auto_explain \
- btree_gin \
- btree_gist \
- chkpass \
- citext \
- cube \
- dblink \
- dict_int \
- dict_xsyn \
- dummy_seclabel \
- earthdistance \
- file_fdw \
- fuzzystrmatch \
- hstore \
- intagg \
- intarray \
- isn \
- lo \
- ltree \
oid2name \
- pageinspect \
- passwordcheck \
- pg_archivecleanup \
- pg_buffercache \
- pg_freespacemap \
- pg_standby \
- pg_stat_statements \
- pg_test_fsync \
- pg_test_timing \
- pg_trgm \
- pg_upgrade \
- pg_upgrade_support \
pgbench \
- pgcrypto \
- pgrowlocks \
- pgstattuple \
- pg_xlogdump \
- postgres_fdw \
- seg \
- spi \
- tablefunc \
- tcn \
- test_parser \
- tsearch2 \
- unaccent \
- vacuumlo \
- worker_spi
+ vacuumlo
-ifeq ($(with_openssl),yes)
-SUBDIRS += sslinfo
-else
-ALWAYS_SUBDIRS += sslinfo
-endif
ifeq ($(with_ossp_uuid),yes)
SUBDIRS += uuid-ossp
--- a/src/backend/Makefile
+++ b/src/backend/Makefile
@@ -47,7 +47,7 @@
##########################################################################
-all: submake-libpgport submake-schemapg postgres $(POSTGRES_IMP)
+all: someheaders
ifneq ($(PORTNAME), cygwin)
ifneq ($(PORTNAME), win32)
@@ -116,7 +116,7 @@
endif # aix
# Update the commonly used headers before building the subdirectories
-$(SUBDIRS:%=%-recursive): $(top_builddir)/src/include/parser/gram.h $(top_builddir)/src/include/catalog/schemapg.h $(top_builddir)/src/include/utils/fmgroids.h $(top_builddir)/src/include/utils/errcodes.h $(top_builddir)/src/include/utils/probes.h
+someheaders $(SUBDIRS:%=%-recursive): $(top_builddir)/src/include/parser/gram.h $(top_builddir)/src/include/catalog/schemapg.h $(top_builddir)/src/include/utils/fmgroids.h $(top_builddir)/src/include/utils/errcodes.h $(top_builddir)/src/include/utils/probes.h
# run this unconditionally to avoid needing to know its dependencies here:
submake-schemapg:
@@ -209,23 +209,8 @@
##########################################################################
-install: all installdirs install-bin
-ifeq ($(PORTNAME), cygwin)
-ifeq ($(MAKE_DLL), true)
- $(INSTALL_DATA) libpostgres.a '$(DESTDIR)$(libdir)/libpostgres.a'
-endif
-endif
-ifeq ($(PORTNAME), win32)
-ifeq ($(MAKE_DLL), true)
- $(INSTALL_DATA) libpostgres.a '$(DESTDIR)$(libdir)/libpostgres.a'
-endif
-endif
- $(MAKE) -C catalog install-data
- $(MAKE) -C tsearch install-data
- $(INSTALL_DATA) $(srcdir)/libpq/pg_hba.conf.sample '$(DESTDIR)$(datadir)/pg_hba.conf.sample'
- $(INSTALL_DATA) $(srcdir)/libpq/pg_ident.conf.sample '$(DESTDIR)$(datadir)/pg_ident.conf.sample'
- $(INSTALL_DATA) $(srcdir)/utils/misc/postgresql.conf.sample '$(DESTDIR)$(datadir)/postgresql.conf.sample'
- $(INSTALL_DATA) $(srcdir)/access/transam/recovery.conf.sample '$(DESTDIR)$(datadir)/recovery.conf.sample'
+install:
+
install-bin: postgres $(POSTGRES_IMP) installdirs
$(INSTALL_PROGRAM) postgres$(X) '$(DESTDIR)$(bindir)/postgres$(X)'
--- a/src/bin/Makefile
+++ b/src/bin/Makefile
@@ -13,8 +13,7 @@
top_builddir = ../..
include $(top_builddir)/src/Makefile.global
-SUBDIRS = initdb pg_ctl pg_dump \
- psql scripts pg_config pg_controldata pg_resetxlog pg_basebackup
+SUBDIRS = pg_dump psql scripts pg_config
ifeq ($(PORTNAME), win32)
SUBDIRS += pgevent
--- a/src/Makefile
+++ b/src/Makefile
@@ -15,17 +15,11 @@
SUBDIRS = \
common \
port \
- timezone \
backend \
- backend/utils/mb/conversion_procs \
- backend/snowball \
include \
interfaces \
- backend/replication/libpqwalreceiver \
bin \
- pl \
- makefiles \
- test/regress
+ makefiles
# There are too many interdependencies between the subdirectories, so
# don't attempt parallel make here.

@ -1,460 +0,0 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
PYTHON_COMPAT=( python2_7 python3_{5,6} )
PLOCALES="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"
inherit flag-o-matic l10n 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 ~x86-fbsd ~ppc-macos ~x86-solaris"
SLOT=$(get_major_version)
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="https://www.postgresql.org/"
IUSE="doc kerberos kernel_linux ldap libressl nls pam perl python +readline
selinux +server systemd ssl static-libs tcl threads uuid xml zlib"
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
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= )
server? ( systemd? ( sys-apps/systemd ) )
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 || eapply "${FILESDIR}/${PN}-10.2-no-server.patch"
if use pam ; then
sed -e "s/\(#define PGSQL_PAM_SERVICE \"postgresql\)/\1-${SLOT}/" \
-i src/backend/libpq/auth.c || \
die 'PGSQL_PAM_SERVICE rename failed.'
fi
eapply_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 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) \
$(usex server "$(use_with systemd)" '--without-systemd') \
$(use_with tcl) \
${uuid_config} \
$(use_with xml libxml) \
$(use_with xml libxslt) \
$(use_with zlib) \
$(use_enable nls nls "'$(l10n_get_locales)'")
}
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
serverman=(
initdb
pg_{archivecleanup,controldata,ctl,resetwal,rewind,standby}
pg_{test_{fsync,timing},upgrade,waldump}
post{gres,master}
)
for m in ${serverman[@]} ; do
rm "${ED}/usr/share/postgresql-${SLOT}/man/man1/${m}.1"
done
fi
docompress /usr/share/postgresql-${SLOT}/man/man{1,3,7}
# Create slot specific man pages
local bn f mansec slotted_name
for mansec in 1 3 7 ; do
local rel_manpath="../../postgresql-${SLOT}/man/man${mansec}"
mkdir -p "${ED}"/usr/share/man/man${mansec} || die "making man dir"
pushd "${ED}"/usr/share/man/man${mansec} > /dev/null || die "pushd failed"
for f in "${ED}/usr/share/postgresql-${SLOT}/man/man${mansec}"/* ; do
bn=$(basename "${f}")
slotted_name=${bn%.${mansec}}${SLOT}.${mansec}
case ${bn} in
TABLE.7|WITH.7)
echo ".so ${rel_manpath}/SELECT.7" > ${slotted_name}
;;
*)
echo ".so ${rel_manpath}/${bn}" > ${slotted_name}
;;
esac
done
popd > /dev/null
done
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/.}"
done
if use doc ; then
docinto html
dodoc doc/src/sgml/html/*
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}
if use systemd; then
sed -e "s|@SLOT@|${SLOT}|g" -e "s|@LIBDIR@|$(get_libdir)|g" \
"${FILESDIR}/${PN}.service-9.6-r1" | \
systemd_newunit - ${PN}-${SLOT}.service
newbin "${FILESDIR}"/${PN}-check-db-dir ${PN}-${SLOT}-check-db-dir
systemd_newtmpfilesd "${FILESDIR}"/${PN}.tmpfiles ${PN}-${SLOT}.conf
fi
use pam && pamd_mimic system-auth ${PN}-${SLOT} auth account session
if use prefix ; then
keepdir /run/postgresql
fperms 1775 /run/postgresql
fi
fi
}
pkg_postinst() {
use server && use systemd && systemd_tmpfiles_create ${PN}-${SLOT}.conf
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 "https://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}"
if [[ -n ${REPLACING_VERSIONS} ]] ; then
ewarn "If your system is using 'pg_stat_statements' and you are running a"
ewarn "version of PostgreSQL ${SLOT}, we advise that you execute"
ewarn "the following command after upgrading:"
ewarn
ewarn "ALTER EXTENSION pg_stat_statements UPDATE;"
fi
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 " https://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html"
einfo " https://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
if ! use systemd; then
einfo "The PostgreSQL server, by default, will log events to:"
einfo " ${DATA_DIR%/}/postmaster.log"
einfo
fi
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}"
elif use systemd; then
einfo "You should use the 'postgresql-${SLOT}.service' unit to run PostgreSQL"
einfo "instead of 'pg_ctl'."
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
}

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

Loading…
Cancel
Save