[CMake] CMake GUI "Stop" button does not halt exec_process

Michael Jackson mike.jackson at bluequartz.net
Fri Jan 11 12:33:17 EST 2019


This is interesting as I have come across something that sounds related but might not be. Inside of QtCreator my projects are setup to call “cmake –build ${build_dir} –target all”. After updating to Xcode 10.1 from Xcode 9.4.x when I stop my build inside of QtCreator the cmake process itself is stopped BUT the actual compilers (clang in my case) keep going. I have to open a terminal and “killall clang” to get everything to stop. I never had a problem until I updated to Xcode 10.1. This is with CMake 3.13.0 and macOS 10.13.6. Again, maybe related, maybe not.

 

--

Michael Jackson | Owner, President

      BlueQuartz Software

[e] mike.jackson at bluequartz.net

[w] www.bluequartz.net

 

From: CMake <cmake-bounces at cmake.org> on behalf of Person Withhats <personwithhats2 at gmail.com>
Date: Friday, January 11, 2019 at 11:47 AM
To: Hendrik Sattler <post at hendrik-sattler.de>
Cc: CMake <cmake at cmake.org>
Subject: Re: [CMake] CMake GUI "Stop" button does not halt exec_process

 

I don't follow. None of this looks like I can press stop in CMake and have the process die. I'm not making any additional children, just execute_process in CMak (so 1 child that never gets killed).

 

On Fri, Jan 11, 2019 at 7:58 AM Hendrik Sattler <post at hendrik-sattler.de> wrote:

Hi,

killing everything might be problematic in some cases: MSVC uses some shared processes to write PDB files. Killing that will make an unrelated other build fail. That was real fun to find out when Jenkins was cleaning up. So kill your children but don't be too pedantic.

HS

Am 11. Januar 2019 10:43:05 MEZ schrieb Chris Wilson <chris+cmake at qwirx.com>:

In case it helps, Box Backup uses Windows Job Objects to ensure that any daemons started during a test will automatically be killed when the test process exits (if not stopped cleanly beforehand):

 

https://github.com/boxbackup/boxbackup/blob/s3_support/infrastructure/buildenv-testmain-template.cpp#L367

 

On Linux you can use prctl(PR_SET_PDEATHSIG, SIGKILL) in the child process (between fork() and exec()) to achieve this.

 

On Thu, 10 Jan 2019 at 22:17, Person Withhats <personwithhats2 at gmail.com> wrote:

Pressing "STOP" in the CMake GUI interface halts CMake itself but does not stop any execute_process that is going on at the time. This makes it hang until the process finishes, since no interrupt is sent......

 

Aggravating when you're using an exterior script (e.g. a .exe or .py) that e.g. handles package maintenance. Would hang up for the entire duration of ~40 minutes unless you force kill that sub process.

 

I think force-killing CMake GUI also won't forward the kill to the exec_process, orphaning it.....>.<

 

Let me know any suggestions or possible fixes

-- 

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:
https://cmake.org/mailman/listinfo/cmake

-- 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: https://cmake.org/mailman/listinfo/cmake 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://cmake.org/pipermail/cmake/attachments/20190111/fed078da/attachment.html>


More information about the CMake mailing list