<div dir="ltr">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).<br></div><br><div class="gmail_quote"><div dir="ltr">On Fri, Jan 11, 2019 at 7:58 AM Hendrik Sattler <<a href="mailto:post@hendrik-sattler.de">post@hendrik-sattler.de</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>Hi,<br><br>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.<br><br>HS<br><br><br><div class="gmail_quote">Am 11. Januar 2019 10:43:05 MEZ schrieb Chris Wilson <<a href="mailto:chris%2Bcmake@qwirx.com" target="_blank">chris+cmake@qwirx.com</a>>:<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div dir="ltr">In case it helps, Box Backup uses Windows <a href="https://docs.microsoft.com/en-us/windows/desktop/api/winbase/nf-winbase-createjobobjecta" target="_blank">Job Objects</a> to ensure that any daemons started during a test will automatically be killed when the test process exits (if not stopped cleanly beforehand):<div><br></div><div><a href="https://github.com/boxbackup/boxbackup/blob/s3_support/infrastructure/buildenv-testmain-template.cpp#L367" target="_blank">https://github.com/boxbackup/boxbackup/blob/s3_support/infrastructure/buildenv-testmain-template.cpp#L367</a><br></div><div><br></div><div>On Linux you can use prctl(PR_SET_PDEATHSIG, SIGKILL) in the child process (between fork() and exec()) to achieve this.</div></div><br><div class="gmail_quote"><div dir="ltr">On Thu, 10 Jan 2019 at 22:17, Person Withhats <<a href="mailto:personwithhats2@gmail.com" target="_blank">personwithhats2@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">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......<div><br></div><div>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.</div><div><br></div><div>I think force-killing CMake GUI also won't forward the kill to the exec_process, orphaning it.....>.<</div><div><br></div><div>Let me know any suggestions or possible fixes</div></div>
-- <br>
<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" rel="noreferrer" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br>
<br>
Kitware offers various services to support the CMake community. For more information on each offering, please visit:<br>
<br>
CMake Support: <a href="http://cmake.org/cmake/help/support.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/support.html</a><br>
CMake Consulting: <a href="http://cmake.org/cmake/help/consulting.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/consulting.html</a><br>
CMake Training Courses: <a href="http://cmake.org/cmake/help/training.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/training.html</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="https://cmake.org/mailman/listinfo/cmake" rel="noreferrer" target="_blank">https://cmake.org/mailman/listinfo/cmake</a><br>
</blockquote></div>
</blockquote></div></div></blockquote></div>