Date: Mon, 13 Aug 2018 14:01:56 +0200 From: Jan Beich <jbeich@FreeBSD.org> To: Alexey Dokuchaev <danfe@FreeBSD.org> Cc: Mark Linimon <linimon@lonesome.com>, svn-ports-head@freebsd.org, Mahdi Mokhtari <mmokhi@FreeBSD.org>, svn-ports-all@freebsd.org, ports-committers@freebsd.org Subject: Re: svn commit: r477036 - in head/databases/mysql80-server: . files Message-ID: <tvny-eaq3-wny@FreeBSD.org> In-Reply-To: <20180813101157.GA88376@FreeBSD.org> (Alexey Dokuchaev's message of "Mon, 13 Aug 2018 10:11:57 %2B0000") References: <201808121910.w7CJAhiQ051528@repo.freebsd.org> <20180812223108.GA20123@lonesome.com> <20180813101157.GA88376@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Alexey Dokuchaev <danfe@FreeBSD.org> writes: > On Sun, Aug 12, 2018 at 10:31:09PM +0000, Mark Linimon wrote: > >> On Sun, Aug 12, 2018 at 07:10:43PM +0000, Mahdi Mokhtari wrote: >> > databases/mysql80-server: Fix build on default Clang of 10.4-base >> > Add sse4.2 flag to CXXFLAGS on 10.4 case. >> > The build-script needs it when using intrin lib on crc32 Please, quote error messages verbatim in case a better fix is possible. databases/mysql80-server: unbreak on 10.4 amd64 In file included from storage/innobase/ut/crc32.cc:111: /usr/include/clang/3.4.1/nmmintrin.h:28:2: error: "SSE4.2 instruction set not enabled" #error "SSE4.2 instruction set not enabled" ^ storage/innobase/ut/crc32.cc:214:15: warning: unknown attribute 'target' ignored [-Wattributes] MY_ATTRIBUTE((target("sse4.2"))) ^ include/my_compiler.h:157:39: note: expanded from macro 'MY_ATTRIBUTE' #define MY_ATTRIBUTE(A) __attribute__(A) ^ storage/innobase/ut/crc32.cc:216:10: error: use of undeclared identifier '_mm_crc32_u8' *crc = _mm_crc32_u8(static_cast<unsigned>(*crc), (*data)[0]); ^ storage/innobase/ut/crc32.cc:225:15: warning: unknown attribute 'target' ignored [-Wattributes] MY_ATTRIBUTE((target("sse4.2"))) ^ include/my_compiler.h:157:39: note: expanded from macro 'MY_ATTRIBUTE' #define MY_ATTRIBUTE(A) __attribute__(A) ^ storage/innobase/ut/crc32.cc:228:15: error: use of undeclared identifier '_mm_crc32_u64' crc_64bit = _mm_crc32_u64(crc_64bit, data); ^ storage/innobase/ut/crc32.cc:238:15: warning: unknown attribute 'target' ignored [-Wattributes] MY_ATTRIBUTE((target("sse4.2"))) ^ include/my_compiler.h:157:39: note: expanded from macro 'MY_ATTRIBUTE' #define MY_ATTRIBUTE(A) __attribute__(A) ^ storage/innobase/ut/crc32.cc:288:15: warning: unknown attribute 'target' ignored [-Wattributes] MY_ATTRIBUTE((target("sse4.2"))) ^ include/my_compiler.h:157:39: note: expanded from macro 'MY_ATTRIBUTE' #define MY_ATTRIBUTE(A) __attribute__(A) ^ 4 warnings and 3 errors generated. >> > +# required for SSE-4.2 support on the default Clang++ on 10.4 >> > +.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1100000 >> > +CXXFLAGS+= -msse4.2 >> > +.endif https://reviews.llvm.org/rL239883 is part of Clang 3.8. Simply request a more modern version via USES=compiler:c++14-lang. target(...) attribute not being recognized is a giveaway sign the chosen compiler is unsupported. Ironically, 10.4 i386 built fine with Clang 3.4 as is: https://ptpb.pw/a1_F >> >> IIUC this will break on mips* and powerpc*. mips* is not supported by any lang/gcc* required by the port in question. mips* was supposed to switch to Clang 6.0 but that has yet to happen. i386/amd64 don't mandate SSE4.1. Runtime on old CPUs may crash with SIGILL. > > Plus sparc64 and others which use gcc by default What "others" that are supported by lang/gcc* via USES=compiler:c++11-lib? Or did you miss GCC isn't really supported by this port? -- CMAKE_GENERATOR: Unix Makefiles CMake Error at cmake/os/FreeBSD.cmake:40 (MESSAGE): Unsupported compiler! If sparc64 is still stuck on lang/gcc48 expect bumping into https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=193528 plugin/x/protocol/plugin/message_field_chain.cc: In member function 'void Message_field_chain::chain_message_and_its_children(const string&, std::set<std::basic_string<char> >*, const Descriptor*)': plugin/x/protocol/plugin/message_field_chain.cc:55:23: error: 'to_string' is not a member of 'std' chain + "." + std::to_string(field->number()), types_done, ^ plugin/x/protocol/plugin/message_field_chain.cc: In member function 'bool Message_field_chain::generate_chain_for_each_client_message()': plugin/x/protocol/plugin/message_field_chain.cc:74:36: error: 'to_string' is not a member of 'std' chain_message_and_its_children(std::to_string(client_id), &types, message); ^ > (which, unlike clang, refuses to accept unrecognized command line > options). Not quite. $ clang60 -Wfoo a.c warning: unknown warning option '-Wfoo' [-Wunknown-warning-option] 1 warning generated. $ clang60 -ffoo a.c clang-6.0: error: unknown argument: '-ffoo' $ clang60 -mfoo a.c clang-6.0: error: unknown argument: '-mfoo'
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?tvny-eaq3-wny>