Skip to content

Commit

Permalink
Fix constraint on protobuf version in gz-msgs python package
Browse files Browse the repository at this point in the history
  • Loading branch information
traversaro authored Oct 24, 2024
1 parent 19e40db commit c967b23
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
2 changes: 2 additions & 0 deletions recipe/build_cxx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ if [[ "${target_platform}" == osx-* ]]; then
CXXFLAGS="${CXXFLAGS} -D_LIBCPP_DISABLE_AVAILABILITY"
fi

env

if [[ "$CONDA_BUILD_CROSS_COMPILATION" == 1 ]]; then
(
mkdir -p build_cxx_host
Expand Down
15 changes: 9 additions & 6 deletions recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,11 @@
{% set component_version = component_name + major_version %}
{% set cxx_name = "lib" + name %}
{% set python_name = name + "-python" %}
{% set protobuf_major_version = "5" %}
{% set protobuf_version = "5.28.2"}
{% set protobuf_major_version = protobuf_version.split('.')[0] %}
{% set next_protobuf_major_version = "6"}




package:
Expand All @@ -20,7 +24,7 @@ source:
- win_enable_py_tests.patch

build:
number: 3
number: 4

outputs:
- name: {{ cxx_name }}
Expand Down Expand Up @@ -94,14 +98,13 @@ outputs:
- libabseil
- libprotobuf
- python
- protobuf {{ protobuf_major_version }}.*
- protobuf {{ protobuf_version }}
- pytest
- dlfcn-win32 # [win]
run:
- python >=3.8
# We need to ensure that at runtime we use the same major protobuf
# version that was used to generate the python messages
- protobuf {{ protobuf_major_version }}.*
# See https://protobuf.dev/support/cross-version-runtime-guarantee/
- protobuf >={{ protobuf_version }},<{{ next_protobuf_major_version }}.0a0
test:
commands:
- pip check
Expand Down

0 comments on commit c967b23

Please sign in to comment.