diff --git a/devel/qjson/Makefile b/devel/qjson/Makefile --- a/devel/qjson/Makefile +++ b/devel/qjson/Makefile @@ -29,12 +29,6 @@ DOXYGEN_BUILD_DEPENDS= doxygen:devel/doxygen -.include - -.if ${OPSYS} == FreeBSD && ${OSVERSION} >= 1400091 -CXXFLAGS+= -Dregister= -.endif - post-build-DOXYGEN-on: cd ${WRKSRC}/doc && doxygen @@ -42,4 +36,12 @@ ${MKDIR} ${STAGEDIR}${_DOCSDIR} cd ${WRKSRC}/doc/html && ${COPYTREE_SHARE} . ${STAGEDIR}${_DOCSDIR} -.include +.include + +# Clang 16 defaults to building in C++17, and throws an error when the +# `register' keyword is used. Make clang just ignore the keyword instead. +.if ${COMPILER_TYPE} == clang && ${COMPILER_VERSION} >= 160 +CXXFLAGS+= -Wno-register +.endif + +.include