1
0
Fork 0

Fix build for windows after logstream changes

This commit is contained in:
Frederic Bouvier 2013-02-08 08:46:34 +01:00
parent c0173cf2b5
commit 7cc3ffb30f
4 changed files with 13 additions and 2 deletions

View file

@ -30,6 +30,10 @@
# include <config.h>
#endif
#ifdef HAVE_WINDOWS_H
#include <windows.h>
#endif
#include <simgear/compiler.h>
#include <fstream>

View file

@ -125,7 +125,6 @@ int main ( int argc, char **argv );
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,
LPSTR lpCmdLine, int nCmdShow) {
logbuf::has_no_console();
main( __argc, __argv );
}
#endif

View file

@ -18,6 +18,10 @@
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif
#ifdef HAVE_WINDOWS_H
#include <windows.h>
#endif

View file

@ -3,6 +3,10 @@
# include "config.h"
#endif
#ifdef HAVE_WINDOWS_H
#include <windows.h>
#endif
#ifdef HAVE_SYS_TIME_H
# include <sys/time.h> // gettimeofday
#endif
@ -330,7 +334,7 @@ static naRef f_logprint(naContext c, naRef me, int argc, naRef* args)
if(naIsNil(s)) continue;
buf += naStr_data(s);
}
SG_LOG(SG_NASAL, (sgDebugPriority) priority.num, buf);
SG_LOG(SG_NASAL, (sgDebugPriority)(int) priority.num, buf);
return naNum(buf.length());
}