[Cmake-commits] CMake branch, master, updated. v3.10.0-455-g868fdb4

2017-11-29 Thread Kitware Robot
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, master has been updated
   via  868fdb439a2b984de3247cda5616991f6bf7c839 (commit)
  from  b311b8751819ec881824c61ef8de03387ff40c3f (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 -
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=868fdb439a2b984de3247cda5616991f6bf7c839
commit 868fdb439a2b984de3247cda5616991f6bf7c839
Author: Kitware Robot <kwro...@kitware.com>
AuthorDate: Thu Nov 30 00:01:14 2017 -0500
Commit: Kitware Robot <kwro...@kitware.com>
CommitDate: Thu Nov 30 00:01:14 2017 -0500

CMake Nightly Date Stamp

diff --git a/Source/CMakeVersion.cmake b/Source/CMakeVersion.cmake
index eca7be2..afba743 100644
--- a/Source/CMakeVersion.cmake
+++ b/Source/CMakeVersion.cmake
@@ -1,5 +1,5 @@
 # CMake version number components.
 set(CMake_VERSION_MAJOR 3)
 set(CMake_VERSION_MINOR 10)
-set(CMake_VERSION_PATCH 20171129)
+set(CMake_VERSION_PATCH 20171130)
 #set(CMake_VERSION_RC 1)

---

Summary of changes:
 Source/CMakeVersion.cmake |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


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


Re: [CMake] Using find_package() portably?

2017-11-29 Thread Florent Castelli

On 29/11/2017 12:02, Johannes Zarl-Zierl wrote:

Hello Carsten,

On Samstag, 25. November 2017 11:46:44 CET Carsten Fuchs wrote:

Thanks for your reply, but how can I proceed from here?

In order to be able to write in the parent script something that works
in either case, that is,

target_link_libraries(main_program )

Well, that's one way, but that doesn't really provide any benefit above the
original solution (i.e. just define the JPEG_INCLUDES and JPEG_LIBRARIES
variables accordingly).


it seems that I either

- have to make a copy of FindJPEG.cmake, customize it to define
target JPEG::JEPG and ship it along with my project,

Either that or you define it yourself:
find_package(JPEG)
if (JPEG_FOUND)


I'd say "if(JPEG_FOUND AND NOT TARGET JPEG::JPEG)"
If someone improves FindJPEG.cmake, you won't break your build.


  add_library(JPEG::JPEG UNKNOWN IMPORTED)
  set_property(
   TARGET JPEG::JPEG
   PROPERTY IMPORTED_LOCATION ${JPEG_LIBRARIES}
   )
  set_property(
   TARGET JPEG::JPEG PROPERTY
   INTERFACE_INCLUDE_DIRECTORIES ${JPEG_INCLUDES}
  )
endif()

I admit it's not a huge benefit over just using the variables. The advantages:
- you get slightly better error handling
- your target_link_libraries commands are slightly more readable.


- or write my `../ExtLibs/libjpeg/CMakeLists.txt` so that it globally
defines JPEG_LIBRARIES and JPEG_INCLUDE_DIRS

That will work, too.


Cheers,
   Johannes



--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


[Cmake-commits] CMake branch, master, updated. v3.10.0-454-gb311b87

2017-11-29 Thread Kitware Robot
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, master has been updated
   via  b311b8751819ec881824c61ef8de03387ff40c3f (commit)
   via  fbe91dba6a615d799f3ece996ddccdabb819c4dc (commit)
  from  5def40891fc1ad0a7d7ba7a16bd11b2d26fa66ab (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 -
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=b311b8751819ec881824c61ef8de03387ff40c3f
commit b311b8751819ec881824c61ef8de03387ff40c3f
Merge: 5def408 fbe91db
Author: Craig Scott 
AuthorDate: Wed Nov 29 20:09:30 2017 +
Commit: Kitware Robot 
CommitDate: Wed Nov 29 15:09:58 2017 -0500

Merge topic 'check_fixtures_before_exe_existence'

fbe91dba CTest: Check failed fixture dependencies before test command and 
args

Acked-by: Kitware Robot 
Acked-by: Brad King 
Merge-request: !1526


https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=fbe91dba6a615d799f3ece996ddccdabb819c4dc
commit fbe91dba6a615d799f3ece996ddccdabb819c4dc
Author: Craig Scott 
AuthorDate: Mon Nov 27 22:06:14 2017 +1100
Commit: Craig Scott 
CommitDate: Wed Nov 29 07:27:20 2017 +1100

CTest: Check failed fixture dependencies before test command and args

diff --git a/Source/CTest/cmCTestRunTest.cxx b/Source/CTest/cmCTestRunTest.cxx
index 99531af..5443494 100644
--- a/Source/CTest/cmCTestRunTest.cxx
+++ b/Source/CTest/cmCTestRunTest.cxx
@@ -432,8 +432,6 @@ bool cmCTestRunTest::StartTest(size_t total)
 return false;
   }
 
-  this->ComputeArguments();
-  std::vector& args = this->TestProperties->Args;
   this->TestResult.Properties = this->TestProperties;
   this->TestResult.ExecutionTime = 0;
   this->TestResult.CompressOutput = false;
@@ -444,6 +442,10 @@ bool cmCTestRunTest::StartTest(size_t total)
   this->TestResult.Name = this->TestProperties->Name;
   this->TestResult.Path = this->TestProperties->Directory;
 
+  // Check for failed fixture dependencies before we even look at the command
+  // arguments because if we are not going to run the test, the command and
+  // its arguments are irrelevant. This matters for the case where a fixture
+  // dependency might be creating the executable we want to run.
   if (!this->FailedDependencies.empty()) {
 this->TestProcess = new cmProcess;
 std::string msg = "Failed test dependencies:";
@@ -459,6 +461,8 @@ bool cmCTestRunTest::StartTest(size_t total)
 return false;
   }
 
+  this->ComputeArguments();
+  std::vector& args = this->TestProperties->Args;
   if (args.size() >= 2 && args[1] == "NOT_AVAILABLE") {
 this->TestProcess = new cmProcess;
 std::string msg;
diff --git a/Tests/RunCMake/ctest_fixtures/CMakeLists.txt.in 
b/Tests/RunCMake/ctest_fixtures/CMakeLists.txt.in
index 5cb0b4e..6b11cff 100644
--- a/Tests/RunCMake/ctest_fixtures/CMakeLists.txt.in
+++ b/Tests/RunCMake/ctest_fixtures/CMakeLists.txt.in
@@ -27,7 +27,11 @@ passTest(two)   # 6
 passTest(cleanupBar)# 7
 passTest(three) # 8
 failTest(setupFails)# 9
-passTest(wontRun)   # 10
+
+# Special case, test executable always missing to verify fixture dependencies
+# are checked before existence of test executable to be run
+add_test(NAME wontRun COMMAND iDoNotExist)  # 10
+
 passTest(cyclicSetup)   # 11
 passTest(cyclicCleanup) # 12
 passTest(cleanupUnused) # 13

---

Summary of changes:
 Source/CTest/cmCTestRunTest.cxx |8 ++--
 Tests/RunCMake/ctest_fixtures/CMakeLists.txt.in |6 +-
 2 files changed, 11 insertions(+), 3 deletions(-)


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


[CMake] CTEST_CUSTOM_MAXIMUM_FAILED_TEST_OUTPUT_SIZE

2017-11-29 Thread Thompson, KT
Hi,

I'm trying to limit the amount of data that is uploaded to my CDash server by 
setting

set( CTEST_CUSTOM_MAXIMUM_NUMBER_OF_WARNINGS "30" )
set( CTEST_CUSTOM_MAXIMUM_PASSED_TEST_OUTPUT_SIZE "1024" ) # bytes (1 kB)
set( CTEST_CUSTOM_MAXIMUM_FAILED_TEST_OUTPUT_SIZE "1024" ) # bytes (1 kB)

in my projects's CTestCustom.cmake (this file exists in my project source 
directory and is copied to the top level build tree).  But this seems to have 
no effect.  The documentation for these variables is very sparse so I would 
appreciate any links to discussions or examples about how to use these 
variables.

Thank you!

-kt


-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] CPack: Create debian packge for each sub-project

