From e9f1de751b66aaaf0d9ea0b8934794d838d05dbc Mon Sep 17 00:00:00 2001 From: Bernhard Miklautz Date: Tue, 24 Jan 2012 09:04:02 +0100 Subject: [PATCH] build: Added option WITH_NEON Enables neon optimized rfx decoder --- cmake/ConfigOptions.cmake | 1 + config.h.in | 1 + libfreerdp-codec/CMakeLists.txt | 8 ++++++++ 3 files changed, 10 insertions(+) diff --git a/cmake/ConfigOptions.cmake b/cmake/ConfigOptions.cmake index ba4b7e004..d59a04e9b 100644 --- a/cmake/ConfigOptions.cmake +++ b/cmake/ConfigOptions.cmake @@ -23,3 +23,4 @@ option(WITH_SSE2_TARGET "Allow compiler to generate SSE2 instructions." OFF) option(WITH_DEBUG_REDIR "Redirection debug messages" OFF) option(WITH_DEBUG_CLIPRDR "Print clipboard redirection debug messages" OFF) option(WITH_DEBUG_WND "Print window order debug messages" OFF) +option(WITH_NEON "Enable NEON optimization for rfx decoder" OFF) diff --git a/config.h.in b/config.h.in index 804971331..bc5770ee4 100644 --- a/config.h.in +++ b/config.h.in @@ -37,6 +37,7 @@ #cmakedefine WITH_PROFILER #cmakedefine WITH_SSE2 #cmakedefine WITH_SSE2_TARGET +#cmakedefine WITH_NEON #cmakedefine WITH_DEBUG_X11 #cmakedefine WITH_DEBUG_X11_CLIPRDR #cmakedefine WITH_DEBUG_X11_LOCAL_MOVESIZE diff --git a/libfreerdp-codec/CMakeLists.txt b/libfreerdp-codec/CMakeLists.txt index 58d338ae2..7562a9137 100644 --- a/libfreerdp-codec/CMakeLists.txt +++ b/libfreerdp-codec/CMakeLists.txt @@ -49,6 +49,14 @@ if(WITH_SSE2) set_property(SOURCE rfx_sse2.c PROPERTY COMPILE_FLAGS "-msse2") endif() +if(WITH_NEON) + set(FREERDP_CODEC_SRCS ${FREERDP_CODEC_SRCS} + rfx_neon.c + rfx_neon.h +) + set_property(SOURCE rfx_neon.c PROPERTY COMPILE_FLAGS "-mfpu=neon -mfloat-abi=softfp") +endif() + add_library(freerdp-codec ${FREERDP_CODEC_SRCS}) set_target_properties(freerdp-codec PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")