Skip to content

Commit

Permalink
Turn on EXPORT_COMPILE_COMMANDS
Browse files Browse the repository at this point in the history
For `clangd` to work properly, one may need to make symbolic links

```
cd patch-loader
ln -sf $PWD/build/tools/debug/arm64-v8a/compile_commands.json build
```
  • Loading branch information
JingMatrix committed May 19, 2024
1 parent 4a7cc25 commit 04a75ce
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
.project
.cache
.settings
libxposed
*.iml
Expand Down
2 changes: 2 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ fun Project.configureBaseExtension() {

externalNativeBuild.cmake {
version = "3.28.1+"
buildStagingDirectory = layout.buildDirectory.get().asFile
}

defaultConfig {
Expand Down Expand Up @@ -122,6 +123,7 @@ fun Project.configureBaseExtension() {
cppFlags("-std=c++20", *flags)
cFlags("-std=c18", *flags)
arguments(
"-DCMAKE_EXPORT_COMPILE_COMMANDS=ON",
"-DANDROID_STL=none",
"-DVERSION_CODE=$verCode",
"-DVERSION_NAME=$verName",
Expand Down
2 changes: 1 addition & 1 deletion core
Submodule core updated 2 files
+1 −0 .gitignore
+3 −1 build.gradle.kts

0 comments on commit 04a75ce

Please sign in to comment.