| sun4 | SunOS 4 (being phased out) |
| sparc_sunos5 | SunOS 5 (tested on 5.5 and 5.7) |
| i386_linux | Intel x86 Linux |
| i386_nt | Windows 95,98,2000,NT4 |
| alpha_linux | 64-bit Alpha Linux |
Fore each of the architectures, there is the following set of packages
(except that not all CPLEX/XPRESS interfaces are available on allarchitectures):
| eclipse_basic.tgz | alternative | ECLiPSe development system (flexlm-related predicates are dummy and fail always) |
| eclipse_rt.tgz | alternative | ECLiPSe runtime subset (a subset of eclipse_basic) plus flexlm functionality |
| eclipse_misc.tgz | optional | Public domain libraries, probably not relevant for PT |
| eclipse_doc_online.tgz | optional | Documentation in html format |
| eclipse_doc_print.tgz | optional | Documentation in pdf format (does not include Reference Manual) |
| if_cplex65.tgz | optional | Interface to CPLEX 6.5 with CPLEX statically linked (requires development license) |
| if_cplex71.tgz | optional | Interface to CPLEX 7.1 with CPLEX statically linked (requires runtime or development license) |
| if_xpress12.tgz | optional | Interface to XPRESS 12.20 (requires development license) |
| if_xpress1250.tgz | optional | Interface to XPRESS 12.50 (requires development license) |
| if_xpress12parcrisk.tgz | optional | Interface to XPRESS 12.20 (requires intialisation with 'parcrisk' runtime key or development license) |
Installing a development system:
To create a development environment with operational FlexLM licensing functionality, simply unpack both packages eclipse_basic.tgz and eclipse_rt.tgz into the same location.
:- lib(eplex).If only one variant of the library is installed (i.e. only a single if_cplex or if_xpress package has been unpacked), then this one gets loaded by ECLiPSe. This should normally be the case for a runtime installation of ECLiPSe.
:- lib(eplex_xpress).
:- lib(eplex_cplex).If this is still ambiguous (e.g. different versions installed), ECLiPSe will pick an arbitrary one.
A further way to select a particular solver is to make an entry in the eplex_lic_info.ecl file, which is located in the lib subdirectory of the ECLiPSe installation. This method is only recommended for development installations. The file contains entries of the form:
licence(Hostname, Solver, Version, LicStr, LicNum).e.g.
licence('breeze.icparc.ic.ac.uk', cplex, '65', '', 0).
which specifies that on the given machine the if_cplex65 version of the
interface should be used (the last two arguments will be passed to lp_get_license/2
when ECLiPSe tries to obtain a license for the solver, see below). A default
entry is written by giving an ECLiPSe variable in place of the machine
name, e.g.
licence(_Default, xpress, '12', default, 0).This line will match any machine and select if_xpress12 and expect XPRESS licensing information in a default location. Whenever an eplex_lic_info.ecl file is present, ECLiPSe will load the solver variant that corresponds to the first matching line in that file.
After loading the eplex library, it tries to obtain a license immediately by implicitly calling lp_get_license/0. lp_get_license/0 calls lp_get_license/2 with the arguments being the last two arguments of the matching line in eplex_lic_info.ecl. Failure to obtain a license is not fatal (a warning may be printed), a license can always be obtained subsequently using lp_get_license/2.
:- lp_get_license('', 0).
or by making an entry in the eplex_lic_info.ecl file (see above) with the
last two arguments being '' and 0, i.e.
licence(..., ..., ..., '', 0).The license will then be automatically obtained when the library gets loaded or when you call lp_get_license/0.
For using the student version, or if you have a dongle, use
:- lp_get_license(default, 0).For using an xpress.pwd file in the directory /my/pwd/location, use
:- lp_get_license('/my/pwd/location', 0).
If you want the value of the XPRESS environment variable to be used instead,
give an empty string, i.e.
:- lp_get_license('', 0).
In all three cases, you can alternatively make an entry in the eplex_lic_info.ecl
file with the last two arguments corresponding to the arguments of lp_get_license_info/2.
The license will then be automatically obtained when the library gets loaded
or when you call lp_get_license/0.
:- lib(eplex).
:- ( lp_get_license("LICENSE parctechnologies-london\nRUNTIME CPLEX ...", 9999999) ->
true % got a runtime license
; lp_get_license ->
true % got a development license
;
writeln(error, "No license"), % got nothing
abort
).
lp_get_license/2 gets called with a license string and a number which is
the signature for the string.
:- lib(eplex).
:- (
( lp_get_license_challenge(N) ->
Response is 90057741 - (N*N)//19,
lp_get_license("", Response) % get runtime license
;
lp_get_license % try development license
)
->
true % got it
;
writeln(error, "No license"),
abort
).
Note that lp_get_license_challenge/1 will succeed for VAR versions of XPRESS-MP
(e.g. if_xpress12parcrisk) and fail for non-VAR versions (e.g. if_xpress12).
You can therefore write the code such that it works for both.
:- lib(eplex). :- ( lp_get(optimizer, xpress) -> ... code to get XPRESS-MP license ... ; lp_get(optimizer, cplex) -> ... code to get CPLEX license ... ; abort % should not occur ).