Commit graph

24 commits

Author SHA1 Message Date
Michal Sojka
0ecce1a1b5 Update patchAmentVendorGit to use automatically extracted information about vendored source
The information is stored in vendored-source.json files in the package
directories. The file can be automatically generated by running
command like this:

    $(nix-build -A rosPackages.jazzy.gz-math-vendor.updateAmentVendor)'

This command executes Cmake for the given package with an alternative
implementation of the ament_vendor Cmake macro, which generates the
file instead of fetching the source code. The above command generates
`distros/jazzy/gz-math-vendor/vendored-source.json` files with this
content:

    {
      "url": "https://github.com/gazebosim/gz-math.git",
      "rev": "gz-math7_7.5.2",
      "hash": "sha256-LwYeyv8nwX06n5ju+ra2uqNMedMSLRumem8qDHXtNns="
    }

patchAmentVendorGit function is updated to pick the information about
patching from that file instead of from its arguments.

patchGzAmentVendorGit is updated similarly and the check for version
mismatch is removed, because it would not work (version information is
not available from function arguments) and more importantly, it
is (hopefully) no longer needed, because the version will always be
updated automatically by CI.
2025-04-13 21:39:02 -04:00
Ben Wolsieffer
f5f0ee1237 Cleanup overrides
Move some ROS 1 specific overrides out of distro-overlay.nix, get rid of
some that have been fixed upstream and remove some for packages that
only exist in ancient distros.
2024-11-17 15:07:05 -05:00
Ben Wolsieffer
f556a34f39 Improve patchExternalProjectGit
Add basic support for checking the version if it is assigned to a
variable.
2024-11-15 13:10:05 -05:00
Ben Wolsieffer
a5a2a217b3 Don't install ament-cmake-vendor packages to /opt
Use the standard install directories instead. This makes the packages
integrate with Nix better and doesn't appear to break anything.
2024-10-15 21:40:40 -04:00
hacker1024
76cfc9ec7e lib.patchGzAmentVendorGit: Add GZ_CONFIG_PATH to passthru 2024-10-13 16:32:24 -04:00
Bernd Müller
a20dfec18d [fix] gz setup and apply suggestions from wentasah 2024-10-13 16:32:24 -04:00
Michal Sojka
14177a7922 Patch and fix gz-*-vendor packages for Jazzy and Rolling
This fixes build failures in gz-*-vendor packages for Jazzy and
Rolling. Some of these packages are required for building rviz2.

Since most of the gz-* packages share the same structure, we introduce
patchGzAmentVendorGit function to make patching easier. In addition to
patching ament_vendor() calls, it adds a check to CMakeLists.txt to
detect upstream updates of the vendored package version. This should
help keeping our overrides in sync with upstream.

Currently, the overrides for Jazzy and Rolling are the same.

Co-authored-by: Błażej Sowa <bsowa123@gmail.com>
2024-10-13 16:32:24 -04:00
Ben Wolsieffer
80b46d5263 patchExternalProjectGit: fail if URL or rev doesn't match
This catches when packages update their vendored version but we haven't
updated on our end. Try to fix all usages of patchExternalProjectGit so
they are correct now.
2024-07-23 22:22:37 -04:00
Ben Wolsieffer
4fb038f771 substituteInPlace: --replace -> --replace-fail
This will help spot bugs and cases where the substitutions are no longer
applying.
2024-07-21 17:16:34 -04:00
Ben Wolsieffer
2427b8430e lib: tarSource: fix evaluation with no hash
Passing a null hash to mkDerivation now throws an error.
2023-11-26 16:18:48 -05:00
Ben Wolsieffer
27df3bd06a rviz-ogre-vendor: fix hash again, this time make imgui FOD
The imgui.tar store path makes into into the source tarball, so imgui must be
a fixed output derivation.
2023-10-02 22:41:43 -04:00
Ben Wolsieffer
3f59cb9588 lib.tarSource: normalize time stamps
This fixes non-determinism due to files changed in the hook.

Fixes #308
2023-09-28 22:37:26 -04:00
Ben Wolsieffer
e9d9ef5749 Rename patchVendorGit to patchExternalProjectGit 2023-09-08 20:45:48 -04:00
Ben Wolsieffer
9417386d01 lib: get rid of "with lib;" 2023-08-05 19:55:59 -04:00
Ben Wolsieffer
5f9268646a rolling: rviz-ogre-vendor: correctly patch vendor URLs
This package requires complex patching. It uses ament_vendor(), which is picky
about what kinds of sources it requires. Additionally, ogre contains its own
vendoring of imgui that needs to be patched.
2023-08-05 19:50:56 -04:00
Ben Wolsieffer
ea2b17b2d5 Replace mergeOverlays with composeManyExtensions
This does the same thing, but is provided by nixpkgs.
2022-09-20 15:18:02 -04:00
Ben Wolsieffer
77f8c165f7 Revert "Use Boost 1.73 to get rid of Boost Python patching."
This reverts commit 0a31983537.
2022-03-29 12:50:00 -04:00
Ben Wolsieffer
0a31983537 Use Boost 1.73 to get rid of Boost Python patching. 2021-11-24 20:17:55 -05:00
Ben Wolsieffer
b14b103012 Improve overlay lib functions some more. 2020-08-02 15:05:33 -04:00
Ben Wolsieffer
b1c2f965a6 Improve overlay functions. 2020-08-02 14:29:36 -04:00
Ben Wolsieffer
b0c384c13a fmilibrary-vendor: fix vendor URL 2020-02-04 21:08:38 -05:00
Ben Wolsieffer
2c19fe0545 eloquent: foonathan-memory-vendor: work around the poorly designed build system 2019-12-09 22:39:31 -05:00
Ben Wolsieffer
b2e9de9c59 Improve patchBoostPython 2019-12-08 12:08:42 -05:00
Ben Wolsieffer
d59aab21f6 Refactor functions into lib attrset. 2019-12-06 17:19:28 -05:00