diff --git a/databases/firebird30-server/Makefile b/databases/firebird30-server/Makefile index a9765cd653cf..c8a7f2d0e647 100644 --- a/databases/firebird30-server/Makefile +++ b/databases/firebird30-server/Makefile @@ -1,201 +1,201 @@ PORTNAME= firebird PORTVERSION= 3.0.10 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES?= databases MASTER_SITES= https://github.com/FirebirdSQL/${PORTNAME}/releases/download/v${PORTVERSION}/ PKGNAMESUFFIX?= ${PORTVERSION:R:S/.//}-server DISTNAME= ${PORTNAME:S/f/F/}-${PORTVERSION}.33601-0 DIST_SUBDIR= ${PORTNAME} MAINTAINER= acm@FreeBSD.org COMMENT?= Firebird-3 relational database (server) WWW= https://www.firebirdsql.org/ LICENSE= IDPL IPL LICENSE_COMB= multi LICENSE_NAME_IDPL= Initial Developer's Public License LICENSE_NAME_IPL= InterBase Public License LICENSE_FILE_IDPL= ${WRKSRC}/builds/install/misc/IDPLicense.txt LICENSE_FILE_IPL= ${WRKSRC}/builds/install/misc/IPLicense.txt LICENSE_PERMS_IDPL= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept LICENSE_PERMS_IPL= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept LIB_DEPENDS= libicuuc.so:devel/icu \ libtommath.so:math/libtommath CONFLICTS_INSTALL= firebird25 firebird40 USES= cpe gmake pkgconfig localbase:ldflags libedit tar:bzip2 USE_CXXSTD= gnu++03 GNU_CONFIGURE= yes MAKE_JOBS_UNSAFE= yes CPE_VENDOR= firebirdsql CONFIGURE_ARGS= --prefix=${LOCALSTATEDIR} \ --exec-prefix=${PREFIX} \ --with-fbbin=${PREFIX}/bin \ --with-fblib=${PREFIX}/lib \ --with-fbconf=${PREFIX}/${CONFDIR} \ --with-fbglock=${LOCALSTATEDIR} \ --with-fbhelp=${LOCALSTATEDIR}/help \ --with-fbintl=${LIBEXECDIR}/intl \ --with-fblog=${LOCALSTATEDIR} \ --with-fbmsg=${DATADIR} \ --with-fbplugins=${LIBEXECDIR}/plugins \ --with-fbsbin=${PREFIX}/sbin \ --with-fbsecure-db=${LOCALSTATEDIR} \ --with-fbsample-db=${EXAMPLESDIR} \ --with-fbudf=${LIBEXECDIR}/UDF CONFIGURE_ENV+= PTHREAD_LIBS="-lpthread" \ ac_cv_header_atomic_ops_h="no" \ ac_cv_lib_atomic_ops_main="no" CPPFLAGS+= -DU_NOEXCEPT= -fno-delete-null-pointer-checks # For USE_CXXSTD=gnu++98 LOCALSTATEDIR= /var/db/firebird CONFDIR= etc/firebird LIBEXECDIR= ${PREFIX}/libexec/firebird PLIST_SUB= FIREBIRD_VERSION=${PORTVERSION} \ LOCALSTATEDIR="var/db/firebird" CONFDIR="${CONFDIR}" # Don't use ld for linking, use gcc LD= ${CC} # Don't strip binary files STRIP= ONLY_FOR_ARCHS= i386 amd64 # sparc64 fails due to lack of valid AtomicCounter implementation in # src/common/classes/fb_atomic.h; presumably other tier-2s would as well INSTALL_FB= ${INSTALL} ${COPY} .if !defined(CLIENT_ONLY) # Server part stuff USES+= firebird:3.0 CONFIGURE_ARGS+=--without-editline USE_RC_SUBR= firebird SUB_FILES= pkg-message UTIL_SBIN= fbguard firebird UTIL_BIN= fb_lock_print fbsplit fbstat fbsvcmgr fbtracemgr gbak gfix gsec \ nbackup UDF_SO= ib_udf.so fbudf.so UDF_SQL= ib_udf.sql ib_udf2.sql fbudf.sql PLUGIN_SO= libEngine12.so libfbtrace.so libLegacy_Auth.so \ libLegacy_UserManager.so libSrp.so libudr_engine.so PKGINSTALL?= ${PKGDIR}/pkg-install-server .else # Client part stuff USES+= libedit CONFIGURE_ARGS+= --with-system-editline CONFIGURE_ENV+= ac_cv_lib_edit_readline="yes" USE_LDCONFIG= yes CLIENT_BIN= gpre isql-fb qli -CLIENT_HEADER= extlib/ib_util.h include/ibase.h include/iberror.h yvalve/perf.h +CLIENT_HEADER= ib_util.h ibase.h iberror.h perf.h OPTIONS_DEFINE= DOCS DOCS_PORTDOCS= * FB_DOCS_FILES= WhatsNew README.* Firebird* ambiguity.txt \ ods11-index-structure.html FB_DOCS_DIRS= sql.extensions license upgrade .endif MAKE_ENV+= FIREBIRD_TMP="${WRKDIR}" FIREBIRD_LOCK="${WRKDIR}" MAKE_ARGS+= PREFIX="${STAGEDIR}${PREFIX}" .include .if ${ARCH} == "amd64" CFLAGS+= -DAMD64 .endif .if !defined(CLIENT_ONLY) USERS= ${PORTNAME} GROUPS= ${USERS} -MAKE_ENV+= IsServer=Y +#MAKE_ENV+= IsServer=Y .endif post-patch: ${FIND} ${WRKSRC} -name "*.sh" -exec ${CHMOD} +x {} \+ ${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g' \ ${WRKSRC}/builds/install/misc/firebird.conf.in pre-build: .if !defined(CLIENT_ONLY) @${SETENV} PKG_PREFIX="${STAGEDIR}${PREFIX}" ${SH} ${PKGINSTALL} ${PORTNAME} PRE-INSTALL .endif ${MAKE} -C ${WRKSRC}/extern/btyacc do-install: .if !defined(CLIENT_ONLY) ${INSTALL_PROGRAM} ${UTIL_BIN:S!^!${WRKSRC}/gen/Release/firebird/bin/!} ${STAGEDIR}${PREFIX}/bin ${INSTALL_PROGRAM} ${UTIL_SBIN:S!^!${WRKSRC}/gen/Release/firebird/bin/!} ${STAGEDIR}${PREFIX}/sbin @${MKDIR} ${STAGEDIR}${PREFIX}/${CONFDIR} ${INSTALL_DATA} ${WRKSRC}/gen/Release/firebird/databases.conf ${STAGEDIR}${PREFIX}/${CONFDIR}/databases.conf.sample ${INSTALL_DATA} ${WRKSRC}/gen/Release/firebird/fbtrace.conf ${STAGEDIR}${PREFIX}/${CONFDIR}/fbtrace.conf ${INSTALL_DATA} ${WRKSRC}/gen/Release/firebird/plugins.conf ${STAGEDIR}${PREFIX}/${CONFDIR}/plugins.conf.sample ${INSTALL_DATA} ${WRKSRC}/gen/Release/firebird/plugins/udr_engine.conf ${STAGEDIR}${PREFIX}/${CONFDIR}/udr_engine.conf.sample ${MKDIR} ${STAGEDIR}${LIBEXECDIR}/udf ${STAGEDIR}${LOCALSTATEDIR}/help ${STAGEDIR}${LIBEXECDIR}/intl \ ${STAGEDIR}${LIBEXECDIR}/plugins ${STAGEDIR}${EXAMPLESDIR} ${INSTALL_DATA} ${WRKSRC}/gen/Release/firebird/lib/libib_util.so ${STAGEDIR}${PREFIX}/lib ${INSTALL_DATA} ${WRKSRC}/gen/Release/firebird/intl/fbintl.conf ${STAGEDIR}${LIBEXECDIR}/intl/fbintl.conf ${INSTALL_FB} -m 0555 ${UDF_SO:S!^!${WRKSRC}/gen/Release/firebird/UDF/!} ${STAGEDIR}${LIBEXECDIR}/udf ${INSTALL_FB} -m 0444 ${UDF_SQL:S!^!${WRKSRC}/gen/Release/firebird/UDF/!} ${STAGEDIR}${LIBEXECDIR}/udf ${INSTALL_FB} -m 0555 ${PLUGIN_SO:S!^!${WRKSRC}/gen/Release/firebird/plugins/!} ${STAGEDIR}${LIBEXECDIR}/plugins ${INSTALL_FB} -m 0660 ${WRKSRC}/gen/Release/firebird/security3.fdb ${STAGEDIR}${LOCALSTATEDIR}/security3.fdb.sample ${INSTALL_FB} -m 0660 ${WRKSRC}/gen/Release/firebird/examples/empbuild/employee.fdb ${STAGEDIR}${EXAMPLESDIR}/employee.fdb ${INSTALL_FB} -m 0440 ${WRKSRC}/gen/Release/firebird/help/help.fdb ${STAGEDIR}${LOCALSTATEDIR}/help ${INSTALL_FB} -m 0555 ${WRKSRC}/gen/Release/firebird/intl/libfbintl.so ${STAGEDIR}${LIBEXECDIR}/intl/libfbintl.so .else # defined CLIENT_ONLY ${INSTALL_PROGRAM} ${CLIENT_BIN:S!^!${WRKSRC}/gen/Release/firebird/bin/!} ${STAGEDIR}${PREFIX}/bin ${SED} -e "s=%%PREFIX%%=${PREFIX}=g" ${WRKSRC}/gen/Release/firebird/firebird.conf > ${WRKDIR}/firebird.conf @${MKDIR} ${STAGEDIR}${PREFIX}/${CONFDIR} ${INSTALL_DATA} ${WRKDIR}/firebird.conf ${STAGEDIR}${PREFIX}/${CONFDIR}/firebird.conf.sample ${INSTALL_DATA} ${WRKSRC}/gen/Release/firebird/lib/libfbclient.so.${PORTVERSION} \ ${STAGEDIR}${PREFIX}/lib ${LN} -fs libfbclient.so.${PORTVERSION} ${STAGEDIR}${PREFIX}/lib/libfbclient.so.3 ${LN} -fs libfbclient.so.${PORTVERSION} ${STAGEDIR}${PREFIX}/lib/libfbclient.so @${MKDIR} ${STAGEDIR}${PREFIX}/include/firebird - ${INSTALL_DATA} ${CLIENT_HEADER:S!^!${WRKSRC}/src/!} ${STAGEDIR}${PREFIX}/include + ${INSTALL_DATA} ${CLIENT_HEADER:S!^!${WRKSRC}/gen/Release/firebird/include/!} ${STAGEDIR}${PREFIX}/include - @cd ${WRKSRC}/src/include/firebird && \ + @cd ${WRKSRC}/gen/Release/firebird/include/firebird && \ ${FIND} * -type d -exec ${MKDIR} "${STAGEDIR}${PREFIX}/include/firebird/{}" \; - @cd ${WRKSRC}/src/include/firebird && \ + @cd ${WRKSRC}/gen/Release/firebird/include/firebird && \ ${FIND} * -type f -exec ${INSTALL_DATA} "{}" "${STAGEDIR}${PREFIX}/include/firebird/{}" \; @${MKDIR} ${STAGEDIR}${DATADIR} ${INSTALL_DATA} ${WRKSRC}/gen/Release/firebird/*.msg ${STAGEDIR}${DATADIR} post-install-DOCS-on: @${ECHO_MSG} "===> Installing documentation for ${PKGNAME}" @${MKDIR} ${FB_DOCS_DIRS:S!^!${STAGEDIR}${DOCSDIR}/!} ${INSTALL_DATA} ${FB_DOCS_FILES:S!^!${WRKSRC}/doc/!} ${STAGEDIR}${DOCSDIR} ${LN} -sf README.user ${STAGEDIR}${DOCSDIR}/README ${INSTALL_DATA} ${WRKSRC}/doc/sql.extensions/* ${STAGEDIR}${DOCSDIR}/sql.extensions ${INSTALL_DATA} ${WRKSRC}/doc/license/* ${STAGEDIR}${DOCSDIR}/license ${INSTALL_DATA} ${WRKSRC}/src/misc/upgrade/v3.0/* ${STAGEDIR}${DOCSDIR}/upgrade .endif .include diff --git a/databases/firebird30-server/files/patch-builds_install_misc_firebird.conf.in b/databases/firebird30-server/files/patch-builds_install_misc_firebird.conf.in index 953e438de696..ac685450a0b5 100644 --- a/databases/firebird30-server/files/patch-builds_install_misc_firebird.conf.in +++ b/databases/firebird30-server/files/patch-builds_install_misc_firebird.conf.in @@ -1,12 +1,11 @@ ---- builds/install/misc/firebird.conf.in.orig 2020-10-12 00:02:22 UTC +--- builds/install/misc/firebird.conf.in.orig 2022-06-07 08:18:52 UTC +++ builds/install/misc/firebird.conf.in @@ -189,7 +189,7 @@ # # Type: string (special format) # -#UdfAccess = Restrict UDF -+UdfAccess = Restrict %%PREFIX%%/libexec/firebird/udf ++UdfAccess = Restrict /usr/local/libexec/firebird/udf # ---------------------------- - diff --git a/databases/firebird30-server/files/patch-builds-posix_Makefile.in b/databases/firebird30-server/files/patch-builds_posix_Makefile.in similarity index 59% rename from databases/firebird30-server/files/patch-builds-posix_Makefile.in rename to databases/firebird30-server/files/patch-builds_posix_Makefile.in index 3957c91179a9..8092243be081 100644 --- a/databases/firebird30-server/files/patch-builds-posix_Makefile.in +++ b/databases/firebird30-server/files/patch-builds_posix_Makefile.in @@ -1,34 +1,21 @@ ---- builds/posix/Makefile.in 2020-10-20 03:40:05.000000000 -0500 -+++ builds/posix/Makefile.in 2021-06-25 00:25:25.389776000 -0500 -@@ -186,16 +186,18 @@ +--- builds/posix/Makefile.in.orig 2022-06-07 08:18:52 UTC ++++ builds/posix/Makefile.in +@@ -191,16 +191,16 @@ master_process: $(MAKE) preliminaryCheck $(MAKE) boot $(MAKE) yvalve + $(MAKE) engine ifeq ($(IsDeveloper), Y) # In developer mode we must regenerate various files in include/gen $(MAKE) ids endif - $(MAKE) engine -+ifeq ($(IsServer), Y) $(MAKE) fbintl $(MAKE) utilities -+endif # Now having ready such useful tools as gbak and isql, we may restore / create # required databases and switch to full-featured gpre - $(MAKE) gpre + $(MAKE) gbak gfix gpre # Pay attention - after build force gpre_current to point to gpre # even if gpre itself was not rebuilt -$(RM) $(GPRE_CURRENT) -@@ -204,8 +206,10 @@ - # In developer mode we must regenerate various files in include/gen - $(MAKE) codes - endif -+ifeq ($(IsServer), Y) - $(MAKE) plugins - $(MAKE) examples -+endif - $(MAKE) rest - - diff --git a/databases/firebird30-server/files/patch-builds-posix_Makefile.in.plugins_examples b/databases/firebird30-server/files/patch-builds_posix_Makefile.in.plugins__examples similarity index 79% rename from databases/firebird30-server/files/patch-builds-posix_Makefile.in.plugins_examples rename to databases/firebird30-server/files/patch-builds_posix_Makefile.in.plugins__examples index 4a58a2a2fe22..a3cd068de57b 100644 --- a/databases/firebird30-server/files/patch-builds-posix_Makefile.in.plugins_examples +++ b/databases/firebird30-server/files/patch-builds_posix_Makefile.in.plugins__examples @@ -1,12 +1,11 @@ ---- builds/posix/Makefile.in.plugins_examples.orig 2021-03-27 11:14:37 UTC +--- builds/posix/Makefile.in.plugins_examples.orig 2022-06-07 08:18:52 UTC +++ builds/posix/Makefile.in.plugins_examples @@ -99,7 +99,7 @@ AllObjects += $(CA_Objects) crypt_app: $(CRYPT_APP) $(CRYPT_APP): $(CA_Objects) - $(EXE_LINK) $^ -o $@ $(FIREBIRD_LIBRARY_LINK) + $(EXE_LINK) $^ -o $@ $(LDFLAGS) $(FIREBIRD_LIBRARY_LINK) include $(ROOT)/gen/make.shared.targets - diff --git a/databases/firebird30-server/files/patch-builds_posix_empty.vers b/databases/firebird30-server/files/patch-builds_posix_empty.vers index 598107119be9..8ca57ab7e436 100644 --- a/databases/firebird30-server/files/patch-builds_posix_empty.vers +++ b/databases/firebird30-server/files/patch-builds_posix_empty.vers @@ -1,9 +1,8 @@ ---- builds/posix/empty.vers.orig 2020-10-12 00:02:22 UTC +--- builds/posix/empty.vers.orig 2022-06-07 08:18:52 UTC +++ builds/posix/empty.vers @@ -21,3 +21,5 @@ # Contributor(s): ______________________________________. main +__progname +environ - diff --git a/databases/firebird30-server/files/patch-builds_posix_make.defaults b/databases/firebird30-server/files/patch-builds_posix_make.defaults index b30b259a6848..79982d81f157 100644 --- a/databases/firebird30-server/files/patch-builds_posix_make.defaults +++ b/databases/firebird30-server/files/patch-builds_posix_make.defaults @@ -1,64 +1,64 @@ ---- builds/posix/make.defaults 2020-10-20 03:40:05.000000000 -0500 -+++ builds/posix/make.defaults 2021-06-25 00:23:49.718147000 -0500 -@@ -134,7 +134,7 @@ +--- builds/posix/make.defaults.orig 2022-06-07 08:18:52 UTC ++++ builds/posix/make.defaults +@@ -134,7 +134,7 @@ CAS_OPTIONS=@CAS_OPTIONS@ MATHLIB=@MATHLIB@ # switch to make sed edit files inplace -INLINE_EDIT_SED:= -i +INLINE_EDIT_SED:= -i "" # Default programs and tools to be used in the build process -@@ -144,7 +144,7 @@ +@@ -144,7 +144,7 @@ RM_R= rm -rf CHMOD= chmod CHMOD_6= chmod 666 CHMOD_7= chmod 777 -CHMOD_S7= chmod 06777 +CHMOD_S7= chmod 04555 MV= mv -f TOUCH= touch CP= cp -@@ -219,7 +219,7 @@ +@@ -219,7 +219,7 @@ vpath %.dll $(LIB) #LibraryFileName=libfbclient LibraryFileName=libfbclient LibraryFullName=$(LibraryFileName).${SHRLIB_EXT}.${FirebirdVersion} -LibrarySoName=$(LibraryFileName).${SHRLIB_EXT}.2 +LibrarySoName=$(LibraryFileName).${SHRLIB_EXT}.3 LibraryBaseName=$(LibraryFileName).${SHRLIB_EXT} LIBFIREBIRD_FULLNAME = $(LIB)/$(LibraryFullName) -@@ -240,7 +240,7 @@ +@@ -240,7 +240,7 @@ LIBFBINTL_SO = $(FB_BUILD)/intl/$(LIB_PREFIX)fbintl.$( ifeq ($(EDITLINE_FLG),Y) ifeq ($(STD_EDITLINE), true) - LIBEDITLINE := -l$(READLINE) + LIBEDITLINE := $(shell pkgconf libedit --libs) else LIBEDITLINE := $(LIB)/libedit.a endif -@@ -362,7 +362,7 @@ +@@ -362,7 +362,7 @@ CREATE_DB = $(RBIN)/create_db$(EXEC_EXT) GDS_DROP = $(BIN)/gds_drop$(EXEC_EXT) FBSVCMGR = $(BIN)/fbsvcmgr$(EXEC_EXT) FBTRACEMGR = $(BIN)/fbtracemgr$(EXEC_EXT) -GSTAT = $(BIN)/gstat$(EXEC_EXT) +GSTAT = $(BIN)/fbstat$(EXEC_EXT) NBACKUP = $(BIN)/nbackup$(EXEC_EXT) LOCKPRINT = $(BIN)/fb_lock_print$(EXEC_EXT) GSEC = $(BIN)/gsec$(EXEC_EXT) -@@ -383,13 +383,13 @@ +@@ -383,13 +383,13 @@ SECURITY_FDB = $(FIREBIRD)/security3.fdb QLI = $(BIN)/qli$(EXEC_EXT) # From isql -ISQL = $(BIN)/isql$(EXEC_EXT) -RUN_ISQL = $(RBIN)/isql$(EXEC_EXT) +ISQL = $(BIN)/isql-fb$(EXEC_EXT) +RUN_ISQL = $(RBIN)/isql-fb$(EXEC_EXT) # From burp GBAK = $(BIN)/gbak$(EXEC_EXT) RUN_GBAK = $(RBIN)/gbak$(EXEC_EXT) -GSPLIT = $(BIN)/gsplit$(EXEC_EXT) +GSPLIT = $(BIN)/fbsplit$(EXEC_EXT) # From gpre # (gpre current is a link to one of the others) diff --git a/databases/firebird30-server/files/patch-builds-posix-prefix.freebsd b/databases/firebird30-server/files/patch-builds_posix_prefix.freebsd similarity index 92% rename from databases/firebird30-server/files/patch-builds-posix-prefix.freebsd rename to databases/firebird30-server/files/patch-builds_posix_prefix.freebsd index 3da3ac70283e..9734f4083aa3 100644 --- a/databases/firebird30-server/files/patch-builds-posix-prefix.freebsd +++ b/databases/firebird30-server/files/patch-builds_posix_prefix.freebsd @@ -1,20 +1,19 @@ ---- builds/posix/prefix.freebsd.orig 2021-03-27 18:59:05 UTC +--- builds/posix/prefix.freebsd.orig 2022-06-07 08:18:52 UTC +++ builds/posix/prefix.freebsd @@ -20,5 +20,14 @@ EXE_LINK_OPTIONS+=-Wl,-rpath,../gen/firebird/lib -PROD_FLAGS=-O -fno-builtin -DFREEBSD -pipe -MMD -fPIC -DEV_FLAGS=-ggdb -DFREEBSD -pipe -MMD -p -fPIC -Wall -Wno-non-virtual-dtor +COMMON_FLAGS=-DFREEBSD -pipe -MMD -fPIC +PROD_FLAGS=$(COMMON_FLAGS) -O0 -g -fno-builtin -Wno-deprecated +DEV_FLAGS=$(COMMON_FLAGS) -ggdb -p -Wall -Wno-non-virtual-dtor + +# This file must be compiled with SSE4.2 support +%/CRC32C.o: COMMON_FLAGS += -msse4 + +# These files are generated incorrectly (e.g. array.epp => array.cpp) +%/array.o %/blob.o %/alice_meta.o %/restore.o %/backup.o: COMMON_FLAGS += -Wno-narrowing +%/OdsDetection.o %/dba.o: COMMON_FLAGS += -Wno-narrowing + - diff --git a/databases/firebird30-server/files/patch-builds-posix-prefix.freebsd_amd64 b/databases/firebird30-server/files/patch-builds_posix_prefix.freebsd__amd64 similarity index 91% rename from databases/firebird30-server/files/patch-builds-posix-prefix.freebsd_amd64 rename to databases/firebird30-server/files/patch-builds_posix_prefix.freebsd__amd64 index dd0f1ae39223..d51c1af1e2d6 100644 --- a/databases/firebird30-server/files/patch-builds-posix-prefix.freebsd_amd64 +++ b/databases/firebird30-server/files/patch-builds_posix_prefix.freebsd__amd64 @@ -1,19 +1,18 @@ ---- builds/posix/prefix.freebsd_amd64.orig 2020-10-20 08:40:05 UTC +--- builds/posix/prefix.freebsd_amd64.orig 2022-06-07 08:18:52 UTC +++ builds/posix/prefix.freebsd_amd64 @@ -20,5 +20,13 @@ EXE_LINK_OPTIONS+=-Wl,-rpath,../gen/firebird/lib -PROD_FLAGS=-O -fno-builtin -DFREEBSD -DAMD64 -pipe -MMD -fPIC -DEV_FLAGS=-ggdb -DFREEBSD -DAMD64 -pipe -MMD -p -fPIC -Wall -Wno-non-virtual-dtor +COMMON_FLAGS=-DFREEBSD -DAMD64 -pipe -MMD -fPIC +PROD_FLAGS=$(COMMON_FLAGS) -O0 -g -fno-builtin -Wno-deprecated +DEV_FLAGS=$(COMMON_FLAGS) -ggdb -p -Wall -Wno-non-virtual-dtor + +# This file must be compiled with SSE4.2 support +%/CRC32C.o: COMMON_FLAGS += -msse4 + +# These files are generated incorrectly (e.g. array.epp => array.cpp) +%/array.o %/blob.o %/alice_meta.o %/restore.o %/backup.o: COMMON_FLAGS += -Wno-narrowing +%/OdsDetection.o %/dba.o: COMMON_FLAGS += -Wno-narrowing - diff --git a/databases/firebird30-server/files/patch-extern_btyacc_Makefile b/databases/firebird30-server/files/patch-extern_btyacc_Makefile index defaa3243e5b..24cb5ddee87a 100644 --- a/databases/firebird30-server/files/patch-extern_btyacc_Makefile +++ b/databases/firebird30-server/files/patch-extern_btyacc_Makefile @@ -1,12 +1,11 @@ ---- extern/btyacc/Makefile.orig 2020-10-12 00:02:22 UTC +--- extern/btyacc/Makefile.orig 2022-06-07 08:18:52 UTC +++ extern/btyacc/Makefile @@ -42,7 +42,7 @@ OTHERS = README README.BYACC \ all: $(PROGRAM) $(PROGRAM): $(OBJS) $(LIBS) - $(CC) $(LDFLAGS) -o $(PROGRAM) $(OBJS) $(LIBS) + $(CC) $(CFLAGS) $(LDFLAGS) -o $(PROGRAM) $(OBJS) $(LIBS) clean:; rm -f $(OBJS) - diff --git a/databases/firebird30-server/files/patch-extern_cloop_Makefile b/databases/firebird30-server/files/patch-extern_cloop_Makefile index 8c4b33ba7dac..4f1e65880bbd 100644 --- a/databases/firebird30-server/files/patch-extern_cloop_Makefile +++ b/databases/firebird30-server/files/patch-extern_cloop_Makefile @@ -1,24 +1,23 @@ ---- extern/cloop/Makefile 2020-10-12 00:02:22 UTC +--- extern/cloop/Makefile.orig 2022-06-07 08:18:52 UTC +++ extern/cloop/Makefile @@ -6,7 +6,7 @@ TARGET := release CC := $(CC) CXX := $(CXX) -LD := $(CXX) +LD := $(CXX) $(LDFLAGS) SRC_DIR := src BUILD_DIR := build -@@ -27,8 +27,9 @@ SRCS_CPP := $(foreach sdir,$(SRC_DIRS),$ +@@ -27,8 +27,9 @@ SRCS_CPP := $(foreach sdir,$(SRC_DIRS),$(wildcard $(sd OBJS_C := $(patsubst $(SRC_DIR)/%.c,$(OBJ_DIR)/%.o,$(SRCS_C)) OBJS_CPP := $(patsubst $(SRC_DIR)/%.cpp,$(OBJ_DIR)/%.o,$(SRCS_CPP)) -C_FLAGS := -ggdb -fPIC -MMD -MP -W -Wall -Wno-unused-parameter -CXX_FLAGS := $(C_FLAGS) +COMMON_C_FLAGS := -ggdb -fPIC -MMD -MP -W -Wall -Wno-unused-parameter +C_FLAGS := $(COMMON_C_FLAGS) $(CFLAGS) $(CPPFLAGS) +CXX_FLAGS := $(COMMON_C_FLAGS) $(CXXFLAGS) $(CPPFLAGS) FPC_FLAGS := -Mdelphi ifeq ($(TARGET),release) - diff --git a/databases/firebird30-server/files/patch-src_common_os_posix_SyncSignals.cpp b/databases/firebird30-server/files/patch-src_common_os_posix_SyncSignals.cpp index 159ee13a99c0..f24f4e93b82f 100644 --- a/databases/firebird30-server/files/patch-src_common_os_posix_SyncSignals.cpp +++ b/databases/firebird30-server/files/patch-src_common_os_posix_SyncSignals.cpp @@ -1,13 +1,12 @@ ---- src/common/os/posix/SyncSignals.cpp.orig 2020-10-12 00:02:22 UTC +--- src/common/os/posix/SyncSignals.cpp.orig 2022-06-07 08:18:52 UTC +++ src/common/os/posix/SyncSignals.cpp @@ -54,9 +54,6 @@ #include #include -#if defined FREEBSD || defined NETBSD || defined DARWIN || defined HPUX -#define sigset signal -#endif namespace { - diff --git a/databases/firebird30-server/files/patch-src-jrd-os-posix_unix.cpp b/databases/firebird30-server/files/patch-src_jrd_os_posix_unix.cpp similarity index 75% rename from databases/firebird30-server/files/patch-src-jrd-os-posix_unix.cpp rename to databases/firebird30-server/files/patch-src_jrd_os_posix_unix.cpp index 6c9dc50ba31d..ffaecc74c81e 100644 --- a/databases/firebird30-server/files/patch-src-jrd-os-posix_unix.cpp +++ b/databases/firebird30-server/files/patch-src_jrd_os_posix_unix.cpp @@ -1,25 +1,25 @@ ---- src/jrd/os/posix/unix.cpp 2021-06-22 00:38:07.434896000 -0500 -+++ src/jrd/os/posix/unix.cpp 2021-06-22 00:43:54.988645000 -0500 +--- src/jrd/os/posix/unix.cpp.orig 2022-06-07 08:18:52 UTC ++++ src/jrd/os/posix/unix.cpp @@ -56,6 +56,13 @@ #include #endif +#ifdef FREEBSD +#include +#define BLKGETSIZE64 DIOCGMEDIASIZE +#define BLKGETSIZE DIOCGMEDIASIZE +#define BLKSSZGET DIOCGSECTORSIZE +#endif + #endif //SUPPORT_RAW_DEVICES #include "../jrd/jrd.h" -@@ -495,7 +502,7 @@ +@@ -496,7 +503,7 @@ ULONG PIO_get_number_of_pages(const jrd_file* file, co // Looks like any OS needs own ioctl() to determine raw device size #undef HAS_RAW_SIZE -#ifdef LINUX +#if defined(LINUX) || defined(FREEBSD) #ifdef BLKGETSIZE64 if (ioctl(file->fil_desc, BLKGETSIZE64, &length) != 0) #endif /*BLKGETSIZE64*/ diff --git a/databases/firebird30-server/files/patch-src_remote_inet.cpp b/databases/firebird30-server/files/patch-src_remote_inet.cpp index 6b45a4f61e75..269a80fd8457 100644 --- a/databases/firebird30-server/files/patch-src_remote_inet.cpp +++ b/databases/firebird30-server/files/patch-src_remote_inet.cpp @@ -1,25 +1,24 @@ ---- src/remote/inet.cpp.orig 2020-10-20 08:40:05 UTC +--- src/remote/inet.cpp.orig 2022-06-07 08:18:52 UTC +++ src/remote/inet.cpp -@@ -962,7 +962,7 @@ rem_port* INET_connect(const TEXT* name, +@@ -960,7 +960,7 @@ rem_port* INET_connect(const TEXT* name, gai_hints.ai_family = ((host.hasData() || !ipv6) ? AF_UNSPEC : AF_INET6); gai_hints.ai_socktype = SOCK_STREAM; -#if !defined(WIN_NT) && !defined(__clang__) +#if !defined(WIN_NT) && !defined(__FreeBSD__) && !defined(__DragonFly__) gai_hints.ai_protocol = SOL_TCP; #else gai_hints.ai_protocol = IPPROTO_TCP; -@@ -1176,6 +1176,12 @@ static rem_port* listener_socket(rem_port* port, USHOR +@@ -1174,6 +1174,12 @@ static rem_port* listener_socket(rem_port* port, USHOR setFastLoopbackOption(port); inet_ports->registerPort(port); + + char *parent_pid; + if (parent_pid = getenv("FB_SIGNAL_PROCESS")) + { + kill(atoi(parent_pid), SIGUSR1); + } if (flag & SRVR_multi_client) { -