package/ibm-sw-tpm2: fix glibc build errors
authorVincent Fazio <vfazio@gmail.com>
Tue, 18 Aug 2020 14:25:12 +0000 (09:25 -0500)
committerThomas Petazzoni <thomas.petazzoni@bootlin.com>
Tue, 18 Aug 2020 14:43:40 +0000 (16:43 +0200)
commita34e7f88f67b77066f73894dc8e42bca3c076fa6
treecb0c6d13cb1fcdd7729a9ff5f91892b6e9a6a23e
parent6f149e278a9daf07bf4a7a8a32c77ab01acf6d54
package/ibm-sw-tpm2: fix glibc build errors

In order to not have to define all architecture bitness variants in
src/LibSupport.h to conditionally define RADIX_BITS, a patch was created
to depend on LONG_BIT being defined via limits.h

For glibc, LONG_BIT is behind a _XOPEN_SOURCE define guard so patch the
makefile to define this macro as well as _DEFAULT_SOURCE.

Defining _XOPEN_SOURCE requires _DEFAULT_SOURCE to be explicitly defined
for builds to succeed as it is no longer impliclty defined when
_XOPEN_SOURCE is defined.

Fixes:
http://autobuild.buildroot.net/results/bc145dd23c80a0660300766d0c114a00ed2e52b6/
http://autobuild.buildroot.net/results/1d84e70c30d4d0719274aa4f3edc01772beb24a3/

Fixes: 19bd089004 ("package/ibm-sw-tpm2: fix patch to address musl builds")
Signed-off-by: Vincent Fazio <vfazio@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
package/ibm-sw-tpm2/0001-Use-LONG_BIT-to-define-RADIX_BITS.patch