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

Issues building from source with cmake #57

Open
sheinasim opened this issue Oct 22, 2022 · 5 comments
Open

Issues building from source with cmake #57

sheinasim opened this issue Oct 22, 2022 · 5 comments

Comments

@sheinasim
Copy link

sheinasim commented Oct 22, 2022

Hi there!

I'm trying to install this in my local space on an HPC and I'm getting this error both when I clone the repo and when I download the latest release:

make[4]: *** [thirdparty/graph-tools/CMakeFiles/graphtools.dir/all] Error 2
make[3]: *** [all] Error 2
make[2]: *** [reviewer-prefix/src/reviewer-stamp/reviewer-build] Error 2
make[1]: *** [CMakeFiles/reviewer.dir/all] Error 2
make: *** [all] Error 2

I'm setting up the environment using conda. Any thoughts as to what is causing the error?

Thanks!
Sheina

@sclamons
Copy link
Collaborator

Hi sheinasim! Sorry it's taken me a few days to get to this. Would you mind posting the full contents of your build process?

@sheinasim
Copy link
Author

Hello @sclamons!

Thank you for your reply. I actually found a workaround by installing it locally to my laptop instead of the HPC.

I did actually end up with another issue, is there a way to create the BAMlet file and the .vcf from long read data? ExpansionHunter requires paired reads, and ultimately, I'd like to use REViewer to visualize my repeats (less so to characterize repeat variants).

Thanks!
Sheina

@sclamons
Copy link
Collaborator

sclamons commented Oct 26, 2022 via email

@sheinasim
Copy link
Author

Yes, I tried but it skips all the reads that aren't paired. So all the reads :)

@Stikus
Copy link

Stikus commented Dec 8, 2023

There are two issues causing this error:

/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp: In constructor ‘graphtools::GraphCoordinates::GraphCoordinatesImpl::GraphCoordinatesImpl(const graphtools::Graph*)’:
/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:52:40: error: ‘numeric_limits’ is not a member of ‘std’
   52 |                 size_t min_dist = std::numeric_limits<size_t>::max();
      |                                        ^~~~~~~~~~~~~~
/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:52:61: error: expected primary-expression before ‘>’ token
   52 |                 size_t min_dist = std::numeric_limits<size_t>::max();
      |                                                             ^
/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:52:64: error: ‘::max’ has not been declared; did you mean ‘std::max’?
   52 |                 size_t min_dist = std::numeric_limits<size_t>::max();
      |                                                                ^~~
      |                                                                std::max
In file included from /usr/include/c++/11/algorithm:62,
                 from /usr/include/c++/11/regex:38,
                 from /soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/include/graphalign/GraphAlignment.hh:28,
                 from /soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/include/graphcore/GraphCoordinates.hh:23,
                 from /soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:21:
/usr/include/c++/11/bits/stl_algo.h:3467:5: note: ‘std::max’ declared here
 3467 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:67:38: error: ‘numeric_limits’ is not a member of ‘std’
   67 |                 if (min_dist != std::numeric_limits<size_t>::max())
      |                                      ^~~~~~~~~~~~~~
/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:67:59: error: expected primary-expression before ‘>’ token
   67 |                 if (min_dist != std::numeric_limits<size_t>::max())
      |                                                           ^
/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:67:62: error: ‘::max’ has not been declared; did you mean ‘std::max’?
   67 |                 if (min_dist != std::numeric_limits<size_t>::max())
      |                                                              ^~~
      |                                                              std::max
In file included from /usr/include/c++/11/algorithm:62,
                 from /usr/include/c++/11/regex:38,
                 from /soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/include/graphalign/GraphAlignment.hh:28,
                 from /soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/include/graphcore/GraphCoordinates.hh:23,
                 from /soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:21:
/usr/include/c++/11/bits/stl_algo.h:3467:5: note: ‘std::max’ declared here
 3467 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp: In member function ‘uint64_t graphtools::GraphCoordinates::distance(uint64_t, uint64_t) const’:
