merge "nim.cfg" into "config.nims" (#1820)

to reduce the number of configuration files
This commit is contained in:
Ștefan Talpalaru 2020-10-07 12:02:00 +02:00 committed by GitHub
parent e9b2253fac
commit f1acc0532c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 37 additions and 35 deletions

View File

@ -101,3 +101,40 @@ switch("warning", "LockLevel:off")
# Useful for Chronos metrics.
#--define:chronosFutureTracking
# ############################################################
#
# No LTO for crypto
#
# ############################################################
# This applies per-file compiler flags to C files
# which do not support {.localPassC: "-fno-lto".}
# Unfortunately this is filename based instead of path-based
# Assumes GCC
# BLST
put("server.always", "-fno-lto")
put("assembly.always", "-fno-lto")
# Secp256k1
put("secp256k1.always", "-fno-lto")
# BearSSL - only RNGs
put("aesctr_drbg.always", "-fno-lto")
put("hmac_drbg.always", "-fno-lto")
put("sysrng.always", "-fno-lto")
# Miracl - only ECP to derive public key from private key
put("ecp_BLS12381.always", "-fno-lto")
# ############################################################
#
# Spurious warnings
#
# ############################################################
# sqlite3.c: In function sqlite3SelectNew:
# vendor/nim-sqlite3-abi/sqlite3.c:124500: warning: function may return address of local variable [-Wreturn-local-addr]
put("sqlite3.always", "-fno-lto") # -Wno-return-local-addr

35
nim.cfg
View File

@ -1,35 +0,0 @@
# ############################################################
#
# No LTO for crypto
#
# ############################################################
# This applies per-file compiler flags to C files
# which do not support {.localPassC: "-fno-lto".}
# Unfortunately this is filename based instead of path-based
# Assumes GCC
# BLST
server.always = "-fno-lto"
assembly.always = "-fno-lto"
# Secp256k1
secp256k1.always = "-fno-lto"
# BearSSL - only RNGs
aesctr_drbg.always = "-fno-lto"
hmac_drbg.always = "-fno-lto"
sysrng.always = "-fno-lto"
# Miracl - only ECP to derive public key from private key
ecp_BLS12381.always = "-fno-lto"
# ############################################################
#
# Spurious warnings
#
# ############################################################
# sqlite3.c: In function sqlite3SelectNew:
# vendor/nim-sqlite3-abi/sqlite3.c:124500: warning: function may return address of local variable [-Wreturn-local-addr]
sqlite3.always = "-fno-lto" # -Wno-return-local-addr