svn commit: r565268 - head/databases/xtrabackup

Oleksii Samorukov samm at FreeBSD.org
Sun Feb 14 22:09:30 UTC 2021


Author: samm
Date: Sun Feb 14 22:09:29 2021
New Revision: 565268
URL: https://svnweb.freebsd.org/changeset/ports/565268

Log:
  databases/xtrabackup: fix build on FreeBSD 13
  
  Compilation of the embedded mysql server fail with clang 11, use clang 10 as
  workaround (same as databases/mysql57-server do)
  
  Reported by:	pkg-fallout at FreeBSD.org

Modified:
  head/databases/xtrabackup/Makefile

Modified: head/databases/xtrabackup/Makefile
==============================================================================
--- head/databases/xtrabackup/Makefile	Sun Feb 14 21:58:24 2021	(r565267)
+++ head/databases/xtrabackup/Makefile	Sun Feb 14 22:09:29 2021	(r565268)
@@ -28,12 +28,12 @@ LIB_DEPENDS=	libcurl.so:ftp/curl \
 		libgpg-error.so:security/libgpg-error
 RUN_DEPENDS=	qpress:archivers/qpress
 
-CONFLICTS_INSTALL=	${PORTNAME}8
-
-# autotool is in use for 5.1 builds
 USES=		alias autoreconf:build bison cmake:noninja compiler:c++11-lang \
 		cpe gettext libtool perl5 shebangfix
 USE_CXXSTD=	c++11
+
+CONFLICTS_INSTALL=	${PORTNAME}8
+
 CPE_VENDOR=	percona
 SHEBANG_FILES=	storage/innobase/xtrabackup/xbcloud_osenv.sh
 CMAKE_ARGS=	-DWITH_BOOST=${WRKDIR}/boost_1_59_0 -DWITH_VERSION_CHECK=OFF
@@ -43,8 +43,20 @@ WRKSRC=		${WRKDIR}/percona-${PORTNAME}-${PORTVERSION}
 PLIST_FILES=	bin/xtrabackup bin/xbstream bin/innobackupex bin/xbcrypt \
 		bin/xbcloud bin/xbcloud_osenv
 
+.include <bsd.port.pre.mk>
+# xtrabackup/mysql57 fails to compile with llvm11, which was imported to current in r364284
+# without a version increase (1300109 = r364274).
+# Until a proper fix is provided, simply use llvm from ports, which probably could be
+# a backport of amongst other tings:
+# https://github.com/mysql/mysql-server/commit/08f46b3c00ee70e7ed7825daeb91df2289f80f50
+.if ${CHOSEN_COMPILER_TYPE} == clang && ${OPSYS} == FreeBSD && ${OSVERSION} >= 1300109
+BUILD_DEPENDS+=	clang${LLVM_DEFAULT}:devel/llvm${LLVM_DEFAULT}
+CC=		${LOCALBASE}/bin/clang${LLVM_DEFAULT}
+CXX=		${LOCALBASE}/bin/clang++${LLVM_DEFAULT}
+.endif
+
 # Not sure why it's trying to install mysql client libraries now
 post-install:
 	${RM} -rf ${STAGEDIR}${LOCALBASE}/lib
 
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>


More information about the svn-ports-all mailing list