/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:197:28: error: ‘numeric_limits’ is not a member of ‘std’
  197 |     uint64_t result = std::numeric_limits<uint64_t>::max();
      |                            ^~~~~~~~~~~~~~
/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:197:51: error: expected primary-expression before ‘>’ token
  197 |     uint64_t result = std::numeric_limits<uint64_t>::max();
      |                                                   ^
/soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:197:54: error: ‘::max’ has not been declared; did you mean ‘std::max’?
  197 |     uint64_t result = std::numeric_limits<uint64_t>::max();
      |                                                      ^~~
      |                                                      std::max
In file included from /usr/include/c++/11/algorithm:62,
                 from /usr/include/c++/11/regex:38,
                 from /soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/include/graphalign/GraphAlignment.hh:28,
                 from /soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/include/graphcore/GraphCoordinates.hh:23,
                 from /soft/REViewer-0.2.7-src/reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp:21:
/usr/include/c++/11/bits/stl_algo.h:3467:5: note: ‘std::max’ declared here
 3467 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
make[5]: *** [thirdparty/graph-tools/CMakeFiles/graphtools.dir/build.make:286: thirdparty/graph-tools/CMakeFiles/graphtools.dir/src/graphcore/GraphCoordinates.cpp.o] Error 1
In file included from /usr/include/signal.h:328,
                 from /soft/REViewer-0.2.7-src/build/install/include/catch2/catch.hpp:8031,
                 from /soft/REViewer-0.2.7-src/reviewer/tests/UnitTests.cpp:22:
/soft/REViewer-0.2.7-src/build/install/include/catch2/catch.hpp:10815:58: error: call to non-‘constexpr’ function ‘long int sysconf(int)’
10815 |     static constexpr std::size_t sigStackSize = 32768 >= MINSIGSTKSZ ? 32768 : MINSIGSTKSZ;
      |                                                          ^~~~~~~~~~~
In file included from /usr/include/x86_64-linux-gnu/bits/sigstksz.h:24,
                 from /usr/include/signal.h:328,
                 from /soft/REViewer-0.2.7-src/build/install/include/catch2/catch.hpp:8031,
                 from /soft/REViewer-0.2.7-src/reviewer/tests/UnitTests.cpp:22:
/usr/include/unistd.h:640:17: note: ‘long int sysconf(int)’ declared here
  640 | extern long int sysconf (int __name) __THROW;
      |                 ^~~~~~~
In file included from /soft/REViewer-0.2.7-src/reviewer/tests/UnitTests.cpp:22:
/soft/REViewer-0.2.7-src/build/install/include/catch2/catch.hpp:10874:45: error: size of array ‘altStackMem’ is not an integral constant-expression
10874 |     char FatalConditionHandler::altStackMem[sigStackSize] = {};
      |                                             ^~~~~~~~~~~~
make[5]: *** [CMakeFiles/UnitTests.dir/build.make:76: CMakeFiles/UnitTests.dir/tests/UnitTests.cpp.o] Error 1
make[4]: *** [CMakeFiles/Makefile2:218: CMakeFiles/UnitTests.dir/all] Error 2
make[3]: *** [Makefile:136: all] Error 2
make[2]: *** [CMakeFiles/reviewer.dir/build.make:86: reviewer-prefix/src/reviewer-stamp/reviewer-build] Error 2
make[1]: *** [CMakeFiles/Makefile2:198: CMakeFiles/reviewer.dir/all] Error 2
make: *** [Makefile:91: all] Error 2

Fixes:

sed -i '/catchorg/s/2.12.4/2.13.5/' CMakeLists.txt
sed -i '/^#include <cassert>/a #include <limits>' reviewer/thirdparty/graph-tools/src/graphcore/GraphCoordinates.cpp

@egor-dolzhenko @sclamons Can anyone add these or similar fixes?
There is ever a PR #45 for one of them.

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

3 participants