Skip to content

Commit

Permalink
stm32: Add missing header include for debug builds.
Browse files Browse the repository at this point in the history
Debug build fails if string.h header is not included.

Signed-off-by: iabdalkader <i.abdalkader@gmail.com>
  • Loading branch information
iabdalkader authored and dpgeorge committed Nov 28, 2023
1 parent 992cd64 commit cfcd0c4
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions ports/stm32/i2c.c
Expand Up @@ -24,6 +24,7 @@
* THE SOFTWARE.
*/

#include <string.h>
#include "py/mperrno.h"
#include "py/mphal.h"
#include "py/runtime.h"
Expand Down
1 change: 1 addition & 0 deletions ports/stm32/machine_i2s.c
Expand Up @@ -29,6 +29,7 @@
// extmod/machine_i2s.c via MICROPY_PY_MACHINE_I2S_INCLUDEFILE.

#include <stdlib.h>
#include <string.h>
#include "py/mphal.h"
#include "pin.h"
#include "dma.h"
Expand Down
3 changes: 3 additions & 0 deletions ports/stm32/pin_static_af.h
Expand Up @@ -26,6 +26,9 @@
#ifndef MICROPY_INCLUDED_STM32_PIN_STATIC_AF_H
#define MICROPY_INCLUDED_STM32_PIN_STATIC_AF_H

// For debug builds some of the macros expand to use strcmp.
#include <string.h>

#include "py/mphal.h"
#include "genhdr/pins.h"
#include "genhdr/pins_af_defs.h"
Expand Down
1 change: 1 addition & 0 deletions ports/stm32/spi.c
Expand Up @@ -24,6 +24,7 @@
* THE SOFTWARE.
*/

#include <string.h>
#include "py/runtime.h"
#include "py/mperrno.h"
#include "py/mphal.h"
Expand Down

0 comments on commit cfcd0c4

Please sign in to comment.