Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding osqp-eigen recipe #15309

Merged
merged 9 commits into from
Jun 23, 2021
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions recipes/osqp-eigen/bld.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
mkdir build
cd build

cmake ^
-G "NMake Makefiles" ^
-DCMAKE_INSTALL_PREFIX=%LIBRARY_PREFIX% ^
-DCMAKE_PREFIX_PATH=%LIBRARY_PREFIX% ^
-DCMAKE_BUILD_TYPE=Release ^
%SRC_DIR%
if errorlevel 1 exit 1

:: Build.
cmake --build . --config Release
if errorlevel 1 exit 1

:: Install.
cmake --build . --config Release --target install
if errorlevel 1 exit 1
11 changes: 11 additions & 0 deletions recipes/osqp-eigen/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/sh

mkdir build && cd build

cmake ${CMAKE_ARGS} -DCMAKE_INSTALL_PREFIX=$PREFIX \
-DCMAKE_PREFIX_PATH=$PREFIX \
GiulioRomualdi marked this conversation as resolved.
Show resolved Hide resolved
-DCMAKE_BUILD_TYPE=Release \
$SRC_DIR

make -j${CPU_COUNT}
make install
48 changes: 48 additions & 0 deletions recipes/osqp-eigen/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
{% set name = "osqp-eigen" %}
{% set version = "0.6.4" %}

package:
name: {{ name }}
version: {{ version }}

source:
url: https://github.com/robotology/{{ name }}/archive/refs/tags/v{{ version }}.tar.gz
sha256: f3fcff8b26646410b40c2003f5c2ffb7b0099fa70a6aa531dec69cfaf4de9aef

build:
number: 0
run_exports:
- {{ pin_subpackage(name, max_pin='x.x.x') }}

requirements:
build:
- {{ compiler('c') }}
- {{ compiler('cxx') }}
- make # [not win]
- cmake
host:
- libosqp
- eigen

test:
commands:
- test -f ${PREFIX}/include/OsqpEigen/OsqpEigen.h # [not win]
- test -f ${PREFIX}/lib/cmake/OsqpEigen/OsqpEigenConfig.cmake # [not win]
- test -f ${PREFIX}/lib/libOsqpEigen.so # [linux]
- test -f ${PREFIX}/lib/libOsqpEigen.dylib # [osx]
- if not exist %PREFIX%\\Library\\include\\OsqpEigen\\OsqpEigen.h exit 1 # [win]
- if not exist %PREFIX%\\Library\\lib\\OsqpEigen.lib exit 1 # [win]
- if not exist %PREFIX%\\Library\\bin\\OsqpEigen.dll exit 1 # [win]
- if not exist %PREFIX%\\Library\\lib\\cmake\\OsqpEigen\\OsqpEigenConfig.cmake exit 1 # [win]

about:
home: https://github.com/robotology/osqp-eigen
license: LGPL-3.0-or-later
license_family: LGPL
license_file: LICENSE
summary: 'Simple C++ wrapper for osqp library.'

extra:
recipe-maintainers:
- GiulioRomualdi
- traversaro