Code Monkey home page Code Monkey logo

Comments (8)

anonanon17 avatar anonanon17 commented on May 21, 2024 1

Ah okay, well it seems from this #29 that it will be easiest to just use a g++ or clang compiler instead - I may try Visual Studio with g++ or clang dropped in as the compiler, I'll report back with results.

from ecst.

vittorioromeo avatar vittorioromeo commented on May 21, 2024 1

@anonanon17: this is an ecst bug, not related to Windows. I will fix it ASAP.

from ecst.

OvermindDL1 avatar OvermindDL1 commented on May 21, 2024

I'm so confused, every other header-only library I have used is just a .dll, a .lib and a bunch of header files.

Well first of all if a library is 'header-only' then it, by definition, would not have any .dll/.lib/.a/whatever other files, only *.h/*.hpp. ^.^

Same with this library, you only need to include the include directories and 'use' them in your project.

I've not tried it in VC (I'm a linux user myself) but I'd imagine the parts of the source that do not work are probably just some GCC intrinsics or some #ifdef's or something that you could fix yourself and PR the fixes back here. :-)

You'd start by just making your project in VC, then just linking in the headers from this project, then find what does not compile as you try to use it and fix it (and PR the fixes back), and repeat. :-)

from ecst.

anonanon17 avatar anonanon17 commented on May 21, 2024

Update:

Visual Studio g++ was incredibly unfriendly so I've switched to Code::Blocks using MinGW gcc as the compiler.

Unfortunately, after linking boost, ecst, vrm_core and vrm_pp I get some errors in the ecst code that I believe may be actual errors and not just linking issues. Do you have any ideas?

EDIT: I believe this is an issue with my MinGW installation - I think I have the Win32 threads rather than Posix threads, I will report back when I try Posix shortly.

EDIT 2: Made sure I'm using Posix, but still get the same errors. I'm very confused at the moment.

EDIT 3: Turns out the "standard" MinGW installation does not support Posix (or if it does, not easily). I installed MinGW-w64 and got a little bit further, see the below post.

||=== Build: Debug in ECST_Test (compiler: GNU GCC Compiler) ===|
c:\clib\ecst\include\ecst\aliases\threading\std.hpp|50|error: 'this_thread' is not a namespace-name|
c:\clib\ecst\include\ecst\aliases\threading\std.hpp|50|error: expected namespace-name before ';' token|
c:\clib\ecst\include\ecst\aliases\threading\std.hpp|52|error: 'std::thread' has not been declared|
c:\clib\ecst\include\ecst\aliases\threading\std.hpp|53|error: 'std::mutex' has not been declared|
c:\clib\ecst\include\ecst\aliases\threading\std.hpp|55|error: 'std::condition_variable' has not been declared|
c:\clib\ecst\include\ecst\mp\list\basic.hpp||In function 'constexpr auto ecst::mp::list::index_of(TList&&, T&&)':|
c:\clib\ecst\include\ecst\mp\list\basic.hpp|31|error: 'make_pack' in namespace 'boost::hana::detail' does not name a template type|
c:\clib\ecst\include\ecst\mp\list\basic.hpp|32|error: 'Pack' was not declared in this scope|
c:\clib\ecst\include\ecst\mp\list\basic.hpp|32|error: template argument 2 is invalid|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|17|error: 'mutex' in namespace 'ecst' does not name a type|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|18|error: 'condition_variable' in namespace 'ecst' does not name a type|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|19|error: 'mutex_type' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|19|error: template argument 1 is invalid|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|20|error: 'mutex_type' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|20|error: template argument 1 is invalid|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|31|error: variable or field 'access_cv_counter' declared void|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|31|error: 'mutex_type' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|31|error: 'mutex' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|31|error: 'cv_type' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|31|error: 'cv' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|31|error: expected primary-expression before '&' token|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|31|error: 'c' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|31|error: expected primary-expression before '&&' token|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|31|error: 'f' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|43|error: variable or field 'decrement_cv_counter_then' declared void|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|43|error: 'mutex_type' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|43|error: 'mutex' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|43|error: 'cv_type' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|43|error: 'cv' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|43|error: expected primary-expression before '&' token|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|43|error: 'c' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|43|error: expected primary-expression before '&&' token|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|43|error: 'f' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|55|error: variable or field 'decrement_cv_counter_and_notify_one' declared void|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|55|error: 'mutex_type' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|55|error: 'mutex' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|55|error: 'cv_type' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|55|error: 'cv' was not declared in this scope|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|55|error: expected primary-expression before '&' token|
c:\clib\ecst\include\ecst\utils\cv_operations\cv_operations.hpp|55|error: 'c' was not declared in this scope|
c:\clib\ecst\include\ecst\thread_pool\third_party\concurrent_queue\concurrentqueue.h|51|error: expected '}' before end of line|
c:\clib\ecst\include\ecst\thread_pool\third_party\concurrent_queue\concurrentqueue.h|51|error: expected '}' before end of line|
c:\clib\ecst\include\ecst\thread_pool\third_party\concurrent_queue\concurrentqueue.h|51|error: expected declaration before end of line|
||=== Build failed: 42 error(s), 0 warning(s) (0 minute(s), 1 second(s)) ===|

from ecst.

anonanon17 avatar anonanon17 commented on May 21, 2024

Update 2:

Uninstalled MinGW, and installed MinGW-w64 (which supports Posix properly). I now get the following errors:

EDIT: I have looked through every single issue, and the only hope seems to be using nuwen MinGW #15, although this is just a package containing the latest boost and MinGW-w64 so I can't see why this would make a difference. I will update when I have tried again.

EDIT 2: So I uninstalled MinGW-w64 and installed nuwen MinGW. I get exactly the same errors upon building, which makes me believe this is an error with ECST itself as the creator mentions using nuwen MinGW to successfully build ECST in #15 .

At this point I believe it is probably best for me to abandon hope of using ECST and roll my own solution. If anyone does have a solution to the compilation issues I'm facing that would be great.

EDIT 3: In case anyone is reading this in the future, these are the steps I took that did not work:

1 - Clone ECST repo.
2 - Run setup .sh script.
3 - Install Code::Blocks and nuwen MinGW using this tutorial: https://solarianprogrammer.com/2017/11/22/install-codeblocks-gcc-windows/
4 - Check the gcc compiler is working fine (it was).
5 - Create a new console project.
6 - Insert the "code sample" code from the repo.
7 - Link the ecst, vrm_core, vrm_pp and boost libraries.
8 - Build.

I get exactly the same errors (below) that I got with any other MinGW installation. I can only conclude there is an issue with ECST, or some magic trick that will get it working. Either way, I unfortunately do not have time to mess around with this any longer.

||=== Build: Debug in ECST_Test (compiler: GNU GCC Compiler (x64)) ===| C:\CLib\ecst\include\ecst\mp\list\basic.hpp||In function 'constexpr auto ecst::mp::list::index_of(TList&&, T&&)':| C:\CLib\ecst\include\ecst\mp\list\basic.hpp|31|error: 'make_pack' in namespace 'boost::hana::detail' does not name a template type| C:\CLib\ecst\include\ecst\mp\list\basic.hpp|32|error: 'Pack' was not declared in this scope| C:\CLib\ecst\include\ecst\mp\list\basic.hpp|32|error: template argument 2 is invalid| C:\CLib\Test\ECST_Test\main.cpp|12|error: 'vec2f' does not name a type| C:\CLib\Test\ECST_Test\main.cpp|17|error: 'vec2f' does not name a type| C:\CLib\Test\ECST_Test\main.cpp|22|error: 'vec2f' does not name a type| C:\CLib\Test\ECST_Test\main.cpp|56|error: 'ft' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|75|error: 'ft' has not been declared| C:\CLib\Test\ECST_Test\main.cpp||In function 'constexpr auto ecst_setup::make_ssl()':| C:\CLib\Test\ECST_Test\main.cpp|140|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|148|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|150|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|161|error: 'vec2f' does not name a type| C:\CLib\Test\ECST_Test\main.cpp||In function 'auto mk_particle(TProxy&, const int&)':| C:\CLib\Test\ECST_Test\main.cpp|169|error: there are no arguments to 'rndvec2f' that depend on a template parameter, so a declaration of 'rndvec2f' must be available [-fpermissive]| C:\CLib\Test\ECST_Test\main.cpp|169|note: (if you use '-fpermissive', G++ will accept your code, but allowing the use of an undeclared name is deprecated)| C:\CLib\Test\ECST_Test\main.cpp||In function 'int main()':| C:\CLib\Test\ECST_Test\main.cpp|189|error: invalid use of void expression| C:\CLib\Test\ECST_Test\main.cpp|198|error: 'sz_t' was not declared in this scope| C:\CLib\Test\ECST_Test\main.cpp|198|note: suggested alternatives:| ..\..\ecst\extlibs\vrm_core\include\vrm\core\type_aliases\numerical.hpp|24|note: 'vrm::core::sz_t'| ..\..\ecst\extlibs\vrm_core\include\vrm\core\type_aliases\numerical.hpp|24|note: 'vrm::core::sz_t'| ..\..\ecst\extlibs\vrm_core\include\vrm\core\type_aliases\numerical.hpp|24|note: 'vrm::core::sz_t'| ..\..\ecst\extlibs\vrm_core\include\vrm\core\type_aliases\numerical.hpp|24|note: 'vrm::core::sz_t'| ..\..\ecst\extlibs\vrm_core\include\vrm\core\type_aliases\numerical.hpp|24|note: 'vrm::core::sz_t'| C:\CLib\Test\ECST_Test\main.cpp|198|error: 'i' was not declared in this scope| C:\CLib\Test\ECST_Test\main.cpp|200|error: there are no arguments to 'random_position' that depend on a template parameter, so a declaration of 'random_position' must be available [-fpermissive]| C:\CLib\Test\ECST_Test\main.cpp||In function 'int main()':| C:\CLib\Test\ECST_Test\main.cpp|207|error: 'delta_time' was not declared in this scope| C:\CLib\Test\ECST_Test\main.cpp|207|note: suggested alternative: 'localtime'| C:\CLib\Test\ECST_Test\main.cpp|212|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|214|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|214|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|214|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|216|error: 'dt' is not captured| C:\CLib\Test\ECST_Test\main.cpp|209|note: the lambda has no capture-default| C:\CLib\Test\ECST_Test\main.cpp|207|note: '<typeprefixerror>dt' declared here| C:\CLib\Test\ECST_Test\main.cpp|218|error: 'dt' is not captured| C:\CLib\Test\ECST_Test\main.cpp|216|note: the lambda has no capture-default| C:\CLib\Test\ECST_Test\main.cpp|207|note: '<typeprefixerror>dt' declared here| C:\CLib\Test\ECST_Test\main.cpp|223|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|224|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|224|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|225|error: 'dt' is not captured| C:\CLib\Test\ECST_Test\main.cpp|209|note: the lambda has no capture-default| C:\CLib\Test\ECST_Test\main.cpp|207|note: '<typeprefixerror>dt' declared here| C:\CLib\Test\ECST_Test\main.cpp|227|error: 'dt' is not captured| C:\CLib\Test\ECST_Test\main.cpp|225|note: the lambda has no capture-default| C:\CLib\Test\ECST_Test\main.cpp|207|note: '<typeprefixerror>dt' declared here| C:\CLib\Test\ECST_Test\main.cpp|229|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|230|error: 'dt' is not captured| C:\CLib\Test\ECST_Test\main.cpp|209|note: the lambda has no capture-default| C:\CLib\Test\ECST_Test\main.cpp|207|note: '<typeprefixerror>dt' declared here| C:\CLib\Test\ECST_Test\main.cpp|236|error: there are no arguments to 'do_something_before' that depend on a template parameter, so a declaration of 'do_something_before' must be available [-fpermissive]| C:\CLib\Test\ECST_Test\main.cpp|238|error: 'dt' is not captured| C:\CLib\Test\ECST_Test\main.cpp|230|note: the lambda has no capture-default| C:\CLib\Test\ECST_Test\main.cpp|207|note: '<typeprefixerror>dt' declared here| C:\CLib\Test\ECST_Test\main.cpp|240|error: 'dt' is not captured| C:\CLib\Test\ECST_Test\main.cpp|238|note: the lambda has no capture-default| C:\CLib\Test\ECST_Test\main.cpp|207|note: '<typeprefixerror>dt' declared here| C:\CLib\Test\ECST_Test\main.cpp|243|error: there are no arguments to 'do_something_after' that depend on a template parameter, so a declaration of 'do_something_after' must be available [-fpermissive]| C:\CLib\Test\ECST_Test\main.cpp||In function 'int main()':| C:\CLib\Test\ECST_Test\main.cpp|248|error: 'st' has not been declared| C:\CLib\Test\ECST_Test\main.cpp|251|error: there are no arguments to 'log' that depend on a template parameter, so a declaration of 'log' must be available [-fpermissive]| C:\CLib\Test\ECST_Test\main.cpp|253|error: expected unqualified-id before '}' token| C:\CLib\Test\ECST_Test\main.cpp|253|error: expected ';' before '}' token| C:\CLib\Test\ECST_Test\main.cpp|256|error: there are no arguments to 'log' that depend on a template parameter, so a declaration of 'log' must be available [-fpermissive]| C:\CLib\Test\ECST_Test\main.cpp|257|error: expected unqualified-id before '}' token| C:\CLib\Test\ECST_Test\main.cpp|257|error: expected ';' before '}' token| C:\CLib\Test\ECST_Test\main.cpp||In instantiation of 'main()::<lambda(auto:143)> [with auto:143 = ecst::entity_id]':| C:\CLib\ecst\include\ecst\context\data\data\refresh_event\refresh_event.inl|46|required from 'struct ecst::refresh_event::on_reclaim(TF&&) [with TF = main()::<lambda(auto:143)>]::<lambda>'| C:\CLib\ecst\include\ecst\context\data\data\refresh_event\refresh_event.inl|49|required from 'auto ecst::refresh_event::on_reclaim(TF&&) [with TF = main()::<lambda(auto:143)>]'| C:\CLib\Test\ECST_Test\main.cpp|257|required from here| C:\CLib\Test\ECST_Test\main.cpp|256|error: 'log' was not declared in this scope| C:\CLib\Test\ECST_Test\main.cpp|256|note: suggested alternative:| C:\CLib\ecst\include\ecst\debug\log\impl.hpp|81|note: 'ecst::debug::impl::log'| ||=== Build failed: 43 error(s), 4 warning(s) (0 minute(s), 2 second(s)) ===|

from ecst.

anonanon17 avatar anonanon17 commented on May 21, 2024

Just for "fun", I tried compiling with Clang. I got essentially the exact same issue, so I'm now almost certain either boost::hana or ECST is broken.

||=== Build: Debug in BasicCompilerTest (compiler: LLVM Clang Compiler) ===| C:\CLib\ecst\include\ecst\mp\.\list\basic.hpp|31|error: no type named 'make_pack' in namespace 'boost::hana::detail'| C:\CLib\ecst\include\ecst\mp\.\list\basic.hpp|31|error: expected ';' after alias declaration| C:\CLib\ecst\include\ecst\mp\.\list\basic.hpp|32|error: use of undeclared identifier 'Pack'| C:\CLib\ecst\include\ecst\mp\.\list\basic.hpp|32|error: no type named 'value' in the global namespace| C:\CLib\Test\BasicCompilerTest\main.cpp|12|error: unknown type name 'vec2f'| C:\CLib\Test\BasicCompilerTest\main.cpp|17|error: unknown type name 'vec2f'| C:\CLib\Test\BasicCompilerTest\main.cpp|22|error: unknown type name 'vec2f'| C:\CLib\Test\BasicCompilerTest\main.cpp|56|error: unknown type name 'ft'| C:\CLib\Test\BasicCompilerTest\main.cpp|75|error: unknown type name 'ft'| C:\CLib\Test\BasicCompilerTest\main.cpp|140|error: use of undeclared identifier 'st'| C:\CLib\Test\BasicCompilerTest\main.cpp|148|error: use of undeclared identifier 'st'| C:\CLib\Test\BasicCompilerTest\main.cpp|150|error: use of undeclared identifier 'st'| C:\CLib\Test\BasicCompilerTest\main.cpp|139|error: variables defined in a constexpr function must be initialized| C:\CLib\Test\BasicCompilerTest\main.cpp|161|error: unknown type name 'vec2f'| C:\CLib\Test\BasicCompilerTest\main.cpp|198|error: unknown type name 'sz_t'| C:\CLib\Test\BasicCompilerTest\main.cpp|207|error: use of undeclared identifier 'delta_time'| C:\CLib\Test\BasicCompilerTest\main.cpp|212|error: use of undeclared identifier 'st'| C:\CLib\Test\BasicCompilerTest\main.cpp|214|error: use of undeclared identifier 'st'| C:\CLib\Test\BasicCompilerTest\main.cpp|214|error: use of undeclared identifier 'st'| ||error: too many errors emitted, stopping now [-ferror-limit=]| ||=== Build failed: 20 error(s), 0 warning(s) (0 minute(s), 2 second(s)) ===|

from ecst.

vittorioromeo avatar vittorioromeo commented on May 21, 2024

@anonanon17 : Let me know if 30cfe09 fixed your build issue.

BTW, if you need a Windows implementation of std::thread, check out:
https://github.com/meganz/mingw-std-threads

from ecst.

anonanon17 avatar anonanon17 commented on May 21, 2024

Appears to have fixed the issue, thanks! I used gcc to compile (via nuwen MinGW) and I will try a clang build later.

I'm going to go through making a basic setup using your thesis as a guide, and I'll let you know if I encounter any problems. I'm fairly certain the original issue is fixed.

Will also check out that std::thread implementation, thanks.

from ecst.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.