You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

95 lines
1.7 KiB

  1. From 9717338f1917fa5db63fe7c9758639417ab06f61 Mon Sep 17 00:00:00 2001
  2. From: yangfl <yangfl@users.noreply.github.com>
  3. Date: Mon, 4 Jan 2021 23:09:41 +0800
  4. Subject: [PATCH 06/10] extmod: Use system mbedtls
  5. ---
  6. extmod/extmod.mk | 77 ++----------------------------------------------
  7. 1 file changed, 2 insertions(+), 75 deletions(-)
  8. --- a/extmod/extmod.mk
  9. +++ b/extmod/extmod.mk
  10. @@ -66,81 +66,8 @@ SRC_MOD += $(addprefix $(AXTLS_DIR)/,\
  11. crypto/sha1.c \
  12. )
  13. else ifeq ($(MICROPY_SSL_MBEDTLS),1)
  14. -MBEDTLS_DIR = lib/mbedtls
  15. -CFLAGS_MOD += -DMICROPY_SSL_MBEDTLS=1 -I$(TOP)/$(MBEDTLS_DIR)/include
  16. -SRC_MOD += $(addprefix $(MBEDTLS_DIR)/library/,\
  17. - aes.c \
  18. - aesni.c \
  19. - arc4.c \
  20. - asn1parse.c \
  21. - asn1write.c \
  22. - base64.c \
  23. - bignum.c \
  24. - blowfish.c \
  25. - camellia.c \
  26. - ccm.c \
  27. - certs.c \
  28. - chacha20.c \
  29. - chachapoly.c \
  30. - cipher.c \
  31. - cipher_wrap.c \
  32. - cmac.c \
  33. - ctr_drbg.c \
  34. - debug.c \
  35. - des.c \
  36. - dhm.c \
  37. - ecdh.c \
  38. - ecdsa.c \
  39. - ecjpake.c \
  40. - ecp.c \
  41. - ecp_curves.c \
  42. - entropy.c \
  43. - entropy_poll.c \
  44. - error.c \
  45. - gcm.c \
  46. - havege.c \
  47. - hmac_drbg.c \
  48. - md2.c \
  49. - md4.c \
  50. - md5.c \
  51. - md.c \
  52. - md_wrap.c \
  53. - oid.c \
  54. - padlock.c \
  55. - pem.c \
  56. - pk.c \
  57. - pkcs11.c \
  58. - pkcs12.c \
  59. - pkcs5.c \
  60. - pkparse.c \
  61. - pk_wrap.c \
  62. - pkwrite.c \
  63. - platform.c \
  64. - platform_util.c \
  65. - poly1305.c \
  66. - ripemd160.c \
  67. - rsa.c \
  68. - rsa_internal.c \
  69. - sha1.c \
  70. - sha256.c \
  71. - sha512.c \
  72. - ssl_cache.c \
  73. - ssl_ciphersuites.c \
  74. - ssl_cli.c \
  75. - ssl_cookie.c \
  76. - ssl_srv.c \
  77. - ssl_ticket.c \
  78. - ssl_tls.c \
  79. - timing.c \
  80. - x509.c \
  81. - x509_create.c \
  82. - x509_crl.c \
  83. - x509_crt.c \
  84. - x509_csr.c \
  85. - x509write_crt.c \
  86. - x509write_csr.c \
  87. - xtea.c \
  88. - )
  89. +CFLAGS_MOD += -DMICROPY_SSL_MBEDTLS=1
  90. +LDFLAGS_MOD += -lmbedx509 -lmbedtls -lmbedcrypto
  91. endif
  92. endif