Skip to content

Add option to extract debug infos into <file>.debug file and link it #949

@henderkes

Description

@henderkes

like

if (!$this->getOption('no-strip', false) && file_exists(BUILD_BIN_PATH . '/frankenphp')) {
    shell()->cd(BUILD_BIN_PATH)->exec('objcopy --only-keep-debug frankenphp frankenphp.debug');
    if (PHP_OS_FAMILY === 'Linux') {
        shell()->cd(BUILD_BIN_PATH)->exec('strip --strip-unneeded frankenphp');
    } else {
        shell()->cd(BUILD_BIN_PATH)->exec('strip -S frankenphp');
    }
    shell()->cd(BUILD_BIN_PATH)->exec('objcopy --add-gnu-debuglink=frankenphp.debug frankenphp');
}

Metadata

Metadata

Assignees

Labels

kind/frameworkIssues related to CLI app frameworknew featureNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions