#include <env_internal.h>
#endif
-#ifdef CONFIG_NET
+#if CONFIG_IS_ENABLED(NET) || CONFIG_IS_ENABLED(NET_LWIP)
#define ENV_FLAGS_NET_VARTYPE_REPS "im"
#else
#define ENV_FLAGS_NET_VARTYPE_REPS ""
"decimal",
"hexadecimal",
"boolean",
-#ifdef CONFIG_NET
+#if CONFIG_IS_ENABLED(NET) || CONFIG_IS_ENABLED(NET_LWIP)
"IP address",
"MAC address",
#endif
*end = value;
}
-#ifdef CONFIG_NET
+#if CONFIG_IS_ENABLED(NET) || CONFIG_IS_ENABLED(NET_LWIP)
int eth_validate_ethaddr_str(const char *addr)
{
const char *end;
enum env_flags_vartype type)
{
const char *end;
-#ifdef CONFIG_NET
+#if CONFIG_IS_ENABLED(NET) || CONFIG_IS_ENABLED(NET_LWIP)
const char *cur;
int i;
#endif
if (value[1] != '\0')
return -1;
break;
-#ifdef CONFIG_NET
+#if CONFIG_IS_ENABLED(NET) || CONFIG_IS_ENABLED(NET_LWIP)
case env_flags_vartype_ipaddr:
cur = value;
for (i = 0; i < 4; i++) {
env_flags_vartype_decimal,
env_flags_vartype_hex,
env_flags_vartype_bool,
-#ifdef CONFIG_NET
+#if CONFIG_IS_ENABLED(NET) || CONFIG_IS_ENABLED(NET_LWIP)
env_flags_vartype_ipaddr,
env_flags_vartype_macaddr,
#endif
#define CFG_ENV_FLAGS_LIST_STATIC ""
#endif
-#ifdef CONFIG_NET
+#if CONFIG_IS_ENABLED(NET) || CONFIG_IS_ENABLED(NET_LWIP)
#ifdef CONFIG_REGEX
#define ETHADDR_WILDCARD "\\d*"
#else
*/
enum env_flags_varaccess env_flags_parse_varaccess_from_binflags(int binflags);
-#ifdef CONFIG_NET
+#if CONFIG_IS_ENABLED(NET) || CONFIG_IS_ENABLED(NET_LWIP)
/*
* Check if a string has the format of an Ethernet MAC address
*/