(Preface: I am running on a Qualcomm AOSP build tree for Android-Q, and not sure how different it is from an unmodified Android release.)
It doesn't look to me like symlinks work for cc_prebuilt_binary the way they work for cc_binary.
Android.bp for the source case:
Android.bp for the prebuilt case:
The results when both of these are built:
-rwxrwxr-x 1 builder group 14784 Apr 25 14:28 world_bin*
lrwxrwxrwx 1 builder group 5 Apr 25 14:28 hello -> world*
-rwxrwxr-x 1 builder group 14784 Apr 25 14:28 world*
It even appears that such symlinks declarations that are in AOSP/system/core/logcat/Android.bp don't work:
cc_prebuilt_binary {
name: "logpersist.start",
srcs: ["logpersist"],
init_rc: ["logcatd.rc"],
required: ["logcatd"],
symlinks: [
"logpersist.stop",
],
strip: {
none: true,
},
}
Yields
logpersist.start, but no links as
logpersist.stop or
logpersist.cat
Has the symlinks feature of cc_prebuilt_binary not been implemented yet?
Thanks in advance,
Chris