Why can't you link your programs with the TWS API provided libraries? Those are the ones IBKR uses and has tested the API against. Using any "similarly named" libraries from source or Debian packages is guaranteed to invite trouble.
Not sure which API version you are using, but Version 10.17.01 (was the "latest" on 2022/08/09) ships with these libraries you should use:
source/CppClient/client/lib/biddll.dll
source/CppClient/client/lib/biddll.lib
source/CppClient/client/lib/eula.txt
source/CppClient/client/lib/libbid.lib
´³¨¹°ù²µ±ð²Ô
toggle quoted message
Show quoted text
On Mon, Sep 19, 2022 at 03:11 PM, thepeete wrote:
Hi,
I'm trying to revive my old linux C++ program that connects to TWS, updating it use IBJts.10.16 (and now .18).? That Decimal type is really messing with me.? I can't link my program with the libraries included with the API, but I was able to download the Intel library and compile it with:
make CC="gcc -fPIC" CALL_BY_REF=0 GLOBAL_RND=0 GLOBAL_FLAGS=0 UNCHANGED_BINARY_FLAGS=0
The -fPIC was necessary for linking.? I am using gcc 12.1.1 20220730
Now my program compiles and links fine, seems to run just fine, except when getting "Decimal" data (e.g. a tick size), I get nonsensical numbers.? As far as I can see, the string received makes sense, but whatever is output by __bid64_from_string gives me monstrosity like 3584865303386914816 (in Hex: 0x31C0000000000000)
Did anybody encountered issues like me with the library?