[Cmake-commits] CMake branch, next, updated. v2.8.3-557-g78c1abd

Brad King brad.king at kitware.com
Mon Nov 8 11:23:17 EST 2010


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  78c1abde46641d7a02e19bd8b5f1e72f295dbf5d (commit)
       via  20ceccc4f28474c89af5797640852f966b731be4 (commit)
      from  9c6907c1d921cfd1f87cf0ece3fc85a901ef27d1 (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=78c1abde46641d7a02e19bd8b5f1e72f295dbf5d
commit 78c1abde46641d7a02e19bd8b5f1e72f295dbf5d
Merge: 9c6907c 20ceccc
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Mon Nov 8 11:23:15 2010 -0500
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Mon Nov 8 11:23:15 2010 -0500

    Merge topic 'FindPerlLibs-mac' into next
    
    20ceccc FindPerlLibs: Fix for Mac locally applied patches


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=20ceccc4f28474c89af5797640852f966b731be4
commit 20ceccc4f28474c89af5797640852f966b731be4
Author:     Dave Abrahams <dave at boostpro.com>
AuthorDate: Mon Nov 8 11:06:56 2010 -0500
Commit:     Brad King <brad.king at kitware.com>
CommitDate: Mon Nov 8 11:09:41 2010 -0500

    FindPerlLibs: Fix for Mac locally applied patches
    
    Previously FindPerlLibs did not work with the Mac stock Perl because it
    includes patches.  From "perl -V":
    
      Locally applied patches:
        /Library/Perl/Updates/<version> comes before system perl directories
        installprivlib and installarchlib points to the Updates directory
    
    Adjust paths accordingly.

diff --git a/Modules/FindPerlLibs.cmake b/Modules/FindPerlLibs.cmake
index 4cb0263..0d620e3 100644
--- a/Modules/FindPerlLibs.cmake
+++ b/Modules/FindPerlLibs.cmake
@@ -147,6 +147,32 @@ if (PERL_EXECUTABLE)
     string(REGEX REPLACE "install[a-z]+='([^']+)'.*" "\\1" PERL_VENDORLIB ${PERL_VENDORLIB_OUTPUT_VARIABLE})
   endif (NOT PERL_VENDORLIB_RESULT_VARIABLE)
 
+  macro(perl_adjust_darwin_lib_variable varname)
+    string( TOUPPER PERL_${varname} FINDPERL_VARNAME )
+    string( TOLOWER install${varname} PERL_VARNAME )
+
+    if (NOT PERL_MINUSV_OUTPUT_VARIABLE)
+      execute_process(
+        COMMAND
+        ${PERL_EXECUTABLE} -V
+        OUTPUT_VARIABLE
+        PERL_MINUSV_OUTPUT_VARIABLE
+        RESULT_VARIABLE
+        PERL_MINUSV_RESULT_VARIABLE
+        )
+    endif()
+
+    if (NOT PERL_MINUSV_RESULT_VARIABLE)
+      string(REGEX MATCH "(${PERL_VARNAME}.*points? to the Updates directory)"
+        PERL_NEEDS_ADJUSTMENT ${PERL_MINUSV_OUTPUT_VARIABLE})
+
+      if (PERL_NEEDS_ADJUSTMENT)
+        string(REGEX REPLACE "(.*)/Updates/" "/System/\\1/" ${FINDPERL_VARNAME} ${${FINDPERL_VARNAME}})
+      endif (PERL_NEEDS_ADJUSTMENT)
+
+    endif (NOT PERL_MINUSV_RESULT_VARIABLE)
+  endmacro()
+
   ### PERL_ARCHLIB
   execute_process(
     COMMAND
@@ -158,6 +184,7 @@ if (PERL_EXECUTABLE)
   )
   if (NOT PERL_ARCHLIB_RESULT_VARIABLE)
     string(REGEX REPLACE "install[a-z]+='([^']+)'.*" "\\1" PERL_ARCHLIB ${PERL_ARCHLIB_OUTPUT_VARIABLE})
+    perl_adjust_darwin_lib_variable( ARCHLIB )
   endif (NOT PERL_ARCHLIB_RESULT_VARIABLE)
 
   ### PERL_PRIVLIB
@@ -171,6 +198,7 @@ if (PERL_EXECUTABLE)
   )
   if (NOT PERL_PRIVLIB_RESULT_VARIABLE)
     string(REGEX REPLACE "install[a-z]+='([^']+)'.*" "\\1" PERL_PRIVLIB ${PERL_PRIVLIB_OUTPUT_VARIABLE})
+    perl_adjust_darwin_lib_variable( PRIVLIB )
   endif (NOT PERL_PRIVLIB_RESULT_VARIABLE)
 
 

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

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


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list