Skip to content

Commit aa18162

Browse files
Merge pull request #229 from traversaro/rebuild-christmas-2024-linux-64-rattler-build
Rebuild January 2025 - switch to rattler-build
2 parents 71d4b56 + 0218b40 commit aa18162

File tree

105 files changed

+5298
-2646
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

105 files changed

+5298
-2646
lines changed

.ci_support/conda_forge_pinnings.yaml

Lines changed: 0 additions & 847 deletions
This file was deleted.

.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# GitHub syntax highlighting
2+
pixi.lock linguist-language=YAML linguist-generated=true

.github/testpr_environment.yml

Lines changed: 0 additions & 15 deletions
This file was deleted.

.github/workflows/main.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
name: Generate CI pipelines for ROS 2 packages
2+
13
permissions:
24
actions: write
35
contents: write
@@ -18,7 +20,7 @@ jobs:
1820
python-version: '3.11' # Version range or exact version of a Python version to use, using SemVer's version range syntax
1921
- name: Install vinca
2022
run: |
21-
pip install git+https://github.com/RoboStack/vinca.git
23+
pip install git+https://github.com/RoboStack/vinca.git@rattler-build-humble
2224
2325
- name: Generate recipes for linux-64
2426
run: |

.github/workflows/testpr.yml

Lines changed: 66 additions & 98 deletions
Original file line numberDiff line numberDiff line change
@@ -8,71 +8,51 @@ env:
88

99
jobs:
1010
build:
11-
runs-on: ${{ matrix.os }}
1211
strategy:
1312
fail-fast: false
1413
matrix:
15-
os: [ubuntu-latest, macos-latest, macos-14, windows-2019]
16-
platform: [linux-64, linux-aarch64, osx-64, win-64, osx-arm64]
17-
exclude:
18-
- os: ubuntu-latest
19-
platform: win-64
20-
- os: ubuntu-latest
21-
platform: osx-64
14+
include:
2215
- os: ubuntu-latest
23-
platform: osx-arm64
24-
- os: macos-14
2516
platform: linux-64
26-
- os: macos-14
17+
- os: cirun-linux-aarch64--${{ github.run_id }}
2718
platform: linux-aarch64
28-
- os: macos-14
19+
- os: macos-13
2920
platform: osx-64
3021
- os: macos-14
31-
platform: win-64
32-
- os: macos-latest
33-
platform: linux-64
34-
- os: macos-latest
35-
platform: linux-aarch64
36-
- os: macos-latest
3722
platform: osx-arm64
38-
- os: macos-latest
39-
platform: win-64
4023
- os: windows-2019
41-
platform: linux-64
42-
- os: windows-2019
43-
platform: linux-aarch64
44-
- os: windows-2019
45-
platform: osx-64
46-
- os: windows-2019
47-
platform: osx-arm64
24+
platform: win-64
25+
26+
runs-on: ${{ matrix.os }}
27+
4828
steps:
29+
- uses: actions/checkout@v4
30+
with:
31+
persist-credentials: false # otherwise, the token used is the GITHUB_TOKEN, instead of your personal token
32+
fetch-depth: 0 # otherwise, you will failed to push refs to dest repo
33+
34+
- uses: prefix-dev/[email protected]
35+
with:
36+
environments: beta
37+
frozen: true
38+
4939
# Workaround for https://github.com/RoboStack/ros-humble/pull/141#issuecomment-1941919816
5040
- name: Clean up PATH
5141
if: contains(matrix.os, 'windows')
5242
uses: egor-tensin/cleanup-path@v4
5343
with:
5444
# cygpath in C:\Program Files\Git\usr\bin is used by install micromamba
55-
# git in C:\Program Files\Git\bin is used by pip install git+
45+
# git in C:\Program Files\Git\bin is used by pip install git+
5646
dirs: 'C:\Program Files\Git\usr\bin;C:\Program Files\Git\bin;C:\Program Files\Git\cmd;C:\Program Files\Git\mingw64\bin'
5747

