Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running configure and make on master on Apple fails #9

Open
stephenberry opened this issue Sep 4, 2024 · 11 comments
Open

Running configure and make on master on Apple fails #9

stephenberry opened this issue Sep 4, 2024 · 11 comments

Comments

@stephenberry
Copy link
Contributor

I tried to build master on my Mac and the make command is failing. ./configure seemed to work.

Here's the error:

make
Building Dir src Start
Building Dir Memory Start
Building release
 Done Building Memory release/libMemory.dylib
Start Installing Headers
End Installing Headers
Start Installing Libraries
End Installing Libraries
Building Dir Memory Finish
Building Dir ThirdParty Start
ERROR
g++   -I /opt/homebrew/include  -I /opt/homebrew/include      -fPIC -Wall -Wextra -Werror -Wstrict-aliasing  -pedantic -Wunreachable-code -Wno-long-long -Wdeprecated -Wdeprecated-declarations -Wmissing-braces -Wmissing-field-initializers -Wunused-variable -Winconsistent-missing-override -Wdelete-non-abstract-non-virtual-dtor -Wdelete-non-virtual-dtor -Wno-deprecated-register -Wno-literal-range  -Wno-unknown-pragmas   -I/Users/stephenberry/Develop/repos/JsonBenchmark/build/include -isystem /Users/stephenberry/Develop/repos/JsonBenchmark/build/include3rd  -g   -Wno-unreachable-code  -DTHOR_USE_CPLUSPLUS23 -std=c++2b   -Wno-return-stack-address  -Wno-range-loop-analysis  -Wno-deprecated-declarations  -I../../thirdparty/ThorsMongo/magic_enum/include/magic_enum  -MF"makedependency/ThorsSerializerTest.d" -MM -MP -MT"makedependency/ThorsSerializerTest.d" -MT"debug/ThorsSerializerTest.o" -MT"release/ThorsSerializerTest.o" -MT"coverage/ThorsSerializerTest.o" "ThorsSerializerTest.cpp"
========================================
src/ThirdParty/ThorsSerializerTest.cpp:3:10: fatal error: 'ThorSerialize/Traits.h' file not found
#include "ThorSerialize/Traits.h"
         ^~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make[2]: *** [makedependency/ThorsSerializerTest.d] Error 1
make[1]: *** [ThirdParty.dir] Error 2
make: *** [src.dir] Error 2
@Loki-Astari
Copy link
Owner

Loki-Astari commented Sep 4, 2024

On mac it used to assume you had installed ThorsSerializer using brew.

But I fixed that yesterday.

You can fix in one of two ways:

  1. Use brew. brew install thors-mongo
  2. Pull the latest version of the project and re-run the init3rdParty script.

@stephenberry
Copy link
Contributor Author

stephenberry commented Sep 16, 2024

I tried to build again with the latest on Mac just now, but I get the following make error:

This was after configure seemed to work.

 % make
Building Dir src Start
Building Dir Memory Start
Building release
g++ -c -O3  Memory.cpp                                                                             OK
g++ -dynamiclib -install_name libMemory23.dylib -o release/libMemory.dylib -O3                     OK
 Done Building Memory release/libMemory.dylib
Start Installing Headers
 Install Header Memory.h
 Install Header MemoryConfig.h
End Installing Headers
Start Installing Libraries
 Install - release - libMemory23.dylib
End Installing Libraries
Building Dir Memory Finish
Building Dir ThirdParty Start
Makefile:8: ../../thirdparty/Jsonifier/avx_flags.txt: No such file or directory
make[2]: *** No rule to make target `../../thirdparty/Jsonifier/avx_flags.txt'.  Stop.
make[1]: *** [ThirdParty.dir] Error 2
make: *** [src.dir] Error 2

@Loki-Astari
Copy link
Owner

Did we solve this in another thread?
Or is this still an issue.

@stephenberry
Copy link
Contributor Author

stephenberry commented Sep 19, 2024

Currently I can't clone: fatal: Failed to recurse into submodule path 'thirdparty/ThorsMongo'

@stephenberry
Copy link
Contributor Author

More details: fatal: Fetched in submodule path 'thirdparty/ThorsMongo/third/ThorsSerializer', but it did not contain 97eda05feda36dff95821d366e0dfdc5152f6c9b. Direct fetching of that commit failed.

@Loki-Astari
Copy link
Owner

Sorry I am messing around.
I will have it fixed by tonight.

As a temporary work around.

cd thirdparty/ThorsMongo/third/ThorsSerializer
git checkout master
git pull
cd ../../../..

@stephenberry
Copy link
Contributor Author

Tried again today and got the following error:

Makefile:8: ../../thirdparty/Jsonifier/avx_flags.txt: No such file or directory
make[2]: *** No rule to make target `../../thirdparty/Jsonifier/avx_flags.txt'.  Stop.
make[1]: *** [ThirdParty.dir] Error 2
make: *** [src.dir] Error 2

