Skip to content

Commit

Permalink
Merge pull request #22443 from bluescarni/range-v3
Browse files Browse the repository at this point in the history
Add range-v3
  • Loading branch information
isuruf committed Apr 20, 2023
2 parents c6fec8c + ada06e6 commit 09d9af6
Show file tree
Hide file tree
Showing 3 changed files with 79 additions and 0 deletions.
21 changes: 21 additions & 0 deletions recipes/range-v3/bld.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
mkdir build
cd build

:: Generator can be removed once https://github.com/conda-forge/conda-forge-pinning-feedstock/pull/4357 is in
cmake -G "NMake Makefiles" ^
-DCMAKE_PREFIX_PATH=%LIBRARY_PREFIX% ^
-DCMAKE_INSTALL_PREFIX=%LIBRARY_PREFIX% ^
-DBUILD_TESTING=YES ^
-DRANGES_ASSERTIONS=NO ^
-DRANGES_BUILD_CALENDAR_EXAMPLE=NO ^
-DRANGES_DEBUG_INFO=NO ^
-DRANGE_V3_DOCS=NO ^
-DRANGE_V3_EXAMPLES=NO ^
-DRANGE_V3_TESTS=YES ^
..

cmake --build . --config Release

ctest --output-on-failure -j%CPU_COUNT% -V -C Release

cmake --build . --config Release --target install
24 changes: 24 additions & 0 deletions recipes/range-v3/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
#!/usr/bin/env bash

mkdir build
cd build

cmake ${CMAKE_ARGS} \
-DCMAKE_PREFIX_PATH=$PREFIX \
-DCMAKE_INSTALL_PREFIX=$PREFIX \
-DBUILD_TESTING=YES \
-DCMAKE_BUILD_TYPE=Release \
-DRANGES_ASSERTIONS=NO \
-DRANGES_BUILD_CALENDAR_EXAMPLE=NO \
-DRANGES_DEBUG_INFO=NO \
-DRANGE_V3_DOCS=NO \
-DRANGE_V3_EXAMPLES=NO \
-DRANGE_V3_TESTS=YES \
..


make -j${CPU_COUNT} VERBOSE=1

ctest -j${CPU_COUNT} --output-on-failure

make install
34 changes: 34 additions & 0 deletions recipes/range-v3/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{% set version = "0.12.0" %}

package:
name: range-v3
version: {{ version }}

source:
url: https://github.com/ericniebler/range-v3/archive/refs/tags/{{ version }}.tar.gz
sha256: 015adb2300a98edfceaf0725beec3337f542af4915cec4d0b89fa0886f4ba9cb

build:
number: 0

requirements:
build:
- {{ compiler('c') }}
- {{ compiler('cxx') }}
- cmake
- make # [unix]

test:
commands:
- test -f $PREFIX/include/range/v3/all.hpp # [unix]
- if not exist %PREFIX%\\Library\\include\\range\\v3\\all.hpp exit 1 # [win]

about:
home: https://github.com/ericniebler/range-v3
license: BSL-1.0
license_file: LICENSE.txt
summary: Range library for C++14/17/20, basis for C++20's std::ranges

extra:
recipe-maintainers:
- bluescarni

0 comments on commit 09d9af6

Please sign in to comment.