Skip to content

Commit 136369d

Browse files
committed
all: Update to point to files in new shared/ directory.
Signed-off-by: Damien George <damien@micropython.org>
1 parent 4d54671 commit 136369d

File tree

141 files changed

+324
-306
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

141 files changed

+324
-306
lines changed

docs/develop/porting.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ The basic MicroPython firmware is implemented in the main port file, e.g ``main.
4242
#include "py/gc.h"
4343
#include "py/mperrno.h"
4444
#include "py/stackctrl.h"
45-
#include "lib/utils/gchelper.h"
46-
#include "lib/utils/pyexec.h"
45+
#include "shared/runtime/gchelper.h"
46+
#include "shared/runtime/pyexec.h"
4747
4848
// Allocate memory for the MicroPython GC heap.
4949
static char heap[4096];
@@ -106,10 +106,10 @@ We also need a Makefile at this point for the port:
106106
SRC_C = \
107107
main.c \
108108
mphalport.c \
109-
lib/mp-readline/readline.c \
110-
lib/utils/gchelper_generic.c \
111-
lib/utils/pyexec.c \
112-
lib/utils/stdout_helpers.c \
109+
shared/readline/readline.c \
110+
shared/runtime/gchelper_generic.c \
111+
shared/runtime/pyexec.c \
112+
shared/runtime/stdout_helpers.c \
113113
114114
# Define the required object files.
115115
OBJ = $(PY_CORE_O) $(addprefix $(BUILD)/, $(SRC_C:.c=.o))

drivers/cyw43/cyw43.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
#include "lwip/netif.h"
3030
#include "lwip/dhcp.h"
31-
#include "lib/netutils/dhcpserver.h"
31+
#include "shared/netutils/dhcpserver.h"
3232
#include "drivers/cyw43/cyw43_ll.h"
3333

3434
// For trace_flags

drivers/cyw43/cyw43_lwip.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
#include <string.h>
2929

3030
#include "py/mphal.h"
31-
#include "lib/netutils/netutils.h"
31+
#include "shared/netutils/netutils.h"
3232
#include "lwip/etharp.h"
3333
#include "lwip/dns.h"
3434
#include "lwip/apps/mdns.h"

examples/embedding/Makefile.upylib

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,9 @@ endif
8282
endif
8383

8484
ifeq ($(MICROPY_USE_READLINE),1)
85-
INC += -I$(MPTOP)/lib/mp-readline
85+
INC += -I$(MPTOP)/shared/readline
8686
CFLAGS_MOD += -DMICROPY_USE_READLINE=1
87-
LIB_SRC_C_EXTRA += mp-readline/readline.c
87+
SHARED_SRC_C_EXTRA += readline/readline.c
8888
endif
8989
ifeq ($(MICROPY_USE_READLINE),2)
9090
CFLAGS_MOD += -DMICROPY_USE_READLINE=2
@@ -145,19 +145,19 @@ SRC_C = $(addprefix ports/unix/,\
145145
$(SRC_MOD) \
146146
)
147147

148-
LIB_SRC_C = $(addprefix lib/,\
149-
$(LIB_SRC_C_EXTRA) \
150-
utils/printf.c \
151-
utils/gchelper_generic.c \
148+
SHARED_SRC_C = $(addprefix shared/,\
149+
libc/printf.c \
150+
runtime/gchelper_generic.c \
152151
timeutils/timeutils.c \
152+
$(SHARED_SRC_C_EXTRA) \
153153
)
154154

155155
OBJ = $(PY_O)
156156
OBJ += $(addprefix $(BUILD)/, $(SRC_C:.c=.o))
157-
OBJ += $(addprefix $(BUILD)/, $(LIB_SRC_C:.c=.o))
157+
OBJ += $(addprefix $(BUILD)/, $(SHARED_SRC_C:.c=.o))
158158

159159
# List of sources for qstr extraction
160-
SRC_QSTR += $(SRC_C) $(LIB_SRC_C)
160+
SRC_QSTR += $(SRC_C) $(SHARED_SRC_C)
161161
# Append any auto-generated sources that are needed by sources listed in
162162
# SRC_QSTR
163163
SRC_QSTR_AUTO_DEPS +=

extmod/extmod.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ set(MICROPY_EXTMOD_DIR "${MICROPY_DIR}/extmod")
44
set(MICROPY_OOFATFS_DIR "${MICROPY_DIR}/lib/oofatfs")
55

66
set(MICROPY_SOURCE_EXTMOD
7-
${MICROPY_DIR}/lib/embed/abort_.c
8-
${MICROPY_DIR}/lib/utils/printf.c
7+
${MICROPY_DIR}/shared/libc/abort_.c
8+
${MICROPY_DIR}/shared/libc/printf.c
99
${MICROPY_EXTMOD_DIR}/machine_i2c.c
1010
${MICROPY_EXTMOD_DIR}/machine_mem.c
1111
${MICROPY_EXTMOD_DIR}/machine_pulse.c

extmod/extmod.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ LWIP_DIR = lib/lwip/src
153153
INC += -I$(TOP)/$(LWIP_DIR)/include
154154
CFLAGS_MOD += -DMICROPY_PY_LWIP=1
155155
$(BUILD)/$(LWIP_DIR)/core/ipv4/dhcp.o: CFLAGS_MOD += -Wno-address
156-
SRC_MOD += extmod/modlwip.c lib/netutils/netutils.c
156+
SRC_MOD += extmod/modlwip.c shared/netutils/netutils.c
157157
SRC_MOD += $(addprefix $(LWIP_DIR)/,\
158158
apps/mdns/mdns.c \
159159
core/def.c \

extmod/modlwip.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
#include "py/mperrno.h"
3636
#include "py/mphal.h"
3737

38-
#include "lib/netutils/netutils.h"
38+
#include "shared/netutils/netutils.h"
3939

4040
#include "lwip/init.h"
4141
#include "lwip/tcp.h"

extmod/uos_dupterm.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
#include "py/objarray.h"
3434
#include "py/stream.h"
3535
#include "extmod/misc.h"
36-
#include "lib/utils/interrupt_char.h"
36+
#include "shared/runtime/interrupt_char.h"
3737

3838
#if MICROPY_PY_OS_DUPTERM
3939

extmod/vfs_fat.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
#include "py/mperrno.h"
3838
#include "lib/oofatfs/ff.h"
3939
#include "extmod/vfs_fat.h"
40-
#include "lib/timeutils/timeutils.h"
40+
#include "shared/timeutils/timeutils.h"
4141

4242
#if FF_MAX_SS == FF_MIN_SS
4343
#define SECSIZE(fs) (FF_MIN_SS)

extmod/vfs_lfs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626

2727
#include "py/runtime.h"
2828
#include "py/mphal.h"
29-
#include "lib/timeutils/timeutils.h"
29+
#include "shared/timeutils/timeutils.h"
3030
#include "extmod/vfs.h"
3131
#include "extmod/vfs_lfs.h"
3232

0 commit comments

Comments
 (0)