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

How I can use #if define for checking major version of lwip? #10

Open
TridentTD opened this issue Jan 8, 2018 · 2 comments
Open

How I can use #if define for checking major version of lwip? #10

TridentTD opened this issue Jan 8, 2018 · 2 comments

Comments

@TridentTD
Copy link

Is there any #define for seperating lwip v1.4 and lwip2?

Thank you.

@d-a-v
Copy link
Owner

d-a-v commented Jan 9, 2018

yes

#include <lwip/init.h>
#if LWIP_VERSION_MAJOR == 2

#warning v2
const int v = 2;

#elif LWIP_VERSION_MAJOR == 1

#warning v1
const int v = 1;

#else
#error LWIP_VERSION_MAJOR not defined
#endif

@TridentTD
Copy link
Author

Thank you @d-a-v

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

No branches or pull requests

2 participants