Skip to content

Pass cfg to build script #1580

@dtolnay

Description

@dtolnay

#1543 #1559 broke proc-macro2's documentation build — see dtolnay/proc-macro2#309.

As far as I can tell the difference is that cargo rustdoc -- --cfg mycfg sets mycfg during both the compilation of the build.rs and the invocation of rustdoc, whereas cargo rustdoc --config 'build.rustdocflags=["--cfg", "mycfg"]' sets it only during rustdoc and not the compilation of build.rs.

As far as I can tell there is now no way to set cfg for a build script build on docs.rs.

@willcrichton @jyn514

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions