File indexing completed on 2025-01-05 05:12:56
0001 first: all 0002 0003 include ../Makefile.include 0004 0005 include ../libiconv/Makefile.include 0006 include ../gettext/Makefile.include 0007 0008 include Makefile.include 0009 0010 PRODUCT_NAME = postgresql 0011 PRODUCT_VERSION = 10.4 0012 PRODUCT_DIRNAME = $(PRODUCT_NAME)-$(PRODUCT_VERSION) 0013 PRODUCT_PORT_SUFFIX = $(TARGET_MACHINE) 0014 0015 PRODUCT_ARCHIVE = $(PRODUCT_NAME)-$(PRODUCT_VERSION).tar.gz 0016 PRODUCT_ARCHIVE_URL = https://ftp.postgresql.org/pub/source/v10.4/$(PRODUCT_ARCHIVE) 0017 PRODUCT_ARCHIVE_DIR = $(ARCHIVE_DIR) 0018 PRODUCT_ARCHIVE_PATH = $(PRODUCT_ARCHIVE_DIR)/$(PRODUCT_ARCHIVE) 0019 0020 PRODUCT_SOURCE_DIR = $(SOURCE_DIR)/$(PRODUCT_DIRNAME) 0021 0022 PRODUCT_PORT_DIR = $(PORT_DIR)/$(PRODUCT_DIRNAME)-$(PRODUCT_PORT_SUFFIX) 0023 0024 PRODUCT_BUILD_DIR = $(BUILD_DIR)/$(PRODUCT_DIRNAME)-$(PRODUCT_PORT_SUFFIX) 0025 0026 PRODUCT_INSTALL_DIR = $(POSTGRESQL_INSTALL_DIR) 0027 PRODUCT_INSTALL_INCLUDE_DIR = $(PRODUCT_INSTALL_DIR)/include 0028 PRODUCT_INSTALL_LIB_DIR = $(PRODUCT_INSTALL_DIR)/bin 0029 0030 PRODUCT_DEPLOY_DIR = $(POSTGRESQL_DEPLOY_DIR) 0031 PRODUCT_DEPLOY_INCLUDE_DIR = $(PRODUCT_DEPLOY_DIR)/include 0032 PRODUCT_DEPLOY_LIB_DIR = $(PRODUCT_DEPLOY_DIR)/lib 0033 0034 PRODUCT_CONFIGURE_TXT_PATH = $(BUILD_DIR)/$(PRODUCT_NAME)-$(PRODUCT_VERSION)-$(PRODUCT_PORT_SUFFIX).configure.txt 0035 PRODUCT_README_PORT_MD_PATH = $(PRODUCT_PORT_DIR)/README.$(PRODUCT_PORT_SUFFIX).md 0036 PRODUCT_BUILD_TXT_PATH = $(BUILD_DIR)/$(PRODUCT_NAME)-$(PRODUCT_VERSION)-$(PRODUCT_PORT_SUFFIX).build.txt 0037 0038 PRODUCT_INCLUDE_FILES = libpq server informix internal ecpg_config.h ecpg_informix.h ecpgerrno.h ecpglib.h ecpgtype.h libpq-events.h libpq-fe.h pg_config.h pg_config_ext.h pg_config_manual.h pg_config_os.h pgtypes_date.h pgtypes_error.h pgtypes_interval.h pgtypes_numeric.h pgtypes_timestamp.h postgres_ext.h sql3types.h sqlca.h sqlda-compat.h sqlda-native.h sqlda.h 0039 PRODUCT_INCLUDE_FILES_INSTALL := $(addprefix $(PRODUCT_INSTALL_INCLUDE_DIR)/, $(PRODUCT_INCLUDE_FILES)) 0040 PRODUCT_INCLUDE_FILES_DEPLOY := $(addprefix $(PRODUCT_DEPLOY_INCLUDE_DIR)/, $(PRODUCT_INCLUDE_FILES)) 0041 0042 PRODUCT_LIB_FILES = libpq.dll 0043 PRODUCT_LIB_FILES_INSTALL = $(addprefix $(PRODUCT_INSTALL_LIB_DIR)/, $(PRODUCT_LIB_FILES)) 0044 PRODUCT_LIB_FILES_DEPLOY = $(addprefix $(PRODUCT_DEPLOY_LIB_DIR)/, $(PRODUCT_LIB_FILES)) 0045 0046 PATH := $(GETTEXT_INSTALL_DIR)/bin:$(LIBICONV_INSTALL_DIR)/bin:$(PATH) 0047 0048 export PATH MAKE 0049 0050 include ../Makefile.phony 0051 0052 all: deploy 0053 0054 include ../Makefile.deploy 0055 0056 # Parallel install of gettext seems to cause conflicting access to some files, so force a single job. 0057 buildinstall $(PRODUCT_LIB_FILES_INSTALL) $(PRODUCT_INCLUDE_FILES_INSTALL): $(PRODUCT_BUILD_TXT_PATH) | $(CD) $(MAKE) 0058 $(CD) $(PRODUCT_BUILD_DIR) && $(MAKE) -j 1 install 0059 0060 # Parallel build freezes for some reason, so disable it. 0061 build $(PRODUCT_BUILD_TXT_PATH): $(PRODUCT_BUILD_DIR)/GNUmakefile | $(CD) $(MAKE) $(TEE) $(CMD) $(PERL) 0062 $(CD) $(PRODUCT_BUILD_DIR) && $(MAKE) -j 1 2>&1 | $(TEE) $(PRODUCT_BUILD_TXT_PATH) 0063 0064 #<recipes-i686-mingw32-postgresql-1.workaround target="PostgreSQL" cause="gettext"> 0065 # Normally PostgreSQL would be configured with `--enable-nls` option. The 0066 # problem is, despite enabling thread-safety, which is confirmed by 0067 # PQisthreadsafe() returning 1, it comes out _libpq_ (and possibly other 0068 # libraries) is not thread-safe because of _gettext_. Enabling NLS causes 0069 # crashes, when multiple threads try to open a connection in parallel. 0070 buildconfigure $(PRODUCT_BUILD_DIR)/GNUmakefile: $(PRODUCT_BUILD_DIR)/configure \ 0071 $(LIBICONV_INSTALL_DIR) \ 0072 $(GETTEXT_INSTALL_DIR) | $(CD) $(SH) $(TEE) $(AWK) $(SED) $(CMD) $(PERL) 0073 $(CD) $(PRODUCT_BUILD_DIR) && $(SH) configure --host=$(HOST_MACHINE) --build=$(BUILD_MACHINE) \ 0074 --prefix=$(PRODUCT_INSTALL_DIR) \ 0075 --sysconfdir=/etc \ 0076 --localedir=/share/locale \ 0077 --enable-thread-safety \ 0078 --with-libraries=$(LIBICONV_INSTALL_DIR)/lib:$(GETTEXT_INSTALL_DIR)/lib \ 0079 --with-includes=$(LIBICONV_INSTALL_DIR)/include:$(GETTEXT_INSTALL_DIR)/include \ 0080 --disable-rpath \ 0081 2>&1 | $(TEE) $(PRODUCT_CONFIGURE_TXT_PATH) 0082 #</recipes-i686-mingw32-postgresql-1.workaround> 0083 0084 include ../Makefile.builddir 0085 0086 include ../Makefile.port 0087 0088 include ../Makefile.portdir 0089 0090 include ../Makefile.sourcedir 0091 0092 include ../Makefile.archive 0093 0094 include ../Makefile.clean 0095