@Loki-Astari
Copy link
Owner

Looks like you have not run the 3rd-Party init script.

If you are starting from scratch.
The commands are:

> git checkout https://github.com/Loki-Astar/JsonBenchmark.git
> cd JsonBenchmark
> ./configure
> ./initPlatform
> ./init3rdParty
>
> make
> ./runTests

@stephenberry
Copy link
Contributor Author

Thanks, I ran all those commands and now get this make error:

ERROR
g++   -I /opt/homebrew/include  -I /opt/homebrew/include      -fPIC -Wall -Wextra -Werror -Wstrict-aliasing  -pedantic -Wunreachable-code -Wno-long-long -Wdeprecated -Wdeprecated-declarations -Wmissing-braces -Wmissing-field-initializers -Wunused-variable -Winconsistent-missing-override -Wdelete-non-abstract-non-virtual-dtor -Wdelete-non-virtual-dtor -Wno-deprecated-register -Wno-literal-range  -Wno-unknown-pragmas -Wno-unknown-warning-option   -I/Users/stephenberry/Develop/repos/JsonBenchmark/build/include -isystem /Users/stephenberry/Develop/repos/JsonBenchmark/build/include3rd  -g   -Wno-unreachable-code  -DTHOR_USE_CPLUSPLUS23 -std=c++23   -Wno-return-stack-address  -Wno-range-loop-analysis  -Wno-deprecated-declarations  -Wno-array-bounds  -I../../thirdparty/ThorsMongo/magic_enum/include/magic_enum  -MF"makedependency/ThorsSerializerTest.d" -MM -MP -MT"makedependency/ThorsSerializerTest.d" -MT"debug/ThorsSerializerTest.o" -MT"release/ThorsSerializerTest.o" -MT"coverage/ThorsSerializerTest.o" "ThorsSerializerTest.cpp"
========================================
src/ThirdParty/ThorsSerializerTest.cpp:3:10: fatal error: 'ThorSerialize/Traits.h' file not found
    3 | #include "ThorSerialize/Traits.h"
      |          ^~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
make[2]: *** [makedependency/ThorsSerializerTest.d] Error 1
make[1]: *** [ThirdParty.dir] Error 2
make: *** [src.dir] Error 2

@stephenberry
Copy link
Contributor Author

Not sure if this matters, but I got these errors during initialization:

Building: NotThor
Mark:     
Checking
checking for yaml_parser_initialize in -lyaml... no
FAIL: Using: ><
: error: 
Error: Could not find libyaml

You can solve this by installing libyaml
    see http://pyyaml.org/wiki/LibYAML

Alternately specify install location with:
    --with-yaml-root=<location of yaml installation>


    


No Tests

No Tests
                                                                                        %

                                                                                                              /bin/bash: vera++: command not found

 vera++ --root=/Users/stephenberry/Develop/repos/JsonBenchmark/thirdparty/ThorsMongo/build/vera-plusplus --profile thor  --exclusions vera_exclusions --show-rule --error --std-report coverage/loguru.cpp.vera.report loguru.cpp
===================================================
cat: coverage/loguru.cpp.vera.report: No such file or directory
make[3]: *** [coverage/loguru.cpp.vera] Error 1
make[2]: *** [report/vera] Error 2
make[1]: *** [ThorsLogging.dir] Error 2
make: *** [src.dir] Error 2


No Tests

No Tests
                                                                                        %


loguru.cpp                                                                                                    
g++ -c loguru.cpp -o debug/loguru.o -DLOGURU_WITH_STREAMS=1 -fPIC -Wall -Wextra -Werror -Wstrict-aliasing -pedantic -Wunreachable-code -Wno-long-long -Wdeprecated -Wdeprecated-declarations -Wmissing-braces -Wmissing-field-initializers -Wunused-variable -Wno-attributes -Wno-type-limits -I/Users/stephenberry/Develop/repos/JsonBenchmark/thirdparty/ThorsMongo/build/include -isystem /Users/stephenberry/Develop/repos/JsonBenchmark/thirdparty/ThorsMongo/build/include3rd -g -Wno-unreachable-code -DTHOR_USE_CPLUSPLUS -DMOCK_FUNC(x)=::x -DMOCK_TFUNC(x)=::x
========================================
In file included from loguru.cpp:23:
src/ThorsLogging/./loguru.hpp:274:13: error: use of undeclared identifier 'nullptr'
  274 |                         t._str = nullptr;
      |                                  ^
src/ThorsLogging/./loguru.hpp:281:39: error: use of undeclared identifier 'nullptr'
  281 |                 bool empty() const { return _str == nullptr || *_str == '\0'; }
      |                                                     ^
src/ThorsLogging/./loguru.hpp:286:11: error: use of undeclared identifier 'nullptr'
  286 |                         _str = nullptr;
      |                                ^
src/ThorsLogging/./loguru.hpp:496:62: error: expected expression
  496 |         void init(int& argc, char* argv[], const Options& options = {});
      |                                                                     ^
src/ThorsLogging/./loguru.hpp:585:30: error: use of undeclared identifier 'nullptr'
  585 |                 close_handler_t on_close = nullptr,
      |                                            ^
src/ThorsLogging/./loguru.hpp:586:30: error: use of undeclared identifier 'nullptr'
  586 |                 flush_handler_t on_flush = nullptr);
      |                                            ^
src/ThorsLogging/./loguru.hpp:661:26: error: use of undeclared identifier 'nullptr'
  661 |                 LogScopeRAII() : _file(nullptr) {} // No logging
      |                                        ^
src/ThorsLogging/./loguru.hpp:1236:18: error: expected ';' at end of declaration list
 1236 |                 ~StreamLogger() noexcept(false);
      |                                ^
src/ThorsLogging/./loguru.hpp:1263:33: error: expected ';' at end of declaration list
 1263 |                 LOGURU_NORETURN ~AbortLogger() noexcept(false);
      |                                               ^
src/ThorsLogging/loguru.cpp:174:22: error: alias declarations are a C++11 extension [-Werror,-Wc++11-extensions]
  174 |         using CallbackVec = std::vector<Callback>;
      |                             ^
src/ThorsLogging/loguru.cpp:176:25: error: alias declarations are a C++11 extension [-Werror,-Wc++11-extensions]
  176 |         using StringPair     = std::pair<std::string, std::string>;
      |                                ^
src/ThorsLogging/loguru.cpp:177:25: error: alias declarations are a C++11 extension [-Werror,-Wc++11-extensions]
  177 |         using StringPairList = std::vector<StringPair>;
      |                                ^
src/ThorsLogging/loguru.cpp:179:8: error: 'auto' type specifier is a C++11 extension [-Werror,-Wc++11-extensions]
  179 |         const auto s_start_time = steady_clock::now();
      |               ^
src/ThorsLogging/loguru.cpp:209:51: error: expected ';' after top level declarator
  209 |         static std::atomic<unsigned> s_stderr_indentation { 0 };
      |                                                          ^
      |                                                          ;
src/ThorsLogging/loguru.cpp:217:43: error: expected expression
  217 |         static const bool s_terminal_has_color = [](){
      |                                                  ^
src/ThorsLogging/loguru.cpp:445:3: error: 'auto' type specifier is a C++11 extension [-Werror,-Wc++11-extensions]
  445 |                 auto result = vtextprintf(format, vlist);
      |                 ^
src/ThorsLogging/loguru.cpp:477:4: error: 'auto' type specifier is a C++11 extension [-Werror,-Wc++11-extensions]
  477 |                         auto cmd = argv[arg_it];
      |                         ^
src/ThorsLogging/loguru.cpp:478:4: error: 'auto' type specifier is a C++11 extension [-Werror,-Wc++11-extensions]
  478 |                         auto arg_len = strlen(verbosity_flag);
      |                         ^
src/ThorsLogging/loguru.cpp:494:5: error: 'auto' type specifier is a C++11 extension [-Werror,-Wc++11-extensions]
  494 |                                 auto value_str = cmd + arg_len;
      |                                 ^
src/ThorsLogging/fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
make[3]: *** [debug/loguru.o] Error 1
make[2]: *** [debug] Error 2
make[1]: *** [ThorsLogging.dir] Error 2
make: *** [src.dir] Error 2

@Loki-Astari
Copy link
Owner

The problems seems to be that the ./init3rdParty failed because you don't have libyaml installed.
I will fix the scrips.

But you can fix temporarily with:

> brew install libyaml
> ./init3rdParty
> 
> make

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants