You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I cannot compile GraphGen inside Docker, due to an error: 'shared_ptr' is not a member of 'std'.
Here is the transcript of everything I did:
$ docker run -it therealcaoyudong/qtorch
root@1a60ed7013b4:/# cd root/qtorch/
root@1a60ed7013b4:~/qtorch# make all
Compiling All Executables - Note that nlopt-2.4.2 must be installed successfully to compile.....
make[1]: Entering directory '/root/qtorch'
Compiling qtorch .....
make[1]: Leaving directory '/root/qtorch'
make[1]: Entering directory '/root/qtorch'
Compiling Test Executable .....
make[1]: Leaving directory '/root/qtorch'
make[1]: Entering directory '/root/qtorch'
Compiling QAOA MaxCut - Note that nlopt-2.4.2 must be installed successfully to compile .....
cp: cannot create regular file '/root/usr/local/bin': No such file or directory
Makefile:62: recipe for target 'cut' failed
make[1]: *** [cut] Error 1
make[1]: Leaving directory '/root/qtorch'
Makefile:28: recipe for target 'all' failed
make: *** [all] Error 2
root@1a60ed7013b4:~/qtorch# mkdir -p /root/usr/local/bin # Create directory to fix above error
root@1a60ed7013b4:~/qtorch# make all
Compiling All Executables - Note that nlopt-2.4.2 must be installed successfully to compile.....
make[1]: Entering directory '/root/qtorch'
Compiling qtorch .....
make[1]: Leaving directory '/root/qtorch'
make[1]: Entering directory '/root/qtorch'
Compiling Test Executable .....
make[1]: Leaving directory '/root/qtorch'
make[1]: Entering directory '/root/qtorch'
Compiling QAOA MaxCut - Note that nlopt-2.4.2 must be installed successfully to compile .....
make[1]: Leaving directory '/root/qtorch'
root@1a60ed7013b4:~/qtorch# cd Xreg\ GraphGen/
root@1a60ed7013b4:~/qtorch/Xreg GraphGen# make all
g++ -g -std=c++11 main.cpp -o main
In file included from main.cpp:2:0:
GraphNode.h:13:17: error: 'shared_ptr' is not a member of 'std'
std::vector<std::shared_ptr<GraphNode>> mConnections;
^
GraphNode.h:13:17: error: 'shared_ptr' is not a member of 'std'
GraphNode.h:13:33: error: template argument 1 is invalid
std::vector<std::shared_ptr<GraphNode>> mConnections;
^
GraphNode.h:13:33: error: template argument 2 is invalid
GraphNode.h:13:42: error: expected unqualified-id before '>' token
std::vector<std::shared_ptr<GraphNode>> mConnections;
^
main.cpp:10:23: error: 'shared_ptr' is not a member of 'std'
bool alreadyConnected(std::shared_ptr<GraphNode> a, std::shared_ptr<GraphNode> b)
^
main.cpp:10:48: error: expected primary-expression before '>' token
bool alreadyConnected(std::shared_ptr<GraphNode> a, std::shared_ptr<GraphNode> b)
^
main.cpp:10:50: error: 'a' was not declared in this scope
bool alreadyConnected(std::shared_ptr<GraphNode> a, std::shared_ptr<GraphNode> b)
^
main.cpp:10:53: error: 'shared_ptr' is not a member of 'std'
bool alreadyConnected(std::shared_ptr<GraphNode> a, std::shared_ptr<GraphNode> b)
^
main.cpp:10:78: error: expected primary-expression before '>' token
bool alreadyConnected(std::shared_ptr<GraphNode> a, std::shared_ptr<GraphNode> b)
^
main.cpp:10:80: error: 'b' was not declared in this scope
bool alreadyConnected(std::shared_ptr<GraphNode> a, std::shared_ptr<GraphNode> b)
^
main.cpp:10:81: error: expression list treated as compound expression in initializer [-fpermissive]
bool alreadyConnected(std::shared_ptr<GraphNode> a, std::shared_ptr<GraphNode> b)
^
main.cpp:11:1: error: expected ',' or ';' before '{' token
{
^
Makefile:2: recipe for target 'all' failed
make: *** [all] Error 1
root@1a60ed7013b4:~/qtorch/Xreg GraphGen#
Is there a quick fix for this?
The text was updated successfully, but these errors were encountered:
Hello - unfortunately, I don't think that docker container is maintained. If you clone the git repo, go into the XregGraphGen folder, then run make all, it should compile to a binary called main, which you should be able to run with ./main <args>. I was able to do this just now
Hi all,
I cannot compile GraphGen inside Docker, due to an error:
'shared_ptr' is not a member of 'std'
.Here is the transcript of everything I did:
Is there a quick fix for this?
The text was updated successfully, but these errors were encountered: