boringssl/crypto/err/CMakeLists.txt
David Benjamin d27eda00a4 Generate error data at build time.
This avoids cluttering up the diff and making merge conflicts a pain.  It does,
however, mean we need to generate err_data.c ahead of time in Chromium and
likely other downstream builds. It also adds a build dependency on Go.

Change-Id: I6e0513ed9f50cfb030f7a523ea28519590977104
Reviewed-on: https://boringssl-review.googlesource.com/3790
Reviewed-by: Adam Langley <agl@google.com>
2015-03-06 18:59:25 +00:00

51 lines
797 B
CMake

include_directories(. .. ../../include)
add_custom_command(
OUTPUT err_data.c
COMMAND ${GO_EXECUTABLE} run err_data_generate.go > ${CMAKE_CURRENT_BINARY_DIR}/err_data.c
DEPENDS
err_data_generate.go
asn1.errordata
bio.errordata
bn.errordata
buf.errordata
cipher.errordata
conf.errordata
crypto.errordata
dh.errordata
digest.errordata
dsa.errordata
ecdh.errordata
ecdsa.errordata
ec.errordata
engine.errordata
evp.errordata
hkdf.errordata
obj.errordata
pem.errordata
pkcs8.errordata
rsa.errordata
ssl.errordata
x509.errordata
x509v3.errordata
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
)
add_library(
err
OBJECT
err.c
err_data.c
err_impl.c
)
add_executable(
err_test
err_test.c
)
target_link_libraries(err_test crypto)