From d7617868eb6fe2975fdc7175c31882e941ef72ed Mon Sep 17 00:00:00 2001 From: Bruno Martins Date: Sun, 23 Jun 2024 21:58:49 +0100 Subject: [PATCH] sm8450-common: Convert WiFi firmware symlink to install_symlink target The last bit that was preventing building hermetic images. Change-Id: I75bb7de4593a7992f6015317cf97e088beeba0cb --- Android.bp | 35 +++++++++++++++++++++++++++++++++++ Android.mk | 25 ------------------------- common.mk | 8 ++++++++ 3 files changed, 43 insertions(+), 25 deletions(-) diff --git a/Android.bp b/Android.bp index d87505e..b0a9e89 100644 --- a/Android.bp +++ b/Android.bp @@ -11,3 +11,38 @@ soong_namespace { "vendor/qcom/opensource/commonsys-intf/display", ], } + +install_symlink { + name: "firmware_WCNSS_qcom_cfg.ini_symlink", + vendor: true, + installed_location: "firmware/wlan/qca_cld/WCNSS_qcom_cfg.ini", + symlink_target: "/vendor/etc/wifi/WCNSS_qcom_cfg.ini", +} + +install_symlink { + name: "firmware_qca6490_WCNSS_qcom_cfg.ini_symlink", + vendor: true, + installed_location: "firmware/wlan/qca_cld/qca6490/WCNSS_qcom_cfg.ini", + symlink_target: "/vendor/etc/wifi/qca6490/WCNSS_qcom_cfg.ini", +} + +install_symlink { + name: "firmware_qca6490_wlan_mac.bin_symlink", + vendor: true, + installed_location: "firmware/wlan/qca_cld/qca6490/wlan_mac.bin", + symlink_target: "/mnt/vendor/persist/qca6490/wlan_mac.bin", +} + +install_symlink { + name: "firmware_qca6750_WCNSS_qcom_cfg.ini_symlink", + vendor: true, + installed_location: "firmware/wlan/qca_cld/qca6750/WCNSS_qcom_cfg.ini", + symlink_target: "/vendor/etc/wifi/qca6750/WCNSS_qcom_cfg.ini", +} + +install_symlink { + name: "firmware_qca6750_wlan_mac.bin_symlink", + vendor: true, + installed_location: "firmware/wlan/qca_cld/qca6750/wlan_mac.bin", + symlink_target: "/mnt/vendor/persist/qca6750/wlan_mac.bin", +} diff --git a/Android.mk b/Android.mk index 54325ac..b19a044 100644 --- a/Android.mk +++ b/Android.mk @@ -39,29 +39,4 @@ ALL_DEFAULT_INSTALLED_MODULES += \ $(DSP_MOUNT_POINT) \ $(VM_SYSTEM_MOUNT_POINT) -FIRMWARE_WLAN_QCA_CLD_SYMLINKS := $(TARGET_OUT_VENDOR)/firmware/wlan/qca_cld/ -$(FIRMWARE_WLAN_QCA_CLD_SYMLINKS): $(LOCAL_INSTALLED_MODULE) - @echo "Creating qca_cld wlan firmware symlinks: $@" - mkdir -p $@ - $(hide) ln -sf /vendor/etc/wifi/WCNSS_qcom_cfg.ini $@/WCNSS_qcom_cfg.ini - -FIRMWARE_WLAN_QCA_CLD_QCA6490_SYMLINKS := $(TARGET_OUT_VENDOR)/firmware/wlan/qca_cld/qca6490/ -$(FIRMWARE_WLAN_QCA_CLD_QCA6490_SYMLINKS): $(LOCAL_INSTALLED_MODULE) - @echo "Creating qca6490 qca_cld wlan firmware symlinks: $@" - mkdir -p $@ - $(hide) ln -sf /vendor/etc/wifi/qca6490/WCNSS_qcom_cfg.ini $@/WCNSS_qcom_cfg.ini - $(hide) ln -sf /mnt/vendor/persist/qca6490/wlan_mac.bin $@/wlan_mac.bin - -FIRMWARE_WLAN_QCA_CLD_QCA6750_SYMLINKS := $(TARGET_OUT_VENDOR)/firmware/wlan/qca_cld/qca6750/ -$(FIRMWARE_WLAN_QCA_CLD_QCA6750_SYMLINKS): $(LOCAL_INSTALLED_MODULE) - @echo "Creating qca6750 qca_cld wlan firmware symlinks: $@" - mkdir -p $@ - $(hide) ln -sf /vendor/etc/wifi/qca6750/WCNSS_qcom_cfg.ini $@/WCNSS_qcom_cfg.ini - $(hide) ln -sf /mnt/vendor/persist/qca6750/wlan_mac.bin $@/wlan_mac.bin - -ALL_DEFAULT_INSTALLED_MODULES += \ - $(FIRMWARE_WLAN_QCA_CLD_SYMLINKS) \ - $(FIRMWARE_WLAN_QCA_CLD_QCA6490_SYMLINKS) \ - $(FIRMWARE_WLAN_QCA_CLD_QCA6750_SYMLINKS) - endif diff --git a/common.mk b/common.mk index 12c0143..1c9d479 100644 --- a/common.mk +++ b/common.mk @@ -573,3 +573,11 @@ PRODUCT_COPY_FILES += \ PRODUCT_PACKAGES += \ libnl \ libwfdaac_vendor + +# WiFi firmware symlinks +PRODUCT_PACKAGES += \ + firmware_WCNSS_qcom_cfg.ini_symlink \ + firmware_qca6490_WCNSS_qcom_cfg.ini_symlink \ + firmware_qca6490_wlan_mac.bin_symlink \ + firmware_qca6750_WCNSS_qcom_cfg.ini_symlink \ + firmware_qca6750_wlan_mac.bin_symlink