libwinpr: use ModuleOptions.cmake automatically

This commit is contained in:
Marc-André Moreau 2012-10-03 19:50:48 -04:00
parent a9d4164a23
commit b15e152011
2 changed files with 18 additions and 24 deletions

View File

@ -25,30 +25,15 @@ if(WITH_MONOLITHIC_BUILD)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
endif()
set(WINPR_MODULES
crt
utils
heap
path
io
file
error
environment
interlocked
handle
synch
thread
sysinfo
bcrypt
dsparse
asn1
rpc
sspicli
sspi
registry
library
timezone
winsock)
set(FILENAME "ModuleOptions.cmake")
file(GLOB FILEPATHS RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} "*/${FILENAME}")
foreach(FILEPATH ${FILEPATHS})
if(${FILEPATH} MATCHES "^([^/]*)//${FILENAME}")
string(REGEX REPLACE "^([^/]*)//${FILENAME}" "\\1" WINPR_MODULE ${FILEPATH})
set(WINPR_MODULES ${WINPR_MODULES} ${WINPR_MODULE})
endif()
endforeach(FILEPATH)
foreach(WINPR_MODULE ${WINPR_MODULES})
add_subdirectory(${WINPR_MODULE})

View File

@ -0,0 +1,9 @@
set(MINWIN_LAYER "0")
set(MINWIN_GROUP "none")
set(MINWIN_MAJOR_VERSION "0")
set(MINWIN_MINOR_VERSION "0")
set(MINWIN_SHORT_NAME "utils")
set(MINWIN_LONG_NAME "WinPR Utils")
set(MODULE_LIBRARY_NAME "${MINWIN_SHORT_NAME}")