aboutsummaryrefslogtreecommitdiff
path: root/emulators/wxmupen64plus/files/patch-wscript
blob: 9bb0a4a2d6ce6283210fa6cd1bdaea736f11b456 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
--- wscript.orig	2012-03-18 17:28:41.000000000 -0500
+++ wscript	2013-10-04 20:56:33.000000000 -0500
@@ -83,14 +83,13 @@
     ctx.env['datadir'] = Options.options.datadir
     ctx.env['libdir'] = Options.options.libdir
     
-    ctx.find_program('gcc', var='GCC', mandatory=True)
-    ctx.find_program('g++', var='GPP', mandatory=True)
+    ctx.find_program('%%CC%%', var='GCC', mandatory=True)
+    ctx.find_program('%%CXX%%', var='GPP', mandatory=True)
     ctx.check_cc(header_name="stdio.h", function_name='printf', msg='Checking C compiler works', errmsg="No")
     ctx.check_cxx(header_name="cstdio", function_name='printf', msg='Checking C++ compiler works', errmsg="No")
     ctx.check_cc(header_name="m64p_frontend.h",   includes=[api_path])
     ctx.check_cc(header_name="m64p_config.h",     includes=[api_path])
     ctx.check_cc(header_name="m64p_types.h",      includes=[api_path])
-    ctx.check_cc(header_name="../main/version.h", includes=[api_path])
 
     ctx.check_cfg(path=sdl_config, args='--cflags --libs',   package='', uselib_store='SDL')
     
@@ -99,20 +98,7 @@
             ctx.fatal("On Windows, the --wxhome argument is mandatory")
         ctx.check_cfg(msg="Checking for wxWidgets 2.9.x", path=wx_config,  args='--version=2.9 --cxxflags --prefix=' + wxhome + ' ' + wxconfig_args + ' --libs core,base,gl,html', package='', uselib_store='wxWidgets')
     else:
-        ctx.check_cfg(msg="Checking for wxWidgets 2.9.x", path=wx_config,  args='--version=2.9 --cxxflags --libs core,base,gl,html ' + wxconfig_args, package='', uselib_store='wxWidgets')
-
-    ctx.check_cc(compile_filename='test.c', execute=False, cflags=["-I"+api_path], msg="Checking mupen64plus is recent enough...", fragment=
-"""#include "../main/version.h"
-   #if FRONTEND_API_VERSION < 0x020001
-   #error Your mupen64plus build is too old, please upgrade
-   #endif
-   #if CONFIG_API_VERSION < 0x020000
-   #error Your mupen64plus build is too old, please upgrade
-   #endif
-   #if VIDEXT_API_VERSION < 0x020000
-   #error Your mupen64plus build is too old, please upgrade
-   #endif
-   int main(int argc, char** argv) {}""")
+        ctx.check_cfg(msg="Checking for wxWidgets 2.9.x", path=wx_config,  args='--version=2.9 --cxxflags --libs adv,core,base,gl,html ' + wxconfig_args, package='', uselib_store='wxWidgets')
 
 # --------------------------------------------------------------------------------------------
 #                                            BUILD