Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 51e4549b authored by Henri Chataing's avatar Henri Chataing Committed by Automerger Merge Worker
Browse files

Merge "gdcert: Remove the pybind module bluetooth_packets_python3" into main...

Merge "gdcert: Remove the pybind module bluetooth_packets_python3" into main am: 914238d6 am: bbab7d25

Original change: https://android-review.googlesource.com/c/platform/packages/modules/Bluetooth/+/3008475



Change-Id: Idb4cdca3066d1562c48917c99252aba826899759
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents bebf379f bbab7d25
Loading
Loading
Loading
Loading
+1 −7
Original line number Diff line number Diff line
@@ -24,9 +24,6 @@ LOCAL_host_python_hci_packets_library := \
LOCAL_host_python_smp_packets_library := \
	$(SOONG_OUT_DIR)/.intermediates/packages/modules/Bluetooth/system/pdl/security/gd_smp_packets_python3_gen/gen/smp_packets.py

LOCAL_host_python_extension_libraries := \
	$(HOST_OUT_SHARED_LIBRARIES)/bluetooth_packets_python3.so

LOCAL_host_libraries := \
	$(HOST_OUT_SHARED_LIBRARIES)/libbase.so \
	$(HOST_OUT_SHARED_LIBRARIES)/libbinder.so \
@@ -98,14 +95,12 @@ $(bluetooth_cert_src_and_bin_zip): PRIVATE_bluetooth_project_dir := $(LOCAL_blue
$(bluetooth_cert_src_and_bin_zip): PRIVATE_cert_test_sources := $(LOCAL_cert_test_sources)
$(bluetooth_cert_src_and_bin_zip): PRIVATE_host_executables := $(LOCAL_host_executables)
$(bluetooth_cert_src_and_bin_zip): PRIVATE_host_libraries := $(LOCAL_host_libraries)
$(bluetooth_cert_src_and_bin_zip): PRIVATE_host_python_extension_libraries := $(LOCAL_host_python_extension_libraries)
$(bluetooth_cert_src_and_bin_zip): PRIVATE_host_python_hci_packets_library := $(LOCAL_host_python_hci_packets_library)
$(bluetooth_cert_src_and_bin_zip): PRIVATE_host_python_smp_packets_library := $(LOCAL_host_python_smp_packets_library)
$(bluetooth_cert_src_and_bin_zip): PRIVATE_target_executables := $(LOCAL_target_executables)
$(bluetooth_cert_src_and_bin_zip): PRIVATE_target_libraries := $(LOCAL_target_libraries)
$(bluetooth_cert_src_and_bin_zip): $(SOONG_ZIP) $(LOCAL_cert_test_sources) \
		$(LOCAL_host_executables) $(LOCAL_host_libraries) $(LOCAL_host_python_libraries) \
		$(LOCAL_host_python_extension_libraries) \
		$(LOCAL_host_python_hci_packets_library) \
		$(LOCAL_host_python_smp_packets_library) \
		$(LOCAL_target_executables) $(LOCAL_target_libraries)
@@ -114,7 +109,6 @@ $(bluetooth_cert_src_and_bin_zip): $(SOONG_ZIP) $(LOCAL_cert_test_sources) \
		-C $(dir $(PRIVATE_host_python_hci_packets_library)) -f $(PRIVATE_host_python_hci_packets_library) \
		-C $(dir $(PRIVATE_host_python_smp_packets_library)) -f $(PRIVATE_host_python_smp_packets_library) \
		-C $(HOST_OUT_EXECUTABLES) $(addprefix -f ,$(PRIVATE_host_executables)) \
		-C $(HOST_OUT_SHARED_LIBRARIES) $(addprefix -f ,$(PRIVATE_host_python_extension_libraries)) \
		-P lib64 \
		-C $(HOST_OUT_SHARED_LIBRARIES) $(addprefix -f ,$(PRIVATE_host_libraries)) \
		-P target \
@@ -125,7 +119,7 @@ $(call declare-container-license-metadata,$(bluetooth_cert_src_and_bin_zip),\
    SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD SPDX-license-identifier-MIT legacy_unencumbered,\
    notice, $(LOCAL_PATH)/../NOTICE,,packages/modules/Bluetooth)
$(call declare-container-license-deps,$(bluetooth_cert_src_and_bin_zip),\
    $(LOCAL_host_python_extension_libraries) $(LOCAL_target_executables) $(LOCAL_target_libraries),$(bluetooth_cert_src_and_bin_zip):)
    $(LOCAL_target_executables) $(LOCAL_target_libraries),$(bluetooth_cert_src_and_bin_zip):)

# TODO: Find a better way to locate output from SOONG genrule()
LOCAL_facade_generated_py_zip := \
+0 −1
Original line number Diff line number Diff line
@@ -14,7 +14,6 @@
#   See the License for the specific language governing permissions and
#   limitations under the License.

