From 5d0e2fd3d6fe70484c116d9505a6117561f4961b Mon Sep 17 00:00:00 2001 From: Koop Mast Date: Fri, 21 Feb 2014 00:21:46 +0100 Subject: [PATCH 2/2] Make this compile on 32-bit FreeBSD. Don't try to compile this code on 32-bit FreeBSD, it will error out complain about registers only being available in 64-bit mode. --- src/pulsecore/sconv_sse.c | 4 ++-- src/pulsecore/svolume_mmx.c | 4 ++-- src/pulsecore/svolume_sse.c | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/pulsecore/sconv_sse.c b/src/pulsecore/sconv_sse.c index 2f84f5a..f430abf 100644 --- a/src/pulsecore/sconv_sse.c +++ b/src/pulsecore/sconv_sse.c @@ -33,7 +33,7 @@ #include "cpu-x86.h" #include "sconv.h" -#if !defined(__APPLE__) && defined (__i386__) || defined (__amd64__) +#if !defined(__APPLE__) && !defined(__FreeBSD__) && defined (__i386__) || defined (__amd64__) static const PA_DECLARE_ALIGNED (16, float, scale[4]) = { 0x8000, 0x8000, 0x8000, 0x8000 }; @@ -163,7 +163,7 @@ static void pa_sconv_s16le_from_f32ne_sse2(unsigned n, const float *a, int16_t * #endif /* defined (__i386__) || defined (__amd64__) */ void pa_convert_func_init_sse(pa_cpu_x86_flag_t flags) { -#if !defined(__APPLE__) && defined (__i386__) || defined (__amd64__) +#if !defined(__APPLE__) && !defined(__FreeBSD__) && defined (__i386__) || defined (__amd64__) if (flags & PA_CPU_X86_SSE2) { pa_log_info("Initialising SSE2 optimized conversions."); diff --git a/src/pulsecore/svolume_mmx.c b/src/pulsecore/svolume_mmx.c index d68a105..fdce9c4 100644 --- a/src/pulsecore/svolume_mmx.c +++ b/src/pulsecore/svolume_mmx.c @@ -34,7 +34,7 @@ #include "sample-util.h" -#if defined (__i386__) || defined (__amd64__) +#if !defined(__FreeBSD__) && defined (__i386__) || defined (__amd64__) /* in s: 2 int16_t samples * in v: 2 int32_t volumes, fixed point 16:16 * out s: contains scaled and clamped int16_t samples. @@ -243,7 +243,7 @@ static void pa_volume_s16re_mmx(int16_t *samples, const int32_t *volumes, unsign #endif /* defined (__i386__) || defined (__amd64__) */ void pa_volume_func_init_mmx(pa_cpu_x86_flag_t flags) { -#if defined (__i386__) || defined (__amd64__) +#if !defined(__FreeBSD__) && defined (__i386__) || defined (__amd64__) if ((flags & PA_CPU_X86_MMX) && (flags & PA_CPU_X86_CMOV)) { pa_log_info("Initialising MMX optimized volume functions."); diff --git a/src/pulsecore/svolume_sse.c b/src/pulsecore/svolume_sse.c index 9979087..553a8ad 100644 --- a/src/pulsecore/svolume_sse.c +++ b/src/pulsecore/svolume_sse.c @@ -34,7 +34,7 @@ #include "sample-util.h" -#if defined (__i386__) || defined (__amd64__) +#if !defined(__FreeBSD__) && defined (__i386__) || defined (__amd64__) #define VOLUME_32x16(s,v) /* .. | vh | vl | */ \ " pxor %%xmm4, %%xmm4 \n\t" /* .. | 0 | 0 | */ \ @@ -254,7 +254,7 @@ static void pa_volume_s16re_sse2(int16_t *samples, const int32_t *volumes, unsig #endif /* defined (__i386__) || defined (__amd64__) */ void pa_volume_func_init_sse(pa_cpu_x86_flag_t flags) { -#if defined (__i386__) || defined (__amd64__) +#if !defined(__FreeBSD__) && defined (__i386__) || defined (__amd64__) if (flags & PA_CPU_X86_SSE2) { pa_log_info("Initialising SSE2 optimized volume functions."); -- 1.8.5.2