From e6de20411b668d0e5cec7c38300e5b36abd4b4c6 Mon Sep 17 00:00:00 2001 From: Francisco Redondo Marchena Date: Mon, 15 Jun 2015 10:24:31 +0000 Subject: Disable 'sse' optimization when compiling gf-complete Add --disable-sse on configuration time to avoid to use the sse4 instructions. Mason 32-bits is failing to compile gf-complete because it tries to use this set of instructions which are specific for 64 bits machines, showing the following error: gf_w128.c:393:5: error: incompatible types when assigning to type '__m128i' from type 'int' a = _mm_insert_epi64(prod, a128[1], 0x0); ^ gf_w128.c:394:5: error: incompatible types when assigning to type '__m128i' from type 'int' a = _mm_insert_epi64(a, a128[0], 0x1); ^ gf_w128.c:395:5: error: incompatible types when assigning to type '__m128i' from type 'int' b = _mm_insert_epi64(prod, b128[1], 0x0); ^ gf_w128.c:396:5: error: incompatible types when assigning to type '__m128i' from type 'int' b = _mm_insert_epi64(b, b128[0], 0x1); ^ Change-Id: I5162cf7722f36925dd082f99478afdaf83d55b80 --- strata/swift.morph | 1 + strata/swift/gf-complete.morph | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) create mode 100644 strata/swift/gf-complete.morph diff --git a/strata/swift.morph b/strata/swift.morph index 756c277e..6045727a 100644 --- a/strata/swift.morph +++ b/strata/swift.morph @@ -20,6 +20,7 @@ chunks: ref: a380246762c16ea8eb7dbfccd50d296c3743b39e unpetrify-ref: v1.0.7 - name: gf-complete + morph: strata/swift/gf-complete.morph repo: upstream:gf-complete ref: 715443661c00558fe32f004a4be5f93f341b6e59 unpetrify-ref: v2 diff --git a/strata/swift/gf-complete.morph b/strata/swift/gf-complete.morph new file mode 100644 index 00000000..e8965c76 --- /dev/null +++ b/strata/swift/gf-complete.morph @@ -0,0 +1,20 @@ +name: gf-complete +kind: chunk +build-system: autotools +pre-configure-commands: +- ./autogen.sh +configure-commands: +- | + cpu="$(echo $TARGET | cut -d '-' -f 1)" + case "$cpu" in + x86_64) + SSE= + ;; + *) + # Disable SSE4 for any architecture which are not x86_64 bits + # see more information about architecture which support SSE in + # https://en.wikipedia.org/wiki/SSE4#Supporting_CPUs. + SSE=--disable-sse + ;; + esac + ./configure --prefix="$PREFIX" "$SSE" -- cgit v1.2.1