Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: Could not auto-detect a suitable build method #17983

Open
huanglei3 opened this issue Nov 14, 2024 · 1 comment
Open

Error: Could not auto-detect a suitable build method #17983

huanglei3 opened this issue Nov 14, 2024 · 1 comment
Labels
question Further information is requested

Comments

@huanglei3
Copy link

** Error: Could not auto-detect a suitable build method**

hello ,when i exec command:codeql database create testdb1 -l cpp -s F:\project,i meet this error:

Initializing database at F:\project\testdb1.
Running build command: [F:\codeql-win64\codeql\cpp\tools\autobuild.cmd]
Running command in F:\project\flameshot: [F:\codeql-win64\codeql\cpp\tools\autobuild.cmd]
[2024-11-14 15:17:33] [build-stdout] CodeQL C++ autobuilder
[2024-11-14 15:17:33] [build-stdout] Working directory: F:\project\flameshot
[2024-11-14 15:17:33] [build-stdout] Attempting to locate build script
[2024-11-14 15:17:33] [build-stderr] Error: Could not auto-detect a suitable build method
[2024-11-14 15:17:34] [ERROR] Spawned process exited abnormally (code 1; tried to run: [F:\codeql-win64\codeql\tools\win64\tracer.exe, F:\codeql-win64\codeql\tools\win64\runner.exe, cmd.exe, /C, type, NUL, &&, F:\codeql-win64\codeql\cpp\tools\autobuild.cmd])
A fatal error occurred: Exit status 1 from command: [F:\codeql-win64\codeql\tools\win64\runner.exe, cmd.exe, /C, type, NUL, &&, F:\codeql-win64\codeql\cpp\tools\autobuild.cmd]

please help me,thank you

@huanglei3 huanglei3 added the question Further information is requested label Nov 14, 2024
@aibaars
Copy link
Contributor

aibaars commented Nov 14, 2024

The following documentation should give you an idea of how CodeQL tries to automatically build your project https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages#building-cc

If using autobuild fails then you need to manually supply a build command. See the following documentation for instructions: https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages#about-specifying-build-steps-manually

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants