Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 15 additions & 42 deletions rust/bulk_generation_targets.yml
Original file line number Diff line number Diff line change
@@ -1,45 +1,18 @@
strategy: repo
strategy: dca
language: rust
destination: rust/ql/lib/ext/generated
extractor_options:
- cargo_features='*'
targets:
- git_repo: https://github.com/rust-lang/libc
git_tag: 0.2.172
name: libc
- git_repo: https://github.com/rust-lang/log
git_tag: 0.4.27
name: log
- git_repo: https://github.com/BurntSushi/memchr
git_tag: 2.7.4
name: memchr
- git_repo: https://github.com/matklad/once_cell
git_tag: v1.21.3
name: once_cell
- git_repo: https://github.com/rust-random/rand
git_tag: 0.9.1
name: rand
- git_repo: https://github.com/servo/rust-smallvec
git_tag: v1.15.0
name: smallvec
- git_repo: https://github.com/serde-rs/serde
git_tag: v1.0.219
name: serde
- git_repo: https://github.com/tokio-rs/tokio
git_tag: tokio-1.45.0
name: tokio
- git_repo: https://github.com/seanmonstar/reqwest
git_tag: v0.12.15
name: reqwest
- git_repo: https://github.com/SergioBenitez/Rocket
git_tag: v0.5.1
name: rocket
- git_repo: https://github.com/actix/actix-web
git_tag: web-v4.11.0
name: actix-web
- git_repo: https://github.com/hyperium/hyper
git_tag: v1.6.0
name: hyper
- git_repo: https://github.com/clap-rs/clap
git_tag: v4.5.38
name: clap
- name: rust
- name: libc
- name: log
- name: memchr
- name: once_cell
- name: rand
- name: smallvec
- name: serde
- name: tokio
- name: reqwest
- name: rocket
- name: actix-web
- name: hyper
- name: clap
Copy link
Contributor

Choose a reason for hiding this comment

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

This is a nice simple list, once everything is merged and stable I'll add a bunch more targets to it.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

one thing to keep in mind is that at the moment this list needs to be topologically ordered with respect to dependencies (so later additions should depend on earlier ones and not the other way around). Possibly worth a comment here, now that this is yaml

Copy link
Contributor Author

Choose a reason for hiding this comment

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

also, just so you know, you can tweak what gets generated with any of

with-sinks: false
with-sources: false
with-summaries: false

(all are true by default)

Copy link
Contributor

Choose a reason for hiding this comment

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

What are the expected use cases for those three options?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I don't really know, but you can ask Mathias once he's back from his PTO, two of them are used for the C++ generated models

Copy link
Contributor

Choose a reason for hiding this comment

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

My guess is there are certain libraries that produce a lot of inaccurate models of one type but not the others, and this gives us some additional control. @MathiasVP ? (no rush, not blocking this PR)

Copy link
Contributor

Choose a reason for hiding this comment

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

The reason is simply that C++ doesn't yet autogenerate sources and sinks (for a couple of reasons, but mainly because I didn't bother to set that properly up yet). The MaD generator script (which this script invokes under the hood) already provides these hooks to configure which kinds of models are generated, so I just lifted those hooks to this script in #19627