add (nearly) all defines from tomcrypt_custom.h to crypt_build_settings
... and provide a new make target to check if something is missing
This commit is contained in:
		
							parent
							
								
									0b140206cf
								
							
						
					
					
						commit
						d4945ac521
					
				
							
								
								
									
										6
									
								
								makefile
									
									
									
									
									
								
							
							
						
						
									
										6
									
								
								makefile
									
									
									
									
									
								
							| @ -387,6 +387,12 @@ zipup: no_oops docs | |||||||
| 	mv -fv crypt* ~ ; rm -rf libtomcrypt-$(VERSION) | 	mv -fv crypt* ~ ; rm -rf libtomcrypt-$(VERSION) | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
|  | check_defines: | ||||||
|  | 	cat src/headers/tomcrypt_custom.h | grep '\#define[ \t]*LTC_' | sed -e 's@/\*@@g' -e 's@\*/@@g' -e 's@^[ \t]*@@g' \
 | ||||||
|  | 	| cut -d' ' -f 2 | sed -e 's@(x)@@g' | sort | uniq \
 | ||||||
|  | 	| grep -v -e 'LTC_ECC[0-9]*' -e 'LTC_DH[0-9]*' -e 'LTC_NO_' -e 'LTC_MUTEX' -e 'LTC_MPI' \
 | ||||||
|  | 	| xargs -I '{}' sh -c 'grep -q -m 1 -o {} src/misc/crypt/crypt.c || echo {} not found' | ||||||
|  | 
 | ||||||
| # $Source$
 | # $Source$
 | ||||||
| # $Revision$
 | # $Revision$
 | ||||||
| # $Date$
 | # $Date$
 | ||||||
|  | |||||||
| @ -14,6 +14,8 @@ | |||||||
|   @file crypt.c |   @file crypt.c | ||||||
|   Build strings, Tom St Denis |   Build strings, Tom St Denis | ||||||
| */ | */ | ||||||
|  | #define NAME_VALUE(s) #s"="NAME(s) | ||||||
|  | #define NAME(s) #s | ||||||
| 
 | 
 | ||||||
| const char *crypt_build_settings = | const char *crypt_build_settings = | ||||||
|    "LibTomCrypt " SCRYPT " (Tom St Denis, tomstdenis@gmail.com)\n" |    "LibTomCrypt " SCRYPT " (Tom St Denis, tomstdenis@gmail.com)\n" | ||||||
| @ -251,7 +253,7 @@ const char *crypt_build_settings = | |||||||
| 
 | 
 | ||||||
|     "\nPRNG:\n" |     "\nPRNG:\n" | ||||||
| #if defined(LTC_YARROW) | #if defined(LTC_YARROW) | ||||||
|     "   Yarrow\n" |     "   Yarrow ("NAME_VALUE(LTC_YARROW_AES)")\n" | ||||||
| #endif | #endif | ||||||
| #if defined(LTC_SPRNG) | #if defined(LTC_SPRNG) | ||||||
|     "   SPRNG\n" |     "   SPRNG\n" | ||||||
| @ -260,7 +262,7 @@ const char *crypt_build_settings = | |||||||
|     "   RC4\n" |     "   RC4\n" | ||||||
| #endif | #endif | ||||||
| #if defined(LTC_FORTUNA) | #if defined(LTC_FORTUNA) | ||||||
|     "   Fortuna\n" |     "   Fortuna (" NAME_VALUE(LTC_FORTUNA_POOLS) ", " NAME_VALUE(LTC_FORTUNA_WD) ")\n" | ||||||
| #endif | #endif | ||||||
| #if defined(LTC_SOBER128) | #if defined(LTC_SOBER128) | ||||||
|     "   SOBER128\n" |     "   SOBER128\n" | ||||||
| @ -341,6 +343,9 @@ const char *crypt_build_settings = | |||||||
| #if defined(LTC_DER) | #if defined(LTC_DER) | ||||||
|     " DER " |     " DER " | ||||||
| #endif | #endif | ||||||
|  | #if defined(LTC_DER_MAX_PUBKEY_SIZE) | ||||||
|  |     " " NAME_VALUE(LTC_DER_MAX_PUBKEY_SIZE) " " | ||||||
|  | #endif | ||||||
| #if defined(LTC_PKCS_1) | #if defined(LTC_PKCS_1) | ||||||
|     " PKCS#1 " |     " PKCS#1 " | ||||||
| #endif | #endif | ||||||
| @ -353,12 +358,30 @@ const char *crypt_build_settings = | |||||||
| #if defined(MPI) | #if defined(MPI) | ||||||
|     " MPI " |     " MPI " | ||||||
| #endif | #endif | ||||||
|  | #if defined(LTC_DEVRANDOM) | ||||||
|  |     " LTC_DEVRANDOM " | ||||||
|  | #endif | ||||||
| #if defined(LTC_TRY_URANDOM_FIRST) | #if defined(LTC_TRY_URANDOM_FIRST) | ||||||
|     " LTC_TRY_URANDOM_FIRST " |     " LTC_TRY_URANDOM_FIRST " | ||||||
| #endif | #endif | ||||||
|  | #if defined(LTC_RNG_GET_BYTES) | ||||||
|  |     " LTC_RNG_GET_BYTES " | ||||||
|  | #endif | ||||||
|  | #if defined(LTC_RNG_MAKE_PRNG) | ||||||
|  |     " LTC_RNG_MAKE_PRNG " | ||||||
|  | #endif | ||||||
|  | #if defined(LTC_HASH_HELPERS) | ||||||
|  |     " LTC_HASH_HELPERS " | ||||||
|  | #endif | ||||||
|  | #if defined(LTC_VALGRIND) | ||||||
|  |     " LTC_VALGRIND " | ||||||
|  | #endif | ||||||
| #if defined(LTC_TEST) | #if defined(LTC_TEST) | ||||||
|     " LTC_TEST " |     " LTC_TEST " | ||||||
| #endif | #endif | ||||||
|  | #if defined(LTC_TEST_EXT) | ||||||
|  |     " LTC_TEST_EXT " | ||||||
|  | #endif | ||||||
| #if defined(LTC_SMALL_CODE) | #if defined(LTC_SMALL_CODE) | ||||||
|     " LTC_SMALL_CODE " |     " LTC_SMALL_CODE " | ||||||
| #endif | #endif | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user