-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #15 from gonicus/carddav-github
feat: carddav contact support
- Loading branch information
Showing
30 changed files
with
859 additions
and
35 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 |
---|---|---|
@@ -0,0 +1,30 @@ | ||
diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
index 6883604..c410318 100644 | ||
--- a/CMakeLists.txt | ||
+++ b/CMakeLists.txt | ||
@@ -5,15 +5,15 @@ find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Network Xml REQUIRED) | ||
set(LIBRARY_OUTPUT_PATH ${PROJECT_BINARY_DIR}) | ||
set(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}) | ||
add_library(QtWebDAV SHARED | ||
- QNaturalSort.cpp | ||
- QNaturalSort.h | ||
- QWebDAV.cpp | ||
- QWebDAV.h | ||
- QWebDAV_global.h | ||
- QWebDAVDirParser.cpp | ||
- QWebDAVDirParser.h | ||
- QWebDAVItem.cpp | ||
- QWebDAVItem.h | ||
+ qnaturalsort.cpp | ||
+ qnaturalsort.h | ||
+ qwebdav.cpp | ||
+ qwebdav.h | ||
+ qwebdav_global.h | ||
+ qwebdavdirparser.cpp | ||
+ qwebdavdirparser.h | ||
+ qwebdavitem.cpp | ||
+ qwebdavitem.h | ||
) | ||
|
||
target_link_libraries(QtWebDAV PUBLIC | ||
|
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 |
---|---|---|
@@ -0,0 +1,10 @@ | ||
diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
index b8d0506..0f14d34 100644 | ||
--- a/CMakeLists.txt | ||
+++ b/CMakeLists.txt | ||
@@ -6,5 +6,3 @@ set(CMAKE_CXX_STANDARD 14) | ||
include_directories(include) | ||
|
||
add_subdirectory(src) | ||
-ENABLE_TESTING() | ||
-add_subdirectory(test) |
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 |
---|---|---|
@@ -0,0 +1,69 @@ | ||
diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
index 6883604..7be4550 100644 | ||
--- a/CMakeLists.txt | ||
+++ b/CMakeLists.txt | ||
@@ -2,29 +2,50 @@ cmake_minimum_required(VERSION 3.19) | ||
project(QtWebDAV) | ||
find_package(QT NAMES Qt6 Qt5 COMPONENTS Network Xml REQUIRED) | ||
find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Network Xml REQUIRED) | ||
-set(LIBRARY_OUTPUT_PATH ${PROJECT_BINARY_DIR}) | ||
-set(EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}) | ||
+ | ||
add_library(QtWebDAV SHARED | ||
- QNaturalSort.cpp | ||
- QNaturalSort.h | ||
- QWebDAV.cpp | ||
- QWebDAV.h | ||
- QWebDAV_global.h | ||
- QWebDAVDirParser.cpp | ||
- QWebDAVDirParser.h | ||
- QWebDAVItem.cpp | ||
- QWebDAVItem.h | ||
+ qnaturalsort.cpp | ||
+ qnaturalsort.h | ||
+ qwebdav.cpp | ||
+ qwebdav.h | ||
+ qwebdav_global.h | ||
+ qwebdavdirparser.cpp | ||
+ qwebdavdirparser.h | ||
+ qwebdavitem.cpp | ||
+ qwebdavitem.h | ||
) | ||
|
||
target_link_libraries(QtWebDAV PUBLIC | ||
Qt${QT_VERSION_MAJOR}::Network | ||
Qt${QT_VERSION_MAJOR}::Xml | ||
) | ||
-target_include_directories(QtWebDAV PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}) | ||
+target_include_directories(QtWebDAV PUBLIC | ||
+ $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}> | ||
+ $<INSTALL_INTERFACE:include> | ||
+) | ||
target_compile_definitions(QtWebDAV PRIVATE -DQWEBDAV_LIBRARY) | ||
target_compile_definitions(QtWebDAV PRIVATE DEBUG_WEBDAV) | ||
set_target_properties(QtWebDAV PROPERTIES AUTOMOC ON) | ||
+ | ||
+file(GLOB_RECURSE QTWEBDAV_INCLUDE_FILES "${CMAKE_CURRENT_SOURCE_DIR}/*.h") | ||
+set_target_properties(${PROJECT_NAME} | ||
+ PROPERTIES PUBLIC_HEADER "${QTWEBDAV_INCLUDE_FILES}" | ||
+) | ||
+ | ||
option(BUILD_EXAMPLE "Build with example") | ||
if (BUILD_EXAMPLE) | ||
add_subdirectory(example) | ||
-endif() | ||
\ No newline at end of file | ||
+endif() | ||
+ | ||
+install(TARGETS ${CMAKE_PROJECT_NAME} | ||
+ EXPORT targets | ||
+ LIBRARY | ||
+ DESTINATION ${CMAKE_INSTALL_LIBDIR} | ||
+ PUBLIC_HEADER | ||
+ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} | ||
+) | ||
+ | ||
+install(EXPORT targets | ||
+ FILE ${CMAKE_PROJECT_NAME}Config.cmake | ||
+ DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${CMAKE_PROJECT_NAME} | ||
+) |
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 |
---|---|---|
@@ -0,0 +1,42 @@ | ||
diff --git a/CMakeLists.txt b/CMakeLists.txt | ||
index b8d0506..0f14d34 100644 | ||
--- a/CMakeLists.txt | ||
+++ b/CMakeLists.txt | ||
@@ -6,5 +6,3 @@ set(CMAKE_CXX_STANDARD 14) | ||
include_directories(include) | ||
|
||
add_subdirectory(src) | ||
-ENABLE_TESTING() | ||
-add_subdirectory(test) | ||
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt | ||
index f24ebe4..434b9ec 100644 | ||
--- a/src/CMakeLists.txt | ||
+++ b/src/CMakeLists.txt | ||
@@ -8,12 +8,24 @@ utils.cpp ) | ||
|
||
target_include_directories(${CMAKE_PROJECT_NAME} | ||
PUBLIC | ||
- $<INSTALL_INTERFACE:include> | ||
+ $<INSTALL_INTERFACE:include> | ||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/include> | ||
PRIVATE | ||
${CMAKE_CURRENT_SOURCE_DIR}/src | ||
) | ||
|
||
+file(GLOB_RECURSE VCARD_INCLUDE_FILES "${PROJECT_SOURCE_DIR}/include/*.h") | ||
+set_target_properties(${PROJECT_NAME} | ||
+ PROPERTIES PUBLIC_HEADER "${VCARD_INCLUDE_FILES}" | ||
+) | ||
+ | ||
+include(GNUInstallDirs) | ||
install(TARGETS ${CMAKE_PROJECT_NAME} | ||
+ EXPORT targets | ||
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} | ||
- PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) | ||
\ No newline at end of file | ||
+ PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) | ||
+ | ||
+install(EXPORT targets | ||
+ FILE ${CMAKE_PROJECT_NAME}Config.cmake | ||
+ DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${CMAKE_PROJECT_NAME} | ||
+) |
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
Oops, something went wrong.