Smile
Smile

Reputation: 33

Integrating concorde tsp solver on Windows C++ Visual Studio x64 project

We are attempting to integrate the Concorde TSP solver in our Windows x64 C++ Visual Studio project. We have tried for two days now. Without luck. We don't understand how to do it, or if it is even possible. The documentation and programs is old. But from what we have found on the internet is should still be the fastest and best version of the Traveling salesman problem(TSP). But if that is outdated information. Please let us now of a better version, that is compatible with our needs. We would happily move away from this version.

We have tried unpacking, configuring, and compiling Concorde. Than adding it to our project without any luck.

Whan unpacking, configuring, and compiling Concord we have used Windows Subsystem for Linux (WSL) with QSopt

Despite trying to following the guide and info on the internet, we are encountering issues with the integration process.

What We Have Done:

Downloaded Concorde from Concorde TSP solver page . Download QSopt from QSopt page, choosing the Ubuntu 18 (with -fPIC). Have tryd Windows/Cygwin and Red Hat Linux 8.0 aswell but Ubuntu looks to work(qsopt.a and qsopt.h).

Setting Up Environment is done like this:

Installed and configured WSL on Windows. Placed qsopt.a and qsopt.h in a directory accessible from WSL (/mnt/c/path_to_qsopt_directory). Configuring Concorde:

Ran ./configure script in Concorde directory with --with-qsopt=/mnt/c/path_to_qsopt_directory. Verified configuration in INCLUDE/config.h. Compiling Concorde:

Ran make to compile Concorde and its libraries (concorde.a). This part looks to be successful. But maybe we have missed something?

Trying to Integrating with Visual Studio:

Configured Visual Studio project to include concorde.h, qsopt.h header. Linked against concorde.a, qsopt.a.

Current Issue(Error Messages) while compilation : Inside the concorde.h we get this error (Are they important? Can we just remove them?): Cannot open include file: 'sys/time.h', # include <unistd.h>, # include <sys/resource.h>, # include <sys/socket.h>, # include <netdb.h>, # include <netinet/in.h>.

*linking(Main problem...) library is corrupt qsopt.a : warning LNK4272: library machine type 'x86' conflicts with target machine type 'x64' concorde.a : fatal error LNK1136: invalid or corrupt file

Additional Information: Operating System: Windows 10 Development Environment: Visual Studio 2019 WSL Distribution: (Ubuntu) Thank you for your assistance in resolving this integration issue.

Upvotes: 0

Views: 128

Answers (0)

Related Questions