Skip to content

Updated to latest GLPK which has a new API. Recompiled Windows builds with VC2015.#2

Merged
blegat merged 7 commits intoblegat:masterfrom
tholden:master
Jul 8, 2016
Merged

Updated to latest GLPK which has a new API. Recompiled Windows builds with VC2015.#2
blegat merged 7 commits intoblegat:masterfrom
tholden:master

Conversation

@tholden
Copy link
Copy Markdown
Contributor

@tholden tholden commented Jul 8, 2016

No description provided.

@blegat
Copy link
Copy Markdown
Owner

blegat commented Jul 8, 2016

Thanks a lot for this huge contribution :)
Something I do not get though. What is the version of the API that is now supported ?
At the beginning of the files lpx.c and lpx.h you say that they contain the support for the old API. Where is you code for the new API then ?

@tholden
Copy link
Copy Markdown
Contributor Author

tholden commented Jul 8, 2016

lpx.c and lpx.h are taken from the examples directory of the latest version of GLPK (4.60), with minimal modifications (just commenting out the main function). They act as an intermediary between your code which uses the old API and the new API.

However, please do not merge this pull request yet, as I have subsequently noticed two problems. You are using GPL v2 but GLPK is on GPL v3, so to include those two files, the license also needs to be bumped. Secondly, the Windows builds have a missing dependency.

I'll fix the pull request...

@tholden
Copy link
Copy Markdown
Contributor Author

tholden commented Jul 8, 2016

The previous two commits fix the aforementioned problems. The result passes YALMIP's tests, and also passes glpktest1.m . However, the second of the two tests in glpktest2.m currently crashes MATLAB. From debugging, this seems to be caused by a failure of the assert on line 175 of lpx.c, which has the following associated comment:
/* if cps is NULL (not found), the problem object was created with glp_create_prob rather than with lpx_create_prob */
This should be something fixable. I'll have a look.

@tholden
Copy link
Copy Markdown
Contributor Author

tholden commented Jul 8, 2016

Remaining problem fixed by switching to the lpx_create/delete_prob calls. Passes both test scripts on win64 and win32. Also still passes YALMIP tests.

Should be OK to merge now if you're happy with these changes. You might want to rebuild for Mac and Linux though.

@blegat
Copy link
Copy Markdown
Owner

blegat commented Jul 8, 2016

Excellent ! Thanks a lot :) I will open issues for Linux and Mac builds.

@blegat blegat merged commit 376ae38 into blegat:master Jul 8, 2016
@blegat
Copy link
Copy Markdown
Owner

blegat commented Jul 8, 2016

Your build are with GLPK 4.32 ?

@tholden
Copy link
Copy Markdown
Contributor Author

tholden commented Jul 8, 2016

4.60

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants