Windows users: see https://github.com/wraitii/0ad/tree/sm68
These are the build system changes necessary for SM68. A few new patches, some fixed upstream.
Differential D3143
[SM68] Build system changes wraitii on Nov 25 2020, 3:42 PM. Authored by
Details
Windows users: see https://github.com/wraitii/0ad/tree/sm68 These are the build system changes necessary for SM68. A few new patches, some fixed upstream. Compile on all major platforms.
Diff Detail
Event TimelineComment Actions Build failure - The Moirai have given mortals hearts that can endure. Link to build: https://jenkins.wildfiregames.com/job/docker-differential/3769/display/redirect Comment Actions Build failure - The Moirai have given mortals hearts that can endure. Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/3217/display/redirect
Comment Actions I needed to install the llvm and rustc package now. And autoconf2.13 is no longer needed. Lubuntu 18.04, GCC 7.5. Comment Actions Build failure - The Moirai have given mortals hearts that can endure. Link to build: https://jenkins.wildfiregames.com/job/vs2015-differential/3270/display/redirect Comment Actions Build failure - The Moirai have given mortals hearts that can endure. builderr-debug-macos.txt In file included from ../../../source/network/NetClient.cpp:20: In file included from ../../../source/network/NetClient.h:24: ../../../source/scriptinterface/ScriptInterface.h:84:2: error: unknown type name 'JSCompartment'; did you mean 'JS::Compartment'? JSCompartment* m_formerCompartment; ^~~~~~~~~~~~~ JS::Compartment ../../../libraries/source/spidermonkey/include-unix-debug/js/RealmOptions.h:27:21: note: 'JS::Compartment' declared here class JS_PUBLIC_API Compartment; ^ In file included from ../../../source/network/NetClientTurnManager.cpp:21: In file included from ../../../source/network/NetClient.h:24: ../../../source/scriptinterface/ScriptInterface.h:84:2: error: unknown type name 'JSCompartment'; did you mean 'JS::Compartment'? JSCompartment* m_formerCompartment; ^~~~~~~~~~~~~ JS::Compartment ../../../libraries/source/spidermonkey/include-unix-debug/js/RealmOptions.h:27:21: note: 'JS::Compartment' declared here class JS_PUBLIC_API Compartment; ^ In file included from ../../../source/network/NetClient.cpp:20: In file included from ../../../source/network/NetClient.h:24: ../../../source/scriptinterface/ScriptInterface.h:333:37: error: use of undeclared identifier 'JSStructuredCloneData' using StructuredClone = shared_ptr<JSStructuredCloneData>; ^ In file included from ../../../source/network/NetClientTurnManager.cpp:21: In file included from ../../../source/network/NetClient.h:24: ../../../source/scriptinterface/ScriptInterface.h:333:37: error: use of undeclared identifier 'JSStructuredCloneData' using StructuredClone = shared_ptr<JSStructuredCloneData>; ^ ../../../source/scriptinterface/ScriptInterface.h:335:2: error: unknown type name 'StructuredClone' StructuredClone WriteStructuredClone(JS::HandleValue v, bool sameThread) const; ^ ../../../source/scriptinterface/ScriptInterface.h:335:2: error: unknown type name 'StructuredClone' StructuredClone WriteStructuredClone(JS::HandleValue v, bool sameThread) const; ^ ../../../source/scriptinterface/ScriptInterface.h:336:33: error: unknown type name 'StructuredClone' void ReadStructuredClone(const StructuredClone& ptr, JS::MutableHandleValue ret) const; ^ ../../../source/scriptinterface/ScriptInterface.h:336:33: error: unknown type name 'StructuredClone' void ReadStructuredClone(const StructuredClone& ptr, JS::MutableHandleValue ret) const; ^ In file included from ../../../source/network/NetClient.cpp:20: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:164:64: error: no type named 'AutoValueVector' in namespace 'JS'; did you mean 'ValueVector'? static void AssignOrToJSValHelper(const ScriptRequest& rq, JS::AutoValueVector& argv, const T& a, const Ts&... params) ~~~~^~~~~~~~~~~~~~~ ValueVector ../../../libraries/source/spidermonkey/include-unix-debug/jsapi.h:95In file included from :7: note: 'ValueVector' declared here using ValueVector = JS::GCVector<JS::Value>; ^ ../../../source/network/NetClientTurnManager.cpp:21: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:164:64: error: no type named 'AutoValueVector' in namespace 'JS'; did you mean 'ValueVector'? static void AssignOrToJSValHelper(const ScriptRequest& rq, JS::AutoValueVector& argv, const T& a, const Ts&... params) ~~~~^~~~~~~~~~~~~~~ ValueVector ../../../libraries/source/spidermonkey/include-unix-debug/jsapi.h:95:7: note: 'ValueVector' declared here using ValueVector = JS::GCVector<JS::Value>; ^ In file included from ../../../source/network/NetClient.cpp:20: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:171:72: error: no type named 'AutoValueVector' in namespace 'JS'; did you mean 'ValueVector'? static void AssignOrToJSValHelper(const ScriptRequest& UNUSED(rq), JS::AutoValueVector& UNUSED(argv)) ~~~~^~~~~~~~~~~~~~~ ValueVector ../../../libraries/source/spidermonkey/include-unix-debug/jsapi.h:95:7: note: 'ValueVector' declared here using ValueVector = JS::GCVector<JS::Value>; ^ In file included from ../../../source/network/NetClientTurnManager.cpp:21: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:171:72: error: no type named 'AutoValueVector' in namespace 'JS'; did you mean 'ValueVector'? static void AssignOrToJSValHelper(const ScriptRequest& UNUSED(rq), JS::AutoValueVector& UNUSED(argv)) ~~~~^~~~~~~~~~~~~~~ ValueVector ../../../libraries/source/spidermonkey/include-unix-debug/jsapi.h:95:7: note: 'ValueVector' declared here using ValueVector = JS::GCVector<JS::Value>; ^ In file included from ../../../source/network/NetClient.cpp:20: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:182:21: error: expected ';' after expression JS::AutoValueVector argv(rq.cx); ^ ; In file included from ../../../source/network/NetClientTurnManager.cpp:21: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:182:21: error: expected ';' after expression JS::AutoValueVector argv(rq.cx); ^ ; ../../../source/scriptinterface/NativeWrapperDefns.h:182:6: error: no member named 'AutoValueVector' in namespace 'JS' ../../../source/scriptinterface/NativeWrapperDefns.h:182:6: error: no member named 'AutoValueVector' in namespace 'JS' JS::AutoValueVector argv(rq.cx); ~~~~^ JS::AutoValueVector argv(rq.cx); ~~~~^ ../../../source/scriptinterface/NativeWrapperDefns.h:182:22: error: use of undeclared identifier 'argv' JS::AutoValueVector argv(rq.cx); ^ ../../../source/scriptinterface/NativeWrapperDefns.h:182:22: error: use of undeclared identifier 'argv' JS::AutoValueVector argv(rq.cx); ^ ../../../source/scriptinterface/NativeWrapperDefns.h:183:10: error: use of undeclared identifier 'argv' DISCARD argv.resize(sizeof...(Ts)); ^ ../../../source/scriptinterface/NativeWrapperDefns.h:183:10: error: use of undeclared identifier 'argv' DISCARD argv.resize(sizeof...(Ts)); ^ ../../../source/scriptinterface/NativeWrapperDefns.h:184:31: error: use of undeclared identifier 'argv'; did you mean 'nargs'? AssignOrToJSValHelper<0>(rq, argv, params...); ^~~~ nargs ../../../source/scriptinterface/NativeWrapperDecls.h:93:15: note: 'nargs' declared here static size_t nargs() { return sizeof...(Ts); } ^ ../../../source/scriptinterface/NativeWrapperDefns.h:184:31: error: use of undeclared identifier 'argv'; did you mean 'nargs'? AssignOrToJSValHelper<0>(rq, argv, params...); ^~~~ nargs ../../../source/scriptinterface/NativeWrapperDecls.h:93:15: note: 'nargs' declared here static size_t nargs() { return sizeof...(Ts); } ^ In file included from ../../../source/network/NetClient.cpp:20: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:185:32: error: use of undeclared identifier 'argv' if (!CallFunction_(val, name, argv, &jsRet)) ^ In file included from ../../../source/network/NetClientTurnManager.cpp:21: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:185:32: error: use of undeclared identifier 'argv' if (!CallFunction_(val, name, argv, &jsRet)) ^ ../../../source/scriptinterface/NativeWrapperDefns.h:195:21: error: expected ';' after expression JS::AutoValueVector argv(rq.cx); ^ ; ../../../source/scriptinterface/NativeWrapperDefns.h:195:6: error: no member named 'AutoValueVector' in namespace 'JS' JS::AutoValueVector argv(rq.cx); ~~~~^ ../../../source/scriptinterface/NativeWrapperDefns.h:195:21: error: expected ';' after expression JS::AutoValueVector argv(rq.cx); ^ ; ../../../source/scriptinterface/NativeWrapperDefns.h:195:6: error: no member named 'AutoValueVector' in namespace 'JS' JS::AutoValueVector argv(rq.cx); ~~~~^ ../../../source/scriptinterface/NativeWrapperDefns.h:195:22: error: use of undeclared identifier 'argv' JS::AutoValueVector argv(rq.cx); ^ ../../../source/scriptinterface/NativeWrapperDefns.h:195:22: error: use of undeclared identifier 'argv' JS::AutoValueVector argv(rq.cx); ^ ../../../source/scriptinterface/NativeWrapperDefns.h:196:10: error: use of undeclared identifier 'argv' DISCARD argv.resize(sizeof...(Ts)); ^ ../../../source/scriptinterface/NativeWrapperDefns.h:196:10: error: use of undeclared identifier 'argv' DISCARD argv.resize(sizeof...(Ts)); ^ ../../../source/scriptinterface/NativeWrapperDefns.h:197:31: error: use of undeclared identifier 'argv'; did you mean 'nargs'? AssignOrToJSValHelper<0>(rq, argv, params...); ^~~~ nargs ../../../source/scriptinterface/NativeWrapperDecls.h:93:15: note: 'nargs' declared here static size_t nargs() { return sizeof...(Ts); } ^ ../../../source/scriptinterface/NativeWrapperDefns.h:197:31: error: use of undeclared identifier 'argv'; did you mean 'nargs'? AssignOrToJSValHelper<0>(rq, argv, params...); ^~~~ nargs ../../../source/scriptinterface/NativeWrapperDecls.h:93:15: note: 'nargs' declared here static size_t nargs() { return sizeof...(Ts); } ^ In file included from ../../../source/network/NetClient.cpp:20: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:198:34: error: use of undeclared identifier 'argv'; did you mean 'nargs'? return CallFunction_(val, name, argv, jsRet); ^~~~ nargs ../../../source/scriptinterface/NativeWrapperDecls.h:93:15: note: 'nargs' declared here static size_t nargs() { return sizeof...(Ts); } ^ In file included from ../../../source/network/NetClientTurnManager.cpp:21: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:198:34: error: use of undeclared identifier 'argv'; did you mean 'nargs'? return CallFunction_(val, name, argv, jsRet); ^~~~ nargs ../../../source/scriptinterface/NativeWrapperDecls.h:93:15: note: 'nargs' declared here static size_t nargs() { return sizeof...(Ts); } ^ In file included from ../../../source/network/NetClient.cpp:20: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:205:21: error: expected ';' after expression JS::AutoValueVector argv(rq.cx); ^ ; fatal error: too many errors emitted, stopping now [-ferror-limit=] In file included from ../../../source/network/NetClientTurnManager.cpp:21: In file included from ../../../source/network/NetClient.h:24: In file included from ../../../source/scriptinterface/ScriptInterface.h:486: ../../../source/scriptinterface/NativeWrapperDefns.h:205:21: error: expected ';' after expression JS::AutoValueVector argv(rq.cx); ^ ; fatal error: too many errors emitted, stopping now [-ferror-limit=] 20 errors generated. make[1]: *** [obj/network_Debug/NetClientTurnManager.o] Error 1 make[1]: *** Waiting for unfinished jobs.... 20 errors generated. make[1]: *** [obj/network_Debug/NetClient.o] Error 1 make: *** [network] Error 2 Link to build: https://jenkins.wildfiregames.com/job/macos-differential/2174/display/redirect Comment Actions Build failure - The Moirai have given mortals hearts that can endure. builderr-debug-gcc7.txt In file included from ../../../source/network/NetClient.h:24, from ../../../source/network/NetClient.cpp:20: ../../../source/scriptinterface/ScriptInterface.h:84:2: error: 'JSCompartment' does not name a type; did you mean 'JSContext'? JSCompartment* m_formerCompartment; ^~~~~~~~~~~~~ JSContext In file included from ../../../source/network/NetClient.h:24, from ../../../source/network/NetClient.cpp:20: ../../../source/scriptinterface/ScriptInterface.h:333:37: error: 'JSStructuredCloneData' was not declared in this scope using StructuredClone = shared_ptr<JSStructuredCloneData>; ^~~~~~~~~~~~~~~~~~~~~ ../../../source/scriptinterface/ScriptInterface.h:333:37: note: suggested alternative: 'JSStructuredCloneWriter' using StructuredClone = shared_ptr<JSStructuredCloneData>; ^~~~~~~~~~~~~~~~~~~~~ JSStructuredCloneWriter ../../../source/scriptinterface/ScriptInterface.h:333:58: error: template argument 1 is invalid using StructuredClone = shared_ptr<JSStructuredCloneData>; ^ ../../../source/scriptinterface/ScriptInterface.h:335:2: error: 'StructuredClone' does not name a type; did you mean 'JSStructuredCloneWriter'? StructuredClone WriteStructuredClone(JS::HandleValue v, bool sameThread) const; ^~~~~~~~~~~~~~~ JSStructuredCloneWriter ../../../source/scriptinterface/ScriptInterface.h:336:33: error: 'StructuredClone' does not name a type; did you mean 'JSStructuredCloneWriter'? void ReadStructuredClone(const StructuredClone& ptr, JS::MutableHandleValue ret) const; ^~~~~~~~~~~~~~~ JSStructuredCloneWriter In file included from ../../../source/scriptinterface/ScriptInterface.h:486, from ../../../source/network/NetClient.h:24, from ../../../source/network/NetClient.cpp:20: ../../../source/scriptinterface/NativeWrapperDefns.h:164:64: error: 'JS::AutoValueVector' has not been declared static void AssignOrToJSValHelper(const ScriptRequest& rq, JS::AutoValueVector& argv, const T& a, const Ts&... params) ^~~~~~~~~~~~~~~ ../../../source/scriptinterface/NativeWrapperDefns.h: In function 'void AssignOrToJSValHelper(const ScriptRequest&, int&, const T&, const Ts& ...)': ../../../source/scriptinterface/NativeWrapperDefns.h:166:45: error: invalid types 'int[int]' for array subscript ScriptInterface::AssignOrToJSVal(rq, argv[i], a); ^ ../../../source/scriptinterface/NativeWrapperDefns.h: At global scope: ../../../source/scriptinterface/NativeWrapperDefns.h:171:72: error: 'JS::AutoValueVector' has not been declared static void AssignOrToJSValHelper(const ScriptRequest& UNUSED(rq), JS::AutoValueVector& UNUSED(argv)) ^~~~~~~~~~~~~~~ ../../../source/scriptinterface/NativeWrapperDefns.h: In member function 'bool ScriptInterface::CallFunction(JS::HandleValue, const char*, R&, const Ts& ...) const': ../../../source/scriptinterface/NativeWrapperDefns.h:182:6: error: 'AutoValueVector' is not a member of 'JS' JS::AutoValueVector argv(rq.cx); ^~~~~~~~~~~~~~~ ../../../source/scriptinterface/NativeWrapperDefns.h:182:6: note: suggested alternative: 'ValueVector' JS::AutoValueVector argv(rq.cx); ^~~~~~~~~~~~~~~ ValueVector ../../../source/scriptinterface/NativeWrapperDefns.h:183:10: error: 'argv' was not declared in this scope DISCARD argv.resize(sizeof...(Ts)); ^~~~ ../../../source/scriptinterface/NativeWrapperDefns.h:183:10: note: suggested alternative: 'nargs' DISCARD argv.resize(sizeof...(Ts)); ^~~~ nargs ../../../source/scriptinterface/NativeWrapperDefns.h: In member function 'bool ScriptInterface::CallFunction(JS::HandleValue, const char*, JS::Rooted<T>*, const Ts& ...) const': ../../../source/scriptinterface/NativeWrapperDefns.h:195:6: error: 'AutoValueVector' is not a member of 'JS' JS::AutoValueVector argv(rq.cx); ^~~~~~~~~~~~~~~ ../../../source/scriptinterface/NativeWrapperDefns.h:195:6: note: suggested alternative: 'ValueVector' JS::AutoValueVector argv(rq.cx); ^~~~~~~~~~~~~~~ ValueVector ../../../source/scriptinterface/NativeWrapperDefns.h:196:10: error: 'argv' was not declared in this scope DISCARD argv.resize(sizeof...(Ts)); ^~~~ ../../../source/scriptinterface/NativeWrapperDefns.h:196:10: note: suggested alternative: 'nargs' DISCARD argv.resize(sizeof...(Ts)); ^~~~ nargs ../../../source/scriptinterface/NativeWrapperDefns.h: In member function 'bool ScriptInterface::CallFunction(JS::HandleValue, const char*, JS::MutableHandle<T>, const Ts& ...) const': ../../../source/scriptinterface/NativeWrapperDefns.h:205:6: error: 'AutoValueVector' is not a member of 'JS' JS::AutoValueVector argv(rq.cx); ^~~~~~~~~~~~~~~ ../../../source/scriptinterface/NativeWrapperDefns.h:205:6: note: suggested alternative: 'ValueVector' JS::AutoValueVector argv(rq.cx); ^~~~~~~~~~~~~~~ ValueVector ../../../source/scriptinterface/NativeWrapperDefns.h:206:10: error: 'argv' was not declared in this scope DISCARD argv.resize(sizeof...(Ts)); ^~~~ ../../../source/scriptinterface/NativeWrapperDefns.h:206:10: note: suggested alternative: 'nargs' DISCARD argv.resize(sizeof...(Ts)); ^~~~ nargs ../../../source/scriptinterface/NativeWrapperDefns.h: In member function 'bool ScriptInterface::CallFunctionVoid(JS::HandleValue, const char*, const Ts& ...) const': ../../../source/scriptinterface/NativeWrapperDefns.h:217:6: error: 'AutoValueVector' is not a member of 'JS' JS::AutoValueVector argv(rq.cx); ^~~~~~~~~~~~~~~ ../../../source/scriptinterface/NativeWrapperDefns.h:217:6: note: suggested alternative: 'ValueVector' JS::AutoValueVector argv(rq.cx); ^~~~~~~~~~~~~~~ ValueVector ../../../source/scriptinterface/NativeWrapperDefns.h:218:10: error: 'argv' was not declared in this scope DISCARD argv.resize(sizeof...(Ts)); ^~~~ ../../../source/scriptinterface/NativeWrapperDefns.h:218:10: note: suggested alternative: 'nargs' DISCARD argv.resize(sizeof...(Ts)); ^~~~ nargs make[1]: *** [network.make:145: obj/network_Debug/NetClient.o] Error 1 make: *** [Makefile:77: network] Error 2 Link to build: https://jenkins.wildfiregames.com/job/docker-differential/3835/display/redirect |