parent
f20dc18a77
commit
738a8fca91
Binary file not shown.
Binary file not shown.
@ -0,0 +1,38 @@
|
||||
# Copyright 1999-2019 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI="7"
|
||||
|
||||
MY_PN=${PN}.sh
|
||||
DESCRIPTION="Tool to check properties of executables (e.g. ASLR/PIE, RELRO, PaX, Canaries)"
|
||||
HOMEPAGE="https://github.com/slimm609/checksec.sh"
|
||||
SRC_URI="https://github.com/slimm609/${MY_PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
||||
|
||||
LICENSE="BSD"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~mips ~ppc ~ppc64 ~x86"
|
||||
IUSE=""
|
||||
|
||||
S="${WORKDIR}"/${MY_PN}-${PV}
|
||||
|
||||
DOCS=( ChangeLog README.md )
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-1.7.2-path.patch
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
sed 's,^pkg_release=false,pkg_release=true,' -i ${PN} || die
|
||||
default
|
||||
}
|
||||
|
||||
src_install() {
|
||||
default
|
||||
|
||||
doman extras/man/*
|
||||
|
||||
insinto /usr/share/zsh/site-functions
|
||||
doins extras/zsh/_${PN}
|
||||
|
||||
dobin ${PN}
|
||||
}
|
@ -1,18 +0,0 @@
|
||||
#!/sbin/openrc-run
|
||||
# Copyright 1999-2015 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
MCOLLECTIVE_PID_DIR="${MCOLLECTIVE_PID_DIR:-/var/run/puppetlabs}"
|
||||
|
||||
command="/usr/sbin/mcollectived"
|
||||
pidfile="${MCOLLECTIVE_PID_DIR}/mcollectived.pid"
|
||||
|
||||
command_args="--pidfile ${pidfile} --config=/etc/puppetlabs/mcollective/server.cfg --daemonize"
|
||||
|
||||
depend() {
|
||||
need net
|
||||
}
|
||||
|
||||
start_pre() {
|
||||
checkpath --directory "${MCOLLECTIVE_PID_DIR}"
|
||||
}
|
@ -1,14 +0,0 @@
|
||||
[Unit]
|
||||
Description=The Marionette Collective
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=forking
|
||||
StandardOutput=syslog
|
||||
StandardError=syslog
|
||||
ExecStart=/usr/sbin/mcollectived --config=/etc/puppetlabs/mcollective/server.cfg --pidfile=/var/run/puppetlabs/mcollective.pid --daemonize
|
||||
ExecReload=/bin/kill -USR1 $MAINPID
|
||||
PIDFile=/var/run/puppetlabs/mcollective.pid
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Binary file not shown.
@ -0,0 +1,78 @@
|
||||
https://bugs.gentoo.org/661328
|
||||
|
||||
--- clamav-0.101.2/m4/reorganization/libs/xml.m4
|
||||
+++ clamav-0.101.2/m4/reorganization/libs/xml.m4
|
||||
@@ -4,55 +4,19 @@
|
||||
[AS_HELP_STRING([--disable-xml], [do not include DMG and XAR support])],
|
||||
want_xml=$enableval, want_xml="auto")
|
||||
|
||||
-XML_HOME=""
|
||||
-if test "X$want_xml" != "Xno"; then
|
||||
- AC_MSG_CHECKING([for libxml2 installation])
|
||||
- AC_ARG_WITH([xml],
|
||||
- AS_HELP_STRING([--with-xml@<:@=DIR@:>@], [path to directory containing libxml2 library
|
||||
- @<:@default=/usr/local or /usr if not found in /usr/local@:>@]),
|
||||
- [with_xml_val=$withval]
|
||||
- )
|
||||
-fi
|
||||
-
|
||||
-AS_IF([test "x$with_xml_val" = "xno"], [XML_HOME=""],
|
||||
- [test "x$with_xml_val" = "xyes"], [XML_HOME="/usr/local"],
|
||||
- [XML_HOME="$with_xml_val"])
|
||||
-
|
||||
-AS_IF([test "x$XML_HOME" != "x"], [
|
||||
- AS_IF([test ! -x "$XML_HOME/bin/xml2-config"], [XML_HOME=""])
|
||||
- ])
|
||||
-
|
||||
-AS_IF([test "x$XML_HOME" = "x" -a "x$with_xml_val" = "xyes"], [
|
||||
- AS_IF([test -x "/usr/bin/xml2-config"], [XML_HOME="/usr"])
|
||||
- ])
|
||||
-
|
||||
-if test "x$XML_HOME" != "x"; then
|
||||
- AC_MSG_RESULT([$XML_HOME])
|
||||
-else
|
||||
- AC_MSG_RESULT([not found])
|
||||
-fi
|
||||
-
|
||||
-found_xml="no"
|
||||
-XMLCONF_VERSION=""
|
||||
-XML_CPPFLAGS=""
|
||||
-XML_LIBS=""
|
||||
-if test "x$XML_HOME" != "x"; then
|
||||
- AC_MSG_CHECKING([xml2-config version])
|
||||
- XMLCONF_VERSION="`$XML_HOME/bin/xml2-config --version`"
|
||||
- if test "x%XMLCONF_VERSION" != "x"; then
|
||||
- AC_MSG_RESULT([$XMLCONF_VERSION])
|
||||
- found_xml="yes"
|
||||
- XML_CPPFLAGS="`$XML_HOME/bin/xml2-config --cflags`"
|
||||
- XML_LIBS="`$XML_HOME/bin/xml2-config --libs`"
|
||||
- AS_ECHO("$XML_CPPFLAGS")
|
||||
- AS_ECHO("$XML_LIBS")
|
||||
- else
|
||||
- AC_MSG_ERROR([xml2-config failed])
|
||||
- fi
|
||||
-fi
|
||||
+PKG_CHECK_MODULES([XML], [libxml-2.0],
|
||||
+ [found_xml=yes],
|
||||
+ [
|
||||
+ found_xml=no
|
||||
+ AS_IF([test "x$want_xml" = xyes],
|
||||
+ [AC_MSG_ERROR([--enable-xml set but cannot find libxml2])]
|
||||
+ )
|
||||
+ ]
|
||||
+)
|
||||
|
||||
working_xml="no"
|
||||
if test "X$found_xml" != "Xno"; then
|
||||
+ XML_HOME=$(${PKG_CONFIG} --variable prefix libxml-2.0)
|
||||
AC_MSG_CHECKING([for xmlreader.h in $XML_HOME])
|
||||
|
||||
if test ! -f "$XML_HOME/include/libxml2/libxml/xmlreader.h"; then
|
||||
@@ -61,6 +25,7 @@
|
||||
AC_MSG_RESULT([found])
|
||||
save_LIBS="$LIBS"
|
||||
save_CPPFLAGS="$CPPFLAGS"
|
||||
+ XML_CPPFLAGS="$XML_CFLAGS"
|
||||
CPPFLAGS="$CPPFLAGS $XML_CPPFLAGS"
|
||||
save_LDFLAGS="$LDFLAGS"
|
||||
LDFLAGS="$LDFLAGS $XML_LIBS"
|
@ -0,0 +1,31 @@
|
||||
https://bugs.gentoo.org/670729
|
||||
|
||||
--- a/m4/reorganization/clamdtop.m4
|
||||
+++ b/m4/reorganization/clamdtop.m4
|
||||
@@ -4,12 +4,26 @@
|
||||
|
||||
if test "$enable_clamdtop" != "no"; then
|
||||
|
||||
+PKG_CHECK_MODULES([CURSES], [ncursesw],
|
||||
+ [CURSES_INCLUDE="<ncurses.h>";
|
||||
+ HAVE_LIBNCURSES=yes],
|
||||
+ HAVE_LIBNCURSES=no])
|
||||
+
|
||||
+if test "X$HAVE_LIBNCURSES" != "Xyes"; then
|
||||
+PKG_CHECK_MODULES([CURSES], [ncurses],
|
||||
+ [CURSES_INCLUDE="<ncurses.h>";
|
||||
+ HAVE_LIBNCURSES=yes],
|
||||
+ HAVE_LIBNCURSES=no])
|
||||
+fi
|
||||
+
|
||||
+if test "X$HAVE_LIBNCURSES" != "Xyes"; then
|
||||
AC_LIB_FIND([ncurses], [ncurses/ncurses.h],
|
||||
AC_LANG_PROGRAM([#include <ncurses/ncurses.h>],
|
||||
[initscr(); KEY_RESIZE;]),
|
||||
[CURSES_CPPFLAGS="$INCNCURSES"; CURSES_LIBS="$LTLIBNCURSES";
|
||||
CURSES_INCLUDE="<ncurses/ncurses.h>"],
|
||||
[])
|
||||
+fi
|
||||
|
||||
if test "X$HAVE_LIBNCURSES" != "Xyes"; then
|
||||
HAVE_LIBNCURSES=
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,3 +1 @@
|
||||
DIST vile-9.8r.tgz 2322132 BLAKE2B ec477afbf927b527a484dd6ec2cf596a3f97ee1a523e7254aaaf88b98c1b353c82358a0e80408bcbe270ec6eb7b958fb8e9d517801705cf8bbcb4e58bea94026 SHA512 4f610c8c8f491d8d630d042166cbbdc12b89513d40d14dd70526d6cb5d7ebf603a99b19ce2fc42f7143d674e6d5155fcd305da297e03e46caa862ff40e2bbdd4
|
||||
DIST vile-9.8s.tgz 2328441 BLAKE2B 35b5cbec671347eb81503b70a2061395e3c8c904cd304acc83feda2baed71ede7936143ea554bb3bba0cda8056b1a6d76c5ee6473b244a8a05d113a8e613ead0 SHA512 06bfa64e5908aa31351068c5509e6fcc98bde202b814aa6abe5c449f841378c897df1fdbb8b20bdb5e71578238e1e9d11dac08e66159317276a01a9ac96ae9ab
|
||||
DIST vile-9.8t.tgz 2352119 BLAKE2B fc1c75eba09e8be99945ba0d178fd150576d8108f906afb20dba265adaee9e5bea4869415d3ebceabf0b6b56c147add79e9c7e4fe34d7f4744930c3728e4a4a4 SHA512 4be4e37c7231395cae9236796073c2c3e428f1945283785a931c5d4cce94e0f970efa6634b0f9053679a00f4b4577704ea38ded2129e444b26ee9935a1c3d229
|
||||
|
@ -1,42 +0,0 @@
|
||||
# Copyright 1999-2017 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
|
||||
DESCRIPTION="VI Like Emacs -- yet another full-featured vi clone"
|
||||
HOMEPAGE="https://invisible-island.net/vile/"
|
||||
SRC_URI="ftp://invisible-island.net/vile/current/${P}.tgz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="alpha amd64 ia64 ppc sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos"
|
||||
IUSE="perl"
|
||||
|
||||
RDEPEND=">=sys-libs/ncurses-5.2:0=
|
||||
perl? ( dev-lang/perl )"
|
||||
DEPEND="${RDEPEND}
|
||||
sys-devel/flex
|
||||
app-eselect/eselect-vi"
|
||||
|
||||
src_configure() {
|
||||
econf \
|
||||
--with-ncurses \
|
||||
$(use_with perl )
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" INSTALL_OPT_S="" install
|
||||
dodoc CHANGES* README doc/*.doc
|
||||
docinto html
|
||||
dodoc doc/*.html
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
einfo "Updating ${EPREFIX}/usr/bin/vi symlink"
|
||||
eselect vi update --if-unset
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
einfo "Updating ${EPREFIX}/usr/bin/vi symlink"
|
||||
eselect vi update --if-unset
|
||||
}
|
@ -1,42 +0,0 @@
|
||||
# Copyright 1999-2017 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
|
||||
DESCRIPTION="VI Like Emacs -- yet another full-featured vi clone"
|
||||
HOMEPAGE="https://invisible-island.net/vile/"
|
||||
SRC_URI="ftp://invisible-island.net/vile/current/${P}.tgz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos"
|
||||
IUSE="perl"
|
||||
|
||||
RDEPEND=">=sys-libs/ncurses-5.2:0=
|
||||
perl? ( dev-lang/perl )"
|
||||
DEPEND="${RDEPEND}
|
||||
sys-devel/flex
|
||||
app-eselect/eselect-vi"
|
||||
|
||||
src_configure() {
|
||||
econf \
|
||||
--with-ncurses \
|
||||
$(use_with perl )
|
||||
}
|
||||
|
||||
src_install() {
|
||||
emake DESTDIR="${D}" INSTALL_OPT_S="" install
|
||||
dodoc CHANGES* README doc/*.doc
|
||||
docinto html
|
||||
dodoc doc/*.html
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
einfo "Updating ${EPREFIX}/usr/bin/vi symlink"
|
||||
eselect vi update --if-unset
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
einfo "Updating ${EPREFIX}/usr/bin/vi symlink"
|
||||
eselect vi update --if-unset
|
||||
}
|
@ -1,3 +1 @@
|
||||
DIST vile-9.8r.tgz 2322132 BLAKE2B ec477afbf927b527a484dd6ec2cf596a3f97ee1a523e7254aaaf88b98c1b353c82358a0e80408bcbe270ec6eb7b958fb8e9d517801705cf8bbcb4e58bea94026 SHA512 4f610c8c8f491d8d630d042166cbbdc12b89513d40d14dd70526d6cb5d7ebf603a99b19ce2fc42f7143d674e6d5155fcd305da297e03e46caa862ff40e2bbdd4
|
||||
DIST vile-9.8s.tgz 2328441 BLAKE2B 35b5cbec671347eb81503b70a2061395e3c8c904cd304acc83feda2baed71ede7936143ea554bb3bba0cda8056b1a6d76c5ee6473b244a8a05d113a8e613ead0 SHA512 06bfa64e5908aa31351068c5509e6fcc98bde202b814aa6abe5c449f841378c897df1fdbb8b20bdb5e71578238e1e9d11dac08e66159317276a01a9ac96ae9ab
|
||||
DIST vile-9.8t.tgz 2352119 BLAKE2B fc1c75eba09e8be99945ba0d178fd150576d8108f906afb20dba265adaee9e5bea4869415d3ebceabf0b6b56c147add79e9c7e4fe34d7f4744930c3728e4a4a4 SHA512 4be4e37c7231395cae9236796073c2c3e428f1945283785a931c5d4cce94e0f970efa6634b0f9053679a00f4b4577704ea38ded2129e444b26ee9935a1c3d229
|
||||
|
@ -1,42 +0,0 @@
|
||||
# Copyright 1999-2018 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
|
||||
MY_P="${PN/x/}-${PV}"
|
||||
DESCRIPTION="VI Like Emacs -- yet another full-featured vi clone"
|
||||
HOMEPAGE="https://invisible-island.net/vile/"
|
||||
SRC_URI="ftp://invisible-island.net/vile/current/${MY_P}.tgz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="alpha amd64 ia64 ppc sparc x86"
|
||||
IUSE="perl"
|
||||
|
||||
RDEPEND="perl? ( dev-lang/perl )
|
||||
=app-editors/vile-${PV}
|
||||
>=x11-libs/libX11-1.0.0
|
||||
>=x11-libs/libXt-1.0.0
|
||||
>=x11-libs/libICE-1.0.0
|
||||
>=x11-libs/libSM-1.0.0
|
||||
>=x11-libs/libXaw-1.0.1
|
||||
>=x11-libs/libXpm-3.5.4.2"
|
||||
DEPEND="${RDEPEND}
|
||||
x11-base/xorg-proto
|
||||
sys-devel/flex"
|
||||
|
||||
S=${WORKDIR}/${MY_P}
|
||||
|
||||
src_configure() {
|
||||
econf \
|
||||
--with-ncurses \
|
||||
--with-x \
|
||||
$(use_with perl)
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dobin xvile
|
||||
dodoc CHANGES* README doc/*.doc
|
||||
docinto html
|
||||
dodoc doc/*.html
|
||||
}
|
@ -1,42 +0,0 @@
|
||||
# Copyright 1999-2018 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=6
|
||||
|
||||
MY_P="${PN/x/}-${PV}"
|
||||
DESCRIPTION="VI Like Emacs -- yet another full-featured vi clone"
|
||||
HOMEPAGE="https://invisible-island.net/vile/"
|
||||
SRC_URI="ftp://invisible-island.net/vile/current/${MY_P}.tgz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~sparc ~x86"
|
||||
IUSE="perl"
|
||||
|
||||
RDEPEND="perl? ( dev-lang/perl )
|
||||
=app-editors/vile-${PV}
|
||||
>=x11-libs/libX11-1.0.0
|
||||
>=x11-libs/libXt-1.0.0
|
||||
>=x11-libs/libICE-1.0.0
|
||||
>=x11-libs/libSM-1.0.0
|
||||
>=x11-libs/libXaw-1.0.1
|
||||
>=x11-libs/libXpm-3.5.4.2"
|
||||
DEPEND="${RDEPEND}
|
||||
x11-base/xorg-proto
|
||||
sys-devel/flex"
|
||||
|
||||
S=${WORKDIR}/${MY_P}
|
||||
|
||||
src_configure() {
|
||||
econf \
|
||||
--with-ncurses \
|
||||
--with-x \
|
||||
$(use_with perl)
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dobin xvile
|
||||
dodoc CHANGES* README doc/*.doc
|
||||
docinto html
|
||||
dodoc doc/*.html
|
||||
}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,14 +0,0 @@
|
||||
# -log.format value
|
||||
# If set use a syslog logger or JSON logging. Example: logger:syslog?appname=bob&local=7 or logger:stdout?json=true. Defaults to stderr.
|
||||
# -log.level value
|
||||
# Only log messages with the given severity or above. Valid levels: [debug, info, warn, error, fatal].
|
||||
# -persistence.file string
|
||||
# File to persist metrics. If empty, metrics are only kept in memory.
|
||||
# -persistence.interval duration
|
||||
# The minimum interval at which to write out the persistence file. (default 5m0s)
|
||||
# -web.listen-address string
|
||||
# Address to listen on for the web interface, API, and telemetry. (default ":9091")
|
||||
# -web.telemetry-path string
|
||||
# Path under which to expose metrics. (default "/metrics")
|
||||
|
||||
#command_args="-web.listen-address localhost:9091 -persistence.file=/var/lib/${RC_SVCNAME}/persistence.gob"
|
@ -1,19 +0,0 @@
|
||||
#!/sbin/openrc-run
|
||||
# Copyright 2018 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
description="Prometheus push acceptor for ephemeral and batch jobs"
|
||||
pidfile=${pidfile:-"/run/${RC_SVCNAME}.pid"}
|
||||
user=${user:-${RC_SVCNAME}}
|
||||
group=${group:-${RC_SVCNAME}}
|
||||
|
||||
command="/usr/bin/pushgateway"
|
||||
command_args="${command_args:--web.listen-address localhost:9091 -persistence.file=/var/lib/${RC_SVCNAME}/persistence.gob}"
|
||||
command_background="true"
|
||||
start_stop_daemon_args="--user ${user} --group ${group} \
|
||||
--stdout /var/log/${RC_SVCNAME}/${RC_SVCNAME}.log \
|
||||
--stderr /var/log/${RC_SVCNAME}/${RC_SVCNAME}.log"
|
||||
|
||||
depend() {
|
||||
need net
|
||||
}
|
@ -1,16 +0,0 @@
|
||||
[Unit]
|
||||
Description=Prometheus exporter for ephemereal jobs
|
||||
Documentation=https://prometheus.io/docs/instrumenting/pushing/
|
||||
After=network-online.target
|
||||
|
||||
[Service]
|
||||
User=pushgateway
|
||||
Restart=on-failure
|
||||
Environment=PUSHGATEWAY_ARGS="-web.listen-address localhost:9091 --persistence.file=/var/lib/pushgateway/persistence.gob"
|
||||
ExecStart=/usr/bin/pushgateway $PUSHGATEWAY_ARGS
|
||||
ExecReload=/bin/kill -HUP $MAINPID
|
||||
TimeoutStopSec=20s
|
||||
SendSIGKILL=no
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,10 +1,10 @@
|
||||
DIST mariadb-10.1.38.tar.gz 63535685 BLAKE2B c179ea2f60287c2bc1c0d1c47ae989ac2653a24063e8344cef2f3062fc6798e18b969e8f9aa8287104ce2518e6c644cb8d3a4650b5a0bc5dfde973e76e618955 SHA512 184582f3a902a989ba3d9c4d21288c014c8b469adbbb4cbabc621c5006022cef29baed8c1140ed4476b124da83b76dfa414295ed0c3374be826e75aca953a77b
|
||||
DIST mariadb-10.1.40.tar.gz 63573615 BLAKE2B a57f89c3a9cbfdfc7ff85ec6d7f4231f29a8c2b5df8a86e069e9c077aafc16f60655eab2765a622ec2675fbec4739a477613a42c68f897785443d8366fb5d1a3 SHA512 6b946189c69905f1a23a96d34720f1592353e0095455bf452bba31d53c90143d088f0fd997cac3da0a779840bb6ae6cc30b45144cba474463a8e3a6978a8a8f3
|
||||
DIST mariadb-10.1.41.tar.gz 63615288 BLAKE2B 91ebc6d24c80ad9651c42a2f4553ce3ec3b7beb17493f90ebbf02ab23f425b0f729766cf2c81202832dfbca0a5e285f94a4daf794fcf4d445730fbe4fcc88871 SHA512 4a18b06fda49c5c3627b4e7cd32fb460e73762273a0c3d09098e34c71e63caa8fad03cdd92ae4a391cdfdb3719934688f0bdf312fa4af7ac3b9e5f5d90f404be
|
||||
DIST mariadb-10.2.22.tar.gz 71907765 BLAKE2B e7781a9e1bb0becca543ebb0b9e03912fbafa9de45bbd5c7232f92d29b934148dd124ad462bf8aa5aec2e4ee0bf75a03fae5e5fe97a77e1d93095052a577c14b SHA512 cd61d0c2d528b23b975e6ea142560d9b9ebff7ecda6fa9b3659b25b3406e8cc925918f4c3bb0e200ddb8d0520bcaa4d4f70d245b4731896f9ba2f1bdf0a817b2
|
||||
DIST mariadb-10.2.25.tar.gz 71997847 BLAKE2B 03435106c5b2316e8f66028fa05b85042f35ebe84fa245d214622252048befa414d1630c4edead9ccb07f88f8c8085bb4c2e1361e08f58829b0a751326503cf1 SHA512 0d0f5e188f81715edb02ee91cc6c15ad0f674da67bc8d291a2bad9454190e9423f85ee1b69f88d3b429bc56c58a899f889f04862a4bddf2afdac744318c9c723
|
||||
DIST mariadb-10.3.16.tar.gz 70862041 BLAKE2B 522c3185e9928cfb669065fd8b1b8538f53a63d0413ae32e317a1ee6c572c6af458ba15e904e19b2cdb6e83b870360f56f4368eecc2774caab8ac85bc000f609 SHA512 b22a8c8fa0265f88962432ade71c3f0ec554f7d38042def832cfcb50f3aa1dd77a715c76706ffeae679b95438529b06e98b73b7e219f9c645980802027ec022f
|
||||
DIST mariadb-10.4.6.tar.gz 76710358 BLAKE2B 7fcaced6cbcc027ad2a1f1e681af30d0f4ec45f432bad4c6c7d9625a8d20978e4c49cbec3016be873ecda16cb113a8f3b6a8ec8995772255c23e908cc5d11178 SHA512 b04c47f72de2473d7b5edd04b4785a1d7179bb1f429f30ba53ae6cfbbb413200d9803eff1072949b2e81fd7d2164ea34c68620d621d4181b913daa2293ae140c
|
||||
DIST mariadb-5.5.64.tar.gz 45953561 BLAKE2B d6efe53e520b829ec337a00efadd7d813afd5e3ee6ac5a298773c7cd1b724d01856979317fe2bcf814af3bdabdbd7c6c3d2e27a60b4cdf6032b1dfd64e54d84d SHA512 3e93044eb30d2ce50fefce503f16f4b542fd647ff4367675147ebe1b1f576b4fbad5c0bb25670136d0758d2b8b0c571119244c87d66565bb9b3471811f5dc6b8
|
||||
DIST mariadb-10.2.26.tar.gz 73037655 BLAKE2B 54fd27959960736bffe0eeacc913b9aed0407d1be7a60d3035a1b84cbe8066aa1551c1c82a1b90b824debf85faaa9d11e3de29634a0108bc04bc17ca5c2a9d7c SHA512 1eaac1c1dda1017b64249d39d872729d3140d81653240c54f688f64440b1775e5f3a7c5a8486075fa1799411dfb0c2c09b7c1dbb46d95675572d90127048c124
|
||||
DIST mariadb-10.3.17.tar.gz 71894997 BLAKE2B 8e04302f67a99c28751f9970b7e8dfc5ada0583fdabc416e0469e23fa93d22dae8b79e762ef14ca65957e22ec310a290b15d33746f6f2e7287f922803e6a6826 SHA512 6fba995d8c284a12f19ee5635f5d69d8fa89fc314f512cd1764b2c4593933baf71a472ddce630463debd3bfbafa1cf5afee3f40d3c4062242f58cea16259561e
|
||||
DIST mariadb-10.4.7.tar.gz 78155161 BLAKE2B b2c92093438b3574e494bda2180f4a2b5cbe10bac1c46acc45b5303fb4c2a1ca54f3ea88d138ab9cbb492460171dde86f3c21e5873d964b15c6c064e2e6eb47f SHA512 cb8b5adaef1970b9c8f04db08c18660f8b3df87f699aa93c1bee9497b887ddf50fcf3a2aebbe21a5fc9dfcbd118d0192d7421512522d98eaf30a014822c2f7ce
|
||||
DIST mariadb-5.5.65.tar.gz 45957577 BLAKE2B 9ed27349d008d2001ed4059370505064918ef3586f89157f5f28892bceabd3073b7070f4054c0a700f1504dde3a4077e274111d5b8cb3713bc5db0910b752628 SHA512 5dbaa2ba7a829a0d5ae6ab8394c31a58753cd93da2637cd83d1e055e78b0796d63214418ddc91a65cefdd791aad4f01b0743aa8c7c40ecbb404cb81fd0138443
|
||||
DIST mysql-extras-20180809-1700Z.tar.bz2 322999 BLAKE2B 8b5feb32085dc35b2f68dae985b2d266c4eaa0e956b490050a2df04bbff99bf8623b67e75af9326d84e3ad625c4d86b0d21d23c9a96df5a0c9cd5ed730958970 SHA512 fbd7af9284bbf09d55f128361e7cc52d94f24ac491aac800cd6d61f2e444aeca66a4d5e6ae94c2fb4044e00cec9b232bae9a76a229f87f19d90b7aecf70792ec
|
||||
DIST mysql-extras-20190305-2052Z.tar.bz2 331304 BLAKE2B 1d2c35a961159fa5ce9ee6699fce943f5a5b5cf60b11c9bb4bcccee4943f4508a9eb6d01050c642353ac592ce1a6b421abf2a1bebc706c44c4c8a36aa698ec43 SHA512 ae63403320e010acbb92f8aec6da8ed4f267cef0bad37147d594076fd94571de7f98bfc2afbe94af5d716f58d57696fd958b1e13e20e87052f252ed4a188cd3c
|
||||
DIST mysql-extras-20190521-1824Z.tar.bz2 331441 BLAKE2B d45fd1be113d3dc7f10a3ff89cfda3d59974d88366a143b473a68493c93e244d45a836b4e13dc9e88bbd8b734507858d6b4b1251325c464f48572fe158d7edf7 SHA512 8b91f534acbd07e3a2f66e28b1301f960ed9192c2bc1edbc07741b6200ad0767fdc004faebce2a60fa67a8f3aee186c98ee2f56278d4e8773e5df77f609ef837
|
||||
DIST mysql-extras-20190731-2258Z.tar.bz2 332111 BLAKE2B cc144c9af852bfdd4149b96bdc22f8afb2d0aa92f95ebd272a244f0fb7743dc03f9244871d5c195260bac5d9ed20583093257ee2c95a5a4d0a4dae488d781adf SHA512 d4428a1128cd5aef62c463b659992b110090b1602cdcb6b8d922d570c6b946fde325bfcf5a9a955a8dcc61f3ccd3d612d8517ebf63e316f98ca9ff2cd8a807aa
|
||||
|
@ -0,0 +1,799 @@
|
||||
# Copyright 1999-2019 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI="6"
|
||||
MY_EXTRAS_VER="20190604-1109Z"
|
||||
|
||||
CMAKE_MAKEFILE_GENERATOR=emake
|
||||
|
||||
# Keeping eutils in EAPI=6 for emktemp in pkg_config
|
||||
|
||||
inherit eutils flag-o-matic prefix toolchain-funcs \
|
||||
user cmake-utils multilib-build
|
||||
|
||||
SRC_URI="http://cdn.mysql.com/Downloads/MySQL-5.6/${P}.tar.gz
|
||||
https://cdn.mysql.com/archives/mysql-5.6/${P}.tar.gz
|
||||
http://downloads.mysql.com/archives/MySQL-5.6/${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://www.mysql.com/"
|
||||
DESCRIPTION="A fast, multi-threaded, multi-user SQL database server"
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0/18"
|
||||
IUSE="client-libs cracklib debug jemalloc latin1 libressl numa +perl profiling selinux
|
||||
+server static static-libs systemtap tcmalloc test yassl"
|
||||
|
||||
# Tests always fail when libressl is enabled due to hard-coded ciphers in the tests
|
||||
RESTRICT="libressl? ( test )"
|
||||
|
||||
REQUIRED_USE="?? ( tcmalloc jemalloc ) static? ( yassl )"
|
||||
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~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
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/mysql-extras.git"
|
||||
EGIT_CHECKOUT_DIR="${WORKDIR}/mysql-extras"
|
||||
EGIT_CLONE_TYPE=shallow
|
||||
MY_PATCH_DIR="${WORKDIR}/mysql-extras"
|
||||
else
|
||||
MY_PATCH_DIR="${WORKDIR}/mysql-extras-${MY_EXTRAS_VER}"
|
||||
fi
|
||||
|
||||
PATCHES=(
|
||||
"${MY_PATCH_DIR}"/01050_all_mysql_config_cleanup-5.6.patch
|
||||
"${MY_PATCH_DIR}"/02040_all_embedded-library-shared-5.5.10.patch
|
||||
"${MY_PATCH_DIR}"/20006_all_cmake_elib-mysql-5.6.35.patch
|
||||
"${MY_PATCH_DIR}"/20007_all_cmake-debug-werror-5.6.22.patch
|
||||
"${MY_PATCH_DIR}"/20008_all_mysql-tzinfo-symlink-5.6.37.patch
|
||||
"${MY_PATCH_DIR}"/20009_all_mysql_myodbc_symbol_fix-5.6.patch
|
||||
"${MY_PATCH_DIR}"/20018_all_mysql-5.6.25-without-clientlibs-tools.patch
|
||||
"${MY_PATCH_DIR}"/20027_all_mysql-5.5-perl5.26-includes.patch
|
||||
"${MY_PATCH_DIR}"/20031_all_mysql-5.6-fix-monitor.test.patch
|
||||
"${MY_PATCH_DIR}"/20036_all_mysql-5.6-fix-rpl_semi_sync_shutdown_hang.test.patch
|
||||
"${MY_PATCH_DIR}"/20018_all_mysql-5.6.44-fix-libressl-support.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=
|
||||
)
|
||||
net-misc/curl
|
||||
>=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.0.2*:0= )
|
||||
libressl? ( =dev-libs/libressl-2.6.5*:0= )
|
||||
)
|
||||
>=sys-libs/zlib-1.2.3:0=
|
||||
sys-libs/ncurses:0=
|
||||
server? (
|
||||
numa? ( sys-process/numactl )
|
||||
)
|
||||
!client-libs? ( dev-db/mysql-connector-c[${MULTILIB_USEDEP},static-libs?] )
|
||||
"
|
||||
DEPEND="virtual/yacc
|
||||
static? ( sys-libs/ncurses[static-libs] )
|
||||
test? ( dev-perl/JSON )
|
||||
|| ( >=sys-devel/gcc-3.4.6 >=sys-devel/gcc-apple-4.0 )
|
||||
${COMMON_DEPEND}"
|
||||
RDEPEND="selinux? ( sec-policy/selinux-mysql )
|
||||
client-libs? ( !dev-db/mariadb-connector-c[mysqlcompat] !dev-db/mysql-connector-c )
|
||||
!dev-db/mariadb !dev-db/mariadb-galera !dev-db/percona-server !dev-db/mysql-cluster
|
||||
server? ( !prefix? ( dev-db/mysql-init-scripts ) )
|
||||
${COMMON_DEPEND}
|
||||
"
|
||||
# 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)
|
||||
# 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
|
||||
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() {
|
||||
# Here we need to see if the implementation switched client libraries
|
||||
# We check if this is a new instance of the package and a client library already exists
|
||||
local SHOW_ABI_MESSAGE libpath
|
||||
if use client-libs && [[ -z ${REPLACING_VERSIONS} && -e "${EROOT%/}/usr/$(get_libdir)/libmysqlclient.so" ]] ; then
|
||||
libpath=$(readlink "${EROOT%/}/usr/$(get_libdir)/libmysqlclient.so")
|
||||
elog "Due to ABI changes when switching between different client libraries,"
|
||||
elog "revdep-rebuild must find and rebuild all packages linking to libmysqlclient."
|
||||
elog "Please run: revdep-rebuild --library ${libpath}"
|
||||
ewarn "Failure to run revdep-rebuild may cause issues with other programs or libraries"
|
||||
fi
|
||||
}
|
||||
|
||||
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 [[ -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
|
||||
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 jemalloc ; then
|
||||
echo "TARGET_LINK_LIBRARIES(mysqld jemalloc)" >> "${S}/sql/CMakeLists.txt" || die
|
||||
fi
|
||||
if use tcmalloc; then
|
||||
echo "TARGET_LINK_LIBRARIES(mysqld tcmalloc)" >> "${S}/sql/CMakeLists.txt" || die
|
||||
fi
|
||||
# Remove the centos and rhel selinux policies to support mysqld_safe under SELinux
|
||||
if [[ -d "${S}/support-files/SELinux" ]] ; then
|
||||
echo > "${S}/support-files/SELinux/CMakeLists.txt" || die
|
||||
fi
|
||||
|
||||
if use libressl ; then
|
||||
sed -i 's/OPENSSL_MAJOR_VERSION STREQUAL "1"/OPENSSL_MAJOR_VERSION STREQUAL "2"/' \
|
||||
"${S}/cmake/ssl.cmake" || die
|
||||
fi
|
||||
|
||||
sed -i 's~ADD_SUBDIRECTORY(storage/ndb)~~' CMakeLists.txt || die
|
||||
|
||||
local plugin
|
||||
local server_plugins=( semisync )
|
||||
local test_plugins=( audit_null 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
|
||||
|
||||
# Don't build example
|
||||
_disable_engine example
|
||||
_disable_engine ndb
|
||||
_disable_plugin innodb_memcached
|
||||
|
||||
cmake-utils_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"
|
||||
-DMYSQL_DATADIR="${EPREFIX}/var/lib/mysql"
|
||||
-DSYSCONFDIR="${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/mysql
|
||||
-DINSTALL_PLUGINDIR=$(get_libdir)/mysql/plugin
|
||||
-DINSTALL_SCRIPTDIR=share/mysql/scripts
|
||||
-DINSTALL_MYSQLDATADIR="${EPREFIX}/var/lib/mysql"
|
||||
-DINSTALL_SBINDIR=sbin
|
||||
-DINSTALL_SUPPORTFILESDIR="${EPREFIX}/usr/share/mysql"
|
||||
-DCOMPILATION_COMMENT="Gentoo Linux ${PF}"
|
||||
-DWITH_UNIT_TESTS=$(usex test ON OFF)
|
||||
### TODO: make this system but issues with UTF-8 prevent it
|
||||
-DWITH_EDITLINE=bundled
|
||||
-DWITH_ZLIB=system
|
||||
-DWITH_LIBWRAP=0
|
||||
-DENABLED_LOCAL_INFILE=1
|
||||
-DMYSQL_UNIX_ADDR="${EPREFIX}/var/run/mysqld/mysqld.sock"
|
||||
-DWITH_DEFAULT_COMPILER_OPTIONS=0
|
||||
-DWITH_DEFAULT_FEATURE_SET=0
|
||||
# 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)
|
||||
-DWITH_LIBEVENT=NO
|
||||
-DWITHOUT_CLIENTLIBS=YES
|
||||
-DENABLE_DTRACE=$(usex systemtap)
|
||||
-DWITH_SSL=$(usex yassl bundled system)
|
||||
-DINSTALL_MYSQLTESTDIR=$(usex test 'share/mysql/mysql-test' '')
|
||||
-DWITHOUT_VALIDATE_PASSWORD=1
|
||||
)
|
||||
|
||||
if use server ; then
|
||||
|
||||
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+=(
|
||||
-DWITH_NUMA=$(usex numa ON OFF)
|
||||
-DEXTRA_CHARSETS=all
|
||||
-DDISABLE_SHARED=$(usex static YES NO)
|
||||
-DWITH_DEBUG=$(usex debug)
|
||||
-DWITH_EMBEDDED_SERVER=OFF
|
||||
)
|
||||
|
||||
if use profiling ; then
|
||||
# Setting to OFF doesn't work: Once set, profiling options will be added
|
||||
# to `mysqld --help` output via sql/sys_vars.cc causing
|
||||
# "main.mysqld--help-notwin" test to fail
|
||||
mycmakeargs+=( -DENABLED_PROFILING=ON )
|
||||
fi
|
||||
|
||||
if use static; then
|
||||
mycmakeargs+=( -DWITH_PIC=1 )
|
||||
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
|
||||
-DWITH_INNODB_MEMCACHED=0
|
||||
)
|
||||
|
||||
else
|
||||
mycmakeargs+=(
|
||||
-DWITHOUT_SERVER=1
|
||||
-DWITH_EMBEDDED_SERVER=OFF
|
||||
-DEXTRA_CHARSETS=none
|
||||
)
|
||||
fi
|
||||
|
||||
cmake-utils_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
cmake-utils_src_compile
|
||||
}
|
||||
|
||||
src_install() {
|
||||
cmake-utils_src_install
|
||||
|
||||
# Kill old libmysqclient_r symlinks if they exist. Time to fix what depends on them.
|
||||
find "${D}" -name 'libmysqlclient_r.*' -type l -delete || die
|
||||
# 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
|
||||
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='perl server static-libs' \
|
||||
# FEATURES='test userpriv -usersandbox' \
|
||||
# ebuild mysql-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 MySQL 5.6 for now and are believed to be
|
||||
# false positives:
|
||||
#
|
||||
local t
|
||||
|
||||
for t in auth_sec.keyring_udf federated.federated_plugin ; do
|
||||
_disable_test "$t" "False positives in Gentoo"
|
||||
done
|
||||
|
||||
# Bad test definition
|
||||
_disable_test main.mysqldump "Test fails after 2018-12-31 with new warnings"
|
||||
|
||||
# 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/mysql"}
|
||||
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 "${EROOT%/}/$MYSQL_TMPDIR" ]]; then
|
||||
einfo "Creating MySQL tmpdir $MYSQL_TMPDIR"
|
||||
install -d -m 770 -o mysql -g mysql "${EROOT%/}/$MYSQL_TMPDIR"
|
||||
fi
|
||||
if [[ ! -d "${EROOT%/}/$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 http://bugs.mysql.com/bug.php?id=31312
|
||||
use prefix && options="${options} '--defaults-file=${MY_SYSCONFDIR}/my.cnf'"
|
||||
|
||||
local help_tables="${EROOT%/}${MY_SHAREDSTATEDIR}/fill_help_tables.sql"
|
||||
[[ -r "${help_tables}" ]] \
|
||||
&& cp "${help_tables}" "${TMPDIR}/fill_help_tables.sql" \
|
||||
|| touch "${TMPDIR}/fill_help_tables.sql"
|
||||
help_tables="${TMPDIR}/fill_help_tables.sql"
|
||||
|
||||
# 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 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
|
||||
# http://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
|
||||
chown mysql "${sqltmp}" || die
|
||||
|
||||
local cmd=( "${EROOT%/}/usr/share/mysql/scripts/mysql_install_db" )
|
||||
[[ -f "${cmd}" ]] || cmd=( "${EROOT%/}/usr/bin/mysql_install_db" )
|
||||
if [[ -r "${help_tables}" ]] ; then
|
||||
cat "${help_tables}" >> "${sqltmp}"
|
||||
fi
|
||||
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} \
|
||||
$(use prefix || echo --user=mysql) \
|
||||
--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="SET PASSWORD FOR 'root'@'localhost' = PASSWORD('${MYSQL_ROOT_PASSWORD}');"
|
||||
"${EROOT%/}/usr/bin/mysql" \
|
||||
--no-defaults \
|
||||
"--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"
|
||||
}
|
@ -0,0 +1,946 @@
|
||||
# Copyright 1999-2019 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI="6"
|
||||
MY_EXTRAS_VER="20190604-1109Z"
|
||||
|
||||
CMAKE_MAKEFILE_GENERATOR=emake
|
||||
|
||||
# Keeping eutils in EAPI=6 for emktemp in pkg_config
|
||||
|
||||
inherit cmake-utils eutils flag-o-matic linux-info \
|
||||
prefix toolchain-funcs user multilib-minimal
|
||||
|
||||
SRC_URI="https://cdn.mysql.com/Downloads/MySQL-5.7/${PN}-boost-${PV}.tar.gz
|
||||
https://cdn.mysql.com/archives/mysql-5.7/mysql-boost-${PV}.tar.gz
|
||||
http://downloads.mysql.com/archives/MySQL-5.7/${PN}-boost-${PV}.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"
|
||||
fi
|
||||
|
||||
HOMEPAGE="https://www.mysql.com/"
|
||||
DESCRIPTION="A fast, multi-threaded, multi-user SQL database server"
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0/18"
|
||||
IUSE="cjk client-libs cracklib debug experimental jemalloc latin1 libressl numa +perl profiling
|
||||
selinux +server static static-libs systemtap tcmalloc test yassl"
|
||||
|
||||
# Tests always fail when libressl is enabled due to hard-coded ciphers in the tests
|
||||
RESTRICT="libressl? ( test )"
|
||||
|
||||
REQUIRED_USE="?? ( tcmalloc jemalloc ) static? ( yassl )"
|
||||
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~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
|
||||
inherit git-r3
|
||||
EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/mysql-extras.git"
|
||||
EGIT_CHECKOUT_DIR="${WORKDIR}/mysql-extras"
|
||||
EGIT_CLONE_TYPE=shallow
|
||||
MY_PATCH_DIR="${WORKDIR}/mysql-extras"
|
||||
else
|
||||
MY_PATCH_DIR="${WORKDIR}/mysql-extras-${MY_EXTRAS_VER}"
|
||||
fi
|
||||
|
||||
PATCHES=(
|
||||
"${MY_PATCH_DIR}"/20001_all_fix-minimal-build-cmake-mysql-5.7.23.patch
|
||||
"${MY_PATCH_DIR}"/20007_all_cmake-debug-werror-5.7.patch
|
||||
"${MY_PATCH_DIR}"/20009_all_mysql_myodbc_symbol_fix-5.7.10.patch
|
||||
"${MY_PATCH_DIR}"/20018_all_mysql-5.7.21-without-clientlibs-tools.patch
|
||||
"${MY_PATCH_DIR}"/20018_all_mysql-5.7.25-fix-libressl-support.patch
|
||||
"${MY_PATCH_DIR}"/20018_all_mysql-5.7.23-add-missing-gcc-8-fix.patch
|
||||
"${MY_PATCH_DIR}"/20018_all_mysql-5.7.23-fix-grant_user_lock-a-root.patch
|
||||
"${MY_PATCH_DIR}"/20018_all_mysql-5.7.23-round-off-test-values-for-same-output-on-all-architectures.patch
|
||||
"${MY_PATCH_DIR}"/20018_all_mysql-5.7.23-fix-mips-ASM.patch
|
||||
"${MY_PATCH_DIR}"/20018_all_mysql-5.7.25-fix-build-without-server.patch
|
||||
)
|
||||
|
||||
# Be warned, *DEPEND are version-dependant
|
||||
# These are used for both runtime and compiletime
|
||||
# MULTILIB_USEDEP only set for libraries used by the client library
|
||||
COMMON_DEPEND="net-misc/curl:=
|
||||
>=sys-apps/sed-4
|
||||
>=sys-apps/texinfo-4.7-r1
|
||||
sys-libs/ncurses:0=
|
||||
client-libs? ( >=sys-libs/zlib-1.2.3:0=[${MULTILIB_USEDEP},static-libs?] )
|
||||
!client-libs? (
|
||||
dev-db/mysql-connector-c[${MULTILIB_USEDEP},static-libs?]
|
||||
>=sys-libs/zlib-1.2.3:0=
|
||||
)
|
||||
jemalloc? ( dev-libs/jemalloc:0= )
|
||||
kernel_linux? (
|
||||
dev-libs/libaio:0=
|
||||
sys-process/procps:0=
|
||||
)
|
||||
server? (
|
||||
>=app-arch/lz4-0_p131:=
|
||||
cjk? ( app-text/mecab:= )
|
||||
experimental? (
|
||||
dev-libs/libevent:=
|
||||
dev-libs/protobuf:=
|
||||
net-libs/libtirpc:=
|
||||
)
|
||||
numa? ( sys-process/numactl )
|
||||
)
|
||||
systemtap? ( >=dev-util/systemtap-1.3:0= )
|
||||
tcmalloc? ( dev-util/google-perftools:0= )
|
||||
!yassl? (
|
||||
client-libs? (
|
||||
!libressl? ( >=dev-libs/openssl-1.0.0:0=[${MULTILIB_USEDEP},static-libs?] )
|
||||
libressl? ( dev-libs/libressl:0=[${MULTILIB_USEDEP},static-libs?] )
|
||||
)
|
||||
!client-libs? (
|
||||
!libressl? ( >=dev-libs/openssl-1.0.0:0= )
|
||||
libressl? ( dev-libs/libressl:0= )
|
||||
)
|
||||
)
|
||||
"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
|| ( >=sys-devel/gcc-3.4.6 >=sys-devel/gcc-apple-4.0 )
|
||||
dev-libs/protobuf
|
||||
virtual/yacc
|
||||
server? (
|
||||
dev-libs/libevent
|
||||
experimental? ( net-libs/rpcsvc-proto )
|
||||
)
|
||||
static? ( sys-libs/ncurses[static-libs] )
|
||||
test? ( dev-perl/JSON )
|
||||
"
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!dev-db/mariadb !dev-db/mariadb-galera !dev-db/percona-server !dev-db/mysql-cluster
|
||||
client-libs? ( !dev-db/mariadb-connector-c[mysqlcompat] !dev-db/mysql-connector-c dev-libs/protobuf:= )
|
||||
selinux? ( sec-policy/selinux-mysql )
|
||||
server? ( !prefix? ( dev-db/mysql-init-scripts ) )
|
||||
"
|
||||
# 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 )"
|
||||
|
||||
mysql_init_vars() {
|
||||
MY_SHAREDSTATEDIR=${MY_SHAREDSTATEDIR="${EPREFIX%/}/usr/share/mysql"}
|
||||
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_pretend() {
|
||||
if use numa ; then
|
||||
local CONFIG_CHECK="~NUMA"
|
||||
|
||||
local WARNING_NUMA="This package expects NUMA support in kernel which this system does not have at the moment;"
|
||||
WARNING_NUMA+=" Either expect runtime errors, enable NUMA support in kernel or rebuild the package without NUMA support"
|
||||
|
||||
check_extra_config
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
if [[ ${MERGE_TYPE} != binary ]] ; then
|
||||
local GCC_MAJOR_SET=$(gcc-major-version)
|
||||
local GCC_MINOR_SET=$(gcc-minor-version)
|
||||
# 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
|
||||
|
||||
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() {
|
||||
# Here we need to see if the implementation switched client libraries
|
||||
# We check if this is a new instance of the package and a client library already exists
|
||||
local SHOW_ABI_MESSAGE libpath
|
||||
if use client-libs && [[ -z ${REPLACING_VERSIONS} && -e "${EROOT}usr/$(get_libdir)/libmysqlclient.so" ]] ; then
|
||||
libpath=$(readlink "${EROOT}usr/$(get_libdir)/libmysqlclient.so")
|
||||
elog "Due to ABI changes when switching between different client libraries,"
|
||||
elog "revdep-rebuild must find and rebuild all packages linking to libmysqlclient."
|
||||
elog "Please run: revdep-rebuild --library ${libpath}"
|
||||
ewarn "Failure to run revdep-rebuild may cause issues with other programs or libraries"
|
||||
fi
|
||||
}
|
||||
|
||||
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 [[ -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
|
||||
fi
|
||||
|
||||
# Note about configuration change
|
||||
einfo
|
||||
elog "This version of ${PN} reorganizes the configuration from a single my.cnf"
|
||||
elog "to several files in /etc/mysql/mysql.d."
|
||||
elog "Please backup any changes you made to /etc/mysql/my.cnf"
|
||||
elog "and add them as a new file under /etc/mysql/mysql.d with a .cnf extension."
|
||||
elog "You may have as many files as needed and they are read alphabetically."
|
||||
elog "Be sure the options have the appropriate section headers, i.e. [mysqld]."
|
||||
einfo
|
||||
}
|
||||
|
||||
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() {
|
||||
cmake-utils_src_prepare
|
||||
|
||||
if use jemalloc ; then
|
||||
echo "TARGET_LINK_LIBRARIES(mysqld jemalloc)" >> "${S}/sql/CMakeLists.txt" || die
|
||||
fi
|
||||
|
||||
if use tcmalloc ; then
|
||||
echo "TARGET_LINK_LIBRARIES(mysqld tcmalloc)" >> "${S}/sql/CMakeLists.txt" || die
|
||||
fi
|
||||
|
||||
# Remove the centos and rhel selinux policies to support mysqld_safe under SELinux
|
||||
if [[ -d "${S}/support-files/SELinux" ]] ; then
|
||||
echo > "${S}/support-files/SELinux/CMakeLists.txt" || die
|
||||
fi
|
||||
|
||||
# Remove bundled libs so we cannot accidentally use them
|
||||
# We keep extra/lz4 directory because we use extra/lz4/xxhash.c via sql/CMakeLists.txt:394
|
||||
rm -rv \
|
||||
"${S}"/extra/protobuf \
|
||||
"${S}"/extra/libevent \
|
||||
"${S}"/zlib \
|
||||
|| die
|
||||
|
||||
if use libressl ; then
|
||||
sed -i 's/OPENSSL_MAJOR_VERSION STREQUAL "1"/OPENSSL_MAJOR_VERSION STREQUAL "2"/' \
|
||||
"${S}/cmake/ssl.cmake" || die
|
||||
fi
|
||||
|
||||
sed -i 's~ADD_SUBDIRECTORY(storage/ndb)~~' CMakeLists.txt || die
|
||||
}
|
||||
|
||||
src_configure(){
|
||||
# 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
|
||||
|
||||
if use client-libs ; then
|
||||
multilib-minimal_src_configure
|
||||
else
|
||||
multilib_src_configure
|
||||
fi
|
||||
}
|
||||
|
||||
multilib_src_configure() {
|
||||
debug-print-function ${FUNCNAME} "$@"
|
||||
|
||||
if ! multilib_is_native_abi && ! use client-libs ; then
|
||||
return
|
||||
fi
|
||||
|
||||
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"
|
||||
-DMYSQL_DATADIR="${EPREFIX%/}/var/lib/mysql"
|
||||
-DSYSCONFDIR="${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/mysql
|
||||
-DINSTALL_PLUGINDIR=$(get_libdir)/mysql/plugin
|
||||
-DINSTALL_SCRIPTDIR=share/mysql/scripts
|
||||
-DINSTALL_MYSQLDATADIR="${EPREFIX%/}/var/lib/mysql"
|
||||
-DINSTALL_SBINDIR=sbin
|
||||
-DINSTALL_SUPPORTFILESDIR="${EPREFIX%/}/usr/share/mysql"
|
||||
-DCOMPILATION_COMMENT="Gentoo Linux ${PF}"
|
||||
-DWITH_UNIT_TESTS=$(usex test ON OFF)
|
||||
### TODO: make this system but issues with UTF-8 prevent it
|
||||
-DWITH_EDITLINE=bundled
|
||||
-DWITH_ZLIB=system
|
||||
-DWITH_LIBWRAP=0
|
||||
-DENABLED_LOCAL_INFILE=1
|
||||
-DMYSQL_UNIX_ADDR="${EPREFIX%/}/var/run/mysqld/mysqld.sock"
|
||||
-DWITH_DEFAULT_COMPILER_OPTIONS=0
|
||||
-DWITH_DEFAULT_FEATURE_SET=0
|
||||
# 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)
|
||||
-DWITH_CURL=system
|
||||
-DWITH_BOOST="${S}/boost"
|
||||
)
|
||||
if use test ; then
|
||||
mycmakeargs+=( -DINSTALL_MYSQLTESTDIR=share/mysql/mysql-test )
|
||||
else
|
||||
mycmakeargs+=( -DINSTALL_MYSQLTESTDIR='' )
|
||||
fi
|
||||
|
||||
if ! use yassl ; then
|
||||
mycmakeargs+=( -DWITH_SSL=system )
|
||||
else
|
||||
mycmakeargs+=( -DWITH_SSL=bundled )
|
||||
fi
|
||||
|
||||
if ! use client-libs ; then
|
||||
mycmakeargs+=( -DWITHOUT_CLIENTLIBS=YES )
|
||||
fi
|
||||
|
||||
# bfd.h is only used starting with 10.1 and can be controlled by NOT_FOR_DISTRIBUTION
|
||||
# systemtap only works on native ABI, bug 530132
|
||||
if multilib_is_native_abi ; then
|
||||
mycmakeargs+=(
|
||||
-DENABLE_DTRACE=$(usex systemtap)
|
||||
)
|
||||
else
|
||||
mycmakeargs+=(
|
||||
-DWITHOUT_TOOLS=1
|
||||
-DWITH_READLINE=1
|
||||
-DENABLE_DTRACE=0
|
||||
)
|
||||
fi
|
||||
|
||||
if multilib_is_native_abi && use server ; then
|
||||
mycmakeargs+=(
|
||||
-DWITH_LIBEVENT=system
|
||||
-DWITH_LZ4=system
|
||||
-DWITH_PROTOBUF=system
|
||||
-DWITH_MECAB=$(usex cjk system OFF)
|
||||
-DWITH_NUMA=$(usex numa ON OFF)
|
||||
-DWITH_RAPID=$(usex experimental ON OFF)
|
||||
)
|
||||
|
||||
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_DEBUG=$(usex debug)
|
||||
-DWITH_EMBEDDED_SERVER=OFF
|
||||
)
|
||||
|
||||
if use profiling ; then
|
||||
# Setting to OFF doesn't work: Once set, profiling options will be added
|
||||
# to `mysqld --help` output via sql/sys_vars.cc causing
|
||||
# "main.mysqld--help-notwin" test to fail
|
||||
mycmakeargs+=( -DENABLED_PROFILING=ON )
|
||||
fi
|
||||
|
||||
if use static ; then
|
||||
mycmakeargs+=( -DWITH_PIC=1 )
|
||||
fi
|
||||
|
||||
# Storage engines
|
||||
mycmakeargs+=(
|
||||
-DWITH_EXAMPLE_STORAGE_ENGINE=0
|
||||
-DWITH_ARCHIVE_STORAGE_ENGINE=1
|
||||
-DWITH_BLACKHOLE_STORAGE_ENGINE=1
|
||||
-DWITH_CSV_STORAGE_ENGINE=1
|
||||
-DWITH_FEDERATED_STORAGE_ENGINE=1
|
||||
-DWITH_HEAP_STORAGE_ENGINE=1
|
||||
-DWITH_INNOBASE_STORAGE_ENGINE=1
|
||||
-DWITH_INNODB_MEMCACHED=0
|
||||
-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
|
||||
)
|
||||
fi
|
||||
|
||||
cmake-utils_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
if use client-libs ; then
|
||||
multilib-minimal_src_compile
|
||||
else
|
||||
multilib_src_compile
|
||||
fi
|
||||
}
|
||||
|
||||
multilib_src_compile() {
|
||||
cmake-utils_src_compile
|
||||
}
|
||||
|
||||
# Official test instructions:
|
||||
# ulimit -n 16500 && \
|
||||
# USE='latin1 perl server' \
|
||||
# FEATURES='test userpriv -usersandbox' \
|
||||
# ebuild mysql-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 MySQL 5.7 for now and are believed to be
|
||||
# false positives:
|
||||
#
|
||||
local t
|
||||
|
||||
for t in auth_sec.keyring_udf ; do
|
||||
_disable_test "$t" "False positives in Gentoo"
|
||||
done
|
||||
|
||||
# Unstable tests
|
||||
# - main.xa_prepared_binlog_off: https://bugs.mysql.com/bug.php?id=83340
|
||||
# - rpl.rpl_non_direct_stm_mixing_engines: MDEV-14489
|
||||
for t in main.xa_prepared_binlog_off rpl.rpl_non_direct_stm_mixing_engines ; do
|
||||
_disable_test "$t" "Unstable test"
|
||||
done
|
||||
|
||||
if ! use amd64 ; then
|
||||
# fixed in >=mysql-8 via commit 0a417e84
|
||||
_disable_test "gis.gis_bugs_crashes" "Unstable results on non-amd64 architectures due to floating-point operation"
|
||||
fi
|
||||
|
||||
if use numa && use kernel_linux ; then
|
||||
# bug 584880
|
||||
if ! linux_config_exists || ! linux_chkconfig_present NUMA ; then
|
||||
for t in sys_vars.innodb_numa_interleave_basic ; do
|
||||
_disable_test "$t" "Test $t requires system with NUMA support"
|
||||
done
|
||||
fi
|
||||
fi
|
||||
|
||||
if ! use latin1 ; then
|
||||
# The following tests will fail if DEFAULT_CHARSET
|
||||
# isn't set to latin1:
|
||||
for t in \
|
||||
binlog.binlog_mysqlbinlog_filter \
|
||||
binlog.binlog_xa_prepared_disconnect \
|
||||
funcs_1.is_columns_mysql \
|
||||
funcs_1.is_tables_mysql \
|
||||
funcs_1.is_triggers \
|
||||
innodb.innodb_pagesize_max_recordsize \
|
||||
innodb.innodb-system-table-view \
|
||||
innodb.mysqldump_max_recordsize \
|
||||
main.mysql_client_test \
|
||||
main.mysqld--help-notwin \
|
||||
main.type_string \
|
||||
main.information_schema \
|
||||
perfschema.binlog_edge_mix \
|
||||
perfschema.binlog_edge_stmt \
|
||||
rpl.rpl_xa_survive_disconnect \
|
||||
rpl.rpl_xa_survive_disconnect_lsu_off \
|
||||
rpl.rpl_xa_survive_disconnect_table \
|
||||
; do
|
||||
_disable_test "$t" "requires DEFAULT_CHARSET=latin1 but USE=-latin1 is set"
|
||||
done
|
||||
fi
|
||||
|
||||
# Try to increase file limits to increase test coverage
|
||||
if ! ulimit -n 16500 1>/dev/null 2>&1 ; then
|
||||
# Upper limit comes from parts.partition_* tests
|
||||
ewarn "For maximum test coverage please raise open file limit to 16500 (ulimit -n 16500) before calling the package manager."
|
||||
|
||||
if ! ulimit -n 4162 1>/dev/null 2>&1 ; then
|
||||
# Medium limit comes from '[Warning] Buffered warning: Could not increase number of max_open_files to more than 3000 (request: 4162)'
|
||||
ewarn "For medium test coverage please raise open file limit to 4162 (ulimit -n 4162) before calling the package manager."
|
||||
|
||||
if ! ulimit -n 3000 1>/dev/null 2>&1 ; then
|
||||
ewarn "For minimum test coverage please raise open file limit to 3000 (ulimit -n 3000) before calling the package manager."
|
||||
else
|
||||
einfo "Will run test suite with open file limit set to 3000 (minimum test coverage)."
|
||||
fi
|
||||
else
|
||||
einfo "Will run test suite with open file limit set to 4162 (medium test coverage)."
|
||||
fi
|
||||
else
|
||||
einfo "Will run test suite with open file limit set to 16500 (best test coverage)."
|
||||
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"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
local MULTILIB_WRAPPED_HEADERS
|
||||
local MULTILIB_CHOST_TOOLS
|
||||
if use client-libs ; then
|
||||
# headers with ABI specific data
|
||||
MULTILIB_WRAPPED_HEADERS=(
|
||||
/usr/include/mysql/server/my_config.h
|
||||
/usr/include/mysql/server/mysql_version.h )
|
||||
|
||||
# wrap the config scripts
|
||||
MULTILIB_CHOST_TOOLS=( /usr/bin/mysql_config )
|
||||
multilib-minimal_src_install
|
||||
else
|
||||
multilib_src_install
|
||||
multilib_src_install_all
|
||||
fi
|
||||
}
|
||||
|
||||
# Intentionally override eclass function
|
||||
multilib_src_install() {
|
||||
|
||||
cmake-utils_src_install
|
||||
|
||||
# Kill old libmysqclient_r symlinks if they exist. Time to fix what depends on them.
|
||||
find "${D}" -name 'libmysqlclient_r.*' -type l -delete || die
|
||||
}
|
||||
|
||||
multilib_src_install_all() {
|
||||
# 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
|
||||
cp "${FILESDIR}/my.cnf-5.7" "${TMPDIR}/my.cnf" || die
|
||||
eprefixify "${TMPDIR}/my.cnf"
|
||||
doins "${TMPDIR}/my.cnf"
|
||||
insinto "${MY_SYSCONFDIR#${EPREFIX}}/mysql.d"
|
||||
cp "${FILESDIR}/my.cnf.distro-client" "${TMPDIR}/50-distro-client.cnf" || die
|
||||
eprefixify "${TMPDIR}/50-distro-client.cnf"
|
||||
doins "${TMPDIR}/50-distro-client.cnf"
|
||||
|
||||
if use server ; then
|
||||
mycnf_src="my.cnf.distro-server"
|
||||
sed -e "s!@DATADIR@!${MY_DATADIR}!g" \
|
||||
"${FILESDIR}/${mycnf_src}" \
|
||||
> "${TMPDIR}/my.cnf.ok" || die
|
||||
|
||||
if use prefix ; then
|
||||
sed -i -r -e '/^user[[:space:]]*=[[:space:]]*mysql$/d' \
|
||||
"${TMPDIR}/my.cnf.ok" || die
|
||||
fi
|
||||
|
||||
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" 50-distro-server.cnf
|
||||
fi
|
||||
|
||||
#Remove mytop if perl is not selected
|
||||
[[ -e "${ED}/usr/bin/mytop" ]] && ! use perl && rm -f "${ED}/usr/bin/mytop"
|
||||
}
|
||||
|
||||
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 "${EROOT%/}/$MYSQL_TMPDIR" ]] ; then
|
||||
einfo "Creating MySQL tmpdir $MYSQL_TMPDIR"
|
||||
install -d -m 770 -o mysql -g mysql "${EROOT%/}/$MYSQL_TMPDIR"
|
||||
fi
|
||||
|
||||
if [[ ! -d "${EROOT%/}/$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 http://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 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
|
||||
# http://dev.mysql.com/doc/mysql/en/time-zone-support.html
|
||||
echo "USE mysql;" >"${sqltmp}"
|
||||
"${EROOT%/}/usr/bin/mysql_tzinfo_to_sql" "${EROOT%/}/usr/share/zoneinfo" >> "${sqltmp}" 2>/dev/null
|
||||
chown mysql "${sqltmp}" || die
|
||||
|
||||
# --initialize-insecure will not set root password
|
||||
# --initialize would set a random one in the log which we don't need as we set it ourselves
|
||||
local cmd=( "${EROOT%/}/usr/sbin/mysqld" "--initialize-insecure" "--init-file='${sqltmp}'" )
|
||||
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} \
|
||||
$(use prefix || echo --user=mysql) \
|
||||
--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="ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY '${MYSQL_ROOT_PASSWORD}'"
|
||||
"${EROOT%/}/usr/bin/mysql" \
|
||||
--no-defaults \
|
||||
"--socket=${socket}" \
|
||||
-hlocalhost \
|
||||
-e "${sql}"
|
||||
eend $?
|
||||
|
||||
# Stop the server and cleanup
|
||||
einfo "Stopping the server ..."
|
||||
kill $(< "${pidfile}" )
|
||||
rm -f "${sqltmp}"
|
||||
wait %1
|
||||
einfo "Done"
|
||||
}
|
@ -1,2 +1,3 @@
|
||||
DIST mysqltuner-1.6.18.tar.gz 169074 BLAKE2B e138e29db2f0b1abf88b2d8268732fd9f05043abf320d8d97493d6abb3880e5664eaea39392406297e3125789ffc172f6347922ba14a00af16beb3f6f8080802 SHA512 8067b7ac4a4fe7398ee2cdc463a30042f46972f97680b49912dca46fd1d835989aa4115568dbe5473ff28c4d956bf0ad70537318db788dd56bc93ad220e6bcb6
|
||||
DIST mysqltuner-1.7.13.tar.gz 26721104 BLAKE2B 76a51c5e3ff897feed6bb6348fb5b09ab3fce0eae403880a3be96203522c9006980dbf6966e8c7e7784168c71e149cc57941ffbadba049b68b30993ed4d519d1 SHA512 88842bef1968f3150be49a5e82cdd0349bf0975f6ff0d8188117240ed2161ae1e44722077ff661ce31b55d0d4fc90fa4bb1972d96405113d82255718cebe0d53
|
||||
DIST mysqltuner-1.7.15.tar.gz 212839 BLAKE2B cd90091063e6ae7737cb79f6936d14577352c5b6c016e0efcf82cfcabcbc1acf9f646258bebc835ede368d5ea5594e269d165cb01ab8c980e5fdc68f3c605747 SHA512 b1ea9c91df3fb68d7ae9e54014b4d9095122f10750f7807e0c72d9bbbb859db9a60bc8698d337f4dda6e1bd89ce4ff97fa4299f5dbf650f6fa03012c309e761f
|
||||
|
@ -0,0 +1,11 @@
|
||||
--- a/mysqltuner.pl 2019-05-21 21:04:53.000000000 +0300
|
||||
+++ b/mysqltuner.pl 2019-07-28 22:14:09.888967978 +0300
|
||||
@@ -1739,7 +1739,7 @@
|
||||
my $PASS_COLUMN_NAME = 'password';
|
||||
if ( $myvar{'version'} =~ /5\.7|10\..*MariaDB*/ ) {
|
||||
$PASS_COLUMN_NAME =
|
||||
-"IF(plugin='mysql_native_password', authentication_string, password)";
|
||||
+"IF(plugin='mysql_native_password', authentication_string, 'password')";
|
||||
}
|
||||
debugprint "Password column = $PASS_COLUMN_NAME";
|
||||
|
@ -0,0 +1,39 @@
|
||||
# Copyright 1999-2019 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=7
|
||||
|
||||
MY_PN=MySQLTuner-perl
|
||||
|
||||
DESCRIPTION="MySQLTuner is a high-performance MySQL tuning script"
|
||||
HOMEPAGE="https://github.com/major/MySQLTuner-perl"
|
||||
SRC_URI="https://github.com/major/${MY_PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
||||
|
||||
LICENSE="GPL-3+"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
|
||||
RDEPEND="
|
||||
dev-lang/perl
|
||||
virtual/mysql
|
||||
virtual/perl-Getopt-Long"
|
||||
|
||||
DEPEND="${RDEPEND}"
|
||||
|
||||
PATCHES=(
|
||||
# Fix password detecting under MySQL 5.7 upstream #442 #427 #441
|
||||
"${FILESDIR}/${P}-password.patch" )
|
||||
|
||||
S="${WORKDIR}/${MY_PN}-${PV}"
|
||||
|
||||
DOCS=( USAGE.md CONTRIBUTING.md INTERNALS.md basic_passwords.txt vulnerabilities.csv )
|
||||
|
||||
src_install() {
|
||||
einstalldocs
|
||||
|
||||
newbin "${PN}.pl" "${PN}"
|
||||
|
||||
# Passwords and vulnerabilities are meant to be fed
|
||||
# to the script uncompressed.
|
||||
docompress -x "/usr/share/doc/${PF}/basic_passwords.txt" "/usr/share/doc/${PF}/vulnerabilities.csv"
|
||||
}
|
@ -1,45 +1,35 @@
|
||||
DIST instantclient-basic-linux-12.1.0.2.0.zip 59727331 BLAKE2B 8a4beb891fd6693b74be4f575bff3af7f70cb751a9fbfab80aa145737008cc745f83f2ec349a5959fcaac9aa789210ecd6da88e0eea63d23ce62fcb402274ea8 SHA512 5d93c72c43ba2ca765209f4c1d518b9e93c80ff33625bf0bc33b974413e2b91ab22681e0922d2148fbfa6b6043fe84eee5334aa398e1ee7b1c2663ff2b3bb235
|
||||
DIST instantclient-basic-linux-12.2.0.1.0.zip 64594237 BLAKE2B bd74522486ec6be857ed83e23a1a64a2794dc14ac184ef9dd4324fc4b9d0d61be8b6b70e32cfe814c6c8972bc7c9aef1d48a60180b8310d861fa66179027c391 SHA512 35cdd84765f1e020cd1e7fe3a765449bcad1c3b09189ab64f6a969da27d7ff2932bad319037ec066615e672d2b3105d4c36b42ec30ab60d6c577a2796908d22b
|
||||
DIST instantclient-basic-linux-18.3.0.0.0dbru.zip 67930600 BLAKE2B 70d9c54a8df66859d40e4374cd3073613fbf3656850373ada6c9707a7076e0d0749e3b1a84e2d46d18643f80020ecf8c525224433c946946787388dc3f57c79c SHA512 3e1bda593c14d14942c7bf8393111792df01bc9d5a15ae0b4010bd29d71bda4ab044dca6741d00185976c70790fc24b5221afc436d33abe6277e7513cb8bd859
|
||||
DIST instantclient-basic-linux.x64-12.1.0.2.0.zip 63352239 BLAKE2B 88042fbdccc6b79e8ed82f78f47ac985af413c53b9f2c9654a8ab10008ca9f7cdc4c46a12af5eca6aca47f27bd4d28ee465cd6ed91076268a361faa247440162 SHA512 e4cbdf40f00521651002f0753ead292b7a33352a7dae5d77635fbdb784451a1b9331ad614326dccdea34ecff3d44ddd0932b83c4bd405e69d95c7decae945f2c
|
||||
DIST instantclient-basic-linux.x64-12.2.0.1.0.zip 68965195 BLAKE2B 11e4a995f00ec4f218fe08ddd139c6d60b28bd9ffb78ce566be989eb5d229e5186e60406598b78067f480755e49bbeb6675dd3081186599fc0cac89e66a6f2eb SHA512 13f9b80d1021309fa48ca6c9dd6406ba6f97dcd611f786e940db42eeaba40cdf603b108954b9b3195f830e49377593e31b04f8d9310f619418bcd129b39f2ff1
|
||||
DIST instantclient-basic-linux-19.3.0.0.0dbru.zip 69597591 BLAKE2B 4ac954c027a83c1a05b502203f1465bb29bb4e58486a98bec7848d9ae0bed6835fdc6bb5f889cc9dadc815d47e5e06258c11a6ab1fd045bd7a878858f3d1164b SHA512 d9a7c664cae598344ec7b9e9c43def9626dcc0d54d478843a5145dfb3dad5df51121c5b2e9f4bb48a240611981f7721441344649d1f267b667356271ac778beb
|
||||
DIST instantclient-basic-linux.x64-18.3.0.0.0dbru.zip 72794506 BLAKE2B 22db5d69d48c33061db72bdc050e081ec24152c5e4655505c7f75407646f5ffa140aa51f4638ad8e7c5628476bb44358cb061b2d228ab1e36cd9464e49fcf1f6 SHA512 92e607e1711b24ddf10f11ecd3b389795acc544a567a95cb62b624e5913ad11a1707699b5df659f5fb33dae5cd56700036644e643c7edbe51e7a67e57a152ecc
|
||||
DIST instantclient-basic-linux.x64-18.5.0.0.0dbru.zip 72902980 BLAKE2B 23fd9885309507183758cf817b0d68342633ad08eb627f4136b967cf38e1910cefa905f17ffea7c929fafe2232eca71ee66a15153f202eb0d03236a1b21cdc30 SHA512 10e6f91dfe07ee4788a5f70ce65affe141061e7b1d6ea0eab6583bd2aed47d7281824e91da2103c53f15e49f02b94add8c3d524494cd4eacded90b2d1cc8743b
|
||||
DIST instantclient-jdbc-linux-12.1.0.2.0.zip 1571004 BLAKE2B 5d6d8f2ad86eff24be192ff0984a92351cb0dbf56619428a3c5c339dc0a5cc0048e2143e252803f5def6f0f111c4f69081d8aa41bc28002361586bef8ecff44b SHA512 ed3e5f831f1ac7351bd6eb7b3c10a09bba0f1989384ff1f041fdf94a5ca6acbf06e8285283f48731be6ece3dce55d307ac31e8bab57548dca0e3b3056060b5b2
|
||||
DIST instantclient-jdbc-linux-12.2.0.1.0.zip 1572140 BLAKE2B ac8a5767924a991503d64b7127e801bd09116ff5155a4943db76bf8678bccfd38c35d744d5a1654a51368feef97df39cad8a9b62ceb69f0cdf416af742385dea SHA512 3b57ab454645f8719a75c8778ab33589548018ec09d187ca88252006f44b014d62659a622ae423f79f9bf0f11149cafaa33880e90278c94a847e69e409bd3dca
|
||||
DIST instantclient-basic-linux.x64-19.3.0.0.0dbru.zip 75106438 BLAKE2B d3738c6a92251c75bf39afa996eecfeb9052c6cb6a8cd2080755c8108559257c4aaf660b6a12a1127228122836c85d15d84bb322d49921184ec67ee32ffbfddc SHA512 13ddda55c88fe72e761d9b9ce5bc5ccda4df0bd5ca6237efed34e6dfebf10866b116f3aa7eaf023a73458406584a4e57ecde825bf996fc0e844c030e4d8a3bba
|
||||
DIST instantclient-jdbc-linux-18.3.0.0.0dbru.zip 1574763 BLAKE2B 2ddbb6a6d61c3b6bc3e37b40f786dd86f5efadcf8cbe5b58dec2631b92ebae25065cb29f87ceed9a1f426ada094a9c0ef1887f8ea7b70e66527e9b75e11f213e SHA512 96298e579b6b5a81ae2ef679d6bf9a18f8bd08c33981d0a5b836c20710dc07d15d7964895a3d66c01075a20720d333f766ac439dc4f3867edac473e020eaf065
|
||||
DIST instantclient-jdbc-linux.x64-12.1.0.2.0.zip 1571639 BLAKE2B 1e50ff99548aa22e32ae48b629e6a83477cf7ad6d56b622e4c03831b43377841d3892b1f3079148a2a93b42d7d2be2670233c33edebac219f5a71384e43ab495 SHA512 1e6aa33c159d5769d10b16da3c5ff16629dae049c7e7d3ab1504a0ad625968f4d3f655a83ff128bff726c3ed03eab9ef7603c897aad288d1dc4e557c03ac7e2a
|
||||
DIST instantclient-jdbc-linux.x64-12.2.0.1.0.zip 1572942 BLAKE2B 3521505368a46046149ae28e2fae0bb85d5a70da33c029c684289a3586341fc0e63b0a88b93cbaa28aacbffaca678260f94658faa2b7e8aa31d1103a41660dac SHA512 79c939442431e14b9f30e94821fc4d8eeb34cd35b887fd8fa90a045357a241a58a53d591d22a5f42b188540c50350b842391a3871c86eb4fe8169ea23001a21a
|
||||
DIST instantclient-jdbc-linux-19.3.0.0.0dbru.zip 1577507 BLAKE2B 2347eb36b1dbe7552753be35b2656edbb43140768379abb8e5c94be7fb3f66fa139becb332d328d8e7f0b7f0b4e32d86703d1760dba36f53471a5b6b3c9b2341 SHA512 66c60f97994a1f45b0ef9e1600da6de319476a6ec4f6a0c9a04516d86e9d89fde1cdfd3bbd8279df125f96326f52875a1daef2ecbb6525fa26482eb637133205
|
||||
DIST instantclient-jdbc-linux.x64-18.3.0.0.0dbru.zip 1575572 BLAKE2B bb9d5ad0064b547a7152d4f9b170c646105b4a0731596fe381f7a2c63b720e36cc5a93eea59ea71aa3405999d972cf962a74063350c468a8d114ad28f5a0be0c SHA512 70ebece929cb11f34fdcb6aea75af3679f22d0b838c3d256d4c7c0249977423625b1244a54ca504b51d24e2f178b1784571e185574cd3db34c2cda8128298b60
|
||||
DIST instantclient-jdbc-linux.x64-18.5.0.0.0dbru.zip 1578269 BLAKE2B 88047325934da02e81e907c9c4caee540cb06da7d7c08562e90781c2f6004940ba20131d971018fe237cc09cfef010fdf6f912b2309006396315ad67c17b10b6 SHA512 e46a4326f61863a63be333bd588571bc037edd2de1f2462b799e17c65ca8556aeaf42e2eed3a7226bf8c89479b4a723fc6cf6582a65b5ee8a827ffdad1c06bc8
|
||||
DIST instantclient-odbc-linux-12.1.0.2.0.zip 1100875 BLAKE2B f8b1475962ab8b66b0e24b7bebc74cd13278e2dfe24885e5ef41e051319baee615ed5015a6b7d87e363e8915ff07fde8e17764a8e6aaa4b5b516f266ef1649dd SHA512 ff3b13a338f0acbae07f23d0e54f0ffa803afcda1a798b9cf38ced103201c0698a7240a062fb67af3547c17e906089e236cc3454685ca4645161a8b14414235e
|
||||
DIST instantclient-odbc-linux-12.2.0.1.0-2.zip 590200 BLAKE2B 732c07ecd7d19fd425873f2ddec00ffbe3da3b07b05bb902d2e3bcf6bcdcd62c7cecdf2bf2289f2c60df4d6dab3f337729eb7c4aacb64dacf73eadcf3ae3f99a SHA512 78a237d165dab3e991bc9bb495c67913c78b660922bfce872be5c774176eaee2ba2af08798b983ad513a33451cde06fe3a727dec66b91b944dc698bf048c7ef5
|
||||
DIST instantclient-jdbc-linux.x64-19.3.0.0.0dbru.zip 1578033 BLAKE2B 18c9fcca1282c316c67bf86258154d94a26d81779c1d36e782dd55d91fbaf40f03f1e403db9beefe114a27f09fd3d2bcfc643cf3e9a02ae68a5bc3d2eee51c16 SHA512 58813681a74286a7f080f729e3a237584a091487401af08619e2b4349323bf3def8cce22eb550d8ee5675e9a4c7ddddab8fa493bdd8c89981aff3ef0f65d1eb3
|
||||
DIST instantclient-odbc-linux-18.3.0.0.0dbru.zip 605026 BLAKE2B 2f7808ef2706c65d1c876e44e7b831ea0629a218347f34dd4b81cce192b45b78b26c9e164b179232b1fceeeeb5f84d807ac6bef1f36fd7d077e620bbb6c093eb SHA512 370d3f34c57e33909642f18104de8b48c2ab0fd1cf679087f8601720ebc1097f64caceb118010b9e8d2f7207cef04210b22a36824de747683c3a1162ccb4f09e
|
||||
DIST instantclient-odbc-linux.x64-12.1.0.2.0.zip 1289004 BLAKE2B 674b50e841c66af1d17c5293e3b1909b937664d106864d7709a921ee6f1e46f6571b3c00d064c6ffae0583f4fd84a0e1e7f0b8f635338856c429d9986208c69d SHA512 b6dd02a2566aba66bbdd61e37e00f0c0ec2d466ad969658d4943657642e6e385cb08d0bee3a127b38a7077ec71c8f341aa4696f381e4d9978f807caa1f3ccb91
|
||||
DIST instantclient-odbc-linux.x64-12.2.0.1.0-2.zip 634023 BLAKE2B 82cd7683bde15a6ff2c96b6b45da95509a7acf0dc7f6a58a19276a526a397481075fc27a450c1a6ac053a460bf075222a3d5afeba9c33f35cff9365b38eb922a SHA512 48d831c798b455349e1a79cecdeee96652d1911f2371d67c4d280b6595ac253ddff5b052ff2f680b42a5fc77b655ee438837ad4abde3137e251facd22c31cf2e
|
||||
DIST instantclient-odbc-linux-19.3.0.0.0dbru.zip 600586 BLAKE2B ec76518290f306f41305b12da317ad6de8a73f5049ca6e06fb0e4197ecc9dc8f9855c469fa36e309615a749150580d3ff89a35bfe5878c6441fe4f6218ce3410 SHA512 77aa6c1c5f5a93b86e4e529656ab1b2eaa1e008e343d17193a074e758fc270a5b12d641a959c51b00d5cbc7a2b562c590e662701e66e295d218995ff266f005b
|
||||
DIST instantclient-odbc-linux.x64-18.3.0.0.0dbru.zip 648825 BLAKE2B 1e96b87802c9ccc7d5f6ae2fdab501004e6fe8d4e155503bb983c82cdbfff729263e541689f4c2dbeeabfdd1037f0a97191e3a50842a8488a3267f24fec6b43d SHA512 23ad10a834fd92007147f8a7ad95dd9df4fbd5b786f7e2bb9afd6a12101fb934a40daa81ade914d8d0f59872591a1ae29438f23229b3767ed4ea3ff7cc730f66
|
||||
DIST instantclient-odbc-linux.x64-18.5.0.0.0dbru.zip 651470 BLAKE2B c5e7d794137fafb97ecb5fb647a640e59490270787c16f972882c03b34c4f404717f6f87e8501252f415a85b8d92031bba9910eb034c92c4f7fac37f66a3fe43 SHA512 b9e066af00b263b348f1e7a26dbf5672f01be79115bd75a47e2cff95f32fb412a8d03736e1c5ac663847a2d75ea5606cdb1fc27434f7690120c462f8eb15a6cf
|
||||
DIST instantclient-odbc-linux.x64-19.3.0.0.0dbru.zip 638697 BLAKE2B 2a9077243a4718c7af4abc2c36b7ca3e2993acb904dd9873c91bf8c0010ebaf18d6864a6b488eaa3a66d6fa42f83d099367533dad65d228db6e21e2b4e23a6df SHA512 dc148301d7e0ce7d74d90619f4f6aa03a26d61033d36803de7623ad64ddd5da1b34e24704ec1cf948ec341ba91e96c1bc08a5b62da79555d248f245ae75e776d
|
||||
DIST instantclient-precomp-linux-18.3.0.0.0dbru.zip 5200252 BLAKE2B 1d3613de34ccd61fd7c3795170d6d012491bc2c045c39f39db716ac7ce2e68e7e8da84c5b95afa8e50afb97d2fcad8e469f25627b9ec570f58f0b167a2f2348e SHA512 f783b6f346cc4848567a1b7284a93d1bf20a9555fa9cbfd57597b3856444969653cc6d6c3c3e710da6775d39d2efa6399b9e91f4f7458de43b0a404f4f693dd0
|
||||
DIST instantclient-precomp-linux-19.3.0.0.0dbru.zip 5183647 BLAKE2B 79a37d25e5731978911d643bdd19c0b0f1f66b153ed7164358fe2038a987594a73a8aacbc2fd8c542557a099e52931666cc9df5d5fb1af30e3fd365378fd505b SHA512 a6f7d7f82d657bb32431aa81c4dfa1fb3ea31aaa6df9781e19fc78c2ef25bf168420c95e3d9fa8f4aa3912afd3fc98eaa45f63a28ddaa091c4e50360802735b3
|
||||
DIST instantclient-precomp-linux.x64-18.3.0.0.0dbru.zip 6403554 BLAKE2B bd8e1b3de4b8c12214ea066be22f7ca18133e62e1d9a70b2710578e967204561cdcc9f719f8c1310e19e94baca367e0aa8c482e637b2f13a51781328b229be92 SHA512 292322eb07e3707cf469cea8390636fb2fae99a50b3b900a9c43b5808ce741cb708541820de5e9aa9c341290ad5015be32d968c43e1a14aebf97dd5fd04fc925
|
||||
DIST instantclient-precomp-linux.x64-18.5.0.0.0dbru.zip 6401804 BLAKE2B 9098fa6966023e4cc48e9c4fe60aef5e7c4d15a5200fcf92716fc224fa741cb6bd41bbe58a1820ab4c4c95b5be2faee8f0d85dcf6d5c0f14c51943fd67b32856 SHA512 e44ddacecbcc7311f59490116fe44f0d9b303c0a669d9ecf43926bb5627b0a767400bd51e8ec1162d088ff52022d2fa0d2f4e9d83e7efc0e40b0c02679c1b109
|
||||
DIST instantclient-sdk-linux-12.1.0.2.0.zip 667183 BLAKE2B 7dc36af0ea105ea97a961a2332b3643ec22cd64b81adbfc7206fce6e963948d5e59f860b8d4fe1318ed238adfb95effa2a138aec3e017a54bd7ce4c4cf1941be SHA512 fdc0111dba77aa88dc7a39c8d9afbd08c4ffde63890595501915be48a70f6fc623762657a1f3e3b54dd08b0d1e5ce00f99ec5ce40990bb17fab63ae38b986dc9
|
||||
DIST instantclient-sdk-linux-12.2.0.1.0.zip 674751 BLAKE2B 385a51450ed05c0e80151545037ed58b08dd400c01c8cbb1140045bc6372d4e1d334854881498a5c5833746c796ff94694d495257748442bd49267cc830fda88 SHA512 b2e53e95aaee283f9077f422c7ea8e961a42decb0f58d438eeb32edb32e8c88321261ffd009ca453b531c4aa22a74b8cf71b9a91754c2bd082c83f644523c72e
|
||||
DIST instantclient-precomp-linux.x64-19.3.0.0.0dbru.zip 6225945 BLAKE2B 1a17f20b7147496047f31cfeee56efb74c7daface1c7e6bab2a67258d410723b9e70b771fa9df9e16c2c27c831e97d538a69854e565ebd313f528a7f57a2f358 SHA512 6db99e0df10d439e93813ecdb27e5961232ab64a480b6aa0ee5e00a43e08bae2ade64b2abb60cad58e3139609f81835bde53d91ab35dedf427d3122d65c184b6
|
||||
DIST instantclient-sdk-linux-18.3.0.0.0dbru.zip 927121 BLAKE2B 5b53d759cb82c854d67b9bebaffb07e442b62d13367e5acf19af2dec4dbca2ba3ee50c83f89cf6e865121ad039227d898e74fecf43439610254eb43a429422a0 SHA512 6e4ccafb69d047b96dbda2f493c175f005b593472ea3c9a75fed758d2f12d970509d58b32d94f7a59b3d0402a87efaa754e6487af9cde01f7211f0145434c6c9
|
||||
DIST instantclient-sdk-linux.x64-12.1.0.2.0.zip 667174 BLAKE2B ad3f85a45fa04a579c7233d549a2c4083f0c07348503baea20f8b5404f097c36aed382d0316fbfcd6ec85f56524c288933613de2fc9fcafe961fed32108e002a SHA512 451918e34c4e41dcaea6d678cf10a20a3fb80be5c060aa1a2890f2eb528e6e4982bfd758598eaa115cd367cde0468f7f0f811bac2ef28671075868857eaf9f2e
|
||||
DIST instantclient-sdk-linux.x64-12.2.0.1.0.zip 674743 BLAKE2B fd1ab9b7fb2c3151a30d4f3f01d4003f46f95ae78f822214beed071bd52caddb3df39488d4341cb39a1f9a3259be0bc65b53df7f221055d8540d8fcc531455e9 SHA512 4a62ae1be31514664a0f442f65df633b93bea25f1ebe84e405865b9e363017726075bf2d5b2181600018ee122f74649aaa8ec5b507ee8938e33ae056a7f828b6
|
||||
DIST instantclient-sdk-linux-19.3.0.0.0dbru.zip 932301 BLAKE2B 6c5cfe55a651b9364da3f24d5739813e1b8165fad6434b7a09da2acdeddda408ab4fb37aa34851a537a000a4a7718fbe41ccf8b5fd51aa1bb4fd2e8ec0db33f9 SHA512 8dda8500ffa9eac966f54818d1c19b7d8b878f09c0664e03cfcc8ee8e5b061de566e6b411d15c5db58ef0e97374c2311d16fffd6b4c124dc06bdfd8fa8916b7b
|
||||
DIST instantclient-sdk-linux.x64-18.3.0.0.0dbru.zip 927118 BLAKE2B 9c6cd889843552cee3e84566d9c1b29369b1e7b20a01fac65676a33d6196b042a4c34cd2df8cf1ec5c8664a403e44e6a283f42912b7e056e093c744bd24ec24f SHA512 c9e1493601ec70541e437ded748f3be24deaa3f1037884fd003907bbab38b3099aef12dda1b9845c3eb3ce3827f743696f5ebe6d8dffe7974088c1329528b729
|
||||
DIST instantclient-sdk-linux.x64-18.5.0.0.0dbru.zip 929988 BLAKE2B 942f99fbea74e253a0be1677cfe40d79a26cb7a6442631d626648a65aa4f20b730e4f1ff13effcce5c4befd2ce50ab038f88b61c6f05ccad262568b209b3048f SHA512 7adc9e315c7c8784e4648a97fa54e03eb26a05b7b35a1f5cf1105898701b31fdc22f0011b1ae192752adcf3ec9798ba635bb9a9a5d4bc768a9a519c3564a9375
|
||||
DIST instantclient-sqlplus-linux-12.1.0.2.0.zip 828190 BLAKE2B b047e7ea3bbf1390c7ce3ad96c883d6a234798284b91b8ca8de2b086c27128144a0a3fdee2062c826e7e16b5dc263efdaab7e464371ef63deca4d9ffe4f668a7 SHA512 e521f141f0bb4fe62bda6da389a9c1038be879f1456500a9e70ac0a41d4f35cf2051181a03223521aa24ee06a33b67614d3afd91f01099afa0081f2771876d43
|
||||
DIST instantclient-sqlplus-linux-12.2.0.1.0.zip 869831 BLAKE2B f6c04823b1a6ac45594f13cc2ef45ab0ed25e5dd68bc33cc6412a578647df4472a71293cadbe1e98ea2983664a083b9b148aea04e717e5039e6def065d1ea583 SHA512 83894a72192ea9ca86d361ba70a6c011f297afa5d186a49fbab7050d9615de300d54b12af8d948fe18a75dcf51bd04f9feaa8460a1c69df9c55f9854e3cee61e
|
||||
DIST instantclient-sdk-linux.x64-19.3.0.0.0dbru.zip 932294 BLAKE2B 26ea1ce34209c1dc92101e211f009ecd20cfdad4d88e946844cbd1f2b1f4365c7dd273e7079be1dc807c38393035847e47800d65b0ecebb3a705cc6cac092a0d SHA512 ec3527a8371bb9644f4912b8190cfde53bf2afd8bf2ec7376bad97dc4d4b37f010a5e0d30567e2398f51c07affeeb15515347df095587a9cff84ef657b7e8c6e
|
||||
DIST instantclient-sqlplus-linux-18.3.0.0.0dbru.zip 881315 BLAKE2B 787dd43ffaadd493d8cb3a9a8bbd160f75c51ad07e16d8eb7631e8368b4a8bfe9e574326837724b3573705e1c309cbe0bf364c1b98660534b05f5d72d28b1b11 SHA512 9087e5654143c9da3499fb7f1b8a15b04433cacc0d96257519788b3cd12a0aa480b37fa37fbe55a2f40940ea8da1eeae9881712a87d5942e142c0f29b580e54d
|
||||
DIST instantclient-sqlplus-linux.x64-12.1.0.2.0.zip 861284 BLAKE2B fe2c3e3cd90c61aba7220c7782bcb540017aaa82f884b730b0ab3dfce462f866b468cda71106e016f9581a186582701239c282cb52927face949b0c1f8690692 SHA512 ad0af692bcae1231b58c7ea55fa79d85c7a5c9875a805565b1b5956ed30e608d753ac9210f6169ab3ff4e42ac2f1d871ccff47bd2656f7684925136fef1f30c2
|
||||
DIST instantclient-sqlplus-linux.x64-12.2.0.1.0.zip 904309 BLAKE2B 5d2dca2c98187674a506808f18ef8032f595d250c2a2577cf0cd7a9d785384a29d612b686575ac15516848792539d362745cc1c8aa321d2c84c10df01c896017 SHA512 7d31a5262138f8ae0429cf08f0743b9c8c7863fc8e6abfa8ef089cee2059da75bf23503f9f1f09c28b82c5209aca27f81da6c890799236307395b59fea3bf012
|
||||
DIST instantclient-sqlplus-linux-19.3.0.0.0dbru.zip 883462 BLAKE2B c3891a6ea525add3030372bb96b57e31b3a2743dd5bddbf12d4e2d43b7732b244c265a15423ae48d93db609f37a449233c8c16f5fd7c1d345b6ef42c217bb8d2 SHA512 521b80d47320b4ea51a68bee8f05fa51fa5e74690e62817d1fdb5471eaed577cad6bd5364e18fa5c18dc0cf56b99e33b62488a93c176d860e471ce2a7e9facca
|
||||
DIST instantclient-sqlplus-linux.x64-18.3.0.0.0dbru.zip 915778 BLAKE2B 8d93e462568a5bf5a294a5abcf0a0e30c08e9eef18c01a79b8f716261efbeb14a286d1058ddfa278108daeb49b74a3e296efa83291d7bc03f4ad35428c946701 SHA512 878ac2cf58aaa8cb237779fcd04378c95d738fd444eddd5745838fa86e8cd60f1c2be49f0f4fc3d4b16dca652fe66681ac0907a4aeddec1d9433e63d2f4e5db6
|
||||
DIST instantclient-sqlplus-linux.x64-18.5.0.0.0dbru.zip 918469 BLAKE2B 14efa748e7a892334610fa7a615c56b07e25873d5761408b9cac642af11ae2d97062b8014e4c7dee06dc37676d7c9d1a409d80f50b9d162210e073c1c4ef67d5 SHA512 8c2866ad092893647086adc554c7fab3c9bdc5429c9e0715d68717065fe12f106d228a2f241fe76bdc677a4adfa6eb01b0d866fab2bebbb1491a087a4b9d4a50
|
||||
DIST instantclient-tools-linux-12.1.0.2.0.zip 187088 BLAKE2B 41b68efbbe5925c64a869c71a12a947743e40b7d268c45a1b18c187a8b2179e224cd4ea940248d690b8f334c91afd901c1b3be34b2e8c2748e7f79487890cb60 SHA512 37a9eb3e2fdbbbf32f0fb5d017209db1b62d54efe48a875625e9d6162ea894d93d144358b2360989fa71704b346f86b36f1640a5c98f8aac7c1e6853b2d078fd
|
||||
DIST instantclient-tools-linux-12.2.0.1.0.zip 1032131 BLAKE2B 1a5d94b129d2d8a23031daee3882aef0b783c019baa69fcbd2a5d4ca4c97585212580196be158bdccaff2097027ceee881e948604ea2aa15525f36ea16e04ebd SHA512 e547d571bf881e787dc19bf23f82c4396f14dbca35a51a21e4133ff463f3c3c2c308cc2263f55b49ce70604569158266cd88d7ebf8b5cf51c9cd58b2871133e2
|
||||
DIST instantclient-sqlplus-linux.x64-19.3.0.0.0dbru.zip 910409 BLAKE2B e05c8dd3c545842989a2650013ff7ac8b06b41bef07efcd312ff66c51929942e3336bc9bd9a53a197088433b2cdbcb5bfbf4b2f4e1a40d68cfe559207737446e SHA512 34320712009ea724edd71f04bb72dd58fb99d34b1a357e238c04c9a55c7120eafc8c675558755a85587c7e75801dde2a7f8fc54795dd7e3e61568f8cf27d791d
|
||||
DIST instantclient-tools-linux-18.3.0.0.0dbru.zip 1042756 BLAKE2B 1b1af7abb50b6977e0dd4bc0f2b5e89534cf5bffe216dbe553063761470c45f330f4a72ece428a3e0dc8162cebad3cf0ffa628f4b3879bc434ecda7b7b07570f SHA512 b809b83e2e7dbe19c13611c1eb819fa4648a127ddc8a97abaa794213c7f4b6d28b70956aac4f331389d088c6fccc998d0eda8dc39f2dedc338f3baf03bc3ceac
|
||||
DIST instantclient-tools-linux.x64-12.1.0.2.0.zip 203511 BLAKE2B 6482cfa3ba521a5f5ad3e1517037f514daa1f452d8a5b38f0b4c949681a87dc54fe9551f52fcdc4e1ea6d243a808d3bd763147eaa72d9f656274ac7185823754 SHA512 f18ca11300fc20925c72122d03fc00402b9a52b39f7f70cfd3fa97264a1a2a173e7f77059affba98e897546e05c6ac1e3a546ce1c7e63ef049130496d346342b
|
||||
DIST instantclient-tools-linux.x64-12.2.0.1.0.zip 1132671 BLAKE2B a9ae6d2cd4e5661cb6a5dbb08cbc08ae4a5c28ce0bcc43db86ebd37997f8b14ec27f76613a1429d9359a765b98b465964bc5d24f1fce1d7964597191be658957 SHA512 1697289fc4b6a37277036dbef1892bd113892fcd3b0f347f0960ef8a1b90f3e91411bb237060e88bfdd418e50600372b710df08d97a4e847fd90d077ed0647d2
|
||||
DIST instantclient-tools-linux-19.3.0.0.0dbru.zip 1018792 BLAKE2B e24a264d59a4e29b8dcf56dfd09c80571612f465c8e2e91514c076553f27a0b07e66bb2ac0f3fcd6150c8a04ba861de04576e45ca1c03d173149296c029b8fcb SHA512 33103d934dec1bb6e34fb3f15cbbfba2ceec724334ca89bc55df3953779b3f4d45d70e7c9d1734481f366bb2e7e8ab58bef063415571acdf07022f193558ed54
|
||||
DIST instantclient-tools-linux.x64-18.3.0.0.0dbru.zip 1142609 BLAKE2B 5c915bd940b7bfaa42429710685cfafc5f0189607da2d789f4aaada2bc9d3365ad8e9ee31cc209830fa54b406ffe4b9b2fc2b5e0b6819ff176f7dbb566117a79 SHA512 2c198d9e723b39f7b512217eb08557dfa3c9ae32858acd882df8b9b24beecffe6b44eb089b50341edf01d7e4c0514d4b3de4aa06fa9185aa0538855963c174a4
|
||||
DIST instantclient-tools-linux.x64-18.5.0.0.0dbru.zip 1143747 BLAKE2B af5e70e1add6ca2042a213b5038a805ea3d6074703d5a677798684f60f681d6f7b642154d87a02fe973b5b12295ea9ef6f64c45836ceee66ce67d4e4498417b6 SHA512 7bbacdb1fa062c40b2389599ab522b02d63e68731d461fe45446685642b932ee741b8c9e0fde189d8f741db4131f6ac72c8124612e8668a00f90ed7c594fff50
|
||||
DIST instantclient-tools-linux.x64-19.3.0.0.0dbru.zip 1085243 BLAKE2B abcdf61f01e2bc67610043f1a66015050908f2c09f6aa8b615fd9e8b19a94a161d20b372119bc1bfc1a8ca8511a3859f67c48a39a3c2509fa326a350d7614721 SHA512 33df3a1c19d55ba94e0851bb4eaa83e0bfa72a132de2f5b98bb2a1b0528abee319b20211c7f08719c58250579506cda5c1f4de726f7b1e7c1c484dcb3986e43b
|
||||
|
@ -1,57 +0,0 @@
|
||||
Fake demo_xe.mk found in Oracle eXpress Edition,
|
||||
known by CPAN DBD::Oracle (bug#165834).
|
||||
This provides absolute paths for headers and libraries.
|
||||
|
||||
Paranoia drops those REMOVE lines.
|
||||
--- instantclient_12_1/sdk/demo/demo.mk
|
||||
+++ instantclient_12_1/sdk/demo/demo.mk
|
||||
@@ -28,8 +28,9 @@
|
||||
CC=/opt/SunProd/SUNWspro6.1/bin/CC
|
||||
cc=/opt/SunProd/SUNWspro6.1/bin/cc
|
||||
|
||||
-ICINCHOME=../
|
||||
-ICLIBHOME=../../
|
||||
+LIBDIR=lib
|
||||
+ICINCHOME=$(ORACLE_HOME)/
|
||||
+ICLIBHOME=$(ORACLE_HOME)/$(LIBDIR)
|
||||
ICLIBPATH=-L$(ICLIBHOME)
|
||||
THREADLIBS=-lthread
|
||||
CCLIB=$(ICLIBPATH) -locci -lclntsh $(THREADLIBS)
|
||||
@@ -64,18 +65,18 @@
|
||||
all: clean buildoci $(OCCIDEMO) $(OCCIOBJDEMO)
|
||||
|
||||
buildoci: $(CLNCACHE) $(LIBCLNT) $(CDEMOOBJS)
|
||||
- $(MKLINK) $(ICLIBHOME)libclntsh$(SO_EXT).12.1 $(ICLIBHOME)libclntsh$(SO_EXT)
|
||||
- $(MKLINK) $(ICLIBHOME)libocci$(SO_EXT).12.1 $(ICLIBHOME)libocci$(SO_EXT)
|
||||
+# $(MKLINK) $(ICLIBHOME)libclntsh$(SO_EXT).12.1 $(ICLIBHOME)libclntsh$(SO_EXT)
|
||||
+# $(MKLINK) $(ICLIBHOME)libocci$(SO_EXT).12.1 $(ICLIBHOME)libocci$(SO_EXT)
|
||||
$(CC) -o $(CDEMOEXE) $(LDFLAGS) $(CDEMOOBJS) $(CCLIB)
|
||||
- $(REMOVE) $(ICLIBHOME)libclntsh$(SO_EXT)
|
||||
- $(REMOVE) $(ICLIBHOME)libocci$(SO_EXT)
|
||||
+# $(REMOVE) $(ICLIBHOME)libclntsh$(SO_EXT)
|
||||
+# $(REMOVE) $(ICLIBHOME)libocci$(SO_EXT)
|
||||
|
||||
buildocci: $(CLNCACHE) $(LIBCLNT) $(OBJS)
|
||||
- $(MKLINK) $(ICLIBHOME)libclntsh$(SO_EXT).12.1 $(ICLIBHOME)libclntsh$(SO_EXT)
|
||||
- $(MKLINK) $(ICLIBHOME)libocci$(SO_EXT).12.1 $(ICLIBHOME)libocci$(SO_EXT)
|
||||
+# $(MKLINK) $(ICLIBHOME)libclntsh$(SO_EXT).12.1 $(ICLIBHOME)libclntsh$(SO_EXT)
|
||||
+# $(MKLINK) $(ICLIBHOME)libocci$(SO_EXT).12.1 $(ICLIBHOME)libocci$(SO_EXT)
|
||||
$(CC) -o $(EXE) $(LDFLAGS) $(OBJS) $(CCLIB)
|
||||
- $(REMOVE) $(ICLIBHOME)libclntsh$(SO_EXT)
|
||||
- $(REMOVE) $(ICLIBHOME)libocci$(SO_EXT)
|
||||
+# $(REMOVE) $(ICLIBHOME)libclntsh$(SO_EXT)
|
||||
+# $(REMOVE) $(ICLIBHOME)libocci$(SO_EXT)
|
||||
|
||||
$(OCCIDEMO):
|
||||
$(MAKE) -f $(MAKEFILE) buildocci OBJS=$@.o EXE=$@
|
||||
@@ -93,8 +94,8 @@
|
||||
|
||||
cleancache:
|
||||
$(REMOVE) $(CACHEDIR)
|
||||
- $(REMOVE) $(ICLIBHOME)libclntsh$(SO_EXT)
|
||||
- $(REMOVE) $(ICLIBHOME)libocci$(SO_EXT)
|
||||
+# $(REMOVE) $(ICLIBHOME)libclntsh$(SO_EXT)
|
||||
+# $(REMOVE) $(ICLIBHOME)libocci$(SO_EXT)
|
||||
|
||||
clean: $(CLNCACHE)
|
||||
$(REMOVE) cdemo81 cdemo81.o occidml occidml.o occiobj occiobj.o occiobjo* occiobjm* occiobj.h occiobjout.type
|
@ -1,303 +0,0 @@
|
||||
# Copyright 1999-2016 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI="6"
|
||||
|
||||
inherit eutils versionator pax-utils multilib-minimal
|
||||
|
||||
MY_PVM=$(get_version_component_range 1-2)
|
||||
|
||||
MY_PLAT_x86="Linux x86"
|
||||
MY_BITS_x86=32
|
||||
MY_A_x86="${PN/oracle-/}-basic-linux-${PV}.0.zip"
|
||||
MY_A_x86_sdk="${MY_A_x86/basic/sdk}"
|
||||
MY_A_x86_odbc="${MY_A_x86/basic/odbc}"
|
||||
MY_A_x86_jdbc="${MY_A_x86/basic/jdbc}"
|
||||
MY_A_x86_sqlplus="${MY_A_x86/basic/sqlplus}"
|
||||
MY_A_x86_tools="${MY_A_x86/basic/tools}"
|
||||
|
||||
MY_PLAT_amd64="Linux x86-64"
|
||||
MY_BITS_amd64=64
|
||||
MY_A_amd64="${PN/oracle-}-basic-linux.x64-${PV}.0.zip"
|
||||
MY_A_amd64_sdk="${MY_A_amd64/basic/sdk}"
|
||||
MY_A_amd64_odbc="${MY_A_amd64/basic/odbc}"
|
||||
MY_A_amd64_jdbc="${MY_A_amd64/basic/jdbc}"
|
||||
MY_A_amd64_sqlplus="${MY_A_amd64/basic/sqlplus}"
|
||||
MY_A_amd64_tools="${MY_A_amd64/basic/tools}"
|
||||
|
||||
DESCRIPTION="Oracle 12c Instant Client with SDK"
|
||||
HOMEPAGE="http://www.oracle.com/technetwork/database/features/instant-client/index.html"
|
||||
SRC_URI="
|
||||
abi_x86_32? (
|
||||
${MY_A_x86}
|
||||
odbc? ( ${MY_A_x86_odbc} )
|
||||
jdbc? ( ${MY_A_x86_jdbc} )
|
||||
!abi_x86_64? (
|
||||
sdk? ( ${MY_A_x86_sdk} )
|
||||
sqlplus? ( ${MY_A_x86_sqlplus} )
|
||||
tools? ( ${MY_A_x86_tools} )
|
||||
) )
|
||||
abi_x86_64? (
|
||||
${MY_A_amd64}
|
||||
odbc? ( ${MY_A_amd64_odbc} )
|
||||
jdbc? ( ${MY_A_amd64_jdbc} )
|
||||
sdk? ( ${MY_A_amd64_sdk} )
|
||||
sqlplus? ( ${MY_A_amd64_sqlplus} )
|
||||
tools? ( ${MY_A_amd64_tools} )
|
||||
)
|
||||
"
|
||||
|
||||
LICENSE="OTN"
|
||||
SLOT="0/${MY_PVM}"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
RESTRICT="fetch splitdebug"
|
||||
IUSE="jdbc odbc +sdk +sqlplus tools"
|
||||
|
||||
DEPEND="app-arch/unzip"
|
||||
RDEPEND="
|
||||
>=dev-libs/libaio-0.3.109-r5[${MULTILIB_USEDEP}]
|
||||
!<dev-db/oracle-instantclient-basic-12
|
||||
!<dev-db/oracle-instantclient-odbc-12
|
||||
!<dev-db/oracle-instantclient-jdbc-12
|
||||
!<dev-db/oracle-instantclient-sqlplus-12
|
||||
"
|
||||
|
||||
S="${WORKDIR}"
|
||||
|
||||
QA_PREBUILT="usr/lib*/oracle/*/client/lib*/lib*"
|
||||
|
||||
set_my_abivars() {
|
||||
S="${WORKDIR}/${ABI}/instantclient_$(
|
||||
replace_version_separator 1 "_" "${MY_PVM}"
|
||||
)"
|
||||
|
||||
local abi=${ABI}
|
||||
[[ ${abi} == 'default' ]] && abi=${ARCH}
|
||||
MY_PLAT=MY_PLAT_${abi} ; MY_PLAT=${!MY_PLAT} # platform name
|
||||
MY_BITS=MY_BITS_${abi} ; MY_BITS=${!MY_BITS} # platform bitwidth
|
||||
MY_A=MY_A_${abi} ; MY_A=${!MY_A} # runtime distfile
|
||||
MY_A_sdk=MY_A_${abi}_sdk ; MY_A_sdk=${!MY_A_sdk} # sdk distfile
|
||||
MY_A_odbc=MY_A_${abi}_odbc ; MY_A_odbc=${!MY_A_odbc} # odbc distfile
|
||||
MY_A_jdbc=MY_A_${abi}_jdbc ; MY_A_jdbc=${!MY_A_jdbc} # jdbc distfile
|
||||
MY_A_sqlplus=MY_A_${abi}_sqlplus; MY_A_sqlplus=${!MY_A_sqlplus} # sqlplus distfile
|
||||
MY_A_tools=MY_A_${abi}_tools ; MY_A_tools=${!MY_A_tools} # tools distfile
|
||||
|
||||
[[ -n ${MY_PLAT} ]]
|
||||
}
|
||||
|
||||
oic_distfile_status() {
|
||||
if [[ -r ${DISTDIR}/${1} ]]; then
|
||||
echo "already here"
|
||||
else
|
||||
echo "still absent"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_nofetch() {
|
||||
eerror "Please go to"
|
||||
eerror " ${HOMEPAGE%/*}/index-097480.html"
|
||||
eerror " and download"
|
||||
local ABI
|
||||
for ABI in $(multilib_get_enabled_abis)
|
||||
do
|
||||
set_my_abivars || continue
|
||||
eerror "Instant Client for ${MY_PLAT}"
|
||||
eerror " Basic: ($(oic_distfile_status ${MY_A})) ${MY_A}"
|
||||
use odbc &&
|
||||
eerror " ODBC: ($(oic_distfile_status ${MY_A_odbc})) ${MY_A_odbc}"
|
||||
use jdbc &&
|
||||
eerror " JDBC: ($(oic_distfile_status ${MY_A_jdbc})) ${MY_A_jdbc}"
|
||||
if multilib_is_native_abi; then
|
||||
use sdk &&
|
||||
eerror " SDK: ($(oic_distfile_status ${MY_A_sdk})) ${MY_A_sdk}"
|
||||
use sqlplus &&
|
||||
eerror " SQL*Plus: ($(oic_distfile_status ${MY_A_sqlplus})) ${MY_A_sqlplus}"
|
||||
use tools &&
|
||||
eerror " WRC: ($(oic_distfile_status ${MY_A_tools})) ${MY_A_tools}"
|
||||
fi
|
||||
done
|
||||
eerror "After downloading these files (for *all* shown architectures), put them in:"
|
||||
eerror " ${DISTDIR}/"
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
local ABI
|
||||
for ABI in $(multilib_get_enabled_abis)
|
||||
do
|
||||
set_my_abivars || continue
|
||||
mkdir "${WORKDIR}"/${ABI} || die
|
||||
cd "${WORKDIR}"/${ABI} || die
|
||||
unpack ${MY_A}
|
||||
use odbc && unpack ${MY_A_odbc}
|
||||
use jdbc && unpack ${MY_A_jdbc}
|
||||
if multilib_is_native_abi; then
|
||||
use sdk && unpack ${MY_A_sdk}
|
||||
use sqlplus && unpack ${MY_A_sqlplus}
|
||||
use tools && unpack ${MY_A_tools}
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
use sdk && PATCHES=( "${FILESDIR}"/12.1.0.2-makefile.patch )
|
||||
default
|
||||
}
|
||||
|
||||
# silence configure&compile messages from multilib-minimal
|
||||
src_configure() { :; }
|
||||
src_compile() { :; }
|
||||
|
||||
src_install() {
|
||||
# all content goes here
|
||||
local oracle_home=usr/$(get_libdir)/oracle/${MY_PVM}/client
|
||||
into "/${oracle_home}"
|
||||
|
||||
local ldpath= ABI
|
||||
for ABI in $(multilib_get_enabled_abis) # last iteration is final ABI
|
||||
do
|
||||
if ! set_my_abivars; then
|
||||
elog "Skipping unsupported ABI ${ABI}."
|
||||
continue
|
||||
fi
|
||||
einfo "Installing runtime for ${MY_PLAT} ..."
|
||||
|
||||
cd "${S}" || die
|
||||
|
||||
# shared libraries
|
||||
dolib.so lib*$(get_libname)*
|
||||
|
||||
# ensure to be linkable
|
||||
[[ -e libocci$(get_libname) ]] ||
|
||||
dosym libocci$(get_libname ${MY_PVM}) \
|
||||
"/${oracle_home}"/$(get_libdir)/libocci$(get_libname)
|
||||
[[ -e libclntsh$(get_libname) ]] ||
|
||||
dosym libclntsh$(get_libname ${MY_PVM}) \
|
||||
"/${oracle_home}"/$(get_libdir)/libclntsh$(get_libname)
|
||||
|
||||
# java archives
|
||||
insinto "/${oracle_home}"/$(get_libdir)
|
||||
doins *.jar
|
||||
|
||||
# runtime library path
|
||||
ldpath+=${ldpath:+:}/${oracle_home}/$(get_libdir)
|
||||
|
||||
eend $?
|
||||
done
|
||||
|
||||
local DOCS=()
|
||||
local HTML_DOCS=()
|
||||
local paxbins=( adrci genezi uidrvci )
|
||||
local scripts=()
|
||||
|
||||
use sqlplus && paxbins+=( sqlplus )
|
||||
use tools && paxbins+=( wrc )
|
||||
|
||||
if use odbc; then
|
||||
scripts+=( odbc_update_ini.sh )
|
||||
HTML_DOCS+=( ODBC_IC_Readme_Unix.html help )
|
||||
fi
|
||||
|
||||
einfo "Installing binaries for ${MY_PLAT} ..."
|
||||
dobin ${paxbins[@]} ${scripts}
|
||||
cd "${ED}${oracle_home}"/bin || die
|
||||
pax-mark -c ${paxbins[@]} || die
|
||||
cd "${S}" || die
|
||||
eend $?
|
||||
|
||||
if use sqlplus; then
|
||||
insinto "/${oracle_home}"/sqlplus/admin
|
||||
doins glogin.sql
|
||||
dosym "/${oracle_home}"/bin/sqlplus /usr/bin/sqlplus
|
||||
fi
|
||||
|
||||
if use sdk; then
|
||||
einfo "Installing SDK ..."
|
||||
|
||||
DOCS+=( sdk/demo )
|
||||
cd "${S}"/sdk || die
|
||||
|
||||
# SDK makefile, for #165834
|
||||
# As we change the relative filesystem layout compared
|
||||
# to vanilla instantclient.zip content, it feels easier
|
||||
# to fake the layout found in Oracle eXpress Edition.
|
||||
# Both layouts are known to DBD::Oracle (cpan).
|
||||
insinto "/${oracle_home}"/rdbms/demo
|
||||
newins demo/demo.mk demo_xe.mk
|
||||
|
||||
# Remove ldap.h, #299562
|
||||
rm include/ldap.h || die
|
||||
# DBD::Oracle needs rdbms/public as real directory
|
||||
insinto "/${oracle_home}"/rdbms/public
|
||||
doins include/*.h
|
||||
dosym rdbms/public "/${oracle_home}"/include
|
||||
# ruby-oci8 expects the headers here
|
||||
dosym "/${oracle_home}"/rdbms/public /usr/include/oracle/${MY_PVM}/client
|
||||
|
||||
# ott
|
||||
insinto "/${oracle_home}"/$(get_libdir)
|
||||
dobin ott
|
||||
doins *.zip
|
||||
|
||||
# more files found in the zip
|
||||
insinto "/${oracle_home}"/admin
|
||||
doins admin/oraaccess.xsd
|
||||
|
||||
eend $?
|
||||
fi
|
||||
|
||||
cd "${S}" || die
|
||||
einstalldocs
|
||||
|
||||
# create path for tnsnames.ora
|
||||
insinto /etc/oracle
|
||||
doins "${FILESDIR}"/tnsnames.ora.sample
|
||||
|
||||
# Add OCI libs to library path
|
||||
{
|
||||
echo "# ${EPREFIX}/etc/env.d/50${PN}"
|
||||
echo "# Do not edit this file, but 99${PN} instead"
|
||||
echo
|
||||
echo "ORACLE_HOME=${EPREFIX}/${oracle_home}"
|
||||
echo "LDPATH=${ldpath}"
|
||||
echo "TNS_ADMIN=/etc/oracle/"
|
||||
} > "${T}"/50${PN}
|
||||
|
||||
doenvd "${T}"/50${PN}
|
||||
|
||||
# ensure ORACLE_HOME/lib exists
|
||||
[[ -e ${ED}${oracle_home}/lib/. ]] ||
|
||||
dosym $(get_libdir) "${oracle_home}"/lib
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
if [[ -r ${EROOT}/etc/env.d/99${PN} ]]; then
|
||||
cp "${EROOT}/etc/env.d/99${PN}" "${ED}/etc/env.d/" || die
|
||||
else
|
||||
{
|
||||
echo "# ${EPREFIX}/etc/env.d/99${PN}"
|
||||
echo "# Configure system-wide defaults for your Oracle Instant Client here"
|
||||
echo
|
||||
echo "#$(grep '^ORACLE_HOME=' "${ED}/etc/env.d/50${PN}")"
|
||||
echo "#$(grep '^TNS_ADMIN=' "${ED}/etc/env.d/50${PN}")"
|
||||
echo "#NLS_LANG="
|
||||
} > "${ED}/etc/env.d/99${PN}"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "${P} does not provide an sqlnet.ora"
|
||||
elog "configuration file, redirecting oracle diagnostics for database-"
|
||||
elog "and network-issues into ~USER/oradiag_USER/ instead."
|
||||
elog "It should be safe to ignore this message in sqlnet.log there:"
|
||||
elog " Directory does not exist for read/write [ORACLE_HOME/client/log] []"
|
||||
elog "See https://bugs.gentoo.org/show_bug.cgi?id=465252 for reference."
|
||||
elog "If you want to directly analyse low-level debug info or don't want"
|
||||
elog "to see it at all, so you really need an sqlnet.ora file, please"
|
||||
elog "consult http://search.oracle.com/search/search?q=sqlnet.ora"
|
||||
elog ""
|
||||
elog "TNS_ADMIN has been set to ${EROOT}etc/oracle by default,"
|
||||
elog "put your tnsnames.ora there or configure TNS_ADMIN"
|
||||
elog "to point to your user specific configuration."
|
||||
ewarn "Please re-source your shell settings for ORACLE_HOME"
|
||||
ewarn " changes, such as: source /etc/profile"
|
||||
}
|
@ -1,315 +0,0 @@
|
||||
# Copyright 1999-2017 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI="6"
|
||||
|
||||
inherit eutils versionator pax-utils multilib-minimal
|
||||
|
||||
MY_PVM=$(get_version_component_range 1-2)
|
||||
MYLIB_PVM=12.1
|
||||
|
||||
MY_PV=$(get_version_component_range 1-4)
|
||||
MY_PVP=$(get_version_component_range 5) # p2
|
||||
|
||||
MY_PLAT_x86="Linux x86"
|
||||
MY_BITS_x86=32
|
||||
MY_A_x86="${PN/oracle-/}-basic-linux-${MY_PV}.0.zip"
|
||||
MY_A_x86_sdk="${MY_A_x86/basic/sdk}"
|
||||
MY_A_x86_odbc="${MY_A_x86/basic/odbc}"
|
||||
MY_A_x86_jdbc="${MY_A_x86/basic/jdbc}"
|
||||
MY_A_x86_sqlplus="${MY_A_x86/basic/sqlplus}"
|
||||
MY_A_x86_tools="${MY_A_x86/basic/tools}"
|
||||
|
||||
MY_PLAT_amd64="Linux x86-64"
|
||||
MY_BITS_amd64=64
|
||||
MY_A_amd64="${PN/oracle-}-basic-linux.x64-${MY_PV}.0.zip"
|
||||
MY_A_amd64_sdk="${MY_A_amd64/basic/sdk}"
|
||||
MY_A_amd64_odbc="${MY_A_amd64/basic/odbc}"
|
||||
MY_A_amd64_jdbc="${MY_A_amd64/basic/jdbc}"
|
||||
MY_A_amd64_sqlplus="${MY_A_amd64/basic/sqlplus}"
|
||||
MY_A_amd64_tools="${MY_A_amd64/basic/tools}"
|
||||
|
||||
if [[ ${MY_PVP} == p* ]]
|
||||
then
|
||||
MY_PVP=-${MY_PVP#p}
|
||||
# Updated 9/22/2017: instantclient-odbc-linux-12.2.0.1.0-2.zip
|
||||
MY_A_x86_odbc="${MY_A_x86_odbc%.zip}${MY_PVP}.zip"
|
||||
MY_A_amd64_odbc="${MY_A_amd64_odbc%.zip}${MY_PVP}.zip"
|
||||
fi
|
||||
|
||||
DESCRIPTION="Oracle 12c Instant Client with SDK"
|
||||
HOMEPAGE="http://www.oracle.com/technetwork/database/features/instant-client/index.html"
|
||||
SRC_URI="
|
||||
abi_x86_32? (
|
||||
${MY_A_x86}
|
||||
odbc? ( ${MY_A_x86_odbc} )
|
||||
jdbc? ( ${MY_A_x86_jdbc} )
|
||||
!abi_x86_64? (
|
||||
sdk? ( ${MY_A_x86_sdk} )
|
||||
sqlplus? ( ${MY_A_x86_sqlplus} )
|
||||
tools? ( ${MY_A_x86_tools} )
|
||||
) )
|
||||
abi_x86_64? (
|
||||
${MY_A_amd64}
|
||||
odbc? ( ${MY_A_amd64_odbc} )
|
||||
jdbc? ( ${MY_A_amd64_jdbc} )
|
||||
sdk? ( ${MY_A_amd64_sdk} )
|
||||
sqlplus? ( ${MY_A_amd64_sqlplus} )
|
||||
tools? ( ${MY_A_amd64_tools} )
|
||||
)
|
||||
"
|
||||
|
||||
LICENSE="OTN"
|
||||
SLOT="0/${MYLIB_PVM}"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
RESTRICT="fetch splitdebug"
|
||||
IUSE="jdbc odbc +sdk +sqlplus tools"
|
||||
|
||||
DEPEND="app-arch/unzip"
|
||||
RDEPEND="
|
||||
>=dev-libs/libaio-0.3.109-r5[${MULTILIB_USEDEP}]
|
||||
!<dev-db/oracle-instantclient-basic-12
|
||||
!<dev-db/oracle-instantclient-odbc-12
|
||||
!<dev-db/oracle-instantclient-jdbc-12
|
||||
!<dev-db/oracle-instantclient-sqlplus-12
|
||||
"
|
||||
|
||||
S="${WORKDIR}"
|
||||
|
||||
QA_PREBUILT="usr/lib*/oracle/*/client/lib*/lib*"
|
||||
|
||||
set_my_abivars() {
|
||||
S="${WORKDIR}/${ABI}/instantclient_$(
|
||||
replace_version_separator 1 "_" "${MY_PVM}"
|
||||
)"
|
||||
|
||||
local abi=${ABI}
|
||||
[[ ${abi} == 'default' ]] && abi=${ARCH}
|
||||
MY_PLAT=MY_PLAT_${abi} ; MY_PLAT=${!MY_PLAT} # platform name
|
||||
MY_BITS=MY_BITS_${abi} ; MY_BITS=${!MY_BITS} # platform bitwidth
|
||||
MY_A=MY_A_${abi} ; MY_A=${!MY_A} # runtime distfile
|
||||
MY_A_sdk=MY_A_${abi}_sdk ; MY_A_sdk=${!MY_A_sdk} # sdk distfile
|
||||
MY_A_odbc=MY_A_${abi}_odbc ; MY_A_odbc=${!MY_A_odbc} # odbc distfile
|
||||
MY_A_jdbc=MY_A_${abi}_jdbc ; MY_A_jdbc=${!MY_A_jdbc} # jdbc distfile
|
||||
MY_A_sqlplus=MY_A_${abi}_sqlplus; MY_A_sqlplus=${!MY_A_sqlplus} # sqlplus distfile
|
||||
MY_A_tools=MY_A_${abi}_tools ; MY_A_tools=${!MY_A_tools} # tools distfile
|
||||
|
||||
[[ -n ${MY_PLAT} ]]
|
||||
}
|
||||
|
||||
oic_distfile_status() {
|
||||
if [[ -r ${DISTDIR}/${1} ]]; then
|
||||
echo "already here"
|
||||
else
|
||||
echo "still absent"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_nofetch() {
|
||||
eerror "Please go to"
|
||||
eerror " ${HOMEPAGE%/*}/index-097480.html"
|
||||
eerror " and download"
|
||||
local ABI
|
||||
for ABI in $(multilib_get_enabled_abis)
|
||||
do
|
||||
set_my_abivars || continue
|
||||
eerror "Instant Client for ${MY_PLAT}"
|
||||
eerror " Basic: ($(oic_distfile_status ${MY_A})) ${MY_A}"
|
||||
use odbc &&
|
||||
eerror " ODBC: ($(oic_distfile_status ${MY_A_odbc})) ${MY_A_odbc}"
|
||||
use jdbc &&
|
||||
eerror " JDBC: ($(oic_distfile_status ${MY_A_jdbc})) ${MY_A_jdbc}"
|
||||
if multilib_is_native_abi; then
|
||||
use sdk &&
|
||||
eerror " SDK: ($(oic_distfile_status ${MY_A_sdk})) ${MY_A_sdk}"
|
||||
use sqlplus &&
|
||||
eerror " SQL*Plus: ($(oic_distfile_status ${MY_A_sqlplus})) ${MY_A_sqlplus}"
|
||||
use tools &&
|
||||
eerror " WRC: ($(oic_distfile_status ${MY_A_tools})) ${MY_A_tools}"
|
||||
fi
|
||||
done
|
||||
eerror "After downloading these files (for *all* shown architectures), put them in:"
|
||||
eerror " ${DISTDIR}/"
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
local ABI
|
||||
for ABI in $(multilib_get_enabled_abis)
|
||||
do
|
||||
set_my_abivars || continue
|
||||
mkdir "${WORKDIR}"/${ABI} || die
|
||||
cd "${WORKDIR}"/${ABI} || die
|
||||
unpack ${MY_A}
|
||||
use odbc && unpack ${MY_A_odbc}
|
||||
use jdbc && unpack ${MY_A_jdbc}
|
||||
if multilib_is_native_abi; then
|
||||
use sdk && unpack ${MY_A_sdk}
|
||||
use sqlplus && unpack ${MY_A_sqlplus}
|
||||
use tools && unpack ${MY_A_tools}
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
use sdk && PATCHES=( "${FILESDIR}"/12.1.0.2-makefile.patch )
|
||||
default
|
||||
}
|
||||
|
||||
# silence configure&compile messages from multilib-minimal
|
||||
src_configure() { :; }
|
||||
src_compile() { :; }
|
||||
|
||||
src_install() {
|
||||
# all content goes here
|
||||
local oracle_home=usr/$(get_libdir)/oracle/${MY_PVM}/client
|
||||
into "/${oracle_home}"
|
||||
|
||||
local ldpath= ABI
|
||||
for ABI in $(multilib_get_enabled_abis) # last iteration is final ABI
|
||||
do
|
||||
if ! set_my_abivars; then
|
||||
elog "Skipping unsupported ABI ${ABI}."
|
||||
continue
|
||||
fi
|
||||
einfo "Installing runtime for ${MY_PLAT} ..."
|
||||
|
||||
cd "${S}" || die
|
||||
|
||||
# shared libraries
|
||||
dolib.so lib*$(get_libname)*
|
||||
|
||||
# ensure to be linkable
|
||||
[[ -e libocci$(get_libname) ]] ||
|
||||
dosym libocci$(get_libname ${MYLIB_PVM}) \
|
||||
"/${oracle_home}"/$(get_libdir)/libocci$(get_libname)
|
||||
[[ -e libclntsh$(get_libname) ]] ||
|
||||
dosym libclntsh$(get_libname ${MYLIB_PVM}) \
|
||||
"/${oracle_home}"/$(get_libdir)/libclntsh$(get_libname)
|
||||
|
||||
# java archives
|
||||
insinto "/${oracle_home}"/$(get_libdir)
|
||||
doins *.jar
|
||||
|
||||
# runtime library path
|
||||
ldpath+=${ldpath:+:}/${oracle_home}/$(get_libdir)
|
||||
|
||||
eend $?
|
||||
done
|
||||
|
||||
local DOCS=()
|
||||
local HTML_DOCS=()
|
||||
local paxbins=( adrci genezi uidrvci )
|
||||
local scripts=()
|
||||
|
||||
use sqlplus && paxbins+=( sqlplus )
|
||||
use tools && paxbins+=( wrc )
|
||||
|
||||
if use odbc; then
|
||||
scripts+=( odbc_update_ini.sh )
|
||||
HTML_DOCS+=( ODBC_IC_Readme_Unix.html help )
|
||||
fi
|
||||
|
||||
einfo "Installing binaries for ${MY_PLAT} ..."
|
||||
dobin ${paxbins[@]} ${scripts}
|
||||
cd "${ED}${oracle_home}"/bin || die
|
||||
pax-mark -c ${paxbins[@]} || die
|
||||
cd "${S}" || die
|
||||
eend $?
|
||||
|
||||
if use sqlplus; then
|
||||
insinto "/${oracle_home}"/sqlplus/admin
|
||||
doins glogin.sql
|
||||
dosym "/${oracle_home}"/bin/sqlplus /usr/bin/sqlplus
|
||||
fi
|
||||
|
||||
if use sdk; then
|
||||
einfo "Installing SDK ..."
|
||||
|
||||
DOCS+=( sdk/demo )
|
||||
cd "${S}"/sdk || die
|
||||
|
||||
# SDK makefile, for #165834
|
||||
# As we change the relative filesystem layout compared
|
||||
# to vanilla instantclient.zip content, it feels easier
|
||||
# to fake the layout found in Oracle eXpress Edition.
|
||||
# Both layouts are known to DBD::Oracle (cpan).
|
||||
insinto "/${oracle_home}"/rdbms/demo
|
||||
newins demo/demo.mk demo_xe.mk
|
||||
|
||||
# Remove ldap.h, #299562
|
||||
rm include/ldap.h || die
|
||||
# DBD::Oracle needs rdbms/public as real directory
|
||||
insinto "/${oracle_home}"/rdbms/public
|
||||
doins include/*.h
|
||||
dosym rdbms/public "/${oracle_home}"/include
|
||||
# ruby-oci8 expects the headers here
|
||||
dosym "/${oracle_home}"/rdbms/public /usr/include/oracle/${MYLIB_PVM}/client
|
||||
|
||||
# ott
|
||||
insinto "/${oracle_home}"/$(get_libdir)
|
||||
dobin ott
|
||||
doins *.zip
|
||||
|
||||
# more files found in the zip
|
||||
insinto "/${oracle_home}"/admin
|
||||
doins admin/oraaccess.xsd
|
||||
|
||||
eend $?
|
||||
fi
|
||||
|
||||
cd "${S}" || die
|
||||
einstalldocs
|
||||
|
||||
# create path for tnsnames.ora
|
||||
insinto /etc/oracle
|
||||
doins "${FILESDIR}"/tnsnames.ora.sample
|
||||
|
||||
# Add OCI libs to library path
|
||||
{
|
||||
echo "# ${EPREFIX}/etc/env.d/50${PN}"
|
||||
echo "# Do not edit this file, but 99${PN} instead"
|
||||
echo
|
||||
echo "ORACLE_HOME=${EPREFIX}/${oracle_home}"
|
||||
echo "LDPATH=${ldpath}"
|
||||
echo "TNS_ADMIN=/etc/oracle/"
|
||||
} > "${T}"/50${PN}
|
||||
|
||||
doenvd "${T}"/50${PN}
|
||||
|
||||
# ensure ORACLE_HOME/lib exists
|
||||
[[ -e ${ED}${oracle_home}/lib/. ]] ||
|
||||
dosym $(get_libdir) "${oracle_home}"/lib
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
if [[ -r ${EROOT}/etc/env.d/99${PN} ]]; then
|
||||
cp "${EROOT}/etc/env.d/99${PN}" "${ED}/etc/env.d/" || die
|
||||
else
|
||||
{
|
||||
echo "# ${EPREFIX}/etc/env.d/99${PN}"
|
||||
echo "# Configure system-wide defaults for your Oracle Instant Client here"
|
||||
echo
|
||||
echo "#$(grep '^ORACLE_HOME=' "${ED}/etc/env.d/50${PN}")"
|
||||
echo "#$(grep '^TNS_ADMIN=' "${ED}/etc/env.d/50${PN}")"
|
||||
echo "#NLS_LANG="
|
||||
} > "${ED}/etc/env.d/99${PN}"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "${P} does not provide an sqlnet.ora"
|
||||
elog "configuration file, redirecting oracle diagnostics for database-"
|
||||
elog "and network-issues into ~USER/oradiag_USER/ instead."
|
||||
elog "It should be safe to ignore this message in sqlnet.log there:"
|
||||
elog " Directory does not exist for read/write [ORACLE_HOME/client/log] []"
|
||||
elog "See https://bugs.gentoo.org/show_bug.cgi?id=465252 for reference."
|
||||
elog "If you want to directly analyse low-level debug info or don't want"
|
||||
elog "to see it at all, so you really need an sqlnet.ora file, please"
|
||||
elog "consult http://search.oracle.com/search/search?q=sqlnet.ora"
|
||||
elog ""
|
||||
elog "TNS_ADMIN has been set to ${EROOT}etc/oracle by default,"
|
||||
elog "put your tnsnames.ora there or configure TNS_ADMIN"
|
||||
elog "to point to your user specific configuration."
|
||||
ewarn "Please re-source your shell settings for ORACLE_HOME"
|
||||
ewarn " changes, such as: source /etc/profile"
|
||||
}
|
@ -1,342 +0,0 @@
|
||||
# Copyright 1999-2018 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI="7"
|
||||
|
||||
inherit eutils pax-utils multilib-minimal
|
||||
|
||||
DESCRIPTION="Oracle 18c Instant Client with SDK"
|
||||
HOMEPAGE="https://www.oracle.com/technetwork/database/database-technologies/instant-client/overview/index.html"
|
||||
|
||||
MY_SOVER=18.1 # the library soname found in the zip files
|
||||
|
||||
IUSE="jdbc odbc precomp +sdk +sqlplus tools"
|
||||
REQUIRED_USE="precomp? ( sdk )"
|
||||
|
||||
MY_PVM=$(ver_cut 1-2)
|
||||
MY_P="instantclient_$(ver_rs 1 _ ${MY_PVM})"
|
||||
|
||||
MY_PV=$(ver_cut 1-4)
|
||||
MY_PVP=$(ver_cut 5) # p2
|
||||
|
||||
MY_PLAT_x86="Linux x86"
|
||||
MY_BITS_x86=32
|
||||
MY_A_x86="${PN/oracle-/}-basic-linux-${MY_PV}.0dbru.zip"
|
||||
MY_A_x86_jdbc="${MY_A_x86/basic/jdbc}"
|
||||
MY_A_x86_odbc="${MY_A_x86/basic/odbc}"
|
||||
MY_A_x86_precomp="${MY_A_x86/basic/precomp}"
|
||||
MY_A_x86_sdk="${MY_A_x86/basic/sdk}"
|
||||
MY_A_x86_sqlplus="${MY_A_x86/basic/sqlplus}"
|
||||
MY_A_x86_tools="${MY_A_x86/basic/tools}"
|
||||
|
||||
MY_PLAT_amd64="Linux x86-64"
|
||||
MY_BITS_amd64=64
|
||||
MY_A_amd64="${PN/oracle-}-basic-linux.x64-${MY_PV}.0dbru.zip"
|
||||
MY_A_amd64_jdbc="${MY_A_amd64/basic/jdbc}"
|
||||
MY_A_amd64_odbc="${MY_A_amd64/basic/odbc}"
|
||||
MY_A_amd64_precomp="${MY_A_amd64/basic/precomp}"
|
||||
MY_A_amd64_sdk="${MY_A_amd64/basic/sdk}"
|
||||
MY_A_amd64_sqlplus="${MY_A_amd64/basic/sqlplus}"
|
||||
MY_A_amd64_tools="${MY_A_amd64/basic/tools}"
|
||||
|
||||
if [[ ${MY_PVP} == p* ]]
|
||||
then
|
||||
MY_PVP=-${MY_PVP#p}
|
||||
# Updated 9/22/2017: instantclient-odbc-linux-12.2.0.1.0-2.zip
|
||||
MY_A_x86_odbc="${MY_A_x86_odbc%.zip}${MY_PVP}.zip"
|
||||
MY_A_amd64_odbc="${MY_A_amd64_odbc%.zip}${MY_PVP}.zip"
|
||||
fi
|
||||
|
||||
SRC_URI="
|
||||
abi_x86_32? (
|
||||
${MY_A_x86}
|
||||
jdbc? ( ${MY_A_x86_jdbc} )
|
||||
odbc? ( ${MY_A_x86_odbc} )
|
||||
precomp? ( ${MY_A_x86_precomp} )
|
||||
!abi_x86_64? (
|
||||
sdk? ( ${MY_A_x86_sdk} )
|
||||
sqlplus? ( ${MY_A_x86_sqlplus} )
|
||||
tools? ( ${MY_A_x86_tools} )
|
||||
) )
|
||||
abi_x86_64? (
|
||||
${MY_A_amd64}
|
||||
jdbc? ( ${MY_A_amd64_jdbc} )
|
||||
odbc? ( ${MY_A_amd64_odbc} )
|
||||
precomp? ( ${MY_A_amd64_precomp} )
|
||||
sdk? ( ${MY_A_amd64_sdk} )
|
||||
sqlplus? ( ${MY_A_amd64_sqlplus} )
|
||||
tools? ( ${MY_A_amd64_tools} )
|
||||
)
|
||||
"
|
||||
|
||||
LICENSE="OTN"
|
||||
SLOT="0/${MY_SOVER}"
|
||||
KEYWORDS="~amd64 ~x86"
|
||||
RESTRICT="fetch splitdebug"
|
||||
|
||||
DEPEND="app-arch/unzip"
|
||||
RDEPEND="
|
||||
>=dev-libs/libaio-0.3.109-r5[${MULTILIB_USEDEP}]
|
||||
!<dev-db/oracle-instantclient-basic-12
|
||||
!<dev-db/oracle-instantclient-odbc-12
|
||||
!<dev-db/oracle-instantclient-jdbc-12
|
||||
!<dev-db/oracle-instantclient-sqlplus-12
|
||||
"
|
||||
|
||||
S="${WORKDIR}/${MY_P}"
|
||||
|
||||
QA_PREBUILT="usr/lib*/oracle/client/*/*"
|
||||
|
||||
set_my_abivars() {
|
||||
if multilib_is_native_abi; then
|
||||
MY_WORKDIR="${WORKDIR}"
|
||||
MY_S="${S}"
|
||||
else
|
||||
MY_WORKDIR="${WORKDIR}/${ABI}"
|
||||
MY_S="${MY_WORKDIR}/${MY_P}"
|
||||
fi
|
||||
|
||||
local abi=${ABI}
|
||||
[[ ${abi} == 'default' ]] && abi=${ARCH}
|
||||
MY_PLAT=MY_PLAT_${abi} ; MY_PLAT=${!MY_PLAT} # platform name
|
||||
MY_BITS=MY_BITS_${abi} ; MY_BITS=${!MY_BITS} # platform bitwidth
|
||||
MY_A=MY_A_${abi} ; MY_A=${!MY_A} # runtime distfile
|
||||
MY_A_jdbc=MY_A_${abi}_jdbc ; MY_A_jdbc=${!MY_A_jdbc} # jdbc distfile
|
||||
MY_A_odbc=MY_A_${abi}_odbc ; MY_A_odbc=${!MY_A_odbc} # odbc distfile
|
||||
MY_A_precomp=MY_A_${abi}_precomp; MY_A_precomp=${!MY_A_precomp} # precomp distfile
|
||||
MY_A_sdk=MY_A_${abi}_sdk ; MY_A_sdk=${!MY_A_sdk} # sdk distfile
|
||||
MY_A_sqlplus=MY_A_${abi}_sqlplus; MY_A_sqlplus=${!MY_A_sqlplus} # sqlplus distfile
|
||||
MY_A_tools=MY_A_${abi}_tools ; MY_A_tools=${!MY_A_tools} # tools distfile
|
||||
|
||||
[[ -n ${MY_PLAT} ]]
|
||||
}
|
||||
|
||||
oic_distfile_status() {
|
||||
: # We must not access DISTDIR in pkg_* phase, bug#612966.
|
||||
# Not removing this lines yet, we may eventually specify this feature.
|
||||
# if [[ -r ${DISTDIR}/${1} ]]; then
|
||||
# echo "already here"
|
||||
# else
|
||||
# echo "still absent"
|
||||
# fi
|
||||
}
|
||||
|
||||
pkg_nofetch() {
|
||||
eerror "Please go to"
|
||||
eerror " ${HOMEPAGE//overview/downloads}"
|
||||
eerror " and download"
|
||||
local ABI
|
||||
for ABI in $(multilib_get_enabled_abis)
|
||||
do
|
||||
set_my_abivars || continue
|
||||
eerror "Instant Client for ${MY_PLAT}"
|
||||
# convenient ordering like Linux x86-64 download site
|
||||
eerror " Basic: $(oic_distfile_status ${MY_A}) ${MY_A}"
|
||||
use sqlplus && multilib_is_native_abi &&
|
||||
eerror " SQL*Plus: $(oic_distfile_status ${MY_A_sqlplus}) ${MY_A_sqlplus}"
|
||||
use tools && multilib_is_native_abi &&
|
||||
eerror " Tools: $(oic_distfile_status ${MY_A_tools}) ${MY_A_tools}"
|
||||
use sdk && multilib_is_native_abi &&
|
||||
eerror " SDK: $(oic_distfile_status ${MY_A_sdk}) ${MY_A_sdk}"
|
||||
use jdbc &&
|
||||
eerror " JDBC: $(oic_distfile_status ${MY_A_jdbc}) ${MY_A_jdbc}"
|
||||
use odbc &&
|
||||
eerror " ODBC: $(oic_distfile_status ${MY_A_odbc}) ${MY_A_odbc}"
|
||||
use precomp &&
|
||||
eerror " Precompiler: $(oic_distfile_status ${MY_A_precomp}) ${MY_A_precomp}"
|
||||
done
|
||||
eerror "After downloading these files (for *all* shown architectures),"
|
||||
eerror "put them in your DISTDIR filesystem directory."
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
local ABI
|
||||
for ABI in $(multilib_get_enabled_abis)
|
||||
do
|
||||
set_my_abivars || continue
|
||||
mkdir -p "${MY_WORKDIR}" || die
|
||||
cd "${MY_WORKDIR}" || die
|
||||
unpack ${MY_A}
|
||||
use jdbc && unpack ${MY_A_jdbc}
|
||||
use odbc && unpack ${MY_A_odbc}
|
||||
use precomp && unpack ${MY_A_precomp}
|
||||
if multilib_is_native_abi; then
|
||||
use sdk && unpack ${MY_A_sdk}
|
||||
use sqlplus && unpack ${MY_A_sqlplus}
|
||||
use tools && unpack ${MY_A_tools}
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
if use sdk; then
|
||||
rm sdk/include/ldap.h || die #299562
|
||||
PATCHES=( "${FILESDIR}"/18.3.0.0-makefile.patch )
|
||||
fi
|
||||
default
|
||||
}
|
||||
|
||||
# silence configure&compile messages from multilib-minimal
|
||||
src_configure() { :; }
|
||||
src_compile() { :; }
|
||||
|
||||
src_install() {
|
||||
# all content goes here without version number, bug#578402
|
||||
local oracle_home=/usr/$(get_libdir)/oracle/client
|
||||
local ldpath=
|
||||
|
||||
local ABI
|
||||
for ABI in $(multilib_get_enabled_abis) # last iteration is final ABI
|
||||
do
|
||||
if ! set_my_abivars; then
|
||||
elog "Skipping unsupported ABI ${ABI}."
|
||||
continue
|
||||
fi
|
||||
einfo "Installing runtime for ${MY_PLAT} ..."
|
||||
|
||||
cd "${MY_S}" || die
|
||||
|
||||
# shared libraries
|
||||
into "${oracle_home}"
|
||||
dolib.so lib*$(get_libname)*
|
||||
use precomp && dolib.a cobsqlintf.o
|
||||
|
||||
# ensure to be linkable
|
||||
[[ -e libocci$(get_libname) ]] ||
|
||||
dosym libocci$(get_libname ${MY_SOVER}) \
|
||||
"${oracle_home}"/$(get_libdir)/libocci$(get_libname)
|
||||
[[ -e libclntsh$(get_libname) ]] ||
|
||||
dosym libclntsh$(get_libname ${MY_SOVER}) \
|
||||
"${oracle_home}"/$(get_libdir)/libclntsh$(get_libname)
|
||||
|
||||
# java archives
|
||||
insinto "${oracle_home}"/$(get_libdir)
|
||||
doins *.jar
|
||||
|
||||
# runtime library path
|
||||
ldpath+=${ldpath:+:}${oracle_home}/$(get_libdir)
|
||||
|
||||
# Vanilla filesystem layout does not support multilib
|
||||
# installation, so we need to move the libs into the
|
||||
# ABI specific libdir. However, ruby-oci8 build system
|
||||
# detects an instantclient along the libraries, and
|
||||
# does expect the sdk right there.
|
||||
use sdk && dosym ../sdk "${oracle_home}"/$(get_libdir)/sdk
|
||||
|
||||
eend $?
|
||||
done
|
||||
|
||||
local DOCS=( BASIC_README )
|
||||
local HTML_DOCS=()
|
||||
local paxbins=( adrci genezi uidrvci )
|
||||
local scripts=()
|
||||
|
||||
if use jdbc; then
|
||||
DOCS+=( JDBC_README )
|
||||
fi
|
||||
if use odbc; then
|
||||
DOCS+=( ODBC_README )
|
||||
HTML_DOCS+=( help )
|
||||
scripts+=( odbc_update_ini.sh )
|
||||
fi
|
||||
if use precomp; then
|
||||
DOCS+=( PRECOMP_README )
|
||||
paxbins+=( sdk/{proc,procob,rtsora} )
|
||||
insinto "${oracle_home}/precomp/admin"
|
||||
doins precomp/admin/{pcs,pcb}cfg.cfg
|
||||
fi
|
||||
if use sdk; then
|
||||
einfo "Installing SDK ..."
|
||||
DOCS+=( sdk/SDK_README )
|
||||
scripts+=( sdk/ott )
|
||||
insinto "${oracle_home}"/$(get_libdir)
|
||||
doins sdk/ottclasses.zip
|
||||
insinto "${oracle_home}"/sdk
|
||||
doins -r sdk/{admin,demo,include}
|
||||
|
||||
# The build system in DBD::Oracle perl module would detect
|
||||
# an instantclient along the sharedlibs in ORACLE_HOME, which
|
||||
# we cannot provide. But it also knows Oracle eXpress Edition's
|
||||
# layout - which we emulate enough here to let DBD::Oracle work.
|
||||
dosym ../../sdk/demo/demo.mk "${oracle_home}"/rdbms/demo/demo_xe.mk
|
||||
|
||||
# some build systems expect the headers here, also see bug#652096
|
||||
dosym "${oracle_home}"/sdk/include /usr/include/oracle/${MY_PVM}/client
|
||||
|
||||
eend $?
|
||||
fi
|
||||
if use sqlplus; then
|
||||
DOCS+=( SQLPLUS_README )
|
||||
paxbins+=( sqlplus )
|
||||
insinto "${oracle_home}"/sqlplus/admin
|
||||
doins glogin.sql
|
||||
dosym "${oracle_home}"/bin/sqlplus /usr/bin/sqlplus
|
||||
fi
|
||||
if use tools; then
|
||||
DOCS+=( TOOLS_README )
|
||||
paxbins+=( exp expdp imp impdp sqlldr wrc )
|
||||
fi
|
||||
|
||||
einfo "Installing binaries for ${MY_PLAT} ..."
|
||||
into "${oracle_home}"
|
||||
dobin ${paxbins[*]} ${scripts[*]}
|
||||
pushd "${ED}${oracle_home}/bin" >/dev/null || die
|
||||
pax-mark -c ${paxbins[*]#*/} || die
|
||||
popd >/dev/null || die
|
||||
eend $?
|
||||
|
||||
einstalldocs
|
||||
|
||||
# create path for tnsnames.ora
|
||||
insinto /etc/oracle
|
||||
doins "${FILESDIR}"/tnsnames.ora.sample
|
||||
|
||||
# Add OCI libs to library path
|
||||
{
|
||||
echo "# ${EPREFIX}/etc/env.d/50${PN}"
|
||||
echo "# Do not edit this file, but 99${PN} instead"
|
||||
echo
|
||||
echo "ORACLE_HOME=${EPREFIX}${oracle_home}"
|
||||
echo "LDPATH=${ldpath}"
|
||||
echo "TNS_ADMIN=${EPREFIX}/etc/oracle/"
|
||||
} > "${T}"/50${PN}
|
||||
|
||||
doenvd "${T}"/50${PN}
|
||||
|
||||
# ensure ORACLE_HOME/lib exists
|
||||
[[ -e ${ED}${oracle_home}/lib/. ]] ||
|
||||
dosym $(get_libdir) "${oracle_home#/}"/lib
|
||||
}
|
||||
|
||||
pkg_preinst() {
|
||||
if [[ -r ${EROOT}/etc/env.d/99${PN} ]]; then
|
||||
cp "${EROOT}/etc/env.d/99${PN}" "${ED}/etc/env.d/" || die
|
||||
else
|
||||
{
|
||||
echo "# ${EPREFIX}/etc/env.d/99${PN}"
|
||||
echo "# Configure system-wide defaults for your Oracle Instant Client here"
|
||||
echo
|
||||
echo "#$(grep '^ORACLE_HOME=' "${ED}/etc/env.d/50${PN}")"
|
||||
echo "#$(grep '^TNS_ADMIN=' "${ED}/etc/env.d/50${PN}")"
|
||||
echo "#NLS_LANG="
|
||||
} > "${ED}/etc/env.d/99${PN}"
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
elog "${P} does not provide an sqlnet.ora"
|
||||
elog "configuration file, redirecting oracle diagnostics for database-"
|
||||
elog "and network-issues into ~USER/oradiag_USER/ instead."
|
||||
elog "It should be safe to ignore this message in sqlnet.log there:"
|
||||
elog " Directory does not exist for read/write [ORACLE_HOME/client/log] []"
|
||||
elog "See https://bugs.gentoo.org/show_bug.cgi?id=465252 for reference."
|
||||
elog "If you want to directly analyse low-level debug info or don't want"
|
||||
elog "to see it at all, so you really need an sqlnet.ora file, please"
|
||||
elog "consult http://search.oracle.com/search/search?q=sqlnet.ora"
|
||||
elog ""
|
||||
elog "TNS_ADMIN has been set to ${EPREFIX}/etc/oracle by default,"
|
||||
elog "put your tnsnames.ora there or configure TNS_ADMIN"
|
||||
elog "to point to your user specific configuration."
|
||||
ewarn "Please re-source your shell settings for ORACLE_HOME"
|
||||
ewarn " changes, such as: source ${EPREFIX}/etc/profile"
|
||||
}
|
Binary file not shown.
Binary file not shown.
@ -0,0 +1,373 @@
|
||||
# Copyright 1999-2019 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
# Build written by Andrew John Hughes (gnu_andrew@member.fsf.org)
|
||||
|
||||
# *********************************************************
|
||||
# * IF YOU CHANGE THIS EBUILD, CHANGE ICEDTEA-6.* AS WELL *
|
||||
# *********************************************************
|
||||
|
||||
EAPI="6"
|
||||
SLOT="8"
|
||||
|
||||
inherit check-reqs flag-o-matic java-pkg-2 java-vm-2 multiprocessing pax-utils prefix versionator xdg-utils
|
||||
|
||||
ICEDTEA_VER=$(get_version_component_range 1-3)
|
||||
ICEDTEA_BRANCH=$(get_version_component_range 1-2)
|
||||
ICEDTEA_PKG=icedtea-${ICEDTEA_VER}
|
||||
ICEDTEA_PRE=$(get_version_component_range _)
|
||||
|
||||
CORBA_TARBALL="24a4cc7d7de6.tar.xz"
|
||||
JAXP_TARBALL="7f4569c121d6.tar.xz"
|
||||
JAXWS_TARBALL="1c6f4ebde697.tar.xz"
|
||||
JDK_TARBALL="51afcf17e031.tar.xz"
|
||||
LANGTOOLS_TARBALL="2008b12a91d1.tar.xz"
|
||||
OPENJDK_TARBALL="c8f86954855a.tar.xz"
|
||||
NASHORN_TARBALL="69b1da223d93.tar.xz"
|
||||
HOTSPOT_TARBALL="ab8fadcbbde6.tar.xz"
|
||||
SHENANDOAH_TARBALL="ff69edbcd7ae.tar.xz"
|
||||
AARCH32_TARBALL="26d64a5c4b9a.tar.xz"
|
||||
|
||||
CACAO_TARBALL="cacao-c182f119eaad.tar.xz"
|
||||
JAMVM_TARBALL="jamvm-ec18fb9e49e62dce16c5094ef1527eed619463aa.tar.gz"
|
||||
|
||||
CORBA_GENTOO_TARBALL="icedtea-${ICEDTEA_BRANCH}-corba-${CORBA_TARBALL}"
|
||||
JAXP_GENTOO_TARBALL="icedtea-${ICEDTEA_BRANCH}-jaxp-${JAXP_TARBALL}"
|
||||
JAXWS_GENTOO_TARBALL="icedtea-${ICEDTEA_BRANCH}-jaxws-${JAXWS_TARBALL}"
|
||||
JDK_GENTOO_TARBALL="icedtea-${ICEDTEA_BRANCH}-jdk-${JDK_TARBALL}"
|
||||
LANGTOOLS_GENTOO_TARBALL="icedtea-${ICEDTEA_BRANCH}-langtools-${LANGTOOLS_TARBALL}"
|
||||
OPENJDK_GENTOO_TARBALL="icedtea-${ICEDTEA_BRANCH}-openjdk-${OPENJDK_TARBALL}"
|
||||
NASHORN_GENTOO_TARBALL="icedtea-${ICEDTEA_BRANCH}-nashorn-${NASHORN_TARBALL}"
|
||||
HOTSPOT_GENTOO_TARBALL="icedtea-${ICEDTEA_BRANCH}-hotspot-${HOTSPOT_TARBALL}"
|
||||
SHENANDOAH_GENTOO_TARBALL="icedtea-${ICEDTEA_BRANCH}-shenandoah-${SHENANDOAH_TARBALL}"
|
||||
AARCH32_GENTOO_TARBALL="icedtea-${ICEDTEA_BRANCH}-aarch32-${AARCH32_TARBALL}"
|
||||
|
||||
CACAO_GENTOO_TARBALL="icedtea-${CACAO_TARBALL}"
|
||||
JAMVM_GENTOO_TARBALL="icedtea-${JAMVM_TARBALL}"
|
||||
|
||||
DROP_URL="https://icedtea.classpath.org/download/drops"
|
||||
ICEDTEA_URL="${DROP_URL}/icedtea${SLOT}/${ICEDTEA_VER}"
|
||||
|
||||
DESCRIPTION="A harness to build OpenJDK using Free Software build tools and dependencies"
|
||||
HOMEPAGE="https://icedtea.classpath.org"
|
||||
SRC_PKG="${ICEDTEA_PKG}.tar.xz"
|
||||
SRC_URI="
|
||||
https://icedtea.classpath.org/download/source/${SRC_PKG}
|
||||
${ICEDTEA_URL}/openjdk.tar.xz -> ${OPENJDK_GENTOO_TARBALL}
|
||||
${ICEDTEA_URL}/corba.tar.xz -> ${CORBA_GENTOO_TARBALL}
|
||||
${ICEDTEA_URL}/jaxp.tar.xz -> ${JAXP_GENTOO_TARBALL}
|
||||
${ICEDTEA_URL}/jaxws.tar.xz -> ${JAXWS_GENTOO_TARBALL}
|
||||
${ICEDTEA_URL}/jdk.tar.xz -> ${JDK_GENTOO_TARBALL}
|
||||
${ICEDTEA_URL}/hotspot.tar.xz -> ${HOTSPOT_GENTOO_TARBALL}
|
||||
${ICEDTEA_URL}/nashorn.tar.xz -> ${NASHORN_GENTOO_TARBALL}
|
||||
${ICEDTEA_URL}/langtools.tar.xz -> ${LANGTOOLS_GENTOO_TARBALL}
|
||||
shenandoah? ( ${ICEDTEA_URL}/shenandoah.tar.xz -> ${SHENANDOAH_GENTOO_TARBALL} )
|
||||
arm? ( ${ICEDTEA_URL}/aarch32.tar.xz -> ${AARCH32_GENTOO_TARBALL} )
|
||||
${DROP_URL}/cacao/${CACAO_TARBALL} -> ${CACAO_GENTOO_TARBALL}
|
||||
${DROP_URL}/jamvm/${JAMVM_TARBALL} -> ${JAMVM_GENTOO_TARBALL}"
|
||||
|
||||
LICENSE="Apache-1.1 Apache-2.0 GPL-1 GPL-2 GPL-2-with-linking-exception LGPL-2 MPL-1.0 MPL-1.1 public-domain W3C"
|
||||
KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
|
||||
|
||||
IUSE="+alsa cacao +cups doc examples +gtk headless-awt
|
||||
jamvm +jbootstrap kerberos libressl nsplugin pax_kernel +pch
|
||||
pulseaudio sctp selinux shenandoah smartcard +source +system-lcms test +webstart zero"
|
||||
|
||||
REQUIRED_USE="gtk? ( !headless-awt )"
|
||||
|
||||
# Ideally the following were optional at build time.
|
||||
ALSA_COMMON_DEP="
|
||||
>=media-libs/alsa-lib-1.0"
|
||||
CUPS_COMMON_DEP="
|
||||
>=net-print/cups-1.2.12"
|
||||
X_COMMON_DEP="
|
||||
>=media-libs/giflib-4.1.6:0=
|
||||
>=media-libs/libpng-1.2:0=
|
||||
>=x11-libs/libX11-1.1.3
|
||||
>=x11-libs/libXext-1.1.1
|
||||
>=x11-libs/libXi-1.1.3
|
||||
>=x11-libs/libXrender-0.9.4
|
||||
>=x11-libs/libXtst-1.0.3
|
||||
x11-libs/libXcomposite"
|
||||
X_DEPEND="
|
||||
x11-base/xorg-proto
|
||||
>=x11-libs/libXau-1.0.3
|
||||
>=x11-libs/libXdmcp-1.0.2
|
||||
>=x11-libs/libXinerama-1.0.2"
|
||||
|
||||
# The Javascript requirement is obsolete; OpenJDK 8+ has Nashorn
|
||||
COMMON_DEP="
|
||||
>=dev-libs/glib-2.26:2=
|
||||
>=dev-util/systemtap-1
|
||||
media-libs/fontconfig:1.0=
|
||||
>=media-libs/freetype-2.5.3:2=
|
||||
>=sys-libs/zlib-1.2.3
|
||||
virtual/jpeg:0=
|
||||
kerberos? ( virtual/krb5 )
|
||||
sctp? ( net-misc/lksctp-tools )
|
||||
smartcard? ( sys-apps/pcsc-lite )
|
||||
system-lcms? ( >=media-libs/lcms-2.9:2= )"
|
||||
|
||||
# Gtk+ will move to COMMON_DEP in time; PR1982
|
||||
# gsettings-desktop-schemas will be needed for native proxy support; PR1976
|
||||
RDEPEND="${COMMON_DEP}
|
||||
!dev-java/icedtea:0
|
||||
!dev-java/icedtea-web:7
|
||||
>=gnome-base/gsettings-desktop-schemas-3.12.2
|
||||
virtual/ttf-fonts
|
||||
alsa? ( ${ALSA_COMMON_DEP} )
|
||||
cups? ( ${CUPS_COMMON_DEP} )
|
||||
gtk? (
|
||||
>=dev-libs/atk-1.30.0
|
||||
>=x11-libs/cairo-1.8.8
|
||||
x11-libs/gdk-pixbuf:2
|
||||
>=x11-libs/gtk+-2.8:2
|
||||
>=x11-libs/pango-1.24.5
|
||||
)
|
||||
!headless-awt? ( ${X_COMMON_DEP} )
|
||||
selinux? ( sec-policy/selinux-java )"
|
||||
|
||||
# ca-certificates, perl and openssl are used for the cacerts keystore generation
|
||||
# perl is needed for running the SystemTap tests and the bootstrap javac
|
||||
# lsb-release is used to obtain distro information for the version & crash dump output
|
||||
# attr is needed for xattr.h which defines the extended attribute syscalls used by NIO2
|
||||
# x11-libs/libXt is needed for headers only (Intrinsic.h, IntrinsicP.h, Shell.h, StringDefs.h)
|
||||
# Ant is no longer needed under the new build system
|
||||
DEPEND="${COMMON_DEP} ${ALSA_COMMON_DEP} ${CUPS_COMMON_DEP} ${X_COMMON_DEP} ${X_DEPEND}
|
||||
|| (
|
||||
dev-java/icedtea-bin:8
|
||||
dev-java/icedtea:8
|
||||
dev-java/openjdk:8
|
||||
dev-java/openjdk-bin:8
|
||||
)
|
||||
app-arch/cpio
|
||||
app-arch/unzip
|
||||
app-arch/zip
|
||||
app-misc/ca-certificates
|
||||
dev-lang/perl
|
||||
!libressl? ( dev-libs/openssl:0 )
|
||||
libressl? ( dev-libs/libressl:0 )
|
||||
sys-apps/attr
|
||||
sys-apps/lsb-release
|
||||
x11-libs/libXt
|
||||
virtual/pkgconfig
|
||||
pax_kernel? ( sys-apps/elfix )"
|
||||
|
||||
PDEPEND="webstart? ( >=dev-java/icedtea-web-1.6.1:0 )
|
||||
nsplugin? ( >=dev-java/icedtea-web-1.6.1:0[nsplugin] )
|
||||
pulseaudio? ( dev-java/icedtea-sound )"
|
||||
|
||||
S="${WORKDIR}"/${ICEDTEA_PKG}
|
||||
|
||||
icedtea_check_requirements() {
|
||||
local CHECKREQS_DISK_BUILD
|
||||
|
||||
if use doc; then
|
||||
CHECKREQS_DISK_BUILD="9000M"
|
||||
else
|
||||
CHECKREQS_DISK_BUILD="8500M"
|
||||
fi
|
||||
|
||||
check-reqs_pkg_${EBUILD_PHASE}
|
||||
}
|
||||
|
||||
pkg_pretend() {
|
||||
icedtea_check_requirements
|
||||
}
|
||||
|
||||
pkg_setup() {
|
||||
icedtea_check_requirements
|
||||
|
||||
JAVA_PKG_WANT_BUILD_VM="
|
||||
icedtea-8 icedtea-bin-8
|
||||
openjdk-8 openjdk-bin-8"
|
||||
JAVA_PKG_WANT_SOURCE="1.5"
|
||||
JAVA_PKG_WANT_TARGET="1.5"
|
||||
|
||||
java-vm-2_pkg_setup
|
||||
java-pkg-2_pkg_setup
|
||||
}
|
||||
|
||||
src_unpack() {
|
||||
unpack ${SRC_PKG}
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
# For bootstrap builds as the sandbox control file might not yet exist.
|
||||
addpredict /proc/self/coredump_filter
|
||||
|
||||
# icedtea doesn't like some locales. #330433 #389717
|
||||
export LANG="C" LC_ALL="C"
|
||||
|
||||
local cacao_config config hotspot_port hs_config jamvm_config use_cacao use_jamvm use_zero zero_config
|
||||
local vm=$(java-pkg_get-current-vm)
|
||||
|
||||
# gcj-jdk ensures ecj is present.
|
||||
if use jbootstrap || has "${vm}" gcj-jdk; then
|
||||
use jbootstrap || einfo "bootstrap is necessary when building with ${vm}, ignoring USE=\"-jbootstrap\""
|
||||
config+=" --enable-bootstrap"
|
||||
else
|
||||
config+=" --disable-bootstrap"
|
||||
fi
|
||||
|
||||
# Use Zero if requested
|
||||
if use zero; then
|
||||
use_zero="yes"
|
||||
fi
|
||||
|
||||
# Use JamVM if requested
|
||||
if use jamvm; then
|
||||
use_jamvm="yes"
|
||||
fi
|
||||
|
||||
# Use CACAO if requested
|
||||
if use cacao; then
|
||||
use_cacao="yes"
|
||||
fi
|
||||
|
||||
# Are we on a architecture with a HotSpot port?
|
||||
# In-tree JIT ports are available for amd64, arm, arm64, ppc64 (be&le), SPARC and x86.
|
||||
if { use amd64 || use arm || use arm64 || use ppc64 || use sparc || use x86; }; then
|
||||
hotspot_port="yes"
|
||||
# Work around stack alignment issue, bug #647954.
|
||||
use x86 && append-flags -mincoming-stack-boundary=2
|
||||
fi
|
||||
|
||||
# Always use HotSpot as the primary VM if available. #389521 #368669 #357633 ...
|
||||
# Otherwise use Zero for now until alternate VMs are working
|
||||
if test "x${hotspot_port}" != "xyes"; then
|
||||
use_zero="yes"
|
||||
fi
|
||||
|
||||
if use shenandoah; then
|
||||
if { use amd64 || use arm64; }; then
|
||||
hs_config="--with-hotspot-build=shenandoah"
|
||||
hs_config+=" --with-hotspot-src-zip="${DISTDIR}/${SHENANDOAH_GENTOO_TARBALL}""
|
||||
else
|
||||
eerror "Shenandoah is only supported on arm64 and x86_64. Please re-build with USE="-shenandoah""
|
||||
fi
|
||||
else
|
||||
if use arm ; then
|
||||
hs_config="--with-hotspot-src-zip="${DISTDIR}/${AARCH32_GENTOO_TARBALL}""
|
||||
else
|
||||
hs_config="--with-hotspot-src-zip="${DISTDIR}/${HOTSPOT_GENTOO_TARBALL}""
|
||||
fi
|
||||
fi
|
||||
|
||||
# Turn on JamVM if needed (non-HS archs) or requested
|
||||
if test "x${use_jamvm}" = "xyes"; then
|
||||
if test "x${hotspot_port}" = "xyes"; then
|
||||
ewarn 'Enabling JamVM on an architecture with HotSpot support; issues may result.'
|
||||
ewarn 'If so, please rebuild with USE="-jamvm"'
|
||||
fi
|
||||
ewarn 'JamVM is known to still have issues with IcedTea 3.x; please rebuild with USE="-jamvm"'
|
||||
jamvm_config="--enable-jamvm"
|
||||
fi
|
||||
|
||||
# Turn on CACAO if needed (non-HS archs) or requested
|
||||
if test "x${use_cacao}" = "xyes"; then
|
||||
if test "x${hotspot_port}" = "xyes"; then
|
||||
ewarn 'Enabling CACAO on an architecture with HotSpot support; issues may result.'
|
||||
ewarn 'If so, please rebuild with USE="-cacao"'
|
||||
fi
|
||||
ewarn 'CACAO is known to still have issues with IcedTea 3.x; please rebuild with USE="-cacao"'
|
||||
cacao_config="--enable-cacao"
|
||||
fi
|
||||
|
||||
# Turn on Zero if needed (non-HS/CACAO archs) or requested
|
||||
if test "x${use_zero}" = "xyes"; then
|
||||
if test "x${hotspot_port}" = "xyes"; then
|
||||
ewarn 'Enabling Zero on an architecture with HotSpot support; performance will be significantly reduced.'
|
||||
fi
|
||||
zero_config="--enable-zero"
|
||||
fi
|
||||
|
||||
# PaX breaks pch, bug #601016
|
||||
if use pch && ! host-is-pax; then
|
||||
config+=" --enable-precompiled-headers"
|
||||
else
|
||||
config+=" --disable-precompiled-headers"
|
||||
fi
|
||||
|
||||
config+=" --with-parallel-jobs=$(makeopts_jobs)"
|
||||
|
||||
unset JAVA_HOME JDK_HOME CLASSPATH JAVAC JAVACFLAGS
|
||||
|
||||
econf ${config} \
|
||||
--with-openjdk-src-zip="${DISTDIR}/${OPENJDK_GENTOO_TARBALL}" \
|
||||
--with-corba-src-zip="${DISTDIR}/${CORBA_GENTOO_TARBALL}" \
|
||||
--with-jaxp-src-zip="${DISTDIR}/${JAXP_GENTOO_TARBALL}" \
|
||||
--with-jaxws-src-zip="${DISTDIR}/${JAXWS_GENTOO_TARBALL}" \
|
||||
--with-jdk-src-zip="${DISTDIR}/${JDK_GENTOO_TARBALL}" \
|
||||
--with-langtools-src-zip="${DISTDIR}/${LANGTOOLS_GENTOO_TARBALL}" \
|
||||
--with-nashorn-src-zip="${DISTDIR}/${NASHORN_GENTOO_TARBALL}" \
|
||||
--with-cacao-src-zip="${DISTDIR}/${CACAO_GENTOO_TARBALL}" \
|
||||
--with-jamvm-src-zip="${DISTDIR}/${JAMVM_GENTOO_TARBALL}" \
|
||||
--with-jdk-home="$(java-config -O)" \
|
||||
--prefix="${EPREFIX}/usr/$(get_libdir)/icedtea${SLOT}" \
|
||||
--mandir="${EPREFIX}/usr/$(get_libdir)/icedtea${SLOT}/man" \
|
||||
--docdir="${EPREFIX}/usr/share/doc/${PF}" \
|
||||
--htmldir="${EPREFIX}/usr/share/doc/${PF}/html" \
|
||||
--with-pkgversion="Gentoo ${PF}" \
|
||||
--disable-ccache \
|
||||
--disable-downloading --disable-Werror --disable-tests \
|
||||
--disable-systemtap-tests --enable-improved-font-rendering \
|
||||
--enable-system-jpeg --enable-system-zlib \
|
||||
$(use_enable headless-awt headless) \
|
||||
$(use_enable !headless-awt system-gif) \
|
||||
$(use_enable !headless-awt system-png) \
|
||||
$(use_enable doc docs) \
|
||||
$(use_enable kerberos system-kerberos) \
|
||||
$(use_enable system-lcms) \
|
||||
$(use_with pax_kernel pax "${EPREFIX}/usr/sbin/paxmark.sh") \
|
||||
$(use_enable sctp system-sctp) \
|
||||
$(use_enable smartcard system-pcsc) \
|
||||
${zero_config} ${cacao_config} ${jamvm_config} ${hs_config}
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
default
|
||||
}
|
||||
|
||||
src_test() {
|
||||
default
|
||||
}
|
||||
|
||||
src_install() {
|
||||
default
|
||||
|
||||
local dest="/usr/$(get_libdir)/icedtea${SLOT}"
|
||||
local ddest="${ED}${dest#/}"
|
||||
|
||||
if ! use alsa; then
|
||||
rm -v "${ddest}"/jre/lib/$(get_system_arch)/libjsoundalsa.* || die
|
||||
fi
|
||||
|
||||
if ! use examples; then
|
||||
rm -r "${ddest}"/demo "${ddest}"/sample || die
|
||||
fi
|
||||
|
||||
if ! use source; then
|
||||
rm -v "${ddest}"/src.zip || die
|
||||
fi
|
||||
|
||||
dosym /usr/share/doc/${PF} /usr/share/doc/${PN}${SLOT}
|
||||
|
||||
# Fix the permissions.
|
||||
find "${ddest}" \! -type l \( -perm /111 -exec chmod 755 {} \; -o -exec chmod 644 {} \; \) || die
|
||||
|
||||
dosym "${EPREFIX}"/etc/ssl/certs/java/cacerts "${dest}"/jre/lib/security/cacerts
|
||||
|
||||
java-vm_install-env "${FILESDIR}/icedtea.env.sh"
|
||||
java-vm_sandbox-predict /proc/self/coredump_filter
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
xdg_icon_cache_update
|
||||
java-vm-2_pkg_postinst
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
xdg_icon_cache_update
|
||||
java-vm-2_pkg_postrm
|
||||
}
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,2 +1 @@
|
||||
DIST python-axolotl-0.1.42.tar.gz 53869 BLAKE2B 045d19b38478404b19717daee431a4fc36d187dc511d42ee950b37ef257d98aaee8ba42633888d596265c0d64bfc33f2da9307d45feb4189ec04c03d69687108 SHA512 db9e1cfab87d690619a672b1782942a18b12b17af555959c17bcc3e2581e9c689c57becc0ea884a1129df9dace17684ba03de38b81f8c8c65cab27962ebdb6c5
|
||||
DIST python-axolotl-0.2.3.tar.gz 52139 BLAKE2B 8539f4ff6d9d7e57965cdbbd510f499cf344490091fe56b013d1ab60986092ac8a7a76248624993692077020043ea21c1d9448ecf9b76a698b43da4e014f37ab SHA512 1a10dc9df2f95d19b49909d4d136b5266aae19e24ac84f8b263ae7d4de18f77353c737616ac0648b600e05699a90d348f95c6c1659849986becefb4a0277fc80
|
||||
|
@ -1,28 +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
|
||||
|
||||
DESCRIPTION="A python module for the axolotl protocol"
|
||||
HOMEPAGE="https://github.com/tgalal/python-axolotl"
|
||||
SRC_URI="https://github.com/tgalal/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
|
||||
|
||||
LICENSE="GPL-3"
|
||||
SLOT="0"
|
||||
KEYWORDS="amd64 x86"
|
||||
|
||||
RDEPEND="
|
||||
dev-python/cryptography[${PYTHON_USEDEP}]
|
||||
dev-python/protobuf-python[${PYTHON_USEDEP}]
|
||||
dev-python/python-axolotl-curve25519[${PYTHON_USEDEP}]
|
||||
"
|
||||
DEPEND="${RDEPEND}"
|
||||
BDEPEND="dev-python/setuptools[${PYTHON_USEDEP}]"
|
||||
|
||||
python_test() {
|
||||
esetup.py test
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in new issue