Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

error: iostream.h due to including cplex

I am trying to use cplex in eclipse in Ubuntu 12.04 but when I include ilocplex.h I get the following error

/opt/ibm/ILOG/CPLEX_Studio124/concert/include/ilconcert/ilosys.h:360:22: fatal error: iostream.h: No such file or directory

The only two includes are written as follows:

#include <ilcplex/ilocplex.h>
#include <iostream>

I would appreciate if anyone could help me with this.

like image 488
Shahab Avatar asked Mar 14 '14 16:03

Shahab


1 Answers

At the time ILOG's Concert library was first released, the older iostream.h headers were still common in C++ compilers, but it supports the standard iostream libraries. To use the standard headers and libraries, you need to define the IL_STD preprocessor symbol. Instructions for defining preprocessor directives in Eclipse/C++ can be found in this question.

like image 109
David Nehme Avatar answered Sep 21 '22 15:09

David Nehme