Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update proxysql to 1.4.12 #40

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions proxysql/Makefile
Original file line number Diff line number Diff line change
@@ -1,18 +1,23 @@
# $NetBSD$

DISTNAME= proxysql-1.4.7
DISTNAME= proxysql-1.4.12
CATEGORIES= databases
MASTER_SITES= ${MASTER_SITE_GITHUB:=sysown/}
GITHUB_TAG= v${PKGVERSION_NOREV}

MAINTAINER= [email protected]
HOMEPAGE= http://www.proxysql.com/
HOMEPAGE= https://proxysql.com/
COMMENT= High-performance MySQL proxy
LICENSE= gnu-gpl-v3

GITHUB_TAG= v${PKGVERSION_NOREV}

WRKSRC= ${WRKDIR}/proxysql-1.4.12
USE_LANGUAGES= c c++ c99
USE_TOOLS+= gmake tar
USE_TOOLS+= gawk gmake tar

SMF_NAME= proxysql

BUILD_DEFS+= VARBASE
DEPENDS+= patch>=2.4:../../devel/patch

SUBST_CLASSES+= path
SUBST_STAGE.path= pre-configure
Expand Down Expand Up @@ -47,11 +52,6 @@ INSTALLATION_DIRS+= bin share/examples/proxysql
post-extract:
cd ${WRKSRC}/deps/mariadb-client-library && ${TAR} -xzf mariadb-connector-c-*.tar.gz

# Use embedded sources, because upstream applies custom patches:
#.include "../../databases/sqlite3/buildlink3.mk"
#.include "../../devel/jemalloc/buildlink3.mk"
#.include "../../devel/re2/buildlink3.mk"

.include "../../converters/libiconv/buildlink3.mk"
.include "../../devel/libconfig/buildlink3.mk"
.include "../../devel/libdaemon/buildlink3.mk"
Expand Down
24 changes: 12 additions & 12 deletions proxysql/distinfo
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
$NetBSD$

