help cmake run executables when cross-compiling
diff --git a/client/SDL/common/res/CMakeLists.txt b/client/SDL/common/res/CMakeLists.txt
index fdb80b79b..08f922968 100644
--- a/client/SDL/common/res/CMakeLists.txt
+++ b/client/SDL/common/res/CMakeLists.txt
@@ -51,7 +51,7 @@ list(APPEND FACTORY_CLASSES
 	add_custom_command(
 		OUTPUT ${FILE_BYPRODUCTS}
 		COMMAND ${CMAKE_COMMAND} -E make_directory ${FILE_BIN_DIR}
-		COMMAND $<TARGET_FILE:sdl-common-res2bin> ${FILE} ${FILE_TYPE} ${TARGET_NAME} ${FILE_BIN_DIR}
+		COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $<TARGET_FILE:sdl-common-res2bin> ${FILE} ${FILE_TYPE} ${TARGET_NAME} ${FILE_BIN_DIR}
 		COMMENT "create image resources"
 		DEPENDS sdl-common-res2bin
 		DEPENDS ${FILE}
diff --git a/cmake/InstallFreeRDPMan.cmake b/cmake/InstallFreeRDPMan.cmake
index 758d673d6..a00cdf5eb 100644
--- a/cmake/InstallFreeRDPMan.cmake
+++ b/cmake/InstallFreeRDPMan.cmake
@@ -54,7 +54,7 @@ function(generate_and_install_freerdp_man_from_xml target section dependencies)
 
 		add_custom_command(
                                         OUTPUT "${manpage}"
-					COMMAND ${CMAKE_BINARY_DIR}/client/common/man/generate_argument_docbook
+					COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} ${CMAKE_BINARY_DIR}/client/common/man/generate_argument_docbook
 					COMMAND ${XSLTPROC_EXECUTABLE} --path "${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR}" ${DOCBOOKXSL_DIR}/manpages/docbook.xsl ${manpage}.xml
 					WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
 					DEPENDS
