summaryrefslogtreecommitdiffstats
path: root/adb/Android.mk
Commit message (Collapse)AuthorAgeFilesLines
* Ignore ro.adb.secure in user builds.Elliott Hughes2015-06-191-3/+2
| | | | | | | | | | Require authorization by default, and remove the ability to override that in user builds. (userdebug and eng are still free to do whatever they want.) Bug: http://b/21862859 Change-Id: Ibf8af375be5bf1141c1ad481eee7a59fb10a7adb (cherry picked from commit 5cba504215ea91187cc36ec7aec5dce1b0f4b0fe)
* Include the git sha in the adb version.Dan Albert2015-05-061-6/+10
| | | | | | | Also add --version to adbd to display the same thing. Change-Id: I47dfbad16c892c42ea938aedd085ba77492791ba (cherry picked from commit 1ba1d7c1ee644967ff4743b0d257290cbeca7a83)
* More adb buffer fixes.Elliott Hughes2015-05-011-0/+15
| | | | | | | | | | | | | | This patch factors out a lot of the basic protocol code: sending OKAY, sending FAIL, and sending a length-prefixed string. ADB_TRACE has been non-optional for a long time, so let's just remove the #ifs. Also actually build the device tracker test tool (and remove its duplicate). Bug: http://b/20666660 Change-Id: I6c7d59f18707bdc62ca69dea45547617f9f31fc6 (cherry picked from commit e67f1f87d9b1188ec8617035db7006c37ee7b21e)
* Support the full length of USB serial numbers.Elliott Hughes2015-04-271-0/+1
| | | | | | | | | | | | Two bugs: we couldn't report the serial number correctly if it was long enough, and it wasn't possible to connect to a device whose serial number was long enough to overflow a different fixed-length buffer. Bug: http://b/20317730 (cherry picked from commit 9309ecbcec428edfcb487ef697862bce59a1aed5) Change-Id: I04c160a215418a57bd4fb27b7f63060c8be6f12e
* Merge "Always explain why bind(2) failed."Elliott Hughes2015-04-211-0/+4
|\
| * Always explain why bind(2) failed.Elliott Hughes2015-04-201-0/+4
| | | | | | | | | | | | | | This has confused several people lately. Bug: http://b/20219978 Change-Id: I2537ceb83bff0b3166c230c728d4389a983db858
* | Fix windows adb buildColin Cross2015-04-201-1/+4
| | | | | | | | | | | | | | libc++ is not available on windows yet, but it already defaults to static libstdc++. Change-Id: I85a766ead84f71fe1f2f59be6ac739b0b833b6db
* | Merge "statically link adb and fastboot against libc++"Colin Cross2015-04-201-0/+7
|\ \
| * | statically link adb and fastboot against libc++Colin Cross2015-04-161-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | libc++.so is not widely available on the host, so we compile against one built as part of the platform. This causes problems for adb and fastboot, which are distributed through a number of channels - the sdk, distro packages, downloaded from the build server, or manually copied. Instead of forcing all users to handle libc++.so too, statically link against libc++. Change-Id: I51b75258653a23558c8b598802005f6c1166a439
* | | Fix the Windows adb build.Elliott Hughes2015-04-191-20/+17
| |/ |/| | | | | | | | | | | | | | | | | It looks like we can't use clang on Windows yet because libc++ isn't ready. So move back to GCC for the Windows host clang. Work around the mingw printf format string problems that made us want to switch to clang in the first place, and #include "sysdeps.h" in adb_utils.cpp to work around the absence of lstat(2) on Windows. Change-Id: Icd0797a8c0c2d1d326bdd704ba6bcafcbaeb742f
* | Switch adb over to clang.Elliott Hughes2015-04-171-1/+1
| | | | | | | | Change-Id: Ib5511dcba56e80ffce6bc293d99251ccfd61c330
* | Fix more buffer overruns.Elliott Hughes2015-04-171-0/+2
| | | | | | | | | | | | | | Also add some tests. Bug: 20323050 Change-Id: I9eaf3dc04efd85206663c4cca4f8c1208620a89a
* | Remove various fixed-length buffers (and their overflows).Elliott Hughes2015-04-171-0/+1
| | | | | | | | | | | | | | | | | | | | Bug: 20323052 Bug: 20323051 Bug: 20317728 Bug: 20317727 Bug: 20317726 Bug: 20317725 Change-Id: I57a5e30a5b7867715f55cee7429aa36d7ce21484
* | Merge "Move usb_osx to C++."Dan Albert2015-04-171-1/+1
|\ \
| * | Move usb_osx to C++.Dan Albert2015-04-161-1/+1
| | | | | | | | | | | | Change-Id: I21673211a702cc4f31d4311c36e2a4b22e55fac8
* | | Merge "Link libraries needed for Darwin adb tests."Dan Albert2015-04-171-0/+4
|\ \ \ | |/ /
| * | Link libraries needed for Darwin adb tests.Dan Albert2015-04-161-0/+4
| | | | | | | | | | | | Change-Id: I1c3c3a7bbd3824f5f3a37ee80c24d1c2a9b98748
* | | Move sysdeps_win32 to C++.Elliott Hughes2015-04-161-1/+1
|/ / | | | | | | Change-Id: I27ca41b64d62bb3611b3a39a5c3bb4377d0773bc
* | Switch usb_linux_client to C++.Elliott Hughes2015-04-161-2/+2
| | | | | | | | Change-Id: I8172e81e6c4665aa16e9e8e0c33b048dbb9ad848
* | Move get_my_path_darwin to C++.Elliott Hughes2015-04-161-1/+1
|/ | | | | | As long as we have C in here, we can't use C++ in our headers. Change-Id: Ibccaa77a5af506dc504aa9c39c8dca5dcdbeccab
* Remove LOCAL_ADDITIONAL_DEPENDENCIES in cases where it's not needed.Elliott Hughes2015-04-021-3/+0
| | | | Change-Id: I720b8ef1050da45a7833adef8219b6acb2cf3a38
* adb: Add option to reboot into sideload mode in recoveryTao Bao2015-03-311-1/+2
| | | | | | | | | | | | | | | | Currently it requires manual key press to enter the sideload mode. This CL adds 'adb reboot sideload' to reboot the device into sideload mode directly with text display on. With 'adb reboot sideload-auto-reboot', it will reboot after the sideload regardless of the installation result, unless interrupted by user. Since it needs to write to /cache/recovery/command file, 'adb root' is required before calling 'adb reboot sideload' and the one with '-auto-reboot'. Also it requires the matching CL in bootable/recovery. Change-Id: Ib7bd4e216a1efc01e64460659c97c6005bbaec1b
* Revert "Revert "adb: support /oem partition""Elliott Hughes2015-03-161-1/+1
| | | | | | | | | | This reverts commit 6084a0124f868c7ec43f6c415a27a168f27ff694. The original build breakage is fixed by (a) building the verity code for eng builds as well as userdebug builds and (b) moving the exported remount service functions into a new header file. Change-Id: Ice0c4f97d4db38ab7eb333c7a6e56bbd11123f5b
* Revert "Revert "Create libbase.""Dan Albert2015-03-161-3/+2
| | | | This reverts commit a7870d88167f619e758b5bcd15b410d16da7c16b.
* Revert "Create libbase."Nicolas Geoffray2015-03-161-2/+3
| | | | | | | | Breaks internal master. This reverts commit 98ff77204cef9bb8f0f27420833233622060a09e. Change-Id: I18dc6021cb43efff8aa88486c2d980dc2b8eedba
* Create libbase.Dan Albert2015-03-141-3/+2
| | | | | | | Move StringPrintf and the string based file I/O from libutils to libbase. Change-Id: I0297a6063874b9d92100e0dd5123fddfbda932fe
* adb doesn't actually use libzipfile.Elliott Hughes2015-03-131-1/+0
| | | | Change-Id: Ia7d22214bc8422c88edaaf9bb716d7e12e0bb381
* Move adb to C++.Dan Albert2015-03-091-37/+44
| | | | | | | | | | | | | | | | | I keep trying to clean things up and needing std::strings. Might as well just do this now. usb_linux_client.c is going to stay as C because GCC isn't smart enough to deal with the designated initializers it uses (though for some reason it is in C mode). The Darwin files are staying as C because I don't have a way to test that they build. The Windows files are staying as C because while I can actually build for them, it's slow and painful. Change-Id: I75367d29205a9049d34460032b3bb36384f43941
* Test readx/writex (now renamed).Dan Albert2015-02-251-1/+5
| | | | | | | | | | | | | | Renamed readx/writex to ReadFdExactly/WriteFdExactly respectively. These read/write a full fixed-size buffer. If the whole buffer cannot be read/written, these functions return an error. Rename write_string to WriteStringFully. Move the TEMP_FAILURE_RETRY definition in sysdeps.h out of the !Windows section. It seems Windows won't actually interrupt a call, but it's easier to just define it than to #ifdef each call. Change-Id: Ia8ddffa2a52764a2f9a281c96c937660e002b9b9
* Remove _(GNU|XOPEN)_SOURCE makefile cruft.Dan Albert2015-02-251-4/+6
| | | | | | None of the functions that require these are used. Change-Id: I10cffab127795b94340131f8737f7924b9138f9e
* Add some basic tests to adb.Dan Albert2015-02-251-1/+31
| | | | Change-Id: I946b5b1e5650540db3b4f75892214c4218b3baf3
* Add a project wide clang switch.Dan Albert2015-02-241-0/+8
| | | | | | | I'll probably make this the default soon, but I'm not brave enough to do that without checking the recovery image first. Change-Id: I9cde687b08a588e3797645a308f381e4ec553447
* Fix Mac build.Dan Albert2015-02-241-1/+1
| | | | | | | | | Prior to https://android-review.googlesource.com/#/c/134253/ the makefile had assumed !Windows was the same as Linux, so the Mac was actually getting all the Linux sources as well. I mistakenly didn't add fdevent.cpp to the Darwin sources in that change. Change-Id: I4e12a394e9a2baf7c1e3c711a01a6b5fccbf79d9
* Fix Windows SDK build.Dan Albert2015-02-241-1/+4
| | | | Change-Id: I9c0f9c92c28867ff17f1ec83aac935d18348c335
* Move more into libadb and libadbd.Dan Albert2015-02-201-23/+6
| | | | | | | None of this needs to be shared with minadbd, but these sources are still needed for anything linking libadb (such as tests). Change-Id: I3024f714da42364bf27a991986f00676e2bbbf2c
* Oops. Fix make variable name. Thanks again, make.Dan Albert2015-02-201-2/+2
| | | | Change-Id: Iecbb41acc835bb8eb20b668c89a3ff065470fcb7
* Lose adb.c and sockets.c to libadb.Dan Albert2015-02-191-13/+11
| | | | | | | | Also kill the device side libadb. This was added for the now dead device side adb, and is no longer used. Bug: 17626262 Change-Id: I3b28915641fd5b4f16fc86cf1f4f4e9711093001
* Move adb_main to its own file.Dan Albert2015-02-181-0/+2
| | | | Change-Id: If6e98c089b39f73bd8f4a878a82669bfeee367f3
* Move the listener code into its own file.Dan Albert2015-02-181-0/+1
| | | | Change-Id: I7332455ed1a213daedeaa4a81260edf08b2fd131
* Move the adb auth code into its own file.Dan Albert2015-02-181-2/+9
| | | | Change-Id: I84cf0bd7777f0147119e7c6afc4096c2e93156a2
* Move emulator tracing into its own file.Dan Albert2015-02-181-1/+6
| | | | | | adb.c is far too monolithic. Change-Id: I4a9ee97927e4a96a38ea5859d84efac86bfdfc35
* Move USB transport code to libadb.Dan Albert2015-02-181-10/+15
| | | | | | | | Also note that we need both a libadb and a libadbd (for now) to differentiate between code using ADB_HOST=1 and ADB_HOST=0. Bug: 17626262 Change-Id: I873a8fb442a8a69258fe39af17781714a8fae4f6
* The bsddroid project has been dead since 2010.Elliott Hughes2015-01-311-6/+0
| | | | | | | And even if it wasn't, they should probably keep this stuff in their own repository. Change-Id: If9fa2e47ee2700098d8a99f6986f7e89fc6dfdf3
* Merge "Fix userdebug build."Dan Albert2015-01-271-0/+3
|\
| * Fix userdebug build.Dan Albert2015-01-261-0/+3
| | | | | | | | | | | | | | | | Apparently this code I thought was unused is just unused for eng builds... Bug: 17626262 Change-Id: I2e5f411a2ead7f23d9f5822935de66c992750a03
* | Fix win_sdk build.Dan Albert2015-01-261-42/+1
|/ | | | | | | | Hadn't caught this in the previous submission because I tested the build with another change on top of it that also fixes this. Bug: 17626262 Change-Id: Ia40127618a5466e382081760d614ff7fc09d50a3
* Begin moving code from adb to libadb.Dan Albert2015-01-261-18/+44
| | | | | | | | | | | | | Much of adb is duplicated in bootable/recovery/minadb and fastboot. Changes made to adb rarely get ported to the other two, so the trees have diverged a bit. We'd like to stop this because it is a maintenance nightmare, but the divergence makes this difficult to do all at once. For now, we will start small by moving common files into a static library. Hopefully some day we can get enough of adb in here that we no longer need minadb. Bug: 17626262 Change-Id: Ic8d5653bfcc0fec4e1acbece124402355084b864
* Add adb enable-verityPaul Lawrence2014-12-091-1/+1
| | | | | | | | | | | Note that it is *easy* to break your phone with this feature. It is not a bug that reenabling verity after changing one byte of the system partition stops the device booting. (cherry-pick of 7c442e1700e6312727283db402dec6f666f1b55a.) Bug: 18529433 Change-Id: I632e91281884471a362960f1ba30312d2669b8ff
* Revert "Revert "Enable verity on userdebug, and add disable-verity to adb""Paul Lawrence2014-12-091-1/+15
| | | | | | | | | | | This reverts commit 152d2d4234ba89e0c20c4af13e291b6049a7bc33. Fixed build error, and also fixed memory leak spotted from warning. (cherry-pick of bbb36319119edde9377fb80015235893c30d2bc9.) Bug: 17691572 Change-Id: I23b5ba537f7b557432041d4338b38b9be434e981
* Clean up adb/Android.mkTrevor Drake2014-12-071-6/+2
| | | | | | | Removed redundant LOCAL_C_INCLUDES. Switch from using libunz to libz Change-Id: Ic90c582fa56453bbac09561158e73f240dd47503