Fix libhid API builds with recent gcc/glib `

Since glibc 2.10 `wcsdup` and `strtok_r` require `_POSIX_C_SOURCE`

(see also da520ce 4b8b5ac)
This commit is contained in:
Robin Gareus
2024-09-15 12:00:12 +02:00
parent f94bde59d7
commit 9c64e7d141

View File

@@ -39,6 +39,7 @@ def build(bld):
obj.target = 'hidapi'
obj.vnum = HIDAPI_VERSION
obj.install_path = bld.env['LIBDIR']
obj.defines = '_POSIX_C_SOURCE=200809L'
if bld.env['build_target'] == 'mingw':
obj.source = 'windows/hid.c'