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

Disabling IPV4 causes compilation errors (IDFGH-12116) #64

Closed
ShubhadaHarkut-eaton opened this issue Feb 13, 2024 · 5 comments
Closed

Comments

@ShubhadaHarkut-eaton
Copy link

Disabling IVP4 and building the idf ethernet example code only with IPV6 support enabled leading to many compilation error
idf version used : 4.4
os : windows
ESP : ESP32-WROVER-B

disabling LWIP_IPV4 in opts.h and enabling LWIP_IPV6 in the same file along with other menuconfig configurations for rnabling IPV6

@ShubhadaHarkut-eaton ShubhadaHarkut-eaton changed the title Use only IPV6 Disabling IPV4 causes compilation errors Feb 13, 2024
@github-actions github-actions bot changed the title Disabling IPV4 causes compilation errors Disabling IPV4 causes compilation errors (IDFGH-12116) Feb 13, 2024
@espressif-abhikroy
Copy link
Collaborator

Hi @ShubhadaHarkut-eaton,
The option to disable IPv4 is not available for IDF release v4.4 and v5.0.
It's available from IDF release v5.1 onwards.

@ShubhadaHarkut-eaton
Copy link
Author

Hi @espressif-abhikroy
Any idea if any one has tried esp32 with ipv6 configuration as wireguard client ?

@espressif-abhikroy
Copy link
Collaborator

Sorry, I am not aware of such usage.

@sgryphon
Copy link

I am not sure if it is relevant for your scenario, but I recently put up a pull request to update the protocol examples to work with all/any network configuration. The branch is here: espressif/esp-idf#13250

The update examples work out of the box (no config or code changes) with all network types: IPv4-only, IPv6-only, and dual stack. (You do need to provide config for things like your WiFi password)

Note that this is not the same as turning off IPv4 -- IPv4 is still turned on, just not used. The updated example works in an IPv6-only network, if that is your objective. See the example outputs for IPv6-only network. If you have DNS64/NAT64 available, then it can even connect from an IPv6-only network to an IPv4-only server.

However, IPv4 is still actually on.

If you know IPv4 is not necessary, e.g. if you are developing a Matter device where only IPv6 is required, and want to reduce memory size and development/testing effort, then you could also turn off IPv4 completely. I also tested this scenario (current LWIP/IDF) and found a small compilation bug in the PPP code used in the examples -- this is also fixed in my PR branch, i.e. it does compile with IPv4 turn off (although there is no need to, as the examples works fine in an IPv6-only network without config changes).

@david-cermak
Copy link
Collaborator

Closing as won't do, as IPv4-only is supported from v5.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants