[new-package] coin-or-mp 1.8.4
This commit is contained in:
58
mingw-w64-coin-or-mp/001-fix-build-on-mingw.patch
Normal file
58
mingw-w64-coin-or-mp/001-fix-build-on-mingw.patch
Normal file
@@ -0,0 +1,58 @@
|
||||
--- a/CoinMP/configure
|
||||
+++ b/CoinMP/configure
|
||||
@@ -4046,44 +4046,6 @@
|
||||
{ (exit 1); exit 1; }; }
|
||||
fi
|
||||
enable_shared=yes;
|
||||
-else
|
||||
- case $build in
|
||||
- *-cygwin* | *-mingw*)
|
||||
- coin_disable_shared=yes
|
||||
- if test x"$enable_shared" = xyes; then
|
||||
- case "$CC" in
|
||||
- clang* )
|
||||
- { echo "$as_me:$LINENO: WARNING: Building of DLLs not supported in this configuration." >&5
|
||||
-echo "$as_me: WARNING: Building of DLLs not supported in this configuration." >&2;}
|
||||
- ;;
|
||||
- cl* | */cl* | CL* | */CL* | icl* | */icl* | ICL* | */ICL*)
|
||||
- { echo "$as_me:$LINENO: Building of DLLs not supported in this configuration." >&5
|
||||
-echo "$as_me: Building of DLLs not supported in this configuration." >&6;}
|
||||
- ;;
|
||||
- *gcc*)
|
||||
- if test x"$enable_dependency_linking" = xyes; then
|
||||
- coin_disable_shared=no
|
||||
- else
|
||||
- { echo "$as_me:$LINENO: WARNING: Dependency linking seems to be disabled, so shared libraries (DLLs) will not be built" >&5
|
||||
-echo "$as_me: WARNING: Dependency linking seems to be disabled, so shared libraries (DLLs) will not be built" >&2;}
|
||||
- fi
|
||||
- ;;
|
||||
- *)
|
||||
- { echo "$as_me:$LINENO: WARNING: Building of DLLs not supported in this configuration." >&5
|
||||
-echo "$as_me: WARNING: Building of DLLs not supported in this configuration." >&2;}
|
||||
- ;;
|
||||
- esac
|
||||
- fi
|
||||
- ;;
|
||||
- *-aix*)
|
||||
- coin_disable_shared=yes
|
||||
- platform=AIX
|
||||
- if test x"$enable_shared" = xyes; then
|
||||
- { echo "$as_me:$LINENO: WARNING: Shared objects are not supported." >&5
|
||||
-echo "$as_me: WARNING: Shared objects are not supported." >&2;}
|
||||
- fi
|
||||
- ;;
|
||||
- esac
|
||||
fi
|
||||
if test x"$coin_disable_shared" = xyes; then
|
||||
if test x"$enable_shared" = xyes; then
|
||||
--- a/CoinMP/Makefile.in
|
||||
+++ b/CoinMP/Makefile.in
|
||||
@@ -291,7 +291,7 @@
|
||||
########################################################################
|
||||
pkgconfiglibdir = $(libdir)/pkgconfig
|
||||
pkgconfiglib_DATA = coinmp.pc
|
||||
-addlibsdir = $(DESTDIR)$(datadir)/coin/doc/CoinMP
|
||||
+addlibsdir = $(datadir)/coin/doc/CoinMP
|
||||
addlibs_DATA = examples/Makefile examples/example.c
|
||||
|
||||
########################################################################
|
||||
11
mingw-w64-coin-or-mp/002-fix-build-with-clang.patch
Normal file
11
mingw-w64-coin-or-mp/002-fix-build-with-clang.patch
Normal file
@@ -0,0 +1,11 @@
|
||||
--- a/CoinMP/configure
|
||||
+++ b/CoinMP/configure
|
||||
@@ -11993,7 +11993,7 @@
|
||||
enable_shared_with_static_runtimes_CXX=yes
|
||||
|
||||
if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
|
||||
- archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
|
||||
+ archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
|
||||
# If the export-symbols file already is a .def file (1st line
|
||||
# is EXPORTS), use it as is; otherwise, prepend...
|
||||
archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
|
||||
66
mingw-w64-coin-or-mp/PKGBUILD
Normal file
66
mingw-w64-coin-or-mp/PKGBUILD
Normal file
@@ -0,0 +1,66 @@
|
||||
# Contributor: Mehdi Chinoune <mehdi.chinoune@hotmail.com>
|
||||
|
||||
_realname=coin-or-mp
|
||||
pkgbase=mingw-w64-${_realname}
|
||||
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
|
||||
pkgver=1.8.4
|
||||
pkgrel=1
|
||||
pkgdesc="C-API library for CLP, CBC, and CGL. (mingw-w64)"
|
||||
arch=('any')
|
||||
mingw_arch=('ucrt64' 'clang64' 'clangarm64')
|
||||
url='https://github.com/coin-or/CoinMP'
|
||||
msys2_references=(
|
||||
'archlinux: coin-or-mp'
|
||||
)
|
||||
license=('spdx:CPL-1.0')
|
||||
groups=("${MINGW_PACKAGE_PREFIX}-coin-or")
|
||||
depends=("${MINGW_PACKAGE_PREFIX}-gcc-libs"
|
||||
"${MINGW_PACKAGE_PREFIX}-coin-or-cbc"
|
||||
"${MINGW_PACKAGE_PREFIX}-coin-or-cgl"
|
||||
"${MINGW_PACKAGE_PREFIX}-coin-or-clp"
|
||||
"${MINGW_PACKAGE_PREFIX}-coin-or-coinutils")
|
||||
makedepends=("${MINGW_PACKAGE_PREFIX}-cc"
|
||||
"${MINGW_PACKAGE_PREFIX}-autotools")
|
||||
source=("${url}/archive/releases/${pkgver}/${_realname}-${pkgver}.tar.gz"
|
||||
001-fix-build-on-mingw.patch
|
||||
002-fix-build-with-clang.patch)
|
||||
sha256sums=('ec03a5110d9d79da950669e3400f3b81c4391747b14821d8997f9f8755873150'
|
||||
'c091c865cd50407d93acd0372e1620bceeabec91e652232f0d01ae150b641b88'
|
||||
'84380aa9048f9ce006967defaa0e633f5ca5398efcc3e3b0d570cbaf9a47c7a8')
|
||||
|
||||
prepare() {
|
||||
cd CoinMP-releases-${pkgver}
|
||||
patch -p1 -i "${srcdir}"/001-fix-build-on-mingw.patch
|
||||
|
||||
if [[ ${MINGW_PACKAGE_PREFIX} == *-clang-* ]]; then
|
||||
patch -p1 -i "${srcdir}"/002-fix-build-with-clang.patch
|
||||
fi
|
||||
}
|
||||
|
||||
build() {
|
||||
mkdir -p "${srcdir}/build-${MSYSTEM}" && cd "${srcdir}/build-${MSYSTEM}"
|
||||
|
||||
export lt_cv_deplibs_check_method='pass_all'
|
||||
|
||||
../"CoinMP-releases-${pkgver}"/configure \
|
||||
--prefix="${MINGW_PREFIX}" \
|
||||
--enable-shared \
|
||||
--disable-static \
|
||||
--enable-dependency-linking
|
||||
|
||||
make
|
||||
}
|
||||
|
||||
check() {
|
||||
cd "${srcdir}/build-${MSYSTEM}"
|
||||
|
||||
make check
|
||||
}
|
||||
|
||||
package() {
|
||||
cd "${srcdir}/build-${MSYSTEM}"
|
||||
|
||||
make install DESTDIR="${pkgdir}"
|
||||
|
||||
install -Dm644 "${srcdir}/CoinMP-releases-${pkgver}/CoinMP/LICENSE" "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/LICENSE"
|
||||
}
|
||||
Reference in New Issue
Block a user