-
Notifications
You must be signed in to change notification settings - Fork 807
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix build of xattr vfs plugin and the automated tests
Signed-off-by: Matthieu Gallien <matthieu.gallien@nextcloud.com>
- Loading branch information
Showing
8 changed files
with
70 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,50 @@ | ||
set(vfs_xattr_SRCS vfs_xattr.cpp) | ||
if (APPLE) | ||
set(vfs_xattr_SRCS ${vfs_xattr_SRCS} xattrwrapper_mac.cpp) | ||
else() | ||
set(vfs_xattr_SRCS ${vfs_xattr_SRCS} xattrwrapper_linux.cpp) | ||
endif() | ||
|
||
add_library("${synclib_NAME}_vfs_xattr" SHARED | ||
${vfs_xattr_SRCS} | ||
) | ||
if (UNIX) | ||
set(vfs_xattr_SRCS vfs_xattr.cpp) | ||
if (APPLE) | ||
set(vfs_xattr_SRCS ${vfs_xattr_SRCS} xattrwrapper_mac.cpp) | ||
else() | ||
set(vfs_xattr_SRCS ${vfs_xattr_SRCS} xattrwrapper_linux.cpp) | ||
endif() | ||
|
||
target_link_libraries("${synclib_NAME}_vfs_xattr" | ||
"${synclib_NAME}" | ||
) | ||
add_library("${synclib_NAME}_vfs_xattr" SHARED | ||
${vfs_xattr_SRCS} | ||
) | ||
|
||
set_target_properties("${synclib_NAME}_vfs_xattr" PROPERTIES | ||
LIBRARY_OUTPUT_DIRECTORY ${BIN_OUTPUT_DIRECTORY} | ||
RUNTIME_OUTPUT_DIRECTORY ${BIN_OUTPUT_DIRECTORY} | ||
PREFIX "" | ||
AUTOMOC TRUE | ||
) | ||
target_link_libraries("${synclib_NAME}_vfs_xattr" | ||
"${synclib_NAME}" | ||
) | ||
|
||
if(APPLE) | ||
# for being loadable when client run from build dir | ||
set(vfs_buildoutputdir "${BIN_OUTPUT_DIRECTORY}/${OWNCLOUD_OSX_BUNDLE}/Contents/PlugIns/") | ||
set_target_properties("${synclib_NAME}_vfs_xattr" | ||
PROPERTIES | ||
LIBRARY_OUTPUT_DIRECTORY ${vfs_buildoutputdir} | ||
RUNTIME_OUTPUT_DIRECTORY ${vfs_buildoutputdir} | ||
set_target_properties("${synclib_NAME}_vfs_xattr" PROPERTIES | ||
LIBRARY_OUTPUT_DIRECTORY ${BIN_OUTPUT_DIRECTORY} | ||
RUNTIME_OUTPUT_DIRECTORY ${BIN_OUTPUT_DIRECTORY} | ||
PREFIX "" | ||
AUTOMOC TRUE | ||
) | ||
# For being lodable when client run from install dir (after make macdeployqt) | ||
set(vfs_installdir "${LIB_INSTALL_DIR}/../PlugIns") | ||
else() | ||
set(vfs_installdir "${PLUGINDIR}") | ||
endif() | ||
|
||
INSTALL(TARGETS "${synclib_NAME}_vfs_xattr" | ||
LIBRARY DESTINATION "${vfs_installdir}" | ||
RUNTIME DESTINATION "${vfs_installdir}" | ||
) | ||
target_include_directories("${synclib_NAME}_vfs_xattr" BEFORE PUBLIC ${CMAKE_CURRENT_BINARY_DIR} INTERFACE ${CMAKE_CURRENT_BINARY_DIR}) | ||
|
||
if(APPLE) | ||
# for being loadable when client run from build dir | ||
set(vfs_buildoutputdir "${BIN_OUTPUT_DIRECTORY}/${OWNCLOUD_OSX_BUNDLE}/Contents/PlugIns/") | ||
set_target_properties("${synclib_NAME}_vfs_xattr" | ||
PROPERTIES | ||
LIBRARY_OUTPUT_DIRECTORY ${vfs_buildoutputdir} | ||
RUNTIME_OUTPUT_DIRECTORY ${vfs_buildoutputdir} | ||
) | ||
# For being lodable when client run from install dir (after make macdeployqt) | ||
set(vfs_installdir "${LIB_INSTALL_DIR}/../PlugIns") | ||
else() | ||
set(vfs_installdir "${PLUGINDIR}") | ||
endif() | ||
|
||
GENERATE_EXPORT_HEADER( "${synclib_NAME}_vfs_xattr" | ||
BASE_NAME "${synclib_NAME}_vfs_xattr" | ||
EXPORT_MACRO_NAME NEXTCLOUD_XATTR_EXPORT | ||
EXPORT_FILE_NAME xattrexport.h | ||
) | ||
|
||
INSTALL(TARGETS "${synclib_NAME}_vfs_xattr" | ||
LIBRARY DESTINATION "${vfs_installdir}" | ||
RUNTIME DESTINATION "${vfs_installdir}" | ||
) | ||
endif() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters