public static function become_daemon(callable $call = null) : int        // do not use this unless you know what you are doing
    {
        if (!\extension_loaded('pcntl')) {
            print 'You must have the PCNTL extencion installed. See Carbon PHP for documentation.' and die;
        }

        if ($pid = pcntl_fork()) {  // Parent
            if (\is_callable($call)) {
                return 1;
            }
            exit;
        }
        if ($pid < 0) {
            throw new \RuntimeException('Failed to fork');
        }

        \define('FORK', TRUE);

        /* child becomes our daemon */
        posix_setsid();

        chdir('/');   // What does this do ?

        umask(0);        // Give access to nothing

        register_shutdown_function(function () {
            session_abort();
            posix_kill(posix_getpid(), SIGHUP);
            exit(1);
        });

        if (\is_callable($call)) {
            $call();
            exit(1);
        }

        return posix_getpid();
    }