Hello Andrew,

a program that uses a GLPK library which is not compiled with thread
local storage may fail fatally when run with multiple threads.

I hence suggest to add a function that allows to determine if GLPK was
compiled to be reentrant. We could use the same function to return other
features too.

typedef struct {
   char * option;
   char * value;
} glp_build_options;

#include "config.h"

static glp_build_options build_options[] = {
      {"TLS",
#ifdef TLS
      "available" },
#else
      NULL },
#endif
      {"ODBC_DLNAME",
#ifdef ODBC_DLNAME
      ODBC_DLNAME},
#else
      NULL},
#endif
      {NULL, NULL}
   };

glp_build_options *glp_version_ex() {
   return build_options;
}

Best regards

Heinrich Schuchardt

_______________________________________________
Help-glpk mailing list
Help-glpk@gnu.org
https://lists.gnu.org/mailman/listinfo/help-glpk

Reply via email to