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

Error during compilation #21

Open
leader0001 opened this issue Sep 15, 2023 · 1 comment
Open

Error during compilation #21

leader0001 opened this issue Sep 15, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@leader0001
Copy link

leader0001 commented Sep 15, 2023

I'am trying to compile the project on my Kali Linux.

1- I get the repository with:
git clone https://github.com/vincenzopalazzo/SpyCblock
2- I install dependences:
apt-get update && sudo apt-get install build-essential -y
apt-get install zlib1g-dev -y
apt-get install libncurses-dev -y
apt install cmake -y
3- I try to compile from the script:
./compile.sh

This is the error that I get:

[ 53%] Built target gtest
[ 55%] Built target gtest_main
[ 56%] Building CXX object test/unittest/CMakeFiles/unittest.dir/pointertest.cpp.o
In file included from /home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/test/unittest/pointertest.cpp:16:
In member function ‘rapidjson::GenericPointer<ValueType, Allocator>::Ch* rapidjson::GenericPointer<ValueType, Allocator>::CopyFromRaw(const rapidjson::GenericPointer<ValueType, Allocator>&, std::size_t, std::size_t) [with ValueType = rapidjson::GenericValue<rapidjson::UTF8<> >; Allocator = rapidjson::CrtAllocator]’,
    inlined from ‘rapidjson::GenericPointer<ValueType, Allocator> rapidjson::GenericPointer<ValueType, Allocator>::Append(const Token&, Allocator*) const [with ValueType = rapidjson::GenericValue<rapidjson::UTF8<> >; Allocator = rapidjson::CrtAllocator]’ at /home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/include/rapidjson/pointer.h:238:30,
    inlined from ‘rapidjson::GenericPointer<ValueType, Allocator> rapidjson::GenericPointer<ValueType, Allocator>::Append(const Ch*, rapidjson::SizeType, Allocator*) const [with ValueType = rapidjson::GenericValue<rapidjson::UTF8<> >; Allocator = rapidjson::CrtAllocator]’ at /home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/include/rapidjson/pointer.h:255:39,
    inlined from ‘typename rapidjson::internal::DisableIf<typename rapidjson::internal::RemoveSfinaeTag<rapidjson::internal::SfinaeTag& (*)(rapidjson::internal::NotExpr<rapidjson::internal::IsSame<typename rapidjson::internal::RemoveConst<T>::Type, typename Encoding::Ch> >)>::Type, typename rapidjson::internal::RemoveSfinaeTag<rapidjson::internal::SfinaeTag& (*)(rapidjson::GenericPointer<ValueType, Allocator>)>::Type>::Type rapidjson::GenericPointer<ValueType, Allocator>::Append(T*, Allocator*) const [with T = const char; ValueType = rapidjson::GenericValue<rapidjson::UTF8<> >; Allocator = rapidjson::CrtAllocator]’ at /home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/include/rapidjson/pointer.h:267:62,
    inlined from ‘virtual void Pointer_Append_Test::TestBody()’ at /home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/test/unittest/pointertest.cpp:574:21:
/home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/include/rapidjson/pointer.h:887:24: error: ‘void* memcpy(void*, const void*, size_t)’ offset [0, 23] is out of the bounds [0, 0] [-Werror=array-bounds=]
  887 |             std::memcpy(tokens_, rhs.tokens_, rhs.tokenCount_ * sizeof(Token));
      |             ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1plus: all warnings being treated as errors
make[2]: *** [test/unittest/CMakeFiles/unittest.dir/build.make:272: test/unittest/CMakeFiles/unittest.dir/pointertest.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1683: test/unittest/CMakeFiles/unittest.dir/all] Error 2
make: *** [Makefile:146: all] Error 2
rm: cannot remove 'rapidjson': No such file or directory
The dependecis are OK
Submodule path 'include/spycblockrpc': checked out 'a2120f0cc50f8ccbf58a939a68d9d5ef47b802fd'
fatal: No url found for submodule path 'include/spycblockrpc/lib/cpp-properties' in .gitmodules
fatal: Failed to recurse into submodule path 'include/spycblockrpc'
Already up to date.
Submodule path 'include/bitcoin-cryptography-library': merged in '68061ea1167548aca189ff240895ddd1a50b3d9f'
Already up to date.
Submodule path 'include/cpp-properties': merged in '2ad95c2d639f7114ae9677bdb1d516abe4fb1709'
Already up to date.
Submodule path 'include/progressbar': merged in '05d61b642500a3dbb00237e8e33087917c420a4e'
Updating a2120f0..82ee042
Fast-forward
 .gitmodules                            |   3 +-
 CMakeLists.txt.user.4.10-pre1          | 451 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 src/core/graph/WrapperInformations.cpp |   1 +
 3 files changed, 454 insertions(+), 1 deletion(-)
 create mode 100644 CMakeLists.txt.user.4.10-pre1
Submodule path 'include/spycblockrpc': merged in '82ee042ff768c9c0d65121ba098bc6fd2a06cffa'
Already up to date.
Submodule path 'include/spycblockrpc/lib/cpp-properties': merged in '2ad95c2d639f7114ae9677bdb1d516abe4fb1709'
Submodule path 'lib/cpp-properties': checked out '2ad95c2d639f7114ae9677bdb1d516abe4fb1709'
mkdir: cannot create directory ‘build’: File exists
CMake Error at CMakeLists.txt:10 (find_library):
  Could not find bitcoinapi using the following names: 0.3                                                                                                                                                                                 
                                                                                                                                                                                                                                           
                                                                                                                                                                                                                                           
-- Configuring incomplete, errors occurred!
make: *** No targets specified and no makefile found.  Stop.
@vincenzopalazzo
Copy link
Owner

Mh looks like that rapidjson is causing some problem

In file included from /home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/test/unittest/pointertest.cpp:16:
In member function ‘rapidjson::GenericPointer<ValueType, Allocator>::Ch* rapidjson::GenericPointer<ValueType, Allocator>::CopyFromRaw(const rapidjson::GenericPointer<ValueType, Allocator>&, std::size_t, std::size_t) [with ValueType = rapidjson::GenericValue<rapidjson::UTF8<> >; Allocator = rapidjson::CrtAllocator]’,
    inlined from ‘rapidjson::GenericPointer<ValueType, Allocator> rapidjson::GenericPointer<ValueType, Allocator>::Append(const Token&, Allocator*) const [with ValueType = rapidjson::GenericValue<rapidjson::UTF8<> >; Allocator = rapidjson::CrtAllocator]’ at /home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/include/rapidjson/pointer.h:238:30,
    inlined from ‘rapidjson::GenericPointer<ValueType, Allocator> rapidjson::GenericPointer<ValueType, Allocator>::Append(const Ch*, rapidjson::SizeType, Allocator*) const [with ValueType = rapidjson::GenericValue<rapidjson::UTF8<> >; Allocator = rapidjson::CrtAllocator]’ at /home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/include/rapidjson/pointer.h:255:39,
    inlined from ‘typename rapidjson::internal::DisableIf<typename rapidjson::internal::RemoveSfinaeTag<rapidjson::internal::SfinaeTag& (*)(rapidjson::internal::NotExpr<rapidjson::internal::IsSame<typename rapidjson::internal::RemoveConst<T>::Type, typename Encoding::Ch> >)>::Type, typename rapidjson::internal::RemoveSfinaeTag<rapidjson::internal::SfinaeTag& (*)(rapidjson::GenericPointer<ValueType, Allocator>)>::Type>::Type rapidjson::GenericPointer<ValueType, Allocator>::Append(T*, Allocator*) const [with T = const char; ValueType = rapidjson::GenericValue<rapidjson::UTF8<> >; Allocator = rapidjson::CrtAllocator]’ at /home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/include/rapidjson/pointer.h:267:62,
    inlined from ‘virtual void Pointer_Append_Test::TestBody()’ at /home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/test/unittest/pointertest.cpp:574:21:
/home/kali/Documents/SpyCblock/installer/bitcoin-api-cpp/rapidjson/include/rapidjson/pointer.h:887:24: error: ‘void* memcpy(void*, const void*, size_t)’ offset [0, 23] is out of the bounds [0, 0] [-Werror=array-bounds=]
  887 |             std::memcpy(tokens_, rhs.tokens_, rhs.tokenCount_ * sizeof(Token));
      |             ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1plus: all warnings being treated as errors
make[2]: *** [test/unittest/CMakeFiles/unittest.dir/build.make:272: test/unittest/CMakeFiles/unittest.dir/pointertest.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:1683: test/unittest/CMakeFiles/unittest.dir/all] Error 2
make: *** [Makefile:146: all] Error 2

I will try to play with it a little bit and maybe provide a nix shell where you can build it

@vincenzopalazzo vincenzopalazzo added the bug Something isn't working label Sep 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants