-
Notifications
You must be signed in to change notification settings - Fork 525
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
installation error with basic_string #738
Comments
Are you using the newest boost version 1.68? I had the same problem with this library. |
what are gcc/g++ versions you used? |
Can you try the following patch with boost 1.68 and let me know if it works? diff --git a/src/libtriton/ast/z3/tritonToZ3Ast.cpp b/src/libtriton/ast/z3/tritonToZ3Ast.cpp
index dd2aee69..b2c20a96 100644
--- a/src/libtriton/ast/z3/tritonToZ3Ast.cpp
+++ b/src/libtriton/ast/z3/tritonToZ3Ast.cpp
@@ -161,7 +161,7 @@ namespace triton {
}
case DECIMAL_NODE: {
- std::string value(reinterpret_cast<triton::ast::DecimalNode*>(node.get())->getValue());
+ std::string value(reinterpret_cast<triton::ast::DecimalNode*>(node.get())->getValue().convert_to<std::string>());
return this->context.int_val(value.c_str());
}
@@ -277,7 +277,7 @@ namespace triton {
/* If the conversion is used to evaluate a node, we concretize symbolic variables */
if (this->isEval) {
triton::uint512 value = reinterpret_cast<triton::ast::VariableNode*>(node.get())->evaluate();
- std::string strValue(value);
+ std::string strValue(value.convert_to<std::string>());
return this->context.bv_val(strValue.c_str(), symVar->getSize());
} |
Thanks, that fixes the above compile errors. But the Python binding failures from issue #716 are still existing, so that I can't use Triton for python in windows. |
Mmmmh, what about using Appeveyor's artefacts instead of compiling Triton on windows? |
Btw, i'm really not comfortable with Windows ecosystem so that I cannot figure out by myself what's the root cause of these issues. |
If you figure out how to solve them, I will be more than happy to accept your pull request :) |
Apparently the Z3 Prover is linked dynamically with Triton, that's why I had to move the libz3.dll into the python2.7\Lib\site-packages directory as well for it to work. The tests still don't work as they seem to end up in an infinite loop but the python examples finally work. |
sudo make -j install
/triton/triton/src/libtriton/ast/z3/tritonToZ3Ast.cpp: In member function ‘z3::expr triton::ast::TritonToZ3Ast::convert(const SharedAbstractNode&)’:
/triton/triton/src/libtriton/ast/z3/tritonToZ3Ast.cpp:164:96: error: no matching function for call to ‘std::__cxx11::basic_string::basic_string(triton::uint512)’
std::string value(reinterpret_casttriton::ast::DecimalNode*(node.get())->getValue());
What cause this problem?
The text was updated successfully, but these errors were encountered: