summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Modules/FindGTK2.cmake53
-rw-r--r--Modules/readme.txt3
-rw-r--r--Source/CMakeVersion.cmake2
-rw-r--r--Source/CTest/cmCTestSVN.h1
-rw-r--r--Source/CTest/cmCTestVC.h4
-rw-r--r--Source/cmNinjaTargetGenerator.cxx26
6 files changed, 71 insertions, 18 deletions
diff --git a/Modules/FindGTK2.cmake b/Modules/FindGTK2.cmake
index 49af0f2..517a9ac 100644
--- a/Modules/FindGTK2.cmake
+++ b/Modules/FindGTK2.cmake
@@ -54,7 +54,7 @@
#=============================================================================
# Copyright 2009 Kitware, Inc.
-# Copyright 2008-2009 Philip Lowman <philip@yhbt.com>
+# Copyright 2008-2012 Philip Lowman <philip@yhbt.com>
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
@@ -66,10 +66,13 @@
# (To distribute this file outside of CMake, substitute the full
# License text for the above reference.)
+# Version 1.4 (10/4/2012) (CMake 2.8.10)
+# * 12596: Missing paths for FindGTK2 on NetBSD
+# * 12049: Fixed detection of GTK include files in the lib folder on
+# multiarch systems.
# Version 1.3 (11/9/2010) (CMake 2.8.4)
# * 11429: Add support for detecting GTK2 built with Visual Studio 10.
# Thanks to Vincent Levesque for the patch.
-
# Version 1.2 (8/30/2010) (CMake 2.8.3)
# * Merge patch for detecting gdk-pixbuf library (split off
# from core GTK in 2.21). Thanks to Vincent Untz for the patch
@@ -151,7 +154,7 @@ function(_GTK2_FIND_INCLUDE_DIR _var _hdr)
"_GTK2_FIND_INCLUDE_DIR( ${_var} ${_hdr} )")
endif()
- set(_relatives
+ set(_gtk_packages
# If these ever change, things will break.
${GTK2_ADDITIONAL_SUFFIXES}
glibmm-2.4
@@ -172,8 +175,15 @@ function(_GTK2_FIND_INCLUDE_DIR _var _hdr)
sigc++-2.0
)
- set(_suffixes include lib)
- foreach(_d ${_relatives})
+ #
+ # NOTE: The following suffixes cause searching for header files in both of
+ # these directories:
+ # /usr/include/<pkg>
+ # /usr/lib/<pkg>/include
+ #
+
+ set(_suffixes)
+ foreach(_d ${_gtk_packages})
list(APPEND _suffixes ${_d})
list(APPEND _suffixes ${_d}/include) # for /usr/lib/gtk-2.0/include
endforeach()
@@ -183,18 +193,35 @@ function(_GTK2_FIND_INCLUDE_DIR _var _hdr)
"include suffixes = ${_suffixes}")
endif()
+ if(CMAKE_LIBRARY_ARCHITECTURE)
+ set(_gtk2_arch_dir /usr/lib/${CMAKE_LIBRARY_ARCHITECTURE})
+ if(GTK2_DEBUG)
+ message(STATUS "Adding ${_gtk2_arch_dir} to search path for multiarch support")
+ endif()
+ endif()
find_path(${_var} ${_hdr}
PATHS
+ ${_gtk2_arch_dir}
/usr/local/lib64
+ /usr/local/lib
/usr/lib64
- /opt/gnome
- /opt/openwin
- /usr/openwin
- /sw
- /opt/local
- ENV GTKMM_BASEPATH
- [HKEY_CURRENT_USER\\SOFTWARE\\gtkmm\\2.4;Path]
- [HKEY_LOCAL_MACHINE\\SOFTWARE\\gtkmm\\2.4;Path]
+ /usr/lib
+ /opt/gnome/include
+ /opt/gnome/lib
+ /opt/openwin/include
+ /usr/openwin/lib
+ /sw/include
+ /sw/lib
+ /opt/local/include
+ /opt/local/lib
+ /usr/pkg/lib
+ /usr/pkg/include/glib
+ $ENV{GTKMM_BASEPATH}/include
+ $ENV{GTKMM_BASEPATH}/lib
+ [HKEY_CURRENT_USER\\SOFTWARE\\gtkmm\\2.4;Path]/include
+ [HKEY_CURRENT_USER\\SOFTWARE\\gtkmm\\2.4;Path]/lib
+ [HKEY_LOCAL_MACHINE\\SOFTWARE\\gtkmm\\2.4;Path]/include
+ [HKEY_LOCAL_MACHINE\\SOFTWARE\\gtkmm\\2.4;Path]/lib
PATH_SUFFIXES
${_suffixes}
)
diff --git a/Modules/readme.txt b/Modules/readme.txt
index 4818031..9dc1c6a 100644
--- a/Modules/readme.txt
+++ b/Modules/readme.txt
@@ -127,6 +127,9 @@ If neither the QUIET nor REQUIRED options are given then the
FindXXX.cmake module should look for the package and complain without
error if the module is not found.
+FIND_PACKAGE() will set the variable CMAKE_FIND_PACKAGE_NAME to
+contain the actual name of the package.
+
A package can provide sub-components.
Those components can be listed after the COMPONENTS (or REQUIRED)
or OPTIONAL_COMPONENTS keywords. The set of all listed components will be
diff --git a/Source/CMakeVersion.cmake b/Source/CMakeVersion.cmake
index 84cc45b..cfbca69 100644
--- a/Source/CMakeVersion.cmake
+++ b/Source/CMakeVersion.cmake
@@ -2,5 +2,5 @@
set(CMake_VERSION_MAJOR 2)
set(CMake_VERSION_MINOR 8)
set(CMake_VERSION_PATCH 9)
-set(CMake_VERSION_TWEAK 20121002)
+set(CMake_VERSION_TWEAK 20121009)
#set(CMake_VERSION_RC 1)
diff --git a/Source/CTest/cmCTestSVN.h b/Source/CTest/cmCTestSVN.h
index 73d676e..c6548e3 100644
--- a/Source/CTest/cmCTestSVN.h
+++ b/Source/CTest/cmCTestSVN.h
@@ -63,6 +63,7 @@ private:
// Extended revision structure to include info about external it refers to.
struct Revision;
+ friend struct Revision;
// Info of all the repositories (root, externals and nested ones).
std::list<SVNInfo> Repositories;
diff --git a/Source/CTest/cmCTestVC.h b/Source/CTest/cmCTestVC.h
index 44e1dac..9dd0651 100644
--- a/Source/CTest/cmCTestVC.h
+++ b/Source/CTest/cmCTestVC.h
@@ -67,6 +67,9 @@ protected:
virtual void NoteNewRevision();
virtual bool WriteXMLUpdates(std::ostream& xml);
+#if defined(__SUNPRO_CC) && __SUNPRO_CC <= 0x510
+public: // Sun CC 5.1 needs help to allow cmCTestSVN::Revision to see this
+#endif
/** Basic information about one revision of a tree or file. */
struct Revision
{
@@ -80,6 +83,7 @@ protected:
std::string Log;
};
+protected:
struct File;
friend struct File;
diff --git a/Source/cmNinjaTargetGenerator.cxx b/Source/cmNinjaTargetGenerator.cxx
index 612e047..39f6aab 100644
--- a/Source/cmNinjaTargetGenerator.cxx
+++ b/Source/cmNinjaTargetGenerator.cxx
@@ -368,7 +368,7 @@ cmNinjaTargetGenerator
std::string flags = "$FLAGS";
vars.Defines = "$DEFINES";
vars.TargetPDB = "$TARGET_PDB";
-
+ vars.ObjectDir = "$OBJECT_DIR";
cmMakefile* mf = this->GetMakefile();
@@ -547,7 +547,7 @@ cmNinjaTargetGenerator
cmCustomCommand const* cc = (*si)->GetCustomCommand();
const std::vector<std::string>& ccoutputs = cc->GetOutputs();
std::transform(ccoutputs.begin(), ccoutputs.end(),
- std::back_inserter(orderOnlyDeps), MapToNinjaPath());
+ std::back_inserter(implicitDeps), MapToNinjaPath());
}
// If the source file is GENERATED and does not have a custom command
@@ -566,6 +566,13 @@ cmNinjaTargetGenerator
vars["DEP_FILE"] = objectFileName + ".d";;
EnsureParentDirectoryExists(objectFileName);
+ std::string objectDir = cmSystemTools::GetFilenamePath(objectFileName);
+ objectDir = this->GetLocalGenerator()->Convert(objectDir.c_str(),
+ cmLocalGenerator::START_OUTPUT,
+ cmLocalGenerator::SHELL);
+ vars["OBJECT_DIR"] = objectDir;
+
+
this->SetMsvcTargetPdbVariable(vars);
if(this->Makefile->IsOn("CMAKE_EXPORT_COMPILE_COMMANDS"))
@@ -590,6 +597,7 @@ cmNinjaTargetGenerator
compileObjectVars.Source = escapedSourceFileName.c_str();
compileObjectVars.Object = objectFileName.c_str();
+ compileObjectVars.ObjectDir = objectDir.c_str();
compileObjectVars.Flags = vars["FLAGS"].c_str();
compileObjectVars.Defines = vars["DEFINES"].c_str();
@@ -662,9 +670,19 @@ cmNinjaTargetGenerator
void
cmNinjaTargetGenerator
-::EnsureDirectoryExists(const std::string& dir) const
+::EnsureDirectoryExists(const std::string& path) const
{
- cmSystemTools::MakeDirectory(dir.c_str());
+ if (cmSystemTools::FileIsFullPath(path.c_str()))
+ {
+ cmSystemTools::MakeDirectory(path.c_str());
+ }
+ else
+ {
+ const std::string fullPath = std::string(this->GetGlobalGenerator()->
+ GetCMakeInstance()->GetHomeOutputDirectory())
+ + "/" + path;
+ cmSystemTools::MakeDirectory(fullPath.c_str());
+ }
}
void