[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-users] Compile problem: #define NO_SYS 1, tcp_timer_needed macro i
From: |
Bob Ammerman |
Subject: |
[lwip-users] Compile problem: #define NO_SYS 1, tcp_timer_needed macro issue. |
Date: |
Mon, 15 Nov 2004 16:18:32 -0500 |
Hi,
I am building LWIP from 1.0.0 sources using Visual C 6.0. I have placed
#define NO_SYS 1
in my 'cc.h' file.
I get the warning:
C:\cust\SCI\lwip\lwip\src\api\tcpip.c(72) : warning C4002: too many actual
parameters for macro 'tcp_timer_needed'
followed by the error:
C:\cust\SCI\lwip\lwip\src\api\tcpip.c(73) : error C2059: syntax error : '{'
when compiling 'tcpip.c'.
Upon investigation I find the following code in tcp.h
#if NO_SYS
#define tcp_timer_needed()
#else
void tcp_timer_needed(void);
#endif
Which defines 'tcp_timer_needed' as a zero argument macro.
However, the code in 'tcpip.c' where I encounter the error looks like:
void
tcp_timer_needed(void)
{
....body of function....
}
Which, after macro substitution looks like:
void
{
....body of function....
}
Which is obviously broken.
For now, I am going to just use '#if !NO_SYS' to conditionalize the
definition of 'tcp_timer_needed' in tcpip.c. However, I do not want to have
to leave my own tweak in a standard LWIP module.
Anybody have a better idea??
Bob Ammerman
RAm Systems
- [lwip-users] Compile problem: #define NO_SYS 1, tcp_timer_needed macro issue.,
Bob Ammerman <=