import bluetooth_packets_python3 as bt_packets
from blueberry.tests.gd.cert.capture import Capture
from blueberry.tests.gd.cert.matchers import HciMatchers
from blueberry.tests.gd.cert.matchers import SecurityMatchers
+0 −1
Original line number Diff line number Diff line
@@ -14,7 +14,6 @@
#   See the License for the specific language governing permissions and
#   limitations under the License.

import bluetooth_packets_python3 as bt_packets
import logging
import sys

+0 −1
Original line number Diff line number Diff line
@@ -24,7 +24,6 @@ from blueberry.facade.hci import le_acl_manager_facade_pb2 as le_acl_manager_fac
from blueberry.facade.hci import le_advertising_manager_facade_pb2 as le_advertising_facade
from blueberry.facade.hci import le_initiator_address_facade_pb2 as le_initiator_address_facade
from blueberry.facade.hci import hci_facade_pb2 as hci_facade
from bluetooth_packets_python3 import RawBuilder
from mobly import test_runner
import hci_packets as hci

+0 −98
Original line number Diff line number Diff line
@@ -791,101 +791,3 @@ genrule {
        "wakelock_manager_generated.h",
    ],
}

cc_defaults {
    name: "bluetooth_py3_native_extension_defaults",
    include_dirs: [
        "external/python/cpython3/Include",
    ],
    target: {
        android: {
            include_dirs: ["external/python/cpython3/android/bionic/pyconfig"],
        },
        android_arm: {
            cflags: ["-DSOABI=\"cpython-38android-arm-android-bionic\""],
            suffix: ".cpython-38android-arm-android-bionic",
        },
        android_arm64: {
            cflags: ["-DSOABI=\"cpython-38android-arm64-android-bionic\""],
            suffix: ".cpython-38android-arm64-android-bionic",
        },
        android_x86: {
            cflags: ["-DSOABI=\"cpython-38android-x86-android-bionic\""],
            suffix: ".cpython-38android-x86-android-bionic",
        },
        android_x86_64: {
            cflags: ["-DSOABI=\"cpython-38android-x86_64-android-bionic\""],
            suffix: ".cpython-38android-x86_64-android-bionic",
        },
        // Regenerate include dirs with android_regen.sh
        darwin_x86_64: {
            include_dirs: ["external/python/cpython3/android/darwin_x86_64/pyconfig"],
            cflags: [
                "-DSOABI=\"cpython-38android-x86_64-darwin\"",
                "-Wno-deprecated-declarations",
                "-Wno-pointer-arith",
            ],
            suffix: ".cpython-38android-x86_64-darwin",
        },
        linux_bionic: {
            // NB linux_bionic is a 'host' architecture but it uses the bionic libc like 'android'
            // targets so use the android pyconfig.
            include_dirs: ["external/python/cpython3/android/bionic/pyconfig"],
            cflags: ["-DSOABI=\"cpython-38android-x86_64-linux-bionic\""],
            suffix: ".cpython-38android-x86_64-linux-bionic",
        },
        linux_glibc_x86: {
            enabled: false,
        },
        linux_glibc_x86_64: {
            include_dirs: ["external/python/cpython3/android/linux_x86_64/pyconfig"],
            cflags: ["-DSOABI=\"cpython-38android-x86_64-linux-gnu\""],
            // Commenting out the Linux suffix so that cpython-38-x86_64-linux-gnu
            // Python 3.8 can also import the untagged .so library per PEP 3149
            // Keep this change until Android py3-cmd can run ACTS, gRPC and can
            // Export Python native symbols such as PyType_Type
            // suffix: ".cpython-38android-x86_64-linux-gnu",
        },
        linux_musl_x86: {
            enabled: false,
        },
        linux_musl_x86_64: {
            include_dirs: ["external/python/cpython3/android/linux_x86_64/pyconfig"],
            cflags: ["-DSOABI=\"cpython-38android-x86_64-linux-gnu\""],
            // Commenting out the Linux suffix so that cpython-38-x86_64-linux-gnu
            // Python 3.8 can also import the untagged .so library per PEP 3149
            // Keep this change until Android py3-cmd can run ACTS, gRPC and can
            // Export Python native symbols such as PyType_Type
            // suffix: ".cpython-38android-x86_64-linux-gnu",
        },
        windows: {
            enabled: false,
        },
    },
    allow_undefined_symbols: true,
}

cc_library_host_shared {
    name: "bluetooth_packets_python3",
    defaults: [
        "bluetooth_py3_native_extension_defaults",
        "gd_defaults",
    ],
    srcs: [
        ":BluetoothPacketSources",
        "common/strings.cc",
        "packet/python3_module.cc",

    ],
    header_libs: [
        "pybind11_headers",
    ],
    static_libs: [
        "libbase",
        "libbluetooth_log",
    ],
    cflags: [
        "-fexceptions",
    ],
    rtti: true,
}
Loading