This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  894d5321585d323b1d9e964b51a5ac724290d903 (commit)
       via  84079c92ca5c401e35aefacbcca25e0ac3e644d6 (commit)
      from  8279bae5fdfde13c65d996bffd17aba2c200a11f (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=894d5321585d323b1d9e964b51a5ac724290d903
commit 894d5321585d323b1d9e964b51a5ac724290d903
Merge: 8279bae 84079c9
Author:     Philip Lowman <phi...@yhbt.com>
AuthorDate: Sun Dec 18 18:21:54 2011 -0500
Commit:     CMake Topic Stage <kwro...@kitware.com>
CommitDate: Sun Dec 18 18:21:54 2011 -0500

    Merge topic 'FindProtobuf_import_dirs' into next
    
    84079c9 FindProtobuf: Merge patch that allows extra import dirs


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=84079c92ca5c401e35aefacbcca25e0ac3e644d6
commit 84079c92ca5c401e35aefacbcca25e0ac3e644d6
Author:     Philip Lowman <phi...@yhbt.com>
AuthorDate: Sun Dec 18 18:02:48 2011 -0500
Commit:     Philip Lowman <phi...@yhbt.com>
CommitDate: Sun Dec 18 18:02:48 2011 -0500

    FindProtobuf: Merge patch that allows extra import dirs
    
    Added support for additional import paths during protoc invocation
    time to the PROTOBUF_GENERATE_CPP public macro via a new
    PROTOBUF_IMPORT_DIRS optional variable.
    
    Patch courtesy of Miroslav Kes <m...@ra.rockwell.com>

diff --git a/Modules/FindProtobuf.cmake b/Modules/FindProtobuf.cmake
index 5344304..ac6fd86 100644
--- a/Modules/FindProtobuf.cmake
+++ b/Modules/FindProtobuf.cmake
@@ -7,6 +7,9 @@
 #                              (vsprojects/Debug & vsprojects/Release) will be 
searched
 #                              for libraries and binaries.
 #
+#   PROTOBUF_IMPORT_DIRS     - List of additional directories to be searched 
for
+#                              imported .proto files. (New in CMake 2.8.7)
+#
 # Defines the following variables:
 #
 #   PROTOBUF_FOUND - Found the Google Protocol Buffers library (libprotobuf & 
header files)
@@ -91,6 +94,16 @@ function(PROTOBUF_GENERATE_CPP SRCS HDRS)
     set(_protobuf_include_path -I ${CMAKE_CURRENT_SOURCE_DIR})
   endif()
 
+  if(DEFINED PROTOBUF_IMPORT_DIRS)
+    foreach(DIR ${PROTOBUF_IMPORT_DIRS})
+      get_filename_component(ABS_PATH ${DIR} ABSOLUTE)
+      list(FIND _protobuf_include_path ${ABS_PATH} _contains_already)
+      if(${_contains_already} EQUAL -1)
+          list(APPEND _protobuf_include_path -I ${ABS_PATH})
+      endif()
+    endforeach()
+  endif()
+
   set(${SRCS})
   set(${HDRS})
   foreach(FIL ${ARGN})

-----------------------------------------------------------------------

Summary of changes:
 Modules/FindProtobuf.cmake |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)


hooks/post-receive
-- 
CMake
_______________________________________________
Cmake-commits mailing list
Cmake-commits@cmake.org
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-commits

Reply via email to