android: Fix usage of PATH_MAX

PATH_MAX already contains the terminating null so there's no need to +1
to it.
profiles/input: Fix usage of PATH_MAX

PATH_MAX already contains the terminating null so there's no need to +1
to it. Also, snprintf guarantees a null-terminated string so there's no
need to explicitly set a terminating character after the call.
core: Fix filename/dirname usage & shadowing
core: Refactor dirent type getter to a shared function
android/gatt: Add support for GATT over BR/EDR

This adds listening on both LE and BR/EDR and SDP records for GAP,
GATT and DIS.
android/bluetooth: Add function for checking last seen bearer
android/gatt: Choose LE or BR/EDR based on last seen bearer

This allows to connect both over LE and BR/EDR bearer.
shared/gatt: Add function for getting service UUID
android/gatt: Register SDP records for services
tools: Print controller index after attaching serial port
build: Add support for asciidoc based manual pages
android/README: Don't mention minor Android release number

Minor releases are quite often and don't introduce significant changes.
There is no need pointing this here since aosp-bluez page already
provides info about latest supported minor release.
emulator: Add support for providing a pseudo terminal
tools: Use mainloop handling for btattach utility
emulator: Reopen PTY master when slave closes it
build: Add configure option for generating manual pages
build: Use dist_noinst_MANS for now due to an automake issue
tools/smp-tester: Add user confirmation callback
android/gatt: Make signed_write_cmd similar to rest of write functions

This avoids confusion with assigning bool to uint type.
android/gatt: Fix signed write on encrypted link

This fix invalid setting of res instead of status in error case.