tag:help.appveyor.com,2012-11-13:/discussions/suggestions/565-upgrade-cmake-on-appveyor-workersAppVeyor: Discussion 2018-08-25T02:00:43Ztag:help.appveyor.com,2012-11-13:Comment/360002212015-02-09T17:30:46Z2015-02-09T17:30:46ZUpgrade cmake on appveyor workers<div><p>Will deploy it this week.</p></div>Feodor Fitsnertag:help.appveyor.com,2012-11-13:Comment/360002212015-02-09T17:38:13Z2015-02-12T21:38:56ZUpgrade cmake on appveyor workers<div><p>Great, thanks.</p></div>dmeiser79tag:help.appveyor.com,2012-11-13:Comment/360002212015-02-12T05:06:15Z2015-02-12T05:06:15ZUpgrade cmake on appveyor workers<div><p>It's been updated to the latest 3.1.2</p></div>Feodor Fitsnertag:help.appveyor.com,2012-11-13:Comment/360002212015-02-12T20:13:49Z2015-02-12T20:13:49ZUpgrade cmake on appveyor workers<div><p>Looks like this update broke the build here: <a href=
"https://ci.appveyor.com/project/vitaut/cppformat/build/1.0.699/job/t773yj8fir98gmyf">
https://ci.appveyor.com/project/vitaut/cppformat/build/1.0.699/job/...</a></p>
<p>The output is completely messed up (which is another issue), but
it appears that CMake warning is treated as a failure. It's not
clear what "Command executed with exception:" refers to though.</p></div>victor.zverovichtag:help.appveyor.com,2012-11-13:Comment/360002212015-02-12T20:17:36Z2015-02-12T20:17:36ZUpgrade cmake on appveyor workers<div><p>Seems like cmake is writing to StdErr which is treated by PS as
exception. Try replacing <code>before_build</code> section
with:</p>
<pre>
<code>before_build:
- ps: |
if ($env:Build -eq "mingw") {
# Remove path to Git bin directory from PATH because it breaks MinGW config.
$env:PATH = $env:PATH -replace "C:\\Program Files \(x86\)\\Git\\bin",""
$generator = "-GMinGW Makefiles"
}
- echo "-DCMAKE_BUILD_TYPE=$env:Config"
- cmake -DFMT_EXTRA_TESTS=ON "-DCMAKE_BUILD_TYPE=$env:Config" "$generator" .</code>
</pre></div>Feodor Fitsnertag:help.appveyor.com,2012-11-13:Comment/360002212015-02-12T21:34:35Z2015-02-12T21:34:36ZUpgrade cmake on appveyor workers<div><p>Several options to fix this:<br>
- use <code>cmake_policy</code> as mentioned in the error message
to get old cmake behavior. - Fix the CMakeLists.txt to the new
behavior (get rid of quotes in if statement). - Ignore warning with
-Wno-dev Let me know if you have problems with any of this. I could
provide PR to fix.</p></div>dmeiser79tag:help.appveyor.com,2012-11-13:Comment/360002212015-02-13T03:04:25Z2015-02-13T03:04:27ZUpgrade cmake on appveyor workers<div><p>Feodor, unfortunately changing the <code>before_build</code>
section didn't help, but you were right the problem was in
PowerShell's treatment of stderr. I've moved the code to a separate
Python script, so everything is working now and much cleaner.
Shouldn't have used PowerShell in the first place because it's such
a mess, but I didn't know that Python comes preinstalled on build
machines.</p>
<p>Dominic, I fixed the warning already, but thanks for the
suggestion.</p>
<p>Thanks, guys.</p></div>victor.zverovichtag:help.appveyor.com,2012-11-13:Comment/360002212015-02-13T03:05:35Z2015-02-13T03:05:35ZUpgrade cmake on appveyor workers<div><p>Great, thanks for the update!</p></div>Feodor Fitsnertag:help.appveyor.com,2012-11-13:Comment/360002212015-10-05T22:53:25Z2015-10-05T22:53:26ZUpgrade cmake on appveyor workers<div><p>There is a bug in CMake related to VS2015 and the
redistributable dll's (<a href="https://cmake.org/Bug/view.php?id=15552">https://cmake.org/Bug/view.php?id=15552</a>).
The CMake bug is fixed in CMake version 3.2.3. Could you upgrade
CMake again to at least 3.2.3?</p>
<p>Thank you!</p></div>Christopher Dembiatag:help.appveyor.com,2012-11-13:Comment/360002212015-10-05T23:17:11Z2015-10-05T23:17:11ZUpgrade cmake on appveyor workers<div><p>Sure. I've added a new issue: <a href="https://github.com/appveyor/ci/issues/444">https://github.com/appveyor/ci/issues/444</a></p></div>Feodor Fitsner