I'm very new to programming and just starting learning C++, and I was trying to run this stock market algorithmic trading bot in my terminal. I had ran some very simple C++ command line tool projects in my Xcode successfully but I don't know how to run this type of file in Xcode.
I downloaded the zip file to my computer and followed the guide to download these dependencies, and I guess(?) have both Libcurl: https://curl.haxx.se/docs/install.html and
Jsoncpp: https://github.com/open-source-parsers/jsoncpp installed.
./vcpkg integrate install
Applied user-wide integration for this vcpkg root.
CMake projects should use: "-DCMAKE_TOOLCHAIN_FILE=/Users/irenesmacbook/vcpkg/scripts/buildsystems/vcpkg.cmake"
Does it mean it's successfully done?
I got jsoncpp:x64-osx is already installed. and my vcpkg/package has detect_compiler_x64-osx,
vcpkg-cmake-config_x64-osx,
jsoncpp_x64-osx,
, vcpkg-cmake_x64-osx
I got this error from my mac terminal when I tried to run the bot:
g++ *.cpp -std=c++11 -ljsoncpp -lcurl -o exa.out && ./exa.out -I/usr/local/Cellar/boost/1.67.0_1/include/boost/
duplicate symbol _main in:
/var/folders/x5/9cy_5gsd7jv3nyq0g6_jz9hh0000gn/T/hello-a417ce.o
/var/folders/x5/9cy_5gsd7jv3nyq0g6_jz9hh0000gn/T/hello2-bce365.o
ld: 1 duplicate symbol for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Thanks