diff options
author | Mikael Magnusson <mikma@users.sourceforge.net> | 2021-07-22 00:02:49 +0200 |
---|---|---|
committer | Mikael Magnusson <mikma@users.sourceforge.net> | 2021-09-21 22:22:04 +0200 |
commit | d28760aea75c8da6ebe23775b1b81318729516c1 (patch) | |
tree | fb0ac6fcd7aa4dfd1cdd1fee30338315e6c25a75 /CMakeLists.txt | |
parent | 2455a48e2bff0ae887ef3a81496db1b37a46eae0 (diff) |
prng: add sha-1 based prng using mbedtls
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 9bd62af..d9bbffd 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -36,7 +36,13 @@ if(${DHCPV4_SUPPORT}) set(EXT_SRC ${EXT_SRC} src/dhcpv4.c) endif(${DHCPV4_SUPPORT}) -set(EXT_SRC ${EXT_SRC} src/prng_md5.c) +if(${MBEDTLS}) + add_definitions(-DWITH_MBEDTLS) + set(EXT_SRC ${EXT_SRC} src/prng_mbed.c) + set(EXT_LINK ${EXT_LINK} mbedcrypto) +else(${MBEDTLS}) + set(EXT_SRC ${EXT_SRC} src/prng_md5.c) +endif(${MBEDCTLS}) add_executable(odhcpd src/odhcpd.c src/config.c src/router.c src/dhcpv6.c src/ndp.c src/dhcpv6-ia.c src/netlink.c ${EXT_SRC}) target_link_libraries(odhcpd resolv ubox uci ${libnl} ${EXT_LINK}) |