Loki-Astari / ThorsMongo

C++ MongoDB API and BSON/JSON Serialization library
GNU General Public License v3.0
316 stars 72 forks source link

Unable to configure: no Tcl_Init in -ltcl #57

Closed vanschroeder closed 4 years ago

vanschroeder commented 4 years ago

Describe the bug Can not complete configure. Complains that there is no Tcl_Init in -ltcl

checking for Tcl_Init in -ltcl... no configure: error: The build tools needs libtcl. Please install it.

Yet tcl and libtcl are installed

output of sudo apt-get install libtcl8.6: libtcl8.6 is already the newest version (8.6.8+dfsg-3)

A description of how to build and run the code

$ ./configure --disable-binary

Expected behavior To be able to complete the config script so I can make

Environment:

$ gcc -v Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/7/lto-wrapper OFFLOAD_TARGET_NAMES=nvptx-none OFFLOAD_TARGET_DEFAULT=1 Target: x86_64-linux-gnu Configured with: ../src/configure -v --with-pkgversion='Ubuntu 7.4.0-1ubuntu1~18.04.1' --with-bugurl=file:///usr/share/doc/gcc-7/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++ --prefix=/usr --with-gcc-major-version-only --program-suffix=-7 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-libmpx --enable-plugin --enable-default-pie --with-system-zlib --with-target-system-zlib --enable-objc-gc=auto --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu Thread model: posix gcc version 7.4.0 (Ubuntu 7.4.0-1ubuntu1~18.04.1)

Loki-Astari commented 4 years ago

I will need to get a copy of Mint for virtual machine to try and reproduce.

Loki-Astari commented 4 years ago

Try installing the dev version of tcl.

sudo apt-get install tcl-dev

You can test to see if the libtcl is installed with:

echo "int main(){}" > t.cpp g++ t.cpp -ltcl

If that compiles then you have a correctly installed tcl.

vanschroeder commented 4 years ago

No luck

Per your instructions, tcl does seem to be correctly installed:

$ echo "int main(){}" > t.cpp
$ g++ t.cpp -ltcl
$ ls
a.out  t.cpp

But no change in results with ./configure --disable-binary

Loki-Astari commented 4 years ago

I managed to get it working on a clean Mint:

sudo apt-get install g++ git git clone https://github.com/Loki-Astari/ThorsSerializer.git

I assume you already have the above. The following addition packages are also needed.

# Libs needed by the build/test/validation tools sudo apt-get install python-dev tcl-dev tk-dev cmake

# Libs needed by ThorsSerializer code # The next line must be done on its own (not sure why) sudo apt-get install libboost-all-dev # You will also need lib yaml unless you add --disable-yaml with the configure sudo apt-get install libyaml-dev

At this point the rest should work

./configure --disable-binary make sudo make install

That should be everything.

vanschroeder commented 4 years ago

On my end I installed tk-dev, libboost-all-dev and libyaml-dev

end result was

 Install - release - libThorSerialize17.so
End Installing Libraries
Building Dir Serialize Finish
Building Dir src Finish

Thanks for the rapid help in getting the issue resolved. Hopefully docs will be updated to get other mint users through the install process