mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-28 18:03:04 +00:00
Merge pull request #15214 from taku0/lp_solve_isnan
lp_solve: fixed build error due to defining isnan
This commit is contained in:
commit
35efc53274
@ -6,14 +6,20 @@ stdenv.mkDerivation rec {
|
|||||||
version = "5.5.2.0";
|
version = "5.5.2.0";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "http://sourceforge.net/projects/lpsolve/files/lpsolve/${version}/lp_solve_${version}_source.tar.gz";
|
url = "mirror://sourceforge/project/lpsolve/lpsolve/${version}/lp_solve_${version}_source.tar.gz";
|
||||||
sha256 = "176c7f023mb6b8bfmv4rfqnrlw88lsg422ca74zjh19i2h5s69sq";
|
sha256 = "176c7f023mb6b8bfmv4rfqnrlw88lsg422ca74zjh19i2h5s69sq";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
patches = [ ./isnan.patch ];
|
||||||
|
|
||||||
buildCommand = ''
|
buildCommand = ''
|
||||||
. $stdenv/setup
|
. $stdenv/setup
|
||||||
tar xvfz $src
|
tar xvfz $src
|
||||||
(
|
(
|
||||||
|
cd lp_solve*
|
||||||
|
eval patchPhase
|
||||||
|
)
|
||||||
|
(
|
||||||
cd lp_solve*/lpsolve55
|
cd lp_solve*/lpsolve55
|
||||||
bash ccc
|
bash ccc
|
||||||
mkdir -pv $out/lib
|
mkdir -pv $out/lib
|
||||||
@ -32,12 +38,11 @@ stdenv.mkDerivation rec {
|
|||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
description = "lp_solve is a Mixed Integer Linear Programming (MILP) solver";
|
description = "A Mixed Integer Linear Programming (MILP) solver";
|
||||||
homepage = "http://lpsolve.sourceforge.net";
|
homepage = "http://lpsolve.sourceforge.net";
|
||||||
license = licenses.gpl2Plus;
|
license = licenses.gpl2Plus;
|
||||||
maintainers = with maintainers; [ smironov ];
|
maintainers = with maintainers; [ smironov ];
|
||||||
platforms = platforms.unix;
|
platforms = platforms.unix;
|
||||||
broken = true;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
13
pkgs/applications/science/math/lp_solve/isnan.patch
Normal file
13
pkgs/applications/science/math/lp_solve/isnan.patch
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
diff -u a/lp_lib.h b/lp_lib.h
|
||||||
|
--- a/lp_lib.h 2016-05-04 19:45:15.753143720 +0900
|
||||||
|
+++ b/lp_lib.h 2016-05-04 19:53:59.536920722 +0900
|
||||||
|
@@ -59,9 +59,6 @@
|
||||||
|
# if defined _WIN32 && !defined __GNUC__
|
||||||
|
# define isnan _isnan
|
||||||
|
# endif
|
||||||
|
-#if defined NOISNAN
|
||||||
|
-# define isnan(x) FALSE
|
||||||
|
-#endif
|
||||||
|
|
||||||
|
#define SETMASK(variable, mask) variable |= mask
|
||||||
|
#define CLEARMASK(variable, mask) variable &= ~(mask)
|
Loading…
Reference in New Issue
Block a user