SHA1 (proxysql-1.4.7.tar.gz) = 67f7eb7e231bb9fbee3ff6a6e8548538374ff976
RMD160 (proxysql-1.4.7.tar.gz) = 3b023bce6c46d80852d92e2c1b19ba8a1bb30885
SHA512 (proxysql-1.4.7.tar.gz) = 3ea490d2ffbdabce3c2ae7fa37b6880feed1d7f250a506481642e7efe22a54b1b67b4e6b44f876d38fa721aabb1841afee7cc7b6d2a4606be341e43b3cd754ad
Size (proxysql-1.4.7.tar.gz) = 13013128 bytes
SHA1 (patch-Makefile) = f52d1e5be05fbf7a657b9f9bc5eaa4aba7e911dd
SHA1 (patch-deps_Makefile) = cd456f2943d33233f6504b55a98d4cf379ffb926
SHA1 (proxysql-1.4.12.tar.gz) = 1faeba1535e275c11fb372b6def0b065dd764a1f
RMD160 (proxysql-1.4.12.tar.gz) = 87222c3f7715fb4ceae27c2eaff4b81a8cf90d17
SHA512 (proxysql-1.4.12.tar.gz) = 41dfbbdb5e81137145e96b3499e62e55f6dd02270e01486237884ab88478ed32833b3fda907bb5f93185573936908f8ea7e105819d489bedd8106eacdbf22de4
Size (proxysql-1.4.12.tar.gz) = 13023826 bytes
SHA1 (patch-Makefile) = 5ffaf641c1e149a9654c4de800a25ac0f660987c
SHA1 (patch-deps_Makefile) = 2fee0f19c818935b0a4d278f3ecca75c1cce1cee
SHA1 (patch-deps_mariadb-client-library_mariadb-connector-c-2.3.1_cmake_CheckTypes.cmake) = 9abc7bb9cedccafd95cd7450568f89828a7fb384
SHA1 (patch-deps_mariadb-client-library_mariadb-connector-c-2.3.1_include_my__pthread.h) = 26b278f7d3ea8e4e5a0fecab60f333573f4ae7ee
SHA1 (patch-deps_mariadb-client-library_mariadb-connector-c-2.3.1_libmariadb_my__context.c) = 95494ea9a9a86d1ed25590a098d3ce09fcb6ce7b
SHA1 (patch-etc_proxysql.cnf) = 0f21cf41566ee62fdd765f28807162084f04de19
SHA1 (patch-include_MySQL__Data__Stream.h) = 27d7cf5e989e4d2c86ce35d015ae4a91f27e69da
SHA1 (patch-include_proxy__defines.h) = 92869e76dc6219ff0d5161d2e933d6bcf9fa81fd
SHA1 (patch-include_proxysql.h) = 96f33a5fa02112cae4d0c0626db70529eff66578
SHA1 (patch-lib_ProxySQL__GloVars.cpp) = e24a79cb0e2f7c00814581b62db643a303a26b0e
SHA1 (patch-src_Makefile) = c1bc76c608902e9ecf091e6b04e2efb05b057599
SHA1 (patch-etc_proxysql.cnf) = 7861c4cf01d6947eff890171fa202a8ee6c5a9fe
SHA1 (patch-include_MySQL__Data__Stream.h) = d02b5168e039219c9f3b54989cdd33fcee52fd6f
SHA1 (patch-include_proxy__defines.h) = 2298a748de8372d506304ae0415dcc419b9e11b7
SHA1 (patch-include_proxysql.h) = 00f7646af7cc3fdc400d66435ae0056688ca792a
SHA1 (patch-lib_ProxySQL__GloVars.cpp) = 2454b57a6557c0784d585dcba463ca5892a04520
SHA1 (patch-src_Makefile) = ecfdc8e928561eec1489c93856322ff1dc8218be
30 changes: 30 additions & 0 deletions proxysql/files/smf/manifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0"?>
<!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">
<service_bundle type="manifest" name="export">
<service name="@SMF_PREFIX@/@SMF_NAME@" type="service" version="1">
<create_default_instance enabled="false" />
<single_instance />
<dependency name="network" grouping="require_all" restart_on="none" type="service">
<service_fmri value="svc:/milestone/network:default" />
</dependency>
<dependency name="filesystem-local" grouping="require_all" restart_on="none" type="service">
<service_fmri value="svc:/system/filesystem/local:default" />
</dependency>
<method_context>
<method_environment>
<envvar name="PATH" value="@PREFIX@/bin:@PREFIX@/sbin:/usr/bin:/usr/sbin:/bin:/sbin"/>
</method_environment>
</method_context>
<exec_method type="method" name="start" exec="@PREFIX@/bin/proxysql" timeout_seconds="300" />
<exec_method type="method" name="stop" exec=":kill" timeout_seconds="60"/>
<exec_method type="method" name="refresh" exec="@PREFIX@/bin/proxysql --reload" timeout_seconds="60"/>
<template>
<common_name>
<loctext xml:lang="C">High-performance MySQL proxy</loctext>
</common_name>
<documentation>
<doc_link name="proxysql.com" uri="https://proxysql.com/" />
</documentation>
</template>
</service>
</service_bundle>
8 changes: 4 additions & 4 deletions proxysql/patches/patch-Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,17 @@ $NetBSD$

Sane installation.

