Install scoop and then use scoop to install xmake
scoop install xmake
Because libgit2 requires admin console, you need to launch a admin console to execute the following command:
xmake config --yes -vD -m releasedbg --plat=windows
The next you run xmake config
, it is ok to run without the admin console.
xmake build research
See How to test。
xmake i research
xmake r research
Developers using Vscode can use xmake to generate compile_command.json
, which can be recognized by C/C++ plugin to provide semantics highlight and so on.
xmake project --kind=compile_commands ./.vscode
then modify .vscode/c_cpp_properties.json
to tell C++ lsp configs of this project:
{
{
"configurations": [
{
// other configs
"compilerPath": "<your configuration>",
"cppStandard": "gnu++17",
"intelliSenseMode": "windows-gcc-x64",
"compileCommands": ".vscode/compile_commands.json"
}
],
}
}