diff --git a/sys/Makefile.dep b/sys/Makefile.dep index dad7ead251..4e20e9241b 100644 --- a/sys/Makefile.dep +++ b/sys/Makefile.dep @@ -405,40 +405,6 @@ ifneq (,$(filter entropy_source_%,$(USEMODULE))) USEMODULE += entropy_source endif -ifneq (,$(filter random,$(USEMODULE))) - DEFAULT_MODULE += auto_init_random - USEMODULE += prng - - ifneq (,$(filter prng_fortuna,$(USEMODULE))) - USEMODULE += fortuna - USEMODULE += hashes - USEMODULE += crypto - ifneq (,$(filter fortuna_reseed,$(USEMODULE))) - USEMODULE += atomic_utils - USEMODULE += xtimer - endif - endif - - ifneq (,$(filter prng_tinymt32,$(USEMODULE))) - USEMODULE += tinymt32 - endif - - ifneq (,$(filter prng_sha%prng,$(USEMODULE))) - USEMODULE += prng_shaxprng - USEMODULE += hashes - endif - - ifneq (,$(filter prng_hwrng,$(USEMODULE))) - FEATURES_REQUIRED += periph_hwrng - endif - - ifeq (,$(filter puf_sram,$(USEMODULE))) - FEATURES_OPTIONAL += periph_hwrng - endif - - USEMODULE += luid -endif - ifneq (,$(filter hashes,$(USEMODULE))) USEMODULE += crypto endif diff --git a/sys/random/Makefile.dep b/sys/random/Makefile.dep new file mode 100644 index 0000000000..dcb5b0e9ad --- /dev/null +++ b/sys/random/Makefile.dep @@ -0,0 +1,31 @@ +DEFAULT_MODULE += auto_init_random +USEMODULE += prng + +ifneq (,$(filter prng_fortuna,$(USEMODULE))) + USEMODULE += fortuna + USEMODULE += hashes + USEMODULE += crypto + ifneq (,$(filter fortuna_reseed,$(USEMODULE))) + USEMODULE += atomic_utils + USEMODULE += xtimer + endif +endif + +ifneq (,$(filter prng_tinymt32,$(USEMODULE))) + USEMODULE += tinymt32 +endif + +ifneq (,$(filter prng_sha%prng,$(USEMODULE))) + USEMODULE += prng_shaxprng + USEMODULE += hashes +endif + +ifneq (,$(filter prng_hwrng,$(USEMODULE))) + FEATURES_REQUIRED += periph_hwrng +endif + +ifeq (,$(filter puf_sram,$(USEMODULE))) + FEATURES_OPTIONAL += periph_hwrng +endif + +USEMODULE += luid