Re: [Firebird-devel] MacOS build fail "SSE4.2 instruction set not enabled"

2017-05-16 Thread Alex Peshkoff

On 05/12/17 22:13, Julien wrote:

I gave a try but had this:
lo/lode/dev/core/workdir/UnpackedTarball/firebird/src/common/CRC32C.cpp:41:10: 
error: always_inline function '_mm_crc32_u8' requires target feature 'sse4.1', 
but would be inlined into function 'CRC32C' that is compiled without support 
for 'sse4.1'
 return _mm_crc32_u8(hash_value, *value);
^
Are you sure msse4 shouldn't be added in CXXFLAGS instead of COMMON_FLAGS?


In linux COMMON_FLAGS is used and it appears to be correct choice from 
general POV - msse4 makes sense for both plain C & C++.
But what about darwin - yes, looks like it does not use COMMON_FLAGS at 
all, with CXXFLAGS this should work.


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: [Firebird-devel] MacOS build fail "SSE4.2 instruction set not enabled"

2017-05-12 Thread Alex Peshkoff

On 05/12/17 12:05, marius adrian popa wrote:

Known issue in Firebird 3.0.x

http://firebird.1100200.n4.nabble.com/std-c-11-added-to-CXXFLAGS-in-3-0-on-linux-td4645224.html

introduced by this commit

https://github.com/FirebirdSQL/firebird/commit/52d9a05a0f3d


I can't check myself mac issues, but sooner of all attached patch should 
help.


diff --git a/builds/posix/darwin.defaults b/builds/posix/darwin.defaults
index 3406cc6..b6acb11 100644
--- a/builds/posix/darwin.defaults
+++ b/builds/posix/darwin.defaults
@@ -46,3 +46,5 @@ LINK_CLIENT = $(LIB_LINK) $(LINK_FIREBIRD_CLIENT_SYMBOLS) $(LIB_LINK_OPTIONS) $(
 STATIC_CXX_SUPPORT = -lsupc++ $(GCCS) -lgcc_eh -lSystem
 
 INLINE_EDIT_SED:= -i ""
+
+CXXFLAGS := $(CXXFLAGS) -std=c++11
diff --git a/builds/posix/prefix.darwin_i386 b/builds/posix/prefix.darwin_i386
index 39a3794..35b2763 100644
--- a/builds/posix/prefix.darwin_i386
+++ b/builds/posix/prefix.darwin_i386
@@ -40,3 +40,7 @@ EXE_LINK_OPTIONS:=-m32
 LD_FLAGS+=-m32 -arch i386
 
 include $(ROOT)/gen/darwin.defaults
+
+# This file must be compiled with SSE4.2 support
+%/CRC32C.o: COMMON_FLAGS += -msse4
+
diff --git a/builds/posix/prefix.darwin_x86_64 b/builds/posix/prefix.darwin_x86_64
index c846a08..c145fd9 100644
--- a/builds/posix/prefix.darwin_x86_64
+++ b/builds/posix/prefix.darwin_x86_64
@@ -41,3 +41,7 @@ FIREBIRD_LIBRARY_LINK+=-liconv
 UNDEF_PLATFORM=
 
 include $(ROOT)/gen/darwin.defaults
+
+# This file must be compiled with SSE4.2 support
+%/CRC32C.o: COMMON_FLAGS += -msse4
+
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice