summaryrefslogtreecommitdiff
path: root/sci-mathematics
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-02-03 09:09:48 +0000
committerV3n3RiX <venerix@koprulu.sector>2023-02-03 09:09:48 +0000
commitf50b7965918dcb8fea45f7473e95d644e6c59813 (patch)
tree5e1b75659115a5d0de111190675b38505778045f /sci-mathematics
parentf80acd7c227d742fc13a5e8a85c96e59c0544d98 (diff)
gentoo auto-resync : 03:02:2023 - 09:09:48
Diffstat (limited to 'sci-mathematics')
-rw-r--r--sci-mathematics/Manifest.gzbin18371 -> 18372 bytes
-rw-r--r--sci-mathematics/lpsolve/Manifest3
-rw-r--r--sci-mathematics/lpsolve/files/lpsolve-5.5.2.11-misc.patch335
-rw-r--r--sci-mathematics/lpsolve/lpsolve-5.5.2.11-r1.ebuild44
4 files changed, 382 insertions, 0 deletions
diff --git a/sci-mathematics/Manifest.gz b/sci-mathematics/Manifest.gz
index 2987c54793bf..176d53cdf079 100644
--- a/sci-mathematics/Manifest.gz
+++ b/sci-mathematics/Manifest.gz
Binary files differ
diff --git a/sci-mathematics/lpsolve/Manifest b/sci-mathematics/lpsolve/Manifest
index 898d3424871f..8dccd5043acb 100644
--- a/sci-mathematics/lpsolve/Manifest
+++ b/sci-mathematics/lpsolve/Manifest
@@ -1,3 +1,6 @@
+AUX lpsolve-5.5.2.11-misc.patch 17012 BLAKE2B f766dd655fcd8d181ae5f3749c04cf4e3b1e30760ca3dfd158be07bf8d7b1eabb12f944d93b3ccf7ba4bff8e576793871172106ae54225a62f25be2c675e1d4e SHA512 0ccb63aaa48a045e9924872cc0a09cb209ccf9069744a18eb797ac49847a99a5ea6b6917cd73209ba75e2cac330b9b7f9b7d05f770a1c7f1d35ea453090aa6be
+DIST lp_solve_5.5.2.11_source.tar.gz 556506 BLAKE2B 4c5b53ddadc9db2cbfb78fee141505ced17719f6bd7c780720c6960cc902165c7c3cffbadd048ad5d61ba3951fd65fd6ac08b8d1874dd57c7ac41a168bccd260 SHA512 24f5a14d0c77a71e1ab3f46e08ea3f85f2f116ae2d3d2c54acddc5fb138251ba258240284060827e1b8b7ef15d580acecc242329ec775802fe5e8028407499bc
DIST lpsolve-5.5.2.0.tar.xz 737000 BLAKE2B 912690a7e4ed5fd5d475f322f5c168554fb3d47281545f42d2383ccbe72b3cb0036f72878c94899889972e266e9cf6ad73e59ac1e822deae753ae5b31a00c9b8 SHA512 341bff74dccf805cfd3aa4ee844a51f3c46ce875e88b1bf079a6ff0074f7cbd27420ec9c6a66a2530098a85c967457214543895651f4c570b956324a51bb9fe6
EBUILD lpsolve-5.5.2.0-r1.ebuild 514 BLAKE2B 283f94706a8f16d1afd8dbbcc9ac2a74a51aa8f28531d9402b22c255bc0b9f0b52f593696c2259439ecbddce544b1399baad2c9ead36be5ba9ea948aa825ddca SHA512 754d585a53e8e31f0cabfe16f8de82848f4a89b58749698732f8e46f0bf21a87f48a91e4d1237e82e13f8ce0dbeb2eeec8fa45eb053349e4862837aa9d12e4ac
+EBUILD lpsolve-5.5.2.11-r1.ebuild 880 BLAKE2B b9ac827bfdd0d517aefdc1e1ff2fce7e9c45bd67e5e110b016855cb2a10ac530e0056749bebb8c59bbeec8c81c0f289012cafa705b3a17976493fea26d4abe9f SHA512 a4c099e826c01c525530414c7774eaae9dffa579d3ee66f189c48150742a7cebf16ffa074516c59fd00b9645728b3472168c277ce4f0a0b6cb243f313ed93da8
MISC metadata.xml 463 BLAKE2B f175dce49b24cb9d330a39f29ab07fa821c098aa0f74ed122b51c91bc8cc50e9eb6c60f3267cdab3c523427c25bc1ef6f70f1b34580829c8fa3266b4cbda6265 SHA512 49f10a80ef197ffaff9be05ec05c0a76a9d3c571e88d2c15148f93ffdbd79c280682801a57c11d61a3b230c38434699612ca1448d40d721e59234ffc8fae857e
diff --git a/sci-mathematics/lpsolve/files/lpsolve-5.5.2.11-misc.patch b/sci-mathematics/lpsolve/files/lpsolve-5.5.2.11-misc.patch
new file mode 100644
index 000000000000..b4e1f91f72f4
--- /dev/null
+++ b/sci-mathematics/lpsolve/files/lpsolve-5.5.2.11-misc.patch
@@ -0,0 +1,335 @@
+--- a/bfp/bfp_LUSOL/ccc
++++ b/bfp/bfp_LUSOL/ccc
+@@ -1,13 +1,13 @@
+ :
+ src='../../shared/commonlib.c ../../colamd/colamd.c lp_LUSOL.c ../../lp_utils.c ../../shared/myblas.c LUSOL/lusol.c'
+
+-c=cc
++c=${CC:-cc}
+
+ #determine platform (32/64 bit)
+ >/tmp/platform.c
+ echo '#include <stdlib.h>'>>/tmp/platform.c
+ echo '#include <stdio.h>'>>/tmp/platform.c
+-echo 'main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
++echo 'int main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
+ $c /tmp/platform.c -o /tmp/platform
+ PLATFORM=`/tmp/platform`
+ rm /tmp/platform /tmp/platform.c >/dev/null 2>&1
+--- a/bfp/bfp_LUSOL/ccc.osx
++++ b/bfp/bfp_LUSOL/ccc.osx
+@@ -1,13 +1,13 @@
+ :
+ src='../../shared/commonlib.c ../../colamd/colamd.c lp_LUSOL.c ../../lp_utils.c ../../shared/myblas.c LUSOL/lusol.c'
+
+-c=cc
++c=${CC:-cc}
+
+ #determine platform (32/64 bit)
+ >/tmp/platform.c
+ echo '#include <stdlib.h>'>>/tmp/platform.c
+ echo '#include <stdio.h>'>>/tmp/platform.c
+-echo 'main(){printf("osx%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
++echo 'int main(){printf("osx%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
+ $c /tmp/platform.c -o /tmp/platform
+ PLATFORM=`/tmp/platform`
+ rm /tmp/platform /tmp/platform.c >/dev/null 2>&1
+--- a/demo/ccc
++++ b/demo/ccc
+@@ -1,6 +1,5 @@
+ src='../lp_MDO.c ../shared/commonlib.c ../colamd/colamd.c ../shared/mmio.c ../shared/myblas.c ../ini.c ../lp_rlp.c ../lp_crash.c ../bfp/bfp_LUSOL/lp_LUSOL.c ../bfp/bfp_LUSOL/LUSOL/lusol.c ../lp_Hash.c ../lp_lib.c ../lp_wlp.c ../lp_matrix.c ../lp_mipbb.c ../lp_MPS.c ../lp_params.c ../lp_presolve.c ../lp_price.c ../lp_pricePSE.c ../lp_report.c ../lp_scale.c ../lp_simplex.c ../lp_SOS.c ../lp_utils.c ../yacc_read.c'
+-c=cc
+-
++c=${CC:-cc}
+ math=-lm
+
+ def=
+--- a/demo/ccc.osx
++++ b/demo/ccc.osx
+@@ -1,5 +1,5 @@
+ src='../bfp/lp_MDO.c ../commonlib.c ../myblas.c ../colamd/colamd.c ../ini.c ../fortify.c ../lp_rlp.c ../lp_crash.c ../bfp/bfp_etaPFI/lp_etaPFI.c ../lp_Hash.c ../lp_lib.c ../lp_wlp.c ../lp_matrix.c ../lp_mipbb.c ../lp_MPS.c ../lp_params.c ../lp_presolve.c ../lp_price.c ../lp_pricePSE.c ../lp_report.c ../lp_scale.c ../lp_simplex.c demo.c ../lp_SOS.c ../lp_utils.c ../yacc_read.c'
+-c=cc
++c=${CC:-cc}
+
+ math=-lm
+
+--- a/lp_solve/ccc
++++ b/lp_solve/ccc
+@@ -1,6 +1,6 @@
+ :
+ src='../lp_MDO.c ../shared/commonlib.c ../colamd/colamd.c ../shared/mmio.c ../shared/myblas.c ../ini.c ../fortify.c ../lp_rlp.c ../lp_crash.c ../bfp/bfp_LUSOL/lp_LUSOL.c ../bfp/bfp_LUSOL/LUSOL/lusol.c ../lp_Hash.c ../lp_lib.c ../lp_wlp.c ../lp_matrix.c ../lp_mipbb.c ../lp_MPS.c ../lp_params.c ../lp_presolve.c ../lp_price.c ../lp_pricePSE.c ../lp_report.c ../lp_scale.c ../lp_simplex.c lp_solve.c ../lp_SOS.c ../lp_utils.c ../yacc_read.c'
+-c=cc
++c=${CC:-cc}
+
+ MYTMP=`mktemp -d "${TMPDIR:-/tmp}"/lp_solve_XXXXXX`
+
+@@ -8,7 +8,7 @@ MYTMP=`mktemp -d "${TMPDIR:-/tmp}"/lp_solve_XXXXXX`
+ >"$MYTMP"/platform.c
+ echo '#include <stdlib.h>'>>"$MYTMP"/platform.c
+ echo '#include <stdio.h>'>>"$MYTMP"/platform.c
+-echo 'main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>"$MYTMP"/platform.c
++echo 'int main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>"$MYTMP"/platform.c
+ $c "$MYTMP"/platform.c -o "$MYTMP"/platform
+ PLATFORM=`"$MYTMP"/platform`
+ rm "$MYTMP"/platform "$MYTMP"/platform.c >/dev/null 2>&1
+@@ -22,7 +22,7 @@ math=-lm
+ echo '#include <stdio.h>'>>"$MYTMP"/isnan.c
+ echo '#include <stdlib.h>'>>"$MYTMP"/isnan.c
+ echo '#include <math.h>'>>"$MYTMP"/isnan.c
+-echo 'main(){isnan(0.0);return 0;}'>>"$MYTMP"/isnan.c
++echo 'int main(){isnan(0.0);return 0;}'>>"$MYTMP"/isnan.c
+ $c "$MYTMP"/isnan.c -o "$MYTMP"/isnan $math >/dev/null 2>&1
+ if [ $? = 0 ]
+ then NOISNAN=
+@@ -42,4 +42,4 @@ then opts='-O0'
+ else dl=-ldl
+ fi
+
+-$c -I.. -I../bfp -I../bfp/bfp_LUSOL -I../bfp/bfp_LUSOL/LUSOL -I../colamd -I../shared $opts $def $NOISNAN -DYY_NEVER_INTERACTIVE -DPARSER_LP -DINVERSE_ACTIVE=INVERSE_LUSOL -DRoleIsExternalInvEngine $src -o bin/$PLATFORM/lp_solve $math $dl
++$c $CFLAGS $LDFLAGS -I.. -I../bfp -I../bfp/bfp_LUSOL -I../bfp/bfp_LUSOL/LUSOL -I../colamd -I../shared $opts $def $NOISNAN -DYY_NEVER_INTERACTIVE -DPARSER_LP -DINVERSE_ACTIVE=INVERSE_LUSOL -DRoleIsExternalInvEngine $src -o bin/$PLATFORM/lp_solve $math $dl
+--- a/lp_solve/ccc.osx
++++ b/lp_solve/ccc.osx
+@@ -1,6 +1,6 @@
+ :
+ src='../lp_MDO.c ../shared/commonlib.c ../colamd/colamd.c ../shared/mmio.c ../shared/myblas.c ../ini.c ../fortify.c ../lp_rlp.c ../lp_crash.c ../bfp/bfp_LUSOL/lp_LUSOL.c ../bfp/bfp_LUSOL/LUSOL/lusol.c ../lp_Hash.c ../lp_lib.c ../lp_wlp.c ../lp_matrix.c ../lp_mipbb.c ../lp_MPS.c ../lp_params.c ../lp_presolve.c ../lp_price.c ../lp_pricePSE.c ../lp_report.c ../lp_scale.c ../lp_simplex.c lp_solve.c ../lp_SOS.c ../lp_utils.c ../yacc_read.c'
+-c=cc
++c=${CC:-cc}
+
+ MYTMP=`mktemp -d "${TMPDIR:-/tmp}"/lp_solve_XXXXXX`
+
+@@ -8,7 +8,7 @@ MYTMP=`mktemp -d "${TMPDIR:-/tmp}"/lp_solve_XXXXXX`
+ >"$MYTMP"/platform.c
+ echo '#include <stdlib.h>'>>"$MYTMP"/platform.c
+ echo '#include <stdio.h>'>>"$MYTMP"/platform.c
+-echo 'main(){printf("osx%d", (int) (sizeof(void *)*8));}'>>"$MYTMP"/platform.c
++echo 'int main(){printf("osx%d", (int) (sizeof(void *)*8));}'>>"$MYTMP"/platform.c
+ $c "$MYTMP"/platform.c -o "$MYTMP"/platform
+ PLATFORM=`"$MYTMP"/platform`
+ rm "$MYTMP"/platform "$MYTMP"/platform.c >/dev/null 2>&1
+@@ -22,7 +22,7 @@ math=-lm
+ echo '#include <stdio.h>'>>"$MYTMP"/isnan.c
+ echo '#include <stdlib.h>'>>"$MYTMP"/isnan.c
+ echo '#include <math.h>'>>"$MYTMP"/isnan.c
+-echo 'main(){isnan(0.0);return 0;}'>>"$MYTMP"/isnan.c
++echo 'int main(){isnan(0.0);return 0;}'>>"$MYTMP"/isnan.c
+ $c "$MYTMP"/isnan.c -o "$MYTMP"/isnan $math >/dev/null 2>&1
+ if [ $? = 0 ]
+ then NOISNAN=
+@@ -37,4 +37,4 @@ dl=-ldl
+
+ opts='-idirafter /usr/include/sys -O3 -DINTEGERTIME -Wno-long-double'
+
+-$c -I.. -I../bfp -I../bfp/bfp_LUSOL -I../bfp/bfp_LUSOL/LUSOL -I../colamd -I../shared $opts $def $NOISNAN -DYY_NEVER_INTERACTIVE -DPARSER_LP -DINVERSE_ACTIVE=INVERSE_LUSOL -DRoleIsExternalInvEngine $src -o bin/$PLATFORM/lp_solve $math $dl
++$c $CFLAGS $LDFLAGS -I.. -I../bfp -I../bfp/bfp_LUSOL -I../bfp/bfp_LUSOL/LUSOL -I../colamd -I../shared $opts $def $NOISNAN -DYY_NEVER_INTERACTIVE -DPARSER_LP -DINVERSE_ACTIVE=INVERSE_LUSOL -DRoleIsExternalInvEngine $src -o bin/$PLATFORM/lp_solve $math $dl
+--- a/lpsolve55/ccc
++++ b/lpsolve55/ccc
+@@ -1,6 +1,6 @@
+ :
+ src='../lp_MDO.c ../shared/commonlib.c ../shared/mmio.c ../shared/myblas.c ../ini.c ../fortify.c ../colamd/colamd.c ../lp_rlp.c ../lp_crash.c ../bfp/bfp_LUSOL/lp_LUSOL.c ../bfp/bfp_LUSOL/LUSOL/lusol.c ../lp_Hash.c ../lp_lib.c ../lp_wlp.c ../lp_matrix.c ../lp_mipbb.c ../lp_MPS.c ../lp_params.c ../lp_presolve.c ../lp_price.c ../lp_pricePSE.c ../lp_report.c ../lp_scale.c ../lp_simplex.c ../lp_SOS.c ../lp_utils.c ../yacc_read.c'
+-c=cc
++c=${CC:-cc}
+
+ MYTMP=`mktemp -d "${TMPDIR:-/tmp}"/lp_solve_XXXXXX`
+
+@@ -8,7 +8,7 @@ MYTMP=`mktemp -d "${TMPDIR:-/tmp}"/lp_solve_XXXXXX`
+ >"$MYTMP"/platform.c
+ echo '#include <stdlib.h>'>>"$MYTMP"/platform.c
+ echo '#include <stdio.h>'>>"$MYTMP"/platform.c
+-echo 'main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>"$MYTMP"/platform.c
++echo 'int main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>"$MYTMP"/platform.c
+ $c "$MYTMP"/platform.c -o "$MYTMP"/platform
+ PLATFORM=`"$MYTMP"/platform`
+ rm "$MYTMP"/platform "$MYTMP"/platform.c >/dev/null 2>&1
+@@ -20,7 +20,7 @@ mkdir bin bin/$PLATFORM >/dev/null 2>&1
+ echo '#include <stdio.h>'>>"$MYTMP"/isnan.c
+ echo '#include <stdlib.h>'>>"$MYTMP"/isnan.c
+ echo '#include <math.h>'>>"$MYTMP"/isnan.c
+-echo 'main(){isnan(0.0);return 0;}'>>"$MYTMP"/isnan.c
++echo 'int main(){isnan(0.0);return 0;}'>>"$MYTMP"/isnan.c
+ $c "$MYTMP"/isnan.c -o "$MYTMP"/isnan $math >/dev/null 2>&1
+ if [ $? = 0 ]
+ then NOISNAN=
+@@ -42,13 +42,13 @@ fi
+ opts='-O3'
+
+ $c -s -c -I.. -I../shared -I../bfp -I../bfp/bfp_LUSOL -I../bfp/bfp_LUSOL/LUSOL -I../colamd $opts $def $NOISNAN -DYY_NEVER_INTERACTIVE -DPARSER_LP -DINVERSE_ACTIVE=INVERSE_LUSOL -DRoleIsExternalInvEngine $src
+-ar rv bin/$PLATFORM/liblpsolve55.a `echo $src|sed s/[.]c/.o/g|sed 's/[^ ]*\///g'`
+-ranlib bin/$PLATFORM/liblpsolve55.a
++${AR:-ar} rv bin/$PLATFORM/liblpsolve55.a `echo $src|sed s/[.]c/.o/g|sed 's/[^ ]*\///g'`
++${RANLIB:-ranlib} bin/$PLATFORM/liblpsolve55.a
+
+ if [ "$so" != "" ]
+ then
+- $c -fpic -s -c -I.. -I../shared -I../bfp -I../bfp/bfp_LUSOL -I../bfp/bfp_LUSOL/LUSOL -I../colamd -I. $opts $NOISNAN -DYY_NEVER_INTERACTIVE -DPARSER_LP -DINVERSE_ACTIVE=INVERSE_LUSOL -DRoleIsExternalInvEngine $src
+- $c -shared -Wl,-Bsymbolic -Wl,-soname,liblpsolve55.so -o bin/$PLATFORM/liblpsolve55.so `echo $src|sed s/[.]c/.o/g|sed 's/[^ ]*\///g'` -lc -lm -ldl
++ $c $CFLAGS $LDFLAGS -fpic -c -I.. -I../shared -I../bfp -I../bfp/bfp_LUSOL -I../bfp/bfp_LUSOL/LUSOL -I../colamd -I. $opts $NOISNAN -DYY_NEVER_INTERACTIVE -DPARSER_LP -DINVERSE_ACTIVE=INVERSE_LUSOL -DRoleIsExternalInvEngine $src
++ $c $CFLAGS $LDFLAGS -shared -Wl,-Bsymbolic -Wl,-soname,liblpsolve55.so -o bin/$PLATFORM/liblpsolve55.so `echo $src|sed s/[.]c/.o/g|sed 's/[^ ]*\///g'` -lc -lm -ldl
+ fi
+
+ rm *.o 2>/dev/null
+--- a/lpsolve55/ccc.aix
++++ b/lpsolve55/ccc.aix
+@@ -4,14 +4,14 @@ src='../lp_MDO.c ../shared/commonlib.c ../shared/mmio.c ../shared/myblas.c ../in
+ type xlc >/dev/null 2>&1
+ if [ $? = 0 ]
+ then c=xlc
+-else c=cc
++else c=${CC:-cc}
+ fi
+
+ #determine platform (32/64 bit)
+ >/tmp/platform.c
+ echo '#include <stdlib.h>'>>/tmp/platform.c
+ echo '#include <stdio.h>'>>/tmp/platform.c
+-echo 'main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
++echo 'int main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
+ $c /tmp/platform.c -o /tmp/platform
+ PLATFORM=`/tmp/platform`
+ rm /tmp/platform /tmp/platform.c >/dev/null 2>&1
+@@ -23,7 +23,7 @@ mkdir bin bin/$PLATFORM >/dev/null 2>&1
+ echo '#include <stdio.h>'>>/tmp/isnan.c
+ echo '#include <stdlib.h>'>>/tmp/isnan.c
+ echo '#include <math.h>'>>/tmp/isnan.c
+-echo 'main(){isnan(0.0);return 0;}'>>/tmp/isnan.c
++echo 'int main(){isnan(0.0);return 0;}'>>/tmp/isnan.c
+ $c /tmp/isnan.c -o /tmp/isnan $math >/dev/null 2>&1
+ if [ $? = 0 ]
+ then NOISNAN=
+@@ -38,8 +38,8 @@ so=y
+ opts='-O2'
+
+ $c -s -c -I.. -I../shared -I../bfp -I../bfp/bfp_LUSOL -I../bfp/bfp_LUSOL/LUSOL -I../colamd $opts $def $NOISNAN -DYY_NEVER_INTERACTIVE -DPARSER_LP -DINVERSE_ACTIVE=INVERSE_LUSOL -DRoleIsExternalInvEngine $src
+-ar rv bin/$PLATFORM/liblpsolve55.a `echo $src|sed s/[.]c/.o/g|sed 's/[^ ]*\///g'`
+-ranlib bin/$PLATFORM/liblpsolve55.a
++${AR:-ar} rv bin/$PLATFORM/liblpsolve55.a `echo $src|sed s/[.]c/.o/g|sed 's/[^ ]*\///g'`
++${RANLIB:-ranlib} bin/$PLATFORM/liblpsolve55.a
+
+ if [ "$so" != "" ]
+ then
+--- a/lpsolve55/ccc.hp-ux
++++ b/lpsolve55/ccc.hp-ux
+@@ -1,12 +1,12 @@
+ :
+ src='../lp_MDO.c ../shared/commonlib.c ../shared/mmio.c ../shared/myblas.c ../ini.c ../fortify.c ../colamd/colamd.c ../lp_rlp.c ../lp_crash.c ../bfp/bfp_LUSOL/lp_LUSOL.c ../bfp/bfp_LUSOL/LUSOL/lusol.c ../lp_Hash.c ../lp_lib.c ../lp_wlp.c ../lp_matrix.c ../lp_mipbb.c ../lp_MPS.c ../lp_params.c ../lp_presolve.c ../lp_price.c ../lp_pricePSE.c ../lp_report.c ../lp_scale.c ../lp_simplex.c ../lp_SOS.c ../lp_utils.c ../yacc_read.c'
+-c=cc
++c=${CC:-cc}
+
+ #determine platform (32/64 bit)
+ >/tmp/platform.c
+ echo '#include <stdlib.h>'>>/tmp/platform.c
+ echo '#include <stdio.h>'>>/tmp/platform.c
+-echo 'main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
++echo 'int main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
+ $c /tmp/platform.c -o /tmp/platform
+ PLATFORM=`/tmp/platform`
+ rm /tmp/platform /tmp/platform.c >/dev/null 2>&1
+@@ -18,7 +18,7 @@ mkdir bin bin/$PLATFORM >/dev/null 2>&1
+ echo '#include <stdio.h>'>>/tmp/isnan.c
+ echo '#include <stdlib.h>'>>/tmp/isnan.c
+ echo '#include <math.h>'>>/tmp/isnan.c
+-echo 'main(){isnan(0.0);return 0;}'>>/tmp/isnan.c
++echo 'int main(){isnan(0.0);return 0;}'>>/tmp/isnan.c
+ $c /tmp/isnan.c -o /tmp/isnan $math >/dev/null 2>&1
+ if [ $? = 0 ]
+ then NOISNAN=
+@@ -33,8 +33,8 @@ so=y
+ opts='-O3'
+
+ $c -s -c -I.. -I../shared -I../bfp -I../bfp/bfp_LUSOL -I../bfp/bfp_LUSOL/LUSOL -I../colamd $opts $def $NOISNAN -DYY_NEVER_INTERACTIVE -DPARSER_LP -DINVERSE_ACTIVE=INVERSE_LUSOL -DRoleIsExternalInvEngine $src
+-ar rv bin/$PLATFORM/liblpsolve55.a `echo $src|sed s/[.]c/.o/g|sed 's/[^ ]*\///g'`
+-ranlib bin/$PLATFORM/liblpsolve55.a
++${AR:-ar} rv bin/$PLATFORM/liblpsolve55.a `echo $src|sed s/[.]c/.o/g|sed 's/[^ ]*\///g'`
++${RANLIB:-ranlib} bin/$PLATFORM/liblpsolve55.a
+
+ if [ "$so" != "" ]
+ then
+--- a/lpsolve55/ccc.osx
++++ b/lpsolve55/ccc.osx
+@@ -1,6 +1,6 @@
+ :
+ src='../lp_MDO.c ../shared/commonlib.c ../shared/mmio.c ../shared/myblas.c ../ini.c ../fortify.c ../colamd/colamd.c ../lp_rlp.c ../lp_crash.c ../bfp/bfp_LUSOL/lp_LUSOL.c ../bfp/bfp_LUSOL/LUSOL/lusol.c ../lp_Hash.c ../lp_lib.c ../lp_wlp.c ../lp_matrix.c ../lp_mipbb.c ../lp_MPS.c ../lp_params.c ../lp_presolve.c ../lp_price.c ../lp_pricePSE.c ../lp_report.c ../lp_scale.c ../lp_simplex.c ../lp_SOS.c ../lp_utils.c ../yacc_read.c'
+-c=cc
++c=${CC:-cc}
+
+ MYTMP=`mktemp -d "${TMPDIR:-/tmp}"/lp_solve_XXXXXX`
+
+@@ -8,7 +8,7 @@ MYTMP=`mktemp -d "${TMPDIR:-/tmp}"/lp_solve_XXXXXX`
+ >"$MYTMP"/platform.c
+ echo '#include <stdlib.h>'>>"$MYTMP"/platform.c
+ echo '#include <stdio.h>'>>"$MYTMP"/platform.c
+-echo 'main(){printf("osx%d", (int) (sizeof(void *)*8));}'>>"$MYTMP"/platform.c
++echo 'int main(){printf("osx%d", (int) (sizeof(void *)*8));}'>>"$MYTMP"/platform.c
+ $c "$MYTMP"/platform.c -o "$MYTMP"/platform
+ PLATFORM=`"$MYTMP"/platform`
+ rm "$MYTMP"/platform "$MYTMP"/platform.c >/dev/null 2>&1
+@@ -20,7 +20,7 @@ mkdir bin bin/$PLATFORM >/dev/null 2>&1
+ echo '#include <stdio.h>'>>"$MYTMP"/isnan.c
+ echo '#include <stdlib.h>'>>"$MYTMP"/isnan.c
+ echo '#include <math.h>'>>"$MYTMP"/isnan.c
+-echo 'main(){isnan(0.0);return 0;}'>>"$MYTMP"/isnan.c
++echo 'int main(){isnan(0.0);return 0;}'>>"$MYTMP"/isnan.c
+ $c "$MYTMP"/isnan.c -o "$MYTMP"/isnan $math >/dev/null 2>&1
+ if [ $? = 0 ]
+ then NOISNAN=
+--- a/lpsolve55/ccc.solaris
++++ b/lpsolve55/ccc.solaris
+@@ -1,12 +1,12 @@
+ :
+ src='../lp_MDO.c ../shared/commonlib.c ../shared/mmio.c ../shared/myblas.c ../ini.c ../fortify.c ../colamd/colamd.c ../lp_rlp.c ../lp_crash.c ../bfp/bfp_LUSOL/lp_LUSOL.c ../bfp/bfp_LUSOL/LUSOL/lusol.c ../lp_Hash.c ../lp_lib.c ../lp_wlp.c ../lp_matrix.c ../lp_mipbb.c ../lp_MPS.c ../lp_params.c ../lp_presolve.c ../lp_price.c ../lp_pricePSE.c ../lp_report.c ../lp_scale.c ../lp_simplex.c ../lp_SOS.c ../lp_utils.c ../yacc_read.c'
+-c=cc
++c=${CC:-cc}
+
+ #determine platform (32/64 bit)
+ >/tmp/platform.c
+ echo '#include <stdlib.h>'>>/tmp/platform.c
+ echo '#include <stdio.h>'>>/tmp/platform.c
+-echo 'main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
++echo 'int main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
+ $c /tmp/platform.c -o /tmp/platform
+ PLATFORM=`/tmp/platform`
+ rm /tmp/platform /tmp/platform.c >/dev/null 2>&1
+@@ -18,7 +18,7 @@ mkdir bin bin/$PLATFORM >/dev/null 2>&1
+ echo '#include <stdio.h>'>>/tmp/isnan.c
+ echo '#include <stdlib.h>'>>/tmp/isnan.c
+ echo '#include <math.h>'>>/tmp/isnan.c
+-echo 'main(){isnan(0.0);return 0;}'>>/tmp/isnan.c
++echo 'int main(){isnan(0.0);return 0;}'>>/tmp/isnan.c
+ $c /tmp/isnan.c -o /tmp/isnan $math >/dev/null 2>&1
+ if [ $? = 0 ]
+ then NOISNAN=
+@@ -33,8 +33,8 @@ so=y
+ opts='-O3'
+
+ $c -s -c -I.. -I../shared -I../bfp -I../bfp/bfp_LUSOL -I../bfp/bfp_LUSOL/LUSOL -I../colamd $opts $def $NOISNAN -DYY_NEVER_INTERACTIVE -DPARSER_LP -DINVERSE_ACTIVE=INVERSE_LUSOL -DRoleIsExternalInvEngine $src
+-ar rv bin/$PLATFORM/liblpsolve55.a `echo $src|sed s/[.]c/.o/g|sed 's/[^ ]*\///g'`
+-ranlib bin/$PLATFORM/liblpsolve55.a
++${AR:-ar} rv bin/$PLATFORM/liblpsolve55.a `echo $src|sed s/[.]c/.o/g|sed 's/[^ ]*\///g'`
++${RANLIB:-ranlib} bin/$PLATFORM/liblpsolve55.a
+
+ if [ "$so" != "" ]
+ then
+--- a/lpsolve55/cccLUSOL.osx
++++ b/lpsolve55/cccLUSOL.osx
+@@ -1,11 +1,11 @@
+ src='../lp_MDO.c ../shared/commonlib.c ../shared/mmio.c ../shared/myblas.c ../ini.c ../fortify.c ../colamd/colamd.c ../lp_rlp.c ../lp_crash.c ../bfp/bfp_LUSOL/lp_LUSOL.c ../bfp/bfp_LUSOL/LUSOL/lusol.c ../lp_Hash.c ../lp_lib.c ../lp_wlp.c ../lp_matrix.c ../lp_mipbb.c ../lp_MPS.c ../lp_params.c ../lp_presolve.c ../lp_price.c ../lp_pricePSE.c ../lp_report.c ../lp_scale.c ../lp_simplex.c ../lp_SOS.c ../lp_utils.c ../yacc_read.c ../bfp/bfp_LUSOL/lusol.c'
+-c=cc
++c=${CC:-cc}
+
+ #determine platform (32/64 bit)
+ >/tmp/platform.c
+ echo '#include <stdlib.h>'>>/tmp/platform.c
+ echo '#include <stdio.h>'>>/tmp/platform.c
+-echo 'main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
++echo 'int main(){printf("ux%d", (int) (sizeof(void *)*8));}'>>/tmp/platform.c
+ $c /tmp/platform.c -o /tmp/platform
+ PLATFORM=`/tmp/platform`
+ rm /tmp/platform /tmp/platform.c >/dev/null 2>&1
+@@ -17,7 +17,7 @@ mkdir bin bin/$PLATFORM >/dev/null 2>&1
+ echo '#include <stdio.h>'>>/tmp/isnan.c
+ echo '#include <stdlib.h>'>>/tmp/isnan.c
+ echo '#include <math.h>'>>/tmp/isnan.c
+-echo 'main(){isnan(0.0);return 0;}'>>/tmp/isnan.c
++echo 'int main(){isnan(0.0);return 0;}'>>/tmp/isnan.c
+ $c /tmp/isnan.c -o /tmp/isnan $math >/dev/null 2>&1
+ if [ $? = 0 ]
+ then NOISNAN=
diff --git a/sci-mathematics/lpsolve/lpsolve-5.5.2.11-r1.ebuild b/sci-mathematics/lpsolve/lpsolve-5.5.2.11-r1.ebuild
new file mode 100644
index 000000000000..3e8f059ed599
--- /dev/null
+++ b/sci-mathematics/lpsolve/lpsolve-5.5.2.11-r1.ebuild
@@ -0,0 +1,44 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit toolchain-funcs
+
+DESCRIPTION="Mixed Integer Linear Programming (MILP) solver"
+HOMEPAGE="https://sourceforge.net/projects/lpsolve/"
+SRC_URI="mirror://sourceforge/${PN}/lp_solve_${PV}_source.tar.gz"
+S="${WORKDIR}"/lp_solve_$(ver_cut 1-2)
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~loong ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux"
+
+DEPEND="sci-libs/colamd"
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-5.5.2.11-misc.patch
+)
+
+src_compile() {
+ tc-export AR CC RANLIB LD
+
+ cd lpsolve55 || die
+ sh -x ccc || die
+
+ rm bin/ux*/liblpsolve55.a || die
+
+ cd ../lp_solve || die
+ sh -x ccc || die
+}
+
+src_install() {
+ einstalldocs
+
+ dobin lp_solve/bin/ux*/lp_solve
+ dolib.so lpsolve55/bin/ux*/liblpsolve55.so
+
+ insinto /usr/include/lpsolve
+ doins *.h
+}