shiiion / dolphin

Dolphin fork intended to give Metroid Prime Trilogy mouselook controls
Other
466 stars 43 forks source link

build error because of mbedtls #141

Closed ahmedmoselhi closed 9 months ago

ahmedmoselhi commented 1 year ago

I'm trying to build using obs service for opensuse and I get the following error:

[  212s] /home/abuild/rpmbuild/BUILD/primehack-1.0.5.20221022+git.55330bfe/Source/Core/Common/Crypto/SHA1.cpp:41:13: error: use of undeclared identifier 'mbedtls_sha1_starts_ret'; did you mean 'mbedtls_sha1_starts'?
[  212s]     ASSERT(!mbedtls_sha1_starts_ret(&ctx));
[  212s]             ^~~~~~~~~~~~~~~~~~~~~~~
[  212s]             mbedtls_sha1_starts
[  212s] /home/abuild/rpmbuild/BUILD/primehack-1.0.5.20221022+git.55330bfe/Source/Core/Common/Assert.h:35:11: note: expanded from macro 'ASSERT'
[  212s]     if (!(_a_))                                                                                    \
[  212s]           ^
[  212s] /usr/include/mbedtls/sha1.h:123:5: note: 'mbedtls_sha1_starts' declared here
[  212s] int mbedtls_sha1_starts(mbedtls_sha1_context *ctx);
[  212s]     ^
[  212s] /home/abuild/rpmbuild/BUILD/primehack-1.0.5.20221022+git.55330bfe/Source/Core/Common/Crypto/SHA1.cpp:46:13: error: use of undeclared identifier 'mbedtls_sha1_update_ret'; did you mean 'mbedtls_sha1_update'?
[  212s]     ASSERT(!mbedtls_sha1_update_ret(&ctx, msg, len));
[  212s]             ^~~~~~~~~~~~~~~~~~~~~~~
[  212s]             mbedtls_sha1_update
[  212s] /home/abuild/rpmbuild/BUILD/primehack-1.0.5.20221022+git.55330bfe/Source/Core/Common/Assert.h:35:11: note: expanded from macro 'ASSERT'
[  212s]     if (!(_a_))                                                                                    \
[  212s]           ^
[  212s] /usr/include/mbedtls/sha1.h:142:5: note: 'mbedtls_sha1_update' declared here
[  212s] int mbedtls_sha1_update(mbedtls_sha1_context *ctx,
[  212s]     ^
[  212s] /home/abuild/rpmbuild/BUILD/primehack-1.0.5.20221022+git.55330bfe/Source/Core/Common/Crypto/SHA1.cpp:51:13: error: use of undeclared identifier 'mbedtls_sha1_finish_ret'; did you mean 'mbedtls_sha1_finish'?
[  212s]     ASSERT(!mbedtls_sha1_finish_ret(&ctx, digest.data()));
[  212s]             ^~~~~~~~~~~~~~~~~~~~~~~
[  212s]             mbedtls_sha1_finish
[  212s] /home/abuild/rpmbuild/BUILD/primehack-1.0.5.20221022+git.55330bfe/Source/Core/Common/Assert.h:35:11: note: expanded from macro 'ASSERT'
[  212s]     if (!(_a_))                                                                                    \
[  212s]           ^
[  212s] /usr/include/mbedtls/sha1.h:162:5: note: 'mbedtls_sha1_finish' declared here
[  212s] int mbedtls_sha1_finish(mbedtls_sha1_context *ctx,
[  212s]     ^
[  212s] 3 errors generated.
vyuuui commented 9 months ago

Current branch should be on the latest release, fixes this problem. If anything like this occurs, the easiest workaround is to configure the project to use the non-system library with -DUSE_SYSTEM_<libname>=false