diff options
Diffstat (limited to 'iGetAndroid/app/cmake/Modules')
-rw-r--r-- | iGetAndroid/app/cmake/Modules/FindCCNX_Common.cmake | 39 | ||||
-rw-r--r-- | iGetAndroid/app/cmake/Modules/FindCCNX_Portal.cmake | 40 | ||||
-rw-r--r-- | iGetAndroid/app/cmake/Modules/FindCCNX_Transport_Rta.cmake | 50 | ||||
-rw-r--r-- | iGetAndroid/app/cmake/Modules/FindLibEvent.cmake | 47 | ||||
-rw-r--r-- | iGetAndroid/app/cmake/Modules/FindLibicnet.cmake | 39 | ||||
-rw-r--r-- | iGetAndroid/app/cmake/Modules/FindLibparc.cmake | 39 | ||||
-rw-r--r-- | iGetAndroid/app/cmake/Modules/FindLongBow.cmake | 44 | ||||
-rw-r--r-- | iGetAndroid/app/cmake/Modules/FindUncrustify.cmake | 8 | ||||
-rw-r--r-- | iGetAndroid/app/cmake/Modules/detectCacheSize.cmake | 21 | ||||
-rw-r--r-- | iGetAndroid/app/cmake/Modules/version.cmake | 15 |
10 files changed, 342 insertions, 0 deletions
diff --git a/iGetAndroid/app/cmake/Modules/FindCCNX_Common.cmake b/iGetAndroid/app/cmake/Modules/FindCCNX_Common.cmake new file mode 100644 index 00000000..2629c160 --- /dev/null +++ b/iGetAndroid/app/cmake/Modules/FindCCNX_Common.cmake @@ -0,0 +1,39 @@ +######################################## +# +# Find the Libparc libraries and includes +# This module sets: +# CCNX_COMMON_FOUND: True if Libparc was found +# CCNX_COMMON_LIBRARY: The Libparc library +# CCNX_COMMON_LIBRARIES: The Libparc library and dependencies +# CCNX_COMMON_INCLUDE_DIR: The Libparc include dir +# + +set(CCNX_COMMON_SEARCH_PATH_LIST + ${CCNX_COMMON_HOME} + $ENV{CCNX_COMMON_HOME} + $ENV{CCNX_HOME} + $ENV{PARC_HOME} + $ENV{FOUNDATION_HOME} + /usr/local/parc + /usr/local/ccnx + /usr/local/ccn + /usr/local + /opt + /usr + ) + +find_path(CCNX_COMMON_INCLUDE_DIR ccnx/common/libccnxCommon_About.h + HINTS ${CCNX_COMMON_SEARCH_PATH_LIST} + PATH_SUFFIXES include + DOC "Find the Libccnx-common includes" ) + +find_library(CCNX_COMMON_LIBRARY NAMES ccnx_common + HINTS ${CCNX_COMMON_SEARCH_PATH_LIST} + PATH_SUFFIXES lib + DOC "Find the Libccnx-common libraries" ) + +set(CCNX_COMMON_LIBRARIES ${CCNX_COMMON_LIBRARY}) +set(CCNX_COMMON_INCLUDE_DIRS ${CCNX_COMMON_INCLUDE_DIR}) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(CCNX_Common DEFAULT_MSG CCNX_COMMON_LIBRARY CCNX_COMMON_INCLUDE_DIR) diff --git a/iGetAndroid/app/cmake/Modules/FindCCNX_Portal.cmake b/iGetAndroid/app/cmake/Modules/FindCCNX_Portal.cmake new file mode 100644 index 00000000..68384bab --- /dev/null +++ b/iGetAndroid/app/cmake/Modules/FindCCNX_Portal.cmake @@ -0,0 +1,40 @@ +######################################## +# +# Find the Libccnx-transport libraries and includes +# This module sets: +# CCNX_PORTAL_FOUND: True if Libparc was found +# CCNX_PORTAL_LIBRARY: The Libparc library +# CCNX_PORTAL_LIBRARIES: The Libparc library and dependencies +# CCNX_PORTAL_INCLUDE_DIR: The Libparc include dir +# + +set(CCNX_PORTAL_SEARCH_PATH_LIST + ${CCNX_PORTAL_HOME} + $ENV{CCNX_PORTAL_HOME} + $ENV{CCNX_HOME} + $ENV{PARC_HOME} + $ENV{FOUNDATION_HOME} + /usr/local/parc + /usr/local/ccnx + /usr/local/ccn + /usr/local + /opt + /usr + ) + +find_path(CCNX_PORTAL_INCLUDE_DIR ccnx/api/ccnx_Portal/ccnxPortal_About.h + HINTS ${CCNX_PORTAL_SEARCH_PATH_LIST} + PATH_SUFFIXES include + DOC "Find the Libccnx-portal includes" ) + +find_library(CCNX_PORTAL_LIBRARY NAMES ccnx_api_portal + HINTS ${CCNX_PORTAL_SEARCH_PATH_LIST} + PATH_SUFFIXES lib + DOC "Find the Libccnx-portal libraries" ) + +set(CCNX_PORTAL_LIBRARIES ${CCNX_PORTAL_LIBRARY}) + +set(CCNX_PORTAL_INCLUDE_DIRS ${CCNX_PORTAL_INCLUDE_DIR}) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(CCNX_Portal DEFAULT_MSG CCNX_PORTAL_LIBRARY CCNX_PORTAL_INCLUDE_DIR) diff --git a/iGetAndroid/app/cmake/Modules/FindCCNX_Transport_Rta.cmake b/iGetAndroid/app/cmake/Modules/FindCCNX_Transport_Rta.cmake new file mode 100644 index 00000000..c43436d1 --- /dev/null +++ b/iGetAndroid/app/cmake/Modules/FindCCNX_Transport_Rta.cmake @@ -0,0 +1,50 @@ +######################################## +# +# Find the Libccnx-transport libraries and includes +# This module sets: +# CCNX_TRANSPORT_RTA_FOUND: True if Libparc was found +# CCNX_TRANSPORT_RTA_LIBRARY: The Libparc library +# CCNX_TRANSPORT_RTA_LIBRARIES: The Libparc library and dependencies +# CCNX_TRANSPORT_RTA_INCLUDE_DIR: The Libparc include dir +# + +set(CCNX_TRANSPORT_RTA_SEARCH_PATH_LIST + ${CCNX_TRANSPORT_RTA_HOME} + $ENV{CCNX_TRANSPORT_RTA_HOME} + $ENV{CCNX_HOME} + $ENV{PARC_HOME} + $ENV{FOUNDATION_HOME} + /usr/local/parc + /usr/local/ccnx + /usr/local/ccn + /usr/local + /opt + /usr + ) + +find_path(CCNX_TRANSPORT_RTA_INCLUDE_DIR ccnx/transport/librta_About.h + HINTS ${CCNX_TRANSPORT_RTA_SEARCH_PATH_LIST} + PATH_SUFFIXES include + DOC "Find the Libccnx-transport-rta includes" ) + +find_library(CCNX_TRANSPORT_RTA_LIBRARY NAMES ccnx_transport_rta + HINTS ${CCNX_TRANSPORT_RTA_SEARCH_PATH_LIST} + PATH_SUFFIXES lib + DOC "Find the Libccnx-transport-rta libraries" ) + +find_library(CCNX_API_NOTIFY_LIBRARY NAMES ccnx_api_notify + HINTS ${CCNX_TRANSPORT_RTA_SEARCH_PATH_LIST} + PATH_SUFFIXES lib + DOC "Find the Libccnx-transport-rta libraries" ) + +find_library(CCNX_API_CONTROL_LIBRARY NAMES ccnx_api_control + HINTS ${CCNX_TRANSPORT_RTA_SEARCH_PATH_LIST} + PATH_SUFFIXES lib + DOC "Find the Libccnx-transport-rta libraries" ) + +set(CCNX_TRANSPORT_RTA_LIBRARIES ${CCNX_TRANSPORT_RTA_LIBRARY} ${CCNX_API_CONTROL_LIBRARY} ${CCNX_API_NOTIFY_LIBRARY}) + +set(CCNX_TRANSPORT_RTA_INCLUDE_DIRS ${CCNX_TRANSPORT_RTA_INCLUDE_DIR}) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(CCNX_Transport_Api DEFAULT_MSG CCNX_TRANSPORT_RTA_LIBRARY CCNX_TRANSPORT_RTA_INCLUDE_DIR) diff --git a/iGetAndroid/app/cmake/Modules/FindLibEvent.cmake b/iGetAndroid/app/cmake/Modules/FindLibEvent.cmake new file mode 100644 index 00000000..2d1ca4fe --- /dev/null +++ b/iGetAndroid/app/cmake/Modules/FindLibEvent.cmake @@ -0,0 +1,47 @@ +######################################## +# +# Find the LibEvent libraries and includes +# This module sets: +# LIBEVENT_FOUND: True if LibEvent was found +# LIBEVENT_LIBRARY: The LibEvent library +# LIBEVENT_LIBRARIES: The LibEvent library and dependencies +# LIBEVENT_INCLUDE_DIR: The LibEvent include dir +# +# This module will look for the libraries in various locations +# See the LIBEVENT_SEARCH_PATH_LIST for a full list. +# +# The caller can hint at locations using the following variables: +# +# LIBEVENT_HOME (passed as -D to cmake) +# CCNX_DEPENDENCIES (in environment) +# LIBEVENT_HOME (in environment) +# CCNX_HOME (in environment) +# + +set(LIBEVENT_SEARCH_PATH_LIST + ${LIBEVENT_HOME} + $ENV{CCNX_DEPENDENCIES} + $ENV{LIBEVENT_HOME} + $ENV{CCNX_HOME} + /usr/local/ccnx + /usr/local/ccn + /usr/local + /opt + /usr + ) + +find_path(LIBEVENT_INCLUDE_DIR event2/event.h + HINTS ${LIBEVENT_SEARCH_PATH_LIST} + PATH_SUFFIXES include + DOC "Find the LibEvent includes" ) + +find_library(LIBEVENT_LIBRARY NAMES event + HINTS ${LIBEVENT_SEARCH_PATH_LIST} + PATH_SUFFIXES lib + DOC "Find the LibEvent libraries" ) + +set(LIBEVENT_LIBRARIES ${LIBEVENT_LIBRARY}) +set(LIBEVENT_INCLUDE_DIRS ${LIBEVENT_INCLUDE_DIR}) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(LibEvent DEFAULT_MSG LIBEVENT_LIBRARY LIBEVENT_INCLUDE_DIR) diff --git a/iGetAndroid/app/cmake/Modules/FindLibicnet.cmake b/iGetAndroid/app/cmake/Modules/FindLibicnet.cmake new file mode 100644 index 00000000..4472060b --- /dev/null +++ b/iGetAndroid/app/cmake/Modules/FindLibicnet.cmake @@ -0,0 +1,39 @@ +######################################## +# +# Find the Libparc libraries and includes +# This module sets: +# LIBICNET_FOUND: True if Libconsumer-producer was found +# LIBICNETR_LIBRARY: The Libconsumer-producer library +# LIBICNET_LIBRARIES: The Libconsumer-producer library and dependencies +# LIBICNET_INCLUDE_DIR: The Libconsumer-producer include dir +# + +set(LIBICNET_SEARCH_PATH_LIST + ${LIBICNET_HOME} + $ENV{LIBICNETHOME} + $ENV{CCNX_HOME} + $ENV{PARC_HOME} + $ENV{FOUNDATION_HOME} + /usr/local/parc + /usr/local/ccnx + /usr/local/ccn + /usr/local + /opt + /usr + ) + +find_path(LIBICNET_INCLUDE_DIR icnet/icnet_transport_common.h + HINTS ${LIBICNET_SEARCH_PATH_LIST} + PATH_SUFFIXES include + DOC "Find the libicnet includes") + +find_library(LIBICNET_LIBRARY NAMES icnet + HINTS ${LIBICNET_SEARCH_PATH_LIST} + PATH_SUFFIXES lib + DOC "Find the libicnet libraries") +message("---->${LIBICNET_LIBRARY} ${LIBICNET_INCLUDE_DIR}") +set(LIBICNET_LIBRARIES ${LIBICNET_LIBRARY}) +set(LIBICNET_INCLUDE_DIRS ${LIBICNET_INCLUDE_DIR}) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(Libicnet DEFAULT_MSG LIBICNET_LIBRARY LIBICNET_INCLUDE_DIR)
\ No newline at end of file diff --git a/iGetAndroid/app/cmake/Modules/FindLibparc.cmake b/iGetAndroid/app/cmake/Modules/FindLibparc.cmake new file mode 100644 index 00000000..02835161 --- /dev/null +++ b/iGetAndroid/app/cmake/Modules/FindLibparc.cmake @@ -0,0 +1,39 @@ +######################################## +# +# Find the Libparc libraries and includes +# This module sets: +# LIBPARC_FOUND: True if Libparc was found +# LIBPARC_LIBRARY: The Libparc library +# LIBPARC_LIBRARIES: The Libparc library and dependencies +# LIBPARC_INCLUDE_DIR: The Libparc include dir +# + +set(LIBPARC_SEARCH_PATH_LIST + ${LIBPARC_HOME} + $ENV{LIBPARC_HOME} + $ENV{CCNX_HOME} + $ENV{PARC_HOME} + $ENV{FOUNDATION_HOME} + /usr/local/parc + /usr/local/ccnx + /usr/local/ccn + /usr/local + /opt + /usr + ) + +find_path(LIBPARC_INCLUDE_DIR parc/libparc_About.h + HINTS ${LIBPARC_SEARCH_PATH_LIST} + PATH_SUFFIXES include + DOC "Find the Libparc includes" ) + +find_library(LIBPARC_LIBRARY NAMES parc + HINTS ${LIBPARC_SEARCH_PATH_LIST} + PATH_SUFFIXES lib + DOC "Find the Libparc libraries" ) + +set(LIBPARC_LIBRARIES ${LIBPARC_LIBRARY}) +set(LIBPARC_INCLUDE_DIRS ${LIBPARC_INCLUDE_DIR}) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(Libparc DEFAULT_MSG LIBPARC_LIBRARY LIBPARC_INCLUDE_DIR) diff --git a/iGetAndroid/app/cmake/Modules/FindLongBow.cmake b/iGetAndroid/app/cmake/Modules/FindLongBow.cmake new file mode 100644 index 00000000..e35888eb --- /dev/null +++ b/iGetAndroid/app/cmake/Modules/FindLongBow.cmake @@ -0,0 +1,44 @@ +######################################## +# +# Find the LongBow libraries and includes +# This module sets: +# LONGBOW_FOUND: True if LongBow was found +# LONGBOW_LIBRARY: The LongBow library +# LONGBOW_LIBRARIES: The LongBow library and dependencies +# LONGBOW_INCLUDE_DIR: The LongBow include dir +# + +set(LONGBOW_SEARCH_PATH_LIST + ${LONGBOW_HOME} + $ENV{LONGBOW_HOME} + $ENV{CCNX_HOME} + $ENV{PARC_HOME} + $ENV{FOUNDATION_HOME} + /usr/local/parc + /usr/local/ccnx + /usr/local/ccn + /usr/local + /opt + /usr + ) + +find_path(LONGBOW_INCLUDE_DIR LongBow/longBow_About.h + HINTS ${LONGBOW_SEARCH_PATH_LIST} + PATH_SUFFIXES include + DOC "Find the LongBow includes" ) + +find_library(LONGBOW_LIBRARY NAMES longbow + HINTS ${LONGBOW_SEARCH_PATH_LIST} + PATH_SUFFIXES lib + DOC "Find the LongBow libraries" ) + +find_library(LONGBOW_REPORT_LIBRARY NAMES longbow-textplain longbow-ansiterm + HINTS ${LONGBOW_SEARCH_PATH_LIST} + PATH_SUFFIXES lib + DOC "Find the LongBow report libraries" ) + +set(LONGBOW_LIBRARIES ${LONGBOW_LIBRARY} ${LONGBOW_REPORT_LIBRARY}) +set(LONGBOW_INCLUDE_DIRS ${LONGBOW_INCLUDE_DIR}) + +include(FindPackageHandleStandardArgs) +find_package_handle_standard_args(LongBow DEFAULT_MSG LONGBOW_LIBRARY LONGBOW_INCLUDE_DIR) diff --git a/iGetAndroid/app/cmake/Modules/FindUncrustify.cmake b/iGetAndroid/app/cmake/Modules/FindUncrustify.cmake new file mode 100644 index 00000000..e53f65fe --- /dev/null +++ b/iGetAndroid/app/cmake/Modules/FindUncrustify.cmake @@ -0,0 +1,8 @@ +# Find uncrustify program +# +find_program( UNCRUSTIFY_BIN uncrustify + PATHS + $ENV{UNCRUSTIFY_HOME} + ) + +message( "-- UNCRUSTIFY found in ${UNCRUSTIFY_BIN}" ) diff --git a/iGetAndroid/app/cmake/Modules/detectCacheSize.cmake b/iGetAndroid/app/cmake/Modules/detectCacheSize.cmake new file mode 100644 index 00000000..469d2627 --- /dev/null +++ b/iGetAndroid/app/cmake/Modules/detectCacheSize.cmake @@ -0,0 +1,21 @@ +# Detect the cache size +# +# XXX: TODO: This is a bug when cross compiling. We are detecting the local +# Cache Line size and not the target cache line size. We should provide some +# way to define this + +set(LEVEL1_DCACHE_LINESIZE 32) + +if( APPLE ) + execute_process(COMMAND sysctl -n hw.cachelinesize + OUTPUT_VARIABLE LEVEL1_DCACHE_LINESIZE + OUTPUT_STRIP_TRAILING_WHITESPACE) +endif( APPLE ) + +if( ${CMAKE_SYSTEM_NAME} STREQUAL "Linux" ) + execute_process(COMMAND getconf LEVEL1_DCACHE_LINESIZE + OUTPUT_VARIABLE LEVEL1_DCACHE_LINESIZE + OUTPUT_STRIP_TRAILING_WHITESPACE) +endif() + +message("-- Cache line size: ${LEVEL1_DCACHE_LINESIZE}") diff --git a/iGetAndroid/app/cmake/Modules/version.cmake b/iGetAndroid/app/cmake/Modules/version.cmake new file mode 100644 index 00000000..74831674 --- /dev/null +++ b/iGetAndroid/app/cmake/Modules/version.cmake @@ -0,0 +1,15 @@ +# +# Get a version to pass on the command line +# +execute_process(COMMAND ${PROJECT_SOURCE_DIR}/cmake/get_version.sh ${PROJECT_SOURCE_DIR} + OUTPUT_VARIABLE RELEASE_VERSION + OUTPUT_STRIP_TRAILING_WHITESPACE) + +execute_process(COMMAND date -u +%Y-%m-%dT%H:%M:%SZ + OUTPUT_VARIABLE ISO_DATE + OUTPUT_STRIP_TRAILING_WHITESPACE) + +MESSAGE( STATUS "Configuring version ${RELEASE_VERSION}" ) + +add_definitions("-DRELEASE_VERSION=\"${RELEASE_VERSION}\"") + |