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

Commit dbe55155 authored by Jakub Pawlowski's avatar Jakub Pawlowski
Browse files

Linux build fix

Move metrics_linux.cc into common/, where the metrics live now.
Add btif_avrcp_audio_track_linux.cc
Fix BUILD.gn files.
Define FALLTHROUGH_INTENDED for linux, to fix build error.

Test: build with ninja and run on linux
Change-Id: I117d19ed25828389c385f09ad731e8bd61b38030
parent dcf730b0
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -133,8 +133,6 @@ executable("net_test_bta") {
        "test/gatt/database_builder_test.cc",
        "test/gatt/database_builder_sample_device_test.cc",
        "test/gatt/database_test.cc",
        "gatt/database.cc",
        "gatt/database_builder.cc",
  ]

  include_dirs = [
@@ -148,6 +146,7 @@ executable("net_test_bta") {
  ]

  deps = [
    "//bta",
    "//types",
    "//third_party/googletest:gmock_main",
    "//third_party/libchrome:base",
+2 −0
Original line number Diff line number Diff line
@@ -28,6 +28,7 @@ static_library("btif") {

    #TODO(jpawlowski): heavily depends on Android,
    #   "src/btif_avrcp_audio_track.cc",
    "src/btif_avrcp_audio_track_linux.cc",
    "src/btif_ble_advertiser.cc",
    "src/btif_ble_scanner.cc",
    "src/btif_config.cc",
@@ -103,6 +104,7 @@ static_library("btif") {
  ]

  deps = [
    "//common",
    "//third_party/libchrome:base",
    "//profile/avrcp:profile_avrcp"
  ]
+37 −0
Original line number Diff line number Diff line
/*
 * Copyright 2018 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#include "btif_avrcp_audio_track.h"

void* BtifAvrcpAudioTrackCreate(int trackFreq, int bits_per_sample,
                                int channelType) {
  return nullptr;
}

void BtifAvrcpAudioTrackStart(void* handle) {}

void BtifAvrcpAudioTrackStop(void* handle) {}

void BtifAvrcpAudioTrackDelete(void* handle) {}

void BtifAvrcpAudioTrackPause(void* handle) {}

void BtifAvrcpSetAudioTrackGain(void* handle, float gain) {}

int BtifAvrcpAudioTrackWriteData(void* handle, void* audioBuffer,
                                 int bufferlen) {
  return 0;
}
+2 −0
Original line number Diff line number Diff line
@@ -59,6 +59,8 @@ config("linux") {
    # current build is done by GN or via Android.mk. This is a temporary
    # workaround until we can remove all Android-specific dependencies.
    "OS_GENERIC",

    "FALLTHROUGH_INTENDED",
  ]
}

+0 −1
Original line number Diff line number Diff line
@@ -96,7 +96,6 @@ source_set("base_sources") {
    "base/metrics/sparse_histogram.cc",
    "base/metrics/statistics_recorder.cc",
    "base/native_library.cc",
    "base/native_library_posix.cc",
    "base/observer_list_threadsafe.cc",
    "base/path_service.cc",
    "base/pending_task.cc",
Loading