Skip to content

Commit

Permalink
Abort compile when attempting to build client with Irrlicht 1.8.2
Browse files Browse the repository at this point in the history
  • Loading branch information
kwolekr committed Nov 9, 2015
1 parent 88a3977 commit 889f893
Showing 1 changed file with 13 additions and 6 deletions.
19 changes: 13 additions & 6 deletions src/main.cpp
Expand Up @@ -18,11 +18,11 @@ with this program; if not, write to the Free Software Foundation, Inc.,
*/

#ifdef _MSC_VER
#ifndef SERVER // Dedicated server isn't linked with Irrlicht
#pragma comment(lib, "Irrlicht.lib")
// This would get rid of the console window
//#pragma comment(linker, "/subsystem:windows /ENTRY:mainCRTStartup")
#endif
#ifndef SERVER // Dedicated server isn't linked with Irrlicht
#pragma comment(lib, "Irrlicht.lib")
// This would get rid of the console window
//#pragma comment(linker, "/subsystem:windows /ENTRY:mainCRTStartup")
#endif
#pragma comment(lib, "zlibwapi.lib")
#pragma comment(lib, "Shell32.lib")
#endif
Expand Down Expand Up @@ -59,7 +59,14 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#endif

#ifdef HAVE_TOUCHSCREENGUI
#include "touchscreengui.h"
#include "touchscreengui.h"
#endif

#if !defined(SERVER) && \
(IRRLICHT_VERSION_MAJOR == 1) && \
(IRRLICHT_VERSION_MINOR == 8) && \
(IRRLICHT_VERSION_REVISION == 2)
#error "Irrlicht 1.8.2 is known to be broken - please update Irrlicht to version >= 1.8.3"
#endif

#define DEBUGFILE "debug.txt"
Expand Down

4 comments on commit 889f893

@sofar
Copy link
Contributor

@sofar sofar commented on 889f893 Nov 9, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 ;^)

@HybridDog
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please test the other way round (IRRLICHT_VERSION_REVISION == 2 first, …), l guess 1.8.* often appears but * .*.2 seldom appears.

@est31
Copy link
Contributor

@est31 est31 commented on 889f893 Nov 13, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd consider that less readable. The way @kwolekr did it was completely okay.

@est31
Copy link
Contributor

@est31 est31 commented on 889f893 Nov 13, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And don't overcomplicate version recognition #ifdefs, after all a broken ifdef version recognition is why 1.8.2 is a broken release.

Please sign in to comment.