Skip to content
This repository has been archived by the owner on Nov 8, 2023. It is now read-only.

Brillo m7 dev #21

Closed
wants to merge 2,864 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
2864 commits
Select commit Hold shift + click to select a range
18395cb
Ignore explicit infinite recursion.
stephenhines Sep 30, 2015
bb58cde
system/core: change LruCache to use unordered_set instead of BasicHas…
Sep 25, 2015
730fdbb
Merge "system/core: change LruCache to use unordered_set instead of B…
Sep 30, 2015
8e2c820
am 730fdbb1: Merge "system/core: change LruCache to use unordered_set…
Sep 30, 2015
282efae
system/core: remove methods returning SharedBuffer in String8, String16
Sep 30, 2015
e045333
Merge "system/core: remove methods returning SharedBuffer in String8,…
Sep 30, 2015
ad2a5a8
Merge "fs_mgr: trigger dm-verity error handling for invalid signatures"
samitolvanen Sep 30, 2015
0e7fb13
libutils: fix compile error in SharedBufferTest
Sep 23, 2015
1b2fb58
Merge changes I42162365,Ia72f1305,I57d1f86c,I026d074e
Sep 30, 2015
447356d
Merge "liblog: logcat: Add year and zone to date on each line"
Sep 30, 2015
b5a00d6
am e0453334: Merge "system/core: remove methods returning SharedBuffe…
Sep 30, 2015
049399e
am ad2a5a89: Merge "fs_mgr: trigger dm-verity error handling for inva…
samitolvanen Sep 30, 2015
900362c
am 1b2fb587: Merge changes I42162365,Ia72f1305,I57d1f86c,I026d074e
Sep 30, 2015
351c211
am 447356dd: Merge "liblog: logcat: Add year and zone to date on each…
Sep 30, 2015
aa77e22
adb: detect sockets in CLOSE_WAIT state to prevent socket leak on linux.
yabinc Sep 29, 2015
70ef7b4
adb: put legacy shell: service back in.
dpursell Sep 30, 2015
fd18d9e
Merge "adb: put legacy shell: service back in."
dpursell Sep 30, 2015
de3faec
am fd18d9e2: Merge "adb: put legacy shell: service back in."
dpursell Sep 30, 2015
4818011
crash_reporter: Set Version and Product ID
Sep 30, 2015
ffa866f
Merge "adb: detect sockets in CLOSE_WAIT state to prevent socket leak…
yabinc Oct 1, 2015
4b3ee26
am ffa866f5: Merge "adb: detect sockets in CLOSE_WAIT state to preven…
yabinc Oct 1, 2015
dc91daf
Merge "Ignore explicit infinite recursion."
stephenhines Oct 1, 2015
f141312
am dc91dafa: Merge "Ignore explicit infinite recursion."
stephenhines Oct 1, 2015
888a748
adb: fdevent fixes
CompareAndSwap Sep 30, 2015
9466bb2
Fix build break due to unknown pragma (on gcc).
stephenhines Oct 1, 2015
d29f10c
Merge "Fix build break due to unknown pragma (on gcc)."
stephenhines Oct 1, 2015
cabf610
am d29f10cd: Merge "Fix build break due to unknown pragma (on gcc)."
stephenhines Oct 1, 2015
f84a490
system/core: remove BasicHashtable
Oct 1, 2015
7c262ab
Merge "crash_reporter: Set Version and Product ID"
Oct 1, 2015
3f43729
am 7c262abe: Merge "crash_reporter: Set Version and Product ID"
Oct 1, 2015
7080882
Merge "system/core: remove BasicHashtable"
Oct 1, 2015
7377398
Merge "adb: fdevent fixes"
yabinc Oct 1, 2015
fcbd11f
Remove 'seclabel' option.
jlucangelio Oct 1, 2015
17cd2c4
Merge "Remove 'seclabel' option."
jlucangelio Oct 1, 2015
bdae9bf
resolved conflicts for 70808827 to stage-aosp-master
Oct 1, 2015
fb070f3
am 7377398b: Merge "adb: fdevent fixes"
yabinc Oct 1, 2015
0c4ad78
am 17cd2c49: Merge "Remove \'seclabel\' option."
jlucangelio Oct 1, 2015
6f8885b
Implement C++11 move semantics for android::FileMap
Sep 23, 2015
7a96405
metricsd: Only collect metrics over a short period.
bsimonnet Sep 29, 2015
c6c6ab5
Merge "Implement C++11 move semantics for android::FileMap"
Oct 2, 2015
bda375f
am c6c6ab50: Merge "Implement C++11 move semantics for android::FileMap"
Oct 2, 2015
66255db
Merge "metricsd: Only collect metrics over a short period."
bsimonnet Oct 2, 2015
3fd57f2
am 66255db0: Merge "metricsd: Only collect metrics over a short period."
bsimonnet Oct 2, 2015
b5fa889
Add a "tlsdate" AID for unprivileged tlsdate execution.
Oct 2, 2015
b955f47
Merge "Add a "tlsdate" AID for unprivileged tlsdate execution."
Oct 2, 2015
65475f8
am b955f476: Merge "Add a "tlsdate" AID for unprivileged tlsdate exec…
Oct 2, 2015
16e1c9d
liblog: optimize code hotspot
Oct 2, 2015
ae5a6c0
Speed up adb sync.
enh-google Sep 27, 2015
5ac5c6b
logd: Add LogUtils.h
Aug 28, 2015
ddda212
logd: optimize code hotspots
Oct 2, 2015
5b73a10
Explain adb client/server version mismatch better.
enh-google Oct 3, 2015
e412cc8
Merge "Explain adb client/server version mismatch better."
enh-google Oct 3, 2015
42b8df3
Merge "adb: win32: specify socket protocol"
enh-google Oct 3, 2015
f6d28fc
am e412cc89: Merge "Explain adb client/server version mismatch better."
enh-google Oct 3, 2015
450b592
am 42b8df38: Merge "adb: win32: specify socket protocol"
enh-google Oct 3, 2015
72146b9
Merge "logd: Add LogUtils.h"
Oct 5, 2015
88e0166
Merge "logd: optimize code hotspots"
Oct 5, 2015
bd4f52b
Merge "liblog: optimize code hotspot"
Oct 5, 2015
be162cf
am 72146b93: Merge "logd: Add LogUtils.h"
Oct 5, 2015
2b5f97c
am 88e01661: Merge "logd: optimize code hotspots"
Oct 5, 2015
f469768
am bd4f52b2: Merge "liblog: optimize code hotspot"
Oct 5, 2015
758058f
logd: object layer format statistics
Aug 21, 2015
a5b40d0
metricsd: Don't cache the metrics status in the daemon.
bsimonnet Oct 2, 2015
d7aea44
property_service: log pid,uid and gid of setprop client
Oct 1, 2015
8a69e03
Merge "Speed up adb sync."
enh-google Oct 5, 2015
8c47bb5
am 8a69e031: Merge "Speed up adb sync."
enh-google Oct 5, 2015
fcaef68
Merge "metricsd: Don't cache the metrics status in the daemon."
bsimonnet Oct 5, 2015
a4a479b
am fcaef687: Merge "metricsd: Don\'t cache the metrics status in the …
bsimonnet Oct 5, 2015
59890e2
metricsd: Expose the metrics status through weave.
bsimonnet Oct 2, 2015
d1f8e4d
Merge "metricsd: Expose the metrics status through weave."
bsimonnet Oct 6, 2015
4685739
debuggerd: audit pid, uid and gid on SE Linux denial
Oct 6, 2015
9812fc4
logcat: continue where we left off
Oct 6, 2015
7dc7827
metricsd: Rename build_target_id to product_id.
bsimonnet Oct 6, 2015
6dfef25
adb: keep file flags in fdevent_install.
yabinc Oct 6, 2015
7f9d4c9
Merge "adb: keep file flags in fdevent_install."
yabinc Oct 6, 2015
ca2a0bd
adbd: Add os descriptor support for adb.
Oct 5, 2015
58b136c
Merge "logcat: continue where we left off"
Oct 7, 2015
1591478
init.rc: mkdir /data/misc/update_engine 0700 root root
davidz25 Oct 7, 2015
9e45f20
Merge "metricsd: Rename build_target_id to product_id."
bsimonnet Oct 7, 2015
10bb4e5
Merge "init.rc: mkdir /data/misc/update_engine 0700 root root"
davidz25 Oct 7, 2015
8d28e19
Fix adb -d/-e error reporting.
enh-google Oct 7, 2015
1407b28
Merge "Fix adb -d/-e error reporting."
enh-google Oct 7, 2015
86eb38f
logd: clientHasLogCredentials false negatives
Sep 1, 2015
65fe251
Use const auto&/auto&& in adb.
enh-google Oct 7, 2015
603b8e5
logcat: do not exit buffer loop on error
Sep 16, 2015
de4bb9c
logd: update region lock after entry has passed to reader socket
Sep 16, 2015
c5dc970
logd: clear return and deal with busy if readers locked
Sep 16, 2015
2b25c66
logd: clearAll by UID speedup
Sep 16, 2015
e2b2996
fs_config.c: remove setuid from procrank
nickkral Oct 7, 2015
21f99c0
Merge "Use const auto&/auto&& in adb."
enh-google Oct 7, 2015
b3fbdf5
Merge "fs_config.c: remove setuid from procrank"
nickkral Oct 8, 2015
6db7cd7
crash_reporter: Support crashes from arbitrary users
Oct 6, 2015
df345a8
Merge changes Icc984f40,Ie4c46bc9,I0f238985,I63a729d2,I2b5900a2
Oct 8, 2015
23fe7be
Merge "crash_reporter: Support crashes from arbitrary users"
Oct 8, 2015
35f8963
metricsd: Update weave command APIs
Oct 9, 2015
246c18c
Switch fs_mgr_verity.c to C++.
enh-google Oct 9, 2015
1946d3b
init shouldn't call DumpState by default.
enh-google Oct 9, 2015
5579340
Merge "init shouldn't call DumpState by default."
enh-google Oct 9, 2015
aaad42f
logd: use coalesce instead of merge (cleanup)
Sep 30, 2015
a3ae129
Merge "metricsd: Update weave command APIs"
Oct 9, 2015
d28a535
init.rc: Disable sysrq from the keyboard
nickkral Oct 10, 2015
773fd3c
crash_reporter: Use the actual GID of the crashing process
Oct 10, 2015
9e27cab
Merge "init.rc: Disable sysrq from the keyboard"
nickkral Oct 10, 2015
82b02de
Update metrics to use weaved's client library
Oct 10, 2015
4b2d6dd
Merge "crash_reporter: Use the actual GID of the crashing process"
Oct 10, 2015
2fb90dc
Merge changes from topic 'userspace-audit'
nickkral Oct 10, 2015
aa265b6
crash_reporter: Report the bdk_version
Oct 11, 2015
0cb59c0
system/core: fix iterator for LruCache
Oct 2, 2015
5117e41
Merge "Update metrics to use weaved's client library"
Oct 12, 2015
1c04253
Merge "logd: object layer format statistics"
Oct 12, 2015
f837660
Merge "system/core: fix iterator for LruCache"
Oct 13, 2015
73bf853
Merge "Switch fs_mgr_verity.c to C++."
enh-google Oct 13, 2015
67b3cad
Switch to android::base::ReadFully
jredestig Oct 8, 2015
2154e42
Merge "Switch to android::base::ReadFully"
enh-google Oct 13, 2015
3de3a0f
Error correction: Use libfec in fs_mgr
samitolvanen May 22, 2015
9b3a278
Merge "logd: use coalesce instead of merge (cleanup)"
Oct 13, 2015
af090a6
fix misuse of formatting specifiers
thestinger Oct 13, 2015
58b8be8
logd: correct for number of elements in prune
Sep 30, 2015
4f11a40
Merge "crash_reporter: Report the bdk_version"
Oct 13, 2015
cee4473
Merge "logd: correct for number of elements in prune"
Oct 13, 2015
74dc624
system/core: Rename "chromeos" -> "brillo" in include paths and names…
Oct 13, 2015
7d85a6a
Merge "system/core: Rename "chromeos" -> "brillo" in include paths an…
Oct 13, 2015
72e3c82
crash_reporter: Update to use the os-release.d configs
Oct 13, 2015
a2cfddd
Merge "Error correction: Use libfec in fs_mgr"
samitolvanen Oct 14, 2015
ba00051
Merge "adbd: Add os descriptor support for adb."
Oct 14, 2015
0923453
Revert "Error correction: Use libfec in fs_mgr"
samitolvanen Oct 14, 2015
4bd3148
Merge "Revert "Error correction: Use libfec in fs_mgr""
samitolvanen Oct 14, 2015
634df89
Make allocations use unique_ptr.
cferris1000 Oct 14, 2015
7d69175
Merge "Make allocations use unique_ptr."
cferris1000 Oct 14, 2015
99e3a92
Error correction: Use libfec in fs_mgr
samitolvanen May 22, 2015
fcc9358
Merge "crash_reporter: Update to use the os-release.d configs"
Oct 14, 2015
eb697ab
metricsd: Read build time values from etc/os-release.d.
bsimonnet Oct 14, 2015
defbd39
Merge "metricsd: Read build time values from etc/os-release.d."
bsimonnet Oct 15, 2015
0d6cdfb
Update crash_reporter and metrics rc files to trigger on post-fs-data
Oct 14, 2015
aeca97b
logd: use libpackageparser
Jul 31, 2015
51bdc5b
Merge "Update crash_reporter and metrics rc files to trigger on post-…
Oct 15, 2015
1ed57f0
adb: non-interactive shell stdin.
dpursell Oct 6, 2015
ca0d66d
Merge "adb: non-interactive shell stdin."
dpursell Oct 15, 2015
ad4ad8c
Implement ZipWriter for quickly writing ZipFiles.
Oct 6, 2015
b8cc70a
Merge "Error correction: Use libfec in fs_mgr"
samitolvanen Oct 16, 2015
5683366
crash_reporter: Use os-release.d to store the crash server url
Oct 16, 2015
7cba9db
libbinderwrapper: Add GetCallingUid() and GetCallingPid().
Oct 16, 2015
3947737
Merge "Implement ZipWriter for quickly writing ZipFiles."
Oct 16, 2015
2218720
Merge "crash_reporter: Use os-release.d to store the crash server url"
Oct 16, 2015
4d7591b
Merge "fix misuse of formatting specifiers"
enh-google Oct 16, 2015
fb371d6
Merge "libbinderwrapper: Add GetCallingUid() and GetCallingPid()."
Oct 16, 2015
0a79600
adb: win32: Improve Winsock error code mappings and strings
CompareAndSwap Oct 18, 2015
c249293
Merge "adb: win32: Improve Winsock error code mappings and strings"
enh-google Oct 19, 2015
8ad8076
adb: use libfec in disable-verity
samitolvanen Oct 20, 2015
ed38714
Merge "adb: use libfec in disable-verity"
samitolvanen Oct 20, 2015
cb31b1d
crash_reporter: add missing mkdir for crash_server rule
vapier Oct 20, 2015
0a85d04
Merge "crash_reporter: add missing mkdir for crash_server rule"
vapier Oct 20, 2015
591fd39
Add deflate compression to ZipWriter
Oct 6, 2015
044c790
ZipWriter: archive disk numbers are 0 index based
Oct 20, 2015
c96de0d
Fix lseek argument order.
enh-google Oct 20, 2015
5654360
Merge "Fix lseek argument order."
enh-google Oct 20, 2015
f21f0f1
Fix parameter to lseek
Oct 20, 2015
4a8d125
Merge "Fix parameter to lseek"
enh-google Oct 20, 2015
cd6b53f
Fix some compiler warnings in libpixelflinger.
enh-google Oct 22, 2015
13c19e7
Disable sanitization for LinearTransform
xt0032rus Oct 21, 2015
c52b3c0
Merge "Disable sanitization for LinearTransform"
xt0032rus Oct 22, 2015
30622bb
Remove __DATE__/__TIME__ from init and debuggerd
danw Oct 22, 2015
512b0e6
Merge "Remove __DATE__/__TIME__ from init and debuggerd"
danw Oct 22, 2015
5643f80
Merge "Fix some compiler warnings in libpixelflinger."
enh-google Oct 22, 2015
bd2d961
init/adb: correct static lib dependencies for libselinux
Aug 4, 2015
e509980
sdcard: use libpackageparser
Jul 31, 2015
8906560
Merge "logd: use libpackageparser"
Oct 22, 2015
e269364
Merge "sdcard: use libpackageparser"
Oct 22, 2015
38aee48
Merge "init/adb: correct static lib dependencies for libselinux"
Oct 22, 2015
438eb75
system/core: add libpackagelistparser
agampe Oct 23, 2015
f5852ce
Logd: Fix missing include of rc file
agampe Oct 23, 2015
054c099
Merge "Logd: Fix missing include of rc file"
agampe Oct 23, 2015
77e4677
Merge "system/core: add libpackagelistparser"
agampe Oct 23, 2015
82a6c84
Don't use libstdc++.
DanAlbert Oct 23, 2015
f4e2045
Merge "Don't use libstdc++."
DanAlbert Oct 23, 2015
cca6019
Lose df to toybox.
enh-google Oct 23, 2015
0fd0946
Merge "Lose df to toybox."
enh-google Oct 23, 2015
f3009f2
Disable container overflow detect on target.
eugenis Oct 23, 2015
151e497
Merge "Disable container overflow detect on target."
eugenis Oct 23, 2015
8dcdb57
adb: Mask SIGTTIN so that I/O works when backgrounded.
jmgao Oct 23, 2015
69ccb95
Merge "adb: Mask SIGTTIN so that I/O works when backgrounded."
jmgao Oct 24, 2015
8b43c3e
Fix adb sync/pull/push error reporting.
enh-google Oct 24, 2015
b42e7e8
Merge "Fix adb sync/pull/push error reporting."
enh-google Oct 26, 2015
08a2709
adb: fix -Tt options to match ssh.
dpursell Oct 20, 2015
76e9236
Merge "adb: fix -Tt options to match ssh."
dpursell Oct 27, 2015
26aef37
core: Rename libchromeos into libbrillo
Oct 27, 2015
918b936
crash_sender: Properly handle curl errors
Oct 27, 2015
270f508
crash_reporter: Make report log more useful
Oct 20, 2015
ef3c85a
Merge "crash_sender: Properly handle curl errors"
Oct 27, 2015
f741617
Merge "crash_reporter: Make report log more useful"
Oct 27, 2015
6d92997
Don't use VLAs in adb.
enh-google Oct 27, 2015
6ac83e4
Merge "core: Rename libchromeos into libbrillo"
Oct 27, 2015
2470439
Merge "Don't use VLAs in adb."
enh-google Oct 27, 2015
d69089a
Teach sp<> how to std::move
jreck Oct 28, 2015
faa566d
Use GetBuildTime from libchrome instead of __DATE__
danw Oct 29, 2015
4d18ae9
Merge "Use GetBuildTime from libchrome instead of __DATE__"
danw Oct 29, 2015
4cbed02
liblog: logcat: add epoch and monotonic format modifiers
Aug 31, 2015
500afc7
liblog: add android_log_timestamp() private function
Sep 8, 2015
bb51fbc
Merge changes Iefbea3b1,Ieb924b6d
Oct 29, 2015
0e99a2f
libziparchive: fix calculation of mod_time.
beonit Jul 17, 2015
b57cd14
Merge "libziparchive: fix calculation of mod_time."
narayank Oct 30, 2015
25b230c
fs_mgr: set partition.*.verified property even without state
samitolvanen Oct 30, 2015
b093cda
Merge "fs_mgr: set partition.*.verified property even without state"
samitolvanen Oct 30, 2015
ac60abd
Merge "Add deflate compression to ZipWriter"
Oct 30, 2015
25322ee
Merge "ZipWriter: archive disk numbers are 0 index based"
Oct 30, 2015
2fd45a9
fastboot shouldn't erase non-existent cache partitions.
enh-google Oct 30, 2015
b708d16
Show transfer progress in adb sync/pull/push.
enh-google Oct 27, 2015
9ebdf72
Merge "fastboot shouldn't erase non-existent cache partitions."
enh-google Oct 30, 2015
26352bf
Merge "Show transfer progress in adb sync/pull/push."
enh-google Oct 30, 2015
e6b96d6
metricsd: Report the model manifest id.
bsimonnet Oct 30, 2015
932f7ac
logd: Add support for *.logd.filter
Aug 28, 2015
c723df8
logd: statistics report chatty effective percentage
Aug 24, 2015
95ec339
Merge "logd: Add support for *.logd.filter"
Oct 30, 2015
d2c8cf8
Merge "logd: statistics report chatty effective percentage"
Oct 30, 2015
5dc119a
Remove the name filtering from toolbox ps.
enh-google Oct 30, 2015
9d1636b
Merge "Remove the name filtering from toolbox ps."
enh-google Oct 30, 2015
d2e26c0
Fix ps -Z so it combines with other arguments.
enh-google Oct 30, 2015
dd48ffe
Merge "Fix ps -Z so it combines with other arguments."
enh-google Oct 30, 2015
351ecd1
adb: fix adb client running out of sockets on Windows
CompareAndSwap Oct 15, 2015
1e2382a
Merge "adb: fix adb client running out of sockets on Windows"
enh-google Oct 30, 2015
4a13972
adb: use correct _WIN32 macro.
jmgao Oct 31, 2015
5510c13
libcutils: Make /data/nativetest{,64}/* executable.
Oct 28, 2015
00617fb
Merge "libcutils: Make /data/nativetest{,64}/* executable."
Nov 2, 2015
3ab0586
Fix ParseInt/ParseUint to handle explicit "0x" hex.
enh-google Nov 2, 2015
ddf5eda
Merge "Fix ParseInt/ParseUint to handle explicit "0x" hex."
enh-google Nov 2, 2015
fbfa840
adb: run reverse_service() in main thread.
yabinc Oct 31, 2015
5c75b52
Merge "adb: use correct _WIN32 macro."
jmgao Nov 2, 2015
5345f1d
Make Join support string delimiters
sadmac7000 Oct 31, 2015
46776e7
Merge "Make Join support string delimiters"
sadmac7000 Nov 2, 2015
52b5915
rootdir: Allow board specific folders and symlinks in root directory
drosen-google Oct 28, 2015
0578677
adb: allow multiple args to push/pull.
jmgao Oct 30, 2015
605f2f0
Merge "metricsd: Report the model manifest id."
bsimonnet Nov 2, 2015
1060739
Merge "adb: run reverse_service() in main thread."
yabinc Nov 2, 2015
518d043
Merge "Teach sp<> how to std::move"
jreck Nov 2, 2015
fbe4332
Set HOME, LOGNAME, SHELL, and USER from adbd.
enh-google Nov 2, 2015
6e699df
Merge "rootdir: Allow board specific folders and symlinks in root dir…
drosen-google Nov 2, 2015
36d7af4
Merge "Set HOME, LOGNAME, SHELL, and USER from adbd."
enh-google Nov 2, 2015
8ab9a32
Clarify and fix the intent of the partition-type checking code.
enh-google Nov 2, 2015
d0f45aa
Merge "Clarify and fix the intent of the partition-type checking code."
enh-google Nov 2, 2015
77c0e66
Work around an angler bootloader bug.
enh-google Nov 2, 2015
9eab787
Merge "Work around an angler bootloader bug."
enh-google Nov 3, 2015
c5b8ad8
adb: create unix_isatty() function.
dpursell Oct 28, 2015
d9ff987
Merge "adb: create unix_isatty() function."
dpursell Nov 3, 2015
983c41c
adb: add SyncConnection::Printf.
jmgao Nov 3, 2015
e9af735
Merge "adb: add SyncConnection::Printf."
jmgao Nov 3, 2015
587ea20
adb: fix adb reverse --no-rebind help text
CompareAndSwap Nov 3, 2015
fe54c96
Merge "adb: allow multiple args to push/pull."
jmgao Nov 3, 2015
4f23917
Merge "adb: fix adb reverse --no-rebind help text"
enh-google Nov 3, 2015
42da572
adb: temporary fix to limit USB transfers to 4KB.
dpursell Oct 15, 2015
664571e
Populate BRILLO_CRASH_SERVER from the product config
redpig Nov 5, 2015
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
*~
*.pyc
178 changes: 114 additions & 64 deletions adb/Android.mk
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,25 @@

LOCAL_PATH:= $(call my-dir)

ifeq ($(HOST_OS),windows)
adb_host_clang := false # libc++ for mingw not ready yet.
else
adb_host_clang := true
endif
adb_host_sanitize :=
adb_target_sanitize :=

adb_version := $(shell git -C $(LOCAL_PATH) rev-parse --short=12 HEAD 2>/dev/null)-android

ADB_COMMON_CFLAGS := \
-Wall -Werror \
-Wall -Wextra -Werror \
-Wno-unused-parameter \
-Wno-missing-field-initializers \
-Wvla \
-DADB_REVISION='"$(adb_version)"' \

# Define windows.h and tchar.h Unicode preprocessor symbols so that
# CreateFile(), _tfopen(), etc. map to versions that take wchar_t*, breaking the
# build if you accidentally pass char*. Fix by calling like:
# CreateFileW(widen(utf8).c_str()).
ADB_COMMON_windows_CFLAGS := \
-DUNICODE=1 -D_UNICODE=1 \

# libadb
# =========================================================

Expand All @@ -32,6 +38,7 @@ LIBADB_SRC_FILES := \
adb_auth.cpp \
adb_io.cpp \
adb_listeners.cpp \
adb_trace.cpp \
adb_utils.cpp \
sockets.cpp \
transport.cpp \
Expand All @@ -45,9 +52,14 @@ LIBADB_TEST_SRCS := \

LIBADB_CFLAGS := \
$(ADB_COMMON_CFLAGS) \
-Wno-missing-field-initializers \
-fvisibility=hidden \

LIBADB_linux_CFLAGS := \
-std=c++14 \

LIBADB_windows_CFLAGS := \
$(ADB_COMMON_windows_CFLAGS) \

LIBADB_darwin_SRC_FILES := \
fdevent.cpp \
get_my_path_darwin.cpp \
Expand All @@ -59,10 +71,20 @@ LIBADB_linux_SRC_FILES := \
usb_linux.cpp \

LIBADB_windows_SRC_FILES := \
get_my_path_windows.cpp \
sysdeps_win32.cpp \
usb_windows.cpp \

LIBADB_TEST_linux_SRCS := \
fdevent_test.cpp \
socket_test.cpp \

LIBADB_TEST_darwin_SRCS := \
fdevent_test.cpp \
socket_test.cpp \

LIBADB_TEST_windows_SRCS := \
sysdeps_win32_test.cpp \

include $(CLEAR_VARS)
LOCAL_CLANG := true
LOCAL_MODULE := libadbd
Expand All @@ -72,61 +94,89 @@ LOCAL_SRC_FILES := \
adb_auth_client.cpp \
fdevent.cpp \
jdwp_service.cpp \
qemu_tracing.cpp \
usb_linux_client.cpp \

LOCAL_SHARED_LIBRARIES := libbase
LOCAL_SANITIZE := $(adb_target_sanitize)

# Even though we're building a static library (and thus there's no link step for
# this to take effect), this adds the includes to our path.
LOCAL_STATIC_LIBRARIES := libbase

include $(BUILD_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_CLANG := $(adb_host_clang)
LOCAL_MODULE := libadb
LOCAL_MODULE_HOST_OS := darwin linux windows
LOCAL_CFLAGS := $(LIBADB_CFLAGS) -DADB_HOST=1
LOCAL_CFLAGS_windows := $(LIBADB_windows_CFLAGS)
LOCAL_CFLAGS_linux := $(LIBADB_linux_CFLAGS)
LOCAL_SRC_FILES := \
$(LIBADB_SRC_FILES) \
$(LIBADB_$(HOST_OS)_SRC_FILES) \
adb_auth_host.cpp \

LOCAL_SHARED_LIBRARIES := libbase
LOCAL_SRC_FILES_darwin := $(LIBADB_darwin_SRC_FILES)
LOCAL_SRC_FILES_linux := $(LIBADB_linux_SRC_FILES)
LOCAL_SRC_FILES_windows := $(LIBADB_windows_SRC_FILES)

LOCAL_SANITIZE := $(adb_host_sanitize)

# Even though we're building a static library (and thus there's no link step for
# this to take effect), this adds the SSL includes to our path.
LOCAL_STATIC_LIBRARIES := libcrypto_static
# this to take effect), this adds the includes to our path.
LOCAL_STATIC_LIBRARIES := libcrypto_static libbase

ifeq ($(HOST_OS),windows)
LOCAL_C_INCLUDES += development/host/windows/usb/api/
endif
LOCAL_C_INCLUDES_windows := development/host/windows/usb/api/
LOCAL_MULTILIB := first

include $(BUILD_HOST_STATIC_LIBRARY)

include $(CLEAR_VARS)
LOCAL_CLANG := true
LOCAL_MODULE := adbd_test
LOCAL_CFLAGS := -DADB_HOST=0 $(LIBADB_CFLAGS)
LOCAL_SRC_FILES := $(LIBADB_TEST_SRCS)
LOCAL_SRC_FILES := \
$(LIBADB_TEST_SRCS) \
$(LIBADB_TEST_linux_SRCS) \
shell_service.cpp \
shell_service_protocol.cpp \
shell_service_protocol_test.cpp \
shell_service_test.cpp \

LOCAL_SANITIZE := $(adb_target_sanitize)
LOCAL_STATIC_LIBRARIES := libadbd
LOCAL_SHARED_LIBRARIES := liblog libbase libcutils
LOCAL_SHARED_LIBRARIES := libbase libcutils
include $(BUILD_NATIVE_TEST)

# adb_test
# =========================================================

include $(CLEAR_VARS)
LOCAL_CLANG := $(adb_host_clang)
LOCAL_MODULE := adb_test
LOCAL_MODULE_HOST_OS := darwin linux windows
LOCAL_CFLAGS := -DADB_HOST=1 $(LIBADB_CFLAGS)
LOCAL_SRC_FILES := $(LIBADB_TEST_SRCS) services.cpp
LOCAL_SHARED_LIBRARIES := liblog libbase
LOCAL_CFLAGS_windows := $(LIBADB_windows_CFLAGS)
LOCAL_CFLAGS_linux := $(LIBADB_linux_CFLAGS)
LOCAL_SRC_FILES := \
$(LIBADB_TEST_SRCS) \
services.cpp \
shell_service_protocol.cpp \
shell_service_protocol_test.cpp \

LOCAL_SRC_FILES_linux := $(LIBADB_TEST_linux_SRCS)
LOCAL_SRC_FILES_darwin := $(LIBADB_TEST_darwin_SRCS)
LOCAL_SRC_FILES_windows := $(LIBADB_TEST_windows_SRCS)
LOCAL_SANITIZE := $(adb_host_sanitize)
LOCAL_SHARED_LIBRARIES := libbase
LOCAL_STATIC_LIBRARIES := \
libadb \
libcrypto_static \
libcutils \

ifeq ($(HOST_OS),linux)
LOCAL_LDLIBS += -lrt -ldl -lpthread
endif

ifeq ($(HOST_OS),darwin)
LOCAL_LDLIBS += -framework CoreFoundation -framework IOKit
endif
# Set entrypoint to wmain from sysdeps_win32.cpp instead of main
LOCAL_LDFLAGS_windows := -municode
LOCAL_LDLIBS_linux := -lrt -ldl -lpthread
LOCAL_LDLIBS_darwin := -framework CoreFoundation -framework IOKit
LOCAL_LDLIBS_windows := -lws2_32 -luserenv
LOCAL_STATIC_LIBRARIES_windows := AdbWinApi

include $(BUILD_HOST_NATIVE_TEST)

Expand All @@ -135,11 +185,13 @@ include $(BUILD_HOST_NATIVE_TEST)

ifeq ($(HOST_OS),linux)
include $(CLEAR_VARS)
LOCAL_CLANG := $(adb_host_clang)
LOCAL_MODULE := adb_device_tracker_test
LOCAL_CFLAGS := -DADB_HOST=1 $(LIBADB_CFLAGS)
LOCAL_CFLAGS_windows := $(LIBADB_windows_CFLAGS)
LOCAL_CFLAGS_linux := $(LIBADB_linux_CFLAGS)
LOCAL_SRC_FILES := test_track_devices.cpp
LOCAL_SHARED_LIBRARIES := liblog libbase
LOCAL_SANITIZE := $(adb_host_sanitize)
LOCAL_SHARED_LIBRARIES := libbase
LOCAL_STATIC_LIBRARIES := libadb libcrypto_static libcutils
LOCAL_LDLIBS += -lrt -ldl -lpthread
include $(BUILD_HOST_EXECUTABLE)
Expand All @@ -149,51 +201,48 @@ endif
# =========================================================
include $(CLEAR_VARS)

ifeq ($(HOST_OS),linux)
LOCAL_LDLIBS += -lrt -ldl -lpthread
LOCAL_CFLAGS += -DWORKAROUND_BUG6558362
endif
LOCAL_LDLIBS_linux := -lrt -ldl -lpthread

ifeq ($(HOST_OS),darwin)
LOCAL_LDLIBS += -lpthread -framework CoreFoundation -framework IOKit -framework Carbon
LOCAL_CFLAGS += -Wno-sizeof-pointer-memaccess -Wno-unused-parameter
endif

ifeq ($(HOST_OS),windows)
LOCAL_LDLIBS += -lws2_32 -lgdi32
EXTRA_STATIC_LIBS := AdbWinApi
endif
LOCAL_LDLIBS_darwin := -lpthread -framework CoreFoundation -framework IOKit -framework Carbon
LOCAL_CFLAGS_darwin := -Wno-sizeof-pointer-memaccess -Wno-unused-parameter

LOCAL_CLANG := $(adb_host_clang)
# Use wmain instead of main
LOCAL_LDFLAGS_windows := -municode
LOCAL_LDLIBS_windows := -lws2_32 -lgdi32
LOCAL_STATIC_LIBRARIES_windows := AdbWinApi
LOCAL_REQUIRED_MODULES_windows := AdbWinApi AdbWinUsbApi

LOCAL_SRC_FILES := \
adb_main.cpp \
adb_client.cpp \
client/main.cpp \
console.cpp \
commandline.cpp \
adb_client.cpp \
services.cpp \
file_sync_client.cpp \
line_printer.cpp \
services.cpp \
shell_service_protocol.cpp \

LOCAL_CFLAGS += \
$(ADB_COMMON_CFLAGS) \
-D_GNU_SOURCE \
-DADB_HOST=1 \

LOCAL_CFLAGS_windows := \
$(ADB_COMMON_windows_CFLAGS)

LOCAL_MODULE := adb
LOCAL_MODULE_TAGS := debug
LOCAL_MODULE_HOST_OS := darwin linux windows

LOCAL_SANITIZE := $(adb_host_sanitize)
LOCAL_STATIC_LIBRARIES := \
libadb \
libbase \
libcrypto_static \
libcutils \
liblog \
$(EXTRA_STATIC_LIBS) \

# libc++ not available on windows yet
ifneq ($(HOST_OS),windows)
LOCAL_CXX_STL := libc++_static
endif
LOCAL_CXX_STL := libc++_static

# Don't add anything here, we don't want additional shared dependencies
# on the host adb tool, and shared libraries that link against libc++
Expand All @@ -204,12 +253,6 @@ include $(BUILD_HOST_EXECUTABLE)

$(call dist-for-goals,dist_files sdk,$(LOCAL_BUILT_MODULE))

ifeq ($(HOST_OS),windows)
$(LOCAL_INSTALLED_MODULE): \
$(HOST_OUT_EXECUTABLES)/AdbWinApi.dll \
$(HOST_OUT_EXECUTABLES)/AdbWinUsbApi.dll
endif


# adbd device daemon
# =========================================================
Expand All @@ -219,12 +262,14 @@ include $(CLEAR_VARS)
LOCAL_CLANG := true

LOCAL_SRC_FILES := \
adb_main.cpp \
daemon/main.cpp \
services.cpp \
file_sync_service.cpp \
framebuffer_service.cpp \
remount_service.cpp \
set_verity_enable_state_service.cpp \
shell_service.cpp \
shell_service_protocol.cpp \

LOCAL_CFLAGS := \
$(ADB_COMMON_CFLAGS) \
Expand All @@ -246,15 +291,20 @@ LOCAL_MODULE_PATH := $(TARGET_ROOT_OUT_SBIN)
LOCAL_UNSTRIPPED_PATH := $(TARGET_ROOT_OUT_SBIN_UNSTRIPPED)
LOCAL_C_INCLUDES += system/extras/ext4_utils

LOCAL_SANITIZE := $(adb_target_sanitize)
LOCAL_STATIC_LIBRARIES := \
libadbd \
libbase \
libfs_mgr \
libfec \
libfec_rs \
libselinux \
liblog \
libcutils \
libc \
libmincrypt \
libselinux \
libext4_utils_static \
libsquashfs_utils \
libcutils \
libbase \
libcrypto_static

include $(BUILD_EXECUTABLE)
2 changes: 1 addition & 1 deletion adb/CPPLINT.cfg
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
set noparent
filter=-build/header_guard,-build/include,-readability/function
filter=-build/header_guard,-build/include,-readability/function,-whitespace/indent
2 changes: 1 addition & 1 deletion adb/SERVICES.TXT
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ track-jdwp
Note that there is no single-shot service to retrieve the list only once.

sync:
This starts the file synchronisation service, used to implement "adb push"
This starts the file synchronization service, used to implement "adb push"
and "adb pull". Since this service is pretty complex, it will be detailed
in a companion document named SYNC.TXT

Expand Down
17 changes: 7 additions & 10 deletions adb/SYNC.TXT
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,9 @@ follows as described in SERVICES.TXT.

The following sync requests are accepted:
LIST - List the files in a folder
RECV - Retrieve a file from device
SEND - Send a file to device
RECV - Retreive a file from device

Not yet documented:
STAT - Stat a file
ULNK - Unlink (remove) a file. (Not currently supported)

For all of the sync request above the must be followed by length number of
bytes containing an utf-8 string with a remote filename.
Expand All @@ -40,7 +37,7 @@ Lists files in the directory specified by the remote filename. The server will
respond with zero or more directory entries or "dents".

The directory entries will be returned in the following form
1. A four-byte sync response id beeing "DENT"
1. A four-byte sync response id "DENT"
2. A four-byte integer representing file mode.
3. A four-byte integer representing file size.
4. A four-byte integer representing last modified time.
Expand All @@ -60,13 +57,13 @@ the transfer fails. Some file types will not be deleted, which allows
adb push disk_image /some_block_device
to work.

After this the actual file is sent in chunks. Each chucks has the following
After this the actual file is sent in chunks. Each chunk has the following
format.
A sync request with id "DATA" and length equal to the chunk size. After
follows chunk size number of bytes. This is repeated until the file is
transfered. Each chunk must not be larger than 64k.
transferred. Each chunk must not be larger than 64k.

When the file is tranfered a sync request "DONE" is sent, where length is set
When the file is transferred a sync request "DONE" is sent, where length is set
to the last modified time for the file. The server responds to this last
request (but not to chuck requests) with an "OKAY" sync response (length can
be ignored).
Expand All @@ -77,8 +74,8 @@ Retrieves a file from device to a local file. The remote path is the path to
the file that will be returned. Just as for the SEND sync request the file
received is split up into chunks. The sync response id is "DATA" and length is
the chuck size. After follows chunk size number of bytes. This is repeated
until the file is transfered. Each chuck will not be larger than 64k.
until the file is transferred. Each chuck will not be larger than 64k.

When the file is transfered a sync resopnse "DONE" is retrieved where the
When the file is transferred a sync response "DONE" is retrieved where the
length can be ignored.

Loading