Skip to content

Commit

Permalink
Merging master
Browse files Browse the repository at this point in the history
  • Loading branch information
tkralphs committed Dec 27, 2021
2 parents 1fa082b + 4b9a4f2 commit 6818f1b
Show file tree
Hide file tree
Showing 19 changed files with 354 additions and 323 deletions.
4 changes: 0 additions & 4 deletions .ci/.travis.pre

This file was deleted.

9 changes: 0 additions & 9 deletions .ci/appveyor.post

This file was deleted.

11 changes: 0 additions & 11 deletions .ci/appveyor.pre

This file was deleted.

4 changes: 2 additions & 2 deletions .coin-or/Dependencies
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ThirdParty/ASL https://github.com/coin-or-tools/ThirdParty-ASL master
ThirdParty/ASL https://github.com/coin-or-tools/ThirdParty-ASL stable/2.0
ThirdParty/Glpk https://github.com/coin-or-tools/ThirdParty-Glpk master
ThirdParty/Mumps https://github.com/coin-or-tools/ThirdParty-Mumps master
ThirdParty/Mumps https://github.com/coin-or-tools/ThirdParty-Mumps stable/3.0
Data/Sample https://github.com/coin-or-tools/Data-Sample master
Data/miplib3 https://github.com/coin-or-tools/Data-miplib3 master
CoinUtils https://github.com/coin-or/CoinUtils refactor
Expand Down
8 changes: 3 additions & 5 deletions .coin-or/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@ Description:
License: Eclipse Public License 2.0
LicenseURL: http://www.opensource.org/licenses/EPL-2.0
Zenodo: 173509563
Appveyor:
Status: chribnemsgm9th0x
Bintray:
IncludedIn:
Package: Cbc
Language:
- C++
Expand All @@ -24,15 +22,15 @@ Description:
Dependencies:
- Description: ThirdParty wrapper for building ASL
URL: https://github.com/coin-or-tools/ThirdParty-ASL
Version: master
Version: stable/2.0
Required: Optional
- Description: ThirdParty wrapper for building Glpk
URL: https://github.com/coin-or-tools/ThirdParty-Glpk
Version: master
Required: Optional
- Description: ThirdParty wrapper for building Mumps
URL: https://github.com/coin-or-tools/ThirdParty-Mumps
Version: master
Version: stable/3.0
Required: Optional
- Description: Sample data files
URL: https://github.com/coin-or-tools/Data-Sample
Expand Down
46 changes: 29 additions & 17 deletions .coin-or/generate_readme
Original file line number Diff line number Diff line change
Expand Up @@ -22,29 +22,41 @@ make_header

