2019-07-16 18:28:54 +03:00
|
|
|
crypto_ss.add(genh)
|
|
|
|
crypto_ss.add(files(
|
|
|
|
'afsplit.c',
|
|
|
|
'block-luks.c',
|
|
|
|
'block-qcow.c',
|
|
|
|
'block.c',
|
|
|
|
'cipher.c',
|
|
|
|
'desrfb.c',
|
|
|
|
'hash.c',
|
|
|
|
'hmac.c',
|
|
|
|
'ivgen-essiv.c',
|
|
|
|
'ivgen-plain.c',
|
|
|
|
'ivgen-plain64.c',
|
|
|
|
'ivgen.c',
|
|
|
|
'pbkdf.c',
|
|
|
|
'secret_common.c',
|
|
|
|
'secret.c',
|
|
|
|
'tlscreds.c',
|
|
|
|
'tlscredsanon.c',
|
|
|
|
'tlscredspsk.c',
|
|
|
|
'tlscredsx509.c',
|
|
|
|
'tlssession.c',
|
|
|
|
))
|
|
|
|
|
2021-06-03 12:15:26 +03:00
|
|
|
if nettle.found()
|
|
|
|
crypto_ss.add(nettle, files('hash-nettle.c', 'hmac-nettle.c', 'pbkdf-nettle.c'))
|
|
|
|
elif gcrypt.found()
|
|
|
|
crypto_ss.add(gcrypt, files('hash-gcrypt.c', 'hmac-gcrypt.c', 'pbkdf-gcrypt.c'))
|
2019-07-16 18:28:54 +03:00
|
|
|
else
|
2020-09-01 16:30:49 +03:00
|
|
|
crypto_ss.add(files('hash-glib.c', 'hmac-glib.c', 'pbkdf-stub.c'))
|
2019-07-16 18:28:54 +03:00
|
|
|
endif
|
2021-06-03 12:15:26 +03:00
|
|
|
if xts == 'private'
|
|
|
|
crypto_ss.add(files('xts.c'))
|
|
|
|
endif
|
2019-07-16 18:28:54 +03:00
|
|
|
|
|
|
|
crypto_ss.add(when: 'CONFIG_SECRET_KEYRING', if_true: files('secret_keyring.c'))
|
|
|
|
crypto_ss.add(when: 'CONFIG_AF_ALG', if_true: files('afalg.c', 'cipher-afalg.c', 'hash-afalg.c'))
|
2021-06-03 12:15:26 +03:00
|
|
|
crypto_ss.add(when: gnutls, if_true: files('tls-cipher-suites.c'))
|
2020-09-01 16:30:49 +03:00
|
|
|
|
2020-08-19 15:44:56 +03:00
|
|
|
util_ss.add(files('aes.c'))
|
|
|
|
util_ss.add(files('init.c'))
|
2020-09-01 16:30:49 +03:00
|
|
|
|
2021-06-03 12:15:26 +03:00
|
|
|
if gcrypt.found()
|
|
|
|
util_ss.add(gcrypt, files('random-gcrypt.c'))
|
|
|
|
elif gnutls.found()
|
|
|
|
util_ss.add(gnutls, files('random-gnutls.c'))
|
2020-08-19 15:44:56 +03:00
|
|
|
elif 'CONFIG_RNG_NONE' in config_host
|
|
|
|
util_ss.add(files('random-none.c'))
|
|
|
|
else
|
|
|
|
util_ss.add(files('random-platform.c'))
|
|
|
|
endif
|
2020-09-01 16:30:49 +03:00
|
|
|
|