]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
mbedtls: fix building with sha-256 missing from PSA
authorViktor Szakats <commit@vsz.me>
Fri, 24 Oct 2025 16:34:35 +0000 (18:34 +0200)
committerViktor Szakats <commit@vsz.me>
Fri, 24 Oct 2025 17:14:28 +0000 (19:14 +0200)
Fixing:
```
lib/vtls/mbedtls.c:1505:10: error: call to undeclared function 'Curl_sha256it'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
 1505 |   return Curl_sha256it(sha256sum, input, inputlen);
      |          ^
1 error generated.
```

with mbedTLS configuration:
```
tf-psa-crypto/scripts/config.py unset PSA_WANT_ALG_SHA_256
tf-psa-crypto/scripts/config.py unset PSA_WANT_ALG_TLS12_ECJPAKE_TO_PMS
tf-psa-crypto/scripts/config.py unset MBEDTLS_LMS_C
```

Follow-up to 3a305831d1a9d10b2bfd4fa3939ed41275fee7f7 #19077

Closes #19223

lib/vtls/mbedtls.c

index 5a2310d115a1bb8c4856755498b60d8177eb8ee4..89d4eff64ea48d36adea660631526a51ddba0884 100644 (file)
@@ -73,6 +73,7 @@
 #include "../multiif.h"
 #include "mbedtls_threadlock.h"
 #include "../strdup.h"
+#include "../curl_sha256.h"
 
 /* The last 2 #include files should be in this order */
 #include "../curl_memory.h"