echo "Cbc (*C*oin-or *b*ranch and *c*ut) is an open-source mixed integer linear programming solver written in C++.
It can be used as a callable library or using a stand-alone executable.
It can be called through
* AIMMS (via the [AIMMSlinks](https://github.com/coin-or/AIMMSlinks) project),
* AMPL (natively),
* [CMPL](https://github.com/coin-or/Cmpl),
* [CyLP](https://github.com/coin-or/CyLP),
* GAMS (through the [GAMSlinks](https://github.com/coin-or/GAMSlinks) project),
* [JuMP](https://github.com/JuliaOpt/JuMP.jl),
* Mathematica,
* [MiniZinc](http://www.minizinc.org/),
* MPL (through the [CoinMP](https://github.com/coin-or/CoinMP) project),
* [OpenSolver for Excel](http://opensolver.org),
* [Google's or-tools](https://developers.google.com/optimization),
* [PuLP](https://github.com/coin-or/PuLP),
* [python-mip](https://github.com/coin-or/python-mip), and
* Python (e.g., [cbcpy](https://pypi.org/project/cbcpy)), among others.
It can be used in a wide variety of ways through various modeling systems, packages, etc.
* Stand-alone modeling languages and systems
* AIMMS (via the [AIMMSlinks](https://github.com/coin-or/AIMMSlinks) project),
* AMPL (natively),
* [CMPL](https://github.com/coin-or/Cmpl),
* GAMS (through the [GAMSlinks](https://github.com/coin-or/GAMSlinks) project),
* Mathematica,
* Matlab (https://inverseproblem.co.nz/OPTI/)
* [MiniZinc](http://www.minizinc.org/),
* MPL (through the [CoinMP](https://github.com/coin-or/CoinMP) project),
* R (https://rdrr.io/github/yuehmeir2/myFormAssembler/man/cbc.html)
* Python-based modeling languages and extensions
* [cbcpy](https://pypi.org/project/cbcpy).
* [cvxpy](https://github.com/cvxpy/cvxpy)
* [CyLP](https://github.com/coin-or/CyLP),
* [Google's or-tools](https://developers.google.com/optimization),
* [PuLP](https://github.com/coin-or/PuLP)/[DiPPy](https://github.com/coin-or/Dip),
* [python-mip](https://github.com/coin-or/python-mip),
* [yaposib](https://github.com/coin-or/yaposib)
* Extensions in other languages
* [JuMP](https://github.com/JuliaOpt/JuMP.jl) (Julia),
* [rust-lp-modeler](https://github.com/jcavat/rust-lp-modeler) (Rust)
* [good_lp](https://github.com/rust-or/good_lp) (Rust)
* Spreadsheet extensions
* [OpenSolver for Excel](http://opensolver.org)
* [OpenSolver for Google Sheets](https://opensolver.org/opensolver-for-google-sheets/)
Binaries for most platforms are available for download from
[here](https://www.coin-or.org/download/binary/Cbc). AMPL also provides
stand-alone [Cbc
executables](http://ampl.com/products/solvers/open-source/#cbc) that can be
used with (or without) AMPL. Julia also provides a wide range of
used with (or without) AMPL. Julia provides a wide range of
[binaries](https://github.com/JuliaBinaryWrappers/Cbc_jll.jl/releases).
Alternatives include your favorite package manager, as detailed below.
Alternatives include [conda](https://github.com/conda-forge/coin-or-cbc-feedstock) and
your favorite package manager, as detailed [below](https://github.com/coin-or/Cbc#binaries).
Cbc is developed by John Forrest, now retired from IBM Research, and others.
The project is currently managed by John Forrest, [Ted
Expand Down
103 changes: 103 additions & 0 deletions .github/workflows/linux-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
---
name: Linux build and test
on:
push:
branches:
- 'master'
- 'stable/*'
pull_request:
branches:
- '*'
release:
types:
- created

jobs:
test:
name: Run tests
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-18.04, ubuntu-20.04]
build_static: [true, false]
flags: [ADD_CXXFLAGS=-fvisibility=hidden]
download_requirements: [sudo apt install -y -qq gfortran liblapack-dev libmetis-dev libnauty2-dev]
include:
- os: macos-10.15
build_static: false
flags: CC=clang OSX=10.15
download_requirements: brew install metis bash
- os: macos-10.15
build_static: false
flags: CC=gcc-9 CXX=g++-9 OSX=10.15
download_requirements: brew install metis bash
- os: macos-10.15
build_static: false
flags: CC=gcc-10 CXX=g++-10 OSX=10.15
download_requirements: brew install metis bash
steps:
- name: Checkout source
uses: actions/checkout@v2
with:
path: ${{ github.event.repository.name }}
- name: Install required packages from package manager
run: ${{ matrix.download_requirements }}
- name: Checkout coinbrew
uses: actions/checkout@v2
with:
repository: coin-or/coinbrew
path: coinbrew
- name: Build project
run: |
export ${{ matrix.flags }}
ADD_ARGS=()
ADD_ARGS+=( --no-prompt )
ADD_ARGS+=( --skip='ThirdParty/Metis ThirdParty/Mumps ThirdParty/Blas ThirdParty/Lapack' )
ADD_BUILD_ARGS=()
ADD_BUILD_ARGS+=( --tests main --enable-relocatable )
ADD_BUILD_ARGS+=( --verbosity 2 )
[[ ${{ matrix.build_static }} == "true" ]] && \
ADD_BUILD_ARGS+=( --static --with-lapack='-llapack -lblas -lgfortran -lquadmath -lm' )
bash coinbrew/coinbrew fetch ${{ github.event.repository.name }} --skip-update \
"${ADD_ARGS[@]}"
bash coinbrew/coinbrew build ${{ github.event.repository.name }} \
"${ADD_ARGS[@]}" "${ADD_BUILD_ARGS[@]}" \
ADD_CXXFLAGS="${ADD_CXXFLAGS}" CC=${CC} CXX=${CXX}
[[ ${CC} ]] && CC="${CC}" || CC=""
echo "CC=${CC}" >> $GITHUB_ENV
- name: Archive dist contents
run: |
cp ${{ github.event.repository.name }}/README.md dist/
cp ${{ github.event.repository.name }}/LICENSE dist/
tar -czvf release.tar.gz -C dist .
- name: Checkout package name generation script
uses: actions/checkout@v2
with:
repository: coin-or-tools/platform-analysis-tools
path: tools
ref: 0.0.1
- name: Retrieve platform info
run: |
python3 -m venv venv
source venv/bin/activate
pip install -r tools/requirements.txt
[[ ${{ matrix.build_static }} == "true" ]] && buildtype=static || buildtype=
platform_str=`python3 tools/hsf_get_platform.py -b $buildtype`
echo "platform_string=${platform_str}" >> $GITHUB_ENV
- name: Upload Artifact
if: ${{ github.event_name == 'pull_request'}}
uses: actions/upload-artifact@v2
with:
name: ${{ github.event.repository.name }}-${{ github.head_ref }}-${{ env.platform_string }}.tar.gz
path: release.tar.gz
if-no-files-found: error
- name: Upload package to release
if: ${{ github.event_name == 'release'}}
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./release.tar.gz
asset_name: ${{ github.event.repository.name }}-${{ github.event.release.tag_name }}-${{ env.platform_string }}.tar.gz
asset_content_type: application/gzip
20 changes: 20 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Create Release

on:
push:
tags:
- '*'

jobs:
create_release:
runs-on: ubuntu-latest
steps:
- uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.TKRALPHS_RELEASE }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: false
113 changes: 113 additions & 0 deletions .github/workflows/windows-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
---
name: Windows build and test
on:
push:
branches:
- 'master'
- 'stable/*'
pull_request:
branches:
- '*'
release:
types:
- created

jobs:
test:
name: Run tests
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include: [
{ os: windows-2019, arch: x86_64, msystem: mingw64, debug: true, suffix: "-dbg" },
{ os: windows-2019, arch: x86_64, msystem: mingw64, debug: false, suffix: "" },
{ os: windows-2019, arch: i686, msystem: mingw32, debug: true, suffix: "-dbg" },
{ os: windows-2019, arch: i686, msystem: mingw32, debug: false, suffix: "" },
{ os: windows-2019, arch: msvc, msystem: mingw64, debug: true, suffix: "-mdd" },
{ os: windows-2019, arch: msvc, msystem: mingw64, debug: false, suffix: "-md" },
{ os: windows-2016, arch: msvc, msystem: mingw64, debug: true, suffix: "-mdd" },
{ os: windows-2016, arch: msvc, msystem: mingw64, debug: false, suffix: "-md" },
]
steps:
- name: Checkout source
uses: actions/checkout@v2
with:
path: ${{ github.event.repository.name }}
- name: Checkout coinbrew
uses: actions/checkout@v2
with:
repository: coin-or/coinbrew
path: coinbrew
- name: Set up msvc
uses: ilammy/msvc-dev-cmd@v1
if: ${{ matrix.arch == 'msvc' }}
- name: Set correct host flag and install requirements
run: |
echo "host_flag=--host=${{ matrix.arch }}-w64-mingw32" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
C:\msys64\usr\bin\pacman -S mingw-w64-${{ matrix.arch }}-lapack mingw-w64-${{ matrix.arch }}-winpthreads-git mingw-w64-${{ matrix.arch }}-readline mingw-w64-${{ matrix.arch }}-suitesparse mingw-w64-${{ matrix.arch }}-metis --noconfirm
if: ${{ matrix.arch != 'msvc' }}
- name: Set up msys with ${{ matrix.msystem }}
uses: msys2/setup-msys2@v2
with:
update: true
install: >-
base-devel
git
zip
path-type: inherit
msystem: ${{ matrix.msystem }}
- name: Build project
run: |
ADD_ARGS=()
ADD_ARGS+=( --no-prompt )
ADD_ARGS+=( --skip='ThirdParty/Metis ThirdParty/Mumps ThirdParty/Blas ThirdParty/Lapack' )
ADD_BUILD_ARGS=()
ADD_BUILD_ARGS+=( --build=x86_64-w64-mingw32 --tests main --enable-relocatable )
ADD_BUILD_ARGS+=( --verbosity 2 )
[[ ${{ matrix.debug }} == "true" ]] && ADD_BUILD_ARGS+=( --enable-debug )
[[ ${{ matrix.arch }} == "msvc" ]] && ADD_BUILD_ARGS+=( --enable-msvc )
./coinbrew/coinbrew fetch ${{ github.event.repository.name }} --skip-update "${ADD_ARGS[@]}"
./coinbrew/coinbrew build ${{ github.event.repository.name }} ${{ env.host_flag }} \
"${ADD_ARGS[@]}" "${ADD_BUILD_ARGS[@]}"
cp ${{ github.event.repository.name }}/README.md dist/
cp ${{ github.event.repository.name }}/LICENSE dist/
shell: msys2 {0}
- name: Upload failed build directory
uses: actions/upload-artifact@v2
if: failure()
with:
name: ${{ matrix.os}}-{{ matrix.arch }}-debug=${{ matrix.debug }}-failedbuild
path: build
- name: Generate package name for msvc
run: |
msvc_version=${VisualStudioVersion%.*}
echo "package_suffix=w64-msvc${msvc_version}${{ matrix.suffix }}" >> $GITHUB_ENV
shell: msys2 {0}
if: ${{ matrix.arch == 'msvc' }}
- name: Generate package name
run: |
echo "package_suffix=${{ matrix.arch }}-w64-${{ matrix.msystem }}${{ matrix.suffix }}" >> $GITHUB_ENV
shell: msys2 {0}
if: ${{ matrix.arch != 'msvc' }}
- name: Upload artifact
if: ${{ github.event_name == 'pull_request'}}
uses: actions/upload-artifact@v2
with:
name: ${{ github.event.repository.name }}-${{ github.head_ref }}-${{ env.package_suffix }}
path: dist
if-no-files-found: error
- name: Zip up dist contents for release
if: ${{ github.event_name == 'release'}}
run: cd dist && zip -r ../release.zip *
shell: msys2 {0}
- name: Upload package to release
if: ${{ github.event_name == 'release'}}
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: ./release.zip
asset_name: ${{ github.event.repository.name }}-${{ github.event.release.tag_name }}-${{ env.package_suffix }}.zip
asset_content_type: application/gzip
Loading

0 comments on commit 6818f1b

Please sign in to comment.