Andreas Wacknitz
2023-12-02 8f13bb596138ef6b7f8dccde1bc1c489c6a895cf
add mysql_fdw for Postgresql-15

5 files added
141 ■■■■■ changed files
components/database/postgresql-15-mysql_fdw/Makefile 51 ●●●●● patch | view | raw | blame | history
components/database/postgresql-15-mysql_fdw/manifests/sample-manifest.p5m 33 ●●●●● patch | view | raw | blame | history
components/database/postgresql-15-mysql_fdw/mysql_fdw.p5m 35 ●●●●● patch | view | raw | blame | history
components/database/postgresql-15-mysql_fdw/patches/01-illumos.patch 11 ●●●●● patch | view | raw | blame | history
components/database/postgresql-15-mysql_fdw/pkg5 11 ●●●●● patch | view | raw | blame | history
components/database/postgresql-15-mysql_fdw/Makefile
New file
@@ -0,0 +1,51 @@
#
# This file and its contents are supplied under the terms of the
# Common Development and Distribution License ("CDDL"), version 1.0.
# You may only use this file in accordance with the terms of version
# 1.0 of the CDDL.
#
# A full copy of the text of the CDDL should have accompanied this
# source.  A copy of the CDDL is also available via the Internet at
# http://www.illumos.org/license/CDDL.
#
#
# Copyright 2023 Andreas Wacknitz
#
BUILD_BITS= 64
BUILD_STYLE= justmake
include ../../../make-rules/shared-macros.mk
COMPONENT_NAME=    mysql_fdw
COMPONENT_VERSION=    2.9.1
HUMAN_VERSION=    REL-2_9_1
COMPONENT_SUMMARY=    MySQL Foreign Data Wrapper for PostgreSQL $(PG_VERSION)
COMPONENT_SRC=    $(COMPONENT_NAME)-$(HUMAN_VERSION)
COMPONENT_ARCHIVE=    $(COMPONENT_NAME)-$(HUMAN_VERSION).tar.gz
COMPONENT_PROJECT_URL=    https://github.com/EnterpriseDB/$(COMPONENT_NAME)
COMPONENT_ARCHIVE_URL=    $(COMPONENT_PROJECT_URL)/archive/refs/tags/$(HUMAN_VERSION).tar.gz
COMPONENT_ARCHIVE_HASH= sha256:26e8dc2012de6151450fbf2a5cd591a3d5b8a52b1e3ec0600b14a4a6b4a06b54
COMPONENT_FMRI=    database/postgres-$(PG_VERNUM)/mysql_fdw
COMPONENT_CLASSIFICATION=    System/Databases
COMPONENT_LICENSE=    MIT
COMPONENT_LICENSE_FILE=    LICENSE
PG_VERSION=    15
# Don't depend on host default pg_config
PATH= $(PG_HOME)/bin:$(MYSQL_BINDIR.$(BITS)):/usr/sbin:/usr/bin
TEST_TARGET= $(NO_TESTS)
include $(WS_MAKE_RULES)/common.mk
COMPONENT_BUILD_ENV   += USE_PGXS=1
COMPONENT_BUILD_ARGS  += MYSQL_LIBNAME=$(MYSQL_LIBDIR)/libmysqlclient.so
COMPONENT_INSTALL_ENV += USE_PGXS=1
# Manually added build dependencies
REQUIRED_PACKAGES += $(PG_DEVELOPER_PKG)
REQUIRED_PACKAGES += $(MYSQL_LIBRARY_PKG)
# Auto-generated dependencies
REQUIRED_PACKAGES += system/library
components/database/postgresql-15-mysql_fdw/manifests/sample-manifest.p5m
New file
@@ -0,0 +1,33 @@
#
# This file and its contents are supplied under the terms of the
# Common Development and Distribution License ("CDDL"), version 1.0.
# You may only use this file in accordance with the terms of version
# 1.0 of the CDDL.
#
# A full copy of the text of the CDDL should have accompanied this
# source.  A copy of the CDDL is also available via the Internet at
# http://www.illumos.org/license/CDDL.
#
#
# Copyright 2023 <contributor>
#
set name=pkg.fmri value=pkg:/$(COMPONENT_FMRI)@$(IPS_COMPONENT_VERSION),$(BUILD_VERSION)
set name=pkg.human-version value=$(HUMAN_VERSION)
set name=pkg.summary value="$(COMPONENT_SUMMARY)"
set name=info.classification value="$(COMPONENT_CLASSIFICATION)"
set name=info.upstream-url value=$(COMPONENT_PROJECT_URL)
set name=info.source-url value=$(COMPONENT_ARCHIVE_URL)
set name=org.opensolaris.consolidation value=$(CONSOLIDATION)
license $(COMPONENT_LICENSE_FILE) license='$(COMPONENT_LICENSE)'
file path=usr/postgres/15/lib/$(MACH64)/mysql_fdw.so
file path=usr/postgres/15/share/extension/mysql_fdw--1.0--1.1.sql
file path=usr/postgres/15/share/extension/mysql_fdw--1.0.sql
file path=usr/postgres/15/share/extension/mysql_fdw--1.1--1.2.sql
file path=usr/postgres/15/share/extension/mysql_fdw--1.1.sql
file path=usr/postgres/15/share/extension/mysql_fdw--1.2.sql
file path=usr/postgres/15/share/extension/mysql_fdw.control
file path=usr/postgres/15/share/extension/mysql_fdw_pushdown.config
components/database/postgresql-15-mysql_fdw/mysql_fdw.p5m
New file
@@ -0,0 +1,35 @@
#
# This file and its contents are supplied under the terms of the
# Common Development and Distribution License ("CDDL"), version 1.0.
# You may only use this file in accordance with the terms of version
# 1.0 of the CDDL.
#
# A full copy of the text of the CDDL should have accompanied this
# source.  A copy of the CDDL is also available via the Internet at
# http://www.illumos.org/license/CDDL.
#
#
# Copyright 2023 Andreas Wacknitz
#
set name=pkg.fmri value=pkg:/$(COMPONENT_FMRI)@$(IPS_COMPONENT_VERSION),$(BUILD_VERSION)
set name=pkg.human-version value=$(HUMAN_VERSION)
set name=pkg.summary value="$(COMPONENT_SUMMARY)"
set name=info.classification value="$(COMPONENT_CLASSIFICATION)"
set name=info.upstream-url value=$(COMPONENT_PROJECT_URL)
set name=info.source-url value=$(COMPONENT_ARCHIVE_URL)
set name=org.opensolaris.consolidation value=$(CONSOLIDATION)
license $(COMPONENT_LICENSE_FILE) license='$(COMPONENT_LICENSE)'
depend type=require fmri=database/mariadb-106/library
file path=usr/postgres/15/lib/$(MACH64)/mysql_fdw.so
file path=usr/postgres/15/share/extension/mysql_fdw--1.0--1.1.sql
file path=usr/postgres/15/share/extension/mysql_fdw--1.0.sql
file path=usr/postgres/15/share/extension/mysql_fdw--1.1--1.2.sql
file path=usr/postgres/15/share/extension/mysql_fdw--1.1.sql
file path=usr/postgres/15/share/extension/mysql_fdw--1.2.sql
file path=usr/postgres/15/share/extension/mysql_fdw.control
file path=usr/postgres/15/share/extension/mysql_fdw_pushdown.config
components/database/postgresql-15-mysql_fdw/patches/01-illumos.patch
New file
@@ -0,0 +1,11 @@
--- mysql_fdw-REL-2_9_1/mysql_fdw.c.orig    2023-07-14 12:00:14.000000000 +0200
+++ mysql_fdw-REL-2_9_1/mysql_fdw.c    2023-12-02 20:31:58.742207075 +0100
@@ -385,7 +385,7 @@
 bool
 mysql_load_library(void)
 {
-#if defined(__APPLE__) || defined(__FreeBSD__)
+#if defined(__APPLE__) || defined(__FreeBSD__) || defined(__illumos__)
     /*
      * Mac OS/BSD does not support RTLD_DEEPBIND, but it still works without
      * the RTLD_DEEPBIND
components/database/postgresql-15-mysql_fdw/pkg5
New file
@@ -0,0 +1,11 @@
{
    "dependencies": [
        "database/mariadb-106/library",
        "database/postgres-15/developer",
        "system/library"
    ],
    "fmris": [
        "database/postgres-15/mysql_fdw"
    ],
    "name": "mysql_fdw"
}