Author: pnoltes
Date: Tue Jul 10 19:02:29 2012
New Revision: 1359843
URL: http://svn.apache.org/viewvc?rev=1359843&view=rev
Log:
Added FindJansson and FindSlp cmake macros and udpated bundles using Jansson,
Slp and/or Curl.
Added:
incubator/celix/trunk/cmake/modules/FindJansson.cmake
incubator/celix/trunk/cmake/modules/FindSlp.cmake
Modified:
incubator/celix/trunk/deployment_admin/CMakeLists.txt
incubator/celix/trunk/remote_services/CMakeLists.txt
incubator/celix/trunk/remote_services/discovery/CMakeLists.txt
incubator/celix/trunk/remote_services/example_endpoint/CMakeLists.txt
incubator/celix/trunk/remote_services/example_proxy/CMakeLists.txt
incubator/celix/trunk/remote_services/remote_service_admin/CMakeLists.txt
incubator/celix/trunk/remote_services/remote_service_admin_http/CMakeLists.txt
incubator/celix/trunk/shell/CMakeLists.txt
Added: incubator/celix/trunk/cmake/modules/FindJansson.cmake
URL:
http://svn.apache.org/viewvc/incubator/celix/trunk/cmake/modules/FindJansson.cmake?rev=1359843&view=auto
==============================================================================
--- incubator/celix/trunk/cmake/modules/FindJansson.cmake (added)
+++ incubator/celix/trunk/cmake/modules/FindJansson.cmake Tue Jul 10 19:02:29
2012
@@ -0,0 +1,42 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.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.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+
+# - Try to find Jansson
+# Once done this will define
+# JANSSON_FOUND - System has Jansson
+# JANSSON_INCLUDE_DIRS - The Jansson include directories
+# JANSSON_LIBRARIES - The libraries needed to use Jansson
+# JANSSON_DEFINITIONS - Compiler switches required for using Jansson
+
+find_path(JANSSON_INCLUDE_DIR jansson.h
+ /usr/incluce
+ /usr/local/include )
+
+find_library(JANSSON_LIBRARY NAMES jansson
+ PATHS /usr/lib /usr/local/lib )
+
+set(JANSSON_LIBRARIES ${JANSSON_LIBRARY} )
+set(JANSSON_INCLUDE_DIRS ${JANSSON_INCLUDE_DIR} )
+
+include(FindPackageHandleStandardArgs)
+# handle the QUIETLY and REQUIRED arguments and set JANSSON_FOUND to TRUE
+# if all listed variables are TRUE
+find_package_handle_standard_args(Jansson DEFAULT_MSG
+ JANSSON_LIBRARY JANSSON_INCLUDE_DIR)
+
+mark_as_advanced(JANSSON_INCLUDE_DIR JANSSON_LIBRARY )
\ No newline at end of file
Added: incubator/celix/trunk/cmake/modules/FindSlp.cmake
URL:
http://svn.apache.org/viewvc/incubator/celix/trunk/cmake/modules/FindSlp.cmake?rev=1359843&view=auto
==============================================================================
--- incubator/celix/trunk/cmake/modules/FindSlp.cmake (added)
+++ incubator/celix/trunk/cmake/modules/FindSlp.cmake Tue Jul 10 19:02:29 2012
@@ -0,0 +1,42 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.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.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+
+# - Try to find Slp
+# Once done this will define
+# SLP_FOUND - System has Slp
+# SLP_INCLUDE_DIRS - The Slp include directories
+# SLP_LIBRARIES - The libraries needed to use Slp
+# SLP_DEFINITIONS - Compiler switches required for using Slp
+
+find_path(SLP_INCLUDE_DIR slp.h
+ /usr/incluce
+ /usr/local/include )
+
+find_library(SLP_LIBRARY NAMES slp
+ PATHS /usr/lib /usr/local/lib )
+
+set(SLP_LIBRARIES ${SLP_LIBRARY} )
+set(SLP_INCLUDE_DIRS ${SLP_INCLUDE_DIR} )
+
+include(FindPackageHandleStandardArgs)
+# handle the QUIETLY and REQUIRED arguments and set SLP_FOUND to TRUE
+# if all listed variables are TRUE
+find_package_handle_standard_args(Slp DEFAULT_MSG
+ SLP_LIBRARY SLP_INCLUDE_DIR)
+
+mark_as_advanced(SLP_INCLUDE_DIR SLP_LIBRARY )
\ No newline at end of file
Modified: incubator/celix/trunk/deployment_admin/CMakeLists.txt
URL:
http://svn.apache.org/viewvc/incubator/celix/trunk/deployment_admin/CMakeLists.txt?rev=1359843&r1=1359842&r2=1359843&view=diff
==============================================================================
--- incubator/celix/trunk/deployment_admin/CMakeLists.txt (original)
+++ incubator/celix/trunk/deployment_admin/CMakeLists.txt Tue Jul 10 19:02:29
2012
@@ -16,6 +16,9 @@
# under the License.
celix_subproject(DEPLOYMENT_ADMIN "Option to enable building the Deployment
Admin Service bundles" OFF DEPS framework launcher shell_tui log_writer)
if (DEPLOYMENT_ADMIN)
+
+ find_package(CURL REQUIRED)
+
add_definitions(-DUSE_FILE32API)
include_directories("/opt/local/include")
@@ -35,7 +38,7 @@ if (DEPLOYMENT_ADMIN)
private/src/log_store
private/src/log_sync
)
- target_link_libraries(deployment_admin framework curl)
+ target_link_libraries(deployment_admin framework ${CURL_LIBRARIES})
deploy("deployment-admin" BUNDLES deployment_admin shell shell_tui
log_service log_writer)
endif (DEPLOYMENT_ADMIN)
Modified: incubator/celix/trunk/remote_services/CMakeLists.txt
URL:
http://svn.apache.org/viewvc/incubator/celix/trunk/remote_services/CMakeLists.txt?rev=1359843&r1=1359842&r2=1359843&view=diff
==============================================================================
--- incubator/celix/trunk/remote_services/CMakeLists.txt (original)
+++ incubator/celix/trunk/remote_services/CMakeLists.txt Tue Jul 10 19:02:29
2012
@@ -27,6 +27,10 @@ if (REMOTE_SERVICE_ADMIN)
endif(CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64")
endif(CMAKE_UNAME)
endif(UNIX AND NOT WIN32)
+
+ find_package(Jansson REQUIRED)
+ find_package(CURL REQUIRED)
+ find_package(Slp REQUIRED)
add_subdirectory(utils)
Modified: incubator/celix/trunk/remote_services/discovery/CMakeLists.txt
URL:
http://svn.apache.org/viewvc/incubator/celix/trunk/remote_services/discovery/CMakeLists.txt?rev=1359843&r1=1359842&r2=1359843&view=diff
==============================================================================
--- incubator/celix/trunk/remote_services/discovery/CMakeLists.txt (original)
+++ incubator/celix/trunk/remote_services/discovery/CMakeLists.txt Tue Jul 10
19:02:29 2012
@@ -27,5 +27,5 @@ bundle(discovery SOURCES
private/src/discovery
private/src/discovery_activator
)
-target_link_libraries(discovery framework ${APRUTIL_LIBRARY} slp)
+target_link_libraries(discovery framework ${APRUTIL_LIBRARY} ${SLP_LIBRARIES})
Modified: incubator/celix/trunk/remote_services/example_endpoint/CMakeLists.txt
URL:
http://svn.apache.org/viewvc/incubator/celix/trunk/remote_services/example_endpoint/CMakeLists.txt?rev=1359843&r1=1359842&r2=1359843&view=diff
==============================================================================
--- incubator/celix/trunk/remote_services/example_endpoint/CMakeLists.txt
(original)
+++ incubator/celix/trunk/remote_services/example_endpoint/CMakeLists.txt Tue
Jul 10 19:02:29 2012
@@ -26,4 +26,4 @@ bundle(example_endpoint SOURCES
private/src/example_endpoint_activator
private/src/example_endpoint_impl.c
)
-target_link_libraries(example_endpoint framework jansson)
+target_link_libraries(example_endpoint framework ${JANSSON_LIBRARIES})
Modified: incubator/celix/trunk/remote_services/example_proxy/CMakeLists.txt
URL:
http://svn.apache.org/viewvc/incubator/celix/trunk/remote_services/example_proxy/CMakeLists.txt?rev=1359843&r1=1359842&r2=1359843&view=diff
==============================================================================
--- incubator/celix/trunk/remote_services/example_proxy/CMakeLists.txt
(original)
+++ incubator/celix/trunk/remote_services/example_proxy/CMakeLists.txt Tue Jul
10 19:02:29 2012
@@ -28,4 +28,4 @@ bundle(example_proxy SOURCES
private/src/example_proxy_activator
private/src/example_proxy_impl.c
)
-target_link_libraries(example_proxy framework jansson curl)
+target_link_libraries(example_proxy framework ${JANSSON_LIBRARIES}
${CURL_LIBRARIES})
Modified:
incubator/celix/trunk/remote_services/remote_service_admin/CMakeLists.txt
URL:
http://svn.apache.org/viewvc/incubator/celix/trunk/remote_services/remote_service_admin/CMakeLists.txt?rev=1359843&r1=1359842&r2=1359843&view=diff
==============================================================================
--- incubator/celix/trunk/remote_services/remote_service_admin/CMakeLists.txt
(original)
+++ incubator/celix/trunk/remote_services/remote_service_admin/CMakeLists.txt
Tue Jul 10 19:02:29 2012
@@ -30,4 +30,4 @@ bundle(remote_service_admin SOURCES
private/src/remote_service_admin_activator
private/src/mongoose.c
)
-target_link_libraries(remote_service_admin framework ${APRUTIL_LIBRARY}
jansson)
+target_link_libraries(remote_service_admin framework ${APRUTIL_LIBRARY}
${JANSSON_LIBRARIES})
Modified:
incubator/celix/trunk/remote_services/remote_service_admin_http/CMakeLists.txt
URL:
http://svn.apache.org/viewvc/incubator/celix/trunk/remote_services/remote_service_admin_http/CMakeLists.txt?rev=1359843&r1=1359842&r2=1359843&view=diff
==============================================================================
---
incubator/celix/trunk/remote_services/remote_service_admin_http/CMakeLists.txt
(original)
+++
incubator/celix/trunk/remote_services/remote_service_admin_http/CMakeLists.txt
Tue Jul 10 19:02:29 2012
@@ -30,4 +30,4 @@ bundle(remote_service_admin_http SOURCES
private/src/remote_service_admin_activator
private/src/mongoose.c
)
-target_link_libraries(remote_service_admin_http framework ${APRUTIL_LIBRARY}
jansson.a)
+target_link_libraries(remote_service_admin_http framework ${APRUTIL_LIBRARY}
${JANSSON_LIBRARIES})
Modified: incubator/celix/trunk/shell/CMakeLists.txt
URL:
http://svn.apache.org/viewvc/incubator/celix/trunk/shell/CMakeLists.txt?rev=1359843&r1=1359842&r2=1359843&view=diff
==============================================================================
--- incubator/celix/trunk/shell/CMakeLists.txt (original)
+++ incubator/celix/trunk/shell/CMakeLists.txt Tue Jul 10 19:02:29 2012
@@ -16,6 +16,8 @@
# under the License.
celix_subproject(SHELL "Option to enable building the Shell bundles" "OFF"
DEPS LAUNCHER LOG_SERVICE)
if (SHELL)
+ find_package(CURL REQUIRED)
+
bundle(shell SOURCES shell command
ps_command start_command stop_command
install_command update_command
@@ -23,7 +25,7 @@ if (SHELL)
inspect_command)
include_directories("${PROJECT_SOURCE_DIR}/utils/public/include")
include_directories("${PROJECT_SOURCE_DIR}/log_service/public/include")
- target_link_libraries(shell framework curl)
+ target_link_libraries(shell framework ${CURL_LIBRARIES})
package(shell FILES shell.h command.h)