[Bonmin-tickets] [Bonmin] #6: compiling Bonmin library without ASL
Bonmin
coin-trac at coin-or.org
Sat Feb 17 09:15:18 EST 2007
#6: compiling Bonmin library without ASL
-------------------+--------------------------------------------------------
Reporter: stefan | Owner: somebody
Type: defect | Status: new
Priority: minor | Component: component1
Version: | Keywords:
-------------------+--------------------------------------------------------
Hi,
I tried to generate a Bonmin library without having to download the
ASL.[[BR]]
Unfortunately, the build system still tried to generate the
!BonminAmplInterface and the bonmin and nodeSolver executables, which
depend on the ASL.
For the first problem, I removed src/BonminAmplInterface from the SUBDIRS
variable in Bonmin/Makefile.am, and added
{{{
if COIN_HAS_ASL
SUBDIRS += src/BonminAmplInterface
endif
}}}
For the second problem, I first tried to remove also src/Apps from
SUBDIRS, but then also no library was created (since this is also done in
the Apps directory).[[BR]]
Then I tried to define the bonmin and nodeSolver targets only in the case
that COIN_HAS_ASL is defined, but then automake complained.[[BR]]
What seem to work is to make the definition of bonmin_SOURCES and
nodeSolver_SOURCES depending on COIN_HAS_ASL. So if there is no
COIN_HAS_ASL, then I set them to some dummy.cpp which just defines a
main() function that does nothing.
I've attached my modified src/Apps/Makefile.am and dummy.cpp.
Of course, this is only a quick-and-dirty hack. Better should be to put
the binaries that depend on the ASL into a different subdirectory and to
include it into SUBDIRS only if COIN_HAS_ASL is defined.
I'm using Bonmin release 0.1.1.
Thanks,
Stefan
PS: I was not sure whether I should set the type of this ticket to
"defect" or "enhancement", but since the Bonmin manual says that the ASL
is optional, I've chosen "defect.
--
Ticket URL: <https://projects.coin-or.org/Bonmin/ticket/6>
Bonmin <http://projects.coin-or.org/Bonmin>
Basic Open-source Nonlinear Mixed INteger programming
More information about the Bonmin-tickets
mailing list