2017-11-29 Thread DKLind
I have finally found time to work on a patch so
CPACK_DEBAIN__PACKAGE_VERSION is recognized. I am amazed how
simple the fix actually is.

I plan on submitting a formal patch soon for Debian and RPM. I don't know
anything about other CMake packaging features that might benefit from this
patch.



--
Sent from: http://cmake.3232098.n2.nabble.com/
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


[Cmake-commits] CMake branch, release, updated. v3.10.0-6-g79ad921

2017-11-29 Thread Kitware Robot
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, release has been updated
   via  79ad921a38190e38d10c89f9c7dad1fc78b52986 (commit)
   via  f969f1a9ce1d0045b9d056fd08c4683c34c420fa (commit)
   via  93e7eb7bc5c26aa0bf74887a1c5ba36bfce74bea (commit)
   via  2f72573a62adcb4ef8805163f56bd0a1880fa279 (commit)
  from  c2019d7c0c9156ee78323ef0fc6bbeabe1c22192 (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 -
---

Summary of changes:
 Modules/CMakeDetermineCompilerId.cmake |6 +++---
 Modules/Platform/UnixPaths.cmake   |3 +++
 2 files changed, 6 insertions(+), 3 deletions(-)


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


[Cmake-commits] CMake branch, master, updated. v3.10.0-452-g5def408

2017-11-29 Thread Kitware Robot
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, master has been updated
   via  5def40891fc1ad0a7d7ba7a16bd11b2d26fa66ab (commit)
   via  79ad921a38190e38d10c89f9c7dad1fc78b52986 (commit)
   via  93e7eb7bc5c26aa0bf74887a1c5ba36bfce74bea (commit)
  from  c07b18d8835fbc4ddc0364f6f3531cc515f309fc (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 -
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=5def40891fc1ad0a7d7ba7a16bd11b2d26fa66ab
commit 5def40891fc1ad0a7d7ba7a16bd11b2d26fa66ab
Merge: c07b18d 79ad921
Author: Brad King 
AuthorDate: Wed Nov 29 08:40:00 2017 -0500
Commit: Brad King 
CommitDate: Wed Nov 29 08:40:00 2017 -0500

Merge branch 'release-3.10'


---

Summary of changes:


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


[Cmake-commits] CMake branch, master, updated. v3.10.0-449-gc07b18d

2017-11-29 Thread Kitware Robot
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, master has been updated
   via  c07b18d8835fbc4ddc0364f6f3531cc515f309fc (commit)
   via  71c28bddba25847f65cfebefe884d8e88eedc1af (commit)
   via  d5cad740789bdb2933b5d189f5cd5b7aada9700b (commit)
   via  caffddd620393fd9c73c1ce97d0451ce5570dedf (commit)
   via  4ff89fb6084d84aabe2e64aeccad03794af65a8a (commit)
   via  6e613ff399166c59e881331027e65c601feab807 (commit)
   via  f969f1a9ce1d0045b9d056fd08c4683c34c420fa (commit)
   via  e04f1d1b47f395cd702574041aa17e52e71499d8 (commit)
   via  b31d5e1dfdea5abcf95de05baf7b0e53cc18937a (commit)
   via  1f1c2a9fdf84e1fb6f3399f7f30ad8b7c8d8669d (commit)
   via  c860999213fcf6114084688cad7b8e70264401cc (commit)
   via  ea1bb90270357ecd033c11c941b83e76e6d1525b (commit)
   via  7669695a74959dbad7c801facea4c7428875ffc3 (commit)
  from  9e961930ee1ab526467651935bf7c285c170432d (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 -
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=c07b18d8835fbc4ddc0364f6f3531cc515f309fc
commit c07b18d8835fbc4ddc0364f6f3531cc515f309fc
Merge: 71c28bd e04f1d1
Author: Brad King 
AuthorDate: Wed Nov 29 13:25:44 2017 +
Commit: Kitware Robot 
CommitDate: Wed Nov 29 08:32:26 2017 -0500

Merge topic 'CodeBlocks-custom-compiler-id'

e04f1d1b CodeBlocks: add option for the CB compiler ID

Acked-by: Kitware Robot 
Merge-request: !1512


https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=71c28bddba25847f65cfebefe884d8e88eedc1af
commit 71c28bddba25847f65cfebefe884d8e88eedc1af
Merge: d5cad74 4ff89fb
Author: Brad King 
AuthorDate: Wed Nov 29 13:27:40 2017 +
Commit: Kitware Robot 
CommitDate: Wed Nov 29 08:32:00 2017 -0500

Merge topic 'aix-threads'

4ff89fb6 AIX: Add -pthread flag to enable std::thread with GCC
6e613ff3 bootstrap: Add infrastructure to detect threading flags

Acked-by: Kitware Robot 
Merge-request: !1535


https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=d5cad740789bdb2933b5d189f5cd5b7aada9700b
commit d5cad740789bdb2933b5d189f5cd5b7aada9700b
Merge: caffddd f969f1a
Author: Brad King 
AuthorDate: Wed Nov 29 13:27:15 2017 +
Commit: Kitware Robot 
CommitDate: Wed Nov 29 08:29:36 2017 -0500

Merge topic 'clang-cl-fix'

f969f1a9 Clang: Do not mistake clang-cl 6.0 for GNU-like clang

Acked-by: Kitware Robot 
Merge-request: !1522


https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=caffddd620393fd9c73c1ce97d0451ce5570dedf
commit caffddd620393fd9c73c1ce97d0451ce5570dedf
Merge: 9e96193 b31d5e1
Author: Brad King 
AuthorDate: Wed Nov 29 13:24:40 2017 +
Commit: Kitware Robot 
CommitDate: Wed Nov 29 08:26:05 2017 -0500

Merge topic 'CheckIncludeFiles-language-CXX'

b31d5e1d CheckIncludeFiles: improve warning for missing argument
1f1c2a9f CheckIncludeFiles: clean up documentation of new features
c8609992 Help: Add notes for topic 'CheckIncludeFiles-language-CXX'
ea1bb902 CheckIncludeFiles: add unit tests
7669695a CheckIncludeFiles: extend to allow a LANGUAGE argument

Acked-by: Kitware Robot 
Merge-request: !1464


https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=4ff89fb6084d84aabe2e64aeccad03794af65a8a
commit 4ff89fb6084d84aabe2e64aeccad03794af65a8a
Author: Brad King 
AuthorDate: Tue Nov 28 11:24:26 2017 -0500
Commit: Brad King 
CommitDate: Tue Nov 28 11:24:26 2017 -0500

AIX: Add -pthread flag to enable std::thread with GCC

diff --git a/CMakeLists.txt b/CMakeLists.txt
index fafe536..ebeca22 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -2,7 +2,11 @@
 # file Copyright.txt or https://cmake.org/licensing for details.
 
 cmake_minimum_required(VERSION 3.1 FATAL_ERROR)
+set(CMAKE_USER_MAKE_RULES_OVERRIDE_C 
${CMAKE_CURRENT_SOURCE_DIR}/Source/Modules/OverrideC.cmake)
+set(CMAKE_USER_MAKE_RULES_OVERRIDE_CXX 
${CMAKE_CURRENT_SOURCE_DIR}/Source/Modules/OverrideCXX.cmake)
 project(CMake)
+unset(CMAKE_USER_MAKE_RULES_OVERRIDE_CXX)
+unset(CMAKE_USER_MAKE_RULES_OVERRIDE_C)
 
 # Make sure we can find internal find_package modules only used for
 # building CMake and not for shipping externally
diff --git a/Source/Modules/OverrideC.cmake b/Source/Modules/OverrideC.cmake
new file mode 100644
index 000..f8299ad
--- /dev/null
+++ 

[Cmake-commits] CMake branch, master, updated. v3.10.0-436-g9e96193

2017-11-29 Thread Kitware Robot
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, master has been updated
   via  9e961930ee1ab526467651935bf7c285c170432d (commit)
   via  04f869bb4645aae8171f70746898ca20d3c05be1 (commit)
   via  89a628e28f68daf124129aa1810ba50a420a64c2 (commit)
   via  d4805dd47bc6ea586e16ac5eb9f5bd07f2ff6901 (commit)
   via  cd5002579d64898e6392934e2acb33b199765846 (commit)
   via  458c589fe33fb5e827e9dbcd7799a0cac2559dba (commit)
   via  00e39a4afcb65b3c78acc81e6080c204be84f16f (commit)
   via  2f72573a62adcb4ef8805163f56bd0a1880fa279 (commit)
   via  24e2bc42191b6001b8683d929dd097f68332698f (commit)
   via  72d3161a7f5d350d848d5b44cf343bac19e22238 (commit)
   via  f19c70c3d29f277f82f18820d36ca17e9ba398ae (commit)
  from  a4ddc7357ae880b3695dccec44e383cfa77c7572 (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 -
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=9e961930ee1ab526467651935bf7c285c170432d
commit 9e961930ee1ab526467651935bf7c285c170432d
Merge: 04f869b 458c589
Author: Brad King 
AuthorDate: Wed Nov 29 13:23:01 2017 +
Commit: Kitware Robot 
CommitDate: Wed Nov 29 08:23:11 2017 -0500

Merge topic 'win-clang-debug'

458c589f FindBoost: Add Windows ABI tag for Clang debug
00e39a4a FindBoost: Use CMAKE_CXX_COMPILER_ID for Intel compiler

Acked-by: Kitware Robot 
Merge-request: !1529


https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=04f869bb4645aae8171f70746898ca20d3c05be1
commit 04f869bb4645aae8171f70746898ca20d3c05be1
Merge: 89a628e 72d3161
Author: Brad King 
AuthorDate: Wed Nov 29 13:22:10 2017 +
Commit: Kitware Robot 
CommitDate: Wed Nov 29 08:22:15 2017 -0500

Merge topic 'cppcheck_testdriver'

72d3161a TestDriver: fix style-'variableScope' cppcheck warning

Acked-by: Kitware Robot 
Merge-request: !1518


https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=89a628e28f68daf124129aa1810ba50a420a64c2
commit 89a628e28f68daf124129aa1810ba50a420a64c2
Merge: d4805dd f19c70c
Author: Brad King 
AuthorDate: Wed Nov 29 13:21:39 2017 +
Commit: Kitware Robot 
CommitDate: Wed Nov 29 08:21:44 2017 -0500

Merge topic 'fortran-compiler-launcher'

f19c70c3 Fortran: Add option to run the compiler through launcher tools

Acked-by: Kitware Robot 
Merge-request: !1517


https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=d4805dd47bc6ea586e16ac5eb9f5bd07f2ff6901
commit d4805dd47bc6ea586e16ac5eb9f5bd07f2ff6901
Merge: cd50025 2f72573
Author: Brad King 
AuthorDate: Wed Nov 29 13:20:43 2017 +
Commit: Kitware Robot 
CommitDate: Wed Nov 29 08:20:45 2017 -0500

Merge topic 'cuda-implicit-include-dirs'

2f72573a CUDA: Treat /usr/include as an implicit include directory

Acked-by: Kitware Robot 
Merge-request: !1528


https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=cd5002579d64898e6392934e2acb33b199765846
commit cd5002579d64898e6392934e2acb33b199765846
Merge: a4ddc73 24e2bc4
Author: Brad King 
AuthorDate: Wed Nov 29 13:19:18 2017 +
Commit: Kitware Robot 
CommitDate: Wed Nov 29 08:19:28 2017 -0500

Merge topic 'GNUInstallDirs-update-link'

24e2bc42 GNUInstallDirs: Update link to 64-bit ABI documents

Acked-by: Kitware Robot 
Merge-request: !1527


https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=458c589fe33fb5e827e9dbcd7799a0cac2559dba
commit 458c589fe33fb5e827e9dbcd7799a0cac2559dba
Author: Roger Leigh 
AuthorDate: Mon Nov 27 15:52:45 2017 +
Commit: Brad King 
CommitDate: Mon Nov 27 13:49:01 2017 -0500

FindBoost: Add Windows ABI tag for Clang debug

Thanks to Walter Pearce for this suggestion.

Fixes: #17505

diff --git a/Modules/FindBoost.cmake b/Modules/FindBoost.cmake
index b1805ce..0786248 100644
--- a/Modules/FindBoost.cmake
+++ b/Modules/FindBoost.cmake
@@ -1393,6 +1393,7 @@ endif()
 #   support libraries
 if(WIN32 AND Boost_USE_DEBUG_RUNTIME)
   if("x${CMAKE_CXX_COMPILER_ID}" STREQUAL "xMSVC"
+  OR "x${CMAKE_CXX_COMPILER_ID}" STREQUAL "xClang"
   OR "x${CMAKE_CXX_COMPILER_ID}" STREQUAL "xIntel")
 string(APPEND _boost_DEBUG_ABI_TAG "g")
   endif()

https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=00e39a4afcb65b3c78acc81e6080c204be84f16f
commit 

Re: [CMake] Using find_package() portably?

2017-11-29 Thread Johannes Zarl-Zierl
Hello Carsten,

On Samstag, 25. November 2017 11:46:44 CET Carsten Fuchs wrote:
> Thanks for your reply, but how can I proceed from here?
> 
> In order to be able to write in the parent script something that works
> in either case, that is,
> 
> target_link_libraries(main_program )

Well, that's one way, but that doesn't really provide any benefit above the 
original solution (i.e. just define the JPEG_INCLUDES and JPEG_LIBRARIES 
variables accordingly).

> it seems that I either
> 
>- have to make a copy of FindJPEG.cmake, customize it to define
> target JPEG::JEPG and ship it along with my project,

Either that or you define it yourself:
find_package(JPEG)
if (JPEG_FOUND)
 add_library(JPEG::JPEG UNKNOWN IMPORTED)
 set_property(
  TARGET JPEG::JPEG
  PROPERTY IMPORTED_LOCATION ${JPEG_LIBRARIES}
  )
 set_property(
  TARGET JPEG::JPEG PROPERTY
  INTERFACE_INCLUDE_DIRECTORIES ${JPEG_INCLUDES}
 )
endif()

I admit it's not a huge benefit over just using the variables. The advantages:
- you get slightly better error handling
- your target_link_libraries commands are slightly more readable.

>- or write my `../ExtLibs/libjpeg/CMakeLists.txt` so that it globally
> defines JPEG_LIBRARIES and JPEG_INCLUDE_DIRS

That will work, too.


Cheers,
  Johannes

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake