mirror of
https://github.com/FreeRDP/FreeRDP.git
synced 2024-11-23 18:03:30 +08:00
Merge pull request #774 from FreeRDP/channels
WinPR + Channels + CMake + Windows Server + Client/Server
This commit is contained in:
commit
1c85e089c1
2
.gitignore
vendored
2
.gitignore
vendored
@ -45,6 +45,8 @@ RelWithDebInfo
|
||||
*.so
|
||||
*.so.*
|
||||
*.dylib
|
||||
bin
|
||||
libs
|
||||
cunit/test_freerdp
|
||||
client/X11/xfreerdp
|
||||
client/Mac/xcode
|
||||
|
@ -28,6 +28,7 @@ set(CMAKE_COLOR_MAKEFILE ON)
|
||||
include(CheckIncludeFiles)
|
||||
include(CheckLibraryExists)
|
||||
include(CheckStructHasMember)
|
||||
include(CMakeDetermineSystem)
|
||||
include(FindPkgConfig)
|
||||
include(TestBigEndian)
|
||||
|
||||
@ -36,6 +37,7 @@ set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake/)
|
||||
|
||||
include(AutoVersioning)
|
||||
include(ConfigOptions)
|
||||
include(ComplexLibrary)
|
||||
include(BuildFeatureCheck)
|
||||
include(FindOptionalPackage)
|
||||
include(CheckCCompilerFlag)
|
||||
@ -64,10 +66,6 @@ if(NOT DEFINED BUILD_SHARED_LIBS)
|
||||
set(BUILD_SHARED_LIBS ON)
|
||||
endif()
|
||||
|
||||
if(NOT BUILD_SHARED_LIBS AND MONOLITHIC_BUILD)
|
||||
set(STATIC_CHANNELS ON)
|
||||
endif()
|
||||
|
||||
# Configure MSVC Runtime
|
||||
if(MSVC)
|
||||
include(MSVCRuntime)
|
||||
@ -97,12 +95,12 @@ if(CMAKE_COMPILER_IS_GNUCC)
|
||||
set(CMAKE_C_FLAGS_RELEASE "-DNDEBUG")
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O2")
|
||||
endif()
|
||||
if(WITH_SSE2_TARGET)
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -msse2")
|
||||
endif()
|
||||
if(${CMAKE_VERSION} VERSION_LESS 2.8.8)
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC")
|
||||
endif()
|
||||
if(WITH_SSE2)
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -msse2")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(MSVC)
|
||||
@ -125,18 +123,10 @@ if(MSVC)
|
||||
SET(LIBRARY_OUTPUT_PATH ${PROJECT_BINARY_DIR})
|
||||
endif()
|
||||
|
||||
# config.h definition for installable headers
|
||||
check_include_files(limits.h FREERDP_HAVE_LIMITS_H)
|
||||
check_include_files(stdint.h FREERDP_HAVE_STDINT_H)
|
||||
check_include_files(stdbool.h FREERDP_HAVE_STDBOOL_H)
|
||||
check_include_files(inttypes.h FREERDP_HAVE_INTTYPES_H)
|
||||
|
||||
# Include files
|
||||
check_include_files(fcntl.h HAVE_FCNTL_H)
|
||||
check_include_files(unistd.h HAVE_UNISTD_H)
|
||||
check_include_files(limits.h HAVE_LIMITS_H)
|
||||
check_include_files(stdint.h HAVE_STDINT_H)
|
||||
check_include_files(stdbool.h HAVE_STDBOOL_H)
|
||||
check_include_files(inttypes.h HAVE_INTTYPES_H)
|
||||
check_include_files(sys/modem.h HAVE_SYS_MODEM_H)
|
||||
check_include_files(sys/filio.h HAVE_SYS_FILIO_H)
|
||||
@ -159,20 +149,37 @@ if(APPLE)
|
||||
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl-framework,CoreFoundation")
|
||||
endif()
|
||||
|
||||
# Android
|
||||
if(ANDROID)
|
||||
set(WITH_X11 OFF)
|
||||
set(WITH_CUPS OFF)
|
||||
set(WITH_ALSA OFF)
|
||||
set(WITH_PULSEAUDIO OFF)
|
||||
set(WITH_FFMPEG OFF)
|
||||
set(WITH_GSTREAMER OFF)
|
||||
set(WITH_PCSC OFF)
|
||||
endif()
|
||||
|
||||
if(NOT WIN32)
|
||||
find_required_package(ZLIB)
|
||||
find_optional_package(PulseAudio)
|
||||
find_optional_package(MacAudio)
|
||||
find_optional_package(PCSC)
|
||||
find_suggested_package(Cups)
|
||||
|
||||
if(NOT ANDROID)
|
||||
find_suggested_package(Cups)
|
||||
endif()
|
||||
|
||||
if(NOT APPLE)
|
||||
find_suggested_package(FFmpeg)
|
||||
find_suggested_package(XRandR)
|
||||
find_suggested_package(Gstreamer)
|
||||
find_suggested_package(ALSA)
|
||||
else(NOT APPLE)
|
||||
find_optional_package(FFmpeg)
|
||||
if(NOT ANDROID)
|
||||
find_suggested_package(ALSA)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(NOT ANDROID)
|
||||
find_suggested_package(FFmpeg)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
@ -206,7 +213,12 @@ include_directories(${CMAKE_CURRENT_SOURCE_DIR}/include)
|
||||
# Configure files
|
||||
add_definitions("-DHAVE_CONFIG_H")
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/config.h.in ${CMAKE_CURRENT_SOURCE_DIR}/config.h)
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/include/freerdp/config.h.in ${CMAKE_CURRENT_SOURCE_DIR}/include/freerdp/config.h)
|
||||
|
||||
# RPATH configuration
|
||||
set(CMAKE_SKIP_BUILD_RPATH FALSE)
|
||||
set(CMAKE_BUILD_WITH_INSTALL_RPATH FALSE)
|
||||
set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)
|
||||
set(CMAKE_INSTALL_RPATH "\$ORIGIN/../${CMAKE_INSTALL_LIBDIR}")
|
||||
|
||||
# Unit Tests
|
||||
|
||||
|
@ -17,6 +17,64 @@
|
||||
|
||||
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
|
||||
|
||||
macro(add_channel_client _channel_prefix _channel_name)
|
||||
add_subdirectory(client)
|
||||
if(${_channel_prefix}_CLIENT_STATIC)
|
||||
set(CHANNEL_STATIC_CLIENT_MODULES ${CHANNEL_STATIC_CLIENT_MODULES} ${_channel_prefix} PARENT_SCOPE)
|
||||
set(${_channel_prefix}_CLIENT_NAME ${${_channel_prefix}_CLIENT_NAME} PARENT_SCOPE)
|
||||
set(${_channel_prefix}_CLIENT_CHANNEL ${${_channel_prefix}_CLIENT_CHANNEL} PARENT_SCOPE)
|
||||
set(${_channel_prefix}_CLIENT_ENTRY ${${_channel_prefix}_CLIENT_ENTRY} PARENT_SCOPE)
|
||||
set(CHANNEL_STATIC_CLIENT_ENTRIES ${CHANNEL_STATIC_CLIENT_ENTRIES} ${${_channel_prefix}_CLIENT_ENTRY} PARENT_SCOPE)
|
||||
endif()
|
||||
endmacro(add_channel_client)
|
||||
|
||||
macro(add_channel_server _channel_prefix _channel_name)
|
||||
add_subdirectory(server)
|
||||
if(${_channel_prefix}_SERVER_STATIC)
|
||||
set(CHANNEL_STATIC_SERVER_MODULES ${CHANNEL_STATIC_SERVER_MODULES} ${_channel_prefix} PARENT_SCOPE)
|
||||
set(${_channel_prefix}_SERVER_NAME ${${_channel_prefix}_SERVER_NAME} PARENT_SCOPE)
|
||||
set(${_channel_prefix}_SERVER_CHANNEL ${${_channel_prefix}_SERVER_CHANNEL} PARENT_SCOPE)
|
||||
set(${_channel_prefix}_SERVER_ENTRY ${${_channel_prefix}_SERVER_ENTRY} PARENT_SCOPE)
|
||||
set(CHANNEL_STATIC_SERVER_ENTRIES ${CHANNEL_STATIC_SERVER_ENTRIES} ${${_channel_prefix}_SERVER_ENTRY} PARENT_SCOPE)
|
||||
endif()
|
||||
endmacro(add_channel_server)
|
||||
|
||||
macro(add_channel_client_library _module_prefix _module_name _channel_name _plugin _entry)
|
||||
|
||||
if(_plugin AND MSVC AND (NOT STATIC_CHANNELS))
|
||||
set(${_module_prefix}_SRCS ${${_module_prefix}_SRCS} module.def)
|
||||
endif()
|
||||
|
||||
if(_plugin AND (NOT STATIC_CHANNELS))
|
||||
add_library(${_module_name} ${${_module_prefix}_SRCS})
|
||||
else()
|
||||
set(${_module_prefix}_STATIC ON PARENT_SCOPE)
|
||||
set(${_module_prefix}_NAME ${_module_name} PARENT_SCOPE)
|
||||
set(${_module_prefix}_CHANNEL ${_channel_name} PARENT_SCOPE)
|
||||
set(${_module_prefix}_ENTRY ${_entry} PARENT_SCOPE)
|
||||
add_library(${_module_name} STATIC ${${_module_prefix}_SRCS})
|
||||
endif()
|
||||
|
||||
endmacro(add_channel_client_library)
|
||||
|
||||
macro(add_channel_server_library _module_prefix _module_name _channel_name _plugin _entry)
|
||||
|
||||
if(_plugin AND MSVC AND (NOT STATIC_CHANNELS))
|
||||
set(${_module_prefix}_SRCS ${${_module_prefix}_SRCS} module.def)
|
||||
endif()
|
||||
|
||||
if(_plugin AND (NOT STATIC_CHANNELS))
|
||||
add_library(${_module_name} ${${_module_prefix}_SRCS})
|
||||
else()
|
||||
set(${_module_prefix}_STATIC ON PARENT_SCOPE)
|
||||
set(${_module_prefix}_NAME ${_module_name} PARENT_SCOPE)
|
||||
set(${_module_prefix}_CHANNEL ${_channel_name} PARENT_SCOPE)
|
||||
set(${_module_prefix}_ENTRY ${_entry} PARENT_SCOPE)
|
||||
add_library(${_module_name} STATIC ${${_module_prefix}_SRCS})
|
||||
endif()
|
||||
|
||||
endmacro(add_channel_server_library)
|
||||
|
||||
set(FILENAME "ChannelOptions.cmake")
|
||||
file(GLOB FILEPATHS RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "*/${FILENAME}")
|
||||
|
||||
|
@ -15,17 +15,14 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "audin")
|
||||
set(MODULE_PREFIX "CHANNEL_AUDIN")
|
||||
set(CHANNEL_NAME "audin")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
if(WITH_SERVER_CHANNELS)
|
||||
add_subdirectory(server)
|
||||
set(${MODULE_PREFIX}_SERVER_SRCS ${${MODULE_PREFIX}_SERVER_SRCS} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_SERVER_LIBS ${${MODULE_PREFIX}_SERVER_LIBS} PARENT_SCOPE)
|
||||
set(CHANNEL_BUILTIN_SERVER_MODULES ${CHANNEL_BUILTIN_SERVER_MODULES} ${MODULE_NAME} PARENT_SCOPE)
|
||||
add_channel_server(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
|
@ -15,8 +15,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "audin")
|
||||
set(MODULE_PREFIX "CHANNEL_AUDIN_CLIENT")
|
||||
set(CHANNEL_NAME "audin")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
audin_main.c
|
||||
@ -24,16 +25,20 @@ set(${MODULE_PREFIX}_SRCS
|
||||
|
||||
include_directories(..)
|
||||
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} TRUE "DVCPluginEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
if(NOT STATIC_CHANNELS)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
endif()
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
||||
|
@ -523,6 +523,10 @@ static BOOL audin_process_plugin_data(IWTSPlugin* pPlugin, RDP_PLUGIN_DATA* data
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
#ifdef STATIC_CHANNELS
|
||||
#define DVCPluginEntry audin_DVCPluginEntry
|
||||
#endif
|
||||
|
||||
int DVCPluginEntry(IDRDYNVC_ENTRY_POINTS* pEntryPoints)
|
||||
{
|
||||
int error = 0;
|
||||
@ -546,4 +550,3 @@ int DVCPluginEntry(IDRDYNVC_ENTRY_POINTS* pEntryPoints)
|
||||
|
||||
return error;
|
||||
}
|
||||
|
||||
|
@ -15,14 +15,20 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_PREFIX "CHANNEL_AUDIN_SERVER")
|
||||
set(CHANNEL_NAME "audin")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}-server")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_SERVER" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
audin.c
|
||||
PARENT_SCOPE)
|
||||
audin.c)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS freerdp PARENT_SCOPE)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS freerdp-utils freerdp-channels PARENT_SCOPE)
|
||||
endif()
|
||||
add_channel_server_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} FALSE "DVCPluginEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${CHANNEL}/Server")
|
||||
|
@ -23,36 +23,57 @@ set(${MODULE_PREFIX}_SRCS
|
||||
tables.h
|
||||
channels.c)
|
||||
|
||||
foreach(STATIC_MODULE ${CHANNEL_STATIC_CLIENT_MODULES})
|
||||
|
||||
set(STATIC_MODULE_NAME ${${STATIC_MODULE}_CLIENT_NAME})
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} ${STATIC_MODULE_NAME})
|
||||
|
||||
if(${${STATIC_MODULE}_CLIENT_ENTRY} STREQUAL "VirtualChannelEntry")
|
||||
set(ENTRY_POINT_NAME "${${STATIC_MODULE}_CLIENT_NAME}_${${STATIC_MODULE}_CLIENT_ENTRY}")
|
||||
set(ENTRY_POINT_IMPORT "extern int ${ENTRY_POINT_NAME}(PCHANNEL_ENTRY_POINTS pEntryPoints);")
|
||||
set(VIRTUAL_CHANNEL_ENTRY_IMPORTS "${VIRTUAL_CHANNEL_ENTRY_IMPORTS}\n${ENTRY_POINT_IMPORT}")
|
||||
set(VIRTUAL_CHANNEL_ENTRY_TABLE "${VIRTUAL_CHANNEL_ENTRY_TABLE}\n\t{ \"${STATIC_MODULE_NAME}\", ${ENTRY_POINT_NAME} },")
|
||||
endif()
|
||||
|
||||
if(${${STATIC_MODULE}_CLIENT_ENTRY} STREQUAL "DeviceServiceEntry")
|
||||
set(ENTRY_POINT_NAME "${${STATIC_MODULE}_CLIENT_NAME}_${${STATIC_MODULE}_CLIENT_ENTRY}")
|
||||
set(ENTRY_POINT_IMPORT "extern int ${ENTRY_POINT_NAME}(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints);")
|
||||
set(DEVICE_SERVICE_ENTRY_IMPORTS "${DEVICE_SERVICE_ENTRY_IMPORTS}\n${ENTRY_POINT_IMPORT}")
|
||||
set(DEVICE_SERVICE_ENTRY_TABLE "${DEVICE_SERVICE_ENTRY_TABLE}\n\t{ \"${STATIC_MODULE_NAME}\", ${ENTRY_POINT_NAME} },")
|
||||
endif()
|
||||
list(REMOVE_DUPLICATES CHANNEL_STATIC_CLIENT_ENTRIES)
|
||||
|
||||
foreach(STATIC_ENTRY ${CHANNEL_STATIC_CLIENT_ENTRIES})
|
||||
|
||||
foreach(STATIC_MODULE ${CHANNEL_STATIC_CLIENT_MODULES})
|
||||
|
||||
if(${${STATIC_MODULE}_CLIENT_ENTRY} STREQUAL ${STATIC_ENTRY})
|
||||
set(STATIC_MODULE_NAME ${${STATIC_MODULE}_CLIENT_NAME})
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} ${STATIC_MODULE_NAME})
|
||||
|
||||
set(ENTRY_POINT_NAME "${${STATIC_MODULE}_CLIENT_NAME}_${${STATIC_MODULE}_CLIENT_ENTRY}")
|
||||
set(ENTRY_POINT_IMPORT "extern void ${ENTRY_POINT_NAME}();")
|
||||
set(${STATIC_ENTRY}_IMPORTS "${${STATIC_ENTRY}_IMPORTS}\n${ENTRY_POINT_IMPORT}")
|
||||
set(${STATIC_ENTRY}_TABLE "${${STATIC_ENTRY}_TABLE}\n\t{ \"${STATIC_MODULE_NAME}\", ${ENTRY_POINT_NAME} },")
|
||||
endif()
|
||||
|
||||
endforeach()
|
||||
|
||||
endforeach()
|
||||
|
||||
set(VIRTUAL_CHANNEL_ENTRY_TABLE "${VIRTUAL_CHANNEL_ENTRY_TABLE}\n\t{ \"\", NULL }")
|
||||
set(DEVICE_SERVICE_ENTRY_TABLE "${DEVICE_SERVICE_ENTRY_TABLE}\n\t{ \"\", NULL }")
|
||||
set(CLIENT_STATIC_ENTRY_TABLES_LIST "${CLIENT_STATIC_ENTRY_TABLES_LIST}\nconst STATIC_ENTRY_TABLE CLIENT_STATIC_ENTRY_TABLES[] =\n{")
|
||||
|
||||
foreach(STATIC_ENTRY ${CHANNEL_STATIC_CLIENT_ENTRIES})
|
||||
|
||||
set(CLIENT_STATIC_ENTRY_IMPORTS "${CLIENT_STATIC_ENTRY_IMPORTS}\n${${STATIC_ENTRY}_IMPORTS}")
|
||||
|
||||
set(CLIENT_STATIC_ENTRY_TABLES "${CLIENT_STATIC_ENTRY_TABLES}\nconst STATIC_ENTRY CLIENT_${STATIC_ENTRY}_TABLE[] =\n{")
|
||||
set(CLIENT_STATIC_ENTRY_TABLES "${CLIENT_STATIC_ENTRY_TABLES}\n${${STATIC_ENTRY}_TABLE}")
|
||||
set(CLIENT_STATIC_ENTRY_TABLES "${CLIENT_STATIC_ENTRY_TABLES}\n\t{ \"\", NULL }\n};")
|
||||
|
||||
set(CLIENT_STATIC_ENTRY_TABLES_LIST "${CLIENT_STATIC_ENTRY_TABLES_LIST}\n\t{ \"${STATIC_ENTRY}\", CLIENT_${STATIC_ENTRY}_TABLE },")
|
||||
endforeach()
|
||||
|
||||
set(CLIENT_STATIC_ENTRY_TABLES_LIST "${CLIENT_STATIC_ENTRY_TABLES_LIST}\n\t{ \"\", NULL }\n};")
|
||||
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/tables.c.in ${CMAKE_CURRENT_SOURCE_DIR}/tables.c)
|
||||
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
add_library(${MODULE_NAME} STATIC ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD} INTERNAL
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt winpr-synch winpr-interlocked)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -18,14 +18,11 @@
|
||||
*/
|
||||
|
||||
#include "tables.h"
|
||||
${VIRTUAL_CHANNEL_ENTRY_IMPORTS}
|
||||
${DEVICE_SERVICE_ENTRY_IMPORTS}
|
||||
|
||||
const VIRTUAL_CHANNEL_ENTRY VIRTUAL_CHANNEL_TABLE[] =
|
||||
{${VIRTUAL_CHANNEL_ENTRY_TABLE}
|
||||
};
|
||||
${CLIENT_STATIC_ENTRY_IMPORTS}
|
||||
|
||||
${CLIENT_STATIC_ENTRY_TABLES}
|
||||
|
||||
${CLIENT_STATIC_ENTRY_TABLES_LIST}
|
||||
|
||||
const DEVICE_SERVICE_ENTRY DEVICE_SERVICE_TABLE[] =
|
||||
{${DEVICE_SERVICE_ENTRY_TABLE}
|
||||
};
|
||||
|
||||
|
@ -19,24 +19,16 @@
|
||||
|
||||
#include <freerdp/svc.h>
|
||||
|
||||
#ifndef PDEVICE_SERVICE_ENTRY_POINTS
|
||||
#define PDEVICE_SERVICE_ENTRY_POINTS void*
|
||||
#endif
|
||||
|
||||
typedef int (*VIRTUAL_CHANNEL_ENTRY_FN)(PCHANNEL_ENTRY_POINTS pEntryPoints);
|
||||
typedef int (*DEVICE_SERVICE_ENTRY_FN)(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints);
|
||||
|
||||
struct _VIRTUAL_CHANNEL_ENTRY
|
||||
struct _STATIC_ENTRY
|
||||
{
|
||||
const char* name;
|
||||
const VIRTUAL_CHANNEL_ENTRY_FN entry;
|
||||
const void* entry;
|
||||
};
|
||||
typedef struct _VIRTUAL_CHANNEL_ENTRY VIRTUAL_CHANNEL_ENTRY;
|
||||
typedef struct _STATIC_ENTRY STATIC_ENTRY;
|
||||
|
||||
struct _DEVICE_SERVICE_ENTRY
|
||||
struct _STATIC_ENTRY_TABLE
|
||||
{
|
||||
const char* name;
|
||||
const DEVICE_SERVICE_ENTRY_FN entry;
|
||||
const STATIC_ENTRY* table;
|
||||
};
|
||||
typedef struct _DEVICE_SERVICE_ENTRY DEVICE_SERVICE_ENTRY;
|
||||
|
||||
typedef struct _STATIC_ENTRY_TABLE STATIC_ENTRY_TABLE;
|
||||
|
@ -15,15 +15,11 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "cliprdr")
|
||||
set(MODULE_PREFIX "CHANNEL_CLIPRDR")
|
||||
set(CHANNEL_NAME "cliprdr")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
if(${MODULE_PREFIX}_CLIENT_STATIC)
|
||||
set(CHANNEL_STATIC_CLIENT_MODULES ${CHANNEL_STATIC_CLIENT_MODULES} ${MODULE_PREFIX} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_NAME ${${MODULE_PREFIX}_CLIENT_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_ENTRY ${${MODULE_PREFIX}_CLIENT_ENTRY} PARENT_SCOPE)
|
||||
endif()
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
|
@ -15,8 +15,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "cliprdr")
|
||||
set(MODULE_PREFIX "CHANNEL_CLIPRDR_CLIENT")
|
||||
set(CHANNEL_NAME "cliprdr")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
cliprdr_constants.h
|
||||
@ -25,22 +26,22 @@ set(${MODULE_PREFIX}_SRCS
|
||||
cliprdr_main.c
|
||||
cliprdr_main.h)
|
||||
|
||||
# cliprdr is always built-in
|
||||
|
||||
set(${MODULE_PREFIX}_STATIC ON PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_NAME ${MODULE_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_ENTRY "VirtualChannelEntry" PARENT_SCOPE)
|
||||
|
||||
add_library(${MODULE_NAME} STATIC ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} FALSE "VirtualChannelEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp winpr)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils winpr-crt)
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt)
|
||||
|
||||
if(NOT STATIC_CHANNELS)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
endif()
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
@ -15,15 +15,10 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "disk")
|
||||
set(MODULE_PREFIX "CHANNEL_RDPDR_DISK")
|
||||
set(CHANNEL_NAME "disk")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
if(${MODULE_PREFIX}_CLIENT_STATIC)
|
||||
set(CHANNEL_STATIC_CLIENT_MODULES ${CHANNEL_STATIC_CLIENT_MODULES} ${MODULE_PREFIX} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_NAME ${${MODULE_PREFIX}_CLIENT_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_ENTRY ${${MODULE_PREFIX}_CLIENT_ENTRY} PARENT_SCOPE)
|
||||
endif()
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
|
@ -6,6 +6,10 @@ set(CHANNEL_SPECIFICATIONS "[MS-RDPEFS]")
|
||||
|
||||
string(TOUPPER "WITH_${CHANNEL_SHORT_NAME}" CHANNEL_OPTION)
|
||||
|
||||
option(${CHANNEL_OPTION} "Build ${CHANNEL_SHORT_NAME}" ON)
|
||||
if(ANDROID)
|
||||
option(${CHANNEL_OPTION} "Build ${CHANNEL_SHORT_NAME}" OFF)
|
||||
else()
|
||||
option(${CHANNEL_OPTION} "Build ${CHANNEL_SHORT_NAME}" ON)
|
||||
endif()
|
||||
|
||||
|
||||
|
@ -15,8 +15,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "disk")
|
||||
set(MODULE_PREFIX "CHANNEL_RDPDR_DISK_CLIENT")
|
||||
set(CHANNEL_NAME "disk")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
disk_file.c
|
||||
@ -30,31 +31,25 @@ if(WIN32)
|
||||
dirent.h)
|
||||
endif()
|
||||
|
||||
if(MSVC AND (NOT STATIC_CHANNELS))
|
||||
set(${MODULE_PREFIX}_SRCS ${${MODULE_PREFIX}_SRCS} module.def)
|
||||
endif()
|
||||
|
||||
if(NOT STATIC_CHANNELS)
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
else()
|
||||
set(${MODULE_PREFIX}_STATIC ON PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_NAME ${MODULE_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_ENTRY "DeviceServiceEntry" PARENT_SCOPE)
|
||||
|
||||
add_library(${MODULE_NAME} STATIC ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} TRUE "DeviceServiceEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS freerdp winpr)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS freerdp-utils winpr-crt winpr-synch winpr-thread winpr-interlocked)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt winpr-synch winpr-thread winpr-interlocked)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
if(NOT STATIC_CHANNELS)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
endif()
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
||||
|
@ -55,6 +55,11 @@
|
||||
|
||||
#include "disk_file.h"
|
||||
|
||||
#ifdef _WIN32
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable: 4244)
|
||||
#endif
|
||||
|
||||
static BOOL disk_file_wildcard_match(const char* pattern, const char* filename)
|
||||
{
|
||||
const char *p = pattern, *f = filename;
|
||||
@ -455,6 +460,8 @@ BOOL disk_file_set_information(DISK_FILE* file, UINT32 FsInformationClass, UINT3
|
||||
UINT32 FileAttributes;
|
||||
UINT32 FileNameLength;
|
||||
|
||||
m = 0;
|
||||
|
||||
switch (FsInformationClass)
|
||||
{
|
||||
case FileBasicInformation:
|
||||
@ -692,3 +699,7 @@ BOOL disk_file_query_directory(DISK_FILE* file, UINT32 FsInformationClass, BYTE
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
|
@ -32,8 +32,12 @@
|
||||
#include "statvfs.h"
|
||||
#else
|
||||
#include <dirent.h>
|
||||
#ifdef ANDROID
|
||||
#include <sys/vfs.h>
|
||||
#else
|
||||
#include <sys/statvfs.h>
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef _WIN32
|
||||
#define STAT stat
|
||||
@ -49,8 +53,8 @@
|
||||
#define unlink(a) _unlink(a)
|
||||
#define ftruncate(a,b) _chsize(a,b)
|
||||
|
||||
typedef UINT32 ssize_t ;
|
||||
typedef UINT32 mode_t ;
|
||||
typedef UINT32 ssize_t;
|
||||
typedef UINT32 mode_t;
|
||||
|
||||
#elif defined(__APPLE__) || defined(__FreeBSD__)
|
||||
#define STAT stat
|
||||
|
@ -15,15 +15,11 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "drdynvc")
|
||||
set(MODULE_PREFIX "CHANNEL_DRDYNVC")
|
||||
set(CHANNEL_NAME "drdynvc")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
if(${MODULE_PREFIX}_CLIENT_STATIC)
|
||||
set(CHANNEL_STATIC_CLIENT_MODULES ${CHANNEL_STATIC_CLIENT_MODULES} ${MODULE_PREFIX} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_NAME ${${MODULE_PREFIX}_CLIENT_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_ENTRY ${${MODULE_PREFIX}_CLIENT_ENTRY} PARENT_SCOPE)
|
||||
endif()
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
|
@ -15,8 +15,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "drdynvc")
|
||||
set(MODULE_PREFIX "CHANNEL_DRDYNVC_CLIENT")
|
||||
set(CHANNEL_NAME "drdynvc")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
drdynvc_main.c
|
||||
@ -25,21 +26,19 @@ set(${MODULE_PREFIX}_SRCS
|
||||
dvcman.c
|
||||
dvcman.h)
|
||||
|
||||
# drdynvc is always built-in
|
||||
|
||||
set(${MODULE_PREFIX}_STATIC ON PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_NAME ${MODULE_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_ENTRY "VirtualChannelEntry" PARENT_SCOPE)
|
||||
|
||||
add_library(${MODULE_NAME} STATIC ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} FALSE "VirtualChannelEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp winpr)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils winpr-synch)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-synch)
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
||||
|
@ -15,7 +15,10 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
endif()
|
||||
set(CHANNEL_NAME "parallel")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
@ -15,22 +15,31 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "parallel")
|
||||
set(MODULE_PREFIX "CHANNEL_RDPDR_PARALLEL_CLIENT")
|
||||
set(CHANNEL_NAME "parallel")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
parallel_main.c)
|
||||
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} TRUE "DeviceServiceEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils winpr-interlocked)
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-interlocked)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
if(NOT STATIC_CHANNELS)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
endif()
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
@ -307,6 +307,10 @@ static void parallel_free(DEVICE* device)
|
||||
free(parallel);
|
||||
}
|
||||
|
||||
#ifdef STATIC_CHANNELS
|
||||
#define DeviceServiceEntry parallel_DeviceServiceEntry
|
||||
#endif
|
||||
|
||||
int DeviceServiceEntry(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints)
|
||||
{
|
||||
char* name;
|
||||
|
@ -15,7 +15,10 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
endif()
|
||||
set(CHANNEL_NAME "printer")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
@ -15,8 +15,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "printer")
|
||||
set(MODULE_PREFIX "CHANNEL_RDPDR_PRINTER_CLIENT")
|
||||
set(CHANNEL_NAME "printer")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
printer_main.c
|
||||
@ -37,20 +38,28 @@ if(WIN32)
|
||||
printer_win.h)
|
||||
endif()
|
||||
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} TRUE "DeviceServiceEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp winpr)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils winpr-crt winpr-synch winpr-thread winpr-interlocked)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt winpr-synch winpr-thread winpr-interlocked)
|
||||
|
||||
if(WITH_CUPS)
|
||||
target_link_libraries(${MODULE_NAME} ${CUPS_LIBRARIES})
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} ${CUPS_LIBRARIES})
|
||||
endif()
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
if(NOT STATIC_CHANNELS)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
endif()
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
@ -301,10 +301,10 @@ void printer_register(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints, rdpPrinter* pri
|
||||
}
|
||||
|
||||
#ifdef STATIC_CHANNELS
|
||||
int printer_entry(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints)
|
||||
#else
|
||||
int DeviceServiceEntry(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints)
|
||||
#define DeviceServiceEntry printer_DeviceServiceEntry
|
||||
#endif
|
||||
|
||||
int DeviceServiceEntry(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints)
|
||||
{
|
||||
int i;
|
||||
char* name;
|
||||
|
@ -15,12 +15,10 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
if(${MODULE_PREFIX}_CLIENT_STATIC)
|
||||
set(CHANNEL_STATIC_CLIENT_MODULES ${CHANNEL_STATIC_CLIENT_MODULES} ${MODULE_PREFIX} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_NAME ${${MODULE_PREFIX}_CLIENT_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_ENTRY ${${MODULE_PREFIX}_CLIENT_ENTRY} PARENT_SCOPE)
|
||||
endif()
|
||||
endif()
|
||||
set(CHANNEL_NAME "rail")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
@ -15,8 +15,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "rail")
|
||||
set(MODULE_PREFIX "CHANNEL_RAIL_CLIENT")
|
||||
set(CHANNEL_NAME "rail")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
rail_main.c
|
||||
@ -24,23 +25,16 @@ set(${MODULE_PREFIX}_SRCS
|
||||
rail_orders.c
|
||||
rail_orders.h)
|
||||
|
||||
# rail is always built-in
|
||||
|
||||
set(${MODULE_PREFIX}_STATIC ON PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_NAME ${MODULE_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_ENTRY "VirtualChannelEntry" PARENT_SCOPE)
|
||||
|
||||
add_library(${MODULE_NAME} STATIC ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} FALSE "VirtualChannelEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
||||
|
@ -15,15 +15,10 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "rdpdr")
|
||||
set(MODULE_PREFIX "CHANNEL_RDPDR")
|
||||
set(CHANNEL_NAME "rdpdr")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
if(${MODULE_PREFIX}_CLIENT_STATIC)
|
||||
set(CHANNEL_STATIC_CLIENT_MODULES ${CHANNEL_STATIC_CLIENT_MODULES} ${MODULE_PREFIX} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_NAME ${${MODULE_PREFIX}_CLIENT_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_ENTRY ${${MODULE_PREFIX}_CLIENT_ENTRY} PARENT_SCOPE)
|
||||
endif()
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
|
@ -15,8 +15,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "rdpdr")
|
||||
set(MODULE_PREFIX "CHANNEL_RDPDR_CLIENT")
|
||||
set(CHANNEL_NAME "rdpdr")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
irp.c
|
||||
@ -28,21 +29,20 @@ set(${MODULE_PREFIX}_SRCS
|
||||
rdpdr_capabilities.c
|
||||
rdpdr_capabilities.h)
|
||||
|
||||
# rdpdr is always built-in
|
||||
|
||||
set(${MODULE_PREFIX}_STATIC ON PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_NAME ${MODULE_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_ENTRY "VirtualChannelEntry" PARENT_SCOPE)
|
||||
|
||||
add_library(${MODULE_NAME} STATIC ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} FALSE "VirtualChannelEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp winpr)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils winpr-crt winpr-synch winpr-thread winpr-interlocked)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt winpr-synch winpr-thread winpr-interlocked)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
||||
|
@ -76,7 +76,7 @@ BOOL devman_load_device_service(DEVMAN* devman, RDP_PLUGIN_DATA* plugin_data)
|
||||
PDEVICE_SERVICE_ENTRY entry = NULL;
|
||||
|
||||
name = (char*) plugin_data->data[0];
|
||||
entry = (PDEVICE_SERVICE_ENTRY) freerdp_channels_find_static_device_service_entry(name);
|
||||
entry = (PDEVICE_SERVICE_ENTRY) freerdp_channels_client_find_static_entry("DeviceServiceEntry", name);
|
||||
|
||||
if (!entry)
|
||||
{
|
||||
|
@ -15,23 +15,14 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "rdpsnd")
|
||||
set(MODULE_PREFIX "CHANNEL_RDPSND")
|
||||
set(CHANNEL_NAME "rdpsnd")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
if(${MODULE_PREFIX}_CLIENT_STATIC)
|
||||
set(CHANNEL_STATIC_CLIENT_MODULES ${CHANNEL_STATIC_CLIENT_MODULES} ${MODULE_PREFIX} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_NAME ${${MODULE_PREFIX}_CLIENT_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_CLIENT_ENTRY ${${MODULE_PREFIX}_CLIENT_ENTRY} PARENT_SCOPE)
|
||||
endif()
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
if(WITH_SERVER_CHANNELS)
|
||||
add_subdirectory(server)
|
||||
set(${MODULE_PREFIX}_SERVER_SRCS ${${MODULE_PREFIX}_SERVER_SRCS} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_SERVER_LIBS ${${MODULE_PREFIX}_SERVER_LIBS} PARENT_SCOPE)
|
||||
set(CHANNEL_BUILTIN_SERVER_MODULES ${CHANNEL_BUILTIN_SERVER_MODULES} ${MODULE_NAME} PARENT_SCOPE)
|
||||
add_channel_server(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
|
||||
|
@ -6,9 +6,5 @@ set(CHANNEL_SPECIFICATIONS "[MS-RDPEA]")
|
||||
|
||||
string(TOUPPER "WITH_${CHANNEL_SHORT_NAME}" CHANNEL_OPTION)
|
||||
|
||||
if(WIN32)
|
||||
option(${CHANNEL_OPTION} "Build ${CHANNEL_SHORT_NAME}" OFF)
|
||||
else()
|
||||
option(${CHANNEL_OPTION} "Build ${CHANNEL_SHORT_NAME}" ON)
|
||||
endif()
|
||||
option(${CHANNEL_OPTION} "Build ${CHANNEL_SHORT_NAME}" ON)
|
||||
|
||||
|
@ -15,30 +15,24 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "rdpsnd")
|
||||
set(MODULE_PREFIX "CHANNEL_RDPSND_CLIENT")
|
||||
set(CHANNEL_NAME "rdpsnd")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
rdpsnd_main.c
|
||||
rdpsnd_main.h)
|
||||
|
||||
# rdpsnd is always built-in
|
||||
|
||||
set(${MODULE_PREFIX}_STATIC ON PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_NAME ${MODULE_NAME} PARENT_SCOPE)
|
||||
set(${MODULE_PREFIX}_ENTRY "VirtualChannelEntry" PARENT_SCOPE)
|
||||
|
||||
add_library(${MODULE_NAME} STATIC ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} FALSE "VirtualChannelEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
||||
|
@ -80,10 +80,25 @@ struct data_out_item
|
||||
/* get time in milliseconds */
|
||||
static UINT32 get_mstime(void)
|
||||
{
|
||||
#ifndef _WIN32
|
||||
struct timeval tp;
|
||||
|
||||
gettimeofday(&tp, 0);
|
||||
return (tp.tv_sec * 1000) + (tp.tv_usec / 1000);
|
||||
#else
|
||||
FILETIME ft;
|
||||
UINT64 time64 = 0;
|
||||
|
||||
GetSystemTimeAsFileTime(&ft);
|
||||
|
||||
time64 |= ft.dwHighDateTime;
|
||||
time64 <<= 32;
|
||||
time64 |= ft.dwLowDateTime;
|
||||
time64 /= 10000;
|
||||
|
||||
/* fix epoch? */
|
||||
|
||||
return (UINT32) time64;
|
||||
#endif
|
||||
}
|
||||
|
||||
/* process the linked list of data that has queued to be sent */
|
||||
|
@ -15,18 +15,22 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "rdpsnd")
|
||||
set(MODULE_PREFIX "CHANNEL_RDPSND_SERVER")
|
||||
set(CHANNEL_NAME "rdpsnd")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}-server")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_SERVER" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
rdpsnd.c
|
||||
PARENT_SCOPE)
|
||||
rdpsnd.c)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS freerdp PARENT_SCOPE)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS freerdp-utils PARENT_SCOPE)
|
||||
endif()
|
||||
add_channel_server_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} FALSE "VirtualChannelEntry")
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Server")
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${CHANNEL}/Server")
|
||||
|
@ -25,6 +25,8 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <winpr/crt.h>
|
||||
|
||||
#include <freerdp/utils/stream.h>
|
||||
#include <freerdp/utils/memory.h>
|
||||
#include <freerdp/utils/dsp.h>
|
||||
@ -127,7 +129,8 @@ static BOOL rdpsnd_server_recv_formats(rdpsnd_server* rdpsnd, STREAM* s)
|
||||
|
||||
if (rdpsnd->context.num_client_formats > 0)
|
||||
{
|
||||
rdpsnd->context.client_formats = xzalloc(rdpsnd->context.num_client_formats * sizeof(rdpsndFormat));
|
||||
rdpsnd->context.client_formats = (rdpsndFormat*) malloc(rdpsnd->context.num_client_formats * sizeof(rdpsndFormat));
|
||||
ZeroMemory(rdpsnd->context.client_formats, sizeof(rdpsndFormat));
|
||||
|
||||
for (i = 0; i < rdpsnd->context.num_client_formats; i++)
|
||||
{
|
||||
@ -290,7 +293,7 @@ static void rdpsnd_server_select_format(rdpsnd_server_context* context, int clie
|
||||
|
||||
if (rdpsnd->out_buffer_size < out_buffer_size)
|
||||
{
|
||||
rdpsnd->out_buffer = realloc(rdpsnd->out_buffer, out_buffer_size);
|
||||
rdpsnd->out_buffer = (BYTE*) realloc(rdpsnd->out_buffer, out_buffer_size);
|
||||
rdpsnd->out_buffer_size = out_buffer_size;
|
||||
}
|
||||
|
||||
|
@ -15,7 +15,11 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(CHANNEL_NAME "sample")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
|
@ -5,5 +5,11 @@ set(CHANNEL_LONG_NAME "Sample Virtual Channel Extension")
|
||||
set(CHANNEL_SPECIFICATIONS "")
|
||||
|
||||
string(TOUPPER "WITH_${CHANNEL_SHORT_NAME}" CHANNEL_OPTION)
|
||||
option(${CHANNEL_OPTION} "Build ${CHANNEL_SHORT_NAME}" OFF)
|
||||
|
||||
if(WITH_SAMPLE)
|
||||
option(${CHANNEL_OPTION} "Build ${CHANNEL_SHORT_NAME}" ON)
|
||||
else()
|
||||
option(${CHANNEL_OPTION} "Build ${CHANNEL_SHORT_NAME}" OFF)
|
||||
endif()
|
||||
|
||||
|
||||
|
@ -15,20 +15,26 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "sample")
|
||||
set(MODULE_PREFIX "CHANNEL_SAMPLE_CLIENT")
|
||||
set(CHANNEL_NAME "sample")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
skel_main.c
|
||||
skel_main.h)
|
||||
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} TRUE "DVCPluginEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils)
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
if(NOT STATIC_CHANNELS)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
endif()
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
||||
|
@ -40,7 +40,7 @@
|
||||
|
||||
#include "skel_main.h"
|
||||
|
||||
struct skel_plugin
|
||||
struct sample_plugin
|
||||
{
|
||||
rdpSvcPlugin plugin;
|
||||
|
||||
@ -48,12 +48,12 @@ struct skel_plugin
|
||||
|
||||
};
|
||||
|
||||
static void skel_process_interval(rdpSvcPlugin* plugin)
|
||||
static void sample_process_interval(rdpSvcPlugin* plugin)
|
||||
{
|
||||
printf("skel_process_interval:\n");
|
||||
}
|
||||
|
||||
static void skel_process_receive(rdpSvcPlugin* plugin, STREAM* data_in)
|
||||
static void sample_process_receive(rdpSvcPlugin* plugin, STREAM* data_in)
|
||||
{
|
||||
skelPlugin* skel = (skelPlugin*)plugin;
|
||||
STREAM* data_out;
|
||||
@ -88,27 +88,27 @@ static void skel_process_receive(rdpSvcPlugin* plugin, STREAM* data_in)
|
||||
stream_free(data_in);
|
||||
}
|
||||
|
||||
static void skel_process_connect(rdpSvcPlugin* plugin)
|
||||
static void sample_process_connect(rdpSvcPlugin* plugin)
|
||||
{
|
||||
skelPlugin* skel = (skelPlugin*)plugin;
|
||||
samplePlugin* sample = (samplePlugin*) plugin;
|
||||
DEBUG_SVC("connecting");
|
||||
|
||||
printf("skel_process_connect:\n");
|
||||
printf("sample_process_connect:\n");
|
||||
|
||||
if (skel == NULL)
|
||||
if (sample == NULL)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
/* if you want a call from channel thread once is a while do this */
|
||||
plugin->interval_ms = 1000;
|
||||
plugin->interval_callback = skel_process_interval;
|
||||
plugin->interval_callback = sample_process_interval;
|
||||
|
||||
}
|
||||
|
||||
static void skel_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event)
|
||||
static void sample_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event)
|
||||
{
|
||||
printf("skel_process_event:\n");
|
||||
printf("sample_process_event:\n");
|
||||
|
||||
/* events comming from main freerdp window to plugin */
|
||||
/* send them back with svc_plugin_send_event */
|
||||
@ -116,11 +116,11 @@ static void skel_process_event(rdpSvcPlugin* plugin, RDP_EVENT* event)
|
||||
freerdp_event_free(event);
|
||||
}
|
||||
|
||||
static void skel_process_terminate(rdpSvcPlugin* plugin)
|
||||
static void sample_process_terminate(rdpSvcPlugin* plugin)
|
||||
{
|
||||
skelPlugin* skel = (skelPlugin*)plugin;
|
||||
|
||||
printf("skel_process_terminate:\n");
|
||||
printf("sample_process_terminate:\n");
|
||||
|
||||
if (skel == NULL)
|
||||
{
|
||||
@ -132,5 +132,27 @@ static void skel_process_terminate(rdpSvcPlugin* plugin)
|
||||
free(plugin);
|
||||
}
|
||||
|
||||
DEFINE_SVC_PLUGIN(skel, "skel",
|
||||
CHANNEL_OPTION_INITIALIZED | CHANNEL_OPTION_ENCRYPT_RDP)
|
||||
#define VirtualChannelEntry sample_VirtualChannelEntry
|
||||
|
||||
const int VirtualChannelEntry(PCHANNEL_ENTRY_POINTS pEntryPoints)
|
||||
{
|
||||
samplePlugin* _p;
|
||||
|
||||
_p = (samplePlugin*) malloc(sizeof(samplePlugin));
|
||||
ZeroMemory(_p, sizeof(samplePlugin));
|
||||
|
||||
_p->plugin.channel_def.options =
|
||||
CHANNEL_OPTION_INITIALIZED |
|
||||
CHANNEL_OPTION_ENCRYPT_RDP;
|
||||
|
||||
strcpy(_p->plugin.channel_def.name, "sample");
|
||||
|
||||
_p->plugin.connect_callback = sample_process_connect;
|
||||
_p->plugin.receive_callback = sample_process_receive;
|
||||
_p->plugin.event_callback = sample_process_event;
|
||||
_p->plugin.terminate_callback = sample_process_terminate;
|
||||
|
||||
svc_plugin_init((rdpSvcPlugin*) _p, pEntryPoints);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
@ -18,9 +18,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef __SKEL_MAIN_H
|
||||
#define __SKEL_MAIN_H
|
||||
#ifndef __SAMPLE_MAIN_H
|
||||
#define __SAMPLE_MAIN_H
|
||||
|
||||
typedef struct skel_plugin skelPlugin;
|
||||
typedef struct sample_plugin samplePlugin;
|
||||
|
||||
#endif /* __SKEL_MAIN_H */
|
||||
#endif /* __SAMPLE_MAIN_H */
|
||||
|
@ -15,7 +15,11 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(CHANNEL_NAME "serial")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
|
@ -15,8 +15,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "serial")
|
||||
set(MODULE_PREFIX "CHANNEL_DEVICE_SERIAL_CLIENT")
|
||||
set(CHANNEL_NAME "serial")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
serial_tty.c
|
||||
@ -24,15 +25,19 @@ set(${MODULE_PREFIX}_SRCS
|
||||
serial_constants.h
|
||||
serial_main.c)
|
||||
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} TRUE "DeviceServiceEntry")
|
||||
|
||||
set_target_properties(serial PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils)
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
if(NOT STATIC_CHANNELS)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
endif()
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
@ -397,6 +397,10 @@ static void serial_free(DEVICE* device)
|
||||
free(serial);
|
||||
}
|
||||
|
||||
#ifdef STATIC_CHANNELS
|
||||
#define DeviceServiceEntry serial_DeviceServiceEntry
|
||||
#endif
|
||||
|
||||
int DeviceServiceEntry(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints)
|
||||
{
|
||||
int i, len;
|
||||
|
@ -18,23 +18,32 @@
|
||||
set(MODULE_NAME "freerdp-channels-server")
|
||||
set(MODULE_PREFIX "FREERDP_CHANNELS_SERVER")
|
||||
|
||||
foreach(_MODULE_NAME ${CHANNEL_BUILTIN_SERVER_MODULES})
|
||||
string(TOUPPER "CHANNEL_${_MODULE_NAME}" _MODULE_PREFIX)
|
||||
message(STATUS "Adding built-in channel server module: ${_MODULE_NAME}")
|
||||
|
||||
foreach(SRC ${${_MODULE_PREFIX}_SERVER_SRCS})
|
||||
set(CHANNEL_SERVER_SRCS ${CHANNEL_SERVER_SRCS} "../${_MODULE_NAME}/server/${SRC}")
|
||||
endforeach()
|
||||
|
||||
set(CHANNEL_SERVER_LIBS ${CHANNEL_SERVER_LIBS} ${${_MODULE_PREFIX}_SERVER_LIBS})
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
channels.c
|
||||
channels.h)
|
||||
|
||||
foreach(STATIC_MODULE ${CHANNEL_STATIC_SERVER_MODULES})
|
||||
set(STATIC_MODULE_NAME ${${STATIC_MODULE}_SERVER_NAME})
|
||||
set(STATIC_MODULE_CHANNEL ${${STATIC_MODULE}_SERVER_CHANNEL})
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} ${STATIC_MODULE_NAME})
|
||||
message(STATUS "Adding static server channel: ${STATIC_MODULE_CHANNEL}")
|
||||
endforeach()
|
||||
|
||||
add_library(${MODULE_NAME} ${CHANNEL_SERVER_SRCS})
|
||||
add_library(${MODULE_NAME} STATIC ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${CHANNEL_SERVER_LIBS})
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD} INTERNAL
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt winpr-synch winpr-interlocked)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/Server")
|
||||
|
||||
|
@ -1,8 +1,9 @@
|
||||
/**
|
||||
* FreeRDP: A Remote Desktop Protocol Implementation
|
||||
* Server Virtual Channel Interface
|
||||
* Server Channels
|
||||
*
|
||||
* Copyright 2011-2012 Vic Lee
|
||||
* Copyright 2012 Marc-Andre Moreau <marcandre.moreau@gmail.com>
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@ -17,20 +18,17 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <freerdp/constants.h>
|
||||
#include <freerdp/utils/memory.h>
|
||||
#include <freerdp/server/channels.h>
|
||||
|
||||
#include <winpr/synch.h>
|
||||
|
||||
#include "wtsvc.h"
|
||||
#include "channels.h"
|
||||
|
||||
#define CREATE_REQUEST_PDU 0x01
|
||||
#define DATA_FIRST_PDU 0x02
|
||||
@ -51,6 +49,11 @@ static void wts_data_item_free(wts_data_item* item)
|
||||
free(item);
|
||||
}
|
||||
|
||||
void* freerdp_channels_server_find_static_entry(const char* name, const char* entry)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static rdpPeerChannel* wts_get_dvc_channel_by_id(WTSVirtualChannelManager* vcm, UINT32 ChannelId)
|
||||
{
|
||||
LIST_ITEM* item;
|
||||
@ -805,3 +808,4 @@ BOOL WTSVirtualChannelClose(
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
@ -1,8 +1,9 @@
|
||||
/**
|
||||
* FreeRDP: A Remote Desktop Protocol Implementation
|
||||
* Server Virtual Channel Interface
|
||||
* Server Channels
|
||||
*
|
||||
* Copyright 2011-2012 Vic Lee
|
||||
* Copyright 2012 Marc-Andre Moreau <marcandre.moreau@gmail.com>
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
@ -15,7 +15,10 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
endif()
|
||||
set(CHANNEL_NAME "smartcard")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
@ -24,17 +24,26 @@ set(${MODULE_PREFIX}_SRCS
|
||||
|
||||
include_directories(${PCSC_INCLUDE_DIRS})
|
||||
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} TRUE "DVCPluginEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp winpr)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils winpr-crt winpr-synch winpr-thread winpr-interlocked)
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt winpr-synch winpr-thread winpr-interlocked)
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} ${PCSC_LIBRARIES})
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
if(NOT STATIC_CHANNELS)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
endif()
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${PCSC_LIBRARIES})
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
@ -282,6 +282,10 @@ static void scard_irp_request(DEVICE* device, IRP* irp)
|
||||
freerdp_thread_signal(scard->thread);
|
||||
}
|
||||
|
||||
#ifdef STATIC_CHANNELS
|
||||
#define DeviceServiceEntry smartcard_DeviceServiceEntry
|
||||
#endif
|
||||
|
||||
int DeviceServiceEntry(PDEVICE_SERVICE_ENTRY_POINTS pEntryPoints)
|
||||
{
|
||||
char* name;
|
||||
|
@ -15,8 +15,12 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(CHANNEL_NAME "tsmf")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
||||
|
||||
|
@ -16,8 +16,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "tsmf")
|
||||
set(MODULE_PREFIX "CHANNEL_TSMF_CLIENT")
|
||||
set(CHANNEL_NAME "tsmf")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
tsmf_audio.c
|
||||
@ -37,16 +38,20 @@ set(${MODULE_PREFIX}_SRCS
|
||||
|
||||
include_directories(..)
|
||||
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} TRUE "DVCPluginEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME} freerdp)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} freerdp-utils)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
if(NOT STATIC_CHANNELS)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
endif()
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
||||
|
@ -1205,7 +1205,7 @@ static BOOL tsmf_gstreamer_decodeEx(ITSMFDecoder * decoder, const BYTE * data, U
|
||||
|
||||
if (fout)
|
||||
{
|
||||
fprintf(fout, "%"PRIu64"\n", start_time);
|
||||
fprintf(fout, "%"PRIu64"\n", (long unsigned int) start_time);
|
||||
fclose(fout);
|
||||
}
|
||||
|
||||
@ -1231,7 +1231,7 @@ static BOOL tsmf_gstreamer_decodeEx(ITSMFDecoder * decoder, const BYTE * data, U
|
||||
if (fin)
|
||||
{
|
||||
UINT64 AStartTime = 0;
|
||||
fscanf(fin, "%"PRIu64, &AStartTime);
|
||||
fscanf(fin, "%"PRIu64, (long unsigned int*) &AStartTime);
|
||||
fclose(fin);
|
||||
if (start_time > AStartTime)
|
||||
{
|
||||
@ -1265,7 +1265,7 @@ static BOOL tsmf_gstreamer_decodeEx(ITSMFDecoder * decoder, const BYTE * data, U
|
||||
if (fin)
|
||||
{
|
||||
UINT64 VStartTime = 0;
|
||||
fscanf(fin, "%"PRIu64, &VStartTime);
|
||||
fscanf(fin, "%"PRIu64, (long unsigned int*) &VStartTime);
|
||||
fclose(fin);
|
||||
if (start_time > VStartTime)
|
||||
{
|
||||
|
@ -425,12 +425,17 @@ static void tsmf_process_plugin_data(IWTSPlugin* pPlugin, RDP_PLUGIN_DATA* data)
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef STATIC_CHANNELS
|
||||
#define DVCPluginEntry tsmf_DVCPluginEntry
|
||||
#endif
|
||||
|
||||
int DVCPluginEntry(IDRDYNVC_ENTRY_POINTS* pEntryPoints)
|
||||
{
|
||||
TSMF_PLUGIN * tsmf;
|
||||
int error = 0;
|
||||
TSMF_PLUGIN* tsmf;
|
||||
|
||||
tsmf = (TSMF_PLUGIN*) pEntryPoints->GetPlugin(pEntryPoints, "tsmf");
|
||||
|
||||
if (tsmf == NULL)
|
||||
{
|
||||
tsmf = xnew(TSMF_PLUGIN);
|
||||
@ -448,6 +453,7 @@ int DVCPluginEntry(IDRDYNVC_ENTRY_POINTS* pEntryPoints)
|
||||
tsmf_process_plugin_data((IWTSPlugin*) tsmf,
|
||||
pEntryPoints->GetPluginData(pEntryPoints));
|
||||
}
|
||||
|
||||
return error;
|
||||
}
|
||||
|
||||
|
@ -15,8 +15,12 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(CHANNEL_NAME "urbdrc")
|
||||
set(MODULE_NAME ${CHANNEL_NAME})
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}" MODULE_PREFIX)
|
||||
|
||||
add_subdirectory(libusb)
|
||||
|
||||
if(WITH_CLIENT_CHANNELS)
|
||||
add_subdirectory(client)
|
||||
add_channel_client(${MODULE_PREFIX} ${CHANNEL_NAME})
|
||||
endif()
|
||||
|
@ -16,8 +16,9 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "urbdrc")
|
||||
set(MODULE_PREFIX "CHANNEL_URBDRC_CLIENT")
|
||||
set(CHANNEL_NAME "urbdrc")
|
||||
set(MODULE_NAME "${CHANNEL_NAME}")
|
||||
string(TOUPPER "CHANNEL_${CHANNEL_NAME}_CLIENT" MODULE_PREFIX)
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
searchman.c
|
||||
@ -32,7 +33,8 @@ set(${MODULE_PREFIX}_SRCS
|
||||
|
||||
include_directories(..)
|
||||
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
add_channel_client_library(${MODULE_PREFIX} ${MODULE_NAME} ${CHANNEL_NAME} TRUE "DVCPluginEntry")
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES PREFIX "")
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS
|
||||
@ -40,14 +42,15 @@ set(${MODULE_PREFIX}_LIBS
|
||||
udev
|
||||
uuid)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp)
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-utils)
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
if(NOT STATIC_CHANNELS)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
endif()
|
||||
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${FREERDP_PLUGIN_PATH})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Channels/${MODULE_NAME}/Client")
|
||||
|
@ -1042,6 +1042,10 @@ static int urbdrc_process_plugin_data(IWTSPlugin* pPlugin, RDP_PLUGIN_DATA* data
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
#ifdef STATIC_CHANNELS
|
||||
#define DVCPluginEntry urbdrc_DVCPluginEntry
|
||||
#endif
|
||||
|
||||
int DVCPluginEntry(IDRDYNVC_ENTRY_POINTS* pEntryPoints)
|
||||
{
|
||||
int error = 0;
|
||||
|
@ -1,5 +1,5 @@
|
||||
# FreeRDP: A Remote Desktop Protocol Implementation
|
||||
# FreeRDP Client User Interfaces
|
||||
# FreeRDP Clients
|
||||
#
|
||||
# Copyright 2012 Marc-Andre Moreau <marcandre.moreau@gmail.com>
|
||||
#
|
||||
@ -15,28 +15,31 @@
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
# User Interfaces
|
||||
# Clients
|
||||
|
||||
if(NOT WIN32)
|
||||
# Build Sample Client
|
||||
add_subdirectory(Sample)
|
||||
add_subdirectory(common)
|
||||
|
||||
# Build X11 Client
|
||||
find_suggested_package(X11)
|
||||
if(WITH_X11)
|
||||
add_subdirectory(X11)
|
||||
if(WIN32)
|
||||
add_subdirectory(Windows)
|
||||
else()
|
||||
if(WITH_SAMPLE)
|
||||
add_subdirectory(Sample)
|
||||
endif()
|
||||
|
||||
# Build DirectFB Client
|
||||
find_optional_package(DirectFB)
|
||||
if(WITH_DIRECTFB)
|
||||
add_subdirectory(DirectFB)
|
||||
endif()
|
||||
else()
|
||||
# Build Windows Client
|
||||
add_subdirectory(Windows)
|
||||
endif()
|
||||
|
||||
if(NOT WIN32 AND (NOT ANDROID))
|
||||
find_suggested_package(X11)
|
||||
if(WITH_X11)
|
||||
add_subdirectory(X11)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
||||
add_subdirectory(Mac)
|
||||
endif()
|
||||
|
||||
|
@ -31,18 +31,12 @@ set(${MODULE_PREFIX}_SRCS
|
||||
add_executable(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS ${DIRECTFB_LIBRARIES})
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-channels-client)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-client)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
freerdp-core
|
||||
freerdp-gdi
|
||||
freerdp-locale
|
||||
freerdp-channels
|
||||
freerdp-utils)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-core freerdp-gdi freerdp-locale freerdp-codec freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||
|
@ -227,7 +227,7 @@ static int df_process_plugin_args(rdpSettings* settings, const char* name,
|
||||
void* entry = NULL;
|
||||
rdpChannels* channels = (rdpChannels*) user_data;
|
||||
|
||||
entry = freerdp_channels_find_static_virtual_channel_entry(name);
|
||||
entry = freerdp_channels_client_find_static_entry("VirtualChannelEntry", name);
|
||||
|
||||
if (entry)
|
||||
{
|
||||
|
@ -136,12 +136,10 @@ endif()
|
||||
target_link_libraries(MacFreeRDP
|
||||
${EXTRA_LIBS}
|
||||
freerdp-core
|
||||
freerdp-channels
|
||||
freerdp-cache
|
||||
freerdp-gdi
|
||||
freerdp-utils
|
||||
freerdp-codec
|
||||
freerdp-rail
|
||||
)
|
||||
freerdp-rail)
|
||||
|
||||
set_property(TARGET MacFreeRDP PROPERTY FOLDER "Client/Mac")
|
||||
|
@ -25,15 +25,10 @@ add_executable(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} ${CMAKE_DL_LIBS})
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
freerdp-core
|
||||
freerdp-gdi
|
||||
freerdp-utils
|
||||
freerdp-channels)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-core freerdp-gdi freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
|
@ -36,18 +36,12 @@ set(${MODULE_PREFIX}_SRCS
|
||||
|
||||
add_executable(${MODULE_NAME} WIN32 ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-channels-client)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-client)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
freerdp-core
|
||||
freerdp-gdi
|
||||
freerdp-codec
|
||||
freerdp-channels
|
||||
freerdp-utils)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-core freerdp-gdi freerdp-codec freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||
|
@ -179,7 +179,7 @@ BOOL wf_pre_connect(freerdp* instance)
|
||||
settings->order_support[NEG_ELLIPSE_SC_INDEX] = FALSE;
|
||||
settings->order_support[NEG_ELLIPSE_CB_INDEX] = FALSE;
|
||||
|
||||
settings->glyph_cache = FALSE;
|
||||
settings->glyphSupportLevel = GLYPH_SUPPORT_NONE;
|
||||
|
||||
wfi->cursor = g_default_cursor;
|
||||
|
||||
@ -457,7 +457,7 @@ int wf_process_plugin_args(rdpSettings* settings, const char* name, RDP_PLUGIN_D
|
||||
void* entry = NULL;
|
||||
rdpChannels* channels = (rdpChannels*) user_data;
|
||||
|
||||
entry = freerdp_channels_find_static_virtual_channel_entry(name);
|
||||
entry = freerdp_channels_client_find_static_entry("VirtualChannelEntry", name);
|
||||
|
||||
if (entry)
|
||||
{
|
||||
|
@ -94,19 +94,11 @@ endif()
|
||||
|
||||
include_directories(${CMAKE_SOURCE_DIR}/resources)
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-channels-client)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-client)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
freerdp-core
|
||||
freerdp-gdi
|
||||
freerdp-locale
|
||||
freerdp-rail
|
||||
freerdp-channels
|
||||
freerdp-utils)
|
||||
endif()
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-core freerdp-gdi freerdp-locale freerdp-rail freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||
|
@ -553,7 +553,7 @@ BOOL xf_pre_connect(freerdp* instance)
|
||||
fprintf(stderr, "--authonly, but no -p password. Please provide one.\n");
|
||||
exit(1);
|
||||
}
|
||||
fprintf(stderr, "%s:%d: Authenication only. Don't connect to X.\n", __FILE__, __LINE__);
|
||||
fprintf(stderr, "%s:%d: Authentication only. Don't connect to X.\n", __FILE__, __LINE__);
|
||||
/* Avoid XWindows initialization and configuration below. */
|
||||
return TRUE;
|
||||
}
|
||||
@ -949,7 +949,7 @@ int xf_process_plugin_args(rdpSettings* settings, const char* name, RDP_PLUGIN_D
|
||||
void* entry = NULL;
|
||||
rdpChannels* channels = (rdpChannels*) user_data;
|
||||
|
||||
entry = freerdp_channels_find_static_virtual_channel_entry(name);
|
||||
entry = freerdp_channels_client_find_static_entry("VirtualChannelEntry", name);
|
||||
|
||||
if (entry)
|
||||
{
|
||||
|
38
client/common/CMakeLists.txt
Normal file
38
client/common/CMakeLists.txt
Normal file
@ -0,0 +1,38 @@
|
||||
# FreeRDP: A Remote Desktop Protocol Implementation
|
||||
# FreeRDP Client Common
|
||||
#
|
||||
# Copyright 2012 Marc-Andre Moreau <marcandre.moreau@gmail.com>
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "freerdp-client")
|
||||
set(MODULE_PREFIX "FREERDP_CLIENT")
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
client.c)
|
||||
|
||||
if(MSVC)
|
||||
set(${MODULE_PREFIX}_SRCS ${${MODULE_PREFIX}_SRCS} module.def)
|
||||
endif()
|
||||
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-channels-client)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Client/Common")
|
||||
|
@ -1,9 +1,8 @@
|
||||
/**
|
||||
* FreeRDP: A Remote Desktop Protocol Implementation
|
||||
* Virtual Channel Manager
|
||||
* FreeRDP Client Common
|
||||
*
|
||||
* Copyright 2009-2011 Jay Sorg
|
||||
* Copyright 2010-2011 Vic Lee
|
||||
* Copyright 2012 Marc-Andre Moreau <marcandre.moreau@gmail.com>
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@ -18,19 +17,8 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef __LIBCHANNELS_H
|
||||
#define __LIBCHANNELS_H
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <freerdp/utils/debug.h>
|
||||
|
||||
#ifdef WITH_DEBUG_CHANNELS
|
||||
#define DEBUG_CHANNELS(fmt, ...) DEBUG_CLASS(CHANNELS, fmt, ## __VA_ARGS__)
|
||||
#else
|
||||
#define DEBUG_CHANNELS(fmt, ...) DEBUG_NULL(fmt, ## __VA_ARGS__)
|
||||
#endif
|
||||
|
||||
#endif /* __LIBCHANNELS_H */
|
3
client/common/module.def
Normal file
3
client/common/module.def
Normal file
@ -0,0 +1,3 @@
|
||||
LIBRARY "libfreerdp-client"
|
||||
EXPORTS
|
||||
|
48
cmake/ComplexLibrary.cmake
Normal file
48
cmake/ComplexLibrary.cmake
Normal file
@ -0,0 +1,48 @@
|
||||
|
||||
include(CMakeParseArguments)
|
||||
|
||||
macro(set_complex_link_libraries)
|
||||
|
||||
set(PREFIX "COMPLEX_LIBRARY")
|
||||
|
||||
cmake_parse_arguments(${PREFIX}
|
||||
"INTERNAL"
|
||||
"MODULE;VARIABLE;MONOLITHIC"
|
||||
"MODULES"
|
||||
${ARGN})
|
||||
|
||||
if(NOT DEFINED ${PREFIX}_MONOLITHIC)
|
||||
set(${PREFIX}_MONOLITHIC FALSE)
|
||||
endif()
|
||||
|
||||
if(${${PREFIX}_MONOLITHIC})
|
||||
if(${${PREFIX}_INTERNAL})
|
||||
set(${PREFIX}_LIBS)
|
||||
else()
|
||||
set(${PREFIX}_LIBS ${${PREFIX}_MODULE})
|
||||
endif()
|
||||
else()
|
||||
set(${PREFIX}_LIBS ${${PREFIX}_MODULES})
|
||||
endif()
|
||||
|
||||
set(${${PREFIX}_VARIABLE} ${${${PREFIX}_VARIABLE}} ${${PREFIX}_LIBS})
|
||||
|
||||
endmacro(set_complex_link_libraries)
|
||||
|
||||
macro(add_complex_library)
|
||||
|
||||
set(PREFIX "COMPLEX_LIBRARY")
|
||||
|
||||
cmake_parse_arguments(${PREFIX}
|
||||
""
|
||||
"MODULE;TYPE;MONOLITHIC"
|
||||
"SOURCES"
|
||||
${ARGN})
|
||||
|
||||
if(${${PREFIX}_MONOLITHIC})
|
||||
add_library(${${PREFIX}_MODULE} ${${PREFIX}_TYPE} ${${PREFIX}_SOURCES})
|
||||
else()
|
||||
add_library(${${PREFIX}_MODULE} ${${PREFIX}_SOURCES})
|
||||
endif()
|
||||
|
||||
endmacro(add_complex_library)
|
@ -1,9 +1,21 @@
|
||||
|
||||
if((CMAKE_SYSTEM_PROCESSOR MATCHES "i386|i686|x86") AND (CMAKE_SIZEOF_VOID_P EQUAL 4))
|
||||
set(TARGET_ARCH "x86")
|
||||
elseif((CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64|AMD64") AND (CMAKE_SIZEOF_VOID_P EQUAL 8))
|
||||
set(TARGET_ARCH "x64")
|
||||
endif()
|
||||
|
||||
option(WITH_MANPAGES "Generate manpages." ON)
|
||||
option(WITH_NEON "Enable NEON optimization for rfx decoder" OFF)
|
||||
option(WITH_PROFILER "Compile profiler." OFF)
|
||||
option(WITH_SSE2_TARGET "Allow compiler to generate SSE2 instructions." OFF)
|
||||
option(WITH_SSE2 "Use SSE2 optimization." OFF)
|
||||
|
||||
if((TARGET_ARCH MATCHES "x86|x64") AND (NOT DEFINED WITH_SSE2))
|
||||
option(WITH_SSE2 "Enable SSE2 optimization." ON)
|
||||
else()
|
||||
option(WITH_SSE2 "Enable SSE2 optimization." OFF)
|
||||
endif()
|
||||
|
||||
option(WITH_NEON "Enable NEON optimization." OFF)
|
||||
|
||||
option(WITH_JPEG "Use JPEG decoding." OFF)
|
||||
|
||||
if(APPLE)
|
||||
@ -16,6 +28,7 @@ if(MSVC)
|
||||
endif()
|
||||
|
||||
option(BUILD_TESTING "Build unit tests" OFF)
|
||||
option(WITH_SAMPLE "Build sample code" OFF)
|
||||
|
||||
if(${CMAKE_VERSION} VERSION_GREATER 2.8.8)
|
||||
option(MONOLITHIC_BUILD "Use monolithic build" OFF)
|
||||
@ -24,6 +37,7 @@ endif()
|
||||
option(WITH_CLIENT "Build client binaries" ON)
|
||||
option(WITH_SERVER "Build server binaries" OFF)
|
||||
|
||||
option(STATIC_CHANNELS "Build channels statically" ON)
|
||||
option(WITH_CHANNELS "Build virtual channel plugins" ON)
|
||||
|
||||
if(WITH_CLIENT AND WITH_CHANNELS)
|
||||
|
@ -17,9 +17,7 @@
|
||||
/* Include files */
|
||||
#cmakedefine HAVE_FCNTL_H
|
||||
#cmakedefine HAVE_UNISTD_H
|
||||
#cmakedefine HAVE_LIMITS_H
|
||||
#cmakedefine HAVE_STDINT_H
|
||||
#cmakedefine HAVE_STDBOOL_H
|
||||
#cmakedefine HAVE_INTTYPES_H
|
||||
#cmakedefine HAVE_SYS_MODEM_H
|
||||
#cmakedefine HAVE_SYS_FILIO_H
|
||||
|
@ -68,7 +68,6 @@ target_link_libraries(test_freerdp ${CUNIT_LIBRARIES})
|
||||
target_link_libraries(test_freerdp freerdp-core)
|
||||
target_link_libraries(test_freerdp freerdp-gdi)
|
||||
target_link_libraries(test_freerdp freerdp-utils)
|
||||
target_link_libraries(test_freerdp freerdp-channels)
|
||||
target_link_libraries(test_freerdp freerdp-codec)
|
||||
target_link_libraries(test_freerdp freerdp-crypto)
|
||||
|
||||
|
@ -22,9 +22,9 @@
|
||||
|
||||
#include <freerdp/api.h>
|
||||
|
||||
FREERDP_API void* freerdp_channels_find_static_virtual_channel_entry(const char* name);
|
||||
FREERDP_API void* freerdp_channels_find_static_device_service_entry(const char* name);
|
||||
FREERDP_API void* freerdp_channels_find_static_entry(const char* name, const char* entry);
|
||||
FREERDP_API void* freerdp_channels_client_find_static_entry(const char* name, const char* identifier);
|
||||
FREERDP_API void* freerdp_channels_client_find_dynamic_entry(const char* name, const char* identifier);
|
||||
FREERDP_API void* freerdp_channels_client_find_entry(const char* name, const char* identifier);
|
||||
|
||||
#endif /* FREERDP_CHANNELS_CLIENT */
|
||||
|
||||
|
@ -72,6 +72,7 @@ struct rdp_freerdp_peer
|
||||
psPeerSendChannelData SendChannelData;
|
||||
psPeerReceiveChannelData ReceiveChannelData;
|
||||
|
||||
int pId;
|
||||
UINT32 ack_frame_id;
|
||||
BOOL local;
|
||||
BOOL connected;
|
||||
|
@ -22,49 +22,49 @@
|
||||
|
||||
#include <freerdp/types.h>
|
||||
|
||||
#define GLYPH_FRAGMENT_NOP 0x00
|
||||
#define GLYPH_FRAGMENT_USE 0xFE
|
||||
#define GLYPH_FRAGMENT_ADD 0xFF
|
||||
#define GLYPH_FRAGMENT_NOP 0x00
|
||||
#define GLYPH_FRAGMENT_USE 0xFE
|
||||
#define GLYPH_FRAGMENT_ADD 0xFF
|
||||
|
||||
#define CBR2_HEIGHT_SAME_AS_WIDTH 0x01
|
||||
#define CBR2_PERSISTENT_KEY_PRESENT 0x02
|
||||
#define CBR2_NO_BITMAP_COMPRESSION_HDR 0x08
|
||||
#define CBR2_DO_NOT_CACHE 0x10
|
||||
#define CBR2_HEIGHT_SAME_AS_WIDTH 0x01
|
||||
#define CBR2_PERSISTENT_KEY_PRESENT 0x02
|
||||
#define CBR2_NO_BITMAP_COMPRESSION_HDR 0x08
|
||||
#define CBR2_DO_NOT_CACHE 0x10
|
||||
|
||||
#define SCREEN_BITMAP_SURFACE 0xFFFF
|
||||
#define BITMAP_CACHE_WAITING_LIST_INDEX 0x7FFF
|
||||
#define SCREEN_BITMAP_SURFACE 0xFFFF
|
||||
#define BITMAP_CACHE_WAITING_LIST_INDEX 0x7FFF
|
||||
|
||||
#define CACHED_BRUSH 0x80
|
||||
#define CACHED_BRUSH 0x80
|
||||
|
||||
#define BMF_1BPP 0x1
|
||||
#define BMF_8BPP 0x3
|
||||
#define BMF_16BPP 0x4
|
||||
#define BMF_24BPP 0x5
|
||||
#define BMF_32BPP 0x6
|
||||
#define BMF_1BPP 0x1
|
||||
#define BMF_8BPP 0x3
|
||||
#define BMF_16BPP 0x4
|
||||
#define BMF_24BPP 0x5
|
||||
#define BMF_32BPP 0x6
|
||||
|
||||
#ifndef _WIN32
|
||||
#define BS_SOLID 0x00
|
||||
#define BS_NULL 0x01
|
||||
#define BS_HATCHED 0x02
|
||||
#define BS_PATTERN 0x03
|
||||
#define BS_SOLID 0x00
|
||||
#define BS_NULL 0x01
|
||||
#define BS_HATCHED 0x02
|
||||
#define BS_PATTERN 0x03
|
||||
#endif
|
||||
|
||||
#ifndef _WIN32
|
||||
#define HS_HORIZONTAL 0x00
|
||||
#define HS_VERTICAL 0x01
|
||||
#define HS_FDIAGONAL 0x02
|
||||
#define HS_BDIAGONAL 0x03
|
||||
#define HS_CROSS 0x04
|
||||
#define HS_DIAGCROSS 0x05
|
||||
#define HS_HORIZONTAL 0x00
|
||||
#define HS_VERTICAL 0x01
|
||||
#define HS_FDIAGONAL 0x02
|
||||
#define HS_BDIAGONAL 0x03
|
||||
#define HS_CROSS 0x04
|
||||
#define HS_DIAGCROSS 0x05
|
||||
#endif
|
||||
|
||||
#define SO_FLAG_DEFAULT_PLACEMENT 0x01
|
||||
#define SO_HORIZONTAL 0x02
|
||||
#define SO_VERTICAL 0x04
|
||||
#define SO_REVERSED 0x08
|
||||
#define SO_ZERO_BEARINGS 0x10
|
||||
#define SO_CHAR_INC_EQUAL_BM_BASE 0x20
|
||||
#define SO_MAXEXT_EQUAL_BM_SIDE 0x40
|
||||
#define SO_FLAG_DEFAULT_PLACEMENT 0x01
|
||||
#define SO_HORIZONTAL 0x02
|
||||
#define SO_VERTICAL 0x04
|
||||
#define SO_REVERSED 0x08
|
||||
#define SO_ZERO_BEARINGS 0x10
|
||||
#define SO_CHAR_INC_EQUAL_BM_BASE 0x20
|
||||
#define SO_MAXEXT_EQUAL_BM_SIDE 0x40
|
||||
|
||||
struct _CACHE_BITMAP_ORDER
|
||||
{
|
||||
|
28
include/freerdp/server/channels.h
Normal file
28
include/freerdp/server/channels.h
Normal file
@ -0,0 +1,28 @@
|
||||
/**
|
||||
* FreeRDP: A Remote Desktop Protocol Implementation
|
||||
* Server Channels
|
||||
*
|
||||
* Copyright 2012 Marc-Andre Moreau <marcandre.moreau@gmail.com>
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef FREERDP_CHANNELS_SERVER
|
||||
#define FREERDP_CHANNELS_SERVER
|
||||
|
||||
#include <freerdp/api.h>
|
||||
|
||||
FREERDP_API void* freerdp_channels_server_find_static_entry(const char* name, const char* entry);
|
||||
|
||||
#endif /* FREERDP_CHANNELS_SERVER */
|
||||
|
@ -436,7 +436,8 @@ struct rdp_settings
|
||||
ALIGN64 BOOL persistent_bitmap_cache; /* 330 */
|
||||
ALIGN64 UINT32 bitmapCacheV2NumCells; /* 331 */
|
||||
ALIGN64 BITMAP_CACHE_V2_CELL_INFO* bitmapCacheV2CellInfo; /* 332 */
|
||||
UINT64 paddingQ[344 - 333]; /* 333 */
|
||||
ALIGN64 BOOL allow_cache_waiting_list; /* 333 */
|
||||
UINT64 paddingQ[344 - 334]; /* 334 */
|
||||
|
||||
/* Offscreen Bitmap Cache */
|
||||
ALIGN64 BOOL offscreen_bitmap_cache; /* 344 */
|
||||
@ -445,7 +446,7 @@ struct rdp_settings
|
||||
UINT64 paddingR[352 - 347]; /* 347 */
|
||||
|
||||
/* Glyph Cache */
|
||||
ALIGN64 BOOL glyph_cache; /* 352 */
|
||||
ALIGN64 void* unused352; /* 352 */
|
||||
ALIGN64 UINT32 glyphSupportLevel; /* 353 */
|
||||
ALIGN64 GLYPH_CACHE_DEFINITION* glyphCache; /* 354 */
|
||||
ALIGN64 GLYPH_CACHE_DEFINITION* fragCache; /* 355 */
|
||||
|
@ -23,8 +23,6 @@
|
||||
|
||||
#include <winpr/wtypes.h>
|
||||
|
||||
#include <freerdp/config.h>
|
||||
|
||||
#ifndef MIN
|
||||
#define MIN(x,y) (((x) < (y)) ? (x) : (y))
|
||||
#endif
|
||||
|
@ -29,7 +29,6 @@ set(${MODULE_PREFIX}_SUBMODULES
|
||||
cache
|
||||
codec
|
||||
crypto
|
||||
channels
|
||||
locale
|
||||
core)
|
||||
|
||||
|
19
libfreerdp/cache/CMakeLists.txt
vendored
19
libfreerdp/cache/CMakeLists.txt
vendored
@ -28,21 +28,20 @@ set(${MODULE_PREFIX}_SRCS
|
||||
glyph.c
|
||||
cache.c)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
add_library(${MODULE_NAME} OBJECT ${${MODULE_PREFIX}_SRCS})
|
||||
else()
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
add_complex_library(MODULE ${MODULE_NAME} TYPE "OBJECT"
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
SOURCES ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD} INTERNAL
|
||||
MODULE freerdp
|
||||
MODULES freerdp-core freerdp-utils)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(FREERDP_LIBS ${FREERDP_LIBS} ${${MODULE_PREFIX}_LIBS} PARENT_SCOPE)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
freerdp-core
|
||||
freerdp-utils)
|
||||
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
15
libfreerdp/cache/bitmap.c
vendored
15
libfreerdp/cache/bitmap.c
vendored
@ -280,20 +280,7 @@ rdpBitmapCache* bitmap_cache_new(rdpSettings* settings)
|
||||
bitmap_cache->update = ((freerdp*) settings->instance)->update;
|
||||
bitmap_cache->context = bitmap_cache->update->context;
|
||||
|
||||
bitmap_cache->maxCells = 5;
|
||||
|
||||
settings->bitmap_cache = FALSE;
|
||||
settings->bitmapCacheV2NumCells = 5;
|
||||
settings->bitmapCacheV2CellInfo[0].numEntries = 600;
|
||||
settings->bitmapCacheV2CellInfo[0].persistent = FALSE;
|
||||
settings->bitmapCacheV2CellInfo[1].numEntries = 600;
|
||||
settings->bitmapCacheV2CellInfo[1].persistent = FALSE;
|
||||
settings->bitmapCacheV2CellInfo[2].numEntries = 2048;
|
||||
settings->bitmapCacheV2CellInfo[2].persistent = FALSE;
|
||||
settings->bitmapCacheV2CellInfo[3].numEntries = 4096;
|
||||
settings->bitmapCacheV2CellInfo[3].persistent = FALSE;
|
||||
settings->bitmapCacheV2CellInfo[4].numEntries = 2048;
|
||||
settings->bitmapCacheV2CellInfo[4].persistent = FALSE;
|
||||
bitmap_cache->maxCells = settings->bitmapCacheV2NumCells;
|
||||
|
||||
bitmap_cache->cells = (BITMAP_V2_CELL*) xzalloc(sizeof(BITMAP_V2_CELL) * bitmap_cache->maxCells);
|
||||
|
||||
|
3
libfreerdp/cache/glyph.c
vendored
3
libfreerdp/cache/glyph.c
vendored
@ -464,9 +464,6 @@ rdpGlyphCache* glyph_cache_new(rdpSettings* settings)
|
||||
glyph->settings = settings;
|
||||
glyph->context = ((freerdp*) settings->instance)->update->context;
|
||||
|
||||
if (settings->glyph_cache)
|
||||
settings->glyphSupportLevel = GLYPH_SUPPORT_FULL;
|
||||
|
||||
for (i = 0; i < 10; i++)
|
||||
{
|
||||
glyph->glyphCache[i].number = settings->glyphCache[i].cacheEntries;
|
||||
|
@ -1,51 +0,0 @@
|
||||
# FreeRDP: A Remote Desktop Protocol Implementation
|
||||
# libfreerdp-channels cmake build script
|
||||
#
|
||||
# Copyright 2012 Marc-Andre Moreau <marcandre.moreau@gmail.com>
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set(MODULE_NAME "freerdp-channels")
|
||||
set(MODULE_PREFIX "FREERDP_CHANNELS")
|
||||
|
||||
set(${MODULE_PREFIX}_SRCS
|
||||
libchannels.c
|
||||
libchannels.h
|
||||
wtsvc.c
|
||||
wtsvc.h)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
add_library(${MODULE_NAME} OBJECT ${${MODULE_PREFIX}_SRCS})
|
||||
else()
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr)
|
||||
set(FREERDP_LIBS ${FREERDP_LIBS} ${${MODULE_PREFIX}_LIBS} PARENT_SCOPE)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
freerdp-utils)
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
winpr-crt
|
||||
winpr-synch
|
||||
winpr-interlocked)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "FreeRDP/libfreerdp")
|
File diff suppressed because it is too large
Load Diff
@ -78,23 +78,23 @@ if(WITH_JPEG)
|
||||
set(FREERDP_JPEG_LIBS jpeg)
|
||||
endif()
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
add_library(${MODULE_NAME} OBJECT ${${MODULE_PREFIX}_SRCS})
|
||||
else()
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
add_complex_library(MODULE ${MODULE_NAME} TYPE "OBJECT"
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
SOURCES ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS
|
||||
${FREERDP_JPEG_LIBS})
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD} INTERNAL
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(FREERDP_LIBS ${FREERDP_LIBS} ${${MODULE_PREFIX}_LIBS} PARENT_SCOPE)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
@ -92,26 +92,12 @@ set(${MODULE_PREFIX}_SRCS
|
||||
peer.c
|
||||
peer.h)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
add_library(${MODULE_NAME} OBJECT ${${MODULE_PREFIX}_SRCS})
|
||||
else()
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
add_complex_library(MODULE ${MODULE_NAME} TYPE "OBJECT"
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
SOURCES ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS winpr)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS
|
||||
winpr-utils
|
||||
winpr-sspi
|
||||
winpr-crt)
|
||||
if (NOT WIN32)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr-registry)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} ws2_32)
|
||||
else()
|
||||
@ -120,15 +106,19 @@ endif()
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} ${OPENSSL_LIBRARIES})
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD} INTERNAL
|
||||
MODULE freerdp
|
||||
MODULES freerdp-core freerdp-crypto freerdp-codec freerdp-locale freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-registry winpr-utils winpr-sspi winpr-crt)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(FREERDP_LIBS ${FREERDP_LIBS} ${${MODULE_PREFIX}_LIBS} PARENT_SCOPE)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
freerdp-utils
|
||||
freerdp-codec
|
||||
freerdp-crypto
|
||||
freerdp-locale)
|
||||
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
@ -36,8 +36,23 @@
|
||||
#include <freerdp/settings.h>
|
||||
#include <freerdp/utils/file.h>
|
||||
|
||||
#ifdef _WIN32
|
||||
#pragma warning(push)
|
||||
#pragma warning(disable: 4244)
|
||||
#endif
|
||||
|
||||
static const char client_dll[] = "C:\\Windows\\System32\\mstscax.dll";
|
||||
|
||||
#define REG_QUERY_DWORD_VALUE(_key, _subkey, _type, _value, _size, _result) \
|
||||
_size = sizeof(DWORD); \
|
||||
if (RegQueryValueEx(_key, _subkey, NULL, &_type, (BYTE*) &_value, &_size) == ERROR_SUCCESS) \
|
||||
_result = _value
|
||||
|
||||
#define REG_QUERY_BOOL_VALUE(_key, _subkey, _type, _value, _size, _result) \
|
||||
_size = sizeof(DWORD); \
|
||||
if (RegQueryValueEx(_key, _subkey, NULL, &_type, (BYTE*) &_value, &_size) == ERROR_SUCCESS) \
|
||||
_result = _value ? TRUE : FALSE
|
||||
|
||||
void settings_client_load_hkey_local_machine(rdpSettings* settings)
|
||||
{
|
||||
HKEY hKey;
|
||||
@ -48,46 +63,97 @@ void settings_client_load_hkey_local_machine(rdpSettings* settings)
|
||||
|
||||
status = RegOpenKeyEx(HKEY_LOCAL_MACHINE, _T("Software\\FreeRDP\\Client"), 0, KEY_READ | KEY_WOW64_64KEY, &hKey);
|
||||
|
||||
if (status != ERROR_SUCCESS)
|
||||
return;
|
||||
if (status == ERROR_SUCCESS)
|
||||
{
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("DesktopWidth"), dwType, dwValue, dwSize, settings->width);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("DesktopHeight"), dwType, dwValue, dwSize, settings->height);
|
||||
|
||||
dwSize = sizeof(DWORD);
|
||||
if (RegQueryValueEx(hKey, _T("DesktopWidth"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->width = dwValue;
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("Fullscreen"), dwType, dwValue, dwSize, settings->fullscreen);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("ColorDepth"), dwType, dwValue, dwSize, settings->color_depth);
|
||||
|
||||
dwSize = sizeof(DWORD);
|
||||
if (RegQueryValueEx(hKey, _T("DesktopHeight"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->height = dwValue;
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("KeyboardType"), dwType, dwValue, dwSize, settings->kbd_type);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("KeyboardSubType"), dwType, dwValue, dwSize, settings->kbd_subtype);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("KeyboardFunctionKeys"), dwType, dwValue, dwSize, settings->kbd_fn_keys);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("KeyboardLayout"), dwType, dwValue, dwSize, settings->kbd_layout);
|
||||
|
||||
dwSize = sizeof(DWORD);
|
||||
if (RegQueryValueEx(hKey, _T("KeyboardType"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->kbd_type = dwValue;
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("NlaSecurity"), dwType, dwValue, dwSize, settings->nla_security);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("TlsSecurity"), dwType, dwValue, dwSize, settings->tls_security);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("RdpSecurity"), dwType, dwValue, dwSize, settings->rdp_security);
|
||||
|
||||
dwSize = sizeof(DWORD);
|
||||
if (RegQueryValueEx(hKey, _T("KeyboardSubType"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->kbd_subtype = dwValue;
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("BitmapCache"), dwType, dwValue, dwSize, settings->bitmap_cache);
|
||||
|
||||
dwSize = sizeof(DWORD);
|
||||
if (RegQueryValueEx(hKey, _T("KeyboardFunctionKeys"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->kbd_fn_keys = dwValue;
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("OffscreenBitmapCache"), dwType, dwValue, dwSize, settings->offscreen_bitmap_cache);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("OffscreenBitmapCacheSize"), dwType, dwValue, dwSize, settings->offscreen_bitmap_cache_size);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("OffscreenBitmapCacheEntries"), dwType, dwValue, dwSize, settings->offscreen_bitmap_cache_entries);
|
||||
|
||||
dwSize = sizeof(DWORD);
|
||||
if (RegQueryValueEx(hKey, _T("KeyboardLayout"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->kbd_layout = dwValue;
|
||||
RegCloseKey(hKey);
|
||||
}
|
||||
|
||||
dwSize = sizeof(DWORD);
|
||||
if (RegQueryValueEx(hKey, _T("NlaSecurity"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->nla_security = dwValue ? 1 : 0;
|
||||
status = RegOpenKeyEx(HKEY_LOCAL_MACHINE, _T("Software\\FreeRDP\\Client\\BitmapCacheV2"), 0, KEY_READ | KEY_WOW64_64KEY, &hKey);
|
||||
|
||||
dwSize = sizeof(DWORD);
|
||||
if (RegQueryValueEx(hKey, _T("TlsSecurity"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->tls_security = dwValue ? 1 : 0;
|
||||
if (status == ERROR_SUCCESS)
|
||||
{
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("NumCells"), dwType, dwValue, dwSize, settings->bitmapCacheV2NumCells);
|
||||
|
||||
dwSize = sizeof(DWORD);
|
||||
if (RegQueryValueEx(hKey, _T("RdpSecurity"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->rdp_security = dwValue ? 1 : 0;
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cell0NumEntries"), dwType, dwValue, dwSize, settings->bitmapCacheV2CellInfo[0].numEntries);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("Cell0Persistent"), dwType, dwValue, dwSize, settings->bitmapCacheV2CellInfo[0].persistent);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cell1NumEntries"), dwType, dwValue, dwSize, settings->bitmapCacheV2CellInfo[1].numEntries);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("Cell1Persistent"), dwType, dwValue, dwSize, settings->bitmapCacheV2CellInfo[1].persistent);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cell2NumEntries"), dwType, dwValue, dwSize, settings->bitmapCacheV2CellInfo[2].numEntries);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("Cell2Persistent"), dwType, dwValue, dwSize, settings->bitmapCacheV2CellInfo[2].persistent);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cell3NumEntries"), dwType, dwValue, dwSize, settings->bitmapCacheV2CellInfo[3].numEntries);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("Cell3Persistent"), dwType, dwValue, dwSize, settings->bitmapCacheV2CellInfo[3].persistent);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cell4NumEntries"), dwType, dwValue, dwSize, settings->bitmapCacheV2CellInfo[4].numEntries);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("Cell4Persistent"), dwType, dwValue, dwSize, settings->bitmapCacheV2CellInfo[4].persistent);
|
||||
|
||||
RegCloseKey(hKey);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("AllowCacheWaitingList"), dwType, dwValue, dwSize, settings->allow_cache_waiting_list);
|
||||
|
||||
RegCloseKey(hKey);
|
||||
}
|
||||
|
||||
status = RegOpenKeyEx(HKEY_LOCAL_MACHINE, _T("Software\\FreeRDP\\Client\\GlyphCache"), 0, KEY_READ | KEY_WOW64_64KEY, &hKey);
|
||||
|
||||
if (status == ERROR_SUCCESS)
|
||||
{
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("SupportLevel"), dwType, dwValue, dwSize, settings->glyphSupportLevel);
|
||||
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache0NumEntries"), dwType, dwValue, dwSize, settings->glyphCache[0].cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache0MaxCellSize"), dwType, dwValue, dwSize, settings->glyphCache[0].cacheMaximumCellSize);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache1NumEntries"), dwType, dwValue, dwSize, settings->glyphCache[1].cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache1MaxCellSize"), dwType, dwValue, dwSize, settings->glyphCache[1].cacheMaximumCellSize);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache2NumEntries"), dwType, dwValue, dwSize, settings->glyphCache[2].cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache2MaxCellSize"), dwType, dwValue, dwSize, settings->glyphCache[2].cacheMaximumCellSize);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache3NumEntries"), dwType, dwValue, dwSize, settings->glyphCache[3].cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache3MaxCellSize"), dwType, dwValue, dwSize, settings->glyphCache[3].cacheMaximumCellSize);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache4NumEntries"), dwType, dwValue, dwSize, settings->glyphCache[4].cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache4MaxCellSize"), dwType, dwValue, dwSize, settings->glyphCache[4].cacheMaximumCellSize);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache5NumEntries"), dwType, dwValue, dwSize, settings->glyphCache[5].cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache5MaxCellSize"), dwType, dwValue, dwSize, settings->glyphCache[5].cacheMaximumCellSize);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache6NumEntries"), dwType, dwValue, dwSize, settings->glyphCache[6].cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache6MaxCellSize"), dwType, dwValue, dwSize, settings->glyphCache[6].cacheMaximumCellSize);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache7NumEntries"), dwType, dwValue, dwSize, settings->glyphCache[7].cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache7MaxCellSize"), dwType, dwValue, dwSize, settings->glyphCache[7].cacheMaximumCellSize);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache8NumEntries"), dwType, dwValue, dwSize, settings->glyphCache[8].cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache8MaxCellSize"), dwType, dwValue, dwSize, settings->glyphCache[8].cacheMaximumCellSize);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache9NumEntries"), dwType, dwValue, dwSize, settings->glyphCache[9].cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("Cache9MaxCellSize"), dwType, dwValue, dwSize, settings->glyphCache[9].cacheMaximumCellSize);
|
||||
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("FragCacheNumEntries"), dwType, dwValue, dwSize, settings->fragCache->cacheEntries);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("FragCacheMaxCellSize"), dwType, dwValue, dwSize, settings->fragCache->cacheMaximumCellSize);
|
||||
|
||||
RegCloseKey(hKey);
|
||||
}
|
||||
|
||||
status = RegOpenKeyEx(HKEY_LOCAL_MACHINE, _T("Software\\FreeRDP\\Client\\PointerCache"), 0, KEY_READ | KEY_WOW64_64KEY, &hKey);
|
||||
|
||||
if (status == ERROR_SUCCESS)
|
||||
{
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("LargePointer"), dwType, dwValue, dwSize, settings->large_pointer);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("ColorPointer"), dwType, dwValue, dwSize, settings->color_pointer);
|
||||
REG_QUERY_DWORD_VALUE(hKey, _T("PointerCacheSize"), dwType, dwValue, dwSize, settings->pointer_cache_size);
|
||||
|
||||
RegCloseKey(hKey);
|
||||
}
|
||||
}
|
||||
|
||||
void settings_server_load_hkey_local_machine(rdpSettings* settings)
|
||||
@ -103,14 +169,9 @@ void settings_server_load_hkey_local_machine(rdpSettings* settings)
|
||||
if (status != ERROR_SUCCESS)
|
||||
return;
|
||||
|
||||
if (RegQueryValueEx(hKey, _T("NlaSecurity"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->nla_security = dwValue ? 1 : 0;
|
||||
|
||||
if (RegQueryValueEx(hKey, _T("TlsSecurity"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->tls_security = dwValue ? 1 : 0;
|
||||
|
||||
if (RegQueryValueEx(hKey, _T("RdpSecurity"), NULL, &dwType, (BYTE*) &dwValue, &dwSize) == ERROR_SUCCESS)
|
||||
settings->rdp_security = dwValue ? 1 : 0;
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("NlaSecurity"), dwType, dwValue, dwSize, settings->nla_security);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("TlsSecurity"), dwType, dwValue, dwSize, settings->tls_security);
|
||||
REG_QUERY_BOOL_VALUE(hKey, _T("RdpSecurity"), dwType, dwValue, dwSize, settings->rdp_security);
|
||||
|
||||
RegCloseKey(hKey);
|
||||
}
|
||||
@ -220,13 +281,25 @@ rdpSettings* settings_new(void* instance)
|
||||
|
||||
settings->bitmap_cache = TRUE;
|
||||
settings->persistent_bitmap_cache = FALSE;
|
||||
settings->allow_cache_waiting_list = TRUE;
|
||||
|
||||
settings->bitmapCacheV2NumCells = 5;
|
||||
settings->bitmapCacheV2CellInfo = xzalloc(sizeof(BITMAP_CACHE_V2_CELL_INFO) * 6);
|
||||
settings->bitmapCacheV2CellInfo[0].numEntries = 600;
|
||||
settings->bitmapCacheV2CellInfo[0].persistent = FALSE;
|
||||
settings->bitmapCacheV2CellInfo[1].numEntries = 600;
|
||||
settings->bitmapCacheV2CellInfo[1].persistent = FALSE;
|
||||
settings->bitmapCacheV2CellInfo[2].numEntries = 2048;
|
||||
settings->bitmapCacheV2CellInfo[2].persistent = FALSE;
|
||||
settings->bitmapCacheV2CellInfo[3].numEntries = 4096;
|
||||
settings->bitmapCacheV2CellInfo[3].persistent = FALSE;
|
||||
settings->bitmapCacheV2CellInfo[4].numEntries = 2048;
|
||||
settings->bitmapCacheV2CellInfo[4].persistent = FALSE;
|
||||
|
||||
settings->refresh_rect = TRUE;
|
||||
settings->suppress_output = TRUE;
|
||||
|
||||
settings->glyph_cache = TRUE;
|
||||
settings->glyphSupportLevel = GLYPH_SUPPORT_NONE;
|
||||
settings->glyphSupportLevel = GLYPH_SUPPORT_FULL;
|
||||
settings->glyphCache = xzalloc(sizeof(GLYPH_CACHE_DEFINITION) * 10);
|
||||
settings->fragCache = xnew(GLYPH_CACHE_DEFINITION);
|
||||
settings->glyphCache[0].cacheEntries = 254;
|
||||
@ -325,3 +398,8 @@ void settings_free(rdpSettings* settings)
|
||||
free(settings);
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
#pragma warning(pop)
|
||||
#endif
|
||||
|
||||
|
@ -28,11 +28,9 @@ set(${MODULE_PREFIX}_SRCS
|
||||
crypto.c
|
||||
tls.c)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
add_library(${MODULE_NAME} OBJECT ${${MODULE_PREFIX}_SRCS})
|
||||
else()
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
add_complex_library(MODULE ${MODULE_NAME} TYPE "OBJECT"
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
SOURCES ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
include_directories(${OPENSSL_INCLUDE_DIR})
|
||||
include_directories(${ZLIB_INCLUDE_DIRS})
|
||||
@ -45,11 +43,7 @@ set(${MODULE_PREFIX}_LIBS
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr-sspi)
|
||||
|
||||
if(NOT WIN32)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr-library)
|
||||
endif()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr-sspi winpr-library)
|
||||
endif()
|
||||
|
||||
if(WIN32)
|
||||
@ -58,13 +52,19 @@ else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} ${ZLIB_LIBRARIES})
|
||||
endif()
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD} INTERNAL
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr)
|
||||
set(FREERDP_LIBS ${FREERDP_LIBS} ${${MODULE_PREFIX}_LIBS} PARENT_SCOPE)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr-crt)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
@ -39,22 +39,20 @@ set(${MODULE_PREFIX}_SRCS
|
||||
gdi.c
|
||||
gdi.h)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
add_library(${MODULE_NAME} OBJECT ${${MODULE_PREFIX}_SRCS})
|
||||
else()
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
add_complex_library(MODULE ${MODULE_NAME} TYPE "OBJECT"
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
SOURCES ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD} INTERNAL
|
||||
MODULE freerdp
|
||||
MODULES freerdp-core freerdp-cache freerdp-codec)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(FREERDP_LIBS ${FREERDP_LIBS} ${${MODULE_PREFIX}_LIBS} PARENT_SCOPE)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
freerdp-core
|
||||
freerdp-cache
|
||||
freerdp-codec)
|
||||
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
@ -48,19 +48,21 @@ if(CMAKE_SYSTEM_NAME MATCHES Solaris)
|
||||
set(WITH_SUN true)
|
||||
endif()
|
||||
|
||||
if(NOT WIN32)
|
||||
if(NOT WIN32 AND (NOT ANDROID))
|
||||
find_suggested_package(X11)
|
||||
if(WITH_X11)
|
||||
add_definitions(-DWITH_X11)
|
||||
include_directories(${X11_INCLUDE_DIRS})
|
||||
set(${MODULE_PREFIX}_SRCS ${${MODULE_PREFIX}_SRCS} ${${MODULE_PREFIX}_X11_SRCS})
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} ${X11_LIBRARIES})
|
||||
|
||||
if(WITH_SUN)
|
||||
add_definitions(-DWITH_SUN)
|
||||
set(${MODULE_PREFIX}_SRCS ${${MODULE_PREFIX}_SRCS} ${${MODULE_PREFIX}_SUN_SRCS})
|
||||
elseif(NOT APPLE)
|
||||
find_suggested_package(XKBFile)
|
||||
endif()
|
||||
|
||||
if(WITH_XKBFILE)
|
||||
add_definitions(-DWITH_XKBFILE)
|
||||
include_directories(${XKBFILE_INCLUDE_DIRS})
|
||||
@ -72,21 +74,25 @@ if(NOT WIN32)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
add_library(${MODULE_NAME} OBJECT ${${MODULE_PREFIX}_SRCS})
|
||||
else()
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
add_complex_library(MODULE ${MODULE_NAME} TYPE "OBJECT"
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
SOURCES ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD} INTERNAL
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr)
|
||||
set(FREERDP_LIBS ${FREERDP_LIBS} ${${MODULE_PREFIX}_LIBS} PARENT_SCOPE)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr-crt)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
@ -25,19 +25,20 @@ set(${MODULE_PREFIX}_SRCS
|
||||
rail.c
|
||||
librail.h)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
add_library(${MODULE_NAME} OBJECT ${${MODULE_PREFIX}_SRCS})
|
||||
else()
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
add_complex_library(MODULE ${MODULE_NAME} TYPE "OBJECT"
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
SOURCES ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD} INTERNAL
|
||||
MODULE freerdp
|
||||
MODULES freerdp-utils)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(FREERDP_LIBS ${FREERDP_LIBS} ${${MODULE_PREFIX}_LIBS} PARENT_SCOPE)
|
||||
else()
|
||||
set(FREERDP_RAIL_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-utils)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
@ -52,11 +52,9 @@ if(NOT WIN32)
|
||||
set(${MODULE_PREFIX}_SRCS ${${MODULE_PREFIX}_SRCS} msusb.c)
|
||||
endif()
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
add_library(${MODULE_NAME} OBJECT ${${MODULE_PREFIX}_SRCS})
|
||||
else()
|
||||
add_library(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
add_complex_library(MODULE ${MODULE_NAME} TYPE "OBJECT"
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
SOURCES ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
set_target_properties(${MODULE_NAME} PROPERTIES VERSION ${FREERDP_VERSION_FULL} SOVERSION ${FREERDP_VERSION} PREFIX "lib")
|
||||
|
||||
@ -72,11 +70,14 @@ if(${CMAKE_SYSTEM_NAME} MATCHES SunOS)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} rt)
|
||||
endif()
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt winpr-synch)
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr)
|
||||
set(FREERDP_LIBS ${FREERDP_LIBS} ${${MODULE_PREFIX}_LIBS} PARENT_SCOPE)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} winpr-crt winpr-synch)
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
endif()
|
||||
|
@ -351,7 +351,7 @@ int freerdp_parse_args(rdpSettings* settings, int argc, char** argv,
|
||||
}
|
||||
else if (strcmp("--no-glyph-cache", argv[index]) == 0)
|
||||
{
|
||||
settings->glyph_cache = FALSE;
|
||||
settings->glyphSupportLevel = GLYPH_SUPPORT_NONE;
|
||||
}
|
||||
else if (strcmp("--no-osb", argv[index]) == 0)
|
||||
{
|
||||
|
@ -23,13 +23,17 @@
|
||||
|
||||
#include <errno.h>
|
||||
#include <freerdp/utils/passphrase.h>
|
||||
|
||||
#ifdef _WIN32
|
||||
|
||||
char* freerdp_passphrase_read(const char* prompt, char* buf, size_t bufsiz, int from_stdin)
|
||||
{
|
||||
errno=ENOSYS;
|
||||
errno = ENOSYS;
|
||||
return NULL;
|
||||
}
|
||||
#else
|
||||
|
||||
#elif (!ANDROID)
|
||||
|
||||
#include <fcntl.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
@ -125,4 +129,13 @@ char* freerdp_passphrase_read(const char* prompt, char* buf, size_t bufsiz, int
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
|
||||
char* freerdp_passphrase_read(const char* prompt, char* buf, size_t bufsiz, int from_stdin)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
|
@ -24,14 +24,19 @@
|
||||
#include <stddef.h>
|
||||
#include <freerdp/utils/signal.h>
|
||||
#include <freerdp/utils/memory.h>
|
||||
|
||||
#ifdef _WIN32
|
||||
|
||||
#include <errno.h>
|
||||
|
||||
int freerdp_handle_signals(void)
|
||||
{
|
||||
errno = ENOSYS;
|
||||
return -1;
|
||||
}
|
||||
#else
|
||||
|
||||
#elif (!ANDROID)
|
||||
|
||||
volatile sig_atomic_t terminal_needs_reset = 0;
|
||||
int terminal_fildes = 0;
|
||||
struct termios orig_flags;
|
||||
@ -117,4 +122,12 @@ int freerdp_handle_signals(void)
|
||||
pthread_sigmask(SIG_SETMASK, &orig_set, NULL);
|
||||
return 0;
|
||||
}
|
||||
|
||||
#else
|
||||
|
||||
int freerdp_handle_signals(void)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
@ -17,12 +17,13 @@
|
||||
|
||||
# Servers
|
||||
|
||||
add_subdirectory(common)
|
||||
|
||||
if(NOT WIN32)
|
||||
if(WITH_SAMPLE)
|
||||
add_subdirectory(Sample)
|
||||
endif()
|
||||
|
||||
# Build Test Server
|
||||
add_subdirectory(Sample)
|
||||
|
||||
# Build X11 Server
|
||||
find_suggested_package(X11)
|
||||
if(WITH_X11)
|
||||
add_subdirectory(X11)
|
||||
|
@ -28,20 +28,20 @@ set(${MODULE_PREFIX}_SRCS
|
||||
|
||||
add_executable(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
target_link_libraries(${MODULE_NAME}
|
||||
winpr
|
||||
freerdp
|
||||
freerdp-channels-server)
|
||||
else()
|
||||
target_link_libraries(${MODULE_NAME}
|
||||
winpr-crt
|
||||
freerdp-core
|
||||
freerdp-utils
|
||||
freerdp-codec
|
||||
freerdp-channels
|
||||
freerdp-channels-server)
|
||||
endif()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-server)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-core freerdp-utils freerdp-codec)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE winpr
|
||||
MODULES winpr-crt)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_BINDIR})
|
||||
|
||||
set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER "Server/Sample")
|
||||
|
||||
|
@ -33,10 +33,11 @@ set(${MODULE_PREFIX}_SRCS
|
||||
wf_mirage.h
|
||||
wf_peer.c
|
||||
wf_peer.h
|
||||
wf_rdpsnd.c
|
||||
wf_rdpsnd.h
|
||||
wf_settings.c
|
||||
wf_settings.h
|
||||
wf_info.c
|
||||
|
||||
wf_info.c
|
||||
wf_info.h)
|
||||
|
||||
if(WITH_SERVER_INTERFACE)
|
||||
@ -46,24 +47,22 @@ else()
|
||||
set(${MODULE_PREFIX}_SRCS ${${MODULE_PREFIX}_SRCS} cli/wfreerdp.c cli/wfreerdp.h)
|
||||
add_executable(${MODULE_NAME} ${${MODULE_PREFIX}_SRCS})
|
||||
endif()
|
||||
|
||||
|
||||
if(WITH_WIN8)
|
||||
set(${MODULE_PREFIX}_LIBS d3d11 dxgi dxguid)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} d3d11 dxgi dxguid)
|
||||
endif()
|
||||
|
||||
if(MONOLITHIC_BUILD)
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp)
|
||||
else()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} dsound)
|
||||
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS}
|
||||
freerdp-core
|
||||
freerdp-utils
|
||||
freerdp-codec
|
||||
freerdp-channels)
|
||||
endif()
|
||||
set(${MODULE_PREFIX}_LIBS ${${MODULE_PREFIX}_LIBS} freerdp-server)
|
||||
|
||||
set_complex_link_libraries(VARIABLE ${MODULE_PREFIX}_LIBS
|
||||
MONOLITHIC ${MONOLITHIC_BUILD}
|
||||
MODULE freerdp
|
||||
MODULES freerdp-core freerdp-utils freerdp-codec)
|
||||
|
||||
target_link_libraries(${MODULE_NAME} ${${MODULE_PREFIX}_LIBS})
|
||||
|
||||
|
||||
if(WITH_SERVER_INTERFACE)
|
||||
install(TARGETS ${MODULE_NAME} DESTINATION ${CMAKE_INSTALL_LIBDIR})
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user