You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I'm trying to integrate this into my bazel local project. Need your help to understand better on how integrating this and clear my own assumptions so I'm in the right track.
What I understand, to integrate this library:
Create dummy target in the Xcode for bazel local project. The target name should be the same with your module. (CMIIW). Why we need this dummy target? Target is required by Xcode to create indexing. Xcode also automatically create folders inside DerivedData based by these targets. (for example <module_name>.build folders)
Add this script into your main target (target where you have Bazel Build script running). Add this after the Bazel Build script.
When Bazel is compiling the project, it will create indexstore (if you enabled it by adding build --features="swift.index_while_building" flag in .bazelrc) inside bazel-out folder.
To properly create indexing, we need to add some files in the bazel-out/**/*.indexstore/* into "$BUILD_DIR"/../../Index/DataStore. Also, some objects compiled by Bazel needs to be moved to DerivedData, by using index-import lib.
Up to this step I have hard times to detect if index-import is properly working or not. I managed to get all indexstores into "$BUILD_DIR"/../../Index/DataStore but I can't see some of the compiled objects for swift or objc in the "$CONFIGURATION_TEMP_DIR/\$1.build/Objects-normal/$BUILD_ARCH/\$2.o" folder.
Does the remap option in index-import creates directory if it's not exist? What does the remap option do?
Since there are no failures or any output, how can I debug the missing objc and swift objects in "$CONFIGURATION_TEMP_DIR/\$1.build/Objects-normal/$BUILD_ARCH/\$2.o"?
The text was updated successfully, but these errors were encountered:
Hi,
I'm trying to integrate this into my bazel local project. Need your help to understand better on how integrating this and clear my own assumptions so I'm in the right track.
What I understand, to integrate this library:
dummy target
in the Xcode for bazel local project. The target name should be the same with your module. (CMIIW). Why we need thisdummy target
? Target is required by Xcode to create indexing. Xcode also automatically create folders insideDerivedData
based by these targets. (for example<module_name>.build
folders)Bazel Build
script running). Add this after theBazel Build
script.build --features="swift.index_while_building"
flag in.bazelrc
) insidebazel-out
folder.bazel-out/**/*.indexstore/*
into"$BUILD_DIR"/../../Index/DataStore
. Also, some objects compiled by Bazel needs to be moved toDerivedData
, by usingindex-import
lib.Up to this step I have hard times to detect if
index-import
is properly working or not. I managed to get allindexstores
into"$BUILD_DIR"/../../Index/DataStore
but I can't see some of the compiled objects for swift or objc in the"$CONFIGURATION_TEMP_DIR/\$1.build/Objects-normal/$BUILD_ARCH/\$2.o"
folder.remap
option inindex-import
creates directory if it's not exist? What does theremap
option do?"$CONFIGURATION_TEMP_DIR/\$1.build/Objects-normal/$BUILD_ARCH/\$2.o"
?The text was updated successfully, but these errors were encountered: