Keep in mind, the output is still not identical to upstream.
$ platform-tools_r26.0.0-linux/adb version
Android Debug Bridge version 1.0.39
Revision 3db08f2c6889-android
Installed as /tmp/platform-tools_r26.0.0-linux/adb
$ platform-tools_r26.0.0-linux/fastboot --version
fastboot version 3db08f2c6889-android
Installed as /tmp/platform-tools_r26.0.0-linux/fastboot
$ platform-tools_r27.0.0-linux/adb version
Android Debug Bridge version 1.0.39
Version 27.0.0-4455170
Installed as /tmp/platform-tools_r27.0.0-linux/adb
$ platform-tools_r27.0.0-linux/fastboot --version
fastboot version 27.0.0-4455170
Installed as /tmp/platform-tools_r27.0.0-linux/fastboot
$ adb version
Android Debug Bridge version 1.0.39
Version 27.0.0-0 86c2b588a369-android
Installed as /usr/local/bin/adb
$ fastboot --version
fastboot version 27.0.0-0 86c2b588a369-android
Installed as /usr/local/bin/fastboot
(via Mk/bsd.default-versions.mk and lang/gcc) which has moved from
GCC 5.4 to GCC 6.4 under most circumstances.
This includes ports
- with USE_GCC=yes or USE_GCC=any,
- with USES=fortran,
- using Mk/bsd.octave.mk which in turn features USES=fortran, and
- with USES=compiler specifying openmp, nestedfct, c++11-lib, c++11-lang,
c++14-lang, c++0x, c11, or gcc-c++11-lib.
PR: 219275
lang/gcc which have moved from GCC 4.9.4 to GCC 5.4 (at least under some
circumstances such as versions of FreeBSD or platforms).
This includes ports
- with USE_GCC=yes or USE_GCC=any,
- with USES=fortran,
- using using Mk/bsd.octave.mk which in turn has USES=fortran, and
- with USES=compiler specifying openmp, nestedfct, c++11-lib, c++14-lang,
c++11-lang, c++0x, c11, or gcc-c++11-lib.
PR: 216707
LICENSE= PD
Note that although Public Domain is not technically a license, it's
handled in the same way as licenses here, which is a common practice
(Arch, Gentoo, Fedora, Debian, even FOSSology do the same).
Convert all ports which redefine Public Domain LICENSE to LICENSE=PD.
Approved by: portmgr (bapt)
Differential Revision: D4149
- Try to derive {ADB,FASTBOOT}_REVISION from git(1)
- Use pkg-config for libcrypto/libpcre/libusb (e.g. if they aren't in base)
- Convert PORTDOCS into FILES (bsd.port.mk vs. bsd.prog.mk)
- Partially convert to new testing framework
- Put -lpthread last as enforced by base r274849 but prevent
:= assignment from mucking $ escaping in $()
- |make clean| to clean files built by test target
- Move up bsd.prog.mk in order to use ${PROG} and ${OBJS} defined in it
Copy files in order to fix the following errors.
files/usb_freebsd.cpp:132:4: error: assigning to 'usb_handle *' from incompatible type 'void *'
h = malloc(sizeof(*h));
^ ~~~~~~~~~~~~~~~~~~
files/usb_freebsd.cpp:162:6: error: no matching function for call to 'libusb_bulk_transfer'
if (libusb_bulk_transfer(h->handle, h->ep_out, (void *)(long)_data, len, &actlen, 0) < 0)
^~~~~~~~~~~~~~~~~~~~
/usr/include/libusb.h:478:5: note: candidate function not viable: cannot convert argument of incomplete type 'void *' to 'uint8_t *' (aka 'unsigned char *')
int libusb_bulk_transfer(libusb_device_handle * devh, uint8_t endpoint, uint8_t *data, int length, int *transferred, uint32_t timeout);
^
files/usb_freebsd.cpp:172:6: error: no matching function for call to 'libusb_bulk_transfer'
if (libusb_bulk_transfer(h->handle, h->ep_in, _data, len, &actlen, 0) < 0)
^~~~~~~~~~~~~~~~~~~~
/usr/include/libusb.h:478:5: note: candidate function not viable: cannot convert argument of incomplete type 'void *' to 'uint8_t *' (aka 'unsigned char *')
int libusb_bulk_transfer(libusb_device_handle * devh, uint8_t endpoint, uint8_t *data, int length, int *transferred, uint32_t timeout);
^
3 errors generated.
fastboot.o: In function `find_item(char const*, char const*)':
fastboot.cpp:(.text+0xea): undefined reference to `get_my_path'
Avoid stepping into OS X platform code with off64_t workaround.
cc ... -D__APPLE__ -D__MACH__ .../ext4_utils/ext4_utils.c
In file included from .../ext4_utils/ext4_utils.c:43:0:
/usr/include/sys/disk.h:49:2: error: #error "This file should not be included by userland programs."
#error "This file should not be included by userland programs."
^
*** [ext4_utils.o] Error code 1
Reported by: DPorts
inb4 someone actually tests on NetBSD or OpenBSD...
files/usb_freebsd.c:57:2: error: must
use 'struct' tag to refer to type 'libusb_device_descriptor'
libusb_device_descriptor ddesc;
^
struct
files/usb_freebsd.c:58:2: error: must
use 'struct' tag to refer to type 'libusb_config_descriptor'
libusb_config_descriptor *pcfg;
^
struct
2 errors generated.
Tested by: md5
android.googlesource.com archives have volatile timestamps which makes
them impossible to use as distfiles due to varying checksum.
android organization on GitHub doesn't have platform/system/extras mirror.
And various private and non-vanilla clones seem to lack android-* tags
that are necessary to sync modules.
For now, use my own mirror to avoid local-distfiles and keep the port simple
via multi-GitHub support.