Skip to content

chore: Replace acap-build crate with external rs4a-eap#239

Draft
apljungquist wants to merge 1 commit into
AxisCommunications:mainfrom
apljungquist:delegate-acap-build
Draft

chore: Replace acap-build crate with external rs4a-eap#239
apljungquist wants to merge 1 commit into
AxisCommunications:mainfrom
apljungquist:delegate-acap-build

Conversation

@apljungquist

Copy link
Copy Markdown
Collaborator

Note

This is still work in progress, I still want to land a few more changes in rs4a and publish the crate.
That said, early feedback is welcome, in particular on issues such as:

  • whether the factoring out is at all acceptable
  • pushing environment variable parsing into the CLI; this is kind of a drive by change but it's a practice that has grown on me since it keeps library functions pure and makes it easy for users of a CLI to see all inputs that affect the behavior of the program

Remove the in-tree acap-build crate and depend on the rs4a-eap crate from apljungquist/rs4acap instead. This has benefits in two categories:

  • Clarifies the purpose of this repo as facilitating the use of Rust in ACAP app implementations
  • rs4a-eap has several implemented and planned improvements, notably the option to not depend on external programs allowing it to be fully installed with cargo, and more robust testing.

We drop all use of the reference implementation, which rs4a does not support and instead rely on the testing done by the library maintainer (me). The approach was flawed anyway since bugs could creep in when staging files in a temporary directory.

Footers

Related-to: #205 (abandoned attempt at not shelling out to cp, a problem that does not affect rs4a-eap)

Remove the in-tree `acap-build` crate and depend on the `rs4a-eap` crate from apljungquist/rs4acap instead.
This has benefits in two categories:
- Clarifies the purpose of this repo as facilitating the use of Rust in ACAP app implementations
- `rs4a-eap` has several implemented and planned improvements, notably the option to not depend on external programs allowing it to be fully installed with cargo, and more robust testing.

We drop all use of the reference implementation, which rs4a does not support and instead rely on the testing done by the library maintainer (me). The approach was flawed anyway since bugs could creep in when staging files in a temporary directory.
.args(args)
.artifact_dir(get_cargo_metadata(None)?.target_directory.join("acap"))
.execute()?;
.execute(cli.source_date_epoch.unwrap_or_default())?;

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't actually match the docstring:

Defaults to the current time.

I need to fix that.

I may move the interpolation into execute or some other shared location.

@apljungquist apljungquist changed the title Replace acap-build crate with rs4a-eap from git chore: Replace acap-build crate with external rs4a-eap Jul 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant