2 # This file and its contents are supplied under the terms of the
3 # Common Development and Distribution License ("CDDL"). You may
4 # only use this file in accordance with the terms of the CDDL.
6 # A full copy of the text of the CDDL should have accompanied this
7 # source. A copy of the CDDL is also available via the Internet at
8 # http://www.illumos.org/license/CDDL.
12 # Copyright 2012-2013, EveryCity Ltd. All rights reserved.
13 # Copyright 2019 Alexander Pyhalov
14 # Copyright 2019 Michal Nowak
15 # Copyright 2021 Gary Mills
16 # Copyright 2022 Marco van Wieringen
17 # Copyright 2023 Andreas Wacknitz
22 USE_PARALLEL_BUILD
= yes
23 include ..
/..
/..
/make-rules
/shared-macros.mk
25 COMPONENT_NAME
= postgresql
26 COMPONENT_VERSION_MAJOR
= 16
27 COMPONENT_VERSION
= $(COMPONENT_VERSION_MAJOR
).4
28 COMPONENT_SRC
= $(COMPONENT_NAME
)-$(COMPONENT_VERSION
)
29 COMPONENT_ARCHIVE
= $(COMPONENT_SRC
).
tar.bz2
30 COMPONENT_ARCHIVE_HASH
= sha256
:971766d645aa73e93b9ef4e3be44201b4f45b5477095b049125403f9f3386d6f
31 COMPONENT_ARCHIVE_URL
= https
://ftp.postgresql.org
/pub
/source
/v
$(COMPONENT_VERSION
)/$(COMPONENT_ARCHIVE
)
32 COMPONENT_PROJECT_URL
= https
://www.postgresql.org
33 COMPONENT_FMRI
= database
/postgres-
$(COMPONENT_VERSION_MAJOR
)
34 COMPONENT_CLASSIFICATION
= System
/Databases
35 COMPONENT_LICENSE
= Postgresql
36 COMPONENT_LICENSE_FILE
= COPYRIGHT
38 TEST_TARGET
= $(TEST_64
)
39 include $(WS_MAKE_RULES
)/common.mk
41 # Missing files in build dir for configure without this.
42 COMPONENT_PRE_CONFIGURE_ACTION
= ( $(CLONEY
) $(SOURCE_DIR
) $(@D
) )
44 CONFIGURE_SCRIPT
= $(@D
)/configure
46 CONFIGURE_OPTIONS
= --prefix=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)
47 CONFIGURE_OPTIONS
+= --exec-prefix
=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)
48 CONFIGURE_OPTIONS
+= --datadir=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/share
49 CONFIGURE_OPTIONS
+= --sysconfdir
=/etc
/postgres
/$(COMPONENT_VERSION_MAJOR
)
50 CONFIGURE_OPTIONS
+= --mandir=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/man
51 CONFIGURE_OPTIONS
+= --includedir=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/include
52 CONFIGURE_OPTIONS
+= --sharedstatedir
=/var
/postgres
/$(COMPONENT_VERSION_MAJOR
)
53 CONFIGURE_OPTIONS
+= --localstatedir
=/var
/postgres
/$(COMPONENT_VERSION_MAJOR
)
54 CONFIGURE_OPTIONS
+= --localedir
=/usr
/share
/locale
55 CONFIGURE_OPTIONS
+= --docdir
=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/doc
56 CONFIGURE_OPTIONS
+= --htmldir
=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/doc
57 CONFIGURE_OPTIONS
+= --enable-nls
58 CONFIGURE_OPTIONS
+= --with-system-tzdata
=/usr
/share
/lib
/zoneinfo
59 CONFIGURE_OPTIONS
.64 += --with-tcl
60 CONFIGURE_OPTIONS
.64 += --with-python
61 CONFIGURE_OPTIONS
.64 += --with-pam
62 CONFIGURE_OPTIONS
+= --with-ssl
=openssl
63 CONFIGURE_OPTIONS
+= --with-libedit-preferred
64 CONFIGURE_OPTIONS
+= --with-libxml
65 CONFIGURE_OPTIONS
.64 += --with-libxslt
66 CONFIGURE_OPTIONS
+= --with-lz4
67 # We don't have gss_store_cred_into() which is part of heimdal since 2018:
68 #CONFIGURE_OPTIONS += --with-gssapi
69 CONFIGURE_OPTIONS
+= --enable-thread-safety
70 CONFIGURE_OPTIONS
+= --enable-dtrace
71 CONFIGURE_OPTIONS
+= --enable-integer-datetimes
72 CONFIGURE_OPTIONS
+= --with-includes
=/usr
/include
73 CONFIGURE_OPTIONS
+= --with-tclconfig
=/usr
/lib
74 CONFIGURE_OPTIONS
.64 += --with-perl
75 CONFIGURE_OPTIONS
+= --with-uuid
=e2fs
77 CONFIGURE_OPTIONS
.32 += --bindir=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/bin
/$(MACH32
)
78 CONFIGURE_OPTIONS
.32 += --libexecdir
=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/bin
/$(MACH32
)
79 CONFIGURE_OPTIONS
.32 += --sbindir
=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/bin
/$(MACH32
)
80 CONFIGURE_OPTIONS
.32 += --libdir=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/lib
81 CONFIGURE_OPTIONS
.32 += LDFLAGS
=-L
$(OPENSSL_PREFIX
)/lib
83 CONFIGURE_OPTIONS
.64 += --bindir=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/bin
84 CONFIGURE_OPTIONS
.64 += --libexecdir
=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/bin
85 CONFIGURE_OPTIONS
.64 += --sbindir
=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/bin
86 CONFIGURE_OPTIONS
.64 += --libdir=/usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/lib
/$(MACH64
)
87 CONFIGURE_OPTIONS
.64 += LDFLAGS
=-L
$(OPENSSL_PREFIX
)/lib
/$(MACH64
)
89 CONFIGURE_OPTIONS
+= CPPFLAGS
=-I
$(OPENSSL_PREFIX
)/include
91 CONFIGURE_OPTIONS
+= $(CONFIGURE_OPTIONS.
$(BITS
))
93 CONFIGURE_ENV
+= PYTHON
=$(PYTHON
)
94 CONFIGURE_ENV
+= PERL
=$(PERL
)
96 COMPONENT_BUILD_ENV
+= MAKELEVEL
=0
97 COMPONENT_BUILD_ENV
+= PATH
=$(PATH
)
98 COMPONENT_INSTALL_ENV
+= PATH
=$(PATH
)
100 COMPONENT_BUILD_TARGETS
= world
101 COMPONENT_INSTALL_TARGETS
= install-world
103 COMPONENT_POST_INSTALL_ACTION
.64= cd
$(BUILD_DIR_
$(BITS
))/src
/test/regress
; env
$(COMPONENT_INSTALL_ENV
) gmake
$(COMPONENT_INSTALL_ARGS
) install-lib install-tests
;
105 COMPONENT_POST_INSTALL_ACTION
+= $(COMPONENT_POST_INSTALL_ACTION.
$(BITS
))
106 COMPONENT_POST_INSTALL_ACTION
+= cd
$(PROTO_DIR
) && \
107 $(MV
) usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/include/pg_config.h usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/include/pg_config-
$(BITS
).h
&& \
108 $(MV
) usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/include/server
/pg_config.h usr
/postgres
/$(COMPONENT_VERSION_MAJOR
)/include/server
/pg_config-
$(BITS
).h
112 COMPONENT_TEST_ENV
+= PATH
=$(PATH
)
114 COMPONENT_TEST_TRANSFORMS
= \
116 '-e "s:[ \t]*[0-9]* ms::"' \
121 # Auto-generated dependencies
122 PERL_REQUIRED_PACKAGES
+= runtime
/perl
123 PYTHON_REQUIRED_PACKAGES
+= runtime
/python
124 REQUIRED_PACKAGES
+= $(ICU_LIBRARY_PKG
)
125 REQUIRED_PACKAGES
+= $(OPENSSL_PKG
)
126 REQUIRED_PACKAGES
+= SUNWcs
127 REQUIRED_PACKAGES
+= database
/postgres-common
128 REQUIRED_PACKAGES
+= library
/libedit
129 REQUIRED_PACKAGES
+= library
/libxml2
130 REQUIRED_PACKAGES
+= library
/libxslt
131 REQUIRED_PACKAGES
+= library
/lz4
132 REQUIRED_PACKAGES
+= library
/zlib
133 REQUIRED_PACKAGES
+= runtime
/tcl-8
134 REQUIRED_PACKAGES
+= shell/ksh93
135 REQUIRED_PACKAGES
+= system
/library
136 REQUIRED_PACKAGES
+= system
/library
/math