You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* chore: improve pixi config ros
* chore: error on clippy warnings
* fix: config usage
* misc: package map test changes
* docs: add the mapping logic to the documentation
* docs: use simplified version of the mapping structure
The backend will automatically use the metadata from `package.xml` to generate a complete conda package named `ros-jazzy-my-ros-package`.
113
113
The fields in the `pixi.toml` will override the values from `package.xml` if they are explicitly set.
114
114
115
+
### Automatic Dependency Resolution
116
+
117
+
Because the definition of a dependency in a `package.xml` file is not similar to a conda package name, the backend needs to map ROS dependencies to conda packages.
118
+
119
+
-**Known dependencies**: Mapped using the [`robostack.yaml`](https://github.com/prefix-dev/pixi-build-backends/blob/main/backends/pixi-build-ros/robostack.yaml).
120
+
-**Custom mappings**: You can provide additional mappings in your `pixi.toml` under [`[package.build.config.extra-package-mappings]`](#extra-package-mappings)
121
+
-**Other packages**: Mapped to `ros-<distro>-<package-name>` format.
122
+
123
+
The `<distro>` part of the package name is automatically generated based on the `distro` configuration.
124
+
115
125
## Configuration Options
116
126
117
127
You can customize the ROS backend behavior using the `[package.build.config]` section in your `pixi.toml`. The backend supports the following configuration options:
If specified, internal build state and debug information will be written to this directory. Useful for troubleshooting build issues.
153
163
154
-
```toml
164
+
```toml title="pixi.toml"
155
165
[package.build.config]
156
166
debug-dir = ".build-debug"
157
167
```
@@ -164,7 +174,7 @@ debug-dir = ".build-debug"
164
174
165
175
Additional glob patterns to include as input files for the build process. These patterns are added to the default input globs that include ROS-specific files.
Additional dependency mappings to apply to the dependency mapping process.
198
+
These mappings are used to extend the usage of the dependencies in the `package.xml` file.
199
+
200
+
```toml title="pixi.toml"
201
+
[package.build.config]
202
+
extra-package-mappings = [
203
+
{"ros-custom" = { ros = ["ros-custom-msgs"] }},
204
+
"mapping.yml"
205
+
]
206
+
```
207
+
208
+
Or using a toml array of tables:
209
+
210
+
```toml title="pixi.toml"
211
+
[[package.build.config.extra-package-mappings]]
212
+
custom_msgs = { ros = ["custom-messages"] }
213
+
```
214
+
215
+
Or you can use a file directly in the list:
216
+
217
+
```toml title="pixi.toml"
218
+
[package.build.config]
219
+
extra-package-mappings = ["mapping.yml"]
220
+
```
221
+
222
+
The mapping file can contain the following:
223
+
224
+
```yaml title="mapping.yml"
225
+
package_name: # The name of the package in the package.xml
226
+
conda: conda-package-name # Maps to a conda package, e.g. from `conda-forge`
227
+
package_name2: # The name of the package in the package.xml
228
+
conda: [package1, package2] # Maps to a list of conda packages
229
+
ros_package: # The name of the package in the package.xml
230
+
ros: ros_package # Maps to a RoboStack style package name, e.g. `ros-<distro>-ros-package`
231
+
```
232
+
233
+
182
234
## Build Process
183
235
184
236
The ROS backend follows this build process:
@@ -217,20 +269,6 @@ For ROS1 packages using catkin build system:
217
269
</export>
218
270
```
219
271
220
-
## Dependency Mapping
221
-
222
-
The backend automatically maps ROS dependencies to conda packages using the RoboStack project mappings. Dependencies in `package.xml` are converted as follows:
223
-
224
-
-**ROS packages**: Mapped to `ros-<distro>-<package-name>` format
225
-
-**Known dependencies**: Mapped using the `robostack.yaml` configuration file.
0 commit comments