[Cmake-commits] CMake branch, next, updated. v2.8.6-2302-g182ad9d

Alexander Neundorf neundorf at kde.org
Tue Dec 20 16:34:07 EST 2011


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  182ad9d58ff40da770b9e1ce6ab633d26471bde2 (commit)
       via  43f83d2ee523a38648322f629559694c71d5bb52 (commit)
      from  ff560f201e709791b7078947013e3254fc88af13 (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=182ad9d58ff40da770b9e1ce6ab633d26471bde2
commit 182ad9d58ff40da770b9e1ce6ab633d26471bde2
Merge: ff560f2 43f83d2
Author:     Alexander Neundorf <neundorf at kde.org>
AuthorDate: Tue Dec 20 16:34:06 2011 -0500
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Tue Dec 20 16:34:06 2011 -0500

    Merge topic 'GNUInstallDirs-DebianMultiarch' into next
    
    43f83d2 GNUInstallDirs: add support for Debian multiarch


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=43f83d2ee523a38648322f629559694c71d5bb52
commit 43f83d2ee523a38648322f629559694c71d5bb52
Author:     Alex Neundorf <neundorf at kde.org>
AuthorDate: Wed Dec 14 19:24:28 2011 +0100
Commit:     Alex Neundorf <neundorf at kde.org>
CommitDate: Wed Dec 14 19:24:28 2011 +0100

    GNUInstallDirs: add support for Debian multiarch
    
    This patch makes CMAKE_INSTALL_LIBDIR default to the debian
    multiarch dir if present, e.g. lib/i386-linux-gnu/
    
    Alex

diff --git a/Modules/GNUInstallDirs.cmake b/Modules/GNUInstallDirs.cmake
index a114dcb..0302e4b 100644
--- a/Modules/GNUInstallDirs.cmake
+++ b/Modules/GNUInstallDirs.cmake
@@ -11,7 +11,7 @@
 #  SYSCONFDIR       - read-only single-machine data (etc)
 #  SHAREDSTATEDIR   - modifiable architecture-independent data (com)
 #  LOCALSTATEDIR    - modifiable single-machine data (var)
-#  LIBDIR           - object code libraries (lib or lib64)
+#  LIBDIR           - object code libraries (lib or lib64 or lib/<multiarch-tuple> on Debian)
 #  INCLUDEDIR       - C header files (include)
 #  OLDINCLUDEDIR    - C header files for non-gcc (/usr/include)
 #  DATAROOTDIR      - read-only architecture-independent data root (share)
@@ -75,18 +75,24 @@ if(NOT DEFINED CMAKE_INSTALL_LIBDIR)
   #  - we are NOT on debian
   #  - we are on a 64 bits system
   # reason is: amd64 ABI: http://www.x86-64.org/documentation/abi.pdf
-  # Note that the future of multi-arch handling may be even
-  # more complicated than that: http://wiki.debian.org/Multiarch
+  # For Debian with multiarch, use 'lib/${CMAKE_LIBRARY_ARCHITECTURE}' if
+  # CMAKE_LIBRARY_ARCHITECTURE is set (which contains e.g. "i386-linux-gnu"
+  # See http://wiki.debian.org/Multiarch
   if(CMAKE_SYSTEM_NAME MATCHES "Linux"
-      AND NOT CMAKE_CROSSCOMPILING
-      AND NOT EXISTS "/etc/debian_version")
-    if(NOT DEFINED CMAKE_SIZEOF_VOID_P)
-      message(AUTHOR_WARNING
-        "Unable to determine default CMAKE_INSTALL_LIBDIR directory because no target architecture is known. "
-        "Please enable at least one language before including GNUInstallDirs.")
-    else()
-      if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
-        set(_LIBDIR_DEFAULT "lib64")
+      AND NOT CMAKE_CROSSCOMPILING)
+    if (EXISTS "/etc/debian_version") # is this a debian system ?
+       if(CMAKE_LIBRARY_ARCHITECTURE)
+         set(_LIBDIR_DEFAULT "lib/${CMAKE_LIBRARY_ARCHITECTURE}")
+       endif()
+    else() # not debian, rely on CMAKE_SIZEOF_VOID_P:
+      if(NOT DEFINED CMAKE_SIZEOF_VOID_P)
+        message(AUTHOR_WARNING
+          "Unable to determine default CMAKE_INSTALL_LIBDIR directory because no target architecture is known. "
+          "Please enable at least one language before including GNUInstallDirs.")
+      else()
+        if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
+          set(_LIBDIR_DEFAULT "lib64")
+        endif()
       endif()
     endif()
   endif()

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

Summary of changes:
 Modules/GNUInstallDirs.cmake |   30 ++++++++++++++++++------------
 1 files changed, 18 insertions(+), 12 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list