sakhnik / gpwsafe Goto Github PK
View Code? Open in Web Editor NEWpwsafe reimplementation compatible with recent PasswordSafe
pwsafe reimplementation compatible with recent PasswordSafe
Make fails for me on the tests. (Ubuntu 18.04 googletest 1.8.0-6)
/usr/bin/ld: /usr/local/lib/libgtest.a(gtest-all.cc.o): undefined reference to symbol 'pthread_key_delete@@GLIBC_2.2.5'
//lib/x86_64-linux-gnu/libpthread.so.0: error adding symbols: DSO missing from command line
clang: error: linker command failed with exit code 1 (use -v to see invocation)
test/CMakeFiles/KeyStretchTest.dir/build.make:99: recipe for target 'test/KeyStretchTest' failed
Adding ${CMAKE_THREAD_LIBS_INIT}
to the test/CMakeFiles.txt fixes it.
I don't know if that's the right way or if anyone else has this issue.
I found my solution at: https://stackoverflow.com/questions/31591142/how-do-i-make-gtest-work
Let me know if you want me to make a pull request. Or let me know if I'm doing something wrong.
Here's a diff:
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index ba5104f..880cf0d 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -28,7 +28,7 @@ set(UNIT_TESTS
set(LIBRARIES libgpwsafe
${LIBGCRYPT_LIBRARIES}
${Boost_SYSTEM_LIBRARIES} ${Boost_FILESYSTEM_LIBRARIES}
- ${GTEST_BOTH_LIBRARIES})
+ ${GTEST_BOTH_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT})
foreach(TEST ${UNIT_TESTS})
add_executable(${TEST} ${TEST}.cc)
I'm unable to compile. Running Ubuntu 14.10. Suggestions would be welcome.
-std=c++14
option until I changed it to c++1y
http://www.phoronix.com/scan.php?page=news_item&px=MTQxOTc/tmp/gpwsafe-0.20.1/src/CommandList.cc: In member function ‘virtual void gPWS::CommandList::Execute(const gPWS::Command::Params&)’:
/tmp/gpwsafe-0.20.1/src/CommandList.cc:71:33: error: parameter declared ‘auto’
[](const auto &a, const auto &b)
^
/tmp/gpwsafe-0.20.1/src/CommandList.cc:71:48: error: parameter declared ‘auto’
[](const auto &a, const auto &b)
^
/tmp/gpwsafe-0.20.1/src/CommandList.cc: In lambda function:
/tmp/gpwsafe-0.20.1/src/CommandList.cc:73:29: error: ‘a’ was not declared in this scope
return a->first.size() < b->first.size();
^
/tmp/gpwsafe-0.20.1/src/CommandList.cc:73:47: error: ‘b’ was not declared in this scope
return a->first.size() < b->first.size();
^
In file included from /usr/include/c++/4.8/algorithm:62:0,
from /usr/include/boost/pool/pool.hpp:25,
from /usr/include/boost/pool/singleton_pool.hpp:25,
from /usr/include/boost/pool/pool_alloc.hpp:78,
from /tmp/gpwsafe-0.20.1/src/Memory.hh:25,
from /tmp/gpwsafe-0.20.1/src/Defs.hh:24,
from /tmp/gpwsafe-0.20.1/src/IEmitter.hh:24,
from /tmp/gpwsafe-0.20.1/src/Command.hh:24,
from /tmp/gpwsafe-0.20.1/src/CommandList.hh:25,
from /tmp/gpwsafe-0.20.1/src/CommandList.cc:22:
/usr/include/c++/4.8/bits/stl_algo.h: In instantiation of ‘_FIter std::max_element(_FIter, _FIter, _Compare) [with _FIter = __gnu_cxx::__normal_iterator<std::_Rb_tree_const_iterator<std::pair<const std::basic_string<char, std::char_traits<char>, gPWS::SecureAllocator<char> >, std::shared_ptrgPWS::Entry > >_, std::vector<std::_Rb_tree_const_iterator<std::pair<const std::basic_string<char, std::char_traits<char>, gPWS::SecureAllocator<char> >, std::shared_ptrgPWS::Entry > > > >; _Compare = gPWS::CommandList::Execute(const gPWS::Command::Params&)::__lambda0]’:
/tmp/gpwsafe-0.20.1/src/CommandList.cc:74:19: required from here
/usr/include/c++/4.8/bits/stl_algo.h:6316:32: error: no match for call to ‘(gPWS::CommandList::Execute(const gPWS::Command::Params&)::__lambda0) (std::_Rb_tree_const_iterator<std::pair<const std::basic_string<char, std::char_traits<char>, gPWS::SecureAllocator<char> >, std::shared_ptrgPWS::Entry > >&, std::_Rb_tree_const_iterator<std::pair<const std::basic_string<char, std::char_traits<char>, gPWS::SecureAllocator<char> >, std::shared_ptrgPWS::Entry > >&)’
if (__comp(___result, ___first))
^
/tmp/gpwsafe-0.20.1/src/CommandList.cc:71:19: note: candidates are:
[](const auto &a, const auto &b)
^
In file included from /usr/include/c++/4.8/algorithm:62:0,
from /usr/include/boost/pool/pool.hpp:25,
from /usr/include/boost/pool/singleton_pool.hpp:25,
from /usr/include/boost/pool/pool_alloc.hpp:78,
from /tmp/gpwsafe-0.20.1/src/Memory.hh:25,
from /tmp/gpwsafe-0.20.1/src/Defs.hh:24,
from /tmp/gpwsafe-0.20.1/src/IEmitter.hh:24,
from /tmp/gpwsafe-0.20.1/src/Command.hh:24,
from /tmp/gpwsafe-0.20.1/src/CommandList.hh:25,
from /tmp/gpwsafe-0.20.1/src/CommandList.cc:22:
/usr/include/c++/4.8/bits/stl_algo.h:6316:32: note: void (_)() <conversion>
if (__comp(___result, *__first))
^
/usr/include/c++/4.8/bits/stl_algo.h:6316:32: note: candidate expects 1 argument, 3 provided
/tmp/gpwsafe-0.20.1/src/CommandList.cc:71:49: note: gPWS::CommandList::Execute(const gPWS::Command::Params&)::__lambda0
[](const auto &a, const auto &b)
^
/tmp/gpwsafe-0.20.1/src/CommandList.cc:71:49: note: candidate expects 0 arguments, 2 provided
make[2]: *_\* [src/CMakeFiles/gpwsafe.dir/CommandList.cc.o] Error 1
make[1]: **\* [src/CMakeFiles/gpwsafe.dir/all] Error 2
make: **\* [all] Error 2
```
```
When creating a new entry, if an empty password is given (i.e. when I want to generate a random password) gpwsafe will throw a "Can't get password" exception. Commenting out lines 73-74 of src/Terminal.cc seems to fix this ...
I'd love to use gpwsafe but since I set up password safe to use my yubikey for authentification, I can't. Please support yubikey authentification! :-)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.