Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rename MG_ENABLE_FILE to MG_ENABLE_POSIX_FS #2586

Merged
merged 1 commit into from
Jan 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -132,11 +132,11 @@ s390: CC = $(DOCKER) mdashnet/s390 cc
s390: RUN = $(DOCKER) mdashnet/s390
s390: test

arm: DEFS += -DMG_ENABLE_FILE=0 -DMG_ENABLE_TCPIP=1 -DMG_ARCH=MG_ARCH_NEWLIB
arm: DEFS += -DMG_ENABLE_POSIX_FS=0 -DMG_ENABLE_TCPIP=1 -DMG_ARCH=MG_ARCH_NEWLIB
arm: mongoose.h $(SRCS)
$(DOCKER) mdashnet/armgcc arm-none-eabi-gcc -mcpu=cortex-m3 -mthumb $(SRCS) $(OPTS) $(WARN) $(INCS) $(DEFS) $(TFLAGS) -o unit_test -nostartfiles --specs nosys.specs -e 0

riscv: DEFS += -DMG_ENABLE_FILE=0 -DMG_ENABLE_TCPIP=1 -DMG_ARCH=MG_ARCH_NEWLIB
riscv: DEFS += -DMG_ENABLE_POSIX_FS=0 -DMG_ENABLE_TCPIP=1 -DMG_ARCH=MG_ARCH_NEWLIB
riscv: mongoose.h $(SRCS)
$(DOCKER) mdashnet/riscv riscv-none-elf-gcc -march=rv32imc -mabi=ilp32 $(SRCS) $(OPTS) $(WARN) $(INCS) $(DEFS) $(TFLAGS) -o unit_test

Expand Down
2 changes: 1 addition & 1 deletion examples/arduino/teensy41-http/mongoose_custom.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#define MG_ENABLE_TCPIP 1 // Enable built-in network stack
#define MG_ENABLE_DRIVER_IMXRT 1 // Enable RTxx driver
#define MG_ENABLE_CUSTOM_MILLIS 1 // Let user implement mg_millis()
#define MG_ENABLE_FILE 0 // Disable POSIX filesystem
#define MG_ENABLE_POSIX_FS 0 // Disable POSIX filesystem
#define MG_ENABLE_PACKED_FS 1 // Enable packed filesystem

#define HTTP_URL "http://0.0.0.0"
Expand Down
2 changes: 1 addition & 1 deletion examples/rp2040/pico-rndis-dashboard/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ pico_enable_stdio_uart(firmware 1) # to the UART
# Mongoose build flags
add_definitions(-DMG_ENABLE_TCPIP=1)
add_definitions(-DMG_ENABLE_PACKED_FS=1)
add_definitions(-DMG_ENABLE_FILE=0)
add_definitions(-DMG_ENABLE_POSIX_FS=0)
add_definitions(-DDISABLE_ROUTING=1)

# Example build options
Expand Down
2 changes: 1 addition & 1 deletion examples/rp2040/pico-rndis-device/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@ pico_enable_stdio_uart(firmware 1) # to the UART

# Mongoose build flags
add_definitions(-DMG_ENABLE_TCPIP=1)
add_definitions(-DMG_ENABLE_FILE=0)
add_definitions(-DMG_ENABLE_POSIX_FS=0)

# Example build options
2 changes: 1 addition & 1 deletion examples/rp2040/pico-w5500/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ add_definitions(-DMG_ENABLE_TCPIP=1)
add_definitions(-DMG_ENABLE_PACKED_FS=1)
add_definitions(-DMG_ENABLE_MBEDTLS=0) # TODO(cpq): enable
add_definitions(-DMG_ENABLE_CUSTOM_RANDOM=1)
add_definitions(-DMG_ENABLE_FILE=0)
add_definitions(-DMG_ENABLE_POSIX_FS=0)

# Example build options
add_definitions(-DHTTP_URL="http://0.0.0.0/")
Expand Down
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
// If we could guess an MG_ARCH so far, preserve it, otherwise try GCC-based
#if defined(MG_ARCH)
#define MG_STMPACK_ARCH MG_ARCH
#undef MG_ARCH
#elif defined(__GNUC__)
#define MG_STMPACK_ARCH MG_ARCH_NEWLIB
#endif
#define MG_ENABLE_PACKED_FS 1
#define MG_ENABLE_CUSTOM_MILLIS 1
#define MG_ENABLE_MBEDTLS 0
#define MG_ARCH MG_STMPACK_ARCH
#define MG_STMPACK_NET 0
#define MG_ENABLE_CUSTOM_RANDOM 1
// Translate to Mongoose macros
#if MG_CMSISPACK_NET == 0
#define MG_ENABLE_TCPIP 1
#elif MG_CMSISPACK_NET == 1
#define MG_ENABLE_LWIP 1
#elif MG_CMSISPACK_NET == 2
#define MG_ENABLE_FREERTOS_TCP 1
#elif MG_CMSISPACK_NET == 3
#define MG_ENABLE_RL 1
#endif
#if MG_ENABLE_PACKED_FS
#define MG_ENABLE_FILE 0
#endif
// See https://mongoose.ws/documentation/#build-options

// If we could guess an MG_ARCH so far, preserve it, otherwise try GCC-based
#if defined(MG_ARCH)
#define MG_STMPACK_ARCH MG_ARCH
#undef MG_ARCH
#elif defined(__GNUC__)
#define MG_STMPACK_ARCH MG_ARCH_NEWLIB
#endif

#define MG_ENABLE_PACKED_FS 1
#define MG_ENABLE_CUSTOM_MILLIS 1
#define MG_ENABLE_MBEDTLS 0
#define MG_ARCH MG_STMPACK_ARCH
#define MG_STMPACK_NET 0
#define MG_ENABLE_CUSTOM_RANDOM 1

// Translate to Mongoose macros
#if MG_CMSISPACK_NET == 0
#define MG_ENABLE_TCPIP 1
#elif MG_CMSISPACK_NET == 1
#define MG_ENABLE_LWIP 1
#elif MG_CMSISPACK_NET == 2
#define MG_ENABLE_FREERTOS_TCP 1
#elif MG_CMSISPACK_NET == 3
#define MG_ENABLE_RL 1
#endif

#if MG_ENABLE_PACKED_FS
#define MG_ENABLE_POSIX_FS 0
#endif

// See https://mongoose.ws/documentation/#build-options
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
// If we could guess an MG_ARCH so far, preserve it, otherwise try GCC-based
#if defined(MG_ARCH)
#define MG_STMPACK_ARCH MG_ARCH
#undef MG_ARCH
#elif defined(__GNUC__)
#define MG_STMPACK_ARCH MG_ARCH_NEWLIB
#endif
#define MG_ENABLE_PACKED_FS 1
#define MG_ENABLE_CUSTOM_MILLIS 0
#define MG_ENABLE_MBEDTLS 0
#define MG_ARCH MG_ARCH_CMSIS_RTOS2
#define MG_STMPACK_NET 0
#define MG_ENABLE_CUSTOM_RANDOM 1
// Translate to Mongoose macros
#if MG_STMPACK_NET == 0
#define MG_ENABLE_TCPIP 1
#elif MG_STMPACK_NET == 1
#define MG_ENABLE_LWIP 1
#elif MG_STMPACK_NET == 2
#define MG_ENABLE_FREERTOS_TCP 1
#elif MG_STMPACK_NET == 3
#define MG_ENABLE_RL 1
#endif
#if MG_ENABLE_PACKED_FS
#define MG_ENABLE_FILE 0
#endif
// See https://mongoose.ws/documentation/#build-options

// If we could guess an MG_ARCH so far, preserve it, otherwise try GCC-based
#if defined(MG_ARCH)
#define MG_STMPACK_ARCH MG_ARCH
#undef MG_ARCH
#elif defined(__GNUC__)
#define MG_STMPACK_ARCH MG_ARCH_NEWLIB
#endif

#define MG_ENABLE_PACKED_FS 1
#define MG_ENABLE_CUSTOM_MILLIS 0
#define MG_ENABLE_MBEDTLS 0
#define MG_ARCH MG_ARCH_CMSIS_RTOS2
#define MG_STMPACK_NET 0
#define MG_ENABLE_CUSTOM_RANDOM 1

