Re: [cmake-developers] CMP0065 warning not supressed when --trace used

2016-07-14 Thread Alan W. Irwin

On 2016-07-14 13:49-0400 Brad King wrote:


On 07/14/2016 01:32 PM, Alan W. Irwin wrote:

I am addressing this mostly to you because you are the author of
CMP0065 which has the special property that by default it does not
warn when the policy is not set.  However, I find it does warn when
--trace is set which I am fairly sure is a (minor) bug.


This is documented behavior:

https://cmake.org/cmake/help/v3.6/variable/CMAKE_POLICY_WARNING_CMP.html
"running cmake(1) with the --debug-output, --trace, or --trace-expand option
 will also enable the warning."


I should have followed the obvious link in

to the above URL.  Sorry for that noise.


should change "thier" (in the third last line) to "their".


Recently fixed:

Fix typos.
https://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=56608618


Glad that Felix Geyer spotted this and fixed it last weekend.

Alan
__
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state
implementation for stellar interiors (freeeos.sf.net); the Time
Ephemerides project (timeephem.sf.net); PLplot scientific plotting
software package (plplot.sf.net); the libLASi project
(unifont.org/lasi); the Loads of Linux Links project (loll.sf.net);
and the Linux Brochure Project (lbproject.sf.net).
__

Linux-powered Science
__
--

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-developers


Re: [cmake-developers] CMP0065 warning not supressed when --trace used

2016-07-14 Thread Brad King
On 07/14/2016 01:49 PM, Brad King wrote:
> Add -DCMAKE_POLICY_WARNING_CMP0065=OLD to disable the warning.

Sorry, I meant `-DCMAKE_POLICY_DEFAULT_CMP0065=OLD`:

 https://cmake.org/cmake/help/v3.6/variable/CMAKE_POLICY_DEFAULT_CMP.html

-Brad

-- 

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-developers


[cmake-developers] CMP0065 warning not supressed when --trace used

2016-07-14 Thread Alan W. Irwin

Hi Chuck:

I am addressing this mostly to you because you are the author of
CMP0065 which has the special property that by default it does not
warn when the policy is not set.  However, I find it does warn when
--trace is set which I am fairly sure is a (minor) bug.

Please take a look at the attached CMakeLists.txt file
which is a self-contained simple test project that demonstrates
the described issue with CMP0065 and --trace.  For this project the policy is 
not
set because of

cmake_minimum_required(VERSION 3.3.2 FATAL_ERROR)

And indeed normal use of cmake (version 3.5.2) gives no warning for
CMP0065 as advertised by the CMP0065 documentation.

However, on my Linux platform (Debian Jessie with cmake-3.5.2 which I
built with the bootstrap method) if you use the cmake --trace option you do get 
the following
warning message (after a whole bunch of other messages from the
--trace option).

-- Configuring done
CMake Warning (dev) in CMakeLists.txt:
  Policy CMP0065 is not set: Do not add flags to export symbols from
  executables without the ENABLE_EXPORTS target property.  Run "cmake
  --help-policy CMP0065" for policy details.  Use the cmake_policy command to
  set the policy and suppress this warning.

  For compatibility with older versions of CMake, additional flags may be
  added to export symbols on all executables regardless of thier
  ENABLE_EXPORTS property.
This warning is for project developers.  Use -Wno-dev to suppress it.

First there is an extremely minor but still irritating message content
bug here where you should change "thier" (in the third last line) to
"their".

More seriously, I am pretty sure that the --trace option should not
change warnings policy this way, i.e., this is a bug in --trace or a
bug in the way that CMP0065 implements the supression of the warning
by default.  If you have any difficulty confirming this issue with the
attached CMakeLists.txt and CMake-3.5.2 (or presumably later) please
get back to me.

Alan
__
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state
implementation for stellar interiors (freeeos.sf.net); the Time
Ephemerides project (timeephem.sf.net); PLplot scientific plotting
software package (plplot.sf.net); the libLASi project
(unifont.org/lasi); the Loads of Linux Links project (loll.sf.net);
and the Linux Brochure Project (lbproject.sf.net).
__

Linux-powered Science
__cmake_minimum_required(VERSION 3.3.2 FATAL_ERROR)

project(test_CMP0065 C)

file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/hello.c
"#include 
void main(void)
{
printf(\"hello, world\\n\");
}
"
)

add_executable(hello ${CMAKE_CURRENT_BINARY_DIR}/hello.c)
-- 

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-developers