COIN-OR::LEMON - Graph Library

Opened 4 years ago

Closed 3 years ago

#481 closed defect (fixed)

Shared library build is broken with glpk

Reported by: amluto Owned by: alpar
Priority: major Milestone: LEMON 1.4 release
Component: core Version: hg main
Keywords: Cc:
Revision id:

Description

If I configure with:

cmake .. -DBUILD_SHARED_LIBS:BOOL=ON -DLEMON_ENABLE_GLPK=YES

then the build fails with lots of errors about undefined glp_ symbols.

The library link line is missing -lglpk. I'd submit a patch, but my cmake-foo isn't very good.

Running:

LDFLAGS=-lglpk cmake .. -DBUILD_SHARED_LIBS:BOOL=ON -DLEMON_ENABLE_GLPK=YES

works around the problem, but that's gross.

Attachments (2)

lemon-1.3-lp-linkage.patch (543 bytes) - added by amluto 4 years ago.
Patch to fix shared library build with GLPK, Clp, and Cbc
70afd6c32697.patch (705 bytes) - added by alpar 3 years ago.

Download all attachments as: .zip

Change History (6)

Changed 4 years ago by amluto

Patch to fix shared library build with GLPK, Clp, and Cbc

comment:1 Changed 4 years ago by amluto

This wasn't specific to GLPK. I've attached a patch to fix the issue for GLPK and COIN. I didn't try to fix SOPLEX and CPLEX, since they're non-free.

Changed 3 years ago by alpar

comment:2 follow-up: Changed 3 years ago by alpar

I believe this simple patch should also work. Could you please check?

comment:3 in reply to: ↑ 2 Changed 3 years ago by amluto

Replying to alpar:

I believe this simple patch should also work. Could you please check?

It works. Thanks.

comment:4 Changed 3 years ago by alpar

  • Resolution set to fixed
  • Status changed from new to closed

This fix is in branches default and 1.3 as [07cd9a2d20e0].

Note: See TracTickets for help on using tickets.