pax_global_header00006660000000000000000000000064132043130250014503gustar00rootroot0000000000000052 comment=c1258e3dc1ea27bef12fcfe902b976cf287edc4c libical-3.0.1/000077500000000000000000000000001320431302500131035ustar00rootroot00000000000000libical-3.0.1/.dir-locals.el000066400000000000000000000001741320431302500155360ustar00rootroot00000000000000;; -*- emacs-lisp -*- ((c-mode . ((c-basic-offset . 4) (indent-tabs-mode . nil) (tab-width . 4)))) libical-3.0.1/.gitignore000066400000000000000000000000301320431302500150640ustar00rootroot00000000000000*.kdev4 *~ *.rej *.orig libical-3.0.1/.krazy000066400000000000000000000014601320431302500142450ustar00rootroot00000000000000CHECKSETS foss,c++ EXCLUDE dpointer EXTRA crud,camelcase EXTRA style #Skip foo_export.h SKIP libical_.*_export\.h #Skip examples SKIP /examples/ #For now skip java SKIP /java/ #For now skip python SKIP /python/ #For now skip perl SKIP /Net-ICal-Libical/ #Skip ancient Apple files SKIP /src/libicalvcal/port\.h SKIP /src/libicalvcal/vcaltmp\. SKIP /src/libicalvcal/vcc\. SKIP /src/libicalvcal/vobject\. #Skip contributed files SKIP /src/libical/astime\.h SKIP /src/libical/caldate\.c SKIP /cmake/modules/GObjectIntrospectionMacros\.cmake|/cmake/modules/FindGObjectIntrospection\.cmake SKIP /doc/Doxyfile\.cmake SKIP /cmake/Toolchain-iOS.cmake|/cmake/Toolchain-QNX65.cmake|/cmake/Toolchain-QNX66.cmake|/cmake/Toolchain-android.cmake #Skip zoneinfo SKIP /zoneinfo/ STYLE_LINEMAX 100 STYLE_PYTHONSTYLE_OFFSET 4 libical-3.0.1/.travis.yml000066400000000000000000000017251320431302500152210ustar00rootroot00000000000000env: global: - secure: "NlWO/NTPlOU6cowOMuPOvjAprXVwIjmpHHf9CoMR71E2c/eBFFKIHj10kXuyFwz2KihHAIExmo9OlGtGniNWobvIrVrabO3dsOSb6UGbPAQkzQiyQLKsDNQAZx3nMuWEKBtMsVRee6rd7/2uGTY4WB5Ot3VhrUYcN1FoRgQQ9gk=" - PKG_CONFIG_PATH=/usr/local/opt/libffi/lib/pkgconfig # needed to find homebrew's libffi on osx os: - linux - osx before_install: ./scripts/setup-travis.sh language: c compiler: - gcc - clang script: mkdir build && cd build && cmake -DICAL_GLIB=true -DCMAKE_BUILD_TYPE=Release .. && make && make test addons: apt: sources: - george-edison55-precise-backports # cmake 3.2.3 / doxygen 1.8.3 packages: - cmake - cmake-data coverity_scan: project: name: libical/libical description: "Libical is an Open Source implementation of the iCalendar protocols and protocol data units." notification_email: allen.winter@kdab.com build_command_prepend: cd build && cmake .. build_command: make branch_pattern: coverity_scan libical-3.0.1/AUTHORS000066400000000000000000000001401320431302500141460ustar00rootroot00000000000000 There are now far too many contributors to libical to list here. Thanks to everyone involved! libical-3.0.1/CMakeLists.txt000066400000000000000000000475711320431302500156610ustar00rootroot00000000000000# This is the top-level CMakeLists.txt file for the libical project. # # Pass the following variables to cmake to control the build: # (See doc/UsingLibical.txt for more information) # # -DWITH_CXX_BINDINGS=[true|false] # Build the C++ bindings. # Default=true # # -DICAL_ERRORS_ARE_FATAL=[true|false] # Set to make icalerror_* calls abort instead of internally signaling an error # Default=false # Notes: # Change the behavior at runtime using the icalerror_set_errors_are_fatal() function. # Query the behavior at runtime using the icalerror_get_errors_are_fatal() function. # # -DICAL_ALLOW_EMPTY_PROPERTIES=[true|false] # Set to prevent empty properties from being replaced with X-LIC-ERROR properties. # Default=false # # -DUSE_BUILTIN_TZDATA=[true|false] # Set to build using our own timezone data. # Default=false (use the system timezone data on non-Windows systems) # ALWAYS true on Windows systems # # -DSTATIC_ONLY=[true|false] # Set to build static libraries only. # Turns-off GObject Introspection. # Default=false (build shared and static libs) # # -DSHARED_ONLY=[true|false] # Set to build shared (dynamic) libraries only. # Default=false (build shared and static libs) # Takes precedence over STATIC_ONLY # # -DGOBJECT_INTROSPECTION=[true|false] # Set to build GObject introspection "typelib" files # Requires GObject Introspection development package v0.6.7 or higher # Default=false (do not generate the introspection files) # # -DICAL_GLIB_VAPI=[true|false] # Set to build Vala "vapi" files # Requires Vala package # Default=false (build the libical-glib interface) # # -DICAL_GLIB=[true|false] # Set to build libical-glib (GObject) interface # Requires glib development package v2.20 or higher # Default=true (build the libical-glib interface) # # -DUSE_32BIT_TIME_T=[true|false] # Set to build using a 32bit time_t (ignored unless building with MSVC on Windows) # Default=false (use the default size of time_t) # ## Special CMake Options for Developers # # -DABI_DUMPER=[true|false] # Build for the abi-dumper (requires gcc) # Default=false # # -DADDRESS_SANITIZER=[true|false] # Build with the address sanitizer (requires gcc or clang) # # -DTHREAD_SANITIZER=[true|false] # Build with the thread sanitizer (requires gcc or clang) # cmake_minimum_required(VERSION 3.1.0) #first line, to shutup a cygwin warning project(libical C CXX) cmake_policy(SET CMP0003 NEW) if(POLICY CMP0042) cmake_policy(SET CMP0042 NEW) endif() if(POLICY CMP0054) cmake_policy(SET CMP0054 NEW) endif() set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules) #Include CMake capabilities include(FeatureSummary) # Enable the test harness enable_testing() if(WINCE) find_package(Wcecompat REQUIRED) include_directories(${WCECOMPAT_INCLUDE_DIR}) set(CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES} ${WCECOMPAT_INCLUDE_DIR}) set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} ${WCECOMPAT_LIBRARIES}) endif() set(LIBICAL_LIB_MAJOR_VERSION "3") set(LIBICAL_LIB_MINOR_VERSION "0") set(LIBICAL_LIB_PATCH_VERSION "1") set(LIBICAL_LIB_VERSION_STRING "${LIBICAL_LIB_MAJOR_VERSION}.${LIBICAL_LIB_MINOR_VERSION}.${LIBICAL_LIB_PATCH_VERSION}" ) set(PROJECT_VERSION "${LIBICAL_LIB_MAJOR_VERSION}.${LIBICAL_LIB_MINOR_VERSION}") set(PROJECT_URL "http://libical.github.io/libical/") # library build types set(LIBRARY_TYPE SHARED) option(STATIC_ONLY "Build static libraries only.") add_feature_info( "Option STATIC_ONLY" STATIC_ONLY "build static libraries only" ) if(STATIC_ONLY) set(LIBRARY_TYPE STATIC) endif() option(SHARED_ONLY "Build shared (dynamic) libraries only. Takes precedence over STATIC_ONLY") add_feature_info( "Option SHARED_ONLY" SHARED_ONLY "build shared libraries only" ) if(SHARED_ONLY) set(STATIC_ONLY False) set(LIBRARY_TYPE SHARED) endif() if(NOT STATIC_ONLY AND NOT SHARED_ONLY) add_feature_info( "Build types" TRUE "build both shared and static libraries" ) endif() if(STATIC_ONLY) add_definitions( -DLIBICAL_ICAL_STATIC_DEFINE -DLIBICAL_ICALSS_STATIC_DEFINE -DLIBICAL_VCAL_STATIC_DEFINE ) endif() # must have Perl to create the derived stuff find_package(Perl REQUIRED) set_package_properties(Perl PROPERTIES TYPE REQUIRED PURPOSE "Required by the libical build system." ) # Ensure finding 64bit libs when using 64-bit compilers if(CMAKE_CL_64) set_property(GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS True) endif() # libicu is highly recommended for RSCALE support # libicu can be found at http://www.icu-project.org # RSCALE info at http://tools.ietf.org/html/rfc7529 find_package(ICU) set_package_properties(ICU PROPERTIES TYPE RECOMMENDED PURPOSE "For RSCALE (RFC7529) support" ) add_feature_info( "RSCALE support (RFC7529)" ICU_FOUND "build in RSCALE support" ) if(ICU_FOUND) set(REQUIRES_PRIVATE_ICU "Requires.private: icu-i18n") #for libical.pc set(HAVE_LIBICU 1) if(ICU_MAJOR_VERSION VERSION_GREATER 50) set(HAVE_ICU_DANGI TRUE) else() set(HAVE_ICU_DANGI FALSE) endif() endif() if(ICU_I18N_FOUND) set(HAVE_LIBICU_I18N 1) endif() # compile in Berkeley DB support find_package(BDB) set_package_properties(BDB PROPERTIES TYPE OPTIONAL PURPOSE "For Berkeley DB storage support" ) add_feature_info( "Berkeley DB storage support" BDB_FOUND "build in support for Berkeley DB storage" ) if(BDB_FOUND) set(HAVE_BDB True) endif() # MSVC specific definitions if(WIN32) if(MSVC) add_definitions(-D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE -DYY_NO_UNISTD_H) option(USE_32BIT_TIME_T "Build using a 32bit time_t (ignored unless building with MSVC on Windows).") add_feature_info( "Option USE_32BIT_TIME_T" USE_32BIT_TIME_T "build using 32-bit time_t" ) if(USE_32BIT_TIME_T) add_definitions(-D_USE_32BIT_TIME_T) endif() set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4290") #C++ exception specification ignored set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /wd4068") #unknown pragma set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /wd4028") #formal parameter differs set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /wd4068") #unknown pragma endif() add_definitions(-DBIG_ENDIAN=0 -DLITTLE_ENDIAN=1 -DBYTE_ORDER=BIG_ENDIAN) endif() # Use GNUInstallDirs include(GNUInstallDirs) set(LIB_INSTALL_DIR ${CMAKE_INSTALL_LIBDIR} CACHE STRING "Library directory name" FORCE) set(INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_INCLUDEDIR} CACHE STRING "Include directory name" FORCE) set(SHARE_INSTALL_DIR ${CMAKE_INSTALL_DATAROOTDIR} CACHE STRING "Share directory name") # set the output paths set(EXECUTABLE_OUTPUT_PATH ${CMAKE_BINARY_DIR}/bin) if(WIN32) set(LIBRARY_OUTPUT_PATH ${EXECUTABLE_OUTPUT_PATH}) set(LIB_INSTALL_DIR lib) set(BIN_INSTALL_DIR bin) else() set(LIBRARY_OUTPUT_PATH ${CMAKE_BINARY_DIR}/lib) endif() if(APPLE) set(CMAKE_INSTALL_NAME_DIR ${LIB_DESTINATION}) endif() option(ICAL_ERRORS_ARE_FATAL "icalerror_* calls will abort instead of internally signaling an error.") add_feature_info( "Option ICAL_ERRORS_ARE_FATAL" ICAL_ERRORS_ARE_FATAL "icalerror_* calls will abort instead of internally signaling an error" ) if(ICAL_ERRORS_ARE_FATAL) set(ICAL_ERRORS_ARE_FATAL 1) else() set(ICAL_ERRORS_ARE_FATAL 0) endif() option(ICAL_ALLOW_EMPTY_PROPERTIES "Prevent empty properties from being replaced with X-LIC-ERROR properties.") add_feature_info( "Option ICAL_ALLOW_EMPTY_PROPERTIES" ICAL_ALLOW_EMPTY_PROPERTIES "prevents empty properties from being replaced with X-LIC-ERROR properties" ) if(ICAL_ALLOW_EMPTY_PROPERTIES) set(ICAL_ALLOW_EMPTY_PROPERTIES 1) else() set(ICAL_ALLOW_EMPTY_PROPERTIES 0) endif() option(USE_BUILTIN_TZDATA "build using our own timezone data, else use the system timezone data on non-Windows systems. ALWAYS true on Windows.") if(USE_BUILTIN_TZDATA) set(USE_BUILTIN_TZDATA 1) else() set(USE_BUILTIN_TZDATA 0) endif() add_feature_info( "Option USE_BUILTIN_TZDATA" USE_BUILTIN_TZDATA "use our own timezone data rather then the system timezone data" ) if(WIN32 OR WINCE) #Always use builtin tzdata on Windows systems. if(NOT USE_BUILTIN_TZDATA) message(STATUS "Currently unable to use system tzdata on Windows. Falling back to builtin tzdata" ) set(USE_BUILTIN_TZDATA 1) endif() endif() include(ConfigureChecks.cmake) add_definitions(-DHAVE_CONFIG_H) configure_file(config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config.h) set(INSTALL_TARGETS_DEFAULT_ARGS RUNTIME DESTINATION ${BIN_INSTALL_DIR} LIBRARY DESTINATION ${LIB_INSTALL_DIR} ARCHIVE DESTINATION ${LIB_INSTALL_DIR} ) set(MIN_GOBJECT_INTROSPECTION "0.6.7") option(GOBJECT_INTROSPECTION "Build GObject introspection \"typelib\" files. Requires GObject Introspection development package ${MIN_GOBJECT_INTROSPECTION} or higher.") add_feature_info( "Option GOBJECT_INTROSPECTION" GOBJECT_INTROSPECTION "build GObject introspection \"typelib\" files" ) if(GOBJECT_INTROSPECTION) find_package(GObjectIntrospection ${MIN_GOBJECT_INTROSPECTION}) set_package_properties(GObjectIntrospection PROPERTIES TYPE REQUIRED URL "https://wiki.gnome.org/Projects/GObjectIntrospection" PURPOSE "Required in order to build the GObject introspection \"typelib\" files." ) if(GObjectIntrospection_FOUND) set(HAVE_INTROSPECTION TRUE) if(STATIC_ONLY) message(FATAL_ERROR "You are attempting to build with GObject Introspection enabled, " "however that option is not supported when building static libraries only. " "Please disable the static only option to cmake (-DSTATIC_ONLY=False) " "if you really want to build with GObject Introspection. Alternatively, " "you can disable GObject Introspection (by passing -DGOBJECT_INTROSPECTION=False to cmake)") endif() endif() endif() option(ICAL_GLIB_VAPI "Build Vala \"vapi\" files.") add_feature_info( "Option ICAL_GLIB_VAPI" ICAL_GLIB_VAPI "build Vala \"vapi\" files" ) if(ICAL_GLIB_VAPI) if(NOT GOBJECT_INTROSPECTION) message(FATAL_ERROR "You requested to build the Vala vapi but have not enabled the GObject Introspection. " "Please try again also passing -DGOBJECT_INTROSPECTION=True to cmake" ) endif() find_program(VALAC valac DOC "the Vala compiler") if(NOT VALAC) message(FATAL_ERROR "valac, the Vala compiler was not found. " "Install it or disable Vala bindings with -DICAL_GLIB_VAPI=False" ) endif() find_program(VAPIGEN vapigen DOC "tool to generate the Vala API") if(NOT VAPIGEN) message(FATAL_ERROR "vapigen, the tool for generating the Vala API was not found. " "Install it or disable Vala bindings with -DICAL_GLIB_VAPI=False" ) endif() endif() set(MIN_GLIB "2.32") set(MIN_LIBXML "2.7.3") option(ICAL_GLIB "Build libical-glib interface. Requires glib ${MIN_GLIB} and libxml ${MIN_LIBXML} development packages or higher." True) add_feature_info( "Option ICAL_GLIB" ICAL_GLIB "build libical-glib interface" ) if(ICAL_GLIB) find_package(GLib ${MIN_GLIB}) set_package_properties(GLib PROPERTIES TYPE OPTIONAL PURPOSE "For the optional libical-glib interface" ) find_package(LibXML ${MIN_LIBXML}) set_package_properties(LibXML PROPERTIES TYPE OPTIONAL DESCRIPTION "a library providing XML and HTML support" URL "http://xmlsoft.org" PURPOSE "For the optional libical-glib interface" ) if(GLIB_FOUND AND LIBXML_FOUND) set(HAVE_GLIB TRUE) elseif(GLIB_FOUND) message(FATAL_ERROR "You requested to build libical-glib, but the necessary development package " "is missing or too low a version (libxml ${MIN_LIBXML} or higher is required)" ) elseif(LIBXML_FOUND) message(FATAL_ERROR "You requested to build libical-glib, but the necessary development package " "is missing or too low a version (glib ${MIN_GLIB} or higher is required)" ) else() message(FATAL_ERROR "You requested to build libical-glib, but the necessary development packages " "are missing or too low a version " "(glib ${MIN_GLIB} and libxml ${MIN_LIBXML} or higher are required)" ) endif() endif() # # Compiler settings # if(CMAKE_COMPILER_IS_GNUCC OR "${CMAKE_C_COMPILER_ID}" STREQUAL "Clang") include(CheckCCompilerFlag) check_c_compiler_flag(-Wunused-but-set-variable HAVE_GCC_UNUSED_BUT_SET) check_c_compiler_flag(-Wlogical-op HAVE_GCC_LOGICAL_OP) check_c_compiler_flag(-Wsizeof-pointer-memaccess HAVE_GCC_POINTER_MEMACCESS) check_c_compiler_flag(-Wformat-security HAVE_GCC_FORMAT_SECURITY) check_c_compiler_flag(-Wredundant-decls HAVE_GCC_REDUNDANT_DECLS) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fvisibility=hidden -Wno-deprecated -Wall -Wno-unknown-pragmas -Wextra -Winit-self -Wmissing-include-dirs -Wunused -Wno-div-by-zero -Wundef -Wpointer-arith -Wtype-limits -Wwrite-strings -Werror=return-type") if(HAVE_GCC_UNUSED_BUT_SET) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wunused-but-set-variable") endif() if(HAVE_GCC_LOGICAL_OP) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wlogical-op") endif() if(HAVE_GCC_POINTER_MEMACCESS) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wsizeof-pointer-memaccess") endif() if(HAVE_GCC_FORMAT_SECURITY) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wformat -Wformat-security") endif() if(HAVE_GCC_REDUNDANT_DECLS) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wredundant-decls") endif() if(CMAKE_SYSTEM_NAME MATCHES Linux OR CMAKE_SYSTEM_NAME STREQUAL GNU) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE -D_GNU_SOURCE") endif() endif() if("${CMAKE_C_COMPILER_ID}" STREQUAL "Clang") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Qunused-arguments") endif() if(CMAKE_COMPILER_IS_GNUCXX OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") include(CheckCXXCompilerFlag) check_cxx_compiler_flag(-Wunused-but-set-variable HAVE_GXX_UNUSED_BUT_SET) check_cxx_compiler_flag(-Wlogical-op HAVE_GXX_LOGICAL_OP) check_cxx_compiler_flag(-Wsizeof-pointer-memaccess HAVE_GXX_POINTER_MEMACCESS) check_cxx_compiler_flag(-Wreorder HAVE_GXX_REORDER) check_cxx_compiler_flag(-Wformat-security HAVE_GXX_FORMAT_SECURITY) check_cxx_compiler_flag(-Wredundant-decls HAVE_GXX_REDUNDANT_DECLS) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden -Weffc++ -Wno-deprecated -Wall -Wextra -Woverloaded-virtual -Winit-self -Wmissing-include-dirs -Wunused -Wno-div-by-zero -Wundef -Wpointer-arith -Wtype-limits -Wwrite-strings -Werror=return-type") if(HAVE_GXX_UNUSED_BUT_SET) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wunused-but-set-variable") endif() if(HAVE_GXX_LOGICAL_OP) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wlogical-op") endif() if(HAVE_GXX_POINTER_MEMACCESS) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wsizeof-pointer-memaccess") endif() if(HAVE_GXX_REORDER) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wreorder") endif() if(HAVE_GXX_FORMAT_SECURITY) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wformat -Wformat-security") endif() if(HAVE_GXX_REDUNDANT_DECLS) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wredundant-decls") endif() if(CMAKE_SYSTEM_NAME MATCHES Linux OR CMAKE_SYSTEM_NAME STREQUAL GNU) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -D_XOPEN_SOURCE=500 -D_DEFAULT_SOURCE -D_GNU_SOURCE") endif() endif() if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Qunused-arguments") endif() ################ Developer Options ##################### option(ABI_DUMPER "Build for abi-dumper." False) if(ABI_DUMPER) if(CMAKE_COMPILER_IS_GNUCC) set(CMAKE_C_FLAGS "-g -Og") set(CMAKE_CXX_FLAGS "-g -Og") else() message(FATAL_ERROR "You are trying to build for the abi-dumper using a non-GCC compiler.") endif() endif() option(ADDRESS_SANITIZER "Build with the address sanitizer." False) if(ADDRESS_SANITIZER) if(CMAKE_COMPILER_IS_GNUCC OR "${CMAKE_C_COMPILER_ID}" STREQUAL "Clang") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsanitize=address -g") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=address -g") else() message(FATAL_ERROR "You are trying to build with the address sanitizer using a non-GCC or Clang compiler.") endif() if(GOBJECT_INTROSPECTION) message(STATUS "Warning: Building the address sanitizer with GObject Introspection is is not supported. " "Turning-off GObject Introspection" ) set(HAVE_INTROSPECTION False) endif() if(ICAL_GLIB) message(STATUS "Warning: Building the address sanitizer with the GObject interface is not supported. " "Turning-off the GObject interface" ) set(ICAL_GLIB False) endif() endif() option(THREAD_SANITIZER "Build with the thread sanitizer." False) if(THREAD_SANITIZER) if(CMAKE_COMPILER_IS_GNUCC OR "${CMAKE_C_COMPILER_ID}" STREQUAL "Clang") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsanitize=thread -O1 -g") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=thread -O1 -g") else() message(FATAL_ERROR "You are trying to build with the thread sanitizer using a non-GCC or Clang compiler.") endif() if(GOBJECT_INTROSPECTION) message(STATUS "Warning: Building the thread sanitizer with GObject Introspection is is not supported. " "Turning-off GObject Introspection" ) set(HAVE_INTROSPECTION False) endif() if(ICAL_GLIB) message(STATUS "Warning: Building the thread sanitizer with the GObject interface is not supported. " "Turning-off the GObject interface" ) set(ICAL_GLIB False) endif() endif() ######################################################## option(WITH_CXX_BINDINGS "Build the C++ bindings." True) add_feature_info( "Option WITH_CXX_BINDINGS" WITH_CXX_BINDINGS "build the C++ bindings" ) if(WITH_CXX_BINDINGS) add_definitions(-DWITH_CXX_BINDINGS) endif() #some test programs need to know if we are using 32-bit time if(SIZEOF_TIME_T EQUAL 4) set(USE_32BIT_TIME_T TRUE) endif() if(WIN32 AND MSVC) if(SIZEOF_SIZE_T LESS SIZEOF_TIME_T) unset(SIZEOF_SIZE_T CACHE) unset(SIZEOF_TIME_T CACHE) message(FATAL_ERROR "You are using a Microsoft Visual 32-bit compiler with 64-bit time." "Run cmake again with the \"-DUSE_32BIT_TIME_T=true\" command line option." ) endif() endif() ################# build subdirs ######################## add_subdirectory(design-data) add_subdirectory(doc) add_subdirectory(scripts) add_subdirectory(test-data) add_subdirectory(src) add_subdirectory(examples) if(USE_BUILTIN_TZDATA) # use our zoneinfo if cmake is passed -DUSE_BUILTIN_TZDATA add_subdirectory(zoneinfo) endif() ########### create and install pkg-config file ######### set(VERSION "${LIBICAL_LIB_VERSION_STRING}") set(prefix "${CMAKE_INSTALL_PREFIX}") set(exec_prefix "\${prefix}") set(libdir "\${exec_prefix}/lib") set(includedir "\${prefix}/include") set(PTHREAD_LIBS "${CMAKE_THREAD_LIBS_INIT}") configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/libical.pc.in ${CMAKE_CURRENT_BINARY_DIR}/libical.pc @ONLY ) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libical.pc DESTINATION ${LIB_INSTALL_DIR}/pkgconfig) ########### Create and install the CMake Config files ########## include(CMakePackageConfigHelpers) configure_package_config_file( LibIcalConfig.cmake.in ${libical_BINARY_DIR}/LibIcalConfig.cmake INSTALL_DESTINATION ${LIB_INSTALL_DIR}/cmake/LibIcal PATH_VARS LIB_INSTALL_DIR INCLUDE_INSTALL_DIR ) # Create a version file write_basic_package_version_file( ${libical_BINARY_DIR}/LibIcalConfigVersion.cmake VERSION ${LIBICAL_LIB_VERSION_STRING} COMPATIBILITY SameMajorVersion ) install( FILES ${libical_BINARY_DIR}/LibIcalConfigVersion.cmake ${libical_BINARY_DIR}/LibIcalConfig.cmake DESTINATION ${LIB_INSTALL_DIR}/cmake/LibIcal ) install( EXPORT icalTargets DESTINATION ${LIB_INSTALL_DIR}/cmake/LibIcal FILE LibIcalTargets.cmake ) ########## By popular demand, add an uninstall target ########## if(NOT TARGET uninstall) configure_file( "${CMAKE_CURRENT_SOURCE_DIR}/uninstall.cmake.in" "${CMAKE_CURRENT_BINARY_DIR}/uninstall.cmake" IMMEDIATE @ONLY ) add_custom_target(uninstall COMMAND "${CMAKE_COMMAND}" -P "${CMAKE_CURRENT_BINARY_DIR}/uninstall.cmake" ) endif() feature_summary(WHAT ALL INCLUDE_QUIET_PACKAGES FATAL_ON_MISSING_REQUIRED_PACKAGES) libical-3.0.1/COPYING000066400000000000000000000012251320431302500141360ustar00rootroot00000000000000libical is distributed under two licenses. You may choose the terms of either: * The Mozilla Public License (MPL) v2.0 or * The GNU Lesser General Public License (LGPL) v2.1 ---------------------------------------------------------------------- Software distributed under these licenses is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. The Original Code is libical. The Initial Developer of the Original Code is Eric Busboom All Rights Reserved. Contributor(s): See individual source files. libical-3.0.1/ConfigureChecks.cmake000066400000000000000000000075611320431302500171600ustar00rootroot00000000000000include(CheckIncludeFiles) check_include_files(byteswap.h HAVE_BYTESWAP_H) check_include_files(dirent.h HAVE_DIRENT_H) check_include_files(endian.h HAVE_ENDIAN_H) check_include_files(inttypes.h HAVE_INTTYPES_H) check_include_files(pthread.h HAVE_PTHREAD_H) check_include_files(sys/endian.h HAVE_SYS_ENDIAN_H) check_include_files(sys/param.h HAVE_SYS_PARAM_H) check_include_files(sys/utsname.h HAVE_SYS_UTSNAME_H) check_include_files(fcntl.h HAVE_FCNTL_H) check_include_files(unistd.h HAVE_UNISTD_H) check_include_files(wctype.h HAVE_WCTYPE_H) include(CheckFunctionExists) if(WIN32 AND MSVC) check_function_exists(_access HAVE__ACCESS) #Windows check_function_exists(_getpid HAVE__GETPID) #Windows check_function_exists(_mkdir HAVE__MKDIR) #Windows check_function_exists(_open HAVE__OPEN) #Windows check_function_exists(_snprintf HAVE__SNPRINTF) #Windows check_function_exists(_stat HAVE__STAT) #Windows , check_function_exists(_strdup HAVE__STRDUP) #Windows check_function_exists(_stricmp HAVE__STRICMP) #Windows check_function_exists(_strnicmp HAVE__STRNICMP) #Windows check_function_exists(_read HAVE__READ) #Windows check_function_exists(_write HAVE__WRITE) #Windows else() check_function_exists(access HAVE_ACCESS) #Unix check_function_exists(fork HAVE_FORK) #Unix check_function_exists(getopt HAVE_GETOPT) #Unix check_function_exists(getpid HAVE_GETPID) #Unix check_function_exists(getpwent HAVE_GETPWENT) #Unix , check_function_exists(gmtime_r HAVE_GMTIME_R) #Unix check_function_exists(localtime_r HAVE_LOCALTIME_R) #Unix check_function_exists(mkdir HAVE_MKDIR) #Unix , check_function_exists(open HAVE_OPEN) #Unix ,, check_function_exists(nanosleep HAVE_NANOSLEEP) #Unix check_function_exists(signal HAVE_SIGNAL) #Unix check_function_exists(stat HAVE_STAT) #Unix ,, check_function_exists(strdup HAVE_STRDUP) #Unix check_function_exists(strcasecmp HAVE_STRCASECMP) #Unix check_function_exists(strncasecmp HAVE_STRNCASECMP) #Unix check_function_exists(read HAVE_READ) #Unix check_function_exists(unlink HAVE_UNLINK) #Unix check_function_exists(usleep HAVE_USLEEP) #Unix check_function_exists(waitpid HAVE_WAITPID) #Unix , check_function_exists(write HAVE_WRITE) #Unix if(NOT MINGW) check_function_exists(alarm HAVE_ALARM) #Unix endif() endif() check_function_exists(backtrace HAVE_BACKTRACE) check_function_exists(iswspace HAVE_ISWSPACE) #Linux check_function_exists(setenv HAVE_SETENV) check_function_exists(unsetenv HAVE_UNSETENV) check_function_exists(snprintf HAVE_SNPRINTF) #Available with MSVC 2015 #TODO:BUILDSYSTEM:Figure out why check_function_exists fails to find snprintf for MSVC2015 if(MSVC_VERSION GREATER 1899) set(HAVE_SNPRINTF true) endif() set(_SAVE_RQL ${CMAKE_REQUIRED_LIBRARIES}) set(CMAKE_REQUIRED_LIBRARIES kernel32.lib) check_function_exists(GetNumberFormat HAVE_GETNUMBERFORMAT) #Windows set(CMAKE_REQUIRED_LIBRARIES ${_SAVE_RQL}) include(CheckTypeSize) check_type_size(intptr_t SIZEOF_INTPTR_T) check_type_size(pid_t SIZEOF_PID_T) check_type_size(size_t SIZEOF_SIZE_T) check_type_size(ssize_t SIZEOF_SSIZE_T) check_type_size(time_t SIZEOF_TIME_T) check_type_size(wint_t SIZEOF_WINT_T) include(FindThreads) check_library_exists(pthread pthread_attr_get_np "" HAVE_PTHREAD_ATTR_GET_NP) check_library_exists(pthread pthread_getattr_np "" HAVE_PTHREAD_GETATTR_NP) check_library_exists(pthread pthread_create "" HAVE_PTHREAD_CREATE) check_include_files("pthread.h;pthread_np.h" HAVE_PTHREAD_NP_H) libical-3.0.1/Install.txt000066400000000000000000000115371320431302500152610ustar00rootroot00000000000000Libical uses the CMake buildsystem. Please see the comments at the top of CMakeLists.txt for the available configuration options you can pass to cmake. The installation directory defaults to /usr/local on UNIX and c:/Program Files on Windows. You can change this by passing -DCMAKE_INSTALL_PREFIX=/install/path to cmake. To build a debug version pass -DCMAKE_BUILD_TYPE=Debug to cmake. To build libical you will need: - CMake version 3.1.0 or higher - Perl - libicu (not required but strongly recommended) - a C compiler (let us know if the build fails with your C compiler) Building on Unix with gcc or clang: % mkdir build % cd build % cmake .. % make % make install Building on Windows with MicroSoft Visual Studio: From a command prompt for the version of MSVC you want to use % mkdir build % cd build % cmake -G "NMake Makefiles" .. % nmake % nmake install NOTE: Some MSVC 32bit compilers (like MSVC2005) use a 64bit version of time_t. In these cases you must pass -DUSE_32BIT_TIME_T=true to cmake to make sure the 32bit version of time_t is used instead. Building on Windows with mingw: Make sure you have the path to the MinGW programs in %PATH% first, for example: % set "PATH=c:\MinGW\mingw64\bin;%PATH%" % mkdir build % cd build % cmake -G "MinGW Makefiles" .. % mingw32-make % mingw32-make install Building on Windows under Cygwin: % mkdir build % cd build % cmake .. % make % make install Building on MSYS with mingw: % mkdir build % cd build % cmake -G "MSYS Makefiles" .. % nmake % nmake install To run the test suite, from inside the build directory run 'make test' (or 'nmake test' or 'mingw32-make test') To run the test suite in verbose mode, pass ARGS="-V" to the make command For example: nmake test ARGS="-V" By default, the buildsystem creates shared(dynamic) and static versions of the libraries, but that behavior can be modified at CMake time: - To build the static libraries only, pass -DSTATIC_ONLY=True to CMake. - To build the shared libraries only, pass -DSHARED_ONLY=True to CMake. == Building with Different Compilers == For example, say you want to use Clang to build on Linux. Then you can set the C and C++ compilers at CMake time, like so: % CC=clang CXX=clang++ cmake .. == Optional Dependencies == * libicu "International Components for Unicode" development libraries. Highly recommended for RSCALE support. libicu can be found at http://www.icu-project.org If CMake doesn't locate your libicu installation try setting the ICU_BASE environment variable to the top folder where its installed and run cmake again. * Berkeley DB storage. Optional for the Berkeley Database storage support. The development toolkit can be found at http://www.oracle.com/database/berkeley-db ** This code path has not been fully tested. ** Don't be surprised if there are bugs. ** Do NOT use for production code. * GObject Introspection. To generate GObject introspection "typelib" files pass the -DGOBJECT_INTROSPECTION=True option to CMake. You'll need to have the GObject Introspection development package v0.6.7 or higher installed beforehand. You can also force CMake to ignore any of the optional dependencies by passing the option -DCMAKE_DISABLE_FIND_PACKAGE_=True. For instance: # tell cmake to ignore ICU % cmake -DCMAKE_DISABLE_FIND_PACKAGE_ICU=True == Language Bindings == This C library can be built with bindings for these other languages: * C++. By default the buildsystem will create and install the C++ bindings API. Turn this off by passing -DWITH_CXX_BINDINGS=False option to CMake. * There are Java, Perl, PHP and Python bindings but they are old and haven't been tested in a very long time. Volunteers wanted. == Tweaking the Library Behavior == Use these CMake options to adjust the library behavior as follows: * ICAL_ERRORS_ARE_FATAL=[true|false] Set to make icalerror_* calls abort instead of internally signaling an error. Default=false * ICAL_ALLOW_EMPTY_PROPERTIES=[true|false] Set to prevent empty properties from being replaced with X-LIC-ERROR properties. Default=false * USE_BUILTIN_TZDATA=[true|false] Set to build using our own (instead of the system's) timezone data. Default=false (use the system timezone data on non-Windows systems) ALWAYS true on Windows systems == Tweaking the Installation Directories == By default, the installation layout is according to the GNU standard installation directories. http://www.gnu.org/prep/standards/html_node/Directory-Variables.html You can override various installation folders by passing the following variables to CMake: CMAKE_INSTALL_LIBDIR = The fullpath where you want the put the installed libraries CMAKE_INSTALL_INCLUDEDIR = The fullpath where you want to put the installed include files CMAKE_INSTALL_DATAROOTDIR = The fullpath where to want to put the shared files for example: cmake -DCMAKE_INSTALL_PREFIX=/opt -DCMAKE_INSTALL_LIBDIR=/opt/lib32 .. libical-3.0.1/LICENSE000066400000000000000000000012561320431302500141140ustar00rootroot00000000000000libical is distributed under two licenses. You may choose the terms of either: * The Mozilla Public License (MPL) v2.0 or * The GNU Lesser General Public License (LGPL) v2.1 ---------------------------------------------------------------------- Software distributed under these licenses is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. Libical is distributed under both the LGPL and the MPL. The MPL notice, reproduced below, covers the use of either of the licenses. ---------------------------------------------------------------------- libical-3.0.1/LICENSE.LGPL21.txt000066400000000000000000000642571320431302500156440ustar00rootroot00000000000000 Libical is Copyright (C) 2010-2017 Klaralvdalens Datakonsult AB. You may use, distribute and copy Libical under the terms of the GNU Lesser General Public License version 2.1, which is displayed below. ------------------------------------------------------------------------- GNU LESSER GENERAL PUBLIC LICENSE Version 2.1, February 1999 Copyright (C) 1991, 1999 Free Software Foundation, Inc. 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. [This is the first released version of the Lesser GPL. It also counts as the successor of the GNU Library Public License, version 2, hence the version number 2.1.] Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public Licenses are intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This license, the Lesser General Public License, applies to some specially designated software packages--typically libraries--of the Free Software Foundation and other authors who decide to use it. You can use it too, but we suggest you first think carefully about whether this license or the ordinary General Public License is the better strategy to use in any particular case, based on the explanations below. When we speak of free software, we are referring to freedom of use, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish); that you receive source code or can get it if you want it; that you can change the software and use pieces of it in new free programs; and that you are informed that you can do these things. To protect your rights, we need to make restrictions that forbid distributors to deny you these rights or to ask you to surrender these rights. These restrictions translate to certain responsibilities for you if you distribute copies of the library or if you modify it. For example, if you distribute copies of the library, whether gratis or for a fee, you must give the recipients all the rights that we gave you. You must make sure that they, too, receive or can get the source code. If you link other code with the library, you must provide complete object files to the recipients, so that they can relink them with the library after making changes to the library and recompiling it. And you must show them these terms so they know their rights. We protect your rights with a two-step method: (1) we copyright the library, and (2) we offer you this license, which gives you legal permission to copy, distribute and/or modify the library. To protect each distributor, we want to make it very clear that there is no warranty for the free library. Also, if the library is modified by someone else and passed on, the recipients should know that what they have is not the original version, so that the original author's reputation will not be affected by problems that might be introduced by others. Finally, software patents pose a constant threat to the existence of any free program. We wish to make sure that a company cannot effectively restrict the users of a free program by obtaining a restrictive license from a patent holder. Therefore, we insist that any patent license obtained for a version of the library must be consistent with the full freedom of use specified in this license. Most GNU software, including some libraries, is covered by the ordinary GNU General Public License. This license, the GNU Lesser General Public License, applies to certain designated libraries, and is quite different from the ordinary General Public License. We use this license for certain libraries in order to permit linking those libraries into non-free programs. When a program is linked with a library, whether statically or using a shared library, the combination of the two is legally speaking a combined work, a derivative of the original library. The ordinary General Public License therefore permits such linking only if the entire combination fits its criteria of freedom. The Lesser General Public License permits more lax criteria for linking other code with the library. We call this license the "Lesser" General Public License because it does Less to protect the user's freedom than the ordinary General Public License. It also provides other free software developers Less of an advantage over competing non-free programs. These disadvantages are the reason we use the ordinary General Public License for many libraries. However, the Lesser license provides advantages in certain special circumstances. For example, on rare occasions, there may be a special need to encourage the widest possible use of a certain library, so that it becomes a de-facto standard. To achieve this, non-free programs must be allowed to use the library. A more frequent case is that a free library does the same job as widely used non-free libraries. In this case, there is little to gain by limiting the free library to free software only, so we use the Lesser General Public License. In other cases, permission to use a particular library in non-free programs enables a greater number of people to use a large body of free software. For example, permission to use the GNU C Library in non-free programs enables many more people to use the whole GNU operating system, as well as its variant, the GNU/Linux operating system. Although the Lesser General Public License is Less protective of the users' freedom, it does ensure that the user of a program that is linked with the Library has the freedom and the wherewithal to run that program using a modified version of the Library. The precise terms and conditions for copying, distribution and modification follow. Pay close attention to the difference between a "work based on the library" and a "work that uses the library". The former contains code derived from the library, whereas the latter must be combined with the library in order to run. GNU LESSER GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License Agreement applies to any software library or other program which contains a notice placed by the copyright holder or other authorized party saying it may be distributed under the terms of this Lesser General Public License (also called "this License"). Each licensee is addressed as "you". A "library" means a collection of software functions and/or data prepared so as to be conveniently linked with application programs (which use some of those functions and data) to form executables. The "Library", below, refers to any such software library or work which has been distributed under these terms. A "work based on the Library" means either the Library or any derivative work under copyright law: that is to say, a work containing the Library or a portion of it, either verbatim or with modifications and/or translated straightforwardly into another language. (Hereinafter, translation is included without limitation in the term "modification".) "Source code" for a work means the preferred form of the work for making modifications to it. For a library, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the library. Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running a program using the Library is not restricted, and output from such a program is covered only if its contents constitute a work based on the Library (independent of the use of the Library in a tool for writing it). Whether that is true depends on what the Library does and what the program that uses the Library does. 1. You may copy and distribute verbatim copies of the Library's complete source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and distribute a copy of this License along with the Library. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Library or any portion of it, thus forming a work based on the Library, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) The modified work must itself be a software library. b) You must cause the files modified to carry prominent notices stating that you changed the files and the date of any change. c) You must cause the whole of the work to be licensed at no charge to all third parties under the terms of this License. d) If a facility in the modified Library refers to a function or a table of data to be supplied by an application program that uses the facility, other than as an argument passed when the facility is invoked, then you must make a good faith effort to ensure that, in the event an application does not supply such function or table, the facility still operates, and performs whatever part of its purpose remains meaningful. (For example, a function in a library to compute square roots has a purpose that is entirely well-defined independent of the application. Therefore, Subsection 2d requires that any application-supplied function or table used by this function must be optional: if the application does not supply it, the square root function must still compute square roots.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Library, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Library, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Library. In addition, mere aggregation of another work not based on the Library with the Library (or with a work based on the Library) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may opt to apply the terms of the ordinary GNU General Public License instead of this License to a given copy of the Library. To do this, you must alter all the notices that refer to this License, so that they refer to the ordinary GNU General Public License, version 2, instead of to this License. (If a newer version than version 2 of the ordinary GNU General Public License has appeared, then you can specify that version instead if you wish.) Do not make any other change in these notices. Once this change is made in a given copy, it is irreversible for that copy, so the ordinary GNU General Public License applies to all subsequent copies and derivative works made from that copy. This option is useful when you wish to copy part of the code of the Library into a program that is not a library. 4. You may copy and distribute the Library (or a portion or derivative of it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange. If distribution of object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place satisfies the requirement to distribute the source code, even though third parties are not compelled to copy the source along with the object code. 5. A program that contains no derivative of any portion of the Library, but is designed to work with the Library by being compiled or linked with it, is called a "work that uses the Library". Such a work, in isolation, is not a derivative work of the Library, and therefore falls outside the scope of this License. However, linking a "work that uses the Library" with the Library creates an executable that is a derivative of the Library (because it contains portions of the Library), rather than a "work that uses the library". The executable is therefore covered by this License. Section 6 states terms for distribution of such executables. When a "work that uses the Library" uses material from a header file that is part of the Library, the object code for the work may be a derivative work of the Library even though the source code is not. Whether this is true is especially significant if the work can be linked without the Library, or if the work is itself a library. The threshold for this to be true is not precisely defined by law. If such an object file uses only numerical parameters, data structure layouts and accessors, and small macros and small inline functions (ten lines or less in length), then the use of the object file is unrestricted, regardless of whether it is legally a derivative work. (Executables containing this object code plus portions of the Library will still fall under Section 6.) Otherwise, if the work is a derivative of the Library, you may distribute the object code for the work under the terms of Section 6. Any executables containing that work also fall under Section 6, whether or not they are linked directly with the Library itself. 6. As an exception to the Sections above, you may also combine or link a "work that uses the Library" with the Library to produce a work containing portions of the Library, and distribute that work under terms of your choice, provided that the terms permit modification of the work for the customer's own use and reverse engineering for debugging such modifications. You must give prominent notice with each copy of the work that the Library is used in it and that the Library and its use are covered by this License. You must supply a copy of this License. If the work during execution displays copyright notices, you must include the copyright notice for the Library among them, as well as a reference directing the user to the copy of this License. Also, you must do one of these things: a) Accompany the work with the complete corresponding machine-readable source code for the Library including whatever changes were used in the work (which must be distributed under Sections 1 and 2 above); and, if the work is an executable linked with the Library, with the complete machine-readable "work that uses the Library", as object code and/or source code, so that the user can modify the Library and then relink to produce a modified executable containing the modified Library. (It is understood that the user who changes the contents of definitions files in the Library will not necessarily be able to recompile the application to use the modified definitions.) b) Use a suitable shared library mechanism for linking with the Library. A suitable mechanism is one that (1) uses at run time a copy of the library already present on the user's computer system, rather than copying library functions into the executable, and (2) will operate properly with a modified version of the library, if the user installs one, as long as the modified version is interface-compatible with the version that the work was made with. c) Accompany the work with a written offer, valid for at least three years, to give the same user the materials specified in Subsection 6a, above, for a charge no more than the cost of performing this distribution. d) If distribution of the work is made by offering access to copy from a designated place, offer equivalent access to copy the above specified materials from the same place. e) Verify that the user has already received a copy of these materials or that you have already sent this user a copy. For an executable, the required form of the "work that uses the Library" must include any data and utility programs needed for reproducing the executable from it. However, as a special exception, the materials to be distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. It may happen that this requirement contradicts the license restrictions of other proprietary libraries that do not normally accompany the operating system. Such a contradiction means you cannot use both them and the Library together in an executable that you distribute. 7. You may place library facilities that are a work based on the Library side-by-side in a single library together with other library facilities not covered by this License, and distribute such a combined library, provided that the separate distribution of the work based on the Library and of the other library facilities is otherwise permitted, and provided that you do these two things: a) Accompany the combined library with a copy of the same work based on the Library, uncombined with any other library facilities. This must be distributed under the terms of the Sections above. b) Give prominent notice with the combined library of the fact that part of it is a work based on the Library, and explaining where to find the accompanying uncombined form of the same work. 8. You may not copy, modify, sublicense, link with, or distribute the Library except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense, link with, or distribute the Library is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 9. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Library or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Library (or any work based on the Library), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Library or works based on it. 10. Each time you redistribute the Library (or any work based on the Library), the recipient automatically receives a license from the original licensor to copy, distribute, link with or modify the Library subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties with this License. 11. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Library at all. For example, if a patent license would not permit royalty-free redistribution of the Library by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Library. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply, and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 12. If the distribution and/or use of the Library is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Library under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 13. The Free Software Foundation may publish revised and/or new versions of the Lesser General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Library specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Library does not specify a license version number, you may choose any version ever published by the Free Software Foundation. 14. If you wish to incorporate parts of the Library into other free programs whose distribution conditions are incompatible with these, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Libraries If you develop a new library, and you want it to be of the greatest possible use to the public, we recommend making it free software that everyone can redistribute and change. You can do so by permitting redistribution under these terms (or, alternatively, under the terms of the ordinary General Public License). To apply these terms, attach the following notices to the library. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA Also add information on how to contact you by electronic and paper mail. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the library, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the library `Frob' (a library for tweaking knobs) written by James Random Hacker. , 1 April 1990 Ty Coon, President of Vice That's all there is to it! libical-3.0.1/LICENSE.MPL2.txt000066400000000000000000000405251320431302500154450ustar00rootroot00000000000000Mozilla Public License Version 2.0 ================================== 1. Definitions -------------- 1.1. "Contributor" means each individual or legal entity that creates, contributes to the creation of, or owns Covered Software. 1.2. "Contributor Version" means the combination of the Contributions of others (if any) used by a Contributor and that particular Contributor's Contribution. 1.3. "Contribution" means Covered Software of a particular Contributor. 1.4. "Covered Software" means Source Code Form to which the initial Contributor has attached the notice in Exhibit A, the Executable Form of such Source Code Form, and Modifications of such Source Code Form, in each case including portions thereof. 1.5. "Incompatible With Secondary Licenses" means (a) that the initial Contributor has attached the notice described in Exhibit B to the Covered Software; or (b) that the Covered Software was made available under the terms of version 1.1 or earlier of the License, but not also under the terms of a Secondary License. 1.6. "Executable Form" means any form of the work other than Source Code Form. 1.7. "Larger Work" means a work that combines Covered Software with other material, in a separate file or files, that is not Covered Software. 1.8. "License" means this document. 1.9. "Licensable" means having the right to grant, to the maximum extent possible, whether at the time of the initial grant or subsequently, any and all of the rights conveyed by this License. 1.10. "Modifications" means any of the following: (a) any file in Source Code Form that results from an addition to, deletion from, or modification of the contents of Covered Software; or (b) any new file in Source Code Form that contains any Covered Software. 1.11. "Patent Claims" of a Contributor means any patent claim(s), including without limitation, method, process, and apparatus claims, in any patent Licensable by such Contributor that would be infringed, but for the grant of the License, by the making, using, selling, offering for sale, having made, import, or transfer of either its Contributions or its Contributor Version. 1.12. "Secondary License" means either the GNU General Public License, Version 2.0, the GNU Lesser General Public License, Version 2.1, the GNU Affero General Public License, Version 3.0, or any later versions of those licenses. 1.13. "Source Code Form" means the form of the work preferred for making modifications. 1.14. "You" (or "Your") means an individual or a legal entity exercising rights under this License. For legal entities, "You" includes any entity that controls, is controlled by, or is under common control with You. For purposes of this definition, "control" means (a) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (b) ownership of more than fifty percent (50%) of the outstanding shares or beneficial ownership of such entity. 2. License Grants and Conditions -------------------------------- 2.1. Grants Each Contributor hereby grants You a world-wide, royalty-free, non-exclusive license: (a) under intellectual property rights (other than patent or trademark) Licensable by such Contributor to use, reproduce, make available, modify, display, perform, distribute, and otherwise exploit its Contributions, either on an unmodified basis, with Modifications, or as part of a Larger Work; and (b) under Patent Claims of such Contributor to make, use, sell, offer for sale, have made, import, and otherwise transfer either its Contributions or its Contributor Version. 2.2. Effective Date The licenses granted in Section 2.1 with respect to any Contribution become effective for each Contribution on the date the Contributor first distributes such Contribution. 2.3. Limitations on Grant Scope The licenses granted in this Section 2 are the only rights granted under this License. No additional rights or licenses will be implied from the distribution or licensing of Covered Software under this License. Notwithstanding Section 2.1(b) above, no patent license is granted by a Contributor: (a) for any code that a Contributor has removed from Covered Software; or (b) for infringements caused by: (i) Your and any other third party's modifications of Covered Software, or (ii) the combination of its Contributions with other software (except as part of its Contributor Version); or (c) under Patent Claims infringed by Covered Software in the absence of its Contributions. This License does not grant any rights in the trademarks, service marks, or logos of any Contributor (except as may be necessary to comply with the notice requirements in Section 3.4). 2.4. Subsequent Licenses No Contributor makes additional grants as a result of Your choice to distribute the Covered Software under a subsequent version of this License (see Section 10.2) or under the terms of a Secondary License (if permitted under the terms of Section 3.3). 2.5. Representation Each Contributor represents that the Contributor believes its Contributions are its original creation(s) or it has sufficient rights to grant the rights to its Contributions conveyed by this License. 2.6. Fair Use This License is not intended to limit any rights You have under applicable copyright doctrines of fair use, fair dealing, or other equivalents. 2.7. Conditions Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted in Section 2.1. 3. Responsibilities ------------------- 3.1. Distribution of Source Form All distribution of Covered Software in Source Code Form, including any Modifications that You create or to which You contribute, must be under the terms of this License. You must inform recipients that the Source Code Form of the Covered Software is governed by the terms of this License, and how they can obtain a copy of this License. You may not attempt to alter or restrict the recipients' rights in the Source Code Form. 3.2. Distribution of Executable Form If You distribute Covered Software in Executable Form then: (a) such Covered Software must also be made available in Source Code Form, as described in Section 3.1, and You must inform recipients of the Executable Form how they can obtain a copy of such Source Code Form by reasonable means in a timely manner, at a charge no more than the cost of distribution to the recipient; and (b) You may distribute such Executable Form under the terms of this License, or sublicense it under different terms, provided that the license for the Executable Form does not attempt to limit or alter the recipients' rights in the Source Code Form under this License. 3.3. Distribution of a Larger Work You may create and distribute a Larger Work under terms of Your choice, provided that You also comply with the requirements of this License for the Covered Software. If the Larger Work is a combination of Covered Software with a work governed by one or more Secondary Licenses, and the Covered Software is not Incompatible With Secondary Licenses, this License permits You to additionally distribute such Covered Software under the terms of such Secondary License(s), so that the recipient of the Larger Work may, at their option, further distribute the Covered Software under the terms of either this License or such Secondary License(s). 3.4. Notices You may not remove or alter the substance of any license notices (including copyright notices, patent notices, disclaimers of warranty, or limitations of liability) contained within the Source Code Form of the Covered Software, except that You may alter any license notices to the extent required to remedy known factual inaccuracies. 3.5. Application of Additional Terms You may choose to offer, and to charge a fee for, warranty, support, indemnity or liability obligations to one or more recipients of Covered Software. However, You may do so only on Your own behalf, and not on behalf of any Contributor. You must make it absolutely clear that any such warranty, support, indemnity, or liability obligation is offered by You alone, and You hereby agree to indemnify every Contributor for any liability incurred by such Contributor as a result of warranty, support, indemnity or liability terms You offer. You may include additional disclaimers of warranty and limitations of liability specific to any jurisdiction. 4. Inability to Comply Due to Statute or Regulation --------------------------------------------------- If it is impossible for You to comply with any of the terms of this License with respect to some or all of the Covered Software due to statute, judicial order, or regulation then You must: (a) comply with the terms of this License to the maximum extent possible; and (b) describe the limitations and the code they affect. Such description must be placed in a text file included with all distributions of the Covered Software under this License. Except to the extent prohibited by statute or regulation, such description must be sufficiently detailed for a recipient of ordinary skill to be able to understand it. 5. Termination -------------- 5.1. The rights granted under this License will terminate automatically if You fail to comply with any of its terms. However, if You become compliant, then the rights granted under this License from a particular Contributor are reinstated (a) provisionally, unless and until such Contributor explicitly and finally terminates Your grants, and (b) on an ongoing basis, if such Contributor fails to notify You of the non-compliance by some reasonable means prior to 60 days after You have come back into compliance. Moreover, Your grants from a particular Contributor are reinstated on an ongoing basis if such Contributor notifies You of the non-compliance by some reasonable means, this is the first time You have received notice of non-compliance with this License from such Contributor, and You become compliant prior to 30 days after Your receipt of the notice. 5.2. If You initiate litigation against any entity by asserting a patent infringement claim (excluding declaratory judgment actions, counter-claims, and cross-claims) alleging that a Contributor Version directly or indirectly infringes any patent, then the rights granted to You by any and all Contributors for the Covered Software under Section 2.1 of this License shall terminate. 5.3. In the event of termination under Sections 5.1 or 5.2 above, all end user license agreements (excluding distributors and resellers) which have been validly granted by You or Your distributors under this License prior to termination shall survive termination. ************************************************************************ * * * 6. Disclaimer of Warranty * * ------------------------- * * * * Covered Software is provided under this License on an "as is" * * basis, without warranty of any kind, either expressed, implied, or * * statutory, including, without limitation, warranties that the * * Covered Software is free of defects, merchantable, fit for a * * particular purpose or non-infringing. The entire risk as to the * * quality and performance of the Covered Software is with You. * * Should any Covered Software prove defective in any respect, You * * (not any Contributor) assume the cost of any necessary servicing, * * repair, or correction. This disclaimer of warranty constitutes an * * essential part of this License. No use of any Covered Software is * * authorized under this License except under this disclaimer. * * * ************************************************************************ ************************************************************************ * * * 7. Limitation of Liability * * -------------------------- * * * * Under no circumstances and under no legal theory, whether tort * * (including negligence), contract, or otherwise, shall any * * Contributor, or anyone who distributes Covered Software as * * permitted above, be liable to You for any direct, indirect, * * special, incidental, or consequential damages of any character * * including, without limitation, damages for lost profits, loss of * * goodwill, work stoppage, computer failure or malfunction, or any * * and all other commercial damages or losses, even if such party * * shall have been informed of the possibility of such damages. This * * limitation of liability shall not apply to liability for death or * * personal injury resulting from such party's negligence to the * * extent applicable law prohibits such limitation. Some * * jurisdictions do not allow the exclusion or limitation of * * incidental or consequential damages, so this exclusion and * * limitation may not apply to You. * * * ************************************************************************ 8. Litigation ------------- Any litigation relating to this License may be brought only in the courts of a jurisdiction where the defendant maintains its principal place of business and such litigation shall be governed by laws of that jurisdiction, without reference to its conflict-of-law provisions. Nothing in this Section shall prevent a party's ability to bring cross-claims or counter-claims. 9. Miscellaneous ---------------- This License represents the complete agreement concerning the subject matter hereof. If any provision of this License is held to be unenforceable, such provision shall be reformed only to the extent necessary to make it enforceable. Any law or regulation which provides that the language of a contract shall be construed against the drafter shall not be used to construe this License against a Contributor. 10. Versions of the License --------------------------- 10.1. New Versions Mozilla Foundation is the license steward. Except as provided in Section 10.3, no one other than the license steward has the right to modify or publish new versions of this License. Each version will be given a distinguishing version number. 10.2. Effect of New Versions You may distribute the Covered Software under the terms of the version of the License under which You originally received the Covered Software, or under the terms of any subsequent version published by the license steward. 10.3. Modified Versions If you create software not governed by this License, and you want to create a new license for such software, you may create and use a modified version of this License if you rename the license and remove any references to the name of the license steward (except to note that such modified license differs from this License). 10.4. Distributing Source Code Form that is Incompatible With Secondary Licenses If You choose to distribute Source Code Form that is Incompatible With Secondary Licenses under the terms of this version of the License, the notice described in Exhibit B of this License must be attached. Exhibit A - Source Code Form License Notice ------------------------------------------- This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/. If it is not possible or desirable to put the notice in a particular file, then You may include the notice in a location (such as a LICENSE file in a relevant directory) where a recipient would be likely to look for such a notice. You may add additional accurate notices of copyright ownership. Exhibit B - "Incompatible With Secondary Licenses" Notice --------------------------------------------------------- This Source Code Form is "Incompatible With Secondary Licenses", as defined by the Mozilla Public License, v. 2.0. libical-3.0.1/LibIcalConfig.cmake.in000066400000000000000000000005751320431302500171460ustar00rootroot00000000000000@PACKAGE_INIT@ set_and_check(LibIcal_INCLUDE_DIR "@PACKAGE_INCLUDE_INSTALL_DIR@") set_and_check(LibIcal_LIBRARIES_DIR "@PACKAGE_LIB_INSTALL_DIR@") include("${CMAKE_CURRENT_LIST_DIR}/LibIcalTargets.cmake") set(LibIcal_LIBRARIES ical icalss icalvcal) # Temporary, will be removed once issue#87 is fixed set(LibIcal_STATIC_LIBRARIES ical-static icalss-static icalvcal-static) libical-3.0.1/ReadMe.md000077700000000000000000000000001320431302500164532ReadMe.txtustar00rootroot00000000000000libical-3.0.1/ReadMe.txt000066400000000000000000000054011320431302500150010ustar00rootroot00000000000000# Libical [![Build Status](https://travis-ci.org/libical/libical.svg?branch=master)](https://travis-ci.org/libical/libical) [![Coverity Scan Build Status](https://scan.coverity.com/projects/2367/badge.svg)](https://scan.coverity.com/projects/2367) ## Introduction Libical — an implementation of iCalendar protocols and data formats Most of the code in here was written by Eric Busboom with help from dozens of contributors. It is currently maintained by Art Cancro and Wilfried Goesgens. Libical is an Open Source implementation of the iCalendar protocols and protocol data units. The iCalendar specification describes how calendar clients can communicate with calendar servers so users can store their calendar data and arrange meetings with other users. Libical implements [RFC5545][], [RFC5546][], [RFC7529][]; the iCalendar extensions in [RFC6638][]; and some of [RFC6047][]. [RFC5545]: https://tools.ietf.org/html/rfc5545 [RFC5546]: https://tools.ietf.org/html/rfc5546 [RFC7529]: https://tools.ietf.org/html/rfc7529 [RFC6638]: https://tools.ietf.org/html/rfc6638 [RFC6047]: https://tools.ietf.org/html/rfc6047 ## License The code and datafiles in this distribution are licensed under the Mozilla Public License (MPL) v2.0. See for a copy of this license. Alternately, you may use libical under the terms of the GNU Lesser General Public License (LGPL) v2.1. See for a copy of this license. This dual license ensures that the library can be incorporated into both proprietary code and GPL'd programs, and will benefit from improvements made by programmers in both realms. I will only accept changes into my version of the library if they are similarly dual-licensed. ## Building See the top-level [Install.txt](Install.txt) file. ## Documentation There is rudimentary, unfinished documentation in the `doc/` directory, see [UsingLibical.md](doc/UsingLibical.md) and annotated examples in `examples/` and the test code in `src/test/`. Additionally, progress is underway to add Doxygen documentation for libical, which is available [here](http://libical.github.io/libical/apidocs/index.html) ## Acknowledgments Portions of this distribution are (C) Copyright 1996 Apple Computer, Inc., AT&T Corp., International Business Machines Corporation and Siemens Rolm Communications Inc. See [src/libicalvcal/README.TXT](src/libicalvcal/README.txt) for details. ## Get Involved Subscribe to our mailing lists: For developer discussions For general discussions about libical and related projects Report bugs to our issue tracker at libical-3.0.1/ReleaseNotes.txt000066400000000000000000000111601320431302500162340ustar00rootroot00000000000000Release Highlights ================== Version 3.0.1: -------------- * Built-in timezones updated to tzdata2017c * Fix a multi-threaded deadlock in icaltimezone_load_builtin_timezone() * Fix a CMake problem with parallel builds Version 3.0.0: -------------- * Relicense from MPL 1.0 to MPL 2.0 (keep dual license for LGPL v2.1) * Requires CMake v3.1.0 or higher along with various CMake and buildsystem fixes * Added a 'make uninstall' * Fixed use-after-free issues and some memory leaks * Built-in timezones updated to tzdata2017b * More accurate VTIMEZONE generation when using the system time zone data (when USE_BUILTIN_TZDATA=False) * icalvalue_as_ical_string() returns "TRUE" (non-zero) or "FALSE" (zero) values only. * New icalvalue.h convenience macros: ICAL_BOOLEAN_TRUE and ICAL_BOOLEAN_FALSE * Better value type checking of property values when parsing * icalvalue_new/set_date and icalvalue_new/set_datetime now enforce DATE and DATE-TIME values respectively * draft-ietf-calext-extensions (RFC 7986) support added * Parameter values are now en/decoded per RFC 6868 * Removed is_utc from icaltimetype struct * Set icaltimetype.zone to icaltimezone_get_utc_timezone() to change a time to UTC * Use icaltime_is_utc() to check if a time is in UTC * Added support for VPATCH component * New publicly available functions: + icalproperty_set_parent (icalproperty_get_parent was already public) + icalvalue_get_parent (icalvalue_set_parent was already public) + icalparameter_set_parent + icalparameter_get_parent + icalvalue_new_datetimedate (DATE or DATE-TIME) + icalvalue_set_datetimedate + icalvalue_get_datetimedate + icalrecur_iterator_set_start + icalcomponent_normalize() + icalproperty_normalize() * Removed deprecated functions: + icaltime_from_timet (use icaltime_from_timet_with_zone) + icaltime_start_day_of_week (use icaltime_start_day_week) + icalproperty_remove_parameter (use icalproperty_remove_parameter_by_kind) + icalproperty_string_to_enum (use icalproperty_kind_and_string_to_enum) * Signature changed for functions: + VObject *Parse_MIME_FromFileName(const char *fname) + icalgauge *icalgauge_new_from_sql(const char *sql, int expand) + const char *icallangbind_property_eval_string(icalproperty *prop, const char *sep) + const char *icallangbind_property_eval_string_r(icalproperty *prop, const char *sep) + void set_zone_directory(const char *path) + icalcalendar *icalcalendar_new(const char *dir) + int icalrecur_expand_recurrence(const char *rule, time_t start, int count, time_t *array) Version 2.0.0: -------------- * WARNING: Version 2 IS NOT Binary Compatible with Older Versions * Version 2 is Source Compatible with Older Versions * Lots of source code scrubbing * [New] RSCALE support (requires libicu from http://www.icu-project.org) * [New] CalDAV attachment support (draft-ietf-calext-caldav-attachments) * [New] Resurrect the Berkeley DB storage support * [Bug] issue83: Incorrect recurrence generation for weekly pattern * Handle RRULEs better * Handle threading better Version 1.0.1: -------------- * [Bug] issue74: Do not escape double quote character * [Bug] issue80,issue92: fix crashes using icaltimezone_load_builtin_timezone() recursively * [Bug] Fix icalcomponent_foreach_recurrence() and large durations between recurrences (e.g. FREQ=YEARLY) * [Bug] Properly handle UTCOFFSETs of the form +/-00mmss * [Bug] Properly skip bogus dates (e.g. 2/30, 4/31) in RRULE:FREQ=MONTHLY * [Bug] Properly handle RRULE:FREQ=MONTHLY;BYDAY;BYMONTHDAY when DTSTART isn't on BYDAY * [Bug] Fix RRULE:FREQ=YEARLY;BYDAY;BYWEEKNO - MUST use ISO weeks * [Bug] Properly skip bogus dates (e.g. 2/29) in RRULE:FREQ=YEARLY[;BYMONTH][;BYMONTHDAY] * [New] Update tzdata to version 2014g * [New] Support added for schedule params: agent, status, force-send * [New] Added a UID to the VFREEBUSY component * [New] Allow dates > 2038 if sizeof(time_t) > 4 * [New] Add properties from draft-ietf-tzdist-service * [New] Add support for RRULE:FREQ=YEARLY;BYDAY;BYYEARDAY and fixed RRULE:FREQ=YEARLY;BYYEARDAY with negative days * [Build] Autotools build system is removed * [Build] CMake version 2.8.9 (or higher) is required (was CMake version 2.4.0) * [Build] Add new -DSHARED_ONLY and -DSTATIC_ONLY CMake options * [Build] Remove -DSTATIC_LIBRARY CMake option * [Build] MSYS2 builds (fixed instructions) * [Build/Doc] Now can build api documentation with make docs * [Quality] More regression tests added, in particular for recurrence * [Quality] Almost all compile warnings silenced * [Quality] A bunch of Coverity Scan warnings silenced libical-3.0.1/TEST000066400000000000000000000001171320431302500136040ustar00rootroot00000000000000 Parser Tests ------------ Use iCAL keywords as first words of unquoted stringslibical-3.0.1/THANKS000066400000000000000000000045361320431302500140260ustar00rootroot00000000000000Thanks to: Allan Clark for testing libical against UnixWare. Graham Davison for MacOS support and miscelaneous code bits Seth Alves for the first cut at the Makefile.am files and various utility functions. Russ Steinthal for several utility functions and comments. Ola Lundqvist for the vCal test data file. Colin DuPlantis for new functions in icalparser.c Holger Schmidt for all of icalcstp.c, The CSTP protocol implementation, and modifications to icalcstp.h Gisle Hannemyr The decode*() functions in sspm.c are based on the decode() routine in the mimelite program, Copyright (c) 1994 Gisle Hannemyr. The Evolution team at Helixcode ( Federico Mena Quintero , JP Rosevear , Ettore Perazzoli , Christopher James Lahey , Peter Williams ) for miscelaneous patches and adjustments to the build system. Cornelius Schumacher for many insightful suggestions and a few patches. Mark D. Anderson for discussions and ideas. Martin Neimeier for correcting bugs in icalrecur.c Tom Leitner For several bug fixes in compiling on Tru64 UNIX. Patrick Lewis for several bug reports and substantial ( co-authorship) contributions to the Python bindings Larry W. Virden for several bug reports in compiling on Solaris. Bryan Bartone for code changes based on porting libical to Windows. Hubert V for checking and analyzing the output of the recurrence rule system. Jonathan Yue for icalproperty_get_name() Jeff Mace for finding bugs in gauges. John Gray for routing memory leaks, porting to WIN32, and taking over leadership of the project. Andrea Campi for miscellaneous updates and beginning of Doxygen documentation. Paul Lindner for several contributions, including C++ binding, reentrant parser, thread safe memory allocator, and a lot of documentation. Mark Tearle for keeping the Python bindings up to date. libical-3.0.1/TODO000066400000000000000000000023071320431302500135750ustar00rootroot00000000000000 TODOs for libical ----------------- fix Coverity Scan issues libical treats properties with multiple values incorrecty -- it always seperates multiple values into multiple properties. This is not acceptable for CATEGORIES and RESOURCES. Some TEXT valued properties, like METHOD, have a limited set of valid values. The code should check that the values of these properites are valid. ( Although METHOD now uses enums, and is not really TEXT valued ) Finish implementing values ATTACH/BINARY content_type language Check for buffer overflow on external input. Error Handling Dates and times: the parser will accept many illegal date time values RECUR values ignore integers in BYDAY clauses, ie 'FREQ=MONTHLY;BYDAY=-1SU' Restrictions code does not catch lack of DTEND or DURATION For some value types, if there illegal characters in the value ( like 4.56 in an integer value), the parser will output the characters to stdout. Check all uses of strcpy and sprinf for buffer overflows Make the mime parsing code in sspm grow the list of parts as needed, rather than having a hard limit. in sspm.c, and unrecognized content-transfer-encoding values must force a content type of application/octet-stream. libical-3.0.1/appveyor.yml000066400000000000000000000033411320431302500154740ustar00rootroot00000000000000#---------------------------------# # general configuration # #---------------------------------# # version format version: 1.0.{build}-{branch} # branches to build branches: except: - gh-pages # Do not build on tags (GitHub and BitBucket) skip_tags: false #---------------------------------# # environment configuration # #---------------------------------# # Build worker image image: - Visual Studio 2013 # scripts that are called at very beginning, before repo cloning init: - git config --global core.autocrlf input #---------------------------------# # build configuration # #---------------------------------# # build platform, i.e. x86, x64, Any CPU. This setting is optional. platform: # - x86 uses 32bit time_t - x64 # build Configuration, i.e. Debug, Release, etc. configuration: # - 2015 - 2013 - 2012 # - MinGW #todo: 2010, 2008 build_script: - call scripts\set_compiler_env.bat - mkdir build - cd build - if "%configuration%" EQU "MinGW" ( cmake -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=Release -DICAL_GLIB=False .. ) else ( cmake -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=Release -DICAL_GLIB=False .. ) - nmake # to disable automatic builds #build: off #---------------------------------# # tests configuration # #---------------------------------# test_script: - nmake test # to disable automatic tests #test: off #---------------------------------# # deployment configuration # #---------------------------------# deploy: off #---------------------------------# # notifications # #---------------------------------# notifications: # Email - provider: Email to: - allen.winter@kdab.com on_build_status_changed: true libical-3.0.1/cmake/000077500000000000000000000000001320431302500141635ustar00rootroot00000000000000libical-3.0.1/cmake/Toolchain-Linux-GCC-i686.cmake000066400000000000000000000034151320431302500212710ustar00rootroot00000000000000# Toolchain file for 32bit builds on 64bit Linux hosts # # Copyright (c) 2013-2016 Klarälvdalens Datakonsult AB, a KDAB Group company # All rights reserved. # # Author: Volker Krause # Author: Filipe Azevedo # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # # 1. Redistributions of source code must retain the copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # 3. The name of the author may not be used to endorse or promote products # derived from this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. set(CMAKE_SYSTEM_NAME "Linux") set(CMAKE_SYSTEM_PROCESSOR "i686") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -m32") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m32") libical-3.0.1/cmake/Toolchain-OSX-GCC-i686.cmake000066400000000000000000000034141320431302500206420ustar00rootroot00000000000000# Toolchain file for 32bit builds on 64bit OSX hosts # # Copyright (c) 2013-2016 Klarälvdalens Datakonsult AB, a KDAB Group company # All rights reserved. # # Author: Volker Krause # Author: Filipe Azevedo # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # # 1. Redistributions of source code must retain the copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # 3. The name of the author may not be used to endorse or promote products # derived from this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. set(CMAKE_SYSTEM_NAME "Darwin") set(CMAKE_SYSTEM_PROCESSOR "i686") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -m32") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m32") libical-3.0.1/cmake/Toolchain-QNX65.cmake000066400000000000000000000065251320431302500177340ustar00rootroot00000000000000# # (C) Copyright 2009 Johns Hopkins University (JHU), All Rights # Reserved. # # --- begin cisst license - do not edit --- # # This software is provided "as is" under an open source license, with # no warranty. The complete license can be found in license.txt and # http://www.cisst.org/cisst/license.txt. # # --- end cisst license --- SET(CMAKE_SYSTEM_NAME QNX) SET(CMAKE_SYSTEM_VERSION 6.5.0) SET(CMAKE_SYSTEM_PROCESSOR x86) SET(TOOLCHAIN QNX) #SET(CMAKE_IMPORT_LIBRARY_SUFFIX ".a") SET(CMAKE_SHARED_LIBRARY_PREFIX "lib") SET(CMAKE_SHARED_LIBRARY_SUFFIX ".so") SET(CMAKE_STATIC_LIBRARY_PREFIX "lib") SET(CMAKE_STATIC_LIBRARY_SUFFIX ".a") IF(CMAKE_HOST_WIN32) SET(HOST_EXECUTABLE_SUFFIX ".exe") ENDIF(CMAKE_HOST_WIN32) FIND_PATH(QNX_HOST NAME usr/bin/qcc${HOST_EXECUTABLE_SUFFIX} PATHS $ENV{QNX_HOST} C:/QNX650/host/win32/x86 NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH ) FIND_PATH(QNX_TARGET NAME usr/include/qnx_errno.h PATHS $ENV{QNX_TARGET} C:/QNX650/target/qnx6 NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH ) IF(CMAKE_HOST_WIN32) FIND_PATH(QNX_CONFIGURATION NAME bin/qnxactivate.exe PATHS $ENV{QNX_CONFIGURATION} "C:/Program Files/QNX Software Systems/qconfig" NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH ) ENDIF(CMAKE_HOST_WIN32) SET(ENV{QNX_HOST} ${QNX_HOST}) SET(ENV{QNX_TARGET} ${QNX_TARGET}) IF(CMAKE_HOST_WIN32) SET(ENV{QNX_CONFIGURATION} ${QNX_CONFIGURATION}) SET(ENV{PATH} "$ENV{PATH};${QNX_HOST}/usr/bin") ENDIF(CMAKE_HOST_WIN32) SET(CMAKE_MAKE_PROGRAM "${QNX_HOST}/usr/bin/make${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX Make Program") SET(CMAKE_SH "${QNX_HOST}/usr/bin/sh${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX shell Program") SET(CMAKE_AR "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-ar${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX ar Program") SET(CMAKE_RANLIB "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-ranlib${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX ranlib Program") SET(CMAKE_NM "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-nm${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX nm Program") SET(CMAKE_OBJCOPY "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-objcopy${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX objcopy Program") SET(CMAKE_OBJDUMP "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-objdump${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX objdump Program") SET(CMAKE_LINKER "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-ld" CACHE PATH "QNX Linker Program") SET(CMAKE_STRIP "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-strip${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX Strip Program") SET(CMAKE_C_COMPILER ${QNX_HOST}/usr/bin/qcc) SET(CMAKE_C_FLAGS_DEBUG "-g") SET(CMAKE_C_FLAGS_MINSIZEREL "-Os -DNDEBUG") SET(CMAKE_C_FLAGS_RELEASE "-O3 -DNDEBUG") SET(CMAKE_C_FLAGS_RELWITHDEBINFO "-O2 -g") SET(CMAKE_CXX_COMPILER ${QNX_HOST}/usr/bin/qcc) SET(CMAKE_CXX_FLAGS_DEBUG "-g") SET(CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG") SET(CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG") SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g") SET(CMAKE_FIND_ROOT_PATH ${QNX_TARGET}) SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) SET(CMAKE_C_FLAGS "-Vgcc_ntoarmv7le" CACHE STRING "qcc c flags" FORCE) SET(CMAKE_CXX_FLAGS "-Vgcc_ntoarmv7le -lang-c++" CACHE STRING "qcc cxx flags" FORCE) libical-3.0.1/cmake/Toolchain-QNX66.cmake000066400000000000000000000066421320431302500177350ustar00rootroot00000000000000# # (C) Copyright 2009 Johns Hopkins University (JHU), All Rights # Reserved. # # --- begin cisst license - do not edit --- # # This software is provided "as is" under an open source license, with # no warranty. The complete license can be found in license.txt and # http://www.cisst.org/cisst/license.txt. # # --- end cisst license --- SET(CMAKE_SYSTEM_NAME QNX) SET(CMAKE_SYSTEM_VERSION 6.6.0) SET(CMAKE_SYSTEM_PROCESSOR armv7) SET(TOOLCHAIN QNX) #SET(CMAKE_IMPORT_LIBRARY_SUFFIX ".a") SET(CMAKE_SHARED_LIBRARY_PREFIX "lib") SET(CMAKE_SHARED_LIBRARY_SUFFIX ".so") SET(CMAKE_STATIC_LIBRARY_PREFIX "lib") SET(CMAKE_STATIC_LIBRARY_SUFFIX ".a") IF(CMAKE_HOST_WIN32) SET(HOST_EXECUTABLE_SUFFIX ".exe") ENDIF(CMAKE_HOST_WIN32) FIND_PATH(QNX_HOST NAME usr/bin/qcc${HOST_EXECUTABLE_SUFFIX} PATHS $ENV{QNX_HOST} C:/qnx660/host/win32/x86 NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH ) FIND_PATH(QNX_TARGET NAME usr/include/qconfig.mk PATHS $ENV{QNX_TARGET} C:/qnx660/target/qnx6 NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH ) IF(CMAKE_HOST_WIN32) FIND_PATH(QNX_CONFIGURATION NAME bin/qnxactivate.exe PATHS $ENV{QNX_CONFIGURATION} "C:/Program Files/QNX Software Systems/qconfig" NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH ) ENDIF(CMAKE_HOST_WIN32) SET(ENV{QNX_HOST} ${QNX_HOST}) SET(ENV{QNX_TARGET} ${QNX_TARGET}) IF(CMAKE_HOST_WIN32) SET(ENV{QNX_CONFIGURATION} ${QNX_CONFIGURATION}) SET(ENV{PATH} "$ENV{PATH};${QNX_HOST}/usr/bin") ENDIF(CMAKE_HOST_WIN32) SET(CMAKE_MAKE_PROGRAM "${QNX_HOST}/usr/bin/make${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX Make Program") SET(CMAKE_SH "${QNX_HOST}/usr/bin/sh${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX shell Program") SET(CMAKE_AR "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-ar${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX ar Program") SET(CMAKE_RANLIB "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-ranlib${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX ranlib Program") SET(CMAKE_NM "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-nm${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX nm Program") SET(CMAKE_OBJCOPY "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-objcopy${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX objcopy Program") SET(CMAKE_OBJDUMP "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-objdump${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX objdump Program") SET(CMAKE_LINKER "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-ld${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX Linker Program") SET(CMAKE_STRIP "${QNX_HOST}/usr/bin/nto${CMAKE_SYSTEM_PROCESSOR}-strip${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX Strip Program") SET(CMAKE_C_COMPILER ${QNX_HOST}/usr/bin/qcc${HOST_EXECUTABLE_SUFFIX}) SET(CMAKE_C_FLAGS_DEBUG "-g") SET(CMAKE_C_FLAGS_MINSIZEREL "-Os -DNDEBUG") SET(CMAKE_C_FLAGS_RELEASE "-O3 -DNDEBUG") SET(CMAKE_C_FLAGS_RELWITHDEBINFO "-O2 -g") SET(CMAKE_CXX_COMPILER ${QNX_HOST}/usr/bin/qcc${HOST_EXECUTABLE_SUFFIX}) SET(CMAKE_CXX_FLAGS_DEBUG "-g") SET(CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG") SET(CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG") SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g") SET(CMAKE_FIND_ROOT_PATH ${QNX_TARGET}) SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) SET(CMAKE_C_FLAGS "-Vgcc_ntoarmv7le" CACHE STRING "qcc c flags" FORCE) SET(CMAKE_CXX_FLAGS "-Vgcc_ntoarmv7le -lang-c++" CACHE STRING "qcc cxx flags" FORCE) libical-3.0.1/cmake/Toolchain-RPI.cmake000066400000000000000000000043321320431302500175370ustar00rootroot00000000000000# Basic cmake toolchain file for RaspberryPi # Assumptions: toolchain is in path, $SYSROOT points to the sysroot # # Copyright (c) 2013-2016 Klarälvdalens Datakonsult AB, a KDAB Group company # All rights reserved. # # Author: Volker Krause # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # # 1. Redistributions of source code must retain the copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # 3. The name of the author may not be used to endorse or promote products # derived from this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. set(CMAKE_SYSTEM_NAME "Linux") set(CMAKE_SYSTEM_PROCESSOR "armv6l") set(CMAKE_C_COMPILER "arm-linux-gnueabihf-gcc") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --sysroot=$ENV{SYSROOT}") set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} --sysroot=$ENV{SYSROOT}") set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} --sysroot=$ENV{SYSROOT}") set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} --sysroot=$ENV{SYSROOT}") set(CMAKE_FIND_ROOT_PATH "$ENV{SYSROOT}") set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) libical-3.0.1/cmake/Toolchain-android.cmake000066400000000000000000002401521320431302500205270ustar00rootroot00000000000000# Copyright (c) 2010-2011, Ethan Rublee # Copyright (c) 2011-2014, Andrey Kamaev # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # 1. Redistributions of source code must retain the above copyright notice, # this list of conditions and the following disclaimer. # # 2. Redistributions in binary form must reproduce the above copyright notice, # this list of conditions and the following disclaimer in the documentation # and/or other materials provided with the distribution. # # 3. Neither the name of the copyright holder nor the names of its # contributors may be used to endorse or promote products derived from this # software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE # LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE # POSSIBILITY OF SUCH DAMAGE. # ------------------------------------------------------------------------------ # Android CMake toolchain file, for use with the Android NDK r5-r10d # Requires cmake 2.6.3 or newer (2.8.9 or newer is recommended). # See home page: https://github.com/taka-no-me/android-cmake # # Usage Linux: # $ export ANDROID_NDK=/absolute/path/to/the/android-ndk # $ mkdir build && cd build # $ cmake -DCMAKE_TOOLCHAIN_FILE=path/to/the/android.toolchain.cmake .. # $ make -j8 # # Usage Windows: # You need native port of make to build your project. # Android NDK r7 (and newer) already has make.exe on board. # For older NDK you have to install it separately. # For example, this one: http://gnuwin32.sourceforge.net/packages/make.htm # # $ SET ANDROID_NDK=C:\absolute\path\to\the\android-ndk # $ mkdir build && cd build # $ cmake.exe -G"MinGW Makefiles" # -DCMAKE_TOOLCHAIN_FILE=path\to\the\android.toolchain.cmake # -DCMAKE_MAKE_PROGRAM="%ANDROID_NDK%\prebuilt\windows\bin\make.exe" .. # $ cmake.exe --build . # # # Options (can be set as cmake parameters: -D=): # ANDROID_NDK=/opt/android-ndk - path to the NDK root. # Can be set as environment variable. Can be set only at first cmake run. # # ANDROID_ABI=armeabi-v7a - specifies the target Application Binary # Interface (ABI). This option nearly matches to the APP_ABI variable # used by ndk-build tool from Android NDK. # # Possible targets are: # "armeabi" - ARMv5TE based CPU with software floating point operations # "armeabi-v7a" - ARMv7 based devices with hardware FPU instructions # this ABI target is used by default # "armeabi-v7a with NEON" - same as armeabi-v7a, but # sets NEON as floating-point unit # "armeabi-v7a with VFPV3" - same as armeabi-v7a, but # sets VFPV3 as floating-point unit (has 32 registers instead of 16) # "armeabi-v6 with VFP" - tuned for ARMv6 processors having VFP # "x86" - IA-32 instruction set # "mips" - MIPS32 instruction set # # 64-bit ABIs for NDK r10 and newer: # "arm64-v8a" - ARMv8 AArch64 instruction set # "x86_64" - Intel64 instruction set (r1) # "mips64" - MIPS64 instruction set (r6) # # ANDROID_NATIVE_API_LEVEL=android-8 - level of Android API compile for. # Option is read-only when standalone toolchain is used. # Note: building for "android-L" requires explicit configuration. # # ANDROID_TOOLCHAIN_NAME=arm-linux-androideabi-4.9 - the name of compiler # toolchain to be used. The list of possible values depends on the NDK # version. For NDK r10c the possible values are: # # * aarch64-linux-android-4.9 # * aarch64-linux-android-clang3.4 # * aarch64-linux-android-clang3.5 # * arm-linux-androideabi-4.6 # * arm-linux-androideabi-4.8 # * arm-linux-androideabi-4.9 (default) # * arm-linux-androideabi-clang3.4 # * arm-linux-androideabi-clang3.5 # * mips64el-linux-android-4.9 # * mips64el-linux-android-clang3.4 # * mips64el-linux-android-clang3.5 # * mipsel-linux-android-4.6 # * mipsel-linux-android-4.8 # * mipsel-linux-android-4.9 # * mipsel-linux-android-clang3.4 # * mipsel-linux-android-clang3.5 # * x86-4.6 # * x86-4.8 # * x86-4.9 # * x86-clang3.4 # * x86-clang3.5 # * x86_64-4.9 # * x86_64-clang3.4 # * x86_64-clang3.5 # # ANDROID_FORCE_ARM_BUILD=OFF - set ON to generate 32-bit ARM instructions # instead of Thumb. Is not available for "armeabi-v6 with VFP" # (is forced to be ON) ABI. # # ANDROID_NO_UNDEFINED=ON - set ON to show all undefined symbols as linker # errors even if they are not used. # # ANDROID_SO_UNDEFINED=OFF - set ON to allow undefined symbols in shared # libraries. Automatically turned for NDK r5x and r6x due to GLESv2 # problems. # # ANDROID_STL=gnustl_static - specify the runtime to use. # # Possible values are: # none -> Do not configure the runtime. # system -> Use the default minimal system C++ runtime library. # Implies -fno-rtti -fno-exceptions. # Is not available for standalone toolchain. # system_re -> Use the default minimal system C++ runtime library. # Implies -frtti -fexceptions. # Is not available for standalone toolchain. # gabi++_static -> Use the GAbi++ runtime as a static library. # Implies -frtti -fno-exceptions. # Available for NDK r7 and newer. # Is not available for standalone toolchain. # gabi++_shared -> Use the GAbi++ runtime as a shared library. # Implies -frtti -fno-exceptions. # Available for NDK r7 and newer. # Is not available for standalone toolchain. # stlport_static -> Use the STLport runtime as a static library. # Implies -fno-rtti -fno-exceptions for NDK before r7. # Implies -frtti -fno-exceptions for NDK r7 and newer. # Is not available for standalone toolchain. # stlport_shared -> Use the STLport runtime as a shared library. # Implies -fno-rtti -fno-exceptions for NDK before r7. # Implies -frtti -fno-exceptions for NDK r7 and newer. # Is not available for standalone toolchain. # gnustl_static -> Use the GNU STL as a static library. # Implies -frtti -fexceptions. # gnustl_shared -> Use the GNU STL as a shared library. # Implies -frtti -fno-exceptions. # Available for NDK r7b and newer. # Silently degrades to gnustl_static if not available. # # ANDROID_STL_FORCE_FEATURES=ON - turn rtti and exceptions support based on # chosen runtime. If disabled, then the user is responsible for settings # these options. # # What?: # android-cmake toolchain searches for NDK/toolchain in the following order: # ANDROID_NDK - cmake parameter # ANDROID_NDK - environment variable # ANDROID_STANDALONE_TOOLCHAIN - cmake parameter # ANDROID_STANDALONE_TOOLCHAIN - environment variable # ANDROID_NDK - default locations # ANDROID_STANDALONE_TOOLCHAIN - default locations # # Make sure to do the following in your scripts: # SET( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${my_cxx_flags}" ) # SET( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${my_cxx_flags}" ) # The flags will be prepopulated with critical flags, so don't loose them. # Also be aware that toolchain also sets configuration-specific compiler # flags and linker flags. # # ANDROID and BUILD_ANDROID will be set to true, you may test any of these # variables to make necessary Android-specific configuration changes. # # Also ARMEABI or ARMEABI_V7A or X86 or MIPS or ARM64_V8A or X86_64 or MIPS64 # will be set true, mutually exclusive. NEON option will be set true # if VFP is set to NEON. # # ------------------------------------------------------------------------------ cmake_minimum_required( VERSION 2.6.3 ) if( DEFINED CMAKE_CROSSCOMPILING ) # subsequent toolchain loading is not really needed return() endif() if( CMAKE_TOOLCHAIN_FILE ) # touch toolchain variable to suppress "unused variable" warning endif() # inherit settings in recursive loads get_property( _CMAKE_IN_TRY_COMPILE GLOBAL PROPERTY IN_TRY_COMPILE ) if( _CMAKE_IN_TRY_COMPILE ) include( "${CMAKE_CURRENT_SOURCE_DIR}/../android.toolchain.config.cmake" OPTIONAL ) endif() # this one is important if( CMAKE_VERSION VERSION_GREATER "3.0.99" ) set( CMAKE_SYSTEM_NAME Android ) else() set( CMAKE_SYSTEM_NAME Linux ) endif() # this one not so much set( CMAKE_SYSTEM_VERSION 1 ) # rpath makes low sense for Android set( CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG "" ) set( CMAKE_SKIP_RPATH TRUE CACHE BOOL "If set, runtime paths are not added when using shared libraries." ) # NDK search paths set( ANDROID_SUPPORTED_NDK_VERSIONS ${ANDROID_EXTRA_NDK_VERSIONS} -r10d -r10c -r10b -r10 -r9d -r9c -r9b -r9 -r8e -r8d -r8c -r8b -r8 -r7c -r7b -r7 -r6b -r6 -r5c -r5b -r5 "" ) if( NOT DEFINED ANDROID_NDK_SEARCH_PATHS ) if( CMAKE_HOST_WIN32 ) file( TO_CMAKE_PATH "$ENV{PROGRAMFILES}" ANDROID_NDK_SEARCH_PATHS ) set( ANDROID_NDK_SEARCH_PATHS "${ANDROID_NDK_SEARCH_PATHS}" "$ENV{SystemDrive}/NVPACK" ) else() file( TO_CMAKE_PATH "$ENV{HOME}" ANDROID_NDK_SEARCH_PATHS ) set( ANDROID_NDK_SEARCH_PATHS /opt "${ANDROID_NDK_SEARCH_PATHS}/NVPACK" ) endif() endif() if( NOT DEFINED ANDROID_STANDALONE_TOOLCHAIN_SEARCH_PATH ) set( ANDROID_STANDALONE_TOOLCHAIN_SEARCH_PATH /opt/android-toolchain ) endif() # known ABIs set( ANDROID_SUPPORTED_ABIS_arm "armeabi-v7a;armeabi;armeabi-v7a with NEON;armeabi-v7a with VFPV3;armeabi-v6 with VFP" ) set( ANDROID_SUPPORTED_ABIS_arm64 "arm64-v8a" ) set( ANDROID_SUPPORTED_ABIS_x86 "x86" ) set( ANDROID_SUPPORTED_ABIS_x86_64 "x86_64" ) set( ANDROID_SUPPORTED_ABIS_mips "mips" ) set( ANDROID_SUPPORTED_ABIS_mips64 "mips64" ) # API level defaults set( ANDROID_DEFAULT_NDK_API_LEVEL 8 ) set( ANDROID_DEFAULT_NDK_API_LEVEL_arm64 21 ) set( ANDROID_DEFAULT_NDK_API_LEVEL_x86 9 ) set( ANDROID_DEFAULT_NDK_API_LEVEL_x86_64 21 ) set( ANDROID_DEFAULT_NDK_API_LEVEL_mips 9 ) set( ANDROID_DEFAULT_NDK_API_LEVEL_mips64 21 ) macro( __LIST_FILTER listvar regex ) if( ${listvar} ) foreach( __val ${${listvar}} ) if( __val MATCHES "${regex}" ) list( REMOVE_ITEM ${listvar} "${__val}" ) endif() endforeach() endif() endmacro() macro( __INIT_VARIABLE var_name ) set( __test_path 0 ) foreach( __var ${ARGN} ) if( __var STREQUAL "PATH" ) set( __test_path 1 ) break() endif() endforeach() if( __test_path AND NOT EXISTS "${${var_name}}" ) unset( ${var_name} CACHE ) endif() if( " ${${var_name}}" STREQUAL " " ) set( __values 0 ) foreach( __var ${ARGN} ) if( __var STREQUAL "VALUES" ) set( __values 1 ) elseif( NOT __var STREQUAL "PATH" ) if( __var MATCHES "^ENV_.*$" ) string( REPLACE "ENV_" "" __var "${__var}" ) set( __value "$ENV{${__var}}" ) elseif( DEFINED ${__var} ) set( __value "${${__var}}" ) elseif( __values ) set( __value "${__var}" ) else() set( __value "" ) endif() if( NOT " ${__value}" STREQUAL " " AND (NOT __test_path OR EXISTS "${__value}") ) set( ${var_name} "${__value}" ) break() endif() endif() endforeach() unset( __value ) unset( __values ) endif() if( __test_path ) file( TO_CMAKE_PATH "${${var_name}}" ${var_name} ) endif() unset( __test_path ) endmacro() macro( __DETECT_NATIVE_API_LEVEL _var _path ) set( __ndkApiLevelRegex "^[\t ]*#define[\t ]+__ANDROID_API__[\t ]+([0-9]+)[\t ]*.*$" ) file( STRINGS ${_path} __apiFileContent REGEX "${__ndkApiLevelRegex}" ) if( NOT __apiFileContent ) message( SEND_ERROR "Could not get Android native API level. Probably you have specified invalid level value, or your copy of NDK/toolchain is broken." ) endif() string( REGEX REPLACE "${__ndkApiLevelRegex}" "\\1" ${_var} "${__apiFileContent}" ) unset( __apiFileContent ) unset( __ndkApiLevelRegex ) endmacro() macro( __DETECT_TOOLCHAIN_MACHINE_NAME _var _root ) if( EXISTS "${_root}" ) file( GLOB __gccExePath RELATIVE "${_root}/bin/" "${_root}/bin/*-gcc${TOOL_OS_SUFFIX}" ) __LIST_FILTER( __gccExePath "^[.].*" ) list( LENGTH __gccExePath __gccExePathsCount ) if( NOT __gccExePathsCount EQUAL 1 AND NOT _CMAKE_IN_TRY_COMPILE ) message( WARNING "Could not determine machine name for compiler from ${_root}" ) set( ${_var} "" ) else() get_filename_component( __gccExeName "${__gccExePath}" NAME_WE ) string( REPLACE "-gcc" "" ${_var} "${__gccExeName}" ) endif() unset( __gccExePath ) unset( __gccExePathsCount ) unset( __gccExeName ) else() set( ${_var} "" ) endif() endmacro() # fight against cygwin set( ANDROID_FORBID_SYGWIN TRUE CACHE BOOL "Prevent cmake from working under cygwin and using cygwin tools") mark_as_advanced( ANDROID_FORBID_SYGWIN ) if( ANDROID_FORBID_SYGWIN ) if( CYGWIN ) message( FATAL_ERROR "Android NDK and android-cmake toolchain are not welcome Cygwin. It is unlikely that this cmake toolchain will work under cygwin. But if you want to try then you can set cmake variable ANDROID_FORBID_SYGWIN to FALSE and rerun cmake." ) endif() if( CMAKE_HOST_WIN32 ) # remove cygwin from PATH set( __new_path "$ENV{PATH}") __LIST_FILTER( __new_path "cygwin" ) set(ENV{PATH} "${__new_path}") unset(__new_path) endif() endif() # detect current host platform if( NOT DEFINED ANDROID_NDK_HOST_X64 AND (CMAKE_HOST_SYSTEM_PROCESSOR MATCHES "amd64|x86_64|AMD64" OR CMAKE_HOST_APPLE) ) set( ANDROID_NDK_HOST_X64 1 CACHE BOOL "Try to use 64-bit compiler toolchain" ) mark_as_advanced( ANDROID_NDK_HOST_X64 ) endif() set( TOOL_OS_SUFFIX "" ) if( CMAKE_HOST_APPLE ) set( ANDROID_NDK_HOST_SYSTEM_NAME "darwin-x86_64" ) set( ANDROID_NDK_HOST_SYSTEM_NAME2 "darwin-x86" ) elseif( CMAKE_HOST_WIN32 ) set( ANDROID_NDK_HOST_SYSTEM_NAME "windows-x86_64" ) set( ANDROID_NDK_HOST_SYSTEM_NAME2 "windows" ) set( TOOL_OS_SUFFIX ".exe" ) elseif( CMAKE_HOST_UNIX ) set( ANDROID_NDK_HOST_SYSTEM_NAME "linux-x86_64" ) set( ANDROID_NDK_HOST_SYSTEM_NAME2 "linux-x86" ) else() message( FATAL_ERROR "Cross-compilation on your platform is not supported by this cmake toolchain" ) endif() if( NOT ANDROID_NDK_HOST_X64 ) set( ANDROID_NDK_HOST_SYSTEM_NAME ${ANDROID_NDK_HOST_SYSTEM_NAME2} ) endif() # see if we have path to Android NDK if( NOT ANDROID_NDK AND NOT ANDROID_STANDALONE_TOOLCHAIN ) __INIT_VARIABLE( ANDROID_NDK PATH ENV_ANDROID_NDK ) endif() if( NOT ANDROID_NDK ) # see if we have path to Android standalone toolchain __INIT_VARIABLE( ANDROID_STANDALONE_TOOLCHAIN PATH ENV_ANDROID_STANDALONE_TOOLCHAIN ) if( NOT ANDROID_STANDALONE_TOOLCHAIN ) #try to find Android NDK in one of the the default locations set( __ndkSearchPaths ) foreach( __ndkSearchPath ${ANDROID_NDK_SEARCH_PATHS} ) foreach( suffix ${ANDROID_SUPPORTED_NDK_VERSIONS} ) list( APPEND __ndkSearchPaths "${__ndkSearchPath}/android-ndk${suffix}" ) endforeach() endforeach() __INIT_VARIABLE( ANDROID_NDK PATH VALUES ${__ndkSearchPaths} ) unset( __ndkSearchPaths ) if( ANDROID_NDK ) message( STATUS "Using default path for Android NDK: ${ANDROID_NDK}" ) message( STATUS " If you prefer to use a different location, please define a cmake or environment variable: ANDROID_NDK" ) else() #try to find Android standalone toolchain in one of the the default locations __INIT_VARIABLE( ANDROID_STANDALONE_TOOLCHAIN PATH ANDROID_STANDALONE_TOOLCHAIN_SEARCH_PATH ) if( ANDROID_STANDALONE_TOOLCHAIN ) message( STATUS "Using default path for standalone toolchain ${ANDROID_STANDALONE_TOOLCHAIN}" ) message( STATUS " If you prefer to use a different location, please define the variable: ANDROID_STANDALONE_TOOLCHAIN" ) endif( ANDROID_STANDALONE_TOOLCHAIN ) endif( ANDROID_NDK ) endif( NOT ANDROID_STANDALONE_TOOLCHAIN ) endif( NOT ANDROID_NDK ) # remember found paths if( ANDROID_NDK ) get_filename_component( ANDROID_NDK "${ANDROID_NDK}" ABSOLUTE ) set( ANDROID_NDK "${ANDROID_NDK}" CACHE INTERNAL "Path of the Android NDK" FORCE ) set( BUILD_WITH_ANDROID_NDK True ) if( EXISTS "${ANDROID_NDK}/RELEASE.TXT" ) file( STRINGS "${ANDROID_NDK}/RELEASE.TXT" ANDROID_NDK_RELEASE_FULL LIMIT_COUNT 1 REGEX "r[0-9]+[a-z]?" ) string( REGEX MATCH "r([0-9]+)([a-z]?)" ANDROID_NDK_RELEASE "${ANDROID_NDK_RELEASE_FULL}" ) else() set( ANDROID_NDK_RELEASE "r1x" ) set( ANDROID_NDK_RELEASE_FULL "unreleased" ) endif() string( REGEX REPLACE "r([0-9]+)([a-z]?)" "\\1*1000" ANDROID_NDK_RELEASE_NUM "${ANDROID_NDK_RELEASE}" ) string( FIND " abcdefghijklmnopqastuvwxyz" "${CMAKE_MATCH_2}" __ndkReleaseLetterNum ) math( EXPR ANDROID_NDK_RELEASE_NUM "${ANDROID_NDK_RELEASE_NUM}+${__ndkReleaseLetterNum}" ) elseif( ANDROID_STANDALONE_TOOLCHAIN ) get_filename_component( ANDROID_STANDALONE_TOOLCHAIN "${ANDROID_STANDALONE_TOOLCHAIN}" ABSOLUTE ) # try to detect change if( CMAKE_AR ) string( LENGTH "${ANDROID_STANDALONE_TOOLCHAIN}" __length ) string( SUBSTRING "${CMAKE_AR}" 0 ${__length} __androidStandaloneToolchainPreviousPath ) if( NOT __androidStandaloneToolchainPreviousPath STREQUAL ANDROID_STANDALONE_TOOLCHAIN ) message( FATAL_ERROR "It is not possible to change path to the Android standalone toolchain on subsequent run." ) endif() unset( __androidStandaloneToolchainPreviousPath ) unset( __length ) endif() set( ANDROID_STANDALONE_TOOLCHAIN "${ANDROID_STANDALONE_TOOLCHAIN}" CACHE INTERNAL "Path of the Android standalone toolchain" FORCE ) set( BUILD_WITH_STANDALONE_TOOLCHAIN True ) else() list(GET ANDROID_NDK_SEARCH_PATHS 0 ANDROID_NDK_SEARCH_PATH) message( FATAL_ERROR "Could not find neither Android NDK nor Android standalone toolchain. You should either set an environment variable: export ANDROID_NDK=~/my-android-ndk or export ANDROID_STANDALONE_TOOLCHAIN=~/my-android-toolchain or put the toolchain or NDK in the default path: sudo ln -s ~/my-android-ndk ${ANDROID_NDK_SEARCH_PATH}/android-ndk sudo ln -s ~/my-android-toolchain ${ANDROID_STANDALONE_TOOLCHAIN_SEARCH_PATH}" ) endif() # android NDK layout if( BUILD_WITH_ANDROID_NDK ) if( NOT DEFINED ANDROID_NDK_LAYOUT ) # try to automatically detect the layout if( EXISTS "${ANDROID_NDK}/RELEASE.TXT") set( ANDROID_NDK_LAYOUT "RELEASE" ) elseif( EXISTS "${ANDROID_NDK}/../../linux-x86/toolchain/" ) set( ANDROID_NDK_LAYOUT "LINARO" ) elseif( EXISTS "${ANDROID_NDK}/../../gcc/" ) set( ANDROID_NDK_LAYOUT "ANDROID" ) endif() endif() set( ANDROID_NDK_LAYOUT "${ANDROID_NDK_LAYOUT}" CACHE STRING "The inner layout of NDK" ) mark_as_advanced( ANDROID_NDK_LAYOUT ) if( ANDROID_NDK_LAYOUT STREQUAL "LINARO" ) set( ANDROID_NDK_HOST_SYSTEM_NAME ${ANDROID_NDK_HOST_SYSTEM_NAME2} ) # only 32-bit at the moment set( ANDROID_NDK_TOOLCHAINS_PATH "${ANDROID_NDK}/../../${ANDROID_NDK_HOST_SYSTEM_NAME}/toolchain" ) set( ANDROID_NDK_TOOLCHAINS_SUBPATH "" ) set( ANDROID_NDK_TOOLCHAINS_SUBPATH2 "" ) elseif( ANDROID_NDK_LAYOUT STREQUAL "ANDROID" ) set( ANDROID_NDK_HOST_SYSTEM_NAME ${ANDROID_NDK_HOST_SYSTEM_NAME2} ) # only 32-bit at the moment set( ANDROID_NDK_TOOLCHAINS_PATH "${ANDROID_NDK}/../../gcc/${ANDROID_NDK_HOST_SYSTEM_NAME}/arm" ) set( ANDROID_NDK_TOOLCHAINS_SUBPATH "" ) set( ANDROID_NDK_TOOLCHAINS_SUBPATH2 "" ) else() # ANDROID_NDK_LAYOUT STREQUAL "RELEASE" set( ANDROID_NDK_TOOLCHAINS_PATH "${ANDROID_NDK}/toolchains" ) set( ANDROID_NDK_TOOLCHAINS_SUBPATH "/prebuilt/${ANDROID_NDK_HOST_SYSTEM_NAME}" ) set( ANDROID_NDK_TOOLCHAINS_SUBPATH2 "/prebuilt/${ANDROID_NDK_HOST_SYSTEM_NAME2}" ) endif() get_filename_component( ANDROID_NDK_TOOLCHAINS_PATH "${ANDROID_NDK_TOOLCHAINS_PATH}" ABSOLUTE ) # try to detect change of NDK if( CMAKE_AR ) string( LENGTH "${ANDROID_NDK_TOOLCHAINS_PATH}" __length ) string( SUBSTRING "${CMAKE_AR}" 0 ${__length} __androidNdkPreviousPath ) if( NOT __androidNdkPreviousPath STREQUAL ANDROID_NDK_TOOLCHAINS_PATH ) message( FATAL_ERROR "It is not possible to change the path to the NDK on subsequent CMake run. You must remove all generated files from your build folder first. " ) endif() unset( __androidNdkPreviousPath ) unset( __length ) endif() endif() # get all the details about standalone toolchain if( BUILD_WITH_STANDALONE_TOOLCHAIN ) __DETECT_NATIVE_API_LEVEL( ANDROID_SUPPORTED_NATIVE_API_LEVELS "${ANDROID_STANDALONE_TOOLCHAIN}/sysroot/usr/include/android/api-level.h" ) set( ANDROID_STANDALONE_TOOLCHAIN_API_LEVEL ${ANDROID_SUPPORTED_NATIVE_API_LEVELS} ) set( __availableToolchains "standalone" ) __DETECT_TOOLCHAIN_MACHINE_NAME( __availableToolchainMachines "${ANDROID_STANDALONE_TOOLCHAIN}" ) if( NOT __availableToolchainMachines ) message( FATAL_ERROR "Could not determine machine name of your toolchain. Probably your Android standalone toolchain is broken." ) endif() if( __availableToolchainMachines MATCHES x86_64 ) set( __availableToolchainArchs "x86_64" ) elseif( __availableToolchainMachines MATCHES i686 ) set( __availableToolchainArchs "x86" ) elseif( __availableToolchainMachines MATCHES aarch64 ) set( __availableToolchainArchs "arm64" ) elseif( __availableToolchainMachines MATCHES arm ) set( __availableToolchainArchs "arm" ) elseif( __availableToolchainMachines MATCHES mips64el ) set( __availableToolchainArchs "mips64" ) elseif( __availableToolchainMachines MATCHES mipsel ) set( __availableToolchainArchs "mips" ) endif() execute_process( COMMAND "${ANDROID_STANDALONE_TOOLCHAIN}/bin/${__availableToolchainMachines}-gcc${TOOL_OS_SUFFIX}" -dumpversion OUTPUT_VARIABLE __availableToolchainCompilerVersions OUTPUT_STRIP_TRAILING_WHITESPACE ) string( REGEX MATCH "[0-9]+[.][0-9]+([.][0-9]+)?" __availableToolchainCompilerVersions "${__availableToolchainCompilerVersions}" ) if( EXISTS "${ANDROID_STANDALONE_TOOLCHAIN}/bin/clang${TOOL_OS_SUFFIX}" ) list( APPEND __availableToolchains "standalone-clang" ) list( APPEND __availableToolchainMachines ${__availableToolchainMachines} ) list( APPEND __availableToolchainArchs ${__availableToolchainArchs} ) list( APPEND __availableToolchainCompilerVersions ${__availableToolchainCompilerVersions} ) endif() endif() macro( __GLOB_NDK_TOOLCHAINS __availableToolchainsVar __availableToolchainsLst __toolchain_subpath ) foreach( __toolchain ${${__availableToolchainsLst}} ) if( "${__toolchain}" MATCHES "-clang3[.][0-9]$" AND NOT EXISTS "${ANDROID_NDK_TOOLCHAINS_PATH}/${__toolchain}${__toolchain_subpath}" ) SET( __toolchainVersionRegex "^TOOLCHAIN_VERSION[\t ]+:=[\t ]+(.*)$" ) FILE( STRINGS "${ANDROID_NDK_TOOLCHAINS_PATH}/${__toolchain}/setup.mk" __toolchainVersionStr REGEX "${__toolchainVersionRegex}" ) if( __toolchainVersionStr ) string( REGEX REPLACE "${__toolchainVersionRegex}" "\\1" __toolchainVersionStr "${__toolchainVersionStr}" ) string( REGEX REPLACE "-clang3[.][0-9]$" "-${__toolchainVersionStr}" __gcc_toolchain "${__toolchain}" ) else() string( REGEX REPLACE "-clang3[.][0-9]$" "-4.6" __gcc_toolchain "${__toolchain}" ) endif() unset( __toolchainVersionStr ) unset( __toolchainVersionRegex ) else() set( __gcc_toolchain "${__toolchain}" ) endif() __DETECT_TOOLCHAIN_MACHINE_NAME( __machine "${ANDROID_NDK_TOOLCHAINS_PATH}/${__gcc_toolchain}${__toolchain_subpath}" ) if( __machine ) string( REGEX MATCH "[0-9]+[.][0-9]+([.][0-9x]+)?$" __version "${__gcc_toolchain}" ) if( __machine MATCHES x86_64 ) set( __arch "x86_64" ) elseif( __machine MATCHES i686 ) set( __arch "x86" ) elseif( __machine MATCHES aarch64 ) set( __arch "arm64" ) elseif( __machine MATCHES arm ) set( __arch "arm" ) elseif( __machine MATCHES mips64el ) set( __arch "mips64" ) elseif( __machine MATCHES mipsel ) set( __arch "mips" ) else() set( __arch "" ) endif() #message("machine: !${__machine}!\narch: !${__arch}!\nversion: !${__version}!\ntoolchain: !${__toolchain}!\n") if (__arch) list( APPEND __availableToolchainMachines "${__machine}" ) list( APPEND __availableToolchainArchs "${__arch}" ) list( APPEND __availableToolchainCompilerVersions "${__version}" ) list( APPEND ${__availableToolchainsVar} "${__toolchain}" ) endif() endif() unset( __gcc_toolchain ) endforeach() endmacro() # get all the details about NDK if( BUILD_WITH_ANDROID_NDK ) file( GLOB ANDROID_SUPPORTED_NATIVE_API_LEVELS RELATIVE "${ANDROID_NDK}/platforms" "${ANDROID_NDK}/platforms/android-*" ) string( REPLACE "android-" "" ANDROID_SUPPORTED_NATIVE_API_LEVELS "${ANDROID_SUPPORTED_NATIVE_API_LEVELS}" ) set( __availableToolchains "" ) set( __availableToolchainMachines "" ) set( __availableToolchainArchs "" ) set( __availableToolchainCompilerVersions "" ) if( ANDROID_TOOLCHAIN_NAME AND EXISTS "${ANDROID_NDK_TOOLCHAINS_PATH}/${ANDROID_TOOLCHAIN_NAME}/" ) # do not go through all toolchains if we know the name set( __availableToolchainsLst "${ANDROID_TOOLCHAIN_NAME}" ) __GLOB_NDK_TOOLCHAINS( __availableToolchains __availableToolchainsLst "${ANDROID_NDK_TOOLCHAINS_SUBPATH}" ) if( NOT __availableToolchains AND NOT ANDROID_NDK_TOOLCHAINS_SUBPATH STREQUAL ANDROID_NDK_TOOLCHAINS_SUBPATH2 ) __GLOB_NDK_TOOLCHAINS( __availableToolchains __availableToolchainsLst "${ANDROID_NDK_TOOLCHAINS_SUBPATH2}" ) if( __availableToolchains ) set( ANDROID_NDK_TOOLCHAINS_SUBPATH ${ANDROID_NDK_TOOLCHAINS_SUBPATH2} ) endif() endif() endif() if( NOT __availableToolchains ) file( GLOB __availableToolchainsLst RELATIVE "${ANDROID_NDK_TOOLCHAINS_PATH}" "${ANDROID_NDK_TOOLCHAINS_PATH}/*" ) if( __availableToolchains ) list(SORT __availableToolchainsLst) # we need clang to go after gcc endif() __LIST_FILTER( __availableToolchainsLst "^[.]" ) __LIST_FILTER( __availableToolchainsLst "llvm" ) __LIST_FILTER( __availableToolchainsLst "renderscript" ) __GLOB_NDK_TOOLCHAINS( __availableToolchains __availableToolchainsLst "${ANDROID_NDK_TOOLCHAINS_SUBPATH}" ) if( NOT __availableToolchains AND NOT ANDROID_NDK_TOOLCHAINS_SUBPATH STREQUAL ANDROID_NDK_TOOLCHAINS_SUBPATH2 ) __GLOB_NDK_TOOLCHAINS( __availableToolchains __availableToolchainsLst "${ANDROID_NDK_TOOLCHAINS_SUBPATH2}" ) if( __availableToolchains ) set( ANDROID_NDK_TOOLCHAINS_SUBPATH ${ANDROID_NDK_TOOLCHAINS_SUBPATH2} ) endif() endif() endif() if( NOT __availableToolchains ) message( FATAL_ERROR "Could not find any working toolchain in the NDK. Probably your Android NDK is broken." ) endif() endif() # build list of available ABIs set( ANDROID_SUPPORTED_ABIS "" ) set( __uniqToolchainArchNames ${__availableToolchainArchs} ) list( REMOVE_DUPLICATES __uniqToolchainArchNames ) list( SORT __uniqToolchainArchNames ) foreach( __arch ${__uniqToolchainArchNames} ) list( APPEND ANDROID_SUPPORTED_ABIS ${ANDROID_SUPPORTED_ABIS_${__arch}} ) endforeach() unset( __uniqToolchainArchNames ) if( NOT ANDROID_SUPPORTED_ABIS ) message( FATAL_ERROR "No one of known Android ABIs is supported by this cmake toolchain." ) endif() # choose target ABI __INIT_VARIABLE( ANDROID_ABI VALUES ${ANDROID_SUPPORTED_ABIS} ) # verify that target ABI is supported list( FIND ANDROID_SUPPORTED_ABIS "${ANDROID_ABI}" __androidAbiIdx ) if( __androidAbiIdx EQUAL -1 ) string( REPLACE ";" "\", \"" PRINTABLE_ANDROID_SUPPORTED_ABIS "${ANDROID_SUPPORTED_ABIS}" ) message( FATAL_ERROR "Specified ANDROID_ABI = \"${ANDROID_ABI}\" is not supported by this cmake toolchain or your NDK/toolchain. Supported values are: \"${PRINTABLE_ANDROID_SUPPORTED_ABIS}\" " ) endif() unset( __androidAbiIdx ) # set target ABI options if( ANDROID_ABI STREQUAL "x86" ) set( X86 true ) set( ANDROID_NDK_ABI_NAME "x86" ) set( ANDROID_ARCH_NAME "x86" ) set( ANDROID_LLVM_TRIPLE "i686-none-linux-android" ) set( CMAKE_SYSTEM_PROCESSOR "i686" ) elseif( ANDROID_ABI STREQUAL "x86_64" ) set( X86 true ) set( X86_64 true ) set( ANDROID_NDK_ABI_NAME "x86_64" ) set( ANDROID_ARCH_NAME "x86_64" ) set( CMAKE_SYSTEM_PROCESSOR "x86_64" ) set( ANDROID_LLVM_TRIPLE "x86_64-none-linux-android" ) elseif( ANDROID_ABI STREQUAL "mips64" ) set( MIPS64 true ) set( ANDROID_NDK_ABI_NAME "mips64" ) set( ANDROID_ARCH_NAME "mips64" ) set( ANDROID_LLVM_TRIPLE "mips64el-none-linux-android" ) set( CMAKE_SYSTEM_PROCESSOR "mips64" ) elseif( ANDROID_ABI STREQUAL "mips" ) set( MIPS true ) set( ANDROID_NDK_ABI_NAME "mips" ) set( ANDROID_ARCH_NAME "mips" ) set( ANDROID_LLVM_TRIPLE "mipsel-none-linux-android" ) set( CMAKE_SYSTEM_PROCESSOR "mips" ) elseif( ANDROID_ABI STREQUAL "arm64-v8a" ) set( ARM64_V8A true ) set( ANDROID_NDK_ABI_NAME "arm64-v8a" ) set( ANDROID_ARCH_NAME "arm64" ) set( ANDROID_LLVM_TRIPLE "aarch64-none-linux-android" ) set( CMAKE_SYSTEM_PROCESSOR "aarch64" ) set( VFPV3 true ) set( NEON true ) elseif( ANDROID_ABI STREQUAL "armeabi" ) set( ARMEABI true ) set( ANDROID_NDK_ABI_NAME "armeabi" ) set( ANDROID_ARCH_NAME "arm" ) set( ANDROID_LLVM_TRIPLE "armv5te-none-linux-androideabi" ) set( CMAKE_SYSTEM_PROCESSOR "armv5te" ) elseif( ANDROID_ABI STREQUAL "armeabi-v6 with VFP" ) set( ARMEABI_V6 true ) set( ANDROID_NDK_ABI_NAME "armeabi" ) set( ANDROID_ARCH_NAME "arm" ) set( ANDROID_LLVM_TRIPLE "armv5te-none-linux-androideabi" ) set( CMAKE_SYSTEM_PROCESSOR "armv6" ) # need always fallback to older platform set( ARMEABI true ) elseif( ANDROID_ABI STREQUAL "armeabi-v7a") set( ARMEABI_V7A true ) set( ANDROID_NDK_ABI_NAME "armeabi-v7a" ) set( ANDROID_ARCH_NAME "arm" ) set( ANDROID_LLVM_TRIPLE "armv7-none-linux-androideabi" ) set( CMAKE_SYSTEM_PROCESSOR "armv7-a" ) elseif( ANDROID_ABI STREQUAL "armeabi-v7a with VFPV3" ) set( ARMEABI_V7A true ) set( ANDROID_NDK_ABI_NAME "armeabi-v7a" ) set( ANDROID_ARCH_NAME "arm" ) set( ANDROID_LLVM_TRIPLE "armv7-none-linux-androideabi" ) set( CMAKE_SYSTEM_PROCESSOR "armv7-a" ) set( VFPV3 true ) elseif( ANDROID_ABI STREQUAL "armeabi-v7a with NEON" ) set( ARMEABI_V7A true ) set( ANDROID_NDK_ABI_NAME "armeabi-v7a" ) set( ANDROID_ARCH_NAME "arm" ) set( ANDROID_LLVM_TRIPLE "armv7-none-linux-androideabi" ) set( CMAKE_SYSTEM_PROCESSOR "armv7-a" ) set( VFPV3 true ) set( NEON true ) else() message( SEND_ERROR "Unknown ANDROID_ABI=\"${ANDROID_ABI}\" is specified." ) endif() if( CMAKE_BINARY_DIR AND EXISTS "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeSystem.cmake" ) # really dirty hack # it is not possible to change CMAKE_SYSTEM_PROCESSOR after the first run... file( APPEND "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeSystem.cmake" "SET(CMAKE_SYSTEM_PROCESSOR \"${CMAKE_SYSTEM_PROCESSOR}\")\n" ) endif() if( ANDROID_ARCH_NAME STREQUAL "arm" AND NOT ARMEABI_V6 ) __INIT_VARIABLE( ANDROID_FORCE_ARM_BUILD VALUES OFF ) set( ANDROID_FORCE_ARM_BUILD ${ANDROID_FORCE_ARM_BUILD} CACHE BOOL "Use 32-bit ARM instructions instead of Thumb-1" FORCE ) mark_as_advanced( ANDROID_FORCE_ARM_BUILD ) else() unset( ANDROID_FORCE_ARM_BUILD CACHE ) endif() # choose toolchain if( ANDROID_TOOLCHAIN_NAME ) list( FIND __availableToolchains "${ANDROID_TOOLCHAIN_NAME}" __toolchainIdx ) if( __toolchainIdx EQUAL -1 ) list( SORT __availableToolchains ) string( REPLACE ";" "\n * " toolchains_list "${__availableToolchains}" ) set( toolchains_list " * ${toolchains_list}") message( FATAL_ERROR "Specified toolchain \"${ANDROID_TOOLCHAIN_NAME}\" is missing in your NDK or broken. Please verify that your NDK is working or select another compiler toolchain. To configure the toolchain set CMake variable ANDROID_TOOLCHAIN_NAME to one of the following values:\n${toolchains_list}\n" ) endif() list( GET __availableToolchainArchs ${__toolchainIdx} __toolchainArch ) if( NOT __toolchainArch STREQUAL ANDROID_ARCH_NAME ) message( SEND_ERROR "Selected toolchain \"${ANDROID_TOOLCHAIN_NAME}\" is not able to compile binaries for the \"${ANDROID_ARCH_NAME}\" platform." ) endif() else() set( __toolchainIdx -1 ) set( __applicableToolchains "" ) set( __toolchainMaxVersion "0.0.0" ) list( LENGTH __availableToolchains __availableToolchainsCount ) math( EXPR __availableToolchainsCount "${__availableToolchainsCount}-1" ) foreach( __idx RANGE ${__availableToolchainsCount} ) list( GET __availableToolchainArchs ${__idx} __toolchainArch ) if( __toolchainArch STREQUAL ANDROID_ARCH_NAME ) list( GET __availableToolchainCompilerVersions ${__idx} __toolchainVersion ) string( REPLACE "x" "99" __toolchainVersion "${__toolchainVersion}") if( __toolchainVersion VERSION_GREATER __toolchainMaxVersion ) set( __toolchainMaxVersion "${__toolchainVersion}" ) set( __toolchainIdx ${__idx} ) endif() endif() endforeach() unset( __availableToolchainsCount ) unset( __toolchainMaxVersion ) unset( __toolchainVersion ) endif() unset( __toolchainArch ) if( __toolchainIdx EQUAL -1 ) message( FATAL_ERROR "No one of available compiler toolchains is able to compile for ${ANDROID_ARCH_NAME} platform." ) endif() list( GET __availableToolchains ${__toolchainIdx} ANDROID_TOOLCHAIN_NAME ) list( GET __availableToolchainMachines ${__toolchainIdx} ANDROID_TOOLCHAIN_MACHINE_NAME ) list( GET __availableToolchainCompilerVersions ${__toolchainIdx} ANDROID_COMPILER_VERSION ) unset( __toolchainIdx ) unset( __availableToolchains ) unset( __availableToolchainMachines ) unset( __availableToolchainArchs ) unset( __availableToolchainCompilerVersions ) # choose native API level __INIT_VARIABLE( ANDROID_NATIVE_API_LEVEL ENV_ANDROID_NATIVE_API_LEVEL ANDROID_API_LEVEL ENV_ANDROID_API_LEVEL ANDROID_STANDALONE_TOOLCHAIN_API_LEVEL ANDROID_DEFAULT_NDK_API_LEVEL_${ANDROID_ARCH_NAME} ANDROID_DEFAULT_NDK_API_LEVEL ) string( REPLACE "android-" "" ANDROID_NATIVE_API_LEVEL "${ANDROID_NATIVE_API_LEVEL}" ) string( STRIP "${ANDROID_NATIVE_API_LEVEL}" ANDROID_NATIVE_API_LEVEL ) # adjust API level set( __real_api_level ${ANDROID_DEFAULT_NDK_API_LEVEL_${ANDROID_ARCH_NAME}} ) foreach( __level ${ANDROID_SUPPORTED_NATIVE_API_LEVELS} ) if( (__level LESS ANDROID_NATIVE_API_LEVEL OR __level STREQUAL ANDROID_NATIVE_API_LEVEL) AND NOT __level LESS __real_api_level ) set( __real_api_level ${__level} ) endif() endforeach() if( __real_api_level AND NOT ANDROID_NATIVE_API_LEVEL STREQUAL __real_api_level ) message( STATUS "Adjusting Android API level 'android-${ANDROID_NATIVE_API_LEVEL}' to 'android-${__real_api_level}'") set( ANDROID_NATIVE_API_LEVEL ${__real_api_level} ) endif() unset(__real_api_level) # validate list( FIND ANDROID_SUPPORTED_NATIVE_API_LEVELS "${ANDROID_NATIVE_API_LEVEL}" __levelIdx ) if( __levelIdx EQUAL -1 ) message( SEND_ERROR "Specified Android native API level 'android-${ANDROID_NATIVE_API_LEVEL}' is not supported by your NDK/toolchain." ) else() if( BUILD_WITH_ANDROID_NDK ) __DETECT_NATIVE_API_LEVEL( __realApiLevel "${ANDROID_NDK}/platforms/android-${ANDROID_NATIVE_API_LEVEL}/arch-${ANDROID_ARCH_NAME}/usr/include/android/api-level.h" ) if( NOT __realApiLevel EQUAL ANDROID_NATIVE_API_LEVEL AND NOT __realApiLevel GREATER 9000 ) message( SEND_ERROR "Specified Android API level (${ANDROID_NATIVE_API_LEVEL}) does not match to the level found (${__realApiLevel}). Probably your copy of NDK is broken." ) endif() unset( __realApiLevel ) endif() set( ANDROID_NATIVE_API_LEVEL "${ANDROID_NATIVE_API_LEVEL}" CACHE STRING "Android API level for native code" FORCE ) set( CMAKE_ANDROID_API ${ANDROID_NATIVE_API_LEVEL} ) if( CMAKE_VERSION VERSION_GREATER "2.8" ) list( SORT ANDROID_SUPPORTED_NATIVE_API_LEVELS ) set_property( CACHE ANDROID_NATIVE_API_LEVEL PROPERTY STRINGS ${ANDROID_SUPPORTED_NATIVE_API_LEVELS} ) endif() endif() unset( __levelIdx ) # remember target ABI set( ANDROID_ABI "${ANDROID_ABI}" CACHE STRING "The target ABI for Android. If arm, then armeabi-v7a is recommended for hardware floating point." FORCE ) if( CMAKE_VERSION VERSION_GREATER "2.8" ) list( SORT ANDROID_SUPPORTED_ABIS_${ANDROID_ARCH_NAME} ) set_property( CACHE ANDROID_ABI PROPERTY STRINGS ${ANDROID_SUPPORTED_ABIS_${ANDROID_ARCH_NAME}} ) endif() # runtime choice (STL, rtti, exceptions) if( NOT ANDROID_STL ) set( ANDROID_STL gnustl_static ) endif() set( ANDROID_STL "${ANDROID_STL}" CACHE STRING "C++ runtime" ) set( ANDROID_STL_FORCE_FEATURES ON CACHE BOOL "automatically configure rtti and exceptions support based on C++ runtime" ) mark_as_advanced( ANDROID_STL ANDROID_STL_FORCE_FEATURES ) if( BUILD_WITH_ANDROID_NDK ) if( NOT "${ANDROID_STL}" MATCHES "^(none|system|system_re|gabi\\+\\+_static|gabi\\+\\+_shared|stlport_static|stlport_shared|gnustl_static|gnustl_shared)$") message( FATAL_ERROR "ANDROID_STL is set to invalid value \"${ANDROID_STL}\". The possible values are: none -> Do not configure the runtime. system -> Use the default minimal system C++ runtime library. system_re -> Same as system but with rtti and exceptions. gabi++_static -> Use the GAbi++ runtime as a static library. gabi++_shared -> Use the GAbi++ runtime as a shared library. stlport_static -> Use the STLport runtime as a static library. stlport_shared -> Use the STLport runtime as a shared library. gnustl_static -> (default) Use the GNU STL as a static library. gnustl_shared -> Use the GNU STL as a shared library. " ) endif() elseif( BUILD_WITH_STANDALONE_TOOLCHAIN ) if( NOT "${ANDROID_STL}" MATCHES "^(none|gnustl_static|gnustl_shared)$") message( FATAL_ERROR "ANDROID_STL is set to invalid value \"${ANDROID_STL}\". The possible values are: none -> Do not configure the runtime. gnustl_static -> (default) Use the GNU STL as a static library. gnustl_shared -> Use the GNU STL as a shared library. " ) endif() endif() unset( ANDROID_RTTI ) unset( ANDROID_EXCEPTIONS ) unset( ANDROID_STL_INCLUDE_DIRS ) unset( __libstl ) unset( __libsupcxx ) if( NOT _CMAKE_IN_TRY_COMPILE AND ANDROID_NDK_RELEASE STREQUAL "r7b" AND ARMEABI_V7A AND NOT VFPV3 AND ANDROID_STL MATCHES "gnustl" ) message( WARNING "The GNU STL armeabi-v7a binaries from NDK r7b can crash non-NEON devices. The files provided with NDK r7b were not configured properly, resulting in crashes on Tegra2-based devices and others when trying to use certain floating-point functions (e.g., cosf, sinf, expf). You are strongly recommended to switch to another NDK release. " ) endif() if( NOT _CMAKE_IN_TRY_COMPILE AND X86 AND ANDROID_STL MATCHES "gnustl" AND ANDROID_NDK_RELEASE STREQUAL "r6" ) message( WARNING "The x86 system header file from NDK r6 has incorrect definition for ptrdiff_t. You are recommended to upgrade to a newer NDK release or manually patch the header: See https://android.googlesource.com/platform/development.git f907f4f9d4e56ccc8093df6fee54454b8bcab6c2 diff --git a/ndk/platforms/android-9/arch-x86/include/machine/_types.h b/ndk/platforms/android-9/arch-x86/include/machine/_types.h index 5e28c64..65892a1 100644 --- a/ndk/platforms/android-9/arch-x86/include/machine/_types.h +++ b/ndk/platforms/android-9/arch-x86/include/machine/_types.h @@ -51,7 +51,11 @@ typedef long int ssize_t; #endif #ifndef _PTRDIFF_T #define _PTRDIFF_T -typedef long ptrdiff_t; +# ifdef __ANDROID__ + typedef int ptrdiff_t; +# else + typedef long ptrdiff_t; +# endif #endif " ) endif() # setup paths and STL for standalone toolchain if( BUILD_WITH_STANDALONE_TOOLCHAIN ) set( ANDROID_TOOLCHAIN_ROOT "${ANDROID_STANDALONE_TOOLCHAIN}" ) set( ANDROID_CLANG_TOOLCHAIN_ROOT "${ANDROID_STANDALONE_TOOLCHAIN}" ) set( ANDROID_SYSROOT "${ANDROID_STANDALONE_TOOLCHAIN}/sysroot" ) if( NOT ANDROID_STL STREQUAL "none" ) set( ANDROID_STL_INCLUDE_DIRS "${ANDROID_STANDALONE_TOOLCHAIN}/include/c++/${ANDROID_COMPILER_VERSION}" ) if( NOT EXISTS "${ANDROID_STL_INCLUDE_DIRS}" ) # old location ( pre r8c ) set( ANDROID_STL_INCLUDE_DIRS "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/include/c++/${ANDROID_COMPILER_VERSION}" ) endif() if( ARMEABI_V7A AND EXISTS "${ANDROID_STL_INCLUDE_DIRS}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/${CMAKE_SYSTEM_PROCESSOR}/bits" ) list( APPEND ANDROID_STL_INCLUDE_DIRS "${ANDROID_STL_INCLUDE_DIRS}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/${CMAKE_SYSTEM_PROCESSOR}" ) elseif( ARMEABI AND NOT ANDROID_FORCE_ARM_BUILD AND EXISTS "${ANDROID_STL_INCLUDE_DIRS}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/thumb/bits" ) list( APPEND ANDROID_STL_INCLUDE_DIRS "${ANDROID_STL_INCLUDE_DIRS}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/thumb" ) else() list( APPEND ANDROID_STL_INCLUDE_DIRS "${ANDROID_STL_INCLUDE_DIRS}/${ANDROID_TOOLCHAIN_MACHINE_NAME}" ) endif() # always search static GNU STL to get the location of libsupc++.a if( ARMEABI_V7A AND NOT ANDROID_FORCE_ARM_BUILD AND EXISTS "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/${CMAKE_SYSTEM_PROCESSOR}/thumb/libstdc++.a" ) set( __libstl "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/${CMAKE_SYSTEM_PROCESSOR}/thumb" ) elseif( ARMEABI_V7A AND EXISTS "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/${CMAKE_SYSTEM_PROCESSOR}/libstdc++.a" ) set( __libstl "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/${CMAKE_SYSTEM_PROCESSOR}" ) elseif( ARMEABI AND NOT ANDROID_FORCE_ARM_BUILD AND EXISTS "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/thumb/libstdc++.a" ) set( __libstl "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/thumb" ) elseif( EXISTS "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/libstdc++.a" ) set( __libstl "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib" ) endif() if( __libstl ) set( __libsupcxx "${__libstl}/libsupc++.a" ) set( __libstl "${__libstl}/libstdc++.a" ) endif() if( NOT EXISTS "${__libsupcxx}" ) message( FATAL_ERROR "The required libstdsupc++.a is missing in your standalone toolchain. Usually it happens because of bug in make-standalone-toolchain.sh script from NDK r7, r7b and r7c. You need to either upgrade to newer NDK or manually copy $ANDROID_NDK/sources/cxx-stl/gnu-libstdc++/libs/${ANDROID_NDK_ABI_NAME}/libsupc++.a to ${__libsupcxx} " ) endif() if( ANDROID_STL STREQUAL "gnustl_shared" ) if( ARMEABI_V7A AND EXISTS "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/${CMAKE_SYSTEM_PROCESSOR}/libgnustl_shared.so" ) set( __libstl "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/${CMAKE_SYSTEM_PROCESSOR}/libgnustl_shared.so" ) elseif( ARMEABI AND NOT ANDROID_FORCE_ARM_BUILD AND EXISTS "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/thumb/libgnustl_shared.so" ) set( __libstl "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/thumb/libgnustl_shared.so" ) elseif( EXISTS "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/libgnustl_shared.so" ) set( __libstl "${ANDROID_STANDALONE_TOOLCHAIN}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/libgnustl_shared.so" ) endif() endif() endif() endif() # clang if( "${ANDROID_TOOLCHAIN_NAME}" STREQUAL "standalone-clang" ) set( ANDROID_COMPILER_IS_CLANG 1 ) execute_process( COMMAND "${ANDROID_CLANG_TOOLCHAIN_ROOT}/bin/clang${TOOL_OS_SUFFIX}" --version OUTPUT_VARIABLE ANDROID_CLANG_VERSION OUTPUT_STRIP_TRAILING_WHITESPACE ) string( REGEX MATCH "[0-9]+[.][0-9]+" ANDROID_CLANG_VERSION "${ANDROID_CLANG_VERSION}") elseif( "${ANDROID_TOOLCHAIN_NAME}" MATCHES "-clang3[.][0-9]?$" ) string( REGEX MATCH "3[.][0-9]$" ANDROID_CLANG_VERSION "${ANDROID_TOOLCHAIN_NAME}") string( REGEX REPLACE "-clang${ANDROID_CLANG_VERSION}$" "-${ANDROID_COMPILER_VERSION}" ANDROID_GCC_TOOLCHAIN_NAME "${ANDROID_TOOLCHAIN_NAME}" ) if( NOT EXISTS "${ANDROID_NDK_TOOLCHAINS_PATH}/llvm-${ANDROID_CLANG_VERSION}${ANDROID_NDK_TOOLCHAINS_SUBPATH}/bin/clang${TOOL_OS_SUFFIX}" ) message( FATAL_ERROR "Could not find the Clang compiler driver" ) endif() set( ANDROID_COMPILER_IS_CLANG 1 ) set( ANDROID_CLANG_TOOLCHAIN_ROOT "${ANDROID_NDK_TOOLCHAINS_PATH}/llvm-${ANDROID_CLANG_VERSION}${ANDROID_NDK_TOOLCHAINS_SUBPATH}" ) else() set( ANDROID_GCC_TOOLCHAIN_NAME "${ANDROID_TOOLCHAIN_NAME}" ) unset( ANDROID_COMPILER_IS_CLANG CACHE ) endif() string( REPLACE "." "" _clang_name "clang${ANDROID_CLANG_VERSION}" ) if( NOT EXISTS "${ANDROID_CLANG_TOOLCHAIN_ROOT}/bin/${_clang_name}${TOOL_OS_SUFFIX}" ) set( _clang_name "clang" ) endif() # setup paths and STL for NDK if( BUILD_WITH_ANDROID_NDK ) set( ANDROID_TOOLCHAIN_ROOT "${ANDROID_NDK_TOOLCHAINS_PATH}/${ANDROID_GCC_TOOLCHAIN_NAME}${ANDROID_NDK_TOOLCHAINS_SUBPATH}" ) set( ANDROID_SYSROOT "${ANDROID_NDK}/platforms/android-${ANDROID_NATIVE_API_LEVEL}/arch-${ANDROID_ARCH_NAME}" ) if( ANDROID_STL STREQUAL "none" ) # do nothing elseif( ANDROID_STL STREQUAL "system" ) set( ANDROID_RTTI OFF ) set( ANDROID_EXCEPTIONS OFF ) set( ANDROID_STL_INCLUDE_DIRS "${ANDROID_NDK}/sources/cxx-stl/system/include" ) elseif( ANDROID_STL STREQUAL "system_re" ) set( ANDROID_RTTI ON ) set( ANDROID_EXCEPTIONS ON ) set( ANDROID_STL_INCLUDE_DIRS "${ANDROID_NDK}/sources/cxx-stl/system/include" ) elseif( ANDROID_STL MATCHES "gabi" ) if( ANDROID_NDK_RELEASE_NUM LESS 7000 ) # before r7 message( FATAL_ERROR "gabi++ is not awailable in your NDK. You have to upgrade to NDK r7 or newer to use gabi++.") endif() set( ANDROID_RTTI ON ) set( ANDROID_EXCEPTIONS OFF ) set( ANDROID_STL_INCLUDE_DIRS "${ANDROID_NDK}/sources/cxx-stl/gabi++/include" ) set( __libstl "${ANDROID_NDK}/sources/cxx-stl/gabi++/libs/${ANDROID_NDK_ABI_NAME}/libgabi++_static.a" ) elseif( ANDROID_STL MATCHES "stlport" ) if( NOT ANDROID_NDK_RELEASE_NUM LESS 8004 ) # before r8d set( ANDROID_EXCEPTIONS ON ) else() set( ANDROID_EXCEPTIONS OFF ) endif() if( ANDROID_NDK_RELEASE_NUM LESS 7000 ) # before r7 set( ANDROID_RTTI OFF ) else() set( ANDROID_RTTI ON ) endif() set( ANDROID_STL_INCLUDE_DIRS "${ANDROID_NDK}/sources/cxx-stl/stlport/stlport" ) set( __libstl "${ANDROID_NDK}/sources/cxx-stl/stlport/libs/${ANDROID_NDK_ABI_NAME}/libstlport_static.a" ) elseif( ANDROID_STL MATCHES "gnustl" ) set( ANDROID_EXCEPTIONS ON ) set( ANDROID_RTTI ON ) if( EXISTS "${ANDROID_NDK}/sources/cxx-stl/gnu-libstdc++/${ANDROID_COMPILER_VERSION}" ) if( ARMEABI_V7A AND ANDROID_COMPILER_VERSION VERSION_EQUAL "4.7" AND ANDROID_NDK_RELEASE STREQUAL "r8d" ) # gnustl binary for 4.7 compiler is buggy :( # TODO: look for right fix set( __libstl "${ANDROID_NDK}/sources/cxx-stl/gnu-libstdc++/4.6" ) else() set( __libstl "${ANDROID_NDK}/sources/cxx-stl/gnu-libstdc++/${ANDROID_COMPILER_VERSION}" ) endif() else() set( __libstl "${ANDROID_NDK}/sources/cxx-stl/gnu-libstdc++" ) endif() set( ANDROID_STL_INCLUDE_DIRS "${__libstl}/include" "${__libstl}/libs/${ANDROID_NDK_ABI_NAME}/include" "${__libstl}/include/backward" ) if( EXISTS "${__libstl}/libs/${ANDROID_NDK_ABI_NAME}/libgnustl_static.a" ) set( __libstl "${__libstl}/libs/${ANDROID_NDK_ABI_NAME}/libgnustl_static.a" ) else() set( __libstl "${__libstl}/libs/${ANDROID_NDK_ABI_NAME}/libstdc++.a" ) endif() else() message( FATAL_ERROR "Unknown runtime: ${ANDROID_STL}" ) endif() # find libsupc++.a - rtti & exceptions if( ANDROID_STL STREQUAL "system_re" OR ANDROID_STL MATCHES "gnustl" ) set( __libsupcxx "${ANDROID_NDK}/sources/cxx-stl/gnu-libstdc++/${ANDROID_COMPILER_VERSION}/libs/${ANDROID_NDK_ABI_NAME}/libsupc++.a" ) # r8b or newer if( NOT EXISTS "${__libsupcxx}" ) set( __libsupcxx "${ANDROID_NDK}/sources/cxx-stl/gnu-libstdc++/libs/${ANDROID_NDK_ABI_NAME}/libsupc++.a" ) # r7-r8 endif() if( NOT EXISTS "${__libsupcxx}" ) # before r7 if( ARMEABI_V7A ) if( ANDROID_FORCE_ARM_BUILD ) set( __libsupcxx "${ANDROID_TOOLCHAIN_ROOT}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/${CMAKE_SYSTEM_PROCESSOR}/libsupc++.a" ) else() set( __libsupcxx "${ANDROID_TOOLCHAIN_ROOT}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/${CMAKE_SYSTEM_PROCESSOR}/thumb/libsupc++.a" ) endif() elseif( ARMEABI AND NOT ANDROID_FORCE_ARM_BUILD ) set( __libsupcxx "${ANDROID_TOOLCHAIN_ROOT}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/thumb/libsupc++.a" ) else() set( __libsupcxx "${ANDROID_TOOLCHAIN_ROOT}/${ANDROID_TOOLCHAIN_MACHINE_NAME}/lib/libsupc++.a" ) endif() endif() if( NOT EXISTS "${__libsupcxx}") message( ERROR "Could not find libsupc++.a for a chosen platform. Either your NDK is not supported or is broken.") endif() endif() endif() # case of shared STL linkage if( ANDROID_STL MATCHES "shared" AND DEFINED __libstl ) string( REPLACE "_static.a" "_shared.so" __libstl "${__libstl}" ) # TODO: check if .so file exists before the renaming endif() # ccache support __INIT_VARIABLE( _ndk_ccache NDK_CCACHE ENV_NDK_CCACHE ) if( _ndk_ccache ) if( DEFINED NDK_CCACHE AND NOT EXISTS NDK_CCACHE ) unset( NDK_CCACHE CACHE ) endif() find_program( NDK_CCACHE "${_ndk_ccache}" DOC "The path to ccache binary") else() unset( NDK_CCACHE CACHE ) endif() unset( _ndk_ccache ) # setup the cross-compiler if( NOT CMAKE_C_COMPILER ) if( NDK_CCACHE AND NOT ANDROID_SYSROOT MATCHES "[ ;\"]" ) set( CMAKE_C_COMPILER "${NDK_CCACHE}" CACHE PATH "ccache as C compiler" ) set( CMAKE_CXX_COMPILER "${NDK_CCACHE}" CACHE PATH "ccache as C++ compiler" ) if( ANDROID_COMPILER_IS_CLANG ) set( CMAKE_C_COMPILER_ARG1 "${ANDROID_CLANG_TOOLCHAIN_ROOT}/bin/${_clang_name}${TOOL_OS_SUFFIX}" CACHE PATH "C compiler") set( CMAKE_CXX_COMPILER_ARG1 "${ANDROID_CLANG_TOOLCHAIN_ROOT}/bin/${_clang_name}++${TOOL_OS_SUFFIX}" CACHE PATH "C++ compiler") else() set( CMAKE_C_COMPILER_ARG1 "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-gcc${TOOL_OS_SUFFIX}" CACHE PATH "C compiler") set( CMAKE_CXX_COMPILER_ARG1 "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-g++${TOOL_OS_SUFFIX}" CACHE PATH "C++ compiler") endif() else() if( ANDROID_COMPILER_IS_CLANG ) set( CMAKE_C_COMPILER "${ANDROID_CLANG_TOOLCHAIN_ROOT}/bin/${_clang_name}${TOOL_OS_SUFFIX}" CACHE PATH "C compiler") set( CMAKE_CXX_COMPILER "${ANDROID_CLANG_TOOLCHAIN_ROOT}/bin/${_clang_name}++${TOOL_OS_SUFFIX}" CACHE PATH "C++ compiler") else() set( CMAKE_C_COMPILER "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-gcc${TOOL_OS_SUFFIX}" CACHE PATH "C compiler" ) set( CMAKE_CXX_COMPILER "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-g++${TOOL_OS_SUFFIX}" CACHE PATH "C++ compiler" ) endif() endif() set( CMAKE_ASM_COMPILER "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-gcc${TOOL_OS_SUFFIX}" CACHE PATH "assembler" ) set( CMAKE_STRIP "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-strip${TOOL_OS_SUFFIX}" CACHE PATH "strip" ) set( CMAKE_AR "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-ar${TOOL_OS_SUFFIX}" CACHE PATH "archive" ) set( CMAKE_LINKER "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-ld${TOOL_OS_SUFFIX}" CACHE PATH "linker" ) set( CMAKE_NM "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-nm${TOOL_OS_SUFFIX}" CACHE PATH "nm" ) set( CMAKE_OBJCOPY "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-objcopy${TOOL_OS_SUFFIX}" CACHE PATH "objcopy" ) set( CMAKE_OBJDUMP "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-objdump${TOOL_OS_SUFFIX}" CACHE PATH "objdump" ) set( CMAKE_RANLIB "${ANDROID_TOOLCHAIN_ROOT}/bin/${ANDROID_TOOLCHAIN_MACHINE_NAME}-ranlib${TOOL_OS_SUFFIX}" CACHE PATH "ranlib" ) endif() set( _CMAKE_TOOLCHAIN_PREFIX "${ANDROID_TOOLCHAIN_MACHINE_NAME}-" ) if( CMAKE_VERSION VERSION_LESS 2.8.5 ) set( CMAKE_ASM_COMPILER_ARG1 "-c" ) endif() if( APPLE ) find_program( CMAKE_INSTALL_NAME_TOOL NAMES install_name_tool ) if( NOT CMAKE_INSTALL_NAME_TOOL ) message( FATAL_ERROR "Could not find install_name_tool, please check your installation." ) endif() mark_as_advanced( CMAKE_INSTALL_NAME_TOOL ) endif() # Force set compilers because standard identification works badly for us include( CMakeForceCompiler ) CMAKE_FORCE_C_COMPILER( "${CMAKE_C_COMPILER}" GNU ) if( ANDROID_COMPILER_IS_CLANG ) set( CMAKE_C_COMPILER_ID Clang ) endif() set( CMAKE_C_PLATFORM_ID Linux ) if( X86_64 OR MIPS64 OR ARM64_V8A ) set( CMAKE_C_SIZEOF_DATA_PTR 8 ) else() set( CMAKE_C_SIZEOF_DATA_PTR 4 ) endif() set( CMAKE_C_HAS_ISYSROOT 1 ) set( CMAKE_C_COMPILER_ABI ELF ) CMAKE_FORCE_CXX_COMPILER( "${CMAKE_CXX_COMPILER}" GNU ) if( ANDROID_COMPILER_IS_CLANG ) set( CMAKE_CXX_COMPILER_ID Clang) endif() set( CMAKE_CXX_PLATFORM_ID Linux ) set( CMAKE_CXX_SIZEOF_DATA_PTR ${CMAKE_C_SIZEOF_DATA_PTR} ) set( CMAKE_CXX_HAS_ISYSROOT 1 ) set( CMAKE_CXX_COMPILER_ABI ELF ) set( CMAKE_CXX_SOURCE_FILE_EXTENSIONS cc cp cxx cpp CPP c++ C ) # force ASM compiler (required for CMake < 2.8.5) set( CMAKE_ASM_COMPILER_ID_RUN TRUE ) set( CMAKE_ASM_COMPILER_ID GNU ) set( CMAKE_ASM_COMPILER_WORKS TRUE ) set( CMAKE_ASM_COMPILER_FORCED TRUE ) set( CMAKE_COMPILER_IS_GNUASM 1) set( CMAKE_ASM_SOURCE_FILE_EXTENSIONS s S asm ) foreach( lang C CXX ASM ) if( ANDROID_COMPILER_IS_CLANG ) set( CMAKE_${lang}_COMPILER_VERSION ${ANDROID_CLANG_VERSION} ) else() set( CMAKE_${lang}_COMPILER_VERSION ${ANDROID_COMPILER_VERSION} ) endif() endforeach() # flags and definitions remove_definitions( -DANDROID ) add_definitions( -DANDROID ) if( ANDROID_SYSROOT MATCHES "[ ;\"]" ) if( CMAKE_HOST_WIN32 ) # try to convert path to 8.3 form file( WRITE "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/cvt83.cmd" "@echo %~s1" ) execute_process( COMMAND "$ENV{ComSpec}" /c "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/cvt83.cmd" "${ANDROID_SYSROOT}" OUTPUT_VARIABLE __path OUTPUT_STRIP_TRAILING_WHITESPACE RESULT_VARIABLE __result ERROR_QUIET ) if( __result EQUAL 0 ) file( TO_CMAKE_PATH "${__path}" ANDROID_SYSROOT ) set( ANDROID_CXX_FLAGS "--sysroot=${ANDROID_SYSROOT}" ) else() set( ANDROID_CXX_FLAGS "--sysroot=\"${ANDROID_SYSROOT}\"" ) endif() else() set( ANDROID_CXX_FLAGS "'--sysroot=${ANDROID_SYSROOT}'" ) endif() if( NOT _CMAKE_IN_TRY_COMPILE ) # quotes can break try_compile and compiler identification message(WARNING "Path to your Android NDK (or toolchain) has non-alphanumeric symbols.\nThe build might be broken.\n") endif() else() set( ANDROID_CXX_FLAGS "--sysroot=${ANDROID_SYSROOT}" ) endif() # NDK flags if (ARM64_V8A ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -funwind-tables" ) set( ANDROID_CXX_FLAGS_RELEASE "-fomit-frame-pointer -fstrict-aliasing" ) set( ANDROID_CXX_FLAGS_DEBUG "-fno-omit-frame-pointer -fno-strict-aliasing" ) if( NOT ANDROID_COMPILER_IS_CLANG ) set( ANDROID_CXX_FLAGS_RELEASE "${ANDROID_CXX_FLAGS_RELEASE} -funswitch-loops -finline-limit=300" ) endif() elseif( ARMEABI OR ARMEABI_V7A) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -funwind-tables" ) if( NOT ANDROID_FORCE_ARM_BUILD AND NOT ARMEABI_V6 ) set( ANDROID_CXX_FLAGS_RELEASE "-mthumb -fomit-frame-pointer -fno-strict-aliasing" ) set( ANDROID_CXX_FLAGS_DEBUG "-marm -fno-omit-frame-pointer -fno-strict-aliasing" ) if( NOT ANDROID_COMPILER_IS_CLANG ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -finline-limit=64" ) endif() else() # always compile ARMEABI_V6 in arm mode; otherwise there is no difference from ARMEABI set( ANDROID_CXX_FLAGS_RELEASE "-marm -fomit-frame-pointer -fstrict-aliasing" ) set( ANDROID_CXX_FLAGS_DEBUG "-marm -fno-omit-frame-pointer -fno-strict-aliasing" ) if( NOT ANDROID_COMPILER_IS_CLANG ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -funswitch-loops -finline-limit=300" ) endif() endif() elseif( X86 OR X86_64 ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -funwind-tables" ) if( NOT ANDROID_COMPILER_IS_CLANG ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -funswitch-loops -finline-limit=300" ) endif() set( ANDROID_CXX_FLAGS_RELEASE "-fomit-frame-pointer -fstrict-aliasing" ) set( ANDROID_CXX_FLAGS_DEBUG "-fno-omit-frame-pointer -fno-strict-aliasing" ) elseif( MIPS OR MIPS64 ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -fno-strict-aliasing -finline-functions -funwind-tables -fmessage-length=0" ) set( ANDROID_CXX_FLAGS_RELEASE "-fomit-frame-pointer" ) set( ANDROID_CXX_FLAGS_DEBUG "-fno-omit-frame-pointer" ) if( NOT ANDROID_COMPILER_IS_CLANG ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -fno-inline-functions-called-once -fgcse-after-reload -frerun-cse-after-loop -frename-registers" ) set( ANDROID_CXX_FLAGS_RELEASE "${ANDROID_CXX_FLAGS_RELEASE} -funswitch-loops -finline-limit=300" ) endif() elseif() set( ANDROID_CXX_FLAGS_RELEASE "" ) set( ANDROID_CXX_FLAGS_DEBUG "" ) endif() set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -fsigned-char" ) # good/necessary when porting desktop libraries if( NOT X86 AND NOT ANDROID_COMPILER_IS_CLANG ) set( ANDROID_CXX_FLAGS "-Wno-psabi ${ANDROID_CXX_FLAGS}" ) endif() if( NOT ANDROID_COMPILER_VERSION VERSION_LESS "4.6" ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -no-canonical-prefixes" ) # see https://android-review.googlesource.com/#/c/47564/ endif() # ABI-specific flags if( ARMEABI_V7A ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -march=armv7-a -mfloat-abi=softfp" ) if( NEON ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -mfpu=neon" ) elseif( VFPV3 ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -mfpu=vfpv3" ) else() set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -mfpu=vfpv3-d16" ) endif() elseif( ARMEABI_V6 ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -march=armv6 -mfloat-abi=softfp -mfpu=vfp" ) # vfp == vfpv2 elseif( ARMEABI ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -march=armv5te -mtune=xscale -msoft-float" ) endif() if( ANDROID_STL MATCHES "gnustl" AND (EXISTS "${__libstl}" OR EXISTS "${__libsupcxx}") ) set( CMAKE_CXX_CREATE_SHARED_LIBRARY " -o " ) set( CMAKE_CXX_CREATE_SHARED_MODULE " -o " ) set( CMAKE_CXX_LINK_EXECUTABLE " -o " ) else() set( CMAKE_CXX_CREATE_SHARED_LIBRARY " -o " ) set( CMAKE_CXX_CREATE_SHARED_MODULE " -o " ) set( CMAKE_CXX_LINK_EXECUTABLE " -o " ) endif() # STL if( EXISTS "${__libstl}" OR EXISTS "${__libsupcxx}" ) if( EXISTS "${__libstl}" ) set( CMAKE_CXX_CREATE_SHARED_LIBRARY "${CMAKE_CXX_CREATE_SHARED_LIBRARY} \"${__libstl}\"" ) set( CMAKE_CXX_CREATE_SHARED_MODULE "${CMAKE_CXX_CREATE_SHARED_MODULE} \"${__libstl}\"" ) set( CMAKE_CXX_LINK_EXECUTABLE "${CMAKE_CXX_LINK_EXECUTABLE} \"${__libstl}\"" ) endif() if( EXISTS "${__libsupcxx}" ) set( CMAKE_CXX_CREATE_SHARED_LIBRARY "${CMAKE_CXX_CREATE_SHARED_LIBRARY} \"${__libsupcxx}\"" ) set( CMAKE_CXX_CREATE_SHARED_MODULE "${CMAKE_CXX_CREATE_SHARED_MODULE} \"${__libsupcxx}\"" ) set( CMAKE_CXX_LINK_EXECUTABLE "${CMAKE_CXX_LINK_EXECUTABLE} \"${__libsupcxx}\"" ) # C objects: set( CMAKE_C_CREATE_SHARED_LIBRARY " -o " ) set( CMAKE_C_CREATE_SHARED_MODULE " -o " ) set( CMAKE_C_LINK_EXECUTABLE " -o " ) set( CMAKE_C_CREATE_SHARED_LIBRARY "${CMAKE_C_CREATE_SHARED_LIBRARY} \"${__libsupcxx}\"" ) set( CMAKE_C_CREATE_SHARED_MODULE "${CMAKE_C_CREATE_SHARED_MODULE} \"${__libsupcxx}\"" ) set( CMAKE_C_LINK_EXECUTABLE "${CMAKE_C_LINK_EXECUTABLE} \"${__libsupcxx}\"" ) endif() if( ANDROID_STL MATCHES "gnustl" ) if( NOT EXISTS "${ANDROID_LIBM_PATH}" ) set( ANDROID_LIBM_PATH -lm ) endif() set( CMAKE_CXX_CREATE_SHARED_LIBRARY "${CMAKE_CXX_CREATE_SHARED_LIBRARY} ${ANDROID_LIBM_PATH}" ) set( CMAKE_CXX_CREATE_SHARED_MODULE "${CMAKE_CXX_CREATE_SHARED_MODULE} ${ANDROID_LIBM_PATH}" ) set( CMAKE_CXX_LINK_EXECUTABLE "${CMAKE_CXX_LINK_EXECUTABLE} ${ANDROID_LIBM_PATH}" ) endif() endif() # variables controlling optional build flags if( ANDROID_NDK_RELEASE_NUM LESS 7000 ) # before r7 # libGLESv2.so in NDK's prior to r7 refers to missing external symbols. # So this flag option is required for all projects using OpenGL from native. __INIT_VARIABLE( ANDROID_SO_UNDEFINED VALUES ON ) else() __INIT_VARIABLE( ANDROID_SO_UNDEFINED VALUES OFF ) endif() __INIT_VARIABLE( ANDROID_NO_UNDEFINED VALUES ON ) __INIT_VARIABLE( ANDROID_FUNCTION_LEVEL_LINKING VALUES ON ) __INIT_VARIABLE( ANDROID_GOLD_LINKER VALUES ON ) __INIT_VARIABLE( ANDROID_NOEXECSTACK VALUES ON ) __INIT_VARIABLE( ANDROID_RELRO VALUES ON ) set( ANDROID_NO_UNDEFINED ${ANDROID_NO_UNDEFINED} CACHE BOOL "Show all undefined symbols as linker errors" ) set( ANDROID_SO_UNDEFINED ${ANDROID_SO_UNDEFINED} CACHE BOOL "Allows or disallows undefined symbols in shared libraries" ) set( ANDROID_FUNCTION_LEVEL_LINKING ${ANDROID_FUNCTION_LEVEL_LINKING} CACHE BOOL "Put each function in separate section and enable garbage collection of unused input sections at link time" ) set( ANDROID_GOLD_LINKER ${ANDROID_GOLD_LINKER} CACHE BOOL "Enables gold linker" ) set( ANDROID_NOEXECSTACK ${ANDROID_NOEXECSTACK} CACHE BOOL "Allows or disallows undefined symbols in shared libraries" ) set( ANDROID_RELRO ${ANDROID_RELRO} CACHE BOOL "Enables RELRO - a memory corruption mitigation technique" ) mark_as_advanced( ANDROID_NO_UNDEFINED ANDROID_SO_UNDEFINED ANDROID_FUNCTION_LEVEL_LINKING ANDROID_GOLD_LINKER ANDROID_NOEXECSTACK ANDROID_RELRO ) # linker flags set( ANDROID_LINKER_FLAGS "" ) if( ARMEABI_V7A ) # this is *required* to use the following linker flags that routes around # a CPU bug in some Cortex-A8 implementations: set( ANDROID_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} -Wl,--fix-cortex-a8" ) endif() if( ANDROID_NO_UNDEFINED ) if( MIPS ) # there is some sysroot-related problem in mips linker... if( NOT ANDROID_SYSROOT MATCHES "[ ;\"]" ) set( ANDROID_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} -Wl,--no-undefined -Wl,-rpath-link,${ANDROID_SYSROOT}/usr/lib" ) endif() else() set( ANDROID_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} -Wl,--no-undefined" ) endif() endif() if( ANDROID_SO_UNDEFINED ) set( ANDROID_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} -Wl,-allow-shlib-undefined" ) endif() if( ANDROID_FUNCTION_LEVEL_LINKING ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -fdata-sections -ffunction-sections" ) set( ANDROID_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} -Wl,--gc-sections" ) endif() if( ANDROID_COMPILER_VERSION VERSION_EQUAL "4.6" ) if( ANDROID_GOLD_LINKER AND (CMAKE_HOST_UNIX OR ANDROID_NDK_RELEASE_NUM GREATER 8002) AND (ARMEABI OR ARMEABI_V7A OR X86) ) set( ANDROID_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} -fuse-ld=gold" ) elseif( ANDROID_NDK_RELEASE_NUM GREATER 8002 ) # after r8b set( ANDROID_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} -fuse-ld=bfd" ) elseif( ANDROID_NDK_RELEASE STREQUAL "r8b" AND ARMEABI AND NOT _CMAKE_IN_TRY_COMPILE ) message( WARNING "The default bfd linker from arm GCC 4.6 toolchain can fail with 'unresolvable R_ARM_THM_CALL relocation' error message. See https://code.google.com/p/android/issues/detail?id=35342 On Linux and OS X host platform you can workaround this problem using gold linker (default). Rerun cmake with -DANDROID_GOLD_LINKER=ON option in case of problems. " ) endif() endif() # version 4.6 if( ANDROID_NOEXECSTACK ) if( ANDROID_COMPILER_IS_CLANG ) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -Xclang -mnoexecstack" ) else() set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS} -Wa,--noexecstack" ) endif() set( ANDROID_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} -Wl,-z,noexecstack" ) endif() if( ANDROID_RELRO ) set( ANDROID_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} -Wl,-z,relro -Wl,-z,now" ) endif() if( ANDROID_COMPILER_IS_CLANG ) set( ANDROID_CXX_FLAGS "-target ${ANDROID_LLVM_TRIPLE} -Qunused-arguments ${ANDROID_CXX_FLAGS}" ) if( BUILD_WITH_ANDROID_NDK ) set( ANDROID_CXX_FLAGS "-gcc-toolchain ${ANDROID_TOOLCHAIN_ROOT} ${ANDROID_CXX_FLAGS}" ) endif() endif() # cache flags set( CMAKE_CXX_FLAGS "" CACHE STRING "c++ flags" ) set( CMAKE_C_FLAGS "" CACHE STRING "c flags" ) set( CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG" CACHE STRING "c++ Release flags" ) set( CMAKE_C_FLAGS_RELEASE "-O3 -DNDEBUG" CACHE STRING "c Release flags" ) set( CMAKE_CXX_FLAGS_DEBUG "-O0 -g -DDEBUG -D_DEBUG" CACHE STRING "c++ Debug flags" ) set( CMAKE_C_FLAGS_DEBUG "-O0 -g -DDEBUG -D_DEBUG" CACHE STRING "c Debug flags" ) set( CMAKE_SHARED_LINKER_FLAGS "" CACHE STRING "shared linker flags" ) set( CMAKE_MODULE_LINKER_FLAGS "" CACHE STRING "module linker flags" ) set( CMAKE_EXE_LINKER_FLAGS "-Wl,-z,nocopyreloc" CACHE STRING "executable linker flags" ) # put flags to cache (for debug purpose only) set( ANDROID_CXX_FLAGS "${ANDROID_CXX_FLAGS}" CACHE INTERNAL "Android specific c/c++ flags" ) set( ANDROID_CXX_FLAGS_RELEASE "${ANDROID_CXX_FLAGS_RELEASE}" CACHE INTERNAL "Android specific c/c++ Release flags" ) set( ANDROID_CXX_FLAGS_DEBUG "${ANDROID_CXX_FLAGS_DEBUG}" CACHE INTERNAL "Android specific c/c++ Debug flags" ) set( ANDROID_LINKER_FLAGS "${ANDROID_LINKER_FLAGS}" CACHE INTERNAL "Android specific c/c++ linker flags" ) # finish flags set( CMAKE_CXX_FLAGS "${ANDROID_CXX_FLAGS} ${CMAKE_CXX_FLAGS}" ) set( CMAKE_C_FLAGS "${ANDROID_CXX_FLAGS} ${CMAKE_C_FLAGS}" ) set( CMAKE_CXX_FLAGS_RELEASE "${ANDROID_CXX_FLAGS_RELEASE} ${CMAKE_CXX_FLAGS_RELEASE}" ) set( CMAKE_C_FLAGS_RELEASE "${ANDROID_CXX_FLAGS_RELEASE} ${CMAKE_C_FLAGS_RELEASE}" ) set( CMAKE_CXX_FLAGS_DEBUG "${ANDROID_CXX_FLAGS_DEBUG} ${CMAKE_CXX_FLAGS_DEBUG}" ) set( CMAKE_C_FLAGS_DEBUG "${ANDROID_CXX_FLAGS_DEBUG} ${CMAKE_C_FLAGS_DEBUG}" ) set( CMAKE_SHARED_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} ${CMAKE_SHARED_LINKER_FLAGS}" ) set( CMAKE_MODULE_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} ${CMAKE_MODULE_LINKER_FLAGS}" ) set( CMAKE_EXE_LINKER_FLAGS "${ANDROID_LINKER_FLAGS} ${CMAKE_EXE_LINKER_FLAGS}" ) if( MIPS AND BUILD_WITH_ANDROID_NDK AND ANDROID_NDK_RELEASE STREQUAL "r8" ) set( CMAKE_SHARED_LINKER_FLAGS "-Wl,-T,${ANDROID_NDK_TOOLCHAINS_PATH}/${ANDROID_GCC_TOOLCHAIN_NAME}/mipself.xsc ${CMAKE_SHARED_LINKER_FLAGS}" ) set( CMAKE_MODULE_LINKER_FLAGS "-Wl,-T,${ANDROID_NDK_TOOLCHAINS_PATH}/${ANDROID_GCC_TOOLCHAIN_NAME}/mipself.xsc ${CMAKE_MODULE_LINKER_FLAGS}" ) set( CMAKE_EXE_LINKER_FLAGS "-Wl,-T,${ANDROID_NDK_TOOLCHAINS_PATH}/${ANDROID_GCC_TOOLCHAIN_NAME}/mipself.x ${CMAKE_EXE_LINKER_FLAGS}" ) endif() # pie/pic if( NOT (ANDROID_NATIVE_API_LEVEL LESS 16) AND (NOT DEFINED ANDROID_APP_PIE OR ANDROID_APP_PIE) AND (CMAKE_VERSION VERSION_GREATER 2.8.8) ) set( CMAKE_POSITION_INDEPENDENT_CODE TRUE ) set( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fPIE -pie") else() set( CMAKE_POSITION_INDEPENDENT_CODE FALSE ) set( CMAKE_CXX_FLAGS "-fpic ${CMAKE_CXX_FLAGS}" ) set( CMAKE_C_FLAGS "-fpic ${CMAKE_C_FLAGS}" ) endif() # configure rtti if( DEFINED ANDROID_RTTI AND ANDROID_STL_FORCE_FEATURES ) if( ANDROID_RTTI ) set( CMAKE_CXX_FLAGS "-frtti ${CMAKE_CXX_FLAGS}" ) else() set( CMAKE_CXX_FLAGS "-fno-rtti ${CMAKE_CXX_FLAGS}" ) endif() endif() # configure exceptios if( DEFINED ANDROID_EXCEPTIONS AND ANDROID_STL_FORCE_FEATURES ) if( ANDROID_EXCEPTIONS ) set( CMAKE_CXX_FLAGS "-fexceptions ${CMAKE_CXX_FLAGS}" ) set( CMAKE_C_FLAGS "-fexceptions ${CMAKE_C_FLAGS}" ) else() set( CMAKE_CXX_FLAGS "-fno-exceptions ${CMAKE_CXX_FLAGS}" ) set( CMAKE_C_FLAGS "-fno-exceptions ${CMAKE_C_FLAGS}" ) endif() endif() # global includes and link directories include_directories( SYSTEM "${ANDROID_SYSROOT}/usr/include" ${ANDROID_STL_INCLUDE_DIRS} ) get_filename_component(__android_install_path "${CMAKE_INSTALL_PREFIX}/libs/${ANDROID_NDK_ABI_NAME}" ABSOLUTE) # avoid CMP0015 policy warning link_directories( "${__android_install_path}" ) # detect if need link crtbegin_so.o explicitly if( NOT DEFINED ANDROID_EXPLICIT_CRT_LINK ) set( __cmd "${CMAKE_CXX_CREATE_SHARED_LIBRARY}" ) string( REPLACE "" "${CMAKE_CXX_COMPILER} ${CMAKE_CXX_COMPILER_ARG1}" __cmd "${__cmd}" ) string( REPLACE "" "${CMAKE_C_COMPILER} ${CMAKE_C_COMPILER_ARG1}" __cmd "${__cmd}" ) string( REPLACE "" "${CMAKE_CXX_FLAGS}" __cmd "${__cmd}" ) string( REPLACE "" "" __cmd "${__cmd}" ) string( REPLACE "" "${CMAKE_SHARED_LINKER_FLAGS}" __cmd "${__cmd}" ) string( REPLACE "" "-shared" __cmd "${__cmd}" ) string( REPLACE "" "" __cmd "${__cmd}" ) string( REPLACE "" "" __cmd "${__cmd}" ) string( REPLACE "" "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/toolchain_crtlink_test.so" __cmd "${__cmd}" ) string( REPLACE "" "\"${ANDROID_SYSROOT}/usr/lib/crtbegin_so.o\"" __cmd "${__cmd}" ) string( REPLACE "" "" __cmd "${__cmd}" ) separate_arguments( __cmd ) foreach( __var ANDROID_NDK ANDROID_NDK_TOOLCHAINS_PATH ANDROID_STANDALONE_TOOLCHAIN ) if( ${__var} ) set( __tmp "${${__var}}" ) separate_arguments( __tmp ) string( REPLACE "${__tmp}" "${${__var}}" __cmd "${__cmd}") endif() endforeach() string( REPLACE "'" "" __cmd "${__cmd}" ) string( REPLACE "\"" "" __cmd "${__cmd}" ) execute_process( COMMAND ${__cmd} RESULT_VARIABLE __cmd_result OUTPUT_QUIET ERROR_QUIET ) if( __cmd_result EQUAL 0 ) set( ANDROID_EXPLICIT_CRT_LINK ON ) else() set( ANDROID_EXPLICIT_CRT_LINK OFF ) endif() endif() if( ANDROID_EXPLICIT_CRT_LINK ) set( CMAKE_CXX_CREATE_SHARED_LIBRARY "${CMAKE_CXX_CREATE_SHARED_LIBRARY} \"${ANDROID_SYSROOT}/usr/lib/crtbegin_so.o\"" ) set( CMAKE_CXX_CREATE_SHARED_MODULE "${CMAKE_CXX_CREATE_SHARED_MODULE} \"${ANDROID_SYSROOT}/usr/lib/crtbegin_so.o\"" ) endif() # setup output directories set( CMAKE_INSTALL_PREFIX "${ANDROID_TOOLCHAIN_ROOT}/user" CACHE STRING "path for installing" ) if( DEFINED LIBRARY_OUTPUT_PATH_ROOT OR EXISTS "${CMAKE_SOURCE_DIR}/AndroidManifest.xml" OR (EXISTS "${CMAKE_SOURCE_DIR}/../AndroidManifest.xml" AND EXISTS "${CMAKE_SOURCE_DIR}/../jni/") ) set( LIBRARY_OUTPUT_PATH_ROOT ${CMAKE_SOURCE_DIR} CACHE PATH "Root for binaries output, set this to change where Android libs are installed to" ) if( NOT _CMAKE_IN_TRY_COMPILE ) if( EXISTS "${CMAKE_SOURCE_DIR}/jni/CMakeLists.txt" ) set( EXECUTABLE_OUTPUT_PATH "${LIBRARY_OUTPUT_PATH_ROOT}/bin/${ANDROID_NDK_ABI_NAME}" CACHE PATH "Output directory for applications" ) else() set( EXECUTABLE_OUTPUT_PATH "${LIBRARY_OUTPUT_PATH_ROOT}/bin" CACHE PATH "Output directory for applications" ) endif() set( LIBRARY_OUTPUT_PATH "${LIBRARY_OUTPUT_PATH_ROOT}/libs/${ANDROID_NDK_ABI_NAME}" CACHE PATH "Output directory for Android libs" ) endif() endif() # copy shaed stl library to build directory if( NOT _CMAKE_IN_TRY_COMPILE AND __libstl MATCHES "[.]so$" AND DEFINED LIBRARY_OUTPUT_PATH ) get_filename_component( __libstlname "${__libstl}" NAME ) execute_process( COMMAND "${CMAKE_COMMAND}" -E copy_if_different "${__libstl}" "${LIBRARY_OUTPUT_PATH}/${__libstlname}" RESULT_VARIABLE __fileCopyProcess ) if( NOT __fileCopyProcess EQUAL 0 OR NOT EXISTS "${LIBRARY_OUTPUT_PATH}/${__libstlname}") message( SEND_ERROR "Failed copying of ${__libstl} to the ${LIBRARY_OUTPUT_PATH}/${__libstlname}" ) endif() unset( __fileCopyProcess ) unset( __libstlname ) endif() # set these global flags for cmake client scripts to change behavior set( ANDROID True ) set( BUILD_ANDROID True ) # where is the target environment set( CMAKE_FIND_ROOT_PATH "${ANDROID_TOOLCHAIN_ROOT}/bin" "${ANDROID_TOOLCHAIN_ROOT}/${ANDROID_TOOLCHAIN_MACHINE_NAME}" "${ANDROID_SYSROOT}" "${CMAKE_INSTALL_PREFIX}" "${CMAKE_INSTALL_PREFIX}/share" ) # only search for libraries and includes in the ndk toolchain set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM ONLY ) set( CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY ) set( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY ) # macro to find packages on the host OS macro( find_host_package ) set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER ) set( CMAKE_FIND_ROOT_PATH_MODE_LIBRARY NEVER ) set( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE NEVER ) if( CMAKE_HOST_WIN32 ) SET( WIN32 1 ) SET( UNIX ) elseif( CMAKE_HOST_APPLE ) SET( APPLE 1 ) SET( UNIX ) endif() find_package( ${ARGN} ) SET( WIN32 ) SET( APPLE ) SET( UNIX 1 ) set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM ONLY ) set( CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY ) set( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY ) endmacro() # macro to find programs on the host OS macro( find_host_program ) set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER ) set( CMAKE_FIND_ROOT_PATH_MODE_LIBRARY NEVER ) set( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE NEVER ) if( CMAKE_HOST_WIN32 ) SET( WIN32 1 ) SET( UNIX ) elseif( CMAKE_HOST_APPLE ) SET( APPLE 1 ) SET( UNIX ) endif() find_program( ${ARGN} ) SET( WIN32 ) SET( APPLE ) SET( UNIX 1 ) set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM ONLY ) set( CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY ) set( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY ) endmacro() # export toolchain settings for the try_compile() command if( NOT _CMAKE_IN_TRY_COMPILE ) set( __toolchain_config "") foreach( __var NDK_CCACHE LIBRARY_OUTPUT_PATH_ROOT ANDROID_FORBID_SYGWIN ANDROID_NDK_HOST_X64 ANDROID_NDK ANDROID_NDK_LAYOUT ANDROID_STANDALONE_TOOLCHAIN ANDROID_TOOLCHAIN_NAME ANDROID_ABI ANDROID_NATIVE_API_LEVEL ANDROID_STL ANDROID_STL_FORCE_FEATURES ANDROID_FORCE_ARM_BUILD ANDROID_NO_UNDEFINED ANDROID_SO_UNDEFINED ANDROID_FUNCTION_LEVEL_LINKING ANDROID_GOLD_LINKER ANDROID_NOEXECSTACK ANDROID_RELRO ANDROID_LIBM_PATH ANDROID_EXPLICIT_CRT_LINK ANDROID_APP_PIE ) if( DEFINED ${__var} ) if( ${__var} MATCHES " ") set( __toolchain_config "${__toolchain_config}set( ${__var} \"${${__var}}\" CACHE INTERNAL \"\" )\n" ) else() set( __toolchain_config "${__toolchain_config}set( ${__var} ${${__var}} CACHE INTERNAL \"\" )\n" ) endif() endif() endforeach() file( WRITE "${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/android.toolchain.config.cmake" "${__toolchain_config}" ) unset( __toolchain_config ) endif() # force cmake to produce / instead of \ in build commands for Ninja generator if( CMAKE_GENERATOR MATCHES "Ninja" AND CMAKE_HOST_WIN32 ) # it is a bad hack after all # CMake generates Ninja makefiles with UNIX paths only if it thinks that we are going to build with MinGW set( CMAKE_COMPILER_IS_MINGW TRUE ) # tell CMake that we are MinGW set( CMAKE_CROSSCOMPILING TRUE ) # stop recursion enable_language( C ) enable_language( CXX ) # unset( CMAKE_COMPILER_IS_MINGW ) # can't unset because CMake does not convert back-slashes in response files without it unset( MINGW ) endif() # Variables controlling behavior or set by cmake toolchain: # ANDROID_ABI : "armeabi-v7a" (default), "armeabi", "armeabi-v7a with NEON", "armeabi-v7a with VFPV3", "armeabi-v6 with VFP", "x86", "mips", "arm64-v8a", "x86_64", "mips64" # ANDROID_NATIVE_API_LEVEL : 3,4,5,8,9,14,15,16,17,18,19,21 (depends on NDK version) # ANDROID_STL : gnustl_static/gnustl_shared/stlport_static/stlport_shared/gabi++_static/gabi++_shared/system_re/system/none # ANDROID_FORBID_SYGWIN : ON/OFF # ANDROID_NO_UNDEFINED : ON/OFF # ANDROID_SO_UNDEFINED : OFF/ON (default depends on NDK version) # ANDROID_FUNCTION_LEVEL_LINKING : ON/OFF # ANDROID_GOLD_LINKER : ON/OFF # ANDROID_NOEXECSTACK : ON/OFF # ANDROID_RELRO : ON/OFF # ANDROID_FORCE_ARM_BUILD : ON/OFF # ANDROID_STL_FORCE_FEATURES : ON/OFF # ANDROID_LIBM_PATH : path to libm.so (set to something like $(TOP)/out/target/product//obj/lib/libm.so) to workaround unresolved `sincos` # Can be set only at the first run: # ANDROID_NDK : path to your NDK install # NDK_CCACHE : path to your ccache executable # ANDROID_TOOLCHAIN_NAME : the NDK name of compiler toolchain # ANDROID_NDK_HOST_X64 : try to use x86_64 toolchain (default for x64 host systems) # ANDROID_NDK_LAYOUT : the inner NDK structure (RELEASE, LINARO, ANDROID) # LIBRARY_OUTPUT_PATH_ROOT : # ANDROID_STANDALONE_TOOLCHAIN # # Primary read-only variables: # ANDROID : always TRUE # ARMEABI : TRUE for arm v6 and older devices # ARMEABI_V6 : TRUE for arm v6 # ARMEABI_V7A : TRUE for arm v7a # ARM64_V8A : TRUE for arm64-v8a # NEON : TRUE if NEON unit is enabled # VFPV3 : TRUE if VFP version 3 is enabled # X86 : TRUE if configured for x86 # X86_64 : TRUE if configured for x86_64 # MIPS : TRUE if configured for mips # MIPS64 : TRUE if configured for mips64 # BUILD_WITH_ANDROID_NDK : TRUE if NDK is used # BUILD_WITH_STANDALONE_TOOLCHAIN : TRUE if standalone toolchain is used # ANDROID_NDK_HOST_SYSTEM_NAME : "windows", "linux-x86" or "darwin-x86" depending on host platform # ANDROID_NDK_ABI_NAME : "armeabi", "armeabi-v7a", "x86", "mips", "arm64-v8a", "x86_64", "mips64" depending on ANDROID_ABI # ANDROID_NDK_RELEASE : from r5 to r10d; set only for NDK # ANDROID_NDK_RELEASE_NUM : numeric ANDROID_NDK_RELEASE version (1000*major+minor) # ANDROID_ARCH_NAME : "arm", "x86", "mips", "arm64", "x86_64", "mips64" depending on ANDROID_ABI # ANDROID_SYSROOT : path to the compiler sysroot # TOOL_OS_SUFFIX : "" or ".exe" depending on host platform # ANDROID_COMPILER_IS_CLANG : TRUE if clang compiler is used # # Secondary (less stable) read-only variables: # ANDROID_COMPILER_VERSION : GCC version used (not Clang version) # ANDROID_CLANG_VERSION : version of clang compiler if clang is used # ANDROID_CXX_FLAGS : C/C++ compiler flags required by Android platform # ANDROID_SUPPORTED_ABIS : list of currently allowed values for ANDROID_ABI # ANDROID_TOOLCHAIN_MACHINE_NAME : "arm-linux-androideabi", "arm-eabi" or "i686-android-linux" # ANDROID_TOOLCHAIN_ROOT : path to the top level of toolchain (standalone or placed inside NDK) # ANDROID_CLANG_TOOLCHAIN_ROOT : path to clang tools # ANDROID_SUPPORTED_NATIVE_API_LEVELS : list of native API levels found inside NDK # ANDROID_STL_INCLUDE_DIRS : stl include paths # ANDROID_RTTI : if rtti is enabled by the runtime # ANDROID_EXCEPTIONS : if exceptions are enabled by the runtime # ANDROID_GCC_TOOLCHAIN_NAME : read-only, differs from ANDROID_TOOLCHAIN_NAME only if clang is used # # Defaults: # ANDROID_DEFAULT_NDK_API_LEVEL # ANDROID_DEFAULT_NDK_API_LEVEL_${ARCH} # ANDROID_NDK_SEARCH_PATHS # ANDROID_SUPPORTED_ABIS_${ARCH} # ANDROID_SUPPORTED_NDK_VERSIONS libical-3.0.1/cmake/Toolchain-blackberry-armv7le.cmake000066400000000000000000000047351320431302500226070ustar00rootroot00000000000000# Basic cmake toolchain file for BlackBerry 10 # Copyright (c) 2013-2016 Klarälvdalens Datakonsult AB, a KDAB Group company # All rights reserved. # # Author: Rafael Roquetto # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # # 1. Redistributions of source code must retain the copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # 3. The name of the author may not be used to endorse or promote products # derived from this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # the name of the target operating system set(CMAKE_SYSTEM_NAME QNX) set(CMAKE_SYSTEM_PROCESSOR "armv7le") # which compilers to use for C and C++ set(arch gcc_ntoarmv7le) set(CMAKE_C_COMPILER qcc -V${arch}) set(CMAKE_CXX_COMPILER QCC -V${arch}) # here is the target environment located set(CMAKE_FIND_ROOT_PATH $ENV{QNX_TARGET}/armle-v7 $ENV{QNX_TARGET}) if(CMAKE_HOST_WIN32) set(HOST_EXECUTABLE_SUFFIX ".exe") endif() set(CMAKE_AR "$ENV{QNX_HOST}/usr/bin/ntoarmv7-ar${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX ar Program") set(CMAKE_RANLIB "$ENV{QNX_HOST}/usr/bin/ntoarmv7-ranlib${HOST_EXECUTABLE_SUFFIX}" CACHE PATH "QNX ar Program") # adjust the default behaviour of the FIND_XXX() commands: # search headers and libraries in the target environment, search # programs in the host environment set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) libical-3.0.1/cmake/Toolchain-iMX6.cmake000066400000000000000000000045061320431302500176730ustar00rootroot00000000000000# Basic cmake toolchain file for Freescale iMX6 # Assumptions: toolchain is in path, $SYSROOT points to the sysroot # # Copyright (c) 2013-2016 Klarälvdalens Datakonsult AB, a KDAB Group company # All rights reserved. # # Author: Volker Krause # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # # 1. Redistributions of source code must retain the copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # 3. The name of the author may not be used to endorse or promote products # derived from this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. set(CMAKE_SYSTEM_NAME "Linux") set(CMAKE_SYSTEM_PROCESSOR "armv7-a") set(CMAKE_C_COMPILER "arm-linux-gcc") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} --sysroot=$ENV{SYSROOT} -march=armv7-a -mfpu=neon") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --sysroot=$ENV{SYSROOT} -march=armv7-a -mfpu=neon") set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} --sysroot=$ENV{SYSROOT}") set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} --sysroot=$ENV{SYSROOT}") set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} --sysroot=$ENV{SYSROOT}") set(CMAKE_FIND_ROOT_PATH "$ENV{SYSROOT}") set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) libical-3.0.1/cmake/Toolchain-iOS.cmake000066400000000000000000000141761320431302500176060ustar00rootroot00000000000000# This file is based off of the Platform/Darwin.cmake and Platform/UnixPaths.cmake # files which are included with CMake 2.8.4 # It has been altered for iOS development # Options: # # IOS_PLATFORM = OS (default) or SIMULATOR # This decides if SDKS will be selected from the iPhoneOS.platform or iPhoneSimulator.platform folders # OS - the default, used to build for iPhone and iPad physical devices, which have an arm arch. # SIMULATOR - used to build for the Simulator platforms, which have an x86 arch. # # CMAKE_IOS_DEVELOPER_ROOT = automatic(default) or /path/to/platform/Developer folder # By default this location is automatcially chosen based on the IOS_PLATFORM value above. # If set manually, it will override the default location and force the user of a particular Developer Platform # # CMAKE_IOS_SDK_ROOT = automatic(default) or /path/to/platform/Developer/SDKs/SDK folder # By default this location is automatcially chosen based on the CMAKE_IOS_DEVELOPER_ROOT value. # In this case it will always be the most up-to-date SDK found in the CMAKE_IOS_DEVELOPER_ROOT path. # If set manually, this will force the use of a specific SDK version # Standard settings set (CMAKE_SYSTEM_NAME Darwin) set (CMAKE_SYSTEM_VERSION 1 ) set (UNIX True) set (APPLE True) set (IOS True) # Force the compilers to gcc for iOS include (CMakeForceCompiler) CMAKE_FORCE_C_COMPILER (gcc gcc) CMAKE_FORCE_CXX_COMPILER (g++ g++) # Skip the platform compiler checks for cross compiling set (CMAKE_CXX_COMPILER_WORKS TRUE) set (CMAKE_C_COMPILER_WORKS TRUE) # All iOS/Darwin specific settings - some may be redundant set (CMAKE_SHARED_LIBRARY_PREFIX "lib") set (CMAKE_SHARED_LIBRARY_SUFFIX ".dylib") set (CMAKE_SHARED_MODULE_PREFIX "lib") set (CMAKE_SHARED_MODULE_SUFFIX ".so") set (CMAKE_MODULE_EXISTS 1) set (CMAKE_DL_LIBS "") set (CMAKE_C_OSX_COMPATIBILITY_VERSION_FLAG "-compatibility_version ") set (CMAKE_C_OSX_CURRENT_VERSION_FLAG "-current_version ") set (CMAKE_CXX_OSX_COMPATIBILITY_VERSION_FLAG "${CMAKE_C_OSX_COMPATIBILITY_VERSION_FLAG}") set (CMAKE_CXX_OSX_CURRENT_VERSION_FLAG "${CMAKE_C_OSX_CURRENT_VERSION_FLAG}") # Hidden visibilty is required for cxx on iOS set (CMAKE_C_FLAGS "") set (CMAKE_CXX_FLAGS "-headerpad_max_install_names -fvisibility=hidden -fvisibility-inlines-hidden") set (CMAKE_C_LINK_FLAGS "-Wl,-search_paths_first ${CMAKE_C_LINK_FLAGS}") set (CMAKE_CXX_LINK_FLAGS "-Wl,-search_paths_first ${CMAKE_CXX_LINK_FLAGS}") set (CMAKE_PLATFORM_HAS_INSTALLNAME 1) set (CMAKE_SHARED_LIBRARY_CREATE_C_FLAGS "-dynamiclib -headerpad_max_install_names") set (CMAKE_SHARED_MODULE_CREATE_C_FLAGS "-bundle -headerpad_max_install_names") set (CMAKE_SHARED_MODULE_LOADER_C_FLAG "-Wl,-bundle_loader,") set (CMAKE_SHARED_MODULE_LOADER_CXX_FLAG "-Wl,-bundle_loader,") set (CMAKE_FIND_LIBRARY_SUFFIXES ".dylib" ".so" ".a") # hack: if a new cmake (which uses CMAKE_INSTALL_NAME_TOOL) runs on an old build tree # (where install_name_tool was hardcoded) and where CMAKE_INSTALL_NAME_TOOL isn't in the cache # and still cmake didn't fail in CMakeFindBinUtils.cmake (because it isn't rerun) # hardcode CMAKE_INSTALL_NAME_TOOL here to install_name_tool, so it behaves as it did before, Alex if (NOT DEFINED CMAKE_INSTALL_NAME_TOOL) find_program(CMAKE_INSTALL_NAME_TOOL install_name_tool) endif (NOT DEFINED CMAKE_INSTALL_NAME_TOOL) # Setup iOS platform if (NOT DEFINED IOS_PLATFORM) set (IOS_PLATFORM "OS") endif (NOT DEFINED IOS_PLATFORM) set (IOS_PLATFORM ${IOS_PLATFORM} CACHE STRING "Type of iOS Platform") # Check the platform selection and setup for developer root if (${IOS_PLATFORM} STREQUAL "OS") set (IOS_PLATFORM_LOCATION "iPhoneOS.platform") elseif (${IOS_PLATFORM} STREQUAL "SIMULATOR") set (IOS_PLATFORM_LOCATION "iPhoneSimulator.platform") else (${IOS_PLATFORM} STREQUAL "OS") message (FATAL_ERROR "Unsupported IOS_PLATFORM value selected. Please choose OS or SIMULATOR") endif (${IOS_PLATFORM} STREQUAL "OS") # Setup iOS developer location if (NOT DEFINED CMAKE_IOS_DEVELOPER_ROOT) set (CMAKE_IOS_DEVELOPER_ROOT "/Developer/Platforms/${IOS_PLATFORM_LOCATION}/Developer") endif (NOT DEFINED CMAKE_IOS_DEVELOPER_ROOT) set (CMAKE_IOS_DEVELOPER_ROOT ${CMAKE_IOS_DEVELOPER_ROOT} CACHE PATH "Location of iOS Platform") # Find and use the most recent iOS sdk if (NOT DEFINED CMAKE_IOS_SDK_ROOT) file (GLOB _CMAKE_IOS_SDKS "${CMAKE_IOS_DEVELOPER_ROOT}/SDKs/*") if (_CMAKE_IOS_SDKS) list (SORT _CMAKE_IOS_SDKS) list (REVERSE _CMAKE_IOS_SDKS) list (GET _CMAKE_IOS_SDKS 0 CMAKE_IOS_SDK_ROOT) else (_CMAKE_IOS_SDKS) message (FATAL_ERROR "No iOS SDK's found in default seach path ${CMAKE_IOS_DEVELOPER_ROOT}. Manually set CMAKE_IOS_SDK_ROOT or install the iOS SDK.") endif (_CMAKE_IOS_SDKS) message (STATUS "Toolchain using default iOS SDK: ${CMAKE_IOS_SDK_ROOT}") endif (NOT DEFINED CMAKE_IOS_SDK_ROOT) set (CMAKE_IOS_SDK_ROOT ${CMAKE_IOS_SDK_ROOT} CACHE PATH "Location of the selected iOS SDK") # Set the sysroot default to the most recent SDK set (CMAKE_OSX_SYSROOT ${CMAKE_IOS_SDK_ROOT} CACHE PATH "Sysroot used for iOS support") # set the architecture for iOS - using ARCHS_STANDARD_32_BIT sets armv6,armv7 and appears to be XCode's standard. # The other value that works is ARCHS_UNIVERSAL_IPHONE_OS but that sets armv7 only set (CMAKE_OSX_ARCHITECTURES "$(ARCHS_STANDARD_32_BIT)" CACHE string "Build architecture for iOS") # Set the find root to the iOS developer roots and to user defined paths set (CMAKE_FIND_ROOT_PATH ${CMAKE_IOS_DEVELOPER_ROOT} ${CMAKE_IOS_SDK_ROOT} ${CMAKE_PREFIX_PATH} CACHE string "iOS find search path root") # default to searching for frameworks first set (CMAKE_FIND_FRAMEWORK FIRST) # set up the default search directories for frameworks set (CMAKE_SYSTEM_FRAMEWORK_PATH ${CMAKE_IOS_SDK_ROOT}/System/Library/Frameworks ${CMAKE_IOS_SDK_ROOT}/System/Library/PrivateFrameworks ${CMAKE_IOS_SDK_ROOT}/Developer/Library/Frameworks ) # only search the iOS sdks, not the remainder of the host filesystem set (CMAKE_FIND_ROOT_PATH_MODE_PROGRAM ONLY) set (CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) set (CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) libical-3.0.1/cmake/Toolchain-jetson-tk1.cmake000066400000000000000000000047231320431302500211100ustar00rootroot00000000000000# Basic cmake toolchain file for Freescale iMX6 # Assumptions: toolchain is in path, $SYSROOT points to the sysroot # # Copyright (c) 2013-2016 Klarälvdalens Datakonsult AB, a KDAB Group company # All rights reserved. # # Author: Volker Krause # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # # 1. Redistributions of source code must retain the copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # 3. The name of the author may not be used to endorse or promote products # derived from this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. set(CMAKE_SYSTEM_NAME "Linux") set(CMAKE_SYSTEM_PROCESSOR "armv7-a") set(CMAKE_C_COMPILER "arm-linux-gnueabihf-gcc") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} --sysroot=$ENV{SYSROOT} -mtune=cortex-a15 -march=armv7-a -mfpu=neon-vfpv4") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} --sysroot=$ENV{SYSROOT} -mtune=cortex-a15 -march=armv7-a -mfpu=neon-vfpv4") set(CMAKE_EXE_LINKER_FLAGS "--sysroot=$ENV{SYSROOT} -Wl,-rpath-link,$ENV{SYSROOT}/usr/lib/arm-linux-gnueabihf/tegra" CACHE STRING "executable linker flags" FORCE) set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} --sysroot=$ENV{SYSROOT}") set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} --sysroot=$ENV{SYSROOT}") set(CMAKE_FIND_ROOT_PATH "$ENV{SYSROOT}") set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) libical-3.0.1/cmake/modules/000077500000000000000000000000001320431302500156335ustar00rootroot00000000000000libical-3.0.1/cmake/modules/FindBDB.cmake000066400000000000000000000024721320431302500200320ustar00rootroot00000000000000# Finds the Berkeley DB Library # # BDB_FOUND - True if Berkeley DB found. # BDB_INCLUDE_DIR - Directory to include to get Berkeley DB headers # BDB_LIBRARY - Library to link against for the Berkeley DB # set_package_properties(BDB PROPERTIES DESCRIPTION "Berkeley DB storage" URL "http://www.oracle.com/database/berkeley-db" ) if(BDB_INCLUDE_DIR AND BDB_LIBRARY) # Already in cache, be silent set(BDB_FIND_QUIETLY TRUE) endif() # Look for the header file. find_path( BDB_INCLUDE_DIR NAMES db.h HINTS /usr/local/opt/db/include DOC "Include directory for the Berkeley DB library" ) mark_as_advanced(BDB_INCLUDE_DIR) # Look for the library. find_library( BDB_LIBRARY NAMES db HINTS /usr/local/opt/db4/lib DOC "Libraries to link against for the Berkeley DB" ) mark_as_advanced(BDB_LIBRARY) # Copy the results to the output variables. if(BDB_INCLUDE_DIR AND BDB_LIBRARY) set(BDB_FOUND 1) else() set(BDB_FOUND 0) endif() if(BDB_FOUND) if(NOT BDB_FIND_QUIETLY) message(STATUS "Found Berkeley DB header files in ${BDB_INCLUDE_DIR}") message(STATUS "Found Berkeley libraries: ${BDB_LIBRARY}") endif() else() if(BDB_FIND_REQUIRED) message(FATAL_ERROR "Could not find Berkeley DB") else() message(STATUS "Optional package Berkeley DB was not found") endif() endif() libical-3.0.1/cmake/modules/FindGLib.cmake000066400000000000000000000012661320431302500202600ustar00rootroot00000000000000# - try to find glib # # Once done this will define # # GLIB_FOUND - system has GLib 2.0 # GLIB_CFLAGS # GLIB_LIBRARIES set_package_properties(GLib PROPERTIES DESCRIPTION "A library of handy utility functions" URL "http://www.gtk.org" ) find_package(PkgConfig) if(PKG_CONFIG_FOUND) if(PACKAGE_FIND_VERSION_COUNT GREATER 0) set(_glib_version_cmp ">=${PACKAGE_FIND_VERSION}") endif() pkg_check_modules(_pc_glib glib-2.0${_glib_version_cmp} gobject-2.0${_glib_version_cmp}) if(_pc_glib_FOUND) set(GLIB_FOUND TRUE) set(GLIB_CFLAGS "${_pc_glib_CFLAGS}") set(GLIB_LIBRARIES "${_pc_glib_LDFLAGS}") endif() endif() mark_as_advanced( GLIB_CFLAGS GLIB_LIBRARIES ) libical-3.0.1/cmake/modules/FindGObjectIntrospection.cmake000066400000000000000000000042261320431302500235400ustar00rootroot00000000000000# - try to find gobject-introspection # # Once done this will define # # GObjectIntrospection_FOUND - system has gobject-introspection # GObjectIntrospection_SCANNER - the gobject-introspection scanner, g-ir-scanner # GObjectIntrospection_COMPILER - the gobject-introspection compiler, g-ir-compiler # GObjectIntrospection_GENERATE - the gobject-introspection generate, g-ir-generate # GObjectIntrospection_GIRDIR # GObjectIntrospection_TYPELIBDIR # GObjectIntrospection_CFLAGS # GObjectIntrospection_LIBS # # Copyright (C) 2010, Pino Toscano, # # Redistribution and use is allowed according to the terms of the BSD license. # For details see the accompanying COPYING-CMAKE-SCRIPTS file. macro(_GIR_GET_PKGCONFIG_VAR _outvar _varname) execute_process( COMMAND ${PKG_CONFIG_EXECUTABLE} --variable=${_varname} gobject-introspection-1.0 OUTPUT_VARIABLE _result RESULT_VARIABLE _null ) if (_null) else() string(REGEX REPLACE "[\r\n]" " " _result "${_result}") string(REGEX REPLACE " +$" "" _result "${_result}") separate_arguments(_result) set(${_outvar} ${_result} CACHE INTERNAL "") endif() endmacro(_GIR_GET_PKGCONFIG_VAR) find_package(PkgConfig) if(PKG_CONFIG_FOUND) if(PACKAGE_FIND_VERSION_COUNT GREATER 0) set(_gir_version_cmp ">=${PACKAGE_FIND_VERSION}") endif() pkg_check_modules(_pc_gir gobject-introspection-1.0${_gir_version_cmp}) if(_pc_gir_FOUND) set(GObjectIntrospection_FOUND TRUE) _gir_get_pkgconfig_var(GObjectIntrospection_SCANNER "g_ir_scanner") _gir_get_pkgconfig_var(GObjectIntrospection_COMPILER "g_ir_compiler") _gir_get_pkgconfig_var(GObjectIntrospection_GENERATE "g_ir_generate") _gir_get_pkgconfig_var(GObjectIntrospection_GIRDIR "girdir") _gir_get_pkgconfig_var(GObjectIntrospection_TYPELIBDIR "typelibdir") set(GObjectIntrospection_CFLAGS "${_pc_gir_CFLAGS}") set(GObjectIntrospection_LIBS "${_pc_gir_LIBS}") endif() endif() mark_as_advanced( GObjectIntrospection_SCANNER GObjectIntrospection_COMPILER GObjectIntrospection_GENERATE GObjectIntrospection_GIRDIR GObjectIntrospection_TYPELIBDIR GObjectIntrospection_CFLAGS GObjectIntrospection_LIBS ) libical-3.0.1/cmake/modules/FindICU.cmake000066400000000000000000000074371320431302500200710ustar00rootroot00000000000000# Finds the International Components for Unicode (ICU) Library # # ICU_FOUND - True if ICU found. # ICU_I18N_FOUND - True if ICU's internationalization library found. # ICU_BINARY_DIR - Directory with the runtime binaries # ICU_INCLUDE_DIR - Directory to include to get ICU headers # Note: always include ICU headers as, e.g., # unicode/utypes.h # ICU_LIBRARY - Library to link against for the common ICU # ICU_I18N_LIBRARY - Library to link against for ICU internationaliation # (note: in addition to ICU_LIBRARY) # ICU_VERSION - ICU version MAJOR.MINOR # ICU_MAJOR_VERSION - ICU major version # ICO_MINOR_VERSION - ICU minor version # set_package_properties(ICU PROPERTIES DESCRIPTION "libicu (International Components for Unicode) libraries" URL "http://www.icu-project.org" ) if(WIN32) file(TO_CMAKE_PATH "$ENV{PROGRAMFILES}" _program_FILES_DIR) endif() if(ICU_INCLUDE_DIR AND ICU_LIBRARY) # Already in cache, be silent set(ICU_FIND_QUIETLY TRUE) endif() #set the root from the ICU_BASE environment file(TO_NATIVE_PATH "$ENV{ICU_BASE}" icu_root) #override the root from ICU_BASE defined to cmake if(DEFINED ICU_BASE) file(TO_NATIVE_PATH "${ICU_BASE}" icu_root) endif() # Look for the header file. find_path( ICU_INCLUDE_DIR NAMES unicode/utypes.h HINTS ${icu_root}/include ${_program_FILES_DIR}/icu/include /usr/local/opt/icu4c/include DOC "Include directory for the ICU library" ) mark_as_advanced(ICU_INCLUDE_DIR) # Look for the library. find_library( ICU_LIBRARY NAMES icuuc cygicuuc cygicuuc32 HINTS ${icu_root}/lib/ ${_program_FILES_DIR}/icu/lib/ /usr/local/opt/icu4c/lib/ DOC "Libraries to link against for the common parts of ICU" ) mark_as_advanced(ICU_LIBRARY) # Look for the binary path. find_program( tmp_DIR NAMES genccode uconv PATHS ${icu_root}/bin/ ${_program_FILES_DIR}/icu/bin/ /usr/local/opt/icu4c/bin/ ) get_filename_component(tmp_DIR ${tmp_DIR} DIRECTORY) set(ICU_BINARY_DIR ${tmp_DIR} CACHE DOC "Runtime binaries directory for the ICU library") mark_as_advanced(ICU_BINARY_DIR) # Copy the results to the output variables. if(ICU_INCLUDE_DIR AND ICU_LIBRARY) set(ICU_FOUND 1) set(ICU_LIBRARIES ${ICU_LIBRARY}) set(ICU_INCLUDE_DIRS ${ICU_INCLUDE_DIR}) set(ICU_VERSION 0) set(ICU_MAJOR_VERSION 0) set(ICU_MINOR_VERSION 0) file(READ "${ICU_INCLUDE_DIR}/unicode/uvernum.h" _ICU_VERSION_CONENTS) string(REGEX REPLACE ".*#define U_ICU_VERSION_MAJOR_NUM ([0-9]+).*" "\\1" ICU_MAJOR_VERSION "${_ICU_VERSION_CONENTS}") string(REGEX REPLACE ".*#define U_ICU_VERSION_MINOR_NUM ([0-9]+).*" "\\1" ICU_MINOR_VERSION "${_ICU_VERSION_CONENTS}") set(ICU_VERSION "${ICU_MAJOR_VERSION}.${ICU_MINOR_VERSION}") # Look for the ICU internationalization libraries find_library( ICU_I18N_LIBRARY NAMES icuin icui18n cygicuin cygicuin32 HINTS ${icu_root}/lib/ ${_program_FILES_DIR}/icu/lib/ /usr/local/opt/icu4c/lib/ DOC "Libraries to link against for ICU internationalization" ) mark_as_advanced(ICU_I18N_LIBRARY) if(ICU_I18N_LIBRARY) set(ICU_I18N_FOUND 1) set(ICU_LIBRARIES "${ICU_LIBRARIES} ${ICU_I18N_LIBRARY}") else() set(ICU_I18N_FOUND 0) endif() else() set(ICU_FOUND 0) set(ICU_I18N_FOUND 0) set(ICU_INCLUDE_DIRS) set(ICU_LIBRARIES) set(ICU_VERSION) set(ICU_MAJOR_VERSION) set(ICU_MINOR_VERSION) endif() if(ICU_FOUND) if(NOT ICU_FIND_QUIETLY) message(STATUS "Found ICU version ${ICU_VERSION}") message(STATUS "Found ICU header files in ${ICU_INCLUDE_DIRS}") message(STATUS "Found ICU libraries: ${ICU_LIBRARIES}") endif() else() if(ICU_FIND_REQUIRED) message(FATAL_ERROR "Could not find ICU") else() message(STATUS "Optional package ICU was not found") endif() endif() libical-3.0.1/cmake/modules/FindLibXML.cmake000066400000000000000000000010741320431302500205270ustar00rootroot00000000000000# - try to find libxml # # Once done this will define # # LIBXML_FOUND - system has libxml # LIBXML_CFLAGS # LIBXML_LIBRARIES find_package(PkgConfig) if(PKG_CONFIG_FOUND) if(PACKAGE_FIND_VERSION_COUNT GREATER 0) set(_libxml_version_cmp ">=${PACKAGE_FIND_VERSION}") endif() pkg_check_modules(_pc_libxml libxml-2.0${_libxml_version_cmp}) if(_pc_libxml_FOUND) set(LIBXML_FOUND TRUE) set(LIBXML_CFLAGS "${_pc_libxml_CFLAGS}") set(LIBXML_LIBRARIES "${_pc_libxml_LIBRARIES}") endif() endif() mark_as_advanced( LIBXML_CFLAGS LIBXML_LIBRARIES ) libical-3.0.1/cmake/modules/FindWcecompat.cmake000066400000000000000000000020711320431302500213600ustar00rootroot00000000000000# Try to find Wcecompat functionality # Once done this will define # # WCECOMPAT_FOUND - system has Wcecompat # WCECOMPAT_INCLUDE_DIR - Wcecompat include directory # WCECOMPAT_LIBRARIES - Libraries needed to use Wcecompat # # Copyright (c) 2010, Andreas Holzammer, # # Redistribution and use is allowed according to the terms of the BSD license. if(WCECOMPAT_INCLUDE_DIR AND WCECOMPAT_LIB_FOUND) set(Wcecompat_FIND_QUIETLY TRUE) endif() find_path(WCECOMPAT_INCLUDE_DIR errno.h PATH_SUFFIXES wcecompat) set(WCECOMPAT_LIB_FOUND FALSE) if(WCECOMPAT_INCLUDE_DIR) find_library(WCECOMPAT_LIBRARIES NAMES wcecompat wcecompatex) if(WCECOMPAT_LIBRARIES) set(WCECOMPAT_LIB_FOUND TRUE) endif() endif() # I have no idea what this is about, but it seems to be used quite often, so I add this here set(WCECOMPAT_CONST const) include(FindPackageHandleStandardArgs) find_package_handle_standard_args(Wcecompat DEFAULT_MSG WCECOMPAT_LIBRARIES WCECOMPAT_LIB_FOUND) mark_as_advanced(WCECOMPAT_INCLUDE_DIR WCECOMPAT_LIBRARIES WCECOMPAT_CONST WCECOMPAT_LIB_FOUND) libical-3.0.1/cmake/modules/GObjectIntrospectionMacros.cmake000066400000000000000000000070741320431302500241100ustar00rootroot00000000000000# Copyright (C) 2010, Pino Toscano, # # Redistribution and use is allowed according to the terms of the BSD license. # For details see the accompanying COPYING-CMAKE-SCRIPTS file. macro(_gir_list_prefix _outvar _listvar _prefix) set(${_outvar}) foreach(_item IN LISTS ${_listvar}) list(APPEND ${_outvar} ${_prefix}${_item}) endforeach() endmacro(_gir_list_prefix) macro(gir_add_introspections introspections_girs) set(_gir_girs) set(_gir_typelibs) foreach(gir IN LISTS ${introspections_girs}) set(_gir_name "${gir}") ## Transform the gir filename to something which can reference through a variable ## without automake/make complaining, eg Gtk-2.0.gir -> Gtk_2_0_gir string(REPLACE "-" "_" _gir_name "${_gir_name}") string(REPLACE "." "_" _gir_name "${_gir_name}") # Namespace and Version is either fetched from the gir filename # or the _NAMESPACE/_VERSION variable combo set(_gir_namespace "${${_gir_name}_NAMESPACE}") if (_gir_namespace STREQUAL "") string(REGEX REPLACE "([^-]+)-.*" "\\1" _gir_namespace "${gir}") endif () set(_gir_version "${${_gir_name}_VERSION}") if (_gir_version STREQUAL "") string(REGEX REPLACE ".*-([^-]+).gir" "\\1" _gir_version "${gir}") endif () # _PROGRAM is an optional variable which needs it's own --program argument set(_gir_program "${${_gir_name}_PROGRAM}") if (NOT _gir_program STREQUAL "") set(_gir_program "--program=${_gir_program}") endif () # Variables which provides a list of things _gir_list_prefix(_gir_libraries ${_gir_name}_LIBS "--library=") _gir_list_prefix(_gir_packages ${_gir_name}_PACKAGES "--pkg=") _gir_list_prefix(_gir_includes ${_gir_name}_INCLUDES "--include=") # Reuse the LIBTOOL variable from by automake if it's set set(_gir_libtool "--no-libtool") add_custom_command( COMMAND ${CMAKE_COMMAND} -E env "CC='${CMAKE_C_COMPILER}'" ${GObjectIntrospection_SCANNER} ${GObjectIntrospection_SCANNER_ARGS} --namespace=${_gir_namespace} --nsversion=${_gir_version} ${_gir_libtool} ${_gir_program} ${_gir_libraries} ${_gir_packages} ${_gir_includes} ${${_gir_name}_SCANNERFLAGS} ${${_gir_name}_CFLAGS} ${${_gir_name}_FILES} --output ${CMAKE_CURRENT_BINARY_DIR}/${gir} --accept-unprefixed DEPENDS ${${_gir_name}_FILES} ${${_gir_name}_LIBS} OUTPUT ${gir} WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} VERBATIM ) list(APPEND _gir_girs ${CMAKE_CURRENT_BINARY_DIR}/${gir}) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${gir} DESTINATION ${SHARE_INSTALL_DIR}/gir-1.0) string(REPLACE ".gir" ".typelib" _typelib "${gir}") add_custom_command( COMMAND ${GObjectIntrospection_COMPILER} ${GObjectIntrospection_COMPILER_ARGS} --includedir=. ${CMAKE_CURRENT_BINARY_DIR}/${gir} -o ${CMAKE_CURRENT_BINARY_DIR}/${_typelib} DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${gir} OUTPUT ${_typelib} WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} ) list(APPEND _gir_typelibs ${CMAKE_CURRENT_BINARY_DIR}/${_typelib}) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${_typelib} DESTINATION ${LIB_INSTALL_DIR}/girepository-1.0) endforeach() add_custom_target(gir-girs-${_gir_name} ALL DEPENDS ${_gir_girs}) add_custom_target(gir-typelibs-${_gir_name} ALL DEPENDS ${_gir_typelibs}) endmacro(gir_add_introspections) libical-3.0.1/cmake/run_test.cmake000066400000000000000000000022441320431302500170320ustar00rootroot00000000000000#------------------------------------------------- # some argument checking: # test_cmd is the command to run with all its arguments if(NOT test_cmd) message(FATAL_ERROR "Variable test_cmd not defined") endif() # output_blessed contains the name of the "blessed" output file if(NOT output_blessed) message(FATAL_ERROR "Variable output_blessed not defined") endif() # output_test contains the name of the output file the test_cmd will produce if(NOT output_test) message(FATAL_ERROR "Variable output_test not defined") endif() # convert the space-separated string to a list separate_arguments(test_args) execute_process( COMMAND ${test_cmd} ${test_args} RESULT_VARIABLE test_not_successful ERROR_VARIABLE err ) if(test_not_successful) message(SEND_ERROR "Unable to run test '${test_cmd}': ${err} : shell output: ${test_not_successful}!") endif() execute_process( COMMAND ${CMAKE_COMMAND} -E compare_files ${output_blessed} ${output_test} RESULT_VARIABLE test_not_successful ERROR_VARIABLE err ) if(test_not_successful) message(SEND_ERROR "Output does not match for ${output_blessed} and ${output_test}: ${err} : shell output: ${test_not_successful}!") endif() libical-3.0.1/config.h.cmake000066400000000000000000000325551320431302500156120ustar00rootroot00000000000000/* config.h. Generated by cmake from config.h.cmake */ /* Define if you have the ICU library. */ #cmakedefine HAVE_LIBICU 1 /* Define if you have the ICU internationalization library. */ #cmakedefine HAVE_LIBICU_I18N 1 /* Define if you have the Berkeley DB library. */ #cmakedefine HAVE_BDB 1 /* Define to 1 if you have the `backtrace' function. */ #cmakedefine HAVE_BACKTRACE 1 /* Define to 1 if you have the header file. */ #cmakedefine HAVE_BYTESWAP_H 1 /* Define to 1 if you have the header file. */ #cmakedefine HAVE_ENDIAN_H 1 /* Define to 1 if you have the `GetNumberFormat' function. */ #cmakedefine HAVE_GETNUMBERFORMAT 1 /* Define to 1 if you have the `gmtime_r' function. */ #cmakedefine HAVE_GMTIME_R 1 /* Define to 1 if you have the `localtime_r' function. */ #cmakedefine HAVE_LOCALTIME_R 1 /* Define to 1 if you have the header file. */ #cmakedefine HAVE_INTTYPES_H 1 /* Define to 1 if you have type 'intptr_t' defined. */ #cmakedefine HAVE_INTPTR_T 1 /* Define to 1 if you have the `iswspace' function. */ #cmakedefine HAVE_ISWSPACE 1 /* Define to 1 if you have the header file. */ #cmakedefine HAVE_DIRENT_H 1 /* Define if we have pthread. */ #cmakedefine HAVE_PTHREAD_ATTR_GET_NP 1 #cmakedefine HAVE_PTHREAD_GETATTR_NP 1 #cmakedefine HAVE_PTHREAD_CREATE 1 #cmakedefine HAVE_PTHREAD_NP_H 1 #if defined(HAVE_PTHREAD_ATTR_GET_NP) || defined(HAVE_PTHREAD_GETATTR_NP) || defined(HAVE_PTHREAD_CREATE) || defined(HAVE_PTHREAD_NP_H) #define HAVE_PTHREAD 1 #endif /* Define to 1 if you have the header file. */ #cmakedefine HAVE_PTHREAD_H 1 /* Define to 1 if you have the `nanosleep' function. */ #cmakedefine HAVE_NANOSLEEP 1 /* Define to 1 if you have the `usleep' function. */ #cmakedefine HAVE_USLEEP 1 /* Define to 1 if you have the `snprintf' function. */ #cmakedefine HAVE_SNPRINTF 1 /* Define to 1 if you have the `_snprintf' function. */ #cmakedefine HAVE__SNPRINTF 1 /* Define to 1 if you have the `stat' function. */ #cmakedefine HAVE_STAT 1 /* Define to 1 if you have the `_stat' function. */ #cmakedefine HAVE__STAT 1 /* Define to 1 if you have the `strcasecmp' function. */ #cmakedefine HAVE_STRCASECMP 1 /* Define to 1 if you have the `strncasecmp' function. */ #cmakedefine HAVE_STRNCASECMP 1 /* Define to 1 if you have the `_stricmp' function. */ #cmakedefine HAVE__STRICMP 1 /* Define to 1 if you have the `_strnicmp' function. */ #cmakedefine HAVE__STRNICMP 1 /* Define to 1 if you have the `strdup' function. */ #cmakedefine HAVE_STRDUP 1 /* Define to 1 if you have the `_strdup' function. */ #cmakedefine HAVE__STRDUP 1 /* Define to 1 if you have the `access' function. */ #cmakedefine HAVE_ACCESS 1 /* Define to 1 if you have the `_access' function. */ #cmakedefine HAVE__ACCESS 1 /* Define to 1 if you have the `getopt' function. */ #cmakedefine HAVE_GETOPT 1 /* Define to 1 if you have the `getpid' function. */ #cmakedefine HAVE_GETPID 1 /* Define to 1 if you have the `_getpid' function. */ #cmakedefine HAVE__GETPID 1 /* Define to 1 if you have the `mkdir' function. */ #cmakedefine HAVE_MKDIR 1 /* Define to 1 if you have the `_mkdir' function. */ #cmakedefine HAVE__MKDIR 1 /* Define to 1 if you have the `open' function. */ #cmakedefine HAVE_OPEN 1 /* Define to 1 if you have the `_open' function. */ #cmakedefine HAVE__OPEN 1 /* Define to 1 if you have the `read' function. */ #cmakedefine HAVE_READ 1 /* Define to 1 if you have the `_read' function. */ #cmakedefine HAVE__READ 1 /* Define to 1 if you have the `write' function. */ #cmakedefine HAVE_WRITE 1 /* Define to 1 if you have the `_write' function. */ #cmakedefine HAVE__WRITE 1 /* Define to 1 if you have the header file. */ #cmakedefine HAVE_SYS_ENDIAN_H 1 /* Define to 1 if you have the `setenv' function. */ #cmakedefine HAVE_SETENV 1 /* Define to 1 if you have the header file. */ #cmakedefine HAVE_SYS_PARAM_H 1 /* Define to 1 if you have the header file. */ #cmakedefine HAVE_SYS_UTSNAME_H 1 /* Define to 1 if you have the header file. */ #cmakedefine HAVE_UNISTD_H 1 /* Define to 1 if you have the header file. */ #cmakedefine HAVE_FCNTL_H 1 /* Define to 1 if you have the `unsetenv' function. */ #cmakedefine HAVE_UNSETENV 1 /* Define to 1 if you have the `alarm' function. */ #cmakedefine HAVE_ALARM 1 /* Define to 1 if you have the `signal' function. */ #cmakedefine HAVE_SIGNAL 1 /* Define to 1 if you have the `waitpid' function. */ #cmakedefine HAVE_WAITPID 1 /* Define to 1 if you have the `fork' function. */ #cmakedefine HAVE_FORK 1 /* Define to 1 if you have the `getpwent' function. */ #cmakedefine HAVE_GETPWENT 1 /* Define to 1 if you have the `unlink' function. */ #cmakedefine HAVE_UNLINK 1 /* Define to 1 if you have the header file. */ #cmakedefine HAVE_WCTYPE_H 1 /* Define to make icalerror_* calls abort instead of internally signalling an error */ #define ICAL_ERRORS_ARE_FATAL ${ICAL_ERRORS_ARE_FATAL} /* Define to prevent empty properties from being replaced with X-LIC-ERROR properties */ #define ICAL_ALLOW_EMPTY_PROPERTIES ${ICAL_ALLOW_EMPTY_PROPERTIES} /* Define to the address where bug reports for this package should be sent. */ #define PACKAGE_BUGREPORT "${PROJECT_URL}" /* Define to the full name of this package. */ #define PACKAGE_NAME "${CMAKE_PROJECT_NAME}" /* Define to the full name and version of this package. */ #define PACKAGE_STRING "${CMAKE_PROJECT_NAME} ${PROJECT_VERSION}" /* Define to the one symbol short name of this package. */ #define PACKAGE_TARNAME "${CMAKE_PROJECT_NAME}" /* Define to the version of this package. */ #define PACKAGE_VERSION "${PROJECT_VERSION}" /* whether we should bring our own TZ-Data */ #cmakedefine USE_BUILTIN_TZDATA /* Define to empty if `const' does not conform to ANSI C. */ #cmakedefine const /* Typedef intptr_t if needed */ #cmakedefine HAVE_SIZEOF_INTPTR_T 1 #if !defined(HAVE_SIZEOF_INTPTR_T) typedef unsigned int inptr_t; #endif /* Typedef size_t if needed */ #cmakedefine HAVE_SIZEOF_SIZE_T #if !defined(HAVE_SIZEOF_SIZE_T) typedef unsigned long size_t; #endif /* Typedef ssize_t if needed */ #cmakedefine HAVE_SIZEOF_SSIZE_T #if !defined(HAVE_SIZEOF_SSIZE_T) typedef long ssize_t; #endif /* Typedef pid_t if needed */ #cmakedefine HAVE_SIZEOF_PID_T 1 #if !defined(HAVE_SIZEOF_PID_T) typedef int pid_t; #endif /* Typedef wint_t if needed */ #cmakedefine HAVE_SIZEOF_WINT_T 1 #if !defined(HAVE_SIZEOF_WINT_T) #if defined(HAVE_WCTYPE_H) #include #else typedef unsigned int wint_t; #endif #endif #cmakedefine SIZEOF_TIME_T ${SIZEOF_TIME_T} /* whether we have ICU DANGI calendar */ #cmakedefine HAVE_ICU_DANGI /* getpwent - function to get password file entry */ #if defined(HAVE_GETPWENT) #include #include #endif /* strcasecmp or stricmp: String compare, case independent */ #if defined(HAVE__STRICMP) #define strcasecmp _stricmp #include #else #if !defined(HAVE_STRCASECMP) #error "No case independent string compare function available" #else #include #endif #endif /* strncasecmp or strnicmp: String compare, case independent, size limited */ #if defined(HAVE__STRICMP) #define strncasecmp _strnicmp #include #else #if !defined(HAVE_STRNCASECMP) #error "No case independent string compare size limited function available" #else #include #endif #endif /* snprintf: size limited sprintf */ #if defined(HAVE__SNPRINTF) #define snprintf _snprintf #else #if !defined(HAVE_SNPRINTF) #error "No size limited sprintf available" #endif #endif #include /* sleep: function to sleep for a specified time */ #if defined(_WIN32) #include #if defined(sleep) #undef sleep #endif #define sleep(n) (Sleep((n)*1000)) #else #include #endif /* nanosleep: function for high resolution sleeping */ #if defined(HAVE_NANOSLEEP) #include #endif /* usleep: deprecated, but useful if nanosleep is unavailable */ #if defined(HAVE_USLEEP) #include #endif #if !defined(HAVE_NANOSLEEP) && !defined(HAVE_USLEEP) #if !defined(_WIN32) #error "No function for high resolution timing available" #endif #endif /* stat: function to get status info on a file */ #if defined(HAVE__STAT) #define stat _stat #else #if !defined(HAVE_STAT) #error "No function to get status info on a file available" #endif #endif #include #include /* strdup: function to duplicate a string */ #if defined(HAVE__STRDUP) #define strdup _strdup #else #if !defined(HAVE_STRDUP) #error "No duplicate a string function available" #endif #endif #include /* iswspace: whitespace wide character function */ #if !defined(HAVE_ISWSPACE) #include #define iswspace isspace #else #if defined(HAVE_WCTYPE_H) #include #else #include #endif #endif /* access - system function to check user file permissions */ #if defined(HAVE__ACCESS) #include #define access _access #else #if !defined(HAVE_ACCESS) #error "No check user file access function available" #else #if defined(HAVE_UNISTD_H) #include #endif #endif #endif /* getopt - function to parse command-line options */ #if defined(HAVE_GETOPT) #if defined(HAVE_UNISTD_H) #include #endif #else #if !defined(_WIN32) #error "No parse command-line function available" #endif #endif /* getpid - system function to get process identification */ #if defined(HAVE__GETPID) #include #define getpid _getpid #else #if !defined(HAVE_GETPID) #error "No get process identification function available" #else #if defined(HAVE_UNISTD_H) #include #endif #endif #endif /* mkdir - system function to create a directory */ #if defined(HAVE__MKDIR) #include #define mkdir(path, mode) _mkdir(path) #else #if !defined(HAVE_MKDIR) #error "No create directory system function available" #else #include #include #if defined(__MINGW32__) || defined(__MINGW64__) #define mkdir(path, mode) mkdir(path) #endif #endif #endif /* open - system function to open a file */ #if defined(HAVE__OPEN) #include #define open _open #else #if !defined(HAVE_OPEN) #error "No open file system function available" #endif #endif #if defined(HAVE_FCNTL_H) #include #endif /* read - system function to read from a file descriptor */ #if defined(HAVE__READ) #include #define read _read #else #if !defined(HAVE_READ) #error "No read from file descriptor system function available" #else #if defined(HAVE_UNISTD_H) #include #endif #endif #endif /* write - system function to write to a file descriptor */ #if defined(HAVE__WRITE) #include #define write _write #else #if !defined(HAVE_WRITE) #error "No write to file descriptor system function available" #else #if defined(HAVE_UNISTD_H) #include #endif #endif #endif #if defined(_MSC_VER) typedef int IO_SIZE_T; typedef unsigned int IO_SSIZE_T; #else typedef size_t IO_SIZE_T; typedef ssize_t IO_SSIZE_T; #endif #if defined(_MSC_VER) #if !defined(F_OK) /* file exists */ #define F_OK 0 #endif #if !defined(W_OK) /* file has write permission */ #define W_OK 2 #endif #if !defined(R_OK) /* file has read permission */ #define R_OK 4 #endif #if !defined(X_OK) /* file has execute permission */ #define X_OK 6 #endif #endif #if defined(_MSC_VER) #define _S_ISTYPE(mode, mask) (((mode) & _S_IFMT) == (mask)) #define S_ISDIR(mode) _S_ISTYPE((mode), _S_IFDIR) #define S_ISREG(mode) _S_ISTYPE((mode), _S_IFREG) #endif /* fork - system function to create a child process */ #if defined(HAVE_FORK) #if defined(HAVE_UNISTD_H) #include #endif #endif /* alarm - function to set and alarm for delivering a signal */ #if defined(HAVE_ALARM) #if defined(HAVE_UNISTD_H) #include #endif #endif /* signal - signal handling function */ #if defined(HAVE_SIGNAL) #include #endif /* waitpid - system function waiting on a process */ #if defined(HAVE_WAITPID) #include #include #endif /* unlink - system function to delete a file */ #if defined(HAVE_UNLINK) #if defined(HAVE_UNISTD_H) #include #endif #endif /* gmtime_r - thread safe gmtime() really only needed on Unix */ #include /*define before possible mention of gmtime()*/ #if !defined(HAVE_GMTIME_R) #if !defined(_WIN32) #error "No thread-safe gmtime function available" #endif /*on Windows there might be a macro called gmtime_r in pthread.h. don't use it.*/ #if defined(gmtime_r) #undef gmtime_r #endif /* FYI: The gmtime() in Microsoft's C library is MT-safe */ #define gmtime_r(tp,tmp) (gmtime(tp)?(*(tmp)=*gmtime(tp),(tmp)):0) #endif /* localtime_r - thread safe localtime() really only needed on Unix */ #if !defined(HAVE_LOCALTIME_R) #if !defined(_WIN32) #error "No thread-safe localtime function available" #endif /*on Windows there might be a macro called localtime_r in pthread.h. don't use it.*/ #if defined(localtime_r) #undef localtime_r #endif /* FYI: The localtime() in Microsoft's C library is MT-safe */ #define localtime_r(tp,tmp) (localtime(tp)?(*(tmp)=*localtime(tp),(tmp)):0) #endif #include /* define MAXPATHLEN */ #if defined(_WIN32) #include //for MAX_PATH #define MAXPATHLEN MAX_PATH #else #if defined(HAVE_SYS_PARAM_H) #include #endif #endif #if !defined(MAXPATHLEN) #define MAXPATHLEN 1024 #endif /* MIN macro */ #if !defined(MIN) #define MIN(a,b) (((a)<(b))?(a):(b)) #endif /* Unused argument macro */ #if !defined(_unused) #if defined(__LCLINT__) || defined(S_SPLINT_S) #define _unused(x) /*@unused@*/ x #else #define _unused(x) (void)x #endif #endif libical-3.0.1/debian/000077500000000000000000000000001320431302500143255ustar00rootroot00000000000000libical-3.0.1/debian/changelog000066400000000000000000000022261320431302500162010ustar00rootroot00000000000000libical (0.43-6) stable; urgency=high * new upstream release -- Wilfried Goesgens Sat, 13 Sep 2008 10:00:00 +0001 libical (0.31-4) stable; urgency=high * new release fixing a crash -- Wilfried Goesgens Mon, 17 Mar 2008 20:00:00 +0001 libical (0.30-1) unstable; urgency=low [ Wilfried Goesgens ] * remove CDBS * merge into upstream libical * merge in several patches roaming arround -- Wilfried Goesgens Wed, 30 Nov 2007 12:19:06 +0100 libical (0.26.6-1) unstable; urgency=low [ Fathi Boudra ] * Initial Debian release (Closes: #404862) * Remove dirs and README.Debian * Add soname patch * compat: bumped to 5 * control: * convert package to cdbs * add myself as uploader * bump Standards-Version to 3.7.2 * rewrite descriptions * copyright: complete rewrite [ Wilfried Goesgens ] * Update to aurore ical. -- Fathi Boudra Wed, 27 Dec 2006 12:19:06 +0100 libical (0.24-1) unstable; urgency=low * Initial release -- Wilfried Goesgens Fri, 22 Jul 2005 13:09:43 +0200 libical-3.0.1/debian/compat000066400000000000000000000000021320431302500155230ustar00rootroot000000000000005 libical-3.0.1/debian/control000066400000000000000000000047051320431302500157360ustar00rootroot00000000000000Source: libical Section: libs Priority: optional Maintainer: Wilfried Goesgens Uploaders: Fathi Boudra Build-Depends: debhelper (>= 5.0.42), autotools-dev, tzdata, swig, python-all-dev (>= 2.4.4), python-support (>= 0.5.6), python (>= 2.4.4) XS-Python-Version: all Standards-Version: 3.7.2 Homepage: http://freeassociation.sourceforge.net Package: libical-dev Section: libdevel Architecture: any Depends: ${misc:Depends}, libical0 (= ${binary:Version}) Description: iCalendar library implementation in C (development) libical is an open source implementation of the IETF's iCalendar calendaring and scheduling protocols (RFC 2445, 2446, and 2447). It parses iCal components and provides a C API for manipulating the component properties, parameters, and subcomponents. . This package contains the libical development files. Package: libical0 Section: libs Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends}, tzdata Description: iCalendar library implementation in C (runtime) libical is an open source implementation of the IETF's iCalendar calendaring and scheduling protocols (RFC 2445, 2446, and 2447). It parses iCal components and provides a C API for manipulating the component properties, parameters, and subcomponents. . This package contains the files necessary for running applications that use the libical library. Package: libical0-dbg Section: libs Priority: extra Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends}, libical0 (= ${binary:Version}) Description: iCalendar library implementation in C (runtime) libical is an open source implementation of the IETF's iCalendar calendaring and scheduling protocols (RFC 2445, 2446, and 2447). It parses iCal components and provides a C API for manipulating the component properties, parameters, and subcomponents. . This package contains the files necessary for running and debugging applications that use the libical library. Package: python-libical Section: python Architecture: any Depends: ${shlibs:Depends}, ${python:Depends}, libical0 (= ${binary:Version}) Description: iCalendar library implementation python language bindings libical is an open source implementation of the IETF's iCalendar calendaring and scheduling protocols (RFC 2445, 2446, and 2447). It parses iCal components and provides a C API for manipulating the component properties, parameters, and subcomponents. . This package contains the python language bindings. libical-3.0.1/debian/copyright000066400000000000000000000625261320431302500162730ustar00rootroot00000000000000This package was debianized by Fathi Boudra on Wed, 27 Dec 2006 12:19:06 +0100. It was downloaded from http://www.aurore.net/projects/libical/ This is a modified version of the original libical project from softwarestudio and the original author is Eric Busboom . Upstream Authors: John Gray Andrea Campi Omar Kilani Copyright for generated icalderivedproperties: (C) 1999 Eric Busboom Copyright for generated restrictionrecords and parameterrestrictions: (C) 1999 Graham Davison Copyright for sspm based on code from the mimelite distribution: (C) 1994 Gisle Hannemyr (C) 2000 Eric Busboom Copyright for snprintf: (C) 1997 Theo de Raadt Copyright for astime and caldate: (C) 1986-2000 Hiram Clawson Copyright for icalattach: (C) 2002 Andrea Campi Copyright for icaltimezone: (C) 2001 Damon Chaplin Copyright for icalarray: (C) 2001 Ximian Inc. astime and caldate license: Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. Neither name of The Museum of Hiram nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. snprintf license: Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. sspm license: Permission is granted to hack, make and distribute copies of this program as long as this copyright notice is not removed. libical license: The code and datafiles in this distribution are licensed under the Mozilla Public License. See http://www.mozilla.org/NPL/MPL-1.0.html for a copy of the license. Alternately, you may use libical under the terms of the GNU Library General Public License. See http://www.fsf.org/copyleft/lesser.html for a copy of the LGPL. This dual license ensures that the library can be incorporated into both proprietary code and GPL'd programs, and will benefit from improvements made by programmers in both realms. I will only accept changes into my version of the library if they are similarly dual-licensed. This program is free software; you can redistribute it and/or modify it under the terms of either: The LGPL as published by the Free Software Foundation, version 2.1, available at: http://www.fsf.org/copyleft/lesser.html Or: The Mozilla Public License Version 1.0. You may obtain a copy of the License at http://www.mozilla.org/MPL/ MPL 1.0 license: MOZILLA PUBLIC LICENSE Version 1.0 ---------------- 1. Definitions. 1.1. ``Contributor'' means each entity that creates or contributes to the creation of Modifications. 1.2. ``Contributor Version'' means the combination of the Original Code, prior Modifications used by a Contributor, and the Modifications made by that particular Contributor. 1.3. ``Covered Code'' means the Original Code or Modifications or the combination of the Original Code and Modifications, in each case including portions thereof. 1.4. ``Electronic Distribution Mechanism'' means a mechanism generally accepted in the software development community for the electronic transfer of data. 1.5. ``Executable'' means Covered Code in any form other than Source Code. 1.6. ``Initial Developer'' means the individual or entity identified as the Initial Developer in the Source Code notice required by Exhibit A. 1.7. ``Larger Work'' means a work which combines Covered Code or portions thereof with code not governed by the terms of this License. 1.8. ``License'' means this document. 1.9. ``Modifications'' means any addition to or deletion from the substance or structure of either the Original Code or any previous Modifications. When Covered Code is released as a series of files, a Modification is: A. Any addition to or deletion from the contents of a file containing Original Code or previous Modifications. B. Any new file that contains any part of the Original Code or previous Modifications. 1.10. ``Original Code'' means Source Code of computer software code which is described in the Source Code notice required by Exhibit A as Original Code, and which, at the time of its release under this License is not already Covered Code governed by this License. 1.11. ``Source Code'' means the preferred form of the Covered Code for making modifications to it, including all modules it contains, plus any associated interface definition files, scripts used to control compilation and installation of an Executable, or a list of source code differential comparisons against either the Original Code or another well known, available Covered Code of the Contributor's choice. The Source Code can be in a compressed or archival form, provided the appropriate decompression or de-archiving software is widely available for no charge. 1.12. ``You'' means an individual or a legal entity exercising rights under, and complying with all of the terms of, this License or a future version of this License issued under Section 6.1. For legal entities, ``You'' includes any entity which controls, is controlled by, or is under common control with You. For purposes of this definition, ``control'' means (a) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (b) ownership of fifty percent (50%) or more of the outstanding shares or beneficial ownership of such entity. 2. Source Code License. 2.1. The Initial Developer Grant. The Initial Developer hereby grants You a world-wide, royalty-free, non-exclusive license, subject to third party intellectual property claims: (a) to use, reproduce, modify, display, perform, sublicense and distribute the Original Code (or portions thereof) with or without Modifications, or as part of a Larger Work; and (b) under patents now or hereafter owned or controlled by Initial Developer, to make, have made, use and sell (``Utilize'') the Original Code (or portions thereof), but solely to the extent that any such patent is reasonably necessary to enable You to Utilize the Original Code (or portions thereof) and not to any greater extent that may be necessary to Utilize further Modifications or combinations. 2.2. Contributor Grant. Each Contributor hereby grants You a world-wide, royalty-free, non-exclusive license, subject to third party intellectual property claims: (a) to use, reproduce, modify, display, perform, sublicense and distribute the Modifications created by such Contributor (or portions thereof) either on an unmodified basis, with other Modifications, as Covered Code or as part of a Larger Work; and (b) under patents now or hereafter owned or controlled by Contributor, to Utilize the Contributor Version (or portions thereof), but solely to the extent that any such patent is reasonably necessary to enable You to Utilize the Contributor Version (or portions thereof), and not to any greater extent that may be necessary to Utilize further Modifications or combinations. 3. Distribution Obligations. 3.1. Application of License. The Modifications which You create or to which You contribute are governed by the terms of this License, including without limitation Section 2.2. The Source Code version of Covered Code may be distributed only under the terms of this License or a future version of this License released under Section 6.1, and You must include a copy of this License with every copy of the Source Code You distribute. You may not offer or impose any terms on any Source Code version that alters or restricts the applicable version of this License or the recipients' rights hereunder. However, You may include an additional document offering the additional rights described in Section 3.5. 3.2. Availability of Source Code. Any Modification which You create or to which You contribute must be made available in Source Code form under the terms of this License either on the same media as an Executable version or via an accepted Electronic Distribution Mechanism to anyone to whom you made an Executable version available; and if made available via Electronic Distribution Mechanism, must remain available for at least twelve (12) months after the date it initially became available, or at least six (6) months after a subsequent version of that particular Modification has been made available to such recipients. You are responsible for ensuring that the Source Code version remains available even if the Electronic Distribution Mechanism is maintained by a third party. 3.3. Description of Modifications. You must cause all Covered Code to which you contribute to contain a file documenting the changes You made to create that Covered Code and the date of any change. You must include a prominent statement that the Modification is derived, directly or indirectly, from Original Code provided by the Initial Developer and including the name of the Initial Developer in (a) the Source Code, and (b) in any notice in an Executable version or related documentation in which You describe the origin or ownership of the Covered Code. 3.4. Intellectual Property Matters (a) Third Party Claims. If You have knowledge that a party claims an intellectual property right in particular functionality or code (or its utilization under this License), you must include a text file with the source code distribution titled ``LEGAL'' which describes the claim and the party making the claim in sufficient detail that a recipient will know whom to contact. If you obtain such knowledge after You make Your Modification available as described in Section 3.2, You shall promptly modify the LEGAL file in all copies You make available thereafter and shall take other steps (such as notifying appropriate mailing lists or newsgroups) reasonably calculated to inform those who received the Covered Code that new knowledge has been obtained. (b) Contributor APIs. If Your Modification is an application programming interface and You own or control patents which are reasonably necessary to implement that API, you must also include this information in the LEGAL file. 3.5. Required Notices. You must duplicate the notice in Exhibit A in each file of the Source Code, and this License in any documentation for the Source Code, where You describe recipients' rights relating to Covered Code. If You created one or more Modification(s), You may add your name as a Contributor to the notice described in Exhibit A. If it is not possible to put such notice in a particular Source Code file due to its structure, then you must include such notice in a location (such as a relevant directory file) where a user would be likely to look for such a notice. You may choose to offer, and to charge a fee for, warranty, support, indemnity or liability obligations to one or more recipients of Covered Code. However, You may do so only on Your own behalf, and not on behalf of the Initial Developer or any Contributor. You must make it absolutely clear than any such warranty, support, indemnity or liability obligation is offered by You alone, and You hereby agree to indemnify the Initial Developer and every Contributor for any liability incurred by the Initial Developer or such Contributor as a result of warranty, support, indemnity or liability terms You offer. 3.6. Distribution of Executable Versions. You may distribute Covered Code in Executable form only if the requirements of Section 3.1-3.5 have been met for that Covered Code, and if You include a notice stating that the Source Code version of the Covered Code is available under the terms of this License, including a description of how and where You have fulfilled the obligations of Section 3.2. The notice must be conspicuously included in any notice in an Executable version, related documentation or collateral in which You describe recipients' rights relating to the Covered Code. You may distribute the Executable version of Covered Code under a license of Your choice, which may contain terms different from this License, provided that You are in compliance with the terms of this License and that the license for the Executable version does not attempt to limit or alter the recipient's rights in the Source Code version from the rights set forth in this License. If You distribute the Executable version under a different license You must make it absolutely clear that any terms which differ from this License are offered by You alone, not by the Initial Developer or any Contributor. You hereby agree to indemnify the Initial Developer and every Contributor for any liability incurred by the Initial Developer or such Contributor as a result of any such terms You offer. 3.7. Larger Works. You may create a Larger Work by combining Covered Code with other code not governed by the terms of this License and distribute the Larger Work as a single product. In such a case, You must make sure the requirements of this License are fulfilled for the Covered Code. 4. Inability to Comply Due to Statute or Regulation. If it is impossible for You to comply with any of the terms of this License with respect to some or all of the Covered Code due to statute or regulation then You must: (a) comply with the terms of this License to the maximum extent possible; and (b) describe the limitations and the code they affect. Such description must be included in the LEGAL file described in Section 3.4 and must be included with all distributions of the Source Code. Except to the extent prohibited by statute or regulation, such description must be sufficiently detailed for a recipient of ordinary skill to be able to understand it. 5. Application of this License. This License applies to code to which the Initial Developer has attached the notice in Exhibit A, and to related Covered Code. 6. Versions of the License. 6.1. New Versions. Netscape Communications Corporation (``Netscape'') may publish revised and/or new versions of the License from time to time. Each version will be given a distinguishing version number. 6.2. Effect of New Versions. Once Covered Code has been published under a particular version of the License, You may always continue to use it under the terms of that version. You may also choose to use such Covered Code under the terms of any subsequent version of the License published by Netscape. No one other than Netscape has the right to modify the terms applicable to Covered Code created under this License. 6.3. Derivative Works. If you create or use a modified version of this License (which you may only do in order to apply it to code which is not already Covered Code governed by this License), you must (a) rename Your license so that the phrases ``Mozilla'', ``MOZILLAPL'', ``MOZPL'', ``Netscape'', ``NPL'' or any confusingly similar phrase do not appear anywhere in your license and (b) otherwise make it clear that your version of the license contains terms which differ from the Mozilla Public License and Netscape Public License. (Filling in the name of the Initial Developer, Original Code or Contributor in the notice described in Exhibit A shall not of themselves be deemed to be modifications of this License.) 7. DISCLAIMER OF WARRANTY. COVERED CODE IS PROVIDED UNDER THIS LICENSE ON AN ``AS IS'' BASIS, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, WITHOUT LIMITATION, WARRANTIES THAT THE COVERED CODE IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE COVERED CODE IS WITH YOU. SHOULD ANY COVERED CODE PROVE DEFECTIVE IN ANY RESPECT, YOU (NOT THE INITIAL DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER OF WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS LICENSE. NO USE OF ANY COVERED CODE IS AUTHORIZED HEREUNDER EXCEPT UNDER THIS DISCLAIMER. 8. TERMINATION. This License and the rights granted hereunder will terminate automatically if You fail to comply with terms herein and fail to cure such breach within 30 days of becoming aware of the breach. All sublicenses to the Covered Code which are properly granted shall survive any termination of this License. Provisions which, by their nature, must remain in effect beyond the termination of this License shall survive. 9. LIMITATION OF LIABILITY. UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT (INCLUDING NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL THE INITIAL DEVELOPER, ANY OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF COVERED CODE, OR ANY SUPPLIER OF ANY OF SUCH PARTIES, BE LIABLE TO YOU OR ANY OTHER PERSON FOR ANY INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOSS OF GOODWILL, WORK STOPPAGE, COMPUTER FAILURE OR MALFUNCTION, OR ANY AND ALL OTHER COMMERCIAL DAMAGES OR LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN INFORMED OF THE POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF LIABILITY SHALL NOT APPLY TO LIABILITY FOR DEATH OR PERSONAL INJURY RESULTING FROM SUCH PARTY'S NEGLIGENCE TO THE EXTENT APPLICABLE LAW PROHIBITS SUCH LIMITATION. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THAT EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU. 10. U.S. GOVERNMENT END USERS. The Covered Code is a ``commercial item,'' as that term is defined in 48 C.F.R. 2.101 (Oct. 1995), consisting of ``commercial computer software'' and ``commercial computer software documentation,'' as such terms are used in 48 C.F.R. 12.212 (Sept. 1995). Consistent with 48 C.F.R. 12.212 and 48 C.F.R. 227.7202-1 through 227.7202-4 (June 1995), all U.S. Government End Users acquire Covered Code with only those rights set forth herein. 11. MISCELLANEOUS. This License represents the complete agreement concerning subject matter hereof. If any provision of this License is held to be unenforceable, such provision shall be reformed only to the extent necessary to make it enforceable. This License shall be governed by California law provisions (except to the extent applicable law, if any, provides otherwise), excluding its conflict-of-law provisions. With respect to disputes in which at least one party is a citizen of, or an entity chartered or registered to do business in, the United States of America: (a) unless otherwise agreed in writing, all disputes relating to this License (excepting any dispute relating to intellectual property rights) shall be subject to final and binding arbitration, with the losing party paying all costs of arbitration; (b) any arbitration relating to this Agreement shall be held in Santa Clara County, California, under the auspices of JAMS/EndDispute; and (c) any litigation relating to this Agreement shall be subject to the jurisdiction of the Federal Courts of the Northern District of California, with venue lying in Santa Clara County, California, with the losing party responsible for costs, including without limitation, court costs and reasonable attorneys fees and expenses. The application of the United Nations Convention on Contracts for the International Sale of Goods is expressly excluded. Any law or regulation which provides that the language of a contract shall be construed against the drafter shall not apply to this License. 12. RESPONSIBILITY FOR CLAIMS. Except in cases where another Contributor has failed to comply with Section 3.4, You are responsible for damages arising, directly or indirectly, out of Your utilization of rights under this License, based on the number of copies of Covered Code you made available, the revenues you received from utilizing such rights, and other relevant factors. You agree to work with affected parties to distribute responsibility on an equitable basis. EXHIBIT A. ``The contents of this file are subject to the Mozilla Public License Version 1.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.mozilla.org/MPL/ Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. The Original Code is ______________________________________. The Initial Developer of the Original Code is ________________________. Portions created by ______________________ are Copyright (C) ______ _______________________. All Rights Reserved. Contributor(s): ______________________________________.'' LGPL license: This package is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This package is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this package; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA On Debian systems, the complete text of the GNU Lesser General Public License can be found in `/usr/share/common-licenses/LGPL'. The Debian packaging is (C) 2006, Fathi Boudra and is licensed under the GPL, see `/usr/share/common-licenses/GPL'. libical-3.0.1/debian/docs000066400000000000000000000000211320431302500151710ustar00rootroot00000000000000NEWS README TODO libical-3.0.1/debian/libical-dev.install000066400000000000000000000002431320431302500200670ustar00rootroot00000000000000usr/include usr/lib/libical.a usr/lib/libical.so usr/lib/libicalss.a usr/lib/libicalss.so usr/lib/libicalvcal.a usr/lib/libicalvcal.so usr/lib/pkgconfig/libical.pclibical-3.0.1/debian/libical0.install000066400000000000000000000000221320431302500173660ustar00rootroot00000000000000usr/lib/lib*.so.* libical-3.0.1/debian/python-libical.install000066400000000000000000000000231320431302500206260ustar00rootroot00000000000000usr/lib/pymodules/*libical-3.0.1/debian/rules000066400000000000000000000116761320431302500154150ustar00rootroot00000000000000#!/usr/bin/make -f # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 # These are used for cross-compiling and for saving the configure script # from having to guess our platform (since we know it already) DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) CFLAGS = -Wall -g EXTRA_ARGS= PROFILE_ARGS= # To enable debugging: export DEB_BUILD_OPTIONS="debug profiling threadoff" ifneq (,$(findstring profiling,$(DEB_BUILD_OPTIONS))) PROFILE_ARGS= --with-gprof endif ifneq (,$(findstring backtrace,$(DEB_BUILD_OPTIONS))) EXTRA_ARGS=--with-backtrace BTCFLAGS=-rdynamic endif ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS))) CFLAGS += -O0 -ggdb -D_GNU_SOURCE -MD -MP -Wl,--as-needed -Wall -ansi else CFLAGS += -O2 endif # shared library versions, option 1 version=2.0.5 major=2 # option 2, assuming the library is created as src/.libs/libfoo.so.2.0.5 or so #version=`ls src/.libs/lib*.so.* | \ # awk '{if (match($$0,/[0-9]+\.[0-9]+\.[0-9]+$$/)) print substr($$0,RSTART)}'` #major=`ls src/.libs/lib*.so.* | \ # awk '{if (match($$0,/\.so\.[0-9]+$$/)) print substr($$0,RSTART+4)}'` PYVERS=$(shell pyversions -vr) build: build-c $(PYVERS:%=build-python%/build-stamp) install: build install-c $(PYVERS:%=install-python%) clean: clean-c $(PYVERS:%=clean-python%) ### Python libraries build rules ### build-python%/configure-stamp: dh_testdir mkdir build-python$* cd build-python$* && \ PYTHON=/usr/bin/python$* CFLAGS="$(BTCFLAGS) $(CFLAGS)" ../configure \ --host=$(DEB_HOST_GNU_TYPE) \ --build=$(DEB_BUILD_GNU_TYPE) \ --srcdir=.. \ --prefix=/usr \ --includedir="/usr/include" \ --mandir="/usr/share/man" \ --sysconfdir=/etc \ --localstatedir=/var \ $(EXTRA_ARGS) $(PROFILE_ARGS) \ --libexecdir="/usr/lib/libical" \ --enable-python touch $@ build-python%/build-stamp: build-c build-python%/configure-stamp dh_testdir # Trick into using already built build-c libs so we don't end up # building the same ical lib more than once. find "build-python$*/src" -maxdepth 1 -mindepth 1 | grep -v python$$ | xargs -r -t rm -rf find "build-c/src" -maxdepth 1 -mindepth 1 | grep -v python$$ | xargs -r -t -I{} ln -s "../../{}" "build-python$*/src" $(MAKE) -C build-python$*/src/python pyexecdir=/usr/lib/pymodules/python$* touch $@ install-python%: build-python%/build-stamp dh_testdir dh_testroot # dh_clean -k dh_installdirs # install with hack to move installed python libs to pymodule dir $(MAKE) -C build-python$*/src/python install pyexecdir=/usr/lib/pymodules/python$* DESTDIR=$(CURDIR)/debian/tmp && \ mv -i $(CURDIR)/debian/tmp/usr/lib/python$*/*/* $(CURDIR)/debian/tmp/usr/lib/pymodules/python$*/ clean-python%: # mkdir -p build-python$* && cd build-python$* dh_testdir # dh_testroot rm -rf build-python$* dh_prep ### C libraries build rules ### build-c/configure-stamp: configure #config.status: configure dh_testdir ifneq "$(wildcard /usr/share/misc/config.sub)" "" cp -f /usr/share/misc/config.sub config.sub endif ifneq "$(wildcard /usr/share/misc/config.guess)" "" cp -f /usr/share/misc/config.guess config.guess endif mkdir build-c cd build-c && \ CFLAGS="$(BTCFLAGS) $(CFLAGS)" ../configure \ --host=$(DEB_HOST_GNU_TYPE) \ --build=$(DEB_BUILD_GNU_TYPE) \ --prefix=/usr \ --includedir="/usr/include" \ --mandir="/usr/share/man" \ --sysconfdir=/etc \ --localstatedir=/var \ $(EXTRA_ARGS) $(PROFILE_ARGS) \ --libexecdir="/usr/lib/libical" touch $@ build-c: build-c/build-stamp build-c/build-stamp: build-c/configure-stamp dh_testdir # $(MAKE) clean $(MAKE) -C build-c touch $@ clean-c: dh_testdir dh_testroot rm -rf build-c dh_prep install-c: build-c dh_testdir dh_testroot dh_clean -k dh_installdirs $(MAKE) -C build-c DESTDIR=$(CURDIR)/debian/tmp install # Build architecture-independent files here. binary-indep: build install # We have nothing to do by default. # Build architecture-dependent files here. binary-arch: build install dh_testdir dh_testroot dh_installchangelogs ChangeLog dh_installdocs dh_installexamples dh_install -s --sourcedir=debian/tmp # dh_installmenu # dh_installdebconf # dh_installlogrotate # dh_installemacsen # dh_installpam # dh_installmime # dh_installinit # dh_installcron # dh_installinfo dh_installman dh_link dh_strip dh_compress dh_fixperms # dh_perl dh_pysupport # dh_makeshlibs dh_installdeb # dh_shlibdeps # We need to exclude dependency resolving for the python extension # module because if libical0 is installed but libical-dev is not # we get build errors. The lib in /usr/lib will be found first # but no .la will exist to get the dependency info from. Is there # a way to tell dh_shlibdeps to find the lib first in debian/tmp? dh_shlibdeps -XLibicalWrap # dh_shlibdeps -l$(CURDIR)/debian/tmp/usr/lib -- -v dh_gencontrol dh_md5sums dh_builddeb binary: binary-indep binary-arch .PHONY: build clean binary-indep binary-arch binary install libical-3.0.1/design-data/000077500000000000000000000000001320431302500152635ustar00rootroot00000000000000libical-3.0.1/design-data/CMakeLists.txt000066400000000000000000000000541320431302500200220ustar00rootroot00000000000000 ########### install files ############### libical-3.0.1/design-data/components.txt000066400000000000000000000004211320431302500202060ustar00rootroot00000000000000ANY VAGENDA VALARM VAVAILABILITY VCALENDAR VCAR VCOMMAND VEVENT VFREEBUSY VJOURNAL VQUERY VPATCH VPOLL VSCHEDULE VTIMEZONE VTODO VVOTER X XAUDIOALARM XAVAILABLE XDAYLIGHTSAVINGSTIME XDISPLAYALARM XEMAILALARM XLICINVALID XMIMEPART XPATCH XPROCEDUREALARM XSTANDARDTIME XVOTE libical-3.0.1/design-data/parameters.csv000066400000000000000000000102011320431302500201350ustar00rootroot00000000000000"#Name ","C icalparameter_kind Enum","C Type","Enumeration Values" "ALTREP","2","const char*", "CHARSET","3","const char*", "CN","4","const char*", "CUTYPE","5","icalparameter_cutype","X=20100;INDIVIDUAL;GROUP;RESOURCE;ROOM;UNKNOWN;NONE=20199" "DELEGATED-FROM","6","const char*", "DELEGATED-TO","7","const char*", "DIR","8","const char*", "ENCODING","10","icalparameter_encoding","X=20300;8BIT;BASE64;NONE=20399" "FBTYPE","11","icalparameter_fbtype","X=20400;FREE;BUSY;BUSY-UNAVAILABLE;BUSY-TENTATIVE;NONE=20499" "FMTTYPE","12","const char*", "LANGUAGE","14","const char*", "MEMBER","18","const char*", "#PARTSTAT:FAILED from draft-apthorp-ical-tasks",,, "PARTSTAT","20","icalparameter_partstat","X=20600;NEEDS-ACTION;ACCEPTED;DECLINED;TENTATIVE;DELEGATED;COMPLETED;INPROCESS;FAILED;NONE=20699" "RANGE","21","icalparameter_range","X=20700;THISANDPRIOR;THISANDFUTURE;NONE=20799" "RELATED","22","icalparameter_related","X=20800;START;END;NONE=20899" "RELTYPE","23","icalparameter_reltype","X=20900;PARENT;CHILD;SIBLING;POLL;NONE=20999" "ROLE","24","icalparameter_role","X=21100;CHAIR;REQ-PARTICIPANT;OPT-PARTICIPANT;NON-PARTICIPANT;NONE=21199" "RSVP","25","icalparameter_rsvp","X=21200;TRUE;FALSE;NONE=21299" "SENT-BY","26","const char*", "TZID","27","const char*", "VALUE","28","icalparameter_value","X=21600;BINARY;BOOLEAN;DATE;DURATION;FLOAT;INTEGER;PERIOD;RECUR;TEXT;URI;ERROR;DATE-TIME;UTC-OFFSET;CAL-ADDRESS;NONE=21699" "X","29","const char*", "X-LIC-ERRORTYPE","31","icalparameter_xlicerrortype","X=21800;COMPONENT-PARSE-ERROR;PROPERTY-PARSE-ERROR;PARAMETER-NAME-PARSE-ERROR;PARAMETER-VALUE-PARSE-ERROR;VALUE-PARSE-ERROR;INVALID-ITIP;UNKNOWN-VCAL-PROP-ERROR;MIME-PARSE-ERROR;VCAL-PROP-PARSE-ERROR;NONE=21899" "X-LIC-COMPARETYPE","30","icalparameter_xliccomparetype","X=21700;EQUAL;NOTEQUAL;LESS;GREATER;LESSEQUAL;GREATEREQUAL;REGEX;ISNULL;ISNOTNULL;NONE=21799" "#Parameters from Scheduling Extensions to CalDAV (RFC 6638)" "SCHEDULE-AGENT","34","icalparameter_scheduleagent","X=21300;SERVER;CLIENT;NONE=21399" "SCHEDULE-FORCE-SEND","35","icalparameter_scheduleforcesend","X=21400;REQUEST;REPLY;NONE=21499" "SCHEDULE-STATUS","36","const char*", "#CAP Parameters","Draft 8", "#this parameter should really be called ACTION, but this conflicts with the ACTION property" "ACTIONPARAM","1","icalparameter_action","X=20000;ASK;ABORT;NONE=20099" "ID","13","const char*", "ENABLE","9","icalparameter_enable","X=20200;TRUE;FALSE;NONE=20299" "LATENCY","15","const char*", "LOCAL","16","icalparameter_local","X=20500;TRUE;FALSE;NONE=20599" "LOCALIZE","17","const char*", "OPTIONS","19","const char*", "NO","32",, "#In practice any unknown paramater that is not an xparam is treated as an ianaparam" "IANA","33","const char*", "ANY","0",, "#VPOLL Parameters","draft-york-vpoll","PUBLIC-COMMENT and RESPONSE are deprecated" "PUBLIC-COMMENT","37","const char*", "RESPONSE","38","int", "REQUIRED","43","icalparameter_required","X=21000;TRUE;FALSE;NONE=21099" "STAY-INFORMED","39","icalparameter_stayinformed","X=21500;TRUE;FALSE;NONE=21599" "#CalDAV Managed Attachment Parameters","draft-ietf-calext-caldav-attachments" "MANAGED-ID","40","const char*", "SIZE","41","const char*", "FILENAME","42","const char*", "#Task Extension Parameters","draft-apthorp-ical-tasks" "REASON","43","const char*", "MODIFIED","44","const char*", "SUBSTATE","45","icalparameter_substate",X=21900;OK;ERROR;SUSPENDED;NONE=21999", "#Parameters from New Properties for iCalendar","RFC 7986 Section 6" "DISPLAY","46","icalparameter_display",X=22000;BADGE;GRAPHIC;FULLSIZE;THUMBNAIL;NONE=22099", "EMAIL","47","const char*", "FEATURE","48","icalparameter_feature",X=22100;AUDIO;CHAT;FEED;MODERATOR;PHONE;SCREEN;VIDEO;NONE=22199", "LABEL","49","const char*", "EMAIL","50","const char*", "#VPATCH Extension Parameters","draft-daboo-icalendar-vpatch" "PATCH-ACTION","51","icalparameter_patchaction",X=22200;CREATE;BYNAME;BYVALUE;BYPARAM;NONE=22299", "#NOTE for updaters. Preserve the icalparameter_kind Enum values to aid forward compatibility" "# New Enum values for an existing icalparameter_kind should be inserted before the corresponding NONE value" "# New icalparamter_kind types should start their Enum value after the highest NONE value (currently 22299)" libical-3.0.1/design-data/params-in-prop.txt000066400000000000000000000051741320431302500207000ustar00rootroot00000000000000ACKNOWLEDGED X ACTION VALUE X ATTACH FMTTYPE ENCODING VALUE MANAGED-ID SIZE FILENAME X ATTENDEE CN CUTYPE DELEGATED-FROM DELEGATED-TO DIR EMAIL LANGUAGE MEMBER MODIFIED PARTSTAT REASON ROLE RSVP SENT-BY SCHEDULE-AGENT SCHEDULE-FORCE-SEND SCHEDULE-STATUS SUBSTATE X CALSCALE X CATEGORIES LANGUAGE X CLASS X CMD ACTIONPARAM ID LATENCY LOCALIZE OPTIONS X COMMENT ALTREP LANGUAGE MODIFIED REASON X COMPLETED X CONTACT ALTREP LANGUAGE X CREATED X DESCRIPTION ALTREP LANGUAGE X DTEND VALUE TZID X DTSTAMP X DTSTART VALUE TZID X DUE VALUE TZID X DURATION X EXDATE VALUE TZID X EXRULE X FREEBUSY FBTYPE X GEO X LAST-MODIFIED X LOCATION ALTREP LANGUAGE X METHOD X ORGANIZER CN DIR EMAIL LANGUAGE SCHEDULE-AGENT SCHEDULE-FORCE-SEND SCHEDULE-STATUS SENT-BY X PERCENT-COMPLETE X PRIORITY X PRODID X RDATE VALUE TZID X RECURRENCE-ID VALUE RANGE TZID X RELATED-TO RELTYPE X REPEAT X REQUEST-STATUS LANGUAGE X RESOURCES ALTREP LANGUAGE X RRULE X SEQUENCE LOCAL X STATUS MODIFIED REASON SUBSTATE X SUMMARY ALTREP LANGUAGE X TRANSP X TRIGGER ENABLE VALUE RELATED X TZID X TZNAME LANGUAGE X TZOFFSETFROM X TZOFFSETTO X TZURL X UID X URL X VERSION X XPROP LANGUAGE X X-LIC-ERROR XLICEERRORTYPE X SCOPE X MAXRESULTS X MAXRESULTSSIZE X QUERY X QUERYNAME X TARGET X EXPAND X BUSYTYPE X ACCEPT-RESPONSE X POLL-COMPLETION X POLL-ITEM-ID X POLL-MODE X POLL-PROPERTIES X POLL-WINNER X REPLY-URL REQUIRED X RESPONSE X VOTER CN CUTYPE DELEGATED-FROM DELEGATED-TO DIR_EMAIL LANGUAGE MEMBER ROLE RSVP SCHEDULE-AGENT SCHEDULE-FORCE-SEND SCHEDULE-STATUS SENT-BY STAY-INFORMED X NAME ALTREP LANGUAGE X REFRESH-INTERVAL VALUE X SOURCE X COLOR X IMAGE ALTREP DISPLAY ENCODING FMTTYPE VALUE X CONFERENCE FEATURE LABEL VALUE X PATCH-VERSION X PATCH-ORDER X PATCH-TARGET X PATCH-DELETE X PATCH-PARAMETER ANY libical-3.0.1/design-data/properties.csv000066400000000000000000000126601320431302500202010ustar00rootroot00000000000000,, "#Property Name","C icalproperty_kind Enum","libical Value type","iCalendar default value",Property Flags "#iCalendar Properties","RFC 5545 Sections 3.7 and 3.8", "CALSCALE","8","TEXT","TEXT" "METHOD","48","METHOD","METHOD" "PRODID","57","TEXT","TEXT" "VERSION","89","TEXT","TEXT" "ATTACH","4","ATTACH","URI",is_structured "CATEGORIES","12","TEXT","TEXT",is_multivalued "CLASS","13","CLASS","CLASS" "COMMENT","15","TEXT","TEXT" "DESCRIPTION","29","TEXT","TEXT" "GEO","39","GEO","FLOAT",is_structured "LOCATION","43","TEXT","TEXT" "PERCENT-COMPLETE","54","INTEGER","INTEGER" "PRIORITY","56","INTEGER","INTEGER" "RESOURCES","71","TEXT","TEXT",is_multivalued "STATUS","76","STATUS","STATUS" "SUMMARY","78","TEXT","TEXT" "COMPLETED","16","DATE-TIME","DATE-TIME" "DTEND","30","DATE-TIME-DATE","DATE-TIME" "DUE","33","DATE-TIME-DATE","DATE-TIME" "DTSTART","32","DATE-TIME-DATE","DATE-TIME" "DURATION","34","DURATION","DURATION" "FREEBUSY","38","PERIOD","PERIOD",is_multivalued "TRANSP","80","TRANSP","TRANSP" "TZID","82","TEXT","TEXT" "TZNAME","83","TEXT","TEXT" "TZOFFSETFROM","84","UTC-OFFSET","UTC-OFFSET" "TZOFFSETTO","85","UTC-OFFSET","UTC-OFFSET" "TZURL","86","URI","URI" "ATTENDEE","5","CAL-ADDRESS","CAL-ADDRESS" "CONTACT","18","TEXT","TEXT" "ORGANIZER","52","CAL-ADDRESS","CAL-ADDRESS" "RECURRENCE-ID","66","DATE-TIME-DATE","DATE-TIME" "RELATED-TO","67","TEXT","TEXT" "URL","88","URI","URI" "UID","87","TEXT","TEXT" "EXDATE","35","DATE-TIME-DATE","DATE-TIME",is_multivalued "RDATE","62","DATE-TIME-PERIOD","DATE-TIME",is_multivalued "RRULE","73","RECUR","RECUR" "ACTION","2","ACTION","ACTION" "REPEAT","69","INTEGER","INTEGER" "TRIGGER","81","TRIGGER","DURATION" "CREATED","19","DATE-TIME","DATE-TIME" "DTSTAMP","31","DATE-TIME","DATE-TIME" "LAST-MODIFIED","42","DATE-TIME","DATE-TIME" "SEQUENCE","75","INTEGER","INTEGER" "REQUEST-STATUS","70","REQUEST-STATUS","REQUEST-STATUS" "X","90","X","X",is_multivalued "#Deprecated RFC 2445 Properties","See RFC 5545 Section A.3", "EXRULE","37","RECUR","RECUR" "#CAP Properties","RFC 4324 Section 2.1.2", ,"FIXME","Should be BOOLEAN" "ALLOW-CONFLICT","3","TEXT","TEXT" "CAP-VERSION","9","TEXT","TEXT" "CAR-LEVEL","10","CAR-LEVEL","CAR-LEVEL" "COMPONENTS","17","TEXT","TEXT" "CSID","20","URI","URI" "CALID","6","TEXT","TEXT" "CALMASTER","7","TEXT","TEXT" "CARID","11","TEXT","TEXT" "CMD","14","CMD","CMD" "DECREED","23","TEXT","TEXT" "DEFAULT-CHARSET","24","TEXT","TEXT" "DEFAULT-LOCALE","25","TEXT","TEXT" "DEFAULT-TZID","26","TEXT","TEXT" "DEFAULT-VCARS","27","TEXT","TEXT" ,"FIXME","Should be UPN-FILTER" "DENY","28","TEXT","TEXT" ,"FIXME","Should be BOOLEAN" "EXPAND","36","INTEGER","INTEGER" ,"FIXME","Should be UPN-FILTER" "GRANT","40","TEXT","TEXT" "ITIP-VERSION","41","TEXT","TEXT" "MAXDATE","45","DATE-TIME","DATE-TIME" "MAX-COMPONENT-SIZE","44","INTEGER","INTEGER" "MINDATE","49","DATE-TIME","DATE-TIME" "MULTIPART","50","TEXT","TEXT" "NAME","51","TEXT","TEXT" "OWNER","53","TEXT","TEXT" "PERMISSION","55","TEXT","TEXT" "QUERY","58","QUERY","QUERY" "QUERYID","60","TEXT","TEXT" "QUERY-LEVEL","59","QUERY-LEVEL","QUERY-LEVEL" "RECUR-ACCEPTED","63","TEXT","TEXT" "RECUR-EXPAND","64","TEXT","TEXT" "RECUR-LIMIT","65","TEXT","TEXT" "RESTRICTION","72","QUERY","QUERY" "SCOPE","74","TEXT","TEXT" "STORES-EXPANDED","77","TEXT","TEXT" "TARGET","79","CAL-ADDRESS","CAL-ADDRESS" "#Miscellaneous Properties","Origin Unknown", "MAXRESULTS","46","INTEGER","INTEGER" "MAXRESULTSSIZE","47","INTEGER","INTEGER" "QUERYNAME","61","TEXT","TEXT" "RELCALID","68","TEXT","TEXT" "DATE-MAX","21","DATE-TIME","DATE-TIME" "DATE-MIN","22","DATE-TIME","DATE-TIME" "#libical Internal Properties",, "X-LIC-ERROR","93","TEXT","TEXT" "X-LIC-CLUSTERCOUNT","92","STRING","STRING" "X-LIC-MIMECONTENTTYPE","96","STRING","STRING" "X-LIC-MIMECHARSET","94","STRING","STRING" "X-LIC-MIMEENCODING","97","STRING","STRING" "X-LIC-MIMEOPTINFO","99","STRING","STRING" "X-LIC-MIMECID","95","STRING","STRING" "X-LIC-MIMEFILENAME","98","STRING","STRING" "X-LIC-CLASS","91","X-LIC-CLASS","X-LIC-CLASS" "ANY","0","NO","NO" "NO","100","NO","NO" "#VALARM Extension Properties","draft-daboo-valarm-extensions Section 13.1", "ACKNOWLEDGED","1","DATE-TIME","DATE-TIME" "#VAVAILABILITY Properties","RFC 7953 Section 3.2", "BUSYTYPE","101","BUSYTYPE","BUSYTYPE" "#VPOLL Properties","draft-york-vpoll", "ACCEPT-RESPONSE","102","TEXT,"TEXT",is_multivalued "POLL-COMPLETION","110","POLLCOMPLETION,"POLLCOMPLETION" "POLL-ITEM-ID","103","INTEGER,"INTEGER" "POLL-MODE","104","POLLMODE,"POLLMODE" "POLL-PROPERTIES","105","TEXT,"TEXT",is_multivalued "POLL-WINNER","106","INTEGER,"INTEGER" "REPLY-URL","111","URI,"URI" "RESPONSE","112","INTEGER,"INTEGER" "VOTER","107","CAL-ADDRESS,"CAL-ADDRESS" "#TZdist Properties","RFC 7808 Section 7", "TZID-ALIAS-OF","108","TEXT","TEXT" "TZUNTIL","109","DATE-TIME","DATE-TIME" "#Task Extension Properties","draft-apthorp-ical-tasks", "ESTIMATED-DURATION","113","DURATION","DURATION" "TASK-MODE","114","TASKMODE","TASKMODE" "#New Properties for iCalendar","RFC 7986 Section 5", "NAME","115","TEXT","TEXT" "REFRESH-INTERVAL","116","DURATION","NO" "SOURCE","117","URI","NO" "COLOR","118","TEXT","TEXT" "IMAGE","119","ATTACH","NO",is_structured "CONFERENCE","120","URI","NO" "#VPATCH Extension Properties", "draft-daboo_icalendar-vpatch Section 4", "PATCH-VERSION","121","TEXT","TEXT" "PATCH-ORDER","122","INTEGER","INTEGER" "PATCH-TARGET","123","TEXT","TEXT" "PATCH-DELETE","124","TEXT","TEXT" "PATCH-PARAMETER","125","TEXT","TEXT" "#NOTE for updaters. Preserve the icalproperty_kind Enum values to aid forward compatibility" libical-3.0.1/design-data/restrictions.csv000066400000000000000000002075621320431302500205440ustar00rootroot00000000000000# Method, Target component, Property, Sub-component, Restriction PUBLISH,VEVENT,NONE,NONE,ONEPLUS PUBLISH,VEVENT,DTSTAMP,NONE,ONE PUBLISH,VEVENT,DTSTART,NONE,ONE PUBLISH,VEVENT,ORGANIZER,NONE,ONE PUBLISH,VEVENT,SUMMARY,NONE,ONE PUBLISH,VEVENT,UID,NONE,ONE PUBLISH,VEVENT,RECURRENCEID,NONE,ZEROORONE,must_be_recurring PUBLISH,VEVENT,SEQUENCE,NONE,ZEROORONE PUBLISH,VEVENT,ATTACH,NONE,ZEROPLUS PUBLISH,VEVENT,CATEGORIES,NONE,ZEROPLUS #Non-standard PUBLISH,VEVENT,CLASS,NONE,ZEROORONE PUBLISH,VEVENT,COMMENT,NONE,ZEROORONE PUBLISH,VEVENT,CONTACT,NONE,ZEROPLUS PUBLISH,VEVENT,CREATED,NONE,ZEROORONE PUBLISH,VEVENT,DESCRIPTION,NONE,ZEROORONE PUBLISH,VEVENT,DTEND,NONE,ONEEXCLUSIVE,no_duration PUBLISH,VEVENT,DURATION,NONE,ONEEXCLUSIVE,no_dtend PUBLISH,VEVENT,EXDATE,NONE,ZEROPLUS PUBLISH,VEVENT,EXRULE,NONE,ZEROPLUS PUBLISH,VEVENT,GEO,NONE,ZEROORONE PUBLISH,VEVENT,LASTMODIFIED,NONE,ZEROORONE PUBLISH,VEVENT,LOCATION,NONE,ZEROORONE PUBLISH,VEVENT,PRIORITY,NONE,ZEROORONE PUBLISH,VEVENT,RDATE,NONE,ZEROPLUS PUBLISH,VEVENT,RELATEDTO,NONE,ZEROPLUS PUBLISH,VEVENT,RESOURCES,NONE,ZEROORONE PUBLISH,VEVENT,RRULE,NONE,ZEROPLUS PUBLISH,VEVENT,STATUS,NONE,ZEROORONE,may_be_tent_conf_cancel PUBLISH,VEVENT,TRANSP,NONE,ZEROORONE PUBLISH,VEVENT,URL,NONE,ZEROORONE PUBLISH,VEVENT,X,NONE,ZEROPLUS PUBLISH,VEVENT,ATTENDEE,NONE,ZERO PUBLISH,VEVENT,REQUESTSTATUS,NONE,ZERO PUBLISH,VEVENT,COLOR,NONE,ZEROORONE PUBLISH,VEVENT,CONFERENCE,NONE,ZEROPLUS PUBLISH,VEVENT,IMAGE,NONE,ZEROPLUS PUBLISH,VEVENT,NONE,VALARM,ZEROPLUS PUBLISH,VEVENT,NONE,VFREEBUSY,ZERO PUBLISH,VEVENT,NONE,VJOURNAL,ZERO PUBLISH,VEVENT,NONE,VTODO,ZERO PUBLISH,VEVENT,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref PUBLISH,VEVENT,NONE,X,ZEROPLUS PUBLISH,VEVENT,RELCALID,NONE,ZEROORONE REQUEST,VEVENT,NONE,NONE,ONEPLUS REQUEST,VEVENT,ATTENDEE,NONE,ONEPLUS REQUEST,VEVENT,DTSTAMP,NONE,ONE REQUEST,VEVENT,DTSTART,NONE,ONE REQUEST,VEVENT,ORGANIZER,NONE,ONE REQUEST,VEVENT,SEQUENCE,NONE,ZEROORONE REQUEST,VEVENT,SUMMARY,NONE,ONE REQUEST,VEVENT,UID,NONE,ONE REQUEST,VEVENT,ATTACH,NONE,ZEROPLUS REQUEST,VEVENT,CATEGORIES,NONE,ZEROPLUS #Non-standard REQUEST,VEVENT,CLASS,NONE,ZEROORONE REQUEST,VEVENT,COMMENT,NONE,ZEROORONE REQUEST,VEVENT,CONTACT,NONE,ZEROPLUS REQUEST,VEVENT,CREATED,NONE,ZEROORONE REQUEST,VEVENT,DESCRIPTION,NONE,ZEROORONE REQUEST,VEVENT,DTEND,NONE,ONEEXCLUSIVE,no_duration REQUEST,VEVENT,DURATION,NONE,ONEEXCLUSIVE,no_dtend REQUEST,VEVENT,EXDATE,NONE,ZEROPLUS REQUEST,VEVENT,EXRULE,NONE,ZEROPLUS REQUEST,VEVENT,GEO,NONE,ZEROORONE REQUEST,VEVENT,LASTMODIFIED,NONE,ZEROORONE REQUEST,VEVENT,LOCATION,NONE,ZEROORONE REQUEST,VEVENT,PRIORITY,NONE,ZEROORONE REQUEST,VEVENT,RDATE,NONE,ZEROPLUS REQUEST,VEVENT,RECURRENCEID,NONE,ZEROORONE,must_be_recurring REQUEST,VEVENT,RELATEDTO,NONE,ZEROPLUS REQUEST,VEVENT,REQUESTSTATUS,NONE,ZEROPLUS REQUEST,VEVENT,RESOURCES,NONE,ZEROORONE REQUEST,VEVENT,RRULE,NONE,ZEROPLUS REQUEST,VEVENT,STATUS,NONE,ZEROORONE,may_be_tent_conf REQUEST,VEVENT,TRANSP,NONE,ZEROORONE REQUEST,VEVENT,URL,NONE,ZEROORONE REQUEST,VEVENT,X,NONE,ZEROPLUS REQUEST,VEVENT,COLOR,NONE,ZEROORONE REQUEST,VEVENT,CONFERENCE,NONE,ZEROPLUS REQUEST,VEVENT,IMAGE,NONE,ZEROPLUS REQUEST,VEVENT,NONE,VALARM,ZEROPLUS REQUEST,VEVENT,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref REQUEST,VEVENT,NONE,X,ZEROPLUS REQUEST,VEVENT,NONE,VFREEBUSY,ZERO REQUEST,VEVENT,NONE,VJOURNAL,ZERO REQUEST,VEVENT,NONE,VTODO,ZERO REQUEST,VEVENT,RELCALID,NONE,ZEROORONE REPLY,VEVENT,NONE,NONE,ONEPLUS REPLY,VEVENT,ATTENDEE,NONE,ONE REPLY,VEVENT,DTSTAMP,NONE,ONE REPLY,VEVENT,ORGANIZER,NONE,ONE REPLY,VEVENT,RECURRENCEID,NONE,ZEROORONE,must_be_recurring REPLY,VEVENT,UID,NONE,ONE REPLY,VEVENT,SEQUENCE,NONE,ZEROORONE REPLY,VEVENT,ATTACH,NONE,ZEROPLUS REPLY,VEVENT,CATEGORIES,NONE,ZEROPLUS #Non-standard REPLY,VEVENT,CLASS,NONE,ZEROORONE REPLY,VEVENT,COMMENT,NONE,ZEROORONE REPLY,VEVENT,CONTACT,NONE,ZEROPLUS REPLY,VEVENT,CREATED,NONE,ZEROORONE REPLY,VEVENT,DESCRIPTION,NONE,ZEROORONE REPLY,VEVENT,DTEND,NONE,ONEEXCLUSIVE,no_duration REPLY,VEVENT,DTSTART,NONE,ZEROORONE REPLY,VEVENT,DURATION,NONE,ONEEXCLUSIVE,no_dtend REPLY,VEVENT,EXDATE,NONE,ZEROPLUS REPLY,VEVENT,EXRULE,NONE,ZEROPLUS REPLY,VEVENT,GEO,NONE,ZEROORONE REPLY,VEVENT,LASTMODIFIED,NONE,ZEROORONE REPLY,VEVENT,LOCATION,NONE,ZEROORONE REPLY,VEVENT,PRIORITY,NONE,ZEROORONE REPLY,VEVENT,RDATE,NONE,ZEROPLUS REPLY,VEVENT,RELATEDTO,NONE,ZEROPLUS REPLY,VEVENT,RESOURCES,NONE,ZEROORONE REPLY,VEVENT,REQUESTSTATUS,NONE,ZEROPLUS REPLY,VEVENT,RRULE,NONE,ZEROPLUS REPLY,VEVENT,STATUS,NONE,ZEROORONE REPLY,VEVENT,SUMMARY,NONE,ZEROORONE REPLY,VEVENT,TRANSP,NONE,ZEROORONE REPLY,VEVENT,URL,NONE,ZEROORONE REPLY,VEVENT,X,NONE,ZEROPLUS REPLY,VEVENT,COLOR,NONE,ZEROORONE REPLY,VEVENT,CONFERENCE,NONE,ZEROPLUS REPLY,VEVENT,IMAGE,NONE,ZEROPLUS REPLY,VEVENT,NONE,VTIMEZONE,ZEROORONE,must_if_tz_ref REPLY,VEVENT,NONE,X,ZEROPLUS REPLY,VEVENT,NONE,VALARM,ZERO REPLY,VEVENT,NONE,VFREEBUSY,ZERO REPLY,VEVENT,NONE,VJOURNAL,ZERO REPLY,VEVENT,NONE,VTODO,ZERO REPLY,VEVENT,RELCALID,NONE,ZEROORONE ADD,VEVENT,NONE,NONE,ONE ADD,VEVENT,DTSTAMP,NONE,ONE ADD,VEVENT,DTSTART,NONE,ONE ADD,VEVENT,ORGANIZER,NONE,ONE ADD,VEVENT,SEQUENCE,NONE,ONE ADD,VEVENT,SUMMARY,NONE,ONE ADD,VEVENT,UID,NONE,ONE ADD,VEVENT,ATTACH,NONE,ZEROPLUS ADD,VEVENT,ATTENDEE,NONE,ZEROPLUS ADD,VEVENT,CATEGORIES,NONE,ZEROPLUS #Non-standard ADD,VEVENT,CLASS,NONE,ZEROORONE ADD,VEVENT,COMMENT,NONE,ZEROORONE ADD,VEVENT,CONTACT,NONE,ZEROPLUS ADD,VEVENT,CREATED,NONE,ZEROORONE ADD,VEVENT,DESCRIPTION,NONE,ZEROORONE ADD,VEVENT,DTEND,NONE,ONEEXCLUSIVE,no_duration ADD,VEVENT,DURATION,NONE,ONEEXCLUSIVE,no_dtend ADD,VEVENT,EXDATE,NONE,ZEROPLUS ADD,VEVENT,EXRULE,NONE,ZEROPLUS ADD,VEVENT,GEO,NONE,ZEROORONE ADD,VEVENT,LASTMODIFIED,NONE,ZEROORONE ADD,VEVENT,LOCATION,NONE,ZEROORONE ADD,VEVENT,PRIORITY,NONE,ZEROORONE ADD,VEVENT,RDATE,NONE,ZEROPLUS ADD,VEVENT,RELATEDTO,NONE,ZEROPLUS ADD,VEVENT,RESOURCES,NONE,ZEROORONE ADD,VEVENT,RRULE,NONE,ZEROPLUS ADD,VEVENT,STATUS,NONE,ZEROORONE,may_be_tent_conf ADD,VEVENT,TRANSP,NONE,ZEROORONE ADD,VEVENT,URL,NONE,ZEROORONE ADD,VEVENT,X,NONE,ZEROPLUS ADD,VEVENT,RECURRENCEID,NONE,ZERO,must_be_recurring ADD,VEVENT,REQUESTSTATUS,NONE,ZERO ADD,VEVENT,COLOR,NONE,ZEROORONE ADD,VEVENT,CONFERENCE,NONE,ZEROPLUS ADD,VEVENT,IMAGE,NONE,ZEROPLUS ADD,VEVENT,NONE,VALARM,ZEROPLUS ADD,VEVENT,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref ADD,VEVENT,NONE,X,ZEROPLUS ADD,VEVENT,NONE,VFREEBUSY,ZERO ADD,VEVENT,NONE,VTODO,ZERO ADD,VEVENT,NONE,VJOURNAL,ZERO ADD,VEVENT,RELCALID,NONE,ZEROORONE CANCEL,VEVENT,NONE,NONE,ONEPLUS CANCEL,VEVENT,ATTENDEE,NONE,ZEROPLUS CANCEL,VEVENT,DTSTAMP,NONE,ONE CANCEL,VEVENT,ORGANIZER,NONE,ONE CANCEL,VEVENT,SEQUENCE,NONE,ONE CANCEL,VEVENT,UID,NONE,ONE CANCEL,VEVENT,COMMENT,NONE,ZEROORONE CANCEL,VEVENT,ATTACH,NONE,ZEROPLUS CANCEL,VEVENT,CATEGORIES,NONE,ZEROPLUS #Non-standard CANCEL,VEVENT,CLASS,NONE,ZEROORONE CANCEL,VEVENT,CONTACT,NONE,ZEROPLUS CANCEL,VEVENT,CREATED,NONE,ZEROORONE CANCEL,VEVENT,DESCRIPTION,NONE,ZEROORONE CANCEL,VEVENT,DTEND,NONE,ONEEXCLUSIVE ,no_duration CANCEL,VEVENT,DTSTART,NONE,ZEROORONE CANCEL,VEVENT,DURATION,NONE,ONEEXCLUSIVE,no_dtend CANCEL,VEVENT,EXDATE,NONE,ZEROPLUS CANCEL,VEVENT,EXRULE,NONE,ZEROPLUS CANCEL,VEVENT,GEO,NONE,ZEROORONE CANCEL,VEVENT,LASTMODIFIED,NONE,ZEROORONE CANCEL,VEVENT,LOCATION,NONE,ZEROORONE CANCEL,VEVENT,PRIORITY,NONE,ZEROORONE CANCEL,VEVENT,RDATE,NONE,ZEROPLUS CANCEL,VEVENT,RECURRENCEID,NONE,ZEROORONE,must_be_recurring CANCEL,VEVENT,RELATEDTO,NONE,ZEROPLUS CANCEL,VEVENT,RESOURCES,NONE,ZEROORONE CANCEL,VEVENT,RRULE,NONE,ZEROPLUS CANCEL,VEVENT,STATUS,NONE,ZEROORONE,must_be_canceled_no_attendee CANCEL,VEVENT,SUMMARY,NONE,ZEROORONE CANCEL,VEVENT,TRANSP,NONE,ZEROORONE CANCEL,VEVENT,URL,NONE,ZEROORONE CANCEL,VEVENT,X,NONE,ZEROPLUS CANCEL,VEVENT,REQUESTSTATUS,NONE,ZERO CANCEL,VEVENT,COLOR,NONE,ZEROORONE CANCEL,VEVENT,CONFERENCE,NONE,ZEROPLUS CANCEL,VEVENT,IMAGE,NONE,ZEROPLUS CANCEL,VEVENT,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref CANCEL,VEVENT,NONE,X,ZEROPLUS CANCEL,VEVENT,NONE,VTODO,ZERO CANCEL,VEVENT,NONE,VJOURNAL,ZERO CANCEL,VEVENT,NONE,VFREEBUSY,ZERO CANCEL,VEVENT,NONE,VALARM,ZERO CANCEL,VEVENT,RELCALID,NONE,ZEROORONE REFRESH,VEVENT,NONE,NONE,ONE REFRESH,VEVENT,ATTENDEE,NONE,ONE REFRESH,VEVENT,DTSTAMP,NONE,ONE REFRESH,VEVENT,ORGANIZER,NONE,ONE REFRESH,VEVENT,UID,NONE,ONE REFRESH,VEVENT,COMMENT,NONE,ZEROORONE REFRESH,VEVENT,RECURRENCEID,NONE,ZEROORONE,must_be_recurring REFRESH,VEVENT,X,NONE,ZEROPLUS REFRESH,VEVENT,ATTACH,NONE,ZERO REFRESH,VEVENT,CATEGORIES,NONE,ZERO REFRESH,VEVENT,CLASS,NONE,ZERO REFRESH,VEVENT,CONTACT,NONE,ZERO REFRESH,VEVENT,CREATED,NONE,ZERO REFRESH,VEVENT,DESCRIPTION,NONE,ZERO REFRESH,VEVENT,DTEND,NONE,ZERO REFRESH,VEVENT,DTSTART,NONE,ZERO REFRESH,VEVENT,DURATION,NONE,ZERO REFRESH,VEVENT,EXDATE,NONE,ZERO REFRESH,VEVENT,EXRULE,NONE,ZERO REFRESH,VEVENT,GEO,NONE,ZERO REFRESH,VEVENT,LASTMODIFIED,NONE,ZERO REFRESH,VEVENT,LOCATION,NONE,ZERO REFRESH,VEVENT,PRIORITY,NONE,ZERO REFRESH,VEVENT,RDATE,NONE,ZERO REFRESH,VEVENT,RELATEDTO,NONE,ZERO REFRESH,VEVENT,REQUESTSTATUS,NONE,ZERO REFRESH,VEVENT,RESOURCES,NONE,ZERO REFRESH,VEVENT,RRULE,NONE,ZERO REFRESH,VEVENT,SEQUENCE,NONE,ZERO REFRESH,VEVENT,STATUS,NONE,ZERO REFRESH,VEVENT,SUMMARY,NONE,ZERO REFRESH,VEVENT,TRANSP,NONE,ZERO REFRESH,VEVENT,URL,NONE,ZERO REFRESH,VEVENT,COLOR,NONE,ZEROORONE REFRESH,VEVENT,CONFERENCE,NONE,ZEROPLUS REFRESH,VEVENT,IMAGE,NONE,ZEROPLUS REFRESH,VEVENT,NONE,X,ZEROPLUS REFRESH,VEVENT,NONE,VTODO,ZERO REFRESH,VEVENT,NONE,VJOURNAL,ZERO REFRESH,VEVENT,NONE,VFREEBUSY,ZERO REFRESH,VEVENT,NONE,VTIMEZONE,ZERO,must_if_tz_ref REFRESH,VEVENT,NONE,VALARM,ZERO REFRESH,VEVENT,RELCALID,NONE,ZEROORONE COUNTER,VEVENT,NONE,NONE,ONE COUNTER,VEVENT,DTSTAMP,NONE,ONE COUNTER,VEVENT,DTSTART,NONE,ONE COUNTER,VEVENT,ORGANIZER,NONE,ONE COUNTER,VEVENT,SEQUENCE,NONE,ONE COUNTER,VEVENT,SUMMARY,NONE,ONE COUNTER,VEVENT,UID,NONE,ONE COUNTER,VEVENT,ATTACH,NONE,ZEROPLUS COUNTER,VEVENT,ATTENDEE,NONE,ZEROPLUS COUNTER,VEVENT,CATEGORIES,NONE,ZEROPLUS #Non-standard COUNTER,VEVENT,CLASS,NONE,ZEROORONE COUNTER,VEVENT,COMMENT,NONE,ZEROORONE COUNTER,VEVENT,CONTACT,NONE,ZEROPLUS COUNTER,VEVENT,CREATED,NONE,ZEROORONE COUNTER,VEVENT,DESCRIPTION,NONE,ZEROORONE COUNTER,VEVENT,DTEND,NONE,ONEEXCLUSIVE,no_duration COUNTER,VEVENT,DURATION,NONE,ONEEXCLUSIVE,no_dtend COUNTER,VEVENT,EXDATE,NONE,ZEROPLUS COUNTER,VEVENT,EXRULE,NONE,ZEROPLUS COUNTER,VEVENT,GEO,NONE,ZEROORONE COUNTER,VEVENT,LASTMODIFIED,NONE,ZEROORONE COUNTER,VEVENT,LOCATION,NONE,ZEROORONE COUNTER,VEVENT,PRIORITY,NONE,ZEROORONE COUNTER,VEVENT,RDATE,NONE,ZEROPLUS COUNTER,VEVENT,RECURRENCEID,NONE,ZEROORONE,must_be_recurring COUNTER,VEVENT,RELATEDTO,NONE,ZEROPLUS COUNTER,VEVENT,REQUESTSTATUS,NONE,ZEROPLUS COUNTER,VEVENT,RESOURCES,NONE,ZEROORONE COUNTER,VEVENT,RRULE,NONE,ZEROPLUS COUNTER,VEVENT,STATUS,NONE,ZEROORONE,may_be_tent_conf_cancel COUNTER,VEVENT,TRANSP,NONE,ZEROORONE COUNTER,VEVENT,URL,NONE,ZEROORONE COUNTER,VEVENT,X,NONE,ZEROPLUS COUNTER,VEVENT,COLOR,NONE,ZEROORONE COUNTER,VEVENT,CONFERENCE,NONE,ZEROPLUS COUNTER,VEVENT,IMAGE,NONE,ZEROPLUS COUNTER,VEVENT,NONE,VALARM,ZEROPLUS COUNTER,VEVENT,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref COUNTER,VEVENT,NONE,X,ZEROPLUS COUNTER,VEVENT,NONE,VTODO,ZERO COUNTER,VEVENT,NONE,VJOURNAL,ZERO COUNTER,VEVENT,NONE,VFREEBUSY,ZERO COUNTER,VEVENT,RELCALID,NONE,ZEROORONE DECLINECOUNTER,VEVENT,NONE,NONE,ONE DECLINECOUNTER,VEVENT,DTSTAMP,NONE,ONE DECLINECOUNTER,VEVENT,ORGANIZER,NONE,ONE DECLINECOUNTER,VEVENT,UID,NONE,ONE DECLINECOUNTER,VEVENT,COMMENT,NONE,ZEROORONE DECLINECOUNTER,VEVENT,RECURRENCEID,NONE,ZEROORONE,must_be_recurring DECLINECOUNTER,VEVENT,REQUESTSTATUS,NONE,ZEROPLUS DECLINECOUNTER,VEVENT,SEQUENCE,NONE,ZERO DECLINECOUNTER,VEVENT,X,NONE,ZEROPLUS DECLINECOUNTER,VEVENT,ATTACH,NONE,ZERO DECLINECOUNTER,VEVENT,ATTENDEE,NONE,ZERO DECLINECOUNTER,VEVENT,CATEGORIES,NONE,ZERO DECLINECOUNTER,VEVENT,CLASS,NONE,ZERO DECLINECOUNTER,VEVENT,CONTACT,NONE,ZERO DECLINECOUNTER,VEVENT,CREATED,NONE,ZERO DECLINECOUNTER,VEVENT,DESCRIPTION,NONE,ZERO DECLINECOUNTER,VEVENT,DTEND,NONE,ZERO DECLINECOUNTER,VEVENT,DTSTART,NONE,ZERO DECLINECOUNTER,VEVENT,DURATION,NONE,ZERO DECLINECOUNTER,VEVENT,EXDATE,NONE,ZERO DECLINECOUNTER,VEVENT,EXRULE,NONE,ZERO DECLINECOUNTER,VEVENT,GEO,NONE,ZERO DECLINECOUNTER,VEVENT,LASTMODIFIED,NONE,ZERO DECLINECOUNTER,VEVENT,LOCATION,NONE,ZERO DECLINECOUNTER,VEVENT,PRIORITY,NONE,ZERO DECLINECOUNTER,VEVENT,RDATE,NONE,ZERO DECLINECOUNTER,VEVENT,RELATEDTO,NONE,ZERO DECLINECOUNTER,VEVENT,RESOURCES,NONE,ZERO DECLINECOUNTER,VEVENT,RRULE,NONE,ZERO DECLINECOUNTER,VEVENT,STATUS,NONE,ZERO DECLINECOUNTER,VEVENT,SUMMARY,NONE,ZERO DECLINECOUNTER,VEVENT,TRANSP,NONE,ZERO DECLINECOUNTER,VEVENT,URL,NONE,ZERO DECLINECOUNTER,VEVENT,COLOR,NONE,ZEROORONE DECLINECOUNTER,VEVENT,CONFERENCE,NONE,ZEROPLUS DECLINECOUNTER,VEVENT,IMAGE,NONE,ZEROPLUS DECLINECOUNTER,VEVENT,NONE,X,ZEROPLUS DECLINECOUNTER,VEVENT,NONE,VTODO,ZERO DECLINECOUNTER,VEVENT,NONE,VJOURNAL,ZERO DECLINECOUNTER,VEVENT,NONE,VFREEBUSY,ZERO DECLINECOUNTER,VEVENT,NONE,VTIMEZONE,ZERO,must_if_tz_ref DECLINECOUNTER,VEVENT,NONE,VALARM,ZERO DECLINECOUNTER,VEVENT,RELCALID,NONE,ZEROORONE PUBLISH,VFREEBUSY,NONE,NONE,ONEPLUS PUBLISH,VFREEBUSY,DTSTAMP,NONE,ONE PUBLISH,VFREEBUSY,DTSTART,NONE,ONE PUBLISH,VFREEBUSY,DTEND,NONE,ONE PUBLISH,VFREEBUSY,FREEBUSY,NONE,ZEROPLUS PUBLISH,VFREEBUSY,ORGANIZER,NONE,ONE PUBLISH,VFREEBUSY,COMMENT,NONE,ZEROPLUS PUBLISH,VFREEBUSY,CONTACT,NONE,ZEROORONE PUBLISH,VFREEBUSY,X,NONE,ZEROPLUS PUBLISH,VFREEBUSY,URL,NONE,ZEROORONE PUBLISH,VFREEBUSY,ATTENDEE,NONE,ZERO PUBLISH,VFREEBUSY,DURATION,NONE,ZERO PUBLISH,VFREEBUSY,REQUESTSTATUS,NONE,ZERO PUBLISH,VFREEBUSY,UID,NONE,ONE PUBLISH,VFREEBUSY,NONE,X,ZEROPLUS PUBLISH,VFREEBUSY,NONE,VEVENT,ZERO PUBLISH,VFREEBUSY,NONE,VTODO,ZERO PUBLISH,VFREEBUSY,NONE,VJOURNAL,ZERO PUBLISH,VFREEBUSY,NONE,VTIMEZONE,ZERO,must_if_tz_ref PUBLISH,VFREEBUSY,NONE,VALARM,ZERO REQUEST,VFREEBUSY,NONE,NONE,ONE REQUEST,VFREEBUSY,ATTENDEE,NONE,ONEPLUS REQUEST,VFREEBUSY,DTEND,NONE,ONE REQUEST,VFREEBUSY,DTSTAMP,NONE,ONE REQUEST,VFREEBUSY,DTSTART,NONE,ONE REQUEST,VFREEBUSY,ORGANIZER,NONE,ONE REQUEST,VFREEBUSY,UID,NONE,ONE REQUEST,VFREEBUSY,COMMENT,NONE,ZEROPLUS REQUEST,VFREEBUSY,CONTACT,NONE,ZEROORONE REQUEST,VFREEBUSY,X,NONE,ZEROPLUS REQUEST,VFREEBUSY,FREEBUSY,NONE,ZERO REQUEST,VFREEBUSY,DURATION,NONE,ZERO REQUEST,VFREEBUSY,REQUESTSTATUS,NONE,ZERO REQUEST,VFREEBUSY,URL,NONE,ZERO REQUEST,VFREEBUSY,NONE,X,ZEROPLUS REQUEST,VFREEBUSY,NONE,VALARM,ZERO REQUEST,VFREEBUSY,NONE,VEVENT,ZERO REQUEST,VFREEBUSY,NONE,VTODO,ZERO REQUEST,VFREEBUSY,NONE,VJOURNAL,ZERO REQUEST,VFREEBUSY,NONE,VTIMEZONE,ZERO REPLY,VFREEBUSY,NONE,NONE,ONE REPLY,VFREEBUSY,ATTENDEE,NONE,ONE REPLY,VFREEBUSY,DTSTAMP,NONE,ONE REPLY,VFREEBUSY,DTEND,NONE,ONE REPLY,VFREEBUSY,DTSTART,NONE,ONE REPLY,VFREEBUSY,FREEBUSY,NONE,ZEROPLUS REPLY,VFREEBUSY,ORGANIZER,NONE,ONE REPLY,VFREEBUSY,UID,NONE,ONE REPLY,VFREEBUSY,COMMENT,NONE,ZEROPLUS REPLY,VFREEBUSY,CONTACT,NONE,ZEROORONE REPLY,VFREEBUSY,REQUESTSTATUS,NONE,ZEROPLUS REPLY,VFREEBUSY,URL,NONE,ZEROORONE REPLY,VFREEBUSY,X,NONE,ZEROPLUS REPLY,VFREEBUSY,DURATION,NONE,ZERO REPLY,VFREEBUSY,SEQUENCE,NONE,ZERO REPLY,VFREEBUSY,NONE,X,ZEROPLUS REPLY,VFREEBUSY,NONE,VALARM,ZERO REPLY,VFREEBUSY,NONE,VEVENT,ZERO REPLY,VFREEBUSY,NONE,VTODO,ZERO REPLY,VFREEBUSY,NONE,VJOURNAL,ZERO REPLY,VFREEBUSY,NONE,VTIMEZONE,ZERO PUBLISH,VTODO,NONE,NONE,ONEPLUS PUBLISH,VTODO,DTSTAMP,NONE,ONE PUBLISH,VTODO,DTSTART,NONE,ONE PUBLISH,VTODO,ORGANIZER,NONE,ONE PUBLISH,VTODO,PRIORITY,NONE,ONE PUBLISH,VTODO,SEQUENCE,NONE,ZEROORONE PUBLISH,VTODO,SUMMARY,NONE,ONE PUBLISH,VTODO,UID,NONE,ONE PUBLISH,VTODO,ATTACH,NONE,ZEROPLUS PUBLISH,VTODO,CATEGORIES,NONE,ZEROPLUS #Non-Standard PUBLISH,VTODO,CLASS,NONE,ZEROORONE PUBLISH,VTODO,COMMENT,NONE,ZEROORONE PUBLISH,VTODO,CONTACT,NONE,ZEROPLUS PUBLISH,VTODO,CREATED,NONE,ZEROORONE PUBLISH,VTODO,DESCRIPTION,NONE,ZEROORONE PUBLISH,VTODO,DUE,NONE,ZEROORONE PUBLISH,VTODO,DURATION,NONE,ZEROORONE PUBLISH,VTODO,EXDATE,NONE,ZEROPLUS PUBLISH,VTODO,EXRULE,NONE,ZEROPLUS PUBLISH,VTODO,GEO,NONE,ZEROORONE PUBLISH,VTODO,LASTMODIFIED,NONE,ZEROORONE PUBLISH,VTODO,LOCATION,NONE,ZEROORONE PUBLISH,VTODO,PERCENTCOMPLETE,NONE,ZEROORONE PUBLISH,VTODO,RDATE,NONE,ZEROPLUS PUBLISH,VTODO,RECURRENCEID,NONE,ZEROORONE,must_be_recurring PUBLISH,VTODO,RELATEDTO,NONE,ZEROPLUS PUBLISH,VTODO,RESOURCES,NONE,ZEROORONE PUBLISH,VTODO,RRULE,NONE,ZEROPLUS PUBLISH,VTODO,STATUS,NONE,ZEROORONE PUBLISH,VTODO,URL,NONE,ZEROORONE PUBLISH,VTODO,X,NONE,ZEROPLUS PUBLISH,VTODO,ATTENDEE,NONE,ZERO PUBLISH,VTODO,REQUESTSTATUS,NONE,ZERO PUBLISH,VTODO,COLOR,NONE,ZEROORONE PUBLISH,VTODO,CONFERENCE,NONE,ZEROPLUS PUBLISH,VTODO,IMAGE,NONE,ZEROPLUS PUBLISH,VTODO,NONE,VTIMEZONE,ZEROPLUS PUBLISH,VTODO,NONE,VALARM,ZEROPLUS PUBLISH,VTODO,NONE,X,ZEROPLUS PUBLISH,VTODO,NONE,VFREEBUSY,ZERO PUBLISH,VTODO,NONE,VEVENT,ZERO PUBLISH,VTODO,NONE,VJOURNAL,ZERO PUBLISH,VTODO,RELCALID,NONE,ZEROORONE REQUEST,VTODO,NONE,NONE,ONEPLUS REQUEST,VTODO,ATTENDEE,NONE,ONEPLUS REQUEST,VTODO,DTSTAMP,NONE,ONE REQUEST,VTODO,DTSTART,NONE,ONE REQUEST,VTODO,ORGANIZER,NONE,ONE REQUEST,VTODO,PRIORITY,NONE,ONE REQUEST,VTODO,SEQUENCE,NONE,ZEROORONE REQUEST,VTODO,SUMMARY,NONE,ONE REQUEST,VTODO,UID,NONE,ONE REQUEST,VTODO,ATTACH,NONE,ZEROPLUS REQUEST,VTODO,CATEGORIES,NONE,ZEROPLUS #Non-Standard REQUEST,VTODO,CLASS,NONE,ZEROORONE REQUEST,VTODO,COMMENT,NONE,ZEROORONE REQUEST,VTODO,CONTACT,NONE,ZEROPLUS REQUEST,VTODO,CREATED,NONE,ZEROORONE REQUEST,VTODO,DESCRIPTION,NONE,ZEROORONE REQUEST,VTODO,DUE,NONE,ZEROORONE REQUEST,VTODO,DURATION,NONE,ZEROORONE REQUEST,VTODO,EXDATE,NONE,ZEROPLUS REQUEST,VTODO,EXRULE,NONE,ZEROPLUS REQUEST,VTODO,GEO,NONE,ZEROORONE REQUEST,VTODO,LASTMODIFIED,NONE,ZEROORONE REQUEST,VTODO,LOCATION,NONE,ZEROORONE REQUEST,VTODO,PERCENTCOMPLETE,NONE,ZEROORONE REQUEST,VTODO,RDATE,NONE,ZEROPLUS REQUEST,VTODO,RECURRENCEID,NONE,ZEROORONE,must_be_recurring REQUEST,VTODO,RELATEDTO,NONE,ZEROPLUS REQUEST,VTODO,RESOURCES,NONE,ZEROORONE REQUEST,VTODO,RRULE,NONE,ZEROPLUS REQUEST,VTODO,STATUS,NONE,ZEROORONE,may_be_comp_need_process REQUEST,VTODO,URL,NONE,ZEROORONE REQUEST,VTODO,X,NONE,ZEROPLUS REQUEST,VTODO,REQUESTSTATUS,NONE,ZERO REQUEST,VTODO,COLOR,NONE,ZEROORONE REQUEST,VTODO,CONFERENCE,NONE,ZEROPLUS REQUEST,VTODO,IMAGE,NONE,ZEROPLUS REQUEST,VTODO,NONE,VALARM,ZEROPLUS REQUEST,VTODO,NONE,VTIMEZONE,ZEROPLUS REQUEST,VTODO,NONE,X,ZEROPLUS REQUEST,VTODO,NONE,VEVENT,ZERO REQUEST,VTODO,NONE,VFREEBUSY,ZERO REQUEST,VTODO,NONE,VJOURNAL,ZERO REQUEST,VTODO,RELCALID,NONE,ZEROORONE REPLY,VTODO,NONE,NONE,ONEPLUS REPLY,VTODO,ATTENDEE,NONE,ONEPLUS REPLY,VTODO,DTSTAMP,NONE,ONE REPLY,VTODO,ORGANIZER,NONE,ONE REPLY,VTODO,REQUESTSTATUS,NONE,ONEPLUS REPLY,VTODO,UID,NONE,ONE REPLY,VTODO,ATTACH,NONE,ZEROPLUS REPLY,VTODO,CATEGORIES,NONE,ZEROPLUS #Non-Standard REPLY,VTODO,CLASS,NONE,ZEROORONE REPLY,VTODO,COMMENT,NONE,ZEROORONE REPLY,VTODO,CONTACT,NONE,ZEROPLUS REPLY,VTODO,CREATED,NONE,ZEROORONE REPLY,VTODO,DESCRIPTION,NONE,ZEROORONE REPLY,VTODO,DTSTART,NONE,ZEROORONE REPLY,VTODO,DUE,NONE,ZEROORONE REPLY,VTODO,DURATION,NONE,ZEROORONE REPLY,VTODO,EXDATE,NONE,ZEROPLUS REPLY,VTODO,EXRULE,NONE,ZEROPLUS REPLY,VTODO,GEO,NONE,ZEROORONE REPLY,VTODO,LASTMODIFIED,NONE,ZEROORONE REPLY,VTODO,LOCATION,NONE,ZEROORONE REPLY,VTODO,PERCENTCOMPLETE,NONE,ZEROORONE REPLY,VTODO,PRIORITY,NONE,ZEROORONE REPLY,VTODO,RDATE,NONE,ZEROPLUS REPLY,VTODO,RELATEDTO,NONE,ZEROPLUS REPLY,VTODO,RESOURCES,NONE,ZEROORONE REPLY,VTODO,RRULE,NONE,ZEROPLUS REPLY,VTODO,RECURRENCEID,NONE,ZEROORONE,must_be_recurring REPLY,VTODO,SEQUENCE,NONE,ZEROORONE REPLY,VTODO,STATUS,NONE,ZEROORONE REPLY,VTODO,SUMMARY,NONE,ZEROORONE REPLY,VTODO,URL,NONE,ZEROORONE REPLY,VTODO,X,NONE,ZEROPLUS REPLY,VTODO,COLOR,NONE,ZEROORONE REPLY,VTODO,CONFERENCE,NONE,ZEROPLUS REPLY,VTODO,IMAGE,NONE,ZEROPLUS REPLY,VTODO,NONE,VTIMEZONE,ZEROORONE REPLY,VTODO,NONE,X,ZEROPLUS REPLY,VTODO,NONE,VALARM,ZERO REPLY,VTODO,NONE,VEVENT,ZERO REPLY,VTODO,NONE,VFREEBUSY,ZERO REPLY,VTODO,RELCALID,NONE,ZEROORONE ADD,VTODO,NONE,NONE,ONE ADD,VTODO,DTSTAMP,NONE,ONE ADD,VTODO,ORGANIZER,NONE,ONE ADD,VTODO,PRIORITY,NONE,ONE ADD,VTODO,SEQUENCE,NONE,ONE ADD,VTODO,SUMMARY,NONE,ONE ADD,VTODO,UID,NONE,ONE ADD,VTODO,ATTACH,NONE,ZEROPLUS ADD,VTODO,ATTENDEE,NONE,ZEROPLUS ADD,VTODO,CATEGORIES,NONE,ZEROPLUS ADD,VTODO,CLASS,NONE,ZEROORONE ADD,VTODO,COMMENT,NONE,ZEROORONE ADD,VTODO,CONTACT,NONE,ZEROPLUS ADD,VTODO,CREATED,NONE,ZEROORONE ADD,VTODO,DESCRIPTION,NONE,ZEROORONE ADD,VTODO,DTSTART,NONE,ZEROORONE ADD,VTODO,DUE,NONE,ZEROORONE ADD,VTODO,DURATION,NONE,ZEROORONE ADD,VTODO,EXDATE,NONE,ZEROPLUS ADD,VTODO,EXRULE,NONE,ZEROPLUS ADD,VTODO,GEO,NONE,ZEROORONE ADD,VTODO,LASTMODIFIED,NONE,ZEROORONE ADD,VTODO,LOCATION,NONE,ZEROORONE ADD,VTODO,PERCENTCOMPLETE,NONE,ZEROORONE ADD,VTODO,RDATE,NONE,ZEROPLUS ADD,VTODO,RELATEDTO,NONE,ZEROPLUS ADD,VTODO,RESOURCES,NONE,ZEROORONE ADD,VTODO,RRULE,NONE,ZEROPLUS ADD,VTODO,STATUS,NONE,ZEROORONE,may_be_comp_need_process ADD,VTODO,URL,NONE,ZEROORONE ADD,VTODO,X,NONE,ZEROPLUS ADD,VTODO,RECURRENCEID,NONE,ZERO,must_be_recurring ADD,VTODO,REQUESTSTATUS,NONE,ZERO ADD,VTODO,COLOR,NONE,ZEROORONE ADD,VTODO,CONFERENCE,NONE,ZEROPLUS ADD,VTODO,IMAGE,NONE,ZEROPLUS ADD,VTODO,NONE,VALARM,ZEROPLUS ADD,VTODO,NONE,VTIMEZONE,ZEROPLUS ADD,VTODO,NONE,X,ZEROPLUS ADD,VTODO,NONE,VEVENT,ZERO ADD,VTODO,NONE,VJOURNAL,ZERO ADD,VTODO,NONE,VFREEBUSY,ZERO ADD,VTODO,RELCALID,NONE,ZEROORONE CANCEL,VTODO,NONE,NONE,ONE CANCEL,VTODO,ATTENDEE,NONE,ZEROPLUS CANCEL,VTODO,UID,NONE,ONE CANCEL,VTODO,DTSTAMP,NONE,ONE CANCEL,VTODO,ORGANIZER,NONE,ONE CANCEL,VTODO,SEQUENCE,NONE,ONE CANCEL,VTODO,ATTACH,NONE,ZEROPLUS CANCEL,VTODO,CATEGORIES,NONE,ZEROPLUS #Non-Standard CANCEL,VTODO,CLASS,NONE,ZEROORONE CANCEL,VTODO,COMMENT,NONE,ZEROORONE CANCEL,VTODO,CONTACT,NONE,ZEROPLUS CANCEL,VTODO,CREATED,NONE,ZEROORONE CANCEL,VTODO,DESCRIPTION,NONE,ZEROORONE CANCEL,VTODO,DTSTART,NONE,ZEROORONE CANCEL,VTODO,DUE,NONE,ZEROORONE CANCEL,VTODO,DURATION,NONE,ZEROORONE CANCEL,VTODO,EXDATE,NONE,ZEROPLUS CANCEL,VTODO,EXRULE,NONE,ZEROPLUS CANCEL,VTODO,GEO,NONE,ZEROORONE CANCEL,VTODO,LASTMODIFIED,NONE,ZEROORONE CANCEL,VTODO,LOCATION,NONE,ZEROORONE CANCEL,VTODO,PERCENTCOMPLETE,NONE,ZEROORONE CANCEL,VTODO,RDATE,NONE,ZEROPLUS CANCEL,VTODO,RECURRENCEID,NONE,ZEROORONE,must_be_recurring CANCEL,VTODO,RELATEDTO,NONE,ZEROPLUS CANCEL,VTODO,RESOURCES,NONE,ZEROORONE CANCEL,VTODO,RRULE,NONE,ZEROPLUS CANCEL,VTODO,PRIORITY,NONE,ZEROORONE CANCEL,VTODO,STATUS,NONE,ZEROORONE,must_be_canceled_no_attendee CANCEL,VTODO,URL,NONE,ZEROORONE CANCEL,VTODO,X,NONE,ZEROPLUS CANCEL,VTODO,REQUESTSTATUS,NONE,ZERO CANCEL,VTODO,COLOR,NONE,ZEROORONE CANCEL,VTODO,CONFERENCE,NONE,ZEROPLUS CANCEL,VTODO,IMAGE,NONE,ZEROPLUS CANCEL,VTODO,NONE,VTIMEZONE,ZEROORONE CANCEL,VTODO,NONE,X,ZEROPLUS CANCEL,VTODO,NONE,VALARM,ZERO CANCEL,VTODO,NONE,VEVENT,ZERO CANCEL,VTODO,NONE,VFREEBUSY,ZERO CANCEL,VTODO,RELCALID,NONE,ZEROORONE REFRESH,VTODO,NONE,NONE,ONE REFRESH,VTODO,ATTENDEE,NONE,ONE REFRESH,VTODO,DTSTAMP,NONE,ONE REFRESH,VTODO,UID,NONE,ONE REFRESH,VTODO,RECURRENCEID,NONE,ZEROORONE,must_be_recurring REFRESH,VTODO,X,NONE,ZEROPLUS REFRESH,VTODO,ATTACH,NONE,ZERO REFRESH,VTODO,CATEGORIES,NONE,ZERO REFRESH,VTODO,CLASS,NONE,ZERO REFRESH,VTODO,COMMENT,NONE,ZERO REFRESH,VTODO,CONTACT,NONE,ZERO REFRESH,VTODO,CREATED,NONE,ZERO REFRESH,VTODO,DESCRIPTION,NONE,ZERO REFRESH,VTODO,DTSTART,NONE,ZERO REFRESH,VTODO,DUE,NONE,ZERO REFRESH,VTODO,DURATION,NONE,ZERO REFRESH,VTODO,EXDATE,NONE,ZERO REFRESH,VTODO,EXRULE,NONE,ZERO REFRESH,VTODO,GEO,NONE,ZERO REFRESH,VTODO,LASTMODIFIED,NONE,ZERO REFRESH,VTODO,LOCATION,NONE,ZERO REFRESH,VTODO,ORGANIZER,NONE,ZERO REFRESH,VTODO,PERCENTCOMPLETE,NONE,ZERO REFRESH,VTODO,PRIORITY,NONE,ZERO REFRESH,VTODO,RDATE,NONE,ZERO REFRESH,VTODO,RELATEDTO,NONE,ZERO REFRESH,VTODO,REQUESTSTATUS,NONE,ZERO REFRESH,VTODO,RESOURCES,NONE,ZERO REFRESH,VTODO,RRULE,NONE,ZERO REFRESH,VTODO,SEQUENCE,NONE,ZERO REFRESH,VTODO,STATUS,NONE,ZERO REFRESH,VTODO,URL,NONE,ZERO REFRESH,VTODO,COLOR,NONE,ZEROORONE REFRESH,VTODO,CONFERENCE,NONE,ZEROPLUS REFRESH,VTODO,IMAGE,NONE,ZEROPLUS REFRESH,VTODO,NONE,X,ZEROPLUS REFRESH,VTODO,NONE,VALARM,ZERO REFRESH,VTODO,NONE,VEVENT,ZERO REFRESH,VTODO,NONE,VFREEBUSY,ZERO REFRESH,VTODO,NONE,VTIMEZONE,ZERO REFRESH,VTODO,RELCALID,NONE,ZEROORONE COUNTER,VTODO,NONE,NONE,ONE COUNTER,VTODO,ATTENDEE,NONE,ONEPLUS COUNTER,VTODO,DTSTAMP,NONE,ONE COUNTER,VTODO,ORGANIZER,NONE,ONE COUNTER,VTODO,PRIORITY,NONE,ONE COUNTER,VTODO,SUMMARY,NONE,ONE COUNTER,VTODO,UID,NONE,ONE COUNTER,VTODO,ATTACH,NONE,ZEROPLUS COUNTER,VTODO,CATEGORIES,NONE,ZEROPLUS #Non-standard COUNTER,VTODO,CLASS,NONE,ZEROORONE COUNTER,VTODO,COMMENT,NONE,ZEROORONE COUNTER,VTODO,CONTACT,NONE,ZEROPLUS COUNTER,VTODO,CREATED,NONE,ZEROORONE COUNTER,VTODO,DESCRIPTION,NONE,ZEROORONE COUNTER,VTODO,DTSTART,NONE,ZEROORONE COUNTER,VTODO,DUE,NONE,ZEROORONE COUNTER,VTODO,DURATION,NONE,ZEROORONE COUNTER,VTODO,EXDATE,NONE,ZEROPLUS COUNTER,VTODO,EXRULE,NONE,ZEROPLUS COUNTER,VTODO,GEO,NONE,ZEROORONE COUNTER,VTODO,LASTMODIFIED,NONE,ZEROORONE COUNTER,VTODO,LOCATION,NONE,ZEROORONE COUNTER,VTODO,PERCENTCOMPLETE,NONE,ZEROORONE COUNTER,VTODO,RDATE,NONE,ZEROPLUS COUNTER,VTODO,RECURRENCEID,NONE,ZEROORONE,must_be_recurring COUNTER,VTODO,RELATEDTO,NONE,ZEROPLUS COUNTER,VTODO,REQUESTSTATUS,NONE,ZEROPLUS COUNTER,VTODO,RESOURCES,NONE,ZEROORONE COUNTER,VTODO,RRULE,NONE,ZEROORONE COUNTER,VTODO,SEQUENCE,NONE,ZEROORONE COUNTER,VTODO,STATUS,NONE,ZEROORONE,may_be_comp_need_process COUNTER,VTODO,URL,NONE,ZEROORONE COUNTER,VTODO,X,NONE,ZEROPLUS COUNTER,VTODO,COLOR,NONE,ZEROORONE COUNTER,VTODO,CONFERENCE,NONE,ZEROPLUS COUNTER,VTODO,IMAGE,NONE,ZEROPLUS COUNTER,VTODO,NONE,VALARM,ZEROPLUS COUNTER,VTODO,NONE,VTIMEZONE,ZEROORONE COUNTER,VTODO,NONE,X,ZEROPLUS COUNTER,VTODO,NONE,VEVENT,ZERO COUNTER,VTODO,NONE,VFREEBUSY,ZERO COUNTER,VTODO,RELCALID,NONE,ZEROORONE DECLINECOUNTER,VTODO,NONE,NONE,ONE DECLINECOUNTER,VTODO,ATTENDEE,NONE,ONEPLUS DECLINECOUNTER,VTODO,DTSTAMP,NONE,ONE DECLINECOUNTER,VTODO,ORGANIZER,NONE,ONE DECLINECOUNTER,VTODO,SEQUENCE,NONE,ONE DECLINECOUNTER,VTODO,UID,NONE,ONE DECLINECOUNTER,VTODO,ATTACH,NONE,ZEROPLUS DECLINECOUNTER,VTODO,CATEGORIES,NONE,ZEROPLUS #Non-standard DECLINECOUNTER,VTODO,CLASS,NONE,ZEROORONE DECLINECOUNTER,VTODO,COMMENT,NONE,ZEROORONE DECLINECOUNTER,VTODO,CONTACT,NONE,ZEROPLUS DECLINECOUNTER,VTODO,CREATED,NONE,ZEROORONE DECLINECOUNTER,VTODO,DESCRIPTION,NONE,ZEROORONE DECLINECOUNTER,VTODO,DTSTART,NONE,ZEROORONE DECLINECOUNTER,VTODO,DUE,NONE,ZEROORONE DECLINECOUNTER,VTODO,DURATION,NONE,ZEROORONE DECLINECOUNTER,VTODO,EXDATE,NONE,ZEROPLUS DECLINECOUNTER,VTODO,EXRULE,NONE,ZEROPLUS DECLINECOUNTER,VTODO,GEO,NONE,ZEROORONE DECLINECOUNTER,VTODO,LASTMODIFIED,NONE,ZEROORONE DECLINECOUNTER,VTODO,LOCATION,NONE,ZEROORONE DECLINECOUNTER,VTODO,PERCENTCOMPLETE,NONE,ZEROORONE DECLINECOUNTER,VTODO,PRIORITY,NONE,ZEROORONE DECLINECOUNTER,VTODO,RDATE,NONE,ZEROPLUS DECLINECOUNTER,VTODO,RECURRENCEID,NONE,ZEROORONE,must_be_recurring DECLINECOUNTER,VTODO,RELATEDTO,NONE,ZEROPLUS DECLINECOUNTER,VTODO,REQUESTSTATUS,NONE,ZEROPLUS DECLINECOUNTER,VTODO,RESOURCES,NONE,ZEROORONE DECLINECOUNTER,VTODO,RRULE,NONE,ZEROPLUS DECLINECOUNTER,VTODO,STATUS,NONE,ZEROORONE DECLINECOUNTER,VTODO,URL,NONE,ZEROORONE DECLINECOUNTER,VTODO,X,NONE,ZEROPLUS DECLINECOUNTER,VTODO,COLOR,NONE,ZEROORONE DECLINECOUNTER,VTODO,CONFERENCE,NONE,ZEROPLUS DECLINECOUNTER,VTODO,IMAGE,NONE,ZEROPLUS DECLINECOUNTER,VTODO,NONE,VTIMEZONE,ZEROPLUS DECLINECOUNTER,VTODO,NONE,X,ZEROPLUS DECLINECOUNTER,VTODO,NONE,VALARM,ZERO DECLINECOUNTER,VTODO,NONE,VEVENT,ZERO DECLINECOUNTER,VTODO,NONE,VFREEBUSY,ZERO DECLINECOUNTER,VTODO,RELCALID,NONE,ZEROORONE PUBLISH,VJOURNAL,NONE,NONE,ONEPLUS PUBLISH,VJOURNAL,DESCRIPTION,NONE,ONE PUBLISH,VJOURNAL,DTSTAMP,NONE,ONE PUBLISH,VJOURNAL,DTSTART,NONE,ONE PUBLISH,VJOURNAL,ORGANIZER,NONE,ONE PUBLISH,VJOURNAL,UID,NONE,ONE PUBLISH,VJOURNAL,ATTACH,NONE,ZEROPLUS PUBLISH,VJOURNAL,CATEGORIES,NONE,ZEROPLUS #Non-standard PUBLISH,VJOURNAL,CLASS,NONE,ZEROORONE PUBLISH,VJOURNAL,COMMENT,NONE,ZEROORONE PUBLISH,VJOURNAL,CONTACT,NONE,ZEROPLUS PUBLISH,VJOURNAL,CREATED,NONE,ZEROORONE PUBLISH,VJOURNAL,EXDATE,NONE,ZEROPLUS PUBLISH,VJOURNAL,EXRULE,NONE,ZEROPLUS PUBLISH,VJOURNAL,LASTMODIFIED,NONE,ZEROORONE PUBLISH,VJOURNAL,RDATE,NONE,ZEROPLUS PUBLISH,VJOURNAL,RECURRENCEID,NONE,ZEROORONE,must_be_recurring PUBLISH,VJOURNAL,RELATEDTO,NONE,ZEROPLUS PUBLISH,VJOURNAL,RRULE,NONE,ZEROPLUS PUBLISH,VJOURNAL,SEQUENCE,NONE,ZEROORONE PUBLISH,VJOURNAL,STATUS,NONE,ZEROORONE,may_be_draft_final_canceled PUBLISH,VJOURNAL,SUMMARY,NONE,ZEROORONE PUBLISH,VJOURNAL,URL,NONE,ZEROORONE PUBLISH,VJOURNAL,X,NONE,ZEROPLUS PUBLISH,VJOURNAL,ATTENDEE,NONE,ZERO PUBLISH,VJOURNAL,COLOR,NONE,ZEROORONE PUBLISH,VJOURNAL,IMAGE,NONE,ZEROPLUS PUBLISH,VJOURNAL,NONE,VALARM,ZEROPLUS PUBLISH,VJOURNAL,NONE,VTIMEZONE,ZEROPLUS PUBLISH,VJOURNAL,NONE,X,ZEROPLUS PUBLISH,VJOURNAL,NONE,VEVENT,ZERO PUBLISH,VJOURNAL,NONE,VFREEBUSY,ZERO PUBLISH,VJOURNAL,NONE,VTODO,ZERO ADD,VJOURNAL,NONE,NONE,ONE ADD,VJOURNAL,DESCRIPTION,NONE,ONE ADD,VJOURNAL,DTSTAMP,NONE,ONE ADD,VJOURNAL,DTSTART,NONE,ONE ADD,VJOURNAL,ORGANIZER,NONE,ONE ADD,VJOURNAL,SEQUENCE,NONE,ONE ADD,VJOURNAL,UID,NONE,ONE ADD,VJOURNAL,ATTACH,NONE,ZEROPLUS ADD,VJOURNAL,CATEGORIES,NONE,ZEROPLUS #Non-standard ADD,VJOURNAL,CLASS,NONE,ZEROORONE ADD,VJOURNAL,COMMENT,NONE,ZEROORONE ADD,VJOURNAL,CONTACT,NONE,ZEROPLUS ADD,VJOURNAL,CREATED,NONE,ZEROORONE ADD,VJOURNAL,EXDATE,NONE,ZEROPLUS ADD,VJOURNAL,EXRULE,NONE,ZEROPLUS ADD,VJOURNAL,LASTMODIFIED,NONE,ZEROORONE ADD,VJOURNAL,RDATE,NONE,ZEROPLUS ADD,VJOURNAL,RELATEDTO,NONE,ZEROPLUS ADD,VJOURNAL,RRULE,NONE,ZEROPLUS ADD,VJOURNAL,STATUS,NONE,ZEROORONE ADD,VJOURNAL,SUMMARY,NONE,ZEROORONE ADD,VJOURNAL,URL,NONE,ZEROORONE ADD,VJOURNAL,X,NONE,ZEROPLUS ADD,VJOURNAL,ATTENDEE,NONE,ZERO ADD,VJOURNAL,RECURRENCEID,NONE,ZERO ADD,VJOURNAL,COLOR,NONE,ZEROORONE ADD,VJOURNAL,IMAGE,NONE,ZEROPLUS ADD,VJOURNAL,NONE,VALARM,ZEROPLUS ADD,VJOURNAL,NONE,VTIMEZONE,ZEROORONE ADD,VJOURNAL,NONE,X,ZEROPLUS ADD,VJOURNAL,NONE,VEVENT,ZERO ADD,VJOURNAL,NONE,VFREEBUSY,ZERO ADD,VJOURNAL,NONE,VTODO,ZERO CANCEL,VJOURNAL,NONE,NONE,ONEPLUS CANCEL,VJOURNAL,DTSTAMP,NONE,ONE CANCEL,VJOURNAL,ORGANIZER,NONE,ONE CANCEL,VJOURNAL,SEQUENCE,NONE,ONE CANCEL,VJOURNAL,UID,NONE,ONE CANCEL,VJOURNAL,ATTACH,NONE,ZEROPLUS CANCEL,VJOURNAL,ATTENDEE,NONE,ZEROPLUS CANCEL,VJOURNAL,CATEGORIES,NONE,ZEROPLUS #Non-standard CANCEL,VJOURNAL,CLASS,NONE,ZEROORONE CANCEL,VJOURNAL,COMMENT,NONE,ZEROORONE CANCEL,VJOURNAL,CONTACT,NONE,ZEROPLUS CANCEL,VJOURNAL,CREATED,NONE,ZEROORONE CANCEL,VJOURNAL,DESCRIPTION,NONE,ZEROORONE CANCEL,VJOURNAL,DTSTART,NONE,ZEROORONE CANCEL,VJOURNAL,EXDATE,NONE,ZEROPLUS CANCEL,VJOURNAL,EXRULE,NONE,ZEROPLUS CANCEL,VJOURNAL,LASTMODIFIED,NONE,ZEROORONE CANCEL,VJOURNAL,RDATE,NONE,ZEROPLUS CANCEL,VJOURNAL,RECURRENCEID,NONE,ZEROORONE,must_be_recurring CANCEL,VJOURNAL,RELATEDTO,NONE,ZEROPLUS CANCEL,VJOURNAL,RRULE,NONE,ZEROPLUS CANCEL,VJOURNAL,STATUS,NONE,ZEROORONE,must_be_cancel_if_present CANCEL,VJOURNAL,SUMMARY,NONE,ZEROORONE CANCEL,VJOURNAL,URL,NONE,ZEROORONE CANCEL,VJOURNAL,X,NONE,ZEROPLUS CANCEL,VJOURNAL,REQUESTSTATUS,NONE,ZERO CANCEL,VJOURNAL,COLOR,NONE,ZEROORONE CANCEL,VJOURNAL,IMAGE,NONE,ZEROPLUS CANCEL,VJOURNAL,NONE,VTIMEZONE,ZEROPLUS CANCEL,VJOURNAL,NONE,X,ZEROPLUS CANCEL,VJOURNAL,NONE,VALARM,ZERO CANCEL,VJOURNAL,NONE,VEVENT,ZERO CANCEL,VJOURNAL,NONE,VFREEBUSY,ZERO CANCEL,VJOURNAL,NONE,VTODO,ZERO PUBLISH,VAGENDA,NONE,NONE,ONEPLUS PUBLISH,VAGENDA,CALMASTER,NONE,ONE PUBLISH,VAGENDA,OWNER,NONE,ZEROORONE PUBLISH,VAGENDA,RELCALID,NONE,ZEROORONE PUBLISH,VAGENDA,TZID,NONE,ONE REQUEST,VAGENDA,NONE,NONE,ONEPLUS REQUEST,VAGENDA,CALMASTER,NONE,ONE REQUEST,VAGENDA,OWNER,NONE,ZEROORONE REQUEST,VAGENDA,RELCALID,NONE,ZEROORONE REQUEST,VAGENDA,TZID,NONE,ONE REPLY,VAGENDA,NONE,NONE,ONEPLUS REPLY,VAGENDA,CALMASTER,NONE,ONE REPLY,VAGENDA,OWNER,NONE,ZEROORONE REPLY,VAGENDA,RELCALID,NONE,ZEROORONE REPLY,VAGENDA,TZID,NONE,ONE ADD,VAGENDA,NONE,NONE,ONEPLUS ADD,VAGENDA,CALMASTER,NONE,ONE ADD,VAGENDA,OWNER,NONE,ZEROORONE ADD,VAGENDA,RELCALID,NONE,ZEROORONE ADD,VAGENDA,TZID,NONE,ONE CANCEL,VAGENDA,NONE,NONE,ONEPLUS CANCEL,VAGENDA,CALMASTER,NONE,ONE CANCEL,VAGENDA,OWNER,NONE,ZEROORONE CANCEL,VAGENDA,RELCALID,NONE,ZEROORONE CANCEL,VAGENDA,TZID,NONE,ONE REFRESH,VAGENDA,NONE,NONE,ONEPLUS REFRESH,VAGENDA,CALMASTER,NONE,ONE REFRESH,VAGENDA,OWNER,NONE,ZEROORONE REFRESH,VAGENDA,RELCALID,NONE,ZEROORONE REFRESH,VAGENDA,TZID,NONE,ONE COUNTER,VAGENDA,NONE,NONE,ONEPLUS COUNTER,VAGENDA,CALMASTER,NONE,ONE COUNTER,VAGENDA,OWNER,NONE,ZEROORONE COUNTER,VAGENDA,RELCALID,NONE,ZEROORONE COUNTER,VAGENDA,TZID,NONE,ONE DECLINECOUNTER,VAGENDA,NONE,NONE,ONEPLUS DECLINECOUNTER,VAGENDA,CALMASTER,NONE,ONE DECLINECOUNTER,VAGENDA,OWNER,NONE,ZEROORONE DECLINECOUNTER,VAGENDA,RELCALID,NONE,ZEROORONE DECLINECOUNTER,VAGENDA,TZID,NONE,ONE NONE,VAGENDA,ALLOWCONFLICT,NONE,ONE NONE,VAGENDA,CALMASTER,NONE,ONE NONE,VAGENDA,OWNER,NONE,ZEROORONE NONE,VAGENDA,RELCALID,NONE,ZEROORONE NONE,VAGENDA,TZID,NONE,ONE NONE,VAGENDA,DEFAULTCHARSET,NONE,ONE NONE,VAGENDA,DEFAULTLOCALE,NONE,ONE NONE,VAGENDA,DEFAULTTZID,NONE,ONE NONE,VCALENDAR,ACTION,NONE,ZERO NONE,VCALENDAR,ATTACH,NONE,ZERO NONE,VCALENDAR,ATTENDEE,NONE,ZERO NONE,VCALENDAR,RELCALID,NONE,ZEROORONE NONE,VCALENDAR,CALSCALE,NONE,ZEROORONE NONE,VCALENDAR,CATEGORIES,NONE,ZEROPLUS NONE,VCALENDAR,CLASS,NONE,ZERO NONE,VCALENDAR,COMMENT,NONE,ZERO NONE,VCALENDAR,COMPLETED,NONE,ZERO NONE,VCALENDAR,CONTACT,NONE,ZERO NONE,VCALENDAR,CREATED,NONE,ZERO NONE,VCALENDAR,DESCRIPTION,NONE,ZEROPLUS NONE,VCALENDAR,DTEND,NONE,ZERO NONE,VCALENDAR,DTSTAMP,NONE,ZERO NONE,VCALENDAR,DTSTART,NONE,ZERO NONE,VCALENDAR,DUE,NONE,ZERO NONE,VCALENDAR,DURATION,NONE,ZERO NONE,VCALENDAR,EXDATE,NONE,ZERO NONE,VCALENDAR,EXRULE,NONE,ZERO NONE,VCALENDAR,FREEBUSY,NONE,ZERO NONE,VCALENDAR,GEO,NONE,ZERO NONE,VCALENDAR,LASTMODIFIED,NONE,ZEROORONE NONE,VCALENDAR,LOCATION,NONE,ZERO NONE,VCALENDAR,METHOD,NONE,ZEROORONE NONE,VCALENDAR,ORGANIZER,NONE,ZERO NONE,VCALENDAR,PERCENTCOMPLETE,NONE,ZERO NONE,VCALENDAR,PRIORITY,NONE,ZERO NONE,VCALENDAR,PRODID,NONE,ONE NONE,VCALENDAR,RDATE,NONE,ZERO NONE,VCALENDAR,RECURRENCEID,NONE,ZERO NONE,VCALENDAR,RELATEDTO,NONE,ZERO NONE,VCALENDAR,REPEAT,NONE,ZERO NONE,VCALENDAR,REQUESTSTATUS,NONE,ZERO NONE,VCALENDAR,RESOURCES,NONE,ZERO NONE,VCALENDAR,RRULE,NONE,ZERO NONE,VCALENDAR,SEQUENCE,NONE,ZERO NONE,VCALENDAR,STATUS,NONE,ZERO NONE,VCALENDAR,SUMMARY,NONE,ZERO NONE,VCALENDAR,TRANSP,NONE,ZERO NONE,VCALENDAR,TRIGGER,NONE,ZERO NONE,VCALENDAR,TZID,NONE,ZERO NONE,VCALENDAR,TZNAME,NONE,ZERO NONE,VCALENDAR,TZOFFSETFROM,NONE,ZERO NONE,VCALENDAR,TZOFFSETTO,NONE,ZERO NONE,VCALENDAR,TZURL,NONE,ZERO NONE,VCALENDAR,UID,NONE,ZEROORONE NONE,VCALENDAR,URL,NONE,ZEROORONE NONE,VCALENDAR,VERSION,NONE,ONE NONE,VCALENDAR,X,NONE,ZEROPLUS NONE,VCALENDAR,COLOR,NONE,ZEROORONE NONE,VCALENDAR,REFRESHINTERVAL,NONE,ZEROORONE NONE,VCALENDAR,SOURCE,NONE,ZEROORONE NONE,VCALENDAR,IMAGE,NONE,ZEROPLUS NONE,VCALENDAR,NAME,NONE,ZEROPLUS NONE,VEVENT,ACTION,NONE,ZERO NONE,VEVENT,ATTACH,NONE,ZEROPLUS NONE,VEVENT,ATTENDEE,NONE,ZEROPLUS NONE,VEVENT,CALSCALE,NONE,ZERO NONE,VEVENT,CATEGORIES,NONE,ZEROPLUS NONE,VEVENT,CLASS,NONE,ZEROORONE NONE,VEVENT,COMMENT,NONE,ZEROPLUS NONE,VEVENT,COMPLETED,NONE,ZERO NONE,VEVENT,CONTACT,NONE,ZEROPLUS NONE,VEVENT,CREATED,NONE,ZEROORONE NONE,VEVENT,DESCRIPTION,NONE,ZEROORONE NONE,VEVENT,DTEND,NONE,ONEEXCLUSIVE,no_duration NONE,VEVENT,DTSTAMP,NONE,ZEROORONE NONE,VEVENT,DTSTART,NONE,ZEROORONE NONE,VEVENT,DUE,NONE,ZERO NONE,VEVENT,DURATION,NONE,ONEEXCLUSIVE,no_dtend NONE,VEVENT,EXDATE,NONE,ZEROPLUS NONE,VEVENT,EXRULE,NONE,ZEROPLUS NONE,VEVENT,FREEBUSY,NONE,ZERO NONE,VEVENT,GEO,NONE,ZEROORONE NONE,VEVENT,LASTMODIFIED,NONE,ZEROORONE NONE,VEVENT,LOCATION,NONE,ZEROORONE NONE,VEVENT,METHOD,NONE,ZERO NONE,VEVENT,ORGANIZER,NONE,ZEROORONE NONE,VEVENT,PERCENTCOMPLETE,NONE,ZERO NONE,VEVENT,PRIORITY,NONE,ZEROORONE NONE,VEVENT,PRODID,NONE,ZERO NONE,VEVENT,RDATE,NONE,ZEROPLUS NONE,VEVENT,RECURRENCEID,NONE,ZEROORONE,must_be_recurring NONE,VEVENT,RELATEDTO,NONE,ZEROPLUS NONE,VEVENT,REPEAT,NONE,ZERO NONE,VEVENT,REQUESTSTATUS,NONE,ZEROPLUS NONE,VEVENT,RESOURCES,NONE,ZEROPLUS NONE,VEVENT,RRULE,NONE,ZEROPLUS NONE,VEVENT,SEQUENCE,NONE,ZEROORONE NONE,VEVENT,STATUS,NONE,ZEROORONE NONE,VEVENT,SUMMARY,NONE,ZEROORONE NONE,VEVENT,TRANSP,NONE,ZEROORONE NONE,VEVENT,TRIGGER,NONE,ZERO NONE,VEVENT,TZID,NONE,ZERO NONE,VEVENT,TZNAME,NONE,ZERO NONE,VEVENT,TZOFFSETFROM,NONE,ZERO NONE,VEVENT,TZOFFSETTO,NONE,ZERO NONE,VEVENT,TZURL,NONE,ZERO NONE,VEVENT,UID,NONE,ZEROORONE NONE,VEVENT,URL,NONE,ZEROORONE NONE,VEVENT,VERSION,NONE,ZERO NONE,VEVENT,X,NONE,ZEROPLUS NONE,VEVENT,RELCALID,NONE,ZEROORONE NONE,VEVENT,COLOR,NONE,ZEROORONE NONE,VEVENT,CONFERENCE,NONE,ZEROPLUS NONE,VEVENT,IMAGE,NONE,ZEROPLUS NONE,VTODO,ACTION,NONE,ZERO NONE,VTODO,ATTACH,NONE,ZEROPLUS NONE,VTODO,ATTENDEE,NONE,ZEROPLUS NONE,VTODO,CALSCALE,NONE,ZERO NONE,VTODO,CATEGORIES,NONE,ZEROPLUS NONE,VTODO,CLASS,NONE,ZEROORONE NONE,VTODO,COMMENT,NONE,ZEROPLUS NONE,VTODO,COMPLETED,NONE,ZEROORONE NONE,VTODO,CONTACT,NONE,ZEROPLUS NONE,VTODO,CREATED,NONE,ZEROORONE NONE,VTODO,DESCRIPTION,NONE,ZEROORONE NONE,VTODO,DTEND,NONE,ZERO NONE,VTODO,DTSTAMP,NONE,ZEROORONE NONE,VTODO,DTSTART,NONE,ZEROORONE NONE,VTODO,DUE,NONE,ONEEXCLUSIVE NONE,VTODO,DURATION,NONE,ONEEXCLUSIVE NONE,VTODO,EXDATE,NONE,ZEROPLUS NONE,VTODO,EXRULE,NONE,ZEROPLUS NONE,VTODO,FREEBUSY,NONE,ZERO NONE,VTODO,GEO,NONE,ZEROORONE NONE,VTODO,LASTMODIFIED,NONE,ZEROORONE NONE,VTODO,LOCATION,NONE,ZEROORONE NONE,VTODO,METHOD,NONE,ZERO NONE,VTODO,ORGANIZER,NONE,ZEROORONE NONE,VTODO,PERCENTCOMPLETE,NONE,ZEROORONE NONE,VTODO,PRIORITY,NONE,ZEROORONE NONE,VTODO,PRODID,NONE,ZERO NONE,VTODO,RDATE,NONE,ZEROPLUS NONE,VTODO,RECURRENCEID,NONE,ZEROORONE,must_be_recurring NONE,VTODO,RELATEDTO,NONE,ZEROPLUS NONE,VTODO,REPEAT,NONE,ZERO NONE,VTODO,REQUESTSTATUS,NONE,ZEROPLUS NONE,VTODO,RESOURCES,NONE,ZEROPLUS NONE,VTODO,RRULE,NONE,ZEROPLUS NONE,VTODO,SEQUENCE,NONE,ZEROORONE NONE,VTODO,STATUS,NONE,ZEROORONE NONE,VTODO,SUMMARY,NONE,ZEROORONE NONE,VTODO,TRANSP,NONE,ZERO NONE,VTODO,TRIGGER,NONE,ZERO NONE,VTODO,TZID,NONE,ZERO NONE,VTODO,TZNAME,NONE,ZERO NONE,VTODO,TZOFFSETFROM,NONE,ZERO NONE,VTODO,TZOFFSETTO,NONE,ZERO NONE,VTODO,TZURL,NONE,ZERO NONE,VTODO,UID,NONE,ZEROORONE NONE,VTODO,URL,NONE,ZEROORONE NONE,VTODO,VERSION,NONE,ZERO NONE,VTODO,X,NONE,ZEROPLUS NONE,VTODO,RELCALID,NONE,ZEROORONE NONE,VTODO,COLOR,NONE,ZEROORONE NONE,VTODO,CONFERENCE,NONE,ZEROPLUS NONE,VTODO,IMAGE,NONE,ZEROPLUS NONE,VJOURNAL,ACTION,NONE,ZERO NONE,VJOURNAL,ATTACH,NONE,ZEROPLUS NONE,VJOURNAL,ATTENDEE,NONE,ZEROPLUS NONE,VJOURNAL,CALSCALE,NONE,ZERO NONE,VJOURNAL,CATEGORIES,NONE,ZEROPLUS NONE,VJOURNAL,CLASS,NONE,ZEROORONE NONE,VJOURNAL,COMMENT,NONE,ZEROPLUS NONE,VJOURNAL,COMPLETED,NONE,ZERO NONE,VJOURNAL,CONTACT,NONE,ZEROPLUS NONE,VJOURNAL,CREATED,NONE,ZEROORONE NONE,VJOURNAL,DESCRIPTION,NONE,ZEROORONE NONE,VJOURNAL,DTEND,NONE,ZERO NONE,VJOURNAL,DTSTAMP,NONE,ZEROORONE NONE,VJOURNAL,DTSTART,NONE,ZEROORONE NONE,VJOURNAL,DUE,NONE,ONEEXCLUSIVE NONE,VJOURNAL,DURATION,NONE,ONEEXCLUSIVE NONE,VJOURNAL,EXDATE,NONE,ZEROPLUS NONE,VJOURNAL,EXRULE,NONE,ZEROPLUS NONE,VJOURNAL,FREEBUSY,NONE,ZERO NONE,VJOURNAL,GEO,NONE,ZERO NONE,VJOURNAL,LASTMODIFIED,NONE,ZEROORONE NONE,VJOURNAL,LOCATION,NONE,ZERO NONE,VJOURNAL,METHOD,NONE,ZERO NONE,VJOURNAL,ORGANIZER,NONE,ZEROORONE NONE,VJOURNAL,PERCENTCOMPLETE,NONE,ZERO NONE,VJOURNAL,PRIORITY,NONE,ZERO NONE,VJOURNAL,PRODID,NONE,ZERO NONE,VJOURNAL,RDATE,NONE,ZEROPLUS NONE,VJOURNAL,RECURRENCEID,NONE,ZEROORONE,must_be_recurring NONE,VJOURNAL,RELATEDTO,NONE,ZEROPLUS NONE,VJOURNAL,REPEAT,NONE,ZERO NONE,VJOURNAL,REQUESTSTATUS,NONE,ZEROPLUS NONE,VJOURNAL,RESOURCES,NONE,ZERO NONE,VJOURNAL,RRULE,NONE,ZEROPLUS NONE,VJOURNAL,SEQUENCE,NONE,ZEROORONE NONE,VJOURNAL,STATUS,NONE,ZEROORONE NONE,VJOURNAL,SUMMARY,NONE,ZEROORONE NONE,VJOURNAL,TRANSP,NONE,ZERO NONE,VJOURNAL,TRIGGER,NONE,ZERO NONE,VJOURNAL,TZID,NONE,ZERO NONE,VJOURNAL,TZNAME,NONE,ZERO NONE,VJOURNAL,TZOFFSETFROM,NONE,ZERO NONE,VJOURNAL,TZOFFSETTO,NONE,ZERO NONE,VJOURNAL,TZURL,NONE,ZERO NONE,VJOURNAL,UID,NONE,ZEROORONE NONE,VJOURNAL,URL,NONE,ZEROORONE NONE,VJOURNAL,VERSION,NONE,ZERO NONE,VJOURNAL,X,NONE,ZEROPLUS NONE,VJOURNAL,COLOR,NONE,ZEROORONE NONE,VJOURNAL,IMAGE,NONE,ZEROPLUS NONE,VFREEBUSY,ACTION,NONE,ZERO NONE,VFREEBUSY,ATTACH,NONE,ZERO NONE,VFREEBUSY,ATTENDEE,NONE,ZEROPLUS NONE,VFREEBUSY,CALSCALE,NONE,ZERO NONE,VFREEBUSY,CATEGORIES,NONE,ZERO NONE,VFREEBUSY,CLASS,NONE,ZERO NONE,VFREEBUSY,COMMENT,NONE,ZEROPLUS NONE,VFREEBUSY,COMPLETED,NONE,ZERO NONE,VFREEBUSY,CONTACT,NONE,ZEROORONE NONE,VFREEBUSY,CREATED,NONE,ZERO NONE,VFREEBUSY,DESCRIPTION,NONE,ZERO NONE,VFREEBUSY,DTEND,NONE,ZEROORONE NONE,VFREEBUSY,DTSTAMP,NONE,ONE NONE,VFREEBUSY,DTSTART,NONE,ZEROORONE NONE,VFREEBUSY,DUE,NONE,ZERO NONE,VFREEBUSY,DURATION,NONE,ZERO NONE,VFREEBUSY,EXDATE,NONE,ZERO NONE,VFREEBUSY,EXRULE,NONE,ZERO NONE,VFREEBUSY,FREEBUSY,NONE,ZEROPLUS NONE,VFREEBUSY,GEO,NONE,ZERO NONE,VFREEBUSY,LASTMODIFIED,NONE,ZERO NONE,VFREEBUSY,LOCATION,NONE,ZERO NONE,VFREEBUSY,METHOD,NONE,ZERO NONE,VFREEBUSY,ORGANIZER,NONE,ZEROORONE NONE,VFREEBUSY,PERCENTCOMPLETE,NONE,ZERO NONE,VFREEBUSY,PRIORITY,NONE,ZERO NONE,VFREEBUSY,PRODID,NONE,ZERO NONE,VFREEBUSY,RDATE,NONE,ZERO NONE,VFREEBUSY,RECURRENCEID,NONE,ZERO NONE,VFREEBUSY,RELATEDTO,NONE,ZERO NONE,VFREEBUSY,REPEAT,NONE,ZERO NONE,VFREEBUSY,REQUESTSTATUS,NONE,ZEROPLUS NONE,VFREEBUSY,RESOURCES,NONE,ZERO NONE,VFREEBUSY,RRULE,NONE,ZERO NONE,VFREEBUSY,SEQUENCE,NONE,ZERO NONE,VFREEBUSY,STATUS,NONE,ZERO NONE,VFREEBUSY,SUMMARY,NONE,ZERO NONE,VFREEBUSY,TRANSP,NONE,ZERO NONE,VFREEBUSY,TRIGGER,NONE,ZERO NONE,VFREEBUSY,TZID,NONE,ZERO NONE,VFREEBUSY,TZNAME,NONE,ZERO NONE,VFREEBUSY,TZOFFSETFROM,NONE,ZERO NONE,VFREEBUSY,TZOFFSETTO,NONE,ZERO NONE,VFREEBUSY,TZURL,NONE,ZERO NONE,VFREEBUSY,UID,NONE,ONE NONE,VFREEBUSY,URL,NONE,ZEROORONE NONE,VFREEBUSY,VERSION,NONE,ZERO NONE,VFREEBUSY,X,NONE,ZEROPLUS NONE,VTIMEZONE,ACTION,NONE,ZERO NONE,VTIMEZONE,ATTACH,NONE,ZERO NONE,VTIMEZONE,ATTENDEE,NONE,ZERO NONE,VTIMEZONE,CALSCALE,NONE,ZERO NONE,VTIMEZONE,CATEGORIES,NONE,ZERO NONE,VTIMEZONE,CLASS,NONE,ZERO NONE,VTIMEZONE,COMMENT,NONE,ZERO NONE,VTIMEZONE,COMPLETED,NONE,ZERO NONE,VTIMEZONE,CONTACT,NONE,ZERO NONE,VTIMEZONE,CREATED,NONE,ZERO NONE,VTIMEZONE,DESCRIPTION,NONE,ZERO NONE,VTIMEZONE,DTEND,NONE,ZERO NONE,VTIMEZONE,DTSTAMP,NONE,ZERO NONE,VTIMEZONE,DTSTART,NONE,ZERO NONE,VTIMEZONE,DUE,NONE,ZERO NONE,VTIMEZONE,DURATION,NONE,ZERO NONE,VTIMEZONE,EXDATE,NONE,ZERO NONE,VTIMEZONE,EXRULE,NONE,ZERO NONE,VTIMEZONE,FREEBUSY,NONE,ZERO NONE,VTIMEZONE,GEO,NONE,ZERO NONE,VTIMEZONE,LASTMODIFIED,NONE,ZEROORONE NONE,VTIMEZONE,LOCATION,NONE,ZERO NONE,VTIMEZONE,METHOD,NONE,ZERO NONE,VTIMEZONE,ORGANIZER,NONE,ZERO NONE,VTIMEZONE,PERCENTCOMPLETE,NONE,ZERO NONE,VTIMEZONE,PRIORITY,NONE,ZERO NONE,VTIMEZONE,PRODID,NONE,ZERO NONE,VTIMEZONE,RDATE,NONE,ZERO NONE,VTIMEZONE,RECURRENCEID,NONE,ZERO NONE,VTIMEZONE,RELATEDTO,NONE,ZERO NONE,VTIMEZONE,REPEAT,NONE,ZERO NONE,VTIMEZONE,REQUESTSTATUS,NONE,ZERO NONE,VTIMEZONE,RESOURCES,NONE,ZERO NONE,VTIMEZONE,RRULE,NONE,ZERO NONE,VTIMEZONE,SEQUENCE,NONE,ZERO NONE,VTIMEZONE,STATUS,NONE,ZERO NONE,VTIMEZONE,SUMMARY,NONE,ZERO NONE,VTIMEZONE,TRANSP,NONE,ZERO NONE,VTIMEZONE,TRIGGER,NONE,ZERO NONE,VTIMEZONE,TZID,NONE,ONE NONE,VTIMEZONE,TZIDALIASOF,NONE,ZEROPLUS NONE,VTIMEZONE,TZNAME,NONE,ZERO NONE,VTIMEZONE,TZOFFSETFROM,NONE,ZERO NONE,VTIMEZONE,TZOFFSETTO,NONE,ZERO NONE,VTIMEZONE,TZUNTIL,NONE,ZEROORONE NONE,VTIMEZONE,TZURL,NONE,ZEROPLUS NONE,VTIMEZONE,UID,NONE,ZERO NONE,VTIMEZONE,URL,NONE,ZERO NONE,VTIMEZONE,VERSION,NONE,ZERO NONE,VTIMEZONE,X,NONE,ZEROORONE NONE,VTIMEZONE,NONE,XSTANDARD,ZEROPLUS NONE,VTIMEZONE,NONE,XDAYLIGHT,ZEROPLUS NONE,XSTANDARD,ACTION,NONE,ZERO NONE,XSTANDARD,ATTACH,NONE,ZERO NONE,XSTANDARD,ATTENDEE,NONE,ZERO NONE,XSTANDARD,CALSCALE,NONE,ZERO NONE,XSTANDARD,CATEGORIES,NONE,ZERO NONE,XSTANDARD,CLASS,NONE,ZERO NONE,XSTANDARD,COMMENT,NONE,ZEROPLUS NONE,XSTANDARD,COMPLETED,NONE,ZERO NONE,XSTANDARD,CONTACT,NONE,ZERO NONE,XSTANDARD,CREATED,NONE,ZERO NONE,XSTANDARD,DESCRIPTION,NONE,ZERO NONE,XSTANDARD,DTEND,NONE,ZERO NONE,XSTANDARD,DTSTAMP,NONE,ZERO NONE,XSTANDARD,DTSTART,NONE,ONE NONE,XSTANDARD,DUE,NONE,ZERO NONE,XSTANDARD,DURATION,NONE,ZERO NONE,XSTANDARD,EXDATE,NONE,ZERO NONE,XSTANDARD,EXRULE,NONE,ZERO NONE,XSTANDARD,FREEBUSY,NONE,ZERO NONE,XSTANDARD,GEO,NONE,ZERO NONE,XSTANDARD,LASTMODIFIED,NONE,ZERO NONE,XSTANDARD,LOCATION,NONE,ZERO NONE,XSTANDARD,METHOD,NONE,ZERO NONE,XSTANDARD,ORGANIZER,NONE,ZERO NONE,XSTANDARD,PERCENTCOMPLETE,NONE,ZERO NONE,XSTANDARD,PRIORITY,NONE,ZERO NONE,XSTANDARD,PRODID,NONE,ZERO NONE,XSTANDARD,RDATE,NONE,ZEROPLUS NONE,XSTANDARD,RECURRENCEID,NONE,ZERO NONE,XSTANDARD,RELATEDTO,NONE,ZERO NONE,XSTANDARD,REPEAT,NONE,ZERO NONE,XSTANDARD,REQUESTSTATUS,NONE,ZERO NONE,XSTANDARD,RESOURCES,NONE,ZERO NONE,XSTANDARD,RRULE,NONE,ZEROPLUS NONE,XSTANDARD,SEQUENCE,NONE,ZERO NONE,XSTANDARD,STATUS,NONE,ZERO NONE,XSTANDARD,SUMMARY,NONE,ZERO NONE,XSTANDARD,TRANSP,NONE,ZERO NONE,XSTANDARD,TRIGGER,NONE,ZERO NONE,XSTANDARD,TZID,NONE,ZERO NONE,XSTANDARD,TZNAME,NONE,ZEROPLUS NONE,XSTANDARD,TZOFFSETFROM,NONE,ONE NONE,XSTANDARD,TZOFFSETTO,NONE,ONE NONE,XSTANDARD,TZURL,NONE,ZERO NONE,XSTANDARD,UID,NONE,ZERO NONE,XSTANDARD,URL,NONE,ZERO NONE,XSTANDARD,VERSION,NONE,ZERO NONE,XSTANDARD,X,NONE,ZEROPLUS NONE,XDAYLIGHT,ACTION,NONE,ZERO NONE,XDAYLIGHT,ATTACH,NONE,ZERO NONE,XDAYLIGHT,ATTENDEE,NONE,ZERO NONE,XDAYLIGHT,CALSCALE,NONE,ZERO NONE,XDAYLIGHT,CATEGORIES,NONE,ZERO NONE,XDAYLIGHT,CLASS,NONE,ZERO NONE,XDAYLIGHT,COMMENT,NONE,ZEROPLUS NONE,XDAYLIGHT,COMPLETED,NONE,ZERO NONE,XDAYLIGHT,CONTACT,NONE,ZERO NONE,XDAYLIGHT,CREATED,NONE,ZERO NONE,XDAYLIGHT,DESCRIPTION,NONE,ZERO NONE,XDAYLIGHT,DTEND,NONE,ZERO NONE,XDAYLIGHT,DTSTAMP,NONE,ZERO NONE,XDAYLIGHT,DTSTART,NONE,ONE NONE,XDAYLIGHT,DUE,NONE,ZERO NONE,XDAYLIGHT,DURATION,NONE,ZERO NONE,XDAYLIGHT,EXDATE,NONE,ZERO NONE,XDAYLIGHT,EXRULE,NONE,ZERO NONE,XDAYLIGHT,FREEBUSY,NONE,ZERO NONE,XDAYLIGHT,GEO,NONE,ZERO NONE,XDAYLIGHT,LASTMODIFIED,NONE,ZERO NONE,XDAYLIGHT,LOCATION,NONE,ZERO NONE,XDAYLIGHT,METHOD,NONE,ZERO NONE,XDAYLIGHT,ORGANIZER,NONE,ZERO NONE,XDAYLIGHT,PERCENTCOMPLETE,NONE,ZERO NONE,XDAYLIGHT,PRIORITY,NONE,ZERO NONE,XDAYLIGHT,PRODID,NONE,ZERO NONE,XDAYLIGHT,RDATE,NONE,ZEROPLUS NONE,XDAYLIGHT,RECURRENCEID,NONE,ZERO NONE,XDAYLIGHT,RELATEDTO,NONE,ZERO NONE,XDAYLIGHT,REPEAT,NONE,ZERO NONE,XDAYLIGHT,REQUESTSTATUS,NONE,ZERO NONE,XDAYLIGHT,RESOURCES,NONE,ZERO NONE,XDAYLIGHT,RRULE,NONE,ZEROPLUS NONE,XDAYLIGHT,SEQUENCE,NONE,ZERO NONE,XDAYLIGHT,STATUS,NONE,ZERO NONE,XDAYLIGHT,SUMMARY,NONE,ZERO NONE,XDAYLIGHT,TRANSP,NONE,ZERO NONE,XDAYLIGHT,TRIGGER,NONE,ZERO NONE,XDAYLIGHT,TZID,NONE,ZERO NONE,XDAYLIGHT,TZNAME,NONE,ZEROPLUS NONE,XDAYLIGHT,TZOFFSETFROM,NONE,ONE NONE,XDAYLIGHT,TZOFFSETTO,NONE,ONE NONE,XDAYLIGHT,TZURL,NONE,ZERO NONE,XDAYLIGHT,UID,NONE,ZERO NONE,XDAYLIGHT,URL,NONE,ZERO NONE,XDAYLIGHT,VERSION,NONE,ZERO NONE,XDAYLIGHT,X,NONE,ZEROPLUS NONE,XAUDIOALARM,ACTION,NONE,ONE NONE,XAUDIOALARM,ATTACH,NONE,ZEROORONE NONE,XAUDIOALARM,ATTENDEE,NONE,ZERO NONE,XAUDIOALARM,CALSCALE,NONE,ZERO NONE,XAUDIOALARM,CATEGORIES,NONE,ZERO NONE,XAUDIOALARM,CLASS,NONE,ZERO NONE,XAUDIOALARM,COMMENT,NONE,ZERO NONE,XAUDIOALARM,COMPLETED,NONE,ZERO NONE,XAUDIOALARM,CONTACT,NONE,ZERO NONE,XAUDIOALARM,CREATED,NONE,ZERO NONE,XAUDIOALARM,DESCRIPTION,NONE,ZERO NONE,XAUDIOALARM,DTEND,NONE,ZERO NONE,XAUDIOALARM,DTSTAMP,NONE,ZERO NONE,XAUDIOALARM,DTSTART,NONE,ZERO NONE,XAUDIOALARM,DUE,NONE,ZERO NONE,XAUDIOALARM,DURATION,NONE,ONEMUTUAL,must_have_repeat NONE,XAUDIOALARM,REPEAT,NONE,ONEMUTUAL,must_have_duration NONE,XAUDIOALARM,EXDATE,NONE,ZERO NONE,XAUDIOALARM,EXRULE,NONE,ZERO NONE,XAUDIOALARM,FREEBUSY,NONE,ZERO NONE,XAUDIOALARM,GEO,NONE,ZERO NONE,XAUDIOALARM,LASTMODIFIED,NONE,ZERO NONE,XAUDIOALARM,LOCATION,NONE,ZERO NONE,XAUDIOALARM,METHOD,NONE,ZERO NONE,XAUDIOALARM,ORGANIZER,NONE,ZERO NONE,XAUDIOALARM,PERCENTCOMPLETE,NONE,ZERO NONE,XAUDIOALARM,PRIORITY,NONE,ZERO NONE,XAUDIOALARM,PRODID,NONE,ZERO NONE,XAUDIOALARM,RDATE,NONE,ZERO NONE,XAUDIOALARM,RECURRENCEID,NONE,ZERO NONE,XAUDIOALARM,RELATEDTO,NONE,ZERO NONE,XAUDIOALARM,REQUESTSTATUS,NONE,ZERO NONE,XAUDIOALARM,RESOURCES,NONE,ZERO NONE,XAUDIOALARM,RRULE,NONE,ZERO NONE,XAUDIOALARM,SEQUENCE,NONE,ZERO NONE,XAUDIOALARM,STATUS,NONE,ZERO NONE,XAUDIOALARM,SUMMARY,NONE,ZERO NONE,XAUDIOALARM,TRANSP,NONE,ZERO NONE,XAUDIOALARM,TRIGGER,NONE,ONE NONE,XAUDIOALARM,TZID,NONE,ZERO NONE,XAUDIOALARM,TZNAME,NONE,ZERO NONE,XAUDIOALARM,TZOFFSETFROM,NONE,ZERO NONE,XAUDIOALARM,TZOFFSETTO,NONE,ZERO NONE,XAUDIOALARM,TZURL,NONE,ZERO NONE,XAUDIOALARM,UID,NONE,ZERO NONE,XAUDIOALARM,URL,NONE,ZERO NONE,XAUDIOALARM,VERSION,NONE,ZERO NONE,XAUDIOALARM,X,NONE,ZEROPLUS NONE,XDISPLAYALARM,ACTION,NONE,ONE NONE,XDISPLAYALARM,ATTACH,NONE,ZERO NONE,XDISPLAYALARM,ATTENDEE,NONE,ZERO NONE,XDISPLAYALARM,CALSCALE,NONE,ZERO NONE,XDISPLAYALARM,CATEGORIES,NONE,ZERO NONE,XDISPLAYALARM,CLASS,NONE,ZERO NONE,XDISPLAYALARM,COMMENT,NONE,ZERO NONE,XDISPLAYALARM,COMPLETED,NONE,ZERO NONE,XDISPLAYALARM,CONTACT,NONE,ZERO NONE,XDISPLAYALARM,CREATED,NONE,ZERO NONE,XDISPLAYALARM,DESCRIPTION,NONE,ONE NONE,XDISPLAYALARM,DTEND,NONE,ZERO NONE,XDISPLAYALARM,DTSTAMP,NONE,ZERO NONE,XDISPLAYALARM,DTSTART,NONE,ZERO NONE,XDISPLAYALARM,DUE,NONE,ZERO NONE,XDISPLAYALARM,DURATION,NONE,ONEMUTUAL,must_have_repeat NONE,XDISPLAYALARM,REPEAT,NONE,ONEMUTUAL,must_have_duration NONE,XDISPLAYALARM,EXDATE,NONE,ZERO NONE,XDISPLAYALARM,EXRULE,NONE,ZERO NONE,XDISPLAYALARM,FREEBUSY,NONE,ZERO NONE,XDISPLAYALARM,GEO,NONE,ZERO NONE,XDISPLAYALARM,LASTMODIFIED,NONE,ZERO NONE,XDISPLAYALARM,LOCATION,NONE,ZERO NONE,XDISPLAYALARM,METHOD,NONE,ZERO NONE,XDISPLAYALARM,ORGANIZER,NONE,ZERO NONE,XDISPLAYALARM,PERCENTCOMPLETE,NONE,ZERO NONE,XDISPLAYALARM,PRIORITY,NONE,ZERO NONE,XDISPLAYALARM,PRODID,NONE,ZERO NONE,XDISPLAYALARM,RDATE,NONE,ZERO NONE,XDISPLAYALARM,RECURRENCEID,NONE,ZERO NONE,XDISPLAYALARM,RELATEDTO,NONE,ZERO NONE,XDISPLAYALARM,REQUESTSTATUS,NONE,ZERO NONE,XDISPLAYALARM,RESOURCES,NONE,ZERO NONE,XDISPLAYALARM,RRULE,NONE,ZERO NONE,XDISPLAYALARM,SEQUENCE,NONE,ZERO NONE,XDISPLAYALARM,STATUS,NONE,ZERO NONE,XDISPLAYALARM,SUMMARY,NONE,ZERO NONE,XDISPLAYALARM,TRANSP,NONE,ZERO NONE,XDISPLAYALARM,TRIGGER,NONE,ONE NONE,XDISPLAYALARM,TZID,NONE,ZERO NONE,XDISPLAYALARM,TZNAME,NONE,ZERO NONE,XDISPLAYALARM,TZOFFSETFROM,NONE,ZERO NONE,XDISPLAYALARM,TZOFFSETTO,NONE,ZERO NONE,XDISPLAYALARM,TZURL,NONE,ZERO NONE,XDISPLAYALARM,UID,NONE,ZERO NONE,XDISPLAYALARM,URL,NONE,ZERO NONE,XDISPLAYALARM,VERSION,NONE,ZERO NONE,XDISPLAYALARM,X,NONE,ZEROPLUS NONE,XEMAILALARM,ACTION,NONE,ONE,must_be_email NONE,XEMAILALARM,ATTACH,NONE,ZEROPLUS NONE,XEMAILALARM,ATTENDEE,NONE,ONEPLUS NONE,XEMAILALARM,CALSCALE,NONE,ZERO NONE,XEMAILALARM,CATEGORIES,NONE,ZERO NONE,XEMAILALARM,CLASS,NONE,ZERO NONE,XEMAILALARM,COMMENT,NONE,ZERO NONE,XEMAILALARM,COMPLETED,NONE,ZERO NONE,XEMAILALARM,CONTACT,NONE,ZERO NONE,XEMAILALARM,CREATED,NONE,ZERO NONE,XEMAILALARM,DESCRIPTION,NONE,ONE NONE,XEMAILALARM,DTEND,NONE,ZERO NONE,XEMAILALARM,DTSTAMP,NONE,ZERO NONE,XEMAILALARM,DTSTART,NONE,ZERO NONE,XEMAILALARM,DUE,NONE,ZERO NONE,XEMAILALARM,DURATION,NONE,ONEMUTUAL,must_have_repeat NONE,XEMAILALARM,REPEAT,NONE,ONEMUTUAL,must_have_duration NONE,XEMAILALARM,EXDATE,NONE,ZERO NONE,XEMAILALARM,EXRULE,NONE,ZERO NONE,XEMAILALARM,FREEBUSY,NONE,ZERO NONE,XEMAILALARM,GEO,NONE,ZERO NONE,XEMAILALARM,LASTMODIFIED,NONE,ZERO NONE,XEMAILALARM,LOCATION,NONE,ZERO NONE,XEMAILALARM,METHOD,NONE,ZERO NONE,XEMAILALARM,ORGANIZER,NONE,ZERO NONE,XEMAILALARM,PERCENTCOMPLETE,NONE,ZERO NONE,XEMAILALARM,PRIORITY,NONE,ZERO NONE,XEMAILALARM,PRODID,NONE,ZERO NONE,XEMAILALARM,RDATE,NONE,ZERO NONE,XEMAILALARM,RECURRENCEID,NONE,ZERO NONE,XEMAILALARM,RELATEDTO,NONE,ZERO NONE,XEMAILALARM,REQUESTSTATUS,NONE,ZERO NONE,XEMAILALARM,RESOURCES,NONE,ZERO NONE,XEMAILALARM,RRULE,NONE,ZERO NONE,XEMAILALARM,SEQUENCE,NONE,ZERO NONE,XEMAILALARM,STATUS,NONE,ZERO NONE,XEMAILALARM,SUMMARY,NONE,ONE NONE,XEMAILALARM,TRANSP,NONE,ZERO NONE,XEMAILALARM,TRIGGER,NONE,ONE NONE,XEMAILALARM,TZID,NONE,ZERO NONE,XEMAILALARM,TZNAME,NONE,ZERO NONE,XEMAILALARM,TZOFFSETFROM,NONE,ZERO NONE,XEMAILALARM,TZOFFSETTO,NONE,ZERO NONE,XEMAILALARM,TZURL,NONE,ZERO NONE,XEMAILALARM,UID,NONE,ZERO NONE,XEMAILALARM,URL,NONE,ZERO NONE,XEMAILALARM,VERSION,NONE,ZERO NONE,XEMAILALARM,X,NONE,ZEROPLUS NONE,XPROCEDUREALARM,ACTION,NONE,ONE NONE,XPROCEDUREALARM,ATTACH,NONE,ZEROORONE NONE,XPROCEDUREALARM,ATTENDEE,NONE,ZERO NONE,XPROCEDUREALARM,CALSCALE,NONE,ZERO NONE,XPROCEDUREALARM,CATEGORIES,NONE,ZERO NONE,XPROCEDUREALARM,CLASS,NONE,ZERO NONE,XPROCEDUREALARM,COMMENT,NONE,ZERO NONE,XPROCEDUREALARM,COMPLETED,NONE,ZERO NONE,XPROCEDUREALARM,CONTACT,NONE,ZERO NONE,XPROCEDUREALARM,CREATED,NONE,ZERO NONE,XPROCEDUREALARM,DESCRIPTION,NONE,ZEROORONE NONE,XPROCEDUREALARM,DTEND,NONE,ZERO NONE,XPROCEDUREALARM,DTSTAMP,NONE,ZERO NONE,XPROCEDUREALARM,DTSTART,NONE,ZERO NONE,XPROCEDUREALARM,DUE,NONE,ZERO NONE,XPROCEDUREALARM,DURATION,NONE,ONEMUTUAL,must_have_repeat NONE,XPROCEDUREALARM,REPEAT,NONE,ONEMUTUAL,must_have_duration NONE,XPROCEDUREALARM,EXDATE,NONE,ZERO NONE,XPROCEDUREALARM,EXRULE,NONE,ZERO NONE,XPROCEDUREALARM,FREEBUSY,NONE,ZERO NONE,XPROCEDUREALARM,GEO,NONE,ZERO NONE,XPROCEDUREALARM,LASTMODIFIED,NONE,ZERO NONE,XPROCEDUREALARM,LOCATION,NONE,ZERO NONE,XPROCEDUREALARM,METHOD,NONE,ZERO NONE,XPROCEDUREALARM,ORGANIZER,NONE,ZERO NONE,XPROCEDUREALARM,PERCENTCOMPLETE,NONE,ZERO NONE,XPROCEDUREALARM,PRIORITY,NONE,ZERO NONE,XPROCEDUREALARM,PRODID,NONE,ZERO NONE,XPROCEDUREALARM,RDATE,NONE,ZERO NONE,XPROCEDUREALARM,RECURRENCEID,NONE,ZERO NONE,XPROCEDUREALARM,RELATEDTO,NONE,ZERO NONE,XPROCEDUREALARM,REQUESTSTATUS,NONE,ZERO NONE,XPROCEDUREALARM,RESOURCES,NONE,ZERO NONE,XPROCEDUREALARM,RRULE,NONE,ZERO NONE,XPROCEDUREALARM,SEQUENCE,NONE,ZERO NONE,XPROCEDUREALARM,STATUS,NONE,ZERO NONE,XPROCEDUREALARM,SUMMARY,NONE,ZERO NONE,XPROCEDUREALARM,TRANSP,NONE,ZERO NONE,XPROCEDUREALARM,TRIGGER,NONE,ONE NONE,XPROCEDUREALARM,TZID,NONE,ZERO NONE,XPROCEDUREALARM,TZNAME,NONE,ZERO NONE,XPROCEDUREALARM,TZOFFSETFROM,NONE,ZERO NONE,XPROCEDUREALARM,TZOFFSETTO,NONE,ZERO NONE,XPROCEDUREALARM,TZURL,NONE,ZERO NONE,XPROCEDUREALARM,UID,NONE,ZERO NONE,XPROCEDUREALARM,URL,NONE,ZERO NONE,XPROCEDUREALARM,VERSION,NONE,ZERO NONE,XPROCEDUREALARM,X,NONE,ZEROPLUS NONE,VQUERY,QUERY,NONE,ZEROORONE NONE,VQUERY,QUERYNAME,NONE,ONE NONE,VQUERY,EXPAND,NONE,ONE NONE,VAVAILABILITY,ACTION,NONE,ZERO NONE,VAVAILABILITY,ATTACH,NONE,ZERO NONE,VAVAILABILITY,ATTENDEE,NONE,ZERO NONE,VAVAILABILITY,BUSYTYPE,NONE,ZEROORONE NONE,VAVAILABILITY,CALSCALE,NONE,ZERO NONE,VAVAILABILITY,CATEGORIES,NONE,ZEROPLUS NONE,VAVAILABILITY,CLASS,NONE,ZEROORONE NONE,VAVAILABILITY,COMMENT,NONE,ZEROPLUS NONE,VAVAILABILITY,COMPLETED,NONE,ZERO NONE,VAVAILABILITY,CONTACT,NONE,ZEROPLUS NONE,VAVAILABILITY,CREATED,NONE,ZEROORONE NONE,VAVAILABILITY,DESCRIPTION,NONE,ZEROORONE NONE,VAVAILABILITY,DTEND,NONE,ONEEXCLUSIVE,no_duration NONE,VAVAILABILITY,DTSTAMP,NONE,ONE NONE,VAVAILABILITY,DTSTART,NONE,ZEROORONE NONE,VAVAILABILITY,DUE,NONE,ZERO NONE,VAVAILABILITY,DURATION,NONE,ONEEXCLUSIVE,no_dtend NONE,VAVAILABILITY,EXDATE,NONE,ZERO NONE,VAVAILABILITY,EXRULE,NONE,ZERO NONE,VAVAILABILITY,FREEBUSY,NONE,ZERO NONE,VAVAILABILITY,GEO,NONE,ZERO NONE,VAVAILABILITY,LASTMODIFIED,NONE,ZEROORONE NONE,VAVAILABILITY,LOCATION,NONE,ZERO NONE,VAVAILABILITY,METHOD,NONE,ZERO NONE,VAVAILABILITY,ORGANIZER,NONE,ZEROORONE NONE,VAVAILABILITY,PERCENTCOMPLETE,NONE,ZERO NONE,VAVAILABILITY,PRIORITY,NONE,ZEROORONE NONE,VAVAILABILITY,PRODID,NONE,ZERO NONE,VAVAILABILITY,RDATE,NONE,ZERO NONE,VAVAILABILITY,RECURRENCEID,NONE,ZERO NONE,VAVAILABILITY,RELATEDTO,NONE,ZERO NONE,VAVAILABILITY,REPEAT,NONE,ZERO NONE,VAVAILABILITY,REQUESTSTATUS,NONE,ZERO NONE,VAVAILABILITY,RESOURCES,NONE,ZERO NONE,VAVAILABILITY,RRULE,NONE,ZERO NONE,VAVAILABILITY,SEQUENCE,NONE,ZEROORONE NONE,VAVAILABILITY,STATUS,NONE,ZERO NONE,VAVAILABILITY,SUMMARY,NONE,ZEROORONE NONE,VAVAILABILITY,TRANSP,NONE,ZERO NONE,VAVAILABILITY,TRIGGER,NONE,ZERO NONE,VAVAILABILITY,TZID,NONE,ZERO NONE,VAVAILABILITY,TZNAME,NONE,ZERO NONE,VAVAILABILITY,TZOFFSETFROM,NONE,ZERO NONE,VAVAILABILITY,TZOFFSETTO,NONE,ZERO NONE,VAVAILABILITY,TZURL,NONE,ZERO NONE,VAVAILABILITY,UID,NONE,ONE NONE,VAVAILABILITY,URL,NONE,ZEROORONE NONE,VAVAILABILITY,VERSION,NONE,ZERO NONE,VAVAILABILITY,X,NONE,ZEROPLUS NONE,VAVAILABILITY,NONE,XAVAILABLE,ZEROPLUS NONE,XAVAILABLE,ACTION,NONE,ZERO NONE,XAVAILABLE,ATTACH,NONE,ZERO NONE,XAVAILABLE,ATTENDEE,NONE,ZERO NONE,XAVAILABLE,CALSCALE,NONE,ZERO NONE,XAVAILABLE,CATEGORIES,NONE,ZEROPLUS NONE,XAVAILABLE,CLASS,NONE,ZERO NONE,XAVAILABLE,COMMENT,NONE,ZEROPLUS NONE,XAVAILABLE,COMPLETED,NONE,ZERO NONE,XAVAILABLE,CONTACT,NONE,ZEROPLUS NONE,XAVAILABLE,CREATED,NONE,ZEROORONE NONE,XAVAILABLE,DESCRIPTION,NONE,ZEROORONE NONE,XAVAILABLE,DTEND,NONE,ONEEXCLUSIVE,no_duration NONE,XAVAILABLE,DTSTAMP,NONE,ONE NONE,XAVAILABLE,DTSTART,NONE,ONE NONE,XAVAILABLE,DUE,NONE,ZERO NONE,XAVAILABLE,DURATION,NONE,ONEEXCLUSIVE,no_dtend NONE,XAVAILABLE,EXDATE,NONE,ZEROPLUS NONE,XAVAILABLE,EXRULE,NONE,ZERO NONE,XAVAILABLE,FREEBUSY,NONE,ZERO NONE,XAVAILABLE,GEO,NONE,ZERO NONE,XAVAILABLE,LASTMODIFIED,NONE,ZEROORONE NONE,XAVAILABLE,LOCATION,NONE,ZERO NONE,XAVAILABLE,METHOD,NONE,ZERO NONE,XAVAILABLE,ORGANIZER,NONE,ZERO NONE,XAVAILABLE,PERCENTCOMPLETE,NONE,ZERO NONE,XAVAILABLE,PRIORITY,NONE,ZERO NONE,XAVAILABLE,PRODID,NONE,ZERO NONE,XAVAILABLE,RDATE,NONE,ZEROPLUS NONE,XAVAILABLE,RECURRENCEID,NONE,ZEROORONE,must_be_recurring NONE,XAVAILABLE,RELATEDTO,NONE,ZERO NONE,XAVAILABLE,REPEAT,NONE,ZERO NONE,XAVAILABLE,REQUESTSTATUS,NONE,ZERO NONE,XAVAILABLE,RESOURCES,NONE,ZERO NONE,XAVAILABLE,RRULE,NONE,ZEROORONE NONE,XAVAILABLE,SEQUENCE,NONE,ZERO NONE,XAVAILABLE,STATUS,NONE,ZERO NONE,XAVAILABLE,SUMMARY,NONE,ZEROORONE NONE,XAVAILABLE,TRANSP,NONE,ZERO NONE,XAVAILABLE,TRIGGER,NONE,ZERO NONE,XAVAILABLE,TZID,NONE,ZERO NONE,XAVAILABLE,TZNAME,NONE,ZERO NONE,XAVAILABLE,TZOFFSETFROM,NONE,ZERO NONE,XAVAILABLE,TZOFFSETTO,NONE,ZERO NONE,XAVAILABLE,TZURL,NONE,ZERO NONE,XAVAILABLE,UID,NONE,ONE NONE,XAVAILABLE,URL,NONE,ZERO NONE,XAVAILABLE,VERSION,NONE,ZERO NONE,XAVAILABLE,X,NONE,ZEROPLUS PUBLISH,VPOLL,NONE,NONE,ONEPLUS PUBLISH,VPOLL,DTSTAMP,NONE,ONE PUBLISH,VPOLL,DTSTART,NONE,ZEROORONE PUBLISH,VPOLL,ORGANIZER,NONE,ONE PUBLISH,VPOLL,SUMMARY,NONE,ONE PUBLISH,VPOLL,UID,NONE,ONE PUBLISH,VPOLL,SEQUENCE,NONE,ZEROORONE PUBLISH,VPOLL,ACCEPTRESPONSE,NONE,ZEROORONE PUBLISH,VPOLL,ATTACH,NONE,ZEROPLUS PUBLISH,VPOLL,CATEGORIES,NONE,ZEROPLUS #Non-standard PUBLISH,VPOLL,CLASS,NONE,ZEROORONE PUBLISH,VPOLL,COMMENT,NONE,ZEROPLUS PUBLISH,VPOLL,COMPLETED,NONE,ZEROORONE PUBLISH,VPOLL,CONTACT,NONE,ZEROORONE PUBLISH,VPOLL,CREATED,NONE,ZEROORONE PUBLISH,VPOLL,DESCRIPTION,NONE,ZEROORONE PUBLISH,VPOLL,DTEND,NONE,ONEEXCLUSIVE,no_duration PUBLISH,VPOLL,DURATION,NONE,ONEEXCLUSIVE,no_dtend PUBLISH,VPOLL,LASTMODIFIED,NONE,ZEROORONE PUBLISH,VPOLL,POLLCOMPLETION,NONE,ZEROORONE PUBLISH,VPOLL,POLLITEMID,NONE,ZERO PUBLISH,VPOLL,POLLMODE,NONE,ZEROORONE PUBLISH,VPOLL,POLLPROPERTIES,NONE,ZEROORONE PUBLISH,VPOLL,PRIORITY,NONE,ZEROORONE PUBLISH,VPOLL,RELATEDTO,NONE,ZEROPLUS PUBLISH,VPOLL,RESOURCES,NONE,ZEROPLUS PUBLISH,VPOLL,STATUS,NONE,ZEROORONE PUBLISH,VPOLL,URL,NONE,ZEROORONE PUBLISH,VPOLL,X,NONE,ZEROPLUS PUBLISH,VPOLL,REQUESTSTATUS,NONE,ZERO PUBLISH,VPOLL,NONE,VVOTER,ZEROPLUS PUBLISH,VPOLL,NONE,VALARM,ZEROPLUS PUBLISH,VPOLL,NONE,VEVENT,ZEROPLUS PUBLISH,VPOLL,NONE,VFREEBUSY,ZERO PUBLISH,VPOLL,NONE,VAVAILABILITY,ZERO PUBLISH,VPOLL,NONE,VJOURNAL,ZEROPLUS PUBLISH,VPOLL,NONE,VTODO,ZEROPLUS PUBLISH,VPOLL,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref PUBLISH,VPOLL,NONE,X,ZEROPLUS REQUEST,VPOLL,NONE,NONE,ONE REQUEST,VPOLL,DTSTAMP,NONE,ONE REQUEST,VPOLL,DTSTART,NONE,ZEROORONE REQUEST,VPOLL,ORGANIZER,NONE,ONE REQUEST,VPOLL,SEQUENCE,NONE,ZEROORONE REQUEST,VPOLL,SUMMARY,NONE,ONE REQUEST,VPOLL,UID,NONE,ONE REQUEST,VPOLL,ACCEPTRESPONSE,NONE,ZEROORONE REQUEST,VPOLL,ATTACH,NONE,ZEROPLUS REQUEST,VPOLL,CATEGORIES,NONE,ZEROPLUS #Non-standard REQUEST,VPOLL,CLASS,NONE,ZEROORONE REQUEST,VPOLL,COMMENT,NONE,ZEROPLUS REQUEST,VPOLL,COMPLETED,NONE,ZEROORONE REQUEST,VPOLL,CONTACT,NONE,ZEROPLUS REQUEST,VPOLL,CREATED,NONE,ZEROORONE REQUEST,VPOLL,DESCRIPTION,NONE,ZEROORONE REQUEST,VPOLL,DTEND,NONE,ONEEXCLUSIVE,no_duration REQUEST,VPOLL,DURATION,NONE,ONEEXCLUSIVE,no_dtend REQUEST,VPOLL,GEO,NONE,ZEROORONE REQUEST,VPOLL,LASTMODIFIED,NONE,ZEROORONE REQUEST,VPOLL,LOCATION,NONE,ZEROORONE REQUEST,VPOLL,POLLCOMPLETION,NONE,ZEROORONE REQUEST,VPOLL,POLLITEMID,NONE,ZERO REQUEST,VPOLL,POLLMODE,NONE,ZEROORONE REQUEST,VPOLL,POLLPROPERTIES,NONE,ZEROORONE REQUEST,VPOLL,PRIORITY,NONE,ZEROORONE REQUEST,VPOLL,RELATEDTO,NONE,ZEROPLUS REQUEST,VPOLL,REQUESTSTATUS,NONE,ZERO REQUEST,VPOLL,RESOURCES,NONE,ZEROPLUS REQUEST,VPOLL,STATUS,NONE,ZEROORONE REQUEST,VPOLL,TRANSP,NONE,ZEROORONE REQUEST,VPOLL,URL,NONE,ZEROORONE REQUEST,VPOLL,X,NONE,ZEROPLUS REQUEST,VPOLL,NONE,VVOTER,ONEPLUS REQUEST,VPOLL,NONE,VALARM,ZEROPLUS REQUEST,VPOLL,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref REQUEST,VPOLL,NONE,X,ZEROPLUS REQUEST,VPOLL,NONE,VEVENT,ZEROPLUS REQUEST,VPOLL,NONE,VFREEBUSY,ZERO REQUEST,VPOLL,NONE,VAVAILABILITY,ZERO REQUEST,VPOLL,NONE,VJOURNAL,ZEROPLUS REQUEST,VPOLL,NONE,VTODO,ZEROPLUS REPLY,VPOLL,NONE,NONE,ONEPLUS REPLY,VPOLL,DTSTAMP,NONE,ONE REPLY,VPOLL,ORGANIZER,NONE,ONE REPLY,VPOLL,UID,NONE,ONE REPLY,VPOLL,SEQUENCE,NONE,ZEROORONE REPLY,VPOLL,ACCEPTRESPONSE,NONE,ZEROORONE REPLY,VPOLL,ATTACH,NONE,ZEROPLUS REPLY,VPOLL,CATEGORIES,NONE,ZEROPLUS #Non-standard REPLY,VPOLL,CLASS,NONE,ZEROORONE REPLY,VPOLL,COMMENT,NONE,ZEROPLUS REPLY,VPOLL,COMPLETED,NONE,ZEROORONE REPLY,VPOLL,CONTACT,NONE,ZEROPLUS REPLY,VPOLL,CREATED,NONE,ZEROORONE REPLY,VPOLL,DESCRIPTION,NONE,ZEROORONE REPLY,VPOLL,DTEND,NONE,ONEEXCLUSIVE,no_duration REPLY,VPOLL,DTSTART,NONE,ZEROORONE REPLY,VPOLL,DURATION,NONE,ONEEXCLUSIVE,no_dtend REPLY,VPOLL,GEO,NONE,ZEROORONE REPLY,VPOLL,LASTMODIFIED,NONE,ZEROORONE REPLY,VPOLL,LOCATION,NONE,ZEROORONE REPLY,VPOLL,POLLCOMPLETION,NONE,ZERO REPLY,VPOLL,POLLITEMID,NONE,ONEPLUS REPLY,VPOLL,POLLMODE,NONE,ZERO REPLY,VPOLL,POLLPROPERTIES,NONE,ZERO REPLY,VPOLL,PRIORITY,NONE,ZEROORONE REPLY,VPOLL,RELATEDTO,NONE,ZEROPLUS REPLY,VPOLL,RESOURCES,NONE,ZEROPLUS REPLY,VPOLL,REQUESTSTATUS,NONE,ZEROPLUS REPLY,VPOLL,STATUS,NONE,ZEROORONE REPLY,VPOLL,SUMMARY,NONE,ZEROORONE REPLY,VPOLL,TRANSP,NONE,ZEROORONE REPLY,VPOLL,URL,NONE,ZEROORONE REPLY,VPOLL,X,NONE,ZEROPLUS REPLY,VPOLL,NONE,VVOTER,ONE REPLY,VPOLL,NONE,VALARM,ZERO REPLY,VPOLL,NONE,VTIMEZONE,ZEROORONE,must_if_tz_ref REPLY,VPOLL,NONE,X,ZEROPLUS REPLY,VPOLL,NONE,VEVENT,ZERO REPLY,VPOLL,NONE,VFREEBUSY,ZERO REPLY,VPOLL,NONE,VAVAILABILITY,ZERO REPLY,VPOLL,NONE,VJOURNAL,ZERO REPLY,VPOLL,NONE,VTODO,ZERO CANCEL,VPOLL,NONE,NONE,ONEPLUS CANCEL,VPOLL,UID,NONE,ONE CANCEL,VPOLL,DTSTAMP,NONE,ONE CANCEL,VPOLL,ORGANIZER,NONE,ONE CANCEL,VPOLL,SEQUENCE,NONE,ONE CANCEL,VPOLL,ATTACH,NONE,ZEROPLUS CANCEL,VPOLL,ACCEPTRESPONSE,NONE,ZEROORONE CANCEL,VPOLL,COMMENT,NONE,ZEROPLUS CANCEL,VPOLL,COMPLETED,NONE,ZEROORONE CANCEL,VPOLL,CATEGORIES,NONE,ZEROPLUS #Non-standard CANCEL,VPOLL,CLASS,NONE,ZEROORONE CANCEL,VPOLL,CONTACT,NONE,ZEROPLUS CANCEL,VPOLL,CREATED,NONE,ZEROORONE CANCEL,VPOLL,DESCRIPTION,NONE,ZEROORONE CANCEL,VPOLL,DTEND,NONE,ONEEXCLUSIVE,no_duration CANCEL,VPOLL,DTSTART,NONE,ZEROORONE CANCEL,VPOLL,DURATION,NONE,ONEEXCLUSIVE,no_dtend CANCEL,VPOLL,GEO,NONE,ZEROORONE CANCEL,VPOLL,LASTMODIFIED,NONE,ZEROORONE CANCEL,VPOLL,LOCATION,NONE,ZEROORONE CANCEL,VPOLL,POLLCOMPLETION,NONE,ZERO CANCEL,VPOLL,POLLITEMID,NONE,ZERO CANCEL,VPOLL,POLLMODE,NONE,ZERO CANCEL,VPOLL,POLLPROPERTIES,NONE,ZERO CANCEL,VPOLL,PRIORITY,NONE,ZEROORONE CANCEL,VPOLL,RELATEDTO,NONE,ZEROPLUS CANCEL,VPOLL,RESOURCES,NONE,ZEROPLUS CANCEL,VPOLL,STATUS,NONE,ZEROORONE,must_be_cancel_if_present CANCEL,VPOLL,SUMMARY,NONE,ONE CANCEL,VPOLL,TRANSP,NONE,ZEROORONE CANCEL,VPOLL,URL,NONE,ZEROORONE CANCEL,VPOLL,X,NONE,ZEROPLUS CANCEL,VPOLL,REQUESTSTATUS,NONE,ZERO CANCEL,VPOLL,NONE,VVOTER,ZEROPLUS CANCEL,VPOLL,NONE,VALARM,ZERO CANCEL,VPOLL,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref CANCEL,VPOLL,NONE,X,ZEROPLUS CANCEL,VPOLL,NONE,VEVENT,ZERO CANCEL,VPOLL,NONE,VFREEBUSY,ZERO CANCEL,VPOLL,NONE,VAVAILABILITY,ZERO CANCEL,VPOLL,NONE,VJOURNAL,ZERO CANCEL,VPOLL,NONE,VTODO,ZERO REFRESH,VPOLL,NONE,NONE,ONE REFRESH,VPOLL,DTSTAMP,NONE,ONE REFRESH,VPOLL,ORGANIZER,NONE,ONE REFRESH,VPOLL,UID,NONE,ONE REFRESH,VPOLL,COMMENT,NONE,ZEROPLUS REFRESH,VPOLL,COMPLETED,NONE,ZERO REFRESH,VPOLL,X,NONE,ZEROPLUS REFRESH,VPOLL,ACCEPTRESPONSE,NONE,ZERO REFRESH,VPOLL,ATTACH,NONE,ZERO REFRESH,VPOLL,CATEGORIES,NONE,ZERO #Non-standard REFRESH,VPOLL,CLASS,NONE,ZERO REFRESH,VPOLL,CONTACT,NONE,ZERO REFRESH,VPOLL,CREATED,NONE,ZERO REFRESH,VPOLL,DESCRIPTION,NONE,ZERO REFRESH,VPOLL,DTEND,NONE,ZERO REFRESH,VPOLL,DTSTART,NONE,ZERO REFRESH,VPOLL,DURATION,NONE,ZERO REFRESH,VPOLL,GEO,NONE,ZERO REFRESH,VPOLL,LASTMODIFIED,NONE,ZERO REFRESH,VPOLL,LOCATION,NONE,ZERO REFRESH,VPOLL,POLLCOMPLETION,NONE,ZERO REFRESH,VPOLL,POLLITEMID,NONE,ZERO REFRESH,VPOLL,POLLMODE,NONE,ZERO REFRESH,VPOLL,POLLPROPERTIES,NONE,ZERO REFRESH,VPOLL,PRIORITY,NONE,ZERO REFRESH,VPOLL,RELATEDTO,NONE,ZERO REFRESH,VPOLL,REQUESTSTATUS,NONE,ZERO REFRESH,VPOLL,RESOURCES,NONE,ZERO REFRESH,VPOLL,SEQUENCE,NONE,ZERO REFRESH,VPOLL,STATUS,NONE,ZERO REFRESH,VPOLL,SUMMARY,NONE,ZERO REFRESH,VPOLL,URL,NONE,ZERO REFRESH,VPOLL,NONE,VVOTER,ONE REFRESH,VPOLL,NONE,VALARM,ZERO REFRESH,VPOLL,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref REFRESH,VPOLL,NONE,X,ZEROPLUS REFRESH,VPOLL,NONE,VTODO,ZERO REFRESH,VPOLL,NONE,VJOURNAL,ZERO REFRESH,VPOLL,NONE,VEVENT,ZERO REFRESH,VPOLL,NONE,VFREEBUSY,ZERO REFRESH,VPOLL,NONE,VAVAILABILITY,ZERO POLLSTATUS,VPOLL,NONE,NONE,ONEPLUS POLLSTATUS,VPOLL,COMPLETED,NONE,ZEROORONE POLLSTATUS,VPOLL,DTSTAMP,NONE,ONE POLLSTATUS,VPOLL,DTSTART,NONE,ZEROORONE POLLSTATUS,VPOLL,ORGANIZER,NONE,ONE POLLSTATUS,VPOLL,SUMMARY,NONE,ONE POLLSTATUS,VPOLL,UID,NONE,ONE POLLSTATUS,VPOLL,SEQUENCE,NONE,ZEROORONE POLLSTATUS,VPOLL,ACCEPTRESPONSE,NONE,ZERO POLLSTATUS,VPOLL,ATTACH,NONE,ZERO POLLSTATUS,VPOLL,CATEGORIES,NONE,ZERO POLLSTATUS,VPOLL,CLASS,NONE,ZERO POLLSTATUS,VPOLL,COMMENT,NONE,ZEROPLUS POLLSTATUS,VPOLL,CONTACT,NONE,ZERO POLLSTATUS,VPOLL,CREATED,NONE,ZEROORONE POLLSTATUS,VPOLL,DESCRIPTION,NONE,ZEROORONE POLLSTATUS,VPOLL,DTEND,NONE,ONEEXCLUSIVE,no_duration POLLSTATUS,VPOLL,DURATION,NONE,ONEEXCLUSIVE,no_dtend POLLSTATUS,VPOLL,LASTMODIFIED,NONE,ZEROORONE POLLSTATUS,VPOLL,POLLCOMPLETION,NONE,ZERO POLLSTATUS,VPOLL,POLLITEMID,NONE,ZERO POLLSTATUS,VPOLL,POLLMODE,NONE,ZEROORONE POLLSTATUS,VPOLL,POLLPROPERTIES,NONE,ZERO POLLSTATUS,VPOLL,PRIORITY,NONE,ZEROORONE POLLSTATUS,VPOLL,RELATEDTO,NONE,ZEROPLUS POLLSTATUS,VPOLL,RESOURCES,NONE,ZEROPLUS POLLSTATUS,VPOLL,STATUS,NONE,ZEROORONE POLLSTATUS,VPOLL,URL,NONE,ZEROORONE POLLSTATUS,VPOLL,X,NONE,ZEROPLUS POLLSTATUS,VPOLL,REQUESTSTATUS,NONE,ZERO POLLSTATUS,VPOLL,NONE,VVOTER,ONEPLUS POLLSTATUS,VPOLL,NONE,VALARM,ZEROPLUS POLLSTATUS,VPOLL,NONE,VEVENT,ZEROPLUS POLLSTATUS,VPOLL,NONE,VFREEBUSY,ZERO POLLSTATUS,VPOLL,NONE,VAVAILABILITY,ZERO POLLSTATUS,VPOLL,NONE,VJOURNAL,ZEROPLUS POLLSTATUS,VPOLL,NONE,VTODO,ZEROPLUS POLLSTATUS,VPOLL,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref POLLSTATUS,VPOLL,NONE,X,ZEROPLUS NONE,VPOLL,DTSTAMP,NONE,ONE NONE,VPOLL,UID,NONE,ONE NONE,VPOLL,ORGANIZER,NONE,ONE NONE,VPOLL,ACCEPTRESPONSE,NONE,ZEROORONE NONE,VPOLL,CLASS,NONE,ZEROORONE NONE,VPOLL,CREATED,NONE,ZEROORONE NONE,VPOLL,COMPLETED,NONE,ZEROORONE NONE,VPOLL,DESCRIPTION,NONE,ZEROORONE NONE,VPOLL,DTSTART,NONE,ZEROORONE NONE,VPOLL,LASTMODIFIED,NONE,ZEROORONE NONE,VPOLL,POLLCOMPLETION,NONE,ZEROORONE NONE,VPOLL,POLLMODE,NONE,ZEROORONE NONE,VPOLL,POLLPROPERTIES,NONE,ZEROORONE NONE,VPOLL,PRIORITY,NONE,ZEROORONE NONE,VPOLL,SEQUENCE,NONE,ZEROORONE NONE,VPOLL,STATUS,NONE,ZEROORONE NONE,VPOLL,SUMMARY,NONE,ZEROORONE NONE,VPOLL,URL,NONE,ZEROORONE NONE,VPOLL,DTEND,NONE,ONEEXCLUSIVE,no_duration NONE,VPOLL,DURATION,NONE,ONEEXCLUSIVE,no_dtend NONE,VPOLL,ATTACH,NONE,ZEROPLUS NONE,VPOLL,CATEGORIES,NONE,ZEROPLUS #Non-standard NONE,VPOLL,COMMENT,NONE,ZEROPLUS NONE,VPOLL,CONTACT,NONE,ZEROPLUS NONE,VPOLL,REQUESTSTATUS,NONE,ZEROPLUS NONE,VPOLL,RELATEDTO,NONE,ZEROPLUS NONE,VPOLL,RESOURCES,NONE,ZEROPLUS NONE,VPOLL,X,NONE,ZEROPLUS NONE,VPOLL,POLLWINNER,NONE,ZEROORONE NONE,VPOLL,NONE,VALARM,ZEROPLUS NONE,VPOLL,NONE,VTIMEZONE,ZEROPLUS,must_if_tz_ref NONE,VPOLL,NONE,X,ZEROPLUS NONE,VPOLL,NONE,VEVENT,ZEROPLUS, NONE,VPOLL,NONE,VFREEBUSY,ZEROPLUS NONE,VPOLL,NONE,VAVAILABILITY,ZEROPLUS NONE,VPOLL,NONE,VJOURNAL,ZEROPLUS NONE,VPOLL,NONE,VTODO,ZEROPLUS NONE,VPOLL,NONE,VVOTER,ZEROPLUS NONE,VVOTER,DTSTAMP,NONE,ONE NONE,VVOTER,VOTER,NONE,ONE NONE,VVOTER,CREATED,NONE,ZEROORONE NONE,VVOTER,DESCRIPTION,NONE,ZEROORONE NONE,VVOTER,LASTMODIFIED,NONE,ZEROORONE NONE,VVOTER,SEQUENCE,NONE,ZEROORONE NONE,VVOTER,STATUS,NONE,ZEROORONE NONE,VVOTER,SUMMARY,NONE,ZEROORONE NONE,VVOTER,URL,NONE,ZEROORONE NONE,VVOTER,ATTACH,NONE,ZEROPLUS NONE,VVOTER,CATEGORIES,NONE,ZEROPLUS NONE,VVOTER,COMMENT,NONE,ZEROPLUS NONE,VVOTER,CONTACT,NONE,ZEROPLUS NONE,VVOTER,REQUESTSTATUS,NONE,ZEROPLUS NONE,VVOTER,RELATEDTO,NONE,ZEROPLUS NONE,VVOTER,RESOURCES,NONE,ZEROPLUS NONE,VVOTER,X,NONE,ZEROPLUS NONE,VVOTER,NONE,VALARM,ZERO NONE,VVOTER,NONE,VTIMEZONE,ZERO NONE,VVOTER,NONE,VEVENT,ZERO NONE,VVOTER,NONE,VFREEBUSY,ZERO NONE,VVOTER,NONE,VAVAILABILITY,ZERO NONE,VVOTER,NONE,VJOURNAL,ZERO NONE,VVOTER,NONE,VTODO,ZERO NONE,VVOTER,NONE,XVOTE,ZEROPLUS NONE,VVOTER,NONE,X,ZEROPLUS NONE,XVOTE,POLLITEMID,NONE,ZEROORONE NONE,XVOTE,RESPONSE,NONE,ZEROORONE NONE,XVOTE,COMMENT,NONE,ZEROPLUS NONE,XVOTE,X,NONE,ZEROPLUS NONE,XVOTE,NONE,VALARM,ZEROP NONE,XVOTE,NONE,VTIMEZONE,ZERO NONE,XVOTE,NONE,VEVENT,ZERO NONE,XVOTE,NONE,VFREEBUSY,ZERO NONE,XVOTE,NONE,VAVAILABILITY,ZERO NONE,XVOTE,NONE,VJOURNAL,ZERO NONE,XVOTE,NONE,VTODO,ZERO NONE,XVOTE,NONE,VVOTER,ZERO NONE,XVOTE,NONE,X,ZEROPLUS NONE,VPATCH,DTSTAMP,NONE,ONE NONE,VPATCH,UID,NONE,ONE NONE,VPATCH,PATCHVERSION,NONE,ZEROORONE NONE,VPATCH,PATCHORDER,NONE,ZEROORONE NONE,VPATCH,X,NONE,ZEROPLUS NONE,VPATCH,NONE,XPATCH,ONEPLUS NONE,VPATCH,NONE,X,ZEROPLUS NONE,XPATCH,PATCHTARGET,NONE,ONE NONE,XPATCH,PATCHDELETE,NONE,ZEROPLUS NONE,XPATCH,PATCHPARAMETER,NONE,ZEROPLUS NONE,XPATCH,X,NONE,ZEROPLUS NONE,XPATCH,NONE,VPATCH,ZERO NONE,XPATCH,NONE,XPATCH,ZERO NONE,XPATCH,NONE,X,ZEROPLUS libical-3.0.1/design-data/status.txt000066400000000000000000000071331320431302500173530ustar00rootroot000000000000002.0 STATOK Operation was successfully performed. 2.0.1 STARTSENDATA Start ICAL input; end with . 2.0.11 OKDATAFOLLOWS The request was processed successfully. Reply data follows on the next line and terminates with . 2.0.2 REPLYPENDING A timeout has occurred. The server is still working on the reply. Use CONTINUE to continue waiting for the reply or ABORT to terminate the command. 2.0.3 ABORTED The command currently underway was successsfully aborted. 2.0.4 WILLATTEMPT The specified Calendar is not here but an attempt will be made to deliver the request or reply to the Calendar anyway. 2.0.5 TRUSTEDWILLQUEUE The request or reply will be queued and delivered to the target calendar when its iRIP server contacts this server and issues the SWITCH command. 2.0.6 WILLATTEMPT The specified Calendar is not here but an attempt will be made to deliver the request or reply to the Calendar anyway. 2.0.7 QUEUED The message has been queued for delivery. 2.0.8 QUEUEEMPTY There are no more queued messages. 2.1 FALLBACK Success. Fallback taken on one or more property values. 2.2 NOCOMMANDINPROGRESS An ABORT or CONTINUE was received when no command was in progress 2.2 IGPROP Success. Invalid property ignored. 2.3 IGPARAM Success. invalid property parameter ignored. 2.4 IGXPROP Success. Unknown non-standard property ignored. 2.5 IGXPARAM Success. Unknown non standard property value ignored. 2.6 IGCOMP Success. Invalid calendar component ignored. 2.7 FORWARD Success. Request forwarded to Calendar User. 2.8 ONEEVENT Success. Repeating event ignored. Scheduled as a single component. 2.9 TRUNC Success. Truncated end date time to date boundary. 2.10 ONETODO Success. Repeating VTODO ignored. Scheduled as a single VTODO. 2.11 TRUNCRRULE Success. Unbounded RRULE clipped at some finite number of instances 3.0 INVPROPNAME Invalid property name. 3.1 INVPROPVAL Invalid property value. 3.2 INVPARAM Invalid property parameter. 3.3 INVPARAMVAL Invalid property parameter value. 3.4 INVCOMP Invalid calendar component sequence. 3.5 INVTIME Invalid date or time. 3.6 INVRULE Invalid rule. 3.7 INVCU Invalid Calendar User. 3.8 NOAUTH No authority. 3.9 BADVERSION Unsupported version. 3.10 TOOBIG Request entity too large. 3.11 MISSREQCOMP Required component or property missing. 3.12 UNKCOMP Unknown component or property found. 3.13 BADCOMP Unsupported component or property found 3.14 NOCAP Unsupported capability. 4.0 BUSY Event conflict. Date/time is busy. 5.0 MAYBE Request MAY supported. 5.1 UNAVAIL Service unavailable. 5.2 NOSERVICE Invalid calendar service. 5.3 NOSCHED No scheduling support for user. 6.1 AUTHENTICATEFAILURE Unsupported authentication mechanism, credentials rejected 6.2 AUTHENTICATIONABORTED Sender aborted authentication, authentication exchange cancelled 8.0 GENERALFAILURE A failure has occurred in the Receiver that prevents the operation from succeeding. 8.1 SERVERTOOBUSY The iRIP Receiver is too busy. 8.2 ICALOBJECTTOOBIG Object has exceeded the server's size limit. 8.3 DATETOOLARGE A DATETIME value was too far in the future to be represented on this Calendar. 8.4 DATETOOSMALL A DATETIME value was too far in the past to be represented on this Calendar. 9.0 INVALIDIRIPCOMMAND An unrecongnized command was received. 9.1 UNEXPECTEDCOMMAND The command is not allowed for the server's current state. 10.1 REFERRAL Accompanied by an alternate address. 10.2 SERVERSHUTDOWN The server is shutting down. 10.3 SERVERSTOPPING FLOOD 2 10.4 EXCEEDEDQUOTAS The operation would cause a resource to exceed the allocated quota 10.5 QUEUEDTOOLONG The ITIP message has been queued too long. Delivery has been aborted. libical-3.0.1/design-data/value-types.csv000066400000000000000000000102641320431302500202610ustar00rootroot00000000000000"#Name","C icalvalue_kind Enum","C type& gen flag","Python","Component Values","Enum Values" "BINARY","5011","(m)const char*","file","unitary", "BOOLEAN","5021","(a)int","integer","unitary", "CAL-ADDRESS","5023","(a)const char*","string","unitary", "DATE","5002","(m)struct icaltimetype","Time","unitary", "DATE-TIME","5028","(m)struct icaltimetype","Time","unitary", "DURATION","5020","(a)struct icaldurationtype","Duration","unitary", "FLOAT","5013","(a)float","float","unitary", "INTEGER","5017","(a)int","integer","unitary", "PERIOD","5014","(a)struct icalperiodtype","Period","unitary", "RECUR","5026","(m)struct icalrecurrencetype","RecurrenceSet","unitary", "TEXT","5008","(a)const char*","string","unitary", "URI","5018","(a)const char*","string","unitary", "UTC-OFFSET","5029","(a)int","integer","unitary", "QUERY","5001","(a)const char*","string","unitary", "#Non-standard multi-valued types",,,, "ATTACH","5003","(m)icalattach *","none","URI;BINARY", "DATE-TIME-DATE","5036","(m)struct icaltimetype","Time","DATE-TIME;DATE", "DATE-TIME-PERIOD","5015","(m)struct icaldatetimeperiodtype","none","DATE-TIME;DATE;PERIOD", "TRIGGER","5024","(m)struct icaltriggertype","string","DURATION;DATE-TIME", "#Non-standard property enumeration types",,,, "#METHOD:POLLSTATUS from draft-york-vpoll",,,, "METHOD","5030","(a)enum icalproperty_method","string","unitary","X=10500;PUBLISH;REQUEST;REPLY;ADD;CANCEL;REFRESH;COUNTER;DECLINECOUNTER;CREATE;READ;RESPONSE;MOVE;MODIFY;GENERATEUID;DELETE;POLLSTATUS;NONE=10599" "X-LIC-CLASS","5025","(a)enum icalproperty_xlicclass","string","unitary","X=11100;PUBLISH-NEW;PUBLISH-UPDATE;PUBLISH-FREEBUSY;REQUEST-NEW;REQUEST-UPDATE;REQUEST-RESCHEDULE;REQUEST-DELEGATE;REQUEST-NEW-ORGANIZER;REQUEST-FORWARD;REQUEST-STATUS;REQUEST-FREEBUSY;REPLY-ACCEPT;REPLY-DECLINE;REPLY-DELEGATE;REPLY-CRASHER-ACCEPT;REPLY-CRASHER-DECLINE;ADD-INSTANCE;CANCEL-EVENT;CANCEL-INSTANCE;CANCEL-ALL;REFRESH;COUNTER;DECLINECOUNTER;MALFORMED;OBSOLETE;MISSEQUENCED;UNKNOWN;NONE=11199" "ACTION","5027","(a)enum icalproperty_action","string","unitary","X=10000;AUDIO;DISPLAY;EMAIL;PROCEDURE;NONE=10099" "STATUS","5005","(a)enum icalproperty_status","string","unitary","X=10900;TENTATIVE;CONFIRMED;COMPLETED;NEEDS-ACTION;CANCELLED;IN-PROCESS;DRAFT;FINAL;SUBMITTED;PENDING;FAILED;DELETED;NONE=10999" "TRANSP","5006","(a)enum icalproperty_transp","string","unitary","X=11000;OPAQUE;OPAQUE-NOCONFLICT;TRANSPARENT;TRANSPARENT-NOCONFLICT;NONE=11099" "CLASS","5019","(m)enum icalproperty_class","string","unitary","X=10300;PUBLIC;PRIVATE;CONFIDENTIAL;NONE=10399" "#Other non-standard",,,, "REQUEST-STATUS","5009","(a)struct icalreqstattype","string","unitary" "GEO","5004","(m)struct icalgeotype","tuple","unitary", "STRING","5007","(a)const char*","string","unitary", "X","5022","(m)const char*","string","unitary", "#CAP enumeration types",,,, "CMD","5010","(a)enum icalproperty_cmd","string","unitary","X=10400;ABORT;CONTINUE;CREATE;DELETE;GENERATE-UID;GET-CAPABILITY;IDENTIFY;MODIFY;MOVE;REPLY;SEARCH;SET-LOCALE;NONE=10499" "QUERY-LEVEL","5012","(a)enum icalproperty_querylevel","string","unitary","X=10800;CAL-QL-1;CAL-QL-NONE;NONE=10899" "CAR-LEVEL","5016","(a)enum icalproperty_carlevel","string","unitary","X=10200;CAR-NONE;CAR-MIN;CAR-FULL-1;NONE=10299" "ANY","5000",,,, "NO","5031",,,, "#VAVAILABILITY types","RFC 7953 Section 3.2",,, "BUSYTYPE","5032","(a)enum icalproperty_busytype","string","unitary","X=10100;BUSY;BUSY-UNAVAILABLE;BUSY-TENTATIVE;NONE=10199" "#VPOLL types","draft-york-vpoll",,, "POLLMODE","5033","(a)enum icalproperty_pollmode","string","unitary","X=10700;BASIC;NONE=10799" "POLLCOMPLETION","5034","(a)enum icalproperty_pollcompletion","string","unitary","X=10600;SERVER;SERVER-SUBMIT;SERVER-CHOICE;CLIENT;NONE=10699" "#Task Extension types","draft-apthorp-ical-tasks",,, "TASKMODE","5035","(a)enum icalproperty_taskmode","string","unitary","X=11200;AUTOMATIC-COMPLETION;AUTOMATIC-FAILURE;AUTOMATIC-STATUS;NONE=11299" "#NOTE for updaters. Preserve the icalvalue_kind Enum values and property Enum values to aid forward compatibility" "# New Enum values for an existing icalvalue_kind should be inserted before the corresponding NONE value" "# New icalvalue_kind types should start their Enum value after the highest NONE value (currently 11299)" libical-3.0.1/doc/000077500000000000000000000000001320431302500136505ustar00rootroot00000000000000libical-3.0.1/doc/AddingOrModifyingComponents.txt000066400000000000000000000012731320431302500220170ustar00rootroot00000000000000 How to add or change Components, Properties, Values or Parameters Adding or modifying values --------------------------- You may have to modify these files or data structures file design-data/value-c-types.txt file design-data/prop-to-val.txt table parameter_map[] in icalenums.c enum icalvalue_kind in icalenum.h table value_map[] in icalenums.c enum icalparameter_value in icalenum.h table propval_map[] in icalenums.c function icalvalue_as_ical_string() in icalvalue.c function icalvalue_new_from_string_with_error() in icalvalue.c When you are done, if you changed any files in the design-data directory, regnerate derived datatypes in src/libical with "make derived" or "make icalvalue" libical-3.0.1/doc/CMakeLists.txt000066400000000000000000000026551320431302500164200ustar00rootroot00000000000000add_subdirectory(reference) # # API docs # macro(_join_list _var _sep) set(${_var} "") foreach(_element ${ARGN}) set(${_var} "${${_var}}${_sep}${_element}") endforeach() endmacro() find_package(Doxygen) set_package_properties(Doxygen PROPERTIES TYPE OPTIONAL DESCRIPTION "API Documentation system" URL "http://www.doxygen.org" PURPOSE "Needed to build the API documention." ) if(DOXYGEN_FOUND) file(GLOB _dox_deps *.dox *.html) file(GLOB _all_hdrs ${CMAKE_SOURCE_DIR}/src/libical/*.h ${CMAKE_SOURCE_DIR}/src/libical/*.c ${CMAKE_BINARY_DIR}/src/libical/*.h ${CMAKE_SOURCE_DIR}/src/libicalss/*.h ${CMAKE_SOURCE_DIR}/src/libicalss/*.c ${CMAKE_BINARY_DIR}/src/libicalss/*.h ${CMAKE_SOURCE_DIR}/src/libicalvcal/*.h ${CMAKE_SOURCE_DIR}/src/libicalvcal/*.c ${CMAKE_BINARY_DIR}/src/libicalvcal/*.h ) list(APPEND _all_hdrs ${_dox_deps}) _join_list(DOXYGEN_INPUT " " ${_all_hdrs}) #apidox generation using doxygen configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.cmake ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile ) add_custom_command( OUTPUT ${CMAKE_BINARY_DIR}/apidocs/html/index.html COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile DEPENDS ${_all_hdrs} ${_dox_deps} ${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.cmake WORKING_DIRECTORY ${CMAKE_BINARY_DIR} ) add_custom_target(docs DEPENDS ${CMAKE_BINARY_DIR}/apidocs/html/index.html ) endif() libical-3.0.1/doc/Doxyfile.cmake000066400000000000000000000166101320431302500164410ustar00rootroot00000000000000#--------------------------------------------------------------------------- # Project related configuration options #--------------------------------------------------------------------------- PROJECT_NAME = "Libical API Documentation" PROJECT_NUMBER = @PROJECT_VERSION@ OUTPUT_DIRECTORY = apidocs #CREATE_SUBDIRS = NO OUTPUT_LANGUAGE = English BRIEF_MEMBER_DESC = YES REPEAT_BRIEF = YES ABBREVIATE_BRIEF = "The \$name class" \ "The \$name widget" \ "The \$name file" \ is \ provides \ specifies \ contains \ represents \ a \ an \ the ALWAYS_DETAILED_SEC = NO INLINE_INHERITED_MEMB = NO FULL_PATH_NAMES = NO STRIP_FROM_PATH = STRIP_FROM_INC_PATH = SHORT_NAMES = NO JAVADOC_AUTOBRIEF = NO MULTILINE_CPP_IS_BRIEF = NO INHERIT_DOCS = YES SEPARATE_MEMBER_PAGES = NO TAB_SIZE = 8 OPTIMIZE_OUTPUT_FOR_C = YES OPTIMIZE_OUTPUT_JAVA = NO BUILTIN_STL_SUPPORT = NO DISTRIBUTE_GROUP_DOC = NO SUBGROUPING = YES #--------------------------------------------------------------------------- # Build related configuration options #--------------------------------------------------------------------------- EXTRACT_ALL = NO EXTRACT_PRIVATE = NO EXTRACT_STATIC = YES EXTRACT_LOCAL_CLASSES = YES EXTRACT_LOCAL_METHODS = NO HIDE_UNDOC_MEMBERS = NO HIDE_UNDOC_CLASSES = NO HIDE_FRIEND_COMPOUNDS = YES HIDE_IN_BODY_DOCS = NO INTERNAL_DOCS = NO CASE_SENSE_NAMES = YES HIDE_SCOPE_NAMES = NO SHOW_INCLUDE_FILES = NO INLINE_INFO = YES SORT_MEMBER_DOCS = YES SORT_MEMBERS_CTORS_1ST = YES SORT_BRIEF_DOCS = YES SORT_BY_SCOPE_NAME = NO GENERATE_TODOLIST = NO GENERATE_TESTLIST = YES GENERATE_BUGLIST = YES GENERATE_DEPRECATEDLIST = YES ENABLED_SECTIONS = MAX_INITIALIZER_LINES = 30 SHOW_USED_FILES = YES FILE_VERSION_FILTER = #--------------------------------------------------------------------------- # configuration options related to warning and progress messages #--------------------------------------------------------------------------- QUIET = NO WARNINGS = YES WARN_IF_UNDOCUMENTED = YES WARN_IF_DOC_ERROR = YES WARN_NO_PARAMDOC = YES WARN_FORMAT = "$file:$line: $text" WARN_LOGFILE = doxygen.log #--------------------------------------------------------------------------- # configuration options related to the input files #--------------------------------------------------------------------------- INPUT = @DOXYGEN_INPUT@ FILE_PATTERNS = *.cpp \ *.c \ *.cc \ *.cxx \ *.h \ *.hh \ *.hxx \ *.hpp \ *.dox RECURSIVE = YES EXCLUDE = @CMAKE_SOURCE_DIR@/src/java \ @CMAKE_SOURCE_DIR@/src/php \ @CMAKE_SOURCE_DIR@/src/python EXCLUDE_SYMLINKS = NO EXCLUDE_PATTERNS = */.svn/* \ */.git/* \ */cmake/* \ *.moc.* \ moc* \ *.all_cpp.* \ *unload.* \ */test/* \ */tests/* \ *_p.cpp \ *_export.h EXAMPLE_PATH = EXAMPLE_PATTERNS = * EXAMPLE_RECURSIVE = NO IMAGE_PATH = @CMAKE_SOURCE_DIR@/docs INPUT_FILTER = FILTER_PATTERNS = FILTER_SOURCE_FILES = NO #--------------------------------------------------------------------------- # configuration options related to the alphabetical class index #--------------------------------------------------------------------------- ALPHABETICAL_INDEX = YES COLS_IN_ALPHA_INDEX = 5 IGNORE_PREFIX = #--------------------------------------------------------------------------- # do NOT generate any formats other than html #--------------------------------------------------------------------------- SOURCE_BROWSER = NO GENERATE_HTML = YES GENERATE_LATEX = NO GENERATE_RTF = NO GENERATE_XML = NO GENERATE_AUTOGEN_DEF = NO GENERATE_PERLMOD = NO DISABLE_INDEX = NO #--------------------------------------------------------------------------- # configuration options related to the HTML output #--------------------------------------------------------------------------- GENERATE_HTML = YES HTML_OUTPUT = html HTML_FILE_EXTENSION = .html HTML_HEADER = HTML_FOOTER = HTML_STYLESHEET = GENERATE_HTMLHELP = NO CHM_FILE = HHC_LOCATION = GENERATE_CHI = NO BINARY_TOC = NO TOC_EXPAND = NO DISABLE_INDEX = NO ENUM_VALUES_PER_LINE = 4 GENERATE_TREEVIEW = NO TREEVIEW_WIDTH = 250 #--------------------------------------------------------------------------- # Configuration options related to the preprocessor #--------------------------------------------------------------------------- ENABLE_PREPROCESSING = YES MACRO_EXPANSION = YES EXPAND_ONLY_PREDEF = NO SEARCH_INCLUDES = YES INCLUDE_PATH = INCLUDE_FILE_PATTERNS = PREDEFINED = LIBICAL_ICAL_EXPORT="" \ LIBICAL_ICALSS_EXPORT="" \ LIBICAL_VCAL_EXPORT="" \ LIBICAL_ICAL_NO_EXPORT="" \ LIBICAL_ICALS_NO_EXPORT="" \ LIBICAL_VCAL_NO_EXPORT="" EXPAND_AS_DEFINED = SKIP_FUNCTION_MACROS = YES #--------------------------------------------------------------------------- # Configuration::additions related to external references #--------------------------------------------------------------------------- GENERATE_TAGFILE = libical.tag ALLEXTERNALS = NO EXTERNAL_GROUPS = YES PERL_PATH = /usr/bin/perl #--------------------------------------------------------------------------- # Configuration options related to the dot tool #--------------------------------------------------------------------------- CLASS_DIAGRAMS = YES HIDE_UNDOC_RELATIONS = YES HAVE_DOT = YES CLASS_GRAPH = YES COLLABORATION_GRAPH = NO GROUP_GRAPHS = NO UML_LOOK = NO TEMPLATE_RELATIONS = NO INCLUDE_GRAPH = NO INCLUDED_BY_GRAPH = NO CALL_GRAPH = NO CALLER_GRAPH = NO GRAPHICAL_HIERARCHY = YES DIRECTORY_GRAPH = YES DOT_IMAGE_FORMAT = png DOT_PATH = DOTFILE_DIRS = MAX_DOT_GRAPH_DEPTH = 1000 DOT_TRANSPARENT = NO DOT_MULTI_TARGETS = NO GENERATE_LEGEND = YES DOT_CLEANUP = YES #--------------------------------------------------------------------------- # Configuration::additions related to the search engine #--------------------------------------------------------------------------- SEARCHENGINE = YES SERVER_BASED_SEARCH = NO libical-3.0.1/doc/Mainpage.dox000066400000000000000000000024641320431302500161130ustar00rootroot00000000000000/*! @mainpage Libical - an implementation of iCalendar protocols and data formats @section about About Libical is an Open Source implementation of the iCalendar protocols and protocol data units. The iCalendar specification describes how calendar clients can communicate with calendar servers so users can store their calendar data and arrange meetings with other users. Libical implements RFC2445, RFC2446 and some of RFC2447. @section license License The code and datafiles in this distribution are licensed under the Mozilla Public License (MPL) v2.0. See http://www.mozilla.org/MPL for a copy of the license. Alternately, you may use libical under the terms of the GNU Library General Public License (LGPL) v2.1. See http://www.gnu.org/licenses/lgpl-2.1.txt for a copy of the license. This dual license ensures that the library can be incorporated into both proprietary code and GPL'd programs, and will benefit from improvements made by programmers in both realms. I will only accept changes into my version of the library if they are similarly dual-licensed. @section acknowledgements Acknowledgments Portions of this distribution are (C) Copyright 1996 Apple Computer, Inc., AT&T Corp., International Business Machines Corporation and Siemens Rolm Communications Inc. See src/libicalvcal/README.TXT for details. */ libical-3.0.1/doc/UsingLibical.md000066400000000000000000001353061320431302500165470ustar00rootroot00000000000000# Using Libical > Author: Eric Busboom > > Date: January 2001 ## 1 Introduction Libical is an Open Source implementation of the iCalendar protocols and protocol data units. The iCalendar specification describes how calendar clients can communicate with calendar servers so users can store their calendar data and arrange meetings with other users. Libical implements [RFC5545][], [RFC5546][], [RFC7529][]; the iCalendar extensions in [RFC6638][]; and some of [RFC6047][]. This documentation assumes that you are familiar with the iCalendar standards RFC5545 and RFC5546. These specifications are available at the [IETF Tools][] website: [RFC5545]: https://tools.ietf.org/html/rfc5545 [RFC5546]: https://tools.ietf.org/html/rfc5546 [RFC7529]: https://tools.ietf.org/html/rfc7529 [RFC6638]: https://tools.ietf.org/html/rfc6638 [RFC6047]: https://tools.ietf.org/html/rfc6047 [IETF Tools]: https://tools.ietf.org/ ### 1.1 The libical project This code is under active development. If you would like to contribute to the project, visit ### 1.2 License The code and datafiles in this distribution are licensed under the Mozilla Public License version 2.0. See for a copy of the license. Alternately, you may use libical under the terms of the GNU Lesser General Public License, version 2.1. See for a copy of the LGPL. This dual license ensures that the library can be incorporated into both proprietary code and GPL'd programs, and will benefit from improvements made by programmers in both realms. I will only accept changes into my version of the library if they are similarly dual-licensed. ### 1.3 Example Code A lot of the documentation for this library is in the form of example code. These examples are in the `examples/` directory of the distribution. Also look in `src/test/` for additional annotated examples. ## 2 Building the Library Libical uses autoconf to generate makefiles. It should build with no adjustments on Linux, FreeBSD and Solaris under `gcc`. Some versions have been successfully built on MacOS, Solaris, UnixWare, And Tru64 UNIX without `gcc`, but you may run into problems with a particular later version. For a more complete guide to building the library, see the `README` file in the distribution. ## 3 Structure The iCalendar data model is based on four types of objects: *components*, *properties*, *values* and *parameters*. Properties are the fundamental unit of information in iCalendar, and they work a bit like a hash entry, with a constant key and a variable value. Properties may also have modifiers, called parameters. In the iCal content line ```ical ORGANIZER;ROLE=CHAIR:MAILTO:mrbig@host.com ``` The property name is `ORGANIZER`, the value of the property is `mrbig@host.com` and the `ROLE` parameter specifies that Mr Big is the chair of the meetings associated with this property. Components are groups of properties that represent the core objects of a calendar system, such as events or timezones. Components are delimited by `BEGIN` and `END` tags. When a component is sent across a network, if it is un-encrypted, it will look something like: ```ical BEGIN:VCALENDAR METHOD:REQUEST PRODID: -//hacksw/handcal//NONSGML v1.0//EN BEGIN:VEVENT DTSTAMP:19980309T231000Z UID:guid-1.host1.com ORGANIZER;ROLE=CHAIR:MAILTO:mrbig@host.com ATTENDEE;RSVP=TRUE;ROLE=REQ-PARTICIPANT;CUTYPE=GROUP: MAILTO:employee-A@host.com DESCRIPTION:Project XYZ Review Meeting CATEGORIES:MEETING CLASS:PUBLIC CREATED:19980309T130000Z SUMMARY:XYZ Project Review DTSTART;TZID=US-Eastern:19980312T083000 DTEND;TZID=US-Eastern:19980312T093000 LOCATION:1CP Conference Room 4350 END:VEVENT END:VCALENDAR ``` Note that components can be nested; this example has both a VCALENDAR and a VEVENT component, one nested inside the other. ### 3.1 Core iCal classes Libical is an object-based, data-oriented library. Nearly all of the routines in the library are associated with an opaque data types and perform some operation on that data type. Although the library does not actually have classes, we will use those terms since the behavior of these associations of data and routines is very similar to a class. #### 3.1.1 Properties Properties are represented with the `icalproperty` class and its many "derived" classes with one "derived" class per property type in [RFC5545][]. Again, there is no actual inheritance relations, but there are clusters of routines that make this term useful. A property is a container for a single value and a set of parameters. #### 3.1.2 Components In libical, components are represented with the `icalcomponent` class. `icalcomponent` is a container for a set of other components and properties. #### 3.1.3 Values Values are represented in a similar way to properties; a base class and many "derived " classes. A value is essentially a abstract handle on a single fundamental type, a structure or a union. #### 3.1.4 Parameters Parameters are represented in a similar way to properties, except that they contain only one value. ### 3.2 Other elements of libical In addition to the core iCal classes, libical has many other types, structures, and classes that aid in creating and using iCal components. #### 3.2.1 Enumerations and types Libical is strongly typed, so every component, property, parameter, and value type has an enumeration, and some have an associated structure or union. #### 3.2.2 The parser The libical parser offers a variety of ways to convert [RFC5545][] text into a libical internal component structure. The parser can parse blocks of text as a string, or it can parse line-by-line. #### 3.2.3 Error objects Libical has a substantial error reporting system for both programming errors and component usage errors. #### 3.2.4 Memory Management Since many of libicals interfaces return strings, the library has its own memory management system to elimiate the need to free every string returned from the library. #### 3.2.5 Storage classes The library also offers several classes to store components to files, memory or databases. ## 4 Differences From RFCs Libical has been designed to follow the standards as closely as possible, so that the key objects in the standards are also key objects in the library. However, there are a few areas where the specifications are (arguably) irregular, and following them exactly would result in an unfriendly interface. These deviations make libical easier to use by maintaining a self-similar interface. ### 4.1 Pseudo Components Libical defines components for groups of properties that look and act like components, but are not defined as components in the specification. `XDAYLIGHT` and `XSTANDARD` are notable examples. These pseudo components group properties within the `VTIMEZONE` components. For instanace, the timezone properties associated with daylight savings time starts with `BEGIN:DAYLIGHT` and ends with `END:DAYLIGHT`, just like other components, but is not defined as a component in [RFC5545][] (see [section 3.6.5][RFC5545 3.6.5]) In libical, this grouping is represented by the `XDAYLIGHT` component. Standard iCal components all start with the letter "V," while pseudo components start with "X." There are also pseudo components that are conceptually derived classes of `VALARM`. [RFC5546][] defines what properties may be included in each component, and for `VALARM`, the set of properties it may have depends on the value of the `ACTION` property. For instance, if a `VALARM` component has an `ACTION` property with the value of `AUDIO`, the component must also have an `ATTACH` property. However, if the `ACTION` value is `DISPLAY`, the component must have a `DESCRIPTION` property. To handle these various, complex restrictions, libical has pseudo components for each type of alarm: `XAUDIOALARM`, `XDISPLAYALARM`, `XEMAILALARM` and `XPROCEDUREALARM`. [RFC5545 3.6.5]: ### 4.2 Combined Values Many values can take more than one type. `TRIGGER`, for instance, can have a value type of with `DURATION` or of `DATE-TIME`. These multiple types make it difficult to create routines to return the value associated with a property. It is natural to have interfaces that would return the value of a property, but it is cumbersome for a single routine to return multiple types. So, in libical, properties that can have multiple types are given a single type that is the union of their RFC5545 types. For instance, in libical, the value of the `TRIGGER` property resolves to struct `icaltriggertype`. This type is a union of a `DURATION` and a `DATE-TIME`. ### 4.3 Multi-Valued Properties Some properties, such as `CATEGORIES` have only one value type, but each `CATEGORIES` property can have multiple value instances. This also results in a cumbersome interface -- `CATEGORIES` accessors would have to return a list while all other accessors returned a single value. In libical, all properties have a single value, and multi-valued properties are broken down into multiple single valued properties during parsing. That is, an input line like, ```ical CATEGORIES: work, home ``` becomes in libical's internal representation ```ical CATEGORIES: work CATEGORIES: home ``` Oddly, [RFC5545][] allows some multi-valued properties (like `FREEBUSY`) to exist as both a multi-values property and as multiple single value properties, while others (like `CATEGORIES`) can only exist as single multi-valued properties. This makes the internal representation for `CATEGORIES` illegal. However when you convert a component to a string, the library will collect all of the `CATEGORIES` properties into one. ## 5 Using libical ### 5.1 Creating Components There are three ways to create components in Libical: 1. creating individual objects and assembling them, 2. building entire objects in massive vaargs calls, 3. and parsing a text file containing iCalendar data. #### 5.1.1 Constructor Interfaces Using constructor interfaces, you create each of the objects separately and then assemble them in to components: ```c icalcomponent *event; icalproperty *prop; icalparameter *param; struct icaltimetype atime; // create new VEVENT component event = icalcomponent_new(ICAL_VEVENT_COMPONENT); // add DTSTAMP property to the event prop = icalproperty_new_dtstamp(atime); icalcomponent_add_property(event, prop); // add UID property to the event prop = icalproperty_new_uid("guid-1.example.com"); icalcomponent_add_property(event, prop); // add ORGANIZER (with ROLE=CHAIR) to the event prop = icalproperty_new_organizer("mrbig@example.com"); param = icalparameter_new_role(ICAL_ROLE_CHAIR); icalproperty_add_parameter(prop, param); icalcomponent_add_property(event, prop); ``` Notice that libical uses a semi-object-oriented style of interface. Most things you work with are objects, that are instantiated with a constructor that has "new" in the name. Also note that, other than the object reference, most structure data is passed in to libical routines by value. Libical has some complex but very regular memory handling rules. These are detailed in section [sec:memory]. If any of the constructors fail, they will return 0. If you try to insert 0 into a property or component, or use a zero-valued object reference, libical will either silently ignore the error or will abort with an error message. This behavior is controlled by a compile time flag (`ICAL_ERRORS_ARE_FATAL`), and will abort by default. #### 5.1.2 varargs Constructors There is another way to create complex components, which is arguably more elegant, if you are not horrified by varargs. The varargs constructor interface allows you to create intricate components in a single block of code. Here is the previous examples in the vaargs style. ```c icalcomponent *calendar; struct icaltimetype atime; calendar = icalcomponent_vanew( ICAL_VCALENDAR_COMPONENT, icalproperty_new_version("2.0"), icalproperty_new_prodid( "-//RDU Software//NONSGML HandCal//EN"), icalcomponent_vanew( ICAL_VEVENT_COMPONENT, icalproperty_new_dtstamp(atime), icalproperty_new_uid("guid-1.host1.com"), icalproperty_vanew_organizer( "mrbig@host.com", icalparameter_new_role(ICAL_ROLE_CHAIR), NULL), icalproperty_vanew_attendee( "employee-A@host.com", icalparameter_new_role( ICAL_ROLE_REQPARTICIPANT), icalparameter_new_rsvp(1), icalparameter_new_cutype(ICAL_CUTYPE_GROUP), NULL), icalproperty_new_location( "1CP Conference Room 4350"), NULL), NULL); ``` This form is similar to the constructor form, except that the constructors have `vanew` instead of `new` in the name. The arguments are similar too, except that the component constructor can have a list of properties, and the property constructor can have a list of parameters. *Be sure to terminate every list with a `NULL` (or a *`(void 0)`*, or your code will crash, if you are lucky*. The reason you can't use 0 itself is that depending on what platform you are on, `sizeof(int) ≠ sizeof(void*)`. #### 5.1.3 Parsing Text Files The final way to create components will probably be the most common; you can create components from [RFC5545][] compliant text. If you have the string in memory, use ```c icalcomponent* icalparser_parse_string(char* str); ``` If the string contains only one component, the parser will return the component in libical form. If the string contains multiple components, the multiple components will be returned as the children of an `ICAL_XROOT_COMPONENT` component. Parsing a whole string may seem wasteful if you want to pull a large component off of the network or from a file; you may prefer to parse the component line by line. This is possible too by using: ```c icalparser* icalparser_new(); void icalparser_free( icalparser* parser); icalparser_get_line( icalparser *parser, char* (*read_stream)(char *s, size_t size, void* d)); icalparser_add_line( icalparser *parser, char *line); icalparser_set_gen_data( icalparser *parser, void *data); ``` These routines will construct a parser object to which you can add lines of input and retrieve any components that the parser creates from the input. These routines work by specifing an adaptor routine to get string data from a source. For example: ```c char* read_stream(char *s, size_t size, void *d) { return fgets(s, size, (FILE*)d); } int main(int argc, char *argv[]) { char *line; icalcomponent *component; icalparser *parser = icalparser_new(); // open file (first command-line argument) FILE* stream = fopen(argv[1], "r"); // associate the FILE with the parser so that read_stream // will have access to it icalparser_set_gen_data(parser, stream); do { // read the file, line-by-line, and parse the data line = icalparser_get_line(parser, read_stream); component = icalparser_add_line(parser, line); // if icalparser has finished parsing a component, // it will return it if (component != 0) { // print the parsed component printf("%s", icalcomponent_as_ical_string(component)); icalparser_clean(parser); printf("\n---------------\n"); icalcomponent_free(component); } } while (line != 0); return 0; } ``` The parser object parameterizes the routine used to get input lines with `icalparser_set_gen_data()`and `icalparser_get_line()`. In this example, the routine `read_stream()` will fetch the next line from a stream, with the stream passed in as the `void*` parameter d. The parser calls `read_stream()` from `icalparser_get_line()`, but it also needs to know what stream to use. This is set by the call to `icalparser_set_gen_data()`. By using a different routine for `read_stream()` or passing in different data with `icalparser_set_gen_data()`, you can connect to any data source. Using the same mechanism, other implementations could read from memory buffers, sockets or other interfaces. Since the example code is a very common way to use the parser, there is a convenience routine; ```c icalcomponent* icalparser_parse( icalparser *parser, char* (*line_gen_func)(char *s, size_t size, void* d)); ``` To use this routine, you still must construct the parser object and pass in a reference to a line reading routine. If the parser can create a single component from the input, it will return a pointer to the newly constructed component. If the parser can construct multiple components from the input, it will return a reference to an `XROOT` component (of type `ICAL_XROOT_COMPONENT`.) This `XROOT` component will hold all of the components constructed from the input as children. ```c char* read_stream(char *s, size_t size, void *d) { return fgets(s, size, (FILE*)d); } int main(int argc, char *argv[]) { char* line; icalcomponent *component; icalparser *parser = icalparser_new(); // open file (first command-line argument) FILE* stream = fopen(argv[1], "r"); // associate the FILE with the parser so that read_stream // will have access to it icalparser_set_gen_data(parser, stream); // parse the opened file component = icalparser_parse(parser, read_stream); if (component != 0) { // print the parsed component printf("%s", icalcomponent_as_ical_string(component)); icalcomponent_free(component); } icalparser_free(parser); return 0; } ``` ### 5.2 Accessing Components Given a reference to a component, you probably will want to access the properties, parameters and values inside. Libical interfaces let you find sub-component, add and remove sub-components, and do the same three operations on properties. #### 5.2.1 Finding Components To find a sub-component of a component, use: ```c icalcomponent* icalcomponent_get_first_component( icalcomponent* component, icalcomponent_kind kind); ``` This routine will return a reference to the first component of the type `kind`. The key kind values, listed in icalenums.h are: - `ICAL_ANY_COMPONENT` - `ICAL_VEVENT_COMPONENT` - `ICAL_VTODO_COMPONENT` - `ICAL_VJOURNAL_COMPONENT` - `ICAL_VCALENDAR_COMPONENT` - `ICAL_VFREEBUSY_COMPONENT` - `ICAL_VALARM_COMPONENT` These are only the most common components; there are many more listed in icalenums.h. As you might guess, if there is more than one subcomponent of the type you have chosen, this routine will return only the first. to get at the others, you need to iterate through the component. #### 5.2.2 Iterating Through Components Iteration requires a second routine to get the next subcomponent after the first: ```c icalcomponent* icalcomponent_get_next_component( icalcomponent* component, icalcomponent_kind kind); ``` With the 'first' and 'next' routines, you can create a for loop to iterate through all of a components subcomponents ```c icalcomponent *c; for(c = icalcomponent_get_first_component(comp, ICAL_ANY_COMPONENT); c != 0; c = icalcomponent_get_next_component(comp, ICAL_ANY_COMPONENT)) { do_something(c); } ``` This code bit wil iterate through all of the subcomponents in `comp` but you can select a specific type of component by changing `ICAL_ANY_COMPONENT` to another component type. #### 5.2.3 Using Component Iterators The iteration model in the previous section requires the component to keep the state of the iteration. So, you could not use this model to perform a sorting operations, since you'd need two iterators and there is only space for one. If you ever call `icalcomponent_get_first_component()` when an iteration is in progress, the pointer will be reset to the beginning. To solve this problem, there are also external iterators for components. The routines associated with these external iterators are: ```c icalcompiter icalcomponent_begin_component( icalcomponent* component, icalcomponent_kind kind); icalcompiter icalcomponent_end_component( icalcomponent* component, icalcomponent_kind kind); icalcomponent* icalcompiter_next( icalcompiter* i); icalcomponent* icalcompiter_prior( icalcompiter* i); icalcomponent* icalcompiter_deref( icalcompiter* i); ``` The `*_begin_*()` and `*_end_*()` routines return a new iterator that points to the beginning and end of the list of subcomponent for the given component, and the kind argument works like the kind argument for internal iterators. After creating an iterators, use `*_next()` and `*_prior()` to step forward and backward through the list and get the component that the iterator points to, and use `_deref()` to return the component that the iterator points to without moving the iterator. All routines will return 0 when they move to point off the end of the list. Here is an example of a loop using these routines: ```c for(i = icalcomponent_begin_component(impl->cluster, ICAL_ANY_COMPONENT); icalcompiter_deref(&i)!= 0; icalcompiter_next(&i)) { icalcomponent *this = icalcompiter_deref(&i); } ``` #### 5.2.4 Removing Components Removing an element from a list while iterating through the list with the internal iterators can cause problems, since you will probably be removing the element that the internal iterator points to. The `_remove()` routine will keep the iterator valid by moving it to the next component, but in a normal loop, this will result in two advances per iteration, and you will remove only every other component. To avoid the problem, you will need to step the iterator ahead of the element you are going to remove, like this: ```c for(c = icalcomponent_get_first_component(parent_comp, ICAL_ANY_COMPONENT); c != 0; c = next) { next = icalcomponent_get_next_component(parent_comp, ICAL_ANY_COMPONENT); icalcomponent_remove_component(parent_comp,c); } ``` Another way to remove components is to rely on the side effect of `icalcomponent_remove_component()`: if component iterator in the parent component is pointing to the child that will be removed, it will move the iterator to the component after the child. The following code will exploit this behavior: ```c icalcomponent_get_first_component(parent_comp,ICAL_VEVENT_COMPONENT); while((c=icalcomponent_get_current_component(c)) != 0){ if(icalcomponent_isa(c) == ICAL_VEVENT_COMPONENT){ icalcomponent_remove_component(parent_comp,inner); } else { icalcomponent_get_next_component(parent_comp,ICAL_VEVENT_COMPONENT); } } ``` #### 5.2.5 Working with properties and parameters Finding, iterating and removing properties works the same as it does for components, using the property-specific or parameter-specific interfaces: ```c icalproperty* icalcomponent_get_first_property( icalcomponent* component, icalproperty_kind kind); icalproperty* icalcomponent_get_next_property( icalcomponent* component, icalproperty_kind kind); void icalcomponent_add_property( icalcomponent* component, icalproperty* property); void icalcomponent_remove_property( icalcomponent* component, icalproperty* property); ``` For parameters: ```c icalparameter* icalproperty_get_first_parameter( icalproperty* prop, icalparameter_kind kind); icalparameter* icalproperty_get_next_parameter( icalproperty* prop, icalparameter_kind kind); void icalproperty_add_parameter( icalproperty* prop, icalparameter* parameter); void icalproperty_remove_parameter_by_kind( icalproperty* prop, icalparameter_kind kind); ``` Note that since there should be only one parameter of each type in a property, you will rarely need to use `icalparameter_get_next_parameter()`. #### 5.2.6 Working with values Values are typically part of a property, although they can exist on their own. You can manipulate them either as part of the property or independently. The most common way to work with values to is to manipulate them from they properties that contain them. This involves fewer routine calls and intermediate variables than working with them independently, and it is type-safe. For each property, there are a `_get_()` and a `_set_()` routine that accesses the internal value. For instanace, for the `UID` property, the routines are: ```c void icalproperty_set_uid( icalproperty* prop, const char* v); const char* icalproperty_get_uid( icalproperty* prop); ``` For multi-valued properties, like `ATTACH`, the value type is usually a struct or union that holds both possible types. If you want to work with the underlying value object, you can get and set it with: ```c icalvalue* icalproperty_get_value( icalproperty* prop); void icalproperty_set_value( icalproperty* prop, icalvalue* value); ``` `icalproperty_get_value()` will return a reference that you can manipulate with other icalvalue routines. Most of the time, you will have to know what the type of the value is. For instance, if you know that the value is a `DATETIME` type, you can manipulate it with: ```c struct icaltimetype icalvalue_get_datetime( icalvalue* value); void icalvalue_set_datetime( icalvalue* value, struct icaltimetype v); ``` When working with an extension property or value (and `X-PROPERTY` or a property that has the parameter `VALUE=x-name`), the value type is always a string. To get and set the value, use: ```x void icalproperty_set_x( icalproperty* prop, char* v); char* icalproperty_get_x( icalproperty* prop); ``` All X properties have the type of `ICAL_X_PROPERTY`, so you will need these routines to get and set the name of the property: ```c char* icalproperty_get_x_name( icalproperty* prop) void icalproperty_set_x_name( icalproperty* prop, char* name); ``` #### 5.2.7 Checking Component Validity [RFC5546][] defines rules for what properties must exist in a component to be used for transferring scheduling data. Most of these rules relate to the existence of properties relative to the `METHOD` property, which declares what operation a remote receiver should use to process a component. For instance, if the `METHOD` is `REQUEST` and the component is a `VEVENT`, the sender is probably asking the receiver to join in a meeting. In this case, RFC5546 says that the component must specify a start time (`DTSTART`) and list the receiver as an attendee (`ATTENDEE`). Libical can check these restrictions with the routine: ```c int icalrestriction_check(icalcomponent* comp); ``` This routine returns 0 if the component does not pass RFC5546 restrictions, or if the component is malformed. The component you pass in must be a `VCALENDAR`, with one or more children, like the examples in RFC5546. When this routine runs, it will insert new properties into the component to indicate any errors it finds. See section 6.5.3, `X-LIC-ERROR` for more information about these error properties. 5.2.8 Converting Components to Text To create an RFC5545 compliant text representation of an object, use one of the `*_as_ical_string()` routines: ```c char* icalcomponent_as_ical_string(icalcomponent* component) char* icalproperty_as_ical_string(icalproperty* property) char* icalparameter_as_ical_string(icalparameter* parameter) char* icalvalue_as_ical_string(icalvalue* value) ``` In most cases, you will only use `icalcomponent_as_ical_string()`, since it will cascade and convert all of the parameters, properties and values that are attached to the root component. Remember that the string returned by these routines is owned by the library, and will eventually be re-written. You should copy it if you want to preserve it. ### 5.3 Time #### 5.3.1 Time structure Libical defines its own time structure for storing all dates and times. It would have been nice to re-use the C library's struct `tm`, but that structure does not differentiate between dates and times, and between local time and UTC. The libical structure is: ```c struct icaltimetype { int year; int month; int day; int hour; int minute; int second; int is_utc; /* 1-> time is in UTC timezone */ int is_date; /* 1 -> interpret this as date. */ }; ``` The `year`, `month`, `day`, `hour`, `minute` and `second` fields hold the broken-out time values. The `is_utc` field distinguishes between times in UTC and a local time zone. The `is_date` field indicates if the time should be interpreted only as a date. If it is a date, the hour, minute and second fields are assumed to be zero, regardless of their actual vaules. #### 5.3.2 Creating time structures There are several ways to create a new icaltimetype structure: ```c struct icaltimetype icaltime_from_string( const char* str); struct icaltimetype icaltime_from_timet_with_zone( time_t v, int is_date, icaltimezone* zone); ``` `icaltime_from_string()` takes any RFC5545 compliant time string: ```c struct icaltimetype tt = icaltime_from_string("19970101T103000"); ``` `icaltime_from_timet_with_zone()` takes a `time_t` value, representing seconds past the POSIX epoch, a flag to indicate if the time is a date, and a time zone. Dates have an identical structure to a time, but the time portion (hours, minuts and seconds) is always 00:00:00. Dates act differently in sorting and comparision, and they have a different string representation in [RFC5545][]. #### 5.3.3 Time manipulating routines The `null` time value is used to indicate that the data in the structure is not a valid time. ```c struct icaltimetype icaltime_null_time(void); int icaltime_is_null_time(struct icaltimetype t); ``` It is sensible for the broken-out time fields to contain values that are not permitted in an ISO compliant time string. For instance, the seconds field can hold values greater than 59, and the hours field can hold values larger than 24. The excessive values will be rolled over into the next larger field when the structure is normalized. ```c struct icaltimetype icaltime_normalize(struct icaltimetype t); ``` Normalizing allows you to do arithmetic operations on time values. ```c struct icaltimetype tt = icaltime_from_string("19970101T103000"); tt.days +=3 tt.second += 70; tt = icaltime_normalize(tt); ``` There are several routines to get the day of the week or month, etc, from a time structure. ```c short icaltime_day_of_year( struct icaltimetype t); struct icaltimetype icaltime_from_day_of_year( short doy, short year); short icaltime_day_of_week( struct icaltimetype t); short icaltime_start_doy_week( struct icaltimetype t, int fdow); short icaltime_week_number( short day_of_month, short month, short year); short icaltime_days_in_month( short month, short year); ``` Two routines convert time structures to and from the number of seconds since the POSIX epoch. The `is_date` field indicates whether or not the hour, minute and second fields should be used in the conversion. ```c struct icaltimetype icaltime_from_timet_with_zone( time_t v, int is_date, icaltimezone* zone); time_t icaltime_as_timet( struct icaltimetype); ``` The compare routine works exactly like `strcmp()`, but on time structures. ```c int icaltime_compare( struct icaltimetype a, struct icaltimetype b); ``` The following routines convert between UTC and a named timezone. The tzid field must be a timezone name from the Olsen database, such as `America/Los_Angeles`. The `utc_offset` routine returns the offset of the named time zone from UTC, in seconds. The `tt` parameter in the following routines indicates the date on which the conversion should be made. The parameter is necessary because timezones have many different rules for when daylight savings time is used, and these rules can change over time. So, for a single timezone one year may have daylight savings time on March 15, but for other years March 15 may be standard time, and some years may have standard time all year. ```c int icaltime_utc_offset( struct icaltimetype tt, char* tzid); int icaltime_local_utc_offset(); struct icaltimetype icaltime_as_utc( struct icaltimetype tt, char* tzid); struct icaltimetype icaltime_as_zone( struct icaltimetype tt, char* tzid); struct icaltimetype icaltime_as_local( struct icaltimetype tt); ``` ### 5.4 Storing Objects The libical distribution includes a separate library, libicalss, that allows you to store iCal component data to disk in a variety of ways. The file storage routines are organized in an inheritance heirarchy that is rooted in icalset, with the derived class icalfileset and icaldirset. Icalfileset stores components to a file, while icaldirset stores components to multiple files, one per month based on DTSTAMP. Other storages classess, for storage to a heap or a mysql database for example, could be added in the future. All of the icalset derived classes have the same interface: ```c icaldirset* icaldirset_new( const char* path); void icaldirset_free( icaldirset* store); const char* icaldirset_path( icaldirset* store); void icaldirset_mark( icaldirset* store); icalerrorenum icaldirset_commit( icaldirset* store); icalerrorenum icaldirset_add_component( icaldirset* store, icalcomponent* comp); icalerrorenum icaldirset_remove_component( icaldirset* store, icalcomponent* comp); int icaldirset_count_components( icaldirset* store, icalcomponent_kind kind); icalerrorenum icaldirset_select( icaldirset* store, icalcomponent* gauge); void icaldirset_clear( icaldirset* store); icalcomponent* icaldirset_fetch( icaldirset* store, const char* uid); int icaldirset_has_uid( icaldirset* store, const char* uid); icalcomponent* icaldirset_fetch_match( icaldirset* set, icalcomponent *c); icalerrorenum icaldirset_modify( icaldirset* store, icalcomponent *oldc, icalcomponent *newc); icalcomponent* icaldirset_get_current_component( icaldirset* store); icalcomponent* icaldirset_get_first_component( icaldirset* store); icalcomponent* icaldirset_get_next_component( icaldirset* store); ``` #### 5.4.1 Creating a new set You can create a new set from either the base class or the direved class. From the base class use one of: ```c icalset* icalset_new_file(const char* path); icalset* icalset_new_dir(const char* path); icalset* icalset_new_heap(void); icalset* icalset_new_mysql(const char* path); ``` You can also create a new set based on the derived class, For instance, with icalfileset: ```c icalfileset* icalfileset_new( const char* path); icalfileset* icalfileset_new_open( const char* path, int flags, int mode); ``` `icalset_new_file()` is identical to `icalfileset_new()`. Both routines will open an existing file for readinga and writing, or create a new file if it does not exist. `icalfilset_new_open()` takes the same arguments as the open() system routine and behaves in the same way. The icalset and icalfilset objects are somewhat interchangable -- you can use an `icalfileset*` as an argument to any of the icalset routines. The following examples will all use icalfileset routines; using the other icalset derived classess will be similar. #### 5.4.2 Adding, Finding and Removing Components To add components to a set, use: ```c icalerrorenum icalfileset_add_component( icalfileset* cluster, icalcomponent* child); ``` The fileset keeps an inmemory copy of the components, and this set must be written back to the file ocassionally. There are two routines to manage this: ```c void icalfileset_mark(icalfileset* cluster); icalerrorenum icalfileset_commit(icalfileset* cluster); ``` `icalfileset_mark()` indicates that the in-memory components have changed. Calling the `_add_component()` routine will call `_mark()` automatically, but you may need to call it yourself if you have made a change to an existing component. The `_commit()` routine writes the data base to disk, but only if it is marked. The `_commit()` routine is called automatically when the icalfileset is freed. To iterate through the components in a set, use: ```c icalcomponent* icalfileset_get_first_component(icalfileset* cluster); icalcomponent* icalfileset_get_next_component(icalfileset* cluster); icalcomponent* icalfileset_get_current_component (icalfileset* cluster); ``` These routines work like the corresponding routines from icalcomponent, except that their output is filtered through a gauge. A gauge is a test for the properties within a components; only components that pass the test are returned. A gauge can be constructed from a MINSQL string with: ```c icalgauge* icalgauge_new_from_sql(const char* sql); ``` Then, you can add the gauge to the set with : ```c icalerrorenum icalfileset_select( icalfileset* store, icalgauge* gauge); ``` Here is an example that puts all of these routines together: ```c void test_fileset() { icalfileset *fs; icalcomponent *c; int i; char *path = "test_fileset.ics"; icalgauge *g = icalgauge_new_from_sql( "SELECT * FROM VEVENT WHERE DTSTART > '20000103T120000Z' AND DTSTART <= '20000106T120000Z'"); fs = icalfileset_new(path); for (i = 0; i!= 10; i++){ c = make_component(i); /* Make a new component where DTSTART has month of i */ icalfileset_add_component(fs,c); } icalfileset_commit(fs); /* Write to disk */ icalfileset_select(fs,g); /* Set the gauge to filter components */ for (c = icalfileset_get_first_component(fs); c != 0; c = icalfileset_get_next_component(fs)) { struct icaltimetype t = icalcomponent_get_dtstart(c); printf("%s\n",icaltime_as_ctime(t)); } icalfileset_free(fs); } ``` #### 5.4.3 Other routines There are several other routines in the icalset interface, but they not fully implemented yet. #### 5.5 Memory Management Libical relies heavily on dynamic allocation for both the core objects and for the strings used to hold values. Some of this memory the library caller owns and must free, and some of the memory is managed by the library. Here is a summary of the memory rules. 1. If the function name has "new" in it (such as `icalcomponent_new()`, or `icalpropert_new_clone()`), the caller gets control of the memory. 2. If you got the memory from a routine with new in it, you must call the corresponding `*_free()` routine to free the memory, for example use `icalcomponent_free()` to free objects created with `icalcomponent_new()`) 3. If the function name has "add" in it, the caller is transferring control of the memory to the routine, for example the function ` icalproperty_add_parameter()` 4. If the function name has "remove" in it, the caller passes in a pointer to an object and after the call returns, the caller owns the object. So, before you call `icalcomponent_remove_property(comp, foo)`, you do not own "foo" and after the call returns, you do. 5. If the routine returns a string and its name does NOT end in `_r`, libical owns the memory and will put it on a ring buffer to reclaim later. For example, `icalcomponent_as_ical_string()`. You better `strdup()` it if you want to keep it, and you don't have to delete it. 6. If the routine returns a string and its name *does* end in `_r`, the caller gets control of the memory and is responsible for freeing it. For example, `icalcomponent_as_ical_string_r()` does the same thing as `icalcomponent_as_ical_string()`, except you now have control of the string buffer it returns. ### 5.6 Error Handling Libical has several error handling mechanisms for the various types of programming, semantic and syntactic errors you may encounter. #### 5.6.1 Return values Many library routines signal errors through their return values. All routines that return a pointer, such as `icalcomponent_new()`, will return 0 (zero) on a fatal error. Some routines will return a value of enum `icalerrorenum`. 5.6.2 `icalerrno` Most routines will set the global error value `icalerrno` on errors. This variable is an enumeration; permissible values can be found in `libical/icalerror.h`. If the routine returns an enum icalerrorenum, then the return value will be the same as icalerrno. You can use `icalerror_strerror()` to get a string that describes the error. The enumerations are: - `ICAL_BADARG_ERROR`: One of the argument to a routine was bad. Typically for a null pointer. - `ICAL_NEWFAILED_ERROR`: A `new()` or `malloc()` failed. - `ICAL_MALFORMEDDATA_ERROR`: An input string was not in the correct format - `ICAL_PARSE_ERROR`: The parser failed to parse an incoming component - `ICAL_INTERNAL_ERROR`: Largely equivalent to an assert - `ICAL_FILE_ERROR`: A file operation failed. Check errno for more detail. - `ICAL_ALLOCATION_ERROR`: ? - `ICAL_USAGE_ERROR`: ? - `ICAL_NO_ERROR`: No error - `ICAL_MULTIPLEINCLUSION_ERROR`: ? - `ICAL_TIMEDOUT_ERROR`: For CSTP and acquiring locks - `ICAL_UNKNOWN_ERROR`: ? #### 5.6.3 `X-LIC-ERROR` and `X-LIC-INVALID-COMPONENT` The library handles semantic and syntactic errors in components by inserting errors properties into the components. If the parser cannot parse incoming text (a syntactic error) or if the `icalrestriction_check()` routine indicates that the component does not meet the requirements of RFC5546 (a semantic error) the library will insert properties of the type `X-LIC-ERROR` to describe the error. Here is an example of the error property: ```ical X-LIC-ERROR;X-LIC-ERRORTYPE=INVALID_ITIP :Failed iTIP restrictions for property DTSTART. Expected 1 instances of the property and got 0 ``` This error resulted from a call to `icalrestriction_check()`, which discovered that the component does not have a `DTSTART` property, as required by RFC5545. There are a few routines to manipulate error properties: [ The following data is supposed to be in a table. It looks OK in LyX, but does not format propertly in output. ] +-------------------------------------+---------------------------------------------------------+ | Routine | Purpose | +-------------------------------------+---------------------------------------------------------+ | void icalrestriction_check() | Check a component against RFC5546 and insert | +-------------------------------------+---------------------------------------------------------+ | | error properties to indicate non compliance | +-------------------------------------+---------------------------------------------------------+ | int icalcomponent_count_errors() | Return the number of error properties | +-------------------------------------+---------------------------------------------------------+ | | in a component | +-------------------------------------+---------------------------------------------------------+ | void icalcomponent_strip_errors() | Remove all error properties in as | +-------------------------------------+---------------------------------------------------------+ | | component | +-------------------------------------+---------------------------------------------------------+ | void icalcomponent_convert_errors() | Convert some error properties into | +-------------------------------------+---------------------------------------------------------+ | | REQUESTS-STATUS proprties to indicate the inability to | +-------------------------------------+---------------------------------------------------------+ | | process the component as an iTIP request. | +-------------------------------------+---------------------------------------------------------+ The types of errors are listed in icalerror.h. They are: - `ICAL_XLICERRORTYPE_COMPONENTPARSEERROR` - `ICAL_XLICERRORTYPE_PARAMETERVALUEPARSEERROR` - `ICAL_XLICERRORTYPE_PARAMETERNAMEPARSEERROR` - `ICAL_XLICERRORTYPE_PROPERTYPARSEERROR` - `ICAL_XLICERRORTYPE_VALUEPARSEERROR` - `ICAL_XLICERRORTYPE_UNKVCALPROP` - `ICAL_XLICERRORTYPE_INVALIDITIP` The libical parser will generate the error that end in `PARSEERROR` when it encounters garbage in the input steam. `ICAL_XLICERRORTYPE_INVALIDITIP` is inserted by `icalrestriction_check()`, and `ICAL_XLICERRORTYPE_UNKVCALPROP` is generated by `icalvcal_convert()` when it encounters a vCal property that it cannot convert or does not know about. `icalcomponent_convert_errors()` converts some of the error properties in a component into `REQUEST-STATUS` properties that indicate a failure. As of libical version 0.18, this routine only converts `PARSEERROR` errors and it always generates a 3.x (failure) code. This makes it more of a good idea than a really useful bit of code. #### 5.6.4 `ICAL_ERRORS_ARE_FATAL` and `icalerror_errors_are_fatal` If `icalerror_get_errors_are_fatal()` returns 1, then any error condition will cause the program to abort. The abort occurs in `icalerror_set_errno()`, and is done with an assert(0) if NDEBUG is undefined, and with `icalerror_crash_here()` if NDEBUG is defined. Initially, `icalerror_get_errors_are_fatal()` is 1 when `ICAL_ERRORS_ARE_FATAL` is defined, and 0 otherwise. Since `ICAL_ERRORS_ARE_FATAL` is defined by default, `icalerror_get_errors_are_fatal()` is also set to 1 by default. You can change the compiled-in `ICAL_ERRORS_ARE_FATAL` behavior at runtime by calling `icalerror_set_errors_are_fatal(0)` (i.e, errors are not fatal) or `icalerror_set_errors_are_fatal(1)` (i.e, errors are fatal). ### 5.7 Naming Standard Structures that you access with the "struct" keyword, such as `struct icaltimetype` are things that you are allowed to see inside and poke at. Structures that you access though a typedef, such as `icalcomponent` are things where all of the data is hidden. Component names that start with "V" are part of RFC5545 or another iCal standard. Component names that start with "X" are also part of the spec, but they are not actually components in the spec. However, they look and act like components, so they are components in libical. Names that start with `XLIC` or `X-LIC` are not part of any iCal spec. They are used internally by libical. Enums that identify a component, property, value or parameter end with `_COMPONENT`, `_PROPERTY`, `_VALUE`, or `_PARAMETER`" Enums that identify a parameter value have the name of the parameter as the second word. For instance: `ICAL_ROLE_REQPARTICIPANT` or `ICAL_PARTSTAT_ACCEPTED`. The enums for the parts of a recurarance rule and request statuses are irregular. ## 6 Hacks and Bugs There are a lot of hacks in the library -- bits of code that I am not proud of and should probably be changed. These are marked with the comment string "HACK." ## 7 Library Reference ### 7.1 Manipulating struct icaltimetype #### 7.1.1 Struct icaltimetype ```c struct icaltimetype { int year; int month; int day; int hour; int minute; int second; int is_utc; int is_date; const char* zone; }; ``` libical-3.0.1/doc/UsingLibical.txt000066400000000000000000001271421320431302500167650ustar00rootroot00000000000000 Using Libical Eric Busboom (eric@softwarestudio.org) January 2001 1 Introduction Libical is an Open Source implementation of the iCalendar protocols and protocol data units. The iCalendar specification describes how calendar clients can communicate with calendar servers so users can store their calendar data and arrange meetings with other users. Libical implements RFC5545, RFC5546, RFC7529; the iCalendar extensions in RFC6638; and some of RFC6047. This documentation assumes that you are familiar with the iCalendar standards RFC5545 and RFC5546. These specifications are available at the IETF tools website: https://tools.ietf.org/html/rfc5545 https://tools.ietf.org/html/rfc5546 1.1 The libical project This code is under active development. If you would like to contribute to the project, visit http://libical.github.io/libical/ 1.2 License The code and datafiles in this distribution are licensed under the Mozilla Public License version 2.0. See http://www.mozilla.org/MPL for a copy of the license. Alternately, you may use libical under the terms of the GNU Lesser General Public License, version 2.1. See http://www.gnu.org/licenses/lgpl-2.1.html for a copy of the LGPL. This dual license ensures that the library can be incorporated into both proprietary code and GPL'd programs, and will benefit from improvements made by programmers in both realms. I will only accept changes into my version of the library if they are similarly dual-licensed. 1.3 Example Code A lot of the documentation for this library is in the form of example code. These examples are in the "examples" directory of the distribution. Also look in "src/test" for additional annotated examples. 2 Building the Library Libical uses autoconf to generate makefiles. It should build with no adjustments on Linux, FreeBSD and Solaris under gcc. Some version have been successfully built on MacOS, Solaris, UnixWare, and Tru64 UNIX without gcc, but you may run into problems with a particular later version. For a more complete guide to building the library, see the README file in the distribution. 3 Structure The iCalendar data model is based on four types of objects: components, properties, values and parameters. Properties are the fundamental unit of information in iCalendar, and they work a bit like a hash entry, with a constant key and a variable value. Properties may also have modifiers, called parameters. In the iCal content line ORGANIZER;ROLE=CHAIR:MAILTO:mrbig@host.com The property name is "ORGANIZER," the value of the property is "mrbig@host.com" and the "ROLE" parameter specifies that Mr Big is the chair of the meetings associated with this property. Components are groups of properties that represent the core objects of a calendar system, such as events or timezones. Components are delimited by "BEGIN" and "END" tags. When a component is sent across a network, if it is un-encrypted, it will look something like: BEGIN:VCALENDAR METHOD:REQUEST PRODID: -//hacksw/handcal//NONSGML v1.0//EN BEGIN:VEVENT DTSTAMP:19980309T231000Z UID:guid-1.host1.com ORGANIZER;ROLE=CHAIR:MAILTO:mrbig@host.com ATTENDEE;RSVP=TRUE;ROLE=REQ-PARTICIPANT;CUTYPE=GROUP: MAILTO:employee-A@host.com DESCRIPTION:Project XYZ Review Meeting CATEGORIES:MEETING CLASS:PUBLIC CREATED:19980309T130000Z SUMMARY:XYZ Project Review DTSTART;TZID=US-Eastern:19980312T083000 DTEND;TZID=US-Eastern:19980312T093000 LOCATION:1CP Conference Room 4350 END:VEVENT END:VCALENDAR Note that components can be nested; this example has both a VCALENDAR and a VEVENT component, one nested inside the other. 3.1 Core iCal classes Libical is an object-based, data-oriented library. Nearly all of the routines in the library are associated with an opaque data types and perform some operation on that data type. Although the library does not actually have classes, we will use those terms since the behavior of these associations of data and routines is very similar to a class. 3.1.1 Properties Properties are represented with the icalproperty class and its many "derived" classes with on "derived" class per property type in RFC5545. Again, there is no actual inheritance relations, but there are clusters of routines that make this term useful. A property is a container for a single value and a set of parameters. 3.1.2 Components In libical, components are represented with the icalcomponent class. Icalcomponent is a container for a set of other components and properties. 3.1.3 Values Values are represented in a similar way to properties; a base class and many "derived" classes. A value is essentially a abstract handle on a single fundamental type, a structure or a union. 3.1.4 Parameters Parameters are represented in a similar way to properties, except that they contain only one value. 3.2 Other elements of libical In addition to the core iCal classes, libical has many other types, structures, classes that aid in creating and using iCal components. 3.2.1 Enumerations and types Libical is strongly typed, so every component, property, parameter, and value type has an enumeration, and some have an associated structure or union. 3.2.2 The parser The libical parser offers a variety of ways to convert RFC5545 text into a libical internal component structure. the parser can parse blocks of text as a string, or it can parse line-by-line. 3.2.3 Error objects Libical has a substantial error reporting system for both programming errors and component usage errors. 3.2.4 Memory Management Since many of libicals interfaces return strings, the library has its own memory management system to elimiate the need to free every string returned from the library. 3.2.5 Storage classes The library also offers several classes to store components to flies, memory or databases. 4 Differences From RFCs Libical has been designed to follow the standards as closely as possible, so that the key objects in the standards are also key objects in the library. However, there are a few areas where the specifications are (arguably) irregular, and following them exactly would result in an unfriendly interface. These deviations make libical easier to use by maintaining a self-similar interface. 4.1 Pseudo Components Libical defines components for groups of properties that look and act like components, but are not defined as components in the specification. XDAYLIGHT and XSTANDARD are notable examples. These pseudo components group properties within the VTIMEZONE components. For instanace, the timezone properties associated with daylight savings time starts with "BEGIN:DAYLIGHT" and ends with "END:DAYLIGHT, just like other components, but is not defined as a component in RFC5545 (see RFC5545, section 3.6.5) In Libical,this grouping is represented by the XDAYLIGHT component. Standard iCAL components all start with the letter "V," while pseudo components start with "X." There are also pseudo components that are conceptually derived classes of VALARM. RFC5546 defines what properties may be included in each component, and for VALARM, the set of properties it may have depends on the value of the ACTION property. For instance, if a VALARM component has an ACTION property with the value of "AUDIO," the component must also have an "ATTACH" property. However, if the ACTION value is "DISPLAY," the component must have a DESCRIPTION property. To handle these various, complex restrictions, libical has pseudo components for each type of alarm: XAUDIOALARM, XDISPLAYALARM, XEMAILALARM and XPROCEDUREALARM. 4.2 Combined Values Many values can take more than one type. TRIGGER, for instance, can have a value type of with DURATION or of DATE-TIME. These multiple types make it difficult to create routines to return the value associated with a property. It is natural to have interfaces that would return the value of a property, but it is cumbersome for a single routine to return multiple types. So, in libical, properties that can have multiple types are given a single type that is the union of their RFC5545 types. For instance, in libical, the value of the TRIGGER property resolves to struct icaltriggertype. This type is a union of a DURATION and a DATE-TIME. 4.3 Multi-Valued Properties Some properties, such as CATEGORIES have only one value type, but each CATEGORIES property can have multiple value instances. This also results in a cumbersome interface -- CATEGORIES accessors would have to return a list while all other accessors returned a single value. In libical, all properties have a single value, and multi-valued properties are broken down into multiple single valued properties during parsing. That is, an input line like, CATEGORIES: work, home becomes in libical's internal representation CATEGORIES: work CATEGORIES: home Oddly, RFC5545 allows some multi-valued properties (like FREEBUSY) to exist as both a multi-values property and as multiple single value properties, while others (like CATEGORIES) can only exist as single multi-valued properties. This makes the internal representation for CATEGORIES illegal. However when you convert a component to a string, the library will collect all of the CATEGORIES properties into one. 5 Using libical 5.1 Creating Components There are three ways to create components in Libical: creating individual objects and assembling them, building entire objects in massive vaargs calls, and parsing a text file containing iCalendar data. 5.1.1 Constructor Interfaces Using constructor interfaces, you create each of the objects separately and then assemble them in to components: icalcomponent *event; icalproperty *prop; icalparameter *param; struct icaltimetype atime; event = icalcomponent_new(ICAL_VEVENT_COMPONENT); prop = icalproperty_new_dtstamp(atime) ; icalcomponent_add_property(event, prop); prop = icalproperty_new_uid(''guid-1.host1.com''); icalcomponent_add_property(event,prop); prop=icalproperty_new_organizer(''mrbig@host.com''); param = icalparameter_new_role(ICAL_ROLE_CHAIR) icalproperty_add_parameter(prop, param); icalcomponent_add_property(event,prop); Notice that libical uses a semi-object-oriented style of interface. Most things you work with are objects, that are instantiated with a constructor that has "new" in the name. Also note that, other than the object reference, most structure data is passed in to libical routines by value. Libical has some complex but very regular memory handling rules. These are detailed in section [sec:memory]. If any of the constructors fail, they will return 0. If you try to insert 0 into a property or component, or use a zero-valued object reference, libical will either silently ignore the error or will abort with an error message. This behavior is controlled by a compile time flag (ICAL_ERRORS_ARE_FATAL), and will abort by default. 5.1.2 varargs Constructors There is another way to create complex components, which is arguably more elegant, if you are not horrified by varargs. The varargs constructor interface allows you to create intricate components in a single block of code. Here is the previous examples in the vaargs style. calendar = icalcomponent_vanew( ICAL_VCALENDAR_COMPONENT, icalproperty_new_version(''2.0''), icalproperty_new_prodid( ''-//RDU Software//NONSGML HandCal//EN''), icalcomponent_vanew( ICAL_VEVENT_COMPONENT, icalproperty_new_dtstamp(atime), icalproperty_new_uid(''guid-1.host1.com''), icalproperty_vanew_organizer( ''mrbig@host.com''), icalparameter_new_role(ICAL_ROLE_CHAIR), 0 ), icalproperty_vanew_attendee( ''employee-A@host.com'', icalparameter_new_role( ICAL_ROLE_REQPARTICIPANT), icalparameter_new_rsvp(1), icalparameter_new_cutype(ICAL_CUTYPE_GROUP), 0 ), icalproperty_new_location( "1CP Conference Room 4350"), 0 ), 0 ); This form is similar to the constructor form, except that the constructors have "vanew" instead of "new" in the name. The arguments are similar too, except that the component constructor can have a list of properties, and the property constructor can have a list of parameters. Be sure to terminate every list with a '0', or your code will crash, if you are lucky. 5.1.3 Parsing Text Files The final way to create components will probably be the most common; you can create components from RFC5545 compliant text. If you have the string in memory, use icalcomponent* icalparser_parse_string(char* str); If the string contains only one component, the parser will return the component in libical form. If the string contains multiple components, the multiple components will be returned as the children of an ICAL_XROOT_COMPONENT component. Parsing a whole string may seem wasteful if you want to pull a large component off of the network or from a file; you may prefer to parse the component line by line. This is possible too by using: icalparser* icalparser_new(); void icalparser_free(icalparser* parser); icalparser_get_line(parser,read_stream); icalparser_add_line(parser,line); icalparser_set_gen_data(parser,stream) These routines will construct a parser object to which you can add lines of input and retrieve any components that the parser creates from the input. These routines work by specifing an adaptor routine to get string data from a source. For an example: char* read_stream(char *s, size_t size, void *d) { char *c = fgets(s,size, (FILE*)d); return c; } main() { char* line; icalcomponent *c; icalparser *parser = icalparser_new(); FILE* stream = fopen(argv[1],"r"); icalparser_set_gen_data(parser,stream); do { line = icalparser_get_line(parser,read_stream); c = icalparser_add_line(parser,line); if (c != 0){ printf("%s",icalcomponent_as_ical_string(c)); icalparser_claim(parser); printf("\n---------------\n"); icalcomponent_free(c); } } while (line != 0); } The parser object parameterizes the routine used to get input lines with icalparser_set_gen_data() and icalparser_get_line(). In this example, the routine read_stream() will fetch the next line from a stream, with the stream passed in as the void* parameter d. The parser calls read_stream() from icalparser_get_line(), but it also needs to know what stream to use. This is set by the call to icalparser_set_gen_data(). By using a different routine for read_stream or passing in different data with icalparser_set_gen_data, you can connect to any data source. Using the same mechanism, other implementations could read from memory buffers, sockets or other interfaces. Since the example code is a very common way to use the parser, there is a convenience routine; icalcomponent* icalparser_parse(icalparser *parser, char* (*line_gen_func)(char *s, size_t size, void* d)) To use this routine, you still must construct the parser object and pass in a reference to a line reading routine. If the parser can create a single component from the input, it will return a pointer to the newly constructed component. If the parser can construct multiple components from the input, it will return a reference to an XROOT component ( of type ICAL_XROOT_COMPONENT.) This XROOT component will hold all of the components constructed from the input as children. 5.2 Accessing Components Given a reference to a component, you probably will want to access the properties, parameters and values inside. Libical interfaces let you find sub-component, add and remove sub-components, and do the same three operations on properties. 5.2.1 Finding Components To find a sub-component of a component, use: icalcomponent* icalcomponent_get_first_component( icalcomponent* component, icalcomponent_kind kind); This routine will return a reference to the first component of the type 'kind.' The key kind values, listed in icalenums.h are: ICAL_ANY_COMPONENT ICAL_VEVENT_COMPONENT ICAL_VTODO_COMPONENT ICAL_VJOURNAL_COMPONENT ICAL_VCALENDAR_COMPONENT ICAL_VFREEBUSY_COMPONENT ICAL_VALARM_COMPONENT These are only the most common components; there are many more listed in icalenums.h. As you might guess, if there is more than one subcomponent of the type you have chosen, this routine will return only the first. to get at the others, you need to iterate through the component. 5.2.2 Iterating Through Components Iteration requires a second routine to get the next subcomponent after the first: icalcomponent* icalcomponent_get_next_component( icalcomponent* component, icalcomponent_kind kind); With the 'first' and 'next' routines, you can create a for loop to iterate through all of a components subcomponents for(c = icalcomponent_get_first_component(comp,ICAL_ANY_COMPONENT); c != 0; c = icalcomponent_get_next_component(comp,ICAL_ANY_COMPONENT)) { do_something(c); } This code bit wil iterate through all of the subcomponents in 'comp' but you can select a specific type of component by changing ICAL_ANY_COMPONENT to another component type. 5.2.3 Using Component Iterators The iteration model in the previous section requires the component to keep the state of the iteration. So, you could not use this model to perform a sorting operations, since you'd need two iterators and there is only space for one. If you ever call icalcomponent_get_first_component() when an iteration is in progress, the pointer will be reset to the beginning. To solve this problem, there are also external iterators for components. The routines associated with these external iterators are: icalcompiter icalcomponent_begin_component(icalcomponent* component, icalcomponent_kind kind); icalcompiter icalcomponent_end_component(icalcomponent* component, icalcomponent_kind kind); icalcomponent* icalcompiter_next(icalcompiter* i); icalcomponent* icalcompiter_prior(icalcompiter* i); icalcomponent* icalcompiter_deref(icalcompiter* i); The _begin_() and _end_() routines return a new iterator that points to the beginning and ending of the list of subcomponent for the given component, and the kind argument works like the kind argument for internal iterators. After creating an iterators, use _next_() and _prior_() to step forward and backward through the list and get the component that the iterator points to, and use _deref() to return the component that the iterator points to without moving the iterator. All routines will return 0 when they move to point off the end of the list. Here is an example of a loop using these routines: for( i = icalcomponent_begin_component(impl->cluster,ICAL_ANY_COMPONENT); icalcompiter_deref(&i)!= 0; icalcompiter_next(&i) ) { icalcomponent *this = icalcompiter_deref(&i); } 5.2.4 Removing Components Removing an element from a list while iterating through the list with the internal iterators can cause problems, since you will probably be removing the element that the internal iterator points to. The _remove() routine will keep the iterator valid by moving it to the next component, but in a normal loop, this will result in two advances per iteration, and you will remove only every other component. To avoid the problem, you will need to step the iterator ahead of the element you are going to remove, like this: for(c = icalcomponent_get_first_component(parent_comp,ICAL_ANY_COMPONENT); c != 0; c = next { next = icalcomponent_get_next_component(parent_comp,ICAL_ANY_COMPONENT); icalcomponent_remove_component(parent_comp,c); } Another way to remove components is to rely on the side effect of icalcomponent_remove_component: if component iterator in the parent component is pointing to the child that will be removed, it will move the iterator to the component after the child. The following code will exploit this behavior: icalcomponent_get_first_component(parent_comp,ICAL_VEVENT_COMPONENT); while((c=icalcomponent_get_current_component(c)) != 0 ){ if(icalcomponent_isa(c) == ICAL_VEVENT_COMPONENT){ icalcomponent_remove_component(parent_comp,inner); } else { icalcomponent_get_next_component(parent_comp,ICAL_VEVENT_COMPONENT); } } 5.2.5 Working with properties and parameters Finding, iterating and removing properties works the same as it does for components, using the property-specific or parameter-specific interfaces: icalproperty* icalcomponent_get_first_property( icalcomponent* component, icalproperty_kind kind); icalproperty* icalcomponent_get_next_property( icalcomponent* component, icalproperty_kind kind); void icalcomponent_add_property( icalcomponent* component, icalproperty* property); void icalcomponent_remove_property( icalcomponent* component, icalproperty* property); For parameters: icalparameter* icalproperty_get_first_parameter( icalproperty* prop, icalparameter_kind kind); icalparameter* icalproperty_get_next_parameter( icalproperty* prop, icalparameter_kind kind); void icalproperty_add_parameter( icalproperty* prop, icalparameter* parameter); void icalproperty_remove_parameter_by_kind( icalproperty* prop, icalparameter_kind kind); Note that since there should be only one parameter of each type in a property, you will rarely need to use icalparameter_get_next_parameter. 5.2.6 Working with values Values are typically part of a property, although they can exist on their own. You can manipulate them either as part of the property or independently. The most common way to work with values to is to manipulate them from they properties that contain them. This involves fewer routine calls and intermediate variables than working with them independently, and it is type-safe. For each property, there are a _get_ and a _set_ routine that accesses the internal value. For instanace, for the UID property, the routines are: void icalproperty_set_uid(icalproperty* prop, const char* v) const char* icalproperty_get_uid(icalproperty* prop) For multi-valued properties, like ATTACH, the value type is usually a struct or union that holds both possible types. If you want to work with the underlying value object, you can get and set it with: icalvalue* icalproperty_get_value (icalproperty* prop) void icalproperty_set_value(icalproperty* prop, icalvalue* value); icalproperty_get_value() will return a reference that you can manipulate with other icalvalue routines. Most of the time, you will have to know what the type of the value is. For instance, if you know that the value is a DATETIME type, you can manipulate it with: struct icaltimetype icalvalue_get_datetime(icalvalue* value); void icalvalue_set_datetime(icalvalue* value, struct icaltimetype v); When working with an extension property or value (and X-PROPERTY or a property that has the parameter VALUE=x-name ) the value type is always a string. To get and set the value, use: void icalproperty_set_x(icalproperty* prop, char* v); char* icalproperty_get_x(icalproperty* prop); All X properties have the type of ICAL_X_PROPERTY, so you will need these routines to get and set the name of the property: char* icalproperty_get_x_name(icalproperty* prop) void icalproperty_set_x_name(icalproperty* prop, char* name); 5.2.7 Checking Component Validity RFC 5546 defines rules for what properties must exist in a component to be used for transferring scheduling data. Most of these rules relate to the existence of properties relative to the METHOD property, which declares what operation a remote receiver should use to process a component. For instance, if the METHOD is REQUEST and the component is a VEVENT, the sender is probably asking the receiver to join in a meeting. In this case, RFC5546 says that the component must specify a start time (DTSTART) and list the receiver as an attendee (ATTENDEE). Libical can check these restrictions with the routine: int icalrestriction_check(icalcomponent* comp); This routine returns 0 if the component does not pass RFC5546 restrictions, or if the component is malformed. The component you pass in must be a VCALENDAR, with one or more children, like the examples in RFC5546. When this routine runs, it will insert new properties into the component to indicate any errors it finds. See section 6.5.3, X-LIC-ERROR for more information about these error properties. 5.2.8 Converting Components to Text To create an RFC5545 compliant text representation of an object, use one of the *_as_ical_string() routines: char* icalcomponent_as_ical_string (icalcomponent* component) char* icalproperty_as_ical_string (icalproperty* property) char* icalparameter_as_ical_string (icalparameter* parameter) char* icalvalue_as_ical_string (icalvalue* value) In most cases, you will only use icalcomponent_as_ical_string (), since it will cascade and convert all of the parameters, properties and values that are attached to the root component. Remember that the string returned by these routines is owned by the library, and will eventually be re-written. You should copy it if you want to preserve it. 5.3 Time 5.3.1 Time structure Libical defines its own time structure for storing all dates and times. It would have been nice to re-use the C library's struct tm, but that structure does not differentiate between dates and times, and between local time and UTC. The libical structure is: struct icaltimetype { int year; int month; int day; int hour; int minute; int second; int is_date; /* 1 -> interpret this as date. */ }; The year, month, day, hour, minute and second fields hold the broken-out time values. The is_date field indicates if the time should be interpreted only as a date. If it is a date, the hour, minute and second fields are assumed to be zero, regardless of their actual vaules. 5.3.2 Creating time structures There are several ways to create a new icaltimetype structure: struct icaltimetype icaltime_from_string(const char* str); struct icaltimetype icaltime_from_timet_with_zone(time_t v, int is_date, icaltimezone* zone); icaltime_from_string takes any RFC5545 compliant time string: struct icaltimetype tt = icaltime_from_string("19970101T103000"); icaltime_from_timet_with_zone takes a time_t value, representing seconds past the POSIX epoch, a flag to indicate if the time is a date, and a time zone. Dates have an identical structure to a time, but the time portion (hours, minuts and seconds) is always 00:00:00. Dates act differently in sorting and comparision, and they have a different string representation in RFC5545. 5.3.3 Time manipulating routines The null time value is used to indicate that the data in the structure is not a valid time. struct icaltimetype icaltime_null_time(void); int icaltime_is_null_time(struct icaltimetype t); It is sensible for the broken-out time fields to contain values that are not permitted in an ISO compliant time string. For instance, the seconds field can hold values greater than 59, and the hours field can hold values larger than 24. The excessive values will be rolled over into the next larger field when the structure is normalized. struct icaltimetype icaltime_normalize(struct icaltimetype t); Normalizing allows you to do arithmetic operations on time values. struct icaltimetype tt = icaltime_from_string("19970101T103000"); tt.days +=3 tt.second += 70; tt = icaltime_normalize(tt); There are several routines to get the day of the week or month, etc, from a time structure. short icaltime_day_of_year(struct icaltimetype t); struct icaltimetype icaltime_from_day_of_year(short doy, short year); short icaltime_day_of_week(struct icaltimetype t); short icaltime_start_doy_week(struct icaltimetype t, int fdow); short icaltime_week_number(short day_of_month, short month, short year); short icaltime_days_in_month(short month,short year); Two routines convert time structures to and from the number of seconds since the POSIX epoch. The is_date field indicates whether or not the hour, minute and second fields should be used in the conversion. struct icaltimetype icaltime_from_timet_with_zone(time_t v, int is_date, icaltimezone* zone); time_t icaltime_as_timet(struct icaltimetype); The compare routine works exactly like strcmp, but on time structures. int icaltime_compare(struct icaltimetype a,struct icaltimetype b); The following routines convert between UTC and a named timezone. The tzid field must be a timezone name from the Olsen database, such as "America/Los_Angeles." The utc_offset routine returns the offset of the named time zone from UTC, in seconds. The tt parameter in the following routines indicates the date on which the conversion should be made. The tt parameter is necessary because timezones have many different rules for when daylight savings time is used, and these rules can change over time. So, for a single timezone one year may have daylight savings time on March 15, but for other years March 15 may be standard time, and some years may have standard time all year. int icaltime_utc_offset(struct icaltimetype tt, char* tzid); int icaltime_local_utc_offset(); struct icaltimetype icaltime_as_utc(struct icaltimetype tt,char* tzid); struct icaltimetype icaltime_as_zone(struct icaltimetype tt,char* tzid); struct icaltimetype icaltime_as_local(struct icaltimetype tt); 5.4 Storing Objects The libical distribution includes a separate library, libicalss, that allows you to store iCal component data to disk in a variety of ways. The file storage routines are organized in an inheritance heirarchy that is rooted in icalset, with the derived class icalfileset and icaldirset. Icalfileset stores components to a file, while icaldirset stores components to multiple files, one per month based on DTSTAMP. Other storages classess, for storage to a heap or a mysql database for example, could be added in the future. All of the icalset derived classes have the same interface: icaldirset* icaldirset_new(const char* path); void icaldirset_free(icaldirset* store); const char* icaldirset_path(icaldirset* store); void icaldirset_mark(icaldirset* store); icalerrorenum icaldirset_commit(icaldirset* store); icalerrorenum icaldirset_add_component(icaldirset* store, icalcomponent* comp); icalerrorenum icaldirset_remove_component(icaldirset* store, icalcomponent* comp); int icaldirset_count_components(icaldirset* store, icalcomponent_kind kind); icalerrorenum icaldirset_select(icaldirset* store, icalcomponent* gauge); void icaldirset_clear(icaldirset* store); icalcomponent* icaldirset_fetch(icaldirset* store, const char* uid); int icaldirset_has_uid(icaldirset* store, const char* uid); icalcomponent* icaldirset_fetch_match(icaldirset* set, icalcomponent *c); icalerrorenum icaldirset_modify(icaldirset* store, icalcomponent *oldc, icalcomponent *newc); icalcomponent* icaldirset_get_current_component(icaldirset* store); icalcomponent* icaldirset_get_first_component(icaldirset* store); icalcomponent* icaldirset_get_next_component(icaldirset* store); 5.4.1 Creating a new set You can create a new set from either the base class or the direved class. From the base class use one of: icalset* icalset_new_file(const char* path); icalset* icalset_new_dir(const char* path); icalset* icalset_new_heap(void); icalset* icalset_new_mysql(const char* path); You can also create a new set based on the derived class, For instance, with icalfileset: icalfileset* icalfileset_new(const char* path); icalfileset* icalfileset_new_open(const char* path, int flags, int mode); icalset_new_file is identical to icalfileset_new. Both routines will open an existing file for readinga and writing, or create a new file if it does not exist. Icalfilset_new_open takes the same arguments as the open() system routine and behaves in the same way. The icalset and icalfilset objects are somewhat interchangable -- you can use an icalfileset* as an argument to any of the icalset routines. The following examples will all use icalfileset routines; using the other icalset derived classess will be similar. 5.4.2 Adding, Finding and Removing Components To add components to a set, use: icalerrorenum icalfileset_add_component(icalfileset* cluster, icalcomponent* child); The fileset keeps an inmemory copy of the components, and this set must be written back to the file ocassionally. There are two routines to manage this: void icalfileset_mark(icalfileset* cluster); icalerrorenum icalfileset_commit(icalfileset* cluster); icalfileset_mark indicates that the in-memory components have changed. Calling the _add_component routine will call _mark automatically, but you may need to call it yourself if you have made a change to an existing component. The _commit routine writes the data base to disk, but only if it is marked. The _commit routine is called automatically when the icalfileset is freed. To iterate through the components in a set, use: icalcomponent* icalfileset_get_first_component(icalfileset* cluster); icalcomponent* icalfileset_get_next_component(icalfileset* cluster); icalcomponent* icalfileset_get_current_component (icalfileset* cluster); These routines work like the corresponding routines from icalcomponent, except that their output is filtered through a gauge. A gauge is a test for the properties within a components; only components that pass the test are returned. A gauge can be constructed from a MINSQL string with: icalgauge* icalgauge_new_from_sql(const char* sql); Then, you can add the gauge to the set with : icalerrorenum icalfileset_select(icalfileset* store, icalgauge* gauge); Here is an example that puts all of these routines together: void test_fileset() { icalfileset *fs; icalcomponent *c; int i; char *path = "test_fileset.ics"; icalgauge *g = icalgauge_new_from_sql( "SELECT * FROM VEVENT WHERE DTSTART > '20000103T120000Z' AND DTSTART <= '20000106T120000Z'"); fs = icalfileset_new(path); for (i = 0; i!= 10; i++){ c = make_component(i); /* Make a new component where DTSTART has month of i */ icalfileset_add_component(fs,c); } icalfileset_commit(fs); /* Write to disk */ icalfileset_select(fs,g); /* Set the gauge to filter components */ for (c = icalfileset_get_first_component(fs); c != 0; c = icalfileset_get_next_component(fs)){ struct icaltimetype t = icalcomponent_get_dtstart(c); printf("%s\n",icaltime_as_ctime(t)); } icalfileset_free(fs); } 5.4.3 Other routines There are several other routines in the icalset interface, but they not fully implemented yet. 5.5 Memory Management Libical relies heavily on dynamic allocation for both the core objects and for the strings used to hold values. Some of this memory the library caller owns and must free, and some of the memory is managed by the library. Here is a summary of the memory rules. 1) If the function name has "new" in it (such as icalcomponent_new(), or icalpropert_new_clone()), the caller gets control of the memory. 2) If you got the memory from a routine with new in it, you must call the corresponding *_free routine to free the memory. ( Use icalcomponent_free() to free objects created with icalcomponent_new()) 3) If the function name has "add" in it, the caller is transferring control of the memory to the routine. ( icalproperty_add_parameter() ) 4) If the function name has "remove" in it, the caller passes in a pointer to an object and after the call returns, the caller owns the object. So, before you call icalcomponent_remove_property(comp,foo), you do not own "foo" and after the call returns, you do. 5) If the routine returns a string and its name does NOT end in "_r", libical owns the memory and will put it on a ring buffer to reclaim later. For example, icalcomponent_as_ical_string(). You'd better strdup() it if you want to keep it, and you don't have to delete it. 6) If the routine returns a string and its name *does* end in "_r", the caller gets control of the memory and is responsible for freeing it. For example, icalcomponent_as_ical_string_r() does the same thing as icalcomponent_as_ical_string(), except you now have control of the string buffer it returns. 5.6 Error Handling Libical has several error handling mechanisms for the various types of programming, semantic and syntactic errors you may encounter. 5.6.1 Return values Many library routines signal errors through their return values. All routines that return a pointer, such as icalcomponent_new(), will return 0 ( zero ) on a fatal error. Some routines will return a value of enum icalerrorenum. 5.6.2 icalerrno Most routines will set the global error value icalerrno on errors. This variable is an enumeration; permissible values can be found in libical/icalerror.h. If the routine returns an enum icalerrorenum, then the return value will be the same as icalerrno. You can use icalerror_strerror() to get a string that describes the error. The enumerations are: * ICAL_BADARG_ERROR -- One of the argument to a routine was bad. Typically for a null pointer. * ICAL_NEWFAILED_ERROR -- A new() or malloc() failed * ICAL_MALFORMEDDATA_ERROR -- An input string was not in the correct format * ICAL_PARSE_ERROR -- The parser failed to parse an incoming component * ICAL_INTERNAL_ERROR -- Largely equivalent to an assert * ICAL_FILE_ERROR -- A file operation failed. Check errno for more detail. * ICAL_ALLOCATION_ERROR -- ? * ICAL_USAGE_ERROR -- ? * ICAL_NO_ERROR -- No error * ICAL_MULTIPLEINCLUSION_ERROR -- ? * ICAL_TIMEDOUT_ERROR -- For CSTP and acquiring locks * ICAL_UNKNOWN_ERROR -- ? 5.6.3 X-LIC-ERROR and X-LIC-INVALID-COMPONENT The library handles semantic and syntactic errors in components by inserting errors properties into the components. If the parser cannot parse incoming text ( a syntactic error ) or if the icalrestriction_check() routine indicates that the component does not meet the requirements of RFC5546 ( a semantic error) the library will insert properties of the type X-LIC-ERROR to describe the error. Here is an example of the error property: X-LIC-ERROR;X-LIC-ERRORTYPE=INVALID_ITIP :Failed iTIP restrictions for property DTSTART. Expected 1 instances of the property and got 0 This error resulted from a call to icalrestriction_check(), which discovered that the component does not have a DTSTART property, as required by RFC5545. There are a few routines to manipulate error properties: [ The following data is supposed to be in a table. It looks OK in LyX, but does not format propertly in output. ] +-------------------------------------+---------------------------------------------------------+ | Routine | Purpose | +-------------------------------------+---------------------------------------------------------+ | void icalrestriction_check() | Check a component against RFC5546 and insert | +-------------------------------------+---------------------------------------------------------+ | | error properties to indicate non compliance | +-------------------------------------+---------------------------------------------------------+ | int icalcomponent_count_errors() | Return the number of error properties | +-------------------------------------+---------------------------------------------------------+ | | in a component | +-------------------------------------+---------------------------------------------------------+ | void icalcomponent_strip_errors() | Remove all error properties in as | +-------------------------------------+---------------------------------------------------------+ | | component | +-------------------------------------+---------------------------------------------------------+ | void icalcomponent_convert_errors() | Convert some error properties into | +-------------------------------------+---------------------------------------------------------+ | | REQUESTS-STATUS proprties to indicate the inability to | +-------------------------------------+---------------------------------------------------------+ | | process the component as an iTIP request. | +-------------------------------------+---------------------------------------------------------+ The types of errors are listed in icalerror.h. They are: ICAL_XLICERRORTYPE_COMPONENTPARSEERROR ICAL_XLICERRORTYPE_PARAMETERVALUEPARSEERROR ICAL_XLICERRORTYPE_PARAMETERNAMEPARSEERROR ICAL_XLICERRORTYPE_PROPERTYPARSEERROR ICAL_XLICERRORTYPE_VALUEPARSEERROR ICAL_XLICERRORTYPE_UNKVCALPROP ICAL_XLICERRORTYPE_INVALIDITIP The libical parser will generate the error that end in PARSEERROR when it encounters garbage in the input steam. ICAL_XLICERRORTYPE_INVALIDITIP is inserted by icalrestriction_check(), and ICAL_XLICERRORTYPE_UNKVCALPROP is generated by icalvcal_convert() when it encounters a vCal property that it cannot convert or does not know about. Icalcomponent_convert_errors() converts some of the error properties in a component into REQUEST-STATUS properties that indicate a failure. As of libical version0.18, this routine only convert *PARSEERROR errors and it always generates a 3.x ( failure ) code. This makes it more of a good idea than a really useful bit of code. 5.6.4 ICAL_ERRORS_ARE_FATAL and icalerror_errors_are_fatal If icalerror_get_errors_are_fatal() returns 1, then any error condition will cause the program to abort. The abort occurs in icalerror_set_errno(), and is done with an assert(0) if NDEBUG is undefined, and with icalerror_crash_here if NDEBUG is defined. Initially, icalerror_get_errors_are_fatal() is 1 when ICAL_ERRORS_ARE_FATAL is defined, and 0 otherwise. Since ICAL_ERRORS_ARE_FATAL is defined by default, icalerror_get_errors_are_fatal() is also set to 1 by default. You can change the compiled-in ICAL_ERRORS_ARE_FATAL behavior at runtime by calling icalerror_set_errors_are_fatal(0) (i.e, errors are not fatal) or icalerror_set_errors_are_fatal(1) (i.e, errors are fatal). 5.7 Naming Standard Structures that you access with the "struct" keyword, such as "struct icaltimetype" are things that you are allowed to see inside and poke at. Structures that you access though a typedef, such as "icalcomponent" are things where all of the data is hidden. Component names that start with "V" are part of RFC 5545 or another iCal standard. Component names that start with "X" are also part of the spec, but they are not actually components in the spec. However, they look and act like components, so they are components in libical. Names that start with "XLIC" or "X-LIC" are not part of any iCal spec. They are used internally by libical. Enums that identify a component, property, value or parameter end with "_COMPONENT," "_PROPERTY," "_VALUE," or "_PARAMETER" Enums that identify a parameter value have the name of the parameter as the second word. For instance: ICAL_ROLE_REQPARTICIPANT or ICAL_PARTSTAT_ACCEPTED. The enums for the parts of a recurarance rule and request statuses are irregular. 6 Hacks and Bugs There are a lot of hacks in the library -- bits of code that I am not proud of and should probably be changed. These are marked with the comment string "HACK." 7 Library Reference 7.1 Manipulating struct icaltimetype 7.1.1 Struct icaltimetype struct icaltimetype { int year; int month; int day; int hour; int minute; int second; int is_date; const char* zone; }; libical-3.0.1/doc/reference/000077500000000000000000000000001320431302500156065ustar00rootroot00000000000000libical-3.0.1/doc/reference/CMakeLists.txt000066400000000000000000000000671320431302500203510ustar00rootroot00000000000000if(ICAL_GLIB) add_subdirectory(libical-glib) endif() libical-3.0.1/doc/reference/libical-glib/000077500000000000000000000000001320431302500201205ustar00rootroot00000000000000libical-3.0.1/doc/reference/libical-glib/CMakeLists.txt000066400000000000000000000070221320431302500226610ustar00rootroot00000000000000find_program(GTKDOC_SCAN gtkdoc-scan DOC "a tool to scan header files for public symbols") find_program(GTKDOC_MKDB gtkdoc-mkdb DOC "a tool to generate docbook files") find_program(GTKDOC_MKHTML gtkdoc-mkhtml DOC "a tool to generate documentation in html format") find_program(GTKDOC_FIXXREF gtkdoc-fixxref DOC "a tool to fix cross references in html files") if(NOT (GTKDOC_SCAN AND GTKDOC_MKDB AND GTKDOC_MKHTML AND GTKDOC_FIXXREF)) message(WARNING "Cannot find all gtk-doc binaries, skipping API reference generation for libical-glib") return() endif() # To regenerate libical-glib-docs.xml.in from current sources use these steps: # a) delete ${CMAKE_CURRENT_BINARY_DIR}/libical-glib-docs.xml # b) go to ${CMAKE_CURRENT_BINARY_DIR} and run command: # gtkdoc-scan --module=libical-glib --source-dir=../../../src/libical-glib/ # --deprecated-guards="LIBICAL_GLIB_DISABLE_DEPRECATED" # --ignore-headers=libical-glib-private.h --rebuild-sections --rebuild-types # c) generate the libical-glib-docs.xml file with command: # gtkdoc-mkdb --module=libical-glib --output-format=xml # --source-dir=../../../src/libical-glib/ --xml-mode --name-space=i-cal # d) copy the newly created libical-glib-docs.xml # to ${CURRENT_SOURCE_DIR}/libical-glib-docs.xml.in # e) compare the changes in the file and return back what should be left, # like the replacement of the "[Insert title here]" and the content configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/libical-glib-docs.xml.in ${CMAKE_CURRENT_BINARY_DIR}/libical-glib-docs.xml @ONLY ) set(OUTPUT_DOCDIR ${SHARE_INSTALL_DIR}/gtk-doc/html/libical-glib) add_custom_command(OUTPUT xml/libical-glib-doc.bottom COMMAND ${GTKDOC_SCAN} --module=libical-glib --source-dir="${CMAKE_BINARY_DIR}/src/libical-glib" --deprecated-guards="LIBICAL_GLIB_DISABLE_DEPRECATED" --ignore-headers=libical-glib-private.h --rebuild-sections --rebuild-types COMMAND ${GTKDOC_MKDB} --module=libical-glib --name-space=i-cal --main-sgml-file="${CMAKE_CURRENT_BINARY_DIR}/libical-glib-docs.xml" --xml-mode --output-format=xml --source-dir="${CMAKE_BINARY_DIR}/src/libical-glib" COMMAND ${CMAKE_COMMAND} -E make_directory "${CMAKE_CURRENT_BINARY_DIR}/html" DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/libical-glib-docs.xml" ) if(APPLE) add_custom_command(OUTPUT html/index.html COMMAND env XML_CATALOG_FILES="/usr/local/etc/xml/catalog" ${GTKDOC_MKHTML} --path=.. libical-glib ../libical-glib-docs.xml WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html" DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/libical-glib-docs.xml" "${CMAKE_CURRENT_BINARY_DIR}/xml/libical-glib-doc.bottom" COMMENT "Generating libical-glib documentation" ) else() add_custom_command(OUTPUT html/index.html COMMAND ${GTKDOC_MKHTML} --path=.. libical-glib ../libical-glib-docs.xml WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html" DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/libical-glib-docs.xml" "${CMAKE_CURRENT_BINARY_DIR}/xml/libical-glib-doc.bottom" COMMENT "Generating libical-glib documentation" ) endif() add_custom_target(documentation ALL COMMAND ${GTKDOC_FIXXREF} --module=libical-glib --module-dir=. --extra-dir=.. --html-dir=${OUTPUT_DOCDIR} DEPENDS html/index.html COMMENT "Generating libical-glib documentation" ) add_dependencies(documentation ical-glib) install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html/ DESTINATION ${OUTPUT_DOCDIR}) libical-3.0.1/doc/reference/libical-glib/libical-glib-docs.xml.in000066400000000000000000000064031320431302500245120ustar00rootroot00000000000000 ]> libical-glib Reference Manual for libical-glib @LIBICAL_LIB_VERSION_STRING@. API Reference API Index libical-3.0.1/examples/000077500000000000000000000000001320431302500147215ustar00rootroot00000000000000libical-3.0.1/examples/CMakeLists.txt000066400000000000000000000017071320431302500174660ustar00rootroot00000000000000include_directories( ${CMAKE_BINARY_DIR} ${CMAKE_SOURCE_DIR}/src ${CMAKE_BINARY_DIR}/src ${CMAKE_SOURCE_DIR}/src/libical ${CMAKE_BINARY_DIR}/src/libical ${CMAKE_SOURCE_DIR}/src/libicalss ) ########### doesnothing target ############### set(doesnothing_SRCS access_components.c access_properties_and_parameters.c errors.c main.c parse_text.c ) add_executable(doesnothing ${doesnothing_SRCS}) add_dependencies(doesnothing ical icalss icalvcal) if(NOT STATIC_ONLY) target_link_libraries(doesnothing ical icalss icalvcal) else() target_link_libraries(doesnothing ical-static icalss-static icalvcal-static ) target_link_libraries(doesnothing ${CMAKE_THREAD_LIBS_INIT}) if(ICU_FOUND) target_link_libraries(doesnothing ${ICU_LIBRARY}) endif() if(ICU_I18N_FOUND) target_link_libraries(doesnothing ${ICU_I18N_LIBRARY}) endif() if(BDB_FOUND) target_link_libraries(doesnothing ${BDB_LIBRARY}) endif() endif() libical-3.0.1/examples/access-usecases.txt000066400000000000000000000025341320431302500205400ustar00rootroot00000000000000 Usecases --------- 1) iMIP based CUA uses a local, file-based store 2) CAP based CUA uses one or more remote CAP servers 3) CAP based CUA uses a local cache that synchronizes with one or more CAP servers. 4) CUA imports and exports from a file Scenarios. --------- 1 Open a connection to a store. 2 Create a new calendar for which user Bob can read and user Alice can read an write. 3 Create several new calendars 4 Delete a calendar 5 Change the calid of a calendar 6 Delete all calendars belonging to user bob 7 Get three new UIDs from the store 8 Store a new VEVENT in the store. 9 Find all components for which the LOCATION is "West Conference Room" and change them to "East Conference Room" 10 Find the component with UID X and add a GEO property to it. 11 Delete all VEVENTS which have a METHOD that is not CREATED 12 Retrieve all VEVENTS which have a METHOD that is not CREATED 13 Retrieve the capabilities of the store 14 Retrieve/Modify/Add/Delete properties of a store 15 Retrieve/Modify/Add/Delete VCARs of a store 16 Retrieve/Modify/Add/Delete VTIMEZONEs of a store 17 Retrieve/Modify/Add/Delete properties of a calendar 18 Retrieve/Modify/Add/Delete VCARs of a calendar 19 Retrieve/Modify/Add/Delete VTIMEZONEs of a calendar 20 Translate a CALID into one or more UPNs 21 Expand a group UPN into all of the members of the grouplibical-3.0.1/examples/access_components.c000066400000000000000000000223331320431302500205760ustar00rootroot00000000000000/* Access_component.c */ #include void do_something(icalcomponent *c); /* Creating iCal Components There are two ways to create new component in libical. You can build the component from primitive parts, or you can create it from a string. There are two variations of the API for building the component from primitive parts. In the first variation, you add each parameter and value to a property, and then add each property to a component. This results in a long series of function calls. This style is show in create_new_component() The second variation uses vargs lists to nest many primitive part constructors, resulting in a compact, neatly formated way to create components. This style is shown in create_new_component_with_va_args() */ icalcomponent* create_new_component() { /* variable definitions */ icalcomponent* calendar; icalcomponent* event; struct icaltimetype atime = icaltime_from_timet_with_zone(time(0), 0, icaltimezone_get_utc_timezone()); struct icalperiodtype rtime; icalproperty* property; /* Define a time type that will use as data later. */ rtime.start = icaltime_from_timet_with_zone(time(0), 0, icaltimezone_get_utc_timezone()); rtime.end = icaltime_from_timet_with_zone(time(0), 0, icaltimezone_get_utc_timezone()); rtime.end.hour++; /* Create calendar and add properties */ calendar = icalcomponent_new(ICAL_VCALENDAR_COMPONENT); /* Nearly every libical function call has the same general form. The first part of the name defines the 'class' for the function, and the first argument will be a pointer to a struct of that class. So, icalcomponent_ functions will all take icalcomponent* as their first argument. */ /* The next call creates a new proeprty and immediately adds it to the 'calendar' component. */ icalcomponent_add_property( calendar, icalproperty_new_version("2.0") ); /* Here is the short version of the memory rules: If the routine name has "new" in it: Caller owns the returned memory. If you pass in a string, the routine takes the memory. If the routine name has "add" in it: The routine takes control of the component, property, parameter or value memory. If the routine returns a string ( "get" and "as_ical_string" ) The library owns the returned memory. There are more rules, so refer to the documentation for more details. */ icalcomponent_add_property( calendar, icalproperty_new_prodid("-//RDU Software//NONSGML HandCal//EN") ); /* Add an event */ event = icalcomponent_new(ICAL_VEVENT_COMPONENT); icalcomponent_add_property( event, icalproperty_new_dtstamp(atime) ); /* In the previous call, atime is a struct, and it is passed in by value. This is how all compound types of values are handled. */ icalcomponent_add_property( event, icalproperty_new_uid("guid-1.host1.com") ); /* add a property that has parameters */ property = icalproperty_new_organizer("mailto:mrbig@host.com"); icalproperty_add_parameter( property, icalparameter_new_role(ICAL_ROLE_CHAIR) ); icalcomponent_add_property(event,property); /* In this style of component creation, you need to use an extra call to add parameters to properties, but the form of this operation is the same as adding a property to a component */ /* add another property that has parameters */ property = icalproperty_new_attendee("mailto:employee-A@host.com"); icalproperty_add_parameter( property, icalparameter_new_role(ICAL_ROLE_REQPARTICIPANT) ); icalproperty_add_parameter( property, icalparameter_new_rsvp(1) ); icalproperty_add_parameter( property, icalparameter_new_cutype(ICAL_CUTYPE_GROUP) ); icalcomponent_add_property(event,property); /* more properties */ icalcomponent_add_property( event, icalproperty_new_description("Project XYZ Review Meeting") ); icalcomponent_add_property( event, icalproperty_new_categories("MEETING") ); icalcomponent_add_property( event, icalproperty_new_class(ICAL_CLASS_PUBLIC) ); icalcomponent_add_property( event, icalproperty_new_created(atime) ); icalcomponent_add_property( event, icalproperty_new_summary("XYZ Project Review") ); property = icalproperty_new_dtstart(atime); icalproperty_add_parameter( property, icalparameter_new_tzid("US-Eastern") ); icalcomponent_add_property(event,property); property = icalproperty_new_dtend(atime); icalproperty_add_parameter( property, icalparameter_new_tzid("US-Eastern") ); icalcomponent_add_property(event,property); icalcomponent_add_property( event, icalproperty_new_location("1CP Conference Room 4350") ); icalcomponent_add_component(calendar,event); return calendar; } /* Now, create the same component as in the previous routine, but use the constructor style. */ icalcomponent* create_new_component_with_va_args() { /* This is a similar set up to the last routine */ icalcomponent* calendar; struct icaltimetype atime = icaltime_from_timet_with_zone(time(0), 0, icaltimezone_get_utc_timezone()); struct icalperiodtype rtime; rtime.start = icaltime_from_timet_with_zone(time(0), 0, icaltimezone_get_utc_timezone()); rtime.end = icaltime_from_timet_with_zone(time(0), 0, icaltimezone_get_utc_timezone()); rtime.end.hour++; /* Some of these routines are the same as those in the previous routine, but we've also added several 'vanew' routines. These 'vanew' routines take a list of properties, parameters or values and add each of them to the parent property or component. */ calendar = icalcomponent_vanew( ICAL_VCALENDAR_COMPONENT, icalproperty_new_version("2.0"), icalproperty_new_prodid("-//RDU Software//NONSGML HandCal//EN"), icalcomponent_vanew( ICAL_VEVENT_COMPONENT, icalproperty_new_dtstamp(atime), icalproperty_new_uid("guid-1.host1.com"), icalproperty_vanew_organizer( "mailto:mrbig@host.com", icalparameter_new_role(ICAL_ROLE_CHAIR), 0 ), icalproperty_vanew_attendee( "mailto:employee-A@host.com", icalparameter_new_role(ICAL_ROLE_REQPARTICIPANT), icalparameter_new_rsvp(1), icalparameter_new_cutype(ICAL_CUTYPE_GROUP), 0 ), icalproperty_new_description("Project XYZ Review Meeting"), icalproperty_new_categories("MEETING"), icalproperty_new_class(ICAL_CLASS_PUBLIC), icalproperty_new_created(atime), icalproperty_new_summary("XYZ Project Review"), icalproperty_vanew_dtstart( atime, icalparameter_new_tzid("US-Eastern"), 0 ), icalproperty_vanew_dtend( atime, icalparameter_new_tzid("US-Eastern"), 0 ), icalproperty_new_location("1CP Conference Room 4350"), 0 ), 0 ); /* Note that properties with no parameters can use the regular 'new' constructor, while those with parameters use the 'vanew' constructor. And, be sure that the last argument in the 'vanew' call is a zero. Without, your program will probably crash. */ return calendar; } void find_sub_components(icalcomponent* comp) { icalcomponent *c; /* The second parameter to icalcomponent_get_first_component indicates the type of component to search for. This will iterate through all sub-components */ for(c = icalcomponent_get_first_component(comp,ICAL_ANY_COMPONENT); c != 0; c = icalcomponent_get_next_component(comp,ICAL_ANY_COMPONENT)){ do_something(c); } /* This will iterate only though VEVENT sub-components */ for(c = icalcomponent_get_first_component(comp,ICAL_VEVENT_COMPONENT); c != 0; c = icalcomponent_get_next_component(comp,ICAL_VEVENT_COMPONENT)){ do_something(c); } } /* Ical components only have one internal iterator, so removing the object that the iterator points to can cause problems. Here is the right way to remove components */ void remove_vevent_sub_components(icalcomponent* comp){ icalcomponent *c, *next; for( c = icalcomponent_get_first_component(comp,ICAL_VEVENT_COMPONENT); c != 0; c = next) { next = icalcomponent_get_next_component(comp,ICAL_VEVENT_COMPONENT); icalcomponent_remove_component(comp,c); do_something(c); } } libical-3.0.1/examples/access_properties_and_parameters.c000066400000000000000000000110161320431302500236460ustar00rootroot00000000000000/* access_properties_and_parameters.c */ #include #include /* Get a particular parameter out of a component. This routine will return a list of strings of all attendees who are required. Note that this routine assumes that the component that we pass in is a VEVENT. */ void get_required_attendees(icalcomponent* event) { icalproperty* p; icalparameter* parameter; assert(event != 0); assert(icalcomponent_isa(event) == ICAL_VEVENT_COMPONENT); /* This loop iterates over all of the ATTENDEE properties in the event */ /* The iteration routines save their state in the event struct, so the are not thread safe unless you lock the whole component. */ for( p = icalcomponent_get_first_property(event,ICAL_ATTENDEE_PROPERTY); p != 0; p = icalcomponent_get_next_property(event,ICAL_ATTENDEE_PROPERTY) ) { /* Get the first ROLE parameter in the property. There should only be one, so we won't bother to iterate over them. But, you can iterate over parameters just like with properties */ parameter = icalproperty_get_first_parameter(p,ICAL_ROLE_PARAMETER); /* If the parameter indicates the participant is required, get the attendees name and stick a copy of it into the output array */ if ( icalparameter_get_role(parameter) == ICAL_ROLE_REQPARTICIPANT) { /* Remember, the caller does not own this string, so you should strdup it if you want to change it. */ const char *attendee = icalproperty_get_attendee(p); printf("%s",attendee); } } } /* Here is a similar example. If an attendee has a PARTSTAT of NEEDSACTION or has no PARTSTAT parameter, change it to TENTATIVE. */ void update_attendees(icalcomponent* event) { icalproperty* p; icalparameter* parameter; assert(event != 0); assert(icalcomponent_isa(event) == ICAL_VEVENT_COMPONENT); for( p = icalcomponent_get_first_property(event,ICAL_ATTENDEE_PROPERTY); p != 0; p = icalcomponent_get_next_property(event,ICAL_ATTENDEE_PROPERTY) ) { parameter = icalproperty_get_first_parameter(p,ICAL_PARTSTAT_PARAMETER); if (parameter == 0) { /* There was no PARTSTAT parameter, so add one. */ icalproperty_add_parameter( p, icalparameter_new_partstat(ICAL_PARTSTAT_TENTATIVE) ); } else if (icalparameter_get_partstat(parameter) == ICAL_PARTSTAT_NEEDSACTION) { /* Remove the NEEDSACTION parameter and replace it with TENTATIVE */ icalproperty_remove_parameter_by_kind(p,ICAL_PARTSTAT_PARAMETER); /* Don't forget to free it */ icalparameter_free(parameter); /* Add a new one */ icalproperty_add_parameter( p, icalparameter_new_partstat(ICAL_PARTSTAT_TENTATIVE) ); } } } /* Here are some examples of manipulating properties */ void test_properties() { icalproperty *prop; icalparameter *param; icalvalue *value; char *str; icalproperty *clone; /* Create a new property */ prop = icalproperty_vanew_comment( "Another Comment", icalparameter_new_cn("A Common Name 1"), icalparameter_new_cn("A Common Name 2"), icalparameter_new_cn("A Common Name 3"), icalparameter_new_cn("A Common Name 4"), 0); /* Iterate through all of the parameters in the property */ for(param = icalproperty_get_first_parameter(prop,ICAL_ANY_PARAMETER); param != 0; param = icalproperty_get_next_parameter(prop,ICAL_ANY_PARAMETER)) { printf("Prop parameter: %s\n",icalparameter_get_cn(param)); } /* Get a string representation of the property's value */ printf("Prop value: %s\n",icalproperty_get_comment(prop)); /* Spit out the property in its RFC 5545 representation */ str = icalproperty_as_ical_string_r(prop); printf("As iCAL string:\n %s\n", str); free(str); /* Make a copy of the property. Caller owns the memory */ clone = icalproperty_new_clone(prop); /* Get a reference to the value within the clone property */ value = icalproperty_get_value(clone); str = icalvalue_as_ical_string_r(value); printf("Value: %s", str); free(str); /* Free the original and the clone */ icalproperty_free(clone); icalproperty_free(prop); } libical-3.0.1/examples/changenames.pl000066400000000000000000000001561320431302500175310ustar00rootroot00000000000000s/icalcluster/icalfileset/g; s/ICALCLUSTER/ICALFILESET/g; s/icalstore/icaldirset/g; s/ICALSTORE/ICALDIRSET/g; libical-3.0.1/examples/errors.c000066400000000000000000000033431320431302500164040ustar00rootroot00000000000000/* errors.c */ #include void program_errors() { /*Most routines will set icalerrno on errors. This is an enumeration defined in icalerror.h */ icalerror_clear_errno(); (void)icalcomponent_new(ICAL_VEVENT_COMPONENT); if (icalerrno != ICAL_NO_ERROR){ fprintf(stderr,"Horrible libical error: %s\n", icalerror_strerror(icalerrno)); } } void component_errors(icalcomponent *comp) { int errors; icalproperty *p; /* presume that we just got this component from the parser */ errors = icalcomponent_count_errors(comp); printf("This component has %d parsing errors\n", errors); /* Print out all of the parsing errors. This is not strictly correct, because it does not descend into any sub-components, as icalcomponent_count_errors() does. */ for(p = icalcomponent_get_first_property(comp,ICAL_XLICERROR_PROPERTY); p != 0; p = icalcomponent_get_next_property(comp,ICAL_XLICERROR_PROPERTY)) { printf("-- The error is %s:\n",icalproperty_get_xlicerror(p)); } /* Check the component for iTIP compilance, and add more X-LIC-ERROR properties if it is non-compilant. */ icalrestriction_check(comp); /* Count the new errors. */ if(errors != icalcomponent_count_errors(comp)){ printf(" -- The component also has iTIP restriction errors \n"); } /* Since there are iTIP restriction errors, it may be impossible to process this component as an iTIP request. In this case, the X-LIC-ERROR proeprties should be expressed as REQUEST-STATUS properties in the reply. This following routine makes this conversion */ icalcomponent_convert_errors(comp); } libical-3.0.1/examples/main.c000066400000000000000000000003131320431302500160060ustar00rootroot00000000000000/* This is just to make the code in the example directory link properly. */ #include int main() { return 1; } void do_something(icalcomponent* comp) { (void)comp;/*unused*/ } libical-3.0.1/examples/parse_text.c000066400000000000000000000030171320431302500172440ustar00rootroot00000000000000/* parse_text.c */ #include #include /* The icalparser_get_line routine will create a single *content* line out of one or more input lines. The content line is all of the properties and values for a single property, and it can span several input lines. So, icalparser_get_line will need to be able to get more data on its own. Read_string is a routine that does this. You can write your own version of read stream to get data from other types of files, sockets, etc. */ char* read_stream(char *s, size_t size, void *d) { return fgets(s, (int)size, (FILE*)d); } void parse_text(char* argv[]) { char* line; FILE* stream; icalcomponent *c; /* Create a new parser object */ icalparser *parser = icalparser_new(); stream = fopen(argv[1],"r"); assert(stream != 0); /* Tell the parser what input routie it should use. */ icalparser_set_gen_data(parser,stream); do{ /* Get a single content line by making one or more calls to read_stream()*/ line = icalparser_get_line(parser,read_stream); /* Now, add that line into the parser object. If that line completes a component, c will be non-zero */ c = icalparser_add_line(parser,line); if (c != 0){ char *temp = icalcomponent_as_ical_string_r(c); printf("%s", temp); free(temp); printf("\n---------------\n"); icalcomponent_free(c); } } while ( line != 0); icalparser_free(parser); } libical-3.0.1/libical.pc.in000066400000000000000000000004671320431302500154420ustar00rootroot00000000000000prefix=@prefix@ exec_prefix=@exec_prefix@ libdir=@libdir@ includedir=@includedir@ Name: libical Description: An implementation of basic iCAL protocols Version: @LIBICAL_LIB_VERSION_STRING@ Libs: -L${libdir} -lical -licalss -licalvcal Libs.private: @PTHREAD_LIBS@ @REQUIRES_PRIVATE_ICU@ Cflags: -I${includedir} libical-3.0.1/scripts/000077500000000000000000000000001320431302500145725ustar00rootroot00000000000000libical-3.0.1/scripts/CMakeLists.txt000066400000000000000000000000541320431302500173310ustar00rootroot00000000000000 ########### install files ############### libical-3.0.1/scripts/buildtests.sh000077500000000000000000000332711320431302500173210ustar00rootroot00000000000000#!/bin/sh #Exit if any undefined variable is used. set -u #Exit this script if it any subprocess exits non-zero. #set -e #If any process in a pipeline fails, the return value is a failure. set -o pipefail #ensure parallel builds export MAKEFLAGS=-j8 ##### START FUNCTIONS ##### #function HELP # print a help message and exit HELP() { echo echo "Usage: `basename $0` [OPTIONS]" echo echo "Run build tests" echo "Options:" echo " -k, --no-krazy Don't run any Krazy tests" echo " -c, --no-cppcheck Don't run any cppcheck tests" echo " -t, --no-tidy Don't run any clang-tidy tests" echo " -b, --no-scan Don't run any scan-build tests" echo " -s, --no-splint Don't run any splint tests" echo " -l, --no-clang-build Don't run any clang-build tests" echo " -g, --no-gcc-build Don't run any gcc-build tests" echo " -a, --no-asan-build Don't run any ASAN-build tests" echo " -d, --no-tsan-build Don't run any TSAN-build tests" echo } COMMAND_EXISTS () { command -v $1 >/dev/null 2>&1 if ( test $? != 0 ) then echo "$1 is not in your PATH. Either install this program or skip the assocatied test" exit 1 fi } #function SET_GCC # setup compiling with gcc SET_GCC() { export CC=gcc; export CXX=g++ } #function SET_CLANG # setup compiling with clang SET_CLANG() { export CC=clang; export CXX=clang++ } #function SET_BDIR: # set the name of the build directory for the current test # $1 = the name of the current test SET_BDIR() { BDIR=$TOP/build-$1 } #function CHECK_WARNINGS: # print non-whitelisted warnings found in the file and exit if there are any # $1 = file to check # $2 = warning keyword # $3 = whitelist regex CHECK_WARNINGS() { if ( test -z "$3") then w=`cat $1 | grep "$2" | sort | uniq | wc -l | awk '{print $1}'` else w=`cat $1 | grep "$2" | grep -v "$3" | sort | uniq | wc -l | awk '{print $1}'` fi if ( test $w -gt 0 ) then echo "EXITING. $w warnings encountered" echo cat $1 | grep "$2" | grep -v "$3" | sort | uniq exit 1 fi } #function COMPILE_WARNINGS: # print warnings found in the compile-stage output # $1 = file with the compile-stage output COMPILE_WARNINGS() { whitelist='\(Value[[:space:]]descriptions\|g-ir-scanner:\|clang.*argument[[:space:]]unused[[:space:]]during[[:space:]]compilation\)' CHECK_WARNINGS $1 "warning:" "$whitelist" } #function CPPCHECK_WARNINGS: # print warnings found in the cppcheck output # $1 = file with the cppcheck output CPPCHECK_WARNINGS() { CHECK_WARNINGS $1 "\(warning\)" "" } #function TIDY_WARNINGS: # print warnings find in the clang-tidy output # $1 = file with the clang-tidy output TIDY_WARNINGS() { whitelist='\(Value[[:space:]]descriptions\|g-ir-scanner:\|clang.*argument[[:space:]]unused[[:space:]]during[[:space:]]compilation\|modernize-\|cppcoreguidelines-pro-type-const-cast\|cppcoreguidelines-pro-type-reinterpret-cast\|cppcoreguidelines-pro-type-vararg\|cppcoreguidelines-pro-bounds-pointer-arithmetic\|google-build-using-namespace\|llvm-include-order\|hicpp-use-equals-default\|cppcoreguidelines-no-malloc)' CHECK_WARNINGS $1 "warning:" "$whitelist" } #function SCAN_WARNINGS: # print warnings found in the scan-build output # $1 = file with the scan-build output SCAN_WARNINGS() { whitelist='\(Value[[:space:]]descriptions\|icalerror.*Dereference[[:space:]]of[[:space:]]null[[:space:]]pointer\)' CHECK_WARNINGS $1 "warning:" "$whitelist" } #function CONFIGURE: # creates the builddir and runs CMake with the specified options # $1 = the name of the test # $2 = CMake options CONFIGURE() { SET_BDIR $1 mkdir -p $BDIR cd $BDIR rm -rf * cmake .. $2 || exit 1 } #function CLEAN: # remove the builddir CLEAN() { cd $TOP rm -rf $BDIR } #function BUILD: # runs a build test, where build means: configure, compile, link and run the unit tests # $1 = the name of the test # $2 = CMake options BUILD() { cd $TOP CONFIGURE "$1" "$2" make |& tee make.out || exit 1 COMPILE_WARNINGS make.out make test |& tee make-test.out || exit 1 CLEAN } #function GCC_BUILD: # runs a build test using gcc # $1 = the name of the test (which will have "-gcc" appended to it) # $2 = CMake options GCC_BUILD() { name="$1-gcc" if ( test $rungccbuild -eq 0 ) then echo "===== GCC BUILD TEST $1 DISABLED DUE TO COMMAND LINE OPTION =====" return fi COMMAND_EXISTS "gcc" echo "===== START GCC BUILD: $1 ======" SET_GCC BUILD "$name" "$2" echo "===== END GCC BUILD: $1 ======" } #function CLANG_BUILD: # runs a build test using clang # $1 = the name of the test (which will have "-clang" appended to it) # $2 = CMake options CLANG_BUILD() { name="$1-clang" if ( test $runclangbuild -eq 0 ) then echo "===== CLANG BUILD TEST $1 DISABLED DUE TO COMMAND LINE OPTION =====" return fi COMMAND_EXISTS "clang" echo "===== START CLANG BUILD: $1 ======" SET_CLANG BUILD "$name" "$2" echo "===== END CLANG BUILD: $1 ======" } #function ASAN_BUILD: # runs an clang ASAN build test # $1 = the name of the test (which will have "-asan" appended to it) # $2 = CMake options ASAN_BUILD() { name="$1-asan" if ( test $runasanbuild -eq 0 ) then echo "===== ASAN BUILD TEST $1 DISABLED DUE TO COMMAND LINE OPTION =====" return fi echo "===== START ASAN BUILD: $1 ======" SET_CLANG BUILD "$name" "-DADDRESS_SANITIZER=True $2" echo "===== END ASAN BUILD: $1 ======" } #function TSAN_BUILD: # runs an clang TSAN build test # $1 = the name of the test (which will have "-tsan" appended to it) # $2 = CMake options TSAN_BUILD() { name="$1-tsan" if ( test $runtsanbuild -eq 0 ) then echo "===== TSAN BUILD TEST $1 DISABLED DUE TO COMMAND LINE OPTION =====" return fi echo "===== START TSAN BUILD: $1 ======" SET_CLANG BUILD "$name" "-DTHREAD_SANITIZER=True $2" echo "===== END TSAN BUILD: $1 ======" } #function CPPCHECK # runs a cppcheck test, which means: configure, compile, link and run cppcheck # $1 = the name of the test (which will have "-cppcheck" appended to it) # $2 = CMake options CPPCHECK() { name="$1-cppcheck" if ( test $runcppcheck -eq 0 ) then echo "===== CPPCHECK TEST $1 DISABLED DUE TO COMMAND LINE OPTION =====" return fi COMMAND_EXISTS "cppcheck" echo "===== START SETUP FOR CPPCHECK: $1 ======" #first build it cd $TOP SET_GCC CONFIGURE "$name" "$2" make |& tee make.out || exit 1 echo "===== START CPPCHECK: $1 ======" cd $TOP cppcheck --quiet --std=posix --language=c \ --force --error-exitcode=1 --inline-suppr \ --enable=warning,performance,portability,information \ -D sleep="" \ -D localtime_r="" \ -D gmtime_r="" \ -D size_t="unsigned long" \ -D bswap32="" \ -D PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP="" \ -I $BDIR \ -I $BDIR/src/libical \ -I $BDIR/src/libicalss \ -I $TOP/src/libical \ -I $TOP/src/libicalss \ -I $TOP/src/libicalvcal \ $TOP/src $BDIR/src/libical/icalderived* 2>&1 | \ grep -v 'Found a statement that begins with numeric constant' | \ grep -v 'cannot find all the include files' | \ grep -v Net-ICal | \ grep -v icalssyacc\.c | \ grep -v icalsslexer\.c | tee cppcheck.out CPPCHECK_WARNINGS cppcheck.out rm -f cppcheck.out CLEAN echo "===== END CPPCHECK: $1 ======" } #function SPLINT # runs a splint test, which means: configure, compile, link and run splint # $1 = the name of the test (which will have "-splint" appended to it # $2 = CMake options SPLINT() { name="$1-splint" if ( test $runsplint -eq 0 ) then echo "===== SPLIT TEST $1 DISABLED DUE TO COMMAND LINE OPTION =====" return fi COMMAND_EXISTS "splint" echo "===== START SETUP FOR SPLINT: $1 ======" #first build it cd $TOP SET_GCC CONFIGURE "$name" "$2" make |& tee make.out || exit 1 echo "===== START SPLINT: $1 ======" cd $TOP files=`find src -name "*.c" -o -name "*.h" | \ # skip C++ grep -v _cxx | grep -v /Net-ICal-Libical | # skip lex/yacc grep -v /icalssyacc | grep -v /icalsslexer | \ # skip test programs grep -v /test/ | grep -v /vcaltest\.c | grep -v /vctest\.c | \ # skip builddirs grep -v build-` files="$files $BDIR/src/libical/*.c $BDIR/src/libical/*.h" splint $files \ -weak -warnposix \ -modobserver -initallelements -redef \ -linelen 1000 \ -DHAVE_CONFIG_H=1 \ -DPACKAGE_DATA_DIR="\"foo\"" \ -DTEST_DATADIR="\"bar\"" \ -D"gmtime_r"="" \ -D"localtime_r"="" \ -D"nanosleep"="" \ -D"popen"="fopen" \ -D"pclose"="" \ -D"setenv"="" \ -D"strdup"="" \ -D"strcasecmp"="strcmp" \ -D"strncasecmp"="strncmp" \ -D"putenv"="" \ -D"unsetenv"="" \ -D"tzset()"=";" \ -DLIBICAL_ICAL_EXPORT=extern \ -DLIBICAL_ICALSS_EXPORT=extern \ -DLIBICAL_VCAL_EXPORT=extern \ -DLIBICAL_ICAL_NO_EXPORT="" \ -DLIBICAL_ICALSS_NO_EXPORT="" \ -DLIBICAL_VCAL_NO_EXPORT="" \ -DENOENT=1 -DENOMEM=1 -DEINVAL=1 -DSIGALRM=1 \ `pkg-config glib-2.0 --cflags` \ `pkg-config libxml-2.0 --cflags` \ -I $BDIR \ -I $BDIR/src \ -I $BDIR/src/libical \ -I $BDIR/src/libicalss \ -I $TOP \ -I $TOP/src \ -I $TOP/src/libical \ -I $TOP/src/libicalss \ -I $TOP/src/libicalvcal \ -I $TOP/src/libical-glib | \ cat - |& tee splint-$name.out status=${PIPESTATUS[0]} if ( test $status -gt 0 ) then echo "Splint warnings encountered. Exiting..." exit 1 fi CLEAN rm splint-$name.out echo "===== END SPLINT: $1 ======" } #function CLANGTIDY # runs a clang-tidy test, which means: configure, compile, link and run clang-tidy # $1 = the name of the test (which will have "-tidy" appended) # $2 = CMake options CLANGTIDY() { if ( test $runtidy -eq 0 ) then echo "===== CLANG-TIDY TEST $1 DISABLED DUE TO COMMAND LINE OPTION =====" return fi COMMAND_EXISTS "clang-tidy" echo "===== START CLANG-TIDY: $1 =====" cd $TOP SET_CLANG CONFIGURE "$1-tidy" "$2 -DCMAKE_CXX_CLANG_TIDY=clang-tidy;-checks=*" cmake --build . |& tee make-tidy.out || exit 1 TIDY_WARNINGS make-tidy.out CLEAN echo "===== END CLANG-TIDY: $1 =====" } #function CLANGSCAN # runs a scan-build, which means: configure, compile and link using scan-build # $1 = the name of the test (which will have "-scan" appended) # $2 = CMake options CLANGSCAN() { if ( test $runscan -eq 0 ) then echo "===== SCAN-BUILD TEST $1 DISABLED DUE TO COMMAND LINE OPTION =====" return fi COMMAND_EXISTS "scan-build" echo "===== START SCAN-BUILD: $1 =====" cd $TOP #configure specially with scan-build SET_BDIR "$1-scan" mkdir -p $BDIR cd $BDIR rm -rf * scan-build cmake .. "$2" || exit 1 scan-build make |& tee make-scan.out || exit 1 SCAN_WARNINGS make-scan.out CLEAN echo "===== END CLANG-SCAN: $1 =====" } #function KRAZY # runs a krazy2 test KRAZY() { if ( test $runkrazy -eq 0 ) then echo "===== KRAZY TEST DISABLED DUE TO COMMAND LINE OPTION =====" return fi COMMAND_EXISTS "krazy2all" echo "===== START KRAZY =====" cd $TOP krazy2all |& tee krazy.out status=$? if ( test $status -gt 0 ) then echo "Krazy warnings encountered. Exiting..." exit 1 fi rm -f krazy.out echo "===== END KRAZY ======" } ##### END FUNCTIONS ##### TEMP=`getopt -o hkctbslgad --long help,no-krazy,no-cppcheck,no-tidy,no-scan,no-splint,no-clang-build,no-gcc-build,no-asan-build,no-tsan-build -- "$@"` if [ $? != 0 ] ; then echo "Terminating..." >&2 ; exit 1 ; fi # Note the quotes around `$TEMP': they are essential! eval set -- "$TEMP" runkrazy=1 runcppcheck=1 runtidy=1 runscan=1 runclangbuild=1 rungccbuild=1 runasanbuild=1 runtsanbuild=1 runsplint=1 while true ; do case "$1" in -h|--help) HELP; exit 1;; -k|--no-krazy) runkrazy=0; shift;; -c|--no-cppcheck) runcppcheck=0; shift;; -t|--no-tidy) runtidy=0; shift;; -b|--no-scan) runscan=0; shift;; -s|--no-splint) runsplint=0; shift;; -l|--no-clang-build) runclangbuild=0; shift;; -g|--no-gcc-build) rungccbuild=0; shift;; -a|--no-asan-build) runasanbuild=0; shift;; -d|--no-tsan-build) runtsanbuild=0;shift;; --) shift; break;; *) echo "Internal error!"; exit 1;; esac done #MAIN TOP=`dirname $0` cd $TOP cd .. TOP=`pwd` BDIR="" CMAKEOPTS="-DCMAKE_BUILD_TYPE=Debug -DGOBJECT_INTROSPECTION=True -DICAL_GLIB=True" TZCMAKEOPTS="-DCMAKE_BUILD_TYPE=Debug -DUSE_BUILTIN_TZDATA=True -DGOBJECT_INTROSPECTION=True -DICAL_GLIB=True" #Static code checkers KRAZY SPLINT test2 "$CMAKEOPTS" SPLINT test2builtin "$TZCMAKEOPTS" CPPCHECK test2 "$CMAKEOPTS" CPPCHECK test2builtin "$TZCMAKEOPTS" CLANGSCAN test2 "$CMAKEOPTS" CLANGSCAN test2builtin "$TZCMAKEOPTS" CLANGTIDY test2 "$CMAKEOPTS" CLANGTIDY test2builtin "$TZCMAKEOPTS" #GCC based build tests GCC_BUILD test1 "" GCC_BUILD test2 "$CMAKEOPTS" GCC_BUILD test1cross "-DCMAKE_TOOLCHAIN_FILE=$TOP/cmake/Toolchain-Linux-GCC-i686.cmake" GCC_BUILD test2cross "-DCMAKE_TOOLCHAIN_FILE=$TOP/cmake/Toolchain-Linux-GCC-i686.cmake $CMAKEOPTS" GCC_BUILD test1builtin "-DUSE_BUILTIN_TZDATA=True" GCC_BUILD test2builtin "$TZCMAKEOPTS" #Clang based build tests CLANG_BUILD test1 "" CLANG_BUILD test2 "$CMAKEOPTS" CLANG_BUILD test1cross "-DCMAKE_TOOLCHAIN_FILE=$TOP/cmake/Toolchain-Linux-GCC-i686.cmake" CLANG_BUILD test2cross "-DCMAKE_TOOLCHAIN_FILE=$TOP/cmake/Toolchain-Linux-GCC-i686.cmake $CMAKEOPTS" #Address sanitizer ASAN_BUILD test1asan "" ASAN_BUILD test2asan "$CMAKEOPTS" ASAN_BUILD test3asan "$TZCMAKEOPTS" #Thread sanitizer TSAN_BUILD test1tsan "" TSAN_BUILD test2tsan "$CMAKEOPTS" TSAN_BUILD test3tsan "$TZCMAKEOPTS" echo "ALL TESTS COMPLETED SUCCESSFULLY" libical-3.0.1/scripts/mkderivedcomponents.pl000077500000000000000000000072031320431302500212140ustar00rootroot00000000000000#!/usr/bin/env perl ################################################################################ # (C) COPYRIGHT 2000, Eric Busboom # http://www.softwarestudio.org # # This library is free software; you can redistribute it and/or modify # it under the terms of either: # # The LGPL as published by the Free Software Foundation, version # 2.1, available at: http://www.gnu.org/licenses/lgpl-2.1.txt # # Or: # # The Mozilla Public License Version 2.0. You may obtain a copy of # the License at http://www.mozilla.org/MPL/ ################################################################################ use Getopt::Std; getopts('chspi:'); # ARG 0 is components.txt open(PV, "$ARGV[0]") || die "Can't open components file $ARGV[0]:$!"; my @components; while () { s/#.*//; chop; push(@components, $_); } close PV; # Write the file inline by copying everything before a demarcation # line, and putting the generated data after the demarcation if ($opt_i) { open(IN, $opt_i) || die "Can't open input file \"$opt_i\""; while () { if (/Do not edit/) { last; } print; } if ($opt_i) { print "# Everything below this line is machine generated. Do not edit. \n"; } else { print "/* Everything below this line is machine generated. Do not edit. */\n"; } } if ($opt_c or $opt_h and !$opt_i) { print < http://www.softwarestudio.org The contents of this file are subject to the Mozilla Public License Version 1.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.mozilla.org/MPL/ Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. ======================================================================*/ /* * THIS FILE IS MACHINE GENERATED DO NOT EDIT */ #include /* for va_arg functions */ EOM } if ($opt_p and !$opt_i) { print < # http://www.softwarestudio.org # # This library is free software; you can redistribute it and/or modify # it under the terms of either: # # The LGPL as published by the Free Software Foundation, version # 2.1, available at: http://www.gnu.org/licenses/lgpl-2.1.txt # # Or: # # The Mozilla Public License Version 2.0. You may obtain a copy of # the License at http://www.mozilla.org/MPL/ ################################################################################ require "readvaluesfile.pl"; use Getopt::Std; getopts('chspi:'); %no_xname = (RELATED => 1, RANGE => 1, RSVP => 1, XLICERRORTYPE => 1, XLICCOMPARETYPE => 1); %params = read_parameters_file($ARGV[0]); # Write the file inline by copying everything before a demarcation # line, and putting the generated data after the demarcation if ($opt_i) { open(IN, $opt_i) || die "Can't open input file $opt_i"; while () { if (//) { $autogenMsg = "of section of machine generated code (mkderivedparameters.pl). Do not edit."; if ($opt_p) { $startComment = "#"; $endComment = ""; } else { $startComment = "/*"; $endComment = " */"; } print $startComment. " START " . $autogenMsg . $endComment . "\n\n"; insert_code(); print $startComment. " END " . $autogenMsg . $endComment . "\n\n"; } else { print; } } } sub insert_code { # Write parameter enumerations and datatypes if ($opt_h) { my $enumConst = $params{'ANY'}->{"kindEnum"}; print "typedef enum icalparameter_kind {\n ICAL_ANY_PARAMETER = " . $enumConst . ",\n"; $enumVal = 1; foreach $param (sort keys %params) { next if !$param; next if $param eq 'NO' or $param eq 'ANY'; my $uc = join("", map {uc($_);} split(/-/, $param)); $enumConst = $params{$param}->{"kindEnum"}; print " ICAL_${uc}_PARAMETER = " . $enumConst . ",\n"; } $enumConst = $params{'NO'}->{"kindEnum"}; print " ICAL_NO_PARAMETER = " . $enumConst . "\n} icalparameter_kind;\n\n"; # Now create enumerations for parameter values $lastidx = $idx = 20000; print "#define ICALPARAMETER_FIRST_ENUM $idx\n\n"; foreach $param (sort keys %params) { next if !$param; next if $param eq 'NO' or $param eq 'ANY'; my $type = $params{$param}->{"C"}; my $ucv = join("", map {uc(lc($_));} split(/-/, $param)); my @enums = @{$params{$param}->{'enums'}}; if (@enums) { print "typedef enum $type {\n"; my $first = 1; foreach $e (@enums) { if (!$first) { print ",\n"; } else { $first = 0; } $e =~ /([a-zA-Z0-9\-]+)=?([0-9]+)?/; $e = $1; if ($2) { $idx = $2; } else { $idx++; } if ($idx > $lastidx) { $lastidx = $idx; } my $uce = join("", map {uc(lc($_));} split(/-/, $e)); print " ICAL_${ucv}_${uce} = $idx"; } $c_type =~ s/enum //; print "\n} $type;\n\n"; } } $lastidx++; print "#define ICALPARAMETER_LAST_ENUM $lastidx\n\n"; } if ($opt_c) { # Create the icalparameter_value to icalvalue_kind conversion table my $count = 0; my $out; foreach $enum (@{$params{'VALUE'}->{'enums'}}) { $enum =~ /([a-zA-Z0-9\-]+)=?([0-9]+)?/; $enum = $1; next if $enum eq 'X' or $enum eq 'NONE'; next if $enum eq 'NO' or $enum eq 'ERROR'; $uc = join("", map {uc(lc($_));} split(/-/, $enum)); $out .= " {ICAL_VALUE_${uc}, ICAL_${uc}_VALUE},\n"; $count++; } $count += 2; print "static const struct icalparameter_value_kind_map value_kind_map[$count] = {\n"; print $out; print " {ICAL_VALUE_X, ICAL_X_VALUE},\n"; print " {ICAL_VALUE_NONE, ICAL_NO_VALUE}\n};\n\n"; #Create the parameter Name map $out = ""; $count = 0; foreach $param (sort keys %params) { next if !$param; next if $param eq 'NO' or $param eq 'ANY'; my $lc = join("", map {lc($_);} split(/-/, $param)); my $uc = join("", map {uc(lc($_));} split(/-/, $param)); $count++; $out .= " {ICAL_${uc}_PARAMETER, \"$param\"},\n"; } $count += 1; print "static const struct icalparameter_kind_map parameter_map[$count] = {\n"; print $out; print " { ICAL_NO_PARAMETER, \"\"}\n};\n\n"; # Create the parameter value map $out = ""; $count = 0; foreach $param (sort keys %params) { next if !$param; next if $param eq 'NO' or $param eq 'ANY'; my $type = $params{$param}->{"C"}; my $uc = join("", map {uc(lc($_));} split(/-/, $param)); my @enums = @{$params{$param}->{'enums'}}; if (@enums) { foreach $e (@enums) { $e =~ /([a-zA-Z0-9\-]+)=?([0-9]+)?/; $e = $1; next if $e eq 'X' or $e eq 'NONE'; my $uce = join("", map {uc(lc($_));} split(/-/, $e)); $count++; $out .= " {ICAL_${uc}_PARAMETER,ICAL_${uc}_${uce}, \"$e\"},\n"; } } } $count += 3; print "static const struct icalparameter_map icalparameter_map[] = {\n"; print " {ICAL_ANY_PARAMETER, 0, \"\"},\n"; print $out; print " {ICAL_NO_PARAMETER, 0, \"\"}\n};\n\n"; } foreach $param (sort keys %params) { next if $param eq 'NO' or $param eq 'ANY'; my $type = $params{$param}->{'C'}; my $ucf = join("", map {ucfirst(lc($_));} split(/-/, $param)); my $lc = lc($ucf); my $uc = uc($lc); my $charorenum; my $set_code; my $pointer_check; my $pointer_check_v; my $xrange; if ($type =~ /char/) { $type =~ s/char\*/char \*/; $charorenum = " icalerror_check_arg_rz((param != 0), \"param\");\n return param->string;"; $set_code = "((struct icalparameter_impl *)param)->string = icalmemory_strdup(v);"; $pointer_check = " icalerror_check_arg_rz((v != 0), \"v\");"; $pointer_check_v = "\n icalerror_check_arg_rv((v != 0), \"v\");"; } elsif ($type =~ /int/) { $xrange = " if (param != 0) {\n return param->data;\n } else {\n return 0;\n }"; $charorenum = " icalerror_check_arg((param != 0), \"param\");\n$xrange"; $set_code = "((struct icalparameter_impl *)param)->data = v;"; } else { $xrange = " if (param->string != 0) {\n return ICAL_${uc}_X;\n }\n" if !exists $no_xname{$uc}; $charorenum = " icalerror_check_arg((param != 0), \"param\");\n if (!param) {\n return ICAL_${uc}_NONE;\n }\n$xrange\n return ($type)(param->data);"; $pointer_check = " icalerror_check_arg_rz(v >= ICAL_${uc}_X, \"v\");\n icalerror_check_arg_rz(v < ICAL_${uc}_NONE, \"v\");"; $pointer_check_v = "\n icalerror_check_arg_rv(v >= ICAL_${uc}_X, \"v\");\n icalerror_check_arg_rv(v < ICAL_${uc}_NONE, \"v\");"; $set_code = "((struct icalparameter_impl *)param)->data = (int)v;"; } if ($opt_c) { print <string != NULL) { free((void *)param->string); } $set_code } EOM } elsif ($opt_h) { print <[0] = \$p; return \$self; } sub get { my \$self = shift; my \$impl = \$self->_impl(); return Net::ICal::icalparameter_as_ical_string(\$impl); } sub set { # This is hard to implement, so I've punted for now. die "Set is not implemented"; } EOM } } if ($opt_h) { print < # http://www.softwarestudio.org # # This library is free software; you can redistribute it and/or modify # it under the terms of either: # # The LGPL as published by the Free Software Foundation, version # 2.1, available at: http://www.gnu.org/licenses/lgpl-2.1.txt # # Or: # # The Mozilla Public License Version 2.0. You may obtain a copy of # the License at http://www.mozilla.org/MPL/ ################################################################################ require "readvaluesfile.pl"; use Getopt::Std; getopts('chspmi:'); # ARG 0 is properties.csv %propmap = read_properties_file($ARGV[0]); # ARG 1 is value-types.txt %valuemap = read_values_file($ARGV[1]); $include_vanew = 1; # Write the file inline by copying everything before a demarcation # line, and putting the generated data after the demarcation if ($opt_i) { open(IN, $opt_i) || die "Can't open input file $opt_i"; while () { if (//) { insert_code(); } else { print; } } } sub fudge_data { my $prop = shift; my $value = $propmap{$prop}->{'lic_value'}; if (!$value) { die "Can't find value for property \"$prop\"\n"; } my $ucf = join("", map {ucfirst(lc($_));} split(/-/, $prop)); my $lc = lc($ucf); my $uc = uc($lc); my $ucfvalue = join("", map {ucfirst(lc($_));} split(/-/, $value)); my $lcvalue = lc($ucfvalue); my $ucvalue = uc($lcvalue); my $type = $valuemap{$value}->{C}->[1]; $type =~ s/char\*/char \*/; my @comp_types = @{$valuemap{$value}->{'components'}}; return ($uc, $lc, $lcvalue, $ucvalue, $type, @comp_types); } sub insert_code { # Create the property map data if ($opt_c) { my @props = sort {$propmap{$a}->{"kindEnum"} <=> $propmap{$b}->{"kindEnum"}} keys %propmap; my $count = scalar(@props); print "static const struct icalproperty_map property_map[$count] = {\n"; foreach $prop (@props) { next if !$prop; next if $prop eq 'NO'; my ($uc, $lc, $lcvalue, $ucvalue, $type, @comp_types) = fudge_data($prop); my $defvalue = $propmap{$prop}->{'default_value'}; $defvalue =~ s/-//g; my @flags = @{$propmap{$prop}->{'flags'}}; print " { ICAL_${uc}_PROPERTY, \"$prop\",\n"; print " ICAL_${ucvalue}_VALUE, ICAL_${defvalue}_VALUE,\n"; print " { "; if (@comp_types) { foreach $comp (@comp_types) { $comp =~ s/-//g; print "ICAL_${comp}_VALUE, "; } } elsif ($defvalue ne "NO") { print "ICAL_${defvalue}_VALUE, "; } else { print "ICAL_${ucvalue}_VALUE, "; } print "ICAL_NO_VALUE }, "; if (@flags) { my $sep = "\n "; foreach $flag (@flags) { $flag =~ s/-//g; $flag = uc($flag); print "${sep}ICAL_PROPERTY_${flag}"; $sep = " | "; } } else { print "0"; } print " },\n"; } $prop = "NO"; my ($uc, $lc, $lcvalue, $ucvalue, $type) = fudge_data($prop); print " { ICAL_${uc}_PROPERTY, \"\","; print " ICAL_NO_VALUE, ICAL_NO_VALUE,\n"; print " { ICAL_NO_VALUE }, 0 }\n}"; print ";\n\n"; $count = 1; $bigcount = 0; my %lines; foreach $value (sort keys %valuemap) { next if !$value; next if $value eq 'NO' or $prop eq 'ANY'; my $ucv = join("", map {uc(lc($_));} split(/-/, $value)); my @enums = @{$valuemap{$value}->{'enums'}}; if (@enums) { my ($c_autogen, $c_type) = @{$valuemap{$value}->{'C'}}; foreach $e (@enums) { $e =~ /([a-zA-Z0-9\-]+)=?([0-9]+)?/; $e = $1; if ($2) { $idx = $2; } else { $idx++; } my $uce = join("", map {uc(lc($_));} split(/-/, $e)); if ($e ne "X" and $e ne "NONE") { $str = $e; } else { $str = ""; } if ($e eq "NONE") { $bigcount += 100; } # Create empty "future" properties so the hash math works. if ($e eq "NONE") { my ($tbd) = 1; $saveidx++; for (; $saveidx < $idx ; $saveidx++, $tbd++) { $lines{$saveidx} = " {ICAL_${ucv}_PROPERTY,ICAL_${ucv}_NONE, \"\" }, /*$saveidx*/\n"; } } # Place each property into a hash based on the index specified in value-types.csv # The lines are printed so they're in the same order as the indices $lines{$idx} = " {ICAL_${ucv}_PROPERTY,ICAL_${ucv}_${uce}, \"$str\" }, /*$idx*/\n"; $saveidx = $idx; $count++; } } } $bigcount++; print "static const struct icalproperty_enum_map enum_map[$bigcount] = {\n"; foreach $line (sort keys %lines) { print $lines{$line}; } print " {ICAL_NO_PROPERTY, 0, \"\"}\n};\n\n"; } if ($opt_h) { # Create the property enumerations list my $enumConst = $propmap{'ANY'}->{"kindEnum"}; print "typedef enum icalproperty_kind {\n ICAL_ANY_PROPERTY = " . $enumConst . ",\n"; foreach $prop (sort keys %propmap) { next if !$prop; next if $prop eq 'NO' or $prop eq 'ANY'; my ($uc, $lc, $lcvalue, $ucvalue, $type) = fudge_data($prop); $enumConst = $propmap{$prop}->{"kindEnum"}; print " ICAL_${uc}_PROPERTY = " . $enumConst . ",\n"; } $enumConst = $propmap{'NO'}->{"kindEnum"}; print " ICAL_NO_PROPERTY = " . $enumConst . "\n} icalproperty_kind;\n"; } foreach $prop (sort keys %propmap) { next if !$prop; next if $prop eq 'NO' or $prop eq 'ANY'; my ($uc, $lc, $lcvalue, $ucvalue, $type) = fudge_data($prop); my $pointer_check; if ($type =~ /\*/) { $pointer_check = " icalerror_check_arg_rz((v != 0), \"v\");\n" if $type =~ /\*/; } elsif ($type eq "void") { $pointer_check = " icalerror_check_arg_rv((v != 0), \"v\");\n" if $type =~ /\*/; } my $set_pointer_check = "\n icalerror_check_arg_rv((v != 0), \"v\");" if $type =~ /\*/; if ($opt_c) { # Generate C source if ($include_vanew) { print < # http://www.softwarestudio.org # # This library is free software; you can redistribute it and/or modify # it under the terms of either: # # The LGPL as published by the Free Software Foundation, version # 2.1, available at: http://www.gnu.org/licenses/lgpl-2.1.txt # # Or: # # The Mozilla Public License Version 2.0. You may obtain a copy of # the License at http://www.mozilla.org/MPL/ ################################################################################ use lib '.'; require 'readvaluesfile.pl'; use Getopt::Std; getopts('chi:'); #Options # c -> generate c code file # h-> generate header file # Open with value-types.txt my %h = read_values_file($ARGV[0]); # Write the file inline by copying everything before a demarcation # line, and putting the generated data after the demarcation if ($opt_i) { open(IN, $opt_i) || die "Can't open input file $opt_i"; while () { if (//) { insert_code(); } else { print; } } if ($opt_h) { print "#endif /*ICALVALUE_H*/\n"; } } sub insert_code { # Map type names to the value in the icalvalue_impl data union */ %union_map = ( BOOLEAN => 'int', CALADDRESS => 'string', DATE => 'time', DATETIME => 'time', DATETIMEDATE => 'time', DATETIMEPERIOD => 'period', DURATION => 'duration', INTEGER => 'int', TEXT => 'string', URI => 'string', UTCOFFSET => 'int', QUERY => 'string', X => 'string' ); if ($opt_h) { # First print out the value enumerations $idx = $h{'ANY'}->{"kindEnum"}; print "typedef enum icalvalue_kind {\n"; print " ICAL_ANY_VALUE=$idx,\n"; foreach $value (sort keys %h) { next if !$value; next if $value eq 'NO' or $value eq 'ANY'; my $ucv = join("", map {uc(lc($_));} split(/-/, $value)); $idx = $h{$value}->{"kindEnum"}; print " ICAL_${ucv}_VALUE=$idx,\n"; } $idx = $h{'NO'}->{"kindEnum"}; print " ICAL_NO_VALUE=$idx\n} icalvalue_kind ;\n\n"; # Now create enumerations for property values $lastidx = $idx = 10000; print "#define ICALPROPERTY_FIRST_ENUM $idx\n\n"; foreach $value (sort keys %h) { next if !$value; next if $value eq 'NO' or $value eq 'ANY'; my $ucv = join("", map {uc(lc($_));} split(/-/, $value)); my @enums = @{$h{$value}->{'enums'}}; if (@enums) { my ($c_autogen, $c_type) = @{$h{$value}->{'C'}}; print "typedef $c_type {\n"; my $first = 1; foreach $e (@enums) { if (!$first) { print ",\n"; } else { $first = 0; } $e =~ /([a-zA-Z0-9\-]+)=?([0-9]+)?/; $e = $1; if ($2) { $idx = $2; } else { $idx++; } if ($idx > $lastidx) { $lastidx = $idx; } my $uce = join("", map {uc(lc($_));} split(/-/, $e)); print " ICAL_${ucv}_${uce} = $idx"; } $c_type =~ s/enum //; print "\n} $c_type;\n\n"; } } $lastidx++; print "#define ICALPROPERTY_LAST_ENUM $lastidx\n"; } if ($opt_c) { # print out the value to string map my $count = scalar(keys %h) + 1; print "static const struct icalvalue_kind_map value_map[$count]={\n"; foreach $value (keys %h) { next if $value eq 'NO' or $value eq 'ANY'; my $ucv = join("", map {uc(lc($_));} split(/-/, $value)); print " {ICAL_${ucv}_VALUE,\"$value\"},\n"; } print " {ICAL_NO_VALUE,\"\"}\n};"; } foreach $value (sort keys %h) { next if $value eq 'ANY'; my $autogen = $h{$value}->{C}->[0]; my $type = $h{$value}->{C}->[1]; $type =~ s/char\*/char \*/; my $ucf = join("", map {ucfirst(lc($_));} split(/-/, $value)); my $lc = lc($ucf); my $uc = uc($lc); my $pointer_check = " icalerror_check_arg_rz((v != 0), \"v\");\n" if $type =~ /\*/; my $pointer_check_rv = " icalerror_check_arg_rv((v != 0), \"v\");\n" if $type =~ /\*/; my $assign; if ($type =~ /char/) { $assign = "icalmemory_strdup(v);\n\n if (impl->data.v_string == 0) {\n errno = ENOMEM;\n }\n"; } else { $assign = "v;"; } my $union_data; if (@{$h{$value}->{'enums'}}) { $union_data = 'enum'; } elsif (exists $union_map{$uc}) { $union_data = $union_map{$uc}; } else { $union_data = $lc; } if ($opt_c && $autogen) { print "\ icalvalue *icalvalue_new_${lc}($type v)\ {\ struct icalvalue_impl *impl;\ $pointer_check\ impl = icalvalue_new_impl(ICAL_${uc}_VALUE);\ icalvalue_set_${lc}((icalvalue *)impl, v);\ return (icalvalue*)impl;\ }\ \ void icalvalue_set_${lc}(icalvalue *value, $type v)\ {\ struct icalvalue_impl *impl;\ icalerror_check_arg_rv((value != 0), \"value\");\ $pointer_check_rv\ icalerror_check_value_type(value, ICAL_${uc}_VALUE);\ impl = (struct icalvalue_impl *)value;\n"; if ($union_data eq 'string') { print " if (impl->data.v_${union_data} != 0) {\n free((void *)impl->data.v_${union_data});\n }\n"; } print "\ impl->data.v_$union_data = $assign\ icalvalue_reset_kind(impl);\n}\n\n"; print "$type\ icalvalue_get_${lc}(const icalvalue *value)\n{\n"; if ($union_data eq 'string') { print " icalerror_check_arg_rz((value != 0), \"value\");\n"; } else { print " icalerror_check_arg((value != 0), \"value\");\n"; if ($union_data eq 'enum') { print " if (!value) {\n return ICAL_${uc}_NONE;\n }\n"; } elsif ($union_data eq 'int') { print " if (!value) {\n return 0;\n }\n"; } elsif ($union_data eq 'float') { print " if (!value) {\n return 0.0;\n }\n"; } elsif ($union_data eq 'time') { print " if (!value) {\n return icaltime_null_time();\n }\n"; } elsif ($union_data eq 'duration') { print " if (!value) {\n return icaldurationtype_null_duration();\n }\n"; } elsif ($union_data eq 'period') { print " if (!value) {\n return icalperiodtype_null_period();\n }\n"; } elsif ($union_data eq 'requeststatus') { print " if (!value) {\n return icalreqstattype_from_string(\"0.0\");\n }\n"; } } print " icalerror_check_value_type(value, ICAL_${uc}_VALUE);\ return ((struct icalvalue_impl *)value)->data.v_${union_data};\n}\n"; } elsif ($opt_h && $autogen) { print "\n/* $value */\ LIBICAL_ICAL_EXPORT icalvalue *icalvalue_new_${lc}($type v);\ LIBICAL_ICAL_EXPORT $type icalvalue_get_${lc}(const icalvalue *value);\ LIBICAL_ICAL_EXPORT void icalvalue_set_${lc}(icalvalue *value, ${type} v);\n"; } } } libical-3.0.1/scripts/mkrestrictiontable.pl000077500000000000000000000036761320431302500210530ustar00rootroot00000000000000#!/usr/bin/env perl ################################################################################ # (C) COPYRIGHT 2000, Eric Busboom # http://www.softwarestudio.org # # This library is free software; you can redistribute it and/or modify # it under the terms of either: # # The LGPL as published by the Free Software Foundation, version # 2.1, available at: http://www.gnu.org/licenses/lgpl-2.1.txt # # Or: # # The Mozilla Public License Version 2.0. You may obtain a copy of # the License at http://www.mozilla.org/MPL/ ################################################################################ use Getopt::Std; getopts('i:'); # the argument should be the path to the restriction datafile, usually # design-data/restrictions.csv open(F, "$ARGV[0]") || die "Can't open restriction data file $ARGV[0]:$!"; # Write the file inline by copying everything before a demarcation # line, and putting the generated data after the demarcation if ($opt_i) { open(IN, $opt_i) || die "Can't open input file $opt_i"; while () { if (//) { insert_code(); } if (/Do not edit/) { last; } print; } close IN; } sub insert_code { # First build the property restriction table print "static const icalrestriction_property_record icalrestriction_property_records[] = {\n"; while () { chop; s/\#.*$//; my ($method, $targetcomp, $prop, $subcomp, $restr, $sub) = split(/,/, $_); next if !$method; if (!$sub) { $sub = "NULL"; } else { $sub = "icalrestriction_" . $sub; } $restr =~ s/\s+$//; if ($prop ne "NONE") { print( " \{ICAL_METHOD_${method}, ICAL_${targetcomp}_COMPONENT, ICAL_${prop}_PROPERTY, ICAL_RESTRICTION_${restr}, $sub},\n" ); } } # Print the terminating line print " {ICAL_METHOD_NONE, ICAL_NO_COMPONENT, ICAL_NO_PROPERTY, ICAL_RESTRICTION_NONE, NULL}\n"; print "};\n"; } libical-3.0.1/scripts/readvaluesfile.pl000066400000000000000000000057371320431302500201360ustar00rootroot00000000000000################################################################################ # (C) COPYRIGHT 2000, Eric Busboom # http://www.softwarestudio.org # # This library is free software; you can redistribute it and/or modify # it under the terms of either: # # The LGPL as published by the Free Software Foundation, version # 2.1, available at: http://www.gnu.org/licenses/lgpl-2.1.txt # # Or: # # The Mozilla Public License Version 2.0. You may obtain a copy of # the License at http://www.mozilla.org/MPL/ ################################################################################ sub read_values_file { my $path = shift; my %h; open(F, $path) || die "Can't open values file $path"; while () { chop; s/#.*$//g; s/\"//g; s/\r//g; next if !$_; @column = split(/,/, $_); my $value_name = $column[0]; my $enumConst = $column[1]; my $c_type_str = $column[2]; my $c_autogen = ($c_type_str =~ /\(a\)/); my $c_type = $c_type_str; $c_type =~ s/\(.\)//; my $python_type = $column[3]; my $components = $column[4]; my $enum_values = $column[5]; my @components; if ($components ne "unitary") { @components = split(/;/, $components); } else { @components = (); } my @enums; if ($enum_values) { @enums = split(/;/, $enum_values); } else { @enums = (); } $h{$value_name} = { C => [$c_autogen, $c_type], kindEnum => $enumConst, perl => $perl_type, python => $python_type, components => [@components], enums => [@enums] }; } return %h; } sub read_properties_file { my $path = shift; my %h; open(F, $path) || die "Can't open properties file $path"; while () { chop; s/#.*$//g; s/\"//g; s/\r//g; next if !$_; @column = split(/,/, $_); my $property_name = $column[0]; my $enumConst = $column[1]; my $lic_value = $column[2]; my $default_value = $column[3]; my $flags = $column[4]; my @flags; if ($flags ne "") { @flags = split(/;/, $flags); } else { @flags = (); } $h{$property_name} = { lic_value => $lic_value, kindEnum => $enumConst, default_value => $default_value, flags => [@flags] }; } return %h; } sub read_parameters_file { my $path = shift; my %h; open(F, $path) || die "Can't open parameters file $path"; while () { chop; s/#.*$//g; s/\"//g; s/\r//g; next if !$_; @column = split(/\,/, $_); my $parameter_name = $column[0]; my $enumConst = $column[1]; my $data_type = $column[2]; my $enum_string = $column[3]; my @enums; if ($enum_string) { @enums = split(/;/, $enum_string); } $h{$parameter_name} = { C => $data_type, kindEnum => $enumConst, enums => [@enums] }; } close(F); return %h; } 1; libical-3.0.1/scripts/set_compiler_env.bat000066400000000000000000000021621320431302500206200ustar00rootroot00000000000000@echo off :: Now we declare a scope Setlocal EnableDelayedExpansion EnableExtensions if not defined Configuration set Configuration=2015 if "%Configuration%"=="MinGW" ( goto :mingw ) set arch=x86 if "%platform%" EQU "x64" ( set arch=x86_amd64 ) if "%Configuration%"=="2015" ( set SET_VS_ENV="C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" ) if "%Configuration%"=="2013" ( set SET_VS_ENV="C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\vcvarsall.bat" ) if "%Configuration%"=="2012" ( set SET_VS_ENV="C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\vcvarsall.bat" ) if "%Configuration%"=="2010" ( set SET_VS_ENV="C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\vcvarsall.bat" ) if "%Configuration%"=="2008" ( set SET_VS_ENV="C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\vcvarsall.bat" ) :: Visual Studio detected endlocal & call %SET_VS_ENV% %arch% goto :eof :: MinGW detected :mingw :: workaround for CMake not wanting sh.exe in PATH for MinGW endlocal & set PATH=%PATH:C:\Program Files\Git\usr\bin;=% & set PATH=c:\MinGW\bin;%PATH% libical-3.0.1/scripts/setup-travis.sh000077500000000000000000000006461320431302500176050ustar00rootroot00000000000000#/bin/sh -f # things to do for travis-ci in the before_install section if ( test "`uname -s`" = "Darwin" ) then brew install icu4c brew install db brew install gobject-introspection brew install gtk-doc else sudo apt-get update -qq sudo apt-get install libicu-dev sudo apt-get install libdb4.8-dev sudo apt-get install gobject-introspection libgirepository1.0-dev sudo apt-get install gtk-doc-tools fi libical-3.0.1/src/000077500000000000000000000000001320431302500136725ustar00rootroot00000000000000libical-3.0.1/src/CMakeLists.txt000066400000000000000000000002421320431302500164300ustar00rootroot00000000000000add_subdirectory(libical) add_subdirectory(libicalss) add_subdirectory(libicalvcal) if(ICAL_GLIB) add_subdirectory(libical-glib) endif() add_subdirectory(test) libical-3.0.1/src/Net-ICal-Libical/000077500000000000000000000000001320431302500165635ustar00rootroot00000000000000libical-3.0.1/src/Net-ICal-Libical/MANIFEST000066400000000000000000000004331320431302500177140ustar00rootroot00000000000000MANIFEST Makefile.PL lib/Net/ICal/Libical.pm netical.i netical_wrap.c netical_wrap.doc test-data/2446.mime test-data/error test-data/mail-examples test-data/no-error test-data/rfc2445.ics test-data/rfc2446.ics test-data/single-with-error test/example.pl test/libical.pl test/swig.pl libical-3.0.1/src/Net-ICal-Libical/Makefile.PL000066400000000000000000000015731320431302500205430ustar00rootroot00000000000000#!/usr/bin/perl use ExtUtils::MakeMaker; WriteMakefile( 'MAKEFILE'=> 'Makefile', 'VERSION_FROM' => 'lib/Net/ICal/Libical.pm', 'NAME' => 'Net::ICal::Libical', 'INC' => '-I../libical -I ../libicalss', 'LIBS' => ['-L../libical/.libs -L../libicalss/.libs -lical -licalss -lm'], 'OBJECT' => 'netical_wrap.o', # Object files dist => { COMPRESS =>'gzip', SUFFIX =>'gz' }, ); sub MY::top_targets { my $self = shift; my $old = $self->MM::top_targets; return "all:: netical_wrap.o\n$old"; } sub MY::postamble { return < libical-3.0.1/src/Net-ICal-Libical/lib/000077500000000000000000000000001320431302500173315ustar00rootroot00000000000000libical-3.0.1/src/Net-ICal-Libical/lib/Net/000077500000000000000000000000001320431302500200575ustar00rootroot00000000000000libical-3.0.1/src/Net-ICal-Libical/lib/Net/ICal/000077500000000000000000000000001320431302500206675ustar00rootroot00000000000000libical-3.0.1/src/Net-ICal-Libical/lib/Net/ICal/Libical.pm000066400000000000000000000221441320431302500225670ustar00rootroot00000000000000#!/usr/bin/perl #====================================================================== # FILE: Libical.pm # CREATOR: eric # # (C) COPYRIGHT 2000, Eric Busboom # http://www.softwarestudio.org # # This library is free software; you can redistribute it and/or modify # it under the terms of either: # # The LGPL as published by the Free Software Foundation, version # 2.1, available at: http://www.gnu.org/licenses/lgpl-2.1.html # # Or: # # The Mozilla Public License Version 2.0. You may obtain a copy of # the License at http://www.mozilla.org/MPL/ #====================================================================== # This part of this file was automatically generated by SWIG require Net::ICal::Libical::Component; require Net::ICal::Libical::Property; require Net::ICal::Libical::Time; require Net::ICal::Libical::Duration; package Net::ICal::Libical; require Exporter; require DynaLoader; @ISA = qw(Exporter DynaLoader); package Net::ICal::Libical; bootstrap Net::ICal::Libical; var_Net__ICal__Libical_init(); @EXPORT = qw( ); $VERSION = "0.01"; 1; sub validate_component { my $comp_str = shift; my $c = Net::ICal::Libical::icalparser_parse_string($comp_str); my $out; die "Failed to parse component" if !$c; my $r = Net::ICal::Libical::icalrestriction_check($c); $out = Net::ICal::Libical::icalcomponent_as_ical_string($c); Net::ICal::Libical::icalcomponent_free($c); return $out; } sub generate_occurrences { my $rule = shift; my $start = shift; my $count = shift; my @out; my $array = Net::ICal::Libical::icallangbind_new_array(25); Net::ICal::Libical::icalrecur_expand_recurrence($rule,$start, $count,$array); for($i = 0; $i<$count; $i++){ my $t = Net::ICal::Libical::icallangbind_access_array($array,$i); if($t != 0) { push(@out,$t); } } Net::ICal::Libical::icallangbind_free_array($array); return @out; } # The remaining code is just the interface declarations for a complete # perl binding to libical. Currently, it is looking for an author.... 1; __END__ #""" Represent iCalendar DATE, TIME and DATE-TIME "" package Net::ICal::Libical::Time; @ISA = (Property); sub new {} #"""Updates value and value_type based on the (internal) self.tt.""" sub _update_value { } # " Return true if this is a valid time " sub valid { } # """ Return or set time in seconds past POSIX epoch""" sub utc_seconds {} # """ Return or set boolean indicating if time is in UTC """ sub is_utc {} # Get/Set booll indicating is time is a date sub is_date(self,v=None): #"" Return or set the timezone string for this time """ sub timezone {} #"" Get or set the seconds component of this time """ sub second {} sub minute {} sub hour {} sub day {} sub month {} sub year {} # How dow you over load +,- in perl? # Add duration to time = time sub __add__{} # Subtract time from time = duration # Subtract duration from time = time sub __sub__(self,o): package Net::ICal::Libical::Duration(Property): @ISA = (Property); sub new {} sub _update_value {} #"Return true if this is a valid duration" sub valid {} # """Return or set duration in seconds""" sub seconds {} #"""Represent a span of time""" package Net::ICal::Libical::Period; @ISA = (Property); sub new{} sub _end_is_duration {} sub _end_is_time {} sub _update_value {} #"Return true if this is a valid period" sub valid {} #Return or set start time of the period. The start time may be #expressed as an RFC2445 format string or an instance of Time. #The return value is an instance of Time sub start {} #Return or set end time of the period. The end time may be #expressed as an RFC2445 format string or an instance of Time. #The return value is an instance of Time. #If the Period has a duration set, but not an end time, this #method will caluculate the end time from the duration. sub end {} #Return or set the duration of the period. The duration may be #expressed as an RFC2445 format string or an instance of Duration. #The return value is an instance of Duration. #If the period has an end time set, but not a duration, this #method will calculate the duration from the end time. sub duration{} # Get set the timezone for the period. Basically returns self->dict{TZID} sub timezone(self,v=None): # Represents the value and all parameters of an attendee package Net::ICal::Libical::Attendee(Property): @ISA = (Property); sub new{} # Methods for accessing enumerated parameters sub cn {} sub cutype {} sub dir {} sub delegated_from {} sub delegated_to {} sub language {} sub member {} sub partstat {} sub role {} sub rsvp {} sub sent_by {} package Net::ICal::Libical::Organizer; @ISA = (Property) # Methods for accessing enumerated parameters sub cn{} sub dir{} sub language {} sub sent_by {} package Net::ICal::Libical::Recurrence_Id; @ISA= (Property) package Net::ICal::Libical::Attach; @ISA= (Property) package Net::ICal::Libical::Event; @ISA= (Component) sub component_type {} #"Returns a copy of the object." sub clone {} #Sets or returns the value of the DTEND property. #Usage: #dtend(time_obj) # Set the value using a Time object #dtend('19970101T123000Z') # Set the value as an iCalendar string #dtend(982362522) # Set the value using seconds (time_t) #dtend() # Return a Time # #If the dtend value is being set and duration() has a value, the #duration property will be removed. sub dtend{} #Sets or returns the value of the duration property. #Usage: #duration(dur_obj) # Set the value using a Duration object #duration("P3DT12H") # Set value as an iCalendar string #duration(3600) # Set duration using seconds #duration() # Return a duration # #If the duration value is being set and dtend() has a value, the dtend #property will be removed. sub duration{} #Sets attendees or returns a list of Attendee objects. sub attendees {} #Sets or gets the value of the ORGANIZER property. #Usage: #organizer(orgObj) # Set value using an organizer object #organizer('MAILTO:jd@not.com') # Set value using a CAL-ADDRESS string #organizer() # Return a CAL-ADDRESS string sub organizer{} #"Sets or gets the SUMMARY value of the Event." sub summary{} #Sets or gets the UID of the Event. sub uid{} #Sets or gets the value for the RECURRENCE-ID property. #Usage: #Recurrence_id(recIdObj) # Set using a Recurrence_Id object #Recurrence_id("19700801T133000") # Set using an iCalendar string #Recurrence_id(8349873494) # Set using seconds from epoch #Recurrence_id() # Return a Time sub recurrence_id{} #Sets or gets the SEQUENCE value of the Event. #Usage: #sequence(1) # Set the value using an integer #sequence('2') # Set the value using a string containing an integer #sequence() # Return an integer sub sequence{} #Sets or returns the value of the LAST-MODIFIED property. #Usage: #lastmodified(time_obj) # Set the value using a Time object #lastmodified('19970101T123000Z')# Set using an iCalendar string #lastmodified(982362522) # Set using seconds #lastmodified() # Return a Time sub lastmodified{} #Sets or returns the value of the CREATED property. #Usage: #created(time_obj) # Set the value using a Time object #created('19970101T123000Z') # Set using an iCalendar string #created(982362522) # Set using seconds #created() # Return a Time sub created {} sub related_to{} sub comment{} "Sets or returns the value of the DESCRIPTION property." sub description {} #Sets categories or returns a list of Attendee objects. sub categories {} sub attach{} #Represents a set of event occurrences. This #package controls a component's RRULE, EXRULE, RDATE and EXDATE #properties and can produce from them a set of occurrences. package Net::ICal::Libical::RecurrenceSet: #Include a date or rule to the set. #Use date= or pass in a #Time instance to include a date. Included dates will add an #RDATE property or will remove an EXDATE property of the same #date. #Use rule= or pass in a string to include a rule. Included #rules with either add a RRULE property or remove an EXRULE #property. sub include{} #Exclude date or rule to the set. #Use date= or pass in a Time instance to exclude a #date. Excluded dates will add an EXDATE property or will remove #an RDATE property of the same date. #Use rule= or pass in a string to exclude a rule. Excluded #rules with either add an EXRULE property or remove an RRULE #property. sub exclude{} #Return 'count' occurrences as a tuple of Time instances. sub occurrences{} package Net::ICal::Libical::Store; sub new{} sub path{} sub mark{} sub commit{} sub addComponent{} sub removeComponent{} sub countComponents{} sub select{} sub clearSelect{} sub fetch{} sub fetchMatchK{} sub modify{} sub currentComponent{} sub firstComponent{} sub nextComponent{} package Net::ICal::Libical::FileStore; @ISA = (Store) sub new{} sub path{} sub mark{} sub commit{} sub addComponent{} sub removeComponent{} sub countComponents{} sub select{} sub clearSelect{} sub fetch{} sub fetchMatchK{} sub modify{} sub currentComponent{} sub firstComponent{} sub nextComponent{} 1; libical-3.0.1/src/Net-ICal-Libical/lib/Net/ICal/Libical/000077500000000000000000000000001320431302500222265ustar00rootroot00000000000000libical-3.0.1/src/Net-ICal-Libical/lib/Net/ICal/Libical/Component.pm000066400000000000000000000073121320431302500245310ustar00rootroot00000000000000#!/usr/bin/perl #====================================================================== # FILE: Component.pm # CREATOR: eric 1 Mar 01 # # (C) COPYRIGHT 2000, Eric Busboom # http://www.softwarestudio.org # # This library is free software; you can redistribute it and/or modify # it under the terms of either: # # The LGPL as published by the Free Software Foundation, version # 2.1, available at: http://www.gnu.org/licenses/lgpl-2.1.html # # Or: # # The Mozilla Public License Version 2.0. You may obtain a copy of # the License at http://www.mozilla.org/MPL/ #====================================================================== package Net::ICal::Libical::Component; use Net::ICal::Libical; use strict; sub new{ my $class = shift; my $ical_str = shift; # Ical data in string form my $self = {}; $self->{'comp_p'} = Net::ICal::Libical::icalparser_parse_string($ical_str); die "Can't parse string into component" if !$self->{'comp_p'}; bless $self, $class; } sub new_from_ref { my $class = shift; my $r = shift; my $self = {}; $self->{'comp_p'} = $r; bless $self, $class; } # Destroy must call icalcomponent_free() if icalcomponent_get_parent() # returns NULL sub DESTROY { my $self = shift; my $c = $self->{'comp_p'}; if($c && !Net::ICal::Libical::icalcomponent_get_parent($c)){ Net::ICal::Libical::icalcomponent_free($c); } } # Return an array of all properties of the given type sub properties{ my $self = shift; my $prop_name = shift; my @props; if(!$prop_name){ $prop_name = 'ANY'; } # To loop over properties # $comp_p = $self->{'comp_p'} # $p = icallangbind_get_first_property($comp_p,$prop_name) # $p = icallangbind_get_next_property($comp_p,$prop_name) my $c = $self->{'comp_p'}; my $p; for($p = Net::ICal::Libical::icallangbind_get_first_property($c,$prop_name); $p; $p = Net::ICal::Libical::icallangbind_get_next_property($c,$prop_name)){ my $d_string = Net::ICal::Libical::icallangbind_property_eval_string($p,"=>"); my %dict = %{eval($d_string)}; $dict{'ref'} = $p; # Now, look at $dict{'value_type'} or $dict{'name'} to construct a # derived class of Property. I'll do this later. my $prop; if($dict{'value_type'} eq 'DATE' or $dict{'value_type'} eq 'DATE-TIME'){ $prop = new Net::ICal::Libical::Time(\%dict); } elsif($dict{'value_type'} eq 'DURATION' ) { $prop = new Net::ICal::Libical::Duration(\%dict); } else { $prop = new Net::ICal::Libical::Property(\%dict); } push(@props,$prop); } return @props; } sub add_property { # if there is a 'ref' key in the prop's dict, then it is owned by # an icalcomponent, so dont add it again. But, you may check that # it is owned by this component with: # icalproperty_get_parent(p->{'ref'}') != $self->{'comp_p'} # If there is no 'ref' key, then create one with $p->{'ref'} = # icalproperty_new_from_string($p->as_ical_string) } sub remove_property { # If $p->{'ref'} is set, then remove the property with # icalcomponent_remove_property() } } # Return an array of all components of the given type sub components { my $self = shift; my $comp_name = shift; my @comps; if(!$comp_name){ $comp_name = 'ANY'; } my $c = $self->{'comp_p'}; my $p; for($p = Net::ICal::Libical::icallangbind_get_first_component($c,$comp_name); $p; $p = Net::ICal::Libical::icallangbind_get_next_component($c,$comp_name)){ push(@comps, Net::ICal::Libical::Component->new_from_ref($p)); } return @comps; } sub add_component {} sub remove_component {} sub as_ical_string { my $self = shift; return Net::ICal::Libical::icalcomponent_as_ical_string($self->{'comp_p'}) } 1; libical-3.0.1/src/Net-ICal-Libical/lib/Net/ICal/Libical/Duration.pm000066400000000000000000000071161320431302500243560ustar00rootroot00000000000000#============================================================================= # FILE: Duration.pm # CREATOR: eric # # (C) COPYRIGHT 2000, Eric Busboom # http://www.softwarestudio.org # # This library is free software; you can redistribute it and/or modify # it under the terms of either: # # The LGPL as published by the Free Software Foundation, version # 2.1, available at: http://www.gnu.org/licenses/lgpl-2.1.html # # Or: # # The Mozilla Public License Version 2.0. You may obtain a copy of # the License at http://www.mozilla.org/MPL/ #============================================================================= =head1 NAME Net::ICal::Duration -- represent a length of time =head1 SYNOPSIS use Net::ICal; $d = Net::ICal::Duration->new("P3DT6H15M10S"); $d = Net::ICal::Duration->new(3600); # 1 hour in seconds =head1 DESCRIPTION I Represents a length of time, such a 3 days, 30 seconds or 7 weeks. You would use this for representing an abstract block of time; "I want to have a 1-hour meeting sometime." If you want a calendar- and timezone-specific block of time, see Net::ICal::Period. =cut #============================================================================= package Net::ICal::Libical::Duration; use Net::ICal::Libical::Property; use strict; use Carp; @Net::ICal::Libical::Duration::ISA = qw ( Net::ICal::Libical::Property ); =head1 METHODS =head2 new Create a new I from: =over 4 =item * A string in RFC2445 duration format =item * An integer representing a number of seconds =cut sub new { my $package = shift; my $arg = shift; my $self; if (ref($arg) == 'HASH'){ # Construct from dictionary $self = Net::ICal::Libical::Property::new($package,$arg); my $val=Net::ICal::Libical::icalproperty_get_value_as_string($self->{'ref'}); $self->{'dur'} = Net::ICal::Libical::icaldurationtype_from_string($val); return $self; } elsif ($arg =~ /^[-+]?\d+$/){ # Seconds $self = Net::ICal::Libical::Property::new($package,'DURATION'); $self->{'dur'} = Net::ICal::Libical::icaldurationtype_new_from_int($arg); } elsif ($arg) { # iCalendar string $self = Net::ICal::Libical::Property::new($package,'DURATION'); $self->{'dur'} = Net::ICal::Libical::icaldurationtype_new_from_string($arg); } else { die; } $self->_update_value(); return $self; } sub _update_value { my $self = shift; die "Can't find internal icalduration reference" if !$self->{'dur'}; $self->value(Net::ICal::Libical::icaldurationtype_as_ical_string($self->{'dur'})); } =head2 clone() Return a new copy of the duration. =cut sub clone { die "Not Implemented"; } =head2 is_valid() Determine if this is a valid duration (given criteria TBD). =cut sub is_valid { die "Not Implemented;" } =head2 seconds() Set or Get the length of the duration as seconds. =cut sub seconds { my $self = shift; my $seconds = shift; if($seconds){ $self->{'dur'} = Net::ICal::Libical::icaldurationtype_from_int($seconds); $self->_update_value(); } return Net::ICal::Libical::icaldurationtype_as_int($self->{'dur'}); } =head2 add($duration) Return a new duration that is the sum of this and $duration. Does not modify this object. =cut sub add { my ($self, $duration) = @_; return new Duration($self->seconds() + $duration->seconds()); } =head2 subtract($duration) Return a new duration that is the difference between this and $duration. Does not modify this object. =cut sub subtract { my ($self, $duration) = @_; return new Duration($self->seconds() - $duration->seconds()); } 1; libical-3.0.1/src/Net-ICal-Libical/lib/Net/ICal/Libical/Period.pm000066400000000000000000000206131320431302500240100ustar00rootroot00000000000000#!/usr/bin/perl -w #====================================================================== # FILE: Component.pm # CREATOR: eric # # (C) COPYRIGHT 2000, Eric Busboom # http://www.softwarestudio.org # # This library is free software; you can redistribute it and/or modify # it under the terms of either: # # The LGPL as published by the Free Software Foundation, version # 2.1, available at: http://www.gnu.org/licenses/lgpl-2.1.html # # Or: # # The Mozilla Public License Version 2.0. You may obtain a copy of # the License at http://www.mozilla.org/MPL/ #====================================================================== =pod =head1 NAME Net::ICal::Period -- represent a period of time =head1 SYNOPSIS use Net::ICal; $p = new Net::ICal::Period("19970101T120000","19970101T123000"); $p = new Net::ICal::Period("19970101T120000","PT3W2D40S"); $p = new Net::ICal::Period(time(),3600); $p = new Net::ICal::Period( new Net::ICal::Time("19970101T120000", "America/Los_Angeles"), new Net::ICal::Duration("2h")); =head1 DESCRIPTION Use this to make an object representing a block of time on a real schedule. You can either say, "This event starts at 12 and ends at 2" or "This event starts at 12 and lasts 2 hours." These two ways of specifying events can be treated differently in schedules. If you say, "The meeting is from 12 to 2, but I have to leave at 2," you are implying that the start date and end date are fixed. If you say, "I have a 2-hour drive to Chicago, and I need to leave at 4," you are saying that it will take 2 hours no matter when you leave, and that moving the start time will slide the end time correspondingly. =head1 BASIC METHODS =cut #========================================================================= package Net::ICal::Period; use strict; use Net::ICal::Time; use Net::ICal::Duration; use UNIVERSAL qw(isa); #------------------------------------------------------------------------- =pod =head2 new($time, $time|$duration) Creates a new period object given to parameters: The first must be a I