Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(17)

Side by Side Diff: third_party/librealsense/BUILD.gn

Issue 2028143002: third_party: Add librealsense library Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: support gyp Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « DEPS ('k') | third_party/librealsense/DEPS » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 # Copyright 2016 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
4
5 import("//build/config/linux/pkg_config.gni")
6
7 config("librealsense_config") {
8 include_dirs = [ "src/include" ]
9 }
10
11 # gn definition use_sysroot=false is needed to build in linux
12 if (is_linux || is_mac) {
13 static_library("libuvc") {
14 sources = [
15 "src/src/libuvc/ctrl.c",
16 "src/src/libuvc/dev.c",
17 "src/src/libuvc/diag.c",
18 "src/src/libuvc/frame.c",
19 "src/src/libuvc/init.c",
20 "src/src/libuvc/stream.c",
21 ]
22 deps = [
23 "//third_party/libusb",
24 ]
25 }
26 }
27
28 static_library("librealsense") {
29 sources = [
30 "src/src/context.cpp",
31 "src/src/device.cpp",
32 "src/src/f200-private.cpp",
33 "src/src/f200.cpp",
34 "src/src/image.cpp",
35 "src/src/log.cpp",
36 "src/src/r200-private.cpp",
37 "src/src/r200.cpp",
38 "src/src/rs.cpp",
39 "src/src/stream.cpp",
40 "src/src/sync.cpp",
41 "src/src/types.cpp",
42 "src/src/uvc-libuvc.cpp",
43 "src/src/uvc-v4l2.cpp",
44 "src/src/uvc-wmf.cpp",
45 "src/src/uvc.cpp",
46 "src/src/verify.c",
47 ]
48
49 configs -= [ "//build/config/compiler:chromium_code" ]
50 configs += [ "//build/config/compiler:no_chromium_code" ]
51
52 public_configs = [ ":librealsense_config" ]
53
54 deps = [
55 "//third_party/libusb",
56 ]
57
58 if (is_linux || is_mac) {
59 deps += [ ":libuvc" ]
60 }
61 if (is_linux) {
62 defines = [ "RS_USE_V4L2_BACKEND" ]
63 cflags = [ "-mssse3" ]
64 configs -= [ "//build/config/gcc:no_exceptions" ]
65 }
66
67 # TODO(dshwang): support mac and win later. crbug.com/616098
68 if (is_mac) {
69 defines = [ "RS_USE_LIBUVC_BACKEND" ]
70 }
71 if (is_win) {
72 defines = [ "RS_USE_WMF_BACKEND" ]
73 }
74 }
OLDNEW
« no previous file with comments | « DEPS ('k') | third_party/librealsense/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698