58-
- uses: actions/checkout@master
59-
- name: install micromamba
60-
uses: mamba-org/setup-micromamba@main
61-
with:
62-
environment-file: .github/testpr_environment.yml
63-
condarc: |
64-
channels:
65-
- robostack-staging
66-
- conda-forge
67-
68-
- shell: bash -l {0}
69-
if: matrix.platform == 'linux-aarch64'
70-
run: |
71-
echo "::group::Configure binfmt_misc"
72-
docker run --rm --privileged multiarch/qemu-user-static:register --reset --credential yes
73-
export FEEDSTOCK_NAME="$(basename $GITHUB_REPOSITORY)"
74-
export GIT_BRANCH="$(basename $GITHUB_REF)"
75-
echo "::endgroup::"
48+
# - shell: bash -l {0}
49+
# if: matrix.platform == 'linux-aarch64'
50+
# run: |
51+
# echo "::group::Configure binfmt_misc"
52+
# docker run --rm --privileged multiarch/qemu-user-static:register --reset --credential yes
53+
# export FEEDSTOCK_NAME="$(basename $GITHUB_REPOSITORY)"
54+
# export GIT_BRANCH="$(basename $GITHUB_REF)"
55+
# echo "::endgroup::"
7656

7757
- name: Install libgl1-mesa-dev (only for linux-aarch64)
7858
if: matrix.platform == 'linux-aarch64'
@@ -81,24 +61,15 @@ jobs:
8161
sudo apt-get update
8262
sudo apt-get install -y libgl1-mesa-dev libglu1-mesa-dev libx11-dev libxi-dev libxmu-dev
8363
84-
- shell: bash -l {0}
85-
run: |
86-
conda config --show channels | grep defaults && conda config --remove channels defaults
87-
conda info
88-
conda config --show
89-
micromamba install -y pip rospkg networkx "catkin_pkg>=0.4.16" "ruamel.yaml>=0.16.6" "rosdistro>=0.8.0" "empy>=3.3.4" boa
90-
- name: install vinca
91-
shell: bash -l {0}
92-
run: |
93-
# use no-deps for now, otherwise problems with ruamel.
94-
pip install git+https://github.com/RoboStack/vinca.git --no-deps
9564
# For some reason, the Strawberry perl's pkg-config is found
9665
# instead of the conda's one, so let's delete the /c/Strawberry directory
66+
# Furthermore, we also need to remove an older SDK that is used and can result in compilation problems
9767
- name: Debug pkg-config problem
9868
if: contains(matrix.os, 'windows')
9969
shell: bash -l {0}
10070
run: |
10171
rm -rf /c/Strawberry
72+
rm -rf "/c/Program Files (x86)/Windows Kits/10/Include/10.0.17763.0/"
10273
10374
- name: Check what files have changed
10475
id: filecheck
@@ -119,85 +90,82 @@ jobs:
11990
echo "::set-output name=WIN_YAML_CHANGED::${?}"
12091
- name: Generate recipes for linux-64
12192
shell: bash -l {0}
122-
if: steps.filecheck.outputs.LINUX_YAML_CHANGED == 1 && matrix.os == 'ubuntu-latest' && matrix.platform == 'linux-64'
93+
if: steps.filecheck.outputs.LINUX_YAML_CHANGED == 1 && matrix.platform == 'linux-64'
12394
run: |
124-
git clean -fdx
12595
cp vinca_linux_64.yaml vinca.yaml
126-
vinca --platform linux-64
127-
ls
128-
cat recipe.yaml
96+
mkdir -p recipes
97+
$HOME/.pixi/bin/pixi run -e beta -v vinca --platform linux-64 -m -n
98+
ls -la recipes
12999
- name: Generate recipes for linux-aarch64
130100
shell: bash -l {0}
131-
if: steps.filecheck.outputs.LINUX_AARCH_YAML_CHANGED == 1 && matrix.os == 'ubuntu-latest' && matrix.platform == 'linux-aarch64'
101+
if: steps.filecheck.outputs.LINUX_AARCH_YAML_CHANGED == 1 && matrix.platform == 'linux-aarch64'
132102
run: |
133-
git clean -fdx
134103
cp vinca_linux_aarch64.yaml vinca.yaml
135-
vinca --platform linux-aarch64
136-
ls
137-
cat recipe.yaml
104+
mkdir -p recipes
105+
$HOME/.pixi/bin/pixi run -e beta -v vinca --platform linux-aarch64 -m -n
106+
ls -la recipes
138107
- name: Generate recipes for osx-64
139108
shell: bash -l {0}
140-
if: steps.filecheck.outputs.OSX_YAML_CHANGED == 1 && matrix.os == 'macos-latest' && matrix.platform == 'osx-64'
109+
if: steps.filecheck.outputs.OSX_YAML_CHANGED == 1 && matrix.platform == 'osx-64'
141110
run: |
142-
git clean -fdx
143111
cp vinca_osx.yaml vinca.yaml
144-
vinca --platform osx-64
145-
ls
146-
cat recipe.yaml
112+
mkdir -p recipes
113+
$HOME/.pixi/bin/pixi run -e beta -v vinca --platform osx-64 -m -n
114+
ls -la recipes
147115
- name: Generate recipes for osx-arm64
148116
shell: bash -l {0}
149-
if: steps.filecheck.outputs.OSX_ARM_YAML_CHANGED == 1 && matrix.os == 'macos-14' && matrix.platform == 'osx-arm64'
117+
if: steps.filecheck.outputs.OSX_ARM_YAML_CHANGED == 1 && matrix.platform == 'osx-arm64'
150118
run: |
151-
git clean -fdx
152119
cp vinca_osx_arm64.yaml vinca.yaml
153-
vinca --platform osx-arm64
154-
ls
155-
cat recipe.yaml
120+
mkdir -p recipes
121+
$HOME/.pixi/bin/pixi run -e beta -v vinca --platform osx-arm64 -m -n
122+
ls -la recipes
156123
- name: Generate recipes for win-64
157124
shell: bash -l {0}
158-
if: steps.filecheck.outputs.WIN_YAML_CHANGED == 1 && matrix.os == 'windows-2019' && matrix.platform == 'win-64'
125+
if: steps.filecheck.outputs.WIN_YAML_CHANGED == 1 && matrix.platform == 'win-64'
159126
run: |
127+
# Workaround for problem related to long paths
160128
echo "CONDA_BLD_PATH=C:\\bld\\" >> $GITHUB_ENV
161-
git clean -fdx
129+
mkdir /c/bld
162130
cp vinca_win.yaml vinca.yaml
163-
vinca --platform win-64
164-
ls
165-
cat recipe.yaml
131+
mkdir -p recipes
132+
$HOME/.pixi/bin/pixi run -e beta -v vinca --platform win-64 -m -n
133+
ls -la recipes
166134
- name: Check if there are packages to be built
167135
id: newrecipecheck
168136
shell: bash -l {0}
169137
run: |
170138
# continue on error
171139
set +e
172-
grep -q "outputs: \[\]" recipe.yaml > /dev/null
140+
test ! -d recipes
173141
echo "::set-output name=RECIPE_CREATED::${?}"
174142
- name: Build recipes for linux-64
175143
shell: bash -l {0}
144+
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.LINUX_YAML_CHANGED == 1 && matrix.platform == 'linux-64'
176145
run: |
177-
boa build additional_recipes/ros2-distro-mutex/ -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
178-
boa build . -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
179-
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.LINUX_YAML_CHANGED == 1 && matrix.os == 'ubuntu-latest' && matrix.platform == 'linux-64'
146+
env -i $HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe additional_recipes/ros2-distro-mutex/ --target-platform linux-64 -m ./conda_build_config.yaml -c robostack-staging -c conda-forge --skip-existing
147+
env -i $HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe-dir recipes --target-platform linux-64 -m ./conda_build_config.yaml -c robostack-staging -c conda-forge --skip-existing
180148
- name: Build recipes for linux-aarch64
181149
shell: bash -l {0}
182-
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.LINUX_AARCH_YAML_CHANGED == 1 && matrix.os == 'ubuntu-latest' && matrix.platform == 'linux-aarch64'
150+
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.LINUX_AARCH_YAML_CHANGED == 1 && matrix.platform == 'linux-aarch64'
183151
run: |
184-
boa build additional_recipes/ros2-distro-mutex/ -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml --target-platform=linux-aarch64
185-
boa build . -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml --target-platform=linux-aarch64
152+
env -i $HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe additional_recipes/ros2-distro-mutex/ --target-platform linux-aarch64 -m ./conda_build_config.yaml -c robostack-staging -c conda-forge --skip-existing
153+
env -i $HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe-dir recipes --target-platform linux-aarch64 -m ./conda_build_config.yaml -c robostack-staging -c conda-forge --skip-existing
186154
- name: Build recipes for osx-64
187155
shell: bash -l {0}
188-
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.OSX_YAML_CHANGED == 1 && matrix.os == 'macos-latest' && matrix.platform == 'osx-64'
156+
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.OSX_YAML_CHANGED == 1 && matrix.platform == 'osx-64'
189157
run: |
190-
boa build additional_recipes/ros2-distro-mutex/ -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
191-
boa build . -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
158+
env -i $HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe additional_recipes/ros2-distro-mutex/ --target-platform osx-64 -m ./conda_build_config.yaml -c robostack-staging -c conda-forge --skip-existing
159+
env -i $HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe-dir recipes --target-platform osx-64 -m ./conda_build_config.yaml -c robostack-staging -c conda-forge --skip-existing
192160
- name: Build recipes for osx-arm64
193161
shell: bash -l {0}
194-
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.OSX_ARM_YAML_CHANGED == 1 && matrix.os == 'macos-14' && matrix.platform == 'osx-arm64'
162+
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.OSX_ARM_YAML_CHANGED == 1 && matrix.platform == 'osx-arm64'
195163
run: |
196-
boa build additional_recipes/ros2-distro-mutex/ -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml --target-platform=osx-arm64
197-
boa build . -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
164+
env -i $HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe additional_recipes/ros2-distro-mutex/ --target-platform osx-arm64 -m ./conda_build_config.yaml -c robostack-staging -c conda-forge --skip-existing
165+
env -i $HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe-dir recipes --target-platform osx-arm64 -m ./conda_build_config.yaml -c robostack-staging -c conda-forge --skip-existing
198166
- name: Build recipes for win-64
199167
shell: bash -l {0}
200-
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.WIN_YAML_CHANGED == 1 && matrix.os == 'windows-2019' && matrix.platform == 'win-64'
168+
if: steps.newrecipecheck.outputs.RECIPE_CREATED == 1 && steps.filecheck.outputs.WIN_YAML_CHANGED == 1 && matrix.platform == 'win-64'
201169
run: |
202-
boa build additional_recipes/ros2-distro-mutex/ -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
203-
boa build . -m ./.ci_support/conda_forge_pinnings.yaml -m ./conda_build_config.yaml
170+
$HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe additional_recipes/ros2-distro-mutex/ --target-platform win-64 -m ./conda_build_config.yaml -c robostack-staging -c conda-forge --skip-existing
171+
$HOME/.pixi/bin/pixi run -e beta rattler-build build --recipe-dir recipes -m ./conda_build_config.yaml --target-platform win-64 -c robostack-staging -c conda-forge --skip-existing

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,7 @@ recipes/
55
*.ps1
66
*.json
77
.DS_Store
8+
# pixi environments
9+
.pixi
10+
*.egg-info
11+
output/