// Translate to Mongoose macros
#if MG_STMPACK_NET == 0
#define MG_ENABLE_TCPIP 1
#elif MG_STMPACK_NET == 1
#define MG_ENABLE_LWIP 1
#elif MG_STMPACK_NET == 2
#define MG_ENABLE_FREERTOS_TCP 1
#elif MG_STMPACK_NET == 3
#define MG_ENABLE_RL 1
#endif

#if MG_ENABLE_PACKED_FS
#define MG_ENABLE_POSIX_FS 0
#endif

// See https://mongoose.ws/documentation/#build-options
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
// If we could guess an MG_ARCH so far, preserve it, otherwise try GCC-based
#if defined(MG_ARCH)
#define MG_STMPACK_ARCH MG_ARCH
#undef MG_ARCH
#elif defined(__GNUC__)
#define MG_STMPACK_ARCH MG_ARCH_NEWLIB
#endif
#define MG_ENABLE_PACKED_FS 1
#define MG_ENABLE_CUSTOM_MILLIS 0
#define MG_ENABLE_MBEDTLS 0
#define MG_ARCH MG_ARCH_FREERTOS
#define MG_STMPACK_NET 1
#define MG_ENABLE_CUSTOM_RANDOM 1
// Translate to Mongoose macros
#if MG_STMPACK_NET == 0
#define MG_ENABLE_TCPIP 1
#elif MG_STMPACK_NET == 1
#define MG_ENABLE_LWIP 1
#elif MG_STMPACK_NET == 2
#define MG_ENABLE_FREERTOS_TCP 1
#elif MG_STMPACK_NET == 3
#define MG_ENABLE_RL 1
#endif
#if MG_ENABLE_PACKED_FS
#define MG_ENABLE_FILE 0
#endif
// See https://mongoose.ws/documentation/#build-options

// If we could guess an MG_ARCH so far, preserve it, otherwise try GCC-based
#if defined(MG_ARCH)
#define MG_STMPACK_ARCH MG_ARCH
#undef MG_ARCH
#elif defined(__GNUC__)
#define MG_STMPACK_ARCH MG_ARCH_NEWLIB
#endif

#define MG_ENABLE_PACKED_FS 1
#define MG_ENABLE_CUSTOM_MILLIS 0
#define MG_ENABLE_MBEDTLS 0
#define MG_ARCH MG_ARCH_FREERTOS
#define MG_STMPACK_NET 1
#define MG_ENABLE_CUSTOM_RANDOM 1

// Translate to Mongoose macros
#if MG_STMPACK_NET == 0
#define MG_ENABLE_TCPIP 1
#elif MG_STMPACK_NET == 1
#define MG_ENABLE_LWIP 1
#elif MG_STMPACK_NET == 2
#define MG_ENABLE_FREERTOS_TCP 1
#elif MG_STMPACK_NET == 3
#define MG_ENABLE_RL 1
#endif

#if MG_ENABLE_PACKED_FS
#define MG_ENABLE_POSIX_FS 0
#endif

// See https://mongoose.ws/documentation/#build-options
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
// If we could guess an MG_ARCH so far, preserve it, otherwise try GCC-based
#if defined(MG_ARCH)
#define MG_STMPACK_ARCH MG_ARCH
#undef MG_ARCH
#elif defined(__GNUC__)
#define MG_STMPACK_ARCH MG_ARCH_NEWLIB
#endif
#define MG_ENABLE_PACKED_FS 1
#define MG_ENABLE_CUSTOM_MILLIS 1
#define MG_ENABLE_MBEDTLS 0
#define MG_ARCH MG_STMPACK_ARCH
#define MG_STMPACK_NET 0
#define MG_ENABLE_CUSTOM_RANDOM 1
// Translate to Mongoose macros
#if MG_CMSISPACK_NET == 0
#define MG_ENABLE_TCPIP 1
#elif MG_CMSISPACK_NET == 1
#define MG_ENABLE_LWIP 1
#elif MG_CMSISPACK_NET == 2
#define MG_ENABLE_FREERTOS_TCP 1
#elif MG_CMSISPACK_NET == 3
#define MG_ENABLE_RL 1
#endif
#if MG_ENABLE_PACKED_FS
#define MG_ENABLE_FILE 0
#endif
// See https://mongoose.ws/documentation/#build-options

