refactor(3p/nix): Remove abstractions in HAVE_STRUCT_DIRENT_D_TYPE code

(cherry picked from commit 727dc569a7a13b038d550b8c98a79d5928424d9b)
This commit is contained in:
John Ericson 2019-11-04 12:37:24 -05:00 committed by Vincent Ambo
parent 4b50bd28a0
commit 6cbc248b3f

View file

@ -321,10 +321,8 @@ dirent_h_prefix = '''
#include <dirent.h>
'''
# Code taken from glib, thanks!
if has_dirent_h and meson.get_compiler('cpp').has_member('struct dirent', 'd_type', prefix: dirent_h_prefix)
define = 'HAVE_STRUCT_@0@_@1@'.format('dirent'.to_upper(), 'd_type'.underscorify().to_upper())
config_h.set(define, 1)
config_h.set('HAVE_STRUCT_DIRENT_D_TYPE', 1)
endif
# required dependancies