.scripts/build_linux.sh

Lines changed: 13 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -9,67 +9,25 @@ set -xeuo pipefail
99
export PYTHONUNBUFFERED=1
1010
export FEEDSTOCK_ROOT="${FEEDSTOCK_ROOT:-/home/conda/feedstock_root}"
1111
export RECIPE_ROOT="${RECIPE_ROOT:-/home/conda/recipe_root}"
12-
# export CI_SUPPORT="${FEEDSTOCK_ROOT}/.ci_support"
13-
# export CONFIG_FILE="${CI_SUPPORT}/${CONFIG}.yaml"
1412

15-
cat >~/.condarc <<CONDARC
16-
conda-build:
17-
root-dir: /opt/conda/build_artifacts
18-
CONDARC
13+
curl -fsSL https://pixi.sh/install.sh | bash
14+
export PATH="$HOME/.pixi/bin:$PATH"
1915

20-
# This doesn't work, see e.g. https://dev.azure.com/robostack/ros_pipelines/_build/results?buildId=188&view=logs&j=4e20d398-0572-5e54-89c7-6bdb9c00a59a&t=f5885ff8-badf-54b3-1543-35164851bdf3
21-
# if grep -q libgl "recipes/${CURRENT_BUILD_PKG_NAME}.yaml"; then
22-
# sudo yum install -y install mesa-libGL-devel
23-
# fi
24-
25-
export "CONDA_BLD_PATH=/opt/conda/build_artifacts"
26-
27-
mkdir -p $CONDA_BLD_PATH
28-
conda index $CONDA_BLD_PATH
29-
30-
conda config --set remote_max_retries 5
31-
conda config --add channels conda-forge
32-
conda config --add channels robostack-staging
33-
conda config --add channels $CONDA_BLD_PATH
34-
conda config --remove channels defaults
35-
# conda config --set channel_priority strict
36-
37-
mamba update conda --yes --quiet -c conda-forge
38-
mamba install --yes --quiet pip conda-build anaconda-client mamba boa
39-
40-
# setup_conda_rc "${FEEDSTOCK_ROOT}" "${RECIPE_ROOT}" "${CONFIG_FILE}"
41-
# export PATH="$HOME/miniconda/bin:$PATH"
42-
conda config --set anaconda_upload yes
43-
conda config --set show_channel_urls true
44-
conda config --set auto_update_conda false
45-
conda config --set add_pip_as_python_dependency false
46-
47-
conda info
48-
conda config --show-sources
49-
conda list --show-channel-urls
16+
export CONDA_BLD_PATH="/opt/conda/build_artifacts"
5017