--- Makefile.orig 2018-02-01 02:06:06.000000000 +0000
--- Makefile.orig 2018-09-21 20:55:57.000000000 +0000
+++ Makefile
@@ -12,7 +12,6 @@ DEBUG=${ALL_DEBUG}
#export EXTRALINK
CURVER?=1.4.7
CURVER?=1.4.12
MAKEOPT=-j 4
-DISTRO := $(shell gawk -F= '/^NAME/{print $$2}' /etc/os-release)
ifeq ($(wildcard /usr/lib/systemd/system), /usr/lib/systemd/system)
SYSTEMD=1
else
@@ -654,29 +653,8 @@ cleanall:
@@ -668,29 +667,8 @@ cleanall:
rm binaries/*rpm || true

install: src/proxysql
Expand Down Expand Up @@ -44,7 +44,7 @@ Sane installation.
.PHONY: install

uninstall:
@@ -705,7 +683,6 @@ ifeq ($(DISTRO),"Debian GNU/Linux")
@@ -719,7 +697,6 @@ ifeq ($(DISTRO),"Debian GNU/Linux")
endif
endif
endif
Expand Down
2 changes: 1 addition & 1 deletion proxysql/patches/patch-deps_Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ $NetBSD$
Only build that which comes with local patches.
Use portable sed calls.

--- deps/Makefile.orig 2018-02-01 02:06:06.000000000 +0000
--- deps/Makefile.orig 2018-09-21 20:55:57.000000000 +0000
+++ deps/Makefile
@@ -11,9 +11,9 @@ endif

Expand Down
8 changes: 4 additions & 4 deletions proxysql/patches/patch-etc_proxysql.cnf
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ $NetBSD$

Proper paths.

--- etc/proxysql.cnf.orig 2018-02-01 02:06:06.000000000 +0000
--- etc/proxysql.cnf.orig 2018-09-21 20:55:57.000000000 +0000
+++ etc/proxysql.cnf
@@ -6,7 +6,7 @@


@@ -31,7 +31,7 @@
#
########################################################################################

-datadir="/var/lib/proxysql"
+datadir="@VARBASE@/lib/proxysql"
Expand Down
2 changes: 1 addition & 1 deletion proxysql/patches/patch-include_MySQL__Data__Stream.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Sane symbol naming.

--- include/MySQL_Data_Stream.h.orig 2017-04-23 05:15:16.000000000 +0000
--- include/MySQL_Data_Stream.h.orig 2018-09-21 20:55:57.000000000 +0000
+++ include/MySQL_Data_Stream.h
@@ -15,7 +15,7 @@ typedef struct _queue_t {
unsigned int partial;
Expand Down
2 changes: 1 addition & 1 deletion proxysql/patches/patch-include_proxy__defines.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This should avoid epoll usage.

--- include/proxy_defines.h.orig 2017-04-23 05:15:16.000000000 +0000
--- include/proxy_defines.h.orig 2018-09-21 20:55:57.000000000 +0000
+++ include/proxy_defines.h
@@ -2,7 +2,7 @@
// If defined then active pthread mutex in ProxySQL_Admin else use the wrlock
Expand Down
2 changes: 1 addition & 1 deletion proxysql/patches/patch-include_proxysql.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Fix build on SunOS.

--- include/proxysql.h.orig 2017-04-23 05:15:16.000000000 +0000
--- include/proxysql.h.orig 2018-09-21 20:55:57.000000000 +0000
+++ include/proxysql.h
@@ -1,4 +1,5 @@
#ifdef __cplusplus
Expand Down
4 changes: 2 additions & 2 deletions proxysql/patches/patch-lib_ProxySQL__GloVars.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

Default paths.

--- lib/ProxySQL_GloVars.cpp.orig 2017-03-26 11:18:09.000000000 +0000
--- lib/ProxySQL_GloVars.cpp.orig 2018-09-21 20:55:57.000000000 +0000
+++ lib/ProxySQL_GloVars.cpp
@@ -166,9 +166,9 @@ void ProxySQL_GlobalVariables::process_o
@@ -200,9 +200,9 @@ void ProxySQL_GlobalVariables::process_o
if (Proxy_file_regular(config_file)==false) {
config_file=(char *)"proxysql.cfg";
if (Proxy_file_regular(config_file)==false) {
Expand Down
19 changes: 10 additions & 9 deletions proxysql/patches/patch-src_Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,18 @@ $NetBSD$

We use some pkgsrc deps.

--- src/Makefile.orig 2018-02-01 02:06:06.000000000 +0000
--- src/Makefile.orig 2018-09-21 20:55:57.000000000 +0000
+++ src/Makefile
@@ -43,6 +43,7 @@ MICROHTTPD_LDIR=$(MICROHTTPD_DIR)/microh
CURL_DIR=$(DEPS_PATH)/curl/curl/
CURL_IDIR=$(CURL_DIR)/include
CURL_LDIR=$(CURL_DIR)/lib/.libs
+CURL_LIBS := $(shell curl-config --libs)
@@ -56,12 +56,18 @@ endif

IDIR=../include
LDIR=../lib
@@ -68,9 +69,9 @@ MYCXXFLAGS=-std=c++11 $(IDIRS) $(OPTZ) $
MYCXXFLAGS=-std=c++11 $(IDIRS) $(OPTZ) $(DEBUG) $(PSQLCH)

+ifeq ($(UNAME_S),SunOS)
+ CURL_LIBS := $(shell curl-config --libs)
+else
+ CURL_LIBS := ""
+endif
+
LDFLAGS+=
NOJEMALLOC := $(shell echo $(NOJEMALLOC))
ifeq ($(NOJEMALLOC),1)
Expand Down