// If we could guess an MG_ARCH so far, preserve it, otherwise try GCC-based
#if defined(MG_ARCH)
#define MG_STMPACK_ARCH MG_ARCH
#undef MG_ARCH
#elif defined(__GNUC__)
#define MG_STMPACK_ARCH MG_ARCH_NEWLIB
#endif

#define MG_ENABLE_PACKED_FS 1
#define MG_ENABLE_CUSTOM_MILLIS 1
#define MG_ENABLE_MBEDTLS 0
#define MG_ARCH MG_STMPACK_ARCH
#define MG_STMPACK_NET 0
#define MG_ENABLE_CUSTOM_RANDOM 1

// Translate to Mongoose macros
#if MG_CMSISPACK_NET == 0
#define MG_ENABLE_TCPIP 1
#elif MG_CMSISPACK_NET == 1
#define MG_ENABLE_LWIP 1
#elif MG_CMSISPACK_NET == 2
#define MG_ENABLE_FREERTOS_TCP 1
#elif MG_CMSISPACK_NET == 3
#define MG_ENABLE_RL 1
#endif

#if MG_ENABLE_PACKED_FS
#define MG_ENABLE_POSIX_FS 0
#endif

// See https://mongoose.ws/documentation/#build-options
Original file line number Diff line number Diff line change
@@ -1,32 +1,32 @@
// If we could guess an MG_ARCH so far, preserve it, otherwise try GCC-based
#if defined(MG_ARCH)
#define MG_STMPACK_ARCH MG_ARCH
#undef MG_ARCH
#elif defined(__GNUC__)
#define MG_STMPACK_ARCH MG_ARCH_NEWLIB
#endif
#define MG_ENABLE_PACKED_FS 1
#define MG_ENABLE_CUSTOM_MILLIS 0
#define MG_ENABLE_MBEDTLS 0
#define MG_ARCH MG_ARCH_CMSIS_RTOS2
#define MG_STMPACK_NET 0
#define MG_ENABLE_CUSTOM_RANDOM 1
// Translate to Mongoose macros
#if MG_STMPACK_NET == 0
#define MG_ENABLE_TCPIP 1
#elif MG_STMPACK_NET == 1
#define MG_ENABLE_LWIP 1
#elif MG_STMPACK_NET == 2
#define MG_ENABLE_FREERTOS_TCP 1
#elif MG_STMPACK_NET == 3
#define MG_ENABLE_RL 1
#endif
#if MG_ENABLE_PACKED_FS
#define MG_ENABLE_FILE 0
#endif
// See https://mongoose.ws/documentation/#build-options

// If we could guess an MG_ARCH so far, preserve it, otherwise try GCC-based
#if defined(MG_ARCH)
#define MG_STMPACK_ARCH MG_ARCH
#undef MG_ARCH
#elif defined(__GNUC__)
#define MG_STMPACK_ARCH MG_ARCH_NEWLIB
#endif

#define MG_ENABLE_PACKED_FS 1
#define MG_ENABLE_CUSTOM_MILLIS 0
#define MG_ENABLE_MBEDTLS 0
#define MG_ARCH MG_ARCH_CMSIS_RTOS2
#define MG_STMPACK_NET 0
#define MG_ENABLE_CUSTOM_RANDOM 1

// Translate to Mongoose macros
#if MG_STMPACK_NET == 0
#define MG_ENABLE_TCPIP 1
#elif MG_STMPACK_NET == 1
#define MG_ENABLE_LWIP 1
#elif MG_STMPACK_NET == 2
#define MG_ENABLE_FREERTOS_TCP 1
#elif MG_STMPACK_NET == 3
#define MG_ENABLE_RL 1
#endif

#if MG_ENABLE_PACKED_FS
#define MG_ENABLE_POSIX_FS 0
#endif

// See https://mongoose.ws/documentation/#build-options
Loading
Loading