5118
pwd
5219

53-
for recipe in ${CURRENT_RECIPES[@]}; do
54-
cd ${FEEDSTOCK_ROOT}/recipes/${recipe}
55-
boa build . -m ${FEEDSTOCK_ROOT}/.ci_support/conda_forge_pinnings.yaml -m ${FEEDSTOCK_ROOT}/conda_build_config.yaml
56-
done
57-
58-
anaconda -t ${ANACONDA_API_TOKEN} upload /opt/conda/build_artifacts/linux-*/*.tar.bz2 --force
59-
# quetz-client "${QUETZ_URL}" /opt/conda/build_artifacts --force
60-
61-
# set up the condarc
20+
cd ${FEEDSTOCK_ROOT}
6221

63-
# source run_conda_forge_build_setup
64-
65-
# # make the build number clobber
66-
# make_build_number "${FEEDSTOCK_ROOT}" "${RECIPE_ROOT}" "${CONFIG_FILE}"
22+
for recipe in ${CURRENT_RECIPES[@]}; do
23+
pixi run -v rattler-build build \
24+
--recipe ${FEEDSTOCK_ROOT}/recipes/${recipe} \
25+
-m ${FEEDSTOCK_ROOT}/conda_build_config.yaml \
26+
-c robostack-staging -c conda-forge \
27+
--output-dir $CONDA_BLD_PATH
6728

68-
# conda build "${RECIPE_ROOT}" -m "${CI_SUPPORT}/${CONFIG}.yaml" \
69-
# --clobber-file "${CI_SUPPORT}/clobber_${CONFIG}.yaml"
29+
# -m ${FEEDSTOCK_ROOT}/.ci_support/conda_forge_pinnings.yaml \
7030

71-
# if [[ "${UPLOAD_PACKAGES}" != "False" ]]; then
72-
# upload_package "${FEEDSTOCK_ROOT}" "${RECIPE_ROOT}" "${CONFIG_FILE}"
73-
# fi
31+
done
7432

75-
# touch "${FEEDSTOCK_ROOT}/build_artifacts/conda-forge-build-done-${CONFIG}"
33+
pixi run upload ${CONDA_BLD_PATH}/linux-*/*.conda --force

0 commit comments

Comments
 (0)