tmeiczin / opendcp

Created digital cinemas packages (DCP)
http://www.opendcp.org
GNU General Public License v3.0
122 stars 52 forks source link

Crypto libraries not found #282

Closed caipiranima closed 7 years ago

caipiranima commented 8 years ago

Hello, I'm trying to compile the master branch of the project but I'm facing this error:

[ 11%] Building CXX object libasdcp/CMakeFiles/opendcp-asdcp.dir/KM_prng.cpp.o /home/filipeam/Downloads/Apps/opendcp-master/libasdcp/KM_prng.cpp:64:3: error: ‘AES_KEY’ does not name a type AES_KEY m_Context; ^~~ /home/filipeam/Downloads/Apps/opendcp-master/libasdcp/KM_prng.cpp: In member function ‘void h__RNG::set_key(const bytet)’: /home/filipeam/Downloads/Apps/opendcp-master/libasdcp/KM_prng.cpp:111:33: error: ‘m_Context’ was not declared in this scope SHA1_Update(&SHA, (bytet)&m_Context, sizeof(m_Context)); ^~~~~ /home/filipeam/Downloads/Apps/opendcp-master/libasdcp/KM_prng.cpp:116:63: error: ‘AES_set_encrypt_key’ was not declared in this scope AES_set_encrypt_key(sha_buf, RNG_KEY_SIZE_BITS, &m_Context); ^ /home/filipeam/Downloads/Apps/opendcp-master/libasdcp/KM_prng.cpp: In member function ‘void h__RNG::fill_rand(bytet, ui32_t)’: /home/filipeam/Downloads/Apps/opendcp-master/libasdcp/KM_prng.cpp:130:43: error: ‘m_Context’ was not declared in this scope AES_encrypt(m_ctr_buf, buf + gen_count, &m_Context); ^~~~~ /home/filipeam/Downloads/Apps/opendcp-master/libasdcp/KM_prng.cpp:130:52: error: ‘AES_encrypt’ was not declared in this scope AES_encrypt(m_ctr_buf, buf + gen_count, &m_Context); ^ /home/filipeam/Downloads/Apps/opendcp-master/libasdcp/KM_prng.cpp:138:31: error: ‘m_Context’ was not declared in this scope AES_encrypt(m_ctr_buf, tmp, &m_Context); ^~~~~ /home/filipeam/Downloads/Apps/opendcp-master/libasdcp/KM_prng.cpp:138:40: error: ‘AES_encrypt’ was not declared in this scope AES_encrypt(m_ctr_buf, tmp, &m_Context); ^ libasdcp/CMakeFiles/opendcp-asdcp.dir/build.make:110: recipe for target 'libasdcp/CMakeFiles/opendcp-asdcp.dir/KMprng.cpp.o' failed make[2]: ** [libasdcp/CMakeFiles/opendcp-asdcp.dir/KM_prng.cpp.o] Error 1 CMakeFiles/Makefile2:195: recipe for target 'libasdcp/CMakeFiles/opendcp-asdcp.dir/all' failed make[1]: * [libasdcp/CMakeFiles/opendcp-asdcp.dir/all] Error 2 Makefile:149: recipe for target 'all' failed make: * [all] Error 2

There are any libraries I'm missing to compile opendcp?

Thank you!

madscientist159 commented 8 years ago

Add this line to libasdcp/KM_prng.cpp:

include <openssl/aes.h>

caipiranima commented 7 years ago

Thank you, I think this work! I've downloaded the 0.30 version of opendcp and in fact the file KM_prng.ccp already has this line. I'm on a different system than the one I used when I faced the error. Well, now I managed to compile. Thank you for your support and for this great project!