CMake gets stuck during Build

I’m dealing with this strange situation that I cannot really wrap my head around! :tired_face:

So, I have a CMake scripts called Patch.cmake here that goes and modify some library paths of some of the libraries that I’m installing. I know that the script works correctly! I run it once during the configuration using the execute_process here and several time during the build (for complicated reasons) using the add_custom_target/add_custom_command here. This is supposed to install some R packages and fix their paths, however when I try to run it on GitHub Action, the one that is running with add_custom_target/add_custom_command during the build gets stuck in the first run, at the signing here.

I’m out of ideas! I cannot see why the signing works during the configuration but not during the build. I’m also not building in parallel to make sure that I’m causing any extra issues. I don’t think this is caused by add_custom_target/add_custom_command because I can see that the Patch.cmake gets executed correctly up until the signing process (this line) of the first library.

I’m starting to think that something is up with the GitHub Action. Once I have left the Log open on the background and it just worked! :exploding_head:

I have a guess on why this is happening. I think it might be that the code singing cannot communicate with Apple’s server, or maybe there is a limit. So, I’m thinking to put the singing part into a loop and give it a timeout.