summaryrefslogtreecommitdiff
path: root/dev-db/mysql-udf-base64
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-db/mysql-udf-base64
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-db/mysql-udf-base64')
-rw-r--r--dev-db/mysql-udf-base64/Manifest6
-rw-r--r--dev-db/mysql-udf-base64/files/mysql-udf-base64-signedness.patch29
-rw-r--r--dev-db/mysql-udf-base64/files/mysql-udf-base64.sql5
-rw-r--r--dev-db/mysql-udf-base64/metadata.xml5
-rw-r--r--dev-db/mysql-udf-base64/mysql-udf-base64-20010618.ebuild65
5 files changed, 110 insertions, 0 deletions
diff --git a/dev-db/mysql-udf-base64/Manifest b/dev-db/mysql-udf-base64/Manifest
new file mode 100644
index 000000000000..7151fd1aa582
--- /dev/null
+++ b/dev-db/mysql-udf-base64/Manifest
@@ -0,0 +1,6 @@
+AUX mysql-udf-base64-signedness.patch 879 BLAKE2B ed3876d8b314ef0030006afde8f3f3345b2fdff9f6b39cdb6e2173f585da326e64a2106b76696e94cdfb30ac0ad1cd46663809373ba431dcf6ecc19970671b77 SHA512 7bbd3c477feacecf2bcb8297e1ab482c5b67efbec8cc475627886d4bc48105ca31d32b49fa9ee0d7d0948d94d9d202a2d48c82ebf0e19dd2f3f3da1da362a7ba
+AUX mysql-udf-base64.sql 205 BLAKE2B 3f69177e24534c39886d3027715a50b4bfd4d15d672e8d42f678c2a183798b4d18db69befde4365d08ccab477fba8dcd8ffc617615965f096dd326dfc18c58e0 SHA512 d223b2dc206930a46c6c2c5311f4cbeb5757c7a66b5c5f345533e2d319dc6185eada25b98ef1d5b05c2b804c0f92f22e99b3a340a8b9bb332d8adc00585997d2
+DIST mysql-udf-base64-20010618.c 7106 BLAKE2B 3f295cb172a3a9c3ea89b8cc24b03d8cdc1113ec8df00777069c8fe892fa91df3b2dc8da4193acd74c69c61c3144c4f429fc8d54fbe7cc4f7caba3b10cabe76d SHA512 23d2d1da7481626ebdb8ca3e31d01ae17903ff431415c7bca6ab20e414dc8751ab105a73e55b66a380e0e11ac0fc949b79d5f3c34f3d353abc1a52627be45f86
+DIST mysql-udf-base64-20010618.readme 222 BLAKE2B d030fa20512cdc6a8efe32aa7e11af307016f49b433f76cc5b66d62a6b602d3198a5924cea4e3012395e8e243ee82a298d437415f5989b94bb6c14fc4da96066 SHA512 2e2a17d7d1f1435bda59c89529e38a4843be814de5cb0db57643f8feb99a59cadf1e518e2903c470cd5931a964541dc5cc5d1b7f9041e7ed49442c37f139b2aa
+EBUILD mysql-udf-base64-20010618.ebuild 1429 BLAKE2B 8b5a50219307fd4f49e7b7e43d0cbee7425e7d4971ed8aeda0b8434057f77666d16796e92e33e7016df46e3ce145d8129e41be087e9a5e2a13cc4152ef2fb576 SHA512 6ac0dd2e8128945f8d8ace8ae5c9227a2224fcd51513b4a52f24f238f75511b9ca1d5b1076807356ea36ac3c83157b7dea42fd6f856e4b25085028c7d49eabf3
+MISC metadata.xml 166 BLAKE2B c254f1fb642881aba57637be14fb0a89b10384f91a128feaec3a8c870d76efc2cbacb92caccc0dee2dd19a5ac5eaf8643080dafa05c4e2ac96a68568927e5afd SHA512 a56648c974a1d14dd4c18237532773c72057a13ab90c58b5da04f185e3c12a8bd8d5c21fb06053507f31766291a82dc7d87b34cd65fd94cfe2af7295c813ef84
diff --git a/dev-db/mysql-udf-base64/files/mysql-udf-base64-signedness.patch b/dev-db/mysql-udf-base64/files/mysql-udf-base64-signedness.patch
new file mode 100644
index 000000000000..5084a9dd0128
--- /dev/null
+++ b/dev-db/mysql-udf-base64/files/mysql-udf-base64-signedness.patch
@@ -0,0 +1,29 @@
+--- mysql-udf-base64.c.orig 2011-10-16 14:17:13.000000000 +0200
++++ mysql-udf-base64.c 2011-10-16 14:18:41.000000000 +0200
+@@ -49,7 +49,7 @@
+ #include <string.h>
+ #include <mysql/mysql.h>
+
+-static char base64_table[] =
++static const char base64_table[] =
+ { 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M',
+ 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z',
+ 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm',
+@@ -101,7 +101,7 @@
+ unsigned long len;
+
+ /* *is_null=0; */
+- current = args->args[0];
++ current = (unsigned char*) args->args[0];
+ len = args->lengths[0];
+
+ if (len <= 0 || args->arg_type[0] != STRING_RESULT )
+@@ -211,7 +211,7 @@
+ }
+ }
+
+- current = args->args[0];
++ current = (unsigned char*) args->args[0];
+ len = args->lengths[0];
+
+ if (len <= 0 || args->arg_type[0] != STRING_RESULT )
diff --git a/dev-db/mysql-udf-base64/files/mysql-udf-base64.sql b/dev-db/mysql-udf-base64/files/mysql-udf-base64.sql
new file mode 100644
index 000000000000..619d4b0013d2
--- /dev/null
+++ b/dev-db/mysql-udf-base64/files/mysql-udf-base64.sql
@@ -0,0 +1,5 @@
+drop function base64encode;
+drop function base64decode;
+
+create function base64encode returns string soname 'mysql_udf_base64.so';
+create function base64decode returns string soname 'mysql_udf_base64.so';
diff --git a/dev-db/mysql-udf-base64/metadata.xml b/dev-db/mysql-udf-base64/metadata.xml
new file mode 100644
index 000000000000..6f49eba8f496
--- /dev/null
+++ b/dev-db/mysql-udf-base64/metadata.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<!-- maintainer-needed -->
+</pkgmetadata>
diff --git a/dev-db/mysql-udf-base64/mysql-udf-base64-20010618.ebuild b/dev-db/mysql-udf-base64/mysql-udf-base64-20010618.ebuild
new file mode 100644
index 000000000000..a7b4b06a6907
--- /dev/null
+++ b/dev-db/mysql-udf-base64/mysql-udf-base64-20010618.ebuild
@@ -0,0 +1,65 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=4
+
+inherit eutils toolchain-funcs
+
+MY_PN="${PN//-/_}"
+
+DESCRIPTION="MySQL UDFs that provide base64 encode/decode"
+HOMEPAGE="http://mirrors.sohu.com/mysql/Contrib/Old-Versions/"
+SRC_URI="http://mirrors.sohu.com/mysql/Contrib/Old-Versions/${PN}.c -> ${P}.c
+ http://mirrors.sohu.com/mysql/Contrib/Old-Versions/${PN}.readme -> ${P}.readme"
+
+LICENSE="PHP-2.02"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND=">=virtual/mysql-5.1"
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}"
+
+# compile helper
+_compile() {
+ local CC="$(tc-getCC)"
+ echo "${CC} ${@}" && "${CC}" "${@}"
+}
+
+pkg_setup() {
+ MYSQL_PLUGINDIR="$(mysql_config --plugindir)"
+ MYSQL_INCLUDE="$(mysql_config --include)"
+}
+
+src_unpack() {
+ cp -f "${DISTDIR}/${P}.c" "${S}/${PN}.c"
+ cp -f "${DISTDIR}/${P}.readme" "${S}/${PN}.readme"
+}
+
+src_prepare() {
+ epatch "${FILESDIR}/${PN}-signedness.patch"
+}
+
+src_compile() {
+ _compile ${CFLAGS} -Wall -fPIC ${MYSQL_INCLUDE} \
+ -shared ${LDFLAGS} -o ${MY_PN}.so ${PN}.c
+}
+
+src_install() {
+ exeinto "${MYSQL_PLUGINDIR}"
+ doexe ${MY_PN}.so
+ newdoc ${PN}.readme README
+ newdoc "${FILESDIR}/${PN}.sql" ${MY_PN}.sql
+}
+
+pkg_postinst() {
+ elog
+ elog "Please have a look at the documentation, how to"
+ elog "enable/disable the UDF functions of ${PN}."
+ elog
+ elog "The documentation is located here:"
+ elog "/usr/share/doc/${PF}"
+ elog
+}